Mēnsūra
|
Filter to perform event selection based on basic kinematic properties of leptons. More...
#include <LeptonFilter.hpp>
Public Member Functions | |
LeptonFilter (std::string const name="LeptonFilter") noexcept | |
Creates filter plugin with the given name. | |
LeptonFilter (std::string const &name, Lepton::Flavour flavour, double minPt, double maxAbsEta, unsigned duplicates=1) noexcept | |
Creates filter plugin and adds a selection bin. More... | |
LeptonFilter (LeptonFilter const &)=default | |
LeptonFilter (LeptonFilter &&)=default | |
Default move constructor. | |
LeptonFilter & | operator= (LeptonFilter const &)=delete |
Assignment operator is disabled. | |
virtual | ~LeptonFilter () noexcept |
Trivial destructor. | |
void | AddSelectionBin (Lepton::Flavour flavour, double minPt, double maxAbsEta, unsigned duplicates=1) |
Adds a new selection bin for a lepton with the given flavour. More... | |
virtual void | BeginRun (Dataset const &) override |
Performs initialization for a new dataset. More... | |
virtual Plugin * | Clone () const override |
Creates a newly configured clone. More... | |
![]() | |
AnalysisPlugin (std::string const &name) | |
Constructor. | |
AnalysisPlugin (AnalysisPlugin const &)=default | |
Default copy constructor. | |
AnalysisPlugin (AnalysisPlugin &&)=default | |
Default move constructor. | |
AnalysisPlugin & | operator= (AnalysisPlugin const &)=default |
Default assignment operator. | |
virtual | ~AnalysisPlugin () |
Trivial destructor. | |
![]() | |
Plugin (std::string const &name) | |
Constructor. | |
Plugin (Plugin const &)=default | |
Default copy constructor. | |
Plugin (Plugin &&)=default | |
Default move constructor. | |
Plugin & | operator= (Plugin const &)=default |
Default assignment operator. | |
virtual | ~Plugin () |
Trivial destructor. | |
virtual void | EndRun () |
Performs necessary actions needed after processing of a dataset is finished. More... | |
Processor const & | GetMaster () const |
Returns a reference to the master. More... | |
std::string const & | GetName () const |
Returns name of the plugin. | |
EventOutcome | ProcessEventToOutcome () |
Processes a new event from the current dataset. More... | |
void | SetMaster (Processor const *processor) |
Provides a pointer to an instance of Processor class that owns the plugin. More... | |
Additional Inherited Members | |
![]() | |
enum | EventOutcome { EventOutcome::Ok, EventOutcome::FilterFailed, EventOutcome::NoEvents } |
Outcome of processing of an event. More... | |
![]() | |
Plugin const * | GetDependencyPlugin (std::string const &name) const |
Returns a pointer to a precedent plugin in the path with the given name. More... | |
Filter to perform event selection based on basic kinematic properties of leptons.
The user defines the selection with a set of selection bins. Each bin specifies pt and |eta| requirements for a given lepton flavour. A bin is added for every lepton whose presence is required by the event selection. An event is accepted if for every bin there is at least one compatible tight lepton, the total number of selected tight leptons equals the number of bins, and there are no additional loose leptons.
For instance, a selection asking for two muons with pt > 20 GeV/c and |eta| < 2.1, one of them having pt > 26 GeV/c, can be constructed with the following commands: AddSelectionBin(Lepton::Flavour::Muon, 20., 2.1); AddSelectionBin(Lepton::Flavour::Muon, 26., 2.1);
The |eta| cut is evaluated differently, depending on the flavour of the lepton. For electrons it always refers to the pseudorapidity of the associated ECAL supercluster. For other leptons it is the component of the reconstructed momentum.
The filter relies on the presence of a LeptonReader. The default name is "Leptons".
|
noexcept |
Creates filter plugin and adds a selection bin.
This is a shortcut that calls AddSelectionBin internally.
void LeptonFilter::AddSelectionBin | ( | Lepton::Flavour | flavour, |
double | minPt, | ||
double | maxAbsEta, | ||
unsigned | duplicates = 1 |
||
) |
Adds a new selection bin for a lepton with the given flavour.
The order in which selection bins are added does not matter. To construct several identical bins (for instance, for a dimuon selection with same kinematical requirements), optional argument 'duplicates' can be utilized.
|
overridevirtual |
|
overridevirtual |