LDMX Software
EcalMipTrackingProcessor.h
Go to the documentation of this file.
1
8#ifndef EVENTPROC_ECALMIPTRACKINGPROCESSOR_H_
9#define EVENTPROC_ECALMIPTRACKINGPROCESSOR_H_
10
11// LDMX
13#include "DetDescr/EcalID.h"
15#include "Framework/Configure/Parameters.h"
17
18// C++ Standard Library
19#include <map>
20#include <string>
21#include <utility>
22
23namespace ecal {
25 public:
26 typedef std::pair<ldmx::EcalID, float> CellEnergyPair;
27
28 using XYCoords = ldmx::XYCoords;
29
30 EcalMipTrackingProcessor(const std::string& name, framework::Process& process)
31 : Producer(name, process) {}
32
33 virtual ~EcalMipTrackingProcessor() = default;
34
41 void onNewRun(const ldmx::RunHeader& rh) override;
42
46 void onProcessEnd() override;
47
53 void configure(framework::config::Parameters& parameters) override;
54
55 void produce(framework::Event& event) override;
56
57 using HitData = ldmx::HitData;
58
59 private:
60 void clearProcessor();
61
62 private:
63 int nevents_{0};
64 double processing_time_{0.};
65
66 std::map<std::string, double> profiling_map_;
67
68 double linreg_radius_{0};
69
70 int n_ecal_layers_{0};
71 int n_readout_hits_{0};
72
73 // MIP tracking
85
86 std::string ecal_collection_name_{"EcalVeto"};
87 std::string ecal_pass_name_{""};
88 std::string mip_collection_name_{"EcalTrajectoryInfo"};
89 std::string mip_pass_name_{""};
90 std::string mip_result_name_{"EcalMipResult"};
91
94};
95
96} // namespace ecal
97
98#endif
Class that translates raw positions of ECal module hits into cells in a hexagonal readout.
Class that defines an ECal detector ID with a cell number.
Class that determines MIP tracking information using ECAL hit information.
Base classes for all user event processing components to extend.
const ldmx::EcalGeometry * geometry_
handle to current geometry (to share with member functions)
int photon_territory_hits_
Number of hits in the photon territory.
void produce(framework::Event &event) override
Process the event and put new data products into it.
void onProcessEnd() override
Callback for the EventProcessor to take any necessary action when the processing of events finishes,...
int n_linreg_tracks_
Number of "linreg" tracks found in the event.
void onNewRun(const ldmx::RunHeader &rh) override
onNewRun is the first function called for each processor after the conditions are fully configured an...
int n_near_ph_hits_
Number of hits near the photon trajectory.
void configure(framework::config::Parameters &parameters) override
Configure the processor using the given user specified parameters.
int first_near_ph_layer_
Earliest ECal layer in which a hit is found near the projected photon trajectory.
int n_straight_tracks_
Number of "straight" tracks found in the event.
Implements an event buffer system for storing event data.
Definition Event.h:40
Class which represents the process under execution.
Definition Process.h:34
Base class for a module which produces a data product.
Producer(const std::string &name, Process &process)
Class constructor.
virtual void process(Event &event) final
Processing an event for a Producer is calling produce.
Class encapsulating parameters for configuring a processor.
Definition Parameters.h:26
Translation between real-space positions and cell IDs within the ECal.
Run-specific configuration and data stored in its own output TTree alongside the event TTree in the o...
Definition RunHeader.h:68