|
LDMX Software
|
DQM analyzer for Geant4 electro-nuclear (EN) interactions. More...
#include <ElectroNuclearDQM.h>
Public Member Functions | |
| ElectroNuclearDQM (const std::string &name, framework::Process &process) | |
| void | configure (framework::config::Parameters ¶meters) override |
| Callback for the EventProcessor to configure itself from the given set of parameters. | |
| void | analyze (const framework::Event &event) override |
| Process the event and make histograms or summaries. | |
Public Member Functions inherited from dqm::NuclearDQM | |
| NuclearDQM (const std::string &name, framework::Process &process) | |
| void | configure (framework::config::Parameters ¶meters) override |
| Read common configuration parameters: sim_particles_coll_name, sim_particles_passname, count_light_ions. | |
Public Member Functions inherited from framework::Analyzer | |
| Analyzer (const std::string &name, Process &process) | |
| Class constructor. | |
| virtual void | process (Event &event) final |
| Processing an event for an Analyzer is calling analyze. | |
| virtual void | beforeNewRun (ldmx::RunHeader &run_header) final |
| Don't allow Analyzers to add parameters to the run header. | |
Public Member Functions inherited from framework::EventProcessor | |
| DECLARE_FACTORY (EventProcessor, EventProcessor *, const std::string &, Process &) | |
| declare that we have a factory for this class | |
| EventProcessor (const std::string &name, Process &process) | |
| Class constructor. | |
| virtual | ~EventProcessor ()=default |
| Class destructor. | |
| virtual void | onNewRun (const ldmx::RunHeader &run_header) |
| Callback for the EventProcessor to take any necessary action when the run being processed changes. | |
| virtual void | onFileOpen (EventFile &event_file) |
| Callback for the EventProcessor to take any necessary action when a new event input ROOT file is opened. | |
| virtual void | onFileClose (EventFile &event_file) |
| 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 Member Functions | |
| void | findENElectronProperties (const ldmx::SimParticle *en_electron, const std::vector< const ldmx::SimParticle * > &en_daughters) |
| Fill histograms describing the EN electron and the interaction vertex. | |
| void | findReconstructableKinematics (const std::vector< const ldmx::SimParticle * > &en_daughters) |
| Fill "reconstructable" kinematic histograms applying the semi-inclusive acceptance cuts from the analysis definition: | |
Additional Inherited Members | |
Public Types inherited from dqm::NuclearDQM | |
| enum class | EventType { nothing_hard = 0 , single_neutron = 1 , two_neutrons = 2 , three_or_more_neutrons = 3 , single_charged_pion = 4 , two_charged_pions = 5 , single_neutral_pion = 6 , single_charged_pion_and_nucleon = 7 , single_charged_pion_and_two_nucleons = 8 , two_charged_pions_and_nucleon = 9 , single_neutral_pion_and_nucleon = 10 , single_neutral_pion_and_two_nucleons = 11 , single_neutral_pion_charged_pion_and_nucleon = 12 , single_proton = 13 , two_protons = 14 , proton_neutron = 15 , klong = 16 , charged_kaon = 17 , kshort = 18 , exotics = 19 , multibody = 20 } |
| Classification of PN/EN events by the hard particles produced above a kinetic-energy threshold. More... | |
| enum class | CompactEventType { single_neutron = 0 , single_charged_kaon = 1 , single_neutral_kaon = 2 , two_neutrons = 3 , soft = 4 , other = 5 } |
| Compact classification focusing on very-high-energy single particles. More... | |
Protected Member Functions inherited from dqm::NuclearDQM | |
| std::vector< const ldmx::SimParticle * > | findDaughters (const std::map< int, ldmx::SimParticle > &particleMap, const ldmx::SimParticle *parent, int require_process_type=-1) const |
Return daughters of parent that pass PDG-based filtering: | |
| void | findParticleKinematics (const std::vector< const ldmx::SimParticle * > &daughters, const std::string &prefix) |
| Fill kinematic histograms for the nuclear interaction products. | |
| void | findExtendedKinematics (const std::vector< const ldmx::SimParticle * > &daughters, const std::string &prefix) |
| Fill extended kinematic histograms for EN interactions: hardest_pi_ke/theta (π± only), hardest_pi0_ke/theta, {prefix}_proton_mult, {prefix}_charged_pion_mult, {prefix}_neutral_pion_mult, leading_particle_type. | |
| void | findSubleadingKinematics (const ldmx::SimParticle *initiator, const std::vector< const ldmx::SimParticle * > &daughters, EventType eventType) |
| Fill subleading-kinematics histograms for 1n, 2n, charged-kaon and neutral-kaon event types. | |
| EventType | classifyEvent (const std::vector< const ldmx::SimParticle * > &daughters, double threshold) |
Classify the event by the number and type of hard daughters above threshold [MeV] of kinetic energy. | |
| CompactEventType | classifyCompactEvent (const ldmx::SimParticle *initiator, const std::vector< const ldmx::SimParticle * > &daughters, double threshold) |
Compact classification: looks for a single particle carrying >= 80% of the initiator energy, or two neutrons each above threshold [MeV]. | |
| constexpr bool | isLightIon (int pdgCode) const |
Return true if pdgCode is a light ion (Z <= 4). | |
Protected Member Functions inherited from framework::EventProcessor | |
| void | abortEvent () |
| Abort the event immediately. | |
Protected Attributes inherited from dqm::NuclearDQM | |
| std::string | sim_particles_coll_name_ |
| std::string | sim_particles_passname_ |
| bool | count_light_ions_ {true} |
Protected Attributes inherited from framework::EventProcessor | |
| HistogramPool | histograms_ |
| helper object for making and filling histograms | |
| NtupleManager & | ntuple_ {NtupleManager::getInstance()} |
| Manager for any ntuples. | |
| logging::logger | the_log_ |
| The logger for this EventProcessor. | |
DQM analyzer for Geant4 electro-nuclear (EN) interactions.
Finds the primary (recoil) electron in the SimParticle map and collects its daughters that were produced by the electronNuclear process. These products are then classified and their kinematics histogrammed using the shared machinery in NuclearDQM.
Definition at line 17 of file ElectroNuclearDQM.h.
| dqm::ElectroNuclearDQM::ElectroNuclearDQM | ( | const std::string & | name, |
| framework::Process & | process ) |
Definition at line 6 of file ElectroNuclearDQM.cxx.
|
overridevirtual |
Process the event and make histograms or summaries.
| event | The Event to analyze |
Implements framework::Analyzer.
Definition at line 153 of file ElectroNuclearDQM.cxx.
|
overridevirtual |
Callback for the EventProcessor to configure itself from the given set of parameters.
The parameters a processor has access to are the member variables of the python class in the sequence that has class_name equal to the EventProcessor class name.
For an example, look at MyProcessor.
| parameters | Parameters for configuration. |
Reimplemented from framework::EventProcessor.
Definition at line 10 of file ElectroNuclearDQM.cxx.
|
private |
Fill histograms describing the EN electron and the interaction vertex.
Uses the EN electron's initial energy and vertex position, and takes the vertex position from the first EN daughter (where the reaction occurred).
Definition at line 14 of file ElectroNuclearDQM.cxx.
References ldmx::SimParticle::getEnergy(), and ldmx::SimParticle::getVertex().
|
private |
Fill "reconstructable" kinematic histograms applying the semi-inclusive acceptance cuts from the analysis definition:
Fills recon_* and en_recon_* histograms mirroring the extended kinematics set, plus event_type_recon for the reconstructable subset classification.
Definition at line 30 of file ElectroNuclearDQM.cxx.