LDMX Software
|
User stepping action used to filter events where the primary particle falls below a threshold before reaching the CalorimeterRegion. More...
#include <PrimaryToEcalFilter.h>
Public Member Functions | |
PrimaryToEcalFilter (const std::string &name, framework::config::Parameters ¶meters) | |
Constructor. | |
~PrimaryToEcalFilter () | |
Destructor. | |
void | stepping (const G4Step *step) override |
Only process if the track is a primary (parentID == 0) and if the event is not aborted and the particle is not in the CalorimeterRegion. | |
std::vector< simcore::TYPE > | getTypes () override |
Retrieve the type of actions this class defines. | |
![]() | |
UserAction (const std::string &name, framework::config::Parameters ¶meters) | |
Constructor. | |
virtual | ~UserAction ()=default |
Destructor. | |
virtual void | BeginOfEventAction (const G4Event *) |
Method called at the beginning of every event. | |
virtual void | EndOfEventAction (const G4Event *) |
Method called at the end of every event. | |
virtual void | BeginOfRunAction (const G4Run *) |
Method called at the beginning of a run. | |
virtual void | EndOfRunAction (const G4Run *) |
Method called at the end of a run. | |
virtual void | PreUserTrackingAction (const G4Track *) |
Method called before the UserTrackingAction. | |
virtual void | PostUserTrackingAction (const G4Track *) |
Method called after the UserTrackingAction. | |
virtual G4ClassificationOfNewTrack | ClassifyNewTrack (const G4Track *, const G4ClassificationOfNewTrack &cl) |
Method called when a track is updated. | |
virtual void | NewStage () |
Method called at the beginning of a new stage. | |
virtual void | PrepareNewEvent () |
Method called at the beginning of a new event. | |
Private Attributes | |
double | threshold_ |
Energy [MeV] below which a primary should be vetoed. | |
Additional Inherited Members | |
![]() | |
using | Factory |
factory for user actions | |
![]() | |
UserEventInformation * | getEventInfo () const |
Get a handle to the event information. | |
const std::map< int, ldmx::SimParticle > & | getCurrentParticleMap () const |
Get the current particle map. | |
![]() | |
std::string | name_ {""} |
Name of the UserAction. | |
framework::config::Parameters | parameters_ |
The set of parameters used to configure this class. | |
mutable::framework::logging::logger | theLog_ |
the logging channel user actions can use ldmx_log with | |
User stepping action used to filter events where the primary particle falls below a threshold before reaching the CalorimeterRegion.
This is a simplistic filter designed similar to the TaggerVetoFilter.
Definition at line 30 of file PrimaryToEcalFilter.h.
biasing::PrimaryToEcalFilter::PrimaryToEcalFilter | ( | const std::string & | name, |
framework::config::Parameters & | parameters ) |
Constructor.
[in] | name | the name of the instance of this UserAction. |
[in] | parameters | the parameters used to configure this UserAction. |
Definition at line 20 of file PrimaryToEcalFilter.cxx.
References threshold_.
|
inline |
|
inlineoverridevirtual |
Retrieve the type of actions this class defines.
Implements simcore::UserAction.
Definition at line 58 of file PrimaryToEcalFilter.h.
|
overridevirtual |
Only process if the track is a primary (parentID == 0) and if the event is not aborted and the particle is not in the CalorimeterRegion.
If the energy of the particle is below the input threshold, then the event is aborted.
[in] | step | Geant4 step |
Reimplemented from simcore::UserAction.
Definition at line 26 of file PrimaryToEcalFilter.cxx.
References threshold_.
|
private |
Energy [MeV] below which a primary should be vetoed.
Definition at line 64 of file PrimaryToEcalFilter.h.
Referenced by PrimaryToEcalFilter(), and stepping().