LDMX Software
|
Performs basic ECal reconstruction. More...
#include <EcalRecProducer.h>
Public Member Functions | |
EcalRecProducer (const std::string &name, framework::Process &process) | |
Constructor. | |
virtual | ~EcalRecProducer () |
Destructor. | |
virtual void | configure (framework::config::Parameters &) |
Grabs configure parameters from the python config file. | |
virtual void | produce (framework::Event &event) |
Produce EcalHits and put them into the event bus using the EcalDigis as input. | |
Public Member Functions inherited from framework::Producer | |
Producer (const std::string &name, Process &process) | |
Class constructor. | |
virtual void | beforeNewRun (ldmx::RunHeader &header) |
Handle allowing producers to modify run headers before the run begins. | |
Public Member Functions inherited from framework::EventProcessor | |
EventProcessor (const std::string &name, Process &process) | |
Class constructor. | |
virtual | ~EventProcessor () |
Class destructor. | |
virtual void | onNewRun (const ldmx::RunHeader &runHeader) |
Callback for the EventProcessor to take any necessary action when the run being processed changes. | |
virtual void | onFileOpen (EventFile &eventFile) |
Callback for the EventProcessor to take any necessary action when a new event input ROOT file is opened. | |
virtual void | onFileClose (EventFile &eventFile) |
Callback for the EventProcessor to take any necessary action when a event input ROOT file is closed. | |
virtual void | onProcessStart () |
Callback for the EventProcessor to take any necessary action when the processing of events starts, such as creating histograms. | |
virtual void | onProcessEnd () |
Callback for the EventProcessor to take any necessary action when the processing of events finishes, such as calculating job-summary quantities. | |
template<class T > | |
const T & | getCondition (const std::string &condition_name) |
Access a conditions object for the current event. | |
TDirectory * | getHistoDirectory () |
Access/create a directory in the histogram file for this event processor to create histograms and analysis tuples. | |
void | setStorageHint (framework::StorageControl::Hint hint) |
Mark the current event as having the given storage control hint from this module. | |
void | setStorageHint (framework::StorageControl::Hint hint, const std::string &purposeString) |
Mark the current event as having the given storage control hint from this module and the given purpose string. | |
int | getLogFrequency () const |
Get the current logging frequency from the process. | |
int | getRunNumber () const |
Get the run number from the process. | |
std::string | getName () const |
Get the processor name. | |
void | createHistograms (const std::vector< framework::config::Parameters > &histos) |
Internal function which is used to create histograms passed from the python configuration @parma histos vector of Parameters that configure histograms to create. | |
Private Attributes | |
std::string | digiCollName_ |
Digi Collection Name to use as input. | |
std::string | digiPassName_ |
Digi Pass Name to use as input. | |
std::string | simHitCollName_ |
simhit collection name | |
std::string | simHitPassName_ |
simhit pass name | |
std::string | recHitCollName_ |
output hit collection name | |
double | mip_si_energy_ |
Energy [MeV] deposited by a MIP in Si 0.5mm thick. | |
double | clock_cycle_ |
Length of clock cycle [ns]. | |
double | charge_per_mip_ |
Number of electrons generated by average MIP in Si 0.5mm thick. | |
std::vector< double > | layerWeights_ |
Layer Weights to use for this reconstruction. | |
double | secondOrderEnergyCorrection_ |
Second Order Energy Correction to use for this reconstruction. | |
Additional Inherited Members | |
Static Public Member Functions inherited from framework::EventProcessor | |
static void | declare (const std::string &classname, int classtype, EventProcessorMaker *) |
Internal function which is part of the PluginFactory machinery. | |
Static Public Attributes inherited from framework::Producer | |
static const int | CLASSTYPE {1} |
Constant used to track EventProcessor types by the PluginFactory. | |
Protected Member Functions inherited from framework::EventProcessor | |
void | abortEvent () |
Abort the event immediately. | |
Protected Attributes inherited from framework::EventProcessor | |
HistogramHelper | histograms_ |
Interface class for making and filling histograms. | |
NtupleManager & | ntuple_ {NtupleManager::getInstance()} |
Manager for any ntuples. | |
logging::logger | theLog_ |
The logger for this EventProcessor. | |
Performs basic ECal reconstruction.
Reconstruction is done from the EcalDigi samples. Some hard-coded parameters are used for position and energy calculation.
Definition at line 33 of file EcalRecProducer.h.
ecal::EcalRecProducer::EcalRecProducer | ( | const std::string & | name, |
framework::Process & | process | ||
) |
Constructor.
Definition at line 17 of file EcalRecProducer.cxx.
|
virtual |
|
virtual |
Grabs configure parameters from the python config file.
Reimplemented from framework::EventProcessor.
Definition at line 23 of file EcalRecProducer.cxx.
References charge_per_mip_, clock_cycle_, digiCollName_, digiPassName_, framework::config::Parameters::getParameter(), layerWeights_, mip_si_energy_, recHitCollName_, secondOrderEnergyCorrection_, simHitCollName_, and simHitPassName_.
|
virtual |
Produce EcalHits and put them into the event bus using the EcalDigis as input.
This function unfolds the digi samples taken by the HGC ROC and reconstructs their energy using knowledge of how the chip operates and the position using EcalGeometry.
Negative Electron (charge) count This reconstruction error occurs when the ADC value is below the ADC pedestal for that channel. In the normal running mode, this will never happen because our front-end (the digi emulator or the digitizer itself) will suppress any signals that are below the readout threshold. Nevertheless, in some running modes, we don't have this zero suppression, so we need to check that the reconstruction charge (count of electrons) is non-negative.
Implements framework::Producer.
Definition at line 40 of file EcalRecProducer.cxx.
References ecal::EcalReconConditions::adcGain(), ecal::EcalReconConditions::adcPedestal(), charge_per_mip_, clock_cycle_, ecal::EcalReconConditions::CONDITIONS_NAME, digiCollName_, digiPassName_, framework::Event::exists(), layerWeights_, mip_si_energy_, recHitCollName_, secondOrderEnergyCorrection_, ldmx::CalorimeterHit::setAmplitude(), ldmx::CalorimeterHit::setEnergy(), ldmx::CalorimeterHit::setID(), ldmx::CalorimeterHit::setTime(), ldmx::CalorimeterHit::setXPos(), ldmx::CalorimeterHit::setYPos(), ldmx::CalorimeterHit::setZPos(), simHitCollName_, simHitPassName_, ecal::EcalReconConditions::totGain(), and ecal::EcalReconConditions::totPedestal().
|
private |
Number of electrons generated by average MIP in Si 0.5mm thick.
Definition at line 83 of file EcalRecProducer.h.
Referenced by configure(), and produce().
|
private |
Length of clock cycle [ns].
Definition at line 80 of file EcalRecProducer.h.
Referenced by configure(), and produce().
|
private |
Digi Collection Name to use as input.
Definition at line 62 of file EcalRecProducer.h.
Referenced by configure(), and produce().
|
private |
Digi Pass Name to use as input.
Definition at line 65 of file EcalRecProducer.h.
Referenced by configure(), and produce().
|
private |
Layer Weights to use for this reconstruction.
Layer weights account for the energy lost in the absorber directly in front of the Silicon layer where the measured energy was deposited. These are determined by calculating the average amount of energy lost by a MIP passing through the extra material between sensitive layers.
Definition at line 93 of file EcalRecProducer.h.
Referenced by configure(), and produce().
|
private |
Energy [MeV] deposited by a MIP in Si 0.5mm thick.
Definition at line 77 of file EcalRecProducer.h.
Referenced by configure(), and produce().
|
private |
output hit collection name
Definition at line 74 of file EcalRecProducer.h.
Referenced by configure(), and produce().
|
private |
Second Order Energy Correction to use for this reconstruction.
This is a shift applied to all of the energies in order to have the mean of the total energy deposited in the ECal be accurate. This is less physically motivated than the layer weights and is more of a calibration number.
Definition at line 103 of file EcalRecProducer.h.
Referenced by configure(), and produce().
|
private |
simhit collection name
Definition at line 68 of file EcalRecProducer.h.
Referenced by configure(), and produce().
|
private |
simhit pass name
Definition at line 71 of file EcalRecProducer.h.
Referenced by configure(), and produce().