3#include "iguana/algorithms/Algorithm.h"
5#include "iguana/services/ConcurrentParam.h"
6#include "iguana/services/RCDBReader.h"
26 void Start(hipo::banklist& banks)
override;
27 bool Run(hipo::banklist& banks)
const override;
37 hipo::bank
const& particle_bank,
38 hipo::bank
const& config_bank,
39 hipo::bank& result_bank)
const;
46 concurrent_key_t
PrepareEvent(
int const runnum,
double const beam_energy = -1)
const;
58 concurrent_key_t
const key)
const;
70 int FindScatteredLepton(hipo::bank
const& particle_bank, concurrent_key_t
const key)
const;
72 void Reload(
int const runnum,
double const user_beam_energy, concurrent_key_t key)
const;
75 hipo::banklist::size_type b_particle;
76 hipo::banklist::size_type b_config;
77 hipo::banklist::size_type b_result;
94 mutable std::unique_ptr<ConcurrentParam<int>> o_runnum;
95 mutable std::unique_ptr<ConcurrentParam<std::vector<double>>> o_target_PxPyPzM;
96 mutable std::unique_ptr<ConcurrentParam<std::vector<double>>> o_beam_PxPyPzM;
100 enum method_reconstruction { scattered_lepton };
101 enum method_lepton_finder { highest_energy_FD_trigger };
102 method_reconstruction o_method_reconstruction;
103 method_lepton_finder o_method_lepton_finder;
105 std::unique_ptr<RCDBReader> m_rcdb;
#define DEFINE_IGUANA_ALGORITHM(ALGO_NAME, ALGO_FULL_NAME)
common objects used in algorithms
double vector_element_t
Vector element type.
Algorithm(std::string_view name)
Algorithm: Calculate inclusive kinematics quantities
void Stop() override
Finalize this algorithm after all events are processed.
void Start(hipo::banklist &banks) override
Initialize this algorithm before any events are processed, with the intent to process banks.
bool Run(hipo::banklist &banks) const override
Run Function: Process an event's hipo::banklist
InclusiveKinematicsVars ComputeFromLepton(vector_element_t const lepton_px, vector_element_t const lepton_py, vector_element_t const lepton_pz, concurrent_key_t const key) const
Action Function: compute kinematics from the scattered lepton.
concurrent_key_t PrepareEvent(int const runnum, double const beam_energy=-1) const
Action Function: prepare the event
bool Run(hipo::bank const &particle_bank, hipo::bank const &config_bank, hipo::bank &result_bank) const
Run Function: Process an event's hipo::bank objects
Set of variables created by creator algorithm iguana::physics::InclusiveKinematics.