\(e\)¶
-
class
ElectronSelector
: public xAH::Algorithm¶ This is the algorithm class that selects electrons according to user’s choice.
In a nutshell, this algorithm performs the following actions:
retrieves an
xAOD::ElectronContainer
from eitherTEvent
orTStore
iterates over the input container, and if electron passes selection, copies it in a
ConstDataVector(SG::VIEW_ELEMENTS)
container. Otherwise, the electron is skippedsaves the view container to
TStore
, from where it can be retrieved by algorithms downstream via a name lookup
Public Functions
-
ElectronSelector
()¶
-
~ElectronSelector
()¶
-
EL::StatusCode
setupJob
(EL::Job &job)¶
-
EL::StatusCode
fileExecute
()¶
-
EL::StatusCode
histInitialize
()¶
-
EL::StatusCode
changeInput
(bool firstFile)¶
-
EL::StatusCode
initialize
()¶
-
EL::StatusCode
execute
()¶
-
EL::StatusCode
postExecute
()¶
-
EL::StatusCode
finalize
()¶
-
EL::StatusCode
histFinalize
()¶
-
bool
executeSelection
(const xAOD::ElectronContainer *inElectrons, float mcEvtWeight, bool countPass, ConstDataVector<xAOD::ElectronContainer> *selectedElectrons)¶
-
int
passCuts
(const xAOD::Electron *electron, const xAOD::Vertex *primaryVertex)¶
Public Members
-
bool
m_useCutFlow
= true¶
-
std::string
m_inContainerName
= ""¶ The name of the input container for this algorithm read from
TEvent
orTStore
-
std::string
m_outContainerName
= ""¶ The name of the nominal output container written by the algorithm to
TStore
-
std::string
m_inputAlgoSystNames
= ""¶ The name of the vector containing the names of the systematically-varied containers from the upstream algorithm, which will be processed by this algorithm.
This vector is retrieved from the
TStore
. If left blank, it means there is no upstream algorithm which applies systematics. This is the case when processing straight from the originalxAOD
orDxAOD
.
-
std::string
m_outputAlgoSystNames
= "ElectronSelector_Syst"¶ The name of the vector containing the names of the systematically-varied containers created by by this algorithm.
If
m_systName
is empty, the vector will contain only an empty string. When running on systematics, this is the string a downstream algorithm needs to process electrons.
-
bool
m_decorateSelectedObjects
= true¶ Adds a
passSel
decoration for objects that pass selection.
-
bool
m_createSelectedContainer
= false¶ Fill using a read-only container (
SG::VIEW_ELEMENTS
) toTStore
-
int
m_nToProcess
= -1¶ Number of objects to process, set
n=-1
to look at all.
-
int
m_pass_min
= -1¶ Require event to have minimum number of objects passing selection.
-
int
m_pass_max
= -1¶ Require event to have maximum number of objects passing selection.
-
float
m_pT_max
= 1e8¶ [MeV] Require objects to have maximum transverse momentum threshold
-
float
m_pT_min
= 1e8¶ [MeV] Require objects to have minimum transverse momentum threshold
-
float
m_eta_max
= 1e8¶ Require objects to have maximum \(|\eta|\) value
-
bool
m_vetoCrack
= true¶ Require objects to have \(|\eta|\) outside the crack region using
caloCluster->eta()
-
float
m_d0_max
= 1e8¶ Require objects to have a maximum \(d_{0}\) [mm] (transverse impact parameter)
-
float
m_d0sig_max
= 1e8¶ Require objects to have a maximum \(d_{0}\) significance at BL
-
float
m_z0sintheta_max
= 1e8¶ Require objects to have maximum \(z_{0}\sin(\theta)\) [mm] (longitudinal impact paramter) at BL - corrected with vertex info
-
bool
m_doAuthorCut
= true¶ Perform author kinematic cut.
-
bool
m_doOQCut
= true¶ Perform object quality cut.
-
bool
m_readIDFlagsFromDerivation
= false¶ To read electron PID decision from DAOD, rather than recalculate with tool.
-
bool
m_doModifiedEleId
= false¶ To correct egamma bug, see ATLSUSYSW-445.
-
bool
m_doLHPID
= true¶ Instantiate and perform the electron Likelihood PID.
-
bool
m_doLHPIDcut
= false¶ Cut on electron Likelihood PID (recommended)
-
std::string
m_LHOperatingPoint
= "Loose"¶ Loosest Likelihood PID operating point to save.
-
bool
m_doCutBasedPID
= false¶ Instantiate and perform the electron cut-based PID.
-
bool
m_doCutBasedPIDcut
= false¶ Cut on electron cut-based PID.
-
std::string
m_CutBasedOperatingPoint
= "Loose"¶ Loosest cut-based PID operating point to save.
-
std::string
m_MinIsoWPCut
= ""¶ reject objects which do not pass this isolation cut - default = “” (no cut)
-
std::string
m_IsoWPList
= "FCLoose,FCTight,Gradient,FCHighPtCaloOnly"¶ decorate objects with
isIsolated_*
flag for each WP in this input list - default = all current ASG WPs
-
std::string
m_CaloIsoEff
= "0.1*x+90"¶ to define a custom WP - make sure
"UserDefined"
is added inm_IsoWPList
-
std::string
m_TrackIsoEff
= "98"¶ to define a custom WP - make sure
"UserDefined"
is added inm_IsoWPList
-
std::string
m_CaloBasedIsoType
= "topoetcone20"¶ to define a custom WP - make sure
"UserDefined"
is added inm_IsoWPList
-
std::string
m_TrackBasedIsoType
= "ptvarcone20"¶ to define a custom WP - make sure
"UserDefined"
is added inm_IsoWPList
-
std::string
m_singleElTrigChains
= ""¶ A comma-separated string w/ alll the HLT single electron trigger chains for which you want to perform the matching. This is passed by the user as input in configuration If left empty (as it is by default), no trigger matching will be attempted at all.
-
std::string
m_diElTrigChains
= ""¶ A comma-separated string w/ alll the HLT di-electron trigger chains for which you want to perform the matching. This is passed by the user as input in configuration If left empty (as it is by default), no trigger matching will be attempted at all.
-
double
m_minDeltaR
= 0.07¶ Recommended threshold for egamma triggers: see https://svnweb.cern.ch/trac/atlasoff/browser/Trigger/TrigAnalysis/TriggerMatchingTool/trunk/src/TestMatchingToolAlg.cxx.
-
bool
m_applyCrackVetoCleaning
= false¶ Apply fix to EGamma Crack-Electron topocluster association bug for MET (PFlow) / false by default.
Private Members
-
bool
m_doBLTrackQualityCut
¶ Performs the Likelihood PID B-Layer cut locally.
Note
Occurs automatically only if
m_LHOperatingPoint
isLooseBL
andm_readIDFlagsFromDerivation
istrue
-
std::string
m_outAuxContainerName
¶ the name of the auxiliary store for the output container
-
int
m_numEvent
¶ keep track of the total number of events processed
-
int
m_numObject
¶ keep track of the total number of objects processed
-
int
m_numEventPass
¶ keep track of the number of passed events, and fill the cutflow (relevant only if using the algo to skim events: see
m_pass_max
andm_pass_min
above)
-
int
m_weightNumEventPass
¶ keep track of the number of weighted passed events, and fill the cutflow (relevant only if using the algo to skim events: see
m_pass_max
andm_pass_min
above)
-
int
m_numObjectPass
¶ keep track of the number of selected objects
-
TH1D *
m_cutflowHist
= nullptr¶ histogram for event cutflow
-
TH1D *
m_cutflowHistW
= nullptr¶ histgram for weighted event cutflow
-
int
m_cutflow_bin
¶ index of bin corresponding to this step of the full cutflow
-
bool
m_isUsedBefore
= false¶ checks if the algorithm has been used already
-
TH1D *
m_el_cutflowHist_1
= nullptr¶
-
TH1D *
m_el_cutflowHist_2
= nullptr¶
-
int
m_el_cutflow_all
¶
-
int
m_el_cutflow_OQ_cut
¶
-
int
m_el_cutflow_ptmax_cut
¶
-
int
m_el_cutflow_ptmin_cut
¶
-
int
m_el_cutflow_eta_cut
¶
-
int
m_el_cutflow_z0sintheta_cut
¶
-
int
m_el_cutflow_d0_cut
¶
-
int
m_el_cutflow_d0sig_cut
¶
-
int
m_el_cutflow_BL_cut
¶
-
int
m_el_cutflow_PID_cut
¶
-
int
m_el_cutflow_iso_cut
¶
-
std::vector<std::string>
m_IsoKeys
¶
-
asg::AnaToolHandle<CP::IIsolationSelectionTool>
m_isolationSelectionTool_handle
= {"CP::IsolationSelectionTool/IsolationSelectionTool", }¶ MC15 ASG tool for isolation.
-
CP::IsolationSelectionTool *
m_isolationSelectionTool
= {nullptr}¶
-
asg::AnaToolHandle<Trig::TrigDecisionTool>
m_trigDecTool_handle
= {"Trig::TrigDecisionTool/TrigDecisionTool"}¶
-
asg::AnaToolHandle<Trig::IMatchingTool>
m_trigElectronMatchTool_handle
¶
-
bool
m_doTrigMatch
= true¶ This internal variable gets set to false if no triggers are defined or if TrigDecisionTool is missing.
-
ElectronLHPIDManager *
m_el_LH_PIDManager
= nullptr¶ class to manage LH PID selection/decorations - see ISSUE for explaination
-
ElectronCutBasedPIDManager *
m_el_CutBased_PIDManager
= nullptr¶ class to manage cut-based PID selection/decorations - see ISSUE for explaination
-
std::vector<std::string>
m_singleElTrigChainsList
¶ contains all the HLT trigger chains tokens extracted from
m_singleElTrigChains
-
std::vector<std::string>
m_diElTrigChainsList
¶ contains all the HLT trigger chains tokens extracted from
m_diElTrigChains