ATLAS Offline Software
Loading...
Searching...
No Matches
ST::SUSYObjDef_xAOD Class Reference

#include <SUSYObjDef_xAOD.h>

Inheritance diagram for ST::SUSYObjDef_xAOD:

Public Types

enum  DataSource { Undefined = -1 , Data , FullSim , AtlfastII }
Definition of the StoreGate-like object's definition
typedef ServiceHandle< StoreGateSvcMetaStore_t
 Type of the metadata store object in Athena.
typedef const ServiceHandle< StoreGateSvc > & MetaStorePtr_t
 Type of the metadata store pointer in standalone mode.

Public Member Functions

 SUSYObjDef_xAOD (const std::string &name)
 ~SUSYObjDef_xAOD ()
StatusCode initialize () override final
 Dummy implementation of the initialisation function.
bool isData () const override final
bool isAtlfast () const override final
StatusCode setBoolProperty (const std::string &name, const bool &property) override final
void setDataSource (int source)
StatusCode FillJet (xAOD::Jet &input, const bool doCalib=true, bool isFat=false, bool doLargeRdecorations=false) override final
StatusCode FillTrackJet (xAOD::Jet &input) override final
StatusCode FillTau (xAOD::TauJet &input) override final
StatusCode FillMuon (xAOD::Muon &input, const float ptcut, const float etacut) override final
StatusCode FillElectron (xAOD::Electron &input, const float etcut, const float etacut) override final
StatusCode FillPhoton (xAOD::Photon &input, const float ptcut, const float etacut) override final
const xAOD::VertexGetPrimVtx () const override final
StatusCode GetJets (xAOD::JetContainer *&copy, xAOD::ShallowAuxContainer *&copyaux, const bool recordSG=true, const std::string &jetkey="", const xAOD::JetContainer *containerToBeCopied=nullptr) override final
StatusCode GetTrackJets (xAOD::JetContainer *&copy, xAOD::ShallowAuxContainer *&copyaux, const bool recordSG=true, const std::string &jetkey="", const xAOD::JetContainer *containerToBeCopied=nullptr) override final
StatusCode GetJetsSyst (const xAOD::JetContainer &calibjets, xAOD::JetContainer *&copy, xAOD::ShallowAuxContainer *&copyaux, const bool recordSG=true, const std::string &jetkey="") override final
StatusCode GetFatJets (xAOD::JetContainer *&copy, xAOD::ShallowAuxContainer *&copyaux, const bool recordSG=false, const std::string &jetkey="", const bool doLargeRdecorations=false, const xAOD::JetContainer *containerToBeCopied=nullptr) override final
StatusCode GetTaus (xAOD::TauJetContainer *&copy, xAOD::ShallowAuxContainer *&copyaux, const bool recordSG=true, const std::string &taukey="TauJets", const xAOD::TauJetContainer *containerToBeCopied=nullptr) override final
StatusCode GetMuons (xAOD::MuonContainer *&copy, xAOD::ShallowAuxContainer *&copyaux, const bool recordSG=true, const std::string &muonkey="Muons", const std::string &lrtmuonkey="MuonsLRT", const xAOD::MuonContainer *containerToBeCopied=nullptr) override final
StatusCode GetElectrons (xAOD::ElectronContainer *&copy, xAOD::ShallowAuxContainer *&copyaux, const bool recordSG=true, const std::string &elekey="Electrons", const std::string &lrtelekey="LRTElectrons", const xAOD::ElectronContainer *containerToBeCopied=nullptr) override final
StatusCode GetPhotons (xAOD::PhotonContainer *&copy, xAOD::ShallowAuxContainer *&copyaux, const bool recordSG=true, const std::string &photonkey="Photons", const xAOD::PhotonContainer *containerToBeCopied=nullptr) override final
StatusCode GetMET (xAOD::MissingETContainer &met, const xAOD::JetContainer *jet, const xAOD::ElectronContainer *elec=nullptr, const xAOD::MuonContainer *muon=nullptr, const xAOD::PhotonContainer *gamma=nullptr, const xAOD::TauJetContainer *taujet=nullptr, bool doTST=true, bool doJVTCut=true, const xAOD::IParticleContainer *invis=nullptr) override final
StatusCode GetTrackMET (xAOD::MissingETContainer &met, const xAOD::JetContainer *jet, const xAOD::ElectronContainer *elec=nullptr, const xAOD::MuonContainer *muon=nullptr) override final
StatusCode GetMETSig (xAOD::MissingETContainer &met, double &metSignificance, bool doTST=true, bool doJVTCut=true) override final
StatusCode MergeMuons (const xAOD::MuonContainer &muons, const std::vector< bool > &writeMuon, xAOD::MuonContainer *outputCol) const override final
StatusCode prepareLRTMuons (const xAOD::MuonContainer *inMuons, xAOD::MuonContainer *copy) const override final
StatusCode MergeElectrons (const xAOD::ElectronContainer &electrons, xAOD::ElectronContainer *outputCol, const std::set< const xAOD::Electron * > &ElectronsToRemove) const override final
StatusCode prepareLRTElectrons (const xAOD::ElectronContainer *inMuons, xAOD::ElectronContainer *copy) const override final
StatusCode SetBtagWeightDecorations (const xAOD::Jet &input, const asg::AnaToolHandle< IBTaggingSelectionTool > &btagSelTool, const std::string &btagTagger) const override final
bool IsSignalJet (const xAOD::Jet &input, const float ptcut, const float etacut) const override final
bool IsBadJet (const xAOD::Jet &input) const override final
bool IsBJetLoose (const xAOD::Jet &input) const override final
bool JetPassJVT (xAOD::Jet &input) override final
bool IsSignalMuon (const xAOD::Muon &input, const float ptcut, const float d0sigcut, const float z0cut, const float etacut=DUMMYDEF) const override final
bool IsSignalElectron (const xAOD::Electron &input, const float etcut, const float d0sigcut, const float z0cut, const float etacut=DUMMYDEF) const override final
bool IsCosmicMuon (const xAOD::Muon &input, const float z0cut, const float d0cut) const override final
bool IsHighPtMuon (const xAOD::Muon &input) const override final
bool IsSignalTau (const xAOD::TauJet &input, const float ptcut, const float etacut) const override final
bool IsBadMuon (const xAOD::Muon &input, const float qopcut) const override final
bool IsSignalPhoton (const xAOD::Photon &input, const float ptcut, const float etacut=DUMMYDEF) const override final
bool IsBJet (const xAOD::Jet &input) const override final
bool IsTrackBJet (const xAOD::Jet &input) const override final
bool IsTruthBJet (const xAOD::Jet &input) const override final
int IsBJetContinuous (const xAOD::Jet &input) const override final
int IsTrackBJetContinuous (const xAOD::Jet &input) const override final
float BtagSF (const xAOD::JetContainer *jets) override final
float BtagSFsys (const xAOD::JetContainer *jets, const CP::SystematicSet &systConfig) override final
float BtagSF_trkJet (const xAOD::JetContainer *trkjets) override final
float BtagSFsys_trkJet (const xAOD::JetContainer *trkjets, const CP::SystematicSet &systConfig) override final
double JVT_SF (const xAOD::JetContainer *jets) override final
double JVT_SFsys (const xAOD::JetContainer *jets, const CP::SystematicSet &systConfig) override final
double FJVT_SF (const xAOD::JetContainer *jets) override final
double FJVT_SFsys (const xAOD::JetContainer *jets, const CP::SystematicSet &systConfig) override final
float GetSignalMuonSF (const xAOD::Muon &mu, const bool recoSF=true, const bool isoSF=true, const bool doBadMuonHP=true, const bool warnOVR=true) override final
double GetMuonTriggerEfficiency (const xAOD::Muon &mu, const std::string &trigExpr, const bool isdata=false) override final
double GetTotalMuonTriggerSF (const xAOD::MuonContainer &sfmuons, const std::string &trigExpr) override final
double GetTotalMuonSF (const xAOD::MuonContainer &muons, const bool recoSF=true, const bool isoSF=true, const std::string &trigExpr="HLT_mu20_iloose_L1MU15_OR_HLT_mu50", const bool bmhptSF=true) override final
double GetTotalMuonSFsys (const xAOD::MuonContainer &muons, const CP::SystematicSet &systConfig, const bool recoSF=true, const bool isoSF=true, const std::string &trigExpr="HLT_mu20_iloose_L1MU15_OR_HLT_mu50", const bool bmhptSF=true) override final
float GetSignalElecSF (const xAOD::Electron &el, const bool recoSF=true, const bool idSF=true, const bool triggerSF=true, const bool isoSF=true, const std::string &trigExpr="singleLepton", const bool ecidsSF=false, const bool cidSF=false) override final
double GetEleTriggerEfficiency (const xAOD::Electron &el, const std::string &trigExpr="SINGLE_E_2015_e24_lhmedium_L1EM20VH_OR_e60_lhmedium_OR_e120_lhloose_2016_2018_e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0") const override final
double GetTriggerGlobalEfficiency (const xAOD::ElectronContainer &electrons, const xAOD::MuonContainer &muons, const std::string &trigExpr="diLepton") override final
double GetTriggerGlobalEfficiency (const xAOD::PhotonContainer &photons, const std::string &trigExpr="diPhoton") override final
double GetEleTriggerEfficiencySF (const xAOD::Electron &el, const std::string &trigExpr="SINGLE_E_2015_e24_lhmedium_L1EM20VH_OR_e60_lhmedium_OR_e120_lhloose_2016_2018_e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0") const override final
double GetTriggerGlobalEfficiencySF (const xAOD::ElectronContainer &electrons, const xAOD::MuonContainer &muons, const std::string &trigExpr="diLepton") override final
double GetTriggerGlobalEfficiencySF (const xAOD::PhotonContainer &photons, const std::string &trigExpr="diPhoton") override final
double GetTriggerGlobalEfficiencySFsys (const xAOD::ElectronContainer &electrons, const xAOD::MuonContainer &muons, const CP::SystematicSet &systConfig, const std::string &trigExpr="diLepton") override final
double GetTriggerGlobalEfficiencySFsys (const xAOD::PhotonContainer &photons, const CP::SystematicSet &systConfig, const std::string &trigExpr="diPhoton") override final
float GetTotalElectronSF (const xAOD::ElectronContainer &electrons, const bool recoSF=true, const bool idSF=true, const bool triggerSF=true, const bool isoSF=true, const std::string &trigExpr="singleLepton", const bool ecidsSF=false, const bool cidSF=false) override final
float GetTotalElectronSFsys (const xAOD::ElectronContainer &electrons, const CP::SystematicSet &systConfig, const bool recoSF=true, const bool idSF=true, const bool triggerSF=true, const bool isoSF=true, const std::string &trigExpr="singleLepton", const bool ecidsSF=false, const bool cidSF=false) override final
double GetSignalTauSF (const xAOD::TauJet &tau, const bool idSF=true, const bool triggerSF=true, const std::string &trigExpr="tau25_medium1_tracktwo") override final
double GetSignalTauSFsys (const xAOD::TauJet &tau, const CP::SystematicSet &systConfig, const bool idSF=true, const bool triggerSF=true, const std::string &trigExpr="tau25_medium1_tracktwo") override final
double GetTauTriggerEfficiencySF (const xAOD::TauJet &tau, const std::string &trigExpr="tau25_medium1_tracktwo") override final
double GetTotalTauSF (const xAOD::TauJetContainer &taus, const bool idSF=true, const bool triggerSF=true, const std::string &trigExpr="tau25_medium1_tracktwo") override final
double GetTotalTauSFsys (const xAOD::TauJetContainer &taus, const CP::SystematicSet &systConfig, const bool idSF=true, const bool triggerSF=true, const std::string &trigExpr="tau25_medium1_tracktwo") override final
double GetSignalPhotonSF (const xAOD::Photon &ph, const bool effSF=true, const bool isoSF=true, const bool triggerSF=false) const override final
double GetSignalPhotonSFsys (const xAOD::Photon &ph, const CP::SystematicSet &systConfig, const bool effSF=true, const bool isoSF=true, const bool triggerSF=false) override final
double GetTotalPhotonSF (const xAOD::PhotonContainer &photons, const bool effSF=true, const bool isoSF=true, const bool triggerSF=false) const override final
double GetTotalPhotonSFsys (const xAOD::PhotonContainer &photons, const CP::SystematicSet &systConfig, const bool effSF=true, const bool isoSF=true, const bool triggerSF=false) override final
double GetTotalJetSF (const xAOD::JetContainer *jets, const bool btagSF=true, const bool jvtSF=true, const bool fjvtSF=false) override final
double GetTotalJetSFsys (const xAOD::JetContainer *jets, const CP::SystematicSet &systConfig, const bool btagSF=true, const bool jvtSF=true, const bool fjvtSF=false) override final
bool IsMETTrigPassed (unsigned int runnumber=0, bool j400_OR=false) const override final
bool IsMETTrigPassed (const std::string &triggerName, bool j400_OR=false, const std::string &L1_name="L1_XE50") const override final
bool IsTrigPassed (const std::string &, unsigned int condition=TrigDefs::Physics) const override final
bool IsTrigMatched (const xAOD::IParticle *part, const std::string &tr_item) override final
bool IsTrigMatched (const xAOD::IParticle *part1, const xAOD::IParticle *part2, const std::string &tr_item) override final
bool IsTrigMatched (const std::vector< const xAOD::IParticle * > &v, const std::string &tr_item) override final
bool IsTrigMatched (const std::initializer_list< const xAOD::IParticle * > &v, const std::string &tr_item) override final
void TrigMatch (const xAOD::IParticle *p, std::initializer_list< std::string >::iterator, std::initializer_list< std::string >::iterator) override final
void TrigMatch (const xAOD::IParticle *p, const std::vector< std::string > &items) override final
void TrigMatch (const xAOD::IParticle *p, const std::initializer_list< std::string > &items) override final
void TrigMatch (const xAOD::IParticleContainer *v, const std::vector< std::string > &items) override final
void TrigMatch (const xAOD::IParticleContainer *v, const std::initializer_list< std::string > &items) override final
void TrigMatch (const std::initializer_list< const xAOD::IParticle * > &v, const std::vector< std::string > &items) override final
void TrigMatch (const std::initializer_list< const xAOD::IParticle * > &v, const std::initializer_list< std::string > &items) override final
void TrigMatch (const xAOD::IParticle *p, const std::string &item) override final
void TrigMatch (const xAOD::IParticleContainer *v, const std::string &item) override final
void TrigMatch (const std::initializer_list< const xAOD::IParticle * > &v, const std::string &item) override final
float GetTrigPrescale (const std::string &) const override final
const Trig::ChainGroupGetTrigChainGroup (const std::string &) const override final
std::vector< std::string > GetTriggerOR (const std::string &trigExpr) const
void GetTriggerTokens (std::string, std::vector< std::string > &, std::vector< std::string > &, std::vector< std::string > &, std::vector< std::string > &, std::vector< std::string > &, std::vector< std::string > &, std::vector< std::string > &) const
Trig::FeatureContainer GetTriggerFeatures (const std::string &chainName="EF_.*", unsigned int condition=TrigDefs::Physics) const
const xAOD::EventInfoGetEventInfo () const override final
float GetPileupWeight () override final
float GetPileupWeightPrescaledTrigger (const std::string &trigger_expr) override final
ULong64_t GetPileupWeightHash () override final
float GetDataWeight (const std::string &) override final
float GetCorrectedAverageInteractionsPerCrossing (bool includeDataSF=false) override final
float GetCorrectedActualInteractionsPerCrossing (bool includeDataSF=false) override final
double GetSumOfWeights (int channel) override final
unsigned int GetRandomRunNumber (bool muDependentRRN=true) override final
StatusCode ApplyPRWTool (bool muDependentRRN=true) override final
unsigned int GetRunNumber () const override final
const xAOD::TrackParticleContainerGetInDetLargeD0Tracks (const EventContext &ctx) const override final
const xAOD::TrackParticleContainerGetInDetLargeD0GSFTracks (const EventContext &ctx) const override final
StatusCode ApplyLRTUncertainty () override final
int treatAsYear (const int runNumber=-1) const override final
StatusCode OverlapRemoval (const xAOD::ElectronContainer *electrons, const xAOD::MuonContainer *muons, const xAOD::JetContainer *jets, const xAOD::PhotonContainer *gamma=nullptr, const xAOD::TauJetContainer *taujet=nullptr, const xAOD::JetContainer *fatjets=nullptr) override final
StatusCode NearbyLeptonCorrections (xAOD::ElectronContainer *electrons=nullptr, xAOD::MuonContainer *muons=nullptr) const override final
StatusCode resetSystematics () override final
const CP::SystematicSetcurrentSystematic () const
StatusCode applySystematicVariation (const CP::SystematicSet &systConfig) override final
bool isPrompt (const xAOD::IParticle *part) const override final
StatusCode FindSusyHP (int &pdgid1, int &pdgid2) const
StatusCode FindSusyHP (const xAOD::TruthParticleContainer *truthP, int &pdgid1, int &pdgid2, bool isTruth3=false) const override final
StatusCode FindSusyHP (const xAOD::TruthEvent *truthE, int &pdgid1, int &pdgid2) const override final
std::string TrigSingleLep () const override final
bool isNominal (const CP::SystematicSet &syst) const
bool isWeight (const CP::SystematicSet &systSet) const
bool isVariation (const CP::SystematicSet &syst) const
bool currentSystematicIsNominal () const
bool currentSystematicIsVariation () const
bool currentSystematicIsWeight () const
ST::SystInfo getSystInfo (const CP::SystematicVariation &sys) const override final
std::vector< ST::SystInfogetSystInfoList () const override final
float getSherpaVjetsNjetsWeight () const override final
float getSherpaVjetsNjetsWeight (const std::string &jetContainer) const override final
int getMCShowerType (const std::string &sample_name="", const std::string &tagger="") const override final
template<typename T>
const T * getProperty (const std::string &name)
virtual StatusCode sysInitialize ()
 Function initialising the tool in the correct way in Athena.
virtual void print () const
 Print the state of the tool.
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
virtual StatusCode sysStart () override
 Handle START transition.
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles.
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles.
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T, V, H > &t)
void updateVHKA (Gaudi::Details::PropertyBase &)
MsgStream & msg () const
bool msgLvl (const MSG::Level lvl) const
Functions providing access to the input/output metadata
MetaStorePtr_t inputMetaStore () const
 Accessor for the input metadata store.
MetaStorePtr_t outputMetaStore () const
 Accessor for the output metadata store.
Additional helper functions, not directly mimicking Athena
template<class T>
const T * getProperty (const std::string &name) const
 Get one of the tool's properties.
const std::string & msg_level_name () const __attribute__((deprecated))
 A deprecated function for getting the message level's name.
const std::string & getName (const void *ptr) const
 Get the name of an object that is / should be in the event store.
SG::sgkey_t getKey (const void *ptr) const
 Get the (hashed) key of an object that is in the event store.

Static Public Member Functions

static bool FindSusyHardProc (const xAOD::TruthParticleContainer *truthP, int &pdgid1, int &pdgid2, bool isTruth3=false)
static bool FindSusyHardProc (const xAOD::TruthEvent *truthE, int &pdgid1, int &pdgid2)

Public Attributes

const xAOD::MuonContainerprompt_muons = nullptr
const xAOD::MuonContainerlrt_muons = nullptr
const xAOD::ElectronContainerprompt_electrons = nullptr
const xAOD::ElectronContainerlrt_electrons = nullptr

Protected Member Functions

StatusCode autoconfigurePileupRWTool (const std::string &PRWfilesDir="dev/PileupReweighting/share/", const std::string &PRWfileName="", bool usePathResolver=true, bool RPVLLmode=false, bool Combinedmode=false, const std::string &HFFilter="")
StatusCode readConfig () override final
StatusCode validConfig (bool strict=false) const
const std::vector< std::string > split (const std::string &s, const std::string &delim) const
std::string getDefaultJetUncConfig ()
StatusCode getTauConfig (const std::string &tauConfigPath, std::vector< float > &pT_window, std::vector< float > &eta_window, bool &eleOLR, bool &muVeto, bool &muOLR) const
void configFromFile (bool &property, const std::string &propname, TEnv &rEnv, bool defaultValue)
void configFromFile (double &property, const std::string &propname, TEnv &rEnv, double defaultValue)
void configFromFile (int &property, const std::string &propname, TEnv &rEnv, int defaultValue)
void configFromFile (std::string &property, const std::string &propname, TEnv &rEnv, const std::string &defaultValue, bool allowEmpty=false)
bool check_isOption (const std::string &wp, const std::vector< std::string > &list) const
bool check_isTighter (const std::string &wp1, const std::string &wp, const std::vector< std::string > &list) const
std::string EG_WP (const std::string &wp) const
std::vector< std::string > getElSFkeys (const std::string &mapFile) const
void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed.
Callback functions helping in metadata reading/writing
void setUseIncidents (const bool flag)
virtual void handle (const Incident &inc)
 Function receiving incidents from IncidentSvc/Event.
virtual StatusCode beginInputFile ()
 Function called when a new input file is opened.
virtual StatusCode endInputFile ()
 Function called when the currently open input file got completely processed.
virtual StatusCode beginEvent ()
 Function called when a new events is loaded.
virtual StatusCode metaDataStop ()
 Function called when the tool should write out its metadata.

Protected Attributes

int m_dataSource
int m_jetInputType
std::string m_configFile
bool m_force_noElId
bool m_force_noMuId
bool m_doTTVAsf
bool m_doModifiedEleId
bool m_upstreamTriggerMatching
std::string m_trigMatchingPrefix
 Use composite trigger matching tool if matching was done upstream.
std::string m_jetUncertaintiesConfig
 Prefix for trigger matchiing container name.
std::string m_jetUncertaintiesAnalysisFile
std::string m_jetUncertaintiesCalibArea
std::string m_jetUncertaintiesMCType
std::string m_fatJetUncertaintiesMCType
bool m_jetUncertaintiesPDsmearing
bool m_useBtagging
bool m_useBtagging_trkJet
bool m_debug
bool m_strictConfigCheck
std::string m_badJetCut
std::string m_fatJetUncConfig
bool m_fatJetUncertaintiesPDsmearing
std::string m_fatJetUncVars
TEnv m_WconfigReader
TEnv m_ZconfigReader
TEnv m_TopconfigReader
std::string m_WDecorName
std::string m_ZDecorName
std::string m_TopDecorName
std::string m_WtagConfig
std::string m_ZtagConfig
std::string m_ToptagConfig
std::string m_WZTaggerCalibArea
std::string m_TopTaggerCalibArea
std::string m_WTagUncConfig
std::string m_ZTagUncConfig
std::string m_TopTagUncConfig
std::string m_JetTruthLabelName
bool m_tool_init
bool m_subtool_init
std::string m_eleTerm
std::string m_gammaTerm
std::string m_tauTerm
std::string m_jetTerm
std::string m_muonTerm
std::string m_inputMETSuffix
std::string m_inputMETMap
std::string m_inputMETCore
std::string m_inputMETRef
std::string m_outMETTerm
bool m_metRemoveOverlappingCaloTaggedMuons
bool m_metDoSetMuonJetEMScale
bool m_metDoRemoveMuonJets
bool m_metUseGhostMuons
bool m_metDoMuonEloss
bool m_metGreedyPhotons
bool m_metVeryGreedyPhotons
std::string m_metsysConfigPrefix
bool m_trkMETsyst
bool m_caloMETsyst
bool m_trkJetsyst
int m_softTermParam
bool m_treatPUJets
bool m_doPhiReso
bool m_autoconfigPRW
std::string m_autoconfigPRWPath
std::string m_autoconfigPRWFile
bool m_autoconfigPRWCombinedmode
bool m_autoconfigPRWRPVmode
std::string m_autoconfigPRWRtags
std::string m_mcCampaign
int m_mcChannel
bool m_useCommonPRWFiles
std::string m_commonPRWFileMC20a
std::string m_commonPRWFileMC20d
std::string m_commonPRWFileMC20e
std::string m_commonPRWFileMC23a
std::string m_commonPRWFileMC23d
std::string m_commonPRWFileMC23e
std::string m_commonPRWFileMC23g
std::vector< std::string > m_prwConfFiles
std::vector< std::string > m_prwLcalcFiles
std::string m_prwActualMu2017File
std::string m_prwActualMu2018File
std::string m_prwActualMu2022File
std::string m_prwActualMu2023File
std::string m_prwActualMu2024File
std::string m_prwActualMu2025File
double m_prwDataSF
double m_prwDataSF_UP
double m_prwDataSF_DW
bool m_runDepPrescaleWeightPRW
std::vector< std::string > m_el_id_support
std::vector< std::string > m_ph_id_support
int m_mu_id_support
std::vector< std::string > m_tau_id_support
std::vector< std::string > m_el_iso_support
std::vector< std::string > m_mu_iso_support
std::map< std::string, std::string > m_el_iso_fallback
std::map< std::string, std::string > m_mu_iso_fallback
std::map< int, intm_tau_id_fallback
std::string m_electronTriggerSFStringSingle
std::map< std::string, std::string > m_tau_trig_support
std::string m_eleId
std::string m_eleIdBaseline
std::string m_eleConfig
std::string m_eleConfigBaseline
std::string m_eleBaselineIso_WP
bool m_eleIdExpert
int m_muId
int m_muIdBaseline
std::string m_photonId
std::string m_photonIdBaseline
std::string m_tauTagger
std::string m_tauId
std::string m_tauIdBaseline
bool m_tauEleId
bool m_tauEleIdBaseline
bool m_tauMuOLR
bool m_tauMuOLRBaseline
std::string m_eleIso_WP
std::string m_eleIsoHighPt_WP
double m_eleIsoHighPtThresh
std::string m_eleChID_WP
bool m_eleLRT
int m_eleLRT_strat
bool m_eleChIso
bool m_eleChID_signal
bool m_runECIS
std::string m_photonBaselineIso_WP
std::string m_photonIso_WP
std::string m_photonTriggerName
std::string m_muBaselineIso_WP
std::string m_muIso_WP
std::string m_muIsoHighPt_WP
double m_muIsoHighPtThresh
bool m_muHighPtExtraSmear
bool m_muEffCorrForce1D
std::string m_muTriggerSFCalibRelease
std::string m_muTriggerSFCalibFilename
std::string m_BtagWP
std::string m_BtagTagger
double m_BtagMinPt
std::string m_BtagSystStrategy
std::string m_EigenvectorReductionB
std::string m_EigenvectorReductionC
std::string m_EigenvectorReductionLight
bool m_BtagReadFromObject
std::string m_BtagWP_trkJet
std::string m_BtagTagger_trkJet
double m_BtagMinPt_trkJet
bool m_BtagReadFromObject_trkJet
double m_eleBaselinePt
double m_eleBaselineEta
bool m_eleBaselineCrackVeto
double m_elePt
double m_eleEta
bool m_eleCrackVeto
double m_eled0sig
double m_elez0
double m_elebaselined0sig
double m_elebaselinez0
std::string m_eleEffMapFilePath
std::string m_eleEffMapFilePathRun2
bool m_eleAllowRun3TrigSFFallback
bool m_eleForceFullSimCalib
double m_muBaselinePt
double m_muBaselineEta
double m_muPt
double m_muEta
double m_mud0sig
double m_muz0
double m_mubaselined0sig
double m_mubaselinez0
bool m_murequirepassedHighPtCuts
double m_muCosmicz0
double m_muCosmicd0
double m_badmuQoverP
int m_muCalibrationMode
bool m_muLRT
double m_photonBaselinePt
double m_photonBaselineEta
double m_photonEta
double m_photonPt
bool m_photonBaselineCrackVeto
bool m_photonCrackVeto
bool m_photonAllowLate
double m_tauPrePtCut
double m_tauPt
double m_tauEta
std::string m_tauConfigPath
std::string m_tauConfigPathBaseline
std::string m_tauInputFile
std::string m_tauInputFileBaseline
bool m_tauDoTTM
std::string m_tauSmearingToolRecommendationTag
std::string m_tauEffToolRecommendationTag
bool m_ApplyMVATESQualityCheck
TEnv m_tauConfigReader
double m_jetPt
double m_jetEta
double m_jetJvt
std::string m_JvtWP
double m_JvtPtMax
std::string m_JvtConfigRun2
std::string m_JvtConfigRun3
double m_trkJetPt
double m_trkJetEta
bool m_doFwdJVT
std::string m_fJvtWP
double m_fJvtPtMax
double m_fJvtEtaMin
std::string m_fJvtConfigRun2
std::string m_fJvtConfigRun3
bool m_JMScalib
bool m_orDoTau
 Overlap removal options.
bool m_orDoPhoton
bool m_orDoEleJet
bool m_orDoElEl
bool m_orDoElMu
bool m_orDoMuonJet
bool m_orDoBjet
bool m_orDoElBjet
bool m_orDoMuBjet
bool m_orDoTauBjet
bool m_orDoBoostedElectron
double m_orBoostedElectronC1
double m_orBoostedElectronC2
double m_orBoostedElectronMaxConeSize
bool m_orDoBoostedMuon
double m_orBoostedMuonC1
double m_orBoostedMuonC2
double m_orBoostedMuonMaxConeSize
bool m_orApplyRelPt
double m_orMuJetPtRatio
double m_orMuJetTrkPtRatio
double m_orMuJetInnerDR
bool m_orDoMuonJetGhostAssociation
bool m_orRemoveCaloMuons
std::string m_orBtagWP
std::string m_orInputLabel
bool m_orPhotonFavoured
double m_orBJetPtUpperThres
bool m_orLinkOverlapObjects
bool m_orDoFatjets
double m_EleFatJetDR
double m_JetFatJetDR
bool m_doIsoSignal
bool m_doElIsoSignal
bool m_doPhIsoSignal
bool m_doMuIsoSignal
bool m_useSigLepForIsoCloseByOR
std::string m_IsoCloseByORpassLabel
std::map< std::string, boolm_slices
bool m_isRun3
bool m_isPHYSLITE
std::string m_metJetSelection
int m_showerType
std::string m_defaultJets
std::string m_defaultTrackJets
std::string m_fatJets
std::string m_defaultTruthJets
CP::SystematicSet m_defaultSyst = CP::SystematicSet()
CP::SystematicSet m_currentSyst
std::vector< CP::SystematicSetm_fatjetFFSmearingSyst
std::string m_EG_corrModel
std::string m_EG_corrFNList
bool m_applyJVTCut
std::string m_bTaggingCalibrationFilePath
std::map< std::string, std::string > m_legsPerTool
std::map< std::string, std::string > m_legsPerTool_ph
asg::AnaToolHandle< IJetCalibrationToolm_jetCalibTool
asg::AnaToolHandle< IJetCalibrationToolm_jetFatCalibTool
asg::AnaToolHandle< ICPJetUncertaintiesToolm_jetUncertaintiesTool
asg::AnaToolHandle< ICPJetUncertaintiesToolm_jetUncertaintiesPDSmearTool
asg::AnaToolHandle< ICPJetUncertaintiesToolm_fatjetUncertaintiesTool
asg::AnaToolHandle< ICPJetUncertaintiesToolm_fatjetUncertaintiesPDSmearTool
asg::AnaToolHandle< ICPJetCorrectionToolm_fatjetFFSmearingTool
asg::AnaToolHandle< IJetSelectorm_jetCleaningTool
asg::AnaToolHandle< JetPileupLabelingToolm_jetPileupLabelingTool
asg::AnaToolHandle< JetVertexTaggerToolm_jetJvtMomentTool
asg::AnaToolHandle< JetPileupTag::JetVertexNNTaggerm_jetNNJvtMomentTool
asg::AnaToolHandle< IAsgSelectionToolm_jetNNJvtSelectionTool
asg::AnaToolHandle< CP::IJvtEfficiencyToolm_jetNNJvtEfficiencyTool
asg::AnaToolHandle< IAsgSelectionToolm_jetfJvtSelectionTool
asg::AnaToolHandle< CP::IJvtEfficiencyToolm_jetfJvtEfficiencyTool
asg::AnaToolHandle< SmoothedWZTaggerm_WTaggerTool
asg::AnaToolHandle< SmoothedWZTaggerm_ZTaggerTool
asg::AnaToolHandle< JSSWTopTaggerDNNm_TopTaggerTool
asg::AnaToolHandle< JetTruthLabelingToolm_jetTruthLabelingTool
asg::AnaToolHandle< ICPJetUncertaintiesToolm_WTagjetUncertaintiesTool
asg::AnaToolHandle< ICPJetUncertaintiesToolm_ZTagjetUncertaintiesTool
asg::AnaToolHandle< ICPJetUncertaintiesToolm_TopTagjetUncertaintiesTool
SG::ReadDecorHandleKey< xAOD::JetContainerm_label_truthKey
std::string m_jesConfig
std::string m_jesConfigJMS
std::string m_jesConfigJMSData
std::string m_jesConfigAFII
std::string m_jesConfigFat
std::string m_jesConfigFatData
std::string m_jesCalibSeq
std::string m_jesCalibSeqJMS
std::string m_jesCalibSeqFat
std::string m_jesCalibArea
asg::AnaToolHandle< CP::IMuonSelectionToolm_muonSelectionTool
asg::AnaToolHandle< CP::IMuonSelectionToolm_muonSelectionHighPtTool
asg::AnaToolHandle< CP::IMuonSelectionToolm_muonSelectionToolBaseline
asg::AnaToolHandle< CP::IMuonCalibrationAndSmearingToolm_muonCalibTool
asg::AnaToolHandle< CP::IMuonEfficiencyScaleFactorsm_muonEfficiencySFTool
asg::AnaToolHandle< CP::IMuonEfficiencyScaleFactorsm_muonEfficiencyBMHighPtSFTool
asg::AnaToolHandle< CP::IMuonEfficiencyScaleFactorsm_muonTTVAEfficiencySFTool
asg::AnaToolHandle< CP::IMuonEfficiencyScaleFactorsm_muonIsolationSFTool
asg::AnaToolHandle< CP::IMuonEfficiencyScaleFactorsm_muonHighPtIsolationSFTool
asg::AnaToolHandle< CP::IMuonTriggerScaleFactorsm_muonTriggerSFTool
ToolHandleArray< CP::IMuonTriggerScaleFactorsm_muonTrigSFTools
asg::AnaToolHandle< CP::IMuonLRTOverlapRemovalToolm_muonLRTORTool
SG::WriteHandleKey< xAOD::MuonContainerm_outMuonLocation {this, "OutputMuonLocation", "StdWithLRTMuons", "name of the muon container to write"}
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionToolm_elecEfficiencySFTool_reco
 Combined muon collection.
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionToolm_elecEfficiencySFTool_id
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionToolm_elecEfficiencySFTool_trig_singleLep
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionToolm_elecEfficiencySFTool_trigEff_singleLep
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionToolm_elecEfficiencySFTool_iso
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionToolm_elecEfficiencySFTool_isoHighPt
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionToolm_elecEfficiencySFTool_chf
std::vector< asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > > m_elecEfficiencySFTool_trig_mixLep
std::vector< asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > > m_elecEfficiencySFTool_trigEff_mixLep
ToolHandleArray< IAsgElectronEfficiencyCorrectionToolm_elecTrigSFTools
ToolHandleArray< IAsgElectronEfficiencyCorrectionToolm_elecTrigEffTools
asg::AnaToolHandle< CP::IElectronLRTOverlapRemovalToolm_elecLRTORTool
SG::WriteHandleKey< xAOD::ElectronContainerm_outElectronLocation {this, "OutputElectronLocation", "StdWithLRTElectrons", "name of the muon container to write"}
asg::AnaToolHandle< CP::IEgammaCalibrationAndSmearingToolm_egammaCalibTool
 Combined electron collection.
asg::AnaToolHandle< IAsgElectronLikelihoodToolm_elecSelLikelihood
asg::AnaToolHandle< IAsgElectronLikelihoodToolm_elecSelLikelihoodBaseline
asg::AnaToolHandle< IAsgPhotonIsEMSelectorm_photonSelIsEM
asg::AnaToolHandle< IAsgPhotonIsEMSelectorm_photonSelIsEMBaseline
asg::AnaToolHandle< IAsgDeadHVCellRemovalToolm_deadHVTool
asg::AnaToolHandle< IAsgPhotonEfficiencyCorrectionToolm_photonEfficiencySFTool
asg::AnaToolHandle< IAsgPhotonEfficiencyCorrectionToolm_photonIsolationSFTool
asg::AnaToolHandle< IAsgPhotonEfficiencyCorrectionToolm_photonTriggerSFTool
std::vector< asg::AnaToolHandle< IAsgPhotonEfficiencyCorrectionTool > > m_photonEfficiencySFTool_trigSF_AsymDiphoton
std::vector< asg::AnaToolHandle< IAsgPhotonEfficiencyCorrectionTool > > m_photonEfficiencySFTool_trigEff_AsymDiphoton
ToolHandleArray< IAsgPhotonEfficiencyCorrectionToolm_photonTrigSFTools
ToolHandleArray< IAsgPhotonEfficiencyCorrectionToolm_photonTrigEffTools
asg::AnaToolHandle< IEGammaAmbiguityToolm_egammaAmbiguityTool
asg::AnaToolHandle< IAsgElectronLikelihoodToolm_elecChargeIDSelectorTool
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionToolm_elecChargeEffCorrTool
asg::AnaToolHandle< TauAnalysisTools::ITauSelectionToolm_tauSelTool
asg::AnaToolHandle< TauAnalysisTools::ITauSelectionToolm_tauSelToolBaseline
asg::AnaToolHandle< TauAnalysisTools::ITauSmearingToolm_tauSmearingTool
asg::AnaToolHandle< TauAnalysisTools::ITauTruthMatchingToolm_tauTruthMatch
asg::AnaToolHandle< TauAnalysisTools::ITauEfficiencyCorrectionsToolm_tauEffTool
std::vector< asg::AnaToolHandle< TauAnalysisTools::ITauEfficiencyCorrectionsTool > > m_tauTrigEffTool
asg::AnaToolHandle< IBTaggingEfficiencyToolm_btagEffTool
asg::AnaToolHandle< IBTaggingSelectionToolm_btagSelTool
asg::AnaToolHandle< IBTaggingSelectionToolm_btagSelTool_OR
asg::AnaToolHandle< IBTaggingEfficiencyToolm_btagEffTool_trkJet
asg::AnaToolHandle< IBTaggingSelectionToolm_btagSelTool_trkJet
asg::AnaToolHandle< IMETMakerm_metMaker
asg::AnaToolHandle< IMETSystematicsToolm_metSystTool
asg::AnaToolHandle< IMETSignificancem_metSignif
std::string m_trig2015combination_singleLep
std::string m_trig2016combination_singleLep
std::string m_trig2017combination_singleLep
std::string m_trig2018combination_singleLep
std::string m_trig2022combination_singleLep
std::string m_trig2023combination_singleLep
std::string m_trig2024combination_singleLep
int m_trigNToys_diLep
std::string m_trig2015combination_diLep
std::string m_trig2016combination_diLep
std::string m_trig2017combination_diLep
std::string m_trig2018combination_diLep
std::string m_trig2022combination_diLep
asg::AnaToolHandle< ITrigGlobalEfficiencyCorrectionToolm_trigGlobalEffCorrTool_diLep
int m_trigNToys_multiLep
std::string m_trig2015combination_multiLep
std::string m_trig2016combination_multiLep
std::string m_trig2017combination_multiLep
std::string m_trig2018combination_multiLep
std::string m_trig2022combination_multiLep
asg::AnaToolHandle< ITrigGlobalEfficiencyCorrectionToolm_trigGlobalEffCorrTool_multiLep
int m_trigNToys_diPhoton
std::string m_trig2015combination_diPhoton
std::string m_trig2016combination_diPhoton
std::string m_trig2017combination_diPhoton
std::string m_trig2018combination_diPhoton
std::string m_trig2022combination_diPhoton
asg::AnaToolHandle< ITrigGlobalEfficiencyCorrectionToolm_trigGlobalEffCorrTool_diPhoton
asg::AnaToolHandle< TrigConf::ITrigConfigToolm_trigConfTool
asg::AnaToolHandle< Trig::TrigDecisionToolm_trigDecTool
asg::AnaToolHandle< Trig::IMatchingToolm_trigMatchingTool
asg::AnaToolHandle< Trig::IMatchScoringToolm_trigMatchScoringTool
asg::AnaToolHandle< Trig::IMatchScoringToolm_trigDRScoringTool
asg::AnaToolHandle< CP::IIsolationCorrectionToolm_isoCorrTool
asg::AnaToolHandle< CP::IIsolationSelectionToolm_isoTool
asg::AnaToolHandle< CP::IIsolationSelectionToolm_isoBaselineTool
asg::AnaToolHandle< CP::IIsolationSelectionToolm_isoHighPtTool
asg::AnaToolHandle< CP::IIsolationCloseByCorrectionToolm_isoCloseByTool
asg::AnaToolHandle< CP::IPileupReweightingToolm_prwTool
asg::AnaToolHandle< InDet::IInclusiveTrackFilterToolm_LRTuncTool
asg::AnaToolHandle< ORUtils::IOverlapToolm_tauJetORtool
ORUtils::ToolBox m_orToolbox
asg::AnaToolHandle< IWeightToolm_pmgSHnjetWeighter
asg::AnaToolHandle< IWeightToolm_pmgSHnjetWeighterWZ
std::string m_eleIdBaselineDFName
std::string m_eleIdDFName
std::string m_photonIdBaselineDFName
std::string m_photonIdDFName
std::string m_jetCleanDFName
SG::ConstAccessor< charm_acc_eleIdBaseline
SG::ConstAccessor< charm_acc_eleId
SG::ConstAccessor< charm_acc_photonIdBaseline
SG::ConstAccessor< charm_acc_photonId
SG::ConstAccessor< charm_acc_jetClean

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t

Private Member Functions

StatusCode SUSYToolsInit ()
bool emulateHLT (const std::string &triggerName) const
bool isTrigInTDT (std::scoped_lock< std::mutex > &lock, const std::string &triggerName) const
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey>

Private Attributes

std::map< std::string, std::string > m_conf_to_prop
std::set< std::string > m_bool_prop_set
std::map< std::string, std::function< bool()> > m_metTriggerFuncs ATLAS_THREAD_SAFE
std::map< std::string, bool > m_checkedTriggers ATLAS_THREAD_SAFE
std::mutex m_triggerCacheMutex
std::vector< std::string > m_v_trigs15_cache_singleEle
std::vector< std::string > m_v_trigs16_cache_singleEle
std::vector< std::string > m_v_trigs17_cache_singleEle
std::vector< std::string > m_v_trigs18_cache_singleEle
std::vector< std::string > m_v_trigs22_cache_singleEle
std::vector< std::string > m_v_trigs23_cache_singleEle
std::vector< std::string > m_v_trigs24_cache_singleEle
std::vector< std::string > m_v_trigs15_cache_singleLep
std::vector< std::string > m_v_trigs16_cache_singleLep
std::vector< std::string > m_v_trigs17_cache_singleLep
std::vector< std::string > m_v_trigs18_cache_singleLep
std::vector< std::string > m_v_trigs22_cache_singleLep
std::vector< std::string > m_v_trigs23_cache_singleLep
std::vector< std::string > m_v_trigs24_cache_singleLep
std::vector< std::string > m_v_trigs15_cache_diLep
std::vector< std::string > m_v_trigs16_cache_diLep
std::vector< std::string > m_v_trigs17_cache_diLep
std::vector< std::string > m_v_trigs18_cache_diLep
std::vector< std::string > m_v_trigs22_cache_diLep
std::vector< std::string > m_v_trigs15_cache_multiLep
std::vector< std::string > m_v_trigs16_cache_multiLep
std::vector< std::string > m_v_trigs17_cache_multiLep
std::vector< std::string > m_v_trigs18_cache_multiLep
std::vector< std::string > m_v_trigs22_cache_multiLep
SG::ReadHandleKey< xAOD::TrackParticleContainerm_LRTCollectionName {this, "LRTCollectionName", "InDetLargeD0TrackParticles", "LRT collection name"}
SG::ReadHandleKey< xAOD::TrackParticleContainerm_GSFLRTCollectionName {this, "GSFLRTCollectionName", "LRTGSFTrackParticles", "GSF LRT collection name"}
MetaStore_t m_inputMetaStore
 Object accessing the input metadata store.
MetaStore_t m_outputMetaStore
 Object accessing the output metadata store.
bool m_beginInputFileCalled
 Flag helping to discover when the tool misses the opening of the first input file.
bool m_useIncidents
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default).
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default).
std::vector< SG::VarHandleKeyArray * > m_vhka
bool m_varHandleArraysDeclared

Detailed Description

Definition at line 141 of file SUSYObjDef_xAOD.h.

Member Typedef Documentation

◆ MetaStore_t

Type of the metadata store object in Athena.

Definition at line 66 of file AsgMetadataTool.h.

◆ MetaStorePtr_t

Type of the metadata store pointer in standalone mode.

Definition at line 68 of file AsgMetadataTool.h.

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< AlgTool > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Member Enumeration Documentation

◆ DataSource

Enumerator
Undefined 
Data 
FullSim 
AtlfastII 

Definition at line 477 of file ISUSYObjDef_xAODTool.h.

Constructor & Destructor Documentation

◆ SUSYObjDef_xAOD()

ST::SUSYObjDef_xAOD::SUSYObjDef_xAOD ( const std::string & name)

Definition at line 101 of file SUSYObjDef_xAOD.cxx.

102 : asg::AsgMetadataTool( name ),
105 m_force_noElId(false),
106 m_force_noMuId(false),
107 m_doTTVAsf(true),
110 m_useBtagging(false),
112 m_debug(false),
113 m_strictConfigCheck(false),
114 m_badJetCut(""),
116 m_fatJetUncVars(""),
117 m_WDecorName(""),
118 m_ZDecorName(""),
119 m_TopDecorName(""),
120 m_WtagConfig(""),
121 m_ZtagConfig(""),
122 m_ToptagConfig(""),
125 m_WTagUncConfig(""),
126 m_ZTagUncConfig(""),
129 m_tool_init(false),
130 m_subtool_init(false),
131 // set dummies for configuration
132 m_eleTerm(""),
133 m_gammaTerm(""),
134 m_tauTerm(""),
135 m_jetTerm(""),
136 m_muonTerm(""),
138 m_outMETTerm(""),
142 m_metUseGhostMuons(false),
143 m_metDoMuonEloss(false),
144 m_metGreedyPhotons(false),
147 m_trkMETsyst(true),
148 m_caloMETsyst(false),
149 m_softTermParam(-99),
150 m_treatPUJets(true),
151 m_doPhiReso(true),
152 m_autoconfigPRW(false),
158 m_mcCampaign(""),
159 m_mcChannel(-99),
160 m_useCommonPRWFiles(false),
168 m_prwDataSF(-99.),
169 m_prwDataSF_UP(-99.),
170 m_prwDataSF_DW(-99.),
173 m_eleId(""),
174 m_eleIdBaseline(""),
175 m_eleConfig(""),
178 m_eleIdExpert(false),
179 m_muId(static_cast<int>(xAOD::Muon::Quality(xAOD::Muon::VeryLoose))),
180 m_muIdBaseline(static_cast<int>(xAOD::Muon::Quality(xAOD::Muon::VeryLoose))),
181 m_photonId(""),
183 m_tauTagger(""),
184 m_tauId(""),
185 m_tauIdBaseline(""),
186 m_tauEleId(true),
187 m_tauEleIdBaseline(true),
188 m_tauMuOLR(false),
189 m_tauMuOLRBaseline(false),
190 m_eleIso_WP(""),
193 m_eleChID_WP(""),
194 m_eleLRT_strat(-99),
195 m_eleChIso(true),
196 m_eleChID_signal(false),
197 m_runECIS(false),
199 m_photonIso_WP(""),
202 m_muIso_WP(""),
206 m_muEffCorrForce1D(false),
207 m_BtagWP(""),
208 m_BtagTagger(""),
209 m_BtagMinPt(-99.),
215 m_BtagWP_trkJet(""),
217 m_BtagMinPt_trkJet(-99.),
219 //configurable cuts here
220 m_eleBaselinePt(-99.),
221 m_eleBaselineEta(-99.),
223 m_elePt(-99.),
224 m_eleEta(-99.),
225 m_eleCrackVeto(false),
226 m_eled0sig(-99.),
227 m_elez0(-99.),
228 m_elebaselined0sig(-99.),
229 m_elebaselinez0(-99),
232 //
233 m_muBaselinePt(-99.),
234 m_muBaselineEta(-99.),
235 m_muPt(-99.),
236 m_muEta(-99.),
237 m_mud0sig(-99.),
238 m_muz0(-99.),
239 m_mubaselined0sig(-99.),
240 m_mubaselinez0(-99.),
242 m_muCosmicz0(-99.),
243 m_muCosmicd0(-99.),
244 m_badmuQoverP(-99.),
246 //
247 m_photonBaselinePt(-99.),
249 m_photonEta(-99.),
250 m_photonPt(-99.),
252 m_photonCrackVeto(true),
253 m_photonAllowLate(false),
254 //
255 m_tauPrePtCut(-99.),
256 m_tauPt(-99.),
257 m_tauEta(-99.),
258 m_tauConfigPath(""),
260 m_tauInputFile(""),
262 m_tauDoTTM(false),
266 //
267 m_jetPt(-99.),
268 m_jetEta(-99.),
269 m_jetJvt(-99.),
270 m_JvtWP(""),
271 m_JvtPtMax(-99.),
272 m_JvtConfigRun2(""),
273 m_JvtConfigRun3(""),
274 m_trkJetPt(-99.),
275 m_trkJetEta(-99.),
276 m_doFwdJVT(false),
277 m_fJvtWP(""),
278 m_fJvtPtMax(-99.),
279 m_fJvtEtaMin(-99.),
282 m_JMScalib(false),
283 //
284 m_orDoTau(false),
285 m_orDoPhoton(false),
286 m_orDoEleJet(true),
287 m_orDoElEl(false),
288 m_orDoElMu(false),
289 m_orDoMuonJet(true),
290 m_orDoBjet(false),
291 m_orDoElBjet(true),
292 m_orDoMuBjet(true),
293 m_orDoTauBjet(true),
295 m_orBoostedElectronC1(-999.), // set to positive value to activate
296 m_orBoostedElectronC2(-999.), // set to positive value to activate
297 m_orBoostedElectronMaxConeSize(-999.), // set to positive value to activate
298 m_orDoBoostedMuon(true),
299 m_orBoostedMuonC1(-999.), // set to positive value to activate
300 m_orBoostedMuonC2(-999.), // set to positive value to activate
301 m_orBoostedMuonMaxConeSize(-999.), // set to positive value to activate
302 m_orApplyRelPt(false),
303 m_orMuJetPtRatio(-999.),
304 m_orMuJetTrkPtRatio(-999.),
305 m_orMuJetInnerDR(-999),
308 m_orBtagWP(""),
309 m_orInputLabel(""),
310 m_orPhotonFavoured(false),
313 m_orDoFatjets(false),
314 m_EleFatJetDR(-999.),
315 m_JetFatJetDR(-999.),
316 m_doIsoSignal(true),
317 m_doElIsoSignal(true),
318 m_doPhIsoSignal(true),
319 m_doMuIsoSignal(true),
320
323
324 m_slices(std::map<std::string,bool>()),
325 m_isRun3(false),
326 m_isPHYSLITE(false),
327
329 m_fatJets(""),
330 //
333 m_EG_corrModel(""),
334 m_EG_corrFNList(""),
335 m_applyJVTCut(true),
336 //
337 // set toolhandles empty by default
338 m_jetCalibTool(""),
353 //
354 m_WTaggerTool(""),
355 m_ZTaggerTool(""),
356 m_TopTaggerTool(""),
361 //
365 m_muonCalibTool(""),
372 //
379 //
383 m_photonSelIsEM(""),
391 //
392 m_tauSelTool(""),
395 m_tauTruthMatch(""),
396 m_tauEffTool(""),
397 //
398 m_btagEffTool(""),
399 m_btagSelTool(""),
403 //
404 m_metMaker(""),
405 m_metSystTool(""),
406 m_metSignif(""),
407 //
436 m_trigConfTool(""),
437 m_trigDecTool(""),
441 //
442 m_isoCorrTool(""),
443 m_isoTool(""),
444 //disable m_isoToolLowPtPLV(""),
446 m_isoHighPtTool(""),
447 //
448 m_prwTool(""),
449 //
450 m_LRTuncTool(""),
451 //
452 m_orToolbox("ORToolbox",this),
453 //
456 //
457 m_acc_eleIdBaseline("DFCommonElectronsLHLooseBL"),
458 m_acc_eleId("DFCommonElectronsLHTight"),
459 m_acc_photonIdBaseline("DFCommonPhotonsIsEMTight"),
460 m_acc_photonId("DFCommonPhotonsIsEMTight"),
461 //
462 m_acc_jetClean("DFCommonJets_jetClean_LooseBad")
463{
464 //General settings
465 declareProperty( "DataSource", m_dataSource = Undefined );
466 declareProperty( "DebugMode", m_debug );
467 declareProperty( "ConfigFile", m_configFile = "SUSYTools/SUSYTools_Default.conf" );
468 //Overlap Removal
469 declareProperty( "DoTauOR", m_orDoTau );
470 declareProperty( "DoPhotonOR", m_orDoPhoton );
471 declareProperty( "DoEleJetOR", m_orDoEleJet );
472 declareProperty( "DoElElOR", m_orDoElEl );
473 declareProperty( "DoElMuOR", m_orDoElMu );
474 declareProperty( "DoMuonJetOR", m_orDoMuonJet );
475 declareProperty( "DoBjetOR", m_orDoBjet );
476 declareProperty( "DoElBjetOR", m_orDoElBjet );
477 declareProperty( "DoMuBjetOR", m_orDoMuBjet );
478 declareProperty( "DoTauBjetOR", m_orDoTauBjet );
479 declareProperty( "UseBtagging", m_useBtagging );
480 declareProperty( "UseBtaggingTrkJet", m_useBtagging_trkJet );
481 declareProperty( "DoBoostedElectronOR", m_orDoBoostedElectron );
482 declareProperty( "BoostedElectronORC1", m_orBoostedElectronC1 );
483 declareProperty( "BoostedElectronORC2", m_orBoostedElectronC2 );
484 declareProperty( "BoostedElectronORMaxConeSize", m_orBoostedElectronMaxConeSize );
485 declareProperty( "DoBoostedMuonOR", m_orDoBoostedMuon );
486 declareProperty( "BoostedMuonORC1", m_orBoostedMuonC1 );
487 declareProperty( "BoostedMuonORC2", m_orBoostedMuonC2 );
488 declareProperty( "BoostedMuonORMaxConeSize", m_orBoostedMuonMaxConeSize );
489 declareProperty( "ORDoMuonJetGhostAssociation", m_orDoMuonJetGhostAssociation );
490 declareProperty( "ORRemoveCaloMuons", m_orRemoveCaloMuons );
491 declareProperty( "ORMuJetApplyRelPt", m_orApplyRelPt);
492 declareProperty( "ORMuJetPtRatio", m_orMuJetPtRatio);
493 declareProperty( "ORMuJetInnerDR", m_orMuJetInnerDR );
494 declareProperty( "ORJetTrkPtRatio", m_orMuJetTrkPtRatio);
495 declareProperty( "ORInputLabel", m_orInputLabel);
496 declareProperty( "ORPhotonFavoured", m_orPhotonFavoured);
497 declareProperty( "ORBJetPtUpperThres", m_orBJetPtUpperThres);
498 declareProperty( "ORLinkOverlapObjects", m_orLinkOverlapObjects);
499
500 declareProperty( "DoFatJetOR", m_orDoFatjets);
501 declareProperty( "OREleFatJetDR", m_EleFatJetDR);
502 declareProperty( "ORJetFatJetDR", m_JetFatJetDR);
503 declareProperty( "TriggerUpstreamMatching", m_upstreamTriggerMatching, "Use alternative trigger matching tool based on upstream (in-derivation) matching");
504 declareProperty( "TriggerMatchingPrefix", m_trigMatchingPrefix, "Prefix for trigger matching containers (Analysis for PHSYLITE derivations");
505
506 //--- Object definitions
507 //MET
508 declareProperty( "METEleTerm", m_eleTerm );
509 declareProperty( "METGammaTerm", m_gammaTerm );
510 declareProperty( "METTauTerm", m_tauTerm );
511 declareProperty( "METJetTerm", m_jetTerm );
512 declareProperty( "METMuonTerm", m_muonTerm );
513 declareProperty( "METInputSuffix", m_inputMETSuffix );
514 declareProperty( "METOutputTerm", m_outMETTerm );
515 declareProperty( "METDoTrkSyst", m_trkMETsyst );
516 declareProperty( "METDoCaloSyst", m_caloMETsyst );
517 declareProperty( "METDoTrkJetSyst", m_trkJetsyst );
518 declareProperty( "METJetSelection", m_metJetSelection );
519 declareProperty( "METSysConfigPrefix", m_metsysConfigPrefix );
520
521 declareProperty( "METRemoveORCaloTaggedMuons", m_metRemoveOverlappingCaloTaggedMuons);
522 declareProperty( "METDoSetMuonJetEMScale", m_metDoSetMuonJetEMScale);
523 declareProperty( "METDoRemoveMuonJets", m_metDoRemoveMuonJets );
524 declareProperty( "METUseGhostMuons", m_metUseGhostMuons );
525 declareProperty( "METDoMuonEloss", m_metDoMuonEloss );
526 declareProperty( "METDoGreedyPhotons", m_metGreedyPhotons );
527 declareProperty( "METDoVeryGreedyPhotons", m_metVeryGreedyPhotons );
528
529
530 declareProperty( "SoftTermParam", m_softTermParam);
531 declareProperty( "TreatPUJets", m_treatPUJets);
532 declareProperty( "DoPhiReso", m_doPhiReso);
533
534 //JETS
535 declareProperty( "JetInputType", m_jetInputType );
536
537 declareProperty( "FwdJetDoJVT", m_doFwdJVT );
538
539 declareProperty( "JetJMSCalib", m_JMScalib );
540 declareProperty( "JetLargeRcollection", m_fatJets );
541
542 //BTAGGING
543 declareProperty( "BtagTagger", m_BtagTagger);
544 declareProperty( "BtagWPOR", m_orBtagWP); //the one used in the Overlap Removal
545 declareProperty( "BtagWP", m_BtagWP); //the one used in FillJet() afterwards
546 declareProperty( "BtagMinPt", m_BtagMinPt); // minimum jetPt cut (MR31061) >=20 GeV EM jets & >=10 GeV TrackJets (not calibrated below)
548 declareProperty( "BtagReadFromObject", m_BtagReadFromObject);
549 declareProperty( "BtagTaggerTrkJet", m_BtagTagger_trkJet);
550 declareProperty( "BtagMinPtTrkJet", m_BtagMinPt_trkJet); // minimum jetPt cut (MR31061) >=20 GeV EM jets & >=10 GeV TrackJets (not calibrated below)
551 declareProperty( "BtagWPTrkJet", m_BtagWP_trkJet); //the one used in FillTrackJet() afterwards
552 declareProperty( "BtagReadFromObjectTrkJet", m_BtagReadFromObject_trkJet);
553 //ELECTRONS
554 declareProperty( "EleBaselinePt", m_eleBaselinePt);
555 declareProperty( "ElePt", m_elePt);
556 declareProperty( "EleBaselineEta", m_eleBaselineEta);
557 declareProperty( "EleEta", m_eleEta);
558 declareProperty( "EleBaselineId", m_eleIdBaseline);
559 declareProperty( "EleBaselineConfig", m_eleConfigBaseline);
560 declareProperty( "EleBaselineCrackVeto", m_eleBaselineCrackVeto);
561 declareProperty( "EleId", m_eleId);
562 declareProperty( "EleConfig", m_eleConfig);
563 declareProperty( "EleIso", m_eleIso_WP);
564 declareProperty( "EleIsoHighPt", m_eleIsoHighPt_WP);
565 declareProperty( "EleIsoHighPtThresh", m_eleIsoHighPtThresh);
566 declareProperty( "EleCFT", m_eleChID_WP);
567 declareProperty( "EleCFTIso", m_eleChIso);
568 declareProperty( "EleCFTSignal", m_eleChID_signal);
569 declareProperty( "EleD0sig", m_eled0sig);
570 declareProperty( "EleZ0", m_elez0);
571 declareProperty( "EleBaselineD0sig", m_elebaselined0sig);
572 declareProperty( "EleBaselineZ0", m_elebaselinez0);
573 declareProperty( "EleCrackVeto", m_eleCrackVeto);
574 declareProperty( "EleForceNoId", m_force_noElId );
575 declareProperty( "EleEffMapFilePath", m_eleEffMapFilePath);
576 declareProperty( "EleAllowRun3TrigSFFallback", m_eleAllowRun3TrigSFFallback);
577 declareProperty( "EleForceFullSimCalib", m_eleForceFullSimCalib);
578
579 //MUONS
580 declareProperty( "MuonBaselinePt", m_muBaselinePt);
581 declareProperty( "MuonPt", m_muPt);
582 declareProperty( "MuonBaselineEta", m_muBaselineEta);
583 declareProperty( "MuonEta", m_muEta);
584 declareProperty( "MuonBaselineId", m_muIdBaseline);
585 declareProperty( "MuonId", m_muId);
586 declareProperty( "MuonIso", m_muIso_WP);
587 declareProperty( "MuonIsoHighPt", m_muIsoHighPt_WP);
588 declareProperty( "MuonIsoHighPtThresh", m_muIsoHighPtThresh);
589 declareProperty( "MuonHighPtExtraSmear", m_muHighPtExtraSmear);
590 declareProperty( "MuonEffCorrForce1D", m_muEffCorrForce1D);
591 declareProperty( "MuonD0sig", m_mud0sig);
592 declareProperty( "MuonZ0", m_muz0);
593 declareProperty( "MuonBaselineD0sig", m_mubaselined0sig);
594 declareProperty( "MuonBaselineZ0", m_mubaselinez0);
595 declareProperty( "MuonRequireHighPtCuts", m_murequirepassedHighPtCuts);
596 declareProperty( "MuonForceNoId", m_force_noMuId );
597 declareProperty( "MuonTTVASF", m_doTTVAsf );
598 declareProperty( "MuonCalibrationMode", m_muCalibrationMode);
599 //MUONS TRIGGER SCALE FACTOR
600 declareProperty( "MuonTriggerSFCalibRelease", m_muTriggerSFCalibRelease );
601 declareProperty( "MuonTriggerSFCalibFilename", m_muTriggerSFCalibFilename );
602 //PHOTONS
603 declareProperty( "PhotonBaselinePt", m_photonBaselinePt);
604 declareProperty( "PhotonPt", m_photonPt);
605 declareProperty( "PhotonBaselineEta", m_photonBaselineEta);
606 declareProperty( "PhotonEta", m_photonEta);
607 declareProperty( "PhotonBaselineId", m_photonIdBaseline);
608 declareProperty( "PhotonId", m_photonId);
609 declareProperty( "PhotonIso", m_photonIso_WP);
610 declareProperty( "PhotonTriggerName", m_photonTriggerName);
611 declareProperty( "PhotonBaselineCrackVeto", m_photonBaselineCrackVeto);
612 declareProperty( "PhotonCrackVeto", m_photonCrackVeto);
613 declareProperty( "PhotonAllowLate", m_photonAllowLate);
614
615 //TAUS
616 declareProperty( "TauTagger", m_tauTagger);
617 declareProperty( "TauBaselineId", m_tauIdBaseline);
618 declareProperty( "TauId", m_tauId);
619 declareProperty( "TauBaselineEleId", m_tauEleIdBaseline);
620 declareProperty( "TauEleId", m_tauEleId);
621 declareProperty( "TauBaselineMuOLR", m_tauMuOLRBaseline);
622 declareProperty( "TauMuOLR", m_tauMuOLR);
623 declareProperty( "TauIdConfigPathBaseline", m_tauConfigPathBaseline);
624 declareProperty( "TauIdConfigPath", m_tauConfigPath);
625 declareProperty( "TauIdInputFileBaseline", m_tauInputFileBaseline);
626 declareProperty( "TauIdInputFile", m_tauInputFile);
627 declareProperty( "TauDoTruthMatching", m_tauDoTTM);
628 declareProperty( "TauSmearingToolRecommendationTag", m_tauSmearingToolRecommendationTag);
629 declareProperty( "TauEffToolRecommendationTag", m_tauEffToolRecommendationTag);
630 declareProperty( "TauMVATESQualityCheck", m_ApplyMVATESQualityCheck);
631
632 //Leptons
633 declareProperty( "SigLepRequireIso", m_doIsoSignal ); //leave here for back-compatibility
634 declareProperty( "SigElRequireIso", m_doElIsoSignal );
635 declareProperty( "SigMuRequireIso", m_doMuIsoSignal );
636 declareProperty( "SigPhRequireIso", m_doPhIsoSignal );
637
638 //Isolation correction for leptons and photons
639 declareProperty( "UseSigLepForIsoCloseByOR", m_useSigLepForIsoCloseByOR );
640 declareProperty( "IsoCloseByORpassLabel", m_IsoCloseByORpassLabel );
641
642 //--- Tools configuration
643 //PRW
644 declareProperty( "AutoconfigurePRWTool", m_autoconfigPRW );
645 declareProperty( "AutoconfigurePRWToolPath", m_autoconfigPRWPath ); // e.g. dev/PileupReweighting/share/
646 declareProperty( "AutoconfigurePRWToolFile", m_autoconfigPRWFile ); // e.g. DSID407xxx/pileup_mc16a_dsid407352_FS.root
647 declareProperty( "AutoconfigurePRWToolCombinedmode", m_autoconfigPRWCombinedmode );
648 declareProperty( "AutoconfigurePRWToolRPVmode", m_autoconfigPRWRPVmode );
649 declareProperty( "AutoconfigurePRWToolRtags", m_autoconfigPRWRtags );
650 declareProperty( "mcCampaign", m_mcCampaign );
651 declareProperty( "mcChannel", m_mcChannel );
652 declareProperty( "PRWConfigFiles", m_prwConfFiles );
653 declareProperty( "PRWLumiCalcFiles", m_prwLcalcFiles );
654 declareProperty( "PRWActualMu2017File", m_prwActualMu2017File );
655 declareProperty( "PRWActualMu2018File", m_prwActualMu2018File );
656 declareProperty( "PRWActualMu2022File", m_prwActualMu2022File );
657 declareProperty( "PRWActualMu2023File", m_prwActualMu2023File );
658 declareProperty( "PRWActualMu2024File", m_prwActualMu2024File );
659 declareProperty( "PRWActualMu2025File", m_prwActualMu2025File );
660 declareProperty( "PRWDataScaleFactor", m_prwDataSF);
661 declareProperty( "PRWDataScaleFactorUP", m_prwDataSF_UP);
662 declareProperty( "PRWDataScaleFactorDOWN", m_prwDataSF_DW);
663 declareProperty( "PRWUseRunDependentPrescaleWeight", m_runDepPrescaleWeightPRW);
664 declareProperty( "PRWUseCommonMCFiles", m_useCommonPRWFiles);
665 declareProperty( "PRWCommonFileMC20a", m_commonPRWFileMC20a);
666 declareProperty( "PRWCommonFileMC20d", m_commonPRWFileMC20d);
667 declareProperty( "PRWCommonFileMC20e", m_commonPRWFileMC20e);
668 declareProperty( "PRWCommonFileMC23a", m_commonPRWFileMC23a);
669 declareProperty( "PRWCommonFileMC23d", m_commonPRWFileMC23d);
670 declareProperty( "PRWCommonFileMC23e", m_commonPRWFileMC23e);
671 declareProperty( "PRWCommonFileMC23g", m_commonPRWFileMC23g);
672 //LargeR uncertainties config, as from https://twiki.cern.ch/twiki/bin/viewauth/AtlasProtected/JetUncertainties2016PrerecLargeR#Understanding_which_configuratio
673 declareProperty( "JetLargeRuncConfig", m_fatJetUncConfig );
674 declareProperty( "JetLargeRuncVars", m_fatJetUncVars );
675 declareProperty( "JetWtaggerConfig", m_WtagConfig );
676 declareProperty( "JetZtaggerConfig", m_ZtagConfig );
677 declareProperty( "JetWZTaggerCalibArea", m_WZTaggerCalibArea );
678 declareProperty( "JetToptaggerConfig", m_ToptagConfig );
679 declareProperty( "JetTruthLabelName", m_JetTruthLabelName );
680 declareProperty( "JetTopTaggerCalibArea", m_TopTaggerCalibArea );
681 declareProperty( "JetWTaguncConfig", m_WTagUncConfig );
682 declareProperty( "JetZTaguncConfig", m_ZTagUncConfig );
683 declareProperty( "JetTopTaguncConfig", m_TopTagUncConfig );
684 //Btagging MCtoMC SFs
685 declareProperty( "ShowerType", m_showerType = 0 );
686 //Egamma NP correlation model
687 declareProperty( "EleEffNPcorrModel", m_EG_corrModel );
688 //Egamma correction file list override
689 declareProperty( "EleEffCorrFNList", m_EG_corrFNList );
690 declareProperty( "IsRun3", m_isRun3 );
691 declareProperty( "IsPHYSLITE", m_isPHYSLITE );
692
693 //For electron trigger SF tools
694 declareProperty( "ElectronTriggerSFStringSingle", m_electronTriggerSFStringSingle);
695
696 //--- Tool pointers /MT : we may want to improve the descriptions :)
697 m_jetCalibTool.declarePropertyFor( this, "JetCalibTool", "The JetCalibTool" );
698 m_jetFatCalibTool.declarePropertyFor( this, "FatJetCalibTool", "The JetCalibTool for large-R jets" );
699 m_jetUncertaintiesTool.declarePropertyFor( this, "JetUncertaintiesTool", "The JetUncertaintiesTool" );
700 m_jetUncertaintiesPDSmearTool.declarePropertyFor( this, "JetPDSmearUncertaintiesTool", "The JetPDSmearUncertaintiesTool" );
701 m_fatjetUncertaintiesTool.declarePropertyFor( this, "FatJetUncertaintiesTool", "The JetUncertaintiesTool for large-R jets" );
702 m_fatjetUncertaintiesPDSmearTool.declarePropertyFor( this, "FatJetPDSmearUncertaintiesTool", "The FatJetPDSmearUncertaintiesTool" );
703 m_fatjetFFSmearingTool.declarePropertyFor( this, "FatJetFFSmearingTool", "The FFSmearingTool for large-R jets" );
704 m_WTagjetUncertaintiesTool.declarePropertyFor( this, "WJetUncertaintiesTool", "The JetUncertaintiesTool for large-R W-tagged jets" );
705 m_ZTagjetUncertaintiesTool.declarePropertyFor( this, "ZJetUncertaintiesTool", "The JetUncertaintiesTool for large-R Z-tagged jets" );
706 m_TopTagjetUncertaintiesTool.declarePropertyFor( this, "TopJetUncertaintiesTool", "The JetUncertaintiesTool for large-R Top-tagged jets" );
707 m_jetCleaningTool.declarePropertyFor( this, "JetCleaningTool", "The JetCleaningTool" );
708 m_jetPileupLabelingTool.declarePropertyFor( this, "JetPileupLabelingTool", "The JetPileupLabelingTool" );
709 m_jetJvtMomentTool.declarePropertyFor( this, "JetJvtMomentTool", "The JetJvtMomentTool" );
710 m_jetNNJvtMomentTool.declarePropertyFor( this, "JetNNJvtMomentTool", "The JetNNJvtMomentTool" );
711 m_jetNNJvtSelectionTool.declarePropertyFor( this, "JetNNJvtSelectionTool", "The JetNNJvtSelectionTool" );
712 m_jetNNJvtEfficiencyTool.declarePropertyFor( this, "JetNNJvtEfficiencyTool", "The JetNNJvtEfficiencyTool" );
713 m_jetfJvtSelectionTool.declarePropertyFor( this, "JetfJvtSelectionTool", "The JetfJvtSelectionTool" );
714 m_jetfJvtEfficiencyTool.declarePropertyFor( this, "JetfJvtEfficiencyTool", "The JetfJvtEfficiencyTool" );
715 //
716 m_WTaggerTool.declarePropertyFor( this, "WTaggerTool", "The SmoothedWZTaggerTool" );
717 m_ZTaggerTool.declarePropertyFor( this, "ZTaggerTool", "The SmoothedWZTaggerTool" );
718 m_TopTaggerTool.declarePropertyFor( this, "TopTaggerTool", "The DNNTopTaggerTool" );
719 m_jetTruthLabelingTool.declarePropertyFor( this, "JetTruthLabelingTool", "The JetTruthLabelingTool" );
720 //
721 m_muonSelectionTool.declarePropertyFor( this, "MuonSelectionTool", "The MuonSelectionTool for signal muons" );
722 m_muonSelectionHighPtTool.declarePropertyFor( this, "MuonSelectionHighPtTool", "The MuonSelectionTool for signal muons (HighPt WP)" );
723 m_muonSelectionToolBaseline.declarePropertyFor( this, "MuonSelectionToolBaseline", "The MuonSelectionTool for baseline muons" );
724 m_muonCalibTool.declarePropertyFor( this, "MuonCalibTool", "The MuonCalibTool" );
725 m_muonEfficiencySFTool.declarePropertyFor( this, "MuonEfficiencyScaleFactorsTool", "The MuonEfficiencySFTool" );
726 m_muonEfficiencyBMHighPtSFTool.declarePropertyFor( this, "MuonBadMuonHighPtScaleFactorsTool", "The MuonBadMuonHighPtSFTool" );
727 m_muonTTVAEfficiencySFTool.declarePropertyFor( this, "MuonTTVAEfficiencyScaleFactorsTool", "The MuonTTVAEfficiencySFTool" );
728 m_muonIsolationSFTool.declarePropertyFor( this, "MuonIsolationScaleFactorsTool", "The MuonIsolationSFTool" );
729 m_muonHighPtIsolationSFTool.declarePropertyFor( this, "MuonHighPtIsolationScaleFactorsTool", "The MuonIsolationSFTool" );
730 m_muonTriggerSFTool.declarePropertyFor( this, "MuonTriggerScaleFactorsTool", "The MuonTriggerSFTool" );
731 m_muonLRTORTool.declarePropertyFor( this, "MuonLRTOverlapRemovalTool", "Prompt/LRT muon OR Tool" );
732 //
733 m_elecEfficiencySFTool_reco.declarePropertyFor( this, "ElectronEfficiencyCorrectionTool_reco", "The ElectronEfficiencyCorrectionTool for reconstruction SFs" );
734 m_elecEfficiencySFTool_trig_singleLep.declarePropertyFor( this, "ElectronEfficiencyCorrectionTool_trig_singleLep", "The ElectronEfficiencyCorrectionTool for single-e triggers" );
735 m_elecEfficiencySFTool_id.declarePropertyFor( this, "ElectronEfficiencyCorrectionTool_id", "The ElectronEfficiencyCorrectionTool for ID SFs" );
736 m_elecEfficiencySFTool_iso.declarePropertyFor( this, "ElectronEfficiencyCorrectionTool_iso" , "The ElectronEfficiencyCorrectionTool for iso SFs" );
737 m_elecEfficiencySFTool_isoHighPt.declarePropertyFor( this, "ElectronEfficiencyCorrectionTool_isoHigPt" , "The ElectronEfficiencyCorrectionTool for iso high-pt SFs" );
738 m_elecSelLikelihood.declarePropertyFor( this, "ElectronLikelihoodTool" , "The ElectronSelLikelihoodTool for signal electrons" );
739 m_elecSelLikelihoodBaseline.declarePropertyFor( this, "ElectronLikelihoodToolBaseline" , "The ElectronSelLikelihoodTool for baseline electrons" );
740 m_egammaAmbiguityTool.declarePropertyFor( this, "EgammaAmbiguityTool", "The EgammaAmbiguityTool" );
741 m_elecChargeIDSelectorTool.declarePropertyFor( this, "ElectronChargeIDSelectorTool", "The ElectronChargeIDSelectorTool" );
742 m_elecChargeEffCorrTool.declarePropertyFor( this, "ElectronChargeEffCorrectionTool", "The ElectronChargeEffCorrectionTool" );
743 m_elecLRTORTool.declarePropertyFor( this, "ElectronLRTOverlapRemovalTool", "Prompt/LRT electron OR Tool" );
744 //
745 m_photonSelIsEM.declarePropertyFor( this, "PhotonIsEMSelector" , "The PhotonIsEMSelectorTool for signal photons" );
746 m_photonSelIsEMBaseline.declarePropertyFor( this, "PhotonIsEMSelectorBaseline" , "The PhotonIsEMSelectorTool for baseline photons" );
747 m_photonEfficiencySFTool.declarePropertyFor( this, "PhotonEfficiencyCorrectionTool", "The PhotonEfficiencyCorrectionTool for reco SFs" );
748 m_photonIsolationSFTool.declarePropertyFor( this, "PhotonIsolationCorrectionTool", "The PhotonEfficiencyCorrectionTool for iso SFs" );
749 m_photonTriggerSFTool.declarePropertyFor( this, "PhotonTriggerEfficiencyCorrectionTool", "The PhotonEfficiencyCorrectionTool for trigger SFs" );
750 //
751 m_egammaCalibTool.declarePropertyFor( this, "EgammaCalibrationAndSmearingTool", "The EgammaCalibrationAndSmearingTool");
752 //
753 m_tauSelTool.declarePropertyFor( this, "TauSelectionTool", "The TauSelectionTool for signal taus" );
754 m_tauSelToolBaseline.declarePropertyFor( this, "TauSelectionToolBaseline", "The TauSelectionTool for baseline taus" );
755 m_tauSmearingTool.declarePropertyFor( this, "TauSmearingTool", "The TauSmearingTool" );
756 m_tauTruthMatch.declarePropertyFor( this, "TauTruthMatch", "The TTMT" );
757 m_tauEffTool.declarePropertyFor( this, "TauEfficiencyCorrectionsTool", "The TauEfficiencyCorrectionsTool" );
758 //
759 m_btagEffTool.declarePropertyFor( this, "BTaggingEfficiencyTool", "The BTaggingEfficiencyTool" );
760 m_btagSelTool.declarePropertyFor( this, "BTaggingSelectionTool", "The main BTaggingSelectionTool" );
761 m_btagSelTool_OR.declarePropertyFor( this, "BTaggingSelectionTool_OR", "The BTaggingSelectionTool used to select b-jets for overlap removal" );
762 m_btagEffTool_trkJet.declarePropertyFor( this, "BTaggingEfficiencyTool_trkJet", "The BTaggingEfficiencyTool for track jets" );
763 m_btagSelTool_trkJet.declarePropertyFor( this, "BTaggingSelectionTool_trkJet", "The main BTaggingSelectionTool for track jets" );
764 //
765 m_metMaker.declarePropertyFor( this, "METMaker", "The METMaker instance");
766 m_metSystTool.declarePropertyFor( this, "METSystTool", "The METSystematicsTool");
767 m_metSignif.declarePropertyFor( this, "METSignificance", "The METSignifiance instance");
768 //
769 m_trigGlobalEffCorrTool_diLep.declarePropertyFor( this, "TrigGlobalEfficiencyCorrection_diLep", "The TrigGlobalEfficiencyCorrection tool for dilepton" );
770 m_trigGlobalEffCorrTool_multiLep.declarePropertyFor( this, "TrigGlobalEfficiencyCorrection_multiLep", "The TrigGlobalEfficiencyCorrection tool for trilepton" );
771 m_trigGlobalEffCorrTool_diPhoton.declarePropertyFor( this, "TrigGlobalEfficiencyCorrection_diPhoton", "The TrigGlobalEfficiencyCorrection tool for asymmetric diphoton" );
772 m_trigConfTool.declarePropertyFor( this, "TrigConfigTool", "The TrigConfigTool" );
773 m_trigDecTool.declarePropertyFor( this, "TrigDecisionTool", "The TrigDecisionTool" );
774 m_trigMatchingTool.declarePropertyFor( this, "TrigMatchTool", "The TrigMatchingTool" );
775 m_trigMatchScoringTool.declarePropertyFor( this, "TrigMatchScoringTool", "The TrigMatchScoringTool" );
776 m_trigDRScoringTool.declarePropertyFor( this, "TrigDRScoringTool", "The TrigDRScoringTool" );
777 //
778 m_isoCorrTool.declarePropertyFor( this, "IsolationCorrectionTool", "The IsolationCorrectionTool" );
779 m_isoTool.declarePropertyFor( this, "IsolationSelectionTool", "The IsolationSelectionTool");
780 //disable m_isoToolLowPtPLV.declarePropertyFor( this, "IsolationLowPtPLVTool", "The IsolationLowPtPLVTool");
781 m_isoBaselineTool.declarePropertyFor( this, "IsolationSelectionTool_Baseline", "The IsolationSelectionTool for baseline objects");
782 m_isoHighPtTool.declarePropertyFor( this, "IsolationSelectionTool_HighPt", "The IsolationSelectionTool for High Pt");
783 m_isoCloseByTool.declarePropertyFor( this, "IsolationCloseByCorrectionTool", "The IsolationCloseByCorrectionTool");
784 //
785 m_prwTool.declarePropertyFor( this, "PileupReweightingTool", "The PRW tool" );
786 //
787 m_LRTuncTool.declarePropertyFor( this, "InclusiveTrackFilterTool", "The LRT uncertainty tool");
788 //
789 m_pmgSHnjetWeighter.declarePropertyFor( this, "PMGSHVjetReweightTool", "The PMGSHVjetReweightTool (AntiKt4TruthJets)" );
790 m_pmgSHnjetWeighterWZ.declarePropertyFor( this, "PMGSHVjetReweightWZTool", "The PMGSHVjetReweightTool (AntiKt4TruthWZJets)" );
791 //
792 m_tauJetORtool.declarePropertyFor( this, "TauJetOverlapTool", "The TauJetOverlapTool");
793 //disable m_orToolbox.declarePropertyFor( this, "OverlapRemovalTool", "The overlap removal tool");
794
795 //load supported WPs (by tightness order)
796 m_el_id_support.push_back("VeryLooseNoPix"); // WPs for LRT Electron
797 m_el_id_support.push_back("VeryLooseLLH");
798 m_el_id_support.push_back("LooseNoPix"); // WPs for LRT Electron
799 m_el_id_support.push_back("LooseLLH");
800 m_el_id_support.push_back("LooseAndBLayerLLH");
801 m_el_id_support.push_back("LooseDNNnoCF");
802 m_el_id_support.push_back("LooseDNN");
803 m_el_id_support.push_back("MediumNoPix"); // WPs for LRT Electron
804 m_el_id_support.push_back("MediumLLH");
805 m_el_id_support.push_back("MediumDNNnoCF");
806 m_el_id_support.push_back("MediumDNN");
807 m_el_id_support.push_back("TightNoPix"); // WPs for LRT Electron
808 m_el_id_support.push_back("TightLLH");
809 m_el_id_support.push_back("TightDNNnoCF");
810 m_el_id_support.push_back("TightDNN");
811
812 m_ph_id_support.push_back("Loose");
813 m_ph_id_support.push_back("Medium");
814 m_ph_id_support.push_back("Tight");
815 m_ph_id_support.push_back("TightPtIncl"); // Should not be mixed with Tight
816
817 m_mu_id_support = 4; //maximum value supported
818
819 // Tau ID WPs
820 m_tau_id_support.push_back("001");
821 m_tau_id_support.push_back("VeryLoose");
822 m_tau_id_support.push_back("Loose");
823 m_tau_id_support.push_back("Medium");
824 m_tau_id_support.push_back("Tight");
825
826 // Iso WPs
827 // -- see https://twiki.cern.ch/twiki/bin/view/AtlasProtected/RecommendedIsolationWPs#Current_official_working_points
828 // -- the el iso points are those which have (or will have) SFs available
830 "FCLoose", "FCTight", // current WPs
831 "FCHighPtCaloOnly", // current HighPtCaloOnly WPs
832 "Gradient", //
833 "HighPtCaloOnly", //
834 "TightTrackOnly_VarRad","TightTrackOnly_FixedRad",//
835 "Tight_VarRad","Loose_VarRad", //
836 "PLVLoose", "PLVTight", // PLV recommended WPs, fallback support below b/o SFs and & egamma map file
837 "PLImprovedTight", "PLImprovedVeryTight" // New PLIV WPs, fallback support below b/o SFs & egamma map file
838 };
839 // -- the muon iso points are those which have SFs available
840 // -- more details https://indico.cern.ch/event/878781/contributions/3721998/attachments/1976194/3289315/20200127_IFFshort_2.pdf
842 "PflowLoose_FixedRad", "PflowLoose_VarRad", "PflowTight_FixedRad", "PflowTight_VarRad", // PFlow (new naming) recommended WPs
843 "TightTrackOnly_FixedRad", "TightTrackOnly_VarRad", "HighPtTrackOnly", // TrackOnly (new naming) recommended WPs
844 "PLVLoose", "PLVTight", // PLV recommended WPs
845 "Loose_VarRad", "Loose_FixedRad", "Tight_VarRad", "Tight_FixedRad", // Other WPs (new naming)
846 "PLImprovedTight", "PLImprovedVeryTight" // New PLIV WPs, fallback support below b/o SFs
847 };
848
849 // Construct electron fallback WPs for SFs
850 for (const auto& x : m_el_iso_support) { m_el_iso_fallback[x] = x; } // all current WPs
851 m_el_iso_fallback["PLVTight"] = "FCTight"; // plus actual fallback
852 m_el_iso_fallback["PLVLoose"] = "FCLoose";
853 m_el_iso_fallback["PLImprovedTight"] = "FCTight";
854 m_el_iso_fallback["PLImprovedVeryTight"] = "FCTight";
855 m_el_iso_fallback["HighPtCaloOnly"] = "FCHighPtCaloOnly";
856 m_el_iso_fallback["TightTrackOnly_VarRad"] = "FCTight";
857 m_el_iso_fallback["TightTrackOnly_FixedRad"] = "FCTight";
858 m_el_iso_fallback["Tight_VarRad"] = "FCTight";
859 m_el_iso_fallback["Loose_VarRad"] = "FCLoose";
860
861 // Construct muon fallback WPs for SFs
863 m_mu_iso_fallback["PLImprovedTight"] = "PLVTight";
864 m_mu_iso_fallback["PLImprovedVeryTight"] = "PLVTight";
865
866 // Construct tau fallback WPs for GNTau --> RNN ID SFs
868 m_tau_id_fallback[10] = 6; // VeryLoose
869 m_tau_id_fallback[11] = 7; // Loose
870 m_tau_id_fallback[12] = 8; // Medium
871 m_tau_id_fallback[13] = 9; // Tight
872}
#define x
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
asg::AnaToolHandle< TauAnalysisTools::ITauSelectionTool > m_tauSelToolBaseline
std::vector< std::string > m_ph_id_support
bool m_metRemoveOverlappingCaloTaggedMuons
std::string m_BtagWP_trkJet
std::string m_tauConfigPath
asg::AnaToolHandle< IWeightTool > m_pmgSHnjetWeighter
std::string m_JetTruthLabelName
asg::AnaToolHandle< ICPJetUncertaintiesTool > m_WTagjetUncertaintiesTool
asg::AnaToolHandle< CP::IElectronLRTOverlapRemovalTool > m_elecLRTORTool
std::vector< std::string > m_mu_iso_support
std::vector< std::string > m_el_id_support
asg::AnaToolHandle< Trig::TrigDecisionTool > m_trigDecTool
asg::AnaToolHandle< CP::IMuonSelectionTool > m_muonSelectionTool
std::string m_trig2017combination_singleLep
asg::AnaToolHandle< IWeightTool > m_pmgSHnjetWeighterWZ
std::string m_prwActualMu2018File
asg::AnaToolHandle< ICPJetUncertaintiesTool > m_ZTagjetUncertaintiesTool
std::string m_autoconfigPRWPath
std::string m_trig2017combination_diPhoton
std::string m_trig2018combination_singleLep
std::string m_trig2016combination_multiLep
std::string m_photonIdBaseline
std::string m_prwActualMu2025File
asg::AnaToolHandle< IJetCalibrationTool > m_jetFatCalibTool
std::string m_trig2016combination_diPhoton
asg::AnaToolHandle< ITrigGlobalEfficiencyCorrectionTool > m_trigGlobalEffCorrTool_multiLep
asg::AnaToolHandle< CP::IIsolationSelectionTool > m_isoBaselineTool
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > m_elecEfficiencySFTool_isoHighPt
asg::AnaToolHandle< CP::IMuonEfficiencyScaleFactors > m_muonEfficiencySFTool
std::string m_prwActualMu2022File
asg::AnaToolHandle< CP::IPileupReweightingTool > m_prwTool
std::string m_EG_corrFNList
asg::AnaToolHandle< TauAnalysisTools::ITauSelectionTool > m_tauSelTool
asg::AnaToolHandle< ICPJetUncertaintiesTool > m_jetUncertaintiesPDSmearTool
std::string m_autoconfigPRWRtags
std::string m_trig2024combination_singleLep
asg::AnaToolHandle< IAsgElectronLikelihoodTool > m_elecSelLikelihood
double m_orBoostedElectronMaxConeSize
std::vector< std::string > m_prwLcalcFiles
std::string m_metsysConfigPrefix
asg::AnaToolHandle< TauAnalysisTools::ITauEfficiencyCorrectionsTool > m_tauEffTool
std::string m_trig2016combination_singleLep
std::string m_trigMatchingPrefix
Use composite trigger matching tool if matching was done upstream.
asg::AnaToolHandle< CP::IIsolationSelectionTool > m_isoHighPtTool
std::string m_commonPRWFileMC20d
std::map< std::string, bool > m_slices
std::string m_commonPRWFileMC23g
asg::AnaToolHandle< ITrigGlobalEfficiencyCorrectionTool > m_trigGlobalEffCorrTool_diPhoton
asg::AnaToolHandle< IAsgElectronLikelihoodTool > m_elecSelLikelihoodBaseline
asg::AnaToolHandle< IAsgPhotonIsEMSelector > m_photonSelIsEM
SG::ConstAccessor< char > m_acc_photonId
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > m_elecEfficiencySFTool_id
asg::AnaToolHandle< CP::IMuonEfficiencyScaleFactors > m_muonTTVAEfficiencySFTool
std::string m_ZTagUncConfig
asg::AnaToolHandle< ICPJetCorrectionTool > m_fatjetFFSmearingTool
std::string m_eleEffMapFilePath
std::string m_WZTaggerCalibArea
std::string m_trig2015combination_singleLep
std::string m_EigenvectorReductionB
asg::AnaToolHandle< IMETSignificance > m_metSignif
asg::AnaToolHandle< CP::IIsolationSelectionTool > m_isoTool
asg::AnaToolHandle< CP::IJvtEfficiencyTool > m_jetfJvtEfficiencyTool
SG::ConstAccessor< char > m_acc_eleId
std::string m_prwActualMu2024File
std::string m_metJetSelection
std::vector< std::string > m_el_iso_support
std::string m_trig2017combination_multiLep
asg::AnaToolHandle< Trig::IMatchingTool > m_trigMatchingTool
std::string m_photonBaselineIso_WP
asg::AnaToolHandle< IAsgElectronLikelihoodTool > m_elecChargeIDSelectorTool
std::string m_BtagSystStrategy
std::string m_commonPRWFileMC20e
asg::AnaToolHandle< JetPileupLabelingTool > m_jetPileupLabelingTool
std::string m_trig2023combination_singleLep
asg::AnaToolHandle< CP::IMuonLRTOverlapRemovalTool > m_muonLRTORTool
SG::ConstAccessor< char > m_acc_photonIdBaseline
asg::AnaToolHandle< JSSWTopTaggerDNN > m_TopTaggerTool
asg::AnaToolHandle< CP::IMuonTriggerScaleFactors > m_muonTriggerSFTool
std::vector< std::string > m_tau_id_support
std::string m_tauEffToolRecommendationTag
std::string m_muBaselineIso_WP
std::string m_TopTaggerCalibArea
std::string m_trig2015combination_diLep
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > m_elecEfficiencySFTool_trigEff_singleLep
std::string m_photonTriggerName
asg::AnaToolHandle< IAsgSelectionTool > m_jetNNJvtSelectionTool
asg::AnaToolHandle< SmoothedWZTagger > m_ZTaggerTool
asg::AnaToolHandle< JetPileupTag::JetVertexNNTagger > m_jetNNJvtMomentTool
std::string m_fJvtConfigRun3
std::string m_eleIdBaseline
std::map< std::string, std::string > m_el_iso_fallback
CP::SystematicSet m_currentSyst
asg::AnaToolHandle< CP::IMuonEfficiencyScaleFactors > m_muonEfficiencyBMHighPtSFTool
asg::AnaToolHandle< ORUtils::IOverlapTool > m_tauJetORtool
std::string m_commonPRWFileMC23d
std::string m_muIsoHighPt_WP
std::string m_commonPRWFileMC23e
asg::AnaToolHandle< CP::IMuonCalibrationAndSmearingTool > m_muonCalibTool
std::string m_fJvtConfigRun2
asg::AnaToolHandle< JetVertexTaggerTool > m_jetJvtMomentTool
asg::AnaToolHandle< ICPJetUncertaintiesTool > m_jetUncertaintiesTool
std::string m_tauSmearingToolRecommendationTag
asg::AnaToolHandle< IEGammaAmbiguityTool > m_egammaAmbiguityTool
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > m_elecChargeEffCorrTool
asg::AnaToolHandle< TrigConf::ITrigConfigTool > m_trigConfTool
std::string m_WTagUncConfig
asg::AnaToolHandle< CP::IIsolationCloseByCorrectionTool > m_isoCloseByTool
std::map< int, int > m_tau_id_fallback
std::string m_tauIdBaseline
std::string m_eleIsoHighPt_WP
asg::AnaToolHandle< IMETMaker > m_metMaker
asg::AnaToolHandle< Trig::IMatchScoringTool > m_trigDRScoringTool
asg::AnaToolHandle< IAsgPhotonEfficiencyCorrectionTool > m_photonIsolationSFTool
bool m_orDoTau
Overlap removal options.
std::string m_trig2016combination_diLep
std::string m_JvtConfigRun2
asg::AnaToolHandle< ICPJetUncertaintiesTool > m_fatjetUncertaintiesTool
asg::AnaToolHandle< CP::IIsolationCorrectionTool > m_isoCorrTool
std::string m_eleConfigBaseline
std::string m_trig2022combination_singleLep
asg::AnaToolHandle< IMETSystematicsTool > m_metSystTool
asg::AnaToolHandle< CP::IMuonSelectionTool > m_muonSelectionHighPtTool
std::string m_EigenvectorReductionLight
asg::AnaToolHandle< IAsgSelectionTool > m_jetfJvtSelectionTool
std::string m_trig2018combination_diPhoton
asg::AnaToolHandle< IJetSelector > m_jetCleaningTool
asg::AnaToolHandle< IBTaggingSelectionTool > m_btagSelTool_trkJet
asg::AnaToolHandle< InDet::IInclusiveTrackFilterTool > m_LRTuncTool
asg::AnaToolHandle< CP::IJvtEfficiencyTool > m_jetNNJvtEfficiencyTool
std::string m_commonPRWFileMC20a
std::string m_trig2022combination_diLep
asg::AnaToolHandle< CP::IMuonEfficiencyScaleFactors > m_muonHighPtIsolationSFTool
asg::AnaToolHandle< TauAnalysisTools::ITauSmearingTool > m_tauSmearingTool
SG::ConstAccessor< char > m_acc_eleIdBaseline
std::string m_trig2018combination_diLep
std::string m_trig2017combination_diLep
asg::AnaToolHandle< ITrigGlobalEfficiencyCorrectionTool > m_trigGlobalEffCorrTool_diLep
asg::AnaToolHandle< IBTaggingEfficiencyTool > m_btagEffTool_trkJet
std::string m_prwActualMu2017File
std::vector< std::string > m_prwConfFiles
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > m_elecEfficiencySFTool_reco
Combined muon collection.
asg::AnaToolHandle< ICPJetUncertaintiesTool > m_TopTagjetUncertaintiesTool
std::vector< CP::SystematicSet > m_fatjetFFSmearingSyst
asg::AnaToolHandle< IBTaggingEfficiencyTool > m_btagEffTool
asg::AnaToolHandle< TauAnalysisTools::ITauTruthMatchingTool > m_tauTruthMatch
asg::AnaToolHandle< IBTaggingSelectionTool > m_btagSelTool_OR
std::string m_muTriggerSFCalibRelease
std::string m_tauConfigPathBaseline
std::map< std::string, std::string > m_mu_iso_fallback
asg::AnaToolHandle< IAsgPhotonIsEMSelector > m_photonSelIsEMBaseline
std::string m_inputMETSuffix
asg::AnaToolHandle< IBTaggingSelectionTool > m_btagSelTool
SG::ConstAccessor< char > m_acc_jetClean
asg::AnaToolHandle< IAsgPhotonEfficiencyCorrectionTool > m_photonTriggerSFTool
std::string m_EigenvectorReductionC
std::string m_fatJetUncConfig
ORUtils::ToolBox m_orToolbox
std::string m_TopTagUncConfig
std::string m_tauInputFileBaseline
asg::AnaToolHandle< Trig::IMatchScoringTool > m_trigMatchScoringTool
asg::AnaToolHandle< CP::IMuonSelectionTool > m_muonSelectionToolBaseline
std::string m_trig2022combination_multiLep
std::string m_muTriggerSFCalibFilename
asg::AnaToolHandle< CP::IEgammaCalibrationAndSmearingTool > m_egammaCalibTool
Combined electron collection.
std::string m_IsoCloseByORpassLabel
std::string m_trig2015combination_multiLep
std::string m_trig2022combination_diPhoton
std::string m_prwActualMu2023File
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > m_elecEfficiencySFTool_trig_singleLep
asg::AnaToolHandle< JetTruthLabelingTool > m_jetTruthLabelingTool
asg::AnaToolHandle< ICPJetUncertaintiesTool > m_fatjetUncertaintiesPDSmearTool
std::string m_autoconfigPRWFile
std::string m_bTaggingCalibrationFilePath
asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > m_elecEfficiencySFTool_iso
asg::AnaToolHandle< SmoothedWZTagger > m_WTaggerTool
std::string m_commonPRWFileMC23a
asg::AnaToolHandle< IJetCalibrationTool > m_jetCalibTool
std::string m_eleBaselineIso_WP
std::string m_fatJetUncVars
std::string m_electronTriggerSFStringSingle
std::string m_trig2015combination_diPhoton
asg::AnaToolHandle< CP::IMuonEfficiencyScaleFactors > m_muonIsolationSFTool
std::string m_BtagTagger_trkJet
std::string m_trig2018combination_multiLep
asg::AnaToolHandle< IAsgPhotonEfficiencyCorrectionTool > m_photonEfficiencySFTool
std::string m_JvtConfigRun3

◆ ~SUSYObjDef_xAOD()

ST::SUSYObjDef_xAOD::~SUSYObjDef_xAOD ( )

Definition at line 3190 of file SUSYObjDef_xAOD.cxx.

3190 {
3191
3192#ifdef XAOD_STANDALONE
3193 // remove all tools from the asg::ToolStore (and delete them)
3194 // so that they don't get re-used if we set up another SUSYTools
3195 // instance, e.g. when processing two datasets in one EventLoop
3196 // job
3197 if (!m_trigDecTool.empty()){
3198 if (asg::ToolStore::contains<Trig::TrigDecisionTool>("ToolSvc.TrigDecisionTool") ){
3199 // Ignore both of these so that we are safe if others have cleaned up
3200 m_trigDecTool->finalize().ignore();
3201 asg::ToolStore::remove("ToolSvc.TrigDecisionTool").ignore();
3202 }
3203 }
3204#endif
3205}
static bool contains(const std::string &name)
Check whether a tool with a given type and name is known in the store.
Definition ToolStore.h:51
static StatusCode remove(const IAsgTool *tool)
Remove the specified tool from the store.
Definition ToolStore.cxx:77

Member Function Documentation

◆ ApplyLRTUncertainty()

StatusCode ST::SUSYObjDef_xAOD::ApplyLRTUncertainty ( )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 3155 of file SUSYObjDef_xAOD.cxx.

3155 {
3156
3157 // Don't apply variations for data
3158 if (isData()) return StatusCode::SUCCESS;
3159
3160 const EventContext& ctx = Gaudi::Hive::currentContext();
3161
3162 // Loop over tracks and call LRT uncertainty tool
3163 ATH_MSG_DEBUG ( "Applying LRT filter tool decorations for uncertainty");
3165 for(const auto* trk: inTracks) dec_lrtFilter(*trk) = m_LRTuncTool->accept(trk);
3166
3167 // Loop over GSF LRT tracks and call uncertainty tool
3169 for(const auto* trk: inGSFTracks) dec_lrtFilter(*trk) = m_LRTuncTool->accept(trk);
3170
3171 return StatusCode::SUCCESS;
3172}
#define ATH_MSG_DEBUG(x)
bool isData() const override final
const xAOD::TrackParticleContainer & GetInDetLargeD0GSFTracks(const EventContext &ctx) const override final
const xAOD::TrackParticleContainer & GetInDetLargeD0Tracks(const EventContext &ctx) const override final
static const SG::Decorator< char > dec_lrtFilter("passLRTFilter")
TrackParticleContainer_v1 TrackParticleContainer
Definition of the current "TrackParticle container version".

◆ ApplyPRWTool()

StatusCode ST::SUSYObjDef_xAOD::ApplyPRWTool ( bool muDependentRRN = true)
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 3110 of file SUSYObjDef_xAOD.cxx.

3110 {
3111
3112 const xAOD::EventInfo* evtInfo = GetEventInfo();
3113 if(!randomrunnumber.isAvailable(*evtInfo))
3114 ATH_CHECK( m_prwTool->apply( *evtInfo, muDependentRRN ) );
3115 return StatusCode::SUCCESS;
3116}
#define ATH_CHECK
Evaluate an expression and check for errors.
bool isAvailable(const ELT &e) const
Test to see if this variable exists in the store.
const xAOD::EventInfo * GetEventInfo() const override final
static const SG::ConstAccessor< unsigned int > randomrunnumber("RandomRunNumber")
EventInfo_v1 EventInfo
Definition of the latest event info version.

◆ applySystematicVariation()

StatusCode ST::SUSYObjDef_xAOD::applySystematicVariation ( const CP::SystematicSet & systConfig)
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 2201 of file SUSYObjDef_xAOD.cxx.

2202{
2203 if (!m_tool_init) {
2204 ATH_MSG_ERROR("SUSYTools was not initialized!!");
2205 return StatusCode::FAILURE;
2206 }
2207
2208 ATH_MSG_DEBUG(" in SUSYObjDef_xAOD::applySystematicVariation \"" << systConfig.name() << "\" size " << systConfig.size());
2209
2210 m_currentSyst = systConfig;
2211
2212 // NB: SystematicSet typically has only one component (see SUSYToolsTester macro)
2213 if (!m_jetUncertaintiesTool.empty() && systConfig.name().find("PseudoData") == std::string::npos) {
2214 StatusCode ret = m_jetUncertaintiesTool->applySystematicVariation(systConfig);
2215 if ( ret != StatusCode::SUCCESS) {
2216 ATH_MSG_VERBOSE("Cannot configure JetUncertaintiesTool for systematic var. " << systConfig.name() );
2217 } else {
2218 ATH_MSG_VERBOSE("Configured JetUncertaintiesTool for systematic var. " << systConfig.name() );
2219 }
2220 }
2221 if (!m_jetUncertaintiesPDSmearTool.empty() && systConfig.name().find("PseudoData") != std::string::npos) {
2222 StatusCode ret = m_jetUncertaintiesPDSmearTool->applySystematicVariation(systConfig);
2223 if ( ret != StatusCode::SUCCESS) {
2224 ATH_MSG_VERBOSE("Cannot configure JetUncertaintiesPDSmearTool for systematic var. " << systConfig.name() );
2225 } else {
2226 ATH_MSG_VERBOSE("Configured JetUncertaintiesPDSmearTool for systematic var. " << systConfig.name() );
2227 }
2228 }
2229 if (!m_WTagjetUncertaintiesTool.empty() && !m_WTagUncConfig.empty()) {
2230 StatusCode ret = m_WTagjetUncertaintiesTool->applySystematicVariation(systConfig);
2231 if ( ret != StatusCode::SUCCESS) {
2232 ATH_MSG_VERBOSE("Cannot configure (Fat)JetUncertaintiesTool (WTag) for systematic var. " << systConfig.name() );
2233 } else {
2234 ATH_MSG_VERBOSE("Configured (Fat)JetUncertaintiesTool (WTag) for systematic var. " << systConfig.name() );
2235 }
2236 }
2237 if (!m_ZTagjetUncertaintiesTool.empty() && !m_ZTagUncConfig.empty()) {
2238 StatusCode ret = m_ZTagjetUncertaintiesTool->applySystematicVariation(systConfig);
2239 if ( ret != StatusCode::SUCCESS) {
2240 ATH_MSG_VERBOSE("Cannot configure (Fat)JetUncertaintiesTool (ZTag) for systematic var. " << systConfig.name() );
2241 } else {
2242 ATH_MSG_VERBOSE("Configured (Fat)JetUncertaintiesTool (ZTag) for systematic var. " << systConfig.name() );
2243 }
2244 }
2245
2246 if (!m_TopTagjetUncertaintiesTool.empty() && !m_TopTagUncConfig.empty()) {
2247 StatusCode ret = m_TopTagjetUncertaintiesTool->applySystematicVariation(systConfig);
2248 if ( ret != StatusCode::SUCCESS) {
2249 ATH_MSG_VERBOSE("Cannot configure (Fat)JetUncertaintiesTool (TopTag) for systematic var. " << systConfig.name() );
2250 } else {
2251 ATH_MSG_VERBOSE("Configured (Fat)JetUncertaintiesTool (TopTag) for systematic var. " << systConfig.name() );
2252 }
2253 }
2254 if (!m_fatjetUncertaintiesTool.empty() && systConfig.name().find("PseudoData") == std::string::npos) {
2255 StatusCode ret = m_fatjetUncertaintiesTool->applySystematicVariation(systConfig);
2256 if ( ret != StatusCode::SUCCESS) {
2257 ATH_MSG_VERBOSE("Cannot configure (Fat)JetUncertaintiesTool (main) for systematic var. " << systConfig.name() );
2258 } else {
2259 ATH_MSG_VERBOSE("Configured (Fat)JetUncertaintiesTool (main) for systematic var. " << systConfig.name() );
2260 }
2261 }
2262 if (!m_fatjetUncertaintiesPDSmearTool.empty() && systConfig.name().find("PseudoData") != std::string::npos) {
2263 StatusCode ret = m_fatjetUncertaintiesPDSmearTool->applySystematicVariation(systConfig);
2264 if ( ret != StatusCode::SUCCESS) {
2265 ATH_MSG_VERBOSE("Cannot configure FatJetUncertaintiesPDSmearTool for systematic var. " << systConfig.name() );
2266 } else {
2267 ATH_MSG_VERBOSE("Configured FatJetUncertaintiesPDSmearTool for systematic var. " << systConfig.name() );
2268 }
2269 }
2270 if (!m_fatjetFFSmearingTool.empty() && std::find(m_fatjetFFSmearingSyst.begin(), m_fatjetFFSmearingSyst.end(), systConfig) != m_fatjetFFSmearingSyst.end()) {
2271 StatusCode ret = m_fatjetFFSmearingTool->applySystematicVariation(systConfig);
2272 if ( ret != StatusCode::SUCCESS) {
2273 ATH_MSG_VERBOSE("Cannot configure (Fat)JetFFSmearingTool (main) for systematic var. " << systConfig.name() );
2274 } else {
2275 ATH_MSG_VERBOSE("Configured (Fat)JetFFSmearingTool (main) for systematic var. " << systConfig.name() );
2276 }
2277 }
2278 if (!m_jetNNJvtEfficiencyTool.empty()) {
2279 StatusCode ret = m_jetNNJvtEfficiencyTool->applySystematicVariation(systConfig);
2280 if ( ret != StatusCode::SUCCESS) {
2281 ATH_MSG_VERBOSE("Cannot configure NNJvtEfficiency for systematic var. " << systConfig.name() );
2282 } else {
2283 ATH_MSG_VERBOSE("Configured NNJvtEfficiency for systematic var. " << systConfig.name() );
2284 }
2285 }
2286 if (!m_jetfJvtEfficiencyTool.empty()) {
2287 StatusCode ret = m_jetfJvtEfficiencyTool->applySystematicVariation(systConfig);
2288 if ( ret != StatusCode::SUCCESS) {
2289 ATH_MSG_VERBOSE("Cannot configure fJvtEfficiency for systematic var. " << systConfig.name() );
2290 } else {
2291 ATH_MSG_VERBOSE("Configured fJvtEfficiency for systematic var. " << systConfig.name() );
2292 }
2293 }
2294 if (!m_muonCalibTool.empty()) {
2295 StatusCode ret = m_muonCalibTool->applySystematicVariation(systConfig);
2296 if (ret != StatusCode::SUCCESS) {
2297 ATH_MSG_ERROR("Cannot configure MuonCalibTool for systematic var. " << systConfig.name() );
2298 return ret;
2299 } else {
2300 ATH_MSG_VERBOSE("MuonCalibTool configured for systematic var. " << systConfig.name() );
2301 }
2302 }
2303 if (!m_muonEfficiencySFTool.empty()) {
2304 StatusCode ret = m_muonEfficiencySFTool->applySystematicVariation(systConfig);
2305 if ( ret != StatusCode::SUCCESS) {
2306 ATH_MSG_ERROR("Cannot configure MuonEfficiencyScaleFactors for systematic var. " << systConfig.name() );
2307 return ret;
2308 } else {
2309 ATH_MSG_VERBOSE("MuonEfficiencyScaleFactors configured for systematic var. " << systConfig.name() );
2310 }
2311 }
2312 if (!m_muonEfficiencyBMHighPtSFTool.empty()) {
2313 StatusCode ret = m_muonEfficiencyBMHighPtSFTool->applySystematicVariation(systConfig);
2314 if ( ret != StatusCode::SUCCESS) {
2315 ATH_MSG_ERROR("Cannot configure MuonBadMuonHighPtScaleFactors for systematic var. " << systConfig.name() );
2316 return ret;
2317 } else {
2318 ATH_MSG_VERBOSE("MuonBadMuonHighPtScaleFactors configured for systematic var. " << systConfig.name() );
2319 }
2320 }
2321 if (!m_muonTTVAEfficiencySFTool.empty()) {
2322 StatusCode ret = m_muonTTVAEfficiencySFTool->applySystematicVariation(systConfig);
2323 if ( ret != StatusCode::SUCCESS) {
2324 ATH_MSG_ERROR("Cannot configure MuonTTVAEfficiencyScaleFactors for systematic var. " << systConfig.name() );
2325 return ret;
2326 } else {
2327 ATH_MSG_VERBOSE("MuonTTVAEfficiencyScaleFactors configured for systematic var. " << systConfig.name() );
2328 }
2329 }
2330 if (!m_muonIsolationSFTool.empty()) {
2331 StatusCode ret = m_muonIsolationSFTool->applySystematicVariation(systConfig);
2332 if ( ret != StatusCode::SUCCESS) {
2333 ATH_MSG_ERROR("Cannot configure MuonIsolationScaleFactors for systematic var. " << systConfig.name() );
2334 return ret;
2335 } else {
2336 ATH_MSG_VERBOSE("MuonIsolationScaleFactors configured for systematic var. " << systConfig.name() );
2337 }
2338 }
2339 if (!m_muonTriggerSFTool.empty()) {
2340 StatusCode ret = m_muonTriggerSFTool->applySystematicVariation(systConfig);
2341 if ( ret != StatusCode::SUCCESS) {
2342 ATH_MSG_ERROR("Cannot configure MuonTriggerScaleFactors for systematic var. " << systConfig.name() );
2343 return ret;
2344 } else {
2345 ATH_MSG_VERBOSE("MuonTriggerScaleFactors configured for systematic var. " << systConfig.name() );
2346 }
2347 }
2348 if (!m_elecEfficiencySFTool_reco.empty()) {
2349 StatusCode ret = m_elecEfficiencySFTool_reco->applySystematicVariation(systConfig);
2350 if (ret != StatusCode::SUCCESS) {
2351 ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (reco) for systematic var. " << systConfig.name() );
2352 return ret;
2353 } else {
2354 ATH_MSG_VERBOSE("AsgElectronEfficiencyCorrectionTool (reco) configured for systematic var. " << systConfig.name() );
2355 }
2356 }
2357 if (!m_elecEfficiencySFTool_id.empty()) {
2358 StatusCode ret = m_elecEfficiencySFTool_id->applySystematicVariation(systConfig);
2359 if (ret != StatusCode::SUCCESS) {
2360 ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (id) for systematic var. " << systConfig.name() );
2361 return ret;
2362 } else {
2363 ATH_MSG_VERBOSE("AsgElectronEfficiencyCorrectionTool (id) configured for systematic var. " << systConfig.name() );
2364 }
2365 }
2367 StatusCode ret = m_elecEfficiencySFTool_trig_singleLep->applySystematicVariation(systConfig);
2368 if (ret != StatusCode::SUCCESS) {
2369 ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (trigger) for systematic var. " << systConfig.name() );
2370 return ret;
2371 } else {
2372 ATH_MSG_VERBOSE("AsgElectronEfficiencyCorrectionTool (trigger) configured for systematic var. " << systConfig.name() );
2373 }
2374 }
2376 StatusCode ret = m_elecEfficiencySFTool_trigEff_singleLep->applySystematicVariation(systConfig);
2377 if (ret != StatusCode::SUCCESS) {
2378 ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (trigger SFTool) for systematic var. " << systConfig.name() );
2379 return ret;
2380 } else {
2381 ATH_MSG_VERBOSE("AsgElectronEfficiencyCorrectionTool (trigger SFTool) configured for systematic var. " << systConfig.name() );
2382 }
2383 }
2384 if (!m_trigGlobalEffCorrTool_diLep.empty()) {
2385 StatusCode ret = m_trigGlobalEffCorrTool_diLep->applySystematicVariation(systConfig);
2386 for(auto &sfop : m_elecTrigEffTools){
2387 StatusCode ret1 = sfop->applySystematicVariation(systConfig);
2388 if (ret1 != StatusCode::SUCCESS) { ATH_MSG_ERROR("Cannot configure m_elecTrigEffTools (dilepton trigger) for systematic var. " << systConfig.name() ); return ret1; }
2389 }
2390 for(auto &sfop : m_elecTrigSFTools){
2391 StatusCode ret1 = sfop->applySystematicVariation(systConfig);
2392 if (ret1 != StatusCode::SUCCESS) { ATH_MSG_ERROR("Cannot configure m_elecTrigSFTools (dilepton trigger) for systematic var. " << systConfig.name() ); return ret1; }
2393 }
2394 for(auto &sfop : m_muonTrigSFTools){
2395 StatusCode ret1 = sfop->applySystematicVariation(systConfig);
2396 if (ret1 != StatusCode::SUCCESS) { ATH_MSG_ERROR("Cannot configure m_muonTrigSFTools (dilepton trigger) for systematic var. " << systConfig.name() ); return ret1; }
2397 }
2398 if (ret != StatusCode::SUCCESS) {
2399 ATH_MSG_ERROR("Cannot configure TrigGlobalEfficiencyCorrectionTool (dilepton trigger) for systematic var. " << systConfig.name() );
2400 return ret;
2401 } else {
2402 ATH_MSG_VERBOSE("TrigGlobalEfficiencyCorrectionTool (dilepton trigger) configured for systematic var. " << systConfig.name() );
2403 }
2404 }
2405 if (!m_trigGlobalEffCorrTool_multiLep.empty()) {
2406 StatusCode ret = m_trigGlobalEffCorrTool_multiLep->applySystematicVariation(systConfig);
2407 for(auto &sfop : m_elecTrigEffTools){
2408 StatusCode ret1 = sfop->applySystematicVariation(systConfig);
2409 if (ret1 != StatusCode::SUCCESS) { ATH_MSG_ERROR("Cannot configure m_elecTrigEffTools (multilep trigger) for systematic var. " << systConfig.name() ); return ret1; }
2410 }
2411 for(auto &sfop : m_elecTrigSFTools){
2412 StatusCode ret1 = sfop->applySystematicVariation(systConfig);
2413 if (ret1 != StatusCode::SUCCESS) { ATH_MSG_ERROR("Cannot configure m_elecTrigSFTools (multilep trigger) for systematic var. " << systConfig.name() ); return ret1; }
2414 }
2415 for(auto &sfop : m_muonTrigSFTools){
2416 StatusCode ret1 = sfop->applySystematicVariation(systConfig);
2417 if (ret1 != StatusCode::SUCCESS) { ATH_MSG_ERROR("Cannot configure m_muonTrigSFTools (multilep trigger) for systematic var. " << systConfig.name() ); return ret1; }
2418 }
2419 if (ret != StatusCode::SUCCESS) {
2420 ATH_MSG_ERROR("Cannot configure TrigGlobalEfficiencyCorrectionTool (multi-lepton trigger) for systematic var. " << systConfig.name() );
2421 return ret;
2422 } else {
2423 ATH_MSG_VERBOSE("TrigGlobalEfficiencyCorrectionTool (multi-lepton trigger) configured for systematic var. " << systConfig.name() );
2424 }
2425 }
2426 if (!m_elecEfficiencySFTool_iso.empty()) {
2427 StatusCode ret = m_elecEfficiencySFTool_iso->applySystematicVariation(systConfig);
2428 if (ret != StatusCode::SUCCESS) {
2429 ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (iso) for systematic var. " << systConfig.name() );
2430 return ret;
2431 } else {
2432 ATH_MSG_VERBOSE("AsgElectronEfficiencyCorrectionTool (iso) configured for systematic var. " << systConfig.name() );
2433 }
2434 }
2435 if (!m_elecEfficiencySFTool_isoHighPt.empty()) {
2436 StatusCode ret = m_elecEfficiencySFTool_isoHighPt->applySystematicVariation(systConfig);
2437 if (ret != StatusCode::SUCCESS) {
2438 ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (iso high-pt) for systematic var. " << systConfig.name() );
2439 return ret;
2440 } else {
2441 ATH_MSG_VERBOSE("AsgElectronEfficiencyCorrectionTool (iso high-pt) configured for systematic var. " << systConfig.name() );
2442 }
2443 }
2444 if (!m_elecChargeEffCorrTool.empty()) {
2445 StatusCode ret = m_elecChargeEffCorrTool->applySystematicVariation(systConfig);
2446 if (ret != StatusCode::SUCCESS) {
2447 ATH_MSG_ERROR("Cannot configure ElectronChargeEffCorrectionTool for systematic var. " << systConfig.name() );
2448 return ret;
2449 } else {
2450 ATH_MSG_VERBOSE("ElectronChargeEffCorrectionTool configured for systematic var. " << systConfig.name() );
2451 }
2452 }
2453 if (!isData() && !m_photonEfficiencySFTool.empty()) {
2454 StatusCode ret = m_photonEfficiencySFTool->applySystematicVariation(systConfig);
2455 if (ret != StatusCode::SUCCESS) {
2456 ATH_MSG_ERROR("Cannot configure AsgPhotonEfficiencyCorrectionTool (reco) for systematic var. " << systConfig.name() );
2457 return ret;
2458 } else {
2459 ATH_MSG_VERBOSE("AsgPhotonEfficiencyCorrectionTool (reco) configured for systematic var. " << systConfig.name() );
2460 }
2461 }
2462 if (!isData() && !m_photonIsolationSFTool.empty()) {
2463 StatusCode ret = m_photonIsolationSFTool->applySystematicVariation(systConfig);
2464 if (ret != StatusCode::SUCCESS) {
2465 ATH_MSG_ERROR("Cannot configure AsgPhotonEfficiencyCorrectionTool (iso) for systematic var. " << systConfig.name() );
2466 return ret;
2467 } else {
2468 ATH_MSG_VERBOSE("AsgPhotonEfficiencyCorrectionTool configured (iso) for systematic var. " << systConfig.name() );
2469 }
2470 }
2471 if (!isData() && !m_photonTriggerSFTool.empty()) {
2472 StatusCode ret = m_photonTriggerSFTool->applySystematicVariation(systConfig);
2473 if (ret != StatusCode::SUCCESS) {
2474 ATH_MSG_ERROR("Cannot configure AsgPhotonEfficiencyCorrectionTool (trigger) for systematic var. " << systConfig.name() );
2475 return ret;
2476 } else {
2477 ATH_MSG_VERBOSE("AsgPhotonEfficiencyCorrectionTool configured (trigger) for systematic var. " << systConfig.name() );
2478 }
2479 }
2480 if (!m_trigGlobalEffCorrTool_diPhoton.empty()) {
2481 StatusCode ret = m_trigGlobalEffCorrTool_diPhoton->applySystematicVariation(systConfig);
2482 for(auto &sfop : m_photonTrigEffTools){
2483 StatusCode ret1 = sfop->applySystematicVariation(systConfig);
2484 if (ret1 != StatusCode::SUCCESS) { ATH_MSG_ERROR("Cannot configure m_photonTrigEffTools (diphoton trigger) for systematic var. " << systConfig.name() ); return ret1; }
2485 }
2486 for(auto &sfop : m_photonTrigSFTools){
2487 StatusCode ret1 = sfop->applySystematicVariation(systConfig);
2488 if (ret1 != StatusCode::SUCCESS) { ATH_MSG_ERROR("Cannot configure m_photonTrigSFTools (diphoton trigger) for systematic var. " << systConfig.name() ); return ret1; }
2489 }
2490 if (ret != StatusCode::SUCCESS) {
2491 ATH_MSG_ERROR("Cannot configure TrigGlobalEfficiencyCorrectionTool (diphoton trigger) for systematic var. " << systConfig.name() );
2492 return ret;
2493 } else {
2494 ATH_MSG_VERBOSE("TrigGlobalEfficiencyCorrectionTool (diphoton trigger) configured for systematic var. " << systConfig.name() );
2495 }
2496 }
2497 if (!m_egammaCalibTool.empty()) {
2498 StatusCode ret = m_egammaCalibTool->applySystematicVariation(systConfig);
2499 if (ret != StatusCode::SUCCESS) {
2500 ATH_MSG_ERROR("Cannot configure EgammaCalibrationAndSmearingTool for systematic var. " << systConfig.name() );
2501 return ret;
2502 } else {
2503 ATH_MSG_VERBOSE("EgammaCalibrationAndSmearingTool configured for systematic var. " << systConfig.name() );
2504 }
2505 }
2506 if (!m_isoCorrTool.empty()) {
2507 StatusCode ret = m_isoCorrTool->applySystematicVariation(systConfig);
2508 if (ret != StatusCode::SUCCESS) {
2509 ATH_MSG_ERROR("Cannot configure IsolationCorrectionTool for systematic var. " << systConfig.name() );
2510 return ret;
2511 } else {
2512 ATH_MSG_VERBOSE("IsolationCorrectionTool configured for systematic var. " << systConfig.name() );
2513 }
2514 }
2515 if (!m_btagEffTool.empty()) {
2516 //if ( systConfig.size() > 0 && m_btagEffTool->isAffectedBySystematic(*systConfig.begin()) ) {
2517 StatusCode ret = m_btagEffTool->applySystematicVariation(systConfig);
2518 if ( ret != StatusCode::SUCCESS) {
2519 ATH_MSG_ERROR("Cannot configure xAODBTaggingEfficiency for systematic var. " << systConfig.name() );
2520 return ret;
2521 } else {
2522 ATH_MSG_VERBOSE("Configured xAODBTaggingEfficiency for systematic var. " << systConfig.name() );
2523 }
2524 //}
2525 }
2526 if (!m_btagEffTool_trkJet.empty()) {
2527 StatusCode ret = m_btagEffTool_trkJet->applySystematicVariation(systConfig);
2528 if ( ret != StatusCode::SUCCESS) {
2529 ATH_MSG_ERROR("Cannot configure xAODBTaggingEfficiency (track jets) for systematic var. " << systConfig.name() );
2530 return ret;
2531 } else {
2532 ATH_MSG_VERBOSE("Configured xAODBTaggingEfficiency (track jets) for systematic var. " << systConfig.name() );
2533 }
2534 }
2535 if (!m_tauSmearingTool.empty()) {
2536 StatusCode ret = m_tauSmearingTool->applySystematicVariation(systConfig);
2537 if ( ret != StatusCode::SUCCESS) {
2538 ATH_MSG_ERROR("Cannot configure TauSmearingTool for systematic var. " << systConfig.name() );
2539 return ret;
2540 } else {
2541 ATH_MSG_VERBOSE("Configured TauSmearingTool for systematic var. " << systConfig.name() );
2542 }
2543 }
2544 if (!m_tauEffTool.empty()) {
2545 StatusCode ret = m_tauEffTool->applySystematicVariation(systConfig);
2546 if ( ret != StatusCode::SUCCESS) {
2547 ATH_MSG_ERROR("Cannot configure TauEfficiencyCorrectionsTool for systematic var. " << systConfig.name() );
2548 return ret;
2549 } else {
2550 ATH_MSG_VERBOSE("Configured TauEfficiencyCorrectionsTool for systematic var. " << systConfig.name() );
2551 }
2552 }
2553 for(auto &tool : m_tauTrigEffTool) {
2554 StatusCode ret = tool->applySystematicVariation(systConfig);
2555 if (ret != StatusCode::SUCCESS) {
2556 ATH_MSG_ERROR("Cannot configure " << tool->name() << " for systematic var. " << systConfig.name() );
2557 return ret;
2558 } else {
2559 ATH_MSG_VERBOSE("Configured " << tool->name() << " for systematic var. " << systConfig.name() );
2560 }
2561 }
2562 if (!m_metSystTool.empty()) {
2563 StatusCode ret = m_metSystTool->applySystematicVariation(systConfig);
2564 if ( ret != StatusCode::SUCCESS) {
2565 ATH_MSG_ERROR("Cannot configure METSystematicsTool for systematic var. " << systConfig.name() );
2566 return ret;
2567 } else {
2568 ATH_MSG_VERBOSE("Configured METSystematicsTool for systematic var. " << systConfig.name() );
2569 }
2570 }
2571 if (!m_prwTool.empty()) {
2572 StatusCode ret = m_prwTool->applySystematicVariation(systConfig);
2573 if ( ret != StatusCode::SUCCESS) {
2574 ATH_MSG_ERROR("Cannot configure PileupReweightingTool for systematic var. " << systConfig.name() );
2575 return ret;
2576 } else {
2577 ATH_MSG_VERBOSE("Configured PileupReweightingTool for systematic var. " << systConfig.name() );
2578 }
2579 }
2580
2581 if (!m_LRTuncTool.empty()) {
2582 StatusCode ret = m_LRTuncTool->applySystematicVariation(systConfig);
2583 if ( ret != StatusCode::SUCCESS) {
2584 ATH_MSG_ERROR("Cannot configure InDetTrackFilterTool for systematic var. " << systConfig.name() );
2585 return ret;
2586 } else {
2587 ATH_MSG_VERBOSE("Configured InDetTrackFilterTool for systematic var. " << systConfig.name() );
2588 }
2589 }
2590
2591 return StatusCode::SUCCESS;
2592}
#define ATH_MSG_ERROR(x)
#define ATH_MSG_VERBOSE(x)
std::string name() const
returns: the systematics joined into a single string.
size_t size() const
returns: size of the set
ToolHandleArray< CP::IMuonTriggerScaleFactors > m_muonTrigSFTools
ToolHandleArray< IAsgElectronEfficiencyCorrectionTool > m_elecTrigEffTools
ToolHandleArray< IAsgElectronEfficiencyCorrectionTool > m_elecTrigSFTools
ToolHandleArray< IAsgPhotonEfficiencyCorrectionTool > m_photonTrigSFTools
std::vector< asg::AnaToolHandle< TauAnalysisTools::ITauEfficiencyCorrectionsTool > > m_tauTrigEffTool
ToolHandleArray< IAsgPhotonEfficiencyCorrectionTool > m_photonTrigEffTools
::StatusCode StatusCode
StatusCode definition for legacy code.

◆ autoconfigurePileupRWTool()

StatusCode ST::SUSYObjDef_xAOD::autoconfigurePileupRWTool ( const std::string & PRWfilesDir = "dev/PileupReweighting/share/",
const std::string & PRWfileName = "",
bool usePathResolver = true,
bool RPVLLmode = false,
bool Combinedmode = false,
const std::string & HFFilter = "" )
protected

Definition at line 1029 of file SUSYObjDef_xAOD.cxx.

1029 {
1030
1031 // this will contain the path of the PRW file on /cvmfs which needs to be reverse engineered from the DSID and MC campaign
1032 // the path(s) will be added to m_prwConfFiles which is later used in the configuration of the CP PRW tool
1033 std::string prwConfigFile("");
1034
1035 if ( !isData() && m_autoconfigPRW ) {
1036
1037 prwConfigFile = PRWfilesDir;
1038
1039 float dsid = -999;
1040 std::string amiTag("");
1041 std::string mcCampaignMD("");
1042 std::string simFlavour("");
1043 std::string simType("");
1044 const xAOD::FileMetaData* fmd = nullptr;
1045
1046 // configure PRW rtag options from m_autoconfigPRWRtags string
1047 // e.g. "mc20a:r13167_r14859,mc20d:r13144_r14860,mc20e:r13145_r14861,mc23a:r14622_r14932_r15540,mc23d:r15224_r15530,mc23e:r16083,mc23g:r17610"
1048 std::map<std::string,std::vector<std::string>> PRWRtags = {};
1049 std::string allcampaigns = "mc20a.mc20d.mc20e.mc23a.mc23d.mc23e.mc23g";
1050 bool standard_like = true;
1051 for ( const auto& campaign_rtags : split( m_autoconfigPRWRtags, "," ) ) { // split string by ","
1052 std::string icampaign = campaign_rtags.substr(0, campaign_rtags.find(":")); // first field = campaign, split by ":"
1053 std::vector<std::string> irtags = split( campaign_rtags.substr(campaign_rtags.find(":")+1), "_" ); // remaining fields = rtags, split by "_"
1054 PRWRtags[icampaign] = irtags;
1055 ATH_MSG_DEBUG( "PRW autoconfigure considering rtags " << campaign_rtags.substr(campaign_rtags.find("_")+1) << " for campaign " << icampaign );
1056 }
1057 for ( const auto& x : PRWRtags ) {
1058 if ( allcampaigns.find(x.first)==string::npos ) {
1059 ATH_MSG_ERROR("m_autoconfigPRWRtags contains invalid campaign: " << x.first << " (" << m_autoconfigPRWRtags << ")");
1060 ATH_MSG_ERROR("use any of " << allcampaigns);
1061 return StatusCode::FAILURE;
1062 }
1063 }
1064
1065 // let's use MetaData to extract sample information
1066 if ( inputMetaStore()->contains<xAOD::FileMetaData>("FileMetaData") && inputMetaStore()->retrieve(fmd,"FileMetaData").isSuccess() ) {
1068 fmd->value(xAOD::FileMetaData::amiTag, amiTag);
1069 fmd->value(xAOD::FileMetaData::simFlavour, simFlavour);
1070
1071 if(simFlavour.starts_with("ATLFASTII")) simType = "AFII";
1072 else if(simFlavour.starts_with("ATLFAST3")) simType = "AF3";
1073 else simType = "FS";
1074
1075 bool found = false;
1076 while ( mcCampaignMD.empty() ) {
1077 for ( const auto& campaign_rtags : PRWRtags ) { // consider all campaigns
1078 for ( const auto& rtag: campaign_rtags.second ) { // consider all rtags
1079 if (found) continue;
1080 if (amiTag.find(rtag)!=string::npos) { // find matching tag
1081 mcCampaignMD = campaign_rtags.first.substr(0,5); // save campaign
1082 standard_like = (campaign_rtags.first.find("ns")?true:false); // track non-standard r-tags
1083 found = true; // break if found
1084 }
1085 }
1086 }
1087 // in case not found
1088 if (!found) {
1089 ATH_MSG_ERROR( "autoconfigurePileupRWTool(): unrecognized xAOD::FileMetaData::amiTag, \'" << amiTag << "'. Please check your input sample.");
1090 return StatusCode::FAILURE;
1091 }
1092 //
1093 ATH_MSG_INFO( "Setting up autoconfigurePileupRWTool for mc campaign " << mcCampaignMD << " (from amiTag " << amiTag << ") (standard-like = " << (standard_like?"true":"false") << ")." );
1094 if ( (!standard_like) && (!RPVLLmode) )
1095 ATH_MSG_WARNING("Non-standard r-tag found (" << amiTag.data() << "), but RPVLLmode not set. Perhaps you want to set \"PRW.autoconfigPRWRPVmode: 1\" in the config?");
1096 }
1097 } else {
1098#ifndef XAOD_STANDALONE
1099 ATH_MSG_ERROR( "autoconfigurePileupRWTool(): access to FileMetaData failed, can't get mc channel number.");
1100 return StatusCode::FAILURE;
1101#else
1102
1103 if ( m_mcCampaign == "mc20a" || m_mcCampaign == "mc20d" || m_mcCampaign == "mc20e" || m_mcCampaign == "mc23a" || m_mcCampaign == "mc23d" || m_mcCampaign == "mc23e" || m_mcCampaign == "mc23g") {
1104 // First see if the user set the mcCampaign/run number by property (hopefully temporary workaround)
1105 if ( m_mcChannel > 0) {
1106 ATH_MSG_WARNING( "autoconfigurePileupRWTool(): access to FileMetaData failed -> getting the mc channel number (DSID) and campaign from configuration." );
1107 std::string NoMetadataButPropertyOK("");
1108 NoMetadataButPropertyOK += "autoconfigurePileupRWTool(): 'mcCampaign' is used and passed to SUSYTools as '";
1109 NoMetadataButPropertyOK += m_mcCampaign;
1110 NoMetadataButPropertyOK += "'. 'mcChannel' is used and passed to SUSYTools as '";
1111 NoMetadataButPropertyOK += std::to_string(m_mcChannel);
1112 NoMetadataButPropertyOK += "'. Autocongiguring PRW accordingly.";
1113 ATH_MSG_WARNING( NoMetadataButPropertyOK );
1114 mcCampaignMD = m_mcCampaign;
1115 dsid = m_mcChannel;
1116 } else {
1117 // OK, this is a fall-back option without using MetaData but one has to manually set 'mcCampaign' property
1118 ATH_MSG_WARNING( "autoconfigurePileupRWTool(): access to FileMetaData failed -> getting the mc channel number (DSID) from the event store." );
1119 const xAOD::EventInfo* evtInfo = GetEventInfo();
1120 dsid = evtInfo->mcChannelNumber();
1121
1122 std::string NoMetadataButPropertyOK("");
1123 NoMetadataButPropertyOK += "autoconfigurePileupRWTool(): 'mcCampaign' is used and passed to SUSYTools as '";
1124 NoMetadataButPropertyOK += m_mcCampaign;
1125 NoMetadataButPropertyOK += "'. Autoconfiguring PRW accordingly.";
1126 ATH_MSG_WARNING( NoMetadataButPropertyOK );
1127 mcCampaignMD = m_mcCampaign;
1128 }
1129 } else {
1130 ATH_MSG_ERROR( "autoconfigurePileupRWTool(): `mcCampaign' is not set properly.");
1131 return StatusCode::FAILURE;
1132 }
1133#endif
1134 }
1135
1136 // If requested set the PRW file to common PRW file of the processed MC campaign
1137 if (m_useCommonPRWFiles) {
1138 ATH_MSG_INFO( "autoconfigurePileupRWTool(): retrieving the common PRW file for MC campaign: " << mcCampaignMD );
1139 if (mcCampaignMD == "mc20a") {prwConfigFile = PathResolverFindCalibFile(m_commonPRWFileMC20a);}
1140 else if (mcCampaignMD == "mc20d") {prwConfigFile = PathResolverFindCalibFile(m_commonPRWFileMC20d);}
1141 else if (mcCampaignMD == "mc20e") {prwConfigFile = PathResolverFindCalibFile(m_commonPRWFileMC20e);}
1142 else if (mcCampaignMD == "mc23a") {prwConfigFile = PathResolverFindCalibFile(m_commonPRWFileMC23a);}
1143 else if (mcCampaignMD == "mc23d") {prwConfigFile = PathResolverFindCalibFile(m_commonPRWFileMC23d);}
1144 else if (mcCampaignMD == "mc23e") {prwConfigFile = PathResolverFindCalibFile(m_commonPRWFileMC23e);}
1145 else if (mcCampaignMD == "mc23g") {prwConfigFile = PathResolverFindCalibFile(m_commonPRWFileMC23g);}
1146 else {
1147 ATH_MSG_ERROR( "autoconfigurePileupRWTool(): no common PRW file known for MC campaign: " << mcCampaignMD);
1148 return StatusCode::FAILURE;
1149 }
1150 }
1151 // Otherwise try finding the dedicated PRW file on /cvmfs
1152 else {
1153 // Retrieve the input file
1154 int DSID_INT = static_cast<int>(dsid);
1155 prwConfigFile += "DSID" + std::to_string(DSID_INT/1000) + "xxx/pileup_" + mcCampaignMD + "_dsid" + std::to_string(DSID_INT) + "_" + simType + ".root";
1156
1157 if (RPVLLmode) prwConfigFile = TString(prwConfigFile).ReplaceAll(".root","_rpvll.root").Data();
1158
1159 // PRW file specified by user
1160 // e.g. DSID700xxx/pileup_mc20a_dsid700015_FS.root
1161 if (!PRWfileName.empty()) {
1162 prwConfigFile = PRWfilesDir + PRWfileName;
1163 ATH_MSG_INFO( "autoconfigurePileupRWTool(): PRW file was specifed by user: " << prwConfigFile.data() );
1164 }
1165 }
1166
1167 m_prwConfFiles.clear();
1168
1169 // Combined mode can be only used when running with full data with the same MC samples
1170 if (Combinedmode) {
1171 if (mcCampaignMD.find("mc20") == std::string::npos) {
1172 ATH_MSG_ERROR( "autoconfigurePileupRWTool(): combined mode currently onlys supported for mc20! Impossible to autoconfigure PRW. Aborting." );
1173 return StatusCode::FAILURE;
1174 }
1175 // When using the common PRW files we can directly add them
1176 if (m_useCommonPRWFiles) {
1180 }
1181 // Otherwise we have to replace the mc campaign in the name accordingly
1182 else {
1183 m_prwConfFiles.emplace_back( TString(prwConfigFile).ReplaceAll(mcCampaignMD, "mc20a").Data() );
1184 m_prwConfFiles.emplace_back( TString(prwConfigFile).ReplaceAll(mcCampaignMD, "mc20d").Data() );
1185 m_prwConfFiles.emplace_back( TString(prwConfigFile).ReplaceAll(mcCampaignMD, "mc20e").Data() );
1186 }
1189 } else {
1190 m_prwConfFiles.push_back( prwConfigFile );
1191 if ( mcCampaignMD == "mc20d") {
1193 } else if (mcCampaignMD == "mc20e") {
1195 } else if (mcCampaignMD == "mc23a") {
1197 } else if (mcCampaignMD == "mc23d") {
1199 } else if (mcCampaignMD == "mc23e") {
1201 } else if (mcCampaignMD == "mc23g") {
1203 }
1204 }
1205 prwConfigFile = usePathResolver ? PathResolverFindCalibFile(prwConfigFile) : prwConfigFile;
1206
1207 // Test if file exists (i.e. was requested already to /cvmfs if the DSID-specific PRW files are used) and is usable
1208 TFile testF(prwConfigFile.data(),"read");
1209 if (testF.IsZombie()) {
1210 ATH_MSG_ERROR( "autoconfigurePileupRWTool(): file not found -> " << prwConfigFile.data() << " ! Impossible to autoconfigure PRW. Aborting." );
1211 if ( (!standard_like) && (!RPVLLmode) )
1212 ATH_MSG_WARNING("Running with non-standard r-tag (" << amiTag.data() << "), but RPVLLmode not set. Perhaps you want to set \"PRW.autoconfigPRWRPVmode: 1\" in the config?");
1213 return StatusCode::FAILURE;
1214 }
1215
1216 ATH_MSG_INFO( "autoconfigurePileupRWTool(): configuring PRW tool using " << prwConfigFile.data() );
1217 }
1218 // Return gracefully
1219 return StatusCode::SUCCESS;
1220}
#define ATH_MSG_INFO(x)
#define ATH_MSG_WARNING(x)
std::string PathResolverFindCalibFile(const std::string &logical_file_name)
const std::vector< std::string > split(const std::string &s, const std::string &delim) const
MetaStorePtr_t inputMetaStore() const
Accessor for the input metadata store.
uint32_t mcChannelNumber() const
The MC generator's channel number.
@ mcProcID
Same as mc_channel_number [float].
@ amiTag
AMI tag used to process the file the last time [string].
@ simFlavour
Fast or Full sim [string].
bool value(MetaDataType type, std::string &val) const
Get a pre-defined string value out of the object.
bool contains(const std::string &s, const std::string &regx)
does a string contain the substring
Definition hcg.cxx:116
FileMetaData_v1 FileMetaData
Declare the latest version of the class.

◆ beginEvent()

StatusCode asg::AsgMetadataTool::beginEvent ( )
protectedvirtualinherited

◆ beginInputFile()

StatusCode asg::AsgMetadataTool::beginInputFile ( )
protectedvirtualinherited

Function called when a new input file is opened.

Dummy implementation that can be overridden by the derived tool.

Reimplemented in AsgElectronEfficiencyCorrectionTool, BookkeeperDumperTool, BookkeeperTool, PMGTools::PMGTruthWeightTool, TauAnalysisTools::TauEfficiencyCorrectionsTool, TauAnalysisTools::TauSmearingTool, Trig::TrigDecisionTool, Trig::xAODBunchCrossingTool, TrigConf::xAODConfigTool, xAODMaker::TriggerMenuMetaDataTool, and xAODMaker::TruthMetaDataTool.

Definition at line 185 of file AsgMetadataTool.cxx.

185 {
186
187 // Return gracefully:
188 return StatusCode::SUCCESS;
189 }

◆ BtagSF()

float ST::SUSYObjDef_xAOD::BtagSF ( const xAOD::JetContainer * jets)
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 844 of file Jets.cxx.

844 {
845
846 float totalSF = 1.;
847 for ( const xAOD::Jet* jet : *jets ) {
848
849 float sf = 1.;
850
851 if ( std::abs(jet->eta()) > 2.5 ) {
852 ATH_MSG_VERBOSE( "Trying to retrieve b-tagging SF for jet with |eta|>2.5 (jet eta=" << jet->eta() << "), jet will be skipped");
853 } else if ( jet->pt() < 20e3 ){
854 ATH_MSG_VERBOSE( "Trying to retrieve b-tagging SF for jet with invalid pt (jet pt=" << jet->pt() << "), jet will be skipped");
855 } else {
856
857 CP::CorrectionCode result;
858 int truthlabel(-1);
859 if (!jet->getAttribute("HadronConeExclTruthLabelID", truthlabel)) {
860 ATH_MSG_ERROR("Failed to get jet truth label!");
861 }
862 ATH_MSG_VERBOSE("This jet is " << (acc_bjet(*jet) ? "" : "not ") << "b-tagged.");
863 ATH_MSG_VERBOSE("This jet's truth label is " << truthlabel);
864
865 if ( acc_bjet(*jet) or m_BtagWP == "Continuous") {
866 result = m_btagEffTool->getScaleFactor(*jet, sf);
867
868 switch (result) {
870 ATH_MSG_ERROR( "Failed to retrieve SF for b-tagged jets in SUSYTools_xAOD::BtagSF" );
871 break;
873 ATH_MSG_VERBOSE( "No valid SF for b-tagged jets in SUSYTools_xAOD::BtagSF" );
874 break;
875 default:
876 ATH_MSG_VERBOSE( "Retrieve SF for b-tagged jets in SUSYTools_xAOD::BtagSF with value " << sf );
877 }
878 } else {
879
880 result = m_btagEffTool->getInefficiencyScaleFactor(*jet, sf);
881
882 switch (result) {
884 ATH_MSG_ERROR( "Failed to retrieve SF for non-b-tagged jets in SUSYTools_xAOD::BtagSF" );
885 break;
887 ATH_MSG_VERBOSE( "No valid inefficiency SF for non-b-tagged jets in SUSYTools_xAOD::BtagSF" );
888 break;
889 default:
890 ATH_MSG_VERBOSE( "Retrieve SF for non-b-tagged jets in SUSYTools_xAOD::BtagSF with value " << sf );
891 }
892 }
893 }
894
895 dec_effscalefact(*jet) = sf;
896
897 if( acc_signal(*jet) && acc_passOR(*jet) ) totalSF *= sf; //consider goodjets only
898
899 }
900
901 return totalSF;
902 }
@ Error
Some error happened during the object correction.
@ OutOfValidityRange
Input object is out of validity range.
static const SG::Decorator< double > dec_effscalefact("effscalefact")
static const SG::ConstAccessor< char > acc_signal("signal")
static const SG::ConstAccessor< char > acc_bjet("bjet")
static const SG::ConstAccessor< char > acc_passOR("passOR")
Jet_v1 Jet
Definition of the current "jet version".

◆ BtagSF_trkJet()

float ST::SUSYObjDef_xAOD::BtagSF_trkJet ( const xAOD::JetContainer * trkjets)
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 925 of file Jets.cxx.

925 {
926
927 float totalSF = 1.;
928 for ( const xAOD::Jet* trkjet : *trkjets ) {
929
930 float sf = 1.;
931
932 if ( std::abs(trkjet->eta()) > 2.5 ) {
933 ATH_MSG_VERBOSE( "Trying to retrieve b-tagging SF for trkjet with |eta|>2.5 (trkjet eta=" << trkjet->eta() << "), trkjet will be skipped");
934 } else if ( trkjet->pt() < 10e3 ){
935 ATH_MSG_VERBOSE( "Trying to retrieve b-tagging SF for trkjet with invalid pt (trkjet pt=" << trkjet->pt() << "), jet will be skipped");
936 } else {
937
938 CP::CorrectionCode result;
939 int truthlabel(-1);
940 if (!trkjet->getAttribute("HadronConeExclTruthLabelID", truthlabel)) {
941 ATH_MSG_ERROR("Failed to get jet truth label!");
942 }
943 ATH_MSG_VERBOSE("This jet is " << (acc_bjet(*trkjet) ? "" : "not ") << "b-tagged.");
944 ATH_MSG_VERBOSE("This jet's truth label is " << truthlabel);
945
946 if ( acc_bjet(*trkjet) ) {
947 result = m_btagEffTool_trkJet->getScaleFactor(*trkjet, sf);
948
949 switch (result) {
951 ATH_MSG_ERROR( "Failed to retrieve SF for b-tagged trk jets in SUSYTools_xAOD::BtagSF_trkJet" );
952 break;
954 ATH_MSG_VERBOSE( "No valid SF for b-tagged trk jets in SUSYTools_xAOD::BtagSF_trkJet" );
955 break;
956 default:
957 ATH_MSG_VERBOSE( "Retrieve SF for b-tagged trk jets in SUSYTools_xAOD::BtagSF_trkJet with value " << sf );
958 }
959 } else {
960
961 result = m_btagEffTool_trkJet->getInefficiencyScaleFactor(*trkjet, sf);
962
963 switch (result) {
965 ATH_MSG_ERROR( "Failed to retrieve SF for non-b-tagged trk jets in SUSYTools_xAOD::BtagSF_trkJet" );
966 break;
968 ATH_MSG_VERBOSE( "No valid inefficiency SF for non-b-tagged trk jets in SUSYTools_xAOD::BtagSF_trkJet" );
969 break;
970 default:
971 ATH_MSG_VERBOSE( "Retrieve SF for non-b-tagged trk jets in SUSYTools_xAOD::BtagSF_trkJet with value " << sf );
972 }
973 }
974 }
975
976 dec_effscalefact(*trkjet) = sf;
977
978 if( acc_signal(*trkjet) ) totalSF *= sf;
979
980 }
981
982 return totalSF;
983 }

◆ BtagSFsys()

float ST::SUSYObjDef_xAOD::BtagSFsys ( const xAOD::JetContainer * jets,
const CP::SystematicSet & systConfig )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 905 of file Jets.cxx.

906 {
907 float totalSF = 1.;
908
909 //Set the new systematic variation
910 StatusCode ret = m_btagEffTool->applySystematicVariation(systConfig);
911 if ( ret != StatusCode::SUCCESS) {
912 ATH_MSG_ERROR("Cannot configure BTaggingEfficiencyTool for systematic var. " << systConfig.name() );
913 }
914
915 totalSF = BtagSF( jets );
916
917 ret = m_btagEffTool->applySystematicVariation(m_currentSyst);
918 if ( ret != StatusCode::SUCCESS) {
919 ATH_MSG_ERROR("Cannot configure BTaggingEfficiencyTool for systematic var. " << systConfig.name() );
920 }
921
922 return totalSF;
923 }
float BtagSF(const xAOD::JetContainer *jets) override final
Definition Jets.cxx:844

◆ BtagSFsys_trkJet()

float ST::SUSYObjDef_xAOD::BtagSFsys_trkJet ( const xAOD::JetContainer * trkjets,
const CP::SystematicSet & systConfig )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 986 of file Jets.cxx.

987 {
988 float totalSF = 1.;
989
990 //Set the new systematic variation
991 StatusCode ret = m_btagEffTool_trkJet->applySystematicVariation(systConfig);
992 if ( ret != StatusCode::SUCCESS) {
993 ATH_MSG_ERROR("Cannot configure BTaggingEfficiencyTool (track jets) for systematic var. " << systConfig.name() );
994 }
995
996 totalSF = BtagSF_trkJet( trkjets );
997
998 ret = m_btagEffTool_trkJet->applySystematicVariation(m_currentSyst);
999 if ( ret != StatusCode::SUCCESS) {
1000 ATH_MSG_ERROR("Cannot configure BTaggingEfficiencyTool (track jets) for systematic var. " << systConfig.name() );
1001 }
1002
1003 return totalSF;
1004 }
float BtagSF_trkJet(const xAOD::JetContainer *trkjets) override final
Definition Jets.cxx:925

◆ check_isOption()

bool ST::SUSYObjDef_xAOD::check_isOption ( const std::string & wp,
const std::vector< std::string > & list ) const
protected

Definition at line 1230 of file SUSYObjDef_xAOD.cxx.

1230 {
1231 //check if the selected WP is supported
1232 return (std::find(list.begin(), list.end(),wp) != list.end());
1233}
list(name, path='/')
Definition histSizes.py:38

◆ check_isTighter()

bool ST::SUSYObjDef_xAOD::check_isTighter ( const std::string & wp1,
const std::string & wp,
const std::vector< std::string > & list ) const
protected

Definition at line 1235 of file SUSYObjDef_xAOD.cxx.

1235 {
1236 //check if WP1 is tighter than WP2
1237 //it is assumed that both WPs are supported
1238 return (std::find(list.begin(),list.end(),wp1) > std::find(list.begin(), list.end(),wp2));
1239}

◆ configFromFile() [1/4]

void ST::SUSYObjDef_xAOD::configFromFile ( bool & property,
const std::string & propname,
TEnv & rEnv,
bool defaultValue )
protected

Definition at line 1273 of file SUSYObjDef_xAOD.cxx.

1275{
1276 if(m_bool_prop_set.find(m_conf_to_prop[propname])!=m_bool_prop_set.end()){
1277 ATH_MSG_INFO( "configFromFile(): property \"" << propname << "\" already set with value " << property << ". Ignoring change request." );
1278 rEnv.GetTable()->Remove( rEnv.GetTable()->FindObject(propname.c_str() ) );
1279 return;
1280 }
1281 property = rEnv.GetValue(propname.c_str(), static_cast<int>(defaultValue));
1282 ATH_MSG_INFO( "configFromFile(): Loaded property \"" << propname << "\" with value " << property );
1283 // Remove the item from the table
1284 rEnv.GetTable()->Remove( rEnv.GetTable()->FindObject(propname.c_str() ) );
1285}
std::map< std::string, std::string > m_conf_to_prop
std::set< std::string > m_bool_prop_set

◆ configFromFile() [2/4]

void ST::SUSYObjDef_xAOD::configFromFile ( double & property,
const std::string & propname,
TEnv & rEnv,
double defaultValue )
protected

Definition at line 1288 of file SUSYObjDef_xAOD.cxx.

1290{
1291 // ignore if already configured
1292 if (property > -90.) {
1293 ATH_MSG_INFO( "configFromFile(): property \"" << propname << "\" already set with value " << property << ". Ignoring change request." );
1294 rEnv.GetTable()->Remove( rEnv.GetTable()->FindObject(propname.c_str() ) );
1295 return;
1296 }
1297 property = rEnv.GetValue(propname.c_str(), defaultValue);
1298 ATH_MSG_INFO( "configFromFile(): Loaded property \"" << propname << "\" with value " << property );
1299 // Remove the item from the table
1300 rEnv.GetTable()->Remove( rEnv.GetTable()->FindObject(propname.c_str() ) );
1301}

◆ configFromFile() [3/4]

void ST::SUSYObjDef_xAOD::configFromFile ( int & property,
const std::string & propname,
TEnv & rEnv,
int defaultValue )
protected

Definition at line 1304 of file SUSYObjDef_xAOD.cxx.

1306{
1307 // ignore if already configured
1308 if (property > -90){
1309 ATH_MSG_INFO( "configFromFile(): property \"" << propname << "\" already set with value " << property << ". Ignoring change request." );
1310 rEnv.GetTable()->Remove( rEnv.GetTable()->FindObject(propname.c_str() ) );
1311 return;
1312 }
1313 property = rEnv.GetValue(propname.c_str(), defaultValue);
1314 ATH_MSG_INFO( "configFromFile(): Loaded property \"" << propname << "\" with value " << property );
1315 // Remove the item from the table
1316 rEnv.GetTable()->Remove( rEnv.GetTable()->FindObject(propname.c_str() ) );
1317}

◆ configFromFile() [4/4]

void ST::SUSYObjDef_xAOD::configFromFile ( std::string & property,
const std::string & propname,
TEnv & rEnv,
const std::string & defaultValue,
bool allowEmpty = false )
protected

Definition at line 1320 of file SUSYObjDef_xAOD.cxx.

1322{
1323 // ignore if already configured
1324 if (!property.empty()){
1325 ATH_MSG_INFO( "configFromFile(): property \"" << propname << "\" already set with value " << property << ". Ignoring change request." );
1326 rEnv.GetTable()->Remove( rEnv.GetTable()->FindObject(propname.c_str() ) );
1327 return;
1328 }
1329 property = rEnv.GetValue(propname.c_str(), defaultValue.c_str());
1330 if (property.empty() && !allowEmpty) {
1331 ATH_MSG_FATAL("Read empty string property from text file (property name: " << propname << ")");
1332 }
1333
1334 // post-processing to get rid of leading/trailing spaces and comments
1335 std::string tmp_prop = property.substr(0, property.find('#', 0));
1336 property = TString(tmp_prop).ReplaceAll(" ","").Data();
1337
1338 // Interpret None as an empty string
1339 if (property=="None" || property=="NONE" || property=="none") {
1340 ATH_MSG_VERBOSE( "Property \"" << propname << "\" being set to empty string due to specification of \"" << property << "\"" );
1341 property = "";
1342 }
1343
1344 ATH_MSG_INFO( "configFromFile(): Loaded property \"" << propname << "\" with value " << property );
1345 // Remove the item from the table
1346 rEnv.GetTable()->Remove( rEnv.GetTable()->FindObject(propname.c_str() ) );
1347}
#define ATH_MSG_FATAL(x)

◆ currentSystematic()

const CP::SystematicSet & ST::SUSYObjDef_xAOD::currentSystematic ( ) const

Definition at line 2159 of file SUSYObjDef_xAOD.cxx.

2159 {
2160 return m_currentSyst;
2161}

◆ currentSystematicIsNominal()

bool ST::SUSYObjDef_xAOD::currentSystematicIsNominal ( ) const

Definition at line 2187 of file SUSYObjDef_xAOD.cxx.

2187 {
2188 return isNominal(m_currentSyst);
2189}
bool isNominal(const CP::SystematicSet &syst) const

◆ currentSystematicIsVariation()

bool ST::SUSYObjDef_xAOD::currentSystematicIsVariation ( ) const

Definition at line 2191 of file SUSYObjDef_xAOD.cxx.

2191 {
2192 return isVariation(m_currentSyst);
2193}
bool isVariation(const CP::SystematicSet &syst) const

◆ currentSystematicIsWeight()

bool ST::SUSYObjDef_xAOD::currentSystematicIsWeight ( ) const

Definition at line 2195 of file SUSYObjDef_xAOD.cxx.

2195 {
2196 return isWeight(m_currentSyst);
2197}
bool isWeight(const CP::SystematicSet &systSet) const

◆ declareGaudiProperty()

Gaudi::Details::PropertyBase & AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T, V, H > & hndl,
const SG::VarHandleKeyType &  )
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158 {
160 hndl.value(),
161 hndl.documentation());
162
163 }

◆ declareProperty()

Gaudi::Details::PropertyBase & AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( Gaudi::Property< T, V, H > & t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145 {
146 typedef typename SG::HandleClassifier<T>::type htype;
148 }
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>

◆ detStore()

const ServiceHandle< StoreGateSvc > & AthCommonDataStore< AthCommonMsg< AlgTool > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

◆ EG_WP()

std::string ST::SUSYObjDef_xAOD::EG_WP ( const std::string & wp) const
protected

Definition at line 1242 of file SUSYObjDef_xAOD.cxx.

1242 {
1243 //translate our electron wps to EGamma internal jargon
1244 //@ElectronPhotonSelectorTools/EGSelectorConfigurationMapping.h
1245 TString copy = TString(wp).Copy().ReplaceAll("AndBLayer","BL").ReplaceAll("LLH","LHElectron");
1246 // the DNN WPs are labeled in the map as e.g. TightDNNnoCFElectron or TightDNNElectron
1247 if (wp.find("DNNnoCF") != std::string::npos)
1248 copy.ReplaceAll("DNNnoCF", "DNNnoCFElectron");
1249 else if (wp.find("DNN") != std::string::npos)
1250 copy.ReplaceAll("DNN", "DNNElectron");
1251 return copy.Data();
1252}
bool copy
Definition calibdata.py:26

◆ emulateHLT()

bool ST::SUSYObjDef_xAOD::emulateHLT ( const std::string & triggerName) const
private

Definition at line 91 of file Trigger.cxx.

91 {
92 std::scoped_lock lock (m_triggerCacheMutex);
93 // First, check if we've already tried using this trigger
94 auto funcItr = m_metTriggerFuncs.find(triggerName);
95 if (funcItr != m_metTriggerFuncs.end() )
96 return funcItr->second();
97
98 // Next, check that it really is a HLT MET trigger
99 if (triggerName.substr(0,6) != "HLT_xe") {
100 ATH_MSG_ERROR( "Requested trigger " << triggerName << " isn't a MET trigger! (HLT MET items should begin with 'HLT_xe'). Will return false." );
101 return false;
102 }
103
104 // Next, parse the name to work out which containers are needed to emulate the decision
105 std::vector<std::pair<int, std::string> > hypos; // algorithms and thresholds needed
106 std::string temp(triggerName);
107 // Note, we need to split on '_AND_' used for the combined mht+cell trigger
108 do {
109 auto pos = temp.find("_AND_");
110 std::string itemName = temp.substr(0, pos);
111 ATH_MSG_DEBUG( "Split trigger item " << itemName );
112 if (pos == std::string::npos)
113 temp = "";
114 else
115 temp = temp.substr(pos + 5);
116
117 std::regex expr("HLT_xe([[:digit:]]+)_?(mht|pufit|pueta|tc_lcw|)_?(?:L1XE([[:digit:]]+)|)");
118 std::smatch sm;
119 if (!std::regex_match(itemName, sm, expr) ) {
120 ATH_MSG_WARNING( "Regex reading for item " << itemName << " (" << triggerName << ") failed! Will be ignored!" );
121 continue;
122 }
123 if (sm.size() < 4) { // first object is the whole match, then there are three capture groups
124 ATH_MSG_WARNING( "Regex failed to capture the right groups for item " << itemName << " (" << triggerName << ") failed! Will be ignored!" );
125 for (unsigned int ii = 0; ii < sm.size(); ++ii) {
126 ATH_MSG_WARNING( sm[ii] );
127 }
128 continue;
129 }
130 int threshold = std::stoi(sm[1] );
131 std::string algKey = sm[2];
132 std::string metContBaseName = "HLT_xAOD__TrigMissingETContainer_TrigEFMissingET";
133 if (algKey.empty()) hypos.push_back(std::make_pair(threshold, metContBaseName) );
134 else if (algKey == "mht") hypos.push_back(std::make_pair(threshold, metContBaseName+"_mht") );
135 else if (algKey == "pufit") hypos.push_back(std::make_pair(threshold, metContBaseName+"_topocl_PUC") );
136 else if (algKey == "pueta") hypos.push_back(std::make_pair(threshold, metContBaseName+"_topocl_PS") );
137 else if (algKey == "tc_lcw") hypos.push_back(std::make_pair(threshold, metContBaseName+"topocl") );
138
139 ATH_MSG_DEBUG( "Container: " << hypos.back().second << ", Threshold: " << hypos.back().first );
140
141 if (sm[3] != "" && sm[3] != "50") {
142 ATH_MSG_WARNING( "The trigger requires a different L1 item to L1_XE50! This currently isn't allowed for in the code so the emulation will be slightly wrong" );
143 // Note, now the L1 part is done in the previous section. However I'm keeping this warning here.
144 }
145 }
146 while (!temp.empty());
147
148 // Check if we have the containers and construct the lambda
149 // Already done the L1 decision - only care about HLT
150 std::function<bool()> lambda;
151 bool hasRequired = true;
152 if (hypos.empty()) lambda = [] () {return false;};
153 else {
154 for (const auto& pair : hypos) {
156 auto lambda_hypo = [this, pair] () {
157 const xAOD::TrigMissingETContainer* cont(nullptr);
158 if (evtStore()->retrieve(cont, pair.second) ) {
159 if (cont->empty()) return false;
160 float ex = cont->front()->ex() * 0.001;
161 float ey = cont->front()->ey() * 0.001;
162 float met = std::sqrt(ex*ex + ey*ey);
163 return met > pair.first;
164 }
165 else {
166 return false;
167 }
168 };
169 // an empty std::function evaluates to false
170 if (lambda) {
171 lambda = [lambda, lambda_hypo] () {
172 return lambda() && lambda_hypo();
173 };
174 }
175 else {
176 lambda = lambda_hypo;
177 }
178 }
179 else {
180 hasRequired = false;
181 ATH_MSG_WARNING( "Container: " << pair.second << " missing!" );
182 }
183 }
184 }
185 if (hasRequired) {
186 m_metTriggerFuncs[triggerName] = lambda;
187 return m_metTriggerFuncs.at(triggerName)();
188 }
189 // We can't get the exact trigger decision :( . Look for an alternative
190 std::vector<std::string> replacementTriggers({"HLT_xe110_mht_L1XE50", "HLT_xe100_mht_L1XE50", "HLT_xe90_mht_L1XE50", "HLT_xe70_mht"});
191 for (const std::string& trigName : replacementTriggers) {
192 if (isTrigInTDT(lock, trigName) ) {
193 ATH_MSG_WARNING( "Trigger " << triggerName << " not available and direct emulation impossible! Will use " << trigName << " instead!");
194 m_metTriggerFuncs[triggerName] = [this, trigName] () {
195 return m_trigDecTool->isPassed(trigName);
196 };
197 return m_metTriggerFuncs.at(triggerName)();
198 }
199 }
200 ATH_MSG_ERROR( "Cannot find the trigger in the menu, direct emulation is impossible and no replacement triggers are available! Will return false" );
201 m_metTriggerFuncs.at(triggerName) = [] () {return false;};
202 return m_metTriggerFuncs.at(triggerName)();
203}
virtual void lock()=0
Interface to allow an object to lock itself when made const in SG.
ServiceHandle< StoreGateSvc > & evtStore()
std::mutex m_triggerCacheMutex
bool isTrigInTDT(std::scoped_lock< std::mutex > &lock, const std::string &triggerName) const
Definition Trigger.cxx:77
TrigMissingETContainer_v1 TrigMissingETContainer
DataVector of TrigMissingET - the current version.
setBGCode setTAP setLVL2ErrorBits bool

◆ endInputFile()

StatusCode asg::AsgMetadataTool::endInputFile ( )
protectedvirtualinherited

Function called when the currently open input file got completely processed.

Dummy implementation that can be overridden by the derived tool.

Reimplemented in BookkeeperDumperTool, BookkeeperTool, xAODMaker::TriggerMenuMetaDataTool, and xAODMaker::TruthMetaDataTool.

Definition at line 193 of file AsgMetadataTool.cxx.

193 {
194
195 // Return gracefully:
196 return StatusCode::SUCCESS;
197 }

◆ evtStore()

ServiceHandle< StoreGateSvc > & AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase & ExtraDeps)
protectedinherited

Add StoreName to extra input/output deps as needed.

use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given

◆ FillElectron()

StatusCode ST::SUSYObjDef_xAOD::FillElectron ( xAOD::Electron & input,
const float etcut,
const float etacut )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 226 of file Electrons.cxx.

226 {
227
228 ATH_MSG_VERBOSE( "Starting FillElectron on el with pre-calibration pt=" << input.pt() );
229
230 // According to https://twiki.cern.ch/twiki/bin/view/AtlasProtected/EGammaIdentificationRun2#Electron_identification:
231 // "Please apply the identification to uncalibrated electron object. ID scale factors are to be applied to calibrated objects."
232 dec_baseline(input) = false;
233 dec_selected(input) = 0;
234 dec_signal(input) = false;
235 dec_isol(input) = false;
236 dec_isolHighPt(input) = false;
237 dec_passSignalID(input) = false;
238 dec_passChID(input) = false;
239 dec_ecisBDT(input) = -999.;
240
241 const xAOD::EventInfo* evtInfo = nullptr;
242 ATH_CHECK( evtStore()->retrieve( evtInfo, "EventInfo" ) );
243 const xAOD::Vertex* pv = this->GetPrimVtx();
244 const xAOD::TrackParticle* track = input.trackParticle();
245 if (!track) {
246 ATH_MSG_DEBUG("No primary track particle for this electron. Skipping.");
247 return StatusCode::SUCCESS;
248 }
249 double primvertex_z = pv ? pv->z() : 0;
250 double el_z0 = track->z0() + track->vz() - primvertex_z;
251 dec_z0sinTheta(input) = el_z0 * TMath::Sin(input.p4().Theta());
252 //protect against exception thrown for null or negative d0sig
253 try{
255 }
256 catch(...){
257 float d0sigError = -99.;
258 ATH_MSG_WARNING("FillElectron : Exception catched from d0significance() calculation. Setting dummy decoration d0sig=" << d0sigError );
259 dec_d0sig(input) = d0sigError;
260 }
261
262 // don't bother calibrating or computing WP
263 if ( input.pt() < 4e3 ) return StatusCode::SUCCESS;
264 if ( !input.caloCluster() ) { ATH_MSG_WARNING( "FillElectron: no caloCluster found: " << input.caloCluster() ); return StatusCode::SUCCESS; }
265
266 //Check DeadHVCellRemoval
267 bool pass_deadHVTool = m_deadHVTool->accept(&input);
268
269 if (m_debug) {
270 unsigned char el_nPixHits(0), el_nSCTHits(0);
271 input.trackParticle()->summaryValue(el_nPixHits, xAOD::numberOfPixelHits);
272 input.trackParticle()->summaryValue(el_nSCTHits, xAOD::numberOfSCTHits);
273
274 ATH_MSG_INFO( "ELECTRON eta: " << input.eta());
275 ATH_MSG_INFO( "ELECTRON phi: " << input.phi());
276 ATH_MSG_INFO( "ELECTRON cl eta: " << input.caloCluster()->eta());
277 ATH_MSG_INFO( "ELECTRON cl phi: " << input.caloCluster()->phi());
278 ATH_MSG_INFO( "ELECTRON cl e: " << input.caloCluster()->e());
279 ATH_MSG_INFO( "ELECTRON trk eta: " << input.trackParticle()->eta());
280 ATH_MSG_INFO( "ELECTRON trk phi: " << input.trackParticle()->phi());
281 ATH_MSG_INFO( "ELECTRON author: " << input.author());
282 ATH_MSG_INFO( "ELECTRON OQ: " << acc_OQ(input));
283 ATH_MSG_INFO( "ELECTRON nPixHits: " << static_cast<int>(el_nPixHits));
284 ATH_MSG_INFO( "ELECTRON nSCTHits: " << static_cast<int>(el_nSCTHits));
285 ATH_MSG_INFO( "ELECTRON deadHVTools: " << static_cast<bool>(pass_deadHVTool));
286 }
287
288 if (!pass_deadHVTool) return StatusCode::SUCCESS;
289 if (!input.isGoodOQ(xAOD::EgammaParameters::BADCLUSELECTRON)) return StatusCode::SUCCESS;
290
291 if ( m_elecSelLikelihoodBaseline.empty()) {
292 ATH_MSG_ERROR("No baseline electron selector defined!");
293 return StatusCode::FAILURE;
294 }
295
296 bool passBaseID = false;
297 if (m_eleIdExpert) {
298 passBaseID = bool(m_elecSelLikelihoodBaseline->accept(&input));
299 } else {
300 if (m_acc_eleIdBaseline.isAvailable(input)) {
301 passBaseID = m_acc_eleIdBaseline(input);
302 } else {
303 ATH_MSG_VERBOSE ("DFCommonElectronsLHxxx variables are not found. Calculating the ID from LH tool..");
304 passBaseID = bool(m_elecSelLikelihoodBaseline->accept(&input));
305 }
306 }
307
308 if ( !passBaseID && !m_force_noElId ) return StatusCode::SUCCESS;
309
310 //baseline ID decoration for TauEl OR
311 //dec_passBaseID(input) = true;
312
313 // calibrate the electron 4-vector here only if within eta window
314 if (std::abs(input.caloCluster()->etaBE(2)) >= etacut) return StatusCode::SUCCESS;
315
317 if ( std::abs( input.caloCluster()->etaBE(2) ) >1.37 && std::abs( input.caloCluster()->etaBE(2) ) <1.52) {
318 return StatusCode::SUCCESS;
319 }
320 }
321
322 // corrections described in https://twiki.cern.ch/twiki/bin/view/AtlasProtected/EGammaCalibrationRun2
323 if ( m_egammaCalibTool->applyCorrection(input) != CP::CorrectionCode::Ok)
324 ATH_MSG_ERROR( "FillElectron: EgammaCalibTool applyCorrection failed ");
325
326 if (m_isoCorrTool->applyCorrection(input) != CP::CorrectionCode::Ok)
327 ATH_MSG_ERROR("FillElectron: IsolationCorrectionTool applyCorrection failed");
328
329 ATH_MSG_VERBOSE( "FillElectron: post-calibration pt=" << input.pt() );
330
331 if (input.pt() < etcut) return StatusCode::SUCCESS;
332
333 if (m_elebaselinez0>0. && std::abs(acc_z0sinTheta(input))>m_elebaselinez0) return StatusCode::SUCCESS;
334 if (m_elebaselined0sig>0. && std::abs(acc_d0sig(input))>m_elebaselined0sig) return StatusCode::SUCCESS;
335
336 //--- Do baseline isolation check
337 if ( !( m_eleBaselineIso_WP.empty() ) && !( m_isoBaselineTool->accept(input) ) ) return StatusCode::SUCCESS;
338
339 dec_baseline(input) = true;
340 dec_selected(input) = 2;
341 //disable if (!m_eleIso_WP.empty() && m_eleIso_WP.find("PLV")!=std::string::npos) ATH_CHECK( ->augmentPLV(input) );
342 if (!m_eleIso_WP.empty()) dec_isol(input) = bool(m_isoTool->accept(input));
343 if (!m_eleIsoHighPt_WP.empty()) dec_isolHighPt(input) = bool(m_isoHighPtTool->accept(input));
344
345 //ChargeIDSelector
346 if( m_runECIS ){
347 if (acc_passECIDS.isAvailable(input)) {
348 dec_passChID(input) = acc_passECIDS(input); // Loose 97% WP!
349 } else {
350 dec_passChID(input) = bool(m_elecChargeIDSelectorTool->accept(&input));
351 //disable double bdt = m_elecChargeIDSelectorTool->calculate(&input).getResult("bdt");
352 //disable dec_ecisBDT(input) = bdt;
353 }
354 }
355 else{
356 dec_passChID(input) = true;
357 }
358
359 ATH_MSG_VERBOSE( "FillElectron: passed baseline selection" );
360
361 return StatusCode::SUCCESS;
362}
@ Ok
The correction was done successfully.
asg::AnaToolHandle< IAsgDeadHVCellRemovalTool > m_deadHVTool
const xAOD::Vertex * GetPrimVtx() const override final
float beamPosSigmaY() const
The width of the beam spot in the Y direction.
float beamPosSigmaXY() const
The beam spot shape's X-Y correlation.
float beamPosSigmaX() const
The width of the beam spot in the X direction.
static const SG::ConstAccessor< float > acc_d0sig("d0sig")
static const SG::Decorator< char > dec_passSignalID("passSignalID")
static const SG::Decorator< char > dec_baseline("baseline")
static const SG::Decorator< char > dec_isolHighPt("isolHighPt")
static const SG::ConstAccessor< float > acc_z0sinTheta("z0sinTheta")
static const SG::ConstAccessor< char > acc_passECIDS("DFCommonElectronsECIDS")
static const SG::ConstAccessor< unsigned int > acc_OQ("OQ")
static const SG::Decorator< char > dec_passChID("passChID")
static const SG::Decorator< float > dec_z0sinTheta("z0sinTheta")
static const SG::Decorator< double > dec_ecisBDT("ecisBDT")
static const SG::Decorator< char > dec_isol("isol")
static const SG::Decorator< char > dec_signal("signal")
static const SG::Decorator< float > dec_d0sig("d0sig")
static const SG::Decorator< char > dec_selected("selected")
const uint32_t BADCLUSELECTRON
Definition EgammaDefs.h:116
double d0significance(const xAOD::TrackParticle *tp, double d0_uncert_beam_spot_2)
TrackParticle_v1 TrackParticle
Reference the current persistent version:
Vertex_v1 Vertex
Define the latest version of the vertex class.
@ numberOfSCTHits
number of hits in SCT [unit8_t].
@ numberOfPixelHits
these are the pixel hits, including the b-layer [unit8_t].

◆ FillJet()

StatusCode ST::SUSYObjDef_xAOD::FillJet ( xAOD::Jet & input,
const bool doCalib = true,
bool isFat = false,
bool doLargeRdecorations = false )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 403 of file Jets.cxx.

403 {
404
405 ATH_MSG_VERBOSE( "Starting FillJet on jet with pt=" << input.pt() );
406 ATH_MSG_VERBOSE( "jet (pt,eta,phi) before calibration " << input.pt() << " " << input.eta() << " " << input.phi() );
407
408 static const SG::ConstAccessor<char> acc_wValidKinRange(m_WDecorName+"_ValidKinRange");
409 static const SG::ConstAccessor<char> acc_zValidKinRange(m_ZDecorName+"_ValidKinRange");
410 static const SG::ConstAccessor<char> acc_topValidKinRange(m_TopDecorName+"_ValidKinRange");
411 static const SG::ConstAccessor<char> acc_wtagged(m_WDecorName+"_Tagged");
412 static const SG::ConstAccessor<char> acc_ztagged(m_ZDecorName+"_Tagged");
413 static const SG::ConstAccessor<char> acc_toptagged(m_TopDecorName+"_Tagged");
414
415 if (doCalib) {
416 if(!isFat){
417 //disable - obsoleted ATH_CHECK( m_jetCalibTool->applyCalibration(input) );
418 }
419 else {
420 //disable - obsoleted ATH_CHECK( m_jetFatCalibTool->applyCalibration(input) );
421 dec_baseline(input) = ( input.pt() > m_jetPt ) || ( input.pt() > 20e3 ); // Allows for setting m_jetPt < 20e3
422 dec_bad(input) = false;
423 dec_signal(input) = false;
424 dec_bjet_loose(input) = false;
425 dec_effscalefact(input) = 1.;
426 dec_passOR(input) = true;
427 dec_bjet_jetunc(input) = false;
428 dec_btag_weight(input) = -999.;
429
430 dec_wtagged(input) = -1;
431 dec_ztagged(input) = -1;
432 dec_toptagged(input) = -1;
433 if (doLargeRdecorations) {
434
435 // Retrieve large-R tagging results for W/Z/top
436 if (!m_WtagConfig.empty()) {
437 // Only tag jets if they are inside the kinematic range
438 if ( !acc_wValidKinRange(input) ) {
439 ATH_MSG_VERBOSE("Large-R W candidate jet outside of recommended tagging range. Will set score to 0.");
440 dec_wtagged(input) = 0;
441 }
442 else dec_wtagged(input) = acc_wtagged(input);
443 }
444 if (!m_ZtagConfig.empty()) {
445 // Only tag jets if they are inside the kinematic range
446 if ( !acc_zValidKinRange(input) ) {
447 ATH_MSG_VERBOSE("Large-R Z candidate jet outside of recommended tagging range. Will set score to 0.");
448 dec_ztagged(input) = 0;
449 }
450 else dec_ztagged(input) = acc_ztagged(input);
451 }
452 if (!m_ToptagConfig.empty()) {
453 ATH_CHECK(m_TopTaggerTool->tag(input));
454 // Only tag jets if they are inside the kinematic range
455 if ( !acc_topValidKinRange(input) ) {
456 ATH_MSG_VERBOSE("Large-R Top candidate jet outside of recommended tagging range. Will set score to 0.");
457 dec_toptagged(input) = 0;
458 }
459 else dec_toptagged(input) = acc_toptagged(input);
460 }
461
462 }
463
464 // If a user hasn't specified an uncertainty config, then this tool will be empty
465 // for large R jets
466 if (!m_WTagjetUncertaintiesTool.empty() && !m_WTagUncConfig.empty() && !m_WtagConfig.empty() && doLargeRdecorations) {
467 CP::CorrectionCode result = m_WTagjetUncertaintiesTool->applyCorrection(input);
468 switch (result) {
470 ATH_MSG_ERROR( "Failed to apply largeR W-tag jet scale uncertainties.");
471 return StatusCode::FAILURE;
472 //break;
474 ATH_MSG_VERBOSE( "No valid pt/eta/m range for largeR W-tag jet scale uncertainties. ");
475 break;
476 default:
477 break;
478 }
479 } else {
480 ATH_MSG_DEBUG( "No valid large-R W-tagged fat jet uncertainty, but FillJet called with a fat jet. Skipping uncertainties." );
481 }
482
483 if (!m_ZTagjetUncertaintiesTool.empty() && !m_ZTagUncConfig.empty() && !m_ZtagConfig.empty() && doLargeRdecorations) {
484 CP::CorrectionCode result = m_ZTagjetUncertaintiesTool->applyCorrection(input);
485 switch (result) {
487 ATH_MSG_ERROR( "Failed to apply largeR Z-tag jet scale uncertainties.");
488 return StatusCode::FAILURE;
489 //break;
491 ATH_MSG_VERBOSE( "No valid pt/eta/m range for largeR Z-tag jet scale uncertainties. ");
492 break;
493 default:
494 break;
495 }
496 } else {
497 ATH_MSG_DEBUG( "No valid large-R Z-tagged fat jet uncertainty, but FillJet called with a fat jet. Skipping uncertainties." );
498 }
499
500 if (!m_TopTagjetUncertaintiesTool.empty() && !m_TopTagUncConfig.empty() && !m_ToptagConfig.empty() && doLargeRdecorations) {
501 CP::CorrectionCode result = m_TopTagjetUncertaintiesTool->applyCorrection(input);
502 switch (result) {
504 ATH_MSG_ERROR( "Failed to apply largeR Top-tag jet scale uncertainties.");
505 return StatusCode::FAILURE;
506 //break;
508 ATH_MSG_VERBOSE( "No valid pt/eta/m range for largeR Top-tag jet scale uncertainties. ");
509 break;
510 default:
511 break;
512 }
513 } else {
514 ATH_MSG_DEBUG( "No valid large-R Top-tagged fat jet uncertainty, but FillJet called with a fat jet. Skipping uncertainties." );
515 }
516
517 if (!m_fatjetUncertaintiesTool.empty() && m_currentSyst.name().find("PseudoData") == std::string::npos) {
518 CP::CorrectionCode result = m_fatjetUncertaintiesTool->applyCorrection(input);
519 switch (result) {
521 ATH_MSG_ERROR( "Failed to apply largeR jet scale uncertainties.");
522 return StatusCode::FAILURE;
523 //break;
525 ATH_MSG_VERBOSE( "No valid pt/eta/m range for largeR jet scale uncertainties. ");
526 break;
527 default:
528 break;
529 }
530 } else {
531 ATH_MSG_DEBUG( "No valid fat jet uncertainty, but FillJet called with a fat jet. Skipping uncertainties." );
532 }
533
534 // Use the PDSmeared uncertainties tool on the systematic with PseudoData in the name
535 if (!m_fatjetUncertaintiesPDSmearTool.empty() && m_fatJetUncertaintiesPDsmearing && m_currentSyst.name().find("PseudoData")) {
536 CP::CorrectionCode result = m_fatjetUncertaintiesPDSmearTool->applyCorrection(input);
537 switch (result) {
539 ATH_MSG_ERROR( "Failed to apply largeR jet scale PD uncertainties.");
540 return StatusCode::FAILURE;
541 //break;
543 ATH_MSG_VERBOSE( "No valid pt/eta/m range for largeR jet scale uncertainties. ");
544 break;
545 default:
546 break;
547 }
548 } else {
549 ATH_MSG_DEBUG( "No valid fat jet uncertainty, but FillJet called with a fat jet. Skipping uncertainties." );
550 }
551
553 CP::CorrectionCode result = m_fatjetFFSmearingTool->applyCorrection(input);
554 switch (result) {
556 ATH_MSG_ERROR( "Failed to apply largeR jet scale uncertainties.");
557 return StatusCode::FAILURE;
558 //break;
560 ATH_MSG_VERBOSE( "No valid pt/eta/m range for largeR jet scale uncertainties. ");
561 break;
562 default:
563 break;
564 }
565 } else {
566 ATH_MSG_DEBUG( "No valid fat jet uncertainty, but FillJet called with a fat jet. Skipping uncertainties." );
567 }
568
569 ATH_MSG_VERBOSE( "Large-R jet (pt,eta,phi) after calibration " << input.pt() << " " << input.eta() << " " << input.phi() );
570
571 return StatusCode::SUCCESS;
572 }
573 ATH_MSG_VERBOSE( "jet (pt,eta,phi) after calibration " << input.pt() << " " << input.eta() << " " << input.phi() );
574
575 }
576
577 dec_passOR(input) = true;
578 dec_bjet_jetunc(input) = false;
579
580 if (m_useBtagging) {
581 if (m_BtagWP != "Continuous") this->IsBJet(input);
582 else this->IsBJetContinuous(input);
583 }
584
585 if ( (input.pt() > m_jetPt) || (input.pt() > 15e3) ) {
586 if(!isFat && m_currentSyst.name().find("PseudoData") == std::string::npos) {
587 // Use the normal jet uncertainties tool for this systematic and do not use the PDSmeared initialised tool
588 CP::CorrectionCode result = m_jetUncertaintiesTool->applyCorrection(input);
589 switch (result) {
591 ATH_MSG_ERROR( "Failed to apply JES correction" );
592 break;
594 ATH_MSG_WARNING( "JES correction OutOfValidity range."); // Jet (pt,eta,phi) = (" << input.pt() << ", " << input.eta() << ", " << input.phi() << ")");
595 break;
596 default:
597 break;
598 }
599 }
600 }
601
603 if ( (input.pt() > m_jetPt) || (input.pt() > 15e3) ) {
604 if(!isFat && m_currentSyst.name().find("PseudoData")){
605 // Use the PDSmeared uncertainties tool on the systematic with PseudoData in the name
606 CP::CorrectionCode result = m_jetUncertaintiesPDSmearTool->applyCorrection(input);
607 switch (result) {
609 ATH_MSG_ERROR( "Failed to apply JES correction" );
610 break;
612 ATH_MSG_WARNING( "JES correction OutOfValidity range."); // Jet (pt,eta,phi) = (" << input.pt() << ", " << input.eta() << ", " << input.phi() << ")");
613 break;
614 default:
615 break;
616 }
617 }
618 }
619 }
620
621
622 ATH_MSG_VERBOSE( "jet (pt,eta,phi) after JES correction " << input.pt() << " " << input.eta() << " " << input.phi() );
623
624 dec_passJvt(input) = !m_applyJVTCut || m_jetNNJvtSelectionTool->accept(&input);
625 dec_passFJvt(input) = !m_doFwdJVT || m_jetfJvtSelectionTool->accept(&input);
626 dec_baseline(input) = ( input.pt() > m_jetPt ) || ( input.pt() > 20e3 ); // Allows for setting m_jetPt < 20e3
627 dec_bad(input) = false;
628 dec_signal_less_JVT(input) = false;
629 dec_signal(input) = false;
630 dec_bjet_loose(input) = false;
631 dec_effscalefact(input) = 1.;
632
633 //new state for OR . 0=non-baseline objects, 1=for baseline jets not passing JVT, 2=for any other baseline object
634 if (acc_baseline(input) ){
635 if( acc_passJvt(input) ) dec_selected(input) = 2;
636 else dec_selected(input) = 1;
637 }
638 else{
639 dec_selected(input) = 0;
640 }
641
642 if (m_useBtagging && !m_orBtagWP.empty()) {
643 dec_bjet_loose(input) = this->IsBJetLoose(input);
644 }
645
646 if (m_debug) {
647 ATH_MSG_INFO( "JET pt: " << input.pt() );
648 ATH_MSG_INFO( "JET eta: " << input.eta() );
649 ATH_MSG_INFO( "JET phi: " << input.phi() );
650 ATH_MSG_INFO( "JET E: " << input.e() );
651 ATH_MSG_INFO( "JET Ceta: " << input.jetP4(xAOD::JetConstitScaleMomentum).eta() );
652 ATH_MSG_INFO( "JET Cphi: " << input.jetP4(xAOD::JetConstitScaleMomentum).phi() );
653 ATH_MSG_INFO( "JET CE: " << input.jetP4(xAOD::JetConstitScaleMomentum).e() );
654 ATH_MSG_INFO( "JET Cm: " << input.jetP4(xAOD::JetConstitScaleMomentum).M() ); // fix-me M
655
656 }
657
658 return StatusCode::SUCCESS;
659 }
bool IsBJetLoose(const xAOD::Jet &input) const override final
Definition Jets.cxx:698
int IsBJetContinuous(const xAOD::Jet &input) const override final
Definition Jets.cxx:811
bool IsBJet(const xAOD::Jet &input) const override final
Definition Jets.cxx:789
static const SG::Decorator< char > dec_passOR("passOR")
static const SG::Decorator< char > dec_passFJvt("passFJvt")
static const SG::ConstAccessor< int > acc_ztagged("ztagged")
static const SG::Decorator< int > dec_toptagged("toptagged")
static const SG::Decorator< char > dec_signal_less_JVT("signal_less_JVT")
Decorator for signal jets without a JVT requirement.
static const SG::ConstAccessor< char > acc_passJvt("passJvt")
static const SG::Decorator< char > dec_passJvt("passJvt")
static const SG::Decorator< double > dec_btag_weight("btag_weight")
static const SG::ConstAccessor< char > acc_baseline("baseline")
static const SG::Decorator< char > dec_bjet_jetunc("bjet_jetunc")
static const SG::Decorator< int > dec_ztagged("ztagged")
static const SG::Decorator< int > dec_wtagged("wtagged")
static const SG::Decorator< char > dec_bad("bad")
static const SG::ConstAccessor< int > acc_wtagged("wtagged")
static const SG::ConstAccessor< int > acc_toptagged("toptagged")
static const SG::Decorator< char > dec_bjet_loose("bjet_loose")
@ JetConstitScaleMomentum
Definition JetTypes.h:29

◆ FillMuon()

StatusCode ST::SUSYObjDef_xAOD::FillMuon ( xAOD::Muon & input,
const float ptcut,
const float etacut )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 212 of file Muons.cxx.

212 {
213
214 ATH_MSG_VERBOSE( "Starting FillMuon on mu with pt=" << input.pt() );
215
216 dec_baseline(input) = false;
217 dec_selected(input) = 0;
218 dec_signal(input) = false;
219 dec_isol(input) = false;
220 dec_isolHighPt(input) = false;
221 dec_passedHighPtCuts(input) = false;
222 dec_passSignalID(input) = false;
223
224 if (m_muEffCorrForce1D) {
225 dec_DFCommonJetDr(input) = -2.0;
226 } else if (!acc_DFCommonJetDr.isAvailable(input)) {
227 dec_dRJet(input) = -2.0;
228 }
229
230 // don't bother calibrating or computing WP
231 if ( input.pt() < 3e3 ) return StatusCode::SUCCESS;
232
233 ATH_MSG_VERBOSE( "MUON pt before calibration " << input.pt() );
234
235 ATH_MSG_VERBOSE( "MUON eta = " << input.eta() );
236 ATH_MSG_VERBOSE( "MUON type = " << input.muonType() );
237 ATH_MSG_VERBOSE( "MUON author = " << input.author() );
238
239 if (m_muonCalibTool->applyCorrection( input ) == CP::CorrectionCode::OutOfValidityRange){
240 ATH_MSG_VERBOSE("FillMuon: applyCorrection out of validity range");
241 }
242
243 ATH_MSG_VERBOSE( "MUON pt after calibration " << input.pt() );
244
245 const xAOD::EventInfo* evtInfo = nullptr;
246 ATH_CHECK( evtStore()->retrieve( evtInfo, "EventInfo" ) );
247 const xAOD::Vertex* pv = this->GetPrimVtx();
248 double primvertex_z = pv ? pv->z() : 0;
249 //const xAOD::TrackParticle* track = input.primaryTrackParticle();
251 if (input.muonType() == xAOD::Muon::SiliconAssociatedForwardMuon) {
252 track = input.trackParticle(xAOD::Muon::CombinedTrackParticle);
253 if (!track) return StatusCode::SUCCESS; // don't treat SAF muons without CB track further
254 }
255 else {
256 track = input.primaryTrackParticle();
257 }
258
259 //impact parameters (after applyCorrection() so to have the primaryTrack links restored in old buggy samples)
260 if (track){
261 dec_z0sinTheta(input) = (track->z0() + track->vz() - primvertex_z) * TMath::Sin(input.p4().Theta());
262 } else {
263 ATH_MSG_WARNING("FillMuon: Muon of pT and eta " << input.pt() << " MeV " << input.eta() << " has no associated track");
264 }
265 //protect against exception thrown for null or negative d0sig
266 try {
267 if (track)
269 else
270 dec_d0sig(input) = -99.;
271 }
272 catch (...) {
273 float d0sigError = -99.;
274 ATH_MSG_WARNING("FillMuon : Exception caught from d0significance() calculation. Setting dummy decoration d0sig=" << d0sigError );
275 dec_d0sig(input) = d0sigError;
276 }
277
278 if (m_debug) {
279 // Summary variables in
280 // /cvmfs/atlas.cern.ch/repo/sw/ASG/AnalysisBase/2.0.3/xAODTracking/Root/TrackSummaryAccessors_v1.cxx
281
282 unsigned char nBLHits(0), nPixHits(0), nPixelDeadSensors(0), nPixHoles(0),
283 nSCTHits(0), nSCTDeadSensors(0), nSCTHoles(0), nTRTHits(0), nTRTOutliers(0);
284
285 if (track){
286 track->summaryValue( nBLHits, xAOD::numberOfBLayerHits);
287 track->summaryValue( nPixHits, xAOD::numberOfPixelHits);
288 track->summaryValue( nPixelDeadSensors, xAOD::numberOfPixelDeadSensors);
289 track->summaryValue( nPixHoles, xAOD::numberOfPixelHoles);
290
291 track->summaryValue( nSCTHits, xAOD::numberOfSCTHits);
292 track->summaryValue( nSCTDeadSensors, xAOD::numberOfSCTDeadSensors);
293 track->summaryValue( nSCTHoles, xAOD::numberOfSCTHoles);
294
295 track->summaryValue( nTRTHits, xAOD::numberOfTRTHits);
296 track->summaryValue( nTRTOutliers, xAOD::numberOfTRTOutliers);
297 }
298
299 ATH_MSG_INFO( "MUON pt: " << input.pt() );
300 ATH_MSG_INFO( "MUON eta: " << input.eta() );
301 ATH_MSG_INFO( "MUON phi: " << input.phi() );
302 ATH_MSG_INFO( "MUON comb: " << (input.muonType() == xAOD::Muon::Combined));
303 ATH_MSG_INFO( "MUON sTag: " << (input.muonType() == xAOD::Muon::SegmentTagged));
304 ATH_MSG_INFO( "MUON loose:" << (input.quality() == xAOD::Muon::Loose));
305 ATH_MSG_INFO( "MUON bHit: " << static_cast<int>( nBLHits ));
306 ATH_MSG_INFO( "MUON pHit: " << static_cast<int>( nPixHits ));
307 ATH_MSG_INFO( "MUON pDead:" << static_cast<int>( nPixelDeadSensors ));
308 ATH_MSG_INFO( "MUON pHole:" << static_cast<int>( nPixHoles ));
309 ATH_MSG_INFO( "MUON sHit: " << static_cast<int>( nSCTHits));
310 ATH_MSG_INFO( "MUON sDead:" << static_cast<int>( nSCTDeadSensors ));
311 ATH_MSG_INFO( "MUON sHole:" << static_cast<int>( nSCTHoles ));
312 ATH_MSG_INFO( "MUON tHit: " << static_cast<int>( nTRTHits ));
313 ATH_MSG_INFO( "MUON tOut: " << static_cast<int>( nTRTOutliers ));
314
315 const xAOD::TrackParticle* idtrack =
316 input.trackParticle( xAOD::Muon::InnerDetectorTrackParticle );
317
318 if ( !idtrack) {
319 ATH_MSG_VERBOSE( "No ID track!! " );
320 } else {
321 ATH_MSG_VERBOSE( "ID track pt: " << idtrack->pt());
322 }
323 }
324
325 if ( !m_force_noMuId && !m_muonSelectionToolBaseline->accept(input)) return StatusCode::SUCCESS;
326
327 if (input.pt() <= ptcut || std::abs(input.eta()) >= etacut) return StatusCode::SUCCESS;
328
329 if (m_mubaselinez0>0. && std::abs(acc_z0sinTheta(input))>m_mubaselinez0) return StatusCode::SUCCESS;
330 if (m_mubaselined0sig>0. && std::abs(acc_d0sig(input))>m_mubaselined0sig) return StatusCode::SUCCESS;
331
332 //--- Do baseline isolation check
333 if ( !( m_muBaselineIso_WP.empty() ) && !( m_isoBaselineTool->accept(input) ) ) return StatusCode::SUCCESS;
334
335 dec_baseline(input) = true;
336 dec_selected(input) = 2;
337
338 //disable if (!m_muIso_WP.empty() && m_muIso_WP.find("PLV")!=std::string::npos) ATH_CHECK( m_isoToolLowPtPLV->augmentPLV(input) );
339 if (!m_muIso_WP.empty()) dec_isol(input) = bool(m_isoTool->accept(input));
340 if (!m_muIsoHighPt_WP.empty()) dec_isolHighPt(input) = bool(m_isoHighPtTool->accept(input));
341 dec_passSignalID(input) = bool(m_muonSelectionTool->accept(input));
342
343 ATH_MSG_VERBOSE("FillMuon: passed baseline selection");
344 return StatusCode::SUCCESS;
345}
virtual double pt() const override final
The transverse momentum ( ) of the particle.
float nPixelDeadSensors(const U &p)
float nSCTHoles(const U &p)
float nSCTHits(const U &p)
float nSCTDeadSensors(const U &p)
float nTRTHits(const U &p)
static const SG::Decorator< float > dec_DFCommonJetDr("DFCommonJetDr")
static const SG::Decorator< float > dec_dRJet("dRJet")
static const SG::Decorator< char > dec_passedHighPtCuts("passedHighPtCuts")
static const SG::ConstAccessor< float > acc_DFCommonJetDr("DFCommonJetDr")
@ numberOfPixelHoles
number of pixel layers on track with absence of hits [unit8_t].
@ numberOfTRTHits
number of TRT hits [unit8_t].
@ numberOfBLayerHits
these are the hits in the first pixel layer, i.e.
@ numberOfSCTDeadSensors
number of dead SCT sensors crossed [unit8_t].
@ numberOfTRTOutliers
number of TRT outliers [unit8_t].
@ numberOfPixelDeadSensors
number of dead pixel sensors crossed [unit8_t].
@ numberOfSCTHoles
number of SCT holes [unit8_t].

◆ FillPhoton()

StatusCode ST::SUSYObjDef_xAOD::FillPhoton ( xAOD::Photon & input,
const float ptcut,
const float etacut )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 81 of file Photons.cxx.

81 {
82
83 ATH_MSG_VERBOSE( "Starting FillPhoton on ph with pre-calibration pt=" << input.pt() );
84
85 if ( !input.caloCluster() ) {
86 ATH_MSG_WARNING( "FillPhoton: no caloCluster found: " << input.caloCluster() );
87 return StatusCode::SUCCESS;
88 }
89
90 //Check DeadHVCellRemoval
91 bool pass_deadHVTool = m_deadHVTool->accept(&input);
92
93 if (m_debug) {
94 ATH_MSG_INFO( "PHOTON eta: " << input.eta() );
95 ATH_MSG_INFO( "PHOTON phi: " << input.phi() );
96 ATH_MSG_INFO( "PHOTON cl eta: " << input.caloCluster()->eta() );
97 ATH_MSG_INFO( "PHOTON cl phi: " << input.caloCluster()->phi() );
98 ATH_MSG_INFO( "PHOTON cl e: " << input.caloCluster()->e() );
99 ATH_MSG_INFO( "PHOTON OQ: " << input.OQ() );
100 ATH_MSG_INFO( "PHOTON author: " << input.author() );
101 ATH_MSG_INFO( "PHOTON deadHVTools: " << pass_deadHVTool );
102 }
103
104 dec_baseline(input) = false;
105 dec_selected(input) = 0;
106 dec_isol(input) = false;
107 dec_isEM(input) = 0;
108
109 if (!pass_deadHVTool) return StatusCode::SUCCESS;
110
111 // Author cuts needed according to https://twiki.cern.ch/twiki/bin/view/AtlasProtected/EGammaIdentificationRun2#Photon_authors
113 return StatusCode::SUCCESS;
114
115 // calibrate the photon 4-vector here only if within eta window
116 if (std::abs(input.caloCluster()->etaBE(2)) >= etacut) return StatusCode::SUCCESS;
117
119 if ( std::abs( input.caloCluster()->etaBE(2) ) >1.37 && std::abs( input.caloCluster()->etaBE(2) ) <1.52) {
120 return StatusCode::SUCCESS;
121 }
122 }
123
124 if (m_egammaCalibTool->applyCorrection(input) != CP::CorrectionCode::Ok)
125 ATH_MSG_ERROR("FillPhoton: EgammaCalibTool applyCorrection failed");
126
127 if (m_isoCorrTool->applyCorrection(input) != CP::CorrectionCode::Ok)
128 ATH_MSG_ERROR("FillPhoton: IsolationCorrectionTool applyCorrection failed");
129
130 ATH_MSG_VERBOSE( "FillPhoton: post-calibration pt=" << input.pt() );
131
132 if (input.pt() < ptcut) return StatusCode::SUCCESS;
133
134 //Object quality cut as described at https://twiki.cern.ch/twiki/bin/view/AtlasProtected/EGammaIdentificationRun2#Object_quality_cut
136 return StatusCode::SUCCESS;
137
138 //Photon quality as in https://twiki.cern.ch/twiki/bin/view/AtlasProtected/EGammaIdentificationRun2#Photon_cleaning
139 bool passPhCleaning = false;
141 if ( (!m_photonAllowLate && acc_passPhCleaning(input)) || (m_photonAllowLate && acc_passPhCleaningNoTime(input)) ) passPhCleaning = true;
142 } else {
143 ATH_MSG_VERBOSE ("DFCommonPhotonsCleaning is not found in DAOD..");
145 ( m_photonAllowLate && PhotonHelpers::passOQqualityDelayed(input)) ) passPhCleaning = true;
146 }
147 if (!passPhCleaning) return StatusCode::SUCCESS;
148
149
150 bool passBaseID = false;
151 if (m_acc_photonIdBaseline.isAvailable(input)) {
152 passBaseID = bool(m_acc_photonIdBaseline(input));
153 } else {
154 passBaseID = bool(m_photonSelIsEMBaseline->accept(&input));
155 }
156 if (!passBaseID) return StatusCode::SUCCESS;
157
158 //--- Do baseline isolation check
159 if ( !( m_photonBaselineIso_WP.empty() ) && !( m_isoBaselineTool->accept(input) ) ) return StatusCode::SUCCESS;
160
161 dec_baseline(input) = true;
162 dec_selected(input) = 2;
163 if (!m_photonIso_WP.empty()) dec_isol(input) = bool(m_isoTool->accept(input));
164
165 ATH_MSG_VERBOSE("FillPhoton: passed baseline selection.");
166 return StatusCode::SUCCESS;
167}
bool passOQqualityDelayed(const xAOD::Photon &ph)
Helpers to ease the implementation of the pass Quality requirements.
bool passOQquality(const xAOD::Photon &ph)
Helper to ease the implemmantation of the pass Quality requirements.
static const SG::ConstAccessor< char > acc_passPhCleaning("DFCommonPhotonsCleaning")
static const SG::Decorator< unsigned > dec_isEM("isEM")
static const SG::ConstAccessor< char > acc_passPhCleaningNoTime("DFCommonPhotonsCleaningNoTime")
const uint16_t AuthorPhoton
Object Reconstructed by standard cluster-based algorithm.
Definition EgammaDefs.h:28
const uint32_t BADCLUSPHOTON
Definition EgammaDefs.h:124
const uint16_t AuthorAmbiguous
Object Reconstructed by standard cluster-based algorithm.
Definition EgammaDefs.h:32

◆ FillTau()

StatusCode ST::SUSYObjDef_xAOD::FillTau ( xAOD::TauJet & input)
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 81 of file Taus.cxx.

81 {
82
83 ATH_MSG_VERBOSE( "Starting FillTau on tau with pT = " << input.pt()/1000 << " GeV" );
84 ATH_MSG_VERBOSE( "TAU pT before smearing " << input.pt()/1000 << " GeV");
85
86 // do truth matching first (required unless already done in AOD->DAOD and truth matching info kept in DAOD)
87 if (m_tauDoTTM && !isData()) m_tauTruthMatch->getTruth(input);
88 ATH_MSG_VERBOSE("Tau truth matching done");
89
90 // apply the calibration to data as well (not needed in R22, unless MVA TES gets updated)
91 if (std::abs(input.eta()) <= 2.5 && input.nTracks() > 0) {
92 if (m_tauSmearingTool->applyCorrection(input) != CP::CorrectionCode::Ok) {
93 ATH_MSG_ERROR(" Tau smearing failed " );
94 } else { ATH_MSG_VERBOSE("Tau smearing done"); }
95 }
96
97 ATH_MSG_VERBOSE( "TAU pt after smearing " << input.pt()/1000. );
98
99 // if tauPrePtCut set, apply min pT cut here before calling tau selection tool
100 // (avoid exceptions when running on derivations with removed tracks for low-pT taus, e.g. HIGG4D2)
101 if (input.pt() > m_tauPrePtCut) {
102 dec_baseline(input) = bool(m_tauSelToolBaseline->accept( input ));
103 }
104 else {
105 dec_baseline(input) = false;
106 }
107 if (acc_baseline(input)) dec_selected(input) = 2;
108 else dec_selected(input) = 0;
109
110 if (acc_baseline(input)) ATH_MSG_VERBOSE("FillTau: passed baseline selection");
111 else ATH_MSG_VERBOSE("FillTau: failed baseline selection");
112 return StatusCode::SUCCESS;
113}

◆ FillTrackJet()

StatusCode ST::SUSYObjDef_xAOD::FillTrackJet ( xAOD::Jet & input)
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 661 of file Jets.cxx.

661 {
662
663 ATH_MSG_VERBOSE( "Starting FillTrackJet on jet with pt=" << input.pt() );
664
665 dec_btag_weight(input) = -999.;
666 dec_effscalefact(input) = 1.;
667
668 if (m_defaultTrackJets == "AntiKtVR30Rmax4Rmin02TrackJets") {
669 // VR recommendation
670 // https://twiki.cern.ch/twiki/bin/view/AtlasProtected/BTagCalib2017#Recommendations_for_variable_rad
671 dec_baseline(input) = input.pt() >= 5e3 && input.numConstituents() >= 2;
672 if (m_trkJetPt < 10e3)
673 ATH_MSG_WARNING ("The pt threshold of VR jets you set is: " << m_trkJetPt/1000. << " GeV. But VR jets with pt < 10GeV are uncalibrated.");
674 dec_signal(input) = acc_baseline(input) && input.pt() >= m_trkJetPt && std::abs(input.eta()) <= m_trkJetEta;
675 dec_VRradius(input) = std::max(0.02,std::min(0.4,30000./input.pt()));
676 dec_passDRcut(input) = acc_signal(input);
677 } else {
678 dec_baseline(input) = input.pt() >= m_trkJetPt && std::abs(input.eta()) <= m_trkJetEta;
679 dec_signal(input) = acc_baseline(input);
680 }
681
683 if (m_BtagWP_trkJet != "Continuous") this->IsTrackBJet(input);
684 else this->IsTrackBJetContinuous(input);
685 }
686
687 if (m_debug) {
688 ATH_MSG_INFO( "TRK JET pt: " << input.pt() );
689 ATH_MSG_INFO( "TRK JET eta: " << input.eta() );
690 ATH_MSG_INFO( "TRK JET phi: " << input.phi() );
691 ATH_MSG_INFO( "TRK JET E: " << input.e() );
692 }
693
694 return StatusCode::SUCCESS;
695 }
std::string m_defaultTrackJets
bool IsTrackBJet(const xAOD::Jet &input) const override final
Definition Jets.cxx:800
int IsTrackBJetContinuous(const xAOD::Jet &input) const override final
Definition Jets.cxx:833
static const SG::Decorator< float > dec_VRradius("VRradius")
static const SG::Decorator< char > dec_passDRcut("passDRcut")

◆ FindSusyHardProc() [1/2]

bool ST::SUSYObjDef_xAOD::FindSusyHardProc ( const xAOD::TruthEvent * truthE,
int & pdgid1,
int & pdgid2 )
static

Definition at line 227 of file Truth.cxx.

227 {
228
229 pdgid1 = 0;
230 pdgid2 = 0;
231
232 //go for TRUTH1-like ...
233 const xAOD::TruthParticle* firstsp(nullptr);
234 const xAOD::TruthParticle* secondsp(nullptr);
235
236 for (unsigned int p=0; p < truthE->nTruthParticles(); ++p){
237
238 const xAOD::TruthParticle* tp = truthE->truthParticle(p);
239
240 //check ifSUSY particle
241 if (MC::isSquark(tp) || MC::isSlepton(tp) || MC::isGaugino(tp)) {
242
243 if (tp->nParents() != 0) {
244 if ( !MC::isSUSY(tp->parent(0))) {
245 if (!firstsp) {
246 firstsp = tp;
247 } else if (!secondsp) {
248 secondsp = tp;
249 } else {
250 if (firstsp->nChildren() != 0 && HepMC::is_same_particle(tp,firstsp->child(0))) {
251 firstsp = tp;
252 }
253 else if (secondsp->nChildren() != 0 && HepMC::is_same_particle(tp,secondsp->child(0))) {
254 secondsp = tp;
255 }
256 else if (firstsp->nChildren() != 0 && HepMC::is_same_particle(firstsp->child(0),secondsp)) {
257 firstsp = secondsp;
258 secondsp = tp;
259 }
260 else if (secondsp->nChildren() != 0 && HepMC::is_same_particle(secondsp->child(0),firstsp)) {
261 secondsp = firstsp;
262 firstsp = tp;
263 }
264 }
265 }
266 }
267 }
268 }
269
270 // quit if no sparticles found
271 if (!firstsp && !secondsp) return true; // should find none or two
272
273 if (firstsp->nChildren() == 1) {
274 for (unsigned int p=0; p < truthE->nTruthParticles(); ++p){
275 const xAOD::TruthParticle* tp = truthE->truthParticle(p);
276 if (HepMC::is_same_particle(tp,firstsp->child(0)) && tp->pdgId() != firstsp->pdgId()) {
277 firstsp = tp;
278 break;
279 }
280 }
281 }
282
283 if (secondsp->nChildren() == 1) {
284 for (unsigned int p=0; p < truthE->nTruthParticles(); ++p){
285 const xAOD::TruthParticle* tp = truthE->truthParticle(p);
286 if (HepMC::is_same_particle(tp,secondsp->child(0)) && tp->pdgId() != secondsp->pdgId()) {
287 secondsp = tp;
288 break;
289 }
290 }
291 }
292
293 if (MC::isSUSY(firstsp)) pdgid1 = firstsp->pdgId();
294 if (MC::isSUSY(secondsp)) pdgid2 = secondsp->pdgId();
295
296 // Return gracefully:
297 return true;
298}
const TruthParticle * truthParticle(size_t index) const
Get a pointer to one of the truth particles.
size_t nTruthParticles() const
Get the number of truth particles.
int pdgId() const
PDG ID code.
const TruthParticle_v1 * parent(size_t i) const
Retrieve the i-th mother (TruthParticle) of this TruthParticle.
size_t nParents() const
Number of parents of this particle.
bool is_same_particle(const T1 &p1, const T2 &p2)
Method to establish if two particles in the GenEvent actually represent the same particle.
bool isSlepton(const T &p)
bool isSquark(const T &p)
PDG rule 11d Fundamental supersymmetric particles are identified by adding a nonzero n to the particl...
bool isSUSY(const T &p)
bool isGaugino(const T &p)
TruthParticle_v1 TruthParticle
Typedef to implementation.

◆ FindSusyHardProc() [2/2]

bool ST::SUSYObjDef_xAOD::FindSusyHardProc ( const xAOD::TruthParticleContainer * truthP,
int & pdgid1,
int & pdgid2,
bool isTruth3 = false )
static

Definition at line 126 of file Truth.cxx.

126 {
127
128 pdgid1 = 0;
129 pdgid2 = 0;
130
131 //check for TRUTH3 structure first
132 if(isTruth3){
133 if(!truthP || truthP->size()<2){
134 return false;
135 }
136
137 //get ID of first two BSM particles
138 pdgid1 = (*truthP)[0]->pdgId();
139 pdgid2 = (*truthP)[1]->pdgId();
140 return true;
141 }
142
143 //go for TRUTH1-like if not...
144 const xAOD::TruthParticle* firstsp(nullptr);
145 const xAOD::TruthParticle* secondsp(nullptr);
146
147 if (!truthP || truthP->empty()) {
148 return false;
149 }
150 for (const xAOD::TruthParticle* tp : *truthP) {
151 if (MC::isSquark(tp) || MC::isSlepton(tp) || MC::isGaugino(tp)) {
152
153 if (tp->nParents() != 0) {
154
155 if ( !MC::isSUSY(tp->parent(0))) {
156 if (!firstsp) {
157 firstsp = tp;
158 } else if (!secondsp) {
159 secondsp = tp;
160 } else {
161 if (firstsp->nChildren() != 0 && HepMC::is_same_particle(tp,firstsp->child(0))) {
162 firstsp = tp;
163 }
164 else if (secondsp->nChildren() != 0 && HepMC::is_same_particle(tp,secondsp->child(0))) {
165 secondsp = tp;
166 }
167 else if (firstsp->nChildren() != 0 && HepMC::is_same_particle(firstsp->child(0),secondsp)) {
168 firstsp = secondsp;
169 secondsp = tp;
170 }
171 else if (secondsp->nChildren() != 0 && HepMC::is_same_particle(secondsp->child(0),firstsp)) {
172 secondsp = firstsp;
173 firstsp = tp;
174 }
175 }
176 }
177 }
178 }
179 }
180
181 // quit if no sparticles found
182 if (!firstsp && !secondsp) return true; // should find none or two
183
184 if (firstsp->nChildren() == 1) {
185 for (const xAOD::TruthParticle* tp : *truthP) {
186 if (HepMC::is_same_particle(tp,firstsp->child(0)) && tp->pdgId() != firstsp->pdgId()) {
187 firstsp = tp;
188 break;
189 }
190 }
191 }
192
193 if (secondsp->nChildren() == 1) {
194 for (const xAOD::TruthParticle* tp : *truthP) {
195 if (HepMC::is_same_particle(tp,secondsp->child(0)) && tp->pdgId() != secondsp->pdgId()) {
196 secondsp = tp;
197 break;
198 }
199 }
200 }
201
202 if (MC::isSUSY(firstsp)) pdgid1 = firstsp->pdgId();
203 if (MC::isSUSY(secondsp)) pdgid2 = secondsp->pdgId();
204
205 // Return gracefully:
206 return true;
207}
size_type size() const noexcept
Returns the number of elements in the collection.
bool empty() const noexcept
Returns true if the collection is empty.

◆ FindSusyHP() [1/3]

StatusCode ST::SUSYObjDef_xAOD::FindSusyHP ( const xAOD::TruthEvent * truthE,
int & pdgid1,
int & pdgid2 ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 210 of file Truth.cxx.

210 {
211
212 if (!truthE) {
213 ATH_MSG_ERROR("Null TruthEvent pointer!!");
214 return StatusCode::FAILURE;
215 }
216 if ( !SUSYObjDef_xAOD::FindSusyHardProc(truthE, pdgid1, pdgid2) ) {
217 ATH_MSG_ERROR("Problem finding SUSY hard process");
218 return StatusCode::FAILURE;
219 }
220 if (pdgid1 == 0 || pdgid2 == 0) {
221 ATH_MSG_DEBUG("No sparticles found!");
222 }
223 return StatusCode::SUCCESS;
224}
static bool FindSusyHardProc(const xAOD::TruthParticleContainer *truthP, int &pdgid1, int &pdgid2, bool isTruth3=false)
Definition Truth.cxx:126

◆ FindSusyHP() [2/3]

StatusCode ST::SUSYObjDef_xAOD::FindSusyHP ( const xAOD::TruthParticleContainer * truthP,
int & pdgid1,
int & pdgid2,
bool isTruth3 = false ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 106 of file Truth.cxx.

106 {
107 if (!truthP) {
108 ATH_MSG_ERROR("Null TruthParticleContainer pointer!!");
109 return StatusCode::FAILURE;
110 }
111 if (truthP->empty()) {
112 ATH_MSG_ERROR("Empty TruthParticleContainer!!");
113 return StatusCode::FAILURE;
114 }
115 if ( !SUSYObjDef_xAOD::FindSusyHardProc(truthP, pdgid1, pdgid2, isTruth3) ) {
116 ATH_MSG_ERROR("Problem finding SUSY hard process");
117 return StatusCode::FAILURE;
118 }
119 if (pdgid1 == 0 || pdgid2 == 0) {
120 ATH_MSG_DEBUG("No sparticles found!");
121 }
122 return StatusCode::SUCCESS;
123}

◆ FindSusyHP() [3/3]

StatusCode ST::SUSYObjDef_xAOD::FindSusyHP ( int & pdgid1,
int & pdgid2 ) const

Definition at line 76 of file Truth.cxx.

76 {
77
78 const xAOD::TruthParticleContainer* truthP = nullptr;
79 bool isTruth3 = false;
80 std::string key_T1 = "TruthParticles";
81 std::string key_T3 = "TruthBSM";
82
83 ATH_MSG_DEBUG("Contains " << key_T1 << ": " << ((evtStore()->contains<xAOD::TruthParticleContainer>( key_T1 ))?1:0));
84 ATH_MSG_DEBUG("Contains " << key_T3 << ": " << ((evtStore()->contains<xAOD::TruthParticleContainer>( key_T3 ))?1:0));
85
87 ATH_CHECK( evtStore()->retrieve(truthP, key_T1) );
88 ATH_MSG_DEBUG("Retrieved " << key_T1 << " : size = " << truthP->size());
89 if (truthP->empty()) { ATH_MSG_WARNING(key_T1 << " is empty. Skipping FindSusyHP."); return StatusCode::SUCCESS; }
90 }
92 isTruth3=true;
93 ATH_CHECK( evtStore()->retrieve(truthP, key_T3) );
94 ATH_MSG_DEBUG("Retrieved " << key_T3 << " : size = " << truthP->size());
95 if (truthP->empty()) { ATH_MSG_WARNING(key_T3 << " is empty. Skipping FindSusyHP."); return StatusCode::SUCCESS; }
96 }
97 else {
98 ATH_MSG_WARNING("Neither " << key_T1 << " nor " << key_T3 << " are avaible. Skipping FindSusyHP.");
99 return StatusCode::SUCCESS;
100 }
101
102 return SUSYObjDef_xAOD::FindSusyHP(truthP, pdgid1, pdgid2, isTruth3);
103}
StatusCode FindSusyHP(int &pdgid1, int &pdgid2) const
Definition Truth.cxx:76
TruthParticleContainer_v1 TruthParticleContainer
Declare the latest version of the truth particle container.

◆ FJVT_SF()

double ST::SUSYObjDef_xAOD::FJVT_SF ( const xAOD::JetContainer * jets)
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 1078 of file Jets.cxx.

1078 {
1079
1080 float totalSF = 1.;
1081 if (!m_doFwdJVT) return totalSF;
1082
1083 ConstDataVector<xAOD::JetContainer> fjvtjets(SG::VIEW_ELEMENTS);
1084 for (const xAOD::Jet* jet : *jets) {
1085 // Only jets that were good for every cut except JVT
1086 if (acc_signal_less_JVT(*jet) && acc_passOR(*jet)) {
1087 fjvtjets.push_back(jet);
1088 }
1089 }
1090
1091 for (const xAOD::Jet* jet : fjvtjets) {
1092 float current_sf = 0;
1093
1094 // the SF are only applied for HS jets and implicitely requires the presense of the isHS decoration
1095 CP::CorrectionCode result;
1096 if (acc_passFJvt(*jet)) {
1097 result = m_jetfJvtEfficiencyTool->getEfficiencyScaleFactor(*jet,current_sf);
1098 }
1099 else {
1100 result = m_jetfJvtEfficiencyTool->getInefficiencyScaleFactor(*jet,current_sf);
1101 }
1102
1103 switch (result) {
1105 // this is probably not right, should report an error here
1106 ATH_MSG_ERROR("Inexplicably failed fJVT calibration" );
1107 break;
1109 // no fJvt SF for jet, that is ok e.g. for jets with |eta| < 2.5
1110 ATH_MSG_VERBOSE( "Skip SF application in SUSYTools_xAOD::FJVT_SF as jet outside validate range" );
1111 break;
1112 default:
1113 ATH_MSG_VERBOSE( "Retrieve SF for jet in SUSYTools_xAOD::FJVT_SF with value " << current_sf );
1114 totalSF *= current_sf;
1115 }
1116
1117 }
1118
1119 ATH_MSG_VERBOSE( "Retrieve total SF for jet container in SUSYTools_xAOD::FJVT_SF with value " << totalSF );
1120
1121 return totalSF;
1122 }
@ VIEW_ELEMENTS
this data object is a view, it does not own its elmts
static const SG::ConstAccessor< char > acc_passFJvt("passFJvt")
static const SG::ConstAccessor< char > acc_signal_less_JVT("signal_less_JVT")
Accessor for signal jets without a JVT requirement.

◆ FJVT_SFsys()

double ST::SUSYObjDef_xAOD::FJVT_SFsys ( const xAOD::JetContainer * jets,
const CP::SystematicSet & systConfig )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 1124 of file Jets.cxx.

1124 {
1125
1126 float totalSF = 1.;
1127 if (!m_doFwdJVT) return totalSF;
1128
1129 //Set the new systematic variation
1130 StatusCode ret = m_jetfJvtEfficiencyTool->applySystematicVariation(systConfig);
1131 if ( ret != StatusCode::SUCCESS) {
1132 ATH_MSG_ERROR("Cannot configure fJvtEfficiencyTool for systematic var. " << systConfig.name() );
1133 }
1134
1135 // Delegate
1136 totalSF = SUSYObjDef_xAOD::FJVT_SF( jets );
1137
1138 if (m_doFwdJVT) {
1139 ret = m_jetfJvtEfficiencyTool->applySystematicVariation(m_currentSyst);
1140 if ( ret != StatusCode::SUCCESS) {
1141 ATH_MSG_ERROR("Cannot configure fJvtEfficiencyTool for systematic var. " << systConfig.name() );
1142 }
1143 }
1144
1145 return totalSF;
1146 }
double FJVT_SF(const xAOD::JetContainer *jets) override final
Definition Jets.cxx:1078

◆ GetCorrectedActualInteractionsPerCrossing()

float ST::SUSYObjDef_xAOD::GetCorrectedActualInteractionsPerCrossing ( bool includeDataSF = false)
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 3087 of file SUSYObjDef_xAOD.cxx.

3087 {
3088 const xAOD::EventInfo* evtInfo = GetEventInfo();
3089 return m_prwTool->getCorrectedActualInteractionsPerCrossing( *evtInfo, includeDataSF );
3090}

◆ GetCorrectedAverageInteractionsPerCrossing()

float ST::SUSYObjDef_xAOD::GetCorrectedAverageInteractionsPerCrossing ( bool includeDataSF = false)
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 3082 of file SUSYObjDef_xAOD.cxx.

3082 {
3083 const xAOD::EventInfo* evtInfo = GetEventInfo();
3084 return m_prwTool->getCorrectedAverageInteractionsPerCrossing( *evtInfo, includeDataSF );
3085}

◆ GetDataWeight()

float ST::SUSYObjDef_xAOD::GetDataWeight ( const std::string & trig)
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 3077 of file SUSYObjDef_xAOD.cxx.

3077 {
3078 const xAOD::EventInfo* evtInfo = GetEventInfo();
3079 return m_prwTool->getDataWeight( *evtInfo, trig );
3080}

◆ getDefaultJetUncConfig()

std::string ST::SUSYObjDef_xAOD::getDefaultJetUncConfig ( )
protected

Definition at line 1897 of file SUSYObjDef_xAOD.cxx.

1897 {
1898 if (m_isRun3)
1899 return isAtlfast() ? "rel22/Spring2025_PreRec/R4_CategoryReduction_FullJER_MC23.config" : "rel22/Spring2025_PreRec/R4_CategoryReduction_FullJER_MC23.config";
1900 else
1901 return isAtlfast() ? "rel22/Spring2025_PreRec/R4_CategoryReduction_FullJER_MC20_MC21.config" : "rel22/Spring2025_PreRec/R4_CategoryReduction_FullJER_MC20_MC21.config";
1902}
bool isAtlfast() const override final

◆ GetElectrons()

StatusCode ST::SUSYObjDef_xAOD::GetElectrons ( xAOD::ElectronContainer *& copy,
xAOD::ShallowAuxContainer *& copyaux,
const bool recordSG = true,
const std::string & elekey = "Electrons",
const std::string & lrtelekey = "LRTElectrons",
const xAOD::ElectronContainer * containerToBeCopied = nullptr )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 118 of file Electrons.cxx.

119{
120 if (!m_tool_init) {
121 ATH_MSG_ERROR("SUSYTools was not initialized!!");
122 return StatusCode::FAILURE;
123 }
124
125 // Initializing prompt/LRT OR procedure
126 auto outputCol = std::make_unique<xAOD::ElectronContainer>();
127 std::unique_ptr<xAOD::ElectronAuxContainer> outputAuxCol;
128 outputAuxCol = std::make_unique<xAOD::ElectronAuxContainer>();
129 outputCol->setStore(outputAuxCol.get());
130 ATH_CHECK( m_outElectronLocation.initialize() );
131
132 if (bool(m_eleLRT) && !lrtelekey.empty() && evtStore()->contains<xAOD::ElectronContainer>(lrtelekey)){
133 ATH_MSG_DEBUG("Applying prompt/LRT electron OR procedure");
134
135 // First identify if merged container has already been made (for instances where GetElectrons() is called more than once)
136 if (evtStore()->contains<xAOD::ElectronContainer>("StdWithLRTElectrons")) {
137 ATH_MSG_DEBUG("Merged prompt/LRT container already created in TStore");
138 } else {
139 ATH_MSG_DEBUG("Creating merged prompt/LRT container in TStore");
140
141 // Retrieve prompt and LRT electrons from TStore
142 ATH_CHECK( evtStore()->retrieve(prompt_electrons, elekey) );
143 ATH_CHECK( evtStore()->retrieve(lrt_electrons, lrtelekey) );
144
145 // Remove LRT electrons as flagged by filter for uncertainty
146 auto filtered_electrons = std::make_unique<xAOD::ElectronContainer>();
147 std::unique_ptr<xAOD::ElectronAuxContainer> filtered_electrons_aux = std::make_unique<xAOD::ElectronAuxContainer>();
148 filtered_electrons->setStore(filtered_electrons_aux.get());
149 ATH_CHECK(prepareLRTElectrons(lrt_electrons, filtered_electrons.get()));
150
151 // Check overlap between prompt and LRT collections
152 std::set<const xAOD::Electron *> ElectronsToRemove;
153 m_elecLRTORTool->checkOverlap(*prompt_electrons, *filtered_electrons, ElectronsToRemove);
154
155 // Decorate electrons with prompt/LRT
156 for (const xAOD::Electron* el : *prompt_electrons) dec_isLRT(*el) = 0;
157 for (const xAOD::Electron* el : *filtered_electrons) dec_isLRT(*el) = 1;
158
159 // Create merged StdWithLRTElectrons container
160 outputCol->reserve(prompt_electrons->size() + filtered_electrons->size());
161 ATH_CHECK(MergeElectrons(*prompt_electrons, outputCol.get(), ElectronsToRemove ));
162 ATH_CHECK(MergeElectrons(*filtered_electrons, outputCol.get(), ElectronsToRemove ));
163
164 // Save merged StdWithLRTElectrons container to TStore
165 ATH_CHECK(evtStore()->record(std::move(outputCol), m_outElectronLocation.key()));
166 ATH_CHECK(evtStore()->record(std::move(outputAuxCol), m_outElectronLocation.key() + "Aux.") );
167 }
168 } else if (!lrtelekey.empty()) {
169 if(evtStore()->contains<xAOD::ElectronContainer>(lrtelekey) == false && bool(m_eleLRT) == true) ATH_MSG_WARNING("prompt/LRT OR procedure attempted but " << lrtelekey << " not in ROOT file, check config!");
170 ATH_MSG_DEBUG("Not applying prompt/LRT electron OR procedure");
171 }
172
173 if (m_isPHYSLITE && elekey.find("AnalysisElectrons")==std::string::npos){
174 ATH_MSG_ERROR("You are running on PHYSLITE derivation. Please change the Electrons container to 'AnalysisElectrons'");
175 return StatusCode::FAILURE;
176 }
177
178 const xAOD::ElectronContainer* electrons = nullptr;
179 if (bool(m_eleLRT) && evtStore()->contains<xAOD::ElectronContainer>(lrtelekey)){
180 ATH_MSG_DEBUG("Using container: " << m_outElectronLocation.key());
181 ATH_CHECK( evtStore()->retrieve(electrons, m_outElectronLocation.key()));
182 }
183 else {
184 if (copy==nullptr) { // empty container provided
185 ATH_MSG_DEBUG("Empty container provided");
186 if (containerToBeCopied != nullptr) {
187 ATH_MSG_DEBUG("Containter to be copied not nullptr");
188 electrons = containerToBeCopied;
189 }
190 else {
191 ATH_MSG_DEBUG("Getting Electrons collection");
192 ATH_CHECK( evtStore()->retrieve(electrons, elekey) );
193 }
194 }
195 }
196
197 if (copy==nullptr) { // empty container provided
199 copy = shallowcopy.first.get();
200 copyaux = shallowcopy.second.get();
201 bool setLinks = xAOD::setOriginalObjectLink(*electrons, *copy);
202 if (!setLinks) {
203 ATH_MSG_WARNING("Failed to set original object links on " << elekey);
204 }
205 if (recordSG) {
206 ATH_CHECK( evtStore()->record(std::move(shallowcopy.first), "STCalib" + elekey + m_currentSyst.name()) );
207 ATH_CHECK( evtStore()->record(std::move(shallowcopy.second), "STCalib" + elekey + m_currentSyst.name() + "Aux.") );
208 } else {
209 ATH_MSG_ERROR("Shallow copy not recorded in StoreGate!");
210 return StatusCode::FAILURE;
211 }
212 } else { // use the user-supplied collection instead
213 ATH_MSG_DEBUG("Not retrieving electron collection, using existing one provided by user");
214 electrons=copy; // this does nothing
215 }
216
217 for (const auto electron : *copy) {
220 }
221
222 return StatusCode::SUCCESS;
223}
StatusCode FillElectron(xAOD::Electron &input, const float etcut, const float etacut) override final
StatusCode prepareLRTElectrons(const xAOD::ElectronContainer *inMuons, xAOD::ElectronContainer *copy) const override final
Definition Electrons.cxx:90
StatusCode MergeElectrons(const xAOD::ElectronContainer &electrons, xAOD::ElectronContainer *outputCol, const std::set< const xAOD::Electron * > &ElectronsToRemove) const override final
Definition Electrons.cxx:61
const xAOD::ElectronContainer * lrt_electrons
SG::WriteHandleKey< xAOD::ElectronContainer > m_outElectronLocation
const xAOD::ElectronContainer * prompt_electrons
bool IsSignalElectron(const xAOD::Electron &input, const float etcut, const float d0sigcut, const float z0cut, const float etacut=DUMMYDEF) const override final
static const SG::Decorator< char > dec_isLRT("isLRT")
typename ShallowCopyResult< T >::type ShallowCopyResult_t
Return type of xAOD::shallowCopy.
Definition ShallowCopy.h:68
ElectronContainer_v1 ElectronContainer
Definition of the current "electron container version".
ShallowCopyResult_t< T > shallowCopy(const T &cont, const EventContext &ctx)
Create a shallow copy of an existing container.
bool setOriginalObjectLink(const IParticle &original, IParticle &copy)
This function should be used by CP tools when they make a deep copy of an object in their correctedCo...
Electron_v1 Electron
Definition of the current "egamma version".

◆ GetEleTriggerEfficiency()

double ST::SUSYObjDef_xAOD::GetEleTriggerEfficiency ( const xAOD::Electron & el,
const std::string & trigExpr = "SINGLE_E_2015_e24_lhmedium_L1EM20VH_OR_e60_lhmedium_OR_e120_lhloose_2016_2018_e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0" ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 595 of file Electrons.cxx.

595 {
596
597 std::string single_str = "SINGLE_E";
598 std::string single_Run3 = "202";
599 std::string dilep_str = "DI_E";
600 std::string multi_str = "MULTI_L";
601
602 double trig_eff(1.);
603
604 CP::CorrectionCode result;
605 if ( trigExpr.find(single_str) != std::string::npos || trigExpr.find(single_Run3) != std::string::npos)
606 result = m_elecEfficiencySFTool_trigEff_singleLep->getEfficiencyScaleFactor(el, trig_eff);
607 else if ( trigExpr.find(dilep_str) != std::string::npos )
608 ATH_MSG_ERROR( "Use GetTriggerGlobalEfficiency for logical OR of lepton triggers");
609 else if ( trigExpr.find(multi_str) != std::string::npos )
610 ATH_MSG_ERROR( "Use GetTriggerGlobalEfficiency for logical OR of lepton triggers");
611 else
612 ATH_MSG_ERROR( "The trigger expression (" << trigExpr << ") is not supported by the electron trigger efficiency!");
613
614 switch (result) {
616 ATH_MSG_ERROR( "Failed to retrieve signal electron trigger efficiency");
617 return 1.;
619 ATH_MSG_VERBOSE( "OutOfValidityRange found for signal electron trigger efficiency");
620 return 1.;
621 default:
622 break;
623 }
624
625 return trig_eff;
626}

◆ GetEleTriggerEfficiencySF()

double ST::SUSYObjDef_xAOD::GetEleTriggerEfficiencySF ( const xAOD::Electron & el,
const std::string & trigExpr = "SINGLE_E_2015_e24_lhmedium_L1EM20VH_OR_e60_lhmedium_OR_e120_lhloose_2016_2018_e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0" ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 561 of file Electrons.cxx.

561 {
562
563 double trig_sf(1.);
564
565 std::string single_str = "SINGLE_E";
566 std::string single_Run3 = "202";
567 std::string dilep_str = "DI_E";
568 std::string multi_str = "MULTI_L";
569
570 CP::CorrectionCode result;
571 if ( trigExpr.find(single_str) != std::string::npos || trigExpr.find(single_Run3) != std::string::npos)
572 result = m_elecEfficiencySFTool_trig_singleLep->getEfficiencyScaleFactor(el, trig_sf);
573 else if ( trigExpr.find(dilep_str) != std::string::npos )
574 ATH_MSG_ERROR( "Use GetTriggerGlobalEfficiency for logical OR of lepton triggers");
575 else if ( trigExpr.find(multi_str) != std::string::npos )
576 ATH_MSG_ERROR( "Use GetTriggerGlobalEfficiency for logical OR of lepton triggers");
577 else
578 ATH_MSG_ERROR( "The trigger expression (" << trigExpr << ") is not supported by the electron trigger SF!");
579
580 switch (result) {
582 ATH_MSG_ERROR( "Failed to retrieve signal electron trigger SF");
583 return 1.;
585 ATH_MSG_VERBOSE( "OutOfValidityRange found for signal electron trigger SF");
586 return 1.;
587 default:
588 break;
589 }
590
591 return trig_sf;
592}

◆ getElSFkeys()

std::vector< std::string > ST::SUSYObjDef_xAOD::getElSFkeys ( const std::string & mapFile) const
protected

Definition at line 1254 of file SUSYObjDef_xAOD.cxx.

1254 {
1255
1256 if( mapFile.empty() )
1257 return {};
1258
1259 std::vector<std::string> theKeys;
1260
1261 std::string filename = PathResolverFindCalibFile(mapFile);
1262 std::ifstream input( filename );
1263 for( std::string line; getline( input, line ); ){
1264 std::vector<std::string> tokens = split((const std::string)line,"=");
1265 if(tokens.size()){
1266 theKeys.push_back(tokens.at(0));
1267 }
1268 }
1269
1270 return theKeys;
1271}

◆ GetEventInfo()

const xAOD::EventInfo * ST::SUSYObjDef_xAOD::GetEventInfo ( ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 3039 of file SUSYObjDef_xAOD.cxx.

3039 {
3040 const xAOD::EventInfo* evtInfo = nullptr;
3041 if ( evtStore()->retrieve( evtInfo, "EventInfo" ).isFailure() ) {
3042 throw std::runtime_error("Unable to fetch EventInfo.");
3043 }
3044 return evtInfo;
3045}

◆ GetFatJets()

StatusCode ST::SUSYObjDef_xAOD::GetFatJets ( xAOD::JetContainer *& copy,
xAOD::ShallowAuxContainer *& copyaux,
const bool recordSG = false,
const std::string & jetkey = "",
const bool doLargeRdecorations = false,
const xAOD::JetContainer * containerToBeCopied = nullptr )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 250 of file Jets.cxx.

251 {
252 if (!m_tool_init) {
253 ATH_MSG_ERROR("SUSYTools was not initialized!!");
254 return StatusCode::FAILURE;
255 }
256
257 if (m_fatJets.empty()) {
258 ATH_MSG_ERROR("JetFatCalibTool was not initialized for largeR jet!!");
259 return StatusCode::FAILURE;
260 }
261
262 std::string jetkey_tmp = jetkey;
263 if (jetkey.empty()) {
264 jetkey_tmp = m_fatJets;
265 }
266
267 const xAOD::JetContainer* jets = nullptr;
268 if (copy==nullptr) { // empty container provided
269 if (containerToBeCopied != nullptr) {
270 jets = containerToBeCopied;
271 }
272 else {
273 ATH_MSG_DEBUG("Retrieve jet collection: " << jetkey_tmp);
274 ATH_CHECK( evtStore()->retrieve(jets, jetkey_tmp) );
275 }
276
278 copy = shallowcopy.first.get();
279 copyaux = shallowcopy.second.get();
280 bool setLinks = xAOD::setOriginalObjectLink(*jets, *copy);
281 if (!setLinks) {
282 ATH_MSG_WARNING("Failed to set original object links on " << jetkey_tmp);
283 }
284 if (recordSG) {
285 ATH_CHECK( evtStore()->record(std::move(shallowcopy.first), "STCalib" + jetkey_tmp + m_currentSyst.name()) );
286 ATH_CHECK( evtStore()->record(std::move(shallowcopy.second), "STCalib" + jetkey_tmp + m_currentSyst.name() + "Aux.") );
287 } else {
288 ATH_MSG_ERROR("Shallow copy not recorded in StoreGate!");
289 return StatusCode::FAILURE;
290 }
291 } else { // use the user-supplied collection instead
292 ATH_MSG_DEBUG("Not retrieving jet collection, using existing one provided by user");
293 jets=copy;
294 }
295
296 if(jets->size()==0) {
297 ATH_MSG_DEBUG("Large R jet collection is empty");
298 return StatusCode::SUCCESS;
299 }
300
301 // Calibrate the jets - only insitu for data for now
302 if (isData()) ATH_CHECK(m_jetFatCalibTool->applyCalibration(*copy));
303
304
305 if (!isData() && !m_JetTruthLabelName.empty()){
306 ATH_MSG_DEBUG("Checking if decorator for JetTruthLabelingTool is available:");
307 std::string fatjetcoll = m_fatJets;
308 m_label_truthKey = fatjetcoll+"."+m_JetTruthLabelName;
309 SG::ReadDecorHandle<xAOD::JetContainer, int> labelHandle_truthKey(m_label_truthKey);
310 ATH_MSG_DEBUG("Reading JetTruthLabelingTool truthKey:" << m_label_truthKey << " isAvailable " << labelHandle_truthKey.isAvailable());
311 // Truth Labeling (MC only)
312 if (!labelHandle_truthKey.isAvailable() && !m_isPHYSLITE) ATH_CHECK(m_jetTruthLabelingTool->decorate(*copy));
313 }
314
315
316 // apply boosted jet taggers
317 if (!m_WtagConfig.empty())
318 ATH_CHECK(m_WTaggerTool->decorate(*copy));
319 if (!m_ZtagConfig.empty())
320 ATH_CHECK(m_ZTaggerTool->decorate(*copy));
321
322 for (const auto jet : *copy) {
323 ATH_CHECK( this->FillJet(*jet, true, true, doLargeRdecorations) );
324 //
325 // For OR, selected if it passed cuts
326 if ( acc_baseline(*jet) ){
327 dec_selected(*jet) = 1;
328 }
329 else{
330 dec_selected(*jet) = 0;
331 }
332 }
333
334 return StatusCode::SUCCESS;
335 }
SG::ReadDecorHandleKey< xAOD::JetContainer > m_label_truthKey
StatusCode FillJet(xAOD::Jet &input, const bool doCalib=true, bool isFat=false, bool doLargeRdecorations=false) override final
Definition Jets.cxx:403
JetContainer_v1 JetContainer
Definition of the current "jet container version".

◆ GetInDetLargeD0GSFTracks()

const xAOD::TrackParticleContainer & ST::SUSYObjDef_xAOD::GetInDetLargeD0GSFTracks ( const EventContext & ctx) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 3146 of file SUSYObjDef_xAOD.cxx.

3146 {
3147 SG::ReadHandle<xAOD::TrackParticleContainer> tracks(m_GSFLRTCollectionName, ctx);
3148
3149 if ( !tracks.isValid() ) {
3150 throw std::runtime_error("Unable to fetch LargeD0 GSF tracks.");
3151 }
3152 return *tracks;
3153}
SG::ReadHandleKey< xAOD::TrackParticleContainer > m_GSFLRTCollectionName

◆ GetInDetLargeD0Tracks()

const xAOD::TrackParticleContainer & ST::SUSYObjDef_xAOD::GetInDetLargeD0Tracks ( const EventContext & ctx) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 3134 of file SUSYObjDef_xAOD.cxx.

3134 {
3135 SG::ReadHandle<xAOD::TrackParticleContainer> tracks(m_LRTCollectionName, ctx);
3136
3137 if ( !tracks.isValid() ) {
3138 throw std::runtime_error("Unable to fetch LargeD0 tracks.");
3139 }
3140
3141 //const xAOD::TrackParticleContainer out = *tracks;
3142
3143 return *tracks;
3144}
SG::ReadHandleKey< xAOD::TrackParticleContainer > m_LRTCollectionName

◆ GetJets()

StatusCode ST::SUSYObjDef_xAOD::GetJets ( xAOD::JetContainer *& copy,
xAOD::ShallowAuxContainer *& copyaux,
const bool recordSG = true,
const std::string & jetkey = "",
const xAOD::JetContainer * containerToBeCopied = nullptr )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 73 of file Jets.cxx.

74 {
75 if (!m_tool_init) {
76 ATH_MSG_ERROR("SUSYTools was not initialized!!");
77 return StatusCode::FAILURE;
78 }
79
80 if (m_isPHYSLITE && jetkey.find("AnalysisJets") == std::string::npos){
81 ATH_MSG_ERROR("You are running on PHYSLITE derivation. Please change the Jets container to 'AnalysisJets'");
82 return StatusCode::FAILURE;
83 }
84
85 ATH_MSG_DEBUG("Default jetkey: " << m_defaultJets);
86 ATH_MSG_DEBUG("Function argument jetkey: " << jetkey);
87
88 // load default regular & btag jet keys
89 std::string jetkey_tmp = m_defaultJets; // use default for regular jetkey_tmp
90
91 // override default if user is passing a jetkey
92 if (!jetkey.empty()) {
93 jetkey_tmp = jetkey;
94 }
95
96 // final settings
97 ATH_MSG_DEBUG("Key for retrieving jet collection: jetkey = " << jetkey_tmp);
98
99 const xAOD::JetContainer* jets = nullptr;
100 if (copy==nullptr) { // empty container provided
101 if (containerToBeCopied != nullptr) {
102 jets = containerToBeCopied;
103 }
104 else {
105 ATH_MSG_DEBUG("Retrieve jet collection: " << jetkey_tmp);
106 ATH_CHECK( evtStore()->retrieve(jets, jetkey_tmp) );
107 }
109 copy = shallowcopy.first.get();
110 copyaux = shallowcopy.second.get();
111 bool setLinks = xAOD::setOriginalObjectLink(*jets, *copy);
112 if (!setLinks) {
113 ATH_MSG_WARNING("Failed to set original object links on " << jetkey_tmp);
114 }
115 if (recordSG) {
116 std::string auxname = copyaux->name();
117 if (auxname.compare("UNKNOWN")==0) copyaux->setName(std::string("STCalib" + jetkey_tmp + m_currentSyst.name() + "AuxCopy").c_str());
118 ATH_CHECK( evtStore()->record(std::move(shallowcopy.first), "STCalib" + jetkey_tmp + m_currentSyst.name()) );
119 ATH_CHECK( evtStore()->record(std::move(shallowcopy.second), "STCalib" + jetkey_tmp + m_currentSyst.name() + "Aux.") );
120 } else {
121 ATH_MSG_ERROR("Shallow copy not recorded in StoreGate!");
122 return StatusCode::FAILURE;
123 }
124 } else { // use the user-supplied collection instead
125 ATH_MSG_DEBUG("Not retrieving jet collecton, using existing one provided by user");
126 jets = copy;
127 }
128
129 // Calibrate the jets
130 ATH_CHECK(m_jetCalibTool->applyCalibration(*copy));
131
132 // Add isHS labels to jets (required for JvtEfficiencyTools)
133 if (!isData()) {
134 ATH_CHECK(m_jetPileupLabelingTool->decorate(*copy));
135 }
136
137 // Calculate Jvt scores (required by METSignificance)
138 for (const auto jet : *copy) {
139 dec_jvt(*jet) = m_jetJvtMomentTool->updateJvt(*jet);
140 }
141
142 // Re-calculate NNJvt scores
143 if (m_applyJVTCut) ATH_CHECK(m_jetNNJvtMomentTool->decorate(*copy));
144
145 // Update the jets
146 for (const auto jet : *copy) {
147 ATH_CHECK( this->FillJet(*jet) );
148 }
149
150 for (const auto jet : *copy) {
151 // Update the JVT decorations if needed
152 if( m_doFwdJVT){
153 dec_passJvt(*jet) = acc_passFJvt(*jet) && acc_passJvt(*jet);
154 dec_fjvt(*jet) = acc_fjvt(*jet);
155
156 //new state for OR . 0=non-baseline objects, 1=for baseline jets not passing JVT, 2=for any other baseline object
157 if ( acc_baseline(*jet) ){
158 if( acc_passJvt(*jet) ) dec_selected(*jet) = 2;
159 else dec_selected(*jet) = 1;
160 }
161 else{
162 dec_selected(*jet) = 0;
163 }
164 }
165 this->IsBadJet(*jet);
166 this->IsSignalJet(*jet, m_jetPt, m_jetEta);
167 if (!isData())this->IsTruthBJet(*jet);
168 }
169
170 return StatusCode::SUCCESS;
171 }
bool IsBadJet(const xAOD::Jet &input) const override final
Definition Jets.cxx:763
bool IsTruthBJet(const xAOD::Jet &input) const override final
Definition Truth.cxx:301
bool IsSignalJet(const xAOD::Jet &input, const float ptcut, const float etacut) const override final
Definition Jets.cxx:711
void setName(const char *name)
Set the name of the container instance.
const char * name() const
Get the name of the container instance.
static const SG::ConstAccessor< float > acc_fjvt("DFCommonJets_fJvt")
static const SG::Decorator< float > dec_fjvt("fJvt")
static const SG::Decorator< float > dec_jvt("Jvt")

◆ GetJetsSyst()

StatusCode ST::SUSYObjDef_xAOD::GetJetsSyst ( const xAOD::JetContainer & calibjets,
xAOD::JetContainer *& copy,
xAOD::ShallowAuxContainer *& copyaux,
const bool recordSG = true,
const std::string & jetkey = "" )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 338 of file Jets.cxx.

339 {
340 if (!m_tool_init) {
341 ATH_MSG_ERROR("SUSYTools was not initialized!!");
342 return StatusCode::FAILURE;
343 }
344
345 std::string jetkey_tmp = jetkey;
346 if (jetkey.empty()) {
347 jetkey_tmp = m_defaultJets;
348 }
349
351 copy = shallowcopy.first.get();
352 copyaux = shallowcopy.second.get();
353
354 bool setLinks = xAOD::setOriginalObjectLink(calibjets, *copy);
355 if (!setLinks) {
356 ATH_MSG_WARNING("Failed to set original object links on " << jetkey_tmp);
357 }
358
359 // ghost associate the muons to the jets (needed by MET muon-jet OR later)
360 ATH_MSG_VERBOSE("Run muon-to-jet ghost association");
361 const xAOD::MuonContainer* muons = nullptr;
362 // Do a little guessing
363 if (jetkey!="AnalysisJets"){
364 ATH_CHECK( evtStore()->retrieve(muons, "Muons") );
365 } else {
366 ATH_CHECK( evtStore()->retrieve(muons, "AnalysisMuons") );
367 }
368 met::addGhostMuonsToJets(*muons, *copy);
369
370 // Update the jets
371 for (const auto jet : *copy) {
372 ATH_CHECK( this->FillJet(*jet, false) );
373 }
374
375 for (const auto jet : *copy) {
376 // Update the JVT decorations if needed
377 if( m_doFwdJVT){
378 dec_passJvt(*jet) = acc_passFJvt(*jet) && acc_passJvt(*jet);
379
380 //new state for OR . 0=non-baseline objects, 1=for baseline jets not passing JVT, 2=for any other baseline object
381 if ( acc_baseline(*jet) ){
382 if( acc_passJvt(*jet) ) dec_selected(*jet) = 2;
383 else dec_selected(*jet) = 1;
384 }
385 else{
386 dec_selected(*jet) = 0;
387 }
388 }
389 this->IsBadJet(*jet);
390 this->IsSignalJet(*jet, m_jetPt, m_jetEta);
391 if (!isData())this->IsTruthBJet(*jet);
392 }
393 if (recordSG) {
394 ATH_CHECK( evtStore()->record(std::move(shallowcopy.first), "STCalib" + jetkey_tmp + m_currentSyst.name()) );
395 ATH_CHECK( evtStore()->record(std::move(shallowcopy.second), "STCalib" + jetkey_tmp + m_currentSyst.name() + "Aux.") );
396 } else {
397 ATH_MSG_ERROR("Shallow copy not recorded in StoreGate!");
398 return StatusCode::FAILURE;
399 }
400 return StatusCode::SUCCESS;
401 }
void addGhostMuonsToJets(const xAOD::MuonContainer &muons, xAOD::JetContainer &jets)
MuonContainer_v1 MuonContainer
Definition of the current "Muon container version".

◆ getKey()

SG::sgkey_t asg::AsgTool::getKey ( const void * ptr) const
inherited

Get the (hashed) key of an object that is in the event store.

This is a bit of a special one. StoreGateSvc and xAOD::Event both provide ways for getting the SG::sgkey_t key for an object that is in the store, based on a bare pointer. But they provide different interfaces for doing so.

In order to allow tools to efficiently perform this operation, they can use this helper function.

See also
asg::AsgTool::getName
Parameters
ptrThe bare pointer to the object that the event store should know about
Returns
The hashed key of the object in the store. If not found, an invalid (zero) key.

Definition at line 119 of file AsgTool.cxx.

119 {
120
121#ifdef XAOD_STANDALONE
122 // In case we use @c xAOD::Event, we have a direct function call
123 // for this.
124 return evtStore()->event()->getKey( ptr );
125#else
126 const SG::DataProxy* proxy = evtStore()->proxy( ptr );
127 return ( proxy == nullptr ? 0 : proxy->sgkey() );
128#endif // XAOD_STANDALONE
129 }

◆ getMCShowerType()

int ST::SUSYObjDef_xAOD::getMCShowerType ( const std::string & sample_name = "",
const std::string & tagger = "" ) const
inlinefinaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 428 of file SUSYObjDef_xAOD.h.

428{ return ST::getMCShowerType(sample_name, tagger); }
static int getMCShowerType(const std::string &sample_name, const std::string &tagger="")

◆ GetMET()

StatusCode ST::SUSYObjDef_xAOD::GetMET ( xAOD::MissingETContainer & met,
const xAOD::JetContainer * jet,
const xAOD::ElectronContainer * elec = nullptr,
const xAOD::MuonContainer * muon = nullptr,
const xAOD::PhotonContainer * gamma = nullptr,
const xAOD::TauJetContainer * taujet = nullptr,
bool doTST = true,
bool doJVTCut = true,
const xAOD::IParticleContainer * invis = nullptr )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 23 of file MET.cxx.

30 {
31 if (!m_tool_init) {
32 ATH_MSG_ERROR("SUSYTools was not initialized!!");
33 return StatusCode::FAILURE;
34 }
35
36 const xAOD::MissingETContainer* metcore(nullptr);
37 if ( evtStore()->retrieve( metcore, m_inputMETCore ).isFailure() ) {
38 ATH_MSG_WARNING( "Unable to retrieve MET core container: " << m_inputMETCore );
39 return StatusCode::FAILURE;
40 }
41 const xAOD::MissingETAssociationMap* metMap(nullptr);
42 if ( evtStore()->retrieve(metMap, m_inputMETMap).isFailure() ) {
43 ATH_MSG_WARNING("Unable to retrieve MissingETAssociationMap: " << m_inputMETMap);
44 return StatusCode::FAILURE;
45 }
46 // Helper keeps track of object selection flags for this map
47 xAOD::MissingETAssociationHelper metHelper(&(*metMap));
48
49 std::string softTerm = "SoftClus";
50 if (doTST) {
51 softTerm = "PVSoftTrk";
52 } else if (doJVTCut) {
53 ATH_MSG_WARNING( "Requested CST MET and a JVT cut. This is not a recommended configuration - please consider switching to TST." );
54 }
55
56 metHelper.resetObjSelectionFlags();
57
58 // allow creation of proxy MET by flagging objects for "neutrino/ification" as already selected
59 if (invis) {
60 ATH_CHECK( m_metMaker->markInvisible(invis, metHelper, &met) );
61 }
62
63 if (elec) {
64 ATH_MSG_VERBOSE("Build electron MET");
65 ConstDataVector<xAOD::ElectronContainer> metelectron(SG::VIEW_ELEMENTS);
66 for (const xAOD::Electron* el : *elec) {
67 // pass baseline selection
68 if (acc_baseline(*el)) {
69 bool veto(false);
70 if (invis) {
71 for (const xAOD::IParticle* ipart : *invis) {
72 if (ipart == el) {veto = true; break;}
73 }
74 }
75 if (!veto) metelectron.push_back(el);
76 }
77 }
78 ATH_CHECK( m_metMaker->rebuildMET(m_eleTerm, xAOD::Type::Electron, &met, metelectron.asDataVector(), metHelper) );
79 }
80
81 if (gamma) {
82 ATH_MSG_VERBOSE("Build photon MET");
83 ConstDataVector<xAOD::PhotonContainer> metgamma(SG::VIEW_ELEMENTS);
84 for (const xAOD::Photon* ph : *gamma) {
85 // pass baseline selection
86 if (acc_baseline(*ph)) {
87 bool veto(false);
88 if (invis) {
89 for (const xAOD::IParticle* ipart : *invis) {
90 if (ipart == ph) {veto = true; break;}
91 }
92 }
93 if (!veto) metgamma.push_back(ph);
94 }
95 }
96 ATH_CHECK( m_metMaker->rebuildMET(m_gammaTerm, xAOD::Type::Photon, &met, metgamma.asDataVector(), metHelper) );
97 }
98
99 if (taujet) {
100 ATH_MSG_VERBOSE("Build tau MET");
101 ConstDataVector<xAOD::TauJetContainer> mettau(SG::VIEW_ELEMENTS);
102 for (const xAOD::TauJet* tau : *taujet) {
103 // pass baseline selection
104 if (acc_baseline(*tau)) {
105 bool veto(false);
106 if (invis) {
107 for (const xAOD::IParticle* ipart : *invis) {
108 if (ipart == tau) {veto = true; break;}
109 }
110 }
111 if (!veto) mettau.push_back(tau);
112 }
113 }
114 ATH_CHECK( m_metMaker->rebuildMET(m_tauTerm, xAOD::Type::Tau, &met, mettau.asDataVector(), metHelper) );
115 }
116
117 if (muon) {
118 ATH_MSG_VERBOSE("Build muon MET");
119 ConstDataVector<xAOD::MuonContainer> metmuon(SG::VIEW_ELEMENTS);
120 for (const xAOD::Muon* mu : *muon) {
121 bool veto(false);
122 // pass baseline selection
123 if (acc_baseline(*mu)) {
124 if (invis) {
125 for (const xAOD::IParticle* ipart : *invis) {
126 if (ipart == mu) {veto = true; break;}
127 }
128 }
129 if (!veto) metmuon.push_back(mu);
130 }
131 }
132 ATH_CHECK( m_metMaker->rebuildMET(m_muonTerm, xAOD::Type::Muon, &met, metmuon.asDataVector(), metHelper) );
133 }
134
135 if (!jet) {
136 ATH_MSG_WARNING("Invalid jet container specified for MET rebuilding!");
137 return StatusCode::SUCCESS;
138 }
139
140 ATH_MSG_VERBOSE("Build jet/soft MET");
141 ATH_CHECK( m_metMaker->rebuildJetMET(m_jetTerm, softTerm, &met, jet, metcore, metHelper, doJVTCut) );
142
143 if (!isData()) {
144 m_metSystTool->setRandomSeed(static_cast<int>(1e6*met[softTerm]->phi()));
145 ATH_MSG_VERBOSE("Original soft term " << met[softTerm]->name() << " (met: " << met[softTerm]->met() << ")" );
146 if ( m_metSystTool->applyCorrection(*met[softTerm], metHelper) != CP::CorrectionCode::Ok ) {
147 ATH_MSG_WARNING("GetMET: Failed to apply MET soft term systematics.");
148 }
149 ATH_MSG_VERBOSE("New soft term value: " << met[softTerm]->met() );
150 }
151
152 ATH_MSG_VERBOSE("Build MET sum");
153 ATH_CHECK( met::buildMETSum(m_outMETTerm, &met, met[softTerm]->source()) );
154 ATH_MSG_VERBOSE( "Rebuilt MET: Missing Et (x,y): (" << met[m_outMETTerm]->mpx() << "," << met[m_outMETTerm]->mpy() << ")");
155 ATH_MSG_VERBOSE( "Done rebuilding MET." );
156
157 return StatusCode::SUCCESS;
158}
std::vector< std::string > veto
these patterns are anded
Definition listroot.cxx:191
StatusCode buildMETSum(const std::string &totalName, xAOD::MissingETContainer *metCont)
@ Photon
The object is a photon.
Definition ObjectType.h:47
@ Muon
The object is a muon.
Definition ObjectType.h:48
@ Electron
The object is an electron.
Definition ObjectType.h:46
@ Tau
The object is a tau (jet).
Definition ObjectType.h:49
TauJet_v3 TauJet
Definition of the current "tau version".
Muon_v1 Muon
Reference the current persistent version:
Photon_v1 Photon
Definition of the current "egamma version".
MissingETAssociationMap_v1 MissingETAssociationMap
Version control by type defintion.

◆ GetMETSig()

StatusCode ST::SUSYObjDef_xAOD::GetMETSig ( xAOD::MissingETContainer & met,
double & metSignificance,
bool doTST = true,
bool doJVTCut = true )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 240 of file MET.cxx.

242 {
243
244 std::string softTerm = "SoftClus";
245 if (doTST) {
246 softTerm = "PVSoftTrk";
247 } else if (doJVTCut) {
248 ATH_MSG_WARNING( "Requested CST MET and a JVT cut. This is not a recommended configuration - please consider switching to TST." );
249 }
250
251 const xAOD::EventInfo* evtInfo = nullptr;
252 ATH_CHECK( evtStore()->retrieve( evtInfo, "EventInfo" ) );
253 ATH_CHECK( m_metSignif->varianceMET( &met, evtInfo->averageInteractionsPerCrossing(), m_jetTerm, softTerm, m_outMETTerm) );
254 metSignificance = m_metSignif->GetSignificance();
255 ATH_MSG_VERBOSE( "Obtained MET Significance: " << metSignificance );
256
257 return StatusCode::SUCCESS;
258}
float averageInteractionsPerCrossing() const
Average interactions per crossing for all BCIDs - for out-of-time pile-up.

◆ GetMuons()

StatusCode ST::SUSYObjDef_xAOD::GetMuons ( xAOD::MuonContainer *& copy,
xAOD::ShallowAuxContainer *& copyaux,
const bool recordSG = true,
const std::string & muonkey = "Muons",
const std::string & lrtmuonkey = "MuonsLRT",
const xAOD::MuonContainer * containerToBeCopied = nullptr )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 101 of file Muons.cxx.

102{
103 if (!m_tool_init) {
104 ATH_MSG_ERROR("SUSYTools was not initialized!!");
105 return StatusCode::FAILURE;
106 }
107
108 // Initializing prompt/LRT OR procedure
109 auto outputCol = std::make_unique<xAOD::MuonContainer>();
110 std::unique_ptr<xAOD::MuonAuxContainer> outputAuxCol;
111 outputAuxCol = std::make_unique<xAOD::MuonAuxContainer>();
112 outputCol->setStore(outputAuxCol.get());
113 ATH_CHECK( m_outMuonLocation.initialize() );
114
115 if (bool(m_muLRT) && !lrtmuonkey.empty() && evtStore()->contains<xAOD::MuonContainer>(lrtmuonkey)){
116 ATH_MSG_DEBUG("Applying prompt/LRT muon OR procedure");
117
118 // First identify if merged container has already been made (for instances where GetMuons() is called more than once)
119 if (evtStore()->contains<xAOD::MuonContainer>("StdWithLRTMuons")) {
120 ATH_MSG_DEBUG("Merged prompt/LRT container already created in TStore");
121 } else {
122 ATH_MSG_DEBUG("Creating merged prompt/LRT container in TStore");
123
124 // Retrieve prompt and LRT muons from TStore
125 ATH_CHECK( evtStore()->retrieve(prompt_muons, muonkey) );
126 ATH_CHECK( evtStore()->retrieve(lrt_muons, lrtmuonkey) );
127
128 // Remove LRT muons as flagged by filter for uncertainty
129 auto filtered_muons = std::make_unique<xAOD::MuonContainer>();
130 std::unique_ptr<xAOD::MuonAuxContainer> filtered_muons_aux = std::make_unique<xAOD::MuonAuxContainer>();
131 filtered_muons->setStore(filtered_muons_aux.get());
132 ATH_CHECK(prepareLRTMuons(lrt_muons, filtered_muons.get()));
133
134 // Check overlap between prompt and LRT collections
135 std::vector<bool> writePromptMuon;
136 std::vector<bool> writeLRTMuon;
137 m_muonLRTORTool->checkOverlap(*prompt_muons, *filtered_muons, writePromptMuon, writeLRTMuon);
138
139 // Decorate muons with prompt/LRT
140 for (const xAOD::Muon* mu : *prompt_muons) dec_isLRT(*mu) = 0;
141 for (const xAOD::Muon* mu : *filtered_muons) dec_isLRT(*mu) = 1;
142
143 // Create merged StdWithLRTMuons container
144 outputCol->reserve(prompt_muons->size() + filtered_muons->size());
145 ATH_CHECK(MergeMuons(*prompt_muons, writePromptMuon, outputCol.get()) );
146 ATH_CHECK(MergeMuons(*filtered_muons, writeLRTMuon, outputCol.get()) );
147
148 // Save merged StdWithLRTMuons container to TStore
149 ATH_CHECK(evtStore()->record(std::move(outputCol), m_outMuonLocation.key()));
150 ATH_CHECK(evtStore()->record(std::move(outputAuxCol), m_outMuonLocation.key() + "Aux.") );
151
152 }
153 } else if (!lrtmuonkey.empty()) {
154 if (evtStore()->contains<xAOD::MuonContainer>(lrtmuonkey) == false && bool(m_muLRT) == true) ATH_MSG_WARNING("prompt/LRT OR procedure attempted but " << lrtmuonkey << " not in ROOT file, check config!");
155 ATH_MSG_DEBUG("Not applying prompt/LRT muon OR procedure");
156 }
157
158 if (m_isPHYSLITE && muonkey.find("AnalysisMuons")==std::string::npos){
159 ATH_MSG_ERROR("You are running on PHYSLITE derivation. Please change the Muons container to 'AnalysisMuons'");
160 return StatusCode::FAILURE;
161 }
162
163 const xAOD::MuonContainer* muons = nullptr;
164 if (bool(m_muLRT) && evtStore()->contains<xAOD::MuonContainer>(lrtmuonkey)){
165 ATH_MSG_DEBUG("Using container: " << m_outMuonLocation.key());
166 ATH_CHECK( evtStore()->retrieve(muons, m_outMuonLocation.key()));
167 }
168 else {
169 if (copy==nullptr) { // empty container provided
170 ATH_MSG_DEBUG("Empty container provided");
171 if (containerToBeCopied != nullptr) {
172 ATH_MSG_DEBUG("Containter to be copied not nullptr");
173 muons = containerToBeCopied;
174 }
175 else {
176 ATH_MSG_DEBUG("Getting Muons collection");
177 ATH_CHECK( evtStore()->retrieve(muons, muonkey) );
178 }
179 }
180 }
181
182 if (copy==nullptr) { // empty container provided
184 copy = shallowcopy.first.get();
185 copyaux = shallowcopy.second.get();
186 bool setLinks = xAOD::setOriginalObjectLink(*muons, *copy);
187 if (!setLinks) {
188 ATH_MSG_WARNING("Failed to set original object links on " << muonkey);
189 }
190 if (recordSG) {
191 ATH_CHECK( evtStore()->record(std::move(shallowcopy.first), "STCalib" + muonkey + m_currentSyst.name()) );
192 ATH_CHECK( evtStore()->record(std::move(shallowcopy.second), "STCalib" + muonkey + m_currentSyst.name() + "Aux.") );
193 } else {
194 ATH_MSG_ERROR("Shallow copy not recorded in StoreGate!");
195 return StatusCode::FAILURE;
196 }
197 } else { // use the user-supplied collection instead
198 ATH_MSG_DEBUG("Not retrieving muon collection, using existing one provided by user");
199 muons=copy; // this does nothing
200 }
201
202 for (const auto muon : *copy) {
207 }
208
209 return StatusCode::SUCCESS;
210}
bool IsBadMuon(const xAOD::Muon &input, const float qopcut) const override final
Definition Muons.cxx:409
SG::WriteHandleKey< xAOD::MuonContainer > m_outMuonLocation
StatusCode MergeMuons(const xAOD::MuonContainer &muons, const std::vector< bool > &writeMuon, xAOD::MuonContainer *outputCol) const override final
Definition Muons.cxx:56
StatusCode prepareLRTMuons(const xAOD::MuonContainer *inMuons, xAOD::MuonContainer *copy) const override final
Definition Muons.cxx:74
const xAOD::MuonContainer * lrt_muons
bool IsSignalMuon(const xAOD::Muon &input, const float ptcut, const float d0sigcut, const float z0cut, const float etacut=DUMMYDEF) const override final
Definition Muons.cxx:348
bool IsCosmicMuon(const xAOD::Muon &input, const float z0cut, const float d0cut) const override final
Definition Muons.cxx:448
StatusCode FillMuon(xAOD::Muon &input, const float ptcut, const float etacut) override final
Definition Muons.cxx:212
const xAOD::MuonContainer * prompt_muons

◆ GetMuonTriggerEfficiency()

double ST::SUSYObjDef_xAOD::GetMuonTriggerEfficiency ( const xAOD::Muon & mu,
const std::string & trigExpr,
const bool isdata = false )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 537 of file Muons.cxx.

537 {
538
539 double eff(1.);
540
541 if (m_muonTriggerSFTool->getTriggerEfficiency(mu, eff, trigExpr, isdata) != CP::CorrectionCode::Ok) {
542 ATH_MSG_WARNING("Problem retrieving signal muon trigger efficiency for " << trigExpr );
543 }
544 else{
545 ATH_MSG_DEBUG("Got efficiency " << eff << " for " << trigExpr );
546 }
547 return eff;
548}

◆ getName()

const std::string & asg::AsgTool::getName ( const void * ptr) const
inherited

Get the name of an object that is / should be in the event store.

This is a bit of a special one. StoreGateSvc and xAOD::Event both provide ways for getting the std::string name for an object that is in the store, based on a bare pointer. But they provide different interfaces for doing so.

In order to allow tools to efficiently perform this operation, they can use this helper function.

See also
asg::AsgTool::getKey
Parameters
ptrThe bare pointer to the object that the event store should know about
Returns
The string name of the object in the store. If not found, an empty string.

Definition at line 106 of file AsgTool.cxx.

106 {
107
108#ifdef XAOD_STANDALONE
109 // In case we use @c xAOD::Event, we have a direct function call
110 // for this.
111 return evtStore()->event()->getName( ptr );
112#else
113 const SG::DataProxy* proxy = evtStore()->proxy( ptr );
114 static const std::string dummy = "";
115 return ( proxy == nullptr ? dummy : proxy->name() );
116#endif // XAOD_STANDALONE
117 }

◆ GetPhotons()

StatusCode ST::SUSYObjDef_xAOD::GetPhotons ( xAOD::PhotonContainer *& copy,
xAOD::ShallowAuxContainer *& copyaux,
const bool recordSG = true,
const std::string & photonkey = "Photons",
const xAOD::PhotonContainer * containerToBeCopied = nullptr )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 33 of file Photons.cxx.

34{
35 if (!m_tool_init) {
36 ATH_MSG_ERROR("SUSYTools was not initialized!!");
37 return StatusCode::FAILURE;
38 }
39
40 if (m_isPHYSLITE && photonkey.find("AnalysisPhotons")==std::string::npos){
41 ATH_MSG_ERROR("You are running on PHYSLITE derivation. Please change the Photons container to 'AnalysisPhotons'");
42 return StatusCode::FAILURE;
43 }
44
45 const xAOD::PhotonContainer* photons = nullptr;
46 if (copy==nullptr) { // empty container provided
47 if (containerToBeCopied != nullptr) {
48 photons = containerToBeCopied;
49 }
50 else {
51 ATH_CHECK( evtStore()->retrieve(photons, photonkey) );
52 }
54 copy = shallowcopy.first.get();
55 copyaux = shallowcopy.second.get();
56 bool setLinks = xAOD::setOriginalObjectLink(*photons, *copy);
57 if (!setLinks) {
58 ATH_MSG_WARNING("Failed to set original object links on " << photonkey);
59 }
60 if (recordSG) {
61 ATH_CHECK( evtStore()->record(std::move(shallowcopy.first), "STCalib" + photonkey + m_currentSyst.name()) );
62 ATH_CHECK( evtStore()->record(std::move(shallowcopy.second), "STCalib" + photonkey + m_currentSyst.name() + "Aux.") );
63 } else {
64 ATH_MSG_ERROR("Shallow copy not recorded in StoreGate!");
65 return StatusCode::FAILURE;
66 }
67 } else { // use the user-supplied collection instead
68 ATH_MSG_DEBUG("Not retrieving photon collecton, using existing one provided by user");
69 photons=copy;
70 }
71
72 for (const auto photon : *copy) {
75 }
76
77 return StatusCode::SUCCESS;
78}
StatusCode FillPhoton(xAOD::Photon &input, const float ptcut, const float etacut) override final
Definition Photons.cxx:81
bool IsSignalPhoton(const xAOD::Photon &input, const float ptcut, const float etacut=DUMMYDEF) const override final
Definition Photons.cxx:170
PhotonContainer_v1 PhotonContainer
Definition of the current "photon container version".

◆ GetPileupWeight()

float ST::SUSYObjDef_xAOD::GetPileupWeight ( )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 3047 of file SUSYObjDef_xAOD.cxx.

3047 {
3048
3049 const xAOD::EventInfo* evtInfo = GetEventInfo();
3050 float pu_weight = m_prwTool->getCombinedWeight(*evtInfo);
3051
3052 if(!isfinite(pu_weight)) pu_weight = 1.;
3053
3054 return pu_weight;
3055}

◆ GetPileupWeightHash()

ULong64_t ST::SUSYObjDef_xAOD::GetPileupWeightHash ( )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 3072 of file SUSYObjDef_xAOD.cxx.

3072 {
3073 const xAOD::EventInfo* evtInfo = GetEventInfo();
3074 return m_prwTool->getPRWHash( *evtInfo );
3075}

◆ GetPileupWeightPrescaledTrigger()

float ST::SUSYObjDef_xAOD::GetPileupWeightPrescaledTrigger ( const std::string & trigger_expr)
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 3057 of file SUSYObjDef_xAOD.cxx.

3057 {
3058 /* This requires the setup of the PRW tool using your own prescaled lumicalc
3059 files with syntax "HLT_PrescaledTriggerA.lumicalc.root:HLT_PrescaledTriggerA".
3060 For further informations, please refer to:
3061 https://twiki.cern.ch/twiki/bin/view/AtlasProtected/ExtendedPileupReweighting#Prescaling%20MC
3062 */
3063
3064 const xAOD::EventInfo* evtInfo = GetEventInfo();
3065 float pu_weight = m_prwTool->getCombinedWeight(*evtInfo,trigger_expr);
3066
3067 if(!isfinite(pu_weight)) pu_weight = 1.;
3068
3069 return pu_weight;
3070}

◆ GetPrimVtx()

const xAOD::Vertex * ST::SUSYObjDef_xAOD::GetPrimVtx ( ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 2978 of file SUSYObjDef_xAOD.cxx.

2978 {
2979 const xAOD::VertexContainer* vertices = nullptr;
2980 if ( evtStore()->retrieve( vertices, "PrimaryVertices" ).isSuccess() ) {
2981 for ( const auto vx : *vertices ) {
2982 if (vx->vertexType() == xAOD::VxType::PriVtx) {
2983 ATH_MSG_DEBUG("PrimaryVertex found with z=" << vx->z());
2984 return vx;
2985 }
2986 }
2987 } else {
2988 ATH_MSG_WARNING("Failed to retrieve VertexContainer \"PrimaryVertices\", returning nullptr");
2989 }
2990 return nullptr;
2991}
@ PriVtx
Primary vertex.
VertexContainer_v1 VertexContainer
Definition of the current "Vertex container version".

◆ getProperty() [1/2]

template<class T>
const T * asg::AsgTool::getProperty ( const std::string & name) const
inherited

Get one of the tool's properties.

◆ getProperty() [2/2]

template<typename T>
const T * ST::ISUSYObjDef_xAODTool::getProperty ( const std::string & name)
inlineinherited

Definition at line 240 of file ISUSYObjDef_xAODTool.h.

240 {
241 return dynamic_cast<asg::AsgTool&>(*this).getProperty<T>(name);
242 }
unsigned long long T

◆ GetRandomRunNumber()

unsigned int ST::SUSYObjDef_xAOD::GetRandomRunNumber ( bool muDependentRRN = true)
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 3096 of file SUSYObjDef_xAOD.cxx.

3096 {
3097
3098 const xAOD::EventInfo* evtInfo = GetEventInfo();
3099 if (randomrunnumber.isAvailable(*(evtInfo)) && muDependentRRN) {
3100 return randomrunnumber(*(evtInfo));
3101 }
3102 else if (!muDependentRRN) {
3103 return m_prwTool->getRandomRunNumber( *evtInfo, muDependentRRN );
3104 }
3105 ATH_MSG_ERROR ( "Failed to find RandomRunNumber decoration! You need to call ApplyPRWTool() beforehand!" );
3106 return 0;
3107}

◆ GetRunNumber()

unsigned int ST::SUSYObjDef_xAOD::GetRunNumber ( ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 3118 of file SUSYObjDef_xAOD.cxx.

3118 {
3119
3120 const xAOD::EventInfo* evtInfo = GetEventInfo();
3121
3122 // For data, we can just directly use the run number
3123 if (isData()) { return evtInfo->runNumber(); }
3124
3125 // else it's MC as we need the RRN assigned by the PRW tool
3126 if (!randomrunnumber.isAvailable(*(evtInfo))) {
3127 ATH_MSG_ERROR ( "Failed to find RandomRunNumber decoration! You need to call ApplyPRWTool() beforehand!" );
3128 }
3129 return randomrunnumber(*(evtInfo));
3130
3131}
uint32_t runNumber() const
The current event's run number.

◆ getSherpaVjetsNjetsWeight() [1/2]

float ST::SUSYObjDef_xAOD::getSherpaVjetsNjetsWeight ( ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 2947 of file SUSYObjDef_xAOD.cxx.

2947 {
2948
2949 //Retrieve the truth jets
2950 if( evtStore()->contains<xAOD::JetContainer>("AntiKt4TruthWZJets") ){
2951 return getSherpaVjetsNjetsWeight("AntiKt4TruthWZJets");
2952 }
2953 else if( evtStore()->contains<xAOD::JetContainer>("AntiKt4TruthJets")){
2954 return getSherpaVjetsNjetsWeight("AntiKt4TruthJets" );
2955 }
2956 else{
2957 ATH_MSG_WARNING("No TruthJetContainer found! Dummy null weight retrieved.");
2958 }
2959 return 0.;
2960}
float getSherpaVjetsNjetsWeight() const override final

◆ getSherpaVjetsNjetsWeight() [2/2]

float ST::SUSYObjDef_xAOD::getSherpaVjetsNjetsWeight ( const std::string & jetContainer) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 2962 of file SUSYObjDef_xAOD.cxx.

2962 {
2963
2964 if(jetContainer=="AntiKt4TruthWZJets"){
2965 return m_pmgSHnjetWeighterWZ->getWeight();
2966 }
2967 else if (jetContainer=="AntiKt4TruthJets"){
2968 return m_pmgSHnjetWeighter->getWeight();
2969 }
2970 else{
2971 ATH_MSG_WARNING(jetContainer << " is no supported by PMGSherpa22VJetsWeightTool! Please check...");
2972 }
2973 return 1.;
2974
2975}

◆ GetSignalElecSF()

float ST::SUSYObjDef_xAOD::GetSignalElecSF ( const xAOD::Electron & el,
const bool recoSF = true,
const bool idSF = true,
const bool triggerSF = true,
const bool isoSF = true,
const std::string & trigExpr = "singleLepton",
const bool ecidsSF = false,
const bool cidSF = false )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 423 of file Electrons.cxx.

430 {
431
432 if ((m_eleId == "VeryLooseLLH" || m_eleId == "LooseLLH" || m_eleId == "Loose" || m_eleId == "Medium" || m_eleId == "Tight") && (idSF || triggerSF || isoSF)) {
433 ATH_MSG_ERROR("No signal electron ID or trigger scale factors provided for the selected working point!");
434 ATH_MSG_ERROR("I will now die messily.");
435 }
436
437 //shortcut keys for trigger SF config
438 std::string singleLepStr = "singleLepton";
439 std::string diLepStr = "diLepton";
440 std::string multiLepStr = "multiLepton";
441
442 float sf(1.);
443
444 if (recoSF) {
445 double reco_sf(1.);
446
447 CP::CorrectionCode result = m_elecEfficiencySFTool_reco->getEfficiencyScaleFactor(el, reco_sf);
448 switch (result) {
450 sf *= reco_sf;
451 break;
453 ATH_MSG_ERROR( "Failed to retrieve signal electron reco SF");
454 break;
456 ATH_MSG_VERBOSE( "OutOfValidityRange found for signal electron reco SF");
457 break;
458 default:
459 ATH_MSG_WARNING( "Don't know what to do for signal electron reco SF");
460 }
461 }
462
463 if (idSF) {
464 double id_sf(1.);
465
466 CP::CorrectionCode result = m_elecEfficiencySFTool_id->getEfficiencyScaleFactor(el, id_sf);
467 switch (result) {
469 sf *= id_sf;
470 break;
472 ATH_MSG_ERROR( "Failed to retrieve signal electron id SF");
473 break;
475 ATH_MSG_VERBOSE( "OutOfValidityRange found for signal electron id SF");
476 break;
477 default:
478 ATH_MSG_WARNING( "Don't know what to do for signal electron id SF");
479 }
480 }
481
482 if (triggerSF) {
483
484 std::vector<std::string> trigMChains={};
485 std::string theExpr ("");
486 if(trigExpr==singleLepStr) {
487 if (this->treatAsYear()==2015) trigMChains = m_v_trigs15_cache_singleEle;
488 else if (this->treatAsYear()==2016) trigMChains = m_v_trigs16_cache_singleEle;
489 else if (this->treatAsYear()==2017) trigMChains = m_v_trigs17_cache_singleEle;
490 else if (this->treatAsYear()==2018) trigMChains = m_v_trigs18_cache_singleEle;
491 else if (this->treatAsYear()==2022) trigMChains = m_v_trigs22_cache_singleEle;
492 else if (this->treatAsYear()==2023) trigMChains = m_v_trigs23_cache_singleEle;
493 else trigMChains = m_v_trigs24_cache_singleEle;
495 }
496 else{
497 ATH_MSG_WARNING( "Only single lepton trigger SFs are supported in GetSignalElecSF(). Use GetTriggerGlobalEfficiencySF() for dilepton or multilepton triggers!");
498 }
499
500 //check matching
501 this->TrigMatch({&el}, trigMChains);
502
503 if(!acc_trigmatched(el)){
504 ATH_MSG_DEBUG( "Electron was not matched to trigger " << theExpr << " - scale factor does not apply (year " << this->treatAsYear() << ") Returning 1." );
505 }
506 else{ //is trig-matched electron, go for it!
507 if (trigExpr==multiLepStr || trigExpr==diLepStr) {
508 ATH_MSG_WARNING( "The dilepton or multilepton trigger SFs are not supported in GetSignalElecSF(). Use GetTriggerGlobalEfficiencySF()!");
509 }
510 else {
511 double trig_sf = GetEleTriggerEfficiencySF( el , theExpr );
512 sf *= trig_sf;
513 }
514 }
515 }
516
517 if (isoSF) {
518 double iso_sf(1.);
519 CP::CorrectionCode result;
520 if (acc_isolHighPt(el) && el.pt()>m_eleIsoHighPtThresh)
521 result = m_elecEfficiencySFTool_isoHighPt->getEfficiencyScaleFactor(el, iso_sf);
522 else
523 result = m_elecEfficiencySFTool_iso->getEfficiencyScaleFactor(el, iso_sf);
524
525 switch (result) {
527 sf *= iso_sf;
528 break;
530 ATH_MSG_ERROR( "Failed to retrieve signal electron iso SF");
531 break;
533 ATH_MSG_VERBOSE( "OutOfValidityRange found for signal electron iso SF");
534 break;
535 default:
536 ATH_MSG_WARNING( "Don't know what to do for signal electron iso SF");
537 }
538 }
539
540 // Charge flip SF: combined ECIDs & charge ID
541 if ( ecidsSF || cidSF ) {
542 double chf_sf(1.);
543 // 1. ECIDs SF
544 if ( ecidsSF ) {
545 sf *= chf_sf;
546 ATH_MSG_WARNING( "ECID SF ARE NOT YET SUPPORTED IN R22" );
547 }
548 // 2. CID SF
549 if ( cidSF ) {
550 sf *= chf_sf;
551 dec_sfChIDEff(el) = chf_sf;
552 ATH_MSG_WARNING( "CID SF ARE NOT YET SUPPORTED IN R22" );
553 }
554 }
555
556 dec_effscalefact(el) = sf;
557 return sf;
558}
std::vector< std::string > m_v_trigs24_cache_singleEle
std::vector< std::string > m_v_trigs15_cache_singleEle
double GetEleTriggerEfficiencySF(const xAOD::Electron &el, const std::string &trigExpr="SINGLE_E_2015_e24_lhmedium_L1EM20VH_OR_e60_lhmedium_OR_e120_lhloose_2016_2018_e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0") const override final
std::vector< std::string > m_v_trigs23_cache_singleEle
std::vector< std::string > m_v_trigs18_cache_singleEle
int treatAsYear(const int runNumber=-1) const override final
std::vector< std::string > m_v_trigs22_cache_singleEle
std::vector< std::string > m_v_trigs17_cache_singleEle
std::vector< std::string > m_v_trigs16_cache_singleEle
void TrigMatch(const xAOD::IParticle *p, std::initializer_list< std::string >::iterator, std::initializer_list< std::string >::iterator) override final
Definition Trigger.cxx:232
static const SG::ConstAccessor< char > acc_isolHighPt("isolHighPt")
static const SG::ConstAccessor< char > acc_trigmatched("trigmatched")
static const SG::Decorator< float > dec_sfChIDEff("chargeIDEffiSF")

◆ GetSignalMuonSF()

float ST::SUSYObjDef_xAOD::GetSignalMuonSF ( const xAOD::Muon & mu,
const bool recoSF = true,
const bool isoSF = true,
const bool doBadMuonHP = true,
const bool warnOVR = true )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 484 of file Muons.cxx.

485{
486 float sf(1.);
487
488 if (recoSF) {
489 float sf_reco(1.);
490 if (m_muonEfficiencySFTool->getEfficiencyScaleFactor( mu, sf_reco ) == CP::CorrectionCode::OutOfValidityRange) {
491 if(warnOVR) ATH_MSG_WARNING(" GetSignalMuonSF: Reco getEfficiencyScaleFactor out of validity range");
492 }
493 ATH_MSG_VERBOSE( "MuonReco ScaleFactor " << sf_reco );
494 sf *= sf_reco;
495
496 float sf_ttva(1.);
497 if(m_doTTVAsf){
498 if (m_muonTTVAEfficiencySFTool->getEfficiencyScaleFactor( mu, sf_ttva ) == CP::CorrectionCode::OutOfValidityRange) {
499 if(warnOVR) ATH_MSG_WARNING(" GetSignalMuonSF: TTVA getEfficiencyScaleFactor out of validity range");
500 }
501 ATH_MSG_VERBOSE( "MuonTTVA ScaleFactor " << sf_ttva );
502 sf *= sf_ttva;
503 }
504
505 float sf_badHighPt(1.);
506 if(m_muId == 4 && doBadMuonHP){
507 if (m_muonEfficiencyBMHighPtSFTool->getEfficiencyScaleFactor( mu, sf_badHighPt ) == CP::CorrectionCode::OutOfValidityRange) {
508 if(warnOVR) ATH_MSG_WARNING(" GetSignalMuonSF: BadMuonHighPt getEfficiencyScaleFactor out of validity range");
509 }
510 ATH_MSG_VERBOSE( "MuonBadMuonHighPt ScaleFactor " << sf_badHighPt );
511 sf *= sf_badHighPt;
512 }
513 }
514
515
516 if (isoSF) {
517 float sf_iso(1.);
518 if (acc_isolHighPt(mu) && mu.pt()>m_muIsoHighPtThresh) {
519 if (m_muonHighPtIsolationSFTool->getEfficiencyScaleFactor( mu, sf_iso ) == CP::CorrectionCode::OutOfValidityRange) {
520 if(warnOVR) ATH_MSG_WARNING(" GetSignalMuonSF: high-pt Iso getEfficiencyScaleFactor out of validity range");
521 }
522 } else if (acc_isol(mu) && mu.pt()<m_muIsoHighPtThresh) {
523 if (m_muonIsolationSFTool->getEfficiencyScaleFactor( mu, sf_iso ) == CP::CorrectionCode::OutOfValidityRange) {
524 if(warnOVR) ATH_MSG_WARNING(" GetSignalMuonSF: Iso getEfficiencyScaleFactor out of validity range");
525 }
526 }
527 ATH_MSG_VERBOSE( "MuonIso ScaleFactor " << sf_iso );
528 sf *= sf_iso;
529 }
530
531
532 dec_effscalefact(mu) = sf;
533 return sf;
534}
static const SG::ConstAccessor< char > acc_isol("isol")

◆ GetSignalPhotonSF()

double ST::SUSYObjDef_xAOD::GetSignalPhotonSF ( const xAOD::Photon & ph,
const bool effSF = true,
const bool isoSF = true,
const bool triggerSF = false ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 209 of file Photons.cxx.

210{
211 double sf(1.);
212
213 if (effSF) {
214
215 double sf_eff = 1.;
216
217 CP::CorrectionCode res = m_photonEfficiencySFTool->getEfficiencyScaleFactor( ph, sf_eff );
218 if (res == CP::CorrectionCode::OutOfValidityRange) ATH_MSG_WARNING(" GetSignalPhotonSF: EfficiencyScaleFactor out of validity range");
219
220 sf *= sf_eff;
221 }
222
223 if (isoSF) {
224
225 double sf_iso = 1.;
226
227 CP::CorrectionCode res = m_photonIsolationSFTool->getEfficiencyScaleFactor( ph, sf_iso );
228 if (res == CP::CorrectionCode::OutOfValidityRange) ATH_MSG_WARNING(" GetSignalPhotonSF: IsolationScaleFactor out of validity range");
229
230 sf *= sf_iso;
231 }
232
233 if (triggerSF) {
234
235 double sf_trigger = 1.;
236
237 CP::CorrectionCode res = m_photonTriggerSFTool->getEfficiencyScaleFactor( ph, sf_trigger );
238 if (res == CP::CorrectionCode::OutOfValidityRange) ATH_MSG_WARNING(" GetSignalPhotonSF: TriggerScaleFactor out of validity range");
239
240 sf *= sf_trigger;
241 }
242
243 ATH_MSG_VERBOSE( "ScaleFactor " << sf );
244
245 dec_effscalefact(ph) = sf;
246 return sf;
247}
std::pair< std::vector< unsigned int >, bool > res

◆ GetSignalPhotonSFsys()

double ST::SUSYObjDef_xAOD::GetSignalPhotonSFsys ( const xAOD::Photon & ph,
const CP::SystematicSet & systConfig,
const bool effSF = true,
const bool isoSF = true,
const bool triggerSF = false )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 250 of file Photons.cxx.

251{
252 double sf(1.);
253
254 //Set the new systematic variation
255 StatusCode ret = m_photonEfficiencySFTool->applySystematicVariation(systConfig);
256 if (ret != StatusCode::SUCCESS) {
257 ATH_MSG_ERROR("Cannot configure AsgPhotonEfficiencyCorrectionTool (reco) for systematic var. " << systConfig.name() );
258 }
259
260 ret = m_photonIsolationSFTool->applySystematicVariation(systConfig);
261 if (ret != StatusCode::SUCCESS) {
262 ATH_MSG_ERROR("Cannot configure AsgPhotonEfficiencyCorrectionTool (iso) for systematic var. " << systConfig.name() );
263 }
264
265 ret = m_photonTriggerSFTool->applySystematicVariation(systConfig);
266 if (ret != StatusCode::SUCCESS) {
267 ATH_MSG_ERROR("Cannot configure AsgPhotonEfficiencyCorrectionTool (trigger) for systematic var. " << systConfig.name() );
268 }
269
270 if (effSF) {
271
272 double sf_eff = 1.;
273
274 CP::CorrectionCode res = m_photonEfficiencySFTool->getEfficiencyScaleFactor( ph, sf_eff );
275 if (res == CP::CorrectionCode::OutOfValidityRange) ATH_MSG_WARNING(" GetSignalPhotonSF: getEfficiencyScaleFactor out of validity range");
276
277 sf *= sf_eff;
278 }
279
280 if (isoSF) {
281
282 double sf_iso = 1.;
283
284 CP::CorrectionCode res = m_photonIsolationSFTool->getEfficiencyScaleFactor( ph, sf_iso );
285 if (res == CP::CorrectionCode::OutOfValidityRange) ATH_MSG_WARNING(" GetSignalPhotonSF: getEfficiencyScaleFactor out of validity range");
286
287 sf *= sf_iso;
288 }
289
290 if (triggerSF) {
291
292 double sf_trigger = 1.;
293
294 CP::CorrectionCode res = m_photonTriggerSFTool->getEfficiencyScaleFactor( ph, sf_trigger );
295 if (res == CP::CorrectionCode::OutOfValidityRange) ATH_MSG_WARNING(" GetSignalPhotonSF: getEfficiencyScaleFactor out of validity range");
296
297 sf *= sf_trigger;
298 }
299
300 //Roll back to current sys
301 ret = m_photonEfficiencySFTool->applySystematicVariation(m_currentSyst);
302 if (ret != StatusCode::SUCCESS) {
303 ATH_MSG_ERROR("Cannot configure AsgPhotonEfficiencyCorrectionTool back to default.");
304 }
305
306 ret = m_photonIsolationSFTool->applySystematicVariation(m_currentSyst);
307 if (ret != StatusCode::SUCCESS) {
308 ATH_MSG_ERROR("Cannot configure AsgPhotonEfficiencyCorrectionTool (iso) for systematic var. " << systConfig.name() );
309 }
310
311 ret = m_photonTriggerSFTool->applySystematicVariation(m_currentSyst);
312 if (ret != StatusCode::SUCCESS) {
313 ATH_MSG_ERROR("Cannot configure AsgPhotonEfficiencyCorrectionTool (trigger) for systematic var. " << systConfig.name() );
314 }
315
316 ATH_MSG_VERBOSE( "ScaleFactor " << sf );
317
318 dec_effscalefact(ph) = sf;
319 return sf;
320}

◆ GetSignalTauSF()

double ST::SUSYObjDef_xAOD::GetSignalTauSF ( const xAOD::TauJet & tau,
const bool idSF = true,
const bool triggerSF = true,
const std::string & trigExpr = "tau25_medium1_tracktwo" )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 134 of file Taus.cxx.

138{
139 double sf(1.);
140
141 // TEMPORARY: no recommendations yet for 2024+
142 if (acc_signal(tau) && this->treatAsYear()<2024) {
143 if (idSF) {
144 if (m_tauEffTool->getEfficiencyScaleFactor(tau, sf) != CP::CorrectionCode::Ok) {
145 ATH_MSG_WARNING("Failed to retrieve tau efficiency scale factor.");
146 }
147 ATH_MSG_VERBOSE(" Retrieved tau SF " << sf);
148 }
149
150 if (triggerSF) {
151 double trig_sf = GetTauTriggerEfficiencySF(tau, trigExpr);
152
153 if (trig_sf > -90) {
154 sf *= trig_sf;
155 ATH_MSG_VERBOSE(" Retrieved tau trig SF " << trig_sf);
156 }
157 }
158 }
159
160 dec_effscalefact(tau) = sf;
161 return sf;
162}
double GetTauTriggerEfficiencySF(const xAOD::TauJet &tau, const std::string &trigExpr="tau25_medium1_tracktwo") override final
Definition Taus.cxx:202

◆ GetSignalTauSFsys()

double ST::SUSYObjDef_xAOD::GetSignalTauSFsys ( const xAOD::TauJet & tau,
const CP::SystematicSet & systConfig,
const bool idSF = true,
const bool triggerSF = true,
const std::string & trigExpr = "tau25_medium1_tracktwo" )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 165 of file Taus.cxx.

170{
171 double sf(1.);
172
173 // TEMPORARY: no recommendations yet for 2024+
174 if (this->treatAsYear()<2024) {
175 //Set the new systematic variation
176 StatusCode ret = m_tauEffTool->applySystematicVariation(systConfig);
177 if (ret != StatusCode::SUCCESS) { ATH_MSG_ERROR("Cannot configure TauEfficiencyCorrectionsTool for systematic var. " << systConfig.name() ); }
178
179 for (auto& tool : m_tauTrigEffTool) {
180 ret = tool->applySystematicVariation(systConfig);
181 if (ret != StatusCode::SUCCESS) { ATH_MSG_ERROR("Cannot configure " << tool->name() << " for systematic var. " << systConfig.name()); }
182 }
183
184 sf *= GetSignalTauSF(tau, idSF, triggerSF, trigExpr);
185
186 //Roll back to default
187 ret = m_tauEffTool->applySystematicVariation(m_currentSyst);
188 if (ret != StatusCode::SUCCESS) { ATH_MSG_ERROR("Cannot configure TauEfficiencyCorrectionsTool back to default"); }
189
190 for (auto& tool : m_tauTrigEffTool) {
191 ret = tool->applySystematicVariation(m_currentSyst);
192 if (ret != StatusCode::SUCCESS) { ATH_MSG_ERROR("Cannot configure " << tool->name() << " back to default"); }
193 }
194 }
195
196 dec_effscalefact(tau) = sf;
197
198 return sf;
199}
double GetSignalTauSF(const xAOD::TauJet &tau, const bool idSF=true, const bool triggerSF=true, const std::string &trigExpr="tau25_medium1_tracktwo") override final
Definition Taus.cxx:134

◆ GetSumOfWeights()

double ST::SUSYObjDef_xAOD::GetSumOfWeights ( int channel)
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 3092 of file SUSYObjDef_xAOD.cxx.

3092 {
3093 return m_prwTool->GetSumOfEventWeights(channel);
3094}

◆ getSystInfo()

ST::SystInfo ST::SUSYObjDef_xAOD::getSystInfo ( const CP::SystematicVariation & sys) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 2629 of file SUSYObjDef_xAOD.cxx.

2629 {
2630
2631 SystInfo sysInfo;
2632 sysInfo.affectsKinematics = false;
2633 sysInfo.affectsWeights = false;
2634 sysInfo.affectedWeights.clear();
2635 sysInfo.systset.insert(sys);
2636
2637 if (!m_jetNNJvtEfficiencyTool.empty()) {
2638 if ( m_jetNNJvtEfficiencyTool->isAffectedBySystematic( sys ) ) {
2639 sysInfo.affectsWeights = true;
2640 sysInfo.affectsType = SystObjType::Jet;
2641 sysInfo.affectedWeights.insert(ST::Weights::Jet::JVT);
2642 }
2643 }
2644
2645 if (!m_jetfJvtEfficiencyTool.empty()) {
2646 if ( m_jetfJvtEfficiencyTool->isAffectedBySystematic( sys ) ) {
2647 sysInfo.affectsWeights = true;
2648 sysInfo.affectsType = SystObjType::Jet;
2649 sysInfo.affectedWeights.insert(ST::Weights::Jet::FJVT);
2650 }
2651 }
2652
2653 if (!m_jetUncertaintiesTool.empty()) {
2654 if ( m_jetUncertaintiesTool->isAffectedBySystematic( sys ) ) {
2655 sysInfo.affectsKinematics = true;
2656 sysInfo.affectsType = SystObjType::Jet;
2657 }
2658 }
2659 if (!m_jetUncertaintiesPDSmearTool.empty()) {
2660 if ( m_jetUncertaintiesPDSmearTool->isAffectedBySystematic( sys ) ) {
2661 sysInfo.affectsKinematics = true;
2662 sysInfo.affectsType = SystObjType::Jet;
2663 }
2664 }
2665
2666 if (!m_fatjetUncertaintiesTool.empty()) {
2667 if ( m_fatjetUncertaintiesTool->isAffectedBySystematic( sys ) ) {
2668 sysInfo.affectsKinematics = true;
2669 sysInfo.affectsType = SystObjType::Jet;
2670 }
2671 }
2672 if (!m_fatjetUncertaintiesPDSmearTool.empty()) {
2673 if ( m_fatjetUncertaintiesPDSmearTool->isAffectedBySystematic( sys ) ) {
2674 sysInfo.affectsKinematics = true;
2675 sysInfo.affectsType = SystObjType::Jet;
2676 }
2677 }
2678
2679 if (!m_fatjetFFSmearingTool.empty()) {
2680 CP::SystematicSet dummy;
2681 dummy.insert(sys);
2682 if ( std::find(m_fatjetFFSmearingSyst.begin(), m_fatjetFFSmearingSyst.end(), dummy) != m_fatjetFFSmearingSyst.end() ) {
2683 sysInfo.affectsKinematics = true;
2684 sysInfo.affectsType = SystObjType::Jet;
2685 }
2686 }
2687
2688 if (!m_WTagjetUncertaintiesTool.empty()) {
2689 if ( m_WTagjetUncertaintiesTool->isAffectedBySystematic( CP::SystematicVariation(sys.basename(), CP::SystematicVariation::CONTINUOUS) ) ) {
2690 sysInfo.affectsKinematics = true;
2691 sysInfo.affectsType = SystObjType::Jet;
2692 }
2693 }
2694 if (!m_ZTagjetUncertaintiesTool.empty()) {
2695 if ( m_ZTagjetUncertaintiesTool->isAffectedBySystematic( CP::SystematicVariation(sys.basename(), CP::SystematicVariation::CONTINUOUS) ) ) {
2696 sysInfo.affectsKinematics = true;
2697 sysInfo.affectsType = SystObjType::Jet;
2698 }
2699 }
2700 if (!m_TopTagjetUncertaintiesTool.empty()) {
2701 if ( m_TopTagjetUncertaintiesTool->isAffectedBySystematic( CP::SystematicVariation(sys.basename(), CP::SystematicVariation::CONTINUOUS) ) ) {
2702 sysInfo.affectsKinematics = true;
2703 sysInfo.affectsType = SystObjType::Jet;
2704 }
2705 }
2706
2707 if (!m_muonCalibTool.empty()) {
2708 if ( m_muonCalibTool->isAffectedBySystematic(sys) ) {
2709 sysInfo.affectsKinematics = true;
2710 sysInfo.affectsType = SystObjType::Muon;
2711 }
2712 }
2714 if ( m_elecEfficiencySFTool_trig_singleLep->isAffectedBySystematic(sys) ) {
2715 sysInfo.affectsWeights = true;
2716 sysInfo.affectsType = SystObjType::Electron;
2717 sysInfo.affectedWeights.insert(ST::Weights::Electron::Trigger);
2718 }
2719 }
2721 if ( m_elecEfficiencySFTool_trigEff_singleLep->isAffectedBySystematic(sys) ) {
2722 sysInfo.affectsWeights = true;
2723 sysInfo.affectsType = SystObjType::Electron;
2724 sysInfo.affectedWeights.insert(ST::Weights::Electron::Trigger);
2725 }
2726 }
2727 if (!m_muonEfficiencySFTool.empty()) {
2728 if ( m_muonEfficiencySFTool->isAffectedBySystematic(sys) ) {
2729 sysInfo.affectsWeights = true;
2730 sysInfo.affectsType = SystObjType::Muon;
2731 sysInfo.affectedWeights.insert(ST::Weights::Muon::Reconstruction);
2732 }
2733 }
2734 if (!m_muonEfficiencyBMHighPtSFTool.empty()) {
2735 if ( m_muonEfficiencyBMHighPtSFTool->isAffectedBySystematic(sys) ) {
2736 sysInfo.affectsWeights = true;
2737 sysInfo.affectsType = SystObjType::Muon;
2738 sysInfo.affectedWeights.insert(ST::Weights::Muon::Reconstruction);
2739 }
2740 }
2741 if (!m_muonTTVAEfficiencySFTool.empty()) {
2742 if ( m_muonTTVAEfficiencySFTool->isAffectedBySystematic(sys) ) {
2743 sysInfo.affectsWeights = true;
2744 sysInfo.affectsType = SystObjType::Muon;
2745 sysInfo.affectedWeights.insert(ST::Weights::Muon::Reconstruction);
2746 }
2747 }
2748 if (!m_muonIsolationSFTool.empty()) {
2749 if ( m_muonIsolationSFTool->isAffectedBySystematic(sys) ) {
2750 sysInfo.affectsWeights = true;
2751 sysInfo.affectsType = SystObjType::Muon;
2752 sysInfo.affectedWeights.insert(ST::Weights::Muon::Isolation);
2753 }
2754 }
2755 if (!m_muonTriggerSFTool.empty()) {
2756 if ( m_muonTriggerSFTool->isAffectedBySystematic(sys) ) {
2757 sysInfo.affectsWeights = true;
2758 sysInfo.affectsType = SystObjType::Muon;
2759 sysInfo.affectedWeights.insert(ST::Weights::Muon::Trigger);
2760 }
2761 }
2762 if (!m_elecEfficiencySFTool_reco.empty()) {
2763 if ( m_elecEfficiencySFTool_reco->isAffectedBySystematic(sys) ) {
2764 sysInfo.affectsWeights = true;
2765 sysInfo.affectsType = SystObjType::Electron;
2766 sysInfo.affectedWeights.insert(ST::Weights::Electron::Reconstruction);
2767 }
2768 }
2769 if (!m_elecEfficiencySFTool_id.empty()) {
2770 if ( m_elecEfficiencySFTool_id->isAffectedBySystematic(sys) ) {
2771 sysInfo.affectsWeights = true;
2772 sysInfo.affectsType = SystObjType::Electron;
2773 sysInfo.affectedWeights.insert(ST::Weights::Electron::ID);
2774 }
2775 }
2776 if (!m_trigGlobalEffCorrTool_diLep.empty()) {
2777 if ( m_trigGlobalEffCorrTool_diLep->isAffectedBySystematic(sys) ) {
2778 sysInfo.affectsWeights = true;
2779 sysInfo.affectsType = SystObjType::Electron;
2780 sysInfo.affectedWeights.insert(ST::Weights::Electron::Trigger);
2781 }
2782 }
2783 if (!m_trigGlobalEffCorrTool_multiLep.empty()) {
2784 if ( m_trigGlobalEffCorrTool_multiLep->isAffectedBySystematic(sys) ) {
2785 sysInfo.affectsWeights = true;
2786 sysInfo.affectsType = SystObjType::Electron;
2787 sysInfo.affectedWeights.insert(ST::Weights::Electron::Trigger);
2788 }
2789 }
2790 if (!m_elecEfficiencySFTool_iso.empty() ) {
2791 if ( m_elecEfficiencySFTool_iso->isAffectedBySystematic(sys) ) {
2792 sysInfo.affectsWeights = true;
2793 sysInfo.affectsType = SystObjType::Electron;
2794 sysInfo.affectedWeights.insert(ST::Weights::Electron::Isolation);
2795 }
2796 }
2797 if (!m_elecEfficiencySFTool_isoHighPt.empty() ) {
2798 if ( m_elecEfficiencySFTool_isoHighPt->isAffectedBySystematic(sys) ) {
2799 sysInfo.affectsWeights = true;
2800 sysInfo.affectsType = SystObjType::Electron;
2801 sysInfo.affectedWeights.insert(ST::Weights::Electron::Isolation);
2802 }
2803 }
2804 if (!m_egammaCalibTool.empty()) {
2805 if ( m_egammaCalibTool->isAffectedBySystematic(sys) ) {
2806 sysInfo.affectsKinematics = true;
2807 if (sys.basename().compare(0, 3, "EG_") == 0) {
2808 sysInfo.affectsType = SystObjType::Egamma;
2809 } else if (sys.basename().compare(0, 3, "PH_") == 0) {
2810 sysInfo.affectsType = SystObjType::Photon;
2811 } else if (sys.basename().compare(0, 3, "EL_") == 0) {
2812 sysInfo.affectsType = SystObjType::Electron;
2813 }
2814 }
2815 }
2816 if (!isData() && !m_isoCorrTool.empty()) {
2817 if (m_isoCorrTool->isAffectedBySystematic(sys)){
2818 sysInfo.affectsWeights = false;
2819 sysInfo.affectsKinematics = true;
2820 sysInfo.affectsType = SystObjType::Photon;
2821 }
2822 }
2823 if (!isData() && !m_photonEfficiencySFTool.empty()) {
2824 if (m_photonEfficiencySFTool->isAffectedBySystematic(CP::SystematicVariation(sys.basename(), CP::SystematicVariation::CONTINUOUS)) ) {
2825 sysInfo.affectsWeights = true;
2826 sysInfo.affectsType = SystObjType::Photon;
2827 sysInfo.affectedWeights.insert(ST::Weights::Photon::Reconstruction);
2828 }
2829 }
2830 if (!isData() && !m_photonIsolationSFTool.empty()) {
2831 if (m_photonIsolationSFTool->isAffectedBySystematic(sys)) {
2832 sysInfo.affectsWeights = true;
2833 sysInfo.affectsType = SystObjType::Photon;
2834 sysInfo.affectedWeights.insert(ST::Weights::Photon::Isolation);
2835 }
2836 }
2837 if (!isData() && !m_photonTriggerSFTool.empty()) {
2838 if (m_photonTriggerSFTool->isAffectedBySystematic(sys)) {
2839 sysInfo.affectsWeights = true;
2840 sysInfo.affectsType = SystObjType::Photon;
2841 sysInfo.affectedWeights.insert(ST::Weights::Photon::Trigger);
2842 }
2843 }
2844 if (!m_trigGlobalEffCorrTool_diPhoton.empty()) {
2845 if ( m_trigGlobalEffCorrTool_diPhoton->isAffectedBySystematic(sys) ) {
2846 sysInfo.affectsWeights = true;
2847 sysInfo.affectsType = SystObjType::Photon;
2848 sysInfo.affectedWeights.insert(ST::Weights::Photon::Trigger);
2849 }
2850 }
2851 if ( !m_btagEffTool.empty() ) {
2852 if ( m_btagEffTool->isAffectedBySystematic(sys) ) {
2853 sysInfo.affectsWeights = true;
2854 sysInfo.affectsType = SystObjType::BTag;
2855 sysInfo.affectedWeights.insert(ST::Weights::Jet::Btag);
2856 }
2857 }
2858 if ( !m_btagEffTool_trkJet.empty() ) {
2859 if ( m_btagEffTool_trkJet->isAffectedBySystematic(sys) ) {
2860 sysInfo.affectsWeights = true;
2861 sysInfo.affectsType = SystObjType::BTag;
2862 sysInfo.affectedWeights.insert(ST::Weights::Jet::Btag_Track);
2863 }
2864 }
2865 if (!m_tauSmearingTool.empty()) {
2866 if ( m_tauSmearingTool->isAffectedBySystematic(sys) ) {
2867 sysInfo.affectsKinematics = true;
2868 sysInfo.affectsType = SystObjType::Tau;
2869 }
2870 }
2871 if (!m_tauEffTool.empty()) {
2872 if ( m_tauEffTool->isAffectedBySystematic(sys) ) {
2873 sysInfo.affectsWeights = true;
2874 sysInfo.affectsType = SystObjType::Tau;
2875 sysInfo.affectedWeights.insert(ST::Weights::Tau::Reconstruction);
2876 }
2877 }
2878 for(const auto &tool : m_tauTrigEffTool) {
2879 if(tool->isAffectedBySystematic(sys)) {
2880 sysInfo.affectsWeights = true;
2881 sysInfo.affectsType = SystObjType::Tau;
2882 sysInfo.affectedWeights.insert(ST::Weights::Tau::Trigger);
2883 break;
2884 }
2885 }
2886 if (!m_metSystTool.empty()) {
2887 if ( m_metSystTool->isAffectedBySystematic(sys) ) {
2888 sysInfo.affectsKinematics = true;
2889 switch (met::getSystType(sys)) {
2890 case met::SOFTCALO:
2891 sysInfo.affectsType = SystObjType::MET_CST;
2892 break;
2893 case met::SOFTTRK:
2894 sysInfo.affectsType = SystObjType::MET_TST;
2895 break;
2896 case met::JETTRK:
2897 sysInfo.affectsType = SystObjType::MET_Track;
2898 break;
2899 default:
2900 ATH_MSG_ERROR("Unsupported systematic!");
2901 }
2902 }
2903 }
2904 if (!m_prwTool.empty()) {
2905 if ( m_prwTool->isAffectedBySystematic(sys) ) {
2906 sysInfo.affectsWeights = true;
2907 sysInfo.affectsType = SystObjType::EventWeight;
2908 }
2909 }
2910
2911 if (!m_LRTuncTool.empty()){
2912 if ( m_LRTuncTool->isAffectedBySystematic(sys) ) {
2913 sysInfo.affectsKinematics = true;
2914 sysInfo.affectsType = SystObjType::LRT_Object;
2915 }
2916 }
2917
2918 std::string affectedType;
2919 switch (sysInfo.affectsType) {
2920 case Unknown : affectedType = "UNKNOWN"; break;
2921 case Jet : affectedType = "JET"; break;
2922 case Egamma : affectedType = "EGAMMA"; break;
2923 case Electron : affectedType = "ELECTRON"; break;
2924 case Photon : affectedType = "PHOTON"; break;
2925 case Muon : affectedType = "MUON"; break;
2926 case Tau : affectedType = "TAU"; break;
2927 case BTag : affectedType = "BTAG"; break;
2928 case MET_TST : affectedType = "MET_TST"; break;
2929 case MET_CST : affectedType = "MET_CST"; break;
2930 case MET_Track : affectedType = "MET_Track"; break;
2931 case EventWeight : affectedType = "EVENT WEIGHT"; break;
2932 case LRT_Object : affectedType = "LRT_OBJECT"; break;
2933 }
2934
2935 ATH_MSG_VERBOSE("Variation " << sys.name() << " affects "
2936 << ( sysInfo.affectsWeights ? "weights " : "" )
2937 << ( sysInfo.affectsKinematics ? "kinematics " : "" )
2938 << "for " << affectedType );
2939
2940 return sysInfo;
2941
2942}
static const unsigned int Reconstruction
static const unsigned int Trigger
SystType getSystType(const CP::SystematicVariation &systematic)
@ Unknown
Track fitter not defined.
Egamma_v1 Egamma
Definition of the current "egamma version".
Definition Egamma.h:17

◆ getSystInfoList()

std::vector< ST::SystInfo > ST::SUSYObjDef_xAOD::getSystInfoList ( ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 2594 of file SUSYObjDef_xAOD.cxx.

2594 {
2595 if (!m_tool_init) {
2596 ATH_MSG_ERROR("SUSYTools was not initialized!!");
2597 return vector<ST::SystInfo>();
2598 }
2599
2600 ATH_MSG_INFO("Extracting systematics info list");
2601
2602 // Now we can look at systematics:
2603 const CP::SystematicRegistry& registry = CP::SystematicRegistry::getInstance();
2604 const CP::SystematicSet& recommendedSystematics = registry.recommendedSystematics();
2605
2606 vector<SystInfo> sysInfoList;
2607 sysInfoList.reserve(recommendedSystematics.size() * 2); // allow for continuous systematics
2608
2609 // this is the nominal set
2610 SystInfo infodef;
2611 infodef.affectsKinematics = false;
2612 infodef.affectsWeights = false;
2613 infodef.affectsType = Unknown;
2614 infodef.affectedWeights.clear();
2615 sysInfoList.push_back(infodef);
2616
2617
2618 // add all recommended systematics
2619 for (const auto& systSet : CP::make_systematics_vector(recommendedSystematics)) {
2620 for (const auto& sys : systSet) {
2621 sysInfoList.push_back(getSystInfo(sys));
2622 }
2623 }
2624
2625 ATH_MSG_INFO("Returning list of " << sysInfoList.size() << " systematic variations");
2626 return sysInfoList;
2627}
const SystematicSet & recommendedSystematics() const
returns: the recommended set of systematics
static SystematicRegistry & getInstance()
Get the singleton instance of the registry for the curren thread.
ST::SystInfo getSystInfo(const CP::SystematicVariation &sys) const override final
std::vector< CP::SystematicSet > make_systematics_vector(const SystematicSet &systematics)
utility functions for working with systematics

◆ getTauConfig()

StatusCode ST::SUSYObjDef_xAOD::getTauConfig ( const std::string & tauConfigPath,
std::vector< float > & pT_window,
std::vector< float > & eta_window,
bool & eleOLR,
bool & muVeto,
bool & muOLR ) const
protected

Definition at line 1904 of file SUSYObjDef_xAOD.cxx.

1904 {
1905
1906 if(tauConfigPath.empty()) return StatusCode::FAILURE;
1907
1908 TEnv rEnv;
1909 auto filename = PathResolverFindCalibFile(tauConfigPath);
1910 if ( rEnv.ReadFile(filename.c_str(), kEnvAll) ) {
1911 ATH_MSG_ERROR( "Error while reading tau config file : " << filename );
1912 ATH_MSG_ERROR( "Find examples at: https://gitlab.cern.ch/atlas/athena/-/tree/main/PhysicsAnalysis/Algorithms/TauAnalysisAlgorithms/data");
1913 return StatusCode::FAILURE;
1914 } else {
1915 ATH_MSG_DEBUG( "Successfully read tau config file : " << filename );
1916 }
1917
1918 std::vector<std::string> cuts;
1919 if (rEnv.Defined("SelectionCuts")) {
1920 cuts = split(rEnv.GetValue("SelectionCuts", " "), " ");
1921 } else {
1922 auto *l = rEnv.GetTable();
1923 for( Int_t i = 0; i < l->GetEntries(); ++i ) {
1924 cuts.push_back( l->At(i)->GetName() );
1925 }
1926 }
1927
1928 //default OR settings
1929 eleOLR=false;
1930 muOLR=false;
1931 muVeto=false;
1932
1933 static const std::string trueBool = "TRUE";
1934
1935 // Now find the pT and eta window
1936 std::vector<std::string> v_pT_window;
1937 std::vector<std::string> v_eta_window;
1938 pT_window.clear();
1939 eta_window.clear();
1940 float pT_min = -99.0;
1941 float pT_max = -99.0;
1942 float eta_min = -99.0;
1943 float eta_max = -99.0;
1944 for (const auto& cut : cuts) {
1945 if(cut == "PtRegion") {
1946 v_pT_window = split(rEnv.GetValue("PtRegion", ""), ";");
1947 std::transform(std::begin(v_pT_window),
1948 std::end(v_pT_window),
1949 std::back_inserter(pT_window),
1950 [](const std::string& s) { return std::stof(s); }
1951 );
1952 } else if (cut == "PtMin") {
1953 pT_min = rEnv.GetValue("PtMin", NAN);
1954 } else if (cut == "PtMax") {
1955 pT_max = rEnv.GetValue("PtMax", NAN);
1956 } else if (cut == "AbsEtaRegion") {
1957 v_eta_window = split(rEnv.GetValue("AbsEtaRegion", ""), ";");
1958 std::transform(std::begin(v_eta_window),
1959 std::end(v_eta_window),
1960 std::back_inserter(eta_window),
1961 [](const std::string& s) { return std::stof(s); }
1962 );
1963 } else if (cut == "AbsEtaMin") {
1964 eta_min = rEnv.GetValue("AbsEtaMin", NAN);
1965 } else if (cut == "AbsEtaMax") {
1966 eta_max = rEnv.GetValue("AbsEtaMax", NAN);
1967 }
1968
1969 //OR settings
1970 else if (cut == "EleOLR"){
1971 eleOLR = (rEnv.GetValue("EleOLR", "FALSE") == trueBool);
1972 }
1973 else if (cut == "MuonVeto"){
1974 muVeto = (rEnv.GetValue("MuonVeto", "FALSE") == trueBool);
1975 }
1976 else if (cut == "MuonOLR"){
1977 muOLR = (rEnv.GetValue("MuonOLR", "FALSE") == trueBool);
1978 }
1979 }
1980
1981 if(pT_window.empty()) {
1982 if(pT_min == pT_min) {
1983 // fails on NaN
1984 pT_window.push_back(pT_min);
1985 } else {
1986 pT_window.push_back(-std::numeric_limits<float>::infinity());
1987 }
1988
1989 if(pT_max == pT_max) {
1990 // fails on NaN
1991 pT_window.push_back(pT_max);
1992 } else {
1993 pT_window.push_back(std::numeric_limits<float>::infinity());
1994 }
1995 }
1996
1997 if(eta_window.empty()) {
1998 if(eta_min == eta_min) {
1999 // fails on NaN
2000 eta_window.push_back(eta_min);
2001 } else {
2002 eta_window.push_back(-std::numeric_limits<float>::infinity());
2003 }
2004
2005 if(eta_max == eta_max) {
2006 // fails on NaN
2007 eta_window.push_back(eta_max);
2008 } else {
2009 eta_window.push_back(std::numeric_limits<float>::infinity());
2010 }
2011 }
2012
2013 return StatusCode::SUCCESS;
2014}
l
Printing final latex table to .tex output file.

◆ GetTaus()

StatusCode ST::SUSYObjDef_xAOD::GetTaus ( xAOD::TauJetContainer *& copy,
xAOD::ShallowAuxContainer *& copyaux,
const bool recordSG = true,
const std::string & taukey = "TauJets",
const xAOD::TauJetContainer * containerToBeCopied = nullptr )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 31 of file Taus.cxx.

33{
34 if (!m_tool_init) {
35 ATH_MSG_ERROR("SUSYTools was not initialized!!");
36 return StatusCode::FAILURE;
37 }
38
39 if (m_isPHYSLITE && taukey.find("AnalysisTauJets")==std::string::npos){
40 ATH_MSG_ERROR("You are running on PHYSLITE derivation. Please change the Taus container to 'AnalysisTauJets'");
41 return StatusCode::FAILURE;
42 }
43
44 const xAOD::TauJetContainer* taus = nullptr;
45 if (copy==nullptr) { // empty container provided
46 if (containerToBeCopied != nullptr) {
47 taus = containerToBeCopied;
48 }
49 else {
50 ATH_CHECK( evtStore()->retrieve(taus, taukey) );
51 }
53 copy = shallowcopy.first.get();
54 copyaux = shallowcopy.second.get();
55 bool setLinks = xAOD::setOriginalObjectLink(*taus, *copy);
56 if (!setLinks) {
57 ATH_MSG_WARNING("Failed to set original object links on " << taukey);
58 }
59 if (recordSG) {
60 ATH_CHECK( evtStore()->record(std::move(shallowcopy.first), "STCalib" + taukey + m_currentSyst.name()) );
61 ATH_CHECK( evtStore()->record(std::move(shallowcopy.second), "STCalib" + taukey + m_currentSyst.name() + "Aux.") );
62 } else {
63 ATH_MSG_ERROR("Shallow copy not recorded in StoreGate!");
64 return StatusCode::FAILURE;
65 }
66 } else { // use the user-supplied collection instead
67 ATH_MSG_DEBUG("Not retrieving tau collecton, using existing one provided by user");
68 taus=copy;
69 }
70
71 for (const auto tau : *copy) {
72 ATH_CHECK( this->FillTau(*tau) );
73 this->IsSignalTau(*tau, m_tauPt, m_tauEta);
74 }
75
76 return StatusCode::SUCCESS;
77}
static Double_t taus
StatusCode FillTau(xAOD::TauJet &input) override final
Definition Taus.cxx:81
bool IsSignalTau(const xAOD::TauJet &input, const float ptcut, const float etacut) const override final
Definition Taus.cxx:116
TauJetContainer_v3 TauJetContainer
Definition of the current "taujet container version".

◆ GetTauTriggerEfficiencySF()

double ST::SUSYObjDef_xAOD::GetTauTriggerEfficiencySF ( const xAOD::TauJet & tau,
const std::string & trigExpr = "tau25_medium1_tracktwo" )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 202 of file Taus.cxx.

202 {
203
204 double eff(1.);
205
206 auto map_it = m_tau_trig_support.find(trigExpr);
207 if (map_it == m_tau_trig_support.end()) {
208 ATH_MSG_WARNING("The trigger item requested (" << trigExpr << ") is not supported! Please check. Setting SF to 1.");
209 return eff;
210 }
211
212 // trigger matching (dR=0.2)
213 std::vector<std::string> chains;
214 for (auto part : std::views::split(map_it->second, ',')) chains.emplace_back(&*part.begin(), std::ranges::distance(part));
215 bool match = false;
216 for (const std::string& chain : chains)
217 if (m_trigMatchingTool->match({&tau}, chain, 0.2)) {
218 match = true;
219 break;
220 }
221 if (!match) {
222 ATH_MSG_VERBOSE("Tau did not match trigger " << trigExpr);
223 return eff;
224 }
225
226 int trigIdx = std::distance(std::begin(m_tau_trig_support), map_it);
227 if (m_tauTrigEffTool.at(trigIdx)->getEfficiencyScaleFactor(tau, eff) != CP::CorrectionCode::Ok) {
228 ATH_MSG_ERROR("Some problem found to retrieve SF for trigger item requested (" << trigExpr << ")");
229 eff = -99;
230 }
231
232 return eff;
233}
std::map< std::string, std::string > m_tau_trig_support
bool match(std::string s1, std::string s2)
match the individual directories of two strings
Definition hcg.cxx:359

◆ GetTotalElectronSF()

float ST::SUSYObjDef_xAOD::GetTotalElectronSF ( const xAOD::ElectronContainer & electrons,
const bool recoSF = true,
const bool idSF = true,
const bool triggerSF = true,
const bool isoSF = true,
const std::string & trigExpr = "singleLepton",
const bool ecidsSF = false,
const bool cidSF = false )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 630 of file Electrons.cxx.

630 {
631 float sf(1.);
632
633 for (const xAOD::Electron* electron : electrons) {
634 if (!acc_passOR(*electron)) continue;
635 if (acc_signal(*electron)) { sf *= this->GetSignalElecSF(*electron, recoSF, idSF, triggerSF, isoSF, trigExpr, ecidsSF, cidSF); }
636 else { this->GetSignalElecSF(*electron, recoSF, idSF, triggerSF, isoSF, trigExpr, ecidsSF, cidSF); }
637 }
638
639 return sf;
640}
float GetSignalElecSF(const xAOD::Electron &el, const bool recoSF=true, const bool idSF=true, const bool triggerSF=true, const bool isoSF=true, const std::string &trigExpr="singleLepton", const bool ecidsSF=false, const bool cidSF=false) override final

◆ GetTotalElectronSFsys()

float ST::SUSYObjDef_xAOD::GetTotalElectronSFsys ( const xAOD::ElectronContainer & electrons,
const CP::SystematicSet & systConfig,
const bool recoSF = true,
const bool idSF = true,
const bool triggerSF = true,
const bool isoSF = true,
const std::string & trigExpr = "singleLepton",
const bool ecidsSF = false,
const bool cidSF = false )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 643 of file Electrons.cxx.

643 {
644 float sf(1.);
645
646 //Set the new systematic variation
647 StatusCode ret(StatusCode::SUCCESS);
648 if(!m_elecEfficiencySFTool_reco.empty()){
649 ret = m_elecEfficiencySFTool_reco->applySystematicVariation(systConfig);
650 if (ret != StatusCode::SUCCESS) {
651 ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (reco) for systematic var. " << systConfig.name() );
652 }
653 }
654
655 if(!m_elecEfficiencySFTool_id.empty()){
656 ret = m_elecEfficiencySFTool_id->applySystematicVariation(systConfig);
657 if (ret != StatusCode::SUCCESS) {
658 ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (id) for systematic var. " << systConfig.name() );
659 }
660 }
661
663 ret = m_elecEfficiencySFTool_trig_singleLep->applySystematicVariation(systConfig);
664 if (ret != StatusCode::SUCCESS) {
665 ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (trigger) for systematic var. " << systConfig.name() );
666 }
667 }
668
669 if(!m_elecEfficiencySFTool_iso.empty()){
670 ret = m_elecEfficiencySFTool_iso->applySystematicVariation(systConfig);
671 if (ret != StatusCode::SUCCESS) {
672 ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (iso) for systematic var. " << systConfig.name() );
673 }
674 }
675
677 ret = m_elecEfficiencySFTool_isoHighPt->applySystematicVariation(systConfig);
678 if (ret != StatusCode::SUCCESS) {
679 ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (iso high-pt) for systematic var. " << systConfig.name() );
680 }
681 }
682
683 if(!m_elecChargeEffCorrTool.empty()){
684 ret = m_elecChargeEffCorrTool->applySystematicVariation(systConfig);
685 if (ret != StatusCode::SUCCESS) {
686 ATH_MSG_ERROR("Cannot configure ElectronChargeEfficiencyCorrectionTool for systematic var. " << systConfig.name() );
687 }
688 }
689
690
691 //Get the total SF for new config
692 sf = GetTotalElectronSF(electrons, recoSF, idSF, triggerSF, isoSF, trigExpr, ecidsSF, cidSF);
693
694 //Roll back to default
695 if(!m_elecEfficiencySFTool_reco.empty()){
696 ret = m_elecEfficiencySFTool_reco->applySystematicVariation(m_currentSyst);
697 if (ret != StatusCode::SUCCESS) {
698 ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (reco) back to default.");
699 }
700 }
701
702 if(!m_elecEfficiencySFTool_id.empty()){
703 ret = m_elecEfficiencySFTool_id->applySystematicVariation(m_currentSyst);
704 if (ret != StatusCode::SUCCESS) {
705 ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (id) back to default.");
706 }
707 }
708
710 ret = m_elecEfficiencySFTool_trig_singleLep->applySystematicVariation(m_currentSyst);
711 if (ret != StatusCode::SUCCESS) {
712 ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (trigger) back to default.");
713 }
714 }
715
716 if(!m_elecEfficiencySFTool_iso.empty()){
717 ret = m_elecEfficiencySFTool_iso->applySystematicVariation(m_currentSyst);
718 if (ret != StatusCode::SUCCESS) {
719 ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (iso) back to default.");
720 }
721 }
722
724 ret = m_elecEfficiencySFTool_isoHighPt->applySystematicVariation(m_currentSyst);
725 if (ret != StatusCode::SUCCESS) {
726 ATH_MSG_ERROR("Cannot configure AsgElectronEfficiencyCorrectionTool (iso high-pt) back to default.");
727 }
728 }
729
730 if(!m_elecChargeEffCorrTool.empty()){
731 ret = m_elecChargeEffCorrTool->applySystematicVariation(m_currentSyst);
732 if (ret != StatusCode::SUCCESS) {
733 ATH_MSG_ERROR("Cannot configure ElectronChargeEfficiencyCorrectionTool back to default.");
734 }
735 }
736
737 return sf;
738}
float GetTotalElectronSF(const xAOD::ElectronContainer &electrons, const bool recoSF=true, const bool idSF=true, const bool triggerSF=true, const bool isoSF=true, const std::string &trigExpr="singleLepton", const bool ecidsSF=false, const bool cidSF=false) override final

◆ GetTotalJetSF()

double ST::SUSYObjDef_xAOD::GetTotalJetSF ( const xAOD::JetContainer * jets,
const bool btagSF = true,
const bool jvtSF = true,
const bool fjvtSF = false )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 1148 of file Jets.cxx.

1148 {
1149
1150 double totalSF = 1.;
1151 if (btagSF) totalSF *= BtagSF(jets);
1152
1153 if (jvtSF && m_applyJVTCut) totalSF *= JVT_SF(jets);
1154
1155 if (fjvtSF) totalSF *= FJVT_SF(jets);
1156
1157 return totalSF;
1158 }
double JVT_SF(const xAOD::JetContainer *jets) override final
Definition Jets.cxx:1006

◆ GetTotalJetSFsys()

double ST::SUSYObjDef_xAOD::GetTotalJetSFsys ( const xAOD::JetContainer * jets,
const CP::SystematicSet & systConfig,
const bool btagSF = true,
const bool jvtSF = true,
const bool fjvtSF = false )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 1161 of file Jets.cxx.

1161 {
1162
1163 double totalSF = 1.;
1164 if (btagSF) totalSF *= BtagSFsys(jets, systConfig);
1165
1166 if (jvtSF && m_applyJVTCut) totalSF *= JVT_SFsys(jets, systConfig);
1167
1168 if (fjvtSF) totalSF *= FJVT_SFsys(jets, systConfig);
1169
1170 return totalSF;
1171 }
double JVT_SFsys(const xAOD::JetContainer *jets, const CP::SystematicSet &systConfig) override final
Definition Jets.cxx:1053
double FJVT_SFsys(const xAOD::JetContainer *jets, const CP::SystematicSet &systConfig) override final
Definition Jets.cxx:1124
float BtagSFsys(const xAOD::JetContainer *jets, const CP::SystematicSet &systConfig) override final
Definition Jets.cxx:905

◆ GetTotalMuonSF()

double ST::SUSYObjDef_xAOD::GetTotalMuonSF ( const xAOD::MuonContainer & muons,
const bool recoSF = true,
const bool isoSF = true,
const std::string & trigExpr = "HLT_mu20_iloose_L1MU15_OR_HLT_mu50",
const bool bmhptSF = true )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 606 of file Muons.cxx.

606 {
607 double sf(1.);
608
609 ConstDataVector<xAOD::MuonContainer> sfmuons(SG::VIEW_ELEMENTS);
610 for (const xAOD::Muon* muon : muons) {
611 if( !acc_passOR(*muon) ) continue;
612 if (acc_signal(*muon)) {
613 sfmuons.push_back(muon);
614 if (recoSF || isoSF) { sf *= this->GetSignalMuonSF(*muon, recoSF, isoSF, bmhptSF); }
615 } else { // decorate baseline muons as well
616 if (recoSF || isoSF) { this->GetSignalMuonSF(*muon, recoSF, isoSF, bmhptSF, false); } //avoid OVR warnings in this case
617 }
618 }
619
620 sf *= GetTotalMuonTriggerSF(*sfmuons.asDataVector(), trigExpr);
621
622 return sf;
623}
double GetTotalMuonTriggerSF(const xAOD::MuonContainer &sfmuons, const std::string &trigExpr) override final
Definition Muons.cxx:551
float GetSignalMuonSF(const xAOD::Muon &mu, const bool recoSF=true, const bool isoSF=true, const bool doBadMuonHP=true, const bool warnOVR=true) override final
Definition Muons.cxx:484

◆ GetTotalMuonSFsys()

double ST::SUSYObjDef_xAOD::GetTotalMuonSFsys ( const xAOD::MuonContainer & muons,
const CP::SystematicSet & systConfig,
const bool recoSF = true,
const bool isoSF = true,
const std::string & trigExpr = "HLT_mu20_iloose_L1MU15_OR_HLT_mu50",
const bool bmhptSF = true )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 626 of file Muons.cxx.

626 {
627 double sf(1.);
628 //Set the new systematic variation
629 StatusCode ret = m_muonEfficiencySFTool->applySystematicVariation(systConfig);
630 if ( ret != StatusCode::SUCCESS) {
631 ATH_MSG_ERROR("Cannot configure MuonEfficiencyScaleFactors for systematic var. " << systConfig.name() );
632 }
633
634 ret = m_muonEfficiencyBMHighPtSFTool->applySystematicVariation(systConfig);
635 if ( ret != StatusCode::SUCCESS) {
636 ATH_MSG_ERROR("Cannot configure MuonBadMuonHighPtScaleFactors for systematic var. " << systConfig.name() );
637 }
638
639 ret = m_muonTTVAEfficiencySFTool->applySystematicVariation(systConfig);
640 if ( ret != StatusCode::SUCCESS) {
641 ATH_MSG_ERROR("Cannot configure MuonTTVAEfficiencyScaleFactors for systematic var. " << systConfig.name() );
642 }
643
644 ret = m_muonIsolationSFTool->applySystematicVariation(systConfig);
645 if ( ret != StatusCode::SUCCESS) {
646 ATH_MSG_ERROR("Cannot configure MuonIsolationScaleFactors for systematic var. " << systConfig.name() );
647 }
648
649 ret = m_muonHighPtIsolationSFTool->applySystematicVariation(systConfig);
650 if ( ret != StatusCode::SUCCESS) {
651 ATH_MSG_ERROR("Cannot configure MuonHighPtIsolationScaleFactors for systematic var. " << systConfig.name() );
652 }
653
654 ret = m_muonTriggerSFTool->applySystematicVariation(systConfig);
655 if ( ret != StatusCode::SUCCESS) {
656 ATH_MSG_ERROR("Cannot configure MuonTriggerScaleFactors for systematic var. " << systConfig.name() );
657 }
658
659 ret = m_trigGlobalEffCorrTool_diLep->applySystematicVariation(systConfig);
660 if (ret != StatusCode::SUCCESS) {
661 ATH_MSG_ERROR("Cannot configure TrigGlobalEfficiencyCorrectionTool (trigger) for systematic var. " << systConfig.name() );
662 }
663
664 ret = m_trigGlobalEffCorrTool_multiLep->applySystematicVariation(systConfig);
665 if (ret != StatusCode::SUCCESS) {
666 ATH_MSG_ERROR("Cannot configure TrigGlobalEfficiencyCorrectionTool (trigger) for systematic var. " << systConfig.name() );
667 }
668
669 sf = GetTotalMuonSF(muons, recoSF, isoSF, trigExpr, bmhptSF);
670
671 //Roll back to default
672 ret = m_muonEfficiencySFTool->applySystematicVariation(m_currentSyst);
673 if ( ret != StatusCode::SUCCESS) {
674 ATH_MSG_ERROR("Cannot configure MuonEfficiencyScaleFactors back to default.");
675 }
676
677 ret = m_muonEfficiencyBMHighPtSFTool->applySystematicVariation(m_currentSyst);
678 if ( ret != StatusCode::SUCCESS) {
679 ATH_MSG_ERROR("Cannot configure MuonBadMuonHighPtScaleFactors back to default.");
680 }
681
682 ret = m_muonTTVAEfficiencySFTool->applySystematicVariation(m_currentSyst);
683 if ( ret != StatusCode::SUCCESS) {
684 ATH_MSG_ERROR("Cannot configure MuonTTVAEfficiencyScaleFactors back to default.");
685 }
686
687 ret = m_muonIsolationSFTool->applySystematicVariation(m_currentSyst);
688 if ( ret != StatusCode::SUCCESS) {
689 ATH_MSG_ERROR("Cannot configure MuonIsolationScaleFactors back to default.");
690 }
691
692 ret = m_muonHighPtIsolationSFTool->applySystematicVariation(m_currentSyst);
693 if ( ret != StatusCode::SUCCESS) {
694 ATH_MSG_ERROR("Cannot configure MuonIsolationScaleFactors back to default.");
695 }
696
697 ret = m_muonTriggerSFTool->applySystematicVariation(m_currentSyst);
698 if ( ret != StatusCode::SUCCESS) {
699 ATH_MSG_ERROR("Cannot configure MuonTriggerScaleFactors back to default.");
700 }
701
702 ret = m_trigGlobalEffCorrTool_diLep->applySystematicVariation(m_currentSyst);
703 if (ret != StatusCode::SUCCESS) {
704 ATH_MSG_ERROR("Cannot configure TrigGlobalEfficiencyCorrectionTool (trigger) back to default.");
705 }
706
707 ret = m_trigGlobalEffCorrTool_multiLep->applySystematicVariation(m_currentSyst);
708 if (ret != StatusCode::SUCCESS) {
709 ATH_MSG_ERROR("Cannot configure TrigGlobalEfficiencyCorrectionTool (trigger) back to default.");
710 }
711
712 return sf;
713}
double GetTotalMuonSF(const xAOD::MuonContainer &muons, const bool recoSF=true, const bool isoSF=true, const std::string &trigExpr="HLT_mu20_iloose_L1MU15_OR_HLT_mu50", const bool bmhptSF=true) override final
Definition Muons.cxx:606

◆ GetTotalMuonTriggerSF()

double ST::SUSYObjDef_xAOD::GetTotalMuonTriggerSF ( const xAOD::MuonContainer & sfmuons,
const std::string & trigExpr )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 551 of file Muons.cxx.

551 {
552
553 if (trigExpr.empty() || sfmuons.empty()) return 1.;
554
555
556 double trig_sf = 1.;
557
558 int mulegs = 0;
559 const char *tmp = trigExpr.c_str();
560 while( (tmp = strstr(tmp, "mu")) ){
561 mulegs++;
562 tmp++;
563 }
564
565 bool isdimuon = (trigExpr.find("2mu") != std::string::npos);
566 bool isOR = (trigExpr.find("OR") != std::string::npos);
567
568 if((!isdimuon && mulegs<2) || (isdimuon && sfmuons.size()==2) || (mulegs>=2 && isOR)){ //Case 1: the tool takes easy care of the single, standard-dimuon and OR-of-single chains
569 if (m_muonTriggerSFTool->getTriggerScaleFactor( sfmuons, trig_sf, trigExpr ) == CP::CorrectionCode::Ok) {
570 ATH_MSG_DEBUG( "MuonTrig ScaleFactor " << trig_sf );
571 }
572 else{
573 ATH_MSG_DEBUG( "MuonTrig FAILED SOMEHOW");
574 }
575 }
576 else if(mulegs!=2 && isOR){ //Case 2: not supported. Not efficiency defined for (at least) one leg. Sorry...
577 ATH_MSG_WARNING( "SF for " << trigExpr << " are only supported for two muon events!");
578 }
579 else{ //Case 3: let's go the hard way...
580 //Following https://twiki.cern.ch/twiki/bin/view/Atlas/TrigMuonEfficiency
581 std::string newtrigExpr = TString(trigExpr).Copy().ReplaceAll("HLT_2","").Data();
582
583 //redefine dimuon triggers here (2mu14 --> mu14_mu14)
584 if (isdimuon) { newtrigExpr += "_"+newtrigExpr; }
585 newtrigExpr = std::regex_replace(newtrigExpr, std::regex("HLT_"), "");
586
587 for (auto part : std::views::split(newtrigExpr, '_')) {
588 std::string mutrig(&*part.begin(), std::ranges::distance(part));
589 double dataFactor = 1.;
590 double mcFactor = 1.;
591
592 for (const xAOD::Muon* mu : sfmuons) {
593 // No need for additional trigger matching
594 dataFactor *= (1 - GetMuonTriggerEfficiency(*mu, "HLT_"+mutrig, true));
595 mcFactor *= (1 - GetMuonTriggerEfficiency(*mu, "HLT_"+mutrig, false));
596 }
597 if( (1-mcFactor) > 0. )
598 trig_sf *= (1-dataFactor)/(1-mcFactor);
599 }
600 }
601
602 return trig_sf;
603}
double GetMuonTriggerEfficiency(const xAOD::Muon &mu, const std::string &trigExpr, const bool isdata=false) override final
Definition Muons.cxx:537

◆ GetTotalPhotonSF()

double ST::SUSYObjDef_xAOD::GetTotalPhotonSF ( const xAOD::PhotonContainer & photons,
const bool effSF = true,
const bool isoSF = true,
const bool triggerSF = false ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 323 of file Photons.cxx.

324{
325 double sf(1.);
326
327 for (const xAOD::Photon* photon : photons) {
328 if (acc_signal(*photon) && acc_passOR(*photon)) { sf *= this->GetSignalPhotonSF(*photon, effSF, isoSF, triggerSF); }
329 }
330
331 return sf;
332}
double GetSignalPhotonSF(const xAOD::Photon &ph, const bool effSF=true, const bool isoSF=true, const bool triggerSF=false) const override final
Definition Photons.cxx:209

◆ GetTotalPhotonSFsys()

double ST::SUSYObjDef_xAOD::GetTotalPhotonSFsys ( const xAOD::PhotonContainer & photons,
const CP::SystematicSet & systConfig,
const bool effSF = true,
const bool isoSF = true,
const bool triggerSF = false )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 335 of file Photons.cxx.

336{
337 double sf(1.);
338
339 for (const xAOD::Photon* photon : photons) {
340 if (acc_signal(*photon) && acc_passOR(*photon)) { sf *= this->GetSignalPhotonSFsys(*photon, systConfig, effSF, isoSF, triggerSF); }
341 }
342
343 return sf;
344}
double GetSignalPhotonSFsys(const xAOD::Photon &ph, const CP::SystematicSet &systConfig, const bool effSF=true, const bool isoSF=true, const bool triggerSF=false) override final
Definition Photons.cxx:250

◆ GetTotalTauSF()

double ST::SUSYObjDef_xAOD::GetTotalTauSF ( const xAOD::TauJetContainer & taus,
const bool idSF = true,
const bool triggerSF = true,
const std::string & trigExpr = "tau25_medium1_tracktwo" )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 236 of file Taus.cxx.

236 {
237
238 double sf(1.);
239
240 for (const xAOD::TauJet* tau : taus) {
241 // check existence of OR information
242 if (!acc_passOR.isAvailable(*tau)) {
243 ATH_MSG_WARNING("Tau does not have Overlap Removal decision set. You should only call GetTotalTauSF with taus that have been passed through OR. SF will NOT be applied!");
244 break;
245 }
246
247 // Call this for all taus, which will add the decoration
248 double tmpSF = GetSignalTauSF(*tau, idSF, triggerSF, trigExpr);
249 if (acc_signal(*tau) && acc_passOR(*tau)) {
250 sf *= tmpSF;
251 }
252 }
253
254 return sf;
255}

◆ GetTotalTauSFsys()

double ST::SUSYObjDef_xAOD::GetTotalTauSFsys ( const xAOD::TauJetContainer & taus,
const CP::SystematicSet & systConfig,
const bool idSF = true,
const bool triggerSF = true,
const std::string & trigExpr = "tau25_medium1_tracktwo" )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 258 of file Taus.cxx.

258 {
259 double sf(1.);
260
261 //Set the new systematic variation
262 StatusCode ret = m_tauEffTool->applySystematicVariation(systConfig);
263 if (ret != StatusCode::SUCCESS) { ATH_MSG_ERROR("Cannot configure TauEfficiencyCorrectionsTool for systematic var. " << systConfig.name() ); }
264
265 for (auto& tool : m_tauTrigEffTool) {
266 ret = tool->applySystematicVariation(systConfig);
267 if (ret != StatusCode::SUCCESS) { ATH_MSG_ERROR("Cannot configure " << tool->name() << " for systematic var. " << systConfig.name()); }
268 }
269
270 sf = GetTotalTauSF(taus, idSF, triggerSF, trigExpr);
271
272 //Roll back to default
273 ret = m_tauEffTool->applySystematicVariation(m_currentSyst);
274 if (ret != StatusCode::SUCCESS) { ATH_MSG_ERROR("Cannot configure TauEfficiencyCorrectionsTool back to default"); }
275
276 for (auto& tool : m_tauTrigEffTool) {
277 ret = tool->applySystematicVariation(m_currentSyst);
278 if (ret != StatusCode::SUCCESS) { ATH_MSG_ERROR("Cannot configure " << tool->name() << " back to default"); }
279 }
280
281 return sf;
282}
double GetTotalTauSF(const xAOD::TauJetContainer &taus, const bool idSF=true, const bool triggerSF=true, const std::string &trigExpr="tau25_medium1_tracktwo") override final
Definition Taus.cxx:236

◆ GetTrackJets()

StatusCode ST::SUSYObjDef_xAOD::GetTrackJets ( xAOD::JetContainer *& copy,
xAOD::ShallowAuxContainer *& copyaux,
const bool recordSG = true,
const std::string & jetkey = "",
const xAOD::JetContainer * containerToBeCopied = nullptr )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 173 of file Jets.cxx.

174 {
175 if (!m_tool_init) {
176 ATH_MSG_ERROR("SUSYTools was not initialized!!");
177 return StatusCode::FAILURE;
178 }
179
180 ATH_MSG_DEBUG("Default jetkey (trkjet): " << m_defaultTrackJets);
181 ATH_MSG_DEBUG("Function argument jetkey (trkjet): " << jetkey);
182
183 // load default regular & btag jet keys
184 std::string jetkey_tmp = m_defaultTrackJets;
185
186 // override default if user is passing a jetkey
187 if (!jetkey.empty()) {
188 jetkey_tmp = jetkey;
189 }
190
191 // final settings
192 ATH_MSG_DEBUG("Key for retrieving trkjet collection (as well as bjet info): jetkey = " << jetkey_tmp);
193
194 const xAOD::JetContainer* jets = nullptr;
195 if (copy==nullptr) { // empty container provided
196 if (containerToBeCopied != nullptr) {
197 jets = containerToBeCopied;
198 }
199 else {
200 ATH_MSG_DEBUG("Retrieve jet collection: " << jetkey_tmp);
201 ATH_CHECK( evtStore()->retrieve(jets, jetkey_tmp) );
202 }
204 copy = shallowcopy.first.get();
205 copyaux = shallowcopy.second.get();
206 bool setLinks = xAOD::setOriginalObjectLink(*jets, *copy);
207 if (!setLinks) {
208 ATH_MSG_WARNING("Failed to set original object links on " << jetkey_tmp);
209 }
210 if (recordSG) {
211 ATH_CHECK( evtStore()->record(std::move(shallowcopy.first), "STCalib" + jetkey_tmp + m_currentSyst.name()) );
212 ATH_CHECK( evtStore()->record(std::move(shallowcopy.second), "STCalib" + jetkey_tmp + m_currentSyst.name() + "Aux.") );
213 } else {
214 ATH_MSG_ERROR("Shallow copy not recorded in StoreGate!");
215 return StatusCode::FAILURE;
216 }
217 } else { // use the user-supplied collection instead
218 ATH_MSG_DEBUG("Not retrieving jet collection, using existing one provided by user");
219 jets = copy;
220 }
221
222 //disable - notfortrackjets? // Calibrate the jets
223 //disable - notfortrackjets? ATH_CHECK(m_jetCalibTool->applyCalibration(*copy));
224
225 // Update the jets
226 for (const auto jet : *copy) {
227 ATH_CHECK( this->FillTrackJet(*jet) );
228 }
229
230 if (copy->size() > 1 && m_defaultTrackJets == "AntiKtVR30Rmax4Rmin02TrackJets") {
231 // Use iterators to avoid pairing the jets twice
232 for (xAOD::JetContainer::const_iterator j1 = copy->begin()+1; j1!= copy->end();++j1) {
233 const xAOD::Jet* jet1 = (*j1);
234 if (!acc_signal(*jet1)) continue;
235 for (xAOD::JetContainer::const_iterator j2 = copy->begin(); j2 != j1; ++j2) {
236 const xAOD::Jet* jet2 = (*j2);
237 if (!acc_baseline(*jet2)) continue;
238 //Reference to the use method in P4Helper: deltaR2( const xAOD::IParticle& p4, const xAOD::IParticle& , bool useRapidity=true )
239 float dr_jets = xAOD::P4Helpers::deltaR(jet1,jet2, false);
240 const xAOD::Jet* to_check = acc_VRradius(*jet1) < acc_VRradius(*jet2) ? jet1 : jet2;
241 if( dr_jets < acc_VRradius(*to_check)) dec_passDRcut(*to_check) = false;
242 //break the loop at this point???
243 }
244 }
245 }
246
247 return StatusCode::SUCCESS;
248 }
DataModel_detail::const_iterator< DataVector > const_iterator
Definition DataVector.h:838
StatusCode FillTrackJet(xAOD::Jet &input) override final
Definition Jets.cxx:661
static const SG::ConstAccessor< float > acc_VRradius("VRradius")
double deltaR(double rapidity1, double phi1, double rapidity2, double phi2)
from bare bare rapidity,phi

◆ GetTrackMET()

StatusCode ST::SUSYObjDef_xAOD::GetTrackMET ( xAOD::MissingETContainer & met,
const xAOD::JetContainer * jet,
const xAOD::ElectronContainer * elec = nullptr,
const xAOD::MuonContainer * muon = nullptr )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 161 of file MET.cxx.

164 {
165 if (!m_tool_init) {
166 ATH_MSG_ERROR("SUSYTools was not initialized!!");
167 return StatusCode::FAILURE;
168 }
169
170 const xAOD::MissingETContainer* metcore(nullptr);
171 if ( evtStore()->retrieve( metcore, m_inputMETCore ).isFailure() ) {
172 ATH_MSG_WARNING( "Unable to retrieve MET core container: " << m_inputMETCore );
173 return StatusCode::FAILURE;
174 }
175 const xAOD::MissingETAssociationMap* metMap(nullptr);
176 if ( evtStore()->retrieve(metMap, m_inputMETMap).isFailure() ) {
177 ATH_MSG_WARNING("Unable to retrieve MissingETAssociationMap: " << m_inputMETMap);
178 return StatusCode::FAILURE;
179 }
180 // Helper keeps track of object selection flags for this map
181 xAOD::MissingETAssociationHelper metHelper(&(*metMap));
182
183 metHelper.resetObjSelectionFlags();
184
185 if (elec) {
186 ATH_MSG_VERBOSE("Build electron MET");
187 ConstDataVector<xAOD::ElectronContainer> metelectron(SG::VIEW_ELEMENTS);
188 for (const xAOD::Electron* el : *elec) {
189 // pass baseline selection
190 if (acc_baseline(*el)) metelectron.push_back(el);
191 }
192 ATH_CHECK( m_metMaker->rebuildMET(m_eleTerm, xAOD::Type::Electron, &met, metelectron.asDataVector(), metHelper) );
193 }
194
195 if (muon) {
196 ATH_MSG_VERBOSE("Build muon MET");
197 ConstDataVector<xAOD::MuonContainer> metmuon(SG::VIEW_ELEMENTS);
198 for (const xAOD::Muon* mu : *muon) {
199 // pass baseline selection
200 if (acc_baseline(*mu)) metmuon.push_back(mu);
201 }
202 ATH_CHECK( m_metMaker->rebuildMET(m_muonTerm, xAOD::Type::Muon, &met, metmuon.asDataVector(), metHelper) );
203 }
204
205 if (!jet) {
206 ATH_MSG_WARNING("Invalid jet container specified for MET rebuilding!");
207 return StatusCode::SUCCESS;
208 }
209 ATH_MSG_VERBOSE("Build jet/soft MET_Track");
210
211 std::string softTerm = "PVSoftTrk";
212 ATH_CHECK( m_metMaker->rebuildTrackMET(m_jetTerm, softTerm, &met, jet, metcore, metHelper, true) );
213
214 if (!isData()) {
215 m_metSystTool->setRandomSeed(static_cast<int>(1e6*met[softTerm]->phi()));
216
217 if (m_trkMETsyst) {
218 ATH_MSG_VERBOSE("Apply trkMET systematics");
219 if ( m_metSystTool->applyCorrection(*met[softTerm],metHelper) != CP::CorrectionCode::Ok )
220 ATH_MSG_WARNING("GetMET: Failed to apply MET track (PVSoftTrk) systematics.");
221 }
222
223 if (m_trkJetsyst) {
224 ATH_MSG_VERBOSE("Apply Ref Jet trkMET systematics");
225 if ( m_metSystTool->applyCorrection(*met[m_jetTerm],metHelper) != CP::CorrectionCode::Ok )
226 ATH_MSG_WARNING("GetMET: Failed to apply MET track (RefJet) systematics.");
227 }
228
229 }
230
231 ATH_MSG_VERBOSE("Build MET sum");
232 ATH_CHECK( met::buildMETSum("Track", &met, met[softTerm]->source()) );
233 ATH_MSG_VERBOSE( "Done rebuilding MET." );
234
235 ATH_MSG_VERBOSE( "Track MET: Missing Et (x,y): (" << met["Track"]->mpx() << "," << met["Track"]->mpy() << ")");
236
237 return StatusCode::SUCCESS;
238}

◆ GetTrigChainGroup()

const Trig::ChainGroup * ST::SUSYObjDef_xAOD::GetTrigChainGroup ( const std::string & tr_item) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 309 of file Trigger.cxx.

309 {
310 return m_trigDecTool->getChainGroup(tr_item);
311}

◆ GetTriggerFeatures()

Trig::FeatureContainer ST::SUSYObjDef_xAOD::GetTriggerFeatures ( const std::string & chainName = "EF_.*",
unsigned int condition = TrigDefs::Physics ) const

Definition at line 420 of file Trigger.cxx.

421 {
422 return m_trigDecTool->features(chainName,condition);
423 }

◆ GetTriggerGlobalEfficiency() [1/2]

double ST::SUSYObjDef_xAOD::GetTriggerGlobalEfficiency ( const xAOD::ElectronContainer & electrons,
const xAOD::MuonContainer & muons,
const std::string & trigExpr = "diLepton" )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 580 of file Trigger.cxx.

580 {
581
582 double trig_eff(1.);
583 double trig_eff_data(1.);
584
585 if (trigExpr!="multiLepton" && trigExpr!="diLepton") {
586 ATH_MSG_ERROR( "Failed to retrieve multi-lepton trigger efficiency");
587 return trig_eff;
588 }
589
590 std::vector<const xAOD::Electron*> elec_trig;
591 for (const xAOD::Electron* electron : electrons) {
592 if (!acc_passOR(*electron)) continue;
593 if (!acc_signal(*electron)) continue;
594 elec_trig.push_back(electron);
595 }
596
597 std::vector<const xAOD::Muon*> muon_trig;
598 for (const xAOD::Muon* muon : muons) {
599 if (!acc_passOR(*muon)) continue;
600 if (!acc_signal(*muon)) continue;
601 muon_trig.push_back(muon);
602 }
603
604 bool matched = false;
605 if ((elec_trig.size()+muon_trig.size())>1 && trigExpr=="diLepton") {
606 if ( m_trigGlobalEffCorrTool_diLep->checkTriggerMatching( matched, elec_trig, muon_trig) != CP::CorrectionCode::Ok ) {
607 ATH_MSG_ERROR ("trigGlobEffCorrTool::Trigger matching could not be checked, interrupting execution.");
608 }
609 } else if ((elec_trig.size()+muon_trig.size())>2 && trigExpr=="multiLepton") {
610 if ( m_trigGlobalEffCorrTool_multiLep->checkTriggerMatching( matched, elec_trig, muon_trig) != CP::CorrectionCode::Ok ) {
611 ATH_MSG_ERROR ("trigGlobEffCorrTool::Trigger matching could not be checked, interrupting execution.");
612 }
613 }
614
615 CP::CorrectionCode result;
616 if ((elec_trig.size()+muon_trig.size())>1 && trigExpr=="diLepton" && matched) {
617 result = m_trigGlobalEffCorrTool_diLep->getEfficiency( elec_trig, muon_trig, trig_eff_data, trig_eff);
618 }
619 else if ((elec_trig.size()+muon_trig.size())>2 && trigExpr=="multiLepton" && matched) {
620 result = m_trigGlobalEffCorrTool_multiLep->getEfficiency( elec_trig, muon_trig, trig_eff_data, trig_eff);
621 }
622
623 switch (result) {
625 ATH_MSG_ERROR( "Failed to retrieve multi-lepton trigger efficiency");
626 return 1.;
628 ATH_MSG_VERBOSE( "OutOfValidityRange found for multi-lepton trigger efficiency");
629 return 1.;
630 default:
631 break;
632 }
633
634 if (isData()) return trig_eff_data;
635 else return trig_eff;
636}

◆ GetTriggerGlobalEfficiency() [2/2]

double ST::SUSYObjDef_xAOD::GetTriggerGlobalEfficiency ( const xAOD::PhotonContainer & photons,
const std::string & trigExpr = "diPhoton" )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 641 of file Trigger.cxx.

641 {
642
643 double trig_eff(1.);
644 double trig_eff_data(1.);
645
646 if (trigExpr!="diPhoton") {
647 ATH_MSG_ERROR( "Failed to retrieve diphoton trigger efficiency");
648 return trig_eff;
649 }
650
651 std::vector<const xAOD::Photon*> ph_trig;
652 for (const xAOD::Photon* photon : photons) {
653 if (!acc_passOR(*photon)) continue;
654 if (!acc_signal(*photon)) continue;
655 ph_trig.push_back(photon);
656 }
657
658 CP::CorrectionCode result;
659 if (ph_trig.size()>1) {
660 result = m_trigGlobalEffCorrTool_diPhoton->getEfficiency(ph_trig, trig_eff_data, trig_eff);
661 }
662
663 switch (result) {
665 ATH_MSG_ERROR( "Failed to retrieve diphoton trigger efficiency");
666 return 1.;
668 ATH_MSG_VERBOSE( "OutOfValidityRange found for diphoton trigger efficiency");
669 return 1.;
670 default:
671 break;
672 }
673
674 if (isData()) return trig_eff_data;
675 else return trig_eff;
676}

◆ GetTriggerGlobalEfficiencySF() [1/2]

double ST::SUSYObjDef_xAOD::GetTriggerGlobalEfficiencySF ( const xAOD::ElectronContainer & electrons,
const xAOD::MuonContainer & muons,
const std::string & trigExpr = "diLepton" )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 425 of file Trigger.cxx.

425 {
426
427 double trig_sf(1.);
428
429 if (trigExpr!="multiLepton" && trigExpr!="diLepton") {
430 ATH_MSG_ERROR( "Failed to retrieve multi-lepton trigger SF");
431 return trig_sf;
432 }
433
434 std::vector<const xAOD::Electron*> elec_trig;
435 for (const xAOD::Electron* electron : electrons) {
436 if (!acc_passOR(*electron)) continue;
437 if (!acc_signal(*electron)) continue;
438 elec_trig.push_back(electron);
439 }
440
441 std::vector<const xAOD::Muon*> muon_trig;
442 for (const xAOD::Muon* muon : muons) {
443 if (!acc_passOR(*muon)) continue;
444 if (!acc_signal(*muon)) continue;
445 muon_trig.push_back(muon);
446 }
447
448 bool matched = false;
449 if ((elec_trig.size()+muon_trig.size())>1 && trigExpr=="diLepton") {
450 if ( m_trigGlobalEffCorrTool_diLep->checkTriggerMatching( matched, elec_trig, muon_trig) != CP::CorrectionCode::Ok ) {
451 ATH_MSG_ERROR ("trigGlobEffCorrTool::Trigger matching could not be checked, interrupting execution.");
452 }
453 } else if ((elec_trig.size()+muon_trig.size())>2 && trigExpr=="multiLepton") {
454 if ( m_trigGlobalEffCorrTool_multiLep->checkTriggerMatching( matched, elec_trig, muon_trig) != CP::CorrectionCode::Ok ) {
455 ATH_MSG_ERROR ("trigGlobEffCorrTool::Trigger matching could not be checked, interrupting execution.");
456 }
457 }
458
459 CP::CorrectionCode result;
460 if ((elec_trig.size()+muon_trig.size())>1 && trigExpr=="diLepton" && matched) {
461 result = m_trigGlobalEffCorrTool_diLep->getEfficiencyScaleFactor( elec_trig, muon_trig, trig_sf);
462 }
463 else if ((elec_trig.size()+muon_trig.size())>2 && trigExpr=="multiLepton" && matched) {
464 result = m_trigGlobalEffCorrTool_multiLep->getEfficiencyScaleFactor( elec_trig, muon_trig, trig_sf);
465 }
466
467 switch (result) {
469 ATH_MSG_ERROR( "Failed to retrieve multi-lepton trigger SF");
470 return 1.;
472 ATH_MSG_VERBOSE( "OutOfValidityRange found for multi-lepton trigger SF");
473 return 1.;
474 default:
475 break;
476 }
477
478 return trig_sf;
479}

◆ GetTriggerGlobalEfficiencySF() [2/2]

double ST::SUSYObjDef_xAOD::GetTriggerGlobalEfficiencySF ( const xAOD::PhotonContainer & photons,
const std::string & trigExpr = "diPhoton" )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 523 of file Trigger.cxx.

523 {
524
525 double trig_sf(1.);
526
527 if (trigExpr!="diPhoton") {
528 ATH_MSG_ERROR( "Failed to retrieve diphoton trigger SF");
529 return trig_sf;
530 }
531
532 std::vector<const xAOD::Photon*> ph_trig;
533 for (const xAOD::Photon* photon : photons) {
534 if (!acc_passOR(*photon)) continue;
535 if (!acc_signal(*photon)) continue;
536 ph_trig.push_back(photon);
537 }
538
539 CP::CorrectionCode result;
540 if (ph_trig.size()>1) {
541 result = m_trigGlobalEffCorrTool_diPhoton->getEfficiencyScaleFactor(ph_trig, trig_sf);
542 }
543
544 switch (result) {
546 ATH_MSG_ERROR( "Failed to retrieve diphoton trigger SF");
547 return 1.;
549 ATH_MSG_VERBOSE( "OutOfValidityRange found for diphoton trigger SF");
550 return 1.;
551 default:
552 break;
553 }
554
555 return trig_sf;
556}

◆ GetTriggerGlobalEfficiencySFsys() [1/2]

double ST::SUSYObjDef_xAOD::GetTriggerGlobalEfficiencySFsys ( const xAOD::ElectronContainer & electrons,
const xAOD::MuonContainer & muons,
const CP::SystematicSet & systConfig,
const std::string & trigExpr = "diLepton" )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 481 of file Trigger.cxx.

481 {
482
483 double sf(1.);
484
485 //Set the new systematic variation
486 if (trigExpr == "diLepton") {
487 StatusCode ret = m_trigGlobalEffCorrTool_diLep->applySystematicVariation(systConfig);
488 if (ret != StatusCode::SUCCESS) {
489 ATH_MSG_ERROR("Cannot configure TrigGlobalEfficiencyCorrectionTool (dilepton trigger) for systematic var. " << systConfig.name() );
490 }
491 }
492
493 if (trigExpr == "multiLepton") {
494 StatusCode ret = m_trigGlobalEffCorrTool_multiLep->applySystematicVariation(systConfig);
495 if (ret != StatusCode::SUCCESS) {
496 ATH_MSG_ERROR("Cannot configure TrigGlobalEfficiencyCorrectionTool (multi-lepton trigger) for systematic var. " << systConfig.name() );
497 }
498 }
499
500 //Get the SF for new config
501 sf = GetTriggerGlobalEfficiencySF (electrons, muons, trigExpr);
502
503 //Roll back to default
504 if (trigExpr == "diLepton") {
505 StatusCode ret = m_trigGlobalEffCorrTool_diLep->applySystematicVariation(m_currentSyst);
506 if (ret != StatusCode::SUCCESS) {
507 ATH_MSG_ERROR("Cannot configure TrigGlobalEfficiencyCorrectionTool (dilepton trigger) back to default.");
508 }
509 }
510 if (trigExpr == "multiLepton") {
511 StatusCode ret = m_trigGlobalEffCorrTool_multiLep->applySystematicVariation(m_currentSyst);
512 if (ret != StatusCode::SUCCESS) {
513 ATH_MSG_ERROR("Cannot configure TrigGlobalEfficiencyCorrectionTool (multi-lepton trigger) back to default.");
514 }
515 }
516
517 return sf;
518}
double GetTriggerGlobalEfficiencySF(const xAOD::ElectronContainer &electrons, const xAOD::MuonContainer &muons, const std::string &trigExpr="diLepton") override final
Definition Trigger.cxx:425

◆ GetTriggerGlobalEfficiencySFsys() [2/2]

double ST::SUSYObjDef_xAOD::GetTriggerGlobalEfficiencySFsys ( const xAOD::PhotonContainer & photons,
const CP::SystematicSet & systConfig,
const std::string & trigExpr = "diPhoton" )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 558 of file Trigger.cxx.

558 {
559
560 double sf(1.);
561
562 //Set the new systematic variation
563 StatusCode ret = m_trigGlobalEffCorrTool_diPhoton->applySystematicVariation(systConfig);
564 if (ret != StatusCode::SUCCESS) {
565 ATH_MSG_ERROR("Cannot configure TrigGlobalEfficiencyCorrectionTool (diphoton trigger) for systematic var. " << systConfig.name() );
566 }
567
568 //Get the SF for new config
569 sf = GetTriggerGlobalEfficiencySF (photons, trigExpr);
570
571 //Roll back to default
572 ret = m_trigGlobalEffCorrTool_diPhoton->applySystematicVariation(m_currentSyst);
573 if (ret != StatusCode::SUCCESS) {
574 ATH_MSG_ERROR("Cannot configure TrigGlobalEfficiencyCorrectionTool (diphoton trigger) back to default.");
575 }
576
577 return sf;
578}

◆ GetTriggerOR()

std::vector< std::string > ST::SUSYObjDef_xAOD::GetTriggerOR ( const std::string & trigExpr) const

Definition at line 314 of file Trigger.cxx.

314 {
315
316 static const std::string delOR = "_OR_";
317 std::vector<std::string> trigchains = {};
318 std::string newtrigExpr = TString(trigExpr).Copy().ReplaceAll("||",delOR).Data();
319 newtrigExpr = TString(trigExpr).Copy().ReplaceAll(" ","").Data();
320
321 size_t pos = 0;
322 while ((pos = newtrigExpr.find(delOR)) != std::string::npos) {
323 trigchains.push_back( "HLT_"+newtrigExpr.substr(0, pos) );
324 newtrigExpr.erase(0, pos + delOR.length());
325 }
326 if(pos==std::string::npos)
327 trigchains.push_back("HLT_"+newtrigExpr);
328
329 return trigchains;
330 }

◆ GetTriggerTokens()

void ST::SUSYObjDef_xAOD::GetTriggerTokens ( std::string trigExpr,
std::vector< std::string > & v_trigs15_cache,
std::vector< std::string > & v_trigs16_cache,
std::vector< std::string > & v_trigs17_cache,
std::vector< std::string > & v_trigs18_cache,
std::vector< std::string > & v_trigs22_cache,
std::vector< std::string > & v_trigs23_cache,
std::vector< std::string > & v_trigs24_cache ) const

Definition at line 332 of file Trigger.cxx.

332 {
333
334 // e.g. SINGLE_E_2015_e24_lhmedium_L1EM20VH_OR_e60_lhmedium_OR_e120_lhloose_2016_2018_e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0
335
336 static const std::string del15 = "_2015_";
337 static const std::string del16 = "_2016_";
338 static const std::string del17 = "_2017_";
339
340 size_t pos = 0;
341 std::string token15, token16, token17, token18, token22, token23, token24;
342
343 //get trigger tokens for 2015, 2016, 2017, 2018 and 2022, 2023, 2024
344 if ( (pos = trigExpr.find(del15)) != std::string::npos) {
345 trigExpr.erase(0, pos + del15.length());
346
347 pos = 0;
348 while ((pos = trigExpr.find(del16)) != std::string::npos) {
349 token15 = trigExpr.substr(0, pos);
350 token16 = trigExpr.erase(0, pos + del16.length() + del17.length() - 1);
351 // 2016-2018 use exact the same trigger string
352 token17 = token16;
353 token18 = token16;
354 }
355 }
356
357 // Find year positions (or npos if not present)
358 size_t p22 = trigExpr.find("2022");
359 size_t p23 = trigExpr.find("2023");
360 size_t p24 = trigExpr.find("2024");
361
362 auto next_pos = [&](size_t self) {
363 size_t next = std::string::npos;
364
365 if (self == p22) {
366 if (p23 > self && p23 < next) next = p23;
367 if (p24 > self && p24 < next) next = p24;
368 }
369 else if (self == p23) {
370 if (p22 > self && p22 < next) next = p22;
371 if (p24 > self && p24 < next) next = p24;
372 }
373 else if (self == p24) {
374 if (p22 > self && p22 < next) next = p22;
375 if (p23 > self && p23 < next) next = p23;
376 }
377
378 return next;
379 };
380
381 // Extract 2022,2023,2024 block
382 if (p22 != std::string::npos) {size_t end = next_pos(p22); token22 = trigExpr.substr(p22, end - p22);}
383 if (p23 != std::string::npos) {size_t end = next_pos(p23); token23 = trigExpr.substr(p23, end - p23);}
384 if (p24 != std::string::npos) {size_t end = next_pos(p24); token24 = trigExpr.substr(p24, end - p24);}
385
386 // Remove trailing underscores from tokens if present
387 std::string* toks[] = { &token22, &token23, &token24 };
388 for (auto t : toks) {
389 while (!t->empty() && t->back() == '_') t->pop_back();
390 }
391
392 //Redefine in case of custom user input
393 if(!m_isRun3){
394 if(token15.empty()) token15 = trigExpr;
395 if(token16.empty()) token16 = trigExpr;
396 if(token17.empty()) token17 = trigExpr;
397 if(token18.empty()) token18 = trigExpr;
398 }
399 else{
400 if(token22.empty()) token22 = trigExpr;
401 if(token23.empty()) token23 = trigExpr;
402 if(token24.empty()) token24 = trigExpr;
403 }
404
405 //get trigger chains for matching in 2015 and 2018
406 if(!m_isRun3){
407 v_trigs15_cache = GetTriggerOR(token15);
408 v_trigs16_cache = GetTriggerOR(token16);
409 v_trigs17_cache = GetTriggerOR(token17);
410 v_trigs18_cache = GetTriggerOR(token18);
411 }
412 //get trigger chains for matching in 2022
413 else{
414 v_trigs22_cache = GetTriggerOR(token22);
415 v_trigs23_cache = GetTriggerOR(token23);
416 v_trigs24_cache = GetTriggerOR(token24);
417 }
418 }
std::vector< std::string > GetTriggerOR(const std::string &trigExpr) const
Definition Trigger.cxx:314

◆ GetTrigPrescale()

float ST::SUSYObjDef_xAOD::GetTrigPrescale ( const std::string & tr_item) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 304 of file Trigger.cxx.

304 {
305 return m_trigDecTool->getPrescale(tr_item);
306}

◆ handle()

void asg::AsgMetadataTool::handle ( const Incident & inc)
protectedvirtualinherited

Function receiving incidents from IncidentSvc/Event.

Reimplemented in Trig::TrigDecisionTool.

Definition at line 135 of file AsgMetadataTool.cxx.

135 {
136
137 // Tell the user what's happening:
138 ATH_MSG_VERBOSE( "Callback received with incident: " << inc.type() );
139
140 // Call the appropriate member function:
141 if( inc.type() == IncidentType::BeginInputFile ) {
143 if( beginInputFile().isFailure() ) {
144 ATH_MSG_FATAL( "Failed to call beginInputFile()" );
145 throw std::runtime_error( "Couldn't call beginInputFile()" );
146 }
147 } else if( inc.type() == IncidentType::EndInputFile ) {
148 if( endInputFile().isFailure() ) {
149 ATH_MSG_FATAL( "Failed to call endInputFile()" );
150 throw std::runtime_error( "Couldn't call endInputFile()" );
151 }
152 } else if( inc.type() == IncidentType::BeginEvent ) {
153 // If the tool didn't catch the begin input file incident for the
154 // first input file of the job, then call the appropriate function
155 // now.
156 if( ! m_beginInputFileCalled ) {
158 if( beginInputFile().isFailure() ) {
159 ATH_MSG_FATAL( "Failed to call beginInputFile()" );
160 throw std::runtime_error( "Couldn't call beginInputFile()" );
161 }
162 }
163 if( beginEvent().isFailure() ) {
164 ATH_MSG_FATAL( "Failed to call beginEvent()" );
165 throw std::runtime_error( "Couldn't call beginEvent()" );
166 }
167
168 #ifdef XAOD_STANDALONE
169 } else if( inc.type() == IncidentType::MetaDataStop ) {
170 if( metaDataStop().isFailure() ) {
171 ATH_MSG_FATAL( "Failed to call metaDataStop()" );
172 throw std::runtime_error( "Couldn't call metaDataStop()" );
173 }
174
175 #endif // XAOD_STANDALONE
176 } else {
177 ATH_MSG_WARNING( "Unknown incident type received in AsgMetaDataTool: " << inc.type() );
178 }
179
180 return;
181 }
virtual StatusCode beginInputFile()
Function called when a new input file is opened.
virtual StatusCode beginEvent()
Function called when a new events is loaded.
bool m_beginInputFileCalled
Flag helping to discover when the tool misses the opening of the first input file.
virtual StatusCode endInputFile()
Function called when the currently open input file got completely processed.
virtual StatusCode metaDataStop()
Function called when the tool should write out its metadata.

◆ initialize()

StatusCode ST::SUSYObjDef_xAOD::initialize ( void )
finaloverridevirtual

Dummy implementation of the initialisation function.

It's here to allow the dual-use tools to skip defining an initialisation function. Since many are doing so...

Reimplemented from asg::AsgTool.

Definition at line 900 of file SUSYObjDef_xAOD.cxx.

900 {
901
902 if (m_tool_init) {
903 ATH_MSG_ERROR("Initialising for a second time -- something is wrong!");
904 return StatusCode::FAILURE;
905 }
906
907 // Greet the user:
908 ATH_MSG_INFO( "Initialising... " );
909
910 bool autoconf(false);
911#ifndef XAOD_STANDALONE // For now metadata is Athena-only
912 if ( m_dataSource < 0 ) {
913 autoconf = true;
914 ATH_MSG_INFO("Autoconfiguring: dataSource, mcCampaign, isPHYSLITE");
915 std::string projectName = "";
916 ATH_CHECK( AthAnalysisHelper::retrieveMetadata("/TagInfo", "project_name", projectName, inputMetaStore() ) );
917 if ( projectName == "IS_SIMULATION" ) {
918 std::string simFlavour = "";
919 ATH_CHECK( AthAnalysisHelper::retrieveMetadata("/Simulation/Parameters", "SimulationFlavour", simFlavour, inputMetaStore() ) );
920 TString s(simFlavour); s.ToUpper();
921 m_dataSource = s.Contains("ATLFAST") ? AtlfastII : FullSim;
922 } else if (projectName.compare(0, 4, "data") == 0 ) {
924 } else {
925 ATH_MSG_ERROR("Failed to autoconfigure -- project_name matches neither IS_SIMULATION nor data!");
926 return StatusCode::FAILURE;
927 }
928
929 }
930#endif
931
933
934 //Read configuration from file (stored as Property)
936
937 if (m_dataSource < 0) {
938 ATH_MSG_FATAL( "Data source incorrectly configured!!" );
939 ATH_MSG_FATAL("You must set the DataSource property to Data, FullSim or AtlfastII !!");
940 if (autoconf) ATH_MSG_FATAL("Autoconfiguration seems to have failed!");
941 // if(m_useLeptonTrigger<0) ATH_MSG_ERROR( "UseLeptonTrigger not set");
942 ATH_MSG_FATAL( "Exiting... " );
943 return StatusCode::FAILURE;
944 }
945 ATH_MSG_DEBUG( "Configured: IsData: " << isData() );
946 ATH_MSG_DEBUG( "Configured: IsAtlfast: " << isAtlfast() );
947
948 switch (m_jetInputType) {
952 break;
953 default:
955 return StatusCode::FAILURE;
956 }
957
958 if (m_inputMETSuffix.empty()){
960 }
962 ATH_MSG_INFO( "Configured for jet collection: " << m_defaultJets );
963
964 m_defaultTruthJets = "AntiKt4TruthJets";
965 const xAOD::FileMetaData* fmd = nullptr;
966 std::string dataType;
967 if ( inputMetaStore()->contains<xAOD::FileMetaData>("FileMetaData") && inputMetaStore()->retrieve(fmd,"FileMetaData").isSuccess() )
968 fmd->value(xAOD::FileMetaData::dataType, dataType);
969 if ( dataType.compare("StreamDAOD_PHYS")==0 || dataType.compare("StreamDAOD_PHYSLITE")==0 ) m_defaultTruthJets = "AntiKt4TruthDressedWZJets";
970 if ( dataType.compare("StreamDAOD_PHYSLITE")==0) m_isPHYSLITE = true;
971
972 ATH_MSG_INFO( "Configured for truth jet collection: " << m_defaultTruthJets );
973
974 m_inputMETCore = m_isPHYSLITE? "MET_Core_AnalysisMET":"MET_Core_" + m_inputMETSuffix;
975 m_inputMETMap = m_isPHYSLITE? "METAssoc_AnalysisMET":"METAssoc_" + m_inputMETSuffix;
976
977 ATH_MSG_DEBUG ( "Build MET Core: " << m_inputMETCore);
978 ATH_MSG_DEBUG ( "Build MET with map: " << m_inputMETMap);
979
980 m_jetCleanDFName = TString::Format("DFCommonJets_jetClean_%s", m_badJetCut.c_str());
982
983 // the decorations are named like DFCommonElectronsLHTight, DFCommonElectronsDNNTight or DFCommonElectronsDNNTightNoCF
984 m_eleIdBaselineDFName = m_eleIdBaseline.find("DNN") == std::string::npos ? "DFCommonElectronsLH" : "DFCommonElectronsDNN";
985 m_eleIdBaselineDFName += TString(m_eleIdBaseline).ReplaceAll("LooseAndBLayer","LooseBL").ReplaceAll("LLH","").ReplaceAll("DNNnoCF","").ReplaceAll("DNN","").Data();
986 if (m_eleIdBaseline.find("noCF") != std::string::npos)
987 m_eleIdBaselineDFName += "NoCF";
989
990 m_eleIdDFName = m_eleId.find("DNN") == std::string::npos ? "DFCommonElectronsLH" : "DFCommonElectronsDNN";
991 m_eleIdDFName += TString(m_eleId).ReplaceAll("LooseAndBLayer","LooseBL").ReplaceAll("LLH","").ReplaceAll("DNNnoCF","").ReplaceAll("DNN","").Data();
992 if (m_eleId.find("noCF") != std::string::npos)
993 m_eleIdDFName += "NoCF";
995
996 m_photonIdBaselineDFName = "DFCommonPhotonsIsEM";
999
1000 m_photonIdDFName = "DFCommonPhotonsIsEM";
1001 m_photonIdDFName += TString(m_photonId).Data();
1003
1004 // autoconfigure PRW tool if m_autoconfigPRW==true
1005 if (m_autoconfigPRWPath == "dev/PileupReweighting/share/")
1007 else
1008 // need to set a full path if you don't use the one in CVMFS
1010
1011 // Read Handles
1012 ATH_CHECK( m_LRTCollectionName.initialize() );
1013 ATH_CHECK( m_GSFLRTCollectionName.initialize() );
1014
1015 // Write Handles
1016 ATH_CHECK( m_outElectronLocation.initialize() );
1017 ATH_CHECK( m_outMuonLocation.initialize() );
1018
1019 ATH_CHECK( this->SUSYToolsInit() );
1020
1021 ATH_MSG_VERBOSE("Done with tool retrieval");
1022
1023 m_tool_init = true;
1024
1025 // Return gracefully:
1026 return StatusCode::SUCCESS;
1027}
static std::string retrieveMetadata(const std::string &folder, const std::string &key, const ServiceHandle< StoreGateSvc > &inputMetaStore)
method that always returns as a string you can use from, e.g, pyROOT with evt = ROOT....
std::string m_defaultTruthJets
std::string m_photonIdBaselineDFName
StatusCode readConfig() override final
StatusCode SUSYToolsInit()
std::string m_eleIdBaselineDFName
StatusCode autoconfigurePileupRWTool(const std::string &PRWfilesDir="dev/PileupReweighting/share/", const std::string &PRWfileName="", bool usePathResolver=true, bool RPVLLmode=false, bool Combinedmode=false, const std::string &HFFilter="")
@ dataType
Data type that's in the file [string].
const std::string & typeName(Type id)

◆ inputHandles()

virtual std::vector< Gaudi::DataHandle * > AthCommonDataStore< AthCommonMsg< AlgTool > >::inputHandles ( ) const
overridevirtualinherited

Return this algorithm's input handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ inputMetaStore()

AsgMetadataTool::MetaStorePtr_t asg::AsgMetadataTool::inputMetaStore ( ) const
inherited

Accessor for the input metadata store.

Definition at line 93 of file AsgMetadataTool.cxx.

93 {
94
95#ifdef XAOD_STANDALONE
96 return &m_inputMetaStore;
97#else // XAOD_STANDALONE
98 return m_inputMetaStore;
99#endif // XAOD_STANDALONE
100 }
MetaStore_t m_inputMetaStore
Object accessing the input metadata store.

◆ isAtlfast()

bool ST::SUSYObjDef_xAOD::isAtlfast ( ) const
inlinefinaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 158 of file SUSYObjDef_xAOD.h.

158{return m_dataSource == AtlfastII;}

◆ IsBadJet()

bool ST::SUSYObjDef_xAOD::IsBadJet ( const xAOD::Jet & input) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 763 of file Jets.cxx.

763 {
764
765 if ( !acc_passOR(input) ) return false;
766
767 float ptcut = 20e3;
768 if ( m_jetPt < ptcut ) ptcut = m_jetPt;
769
770 bool isPileup = !acc_passJvt(input);
771
772 if ( input.pt() <= ptcut || isPileup ) return false;
773
774 if (m_acc_jetClean.isAvailable(input)) {
775 dec_bad(input) = !m_acc_jetClean(input);
776 } else {
777 ATH_MSG_VERBOSE("DFCommon jet cleaning variable not available ... setting 'bad' decorator to 0.");
778 dec_bad(input) = 0;
779 // the jet cleaning decisions are only calculable at AOD now
780 // dec_bad(input) = m_jetCleaningTool.empty() ? false : !m_jetCleaningTool->keep(input);
781 }
782
783 ATH_MSG_VERBOSE( "JET isbad?: " << static_cast<int>(acc_bad(input)));
784
785 return acc_bad(input);
786 }
bool isPileup(int origin)
from pileup
static const SG::ConstAccessor< char > acc_bad("bad")

◆ IsBadMuon()

bool ST::SUSYObjDef_xAOD::IsBadMuon ( const xAOD::Muon & input,
const float qopcut ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 409 of file Muons.cxx.

410{
411 const static SG::Decorator<char> dec_bad("bad");
412 dec_bad(input) = false;
413
414 const static SG::Decorator<char> dec_bad_highPt("bad_highPt");
415 dec_bad_highPt(input) = false;
416
418 if (input.muonType() == xAOD::Muon::SiliconAssociatedForwardMuon) {
419 track = input.trackParticle(xAOD::Muon::CombinedTrackParticle);
420 if (!track) return false; // don't treat SAF muons without CB track further
421 }
422 else{
423 track = input.primaryTrackParticle();
424 if (!track){
425 ATH_MSG_WARNING("Non-SAF muon without a track; cannot test IsBadMuon criteria");
426 return false;
427 }
428 }
429
430 float Rerr = Amg::error(track->definingParametersCovMatrix(), 4) / std::abs(track->qOverP());
431 ATH_MSG_VERBOSE( "Track momentum error (%): " << Rerr * 100 );
432 bool isbad = Rerr > qopcut;
433 bool isbadHighPt = Rerr > qopcut;
434
435 //new recommendation from MCP
436 isbad |= m_muonSelectionTool->isBadMuon(input);
437
438 //new recommendation from MCP (at HighPT)
439 isbadHighPt |= m_muonSelectionHighPtTool->isBadMuon(input);
440
441 dec_bad(input) = isbad;
442 dec_bad_highPt(input) = isbadHighPt;
443
444 ATH_MSG_VERBOSE( "MUON isbad?: " << isbad );
445 return isbad;
446}
double error(const Amg::MatrixX &mat, int index)
return diagonal error of the matrix caller should ensure the matrix is symmetric and the index is in ...
SG::Decorator< T, ALLOC > Decorator
Helper class to provide type-safe access to aux data, specialized for JaggedVecElt.
Definition AuxElement.h:576

◆ IsBJet()

bool ST::SUSYObjDef_xAOD::IsBJet ( const xAOD::Jet & input) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 789 of file Jets.cxx.

789 {
790
791 bool isbjet = bool(m_btagSelTool->accept(input));
792 dec_bjet(input) = isbjet;
793
794 if (SetBtagWeightDecorations(input, m_btagSelTool, m_BtagTagger).isFailure())
795 ANA_MSG_ERROR("Couldn't set b-tag decorations for jet, is-b = " << (isbjet?"true":"false") << ", pT = " << input.pt()/1000.);
796
797 return isbjet;
798 }
#define ANA_MSG_ERROR(xmsg)
Macro printing error messages.
StatusCode SetBtagWeightDecorations(const xAOD::Jet &input, const asg::AnaToolHandle< IBTaggingSelectionTool > &btagSelTool, const std::string &btagTagger) const override final
Definition Jets.cxx:1173
static const SG::Decorator< char > dec_bjet("bjet")

◆ IsBJetContinuous()

int ST::SUSYObjDef_xAOD::IsBJetContinuous ( const xAOD::Jet & input) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 811 of file Jets.cxx.

811 {
813 // Cheatsheet:
814 // returns 6 if between 65% and 0%
815 // returns 5 if between 70% and 65%
816 // returns 4 if between 77% and 70%
817 // returns 3 if between 85% and 77%
818 // returns 2 if between 90% and 85%
819 // returns 1 if between 100% and 90%
820 // returns 0 if smaller than -1e4-> should never happen
821 // return -1 if bigger than 1e4 or not in b-tagging acceptance
823
824 int isbjet = m_btagSelTool->getQuantile(input);
825 dec_bjet(input) = isbjet;
826
828 ANA_MSG_ERROR("Couldn't set continuous b-tag decorations for jet, is-b = " << isbjet << ", pT = " << input.pt()/1000.);
829
830 return isbjet;
831 }

◆ IsBJetLoose()

bool ST::SUSYObjDef_xAOD::IsBJetLoose ( const xAOD::Jet & input) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 698 of file Jets.cxx.

698 {
699 bool isbjet_loose = false;
701 isbjet_loose = bool(m_btagSelTool_OR->accept(input)); //note : b-tag applies only to jet with eta < 2.5
702 return isbjet_loose;
703 }

◆ IsCosmicMuon()

bool ST::SUSYObjDef_xAOD::IsCosmicMuon ( const xAOD::Muon & input,
const float z0cut,
const float d0cut ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 448 of file Muons.cxx.

449{
450 dec_cosmic(input) = false;
451
452 const xAOD::TrackParticle* track(nullptr);
453 if (input.muonType() == xAOD::Muon::SiliconAssociatedForwardMuon) {
454 track = input.trackParticle(xAOD::Muon::CombinedTrackParticle);
455 if (!track){
456 ATH_MSG_VERBOSE("WARNING: SAF muon without CB track found. Not possible to check cosmic muon criteria");
457 return false; // don't treat SAF muons without CB track further
458 }
459 }
460 else {
461 track = input.primaryTrackParticle();
462 if (!track){
463 ATH_MSG_WARNING("Non-SAF muon without primary track particle found. Not possible to check cosmic muon criteria");
464 return false;
465 }
466 }
467
468 double mu_d0 = track->d0();
469 const xAOD::Vertex* pv = this->GetPrimVtx();
470 double primvertex_z = pv ? pv->z() : 0;
471 double mu_z0_exPV = track->z0() + track->vz() - primvertex_z;
472
473 bool isCosmicMuon = (std::abs(mu_z0_exPV) >= z0cut || std::abs(mu_d0) >= d0cut);
474
475 if (isCosmicMuon) {
476 ATH_MSG_VERBOSE("COSMIC PV Z = " << primvertex_z << ", track z0 = " << mu_z0_exPV << ", track d0 = " << mu_d0);
477 }
478
479 dec_cosmic(input) = isCosmicMuon;
480 return isCosmicMuon;
481}
static const SG::Decorator< char > dec_cosmic("cosmic")

◆ isData()

bool ST::SUSYObjDef_xAOD::isData ( ) const
inlinefinaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 157 of file SUSYObjDef_xAOD.h.

157{return m_dataSource == Data;}

◆ IsHighPtMuon()

bool ST::SUSYObjDef_xAOD::IsHighPtMuon ( const xAOD::Muon & input) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 390 of file Muons.cxx.

394{
395 if (input.pt() < 3e3){
396 ATH_MSG_DEBUG("No HighPt check supported for muons below 3GeV! False.");
397 dec_passedHighPtCuts(input) = false;
398 return false;
399 }
400
401 bool isHighPt=false;
402 isHighPt = bool(m_muonSelectionHighPtTool->accept(input));
403 dec_passedHighPtCuts(input) = isHighPt;
404
405 return isHighPt;
406}

◆ IsMETTrigPassed() [1/2]

bool ST::SUSYObjDef_xAOD::IsMETTrigPassed ( const std::string & triggerName,
bool j400_OR = false,
const std::string & L1_name = "L1_XE50" ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 57 of file Trigger.cxx.

57 {
58 // NB - this now applies to the entire function...
59
60 // First check if we're affected by the L1_XE50 bug
61 bool L1_pass = m_trigDecTool->isPassed(L1_name);
62 bool HLT_noalg_L1J400 = m_trigDecTool->isPassed("HLT_noalg_L1J400");
63 if (!L1_pass && j400_OR && HLT_noalg_L1J400) {
64 return emulateHLT(triggerName);
65 }
66 else if (L1_pass) {
67 // See if the TDT knows about this
68 {
69 std::scoped_lock lock (m_triggerCacheMutex);
70 if (isTrigInTDT(lock, triggerName) ) return m_trigDecTool->isPassed(triggerName);
71 }
72 return emulateHLT(triggerName);
73 }
74 return false;
75}
bool emulateHLT(const std::string &triggerName) const
Definition Trigger.cxx:91

◆ IsMETTrigPassed() [2/2]

bool ST::SUSYObjDef_xAOD::IsMETTrigPassed ( unsigned int runnumber = 0,
bool j400_OR = false ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 30 of file Trigger.cxx.

30 {
31
32 // Returns MET trigger decision for recommended lowest unprescaled evolution described in
33 // https://twiki.cern.ch/twiki/bin/viewauth/Atlas/LowestUnprescaled
34 // For period vs run number, see https://atlas-tagservices.cern.ch/tagservices/RunBrowser/runBrowserReport/rBR_Period_Report.php
35
36 // if no runNumber specified, just read it from the current event
37 unsigned int rn = (runnumber>0)? runnumber : GetRunNumber();
38
39 int year = treatAsYear(rn);
40
41 if (year == 2015) return IsMETTrigPassed("HLT_xe70_mht",j400_OR); //2015
42 else if(year == 2016 && rn >= 296939 && rn <= 302872 ) return IsMETTrigPassed("HLT_xe90_mht_L1XE50",j400_OR); //2016 A-D3
43 else if(year == 2016 && rn >= 302919 && rn <= 303892 ) return IsMETTrigPassed("HLT_xe100_mht_L1XE50",j400_OR); //2016 D4-F1
44 else if(year == 2016 && rn >= 303943) return IsMETTrigPassed("HLT_xe110_mht_L1XE50",j400_OR); //2016 F2-(open)
45 // don't use complicated logic from IsMETTrigPassed if not needed
46 else if(year == 2017 && rn >= 325713 && rn <= 331975 ) return IsTrigPassed("HLT_xe110_pufit_L1XE55"); // 2017 B1-D5
47 else if(year == 2017 && rn >= 332303 ) return IsTrigPassed("HLT_xe110_pufit_L1XE50"); // 2017 D6-(open)
48 else if(year == 2018 && rn >= 348885 && rn <= 350013 ) return IsTrigPassed("HLT_xe110_pufit_xe70_L1XE50"); // 2018 B-C5
49 else if(year == 2018 && rn >= 350067 ) return IsTrigPassed("HLT_xe110_pufit_xe65_L1XE50"); // 2018 C5-(open)
50 else if(year == 2022 || year == 2023) return IsTrigPassed("HLT_xe65_cell_xe90_pfopufit_L1XE50");
51 else if(year == 2024 || year == 2025 || year == 2026) return IsTrigPassed("HLT_xe65_cell_xe105_nn_L1jXE100");
52
53 return false;
54}
bool IsMETTrigPassed(unsigned int runnumber=0, bool j400_OR=false) const override final
Definition Trigger.cxx:30
unsigned int GetRunNumber() const override final
bool IsTrigPassed(const std::string &, unsigned int condition=TrigDefs::Physics) const override final
Definition Trigger.cxx:207
static std::vector< uint32_t > runnumber
Definition iLumiCalc.h:37

◆ isNominal()

bool ST::SUSYObjDef_xAOD::isNominal ( const CP::SystematicSet & syst) const

Definition at line 2163 of file SUSYObjDef_xAOD.cxx.

2163 {
2164 return syst.name().empty();
2165}

◆ isPrompt()

bool ST::SUSYObjDef_xAOD::isPrompt ( const xAOD::IParticle * part) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 24 of file Truth.cxx.

24 {
25
26 const int type = acc_truthType(*part);
27 int origin = acc_truthOrigin(*part);
28 int originbkg = 0;
29 if(acc_bkgTruthOrigin.isAvailable(*part)){ //only in SUSY2,3,5 for the moment!
30 originbkg = acc_bkgTruthOrigin(*part);
31 }
32 else{
33 ATH_MSG_DEBUG("::isPrompt() : No bkgTruthOrigin decoration available. Returning false by default.");
34 return false;
35 }
36
37 //Electrons
38 if( part->type() == xAOD::Type::Electron ){
39 switch(type){
41 if(origin != MCTruthPartClassifier::PhotonConv) return false;
42 if(originbkg == MCTruthPartClassifier::FSRPhot || originbkg == MCTruthPartClassifier::BremPhot) return true;
43 origin = originbkg;
44 /* FALLTHRU */
46 return (origin == MCTruthPartClassifier::top
56 || origin == MCTruthPartClassifier::LQ
57 || origin == MCTruthPartClassifier::SUSY);
58 default:
59 return false;
60 }
61 // NB: will classify a few muon/quark brems as prompt electrons, but a small effect
62 }
63 if( part->type() == xAOD::Type::Muon ){
64 return (type == MCTruthPartClassifier::IsoMuon);
65 }
66 else{
67 ATH_MSG_DEBUG("::isPrompt() : Only Electrons supported at the moment!");
68 }
69
70 //Photons ... ?
71 //Taus ... ?
72 return false;
73}
static const SG::ConstAccessor< int > acc_truthType("truthType")
static const SG::ConstAccessor< int > acc_truthOrigin("truthOrigin")
static const SG::ConstAccessor< int > acc_bkgTruthOrigin("bkgTruthOrigin")

◆ IsSignalElectron()

bool ST::SUSYObjDef_xAOD::IsSignalElectron ( const xAOD::Electron & input,
const float etcut,
const float d0sigcut,
const float z0cut,
const float etacut = DUMMYDEF ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 365 of file Electrons.cxx.

366{
367 if (!acc_baseline(input)) return false;
368
369 dec_passSignalID(input) = false;
370
371 if (m_eleIdExpert) {
372 if ( !m_elecSelLikelihood.empty() && m_elecSelLikelihood->accept(&input) ) dec_passSignalID(input) = true;
373 }
374 else {
375 if (m_acc_eleId.isAvailable(input)) {
376 dec_passSignalID(input) = m_acc_eleId(input);
377 } else {
378 ATH_MSG_VERBOSE ("DFCommonElectronsLHxxx variables are not found. Calculating the ID from LH tool..");
379 if ( !m_elecSelLikelihood.empty() && m_elecSelLikelihood->accept(&input) ) dec_passSignalID(input) = true;
380 }
381 }
382
383 //overwrite ID selection if forced by user
384 if(m_force_noElId) dec_passSignalID(input) = true;
385
386 if (!acc_passSignalID(input)) return false;
387
388 if (input.p4().Perp2() <= etcut * etcut || input.p4().Perp2() == 0) return false; // eT cut (might be necessary for leading electron to pass trigger)
389 if ( etacut==DUMMYDEF ){
390 if(std::abs(input.caloCluster()->etaBE(2)) > m_eleEta ) return false;
391 }
392 else if ( std::abs(input.caloCluster()->etaBE(2)) > etacut ) return false;
393
394 if (m_eleCrackVeto){
395 if ( std::abs( input.caloCluster()->etaBE(2) ) >1.37 && std::abs( input.caloCluster()->etaBE(2) ) <1.52) {
396 return false;
397 }
398 }
399
400 if (acc_d0sig(input) != 0) {
401 if (d0sigcut > 0.0 && std::abs(acc_d0sig(input)) > d0sigcut) return false; // transverse IP cut
402 }
403
404 if (z0cut > 0.0 && std::abs(acc_z0sinTheta(input)) > z0cut) return false; // longitudinal IP cut
405
406
407 ATH_MSG_VERBOSE( "IsSignalElectron: " << m_eleId << " " << acc_passSignalID(input) << " d0sig " << acc_d0sig(input) << " z0 sin(theta) " << acc_z0sinTheta(input) );
408
409 if (m_doElIsoSignal) {
410 if ( !( (acc_isol(input) && input.pt()<m_eleIsoHighPtThresh) || (acc_isolHighPt(input) && input.pt()>m_eleIsoHighPtThresh)) ) return false;
411 ATH_MSG_VERBOSE( "IsSignalElectron: passed isolation" );
412 }
413
414 if(m_eleChID_signal && !acc_passChID(input)) return false; //add charge flip check to signal definition
415
416 dec_signal(input) = true;
417
418 ATH_MSG_VERBOSE( "IsSignalElectron: passed selection" );
419 return true;
420}
static const SG::ConstAccessor< char > acc_passSignalID("passSignalID")
static const double DUMMYDEF
static const SG::ConstAccessor< char > acc_passChID("passChID")

◆ IsSignalJet()

bool ST::SUSYObjDef_xAOD::IsSignalJet ( const xAOD::Jet & input,
const float ptcut,
const float etacut ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 711 of file Jets.cxx.

711 {
712 if ( !acc_baseline(input) || !acc_passOR(input) ) return false;
713
714 if ( input.pt() <= ptcut || std::abs(input.eta()) >= etacut) return false;
715
716 bool isgoodjet = !acc_bad(input) && acc_passJvt(input);
717
718 dec_signal(input) = isgoodjet;
719
720 // For JVT calculation
721 dec_signal_less_JVT(input) = !acc_bad(input);
722
723
724 if (m_debug) {
725 float emfrac, hecf, LArQuality, HECQuality, Timing, fracSamplingMax, NegativeE, AverageLArQF;
726 std::vector<float> sumpttrk_vec;
727
728 input.getAttribute(xAOD::JetAttribute::EMFrac, emfrac);
729 input.getAttribute(xAOD::JetAttribute::HECFrac, hecf);
730 input.getAttribute(xAOD::JetAttribute::LArQuality, LArQuality);
731 input.getAttribute(xAOD::JetAttribute::HECQuality, HECQuality);
732 input.getAttribute(xAOD::JetAttribute::Timing, Timing);
733 input.getAttribute(xAOD::JetAttribute::SumPtTrkPt500, sumpttrk_vec);
734 input.getAttribute(xAOD::JetAttribute::FracSamplingMax, fracSamplingMax);
735 input.getAttribute(xAOD::JetAttribute::NegativeE, NegativeE);
736 input.getAttribute(xAOD::JetAttribute::AverageLArQF, AverageLArQF);
737
738 float sumpttrk;
739 if (!sumpttrk_vec.empty() && this->GetPrimVtx()) {
740 sumpttrk = sumpttrk_vec[this->GetPrimVtx()->index()];
741 } else {
742 sumpttrk = 0.;
743 }
744
745 ATH_MSG_INFO( "JET pt: " << input.pt() );
746 ATH_MSG_INFO( "JET eta: " << input.eta() );
747 ATH_MSG_INFO( "JET emfrac: " << emfrac );
748 ATH_MSG_INFO( "JET hecfrac: " << hecf );
749 ATH_MSG_INFO( "JET LArQuality: " << LArQuality );
750 ATH_MSG_INFO( "JET HECQuality: " << HECQuality );
751 ATH_MSG_INFO( "JET Timing: " << Timing );
752 ATH_MSG_INFO( "JET sumpttrk: " << sumpttrk );
753 ATH_MSG_INFO( "JET fracSamplingMax: " << fracSamplingMax );
754 ATH_MSG_INFO( "JET AverageLArQF: " << AverageLArQF );
755 }
756
757 ATH_MSG_VERBOSE( "JET isbad?: " << static_cast<int>(acc_bad(input)));
758
759 return isgoodjet;
760 }

◆ IsSignalMuon()

bool ST::SUSYObjDef_xAOD::IsSignalMuon ( const xAOD::Muon & input,
const float ptcut,
const float d0sigcut,
const float z0cut,
const float etacut = DUMMYDEF ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 348 of file Muons.cxx.

349{
350 if (!acc_baseline(input)) return false;
351 if (!acc_passSignalID(input)) return false;
352
353 if (input.pt() <= ptcut || input.pt() == 0) return false; // pT cut (might be necessary for leading muon to pass trigger)
354 if ( etacut==DUMMYDEF ){
355 if(std::abs(input.eta()) > m_muEta ) return false;
356 }
357 else if ( std::abs(input.eta()) > etacut ) return false;
358
359 if (z0cut > 0.0 && std::abs(acc_z0sinTheta(input)) > z0cut) return false; // longitudinal IP cut
360 if (acc_d0sig(input) != 0) {
361 if (d0sigcut > 0.0 && std::abs(acc_d0sig(input)) > d0sigcut) return false; // transverse IP cut
362 }
363
364 if (m_doMuIsoSignal) {
365 if ( !( (acc_isol(input) && input.pt()<m_muIsoHighPtThresh) || (acc_isolHighPt(input) && input.pt()>m_muIsoHighPtThresh)) ) return false;
366 ATH_MSG_VERBOSE( "IsSignalMuon: passed isolation");
367 }
368
369 //set HighPtMuon decoration
370 IsHighPtMuon(input);
371
372 dec_signal(input) = true;
373
374 if (m_muId == 4) { //i.e. HighPt muons
375 ATH_MSG_VERBOSE( "IsSignalMuon: mu pt " << input.pt()
376 << " signal? " << static_cast<int>(acc_signal(input))
377 << " isolation? " << static_cast<int>(acc_isol(input))
378 << " passedHighPtCuts? " << static_cast<int>(acc_passedHighPtCuts(input)));
379 } else {
380 ATH_MSG_VERBOSE( "IsSignalMuon: mu pt " << input.pt()
381 << " signal? " << static_cast<int>( acc_signal(input))
382 << " isolation? " << static_cast<int>( acc_isol(input)));
383 // Don't show HighPtFlag ... we didn't set it!
384 }
385
386 return acc_signal(input);
387}
bool IsHighPtMuon(const xAOD::Muon &input) const override final
Definition Muons.cxx:390
static const SG::ConstAccessor< char > acc_passedHighPtCuts("passedHighPtCuts")

◆ IsSignalPhoton()

bool ST::SUSYObjDef_xAOD::IsSignalPhoton ( const xAOD::Photon & input,
const float ptcut,
const float etacut = DUMMYDEF ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 170 of file Photons.cxx.

171{
172 dec_signal(input) = false;
173
174 if ( !acc_baseline(input) ) return false;
175
176 if ( !m_egammaAmbiguityTool->accept(input) ) return false;
177
178 if ( input.pt() < ptcut ) return false;
179 if ( etacut==DUMMYDEF ){
180 if(std::abs(input.caloCluster()->etaBE(2)) > m_photonEta ) return false;
181 }
182 else if ( std::abs(input.caloCluster()->etaBE(2)) > etacut ) return false;
183
185 if ( std::abs( input.caloCluster()->etaBE(2) ) >1.37 && std::abs( input.caloCluster()->etaBE(2) ) <1.52) {
186 return false;
187 }
188 }
189
190 if (acc_isol(input) || !m_doPhIsoSignal) {
191 ATH_MSG_VERBOSE( "IsSignalPhoton: passed isolation");
192 } else return false;
193
194 bool passID = false;
195 if (m_acc_photonId.isAvailable(input)) {
196 passID = m_acc_photonId(input);
197 } else {
198 ATH_MSG_VERBOSE ("DFCommonPhotonsIsEMxxx variables are not found. Calculating the ID from Photon ID tool..");
199 passID = bool(m_photonSelIsEM->accept(&input));
200 }
201 if ( !passID ) return false;
202
203 dec_signal(input) = true;
204
205 return true;
206}

◆ IsSignalTau()

bool ST::SUSYObjDef_xAOD::IsSignalTau ( const xAOD::TauJet & input,
const float ptcut,
const float etacut ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 116 of file Taus.cxx.

116 {
117
118 dec_signal(input) = false;
119
120 if ( !acc_baseline(input) ) return false;
121
122 if (input.pt() <= ptcut) return false;
123
124 if (std::abs(input.eta()) >= etacut) return false;
125
126 if (!m_tauSelTool->accept( input )) return false;
127
128 dec_signal(input) = true;
129
130 return true;
131}

◆ IsTrackBJet()

bool ST::SUSYObjDef_xAOD::IsTrackBJet ( const xAOD::Jet & input) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 800 of file Jets.cxx.

800 {
801
802 bool isbjet = bool(m_btagSelTool_trkJet->accept(input));
803 dec_bjet(input) = isbjet;
804
806 ANA_MSG_ERROR("Couldn't set b-tag decorations for trackjet, is-b = " << (isbjet?"true":"false") << ", pT = " << input.pt()/1000.);
807
808 return isbjet;
809 }

◆ IsTrackBJetContinuous()

int ST::SUSYObjDef_xAOD::IsTrackBJetContinuous ( const xAOD::Jet & input) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 833 of file Jets.cxx.

833 {
834
835 int isbjet = m_btagSelTool_trkJet->getQuantile(input);
836 dec_bjet(input) = isbjet;
837
839 ANA_MSG_ERROR("Couldn't set continuous b-tag decorations for trackjet, is-b = " << isbjet << ", pT = " << input.pt()/1000.);
840
841 return isbjet;
842 }

◆ isTrigInTDT()

bool ST::SUSYObjDef_xAOD::isTrigInTDT ( std::scoped_lock< std::mutex > & lock,
const std::string & triggerName ) const
private

Definition at line 77 of file Trigger.cxx.

79{
80 auto mapItr = m_checkedTriggers.find(triggerName);
81 if ( mapItr == m_checkedTriggers.end() ) {
82 const auto *cg = m_trigDecTool->getChainGroup(triggerName);
83 return m_checkedTriggers[triggerName] = cg->getListOfTriggers().size() != 0;
84 }
85 else {
86 return mapItr->second;
87 }
88}

◆ IsTrigMatched() [1/4]

bool ST::SUSYObjDef_xAOD::IsTrigMatched ( const std::initializer_list< const xAOD::IParticle * > & v,
const std::string & tr_item )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 227 of file Trigger.cxx.

227 {
228 return m_trigMatchingTool->match(v, tr_item);
229}

◆ IsTrigMatched() [2/4]

bool ST::SUSYObjDef_xAOD::IsTrigMatched ( const std::vector< const xAOD::IParticle * > & v,
const std::string & tr_item )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 222 of file Trigger.cxx.

222 {
223 return m_trigMatchingTool->match(v, tr_item);
224}

◆ IsTrigMatched() [3/4]

bool ST::SUSYObjDef_xAOD::IsTrigMatched ( const xAOD::IParticle * part,
const std::string & tr_item )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 212 of file Trigger.cxx.

212 {
213 return this->IsTrigMatched({part}, tr_item);
214}
bool IsTrigMatched(const xAOD::IParticle *part, const std::string &tr_item) override final
Definition Trigger.cxx:212

◆ IsTrigMatched() [4/4]

bool ST::SUSYObjDef_xAOD::IsTrigMatched ( const xAOD::IParticle * part1,
const xAOD::IParticle * part2,
const std::string & tr_item )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 217 of file Trigger.cxx.

217 {
218 return this->IsTrigMatched({part1, part2}, tr_item);
219}

◆ IsTrigPassed()

bool ST::SUSYObjDef_xAOD::IsTrigPassed ( const std::string & tr_item,
unsigned int condition = TrigDefs::Physics ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 207 of file Trigger.cxx.

207 {
208 return m_trigDecTool->isPassed(tr_item, condition);
209}

◆ IsTruthBJet()

bool ST::SUSYObjDef_xAOD::IsTruthBJet ( const xAOD::Jet & input) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 301 of file Truth.cxx.

301 {
302 //Method to set correctly the IsBjet decoration needed by the JetUncertainties tool
303 bool isBjet = false;
304 if (acc_signal(input)) {
305
306 int truthlabel(-1);
307 if (!input.getAttribute("HadronConeExclTruthLabelID", truthlabel)) {
308 ATH_MSG_ERROR("Failed to get jet truth label!");
309 }
310
311 isBjet = std::abs(truthlabel) == 5;
312 }
313
314 const static SG::Decorator<char> dec_bjet_jetunc("bjet_jetunc"); //added for JetUncertainties usage
315 dec_bjet_jetunc(input) = isBjet;
316
317 return isBjet;
318}

◆ isVariation()

bool ST::SUSYObjDef_xAOD::isVariation ( const CP::SystematicSet & syst) const

Definition at line 2178 of file SUSYObjDef_xAOD.cxx.

2178 {
2179 // returns true if _any_ of the systematics affect kinematics. ignores effect on weights.
2180 for (const auto& sys : systSet) {
2181 auto info = getSystInfo(sys);
2182 if(info.affectsKinematics) { return true; }
2183 }
2184 return false;
2185}

◆ isWeight()

bool ST::SUSYObjDef_xAOD::isWeight ( const CP::SystematicSet & systSet) const

Definition at line 2167 of file SUSYObjDef_xAOD.cxx.

2167 {
2168 // returns true if all systematics do _not_ affect kinematics and _any_ of them affects the weight
2169 bool affectsWeights = false;
2170 for (const auto& sys : systSet) {
2171 auto info = getSystInfo(sys);
2172 if(info.affectsKinematics) { return false; }
2173 affectsWeights = affectsWeights or info.affectsWeights;
2174 }
2175 return affectsWeights;
2176}

◆ JetPassJVT()

bool ST::SUSYObjDef_xAOD::JetPassJVT ( xAOD::Jet & input)
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 705 of file Jets.cxx.

705 {
706 char pass_jvt = !m_applyJVTCut || m_jetNNJvtSelectionTool->accept(&input);
707 dec_passJvt(input) = pass_jvt;
708 return pass_jvt;
709 }

◆ JVT_SF()

double ST::SUSYObjDef_xAOD::JVT_SF ( const xAOD::JetContainer * jets)
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 1006 of file Jets.cxx.

1006 {
1007
1008 float totalSF = 1.;
1009 if (!m_applyJVTCut) return totalSF;
1010
1011 ConstDataVector<xAOD::JetContainer> jvtjets(SG::VIEW_ELEMENTS);
1012 for (const xAOD::Jet* jet : *jets) {
1013 // Only jets that were good for every cut except JVT
1014 if (acc_signal_less_JVT(*jet) && acc_passOR(*jet)) {
1015 jvtjets.push_back(jet);
1016 }
1017 }
1018
1019 for (const xAOD::Jet* jet : jvtjets) {
1020 float current_sf = 0;
1021
1022 // the SF are only applied for HS jets and implicitely requires the presence of the isHS decoration
1023 CP::CorrectionCode result;
1024 if (acc_passJvt(*jet)) {
1025 result = m_jetNNJvtEfficiencyTool->getEfficiencyScaleFactor(*jet,current_sf);
1026 }
1027 else {
1028 result = m_jetNNJvtEfficiencyTool->getInefficiencyScaleFactor(*jet,current_sf);
1029 }
1030
1031 switch (result) {
1033 // this is probably not right, should report an error here
1034 ATH_MSG_ERROR("Inexplicably failed JVT calibration" );
1035 break;
1037 // no NNJvt SF for jet, that is ok e.g. for jets with |eta| > 2.5
1038 ATH_MSG_VERBOSE( "Skip SF application in SUSYTools_xAOD::JVT_SF as jet outside validate range" );
1039 break;
1040 default:
1041 ATH_MSG_VERBOSE( "Retrieve SF for jet in SUSYTools_xAOD::JVT_SF with value " << current_sf );
1042 totalSF *= current_sf;
1043 }
1044
1045 }
1046
1047 ATH_MSG_VERBOSE( "Retrieve total SF for jet container in SUSYTools_xAOD::JVT_SF with value " << totalSF );
1048
1049 return totalSF;
1050 }

◆ JVT_SFsys()

double ST::SUSYObjDef_xAOD::JVT_SFsys ( const xAOD::JetContainer * jets,
const CP::SystematicSet & systConfig )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 1053 of file Jets.cxx.

1053 {
1054
1055 float totalSF = 1.;
1056 if (!m_applyJVTCut) return totalSF;
1057
1058 //Set the new systematic variation
1059 StatusCode ret = m_jetNNJvtEfficiencyTool->applySystematicVariation(systConfig);
1060 if ( ret != StatusCode::SUCCESS) {
1061 ATH_MSG_ERROR("Cannot configure NNjvtEfficiencyTool for systematic var. " << systConfig.name() );
1062 }
1063
1064 // Delegate
1065 totalSF = SUSYObjDef_xAOD::JVT_SF( jets );
1066
1067 // }
1068 if (m_applyJVTCut) {
1069 ret = m_jetNNJvtEfficiencyTool->applySystematicVariation(m_currentSyst);
1070 if ( ret != StatusCode::SUCCESS) {
1071 ATH_MSG_ERROR("Cannot configure NNjvtEfficiencyTool for systematic var. " << systConfig.name() );
1072 }
1073 }
1074
1075 return totalSF;
1076 }

◆ MergeElectrons()

StatusCode ST::SUSYObjDef_xAOD::MergeElectrons ( const xAOD::ElectronContainer & electrons,
xAOD::ElectronContainer * outputCol,
const std::set< const xAOD::Electron * > & ElectronsToRemove ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 61 of file Electrons.cxx.

61 {
62
63 if (electrons.empty()) return StatusCode::SUCCESS;
64 for (const xAOD::Electron* electron: electrons) {
65 if (ElectronsToRemove.find(electron) != ElectronsToRemove.end()){
66 ATH_MSG_DEBUG( "Removing electron from output collection (isLRT?) : ("<< static_cast<int>(acc_isLRT(*electron)) << ")" );
67 ATH_MSG_DEBUG( "ELECTRON cl eta: " << electron->caloCluster()->eta());
68 ATH_MSG_DEBUG( "ELECTRON cl phi: " << electron->caloCluster()->phi());
69 continue;
70 // add electron into output
71 } else {
72 ATH_MSG_DEBUG( "Adding electron to output collection (isLRT?) : (" << static_cast<int>(acc_isLRT(*electron)) << ")" );
73 ATH_MSG_DEBUG( "ELECTRON cl eta: " << electron->caloCluster()->eta());
74 ATH_MSG_DEBUG( "ELECTRON cl phi: " << electron->caloCluster()->phi());
75 auto newElectron = new xAOD::Electron(*electron);
76
77 if ( getOriginalObject(*electron) != nullptr ) {
79 } else {
80 setOriginalObjectLink(*electron, *newElectron);
81 }
82
83 outputCol->push_back(newElectron);
84 }
85 }
86 return StatusCode::SUCCESS;
87}
value_type push_back(value_type pElem)
Add an element to the end of the collection.
static const SG::ConstAccessor< char > acc_isLRT("isLRT")
const IParticle * getOriginalObject(const IParticle &copy)
This function can be used to conveniently get a pointer back to the original object from which a copy...

◆ MergeMuons()

StatusCode ST::SUSYObjDef_xAOD::MergeMuons ( const xAOD::MuonContainer & muons,
const std::vector< bool > & writeMuon,
xAOD::MuonContainer * outputCol ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 56 of file Muons.cxx.

56 {
57 if (muons.empty()) return StatusCode::SUCCESS;
58 for (const xAOD::Muon* muon: muons) {
59 // add muon into output
60 if (writeMuon.at(muon->index())){
61 auto newMuon = new xAOD::Muon(*muon);
62
63 if ( getOriginalObject(*muon) != nullptr ) {
65 } else {
66 setOriginalObjectLink(*muon, *newMuon);
67 }
68 outputCol->push_back(newMuon);
69 }
70 }
71 return StatusCode::SUCCESS;
72}

◆ metaDataStop()

StatusCode asg::AsgMetadataTool::metaDataStop ( )
protectedvirtualinherited

Function called when the tool should write out its metadata.

Dummy implementation that can be overridden by the derived tool.

Reimplemented in BookkeeperDumperTool, BookkeeperTool, xAODMaker::TriggerMenuMetaDataTool, and xAODMaker::TruthMetaDataTool.

Definition at line 209 of file AsgMetadataTool.cxx.

209 {
210
211 // Return gracefully:
212 return StatusCode::SUCCESS;
213 }

◆ msg()

MsgStream & AthCommonMsg< AlgTool >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24 {
25 return this->msgStream();
26 }

◆ msg_level_name()

const std::string & asg::AsgTool::msg_level_name ( ) const
inherited

A deprecated function for getting the message level's name.

Instead of using this, weirdly named function, user code should get the string name of the current minimum message level (in case they really need it...), with:

MSG::name( msg().level() )

This function's name doesn't follow the ATLAS coding rules, and as such will be removed in the not too distant future.

Returns
The string name of the current minimum message level that's printed

Definition at line 101 of file AsgTool.cxx.

101 {
102
103 return MSG::name( msg().level() );
104 }
MsgStream & msg() const
const std::string & name(Level lvl)
Convenience function for translating message levels to strings.
Definition MsgLevel.cxx:19

◆ msgLvl()

bool AthCommonMsg< AlgTool >::msgLvl ( const MSG::Level lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30 {
31 return this->msgLevel(lvl);
32 }

◆ NearbyLeptonCorrections()

StatusCode ST::SUSYObjDef_xAOD::NearbyLeptonCorrections ( xAOD::ElectronContainer * electrons = nullptr,
xAOD::MuonContainer * muons = nullptr ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 3029 of file SUSYObjDef_xAOD.cxx.

3029 {
3030 // This getCloseByIsoCorrection is computationally less expensive and actually corrects the isoaltion
3031 // variables from the contribution of the close by leptons
3032 if (m_isoCloseByTool->getCloseByIsoCorrection(Gaudi::Hive::currentContext(), electrons,muons) != CP::CorrectionCode::Ok) {
3033 return StatusCode::FAILURE;
3034 }
3035 // All done, all good :-)
3036 return StatusCode::SUCCESS;
3037}

◆ outputHandles()

virtual std::vector< Gaudi::DataHandle * > AthCommonDataStore< AthCommonMsg< AlgTool > >::outputHandles ( ) const
overridevirtualinherited

Return this algorithm's output handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ outputMetaStore()

AsgMetadataTool::MetaStorePtr_t asg::AsgMetadataTool::outputMetaStore ( ) const
inherited

Accessor for the output metadata store.

Definition at line 102 of file AsgMetadataTool.cxx.

102 {
103
104#ifdef XAOD_STANDALONE
105 return &m_outputMetaStore;
106#else // XAOD_STANDALONE
107 return m_outputMetaStore;
108#endif // XAOD_STANDALONE
109 }
MetaStore_t m_outputMetaStore
Object accessing the output metadata store.

◆ OverlapRemoval()

StatusCode ST::SUSYObjDef_xAOD::OverlapRemoval ( const xAOD::ElectronContainer * electrons,
const xAOD::MuonContainer * muons,
const xAOD::JetContainer * jets,
const xAOD::PhotonContainer * gamma = nullptr,
const xAOD::TauJetContainer * taujet = nullptr,
const xAOD::JetContainer * fatjets = nullptr )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 2994 of file SUSYObjDef_xAOD.cxx.

2997{
2998
2999 if (this->GetPrimVtx() == nullptr) {
3000 ATH_MSG_WARNING( "Will now call the OR tool on an event without a primary vertex, and it will likely crash. Please require a PV earlier in your analysis code!");
3001 }
3002
3003 ATH_CHECK( m_orToolbox.masterTool->removeOverlaps(electrons, muons, jets, taujet, gamma, fatjets) );
3004
3005 /*
3006 // Count number of objects after overlap removal
3007 int Nel = 0;
3008 for (const auto& el : *electrons) {
3009 if (dec_passOR( *el )) Nel++;
3010 }
3011
3012 int Nmu = 0;
3013 for (const auto& mu : *muons) {
3014 if (dec_passOR( *mu )) Nmu++;
3015 }
3016
3017 int Njet = 0;
3018 for (const auto& jet : *jets) {
3019 if (dec_passOR( *jet )) Njet++;
3020 }
3021
3022 ATH_MSG_VERBOSE( "After overlap removal: Nel=" << Nel << ", Nmu=" << Nmu << ", Njet=" << Njet );
3023 */
3024
3025 return StatusCode::SUCCESS;
3026}

◆ prepareLRTElectrons()

StatusCode ST::SUSYObjDef_xAOD::prepareLRTElectrons ( const xAOD::ElectronContainer * inMuons,
xAOD::ElectronContainer * copy ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 90 of file Electrons.cxx.

90 {
91 for (const xAOD::Electron *electron: *inElectrons){
92 const xAOD::TrackParticle* idtrack = electron->trackParticle();
93
94 // Save electron if the id track passes the LRT filter
95 if ( acc_lrtFilter.isAvailable(*idtrack) )
96 {
97 if ( static_cast<int>(acc_lrtFilter(*idtrack) ) ){
98 std::unique_ptr<xAOD::Electron> copyElectron = std::make_unique<xAOD::Electron>(*electron);
99
100 // transfer original electron link
101
102 setOriginalObjectLink(*electron, *copyElectron);
103 copy->push_back( std::move(copyElectron) );
104 }
105 }
106 else // Keep electron if flag is not available
107 {
108 std::unique_ptr<xAOD::Electron> copyElectron = std::make_unique<xAOD::Electron>(*electron);
109
110 setOriginalObjectLink(*electron, *copyElectron);
111 copy->push_back( std::move(copyElectron) );
112 }
113 }
114 return StatusCode::SUCCESS;
115}
static const SG::ConstAccessor< char > acc_lrtFilter("passLRTFilter")

◆ prepareLRTMuons()

StatusCode ST::SUSYObjDef_xAOD::prepareLRTMuons ( const xAOD::MuonContainer * inMuons,
xAOD::MuonContainer * copy ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 74 of file Muons.cxx.

74 {
75 for (const xAOD::Muon *muon: *inMuons){
76 const xAOD::TrackParticle* idtrack = muon->trackParticle(xAOD::Muon::InnerDetectorTrackParticle);
77
78 // Save muon if the id track passes the LRT filter
79 if ( acc_lrtFilter.isAvailable(*idtrack) )
80 {
81 if ( static_cast<int>(acc_lrtFilter(*idtrack) ) ){
82 std::unique_ptr<xAOD::Muon> copyMuon = std::make_unique<xAOD::Muon>(*muon);
83
84 // transfer original muon link
85 setOriginalObjectLink(*muon, *copyMuon);
86 copy->push_back( std::move(copyMuon) );
87 }
88 }
89 else // Keep muon if flag is not available
90 {
91 std::unique_ptr<xAOD::Muon> copyMuon = std::make_unique<xAOD::Muon>(*muon);
92
93 setOriginalObjectLink(*muon, *copyMuon);
94 copy->push_back( std::move(copyMuon) );
95 }
96
97 }
98 return StatusCode::SUCCESS;
99}

◆ print()

◆ readConfig()

StatusCode ST::SUSYObjDef_xAOD::readConfig ( )
finaloverrideprotectedvirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 1350 of file SUSYObjDef_xAOD.cxx.

1351{
1352 ATH_MSG_INFO( "***** ***** ***** *****" );
1353 ATH_MSG_INFO( "Configuring from file " << m_configFile );
1354
1355 TEnv rEnv;
1356 int success = -1;
1357 success = rEnv.ReadFile(m_configFile.c_str(), kEnvAll);
1358 if (success != 0) return StatusCode::FAILURE;
1359
1360 ATH_MSG_INFO( "Config file opened" );
1361
1363 m_jetInputType = xAOD::JetInput::Type(rEnv.GetValue("Jet.InputType", 9));
1364 ATH_MSG_INFO( "readConfig(): Loaded property Jet.InputType with value " << static_cast<int>(m_jetInputType));
1365 }
1366 // Remove the item from the table
1367 rEnv.GetTable()->Remove( rEnv.GetTable()->FindObject("Jet.InputType") );
1368
1369 if (m_muId == static_cast<int>(xAOD::Muon::Quality(xAOD::Muon::VeryLoose))) {
1370 int muIdTmp = rEnv.GetValue("Muon.Id", 1);
1371 m_muId = (muIdTmp<4 ? static_cast<int>(xAOD::Muon::Quality(muIdTmp)) : muIdTmp);
1372 ATH_MSG_INFO( "readConfig(): Loaded property Muon.Id with value " << m_muId);
1373 // Remove the item from the table
1374 rEnv.GetTable()->Remove( rEnv.GetTable()->FindObject("Muon.Id") );
1375 }
1376 if (m_muIdBaseline == static_cast<int>(xAOD::Muon::Quality(xAOD::Muon::VeryLoose))) {
1377 int muIdTmp = rEnv.GetValue("MuonBaseline.Id", 1);
1378 m_muIdBaseline = (muIdTmp<4 ? static_cast<int>(xAOD::Muon::Quality(muIdTmp)) : muIdTmp);
1379 ATH_MSG_INFO( "readConfig(): Loaded property MuonBaseline.Id with value " << m_muIdBaseline);
1380 // Remove the item from the table
1381 rEnv.GetTable()->Remove( rEnv.GetTable()->FindObject("MuonBaseline.Id") );
1382 }
1383
1384 // Deprecation warning
1385 std::string prop = rEnv.GetValue("Jet.JVT_WP", "");
1386 if ( !prop.empty() ) {
1387 ATH_MSG_WARNING("readConfig(): Found deprecated property name Jet.JVT_WP. Please move to using Jet.JvtWP. Propagating for now.");
1388 rEnv.SetValue("Jet.JvtWP", prop.c_str());
1389 rEnv.GetTable()->Remove( rEnv.GetTable()->FindObject("Jet.JVT_WP") );
1390 }
1391
1392 //load config file to Properties map (only booleans for now)
1393 m_conf_to_prop["IsRun3"] = "IsRun3";
1394 m_conf_to_prop["StrictConfigCheck"] = "StrictConfigCheck";
1395 m_conf_to_prop["Btag.enable"] = "UseBtagging";
1396 m_conf_to_prop["BtagTrkJet.enable"] = "UseBtaggingTrkJet";
1397 m_conf_to_prop["Ele.CrackVeto"] = "EleCrackVeto";
1398 m_conf_to_prop["EleBaseline.CrackVeto"] = "EleBaselineCrackVeto";
1399 m_conf_to_prop["Ele.ForceNoId"] = "EleForceNoId";
1400 m_conf_to_prop["Ele.AllowRun3TrigSFFallback"] = "EleAllowRun3TrigSFFallback";
1401 m_conf_to_prop["Muon.ForceNoId"] = "MuonForceNoId";
1402 m_conf_to_prop["Muon.TTVASF"] = "MuonTTVASF";
1403 m_conf_to_prop["Muon.passedHighPt"] = "MuonRequireHighPtCuts";
1404 m_conf_to_prop["PhotonBaseline.CrackVeto"] = "PhotonBaselineCrackVeto";
1405 m_conf_to_prop["Photon.CrackVeto"] = "PhotonCrackVeto";
1406 m_conf_to_prop["Photon.AllowLate"] = "PhotonAllowLate";
1407
1408 m_conf_to_prop["FwdJet.doJVT"] = "FwdJetDoJVT";
1409
1410 m_conf_to_prop["OR.DoBoostedElectron"] = "DoBoostedElectronOR";
1411 m_conf_to_prop["OR.DoBoostedMuon"] = "DoBoostedMuonOR";
1412 m_conf_to_prop["OR.DoMuonJetGhostAssociation"] = "ORDoMuonJetGhostAssociation";
1413 m_conf_to_prop["OR.DoTau"] = "DoTauOR";
1414 m_conf_to_prop["OR.DoPhoton"] = "DoPhotonOR";
1415 m_conf_to_prop["OR.DoEleJet"] = "DoEleJetOR";
1416 m_conf_to_prop["OR.DoElEl"] = "DoElElOR";
1417 m_conf_to_prop["OR.DoElMu"] = "DoElMuOR";
1418 m_conf_to_prop["OR.DoMuonJet"] = "DoMuonJetOR";
1419 m_conf_to_prop["OR.Bjet"] = "DoBjetOR";
1420 m_conf_to_prop["OR.ElBjet"] = "DoElBjetOR";
1421 m_conf_to_prop["OR.MuBjet"] = "DoMuBjetOR";
1422 m_conf_to_prop["OR.TauBjet"] = "DoTauBjetOR";
1423 m_conf_to_prop["OR.DoFatJets"] = "DoFatJetOR";
1424 m_conf_to_prop["OR.RemoveCaloMuons"] = "ORRemoveCaloMuons";
1425 m_conf_to_prop["OR.MuJetApplyRelPt"] = "ORMuJetApplyRelPt";
1426 m_conf_to_prop["OR.InputLabel"] = "ORInputLabel";
1427 m_conf_to_prop["Trigger.UpstreamMatching"] = "TriggerUpstreamMatching";
1428
1429 m_conf_to_prop["SigLep.RequireIso"] = "SigLepRequireIso";
1430 m_conf_to_prop["SigEl.RequireIso"] = "SigElRequireIso";
1431 m_conf_to_prop["SigMu.RequireIso"] = "SigMuRequireIso";
1432 m_conf_to_prop["SigPh.RequireIso"] = "SigPhRequireIso";
1433 m_conf_to_prop["SigLepPh.IsoCloseByOR"] = "SigLepPhIsoCloseByOR";
1434 m_conf_to_prop["MET.RemoveOverlappingCaloTaggedMuons"] = "METRemoveORCaloTaggedMuons";
1435 m_conf_to_prop["MET.DoSetMuonJetEMScale"] = "METDoSetMuonJetEMScale";
1436 m_conf_to_prop["MET.DoRemoveMuonJets"] = "METDoRemoveMuonJets";
1437 m_conf_to_prop["MET.DoUseGhostMuons"] = "METUseGhostMuons";
1438 m_conf_to_prop["MET.DoMuonEloss"] = "METDoMuonEloss";
1439
1440 m_conf_to_prop["MET.DoTrkSyst"] = "METDoTrkSyst";
1441 m_conf_to_prop["MET.DoCaloSyst"] = "METDoCaloSyst";
1442
1443 m_conf_to_prop["Tau.DoTruthMatching"] = "TauDoTruthMatching";
1444 //
1445
1446 configFromFile(m_slices["ele"], "Slices.Ele", rEnv, true);
1447 configFromFile(m_slices["pho"], "Slices.Pho", rEnv, true);
1448 configFromFile(m_slices["mu"], "Slices.Mu", rEnv, true);
1449 configFromFile(m_slices["tau"], "Slices.Tau", rEnv, true);
1450 configFromFile(m_slices["jet"], "Slices.Jet", rEnv, true);
1451 configFromFile(m_slices["bjet"], "Slices.BJet", rEnv, true);
1452 configFromFile(m_slices["fjet"], "Slices.FJet", rEnv, true);
1453 configFromFile(m_slices["tjet"], "Slices.TJet", rEnv, true);
1454 configFromFile(m_slices["met"], "Slices.MET", rEnv, true);
1455 //
1456 configFromFile(m_isRun3, "IsRun3", rEnv, false);
1457 //
1458 configFromFile(m_eleBaselinePt, "EleBaseline.Pt", rEnv, 10000.);
1459 configFromFile(m_eleBaselineEta, "EleBaseline.Eta", rEnv, 2.47);
1460 configFromFile(m_eleIdBaseline, "EleBaseline.Id", rEnv, "LooseAndBLayerLLH");
1461 configFromFile(m_eleBaselineIso_WP, "EleBaseline.Iso", rEnv, "None");
1462 configFromFile(m_eleConfigBaseline, "EleBaseline.Config", rEnv, "None");
1463 configFromFile(m_eleBaselineCrackVeto, "EleBaseline.CrackVeto", rEnv, false);
1464 configFromFile(m_force_noElId, "Ele.ForceNoId", rEnv, false);
1465
1466 //
1467 configFromFile(m_elePt, "Ele.Et", rEnv, 25000.);
1468 configFromFile(m_eleEta, "Ele.Eta", rEnv, 2.47);
1469 configFromFile(m_eleCrackVeto, "Ele.CrackVeto", rEnv, false);
1470 configFromFile(m_eleIso_WP, "Ele.Iso", rEnv, "Loose_VarRad");
1471 configFromFile(m_eleIsoHighPt_WP, "Ele.IsoHighPt", rEnv, "HighPtCaloOnly");
1472 configFromFile(m_eleIsoHighPtThresh, "Ele.IsoHighPtThresh", rEnv, 200e3);
1473 configFromFile(m_eleChID_WP, "Ele.CFT", rEnv, "None"); // Loose is the only one supported for the moment, and not many clients yet.
1474 configFromFile(m_eleChIso, "Ele.CFTIso", rEnv, true); // use charge ID SFs without iso applied
1475 configFromFile(m_eleChID_signal, "Ele.CFTSignal", rEnv, !m_eleChID_WP.empty()); // Require ECID as part of the signal lepton definition
1476 configFromFile(m_eleId, "Ele.Id", rEnv, "TightLLH");
1477 configFromFile(m_eleLRT, "Ele.LRTOR", rEnv, false);
1478 configFromFile(m_eleLRT_strat, "Ele.LRTORStrat", rEnv, 0);
1479 configFromFile(m_eleConfig, "Ele.Config", rEnv, "None");
1480 configFromFile(m_eled0sig, "Ele.d0sig", rEnv, 5.);
1481 configFromFile(m_elez0, "Ele.z0", rEnv, 0.5);
1482 configFromFile(m_elebaselined0sig, "EleBaseline.d0sig", rEnv, -99.);
1483 configFromFile(m_elebaselinez0, "EleBaseline.z0", rEnv, 0.5);
1484 configFromFile(m_eleIdExpert, "Ele.IdExpert", rEnv, false);
1485 configFromFile(m_EG_corrModel, "Ele.EffNPcorrModel", rEnv, "TOTAL");
1486 configFromFile(m_EG_corrFNList, "Ele.EffCorrFNList", rEnv, "None");
1487 configFromFile(m_electronTriggerSFStringSingle, "Ele.TriggerSFStringSingle", rEnv, "SINGLE_E_2015_e24_lhmedium_L1EM20VH_OR_e60_lhmedium_OR_e120_lhloose_2016_2018_e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0");
1488 configFromFile(m_eleEffMapFilePath, "Ele.EffMapFilePath", rEnv, "ElectronEfficiencyCorrection/2015_2025/rel22.2/2025_Run3_Consolidated_Recommendation_v4/map2.txt");
1489 configFromFile(m_eleAllowRun3TrigSFFallback, "Ele.AllowRun3TrigSFFallback", rEnv, false);
1490 configFromFile(m_eleForceFullSimCalib, "Ele.ForceFullSimCalib", rEnv, false);
1491
1492 configFromFile(m_trig2015combination_singleLep, "Trig.Singlelep2015", rEnv, "e24_lhmedium_L1EM20VH_OR_e60_lhmedium_OR_e120_lhloose || mu20_iloose_L1MU15_OR_mu40");
1493 configFromFile(m_trig2016combination_singleLep, "Trig.Singlelep2016", rEnv, "e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0 || mu26_ivarmedium_OR_mu50");
1494 configFromFile(m_trig2017combination_singleLep, "Trig.Singlelep2017", rEnv, "e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0 || mu26_ivarmedium_OR_mu50");
1495 configFromFile(m_trig2018combination_singleLep, "Trig.Singlelep2018", rEnv, "e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0 || mu26_ivarmedium_OR_mu50");
1496 configFromFile(m_trig2022combination_singleLep, "Trig.Singlelep2022", rEnv, "e26_lhtight_ivarloose_L1EM22VHI_OR_e60_lhmedium_L1EM22VHI_OR_e140_lhloose_L1EM22VHI || HLT_mu24_ivarmedium_L1MU14FCH_OR_HLT_mu50_L1MU14FCH");
1497 configFromFile(m_trig2023combination_singleLep, "Trig.Singlelep2023", rEnv, "e26_lhtight_ivarloose_L1eEM26M_OR_e60_lhmedium_L1eEM26M_OR_e140_lhloose_L1eEM26M || HLT_mu24_ivarmedium_L1MU14FCH_OR_HLT_mu50_L1MU14FCH");
1498 configFromFile(m_trig2024combination_singleLep, "Trig.Singlelep2024", rEnv, "e26_lhtight_ivarloose_L1eEM26M_OR_e60_lhmedium_L1eEM26M_OR_e140_lhloose_L1eEM26M || HLT_mu24_ivarmedium_L1MU14FCH_OR_HLT_mu50_L1MU14FCH");
1499 configFromFile(m_trigNToys_diLep, "Trig.DilepNToys", rEnv, 250); // 0 means calculate from formula instead - needs to be supported for the trigger combination
1500 configFromFile(m_trig2015combination_diLep, "Trig.Dilep2015", rEnv, "e24_lhmedium_L1EM20VH_OR_e60_lhmedium_OR_e120_lhloose || mu20_iloose_L1MU15_OR_mu40 || 2e12_lhloose_L12EM10VH || e17_lhloose_mu14 || e7_lhmedium_mu24 || mu18_mu8noL1 || 2mu10");
1501 configFromFile(m_trig2016combination_diLep, "Trig.Dilep2016", rEnv, "e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0 || mu26_ivarmedium_OR_mu50 || 2e17_lhvloose_nod0 || e17_lhloose_nod0_mu14 || e7_lhmedium_nod0_mu24 || e26_lhmedium_nod0_L1EM22VHI_mu8noL1 || mu22_mu8noL1 || 2mu14");
1502 configFromFile(m_trig2017combination_diLep, "Trig.Dilep2017", rEnv, "e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0 || mu26_ivarmedium_OR_mu50 || 2e24_lhvloose_nod0 || e17_lhloose_nod0_mu14 || e7_lhmedium_nod0_mu24 || e26_lhmedium_nod0_mu8noL1 || mu22_mu8noL1 || 2mu14");
1503 configFromFile(m_trig2018combination_diLep, "Trig.Dilep2018", rEnv, "e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0 || mu26_ivarmedium_OR_mu50 || 2e24_lhvloose_nod0 || e17_lhloose_nod0_mu14 || e7_lhmedium_nod0_mu24 || e26_lhmedium_nod0_mu8noL1 || mu22_mu8noL1 || 2mu14");
1504 // configFromFile(m_trig2022combination_diLep, "Trig.Dilep2022", rEnv, "");
1505 configFromFile(m_trigNToys_multiLep, "Trig.MultiNToys", rEnv, 250); // 0 means calculate from formula instead - needs to be supported for the trigger combination
1506 configFromFile(m_trig2015combination_multiLep, "Trig.Multi2015", rEnv, "e24_lhmedium_L1EM20VH_OR_e60_lhmedium_OR_e120_lhloose || mu20_iloose_L1MU15_OR_mu40 || 2e12_lhloose_L12EM10VH || e17_lhloose_2e9_lhloose || 2e12_lhloose_mu10 || e12_lhloose_2mu10 || e17_lhloose_mu14 || e7_lhmedium_mu24 || mu18_mu8noL1 || 2mu10 || 3mu6");
1507 configFromFile(m_trig2016combination_multiLep, "Trig.Multi2016", rEnv, "e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0 || mu26_ivarmedium_OR_mu50 || 2e17_lhvloose_nod0 || e17_lhloose_nod0_mu14 || e7_lhmedium_nod0_mu24 || e26_lhmedium_nod0_L1EM22VHI_mu8noL1 || e17_lhloose_nod0_2e9_lhloose_nod0 || e12_lhloose_nod0_2mu10 || 2e12_lhloose_nod0_mu10 || mu22_mu8noL1 || 2mu14 || 3mu6");
1508 configFromFile(m_trig2017combination_multiLep, "Trig.Multi2017", rEnv, "e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0 || mu26_ivarmedium_OR_mu50 || 2e24_lhvloose_nod0 || e17_lhloose_nod0_mu14 || e7_lhmedium_nod0_mu24 || e26_lhmedium_nod0_mu8noL1 || e24_lhvloose_nod0_2e12_lhvloose_nod0_L1EM20VH_3EM10VH || e12_lhloose_nod0_2mu10 || 2e12_lhloose_nod0_mu10 || mu22_mu8noL1 || 2mu14 || 3mu6");
1509 configFromFile(m_trig2018combination_multiLep, "Trig.Multi2018", rEnv, "e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0 || mu26_ivarmedium_OR_mu50 || 2e24_lhvloose_nod0 || e17_lhloose_nod0_mu14 || e7_lhmedium_nod0_mu24 || e26_lhmedium_nod0_mu8noL1 || e24_lhvloose_nod0_2e12_lhvloose_nod0_L1EM20VH_3EM10VH || e12_lhloose_nod0_2mu10 || 2e12_lhloose_nod0_mu10 || mu22_mu8noL1 || 2mu14 || 3mu6");
1510 // configFromFile(m_trig2022combination_multiLep, "Trig.Multi2022", rEnv, "");
1511 configFromFile(m_trigNToys_diPhoton, "Trig.DiphotonNToys", rEnv, 250); // 0 means calculate from formula instead - needs to be supported for the trigger combination
1512 configFromFile(m_trig2015combination_diPhoton, "Trig.Diphoton2015", rEnv, "g35_loose_g25_loose");
1513 configFromFile(m_trig2016combination_diPhoton, "Trig.Diphotonp2016", rEnv, "g35_loose_g25_loose");
1514 configFromFile(m_trig2017combination_diPhoton, "Trig.Diphotonp2017", rEnv, "g35_medium_g25_medium_L12EM20VH");
1515 configFromFile(m_trig2018combination_diPhoton, "Trig.Diphotonp2018", rEnv, "g35_medium_g25_medium_L12EM20VH");
1516 // configFromFile(m_trig2018combination_diPhoton, "Trig.Diphotonp2022", rEnv, "");
1517 //
1518 configFromFile(m_muBaselinePt, "MuonBaseline.Pt", rEnv, 10000.);
1519 configFromFile(m_muBaselineEta, "MuonBaseline.Eta", rEnv, 2.7);
1520 configFromFile(m_force_noMuId, "Muon.ForceNoId", rEnv, false);
1521 configFromFile(m_muBaselineIso_WP, "MuonBaseline.Iso", rEnv, "None");
1522 configFromFile(m_doTTVAsf, "Muon.TTVASF", rEnv, true);
1523 //
1524 configFromFile(m_muPt, "Muon.Pt", rEnv, 25000.);
1525 configFromFile(m_muEta, "Muon.Eta", rEnv, 2.7);
1526 configFromFile(m_muIso_WP, "Muon.Iso", rEnv, "Loose_VarRad");
1527 configFromFile(m_muIsoHighPt_WP, "Muon.IsoHighPt", rEnv, "Loose_VarRad");
1528 configFromFile(m_muIsoHighPtThresh, "Muon.IsoHighPtThresh", rEnv, 200e3);
1529 configFromFile(m_mud0sig, "Muon.d0sig", rEnv, 3.);
1530 configFromFile(m_muz0, "Muon.z0", rEnv, 0.5);
1531 configFromFile(m_mubaselined0sig, "MuonBaseline.d0sig", rEnv, -99.);
1532 configFromFile(m_mubaselinez0, "MuonBaseline.z0", rEnv, 0.5);
1533 configFromFile(m_murequirepassedHighPtCuts, "Muon.passedHighPt", rEnv, false);
1534 configFromFile(m_muHighPtExtraSmear, "Muon.HighPtExtraSmear", rEnv, false);
1535 configFromFile(m_muEffCorrForce1D, "Muon.EffCorrForce1D", rEnv, false);
1536 //
1537 configFromFile(m_muTriggerSFCalibRelease, "Muon.TriggerSFCalibRelease" ,rEnv, "None");
1538 configFromFile(m_muTriggerSFCalibFilename, "Muon.TriggerSFCalibFilename",rEnv, "None");
1539 //
1540 configFromFile(m_muCosmicz0, "MuonCosmic.z0", rEnv, 1.);
1541 configFromFile(m_muCosmicd0, "MuonCosmic.d0", rEnv, 0.2);
1542 //
1543 // LRT muons
1544 configFromFile(m_muLRT, "Muon.LRTOR", rEnv, false);
1545 //
1546 configFromFile(m_badmuQoverP, "BadMuon.qoverp", rEnv, 0.4);
1547 //
1548 configFromFile(m_muCalibrationMode, "Muon.CalibrationMode", rEnv, 0); // 0: correctData_CB
1549 //
1550 configFromFile(m_photonBaselinePt, "PhotonBaseline.Pt", rEnv, 25000.);
1551 configFromFile(m_photonBaselineEta, "PhotonBaseline.Eta", rEnv, 2.37);
1552 configFromFile(m_photonIdBaseline, "PhotonBaseline.Id", rEnv, "Tight");
1553 configFromFile(m_photonBaselineCrackVeto, "PhotonBaseline.CrackVeto", rEnv, true);
1554 configFromFile(m_photonBaselineIso_WP, "PhotonBaseline.Iso", rEnv, "None");
1555 //
1556 configFromFile(m_photonPt, "Photon.Pt", rEnv, 130000.);
1557 configFromFile(m_photonEta, "Photon.Eta", rEnv, 2.37);
1558 configFromFile(m_photonId, "Photon.Id", rEnv, "Tight");
1559 configFromFile(m_photonIso_WP, "Photon.Iso", rEnv, "FixedCutTight");
1560 configFromFile(m_photonTriggerName, "Photon.TriggerName", rEnv, "DI_PH_2015_2016_g20_tight_2016_g22_tight_2017_2018_g20_tight_icalovloose_L1EM15VHI"); // for symmetric diphoton triggers
1561 configFromFile(m_photonCrackVeto, "Photon.CrackVeto", rEnv, true);
1562 configFromFile(m_photonAllowLate, "Photon.AllowLate", rEnv, false);
1563 //
1564 configFromFile(m_tauPrePtCut, "Tau.PrePtCut", rEnv, 0.);
1565 configFromFile(m_tauPt, "Tau.Pt", rEnv, 20000.);
1566 configFromFile(m_tauEta, "Tau.Eta", rEnv, 2.5);
1567 configFromFile(m_tauTagger, "Tau.Tagger", rEnv, "RNN");
1568 configFromFile(m_tauId, "Tau.Id", rEnv, "Medium");
1569 configFromFile(m_tauEleId, "Tau.EleId", rEnv, true);
1570 configFromFile(m_tauMuOLR, "Tau.MuOLR", rEnv, false);
1571 configFromFile(m_tauConfigPath, "Tau.ConfigPath", rEnv, "default");
1572 configFromFile(m_tauIdBaseline, "TauBaseline.Id", rEnv, "Medium");
1573 configFromFile(m_tauEleIdBaseline, "TauBaseline.EleId", rEnv, true);
1574 configFromFile(m_tauMuOLRBaseline, "TauBaseline.MuOLR", rEnv, false);
1575 configFromFile(m_tauConfigPathBaseline, "TauBaseline.ConfigPath", rEnv, "default");
1576 configFromFile(m_tauDoTTM, "Tau.DoTruthMatching", rEnv, false);
1577 //
1578 configFromFile(m_tauSmearingToolRecommendationTag,"Tau.SmearingToolRecommendationTag", rEnv, "2025-prerec");
1579 configFromFile(m_tauEffToolRecommendationTag,"Tau.EffToolRecommendationTag", rEnv, "2025-prerec");
1580 configFromFile(m_ApplyMVATESQualityCheck, "Tau.MVATESQualityCheck", rEnv, true);
1581 //
1582 configFromFile(m_jetPt, "Jet.Pt", rEnv, 20000.);
1583 configFromFile(m_jetEta, "Jet.Eta", rEnv, 2.8);
1584 configFromFile(m_JvtWP, "Jet.JvtWP", rEnv, "FixedEffPt"); // https://twiki.cern.ch/twiki/bin/viewauth/AtlasProtected/PileupJetRecommendations
1585 configFromFile(m_JvtPtMax, "Jet.JvtPtMax", rEnv, 60.0e3);
1586 configFromFile(m_JvtConfigRun2, "Jet.JvtConfigRun2", rEnv, "JetJvtEfficiency/May2024/NNJvtSFFile_Run2_EMPFlow.root", true); // empty string means dummy SF
1587 configFromFile(m_JvtConfigRun3, "Jet.JvtConfigRun3", rEnv, "JetJvtEfficiency/May2024/NNJvtSFFile_Run3_EMPFlow.root", true); // empty string means dummy SF
1588 configFromFile(m_jetUncertaintiesConfig, "Jet.UncertConfig", rEnv, getDefaultJetUncConfig() ); // https://twiki.cern.ch/twiki/bin/view/AtlasProtected/JetUncertaintiesRel22/
1589 configFromFile(m_jetUncertaintiesAnalysisFile, "Jet.AnalysisFile", rEnv, "default"); // https://twiki.cern.ch/twiki/bin/view/AtlasProtected/JetUncertaintiesRel21Summer2018SmallR
1590 configFromFile(m_jetUncertaintiesCalibArea, "Jet.UncertCalibArea", rEnv, "default"); // Defaults to default area set by tool
1591 configFromFile(m_jetUncertaintiesMCType, "Jet.UncertMCType", rEnv, "", true); // empty string means the MCType is guessed
1592 configFromFile(m_jetUncertaintiesPDsmearing, "Jet.UncertPDsmearing", rEnv, true); // for non "SimpleJER" config, run the PDSmear systematics. This are labelled with an __2 if they are being used, but otherwise will have the same tree name as the JET_JER systematic trees.
1593 configFromFile(m_fatJets, "Jet.LargeRcollection", rEnv, "AntiKt10UFOCSSKSoftDropBeta100Zcut10Jets"); // set to "None" to turn off large jets
1594 configFromFile(m_fatJetUncConfig, "Jet.LargeRuncConfig", rEnv, "rel22/Spring2025_PreRec/R10_CategoryJES_FullJER_FullJMS.config");
1595 configFromFile(m_fatJetUncertaintiesPDsmearing, "Jet.LargeRUncertPDsmearing", rEnv, true); // for non "SimpleJER" config, run the PDSmear systematics. This are labelled with an __2 if they are being used, but otherwise will have the same tree name as the JET_JER systematic trees.
1596 configFromFile(m_fatJetUncVars, "Jet.LargeRuncVars", rEnv, "default"); // do all if not specified
1597 configFromFile(m_WtagConfig, "Jet.WtaggerConfig", rEnv, "SmoothedContainedWTagger_AntiKt10UFOCSSKSoftDrop_FixedSignalEfficiency80_20220221.dat");
1598 configFromFile(m_ZtagConfig, "Jet.ZtaggerConfig", rEnv, "SmoothedContainedZTagger_AntiKt10UFOCSSKSoftDrop_FixedSignalEfficiency80_20220221.dat");
1599 configFromFile(m_WZTaggerCalibArea, "Jet.WZTaggerCalibArea", rEnv, "Winter2024_R22_PreRecs/SmoothedWZTaggers/");
1600 configFromFile(m_ToptagConfig, "Jet.ToptaggerConfig", rEnv, "DNNTagger_AntiKt10UFOSD_TopInclusive80_Oct30.dat");
1601 configFromFile(m_JetTruthLabelName, "Jet.JetTruthLabelName", rEnv, "R10TruthLabel_R22v1");
1602 configFromFile(m_TopTaggerCalibArea, "Jet.TopTaggerCalibArea", rEnv, "Winter2024_R22_PreRecs/JSSWTopTaggerDNN/");
1603 configFromFile(m_jesConfig, "Jet.JESConfig", rEnv, m_isRun3 ? "AntiKt4EMPFlow_MC23a_PreRecR22_Phase2_CalibConfig_ResPU_EtaJES_GSC_241208_InSitu.config" : "PreRec_R22_PFlow_ResPU_EtaJES_GSC_February23_230215.config"); //https://twiki.cern.ch/twiki/bin/view/AtlasProtected/ApplyJetCalibrationR22
1604 configFromFile(m_jesConfigAFII, "Jet.JESConfigAFII", rEnv, m_isRun3 ? "AntiKt4EMPFlow_MC23a_PreRecR22_Phase2_CalibConfig_ResPU_EtaJES_GSC_241208_InSitu.config" : "PreRec_R22_PFlow_ResPU_EtaJES_GSC_February23_230215.config");
1605 configFromFile(m_jesConfigJMS, "Jet.JESConfigJMS", rEnv, "JES_JMS_MC16Recommendation_Consolidated_MC_only_EMTopo_July2019_Rel21.config");
1606 configFromFile(m_jesConfigJMSData, "Jet.JESConfigJMSData", rEnv, "JES_JMS_MC16Recommendation_Consolidated_data_only_EMTopo_Sep2019_Rel21.config");
1607 configFromFile(m_jesConfigFat, "Jet.JESConfigFat", rEnv, "JES_MC20PreRecommendation_R10_UFO_CSSK_SoftDrop_JMS_R21Insitu_26Nov2024.config");
1608 configFromFile(m_jesConfigFatData, "Jet.JESConfigFatData", rEnv, "JES_MC20PreRecommendation_R10_UFO_CSSK_SoftDrop_JMS_R21Insitu_26Nov2024.config");
1609 configFromFile(m_jesCalibSeq, "Jet.CalibSeq", rEnv, "JetArea_Residual_EtaJES_GSC_Insitu");
1610 configFromFile(m_jesCalibSeqJMS, "Jet.CalibSeqJMS", rEnv, "JetArea_Residual_EtaJES_GSC");
1611 configFromFile(m_jesCalibSeqFat, "Jet.CalibSeqFat", rEnv, "EtaJES_JMS");
1612 configFromFile(m_jesCalibArea, "Jet.CalibArea", rEnv, m_isRun3 ? "00-04-83" : "00-04-82");
1613 //
1614 configFromFile(m_defaultTrackJets, "TrackJet.Coll", rEnv, "AntiKtVR30Rmax4Rmin02TrackJets");
1615 configFromFile(m_trkJetPt, "TrackJet.Pt", rEnv, 20000.);
1616 configFromFile(m_trkJetEta, "TrackJet.Eta", rEnv, 2.8);
1617 //
1618 configFromFile(m_badJetCut, "BadJet.Cut", rEnv, "LooseBad");
1619 //
1620 configFromFile(m_doFwdJVT, "FwdJet.doJVT", rEnv, false); // https://twiki.cern.ch/twiki/bin/viewauth/AtlasProtected/PileupJetRecommendations
1621 configFromFile(m_fJvtWP, "FwdJet.JvtWP", rEnv, "Loose");
1622 configFromFile(m_fJvtPtMax, "FwdJet.JvtPtMax", rEnv, 60e3);
1623 configFromFile(m_fJvtEtaMin, "FwdJet.JvtEtaMin", rEnv, 2.5);
1624 configFromFile(m_fJvtConfigRun2, "FwdJet.JvtConfigRun2", rEnv, "JetJvtEfficiency/May2024/fJvtSFFile_Run2_EMPFlow.root", true); // empty string means dummy SF
1625 configFromFile(m_fJvtConfigRun3, "FwdJet.JvtConfigRun3", rEnv, "JetJvtEfficiency/May2024/fJvtSFFile_Run2_EMPFlow.root", true); // empty string means dummy SF
1626 configFromFile(m_JMScalib, "Jet.JMSCalib", rEnv, false);
1627 //
1628 configFromFile(m_useBtagging, "Btag.enable", rEnv, true);
1629 configFromFile(m_BtagTagger, "Btag.Tagger", rEnv, "GN2v01");
1630 configFromFile(m_BtagWP, "Btag.WP", rEnv, "Continuous");
1631 configFromFile(m_BtagMinPt, "Btag.MinPt", rEnv, -1.); // Not calibrated below 20
1632
1633 configFromFile(m_bTaggingCalibrationFilePath, "Btag.CalibPath", rEnv, m_isRun3 ? "xAODBTaggingEfficiency/13p6TeV/MC23_2026_05_13_GN2v01_v0.root": "xAODBTaggingEfficiency/13TeV/MC20_2025-06-17_GN2v01_v4.root");
1634 configFromFile(m_BtagSystStrategy, "Btag.SystStrategy", rEnv, "SFEigen");
1635 configFromFile(m_EigenvectorReductionB, "Btag.EigenvectorReductionB", rEnv, "Loose");
1636 configFromFile(m_EigenvectorReductionC, "Btag.EigenvectorReductionC", rEnv, "Loose");
1637 configFromFile(m_EigenvectorReductionLight, "Btag.EigenvectorReductionLight", rEnv, "Loose");
1638 configFromFile(m_BtagReadFromObject, "Btag.ReadFromObject", rEnv, false);
1639
1640 configFromFile(m_useBtagging_trkJet, "BtagTrkJet.enable", rEnv, true);
1641 configFromFile(m_BtagTagger_trkJet, "BtagTrkJet.Tagger", rEnv, "DL1r");
1642 configFromFile(m_BtagWP_trkJet, "BtagTrkJet.WP", rEnv, "FixedCutBEff_77");
1643 configFromFile(m_BtagMinPt_trkJet, "BtagTrkJet.MinPt", rEnv, -1.); // Not calibrated below 10
1644 configFromFile(m_BtagReadFromObject_trkJet, "BtagTrkJet.ReadFromObject", rEnv, false);
1645 //
1646 configFromFile(m_orDoBoostedElectron, "OR.DoBoostedElectron", rEnv, true);
1647 configFromFile(m_orBoostedElectronC1, "OR.BoostedElectronC1", rEnv, -999.); // set to positive number to override default
1648 configFromFile(m_orBoostedElectronC2, "OR.BoostedElectronC2", rEnv, -999.); // set to positive number to override default - specify in MeV (i.e. "10*GeV" will nor work in the config file)
1649 configFromFile(m_orBoostedElectronMaxConeSize, "OR.BoostedElectronMaxConeSize", rEnv, -999.); // set to positive number to override default
1650 configFromFile(m_orDoBoostedMuon, "OR.DoBoostedMuon", rEnv, true);
1651 configFromFile(m_orBoostedMuonC1, "OR.BoostedMuonC1", rEnv, -999.); // set to positive number to override default
1652 configFromFile(m_orBoostedMuonC2, "OR.BoostedMuonC2", rEnv, -999.); // set to positive number to override default - specify in MeV (i.e. "10*GeV" will nor work in the config file)
1653 configFromFile(m_orBoostedMuonMaxConeSize, "OR.BoostedMuonMaxConeSize", rEnv, -999.); // set to positive number to override default
1654 configFromFile(m_orDoMuonJetGhostAssociation, "OR.DoMuonJetGhostAssociation", rEnv, true);
1655 configFromFile(m_orDoTau, "OR.DoTau", rEnv, false);
1656 configFromFile(m_orDoPhoton, "OR.DoPhoton", rEnv, false);
1657 configFromFile(m_orDoEleJet, "OR.EleJet", rEnv, true);
1658 configFromFile(m_orDoElEl, "OR.ElEl", rEnv, false);
1659 configFromFile(m_orDoElMu, "OR.ElMu", rEnv, false);
1660 configFromFile(m_orDoMuonJet, "OR.MuonJet", rEnv, true);
1661 configFromFile(m_orDoBjet, "OR.Bjet", rEnv, false);
1662 configFromFile(m_orDoElBjet, "OR.ElBjet", rEnv, false);
1663 configFromFile(m_orDoMuBjet, "OR.MuBjet", rEnv, false);
1664 configFromFile(m_orDoTauBjet, "OR.TauBjet", rEnv, false);
1665 configFromFile(m_orApplyRelPt, "OR.MuJetApplyRelPt", rEnv, false);
1666 configFromFile(m_orMuJetPtRatio, "OR.MuJetPtRatio", rEnv, -999.);
1667 configFromFile(m_orMuJetTrkPtRatio, "OR.MuJetTrkPtRatio", rEnv, -999.);
1668 configFromFile(m_orRemoveCaloMuons, "OR.RemoveCaloMuons", rEnv, true);
1669 configFromFile(m_orMuJetInnerDR, "OR.MuJetInnerDR", rEnv, -999.);
1670 configFromFile(m_orBtagWP, "OR.BtagWP", rEnv, "FixedCutBEff_85");
1671 configFromFile(m_orInputLabel, "OR.InputLabel", rEnv, "selected"); //"baseline"
1672 configFromFile(m_orPhotonFavoured, "OR.PhotonFavoured", rEnv, false);
1673 configFromFile(m_orBJetPtUpperThres, "OR.BJetPtUpperThres", rEnv, -1.); // upper pt threshold of b-jet in OR in unit of MeV, -1 means no pt threshold
1674 configFromFile(m_orLinkOverlapObjects, "OR.LinkOverlapObjects", rEnv, false);
1675 //
1676 configFromFile(m_orDoFatjets, "OR.DoFatJets", rEnv, false);
1677 configFromFile(m_EleFatJetDR, "OR.EleFatJetDR", rEnv, -999.);
1678 configFromFile(m_JetFatJetDR, "OR.JetFatJetDR", rEnv, -999.);
1679 //
1680 configFromFile(m_upstreamTriggerMatching, "Trigger.UpstreamMatching", rEnv, false);
1681 configFromFile(m_trigMatchingPrefix, "Trigger.MatchingPrefix", rEnv, "", true);
1682 //
1683 configFromFile(m_doIsoSignal, "SigLep.RequireIso", rEnv, true);
1684 configFromFile(m_doElIsoSignal, "SigEl.RequireIso", rEnv, m_doIsoSignal);
1685 configFromFile(m_doMuIsoSignal, "SigMu.RequireIso", rEnv, m_doIsoSignal);
1686 configFromFile(m_doPhIsoSignal, "SigPh.RequireIso", rEnv, m_doIsoSignal);
1687 configFromFile(m_useSigLepForIsoCloseByOR, "SigLepPh.UseSigLepForIsoCloseByOR", rEnv, false);
1688 configFromFile(m_IsoCloseByORpassLabel, "SigLepPh.IsoCloseByORpassLabel", rEnv, "None");
1689
1690 //
1691 configFromFile(m_eleTerm, "MET.EleTerm", rEnv, "RefEle");
1692 configFromFile(m_gammaTerm, "MET.GammaTerm", rEnv, "RefGamma");
1693 configFromFile(m_tauTerm, "MET.TauTerm", rEnv, "RefTau");
1694 configFromFile(m_jetTerm, "MET.JetTerm", rEnv, "RefJet");
1695 configFromFile(m_muonTerm, "MET.MuonTerm", rEnv, "Muons");
1696 configFromFile(m_inputMETSuffix, "MET.InputSuffix", rEnv, "", true); // May be empty
1697 configFromFile(m_outMETTerm, "MET.OutputTerm", rEnv, "Final");
1698 configFromFile(m_metRemoveOverlappingCaloTaggedMuons, "MET.RemoveOverlappingCaloTaggedMuons", rEnv, true);
1699 configFromFile(m_metDoSetMuonJetEMScale, "Met.DoSetMuonJetEMScale", rEnv, true);
1700 configFromFile(m_metDoRemoveMuonJets, "MET.DoRemoveMuonJets", rEnv, true);
1701 configFromFile(m_metUseGhostMuons, "MET.UseGhostMuons", rEnv, false);
1702 configFromFile(m_metDoMuonEloss, "MET.DoMuonEloss", rEnv, false);
1703 configFromFile(m_metGreedyPhotons, "MET.DoGreedyPhotons", rEnv, false);
1704 configFromFile(m_metVeryGreedyPhotons, "MET.DoVeryGreedyPhotons", rEnv, false);
1705
1706 configFromFile(m_trkMETsyst, "MET.DoTrkSyst", rEnv, true);
1707 configFromFile(m_caloMETsyst, "MET.DoCaloSyst", rEnv, false);
1708 configFromFile(m_trkJetsyst, "MET.DoTrkJetSyst", rEnv, false);
1709 configFromFile(m_metsysConfigPrefix, "METSys.ConfigPrefix", rEnv, "METUtilities/R22_PreRecs");
1710 configFromFile(m_metJetSelection, "MET.JetSelection", rEnv, "Tight"); // Loose, Tight (default), Tighter, Tenacious
1711 configFromFile(m_softTermParam, "METSig.SoftTermParam", rEnv, met::Random);
1712 configFromFile(m_treatPUJets, "METSig.TreatPUJets", rEnv, true);
1713 configFromFile(m_doPhiReso, "METSig.DoPhiReso", rEnv, false);
1714 //
1715 configFromFile(m_prwActualMu2017File, "PRW.ActualMu2017File", rEnv, "GoodRunsLists/data17_13TeV/20180619/physics_25ns_Triggerno17e33prim.actualMu.OflLumi-13TeV-010.root");
1716 configFromFile(m_prwActualMu2018File, "PRW.ActualMu2018File", rEnv, "GoodRunsLists/data18_13TeV/20190318/physics_25ns_Triggerno17e33prim.actualMu.OflLumi-13TeV-010.root");
1717 configFromFile(m_prwActualMu2022File, "PRW.ActualMu2022File", rEnv, "GoodRunsLists/data22_13p6TeV/20250321/purw.actualMu.root");
1718 configFromFile(m_prwActualMu2023File, "PRW.ActualMu2023File", rEnv, "GoodRunsLists/data23_13p6TeV/20250321/purw.actualMu.root");
1719 configFromFile(m_prwActualMu2024File, "PRW.ActualMu2024File", rEnv, "GoodRunsLists/data24_13p6TeV/20260127/purw.actualMu.root");
1720 configFromFile(m_prwActualMu2025File, "PRW.ActualMu2025File", rEnv, "GoodRunsLists/data25_13p6TeV/20260129/purw.actualMu.root");
1721 configFromFile(m_prwDataSF, "PRW.DataSF", rEnv, 1./1.03); // default for mc16, see: https://twiki.cern.ch/twiki/bin/viewauth/AtlasProtected/ExtendedPileupReweighting#Tool_Properties
1722 configFromFile(m_prwDataSF_UP, "PRW.DataSF_UP", rEnv, 1./0.99); // mc16 uncertainty? defaulting to the value in PRWtool
1723 configFromFile(m_prwDataSF_DW, "PRW.DataSF_DW", rEnv, 1./1.07); // mc16 uncertainty? defaulting to the value in PRWtool
1724 configFromFile(m_runDepPrescaleWeightPRW, "PRW.UseRunDependentPrescaleWeight", rEnv, false); // If set to true, the prescale weight is the luminosity-average prescale over the lumiblocks in the unprescaled lumicalc file in the PRW tool.
1725 configFromFile(m_autoconfigPRWPath, "PRW.autoconfigPRWPath", rEnv, "dev/PileupReweighting/share/");
1726 configFromFile(m_autoconfigPRWFile, "PRW.autoconfigPRWFile", rEnv, "None");
1727 configFromFile(m_autoconfigPRWCombinedmode, "PRW.autoconfigPRWCombinedmode", rEnv, false);
1728 configFromFile(m_autoconfigPRWRPVmode, "PRW.autoconfigPRWRPVmode", rEnv, false);
1729 configFromFile(m_autoconfigPRWRtags, "PRW.autoconfigPRWRtags", rEnv, "mc20a:r13167_r14859,mc20d:r13144_r14860,mc20e:r13145_r14861,mc23a:r14622_r14932_r15540,mc23d:r15224_r15530,mc23e:r16083,mc23g:r17610"); // Tag details here: https://twiki.cern.ch/twiki/bin/view/AtlasProtected/AtlasProductionGroup
1730 configFromFile(m_commonPRWFileMC20a, "PRW.commonPRWFileMC20a", rEnv, "PileupReweighting/mc20_common/mc20a.284500.physlite.prw.v1.root");
1731 configFromFile(m_commonPRWFileMC20d, "PRW.commonPRWFileMC20d", rEnv, "PileupReweighting/mc20_common/mc20d.300000.physlite.prw.v1.root");
1732 configFromFile(m_commonPRWFileMC20e, "PRW.commonPRWFileMC20e", rEnv, "PileupReweighting/mc20_common/mc20e.310000.physlite.prw.v1.root");
1733 configFromFile(m_commonPRWFileMC23a, "PRW.commonPRWFileMC23a", rEnv, "PileupReweighting/mc23_common/mc23a.410000.physlite.prw.v2.root");
1734 configFromFile(m_commonPRWFileMC23d, "PRW.commonPRWFileMC23d", rEnv, "PileupReweighting/mc23_common/mc23d.450000.physlite.prw.v1.root");
1735 configFromFile(m_commonPRWFileMC23e, "PRW.commonPRWFileMC23e", rEnv, "PileupReweighting/mc23_common/mc23e.470000.physlite.prw.v1.root");
1736 configFromFile(m_commonPRWFileMC23g, "PRW.commonPRWFileMC23g", rEnv, "PileupReweighting/mc23_common/mc23g.495000.physlite.prw.v1.root");
1737 //
1738 configFromFile(m_strictConfigCheck, "StrictConfigCheck", rEnv, false);
1739
1740 // Translate tau config names
1741 if(!m_tauConfigPathBaseline.empty()) { //baseline taus
1743 if( m_tauConfigPathBaseline=="default" ) {
1744 if (m_tauTagger == "RNN") m_tauInputFileBaseline = "SUSYTools/tau_selection";
1745 else if (m_tauTagger == "GNTau") m_tauInputFileBaseline = "SUSYTools/tau_selection_gntau";
1746 else if (m_tauTagger == "LowPt") m_tauInputFileBaseline = "SUSYTools/tau_selection_lowpt";
1747 else {
1748 ATH_MSG_ERROR("Invalid tau ID selected: " << m_tauTagger << " - " << m_tauIdBaseline);
1749 return StatusCode::FAILURE;
1750 }
1751 std::string tauWPLC = m_tauIdBaseline;
1752 std::transform(tauWPLC.begin(), tauWPLC.end(), tauWPLC.begin(), [](unsigned char c) { return std::tolower(c); });
1753 // wp
1754 m_tauInputFileBaseline += "_"+tauWPLC;
1755 // eleid & muOLR
1756 m_tauInputFileBaseline += (m_tauEleIdBaseline ? "_eleid" : "_noeleid");
1757 m_tauInputFileBaseline += (m_tauMuOLRBaseline ? "_muonolr" : "");
1758 m_tauInputFileBaseline += ".conf";
1759 }
1760 ANA_MSG_INFO("configFromFile(): Parsed Tau Baseline Config input: " << m_tauInputFileBaseline);
1761 }
1762 if(!m_tauConfigPathBaseline.empty()) { //signal taus
1764 if( m_tauConfigPath=="default" ) {
1765 if (m_tauTagger == "RNN") m_tauInputFile = "SUSYTools/tau_selection";
1766 else if (m_tauTagger == "GNTau") m_tauInputFile = "SUSYTools/tau_selection_gntau";
1767 else if (m_tauTagger == "LowPt") m_tauInputFile = "SUSYTools/tau_selection_lowpt";
1768 else {
1769 ATH_MSG_ERROR("Invalid tau ID selected: " << m_tauTagger << " - " << m_tauId);
1770 return StatusCode::FAILURE;
1771 }
1772 std::string tauWPLC = m_tauId;
1773 std::transform(tauWPLC.begin(), tauWPLC.end(), tauWPLC.begin(), [](unsigned char c) { return std::tolower(c); });
1774 // wp
1775 m_tauInputFile += "_"+tauWPLC;
1776 // eleid & muOLR
1777 m_tauInputFile += (m_tauEleId ? "_eleid" : "_noeleid");
1778 m_tauInputFile += (m_tauMuOLR ? "_muonolr" : "");
1779 m_tauInputFile += ".conf";
1780 }
1781 ANA_MSG_INFO("configFromFile(): Parsed Tau Signal Config input: " << m_tauInputFile);
1782 }
1783
1784 // By now rEnv should be empty!
1785 if (rEnv.GetTable() && rEnv.GetTable()->GetSize()>0){
1786 ATH_MSG_ERROR("Found " << rEnv.GetTable()->GetSize() << " unparsed environment options:");
1787 rEnv.Print();
1788 ATH_MSG_ERROR("Please fix your configuration!");
1789 return StatusCode::FAILURE;
1790 }
1791
1792 // Set up the correct configuration files for the large-R jet tagging corresponding to the input tagger config
1793 if (!m_WtagConfig.empty()) {
1794 if (m_WtagConfig.find("Efficiency50") != std::string::npos){
1795 m_WTagUncConfig = "R10_SF_LCTopo_WTag_SigEff50.config";
1796 }
1797 else if (m_WtagConfig.find("Efficiency80") != std::string::npos){
1798 m_WTagUncConfig = "R10_SF_LCTopo_WTag_SigEff80.config";
1799 }
1800 else {
1801 ATH_MSG_ERROR("You have specified a large-R W-tag config without a matching uncertainties file. Please fix this. Currently the 50% and 80% WPs are supported");
1802 }
1803 }
1804 if (!m_ZtagConfig.empty()) {
1805 if (m_ZtagConfig.find("Efficiency50") != std::string::npos){
1806 m_ZTagUncConfig = "R10_SF_LCTopo_ZTag_SigEff50.config";
1807 }
1808 else if (m_ZtagConfig.find("Efficiency80") != std::string::npos){
1809 m_ZTagUncConfig = "R10_SF_LCTopo_ZTag_SigEff80.config";
1810 }
1811 else {
1812 ATH_MSG_ERROR("You have specified a large-R Z-tag config without a matching uncertainties file. Please fix this. Currently the 50% and 80% WPs are supported");
1813 }
1814 }
1815 std::string TopTagEff = "";
1816 std::string TopTagType = "";
1817 if (!m_ToptagConfig.empty()) {
1818 if (m_ToptagConfig.find("50") != std::string::npos){
1819 TopTagEff = "50";
1820 }
1821 else if (m_ToptagConfig.find("80") != std::string::npos){
1822 TopTagEff = "80";
1823 }
1824 else {
1825 ATH_MSG_ERROR("You have specified a large-R Top-tag config without a matching uncertainties file. Please fix this. Currently the 50% and 80% WPs are supported");
1826 }
1827 //
1828 if (m_ToptagConfig.find("Inclusive") != std::string::npos){
1829 TopTagType = "Inclusive";
1830 }
1831 else if (m_ToptagConfig.find("Contained") != std::string::npos){
1832 TopTagType = "Contained";
1833 }
1834 else {
1835 ATH_MSG_ERROR("You have specified a large-R Top-tag config without a matching uncertainties file. Please fix this. Currently the contained and inclusive WPs are supported");
1836 }
1837 m_TopTagUncConfig = "R10_SF_LCTopo_TopTag"+TopTagType+"_SigEff"+TopTagEff+".config";
1838 }
1839
1840 //** validate configuration
1842
1843 //** cache trigger chains for electron matching
1845
1846 //** cache trigger chains for matching (both electrons and muons)
1848
1856
1862
1868
1869 return StatusCode::SUCCESS;
1870}
#define ANA_MSG_INFO(xmsg)
Macro printing info messages.
std::vector< std::string > m_v_trigs23_cache_singleLep
std::vector< std::string > m_v_trigs18_cache_multiLep
void GetTriggerTokens(std::string, std::vector< std::string > &, std::vector< std::string > &, std::vector< std::string > &, std::vector< std::string > &, std::vector< std::string > &, std::vector< std::string > &, std::vector< std::string > &) const
Definition Trigger.cxx:332
std::vector< std::string > m_v_trigs22_cache_diLep
std::string m_jetUncertaintiesConfig
Prefix for trigger matchiing container name.
std::string m_jetUncertaintiesCalibArea
std::vector< std::string > m_v_trigs17_cache_multiLep
std::vector< std::string > m_v_trigs22_cache_singleLep
std::vector< std::string > m_v_trigs15_cache_multiLep
std::vector< std::string > m_v_trigs17_cache_diLep
std::vector< std::string > m_v_trigs18_cache_singleLep
std::string m_jesConfigJMSData
std::vector< std::string > m_v_trigs15_cache_diLep
std::vector< std::string > m_v_trigs22_cache_multiLep
StatusCode validConfig(bool strict=false) const
std::string m_jesCalibSeqJMS
std::vector< std::string > m_v_trigs24_cache_singleLep
std::vector< std::string > m_v_trigs18_cache_diLep
std::vector< std::string > m_v_trigs16_cache_multiLep
std::string m_jesConfigAFII
std::vector< std::string > m_v_trigs16_cache_singleLep
std::vector< std::string > m_v_trigs16_cache_diLep
std::string m_jetUncertaintiesAnalysisFile
std::string m_jetUncertaintiesMCType
void configFromFile(bool &property, const std::string &propname, TEnv &rEnv, bool defaultValue)
std::vector< std::string > m_v_trigs15_cache_singleLep
std::string getDefaultJetUncConfig()
std::vector< std::string > m_v_trigs17_cache_singleLep
std::string m_jesConfigFatData
std::string m_jesCalibSeqFat

◆ renounce()

std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > AthCommonDataStore< AthCommonMsg< AlgTool > >::renounce ( T & h)
inlineprotectedinherited

Definition at line 380 of file AthCommonDataStore.h.

381 {
382 h.renounce();
384 }
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce(T &h)

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::renounceArray ( SG::VarHandleKeyArray & handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364 {
366 }

◆ resetSystematics()

StatusCode ST::SUSYObjDef_xAOD::resetSystematics ( )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 2155 of file SUSYObjDef_xAOD.cxx.

2155 {
2157}
StatusCode applySystematicVariation(const CP::SystematicSet &systConfig) override final
CP::SystematicSet m_defaultSyst

◆ setBoolProperty()

StatusCode ST::SUSYObjDef_xAOD::setBoolProperty ( const std::string & name,
const bool & property )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 894 of file SUSYObjDef_xAOD.cxx.

894 {
895 m_bool_prop_set.insert(name);
896 return this->setProperty(name, property);
897}
void setProperty(columnar::PythonToolHandle &self, const std::string &key, nb::object value)

◆ SetBtagWeightDecorations()

StatusCode ST::SUSYObjDef_xAOD::SetBtagWeightDecorations ( const xAOD::Jet & input,
const asg::AnaToolHandle< IBTaggingSelectionTool > & btagSelTool,
const std::string & btagTagger ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 1173 of file Jets.cxx.

1173 {
1174 double weight = 0.;
1175 if ( btagSelTool->getTaggerWeight(input, weight, false/*useVetoWP=false*/) != CP::CorrectionCode::Ok ) {
1176 ATH_MSG_ERROR( btagSelTool->name() << ": could not retrieve b-tag weight (" << btagTagger << ")." );
1177 return StatusCode::FAILURE;
1178 }
1179 dec_btag_weight(input) = weight;
1180 ATH_MSG_DEBUG( btagSelTool->name() << " b-tag weight: " << weight );
1181
1182 double btag_pb(-10), btag_pc(-10), btag_pu(-10), btag_ptau(-10);
1183 // following name change is needed given different name is used for GN2v00 in derivation and in CDI
1184 std::string actualTagger = btagTagger;
1185 if (btagTagger == "GN2v00LegacyWP" || btagTagger == "GN2v00NewAliasWP"){
1186 actualTagger = "GN2v00";
1187 }
1188 if (input.isAvailable<float>(actualTagger+"_pb") && input.isAvailable<float>(actualTagger+"_pc")
1189 && input.isAvailable<float>(actualTagger+"_pu") && input.isAvailable<float>(actualTagger+"_ptau")) {
1190 btag_pb = input.auxdata<float>(actualTagger+"_pb");
1191 btag_pc = input.auxdata<float>(actualTagger+"_pc");
1192 btag_pu = input.auxdata<float>(actualTagger+"_pu");
1193 btag_ptau = input.auxdata<float>(actualTagger+"_ptau");
1194 } else {
1195 xAOD::BTaggingUtilities::getBTagging(input)->pb(actualTagger, btag_pb);
1196 xAOD::BTaggingUtilities::getBTagging(input)->pc(actualTagger, btag_pc);
1197 xAOD::BTaggingUtilities::getBTagging(input)->pu(actualTagger, btag_pu);
1198 xAOD::BTaggingUtilities::getBTagging(input)->ptau(actualTagger, btag_ptau);
1199 }
1200 dec_btag_pb(input) = btag_pb;
1201 dec_btag_pc(input) = btag_pc;
1202 dec_btag_pu(input) = btag_pu;
1203 dec_btag_ptau(input) = btag_ptau;
1204 ATH_MSG_DEBUG( btagSelTool->name() << " b-tag " << btagTagger << "-type pb: " << btag_pb );
1205 ATH_MSG_DEBUG( btagSelTool->name() << " b-tag " << btagTagger << "-type pc: " << btag_pc );
1206 ATH_MSG_DEBUG( btagSelTool->name() << " b-tag " << btagTagger << "-type pu: " << btag_pu );
1207 ATH_MSG_DEBUG( btagSelTool->name() << " b-tag " << btagTagger << "-type ptau: " << btag_ptau );
1208
1209 return StatusCode::SUCCESS;
1210 }
virtual CP::CorrectionCode getTaggerWeight(const xAOD::Jet &jet, double &tagweight) const =0
bool pc(const std::string &taggername, double &value) const
bool pu(const std::string &taggername, double &value) const
bool pb(const std::string &taggername, double &value) const
bool ptau(const std::string &taggername, double &value) const
static const SG::Decorator< float > dec_btag_pc("btag_pc")
static const SG::Decorator< float > dec_btag_ptau("btag_ptau")
static const SG::Decorator< float > dec_btag_pu("btag_pu")
static const SG::Decorator< float > dec_btag_pb("btag_pb")
const BTagging * getBTagging(const SG::AuxElement &part)
Access the default xAOD::BTagging object associated to an object.

◆ setDataSource()

void ST::SUSYObjDef_xAOD::setDataSource ( int source)

Definition at line 1222 of file SUSYObjDef_xAOD.cxx.

1222 {
1223 if (source == 0) m_dataSource = Data;
1224 else if (source == 1) m_dataSource = FullSim;
1225 else if (source == 2) m_dataSource = AtlfastII;
1226 else ATH_MSG_ERROR("Trying to set data source to unknown type (" << source << ")");
1227}

◆ setUseIncidents()

void asg::AsgMetadataTool::setUseIncidents ( const bool flag)
inlineprotectedinherited

Definition at line 132 of file AsgMetadataTool.h.

133 {
135 }
bool flag
Definition master.py:29

◆ split()

const std::vector< std::string > ST::SUSYObjDef_xAOD::split ( const std::string & s,
const std::string & delim ) const
protected

Definition at line 1873 of file SUSYObjDef_xAOD.cxx.

1873 {
1874 assert(delim.length() == 1);
1875 std::vector<std::string> retval;
1876 retval.reserve(std::count(s.begin(), s.end(), delim[0]) + 1);
1877 // if only 1
1878 if (s.find(delim)==std::string::npos) {
1879 retval.emplace_back(s);
1880 return retval;
1881 }
1882 // if need to split
1883 size_t last = 0;
1884 size_t next = 0;
1885 bool gothere=false;
1886 while ((next = s.find(delim, last)) != std::string::npos) {
1887 retval.emplace_back(s.substr(last, next - last));
1888 last = next + delim.length();
1889 gothere=true;
1890 }
1891 if(gothere)
1892 retval.emplace_back(s.substr(last));
1893
1894 return retval;
1895}

◆ SUSYToolsInit()

StatusCode SUSYObjDef_xAOD::SUSYToolsInit ( )
private

Definition at line 113 of file SUSYToolsInit.cxx.

114{
115 if (m_dataSource < 0) {
116 ATH_MSG_FATAL("Data source incorrectly configured!!");
117 ATH_MSG_FATAL("You must set the DataSource property to Data, FullSim or AtlfastII !!");
118 ATH_MSG_FATAL("Expect segfaults if you're not checking status codes, which you should be !!");
119 return StatusCode::FAILURE;
120 }
121
122 if (m_subtool_init) {
123 ATH_MSG_INFO("SUSYTools subtools already created. Ignoring this call.");
124 ATH_MSG_INFO("Note: No longer necessary to explicitly call SUSYToolsInit. Will avoid creating tools again.");
125 return StatusCode::SUCCESS;
126 }
127
128 // /////////////////////////////////////////////////////////////////////////////////////////
129 // Initialise PileupReweighting Tool
130
131 if (!m_prwTool.isUserConfigured()) {
132 ATH_MSG_DEBUG("Will now init the PRW tool");
133 std::vector<std::string> file_conf;
134 for (UInt_t i = 0; i < m_prwConfFiles.size(); i++) {
135 ATH_MSG_INFO("Adding PRW file: " << m_prwConfFiles.at(i));
136 file_conf.push_back(m_prwConfFiles.at(i));
137 }
138
139 std::vector<std::string> file_ilumi;
140 for (UInt_t i = 0; i < m_prwLcalcFiles.size(); i++) {
141 ATH_MSG_INFO("Adding ilumicalc file: " << m_prwLcalcFiles.at(i));
142 file_ilumi.push_back(m_prwLcalcFiles.at(i));
143 }
144
145 m_prwTool.setTypeAndName("CP::PileupReweightingTool/PrwTool");
146 ATH_CHECK( m_prwTool.setProperty("ConfigFiles", file_conf) );
147 ATH_CHECK( m_prwTool.setProperty("LumiCalcFiles", file_ilumi) );
148 ATH_CHECK( m_prwTool.setProperty("DataScaleFactor", m_prwDataSF) ); // 1./1.03 -> default for mc16, see: https://twiki.cern.ch/twiki/bin/viewauth/AtlasProtected/ExtendedPileupReweighting#Tool_Properties
149 ATH_CHECK( m_prwTool.setProperty("DataScaleFactorUP", m_prwDataSF_UP) ); // 1. -> old value (mc15), as the one for mc16 is still missing
150 ATH_CHECK( m_prwTool.setProperty("DataScaleFactorDOWN", m_prwDataSF_DW) ); // 1./1.18 -> old value (mc15), as the one for mc16 is still missing
151 ATH_CHECK( m_prwTool.setProperty("TrigDecisionTool", m_trigDecTool.getHandle()) );
152 ATH_CHECK( m_prwTool.setProperty("UseRunDependentPrescaleWeight", m_runDepPrescaleWeightPRW) );
153 ATH_CHECK( m_prwTool.setProperty("OutputLevel", MSG::WARNING) );
154 ATH_CHECK( m_prwTool.retrieve() );
155 } else {
156 ATH_MSG_INFO("Using user-configured PRW tool");
157 ATH_CHECK( m_prwTool.retrieve() );
158 }
159
161 // Initialize LRT systematics tool
162 if (!m_LRTuncTool.isUserConfigured() && !isData())
163 {
164 ATH_MSG_INFO("Initializing LRT uncertainty tool");
165 m_LRTuncTool.setTypeAndName("InDet::InclusiveTrackFilterTool/LRTUncTool");
166 ATH_CHECK( m_LRTuncTool.setProperty("Seed", 1) );
167 if (m_isRun3) {
168 if (m_mcCampaign == "mc23d" || m_mcCampaign == "mc23e")
169 ATH_MSG_WARNING("Please note that current ID recommendations only cover mc23a and not (yet) mc23d/e!");
170 ATH_CHECK( m_LRTuncTool.setProperty("calibFileLRTEff", "InDetTrackSystematicsTools/CalibData_25.2_2025-v00/LargeD0TrackingRecommendations_mc23a.root") );
171 }
172 else
173 ATH_CHECK( m_LRTuncTool.setProperty("calibFileLRTEff", "InDetTrackSystematicsTools/CalibData_24.0_2023-v00/LargeD0TrackingRecommendations_20230824.root") );
174 ATH_CHECK(m_LRTuncTool.retrieve());
175 } else {
176 ATH_MSG_INFO("Using user-configured LRT uncertainty tool");
177 ATH_CHECK(m_LRTuncTool.retrieve());
178 }
179
180 std::string toolName; // to be used for tool init below, keeping explicit string constants a minimum /CO
181
182 std::string jetname,jetcoll,fatjetcoll;
183 if (m_slices["jet"]) {
185 // Initialise jet calibration tool
186
187 // pick the right config file for the JES tool : https://twiki.cern.ch/twiki/bin/view/AtlasProtected/ApplyJetCalibrationR22
189 jetcoll = jetname + "Jets";
190
191 if (!m_jetCalibTool.isUserConfigured()) {
192 toolName = "JetCalibTool_" + jetname;
193 m_jetCalibTool.setTypeAndName("JetCalibrationTool/"+toolName);
194 std::string JES_config_file, calibseq;
195
197 ATH_MSG_ERROR("Unknown (unsupported) jet collection is used, (m_jetInputType = " << m_jetInputType << ")");
198 return StatusCode::FAILURE;
199 }
200
201 std::string JESconfig = isAtlfast() ? m_jesConfigAFII : m_jesConfig;
202 if(isAtlfast() && m_isRun3) {
203 ATH_MSG_WARNING("Jet JES/JER recommendations currently not available for fast sim in Run 3, falling back to full sim version");
204 JESconfig = m_jesConfig;
205 }
206
207 calibseq = m_jesCalibSeq;
208 JES_config_file = JESconfig;
209
210 // remove Insitu if it's in the string if not data
211 if (!isData()) {
212 std::string insitu("_Insitu");
213 auto found = calibseq.find(insitu);
214 if(found != std::string::npos){
215 calibseq.erase(found, insitu.length());
216 }
217 }
218
219 // JMS calibration (if requested)
220 if (m_JMScalib){
221 ATH_MSG_ERROR("JMS calibration is not supported yet for R22. Please modify your settings.");
222 return StatusCode::FAILURE;
223 }
224
225 // now instantiate the tool
226 ATH_CHECK( m_jetCalibTool.setProperty("JetCollection", jetname) );
227 ATH_CHECK( m_jetCalibTool.setProperty("ConfigFile", JES_config_file) );
228 ATH_CHECK( m_jetCalibTool.setProperty("CalibSequence", calibseq) );
229 ATH_CHECK( m_jetCalibTool.setProperty("CalibArea", m_jesCalibArea) );
230 ATH_CHECK( m_jetCalibTool.setProperty("IsData", isData()) );
231 ATH_CHECK( m_jetCalibTool.setProperty("OutputLevel", this->msg().level()) );
232 ATH_CHECK( m_jetCalibTool.retrieve() );
233 } else ATH_CHECK(m_jetCalibTool.retrieve());
234 }
235
236 if (m_slices["fjet"]) {
237 //same for fat groomed jets
238 fatjetcoll = m_fatJets;
239
240 if(fatjetcoll == "AnalysisLargeRJets") {
241 ATH_MSG_DEBUG("Fall back to calibration for AntiKt10UFOCSSKSoftDropBeta100Zcut10Jets, original name for AnalysisLargeRJets");
242 fatjetcoll = "AntiKt10UFOCSSKSoftDropBeta100Zcut10Jets";
243 }
244 if (fatjetcoll.size()>3)fatjetcoll.erase(fatjetcoll.size()-4,4);
245 if (!m_jetFatCalibTool.isUserConfigured() && !m_fatJets.empty()) {
246 toolName = "JetFatCalibTool_" + m_fatJets;
247 m_jetFatCalibTool.setTypeAndName("JetCalibrationTool/"+toolName);
248
249 std::string jesConfigFat = m_jesConfigFat;
250 std::string jesCalibSeqFat = m_jesCalibSeqFat;
251 // add Insitu if data
252 if(isData()) jesCalibSeqFat += "_Insitu";
253
254 // now instantiate the tool
255 ATH_CHECK( m_jetFatCalibTool.setProperty("JetCollection", fatjetcoll) );
256 ATH_CHECK( m_jetFatCalibTool.setProperty("ConfigFile", jesConfigFat) );
257 ATH_CHECK( m_jetFatCalibTool.setProperty("CalibSequence", jesCalibSeqFat) );
258 // always set to false : https://twiki.cern.ch/twiki/bin/viewauth/AtlasProtected/ApplyJetCalibrationR21
259 ATH_CHECK( m_jetFatCalibTool.setProperty("IsData", isData()) );
260 ATH_CHECK( m_jetFatCalibTool.setProperty("OutputLevel", this->msg().level()) );
261 ATH_CHECK( m_jetFatCalibTool.retrieve() );
262 } else if (m_jetFatCalibTool.isUserConfigured()) ATH_CHECK(m_jetFatCalibTool.retrieve());
263 }
264
265 if (m_slices["fjet"]) {
267 // Initialise Boson taggers: https://twiki.cern.ch/twiki/bin/view/AtlasProtected/BoostedJetTaggingRecommendationFullRun2#Higgs_taggers
268 if (!m_WTaggerTool.isUserConfigured() && !m_WtagConfig.empty()) {
269 m_WTaggerTool.setTypeAndName("SmoothedWZTagger/WTagger");
270 ATH_CHECK( m_WTaggerTool.setProperty("ContainerName", m_fatJets) );
271 ATH_CHECK( m_WTaggerTool.setProperty("ConfigFile", m_WtagConfig) );
272 ATH_CHECK( m_WTaggerTool.setProperty("CalibArea", m_WZTaggerCalibArea) );
273 ATH_CHECK( m_WTaggerTool.setProperty("IsMC",!isData()));
274#ifndef XAOD_STANDALONE
275 ATH_CHECK( m_WTaggerTool.setProperty("SuppressOutputDependence", true) );
276#endif
277 ATH_CHECK( m_WTaggerTool.setProperty("OutputLevel", this->msg().level()) );
278 ATH_CHECK( m_WTaggerTool.retrieve() );
279
280 // Retrieving DecorationName (needed to access tagging results downstream):
281 std::string WConfigPath = PathResolverFindCalibFile("BoostedJetTaggers/"+m_WZTaggerCalibArea+"/"+m_WtagConfig);
282 if ( m_WconfigReader.ReadFile( WConfigPath.c_str(), EEnvLevel(0) ) ) {
283 ATH_MSG_ERROR( "Error while reading large-R config file : " << WConfigPath );
284 return StatusCode::FAILURE;
285 }
286 else ATH_MSG_DEBUG( "Successfully read large-R config file : " << WConfigPath );
287
288 m_WDecorName = m_WconfigReader.GetValue("DecorationName" ,"");
289 ANA_MSG_DEBUG( "Found DecorationName in large-R config file : " << m_WDecorName );
290
291 } else if (m_WTaggerTool.isUserConfigured()) ATH_CHECK(m_WTaggerTool.retrieve());
292
293 if (!m_ZTaggerTool.isUserConfigured() && !m_ZtagConfig.empty()) {
294 m_ZTaggerTool.setTypeAndName("SmoothedWZTagger/ZTagger");
295 ATH_CHECK( m_ZTaggerTool.setProperty("ContainerName", m_fatJets) );
296 ATH_CHECK( m_ZTaggerTool.setProperty("ConfigFile", m_ZtagConfig) );
297 ATH_CHECK( m_ZTaggerTool.setProperty("CalibArea", m_WZTaggerCalibArea) );
298 ATH_CHECK( m_ZTaggerTool.setProperty("IsMC",!isData()));
299#ifndef XAOD_STANDALONE
300 ATH_CHECK( m_ZTaggerTool.setProperty("SuppressOutputDependence", true) );
301#endif
302 ATH_CHECK( m_ZTaggerTool.setProperty("OutputLevel", this->msg().level()) );
303 ATH_CHECK( m_ZTaggerTool.retrieve() );
304
305 // Retrieving DecorationName (needed to access tagging results downstream):
306 std::string ZConfigPath = PathResolverFindCalibFile("BoostedJetTaggers/"+m_WZTaggerCalibArea+"/"+m_ZtagConfig);
307 if ( m_ZconfigReader.ReadFile( ZConfigPath.c_str(), EEnvLevel(0) ) ) {
308 ATH_MSG_ERROR( "Error while reading large-R config file : " << ZConfigPath );
309 return StatusCode::FAILURE;
310 }
311 else ATH_MSG_DEBUG( "Successfully read large-R config file : " << ZConfigPath );
312
313 m_ZDecorName = m_ZconfigReader.GetValue("DecorationName" ,"");
314 ANA_MSG_DEBUG( "Found DecorationName in large-R config file : " << m_ZDecorName );
315
316 } else if (m_ZTaggerTool.isUserConfigured()) ATH_CHECK(m_ZTaggerTool.retrieve());
317
318 if (!m_TopTaggerTool.isUserConfigured() && !m_ToptagConfig.empty()) {
319 m_TopTaggerTool.setTypeAndName("JSSWTopTaggerDNN/TopTagger");
320 ATH_CHECK( m_TopTaggerTool.setProperty("ContainerName", m_fatJets) );
321 ATH_CHECK( m_TopTaggerTool.setProperty("ConfigFile", m_ToptagConfig) );
322 ATH_CHECK( m_TopTaggerTool.setProperty("CalibArea", m_TopTaggerCalibArea) );
323 ATH_CHECK( m_TopTaggerTool.setProperty("IsMC",!isData()));
324#ifndef XAOD_STANDALONE
325 ATH_CHECK( m_TopTaggerTool.setProperty("SuppressOutputDependence", true) );
326#endif
327 ATH_CHECK( m_TopTaggerTool.setProperty("OutputLevel", this->msg().level()) );
328 ATH_CHECK( m_TopTaggerTool.retrieve() );
329
330 // Retrieving DecorationName (needed to access tagging results downstream):
331 std::string TopConfigPath = PathResolverFindCalibFile("BoostedJetTaggers/"+m_TopTaggerCalibArea+"/"+m_ToptagConfig);
332 if ( m_TopconfigReader.ReadFile( TopConfigPath.c_str(), EEnvLevel(0) ) ) {
333 ATH_MSG_ERROR( "Error while reading large-R config file : " << TopConfigPath );
334 return StatusCode::FAILURE;
335 }
336 else ATH_MSG_DEBUG( "Successfully read large-R config file : " << TopConfigPath );
337
338 m_TopDecorName = m_TopconfigReader.GetValue("DecorationName" ,"");
339 ANA_MSG_DEBUG( "Found DecorationName in large-R config file : " << m_TopDecorName );
340
341 } else if (m_TopTaggerTool.isUserConfigured()) ATH_CHECK(m_TopTaggerTool.retrieve());
342
344 // Initialise JetTruthLabelingTool: https://twiki.cern.ch/twiki/bin/view/AtlasProtected/JetUncertaintiesRel21Summer2019LargeR#AnalysisBase_21_2_114_and_newer
345 if(!isData()) {
346 m_label_truthKey = fatjetcoll+"."+m_JetTruthLabelName;
347 ATH_CHECK(m_label_truthKey.initialize());
348
349 if (!m_jetTruthLabelingTool.isUserConfigured()) {
350 m_jetTruthLabelingTool.setTypeAndName("JetTruthLabelingTool/ST_JetTruthLabelingTool");
351 ATH_CHECK( m_jetTruthLabelingTool.setProperty("RecoJetContainer", m_fatJets) );
352 ATH_CHECK( m_jetTruthLabelingTool.setProperty("TruthLabelName", m_JetTruthLabelName) );
353 ATH_CHECK( m_jetTruthLabelingTool.setProperty("OutputLevel", this->msg().level()) );
354 ATH_CHECK( m_jetTruthLabelingTool.retrieve() );
355 } else if (m_jetTruthLabelingTool.isUserConfigured()) ATH_CHECK(m_jetTruthLabelingTool.retrieve());
356 }
357 }
358
359 if (m_slices["jet"] || m_slices["fjet"]) {
360
361
363 // Initialise jet uncertainty tool
364 // https://twiki.cern.ch/twiki/bin/view/AtlasProtected/JetUncertaintiesRel22
365 ATH_MSG_INFO("Set up Jet Uncertainty tool...");
366
367 // if not set, derive the MCType from the simulation type and MC campaign
368 if (m_jetUncertaintiesMCType.empty()) m_jetUncertaintiesMCType = m_isRun3 ? (isAtlfast() ? "MC23AF3" : "MC23") : (isAtlfast() ? "AF3" : "MC20");
369
370 // large-R jets use MC20AF3 instead of AF3
372 if (m_fatJetUncertaintiesMCType == "AF3") {
373 m_fatJetUncertaintiesMCType = "MC20AF3";
374 }
375
376 if (!m_jetUncertaintiesTool.isUserConfigured()) {
377 std::string jetdef("AntiKt4" + xAOD::JetInput::typeName(xAOD::JetInput::Type(m_jetInputType)));
378
379 if(jetdef !="AntiKt4EMPFlow"){
380 ATH_MSG_WARNING("Jet Uncertaintes recommendations only exist for PFlow jets, falling back to AntiKt4EMPFlow");
381 jetdef = "AntiKt4EMPFlow";
382 }
383 toolName = "JetUncertaintiesTool_" + jetdef;
384
385 m_jetUncertaintiesTool.setTypeAndName("JetUncertaintiesTool/"+toolName);
386
387 ATH_CHECK( m_jetUncertaintiesTool.setProperty("JetDefinition", jetdef) );
389 ATH_CHECK( m_jetUncertaintiesTool.setProperty("IsData", false) ); // Never use the PDSmearing for the nominal tool.
390 ATH_CHECK( m_jetUncertaintiesTool.setProperty("ConfigFile", m_jetUncertaintiesConfig) );
393 ATH_CHECK( m_jetUncertaintiesTool.setProperty("OutputLevel", this->msg().level()) );
394 ATH_CHECK( m_jetUncertaintiesTool.retrieve() );
395 } else ATH_CHECK( m_jetUncertaintiesTool.retrieve() );
396
397 ATH_MSG_INFO("Set up Jet PD Smear Uncertainty tool...");
398
399 if (!m_jetUncertaintiesPDSmearTool.isUserConfigured() && m_jetUncertaintiesPDsmearing == true) {
400 std::string jetdef("AntiKt4" + xAOD::JetInput::typeName(xAOD::JetInput::Type(m_jetInputType)));
401
402 if(jetdef !="AntiKt4EMPFlow"){
403 ATH_MSG_WARNING("Jet Uncertaintes recommendations only exist for PFlow jets, falling back to AntiKt4EMPFlow");
404 jetdef = "AntiKt4EMPFlow";
405 }
406 toolName = "JetUncertaintiesPDSmearTool_" + jetdef;
407
408 m_jetUncertaintiesPDSmearTool.setTypeAndName("JetUncertaintiesTool/"+toolName);
409
410 // If, for some reason, you're trying to use the PDSmear, with the reduced set return an error (you shouldn't do this, you're just going to duplicate the SimpleJER results.
411 bool JERUncPDsmearing = isData() ? isData() : m_jetUncertaintiesPDsmearing;
412 if (m_jetUncertaintiesConfig.find("SimpleJER") != std::string::npos && JERUncPDsmearing){
413 ATH_MSG_ERROR("You are trying to use the SimpleJER set, with PDsmearing. There is no functionality for this. Please fix your config file. Either run with PDSmear set to false, or run with the AllJER or FullJER sets.");
414 return StatusCode::FAILURE;
415 }
416 ATH_CHECK( m_jetUncertaintiesPDSmearTool.setProperty("JetDefinition", jetdef) );
418 ATH_CHECK( m_jetUncertaintiesPDSmearTool.setProperty("IsData", true) ); // Set to True by default for PDSmear-named tool.
419 ATH_CHECK( m_jetUncertaintiesPDSmearTool.setProperty("PseudoDataJERsmearingMode", true) );
422 ATH_CHECK( m_jetUncertaintiesPDSmearTool.setProperty("OutputLevel", this->msg().level()) );
424 } else{
425 ATH_MSG_DEBUG("Do not retrieve the jet PD Smearing tool if it is not configured");
426 //ATH_CHECK( m_jetUncertaintiesPDSmearTool.retrieve() );
427 }
428 }
429
430 if (m_slices["fjet"]) {
431
432 // JetUncertaintiesTool handles JES, JER and JMS uncertainties for large-R jets
433 if (!m_fatjetUncertaintiesTool.isUserConfigured() && !m_fatJets.empty() && !m_fatJetUncConfig.empty()) {
434
435 ATH_MSG_INFO("Set up Large-R Jet Uncertainty tool...");
436
437 // Print warning about missing large-R jets uncertainties for FastSim in mc23
438 if (m_isRun3 && isAtlfast())
439 ATH_MSG_WARNING("Uncertainties for large-R jets in mc23 and fast simulation not yet available; be aware uncertainties might be not complete!");
440
441 toolName = "JetUncertaintiesTool_" + m_fatJets;
442 m_fatjetUncertaintiesTool.setTypeAndName("JetUncertaintiesTool/"+toolName);
443
444 ATH_CHECK( m_fatjetUncertaintiesTool.setProperty("JetDefinition", fatjetcoll) );
446 ATH_CHECK( m_fatjetUncertaintiesTool.setProperty("IsData", isData()) );
447 ATH_CHECK( m_fatjetUncertaintiesTool.setProperty("ConfigFile", m_fatJetUncConfig) );
449
450 //Restrict variables to be shifted if (required)
451 if( m_fatJetUncVars != "default" ){
452 std::vector<std::string> shift_vars = {};
453
454 std::string temp(m_fatJetUncVars);
455 do {
456 auto pos = temp.find(',');
457 shift_vars.push_back(temp.substr(0, pos));
458 if (pos == std::string::npos)
459 temp = "";
460 else
461 temp = temp.substr(pos + 1);
462
463 }
464 while (!temp.empty() );
465
466 ATH_CHECK( m_fatjetUncertaintiesTool.setProperty("VariablesToShift", shift_vars) );
467 }
468
469 ATH_CHECK( m_fatjetUncertaintiesTool.setProperty("OutputLevel", this->msg().level()) );
471 } else if (m_fatjetUncertaintiesTool.isUserConfigured()) ATH_CHECK(m_fatjetUncertaintiesTool.retrieve());
472
473
474 if (!m_fatjetUncertaintiesPDSmearTool.isUserConfigured() && !m_fatJets.empty() && !m_fatJetUncConfig.empty() && m_fatJetUncertaintiesPDsmearing == true) {
475
476 ATH_MSG_INFO("Set up Jet PD Smear Uncertainty tool...");
477
478 toolName = "JetUncertaintiesPDSmearTool_" + m_fatJets;
479 m_fatjetUncertaintiesPDSmearTool.setTypeAndName("JetUncertaintiesTool/"+toolName);
480
481 // If, for some reason, you're trying to use the PDSmear, with the reduced set return an error (you shouldn't do this, you're just going to duplicate the SimpleJER results.
482 bool JERUncPDsmearing = isData() ? isData() : m_fatJetUncertaintiesPDsmearing;
483 if (m_fatJetUncConfig.find("SimpleJER") != std::string::npos && JERUncPDsmearing){
484 ATH_MSG_ERROR("You are trying to use the SimpleJER set, with PDsmearing. There is no functionality for this. Please fix your config file. Either run with PDSmear set to false, or run with the AllJER or FullJER sets.");
485 return StatusCode::FAILURE;
486 }
487 ATH_CHECK( m_fatjetUncertaintiesPDSmearTool.setProperty("JetDefinition", fatjetcoll) );
489 ATH_CHECK( m_fatjetUncertaintiesPDSmearTool.setProperty("IsData", true) ); // Set to True by default for PDSmear-named tool.
490 ATH_CHECK( m_fatjetUncertaintiesPDSmearTool.setProperty("PseudoDataJERsmearingMode", true) );
493 ATH_CHECK( m_fatjetUncertaintiesPDSmearTool.setProperty("OutputLevel", this->msg().level()) );
495 } else{
496 ATH_MSG_DEBUG("Do not retrieve the jet PD Smearing tool if it is not configured");
497 }
498
499
500 // FFSmearingTool handles JMR uncertainties for large-R jets
501 if (!m_fatjetFFSmearingTool.isUserConfigured() && !m_fatJets.empty() && !m_fatJetUncConfig.empty()) {
502
503 ATH_MSG_INFO("Set up Large-R FFJetSmearingTool ...");
504
505 toolName = "FFJetSmearingTool_" + m_fatJets;
506 m_fatjetFFSmearingTool.setTypeAndName("CP::FFJetSmearingTool/"+toolName);
507
508 ATH_CHECK( m_fatjetFFSmearingTool.setProperty("MassDef", "UFO") );
510 ATH_CHECK( m_fatjetFFSmearingTool.setProperty("ConfigFile", "rel22/Spring2025_PreRec/R10_FullJMR.config") );
511 ATH_CHECK( m_fatjetFFSmearingTool.setProperty("OutputLevel", this->msg().level()) );
512 ATH_CHECK( m_fatjetFFSmearingTool.retrieve() );
513 } else if (m_fatjetFFSmearingTool.isUserConfigured()) ATH_CHECK(m_fatjetFFSmearingTool.retrieve());
514
515 // Need to keep track of systematics of FFJetSmearingTool
516 if (!m_fatJets.empty()) {
517 // m_fatjetFFSmearingSyst = CP::make_systematics_vector(m_fatjetFFSmearingTool->recommendedSystematics());
518 ATH_MSG_INFO("The following uncertainties have been defined for the m_fatjetFFSmearingTool");
519 for (auto & sysSet : m_fatjetFFSmearingTool->recommendedSystematics()){
520 m_fatjetFFSmearingSyst.push_back(CP::SystematicSet({sysSet}));
521 ATH_MSG_INFO(" - " << sysSet.name());
522 }
523 }
524
525 ATH_MSG_INFO(" Won't initialise Wtagger uncertainty tool for fat jets until we get rec for UFO");
526 // Won't initialise Wtagger uncertainty tool for fat jets until we get rec for UFO
527 /*
528 if (!m_WTagjetUncertaintiesTool.isUserConfigured() && !m_fatJets.empty() && !m_WtagConfig.empty() && !m_WTagUncConfig.empty()) {
529
530 toolName = "WTagJetUncertaintiesTool_" + m_fatJets;
531 m_WTagjetUncertaintiesTool.setTypeAndName("JetUncertaintiesTool/"+toolName);
532 ATH_CHECK( m_WTagjetUncertaintiesTool.setProperty("JetDefinition", fatjetcoll) );
533 ATH_CHECK( m_WTagjetUncertaintiesTool.setProperty("MCType", "MC16") );
534 ATH_CHECK( m_WTagjetUncertaintiesTool.setProperty("IsData", isData()) );
535 ATH_CHECK( m_WTagjetUncertaintiesTool.setProperty("ConfigFile", "rel21/Fall2020/"+m_WTagUncConfig) );
536 ATH_CHECK( m_WTagjetUncertaintiesTool.setProperty("OutputLevel", this->msg().level()) );
537 ATH_CHECK( m_WTagjetUncertaintiesTool.retrieve() );
538 } else if (m_WTagjetUncertaintiesTool.isUserConfigured()) ATH_CHECK(m_WTagjetUncertaintiesTool.retrieve());
539 */
540 ATH_MSG_INFO(" Won't initialise Ztagger uncertainty tool for fat jets until we get rec for UFO");
541 // Won't initialise Ztagger uncertainty tool for fat jets until we get rec for UFO
542 /*
543 if (!m_ZTagjetUncertaintiesTool.isUserConfigured() && !m_fatJets.empty() && !m_ZtagConfig.empty() && !m_ZTagUncConfig.empty()) {
544
545 toolName = "ZTagJetUncertaintiesTool_" + m_fatJets;
546 m_ZTagjetUncertaintiesTool.setTypeAndName("JetUncertaintiesTool/"+toolName);
547 ATH_CHECK( m_ZTagjetUncertaintiesTool.setProperty("JetDefinition", fatjetcoll) );
548 ATH_CHECK( m_ZTagjetUncertaintiesTool.setProperty("ConfigFile", "rel21/Fall2020/"+m_ZTagUncConfig) );
549 ATH_CHECK( m_ZTagjetUncertaintiesTool.setProperty("MCType", "MC16") );
550 ATH_CHECK( m_ZTagjetUncertaintiesTool.setProperty("IsData", isData()) );
551 ATH_CHECK( m_ZTagjetUncertaintiesTool.setProperty("OutputLevel", this->msg().level()) );
552 ATH_CHECK( m_ZTagjetUncertaintiesTool.retrieve() );
553 } else if (m_ZTagjetUncertaintiesTool.isUserConfigured()) ATH_CHECK(m_ZTagjetUncertaintiesTool.retrieve());
554 */
555 ATH_MSG_INFO(" Won't initialise top-tagger uncertainty tool for fat jets until we get rec for UFO");
556 // Won't initialise top-tagger uncertainty tool for fat jets until we get rec for UFO
557 /*
558 if (!m_TopTagjetUncertaintiesTool.isUserConfigured() && !m_fatJets.empty() && !m_ToptagConfig.empty() && !m_TopTagUncConfig.empty()) {
559
560 toolName = "TopTagJetUncertaintiesTool_" + m_fatJets;
561 m_TopTagjetUncertaintiesTool.setTypeAndName("JetUncertaintiesTool/"+toolName);
562 ATH_CHECK( m_TopTagjetUncertaintiesTool.setProperty("JetDefinition", fatjetcoll) );
563 ATH_CHECK( m_TopTagjetUncertaintiesTool.setProperty("MCType", "MC16") );
564 ATH_CHECK( m_TopTagjetUncertaintiesTool.setProperty("IsData", isData()) );
565 ATH_CHECK( m_TopTagjetUncertaintiesTool.setProperty("ConfigFile", "rel21/Fall2020/"+m_TopTagUncConfig) );
566 ATH_CHECK( m_TopTagjetUncertaintiesTool.setProperty("OutputLevel", this->msg().level()) );
567 ATH_CHECK( m_TopTagjetUncertaintiesTool.retrieve() );
568 } else if (m_TopTagjetUncertaintiesTool.isUserConfigured()) ATH_CHECK(m_TopTagjetUncertaintiesTool.retrieve());
569 */
570 }
571
572
573 // tagger SF and uncertainties
574 // https://twiki.cern.ch/twiki/bin/view/AtlasProtected/BoostedJetTaggingRecommendationFullRun2
575 // To be implemented here
576
577 if (m_slices["jet"]) {
579 // Initialise jet cleaning tools
580
581 // see https://twiki.cern.ch/twiki/bin/view/AtlasProtected/HowToCleanJetsR22
582 if (m_badJetCut!="" && !m_jetCleaningTool.isUserConfigured()) {
583 toolName = "JetCleaningTool";
584 m_jetCleaningTool.setTypeAndName("JetCleaningTool/"+toolName);
585 ATH_CHECK( m_jetCleaningTool.setProperty("CutLevel", m_badJetCut) );
586 ATH_CHECK( m_jetCleaningTool.setProperty("DoUgly", false) );
587 ATH_CHECK( m_jetCleaningTool.setProperty("OutputLevel", this->msg().level()) );
588 ATH_CHECK( m_jetCleaningTool.retrieve() );
589 } else if (m_jetCleaningTool.isUserConfigured()) ATH_CHECK( m_jetCleaningTool.retrieve() );
590
592 // Initialise jet pileup labeling tool (required for labels used by JvtEfficiencyTools)
593
594 if(!m_jetPileupLabelingTool.isUserConfigured() && !isData()) {
595 toolName = "PileupLabelingTool";
596 m_jetPileupLabelingTool.setTypeAndName("JetPileupLabelingTool/"+toolName);
597 ATH_CHECK( m_jetPileupLabelingTool.setProperty("RecoJetContainer", m_defaultJets) );
598 ATH_CHECK( m_jetPileupLabelingTool.setProperty("TruthJetContainer", m_defaultTruthJets) );
599 #ifndef XAOD_STANDALONE
600 ATH_CHECK( m_jetPileupLabelingTool.setProperty("SuppressInputDependence", true) );
601 ATH_CHECK( m_jetPileupLabelingTool.setProperty("SuppressOutputDependence", true) );
602 #endif
603 ATH_CHECK( m_jetPileupLabelingTool.setProperty("OutputLevel", this->msg().level()) );
604 ATH_CHECK( m_jetPileupLabelingTool.retrieve() );
605 } else if (m_jetPileupLabelingTool.isUserConfigured()) ATH_CHECK( m_jetPileupLabelingTool.retrieve() );
606
608 // Initialise jet Jvt moment tool
609
610 if (!m_jetJvtMomentTool.isUserConfigured()) {
611 toolName = "JvtMomentTool";
612 m_jetJvtMomentTool.setTypeAndName("JetVertexTaggerTool/"+toolName);
613 ATH_CHECK( m_jetJvtMomentTool.setProperty("JetContainer", m_defaultJets) );
614 #ifndef XAOD_STANDALONE
615 ATH_CHECK( m_jetJvtMomentTool.setProperty("SuppressInputDependence", true) );
616 ATH_CHECK( m_jetJvtMomentTool.setProperty("SuppressOutputDependence", true) );
617 #endif
618 ATH_CHECK( m_jetJvtMomentTool.setProperty("OutputLevel", this->msg().level()) );
619 ATH_CHECK( m_jetJvtMomentTool.retrieve() );
620 } else if (m_jetJvtMomentTool.isUserConfigured()) ATH_CHECK( m_jetJvtMomentTool.retrieve() );
621
623 // Initialise jet NNJvt moment tool
624
625 m_applyJVTCut = !m_JvtWP.empty();
626 if (!m_jetNNJvtMomentTool.isUserConfigured() && m_applyJVTCut) {
627 toolName = "NNJvtMomentTool";
628 m_jetNNJvtMomentTool.setTypeAndName("JetPileupTag::JetVertexNNTagger/"+toolName);
629 ATH_CHECK( m_jetNNJvtMomentTool.setProperty("JetContainer", m_defaultJets) );
630 #ifndef XAOD_STANDALONE
631 ATH_CHECK( m_jetNNJvtMomentTool.setProperty("SuppressInputDependence", true) );
632 ATH_CHECK( m_jetNNJvtMomentTool.setProperty("SuppressOutputDependence", true) );
633 #endif
634 ATH_CHECK( m_jetNNJvtMomentTool.setProperty("OutputLevel", this->msg().level()) );
635 ATH_CHECK( m_jetNNJvtMomentTool.retrieve() );
636 } else if (m_jetNNJvtMomentTool.isUserConfigured()) ATH_CHECK( m_jetNNJvtMomentTool.retrieve() );
637
639 // Initialise jet NNJvt selection tool
640
641 if (!m_jetNNJvtSelectionTool.isUserConfigured() && m_applyJVTCut) {
642 toolName = "NNJvtSelectionTool";
643 m_jetNNJvtSelectionTool.setTypeAndName("CP::NNJvtSelectionTool/"+toolName);
644 ATH_CHECK( m_jetNNJvtSelectionTool.setProperty("JetContainer", m_defaultJets) );
645 ATH_CHECK( m_jetNNJvtSelectionTool.setProperty("WorkingPoint", m_JvtWP) );
646 ATH_CHECK( m_jetNNJvtSelectionTool.setProperty("MaxPtForJvt", m_JvtPtMax) );
647 ATH_CHECK( m_jetNNJvtSelectionTool.setProperty("JvtMomentName", "NNJvt") );
648 ATH_CHECK( m_jetNNJvtSelectionTool.setProperty("OutputLevel", this->msg().level()) );
650 } else if (m_jetNNJvtSelectionTool.isUserConfigured()) ATH_CHECK( m_jetNNJvtSelectionTool.retrieve() );
651
653 // Initialise jet NNJvt efficiency tool (scale factors)
654
655 if (!m_jetNNJvtEfficiencyTool.isUserConfigured() && m_applyJVTCut) {
656 toolName = "NNJvtEfficiencyTool";
657 m_jetNNJvtEfficiencyTool.setTypeAndName("CP::NNJvtEfficiencyTool/"+toolName);
658 ATH_CHECK( m_jetNNJvtEfficiencyTool.setProperty("JetContainer", m_defaultJets) );
659 ATH_CHECK( m_jetNNJvtEfficiencyTool.setProperty("WorkingPoint", m_JvtWP) );
660 ATH_CHECK( m_jetNNJvtEfficiencyTool.setProperty("MaxPtForJvt", m_JvtPtMax) );
662 ATH_CHECK( m_jetNNJvtEfficiencyTool.setProperty("OutputLevel", this->msg().level()) );
664 } else if (m_jetNNJvtEfficiencyTool.isUserConfigured()) ATH_CHECK( m_jetNNJvtEfficiencyTool.retrieve() );
665
667 // Initialise jet fJvt selection tool
668
669 if (!m_jetfJvtSelectionTool.isUserConfigured() && m_doFwdJVT) {
670 toolName = "fJvtSelectionTool";
671 m_jetfJvtSelectionTool.setTypeAndName("CP::FJvtSelectionTool/"+toolName);
672 ATH_CHECK( m_jetfJvtSelectionTool.setProperty("JetContainer", m_defaultJets) );
673 ATH_CHECK( m_jetfJvtSelectionTool.setProperty("WorkingPoint", m_fJvtWP) );
674 ATH_CHECK( m_jetfJvtSelectionTool.setProperty("MaxPtForJvt", m_fJvtPtMax) );
675 ATH_CHECK( m_jetfJvtSelectionTool.setProperty("JvtMomentName", "DFCommonJets_fJvt") );
676 ATH_CHECK( m_jetfJvtSelectionTool.setProperty("OutputLevel", this->msg().level()) );
677 ATH_CHECK( m_jetfJvtSelectionTool.retrieve() );
678 } else if (m_jetfJvtSelectionTool.isUserConfigured()) ATH_CHECK( m_jetfJvtSelectionTool.retrieve() );
679
681 // Initialise jet fJvt efficiency tool for scale factors (scale factors)
682
683 if (!m_jetfJvtEfficiencyTool.isUserConfigured() && m_doFwdJVT) {
684 toolName = "fJvtEfficiencyTool";
685 m_jetfJvtEfficiencyTool.setTypeAndName("CP::FJvtEfficiencyTool/"+toolName);
686 ATH_CHECK( m_jetfJvtEfficiencyTool.setProperty("JetContainer", m_defaultJets) );
687 ATH_CHECK( m_jetfJvtEfficiencyTool.setProperty("WorkingPoint", m_fJvtWP) );
688 ATH_CHECK( m_jetfJvtEfficiencyTool.setProperty("MaxPtForJvt", m_fJvtPtMax) );
690 ATH_CHECK( m_jetfJvtEfficiencyTool.setProperty("OutputLevel", this->msg().level()) );
692 } else ATH_CHECK( m_jetfJvtEfficiencyTool.retrieve() );
693 }
694
695
696 if (m_slices["mu"]) {
698 // Check muon baseline ID
699
700 std::string muQualBaseline = "";
701 switch (m_muIdBaseline) {
702 case xAOD::Muon::VeryLoose: muQualBaseline = "VeryLoose";
703 ATH_MSG_WARNING("No muon scale factors are available for VeryLoose working point.");
704 break;
705 case xAOD::Muon::Loose: muQualBaseline = "Loose"; break;
706 case xAOD::Muon::Medium: muQualBaseline = "Medium"; break;
707 case xAOD::Muon::Tight: muQualBaseline = "Tight"; break;
708 case 4: muQualBaseline = "HighPt"; break;
709 case 5: muQualBaseline = "LowPt"; break;
710 case 6: muQualBaseline = "LowPtMVA"; break;
711 case 7: muQualBaseline = "HighPt3Layers"; break;
712 default:
713 ATH_MSG_ERROR("Invalid muon working point provided: " << m_muIdBaseline << ". Cannot initialise!");
714 return StatusCode::FAILURE;
715 break;
716 }
717
719 // Initialise muon calibration tool
720 // https://twiki.cern.ch/twiki/bin/view/AtlasProtected/MuonMomentumCorrectionsSubgroup#CP_MuonCalibrationAndSmearingToo
721 // Please not that for AthAnalysis we need to configure the MuonCalibTool within METSignificance manually and just can't pass the handle
722 // Hence, any changes here should also be propagated to the METSignificance setup further below
723
724 if (!m_muonCalibTool.isUserConfigured()) {
725 m_muonCalibTool.setTypeAndName("CP::MuonCalibTool/ST_MuonCalibrationTool");
726 if (m_isRun3) ATH_CHECK( m_muonCalibTool.setProperty("IsRun3Geo", true ));
727 ATH_CHECK( m_muonCalibTool.setProperty("calibMode", m_muCalibrationMode) );
728 ATH_CHECK( m_muonCalibTool.setProperty("OutputLevel", this->msg().level()) );
729 ATH_CHECK( m_muonCalibTool.setProperty("release", "Recs2025_12_11_Run2Run3" ));
730 int IdBaselineInt = m_muIdBaseline;
731 if (IdBaselineInt == 4) {
732 ATH_CHECK( m_muonCalibTool.setProperty("do2StationsHighPt", true) );
733 }
734 ATH_CHECK( m_muonCalibTool.setProperty("doExtraSmearing", m_muHighPtExtraSmear) );
735 ATH_CHECK( m_muonCalibTool.retrieve() );
736 } else ATH_CHECK( m_muonCalibTool.retrieve() );
737
739 // Initialise muon selection tool
740
741 if (!m_muonSelectionToolBaseline.isUserConfigured()) {
742 toolName = "MuonSelectionTool_Baseline_" + muQualBaseline;
743 m_muonSelectionToolBaseline.setTypeAndName("CP::MuonSelectionTool/"+toolName);
744 if (m_isRun3) ATH_CHECK( m_muonSelectionToolBaseline.setProperty("IsRun3Geo", true ));
745
746 if (m_muBaselineEta<m_muEta){ // Test for inconsistent configuration
747 ATH_MSG_ERROR( "Requested a baseline eta cut for muons (" << m_muBaselineEta <<
748 ") that is tighter than the signal cut (" << m_muEta << "). Please check your config." );
749 return StatusCode::FAILURE;
750 }
751 int IdBaselineInt = m_muIdBaseline;
752 ATH_CHECK( m_muonSelectionToolBaseline.setProperty( "MaxEta", m_muBaselineEta) );
753 if (IdBaselineInt == 6){
754 ATH_CHECK( m_muonSelectionToolBaseline.setProperty( "MuQuality", 5 ) );
755 ATH_CHECK( m_muonSelectionToolBaseline.setProperty( "UseMVALowPt", true));
756 } else if (IdBaselineInt == 7){
757 ATH_CHECK( m_muonSelectionToolBaseline.setProperty( "MuQuality", 4 ) );
758 ATH_CHECK( m_muonSelectionToolBaseline.setProperty( "Use2stationMuonsHighPt", false));
759 } else ATH_CHECK(m_muonSelectionToolBaseline.setProperty( "MuQuality", m_muIdBaseline ));
760 ATH_CHECK( m_muonSelectionToolBaseline.setProperty("OutputLevel", this->msg().level()) );
762 } else ATH_CHECK( m_muonSelectionToolBaseline.retrieve() );
763
764
765 std::string muQual = "";
766 switch (m_muId) {
767 case xAOD::Muon::VeryLoose: muQual = "VeryLoose";
768 ATH_MSG_WARNING("No muon scale factors are available for VeryLoose working point.");
769 break;
770 case xAOD::Muon::Loose: muQual = "Loose"; break;
771 case xAOD::Muon::Medium: muQual = "Medium"; break;
772 case xAOD::Muon::Tight: muQual = "Tight"; break;
773 case 4: muQual = "HighPt"; break;
774 case 5: muQual = "LowPt"; break;
775 case 6: muQual = "LowPtMVA"; break;
776 case 7: muQual = "HighPt3Layers"; break;
777 default:
778 ATH_MSG_ERROR("Invalid muon working point provided: " << m_muId << ". Cannot initialise!");
779 return StatusCode::FAILURE;
780 break;
781 }
782
783 if (!m_muonSelectionTool.isUserConfigured()) {
784 toolName = "MuonSelectionTool_" + muQual;
785 m_muonSelectionTool.setTypeAndName("CP::MuonSelectionTool/"+toolName);
786 if (m_isRun3) ATH_CHECK( m_muonSelectionTool.setProperty("IsRun3Geo", true ));
787 ATH_CHECK( m_muonSelectionTool.setProperty( "MaxEta", m_muEta) );
788 int IdInt = m_muId;
789 if (IdInt == 6){
790 ATH_CHECK( m_muonSelectionTool.setProperty( "MuQuality", 5 ) );
791 ATH_CHECK( m_muonSelectionTool.setProperty( "UseMVALowPt", true));
792 } else if (IdInt == 7){
793 ATH_CHECK( m_muonSelectionTool.setProperty( "MuQuality", 4 ) );
794 ATH_CHECK( m_muonSelectionTool.setProperty( "Use2stationMuonsHighPt", false));
795 } else ATH_CHECK(m_muonSelectionTool.setProperty( "MuQuality", m_muId ));
796 ATH_CHECK( m_muonSelectionTool.setProperty("OutputLevel", this->msg().level()) );
797 ATH_CHECK( m_muonSelectionTool.retrieve() );
798 } else ATH_CHECK( m_muonSelectionTool.retrieve() );
799
800
801 if (!m_muonSelectionHighPtTool.isUserConfigured()) { //Fixed to HighPt WP
802 toolName = "MuonSelectionHighPtTool_" + muQual;
803 m_muonSelectionHighPtTool.setTypeAndName("CP::MuonSelectionTool/"+toolName);
804 if (m_isRun3) ATH_CHECK( m_muonSelectionHighPtTool.setProperty("IsRun3Geo", true ));
805 ATH_CHECK( m_muonSelectionHighPtTool.setProperty( "MaxEta", m_muEta) );
806 ATH_CHECK( m_muonSelectionHighPtTool.setProperty( "MuQuality", 4 ) );
807 ATH_CHECK( m_muonSelectionHighPtTool.setProperty("OutputLevel", this->msg().level()) );
809 } else ATH_CHECK( m_muonSelectionHighPtTool.retrieve() );
810
811
813 // Initialise prompt/LRT muon OR tool
814 if (!m_muonLRTORTool.isUserConfigured()) {
815 toolName = "MuonLRTOverlapRemovalTool";
816 m_muonLRTORTool.setTypeAndName("CP::MuonLRTOverlapRemovalTool/"+toolName);
818 if (m_isRun3) ATH_CHECK( m_muonLRTORTool.setProperty("UseRun3WP", true ));
819 ATH_CHECK( m_muonLRTORTool.setProperty("OutputLevel", this->msg().level()) );
820 ATH_CHECK( m_muonLRTORTool.retrieve() );
821 } else ATH_CHECK( m_muonLRTORTool.retrieve() );
822
824 // Initialise muon efficiency tools
825
826 // Hotfix for the Run2 Muon Identification SFs for the Tight WP
827 std::string MuonCP_Run2_TightFix = "";
828 if(!m_isRun3) {
829 MuonCP_Run2_TightFix = (m_muId == xAOD::Muon::Tight) ? "220725_Preliminary_r22run2" : "230213_Preliminary_r22run2_loosefix";
830 }
831 if (!m_muonEfficiencySFTool.isUserConfigured() && m_muId != xAOD::Muon::VeryLoose && !isData()) {
832 toolName = "MuonEfficiencyScaleFactors_" + muQual;
833 m_muonEfficiencySFTool.setTypeAndName("CP::MuonEfficiencyScaleFactors/"+toolName);
834 ATH_CHECK( m_muonEfficiencySFTool.setProperty("WorkingPoint", muQual) );
835 ATH_CHECK( m_muonEfficiencySFTool.setProperty("CalibrationRelease", m_isRun3 ? "251211_Preliminary_r24run3" : MuonCP_Run2_TightFix) );
836 ATH_CHECK( m_muonEfficiencySFTool.setProperty("OutputLevel", this->msg().level()) );
837 ATH_CHECK( m_muonEfficiencySFTool.retrieve() );
838 } else if (m_muonEfficiencySFTool.isUserConfigured()) ATH_CHECK( m_muonEfficiencySFTool.retrieve() );
839
840
841 if (!m_muonEfficiencyBMHighPtSFTool.isUserConfigured() && !isData()){
842 toolName = "MuonEfficiencyScaleFactorsBMHighPt_" + muQual;
843 m_muonEfficiencyBMHighPtSFTool.setTypeAndName("CP::MuonEfficiencyScaleFactors/"+toolName);
844 ATH_CHECK( m_muonEfficiencyBMHighPtSFTool.setProperty("WorkingPoint", "BadMuonVeto_HighPt") );
845 ATH_CHECK( m_muonEfficiencyBMHighPtSFTool.setProperty("CalibrationRelease", m_isRun3? "220817_Preliminary_r22run3":"230213_Preliminary_r22run2_loosefix") ); //BadMuonVeto_HighPt currently not available for 240711_Preliminary_r24run3
846 ATH_CHECK( m_muonEfficiencyBMHighPtSFTool.setProperty("OutputLevel", this->msg().level()) );
848 } else if (m_muonEfficiencyBMHighPtSFTool.isUserConfigured()) ATH_CHECK( m_muonEfficiencyBMHighPtSFTool.retrieve() );
849
850
851 if (m_doTTVAsf && m_mud0sig<0 && m_muz0<0){
852 ATH_MSG_WARNING("Requested TTVA SFs without d0sig and z0 cuts. Disabling scale factors as they will not make sense.");
853 m_doTTVAsf=false;
854 }
855
856 if (m_doTTVAsf && !m_muonTTVAEfficiencySFTool.isUserConfigured() && !isData()) {
857 toolName = "MuonTTVAEfficiencyScaleFactors";
858 m_muonTTVAEfficiencySFTool.setTypeAndName("CP::MuonEfficiencyScaleFactors/"+toolName);
859 ATH_CHECK( m_muonTTVAEfficiencySFTool.setProperty("WorkingPoint", "TTVA") );
860 ATH_CHECK( m_muonTTVAEfficiencySFTool.setProperty("CalibrationRelease", m_isRun3? "251211_Preliminary_r24run3":"230213_Preliminary_r22run2_loosefix") );
861 ATH_CHECK( m_muonTTVAEfficiencySFTool.setProperty("OutputLevel", this->msg().level()) );
863 } else if (m_muonTTVAEfficiencySFTool.isUserConfigured()) ATH_CHECK( m_muonTTVAEfficiencySFTool.retrieve() );
864
865
866
868 // Initialise muon isolation tool
869 if (!m_muonIsolationSFTool.isUserConfigured() && !m_muIso_WP.empty() && !isData()) {
870 toolName = "MuonIsolationScaleFactors_" + m_muIso_WP;
871
872 std::string tmp_muIso_WP = m_muIso_WP;
873 if ( !check_isOption(m_muIso_WP, m_mu_iso_support) ) { //check if supported
874 ATH_MSG_WARNING("Your selected muon Iso WP ("
875 << m_muIso_WP
876 << ") does not have SFs defined. Will try to find an appropriate fall-back.");
877 if (m_mu_iso_fallback.count(m_muIso_WP) > 0){
878 tmp_muIso_WP = m_mu_iso_fallback[m_muIso_WP];
879 ATH_MSG_WARNING("Your selected muon Iso WP ("
880 << m_muIso_WP
881 << " is not supported, and does not have SFs available. Falling back to "
882 << tmp_muIso_WP
883 << " for SF determination.");
884 } else {
885 ATH_MSG_ERROR("*** The muon isolation WP you selected (" << m_muIso_WP << ") is not currentely supported, and no known fall-back option for SFs exists. Sorry! ***");
886 return StatusCode::FAILURE;
887 }
888 }
889
890 m_muonIsolationSFTool.setTypeAndName("CP::MuonEfficiencyScaleFactors/"+toolName);
891 ATH_CHECK( m_muonIsolationSFTool.setProperty("WorkingPoint", tmp_muIso_WP + "Iso") );
892 ATH_CHECK( m_muonIsolationSFTool.setProperty("CalibrationRelease", m_isRun3? "251211_Preliminary_r24run3":"230213_Preliminary_r22run2_loosefix") );
893 ATH_CHECK( m_muonIsolationSFTool.setProperty("OutputLevel", this->msg().level()) );
894 ATH_CHECK( m_muonIsolationSFTool.retrieve() );
895
896 } else if (m_muonIsolationSFTool.isUserConfigured()) ATH_CHECK( m_muonIsolationSFTool.retrieve() );
897
898
899 if (!m_muonHighPtIsolationSFTool.isUserConfigured() && !m_muIsoHighPt_WP.empty() && !isData()) {
900 toolName = "MuonHighPtIsolationScaleFactors_" + m_muIsoHighPt_WP;
901
902 std::string tmp_muIsoHighPt_WP = m_muIsoHighPt_WP;
903 if ( !check_isOption(m_muIsoHighPt_WP, m_mu_iso_support) ) { //check if supported
904 ATH_MSG_WARNING("Your selected muon high-pt Iso WP ("
906 << ") does not have SFs defined. Will try to find an appropriate fall-back.");
907 if (m_mu_iso_fallback.count(m_muIsoHighPt_WP) > 0){
908 tmp_muIsoHighPt_WP = m_mu_iso_fallback[m_muIsoHighPt_WP];
909 ATH_MSG_WARNING("Your selected muon high-pt Iso WP ("
911 << " is not supported, and does not have SFs available. Falling back to "
912 << tmp_muIsoHighPt_WP
913 << " for SF determination.");
914 } else {
915 ATH_MSG_ERROR("*** The muon isolation WP you selected (" << m_muIsoHighPt_WP << ") is not currentely supported, and no known fall-back option for SFs exists. Sorry! ***");
916 return StatusCode::FAILURE;
917 }
918 }
919
920 m_muonHighPtIsolationSFTool.setTypeAndName("CP::MuonEfficiencyScaleFactors/"+toolName);
921 // Use for the low-pt WP a dedicated set of isolation scale-factors having an extra uncertainty in place
922 ATH_CHECK( m_muonHighPtIsolationSFTool.setProperty("WorkingPoint", tmp_muIsoHighPt_WP + "Iso") );
923 ATH_CHECK( m_muonHighPtIsolationSFTool.setProperty("CalibrationRelease", m_isRun3? "251211_Preliminary_r24run3":"230213_Preliminary_r22run2_loosefix") );
924 ATH_CHECK( m_muonHighPtIsolationSFTool.setProperty("OutputLevel", this->msg().level()) );
926
927 } else if (m_muonHighPtIsolationSFTool.isUserConfigured()) ATH_CHECK( m_muonHighPtIsolationSFTool.retrieve() );
928
929
931 // Initialise muon trigger scale factor tools
932
933 if (!m_muonTriggerSFTool.isUserConfigured() && !isData()) {
934 toolName = "MuonTriggerScaleFactors_" + muQual;
935 m_muonTriggerSFTool.setTypeAndName("CP::MuonTriggerScaleFactors/"+toolName);
936 if ( muQual=="LowPt" ) {
937 ATH_MSG_WARNING("You're using the LowPt muon selection, which is not supported yet in terms of muon trigger scale facorts. TEMPORAIRLY configuring the muonTriggerSFTool for Medium muons. Beware!");
938 ATH_CHECK( m_muonTriggerSFTool.setProperty("MuonQuality", "Medium" ) );
939 }
940 else ATH_CHECK( m_muonTriggerSFTool.setProperty("MuonQuality", muQual) );
941 //ATH_CHECK( m_muonTriggerSFTool.setProperty("Isolation", m_muIso_WP)); This property has been depreacted long time ago
942 ATH_CHECK( m_muonTriggerSFTool.setProperty("AllowZeroSF", true) );
943 ATH_CHECK( m_muonTriggerSFTool.setProperty("OutputLevel", this->msg().level()) );
944 if(!m_muTriggerSFCalibRelease.empty() ) ATH_CHECK( m_muonTriggerSFTool.setProperty("CalibrationRelease",m_muTriggerSFCalibRelease) );
946 if(!m_mcCampaign.empty()) ATH_CHECK( m_muonTriggerSFTool.setProperty("Campaign", m_mcCampaign) ); // if not set, loads all !86245
947 ATH_CHECK( m_muonTriggerSFTool.retrieve() );
948 m_muonTrigSFTools.push_back(m_muonTriggerSFTool.getHandle());
949 } else if (m_muonTriggerSFTool.isUserConfigured()) {
950 ATH_CHECK( m_muonTriggerSFTool.retrieve() );
951 m_muonTrigSFTools.push_back(m_muonTriggerSFTool.getHandle());
952 }
953 }
954
955 if (m_slices["ele"]) {
956 // /////////////////////////////////////////////////////////////////////////////////////////
957 // Initialise electron selector tools
958
959 // Signal Electrons
960 if (!m_elecSelLikelihood.isUserConfigured()) {
961 toolName = "EleSelLikelihood_" + m_eleId;
962
963 if (m_eleId.find("DNN") != std::string::npos) {
964 m_elecSelLikelihood.setTypeAndName("AsgElectronSelectorTool/"+toolName);
965 }
966 else {
967 m_elecSelLikelihood.setTypeAndName("AsgElectronLikelihoodTool/"+toolName);
968 }
969
970 if (! m_eleConfig.empty() ){
971 ATH_MSG_INFO("Overriding specified Ele.Id working point in favour of configuration file");
972 ATH_CHECK( m_elecSelLikelihood.setProperty("ConfigFile", m_eleConfig) );
973 } else if ( !check_isOption(m_eleId, m_el_id_support) ) { //check if supported
974 ATH_MSG_ERROR("Invalid electron ID selected: " << m_eleId);
975 return StatusCode::FAILURE;
976 }
977 else if (m_eleId == "VeryLooseLLH" || m_eleId == "LooseLLH") {
978 ATH_MSG_WARNING(" ****************************************************************************");
979 ATH_MSG_WARNING(" CAUTION: Setting " << m_eleId << " as signal electron ID");
980 ATH_MSG_WARNING(" These may be used for loose electron CRs but no scale factors are provided.");
981 ATH_MSG_WARNING(" ****************************************************************************");
982 ATH_CHECK( m_elecSelLikelihood.setProperty("WorkingPoint", EG_WP(m_eleId) ));
983 } else {
984 ATH_CHECK( m_elecSelLikelihood.setProperty("WorkingPoint", EG_WP(m_eleId) ));
985 }
986
987 ATH_CHECK( m_elecSelLikelihood.setProperty("OutputLevel", this->msg().level()) );
988 ATH_CHECK( m_elecSelLikelihood.retrieve() );
989 } else ATH_CHECK( m_elecSelLikelihood.retrieve() );
990
991 // Baseline Electrons
992 if (!m_elecSelLikelihoodBaseline.isUserConfigured()) {
993 toolName = "EleSelLikelihoodBaseline_" + m_eleIdBaseline;
994
995 if (m_eleIdBaseline.find("DNN") != std::string::npos) {
996 m_elecSelLikelihoodBaseline.setTypeAndName("AsgElectronSelectorTool/"+toolName);
997 }
998 else {
999 m_elecSelLikelihoodBaseline.setTypeAndName("AsgElectronLikelihoodTool/"+toolName);
1000 }
1001
1002 if (! m_eleConfigBaseline.empty() ){
1003 ATH_MSG_INFO("Overriding specified EleBaseline.Id working point in favour of configuration file");
1004 ATH_CHECK( m_elecSelLikelihoodBaseline.setProperty("ConfigFile", m_eleConfigBaseline ));
1005 } else if ( !check_isOption(m_eleIdBaseline, m_el_id_support) ) { //check if supported
1006 ATH_MSG_ERROR("Invalid electron ID selected: " << m_eleIdBaseline);
1007 return StatusCode::FAILURE;
1008 } else {
1009 ATH_CHECK( m_elecSelLikelihoodBaseline.setProperty("WorkingPoint", EG_WP(m_eleIdBaseline)) );
1010 }
1011
1012 ATH_CHECK( m_elecSelLikelihoodBaseline.setProperty("OutputLevel", this->msg().level()) );
1014 } else ATH_CHECK( m_elecSelLikelihoodBaseline.retrieve() );
1015 }
1016
1018 // Initialise prompt/LRT electron OR tool
1019 if (!m_elecLRTORTool.isUserConfigured()) {
1020 toolName = "ElectronLRTOverlapRemovalTool";
1021 m_elecLRTORTool.setTypeAndName("CP::ElectronLRTOverlapRemovalTool/"+toolName);
1022 ATH_MSG_DEBUG("Setting ElectronLRTOverlapRemovalTool strategy to "<<m_eleLRT_strat);
1023 ATH_CHECK( m_elecLRTORTool.setProperty("overlapStrategy", m_eleLRT_strat) );
1024 ATH_CHECK( m_elecLRTORTool.retrieve() );
1025 } else ATH_CHECK( m_elecLRTORTool.retrieve() );
1026
1027 if (m_slices["pho"]) {
1028 // /////////////////////////////////////////////////////////////////////////////////////////
1029 // Initialise photon selector tools
1030
1031 if (!m_photonSelIsEM.isUserConfigured()) {
1032 toolName = "PhotonSelIsEM_" + m_photonId;
1033 m_photonSelIsEM.setTypeAndName("AsgPhotonIsEMSelector/"+toolName);
1034
1035 if (!check_isOption(m_photonId, m_ph_id_support)){ //check if supported
1036 ATH_MSG_ERROR("Invalid photon ID selected: " << m_photonId);
1037 return StatusCode::FAILURE;
1038 }
1039
1040 ATH_CHECK( m_photonSelIsEM.setProperty("WorkingPoint", m_photonId+"Photon") );
1041 ATH_CHECK( m_photonSelIsEM.setProperty("OutputLevel", this->msg().level()) );
1042 ATH_CHECK( m_photonSelIsEM.retrieve() );
1043 } else ATH_CHECK( m_photonSelIsEM.retrieve() );
1044
1045 if (!m_photonSelIsEMBaseline.isUserConfigured()) {
1046 toolName = "PhotonSelIsEMBaseline_" + m_photonIdBaseline;
1047 m_photonSelIsEMBaseline.setTypeAndName("AsgPhotonIsEMSelector/"+toolName);
1048
1049 if(!check_isOption(m_photonIdBaseline, m_ph_id_support)){ //check if supported
1050 ATH_MSG_ERROR("Invalid photon ID selected: " << m_photonIdBaseline);
1051 return StatusCode::FAILURE;
1052 }
1053
1054 ATH_CHECK( m_photonSelIsEMBaseline.setProperty("WorkingPoint", m_photonIdBaseline+"Photon") );
1055 ATH_CHECK( m_photonSelIsEMBaseline.setProperty("OutputLevel", this->msg().level()) );
1056 ATH_CHECK( m_photonSelIsEMBaseline.retrieve() );
1057 } else ATH_CHECK( m_photonSelIsEMBaseline.retrieve() );
1058 }
1059
1060 if (m_slices["ele"]||m_slices["pho"]) {
1062 // Initialise DeadHVCellRemovalTool
1063 // https://twiki.cern.ch/twiki/bin/viewauth/AtlasProtected/EGammaIdentificationRun2#Removal_of_Electron_Photon_clust
1064
1065 ATH_MSG_DEBUG("Setup AsgDeadHVCellRemovalTool/deadHVTool");
1066 m_deadHVTool.setTypeAndName("AsgDeadHVCellRemovalTool/deadHVTool");
1067 ATH_CHECK(m_deadHVTool.retrieve());
1068 }
1069
1070 if (m_slices["ele"]) {
1072 // Initialise electron efficiency tool
1073
1075 if (!isData()) {
1076 if (isAtlfast()) data_type = PATCore::ParticleDataType::Fast;
1077 else data_type = PATCore::ParticleDataType::Full;
1078 ATH_MSG_DEBUG( "Setting data type to " << data_type);
1079 }
1080
1081 m_eleEffMapFilePathRun2 = "ElectronEfficiencyCorrection/2015_2018/rel21.2/Precision_Summer2020_v1/map4.txt";
1082
1083 if(!m_isRun3) {
1084 ATH_MSG_INFO( "Running on Run2 samples; Using egamma SF tools from R21 map ");
1086 }
1087
1088 toolName = "AsgElectronEfficiencyCorrectionTool_reco";
1090
1091 //-- get KEYS supported by egamma SF tools
1092 std::vector<std::string> eSF_keys = getElSFkeys( m_isRun3? m_eleEffMapFilePath : m_eleEffMapFilePathRun2);
1093
1094 if (m_eleId.find("NoPix") != std::string::npos || m_eleId == "VeryLooseLLH" || m_eleId == "LooseLLH" || m_eleId == "Medium") {
1095 ATH_MSG_WARNING("Not configuring electron ID and trigger scale factors for " << m_eleId);
1096 }
1097 else {
1098 // This needs to be formatted for the scale factors: no _Rel20, no LH label, etc.
1099 std::string eleId = TString(m_eleId).ReplaceAll("AndBLayer", "BLayer").ReplaceAll("LLH", "").Data();
1100
1101 if (m_eleId.find("DNN") != std::string::npos) {
1102 eleId = TString(eleId).ReplaceAll("DNNnoCF", "").ReplaceAll("DNN", "").ReplaceAll("Loose", "LooseBLayer").Data();
1103 ATH_MSG_WARNING("Electron DNN ID working point " << m_eleId << " doesn't have SFs yet, fall back to " << eleId);
1104 }
1105
1106 // electron id
1107 toolName = "AsgElectronEfficiencyCorrectionTool_id_" + m_eleId;
1109
1110 // override map file use if correction file list is set for WP
1111 std::map<std::string,std::string> corrFNList;
1112 if ( !m_EG_corrFNList.empty() ) {
1113 for ( const auto& WP_fname : split( m_EG_corrFNList, "," ) ) {
1114 std::string WP = WP_fname.substr(0,WP_fname.find(":"));
1115 std::string fname = WP_fname.substr(WP_fname.find(":")+1);
1116 corrFNList[WP] = fname;
1117 ATH_MSG_WARNING( "Correction file list defined for WP " << WP << ": " << fname << "." );
1118 ATH_MSG_WARNING( "Will use correction file rather than central map file." );
1119 }
1120 }
1121
1122 // electron iso
1123 std::string EleIso("");
1124 if (std::find(eSF_keys.begin(), eSF_keys.end(), eleId+"_"+m_eleIso_WP) != eSF_keys.end()){
1125 EleIso = m_eleIso_WP;
1126 } else if (std::find(eSF_keys.begin(), eSF_keys.end(), eleId+"_"+m_el_iso_fallback[m_eleIso_WP]) != eSF_keys.end()){
1127 //--- Check to see if the only issue is an unknown isolation working point
1129 ATH_MSG_WARNING("(AsgElectronEfficiencyCorrectionTool_iso_*) Your selected electron Iso WP ("
1130 << m_eleIso_WP
1131 << ") does not have iso SFs defined. Falling back to "
1133 << " for SF calculations");
1134 }
1135 else{
1136 ATH_MSG_ERROR("*** THE ELECTRON ISOLATION SF YOU SELECTED (" << m_eleIso_WP << ") GOT NO SUPPORT ***");
1137 return StatusCode::FAILURE;
1138 }
1139
1140 toolName = "AsgElectronEfficiencyCorrectionTool_iso_" + m_eleId + EleIso;
1141
1142 // if running with correction file list
1143 if ( (!m_EG_corrFNList.empty()) && corrFNList.find(EleIso)!=corrFNList.end() ) { // overriding central map file
1144 CONFIG_EG_EFF_TOOL( m_elecEfficiencySFTool_iso, toolName, corrFNList[EleIso] );
1145 }
1146 // can't do the iso tool via the macro, it needs two properties set
1147 else { // default: use map file
1148 if ( !m_elecEfficiencySFTool_iso.isUserConfigured() ) {
1149 if ( !check_isOption(EleIso, m_el_iso_support) ) { //check if supported
1150 ATH_MSG_WARNING( "(" << toolName << ") Your electron Iso WP: " << EleIso<< " is no longer supported. This will almost certainly cause a crash now.");
1151 }
1152
1153 m_elecEfficiencySFTool_iso.setTypeAndName("AsgElectronEfficiencyCorrectionTool/"+toolName);
1154
1155 if ( m_EG_corrFNList.empty() ) {
1157 } else {
1158 ATH_CHECK( m_elecEfficiencySFTool_iso.setProperty("CorrectionFileNameList", corrFNList) );
1159 }
1160 ATH_CHECK( m_elecEfficiencySFTool_iso.setProperty("IdKey", eleId) );
1161 ATH_CHECK( m_elecEfficiencySFTool_iso.setProperty("IsoKey", EleIso) );
1162 if (!isData() && ((EleIso.find("TightTrackOnly_VarRad")!=std::string::npos)||
1163 (EleIso.find("TightTrackOnly_FixedRad")!=std::string::npos)||
1164 (EleIso.find("Tight_VarRad")!=std::string::npos)||
1165 (EleIso.find("Loose_VarRad")!=std::string::npos))) {
1166 if (isAtlfast()) ATH_MSG_WARNING("(AsgElectronEfficiencyCorrectionTool/"+toolName+"). Your selected electron Iso WP (" + EleIso + ") don't have AFII SF. Falling back to FullSim");
1167 ATH_CHECK( m_elecEfficiencySFTool_iso.setProperty("ForceDataType", static_cast<int>(PATCore::ParticleDataType::Full)));
1168 }
1169 else if (!isData()){
1170 ATH_CHECK( m_elecEfficiencySFTool_iso.setProperty("ForceDataType", static_cast<int>(data_type)));
1171 }
1172 ATH_CHECK( m_elecEfficiencySFTool_iso.setProperty("CorrelationModel", m_EG_corrModel) );
1173 ATH_CHECK( m_elecEfficiencySFTool_iso.setProperty("OutputLevel", this->msg().level()) );
1174 ATH_CHECK( m_elecEfficiencySFTool_iso.initialize() );
1175 } else ATH_CHECK( m_elecEfficiencySFTool_iso.initialize() );
1176 }
1177
1178 // electron iso high-pt
1179 std::string EleIsohighPt("");
1180 if (std::find(eSF_keys.begin(), eSF_keys.end(), eleId+"_"+m_eleIsoHighPt_WP) != eSF_keys.end()){
1181 EleIsohighPt = m_eleIsoHighPt_WP;
1182 } else if (std::find(eSF_keys.begin(), eSF_keys.end(), eleId+"_"+m_el_iso_fallback[m_eleIsoHighPt_WP]) != eSF_keys.end()){
1183 //--- Check to see if the only issue is an unknown isolation working point
1184 EleIsohighPt = m_el_iso_fallback[m_eleIsoHighPt_WP];
1185 ATH_MSG_WARNING("(AsgElectronEfficiencyCorrectionTool_iso_*) Your selected high-pT electron Iso WP ("
1187 << ") does not have iso SFs defined. Falling back to "
1189 << " for SF calculations");
1190 }
1191 else{
1192 ATH_MSG_ERROR("*** THE HIGH PT ELECTRON ISOLATION SF YOU SELECTED (" << m_eleIsoHighPt_WP << ") GOT NO SUPPORT");
1193 return StatusCode::FAILURE;
1194 }
1195
1196 toolName = "AsgElectronEfficiencyCorrectionTool_isoHigPt_" + m_eleId + EleIsohighPt;
1197
1198 // if running with correction file list
1199 if ( (!m_EG_corrFNList.empty()) && corrFNList.find(EleIsohighPt)!=corrFNList.end() ) { // overriding central map file
1200 CONFIG_EG_EFF_TOOL( m_elecEfficiencySFTool_isoHighPt, toolName, corrFNList[EleIsohighPt] );
1201 }
1202 // can't do the iso tool via the macro, it needs two properties set
1203 else { // default: use map file
1204 if ( !m_elecEfficiencySFTool_isoHighPt.isUserConfigured() ) {
1205
1206 if ( !check_isOption(EleIsohighPt, m_el_iso_support) ) { //check if supported
1207 ATH_MSG_WARNING( "(" << toolName << ") Your electron high-pt Iso WP: " << EleIsohighPt << " is no longer supported. This will almost certainly cause a crash now.");
1208 }
1209
1210 m_elecEfficiencySFTool_isoHighPt.setTypeAndName("AsgElectronEfficiencyCorrectionTool/"+toolName);
1211
1213 ATH_CHECK( m_elecEfficiencySFTool_isoHighPt.setProperty("IdKey", eleId) );
1214 ATH_CHECK( m_elecEfficiencySFTool_isoHighPt.setProperty("IsoKey", EleIsohighPt) );
1215 if (!isData()) {
1216 ATH_CHECK (m_elecEfficiencySFTool_isoHighPt.setProperty("ForceDataType", (int) data_type) );
1217 }
1218 ATH_CHECK( m_elecEfficiencySFTool_isoHighPt.setProperty("CorrelationModel", m_EG_corrModel) );
1219 ATH_CHECK( m_elecEfficiencySFTool_isoHighPt.setProperty("OutputLevel", this->msg().level()) );
1221 } else ATH_CHECK( m_elecEfficiencySFTool_isoHighPt.initialize() );
1222 }
1223
1224 // electron triggers - first SFs (but we need to massage the id string since all combinations are not supported)
1225
1226 //single lepton
1227
1228 if(m_isRun3 && eleId.find("LooseBLayer") != std::string::npos) ATH_MSG_WARNING("Replacing 'LooseBLayer' with 'Loose' for Electron ID while configuring single-ele trigger SF using: " << m_eleEffMapFilePath);
1229 std::string triggerEleID = m_isRun3? TString(eleId).ReplaceAll("LooseBLayer", "Loose").Data() : eleId;
1230 std::string triggerEleIso= m_eleIso_WP;
1231
1232 // This is an hack to work with ElectronEfficiencyCorrection/2015_2025/rel22.2/2022_Summer_Prerecom_v1/map4.txt to allow
1233
1235 bool pass_isRun3TrigSFFallback = true;
1236 if (triggerEleID.find("Medium") != std::string::npos && triggerEleIso.find("Loose") != std::string::npos) {triggerEleID = "LooseBLayer";}
1237 else if (triggerEleID.find("Medium") != std::string::npos && triggerEleIso.find("Tight") != std::string::npos) {triggerEleID = "Tight"; triggerEleIso = "Tight_VarRad";}
1238 else if (triggerEleID.find("Medium") != std::string::npos && triggerEleIso.find("HighPtCaloOnly") != std::string::npos) {triggerEleID = "Tight"; triggerEleIso = "Tight_VarRad";}
1239 else if (triggerEleID.find("Tight") != std::string::npos && triggerEleIso.find("Loose") != std::string::npos) {triggerEleID = "LooseBLayer";}
1240 else if (triggerEleID.find("Tight") != std::string::npos && triggerEleIso.find("Tight") != std::string::npos) {triggerEleIso= "Tight_VarRad";}
1241 else if (triggerEleID.find("Tight") != std::string::npos && triggerEleIso.find("HighPtCaloOnly") != std::string::npos) {triggerEleID = "Tight"; triggerEleIso = "Tight_VarRad";}
1242 else if (triggerEleID.find("Loose") != std::string::npos && triggerEleIso.find("Tight") != std::string::npos) {triggerEleID = "LooseBLayer"; triggerEleIso = "Loose_VarRad";}
1243 else if (triggerEleID.find("Loose") != std::string::npos && triggerEleIso.find("HighPtCaloOnly") != std::string::npos) {triggerEleID = "LooseBLayer"; triggerEleIso = "Loose_VarRad";}
1244 else {pass_isRun3TrigSFFallback=false;}
1245 if(pass_isRun3TrigSFFallback){
1246 ATH_MSG_INFO(" ************** This is only for testing/studying purpose! ************** ");
1247 ATH_MSG_INFO(" ************** For official recommendation, please get in contact with the SUSY Bkg Forum ************** ");
1248 ATH_MSG_INFO("In the current map ("<<m_eleEffMapFilePath<<"), the only supported Electron ID working-points supported for Electron Trigger Scale Factor are 'Loose_Loose_VarRad' and 'Tight_Tight_VarRad' ");
1249 ATH_MSG_INFO("Only for single-lepton trigger scale factor, fall back to Electron ID: -> "<< triggerEleID << " with Isolation: " << triggerEleIso);
1250 }
1251 }
1252
1253 // The L1 seed changed from 2023 and beyond, so we need to adjust the trigger key accordingly, the SF are now derived by year so we need to change the year in the key as well.
1254
1255 if(m_isRun3){
1256 // Find year positions (or npos if not present)
1257 size_t p22 = m_electronTriggerSFStringSingle.find("2022");
1258 size_t p23 = m_electronTriggerSFStringSingle.find("2023");
1259 size_t p24 = m_electronTriggerSFStringSingle.find("2024");
1260
1261 auto next_pos = [&](size_t self) {
1262 size_t next = std::string::npos;
1263
1264 if (self == p22) {
1265 if (p23 > self && p23 < next) next = p23;
1266 if (p24 > self && p24 < next) next = p24;
1267 }
1268 else if (self == p23) {
1269 if (p22 > self && p22 < next) next = p22;
1270 if (p24 > self && p24 < next) next = p24;
1271 }
1272 else if (self == p24) {
1273 if (p22 > self && p22 < next) next = p22;
1274 if (p23 > self && p23 < next) next = p23;
1275 }
1276
1277 return next;
1278 };
1279 std::string SFStringSingle22="";
1280 std::string SFStringSingle23="";
1281 std::string SFStringSingle24="";
1282
1283 // Extract 2022,2023,2025 block
1284 if (p22 != std::string::npos) {size_t end = next_pos(p22); SFStringSingle22 = m_electronTriggerSFStringSingle.substr(p22, end - p22);}
1285 if (p23 != std::string::npos) {size_t end = next_pos(p23); SFStringSingle23 = m_electronTriggerSFStringSingle.substr(p23, end - p23);}
1286 if (p24 != std::string::npos) {size_t end = next_pos(p24); SFStringSingle24 = m_electronTriggerSFStringSingle.substr(p24, end - p24);}
1287
1288 // Remove trailing underscores from tokens if present
1289 std::string* toks[] = { &SFStringSingle22, &SFStringSingle23, &SFStringSingle24 };
1290 for (auto t : toks) {
1291 while (!t->empty() && t->back() == '_') t->pop_back();
1292 }
1293
1294 if(m_mcCampaign == "mc23a") m_electronTriggerSFStringSingle = SFStringSingle22;
1295 else if(m_mcCampaign == "mc23d") m_electronTriggerSFStringSingle = SFStringSingle23;
1296 else if(m_mcCampaign == "mc23e") m_electronTriggerSFStringSingle = SFStringSingle24;
1297 else {
1298 ATH_MSG_WARNING("Unknown or unsupported mcCampaign for Run 3: " << m_mcCampaign << ". Please contact the SUSY Bkg Forum for assistance.");
1299 ATH_MSG_WARNING("Falling back to 2024 trigger SFs for single-electron triggers.");
1300 m_electronTriggerSFStringSingle = SFStringSingle24;
1301 }
1302 }
1303
1304
1305 ATH_MSG_INFO("eSF_keys: " << m_electronTriggerSFStringSingle<< "_"<<triggerEleID<<"_"<<triggerEleIso);
1306
1307 if (std::find(eSF_keys.begin(), eSF_keys.end(), m_electronTriggerSFStringSingle+"_"+triggerEleID+"_"+triggerEleIso) != eSF_keys.end()){
1308 triggerEleIso = m_eleIso_WP;
1309 } else if (std::find(eSF_keys.begin(), eSF_keys.end(), m_electronTriggerSFStringSingle+"_"+triggerEleID+"_"+m_el_iso_fallback[triggerEleIso]) != eSF_keys.end()){
1310 //--- Check to see if the only issue is an unknown isolation working point
1311 triggerEleIso = m_el_iso_fallback[triggerEleIso];
1312 ATH_MSG_WARNING("(AsgElectronEfficiencyCorrectionTool_trig_singleLep_*) Your selected electron Iso WP ("
1313 << m_eleIso_WP
1314 << ") does not have trigger SFs defined. Falling back to "
1315 << triggerEleIso
1316 << " for SF calculations");
1317 }
1318 else{
1319 ATH_MSG_ERROR("*** THE SINGLE ELECTRON TRIGGER SF YOU SELECTED (" << m_electronTriggerSFStringSingle << ") GOT NO SUPPORT FOR YOUR ID+ISO WPs (" << m_eleId << "+" << m_eleIso_WP << ") ***");
1320 return StatusCode::FAILURE;
1321 }
1322
1323 toolName = "AsgElectronEfficiencyCorrectionTool_trig_singleLep_" + triggerEleID;
1324 if ( !m_elecEfficiencySFTool_trig_singleLep.isUserConfigured() ) {
1325 m_elecEfficiencySFTool_trig_singleLep.setTypeAndName("AsgElectronEfficiencyCorrectionTool/"+toolName);
1328 ATH_CHECK( m_elecEfficiencySFTool_trig_singleLep.setProperty("IdKey", triggerEleID) );
1329 ATH_CHECK( m_elecEfficiencySFTool_trig_singleLep.setProperty("IsoKey", triggerEleIso) );
1330 ATH_CHECK( m_elecEfficiencySFTool_trig_singleLep.setProperty("CorrelationModel", m_EG_corrModel) );
1331 if (!isData()) {
1332 ATH_CHECK( m_elecEfficiencySFTool_trig_singleLep.setProperty("ForceDataType", (int) (data_type==PATCore::ParticleDataType::Fast)? PATCore::ParticleDataType::Full : data_type) );
1333 }
1334 ATH_CHECK( m_elecEfficiencySFTool_trig_singleLep.setProperty("OutputLevel", this->msg().level()) );
1337
1338
1339 toolName = "AsgElectronEfficiencyCorrectionTool_trigEff_singleLep_" + triggerEleID;
1340 if ( !m_elecEfficiencySFTool_trigEff_singleLep.isUserConfigured() ) {
1341 m_elecEfficiencySFTool_trigEff_singleLep.setTypeAndName("AsgElectronEfficiencyCorrectionTool/"+toolName);
1344 ATH_CHECK( m_elecEfficiencySFTool_trigEff_singleLep.setProperty("IdKey", triggerEleID) );
1345 ATH_CHECK( m_elecEfficiencySFTool_trigEff_singleLep.setProperty("IsoKey", triggerEleIso) );
1346 ATH_CHECK( m_elecEfficiencySFTool_trigEff_singleLep.setProperty("CorrelationModel", m_EG_corrModel) );
1347 if (!isData()) {
1348 ATH_CHECK( m_elecEfficiencySFTool_trigEff_singleLep.setProperty("ForceDataType", (int) (data_type==PATCore::ParticleDataType::Fast)? PATCore::ParticleDataType::Full : data_type) );
1349 }
1350 ATH_CHECK( m_elecEfficiencySFTool_trigEff_singleLep.setProperty("OutputLevel", this->msg().level()) );
1353
1354 if (!m_isRun3){
1355 //mixed-leptons
1356 std::map<std::string,std::string> electronTriggerSFMapMixedLepton {
1357 // legs, Trigger keys,
1358 {"e24_lhmedium_L1EM20VH_OR_e60_lhmedium_OR_e120_lhloose,e26_lhtight_nod0_ivarloose_OR_e60_lhmedium_nod0_OR_e140_lhloose_nod0", m_electronTriggerSFStringSingle},
1359 {"e24_lhvloose_nod0_L1EM20VH,e17_lhvloose_nod0,e12_lhloose_L1EM10VH","DI_E_2015_e12_lhloose_L1EM10VH_2016_e17_lhvloose_nod0_2017_2018_e24_lhvloose_nod0_L1EM20VH"},
1360 {"e26_lhmedium_nod0_L1EM22VHI,e26_lhmedium_nod0","MULTI_L_2015_e24_lhmedium_L1EM20VH_OR_e60_lhmedium_OR_e120_lhloose_2016_e26_lhmedium_nod0_L1EM22VHI_2017_2018_e26_lhmedium_nod0"},
1361 {"e17_lhloose,e17_lhloose_nod0","MULTI_L_2015_e17_lhloose_2016_2018_e17_lhloose_nod0"},
1362 {"e12_lhloose,e12_lhloose_nod0","MULTI_L_2015_e12_lhloose_2016_2018_e12_lhloose_nod0"},
1363 {"e7_lhmedium,e7_lhmedium_nod0","MULTI_L_2015_e7_lhmedium_2016_2018_e7_lhmedium_nod0"},
1364 {"e9_lhloose,e9_lhloose_nod0,e12_lhvloose_nod0_L1EM10VH","TRI_E_2015_e9_lhloose_2016_e9_lhloose_nod0_2017_2018_e12_lhvloose_nod0_L1EM10VH"}
1365
1366 };
1367
1368 // 2e17 trigger is used in 2017 or 2018?
1370 if (triglist_2017to2018.find("2e17_lhvloose_nod0_L12EM15VHI") != std::string::npos) {
1371 electronTriggerSFMapMixedLepton["e17_lhvloose_nod0_L1EM15VHI"] = "DI_E_2015_e12_lhloose_L1EM10VH_2016_e17_lhvloose_nod0_2017_2018_e17_lhvloose_nod0_L1EM15VHI";
1372 }
1373
1374 std::string triggerMixedEleIso("");
1375
1376 for(auto const& item : electronTriggerSFMapMixedLepton){
1377
1378 if (std::find(eSF_keys.begin(), eSF_keys.end(), item.second+"_"+eleId+"_"+m_eleIso_WP) != eSF_keys.end()){
1379 triggerMixedEleIso = m_eleIso_WP;
1380 } else if (std::find(eSF_keys.begin(), eSF_keys.end(), item.second+"_"+eleId+"_"+m_el_iso_fallback[m_eleIso_WP]) != eSF_keys.end()){
1381 //--- Check to see if the only issue is an unknown isolation working point
1382 triggerMixedEleIso = m_el_iso_fallback[m_eleIso_WP];
1383 ATH_MSG_WARNING("(AsgElectronEfficiencyCorrectionTool_trig_mixLep_*) Your selected electron Iso WP ("
1384 << m_eleIso_WP
1385 << ") does not have trigger SFs defined. Falling back to "
1386 << triggerMixedEleIso
1387 << " for SF calculations");
1388 } else {
1389 ATH_MSG_ERROR("*** THE MIXED ELECTRON TRIGGER SF YOU SELECTED (" << item.second << ") GOT NO SUPPORT FOR YOUR ID+ISO WPs (" << m_eleId << "+" << m_eleIso_WP << "). The fallback options failed as well sorry! ***");
1390 return StatusCode::FAILURE;
1391 }
1392
1393 ATH_MSG_VERBOSE ("Selected WP: " << item.second << "_" << eleId << "_" << triggerMixedEleIso);
1394
1395 toolName = "AsgElectronEfficiencyCorrectionTool_trig_mixLep_" + (item.first).substr(0,8) + m_eleId;
1396 auto t_sf = m_elecEfficiencySFTool_trig_mixLep.emplace(m_elecEfficiencySFTool_trig_mixLep.end(), "AsgElectronEfficiencyCorrectionTool/"+toolName);
1397 ATH_CHECK( t_sf->setProperty("MapFilePath", m_isRun3? m_eleEffMapFilePath : m_eleEffMapFilePathRun2) );
1398 ATH_CHECK( t_sf->setProperty("TriggerKey", item.second) );
1399 ATH_CHECK( t_sf->setProperty("IdKey", eleId) );
1400 ATH_CHECK( t_sf->setProperty("IsoKey", triggerMixedEleIso) );
1401 ATH_CHECK( t_sf->setProperty("CorrelationModel", m_EG_corrModel) );
1402 if (!isData()) {
1403 ATH_CHECK( t_sf->setProperty("ForceDataType", (int) (data_type==PATCore::ParticleDataType::Fast)? PATCore::ParticleDataType::Full : data_type) );
1404 }
1405 ATH_CHECK( t_sf->setProperty("OutputLevel", this->msg().level()) );
1406 ATH_CHECK( t_sf->initialize() );
1407 m_elecTrigSFTools.push_back(t_sf->getHandle());
1408 #ifndef XAOD_STANDALONE
1409 m_legsPerTool[toolName] = item.first;
1410 #else
1411 m_legsPerTool["ToolSvc."+toolName] = item.first;
1412 #endif
1413
1414 toolName = "AsgElectronEfficiencyCorrectionTool_trigEff_mixLep_" + (item.first).substr(0,8) + m_eleId;
1415 auto t_eff = m_elecEfficiencySFTool_trigEff_mixLep.emplace(m_elecEfficiencySFTool_trigEff_mixLep.end(), "AsgElectronEfficiencyCorrectionTool/"+toolName);
1416 ATH_CHECK( t_eff->setProperty("MapFilePath", m_isRun3? m_eleEffMapFilePath : m_eleEffMapFilePathRun2) );
1417 ATH_CHECK( t_eff->setProperty("TriggerKey", "Eff_"+item.second) );
1418 ATH_CHECK( t_eff->setProperty("IdKey", eleId) );
1419 ATH_CHECK( t_eff->setProperty("IsoKey", triggerMixedEleIso) );
1420 ATH_CHECK( t_eff->setProperty("CorrelationModel", m_EG_corrModel) );
1421 if (!isData()) {
1422 ATH_CHECK( t_eff->setProperty("ForceDataType", (int) (data_type==PATCore::ParticleDataType::Fast)? PATCore::ParticleDataType::Full : data_type) );
1423 }
1424 ATH_CHECK( t_eff->setProperty("OutputLevel", this->msg().level()) );
1425 ATH_CHECK( t_eff->initialize() );
1426 m_elecTrigEffTools.push_back(t_eff->getHandle());
1427 #ifndef XAOD_STANDALONE
1428 m_legsPerTool[toolName] = item.first;
1429 #else
1430 m_legsPerTool["ToolSvc."+toolName] = item.first;
1431 #endif
1432
1433 }
1434 }
1435 else ATH_MSG_WARNING("*** THE ELECTRON TRIGGER SF MIXED AND SF DILEP ARE CURRENTY NOT SUPPORTED IN RUN3 ***");
1436
1437 ATH_MSG_WARNING("*** THE ELECTRON CHARGE FLIP SF ARE CURRENTY NOT SUPPORTED ***");
1438 // all the iinitialisation of the related tools have been cleaned up
1439
1440 }
1441
1442 if (m_slices["pho"]) {
1443 // /////////////////////////////////////////////////////////////////////////////////////////
1444 // Initialise photon efficiency tool
1445
1446 if (!m_photonEfficiencySFTool.isUserConfigured() && !isData()) {
1447 m_photonEfficiencySFTool.setTypeAndName("AsgPhotonEfficiencyCorrectionTool/AsgPhotonEfficiencyCorrectionTool_" + m_photonId);
1448
1449 if (m_photonId != "Tight" ) {
1450 ATH_MSG_WARNING( "No Photon efficiency available for " << m_photonId << ", using Tight instead..." );
1451 }
1452
1453 ATH_CHECK( m_photonEfficiencySFTool.setProperty("MapFilePath", "PhotonEfficiencyCorrection/2015_2025/rel22.2/2024_FinalRun2_Recommendation_v1/map1.txt") );
1454 ATH_CHECK( m_photonEfficiencySFTool.setProperty("ForceDataType", isAtlfast()? (m_isRun3? 1: 3) : 1) ); // Set data type: 1 for FULLSIM, 3 for AtlFast. For Run3 pre-rec only FullSim SFs are available
1455 ATH_CHECK( m_photonEfficiencySFTool.setProperty("OutputLevel", this->msg().level()) );
1456 ATH_CHECK( m_photonEfficiencySFTool.retrieve() );
1457 } else if (m_photonEfficiencySFTool.isUserConfigured()) ATH_CHECK( m_photonEfficiencySFTool.retrieve() );
1458
1459 if (!m_photonIsolationSFTool.isUserConfigured() && !isData()) {
1460 m_photonIsolationSFTool.setTypeAndName("AsgPhotonEfficiencyCorrectionTool/AsgPhotonEfficiencyCorrectionTool_isol" + m_photonIso_WP);
1461
1462 if (m_photonIso_WP != "FixedCutTight" && m_photonIso_WP != "FixedCutLoose" && m_photonIso_WP != "TightCaloOnly") {
1463 ATH_MSG_WARNING( "No Photon efficiency available for " << m_photonIso_WP);
1464 }
1465
1466 ATH_CHECK( m_photonIsolationSFTool.setProperty("MapFilePath", "PhotonEfficiencyCorrection/2015_2025/rel22.2/2022_Summer_Prerecom_v1/map1.txt") );
1467 ATH_CHECK( m_photonIsolationSFTool.setProperty("IsoKey", m_photonIso_WP != "TightCaloOnly" ? m_photonIso_WP.substr(8) : m_photonIso_WP )); // Set isolation WP: Loose,Tight,TightCaloOnly
1468 ATH_CHECK( m_photonIsolationSFTool.setProperty("ForceDataType", 1) ); // Set data type: 1 for FULLSIM, 3 for AF2
1469 ATH_CHECK( m_photonIsolationSFTool.setProperty("OutputLevel", this->msg().level()) );
1470 ATH_CHECK( m_photonIsolationSFTool.retrieve() );
1471 } else if (m_photonEfficiencySFTool.isUserConfigured()) ATH_CHECK( m_photonIsolationSFTool.retrieve() );
1472
1473 // trigger scale factors
1474 if (!m_photonTriggerSFTool.isUserConfigured() && !isData()) {
1475 m_photonTriggerSFTool.setTypeAndName("AsgPhotonEfficiencyCorrectionTool/AsgPhotonEfficiencyCorrectionTool_trig" + m_photonTriggerName);
1476
1477 // Fallback to TightCaloOnly if Tight is selected
1478 std::string photonIso_forTrigSF = m_photonIso_WP;
1479 if (m_photonIso_WP == "FixedCutTight") {
1480 ATH_MSG_WARNING( "No Photon trigger SF available for " << m_photonIso_WP << ", using TightCaloOnly instead... Use at your own risk" );
1481 photonIso_forTrigSF = "TightCaloOnly";
1482 } else { // isolation WP supported: Loose or TightCaloOnly, removing "FixedCut" suffix..
1483 photonIso_forTrigSF = TString(m_photonIso_WP).ReplaceAll("FixedCut","").Data();
1484 }
1485
1486 // "symmetric" diphoton triggers (year dependent)
1487 ATH_CHECK( m_photonTriggerSFTool.setProperty("MapFilePath", "PhotonEfficiencyCorrection/2015_2018/rel21.2/Summer2020_Rec_v1/map3.txt") );
1488 ATH_CHECK( m_photonTriggerSFTool.setProperty("IsoKey", photonIso_forTrigSF )); // Set isolation WP: Loose,TightCaloOnly
1489 ATH_CHECK( m_photonTriggerSFTool.setProperty("TriggerKey", m_photonTriggerName ));
1490 ATH_CHECK( m_photonTriggerSFTool.setProperty("ForceDataType", 1) ); // Set data type: 1 for FULLSIM, 3 for AF2
1491 ATH_CHECK( m_photonTriggerSFTool.setProperty("OutputLevel", this->msg().level()) );
1492 ATH_CHECK( m_photonTriggerSFTool.retrieve() );
1493
1494 // "asymmetric" diphoton triggers
1495 std::map<std::string,std::string> diphotonTriggerSFMapAsymmetric {
1496 // legs, Trigger keys,
1497 {"g25_loose,g25_medium_L1EM20VH", "DI_PH_2015_g25_loose_2016_g25_loose_2017_g25_medium_L1EM20VH_2018_g25_medium_L1EM20VH"},
1498 {"g35_loose,g35_medium_L1EM20VH", "DI_PH_2015_g35_loose_2016_g35_loose_2017_g35_medium_L1EM20VH_2018_g35_medium_L1EM20VH"},
1499 };
1500
1501 for(auto const& item : diphotonTriggerSFMapAsymmetric){
1502
1503 toolName = "AsgPhotonEfficiencyCorrectionTool_trigSF_asymm_diphoton_" + (item.first).substr(0,9) + photonIso_forTrigSF;
1504 auto ph_trigSF = m_photonEfficiencySFTool_trigSF_AsymDiphoton.emplace(m_photonEfficiencySFTool_trigSF_AsymDiphoton.end(), "AsgPhotonEfficiencyCorrectionTool/"+toolName);
1505 ATH_CHECK( ph_trigSF->setProperty("MapFilePath", "PhotonEfficiencyCorrection/2015_2018/rel21.2/Summer2020_Rec_v1/map3.txt") );
1506 ATH_CHECK( ph_trigSF->setProperty("IsoKey", photonIso_forTrigSF) );
1507 ATH_CHECK( ph_trigSF->setProperty("TriggerKey", item.second) );
1508 ATH_CHECK( ph_trigSF->setProperty("ForceDataType", 1) ); // Set DataType: 1 for FullSim and 3 for AFII
1509 ATH_CHECK( ph_trigSF->setProperty("OutputLevel", this->msg().level()) );
1510 ATH_CHECK( ph_trigSF->initialize() );
1511 m_photonTrigSFTools.push_back(ph_trigSF->getHandle());
1512 #ifndef XAOD_STANDALONE
1513 m_legsPerTool_ph[toolName] = item.first;
1514 #else
1515 m_legsPerTool_ph["ToolSvc."+toolName] = item.first;
1516 #endif
1517
1518 toolName = "AsgPhotonEfficiencyCorrectionTool_trigEff_asymm_diphoton_" + (item.first).substr(0,9) + photonIso_forTrigSF;
1519 auto ph_trigEff = m_photonEfficiencySFTool_trigEff_AsymDiphoton.emplace(m_photonEfficiencySFTool_trigEff_AsymDiphoton.end(), "AsgPhotonEfficiencyCorrectionTool/"+toolName);
1520 ATH_CHECK( ph_trigEff->setProperty("MapFilePath", "PhotonEfficiencyCorrection/2015_2018/rel21.2/Summer2020_Rec_v1/map3.txt") );
1521 ATH_CHECK( ph_trigEff->setProperty("IsoKey", photonIso_forTrigSF) );
1522 ATH_CHECK( ph_trigEff->setProperty("TriggerKey", "Eff_"+item.second) );
1523 ATH_CHECK( ph_trigEff->setProperty("ForceDataType", 1) ); // Set DataType: 1 for FullSim and 3 for AFII
1524 ATH_CHECK( ph_trigEff->setProperty("OutputLevel", this->msg().level()) );
1525 ATH_CHECK( ph_trigEff->initialize() );
1526 m_photonTrigEffTools.push_back(ph_trigEff->getHandle());
1527 #ifndef XAOD_STANDALONE
1528 m_legsPerTool_ph[toolName] = item.first;
1529 #else
1530 m_legsPerTool_ph["ToolSvc."+toolName] = item.first;
1531 #endif
1532
1533 }
1534 }
1535 }
1536
1537 }
1538 if (m_slices["ele"] || m_slices["pho"]) {
1540 // Initialize the EgammaAmbiguityTool
1541
1542 if (!m_egammaAmbiguityTool.isUserConfigured()) {
1543 m_egammaAmbiguityTool.setTypeAndName("EGammaAmbiguityTool/EGammaAmbiguityTool");
1544 ATH_CHECK( m_egammaAmbiguityTool.setProperty("OutputLevel", this->msg().level()) );
1545 ATH_CHECK( m_egammaAmbiguityTool.retrieve() );
1546 } else ATH_CHECK( m_egammaAmbiguityTool.retrieve() );
1547 }
1548
1549
1550 if (m_slices["ele"]) {
1551 //disable ///////////////////////////////////////////////////////////////////////////////////////////
1552 //disable // Initialize the AsgElectronChargeIDSelector
1553
1554 //disable if (!m_elecChargeIDSelectorTool.isUserConfigured()) {
1555
1556 //disable // For the selector, can use the nice function
1557 //disable std::string eleId = EG_WP(m_eleId);
1558 //disable m_elecChargeIDSelectorTool.setTypeAndName("AsgElectronChargeIDSelectorTool/ElectronChargeIDSelectorTool_"+eleId);
1559 //disable //default cut value for https://twiki.cern.ch/twiki/bin/view/AtlasProtected/ElectronChargeFlipTaggerTool
1560 //disable float BDTcut = -0.337671; // Loose 97%
1561 //disable if (m_eleChID_WP != "Loose" && !m_eleChID_WP.empty()) {
1562 //disable ATH_MSG_ERROR("Only Loose WP is supported in R21. Invalid ChargeIDSelector WP selected : " << m_eleChID_WP);
1563 //disable return StatusCode::FAILURE;
1564 //disable }
1565
1566 //disable ATH_CHECK( m_elecChargeIDSelectorTool.setProperty("TrainingFile", "ElectronPhotonSelectorTools/ChargeID/ECIDS_20180731rel21Summer2018.root"));
1567 //disable ATH_CHECK( m_elecChargeIDSelectorTool.setProperty("CutOnBDT", BDTcut));
1568 //disable ATH_CHECK( m_elecChargeIDSelectorTool.setProperty("OutputLevel", this->msg().level()) );
1569 //disable ATH_CHECK( m_elecChargeIDSelectorTool.retrieve() );
1570 //disable } else ATH_CHECK( m_elecChargeIDSelectorTool.retrieve() );
1571
1572
1574 // Initialise egamma calibration tool
1575
1576 if (!m_egammaCalibTool.isUserConfigured()) {
1577 m_egammaCalibTool.setTypeAndName("CP::EgammaCalibrationAndSmearingTool/EgammaCalibrationAndSmearingTool");
1578 ATH_MSG_DEBUG( "Initialising EgcalibTool " );
1579 ATH_CHECK( m_egammaCalibTool.setProperty("ESModel", m_isRun3 ? "es2024_Run3_v0" : "es2023_R22_Run2_v1") );
1580 ATH_CHECK( m_egammaCalibTool.setProperty("decorrelationModel", "1NP_v1") );
1581 // allows to bypass (intended) abort from of egamma calibration tool when configured for fastSim
1583 ATH_MSG_WARNING( "Forcing EgcalibTool to use calibrations for full simulation" );
1584 ATH_CHECK( m_egammaCalibTool.setProperty("useFastSim", false) );
1585 }
1586 else {
1587 ATH_MSG_INFO("is Fast Sim:" << isAtlfast());
1588 ATH_CHECK( m_egammaCalibTool.setProperty("useFastSim", isAtlfast() ? 1 : 0) );
1589 }
1590 ATH_CHECK( m_egammaCalibTool.setProperty("OutputLevel", this->msg().level()) );
1591 ATH_CHECK( m_egammaCalibTool.retrieve() );
1592 } else ATH_CHECK( m_egammaCalibTool.retrieve() );
1593 }
1594
1595
1596 if (m_slices["tau"]) {
1598
1600 // Initialise path to tau config file and config reader
1601
1602 // Read in the config file so we can retrieve the fields later when configuring the efficiency tools
1603 if ( m_tauConfigReader.ReadFile( PathResolverFindCalibFile(m_tauInputFile).c_str(), EEnvLevel(0) ) ) {
1604 ATH_MSG_ERROR( "Error while reading tau config file : " << m_tauInputFile );
1605 return StatusCode::FAILURE;
1606 }
1607 else ATH_MSG_DEBUG( "Successfully read tau config file : " << m_tauInputFile );
1608
1609
1611 // Initialise tau selection tools
1612
1613 if (!m_tauSelTool.isUserConfigured()) {
1614 toolName = "TauSelectionTool_" + m_tauId;
1615 m_tauSelTool.setTypeAndName("TauAnalysisTools::TauSelectionTool/"+toolName);
1616 ATH_CHECK( m_tauSelTool.setProperty("ConfigPath", m_tauInputFile) );
1617 ATH_CHECK( m_tauSelTool.setProperty("OutputLevel", this->msg().level()) );
1618 ATH_CHECK( m_tauSelTool.retrieve() );
1619 } else ATH_CHECK( m_tauSelTool.retrieve() );
1620
1621
1622 if (!m_tauSelToolBaseline.isUserConfigured()) {
1623 toolName = "TauSelectionToolBaseline_" + m_tauIdBaseline;
1624 m_tauSelToolBaseline.setTypeAndName("TauAnalysisTools::TauSelectionTool/"+toolName);
1625 ATH_CHECK( m_tauSelToolBaseline.setProperty("ConfigPath", m_tauInputFileBaseline) );
1626 ATH_CHECK( m_tauSelToolBaseline.setProperty("OutputLevel", this->msg().level()) );
1627 ATH_CHECK( m_tauSelToolBaseline.retrieve() );
1628 } else ATH_CHECK( m_tauSelToolBaseline.retrieve() );
1629
1630
1632 // jetIDWP/elIDWP for efficiency tool + trigger tool
1633 std::string jetIDWP = m_tauConfigReader.GetValue("JetIDWP" ,"");
1634 ANA_MSG_DEBUG( "Found JetIDWP in tau config file : " << jetIDWP );
1635 int jet_id_lvl;
1636 // Read out the tau ID from the config file and map into the enum from tau CP
1637 if (jetIDWP == "JETIDNONE") jet_id_lvl = (int)TauAnalysisTools::JetID::JETIDNONE;
1638 else if (jetIDWP == "JETIDRNNVERYLOOSE") jet_id_lvl = (int)TauAnalysisTools::JetID::JETIDRNNVERYLOOSE;
1639 else if (jetIDWP == "JETIDRNNLOOSE") jet_id_lvl = (int)TauAnalysisTools::JetID::JETIDRNNLOOSE;
1640 else if (jetIDWP == "JETIDRNNMEDIUM") jet_id_lvl = (int)TauAnalysisTools::JetID::JETIDRNNMEDIUM;
1641 else if (jetIDWP == "JETIDRNNTIGHT") jet_id_lvl = (int)TauAnalysisTools::JetID::JETIDRNNTIGHT;
1642 else if (jetIDWP == "JETIDGNTAUVERYLOOSE") jet_id_lvl = (int)TauAnalysisTools::JetID::JETIDGNTAUVERYLOOSE;
1643 else if (jetIDWP == "JETIDGNTAULOOSE") jet_id_lvl = (int)TauAnalysisTools::JetID::JETIDGNTAULOOSE;
1644 else if (jetIDWP == "JETIDGNTAUMEDIUM") jet_id_lvl = (int)TauAnalysisTools::JetID::JETIDGNTAUMEDIUM;
1645 else if (jetIDWP == "JETIDGNTAUTIGHT") jet_id_lvl = (int)TauAnalysisTools::JetID::JETIDGNTAUTIGHT;
1646 else {
1647 ATH_MSG_ERROR("Invalid Tau ID in tau config file " << jetIDWP);
1648 return StatusCode::FAILURE;
1649 }
1650 // Read out the (optional) Ele OR from the config file and map into the enum from tau CP
1651 std::string eleIDWP = m_tauConfigReader.GetValue("EleIDWP" ,"");
1652 ANA_MSG_DEBUG( "Found EleIDWP in tau config file : " << eleIDWP );
1653 int ele_id_lvl = -1;
1654 if (eleIDWP == "ELEIDRNNLOOSE") ele_id_lvl = (int)TauAnalysisTools::EleID::ELEIDRNNLOOSE;
1655 else if (eleIDWP == "ELEIDRNNMEDIUM") ele_id_lvl = (int)TauAnalysisTools::EleID::ELEIDRNNMEDIUM;
1656 else if (eleIDWP == "ELEIDRNNTIGHT") ele_id_lvl = (int)TauAnalysisTools::EleID::ELEIDRNNTIGHT;
1657 else {
1658 ATH_MSG_INFO("No or invalid Ele OR in tau config file " << eleIDWP << " will not apply SFs for electro veto" );
1659 }
1660 if (jet_id_lvl == (int)TauAnalysisTools::JetID::JETIDRNNTIGHT || jet_id_lvl == (int)TauAnalysisTools::JetID::JETIDGNTAUTIGHT) {
1661 ATH_MSG_WARNING("EleOR with Tight TauID is currently not supported, please discuss with TauCP!");
1662 }
1663
1664 int jet_id_lvl_fb = jet_id_lvl;
1665 if (m_tau_id_fallback.count(jet_id_lvl) > 0) {
1666 jet_id_lvl_fb = m_tau_id_fallback[jet_id_lvl];
1667 ATH_MSG_WARNING("Configuring fallback RNN ID SF for GNTau config, do not use in production!");
1668 }
1669
1670
1672 // Initialise tau efficiency tool
1673
1674 // TEMPORARY: no recommendations yet for 2024+
1675 if (!m_tauEffTool.isUserConfigured() && !isData() && !(m_mcCampaign=="mc23e" || m_mcCampaign=="mc23g")) {
1676 toolName = "TauEffTool_" + m_tauId;
1677 m_tauEffTool.setTypeAndName("TauAnalysisTools::TauEfficiencyCorrectionsTool/"+toolName);
1678
1679 std::vector<int> correction_types;
1680 // Add retrieval of reco and ID SFs
1681 correction_types.insert(correction_types.end(), {TauAnalysisTools::EfficiencyCorrectionType::SFRecoHadTau,
1682 TauAnalysisTools::EfficiencyCorrectionType::SFJetIDHadTau});
1683
1684 // Add retrieval of electron veto SFs if its applied
1685 if (ele_id_lvl != -1 )
1686 correction_types.insert(correction_types.end(), {TauAnalysisTools::EfficiencyCorrectionType::SFEleIDHadTau,
1687 TauAnalysisTools::EfficiencyCorrectionType::SFEleIDElectron});
1688
1689 ATH_CHECK( m_tauEffTool.setProperty("JetIDLevel", jet_id_lvl_fb) );
1690 ATH_CHECK( m_tauEffTool.setProperty("EleIDLevel", ele_id_lvl) );
1691 ATH_CHECK( m_tauEffTool.setProperty("EfficiencyCorrectionTypes", correction_types) );
1692 ATH_CHECK( m_tauEffTool.setProperty("OutputLevel", this->msg().level()) );
1693 ATH_CHECK( m_tauEffTool.setProperty("useFastSim", isAtlfast()) );
1694 ATH_CHECK( m_tauEffTool.setProperty("RecommendationTag", m_tauEffToolRecommendationTag) );
1695 if (m_isRun3){ ATH_CHECK( m_tauEffTool.setProperty("Campaign", "mc23") );}
1696 else { ATH_CHECK( m_tauEffTool.setProperty("Campaign", "mc20") );}
1697 ATH_CHECK( m_tauEffTool.retrieve() );
1698 } else if (m_tauEffTool.isUserConfigured()) ATH_CHECK( m_tauEffTool.retrieve() );
1699
1700
1702 // Initialise tau trigger efficiency tool(s)
1703
1704 // TEMPORARY: no recommendations yet for 2024+
1705 if (!isData() && !(m_mcCampaign=="mc23e" || m_mcCampaign=="mc23g")) {
1706 // map format: SF file name, corresponding single-tau leg (comma-separated in case of OR)
1708 {"HLT_tau25_medium1_tracktwo", "HLT_tau25_medium1_tracktwo"},
1709 {"HLT_tau35_medium1_tracktwo", "HLT_tau35_medium1_tracktwo"},
1710 {"HLT_tau50L1TAU12_medium1_tracktwo", "HLT_tau50_medium1_tracktwo_L1TAU12"},
1711 {"HLT_tau60_medium1_tracktwo", "HLT_tau60_medium1_tracktwo"},
1712 {"HLT_tau80L1TAU60_medium1_tracktwo", "HLT_tau80_medium1_tracktwo_L1TAU60"},
1713 {"HLT_tau125_medium1_tracktwo", "HLT_tau125_medium1_tracktwo"},
1714 {"HLT_tau160_medium1_tracktwo", "HLT_tau160_medium1_tracktwo"},
1715 {"HLT_tau160L1TAU100_medium1_tracktwo", "HLT_tau160_medium1_tracktwo_L1TAU100"},
1716 // whole 2018 data taking period
1717 {"HLT_tau25_medium1_tracktwoEF", "HLT_tau25_medium1_tracktwoEF"},
1718 {"HLT_tau35_medium1_tracktwoEF", "HLT_tau35_medium1_tracktwoEF"},
1719 {"HLT_tau60_medium1_tracktwoEF", "HLT_tau60_medium1_tracktwoEF"},
1720 {"HLT_tau80L1TAU60_medium1_tracktwoEF", "HLT_tau80_medium1_tracktwoEF_L1TAU60"},
1721 {"HLT_tau160L1TAU100_medium1_tracktwoEF", "HLT_tau160_medium1_tracktwoEF_L1TAU100"},
1722 };
1723
1724 if (m_isRun3){
1726 // 2024,2025,2026
1727 // TBA
1728 // 2022, 2023
1729 {"HLT_tau25_mediumRNN_tracktwoMVA", "HLT_tau25_mediumRNN_tracktwoMVA"},
1730 {"HLT_tau35_mediumRNN_tracktwoMVA", "HLT_tau35_mediumRNN_tracktwoMVA"},
1731 // 2022, 2023 75-1800 bunches
1732 {"HLT_tau160_mediumRNN_tracktwoMVA", "HLT_tau160_mediumRNN_tracktwoMVA_L1TAU100"},
1733 // 2023 from 400 bunches
1734 {"HLT_tau160_mediumRNN_tracktwoMVA", "HLT_tau160_mediumRNN_tracktwoMVA_L1eTAU140"}
1735 };
1736 }
1737
1738 for(auto const& trigger : m_tau_trig_support) {
1739 toolName = "TauTrigEffTool_" + m_tauId + "_" + trigger.first;
1740 auto tau_trigSF = m_tauTrigEffTool.emplace(m_tauTrigEffTool.end(), "TauAnalysisTools::TauEfficiencyCorrectionsTool/"+toolName);
1741 ATH_CHECK( tau_trigSF->setProperty("EfficiencyCorrectionTypes", std::vector<int>({TauAnalysisTools::SFTriggerHadTau})) );
1742 ATH_CHECK( tau_trigSF->setProperty("TriggerName", trigger.first) );
1743 ATH_CHECK( tau_trigSF->setProperty("JetIDLevel", jet_id_lvl_fb) );
1744 ATH_CHECK( tau_trigSF->setProperty("EleIDLevel", ele_id_lvl) );
1745 ATH_CHECK( tau_trigSF->setProperty("OutputLevel", this->msg().level()) );
1746 ATH_CHECK( tau_trigSF->setProperty("useFastSim", isAtlfast()) );
1747 ATH_CHECK( tau_trigSF->setProperty("RecommendationTag", m_tauEffToolRecommendationTag) );
1748 if (m_isRun3){ ATH_CHECK( tau_trigSF->setProperty("Campaign", m_mcCampaign) );}
1749 else { ATH_CHECK( tau_trigSF->setProperty("Campaign", "mc20") );}
1750 ATH_CHECK( tau_trigSF->initialize() );
1751 }
1752 }
1753
1754
1756 // Initialise tau smearing tool
1757
1758 if (!m_tauSmearingTool.isUserConfigured()) {
1759 m_tauSmearingTool.setTypeAndName("TauAnalysisTools::TauSmearingTool/TauSmearingTool");
1760 ATH_CHECK( m_tauSmearingTool.setProperty("RecommendationTag", m_tauSmearingToolRecommendationTag) );
1761 if (m_isRun3){ ATH_CHECK( m_tauSmearingTool.setProperty("Campaign", "mc23") );}
1762 else { ATH_CHECK( m_tauSmearingTool.setProperty("Campaign", "mc20") );}
1763 ATH_CHECK( m_tauSmearingTool.setProperty("MVATESQualityCheck", m_ApplyMVATESQualityCheck) );
1764 ATH_CHECK( m_tauSmearingTool.setProperty("useFastSim", isAtlfast()) );
1765 ATH_CHECK( m_tauSmearingTool.setProperty("OutputLevel", this->msg().level()) );
1766 ATH_CHECK( m_tauSmearingTool.retrieve() );
1767 } else ATH_CHECK( m_tauSmearingTool.retrieve() );
1768
1769
1771 // Initialise tau truth matching tool
1772
1773 if (!m_tauTruthMatch.isUserConfigured() && m_tauDoTTM && !isData()) {
1774 m_tauTruthMatch.setTypeAndName("TauAnalysisTools::TauTruthMatchingTool/TauTruthMatch");
1775 ATH_CHECK( m_tauTruthMatch.setProperty("TruthJetContainerName", m_defaultTruthJets ) );
1776 ATH_CHECK( m_tauTruthMatch.setProperty("OutputLevel", this->msg().level()) );
1777 ATH_CHECK( m_tauTruthMatch.retrieve() );
1778 } else if (m_tauTruthMatch.isUserConfigured()) ATH_CHECK( m_tauTruthMatch.retrieve() );
1779
1780
1781 }
1782
1783
1784 if (m_slices["bjet"]) {
1786 // Initialise B-tagging tools
1787
1788 // btagSelectionTool
1789 std::string jetcollBTag = jetcoll;
1790 if (jetcoll == "AntiKt4LCTopoJets") {
1791 ATH_MSG_WARNING(" *** HACK *** Treating LCTopoJets jets as EMTopo -- use at your own risk!");
1792 jetcollBTag = "AntiKt4EMTopoJets";
1793 }
1794
1795 // print a warning if there is indication that the user supplied a CDI file not matching to the sample being processed
1796 // see --> https://twiki.cern.ch/twiki/bin/view/AtlasProtected/BTagRel22HighLevelSummary
1797 if( (m_bTaggingCalibrationFilePath.find(!m_isRun3 ? "MC20" : "MC23") == std::string::npos) && (m_bTaggingCalibrationFilePath.find(!m_isRun3 ? "MC20" : "MC21") == std::string::npos) ) {
1798 ATH_MSG_WARNING( "You are using a "<<(!m_isRun3 ? "Run3":"Run2")<<" CDI file while running on "<<(!m_isRun3 ? "Run2":"Run3")<<" sample; Please updates your CDI file to the correct version for "<<(!m_isRun3 ? "Run2":"Run3"));
1799 }
1800
1801 if (m_useBtagging && !m_btagSelTool.isUserConfigured() && !m_BtagWP.empty()) {
1802 if (jetcollBTag.find("AntiKt4EMTopoJets") == std::string::npos && jetcollBTag.find("AntiKt4EMPFlowJets")==std::string::npos) {
1803 ATH_MSG_WARNING("** Only AntiKt4EMTopoJets and AntiKt4EMPFlowJets are supported with FTAG scale factors!");
1804 return StatusCode::FAILURE;
1805 }
1806
1807 toolName = "BTagSel_" + jetcollBTag + m_BtagTagger + m_BtagWP;
1808
1809 m_btagSelTool.setTypeAndName("BTaggingSelectionTool/"+toolName);
1810 ATH_CHECK( m_btagSelTool.setProperty("TaggerName", m_BtagTagger ) );
1811 ATH_CHECK( m_btagSelTool.setProperty("OperatingPoint", m_BtagWP ) );
1812 ATH_CHECK( m_btagSelTool.setProperty("JetAuthor", jetcollBTag ) );
1813 ATH_CHECK( m_btagSelTool.setProperty("MinPt", m_BtagMinPt ) );
1814 ATH_CHECK( m_btagSelTool.setProperty("FlvTagCutDefinitionsFileName", m_bTaggingCalibrationFilePath) );
1815 // Read from BTagging object. This will be needed until the input file is produced from
1816 // a derivation release that includes !80336.
1817 ATH_CHECK( m_btagSelTool.setProperty("readFromBTaggingObject", m_BtagReadFromObject ) );
1818 ATH_CHECK( m_btagSelTool.setProperty("OutputLevel", this->msg().level()) );
1819 ATH_CHECK( m_btagSelTool.retrieve() );
1820 } else if (m_btagSelTool.isUserConfigured()) ATH_CHECK( m_btagSelTool.retrieve() );
1821
1822
1823 if (m_useBtagging && !m_btagSelTool_OR.isUserConfigured() && !m_orBtagWP.empty()) {
1824 if (jetcoll != "AntiKt4EMTopoJets" && jetcoll != "AntiKt4EMPFlowJets") {
1825 ATH_MSG_WARNING("** Only AntiKt4EMTopoJets and AntiKt4EMPFlowJets are supported with FTAG scale factors!");
1826 return StatusCode::FAILURE;
1827 }
1828
1829 toolName = "BTagSelOR_" + jetcollBTag + m_orBtagWP;
1830 m_btagSelTool_OR.setTypeAndName("BTaggingSelectionTool/"+toolName);
1831 ATH_CHECK( m_btagSelTool_OR.setProperty("TaggerName", m_BtagTagger ) );
1832 ATH_CHECK( m_btagSelTool_OR.setProperty("OperatingPoint", m_orBtagWP ) );
1833 ATH_CHECK( m_btagSelTool_OR.setProperty("JetAuthor", jetcollBTag ) );
1834 ATH_CHECK( m_btagSelTool_OR.setProperty("MinPt", m_BtagMinPt ) );
1835 ATH_CHECK( m_btagSelTool_OR.setProperty("FlvTagCutDefinitionsFileName", m_bTaggingCalibrationFilePath) );
1836 // Read from BTagging object. This will be needed until the input file is produced from
1837 // a derivation release that includes !80336.
1838 ATH_CHECK( m_btagSelTool_OR.setProperty("readFromBTaggingObject", m_BtagReadFromObject ) );
1839 ATH_CHECK( m_btagSelTool_OR.setProperty("OutputLevel", this->msg().level()) );
1840 ATH_CHECK( m_btagSelTool_OR.retrieve() );
1841 } else if (m_btagSelTool_OR.isUserConfigured()) ATH_CHECK( m_btagSelTool_OR.retrieve() );
1842
1843
1844 std::string trkjetcoll = m_defaultTrackJets;
1845 const std::string& BTagColl_TrkJet = trkjetcoll;
1846 if (m_slices["tjet"]) {
1847 if ( m_useBtagging_trkJet && m_defaultTrackJets.empty()) {
1848 m_useBtagging_trkJet = false;
1849 ATH_MSG_INFO("TrackJet collection set to None: disabling btagging for TrackJets.");
1850 }
1851
1852 if (m_useBtagging_trkJet && !m_btagSelTool_trkJet.isUserConfigured() && !m_BtagWP_trkJet.empty()) {
1853 if (trkjetcoll.find("AntiKt2PV0TrackJets")==std::string::npos && trkjetcoll.find("AntiKtVR30Rmax4Rmin02TrackJets")==std::string::npos) {
1854 ATH_MSG_WARNING("** Only AntiKt2PV0TrackJets and AntiKtVR30Rmax4Rmin02TrackJets are supported with FTAG scale factors!");
1855 return StatusCode::FAILURE;
1856 }
1857
1858 toolName = "BTagSel_" + trkjetcoll + m_BtagTagger_trkJet + m_BtagWP_trkJet;
1859
1860 m_btagSelTool_trkJet.setTypeAndName("BTaggingSelectionTool/"+toolName);
1861 ATH_CHECK( m_btagSelTool_trkJet.setProperty("TaggerName", m_BtagTagger_trkJet ) );
1862 ATH_CHECK( m_btagSelTool_trkJet.setProperty("OperatingPoint", m_BtagWP_trkJet ) );
1863 ATH_CHECK( m_btagSelTool_trkJet.setProperty("MinPt", m_BtagMinPt_trkJet ) );
1864 ATH_CHECK( m_btagSelTool_trkJet.setProperty("JetAuthor", BTagColl_TrkJet ) );
1865 ATH_CHECK( m_btagSelTool_trkJet.setProperty("MinPt", m_BtagMinPt_trkJet ) );
1866 ATH_CHECK( m_btagSelTool_trkJet.setProperty("FlvTagCutDefinitionsFileName", m_bTaggingCalibrationFilePath) );
1867 // Read from BTagging object. This will be needed until the input file is produced from
1868 // a derivation release that includes !80336.
1869 ATH_CHECK( m_btagSelTool_trkJet.setProperty("readFromBTaggingObject", m_BtagReadFromObject_trkJet ) );
1870 ATH_CHECK( m_btagSelTool_trkJet.setProperty("OutputLevel", this->msg().level()) );
1871 ATH_CHECK( m_btagSelTool_trkJet.retrieve() );
1872 } else if (m_btagSelTool_trkJet.isUserConfigured()) ATH_CHECK( m_btagSelTool_trkJet.retrieve() );
1873 }
1874
1875 // Set MCshowerType for FTAG MC/MC SFs
1876 // https://twiki.cern.ch/twiki/bin/view/AtlasProtected/BTagCalibrationRecommendationsRelease21#MC_MC_Scale_Factors_for_Analysis
1877 std::string MCshowerID;
1878 if(m_showerType==-1){
1879 ATH_MSG_ERROR( "Error! m_showerType=-1, which is an error case for FTAG MC/MC SFs." );
1880 return StatusCode::FAILURE;
1881 }
1882 if(m_BtagTagger=="DL1dv01"){
1883 if(!m_isRun3){
1884 MCshowerID= "default"; // Powheg+Pythia8 (410470) - PhPy8EG_A14
1885 if (m_showerType == 1) MCshowerID = "411233"; // PowhegHerwig7
1886 else if (m_showerType == 2) MCshowerID = "600666"; // PhH7EG_H7UE - 601414
1887 else if (m_showerType == 3) MCshowerID = "410250"; // Sherpa_221
1888 else if (m_showerType == 4) MCshowerID = "700122"; // Sh_2210
1889 else if (m_showerType == 5) MCshowerID = "700122"; // Sh_2211
1890 else if (m_showerType == 6) MCshowerID = "700660"; // Sh_2212 - 700660
1891 else if (m_showerType == 7) MCshowerID = "410464"; // aMcAtNloPy8
1892 else if (m_showerType == 8) MCshowerID = "412116"; // aMcAtNloHerwig7
1893 else if (m_showerType != 0){
1894 ATH_MSG_WARNING("Unknown ShowerID detected! Using default FTAG MC-MC SFs (Powheg+Pythia8). Please check if these are applicable for this sample!");
1895 }
1896 }
1897 else{
1898 MCshowerID= "default"; // Powheg+Pythia8 (601229) - PhPy8EG_A14
1899 if (m_showerType == 2) MCshowerID = "601414"; // POWHEG+Herwig721 - PhH7EG_A14
1900 else if (m_showerType == 6) MCshowerID = "700660"; // Sherpa 2.2.12 - Sh_2212
1901 else if (m_showerType != 0){
1902 ATH_MSG_WARNING("Unknown ShowerID detected! Using default FTAG MC-MC SFs (Powheg+Pythia8). Please check if these are applicable for this sample!");
1903 }
1904 }
1905 } else if (m_BtagTagger=="GN2v01"){
1906 if(!m_isRun3){
1907 MCshowerID= "default"; // PowhegPythia8EvtGen (410470)
1908 if (m_showerType == 2) MCshowerID = "411233"; // POWHEGHERWIG7 - 411233
1909 else if (m_showerType == 3) MCshowerID = "600666"; // PhH7EG_H7UE - 600666
1910 else if (m_showerType == 4) MCshowerID = "700660"; // Sh_2210 FTAGAnalysisConfig uses this, but docs say only 11-16 can be used
1911 else if (m_showerType == 5) MCshowerID = "700660"; // Sh_2211
1912 else if (m_showerType == 6) MCshowerID = "700660"; // Sh_2212
1913 else if (m_showerType == 7) MCshowerID = "700660"; // Sh_2214
1914 else if (m_showerType == 8) {
1915 ATH_MSG_WARNING("Unknown Sherpa version detected! Using FTAG MC-MC SFs for Sherpa 2.2.11-2.2.16. Please check if these are applicable for this sample!");
1916 MCshowerID = "700660"; // Unknown Sherpa Version. This is to handle Sh_blank (e.g. DSID 701050). The examples I've found are all 2.2.16, but that's not guaranteed.
1917 }
1918 else if (m_showerType != 0){
1919 ATH_MSG_WARNING("Unknown ShowerID detected! Using default FTAG MC-MC SFs (Powheg+Pythia8). Please check if these are applicable for this sample!");
1920 }
1921 }
1922 else {
1923 MCshowerID= "default"; // PowhegPythia8EvtGen (601229)
1924 if (m_showerType == 3) MCshowerID = "601414"; // PhH7EG_H7UE - 601414
1925 else if (m_showerType == 5) MCshowerID = "700808"; // Sh_2211
1926 else if (m_showerType == 6) MCshowerID = "700808"; // Sh_2212
1927 else if (m_showerType == 7) MCshowerID = "700808"; // Sh_2214
1928 else if (m_showerType == 8) {
1929 ATH_MSG_WARNING("Unknown Sherpa version detected! Using FTAG MC-MC SFs for Sherpa 2.2.11-2.2.16. Please check if these are applicable for this sample!");
1930 MCshowerID = "700660"; // Unknown Sherpa Version
1931 }
1932 else if (m_showerType != 0){
1933 ATH_MSG_WARNING("Unknown ShowerID detected! Using default FTAG MC-MC SFs (Powheg+Pythia8). Please check if these are applicable for this sample!");
1934 }
1935 }
1936 } else {
1937 ATH_MSG_WARNING("Unknown b-tagger detected! Only DL1dv01 and GN2v01 are supported. Falling back to default FTAG MC-MC SFs (Powheg+Pythia8). Please check if these are applicable for this sample!");
1938 MCshowerID= "default";
1939 }
1940
1941 // btagEfficiencyTool
1942 if (m_useBtagging && !m_btagEffTool.isUserConfigured() && !m_BtagWP.empty()) {
1943 if (jetcoll != "AntiKt4EMTopoJets" && jetcoll != "AntiKt4EMPFlowJets") {
1944 ATH_MSG_WARNING("** Only AntiKt4EMTopoJets and AntiKt4EMPFlowJets are supported with FTAG scale factors!");
1945 return StatusCode::FAILURE;
1946 }
1947
1948 toolName = "BTagSF_" + jetcollBTag + m_BtagTagger + m_BtagWP;
1949 m_btagEffTool.setTypeAndName("BTaggingEfficiencyTool/"+toolName);
1950 ATH_CHECK( m_btagEffTool.setProperty("TaggerName", m_BtagTagger ) );
1951 ATH_CHECK( m_btagEffTool.setProperty("ScaleFactorFileName", m_bTaggingCalibrationFilePath) );
1952 ATH_CHECK( m_btagEffTool.setProperty("OperatingPoint", m_BtagWP ) );
1953 ATH_CHECK( m_btagEffTool.setProperty("JetAuthor", jetcollBTag ) );
1954 // Read from BTagging object. This will be needed until the input file is produced from
1955 // a derivation release that includes !80336.
1956 ATH_CHECK( m_btagEffTool.setProperty("readFromBTaggingObject", m_BtagReadFromObject ) );
1957 ATH_CHECK( m_btagEffTool.setProperty("MinPt", m_BtagMinPt ) );
1958 ATH_CHECK( m_btagEffTool.setProperty("SystematicsStrategy", m_BtagSystStrategy ) );
1959 ATH_CHECK( m_btagEffTool.setProperty("EfficiencyBCalibrations", MCshowerID ));
1960 ATH_CHECK( m_btagEffTool.setProperty("EfficiencyCCalibrations", MCshowerID ));
1961 ATH_CHECK( m_btagEffTool.setProperty("EfficiencyTCalibrations", MCshowerID ));
1962 ATH_CHECK( m_btagEffTool.setProperty("EfficiencyLightCalibrations", MCshowerID ));
1963 ATH_CHECK( m_btagEffTool.setProperty("EigenvectorReductionB", m_EigenvectorReductionB ));
1964 ATH_CHECK( m_btagEffTool.setProperty("EigenvectorReductionC", m_EigenvectorReductionC ));
1965 ATH_CHECK( m_btagEffTool.setProperty("EigenvectorReductionLight", m_EigenvectorReductionLight ));
1966 ATH_CHECK( m_btagEffTool.setProperty("OutputLevel", this->msg().level()) );
1967 ATH_CHECK( m_btagEffTool.retrieve() );
1968 } else ATH_CHECK( m_btagEffTool.retrieve() );
1969
1970
1971 if (m_slices["tjet"]) {
1972 if (m_useBtagging_trkJet && !m_btagEffTool_trkJet.isUserConfigured() && !m_BtagWP_trkJet.empty()) {
1973 if (trkjetcoll.find("AntiKt2PV0TrackJets")==std::string::npos && trkjetcoll.find("AntiKtVR30Rmax4Rmin02TrackJets")==std::string::npos) {
1974 ATH_MSG_WARNING("** Only AntiKt2PV0TrackJets and AntiKtVR30Rmax4Rmin02TrackJets are supported with FTAG scale factors!");
1975 return StatusCode::FAILURE;
1976 }
1977
1978 toolName = "BTagSF_" + trkjetcoll;
1979 m_btagEffTool_trkJet.setTypeAndName("BTaggingEfficiencyTool/"+toolName);
1980 ATH_CHECK( m_btagEffTool_trkJet.setProperty("TaggerName", m_BtagTagger_trkJet ) );
1981 ATH_CHECK( m_btagEffTool_trkJet.setProperty("ScaleFactorFileName", m_bTaggingCalibrationFilePath) );
1982 ATH_CHECK( m_btagEffTool_trkJet.setProperty("OperatingPoint", m_BtagWP_trkJet ) );
1983 ATH_CHECK( m_btagEffTool_trkJet.setProperty("JetAuthor", BTagColl_TrkJet ) );
1984 // Read from BTagging object. This will be needed until the input file is produced from
1985 // a derivation release that includes !80336.
1986 ATH_CHECK( m_btagEffTool_trkJet.setProperty("readFromBTaggingObject", m_BtagReadFromObject_trkJet ) );
1987 ATH_CHECK( m_btagEffTool_trkJet.setProperty("MinPt", m_BtagMinPt_trkJet ) );
1988 ATH_CHECK( m_btagEffTool_trkJet.setProperty("SystematicsStrategy", m_BtagSystStrategy ) );
1989 ATH_CHECK( m_btagEffTool_trkJet.setProperty("EfficiencyBCalibrations", MCshowerID ));
1990 ATH_CHECK( m_btagEffTool_trkJet.setProperty("EfficiencyCCalibrations", MCshowerID ));
1991 ATH_CHECK( m_btagEffTool_trkJet.setProperty("EfficiencyTCalibrations", MCshowerID ));
1992 ATH_CHECK( m_btagEffTool_trkJet.setProperty("EfficiencyLightCalibrations", MCshowerID ));
1993 ATH_CHECK( m_btagEffTool_trkJet.setProperty("EigenvectorReductionB", m_EigenvectorReductionB ));
1994 ATH_CHECK( m_btagEffTool_trkJet.setProperty("EigenvectorReductionC", m_EigenvectorReductionC ));
1995 ATH_CHECK( m_btagEffTool_trkJet.setProperty("EigenvectorReductionLight", m_EigenvectorReductionLight ));
1996 ATH_CHECK( m_btagEffTool_trkJet.setProperty("OutputLevel", this->msg().level()) );
1997 ATH_CHECK( m_btagEffTool_trkJet.retrieve() );
1998 } else if (m_btagEffTool_trkJet.isUserConfigured()) ATH_CHECK( m_btagEffTool_trkJet.retrieve() );
1999 }
2000 }
2001
2002
2003 if (m_slices["met"]) {
2005 // Initialise MET tools
2006
2007 if (!m_metMaker.isUserConfigured()) {
2008 toolName = m_doFwdJVT ? m_metJetSelection+"_fJVT" : m_metJetSelection+"_NOfJVT";
2009 m_metMaker.setTypeAndName("met::METMaker/METMaker_ST_"+toolName);
2010
2011 ATH_CHECK( m_metMaker.setProperty("JetContainer", jetcoll) );
2012 ATH_CHECK( m_metMaker.setProperty("ORCaloTaggedMuons", m_metRemoveOverlappingCaloTaggedMuons) );
2013 ATH_CHECK( m_metMaker.setProperty("DoSetMuonJetEMScale", m_metDoSetMuonJetEMScale) );
2014 ATH_CHECK( m_metMaker.setProperty("DoRemoveMuonJets", m_metDoRemoveMuonJets) );
2015 ATH_CHECK( m_metMaker.setProperty("UseGhostMuons", m_metUseGhostMuons) );
2016 ATH_CHECK( m_metMaker.setProperty("DoMuonEloss", m_metDoMuonEloss) );
2017 ATH_CHECK( m_metMaker.setProperty("GreedyPhotons", m_metGreedyPhotons) );
2018 ATH_CHECK( m_metMaker.setProperty("VeryGreedyPhotons", m_metVeryGreedyPhotons) );
2019
2020 // set the jet selection if default empty string is overridden through config file
2021 if (m_metJetSelection.size()) {
2022 ATH_CHECK( m_metMaker.setProperty("JetSelection", m_metJetSelection) );
2023 }
2025 ATH_CHECK( m_metMaker.setProperty("DoPFlow", true) );
2026 }
2027
2028 ATH_CHECK( m_metMaker.setProperty("OutputLevel", this->msg().level()) );
2029 ATH_CHECK( m_metMaker.retrieve() );
2030 } else ATH_CHECK( m_metMaker.retrieve() );
2031
2032
2033 if (!m_metSystTool.isUserConfigured()) {
2034 m_metSystTool.setTypeAndName("met::METSystematicsTool/METSystTool");
2035 ATH_CHECK( m_metSystTool.setProperty("ConfigPrefix", m_metsysConfigPrefix) );
2036
2038 ATH_MSG_ERROR( "Can only have CST *or* TST configured for MET maker. Please unset either METDoCaloSyst or METDoTrkSyst in your config file" );
2039 return StatusCode::FAILURE;
2040 }
2041
2042 if (m_trkMETsyst) {
2043 ATH_CHECK( m_metSystTool.setProperty("ConfigSoftCaloFile", "") );
2044 ATH_CHECK( m_metSystTool.setProperty("ConfigSoftTrkFile", "TrackSoftTerms-pflow_Dec24.config") );
2045 }
2046
2047 if (m_caloMETsyst) {
2048 ATH_MSG_WARNING( "CST is no longer recommended by Jet/MET group");
2049 ATH_CHECK( m_metSystTool.setProperty("ConfigSoftTrkFile", "") );
2050 }
2051
2052 if (m_trkJetsyst) {
2053 ATH_CHECK( m_metSystTool.setProperty("ConfigJetTrkFile", "JetTrackSyst.config") );
2054 }
2055
2056 ATH_CHECK( m_metSystTool.setProperty("OutputLevel", this->msg().level()) );
2057 ATH_CHECK( m_metSystTool.retrieve());
2058 } else ATH_CHECK( m_metSystTool.retrieve());
2059
2060
2061 if (!m_metSignif.isUserConfigured()) {
2062 // See https://twiki.cern.ch/twiki/bin/view/AtlasProtected/MetSignificance
2063 m_metSignif.setTypeAndName("met::METSignificance/metSignificance_"+jetname);
2064#ifndef XAOD_STANDALONE // Athena and AthAnalysis; need to take into account that MuonCalibTool is private tool
2065 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "SoftTermParam", m_softTermParam));
2066 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "TreatPUJets", m_treatPUJets));
2067 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "DoPhiReso", m_doPhiReso));
2068 if(jetname != "AntiKt4EMPFlow")
2069 ATH_MSG_WARNING("METSignificance recommendations only exist for AntiKt4EMPFlow jets, falling back to this.");
2070 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "JetCollection", "AntiKt4EMPFlow"));
2071 // This is the only recommended set of jet resolutions for use with R22+ MET Significance until "Consolidated" recommendations are available
2072 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "JetCalibConfig", "JES_data2017_2016_2015_Recommendation_PFlow_Aug2018_rel21.config") );
2073 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "JetCalibSequence", "JetArea_Residual_EtaJES_GSC_Smear") );
2074 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "JetCalibArea", "00-04-81") );
2075 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "EgammaESModel", m_isRun3 ? "es2024_Run3_v0" : "es2023_R22_Run2_v1") );
2076 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "EgammaDecorrelationModel", "1NP_v1") );
2077 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "EgammaUseFastsim", isAtlfast()) );
2078 // setup a dedicated new muon calib tool for passing down to METSignificance
2079 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "MuonCalibTool", "CP::MuonCalibTool/calibTool"));
2080 if (m_isRun3)
2081 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "calibTool.IsRun3Geo", true));
2082 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "calibTool.calibMode", m_muCalibrationMode));
2083 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "calibTool.OutputLevel",this->msg().level()));
2084 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "calibTool.release", "Recs2025_12_11_Run2Run3"));
2085 int IdBaselineInt = m_muIdBaseline;
2086 if (IdBaselineInt == 4)
2087 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "calibTool.do2StationsHighPt", true));
2088 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "calibTool.doExtraSmearing", m_muHighPtExtraSmear));
2089 ATH_CHECK( AAH::setProperty(m_metSignif.getHandle(), "OutputLevel", this->msg().level()));
2090#else // AnalysisBase; can just pass the jet/egamma/muon calib tools configured above
2091 ATH_CHECK( m_metSignif.setProperty("SoftTermParam", m_softTermParam) );
2092 ATH_CHECK( m_metSignif.setProperty("TreatPUJets", m_treatPUJets) );
2093 ATH_CHECK( m_metSignif.setProperty("DoPhiReso", m_doPhiReso) );
2094 if(jetname != "AntiKt4EMPFlow")
2095 ATH_MSG_WARNING("METSignificance recommendations only exist for AntiKt4EMPFlow jets, falling back to this.");
2096 ATH_CHECK( m_metSignif.setProperty( "JetCollection", "AntiKt4EMPFlow"));
2097 // This is the only recommended set of jet resolutions for use with R22+ MET Significance until "Consolidated" recommendations are available
2098 ATH_CHECK( m_metSignif.setProperty( "JetCalibConfig", "JES_data2017_2016_2015_Recommendation_PFlow_Aug2018_rel21.config") );
2099 ATH_CHECK( m_metSignif.setProperty( "JetCalibSequence", "JetArea_Residual_EtaJES_GSC_Smear") );
2100 ATH_CHECK( m_metSignif.setProperty( "JetCalibArea", "00-04-81") );
2101 ATH_CHECK( m_metSignif.setProperty("egammaCalibTool", m_egammaCalibTool.getHandle()) );
2102 // just pass the muon calib tool
2103 ATH_CHECK( m_metSignif.setProperty("MuonCalibTool",m_muonCalibTool.getHandle()));
2104 ATH_CHECK( m_metSignif.setProperty("OutputLevel", this->msg().level()) );
2105#endif
2106 ATH_CHECK( m_metSignif.retrieve() );
2107 } else ATH_CHECK( m_metSignif.retrieve() );
2108 }
2109
2110
2112// Initialise trigger tools
2113
2114 if (!m_trigDecTool.isUserConfigured()) {
2115
2116 // The decision tool
2117 m_trigDecTool.setTypeAndName("Trig::TrigDecisionTool/TrigDecisionTool");
2118 ATH_CHECK( m_trigDecTool.setProperty("TrigDecisionKey", "xTrigDecision") );
2119 if (m_isRun3) {
2120 ATH_CHECK( m_trigDecTool.setProperty("NavigationFormat", "TrigComposite") );
2121 ATH_CHECK( m_trigDecTool.setProperty("HLTSummary", "HLTNav_Summary_DAODSlimmed") );
2122 }
2123 ATH_CHECK( m_trigDecTool.setProperty("OutputLevel", this->msg().level()) );
2124
2125#ifndef XAOD_STANDALONE // Athena and AthAnalysis
2126 // Clear the default tool handle to cause a fallback on the config service
2127 ATH_CHECK( m_trigDecTool.setProperty("ConfigTool", ""));
2128#else // AnalysisBase
2129 m_trigConfTool.setTypeAndName("TrigConf::xAODConfigTool/xAODConfigTool");
2130 ATH_CHECK(m_trigConfTool.retrieve() );
2131 ATH_CHECK( m_trigDecTool.setProperty("ConfigTool", m_trigConfTool.getHandle()) );
2132#endif
2133
2134 ATH_CHECK( m_trigDecTool.retrieve() );
2135
2136 } else ATH_CHECK( m_trigDecTool.retrieve() );
2137
2138 if (m_isRun3) {
2139 if (!m_trigDRScoringTool.isUserConfigured()) {
2140 m_trigDRScoringTool.setTypeAndName("Trig::DRScoringTool/TrigDRScoringTool");
2141 ATH_CHECK( m_trigDRScoringTool.setProperty("OutputLevel", this->msg().level()) );
2142 ATH_CHECK( m_trigDRScoringTool.retrieve() );
2143 } else ATH_CHECK( m_trigDRScoringTool.retrieve() );
2144 }
2145
2146 if (!m_trigMatchingTool.isUserConfigured()) {
2148 m_trigMatchingTool.setTypeAndName("Trig::MatchFromCompositeTool/TrigMatchFromCompositeTool");
2149 ATH_CHECK( m_trigMatchingTool.setProperty("InputPrefix", m_trigMatchingPrefix) );
2150 ATH_CHECK( m_trigMatchingTool.setProperty("RemapBrokenLinks", true) );
2151 }
2152 else {
2153 if (m_isRun3){
2154 m_trigMatchingTool.setTypeAndName("Trig::R3MatchingTool/TrigR3MatchingTool");
2155 ATH_CHECK( m_trigMatchingTool.setProperty("ScoringTool", m_trigDRScoringTool.getHandle()) );
2156 ATH_CHECK( m_trigMatchingTool.setProperty("TrigDecisionTool", m_trigDecTool.getHandle()) );
2157 }
2158 else {
2159 m_trigMatchingTool.setTypeAndName("Trig::MatchingTool/TrigMatchingTool");
2160 ATH_CHECK( m_trigMatchingTool.setProperty("TrigDecisionTool", m_trigDecTool.getHandle()) );
2161 }
2162 }
2163 ATH_CHECK( m_trigMatchingTool.setProperty("OutputLevel", this->msg().level()) );
2164 ATH_CHECK( m_trigMatchingTool.retrieve() );
2165 } else ATH_CHECK( m_trigMatchingTool.retrieve() );
2166
2168// Initialise trigGlobalEfficiencyCorrection tool
2169
2170 if (!m_trigGlobalEffCorrTool_diLep.isUserConfigured() && !isData()) {
2171
2172 std::string no2e17("");
2173 if (m_trig2017combination_diLep.find("||2e17_lhvloose_nod0_L12EM15VHI") != std::string::npos) {
2174 auto pos_2e17 = m_trig2017combination_diLep.find("||2e17_lhvloose_nod0_L12EM15VHI");
2175 no2e17 = m_trig2017combination_diLep.substr(0, pos_2e17) + m_trig2017combination_diLep.substr(pos_2e17+31, m_trig2017combination_diLep.size());
2176 } else if (m_trig2017combination_diLep.find("2e17_lhvloose_nod0_L12EM15VHI||") != std::string::npos) {
2177 auto pos_2e17 = m_trig2017combination_diLep.find("2e17_lhvloose_nod0_L12EM15VHI||");
2178 no2e17 = m_trig2017combination_diLep.substr(0, pos_2e17) + m_trig2017combination_diLep.substr(pos_2e17+31, m_trig2017combination_diLep.size());
2179 } else {
2181 }
2182 ATH_MSG_DEBUG( "TrigGlobalEfficiencyCorrectionTool/TrigGlobal_diLep: no2e17 trigger string: " << no2e17 );
2183
2184 std::map<std::string,std::string> triggers_diLep;
2185 triggers_diLep["2015"] = m_trig2015combination_diLep;
2186 triggers_diLep["2016"] = m_trig2016combination_diLep;
2187 triggers_diLep["324320-326695"] = m_trig2017combination_diLep; // 2017 before accidental prescale of L12EM15VHI
2188 triggers_diLep["326834-328393"] = no2e17; // 2017 during accidental prescale
2189 triggers_diLep["329385-340453"] = m_trig2017combination_diLep; // 2017 after accidental prescale
2190 triggers_diLep["2018"] = m_trig2018combination_diLep;
2191
2192 m_trigGlobalEffCorrTool_diLep.setTypeAndName("TrigGlobalEfficiencyCorrectionTool/TrigGlobal_diLep");
2193 ATH_CHECK( m_trigGlobalEffCorrTool_diLep.setProperty("ElectronEfficiencyTools", m_elecTrigEffTools) );
2194 ATH_CHECK( m_trigGlobalEffCorrTool_diLep.setProperty("ElectronScaleFactorTools", m_elecTrigSFTools) );
2195 ATH_CHECK( m_trigGlobalEffCorrTool_diLep.setProperty("MuonTools", m_muonTrigSFTools) );
2196 ATH_CHECK( m_trigGlobalEffCorrTool_diLep.setProperty("TriggerCombination", triggers_diLep) );
2197 ATH_CHECK( m_trigGlobalEffCorrTool_diLep.setProperty("TriggerMatchingTool", m_trigMatchingTool.getHandle()) );
2198 ATH_CHECK( m_trigGlobalEffCorrTool_diLep.setProperty("ListOfLegsPerTool", m_legsPerTool) );
2199 ATH_CHECK( m_trigGlobalEffCorrTool_diLep.setProperty("NumberOfToys", m_trigNToys_diLep) );
2200 ATH_CHECK( m_trigGlobalEffCorrTool_diLep.setProperty("OutputLevel", this->msg().level()) );
2202 } else if (m_trigGlobalEffCorrTool_diLep.isUserConfigured()) ATH_CHECK( m_trigGlobalEffCorrTool_diLep.retrieve() );
2203
2204
2205 if (!m_trigGlobalEffCorrTool_multiLep.isUserConfigured() && !isData()) {
2206
2207 std::string no2e17("");
2208 if (m_trig2017combination_multiLep.find("||2e17_lhvloose_nod0_L12EM15VHI") != std::string::npos) {
2209 auto pos_2e17 = m_trig2017combination_multiLep.find("||2e17_lhvloose_nod0_L12EM15VHI");
2210 no2e17 = m_trig2017combination_multiLep.substr(0, pos_2e17) + m_trig2017combination_multiLep.substr(pos_2e17+31, m_trig2017combination_multiLep.size());
2211 } else if (m_trig2017combination_multiLep.find("2e17_lhvloose_nod0_L12EM15VHI||") != std::string::npos) {
2212 auto pos_2e17 = m_trig2017combination_multiLep.find("2e17_lhvloose_nod0_L12EM15VHI||");
2213 no2e17 = m_trig2017combination_multiLep.substr(0, pos_2e17) + m_trig2017combination_multiLep.substr(pos_2e17+31, m_trig2017combination_multiLep.size());
2214 } else {
2216 }
2217 ATH_MSG_DEBUG( "TrigGlobalEfficiencyCorrectionTool/TrigGlobal_multiLep: no2e17 trigger string: " << no2e17 );
2218
2219 std::map<std::string,std::string> triggers_multiLep;
2220 triggers_multiLep["2015"] = m_trig2015combination_multiLep;
2221 triggers_multiLep["2016"] = m_trig2016combination_multiLep;
2222 triggers_multiLep["324320-326695"] = m_trig2017combination_multiLep; // 2017 before accidental prescale of L12EM15VHI
2223 triggers_multiLep["326834-328393"] = no2e17; // 2017 during accidental prescale
2224 triggers_multiLep["329385-340453"] = m_trig2017combination_multiLep; // 2017 after accidental prescale
2225 triggers_multiLep["2018"] = m_trig2018combination_multiLep;
2226
2227 m_trigGlobalEffCorrTool_multiLep.setTypeAndName("TrigGlobalEfficiencyCorrectionTool/TrigGlobal_multiLep");
2228 ATH_CHECK( m_trigGlobalEffCorrTool_multiLep.setProperty("ElectronEfficiencyTools", m_elecTrigEffTools) );
2229 ATH_CHECK( m_trigGlobalEffCorrTool_multiLep.setProperty("ElectronScaleFactorTools", m_elecTrigSFTools) );
2231 ATH_CHECK( m_trigGlobalEffCorrTool_multiLep.setProperty("TriggerCombination", triggers_multiLep) );
2232 ATH_CHECK( m_trigGlobalEffCorrTool_multiLep.setProperty("TriggerMatchingTool", m_trigMatchingTool.getHandle()) );
2233 ATH_CHECK( m_trigGlobalEffCorrTool_multiLep.setProperty("ListOfLegsPerTool", m_legsPerTool) );
2234 ATH_CHECK( m_trigGlobalEffCorrTool_multiLep.setProperty("NumberOfToys", m_trigNToys_multiLep) );
2235 ATH_CHECK( m_trigGlobalEffCorrTool_multiLep.setProperty("OutputLevel", this->msg().level()) );
2237 } else if (m_trigGlobalEffCorrTool_multiLep.isUserConfigured()) ATH_CHECK( m_trigGlobalEffCorrTool_multiLep.retrieve() );
2238
2239
2240 if (!m_trigGlobalEffCorrTool_diPhoton.isUserConfigured() && !isData()) {
2241 m_trigGlobalEffCorrTool_diPhoton.setTypeAndName("TrigGlobalEfficiencyCorrectionTool/TrigGlobal_diPhoton");
2242 ATH_CHECK( m_trigGlobalEffCorrTool_diPhoton.setProperty("PhotonEfficiencyTools", m_photonTrigEffTools) );
2243 ATH_CHECK( m_trigGlobalEffCorrTool_diPhoton.setProperty("PhotonScaleFactorTools", m_photonTrigSFTools) );
2244 ATH_CHECK( m_trigGlobalEffCorrTool_diPhoton.setProperty("TriggerCombination2015", m_trig2015combination_diPhoton) );
2245 ATH_CHECK( m_trigGlobalEffCorrTool_diPhoton.setProperty("TriggerCombination2016", m_trig2016combination_diPhoton) );
2246 ATH_CHECK( m_trigGlobalEffCorrTool_diPhoton.setProperty("TriggerCombination2017", m_trig2017combination_diPhoton) );
2247 ATH_CHECK( m_trigGlobalEffCorrTool_diPhoton.setProperty("TriggerCombination2018", m_trig2018combination_diPhoton) );
2248 ATH_CHECK( m_trigGlobalEffCorrTool_diPhoton.setProperty("ListOfLegsPerTool", m_legsPerTool_ph) );
2249 ATH_CHECK( m_trigGlobalEffCorrTool_diPhoton.setProperty("NumberOfToys", m_trigNToys_diPhoton) );
2250 ATH_CHECK( m_trigGlobalEffCorrTool_diPhoton.setProperty("OutputLevel", this->msg().level()) );
2252 } else if (m_trigGlobalEffCorrTool_diPhoton.isUserConfigured()) ATH_CHECK( m_trigGlobalEffCorrTool_diPhoton.retrieve() );
2253
2254
2255 if (m_slices["ele"] || m_slices["pho"] || m_slices["mu"]) {
2256 // /////////////////////////////////////////////////////////////////////////////////////////
2257 // Initialise Isolation Correction Tool
2258
2259 if ( !m_isoCorrTool.isUserConfigured() ) {
2260 m_isoCorrTool.setTypeAndName("CP::IsolationCorrectionTool/IsoCorrTool");
2261 ATH_CHECK( m_isoCorrTool.setProperty( "ToolVer", "REL22") );
2262 ATH_CHECK( m_isoCorrTool.setProperty( "IsMC", !isData()) );
2263 ATH_CHECK( m_isoCorrTool.setProperty( "AFII_corr", isAtlfast()) );
2264 ATH_CHECK( m_isoCorrTool.setProperty( "Apply_SC_leakcorr", false) );
2265 ATH_CHECK( m_isoCorrTool.setProperty( "FixTimingIssueInCore", true) ); // Similar to https://gitlab.cern.ch/atlas/athena/-/merge_requests/83939
2266 ATH_CHECK( m_isoCorrTool.setProperty( "CorrFile", "IsolationCorrections/v6/isolation_ptcorrections_rel22_mc20.root") );
2267 ATH_CHECK( m_isoCorrTool.setProperty( "OutputLevel", this->msg().level()) );
2268 ATH_CHECK( m_isoCorrTool.retrieve() );
2269 } else ATH_CHECK( m_isoCorrTool.retrieve() );
2270
2271
2272 // /////////////////////////////////////////////////////////////////////////////////////////
2273 // Initialise Isolation Tool
2274 if (!m_isoTool.isUserConfigured()) {
2275 m_isoTool.setTypeAndName("CP::IsolationSelectionTool/IsoTool");
2276 ATH_CHECK( m_isoTool.setProperty("ElectronWP", m_eleIso_WP.empty() ? "Loose_VarRad" : m_eleIso_WP) );
2277 ATH_CHECK( m_isoTool.setProperty("MuonWP", m_muIso_WP.empty() ? "Loose_VarRad" : m_muIso_WP) );
2278 ATH_CHECK( m_isoTool.setProperty("PhotonWP", m_photonIso_WP.empty() ? "FixedCutTight" : m_photonIso_WP ) );
2279 ATH_CHECK( m_isoTool.setProperty("OutputLevel", this->msg().level()) );
2280 ATH_CHECK( m_isoTool.retrieve() );
2281 } else ATH_CHECK( m_isoTool.retrieve() );
2282
2283 //disable if (!m_isoToolLowPtPLV.isUserConfigured()) {
2284 //disable m_isoToolLowPtPLV.setTypeAndName("CP::IsolationLowPtPLVTool/IsoToolLowPtPLV");
2285 //disable ATH_CHECK( m_isoToolLowPtPLV.setProperty("OutputLevel", this->msg().level()) );
2286 //disable ATH_CHECK( m_isoToolLowPtPLV.retrieve() );
2287 //disable } else ATH_CHECK( m_isoToolLowPtPLV.retrieve() );
2288
2289
2290 if (!m_isoBaselineTool.isUserConfigured()) {
2291 m_isoBaselineTool.setTypeAndName("CP::IsolationSelectionTool/IsoBaselineTool");
2292 ATH_CHECK( m_isoBaselineTool.setProperty("ElectronWP", m_eleBaselineIso_WP.empty() ? "Loose_VarRad" : m_eleBaselineIso_WP ) );
2293 ATH_CHECK( m_isoBaselineTool.setProperty("MuonWP", m_muBaselineIso_WP.empty() ? "Loose_VarRad" : m_muBaselineIso_WP ) );
2294 ATH_CHECK( m_isoBaselineTool.setProperty("PhotonWP", m_photonBaselineIso_WP.empty() ? "FixedCutTight" : m_photonBaselineIso_WP ) );
2295 ATH_CHECK( m_isoBaselineTool.setProperty("OutputLevel", this->msg().level()) );
2296 ATH_CHECK( m_isoBaselineTool.retrieve() );
2297 } else ATH_CHECK( m_isoBaselineTool.retrieve() );
2298
2299
2300 if (!m_isoHighPtTool.isUserConfigured()) {
2301 m_isoHighPtTool.setTypeAndName("CP::IsolationSelectionTool/IsoHighPtTool");
2302 ATH_CHECK( m_isoHighPtTool.setProperty("ElectronWP", m_eleIsoHighPt_WP.empty() ? "Loose_VarRad" : m_eleIsoHighPt_WP) );
2303 ATH_CHECK( m_isoHighPtTool.setProperty("MuonWP", m_muIsoHighPt_WP.empty() ? "Loose_VarRad" : m_muIsoHighPt_WP ) );
2304 ATH_CHECK( m_isoHighPtTool.setProperty("PhotonWP", m_photonIso_WP.empty() ? "FixedCutTight" : m_photonIso_WP ) );
2305 ATH_CHECK( m_isoHighPtTool.setProperty("OutputLevel", this->msg().level()) );
2306 ATH_CHECK( m_isoHighPtTool.retrieve() );
2307 } else ATH_CHECK( m_isoHighPtTool.retrieve() );
2308
2309
2310 // /////////////////////////////////////////////////////////////////////////////////////////
2311 // Initialise IsolationCloseByCorrectionTool Tool
2312 if (!m_isoCloseByTool.isUserConfigured()) {
2313 m_isoCloseByTool.setTypeAndName("CP::IsolationCloseByCorrectionTool/IsoCloseByTool");
2314 // Actually we could debate about what is the proper tool to choose if the users have different baseline & signal islation WP's
2315 ATH_CHECK( m_isoCloseByTool.setProperty("IsolationSelectionTool", m_useSigLepForIsoCloseByOR ? m_isoTool : m_isoBaselineTool));
2316 ATH_CHECK( m_isoCloseByTool.setProperty("PassoverlapDecorator", m_IsoCloseByORpassLabel) );
2317 ATH_CHECK( m_isoCloseByTool.setProperty("SelectionDecorator", m_useSigLepForIsoCloseByOR ? "signal" : "baseline") );
2318 // Make this propery configurable as well?
2319 ATH_CHECK( m_isoCloseByTool.setProperty("BackupPrefix", "ORIG") );
2320 // The isolation selection decorator is updated as well by the tool
2321 ATH_CHECK( m_isoCloseByTool.setProperty("IsolationSelectionDecorator", "isol") );
2322
2323 ATH_CHECK( m_isoCloseByTool.setProperty("OutputLevel", this->msg().level()) );
2324#ifndef XAOD_ANALYSIS
2325 ATH_CHECK( m_isoCloseByTool.setProperty("ParticleCaloExtensionTool", "") );
2326#endif
2327 ATH_CHECK( m_isoCloseByTool.retrieve() );
2328 } else ATH_CHECK( m_isoCloseByTool.retrieve() );
2329 }
2330
2331
2332// /////////////////////////////////////////////////////////////////////////////////////////
2333// Initialise Overlap Removal Tool
2334 if ( m_orToolbox.masterTool.empty() ){
2335
2336 // set up the master tool
2337 std::string suffix = "";
2338 if (m_orDoTau) suffix += "Tau";
2339 if (m_orDoPhoton) suffix += "Gamma";
2340 if (m_orDoBjet) suffix += "Bjet";
2341 std::string toolName = "ORTool" + suffix;
2342 ATH_MSG_INFO("SUSYTools: Autoconfiguring " << toolName);
2343
2344 std::string bJetLabel = "";
2345 //overwrite lepton flags if the global is false (yes?)
2346 if (!m_orDoBjet || !m_useBtagging) {
2347 m_orDoElBjet = false;
2348 m_orDoMuBjet = false;
2349 m_orDoTauBjet = false;
2350 }
2352 bJetLabel = "bjet_loose";
2353 }
2354
2355 // Set the generic flags
2356 ORUtils::ORFlags orFlags(toolName, m_orInputLabel, "passOR");
2357 orFlags.bJetLabel = bJetLabel;
2358 orFlags.boostedLeptons = (m_orDoBoostedElectron || m_orDoBoostedMuon);
2359 orFlags.outputPassValue = true;
2360 orFlags.linkOverlapObjects = m_orLinkOverlapObjects;
2361 if (m_orDoElEl) {
2362 orFlags.doEleEleOR = true;
2363 } else orFlags.doEleEleOR = false;
2364 orFlags.doElectrons = true;
2365 orFlags.doMuons = true;
2366 orFlags.doJets = true;
2367 orFlags.doTaus = m_orDoTau;
2368 orFlags.doPhotons = m_orDoPhoton;
2369 orFlags.doFatJets = m_orDoFatjets;
2370
2371 //set up all recommended tools
2373
2374 // We don't currently have a good way to determine here which object
2375 // definitions are disabled, so we currently just configure all overlap
2376 // tools and disable the pointer safety checks
2377 ATH_CHECK( m_orToolbox.setGlobalProperty("OutputLevel", this->msg().level()) );
2378 ATH_CHECK( m_orToolbox.masterTool.setProperty("RequireExpectedPointers", false) );
2379
2380 // Override boosted OR sliding cone options
2381 ATH_CHECK( m_orToolbox.eleJetORT.setProperty("UseSlidingDR", m_orDoBoostedElectron) );
2382 ATH_CHECK( m_orToolbox.muJetORT.setProperty("UseSlidingDR", m_orDoBoostedMuon) );
2383
2384 //add custom tau-jet OR tool
2385 if(m_orDoTau){
2386 m_orToolbox.tauJetORT.setTypeAndName("ORUtils::TauJetOverlapTool/" + orFlags.masterName + ".TauJetORT");
2387 ATH_CHECK( m_orToolbox.tauJetORT.setProperty("BJetLabel", m_orDoTauBjet?bJetLabel:"") );
2388 }
2389
2390 // override sliding cone params if sliding dR is on and the user-provided parameter values are non-negative
2392 if (m_orBoostedElectronC1 > 0) ATH_CHECK( m_orToolbox.eleJetORT.setProperty("SlidingDRC1", m_orBoostedElectronC1) );
2393 if (m_orBoostedElectronC2 > 0) ATH_CHECK( m_orToolbox.eleJetORT.setProperty("SlidingDRC2", m_orBoostedElectronC2) );
2394 if (m_orBoostedElectronMaxConeSize > 0) ATH_CHECK( m_orToolbox.eleJetORT.setProperty("SlidingDRMaxCone", m_orBoostedElectronMaxConeSize) );
2395 }
2396 if (m_orDoBoostedMuon) {
2397 if (m_orBoostedMuonC1 > 0) ATH_CHECK( m_orToolbox.muJetORT.setProperty("SlidingDRC1", m_orBoostedMuonC1) );
2398 if (m_orBoostedMuonC2 > 0) ATH_CHECK( m_orToolbox.muJetORT.setProperty("SlidingDRC2", m_orBoostedMuonC2) );
2399 if (m_orBoostedMuonMaxConeSize > 0) ATH_CHECK( m_orToolbox.muJetORT.setProperty("SlidingDRMaxCone", m_orBoostedMuonMaxConeSize) );
2400 }
2401
2402 // and switch off lep-bjet check if not requested
2403 if (!m_orDoElBjet) {
2404 ATH_CHECK(m_orToolbox.eleJetORT.setProperty("BJetLabel", ""));
2405 }
2406 if (!m_orDoMuBjet) {
2407 ATH_CHECK(m_orToolbox.muJetORT.setProperty("BJetLabel", ""));
2408 }
2409
2410 // propagate the mu-jet ghost-association option which might be set by the user (default is true)
2411 ATH_CHECK(m_orToolbox.muJetORT.setProperty("UseGhostAssociation", m_orDoMuonJetGhostAssociation));
2412
2413 // propagate mu-jet OR settings if requested
2414 ATH_CHECK(m_orToolbox.muJetORT.setProperty("ApplyRelPt", m_orApplyRelPt) );
2415 if(m_orApplyRelPt){
2416 if (m_orMuJetPtRatio > 0) ATH_CHECK(m_orToolbox.muJetORT.setProperty("MuJetPtRatio", m_orMuJetPtRatio) );
2417 if (m_orMuJetTrkPtRatio > 0) ATH_CHECK(m_orToolbox.muJetORT.setProperty("MuJetTrkPtRatio", m_orMuJetTrkPtRatio) );
2418 }
2419 if (m_orMuJetInnerDR > 0) ATH_CHECK(m_orToolbox.muJetORT.setProperty("InnerDR", m_orMuJetInnerDR) );
2420
2421 // propagate the calo muon setting for EleMuORT
2422 ATH_CHECK(m_orToolbox.eleMuORT.setProperty("RemoveCaloMuons", m_orRemoveCaloMuons) );
2423
2424 // Use electron-muon DR matching to remove electrons within DR < 0.01 of Muons.
2425 if (m_orDoElMu){
2426 ATH_CHECK(m_orToolbox.eleMuORT.setProperty("UseDRMatching", m_orDoElMu) );
2427 }
2428
2429 // propagate the fatjets OR settings
2430 if(m_orDoFatjets){
2431 if(m_EleFatJetDR>0) ATH_CHECK(m_orToolbox.eleFatJetORT.setProperty("DR", m_EleFatJetDR));
2432 if(m_JetFatJetDR>0) ATH_CHECK(m_orToolbox.jetFatJetORT.setProperty("DR", m_JetFatJetDR));
2433 }
2434
2435 // Make sure that we deal with prorities correctly
2436 ATH_CHECK(m_orToolbox.eleJetORT.setProperty("EnableUserPriority", true));
2437 ATH_CHECK(m_orToolbox.muJetORT.setProperty("EnableUserPriority", true));
2438 if (m_orDoTau) ATH_CHECK(m_orToolbox.tauJetORT.setProperty("EnableUserPriority", true));
2439 if (m_orDoPhoton) ATH_CHECK(m_orToolbox.phoJetORT.setProperty("EnableUserPriority", true));
2440
2441 if ( m_orPhotonFavoured ) {
2442 ATH_CHECK(m_orToolbox.phoEleORT.setProperty("SwapContainerPrecedence", true));
2443 ATH_CHECK(m_orToolbox.phoMuORT.setProperty("SwapContainerPrecedence", true));
2444 }
2445
2446 if (!m_orDoEleJet){
2447 // Disable the electron removal part of e-j overlap removal
2448 ATH_CHECK( m_orToolbox.eleJetORT.setProperty("OuterDR",-1.) );
2449 ATH_CHECK( m_orToolbox.eleJetORT.setProperty("SlidingDRMaxCone",-1.) );
2450 }
2451 if (!m_orDoMuonJet){
2452 // Disable the muon removal part of m-j overlap removal
2453 ATH_CHECK( m_orToolbox.muJetORT.setProperty("OuterDR",-1.) );
2454 ATH_CHECK( m_orToolbox.muJetORT.setProperty("SlidingDRMaxCone",-1.) );
2455 }
2456
2457 ATH_CHECK( m_orToolbox.initialize() );
2458
2459 }
2460 // Done with the OR toolbox setup!
2461
2462// /////////////////////////////////////////////////////////////////////////////////////////
2463// Initialise PMG Tools
2464 if (!m_pmgSHnjetWeighter.isUserConfigured() && !isData()) {
2465 m_pmgSHnjetWeighter.setTypeAndName("PMGTools::PMGSherpa22VJetsWeightTool/PMGSHVjetReweighter");
2466 ATH_CHECK( m_pmgSHnjetWeighter.setProperty( "TruthJetContainer", "AntiKt4TruthJets"));
2467 ATH_CHECK( m_pmgSHnjetWeighter.setProperty("OutputLevel", this->msg().level()) );
2468 ATH_CHECK( m_pmgSHnjetWeighter.retrieve());
2469 } else if (m_pmgSHnjetWeighter.isUserConfigured()) ATH_CHECK( m_pmgSHnjetWeighter.retrieve());
2470
2471
2472 if (!m_pmgSHnjetWeighterWZ.isUserConfigured() && !isData()) {
2473 m_pmgSHnjetWeighterWZ.setTypeAndName("PMGTools::PMGSherpa22VJetsWeightTool/PMGSHVjetReweighterWZ");
2474 ATH_CHECK( m_pmgSHnjetWeighterWZ.setProperty( "TruthJetContainer", "AntiKt4TruthWZJets"));
2475 ATH_CHECK( m_pmgSHnjetWeighterWZ.setProperty("OutputLevel", this->msg().level()) );
2476 ATH_CHECK( m_pmgSHnjetWeighterWZ.retrieve() );
2477 } else if (m_pmgSHnjetWeighterWZ.isUserConfigured()) ATH_CHECK( m_pmgSHnjetWeighterWZ.retrieve() );
2478
2479
2480 // prevent these initialiation snippets from being run again
2481 m_subtool_init = true;
2482
2483 ATH_MSG_INFO("Done initialising SUSYTools");
2484
2485 return StatusCode::SUCCESS;
2486}
#define ANA_MSG_DEBUG(xmsg)
Macro printing debug messages.
const std::string bJetLabel
#define CONFIG_EG_EFF_TOOL(TOOLHANDLE, TOOLNAME, CORRFILE)
#define CONFIG_EG_EFF_TOOL_KEY(TOOLHANDLE, TOOLNAME, KEYNAME, KEY, MAP)
if(pathvar)
static StatusCode setProperty(const GaudiHandleBase &toolHandle, const std::string &property, const int &value, bool override=true)
std::string m_fatJetUncertaintiesMCType
std::vector< asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > > m_elecEfficiencySFTool_trig_mixLep
std::string m_eleEffMapFilePathRun2
std::vector< asg::AnaToolHandle< IAsgElectronEfficiencyCorrectionTool > > m_elecEfficiencySFTool_trigEff_mixLep
std::map< std::string, std::string > m_legsPerTool_ph
std::vector< asg::AnaToolHandle< IAsgPhotonEfficiencyCorrectionTool > > m_photonEfficiencySFTool_trigSF_AsymDiphoton
std::string EG_WP(const std::string &wp) const
bool check_isOption(const std::string &wp, const std::vector< std::string > &list) const
std::vector< std::string > getElSFkeys(const std::string &mapFile) const
std::map< std::string, std::string > m_legsPerTool
std::vector< asg::AnaToolHandle< IAsgPhotonEfficiencyCorrectionTool > > m_photonEfficiencySFTool_trigEff_AsymDiphoton
StatusCode recommendedTools(const ORFlags &flags, ToolBox &toolBox)
Pre-configured standard recommended OR tools.
setRawEt setRawPhi int

◆ sysInitialize()

StatusCode asg::AsgMetadataTool::sysInitialize ( )
virtualinherited

Function initialising the tool in the correct way in Athena.

This function is used to set up the callbacks from IncidentSvc in Athena at the right time during initialisation, without the user having to do anything special in his/her code.

Reimplemented from AthCommonDataStore< AthCommonMsg< AlgTool > >.

Definition at line 115 of file AsgMetadataTool.cxx.

115 {
116
117#ifndef XAOD_STANDALONE
118 if (m_useIncidents) {
119 // Connect to the IncidentSvc:
120 ServiceHandle< IIncidentSvc > incSvc( "IncidentSvc", name() );
121 ATH_CHECK( incSvc.retrieve() );
122
123 // Set up the right callbacks: don't rethrow exceptions, any failure and we should end
124 incSvc->addListener( this, IncidentType::BeginEvent, 0, false );
125 }
126 // Let the base class do its thing:
127 ATH_CHECK( AlgTool::sysInitialize() );
128
129#endif // not XAOD_STANDALONE
130
131 // Return gracefully:
132 return StatusCode::SUCCESS;
133 }

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ treatAsYear()

int ST::SUSYObjDef_xAOD::treatAsYear ( const int runNumber = -1) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 3175 of file SUSYObjDef_xAOD.cxx.

3175 {
3176 // Use the run number we are passed if we are passed one, otherwise
3177 // use the run number from the GetRunNumber function
3178 int theRunNumber = runNumber>0?runNumber:GetRunNumber();
3179 if (theRunNumber<290000) return 2015;
3180 else if (theRunNumber<320000) return 2016;
3181 else if (theRunNumber<342000) return 2017;
3182 else if (theRunNumber<400000) return 2018;
3183 else if (theRunNumber<445000) return 2022;
3184 else if (theRunNumber<465000) return 2023;
3185 else if (theRunNumber<490000) return 2024;
3186 else if (theRunNumber<510000) return 2025;
3187 return 2026;
3188}

◆ TrigMatch() [1/10]

void ST::SUSYObjDef_xAOD::TrigMatch ( const std::initializer_list< const xAOD::IParticle * > & v,
const std::initializer_list< std::string > & items )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 261 of file Trigger.cxx.

261 {
262 for(const auto& p : v) {
263 this->TrigMatch(p, items);
264 }
265}

◆ TrigMatch() [2/10]

void ST::SUSYObjDef_xAOD::TrigMatch ( const std::initializer_list< const xAOD::IParticle * > & v,
const std::string & item )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 299 of file Trigger.cxx.

299 {
300 return this->TrigMatch(v, {item});
301}

◆ TrigMatch() [3/10]

void ST::SUSYObjDef_xAOD::TrigMatch ( const std::initializer_list< const xAOD::IParticle * > & v,
const std::vector< std::string > & items )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 268 of file Trigger.cxx.

268 {
269 for(const auto& p : v) {
270 this->TrigMatch(p, items);
271 }
272}

◆ TrigMatch() [4/10]

void ST::SUSYObjDef_xAOD::TrigMatch ( const xAOD::IParticle * p,
const std::initializer_list< std::string > & items )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 244 of file Trigger.cxx.

244 {
245 this->TrigMatch(p, items.begin(), items.end());
246}

◆ TrigMatch() [5/10]

void ST::SUSYObjDef_xAOD::TrigMatch ( const xAOD::IParticle * p,
const std::string & item )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 289 of file Trigger.cxx.

289 {
290 return this->TrigMatch(p, {item});
291}

◆ TrigMatch() [6/10]

void ST::SUSYObjDef_xAOD::TrigMatch ( const xAOD::IParticle * p,
const std::vector< std::string > & items )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 249 of file Trigger.cxx.

249 {
250 dec_trigmatched(*p) = 0;
251
252 for(const auto& item: items) {
253 auto result = static_cast<int>(this->IsTrigMatched(p, item));
254 dec_trigmatched(*p) += result;
255 const SG::Decorator<char> dec(item);
256 dec(*p) = result;
257 }
258}
static const SG::Decorator< char > dec_trigmatched("trigmatched")

◆ TrigMatch() [7/10]

void ST::SUSYObjDef_xAOD::TrigMatch ( const xAOD::IParticle * p,
std::initializer_list< std::string >::iterator i1,
std::initializer_list< std::string >::iterator i2 )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 232 of file Trigger.cxx.

232 {
233 dec_trigmatched(*p) = 0;
234
235 for(const auto *it = i1; it != i2; ++it) {
236 auto result = static_cast<int>(this->IsTrigMatched(p, *it));
237 dec_trigmatched(*p) += result;
238 const SG::Decorator<char> dec(*it);
239 dec(*p) = result;
240 }
241}

◆ TrigMatch() [8/10]

void ST::SUSYObjDef_xAOD::TrigMatch ( const xAOD::IParticleContainer * v,
const std::initializer_list< std::string > & items )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 282 of file Trigger.cxx.

282 {
283 for(const auto p : *v) {
284 this->TrigMatch(p, items);
285 }
286}

◆ TrigMatch() [9/10]

void ST::SUSYObjDef_xAOD::TrigMatch ( const xAOD::IParticleContainer * v,
const std::string & item )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 294 of file Trigger.cxx.

294 {
295 return this->TrigMatch(v, {item});
296}

◆ TrigMatch() [10/10]

void ST::SUSYObjDef_xAOD::TrigMatch ( const xAOD::IParticleContainer * v,
const std::vector< std::string > & items )
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 275 of file Trigger.cxx.

275 {
276 for(const auto p : *v) {
277 this->TrigMatch(p, items);
278 }
279}

◆ TrigSingleLep()

std::string ST::SUSYObjDef_xAOD::TrigSingleLep ( ) const
finaloverridevirtual

Implements ST::ISUSYObjDef_xAODTool.

Definition at line 2153 of file SUSYObjDef_xAOD.cxx.

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::updateVHKA ( Gaudi::Details::PropertyBase & )
inlineinherited

Definition at line 308 of file AthCommonDataStore.h.

308 {
309 // debug() << "updateVHKA for property " << p.name() << " " << p.toString()
310 // << " size: " << m_vhka.size() << endmsg;
311 for (auto &a : m_vhka) {
313 for (auto k : keys) {
314 k->setOwner(this);
315 }
316 }
317 }
std::vector< SG::VarHandleKeyArray * > m_vhka

◆ validConfig()

StatusCode ST::SUSYObjDef_xAOD::validConfig ( bool strict = false) const
protected

baseline vs signal pt check

WP check

check pt and eta range

Definition at line 2016 of file SUSYObjDef_xAOD.cxx.

2016 {
2017 // Validate configuration (i.e. that signal settings are tighter than baseline, etc)
2018 // :: Throw SC::FAILURE if strict mode is enabled, just a WARNING if not
2019
2020 // Electrons
2021 if( m_elePt < m_eleBaselinePt ){
2022 ATH_MSG_WARNING("Your electron pt configuration is inconsistent! Signal : " << m_elePt << " < Baseline : " << m_eleBaselinePt);
2023 if(strict) return StatusCode::FAILURE;
2024 }
2025 if( m_eleEta > m_eleBaselineEta ){
2026 ATH_MSG_WARNING("Your electron eta configuration is inconsistent! Signal : " << m_eleEta << " < Baseline : " << m_eleBaselineEta);
2027 if(strict) return StatusCode::FAILURE;
2028 }
2029
2031 ATH_MSG_WARNING("Your electron ID configuration is inconsistent! Signal : " << m_eleId << " looser than Baseline : " << m_eleIdBaseline);
2032 if(strict) return StatusCode::FAILURE;
2033 }
2035 ATH_MSG_WARNING("Your electron crack removal is inconsistent! Signal : " << m_eleCrackVeto << " while Baseline : " << m_eleBaselineCrackVeto);
2036 if(strict) return StatusCode::FAILURE;
2037 }
2038
2039 // Muons
2040 if( m_muPt < m_muBaselinePt ){
2041 ATH_MSG_WARNING("Your muon pt configuration is inconsistent! Signal : " << m_muPt << " < Baseline : " << m_muBaselinePt);
2042 if(strict) return StatusCode::FAILURE;
2043 }
2044 if( m_muEta > m_muBaselineEta ){
2045 ATH_MSG_WARNING("Your muon eta configuration is inconsistent! Signal : " << m_muEta << " < Baseline : " << m_muBaselineEta);
2046 if(strict) return StatusCode::FAILURE;
2047 }
2048 if( m_muId > m_muIdBaseline ){
2049 ATH_MSG_WARNING("Your muon ID configuration is inconsistent! Signal : " << m_muId << " < Baseline : " << m_muIdBaseline);
2050 if(strict) return StatusCode::FAILURE;
2051 }
2052
2053 // Photons
2055 ATH_MSG_WARNING("Your photon pt configuration is inconsistent! Signal : " << m_photonPt << " < Baseline : " << m_photonBaselinePt);
2056 if(strict) return StatusCode::FAILURE;
2057 }
2059 ATH_MSG_WARNING("Your photon eta configuration is inconsistent! Signal : " << m_photonEta << " < Baseline : " << m_photonBaselineEta);
2060 if(strict) return StatusCode::FAILURE;
2061 }
2062 if( m_photonId=="Loose" && m_photonIdBaseline=="Tight" ){
2063 ATH_MSG_WARNING("Your photon ID configuration is inconsistent! Signal : " << m_photonId << " < Baseline : " << m_photonIdBaseline);
2064 if(strict) return StatusCode::FAILURE;
2065 }
2067 ATH_MSG_WARNING("Your photon crack removal is inconsistent! Signal : " << m_photonCrackVeto << " while Baseline : " << m_photonBaselineCrackVeto);
2068 if(strict) return StatusCode::FAILURE;
2069 }
2070
2071 // Jets
2072 if ( m_jetPt < 20e3 ){
2073 ATH_MSG_WARNING("Your minimum signal jet pt is less than 20 GeV! Jet.Pt : " << m_jetPt << ". This is NOT supported by the jet group!");
2074 }
2075
2076 //Btagging //OR-wp looser than signal-wp?
2077 if( m_BtagWP.compare(0, m_BtagWP.size()-3, m_orBtagWP, 0, m_BtagWP.size()-3) == 0 ){ //same tagger WP (FixedCutBEff_XX or HybBEff_XX)
2078 if( atoi(m_BtagWP.substr(m_BtagWP.size()-2, m_BtagWP.size()).c_str()) > atoi(m_orBtagWP.substr(m_orBtagWP.size()-2, m_orBtagWP.size()).c_str()) ){
2079 ATH_MSG_WARNING("Your btagging configuration is inconsistent! Signal : " << m_BtagWP << " is looser than OR-Baseline : " << m_orBtagWP);
2080 }
2081 }
2082 if (m_BtagMinPt < 20e3 || m_BtagMinPt_trkJet < 10e3) {
2083 ATH_MSG_WARNING("You btagging MinPt settings are inconsistent! EM(Topo|PFlow)Jets: not calibrated below 20 GeV (Btag.MinPt: " << m_BtagMinPt/1000. << " GeV set), VRTrackJets: not calibrated below 10 GeV (BtagTrkJet.MinPt: " << m_BtagMinPt_trkJet/1000. << " GeV set).");
2084 }
2085
2086 //Taus
2088 if(m_tauPrePtCut > 0 and m_tauPrePtCut > m_tauPt) {
2089 ATH_MSG_WARNING("Your tau pt configuration is inconsistent! Signal pt cut : " << m_tauPt << " < Baseline (pre) pt cut : " << m_tauPrePtCut);
2090 if(strict) return StatusCode::FAILURE;
2091 }
2094 ATH_MSG_WARNING("Your tau ID configuration is inconsistent! Signal : " << m_tauId << " looser than Baseline : " << m_tauIdBaseline);
2095 if(strict) return StatusCode::FAILURE;
2096 }
2097
2099 std::vector<float> pT_window;
2100 std::vector<float> eta_window;
2101 bool elOLR=false;
2102 bool muVeto=false;
2103 bool muOLR=false;
2104
2105 if(!m_tauConfigPathBaseline.empty()) { //baseline taus
2106
2107 //read config
2108 ANA_CHECK(getTauConfig(m_tauInputFileBaseline, pT_window, eta_window, elOLR, muVeto, muOLR));
2109
2110 //pt-eta checks
2111 if( m_tauPrePtCut > 0 and (m_tauPrePtCut != 1000*pT_window[0] or (pT_window[1] > 0 and m_tauPrePtCut > 1000*pT_window[1]))) {
2112 ATH_MSG_WARNING("Your baseline tau pt configuration is inconsistent! pre pT cut : " << m_tauPrePtCut << " / TauSelectionTool window (in MeV) : [" << 1000*pT_window[0] << ", " << 1000*pT_window[1] << "]");
2113 if(strict) return StatusCode::FAILURE;
2114 }
2115
2116 if( m_tauPt > 0 and (m_tauPt != 1000*pT_window[0] or (pT_window[1] > 0 and m_tauPt > 1000*pT_window[1]))) {
2117 ATH_MSG_WARNING("Your baseline tau pt configuration is inconsistent! pT cut : " << m_tauPt << " / TauSelectionTool window (in Mev) : [" << 1000*pT_window[0] << ", " << 1000*pT_window[1] << "]");
2118 if(strict) return StatusCode::FAILURE;
2119 }
2120
2121 if( m_tauEta > 0 and m_tauEta != eta_window[eta_window.size()-1]) { // eta window can have 4 entries
2122 ATH_MSG_WARNING("Your baseline tau eta configuration is inconsistent! eta cut : " << m_tauEta << " != TauSelectionTool max eta : " << eta_window[eta_window.size()-1]);
2123 if(strict) return StatusCode::FAILURE;
2124 }
2125 }
2126
2127 if(!m_tauConfigPath.empty()) { //signal taus
2128
2129 ANA_CHECK(getTauConfig(m_tauInputFile, pT_window, eta_window, elOLR, muVeto, muOLR));
2130
2131 if( m_tauPrePtCut > 0 and (m_tauPrePtCut != 1000*pT_window[0] or (pT_window[1] > 0 and m_tauPrePtCut > 1000*pT_window[1]))) {
2132 ATH_MSG_WARNING("Your tau pt configuration is inconsistent! pre pT cut : " << m_tauPrePtCut << " / TauSelectionTool window (in MeV) : [" << 1000*pT_window[0] << ", " << 1000*pT_window[1] << "]");
2133 if(strict) return StatusCode::FAILURE;
2134 }
2135
2136 if( m_tauPt > 0 and (m_tauPt != 1000*pT_window[0] or (pT_window[1] > 0 and m_tauPt > 1000*pT_window[1]))) {
2137 ATH_MSG_WARNING("Your tau pt configuration is inconsistent! pT cut : " << m_tauPt << " / TauSelectionTool window (in Mev) : [" << 1000*pT_window[0] << ", " << 1000*pT_window[1] << "]");
2138 if(strict) return StatusCode::FAILURE;
2139 }
2140
2141 if( m_tauEta > 0 and m_tauEta != eta_window[eta_window.size()-1]) { // eta window can have 4 entries
2142 ATH_MSG_WARNING("Your tau eta configuration is inconsistent! eta cut : " << m_tauEta << " != TauSelectionTool max eta : " << eta_window[eta_window.size()-1]);
2143 if(strict) return StatusCode::FAILURE;
2144 }
2145 }
2146
2147
2148 return StatusCode::SUCCESS;
2149}
#define ANA_CHECK(EXP)
check whether the given expression was successful
bool check_isTighter(const std::string &wp1, const std::string &wp, const std::vector< std::string > &list) const
StatusCode getTauConfig(const std::string &tauConfigPath, std::vector< float > &pT_window, std::vector< float > &eta_window, bool &eleOLR, bool &muVeto, bool &muOLR) const
int atoi(std::string_view str)
Helper functions to unpack numbers decoded in string into integers and doubles The strings are requir...

Member Data Documentation

◆ ATLAS_THREAD_SAFE [1/2]

std::map<std::string, bool> m_checkedTriggers ST::SUSYObjDef_xAOD::ATLAS_THREAD_SAFE
mutableprivate

Definition at line 445 of file SUSYObjDef_xAOD.h.

◆ ATLAS_THREAD_SAFE [2/2]

std::map<std::string, std::function<bool()> > m_metTriggerFuncs ST::SUSYObjDef_xAOD::ATLAS_THREAD_SAFE
mutableprivate

Definition at line 443 of file SUSYObjDef_xAOD.h.

◆ lrt_electrons

const xAOD::ElectronContainer* ST::SUSYObjDef_xAOD::lrt_electrons = nullptr

Definition at line 212 of file SUSYObjDef_xAOD.h.

◆ lrt_muons

const xAOD::MuonContainer* ST::SUSYObjDef_xAOD::lrt_muons = nullptr

Definition at line 206 of file SUSYObjDef_xAOD.h.

◆ m_acc_eleId

SG::ConstAccessor<char> ST::SUSYObjDef_xAOD::m_acc_eleId
protected

Definition at line 1005 of file SUSYObjDef_xAOD.h.

◆ m_acc_eleIdBaseline

SG::ConstAccessor<char> ST::SUSYObjDef_xAOD::m_acc_eleIdBaseline
protected

Definition at line 1004 of file SUSYObjDef_xAOD.h.

◆ m_acc_jetClean

SG::ConstAccessor<char> ST::SUSYObjDef_xAOD::m_acc_jetClean
protected

Definition at line 1008 of file SUSYObjDef_xAOD.h.

◆ m_acc_photonId

SG::ConstAccessor<char> ST::SUSYObjDef_xAOD::m_acc_photonId
protected

Definition at line 1007 of file SUSYObjDef_xAOD.h.

◆ m_acc_photonIdBaseline

SG::ConstAccessor<char> ST::SUSYObjDef_xAOD::m_acc_photonIdBaseline
protected

Definition at line 1006 of file SUSYObjDef_xAOD.h.

◆ m_applyJVTCut

bool ST::SUSYObjDef_xAOD::m_applyJVTCut
protected

Definition at line 831 of file SUSYObjDef_xAOD.h.

◆ m_ApplyMVATESQualityCheck

bool ST::SUSYObjDef_xAOD::m_ApplyMVATESQualityCheck
protected

Definition at line 746 of file SUSYObjDef_xAOD.h.

◆ m_autoconfigPRW

bool ST::SUSYObjDef_xAOD::m_autoconfigPRW
protected

Definition at line 596 of file SUSYObjDef_xAOD.h.

◆ m_autoconfigPRWCombinedmode

bool ST::SUSYObjDef_xAOD::m_autoconfigPRWCombinedmode
protected

Definition at line 599 of file SUSYObjDef_xAOD.h.

◆ m_autoconfigPRWFile

std::string ST::SUSYObjDef_xAOD::m_autoconfigPRWFile
protected

Definition at line 598 of file SUSYObjDef_xAOD.h.

◆ m_autoconfigPRWPath

std::string ST::SUSYObjDef_xAOD::m_autoconfigPRWPath
protected

Definition at line 597 of file SUSYObjDef_xAOD.h.

◆ m_autoconfigPRWRPVmode

bool ST::SUSYObjDef_xAOD::m_autoconfigPRWRPVmode
protected

Definition at line 600 of file SUSYObjDef_xAOD.h.

◆ m_autoconfigPRWRtags

std::string ST::SUSYObjDef_xAOD::m_autoconfigPRWRtags
protected

Definition at line 601 of file SUSYObjDef_xAOD.h.

◆ m_badJetCut

std::string ST::SUSYObjDef_xAOD::m_badJetCut
protected

Definition at line 544 of file SUSYObjDef_xAOD.h.

◆ m_badmuQoverP

double ST::SUSYObjDef_xAOD::m_badmuQoverP
protected

Definition at line 724 of file SUSYObjDef_xAOD.h.

◆ m_beginInputFileCalled

bool asg::AsgMetadataTool::m_beginInputFileCalled
privateinherited

Flag helping to discover when the tool misses the opening of the first input file.

Definition at line 126 of file AsgMetadataTool.h.

◆ m_bool_prop_set

std::set<std::string> ST::SUSYObjDef_xAOD::m_bool_prop_set
private

Definition at line 439 of file SUSYObjDef_xAOD.h.

◆ m_btagEffTool

asg::AnaToolHandle<IBTaggingEfficiencyTool> ST::SUSYObjDef_xAOD::m_btagEffTool
protected

Definition at line 933 of file SUSYObjDef_xAOD.h.

◆ m_btagEffTool_trkJet

asg::AnaToolHandle<IBTaggingEfficiencyTool> ST::SUSYObjDef_xAOD::m_btagEffTool_trkJet
protected

Definition at line 936 of file SUSYObjDef_xAOD.h.

◆ m_bTaggingCalibrationFilePath

std::string ST::SUSYObjDef_xAOD::m_bTaggingCalibrationFilePath
protected

Definition at line 833 of file SUSYObjDef_xAOD.h.

◆ m_BtagMinPt

double ST::SUSYObjDef_xAOD::m_BtagMinPt
protected

Definition at line 685 of file SUSYObjDef_xAOD.h.

◆ m_BtagMinPt_trkJet

double ST::SUSYObjDef_xAOD::m_BtagMinPt_trkJet
protected

Definition at line 693 of file SUSYObjDef_xAOD.h.

◆ m_BtagReadFromObject

bool ST::SUSYObjDef_xAOD::m_BtagReadFromObject
protected

Definition at line 690 of file SUSYObjDef_xAOD.h.

◆ m_BtagReadFromObject_trkJet

bool ST::SUSYObjDef_xAOD::m_BtagReadFromObject_trkJet
protected

Definition at line 694 of file SUSYObjDef_xAOD.h.

◆ m_btagSelTool

asg::AnaToolHandle<IBTaggingSelectionTool> ST::SUSYObjDef_xAOD::m_btagSelTool
protected

Definition at line 934 of file SUSYObjDef_xAOD.h.

◆ m_btagSelTool_OR

asg::AnaToolHandle<IBTaggingSelectionTool> ST::SUSYObjDef_xAOD::m_btagSelTool_OR
protected

Definition at line 935 of file SUSYObjDef_xAOD.h.

◆ m_btagSelTool_trkJet

asg::AnaToolHandle<IBTaggingSelectionTool> ST::SUSYObjDef_xAOD::m_btagSelTool_trkJet
protected

Definition at line 937 of file SUSYObjDef_xAOD.h.

◆ m_BtagSystStrategy

std::string ST::SUSYObjDef_xAOD::m_BtagSystStrategy
protected

Definition at line 686 of file SUSYObjDef_xAOD.h.

◆ m_BtagTagger

std::string ST::SUSYObjDef_xAOD::m_BtagTagger
protected

Definition at line 684 of file SUSYObjDef_xAOD.h.

◆ m_BtagTagger_trkJet

std::string ST::SUSYObjDef_xAOD::m_BtagTagger_trkJet
protected

Definition at line 692 of file SUSYObjDef_xAOD.h.

◆ m_BtagWP

std::string ST::SUSYObjDef_xAOD::m_BtagWP
protected

Definition at line 683 of file SUSYObjDef_xAOD.h.

◆ m_BtagWP_trkJet

std::string ST::SUSYObjDef_xAOD::m_BtagWP_trkJet
protected

Definition at line 691 of file SUSYObjDef_xAOD.h.

◆ m_caloMETsyst

bool ST::SUSYObjDef_xAOD::m_caloMETsyst
protected

Definition at line 589 of file SUSYObjDef_xAOD.h.

◆ m_commonPRWFileMC20a

std::string ST::SUSYObjDef_xAOD::m_commonPRWFileMC20a
protected

Definition at line 606 of file SUSYObjDef_xAOD.h.

◆ m_commonPRWFileMC20d

std::string ST::SUSYObjDef_xAOD::m_commonPRWFileMC20d
protected

Definition at line 607 of file SUSYObjDef_xAOD.h.

◆ m_commonPRWFileMC20e

std::string ST::SUSYObjDef_xAOD::m_commonPRWFileMC20e
protected

Definition at line 608 of file SUSYObjDef_xAOD.h.

◆ m_commonPRWFileMC23a

std::string ST::SUSYObjDef_xAOD::m_commonPRWFileMC23a
protected

Definition at line 609 of file SUSYObjDef_xAOD.h.

◆ m_commonPRWFileMC23d

std::string ST::SUSYObjDef_xAOD::m_commonPRWFileMC23d
protected

Definition at line 610 of file SUSYObjDef_xAOD.h.

◆ m_commonPRWFileMC23e

std::string ST::SUSYObjDef_xAOD::m_commonPRWFileMC23e
protected

Definition at line 611 of file SUSYObjDef_xAOD.h.

◆ m_commonPRWFileMC23g

std::string ST::SUSYObjDef_xAOD::m_commonPRWFileMC23g
protected

Definition at line 612 of file SUSYObjDef_xAOD.h.

◆ m_conf_to_prop

std::map<std::string, std::string> ST::SUSYObjDef_xAOD::m_conf_to_prop
private

Definition at line 436 of file SUSYObjDef_xAOD.h.

◆ m_configFile

std::string ST::SUSYObjDef_xAOD::m_configFile
protected

Definition at line 522 of file SUSYObjDef_xAOD.h.

◆ m_currentSyst

CP::SystematicSet ST::SUSYObjDef_xAOD::m_currentSyst
protected

Definition at line 826 of file SUSYObjDef_xAOD.h.

◆ m_dataSource

int ST::SUSYObjDef_xAOD::m_dataSource
protected

Definition at line 519 of file SUSYObjDef_xAOD.h.

◆ m_deadHVTool

asg::AnaToolHandle<IAsgDeadHVCellRemovalTool> ST::SUSYObjDef_xAOD::m_deadHVTool
protected

Definition at line 912 of file SUSYObjDef_xAOD.h.

◆ m_debug

bool ST::SUSYObjDef_xAOD::m_debug
protected

Definition at line 540 of file SUSYObjDef_xAOD.h.

◆ m_defaultJets

std::string ST::SUSYObjDef_xAOD::m_defaultJets
protected

Definition at line 820 of file SUSYObjDef_xAOD.h.

◆ m_defaultSyst

CP::SystematicSet ST::SUSYObjDef_xAOD::m_defaultSyst = CP::SystematicSet()
protected

Definition at line 825 of file SUSYObjDef_xAOD.h.

◆ m_defaultTrackJets

std::string ST::SUSYObjDef_xAOD::m_defaultTrackJets
protected

Definition at line 821 of file SUSYObjDef_xAOD.h.

◆ m_defaultTruthJets

std::string ST::SUSYObjDef_xAOD::m_defaultTruthJets
protected

Definition at line 823 of file SUSYObjDef_xAOD.h.

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default).

Definition at line 393 of file AthCommonDataStore.h.

◆ m_doElIsoSignal

bool ST::SUSYObjDef_xAOD::m_doElIsoSignal
protected

Definition at line 805 of file SUSYObjDef_xAOD.h.

◆ m_doFwdJVT

bool ST::SUSYObjDef_xAOD::m_doFwdJVT
protected

Definition at line 760 of file SUSYObjDef_xAOD.h.

◆ m_doIsoSignal

bool ST::SUSYObjDef_xAOD::m_doIsoSignal
protected

Definition at line 804 of file SUSYObjDef_xAOD.h.

◆ m_doModifiedEleId

bool ST::SUSYObjDef_xAOD::m_doModifiedEleId
protected

Definition at line 527 of file SUSYObjDef_xAOD.h.

◆ m_doMuIsoSignal

bool ST::SUSYObjDef_xAOD::m_doMuIsoSignal
protected

Definition at line 807 of file SUSYObjDef_xAOD.h.

◆ m_doPhiReso

bool ST::SUSYObjDef_xAOD::m_doPhiReso
protected

Definition at line 594 of file SUSYObjDef_xAOD.h.

◆ m_doPhIsoSignal

bool ST::SUSYObjDef_xAOD::m_doPhIsoSignal
protected

Definition at line 806 of file SUSYObjDef_xAOD.h.

◆ m_doTTVAsf

bool ST::SUSYObjDef_xAOD::m_doTTVAsf
protected

Definition at line 526 of file SUSYObjDef_xAOD.h.

◆ m_EG_corrFNList

std::string ST::SUSYObjDef_xAOD::m_EG_corrFNList
protected

Definition at line 830 of file SUSYObjDef_xAOD.h.

◆ m_EG_corrModel

std::string ST::SUSYObjDef_xAOD::m_EG_corrModel
protected

Definition at line 829 of file SUSYObjDef_xAOD.h.

◆ m_egammaAmbiguityTool

asg::AnaToolHandle<IEGammaAmbiguityTool> ST::SUSYObjDef_xAOD::m_egammaAmbiguityTool
protected

Definition at line 922 of file SUSYObjDef_xAOD.h.

◆ m_egammaCalibTool

asg::AnaToolHandle<CP::IEgammaCalibrationAndSmearingTool> ST::SUSYObjDef_xAOD::m_egammaCalibTool
protected

Combined electron collection.

Definition at line 907 of file SUSYObjDef_xAOD.h.

◆ m_EigenvectorReductionB

std::string ST::SUSYObjDef_xAOD::m_EigenvectorReductionB
protected

Definition at line 687 of file SUSYObjDef_xAOD.h.

◆ m_EigenvectorReductionC

std::string ST::SUSYObjDef_xAOD::m_EigenvectorReductionC
protected

Definition at line 688 of file SUSYObjDef_xAOD.h.

◆ m_EigenvectorReductionLight

std::string ST::SUSYObjDef_xAOD::m_EigenvectorReductionLight
protected

Definition at line 689 of file SUSYObjDef_xAOD.h.

◆ m_el_id_support

std::vector<std::string> ST::SUSYObjDef_xAOD::m_el_id_support
protected

Definition at line 629 of file SUSYObjDef_xAOD.h.

◆ m_el_iso_fallback

std::map<std::string, std::string> ST::SUSYObjDef_xAOD::m_el_iso_fallback
protected

Definition at line 637 of file SUSYObjDef_xAOD.h.

◆ m_el_iso_support

std::vector<std::string> ST::SUSYObjDef_xAOD::m_el_iso_support
protected

Definition at line 633 of file SUSYObjDef_xAOD.h.

◆ m_eleAllowRun3TrigSFFallback

bool ST::SUSYObjDef_xAOD::m_eleAllowRun3TrigSFFallback
protected

Definition at line 709 of file SUSYObjDef_xAOD.h.

◆ m_eleBaselineCrackVeto

bool ST::SUSYObjDef_xAOD::m_eleBaselineCrackVeto
protected

Definition at line 699 of file SUSYObjDef_xAOD.h.

◆ m_elebaselined0sig

double ST::SUSYObjDef_xAOD::m_elebaselined0sig
protected

Definition at line 705 of file SUSYObjDef_xAOD.h.

◆ m_eleBaselineEta

double ST::SUSYObjDef_xAOD::m_eleBaselineEta
protected

Definition at line 698 of file SUSYObjDef_xAOD.h.

◆ m_eleBaselineIso_WP

std::string ST::SUSYObjDef_xAOD::m_eleBaselineIso_WP
protected

Definition at line 650 of file SUSYObjDef_xAOD.h.

◆ m_eleBaselinePt

double ST::SUSYObjDef_xAOD::m_eleBaselinePt
protected

Definition at line 697 of file SUSYObjDef_xAOD.h.

◆ m_elebaselinez0

double ST::SUSYObjDef_xAOD::m_elebaselinez0
protected

Definition at line 706 of file SUSYObjDef_xAOD.h.

◆ m_elecChargeEffCorrTool

asg::AnaToolHandle<IAsgElectronEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_elecChargeEffCorrTool
protected

Definition at line 924 of file SUSYObjDef_xAOD.h.

◆ m_elecChargeIDSelectorTool

asg::AnaToolHandle<IAsgElectronLikelihoodTool> ST::SUSYObjDef_xAOD::m_elecChargeIDSelectorTool
protected

Definition at line 923 of file SUSYObjDef_xAOD.h.

◆ m_elecEfficiencySFTool_chf

asg::AnaToolHandle<IAsgElectronEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_elecEfficiencySFTool_chf
protected

Definition at line 897 of file SUSYObjDef_xAOD.h.

◆ m_elecEfficiencySFTool_id

asg::AnaToolHandle<IAsgElectronEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_elecEfficiencySFTool_id
protected

Definition at line 892 of file SUSYObjDef_xAOD.h.

◆ m_elecEfficiencySFTool_iso

asg::AnaToolHandle<IAsgElectronEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_elecEfficiencySFTool_iso
protected

Definition at line 895 of file SUSYObjDef_xAOD.h.

◆ m_elecEfficiencySFTool_isoHighPt

asg::AnaToolHandle<IAsgElectronEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_elecEfficiencySFTool_isoHighPt
protected

Definition at line 896 of file SUSYObjDef_xAOD.h.

◆ m_elecEfficiencySFTool_reco

asg::AnaToolHandle<IAsgElectronEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_elecEfficiencySFTool_reco
protected

Combined muon collection.

Definition at line 891 of file SUSYObjDef_xAOD.h.

◆ m_elecEfficiencySFTool_trig_mixLep

std::vector<asg::AnaToolHandle<IAsgElectronEfficiencyCorrectionTool> > ST::SUSYObjDef_xAOD::m_elecEfficiencySFTool_trig_mixLep
protected

Definition at line 899 of file SUSYObjDef_xAOD.h.

◆ m_elecEfficiencySFTool_trig_singleLep

asg::AnaToolHandle<IAsgElectronEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_elecEfficiencySFTool_trig_singleLep
protected

Definition at line 893 of file SUSYObjDef_xAOD.h.

◆ m_elecEfficiencySFTool_trigEff_mixLep

std::vector<asg::AnaToolHandle<IAsgElectronEfficiencyCorrectionTool> > ST::SUSYObjDef_xAOD::m_elecEfficiencySFTool_trigEff_mixLep
protected

Definition at line 900 of file SUSYObjDef_xAOD.h.

◆ m_elecEfficiencySFTool_trigEff_singleLep

asg::AnaToolHandle<IAsgElectronEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_elecEfficiencySFTool_trigEff_singleLep
protected

Definition at line 894 of file SUSYObjDef_xAOD.h.

◆ m_eleChID_signal

bool ST::SUSYObjDef_xAOD::m_eleChID_signal
protected

Definition at line 670 of file SUSYObjDef_xAOD.h.

◆ m_eleChID_WP

std::string ST::SUSYObjDef_xAOD::m_eleChID_WP
protected

Definition at line 666 of file SUSYObjDef_xAOD.h.

◆ m_eleChIso

bool ST::SUSYObjDef_xAOD::m_eleChIso
protected

Definition at line 669 of file SUSYObjDef_xAOD.h.

◆ m_elecLRTORTool

asg::AnaToolHandle<CP::IElectronLRTOverlapRemovalTool> ST::SUSYObjDef_xAOD::m_elecLRTORTool
protected

Definition at line 903 of file SUSYObjDef_xAOD.h.

◆ m_eleConfig

std::string ST::SUSYObjDef_xAOD::m_eleConfig
protected

Definition at line 648 of file SUSYObjDef_xAOD.h.

◆ m_eleConfigBaseline

std::string ST::SUSYObjDef_xAOD::m_eleConfigBaseline
protected

Definition at line 649 of file SUSYObjDef_xAOD.h.

◆ m_eleCrackVeto

bool ST::SUSYObjDef_xAOD::m_eleCrackVeto
protected

Definition at line 702 of file SUSYObjDef_xAOD.h.

◆ m_elecSelLikelihood

asg::AnaToolHandle<IAsgElectronLikelihoodTool> ST::SUSYObjDef_xAOD::m_elecSelLikelihood
protected

Definition at line 908 of file SUSYObjDef_xAOD.h.

◆ m_elecSelLikelihoodBaseline

asg::AnaToolHandle<IAsgElectronLikelihoodTool> ST::SUSYObjDef_xAOD::m_elecSelLikelihoodBaseline
protected

Definition at line 909 of file SUSYObjDef_xAOD.h.

◆ m_elecTrigEffTools

ToolHandleArray<IAsgElectronEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_elecTrigEffTools
protected

Definition at line 902 of file SUSYObjDef_xAOD.h.

◆ m_elecTrigSFTools

ToolHandleArray<IAsgElectronEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_elecTrigSFTools
protected

Definition at line 901 of file SUSYObjDef_xAOD.h.

◆ m_electronTriggerSFStringSingle

std::string ST::SUSYObjDef_xAOD::m_electronTriggerSFStringSingle
protected

Definition at line 642 of file SUSYObjDef_xAOD.h.

◆ m_eled0sig

double ST::SUSYObjDef_xAOD::m_eled0sig
protected

Definition at line 703 of file SUSYObjDef_xAOD.h.

◆ m_eleEffMapFilePath

std::string ST::SUSYObjDef_xAOD::m_eleEffMapFilePath
protected

Definition at line 707 of file SUSYObjDef_xAOD.h.

◆ m_eleEffMapFilePathRun2

std::string ST::SUSYObjDef_xAOD::m_eleEffMapFilePathRun2
protected

Definition at line 708 of file SUSYObjDef_xAOD.h.

◆ m_eleEta

double ST::SUSYObjDef_xAOD::m_eleEta
protected

Definition at line 701 of file SUSYObjDef_xAOD.h.

◆ m_EleFatJetDR

double ST::SUSYObjDef_xAOD::m_EleFatJetDR
protected

Definition at line 801 of file SUSYObjDef_xAOD.h.

◆ m_eleForceFullSimCalib

bool ST::SUSYObjDef_xAOD::m_eleForceFullSimCalib
protected

Definition at line 710 of file SUSYObjDef_xAOD.h.

◆ m_eleId

std::string ST::SUSYObjDef_xAOD::m_eleId
protected

Definition at line 646 of file SUSYObjDef_xAOD.h.

◆ m_eleIdBaseline

std::string ST::SUSYObjDef_xAOD::m_eleIdBaseline
protected

Definition at line 647 of file SUSYObjDef_xAOD.h.

◆ m_eleIdBaselineDFName

std::string ST::SUSYObjDef_xAOD::m_eleIdBaselineDFName
protected

Definition at line 998 of file SUSYObjDef_xAOD.h.

◆ m_eleIdDFName

std::string ST::SUSYObjDef_xAOD::m_eleIdDFName
protected

Definition at line 999 of file SUSYObjDef_xAOD.h.

◆ m_eleIdExpert

bool ST::SUSYObjDef_xAOD::m_eleIdExpert
protected

Definition at line 651 of file SUSYObjDef_xAOD.h.

◆ m_eleIso_WP

std::string ST::SUSYObjDef_xAOD::m_eleIso_WP
protected

Definition at line 663 of file SUSYObjDef_xAOD.h.

◆ m_eleIsoHighPt_WP

std::string ST::SUSYObjDef_xAOD::m_eleIsoHighPt_WP
protected

Definition at line 664 of file SUSYObjDef_xAOD.h.

◆ m_eleIsoHighPtThresh

double ST::SUSYObjDef_xAOD::m_eleIsoHighPtThresh
protected

Definition at line 665 of file SUSYObjDef_xAOD.h.

◆ m_eleLRT

bool ST::SUSYObjDef_xAOD::m_eleLRT
protected

Definition at line 667 of file SUSYObjDef_xAOD.h.

◆ m_eleLRT_strat

int ST::SUSYObjDef_xAOD::m_eleLRT_strat
protected

Definition at line 668 of file SUSYObjDef_xAOD.h.

◆ m_elePt

double ST::SUSYObjDef_xAOD::m_elePt
protected

Definition at line 700 of file SUSYObjDef_xAOD.h.

◆ m_eleTerm

std::string ST::SUSYObjDef_xAOD::m_eleTerm
protected

Definition at line 569 of file SUSYObjDef_xAOD.h.

◆ m_elez0

double ST::SUSYObjDef_xAOD::m_elez0
protected

Definition at line 704 of file SUSYObjDef_xAOD.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default).

Definition at line 390 of file AthCommonDataStore.h.

◆ m_fatjetFFSmearingSyst

std::vector<CP::SystematicSet> ST::SUSYObjDef_xAOD::m_fatjetFFSmearingSyst
protected

Definition at line 827 of file SUSYObjDef_xAOD.h.

◆ m_fatjetFFSmearingTool

asg::AnaToolHandle<ICPJetCorrectionTool> ST::SUSYObjDef_xAOD::m_fatjetFFSmearingTool
protected

Definition at line 844 of file SUSYObjDef_xAOD.h.

◆ m_fatJets

std::string ST::SUSYObjDef_xAOD::m_fatJets
protected

Definition at line 822 of file SUSYObjDef_xAOD.h.

◆ m_fatJetUncConfig

std::string ST::SUSYObjDef_xAOD::m_fatJetUncConfig
protected

Definition at line 546 of file SUSYObjDef_xAOD.h.

◆ m_fatJetUncertaintiesMCType

std::string ST::SUSYObjDef_xAOD::m_fatJetUncertaintiesMCType
protected

Definition at line 535 of file SUSYObjDef_xAOD.h.

◆ m_fatJetUncertaintiesPDsmearing

bool ST::SUSYObjDef_xAOD::m_fatJetUncertaintiesPDsmearing
protected

Definition at line 547 of file SUSYObjDef_xAOD.h.

◆ m_fatjetUncertaintiesPDSmearTool

asg::AnaToolHandle<ICPJetUncertaintiesTool> ST::SUSYObjDef_xAOD::m_fatjetUncertaintiesPDSmearTool
protected

Definition at line 843 of file SUSYObjDef_xAOD.h.

◆ m_fatjetUncertaintiesTool

asg::AnaToolHandle<ICPJetUncertaintiesTool> ST::SUSYObjDef_xAOD::m_fatjetUncertaintiesTool
protected

Definition at line 842 of file SUSYObjDef_xAOD.h.

◆ m_fatJetUncVars

std::string ST::SUSYObjDef_xAOD::m_fatJetUncVars
protected

Definition at line 548 of file SUSYObjDef_xAOD.h.

◆ m_fJvtConfigRun2

std::string ST::SUSYObjDef_xAOD::m_fJvtConfigRun2
protected

Definition at line 764 of file SUSYObjDef_xAOD.h.

◆ m_fJvtConfigRun3

std::string ST::SUSYObjDef_xAOD::m_fJvtConfigRun3
protected

Definition at line 765 of file SUSYObjDef_xAOD.h.

◆ m_fJvtEtaMin

double ST::SUSYObjDef_xAOD::m_fJvtEtaMin
protected

Definition at line 763 of file SUSYObjDef_xAOD.h.

◆ m_fJvtPtMax

double ST::SUSYObjDef_xAOD::m_fJvtPtMax
protected

Definition at line 762 of file SUSYObjDef_xAOD.h.

◆ m_fJvtWP

std::string ST::SUSYObjDef_xAOD::m_fJvtWP
protected

Definition at line 761 of file SUSYObjDef_xAOD.h.

◆ m_force_noElId

bool ST::SUSYObjDef_xAOD::m_force_noElId
protected

Definition at line 524 of file SUSYObjDef_xAOD.h.

◆ m_force_noMuId

bool ST::SUSYObjDef_xAOD::m_force_noMuId
protected

Definition at line 525 of file SUSYObjDef_xAOD.h.

◆ m_gammaTerm

std::string ST::SUSYObjDef_xAOD::m_gammaTerm
protected

Definition at line 570 of file SUSYObjDef_xAOD.h.

◆ m_GSFLRTCollectionName

SG::ReadHandleKey<xAOD::TrackParticleContainer> ST::SUSYObjDef_xAOD::m_GSFLRTCollectionName {this, "GSFLRTCollectionName", "LRTGSFTrackParticles", "GSF LRT collection name"}
private

Definition at line 482 of file SUSYObjDef_xAOD.h.

482{this, "GSFLRTCollectionName", "LRTGSFTrackParticles", "GSF LRT collection name"};

◆ m_inputMetaStore

MetaStore_t asg::AsgMetadataTool::m_inputMetaStore
privateinherited

Object accessing the input metadata store.

Definition at line 119 of file AsgMetadataTool.h.

◆ m_inputMETCore

std::string ST::SUSYObjDef_xAOD::m_inputMETCore
protected

Definition at line 576 of file SUSYObjDef_xAOD.h.

◆ m_inputMETMap

std::string ST::SUSYObjDef_xAOD::m_inputMETMap
protected

Definition at line 575 of file SUSYObjDef_xAOD.h.

◆ m_inputMETRef

std::string ST::SUSYObjDef_xAOD::m_inputMETRef
protected

Definition at line 577 of file SUSYObjDef_xAOD.h.

◆ m_inputMETSuffix

std::string ST::SUSYObjDef_xAOD::m_inputMETSuffix
protected

Definition at line 574 of file SUSYObjDef_xAOD.h.

◆ m_isoBaselineTool

asg::AnaToolHandle<CP::IIsolationSelectionTool> ST::SUSYObjDef_xAOD::m_isoBaselineTool
protected

Definition at line 984 of file SUSYObjDef_xAOD.h.

◆ m_IsoCloseByORpassLabel

std::string ST::SUSYObjDef_xAOD::m_IsoCloseByORpassLabel
protected

Definition at line 810 of file SUSYObjDef_xAOD.h.

◆ m_isoCloseByTool

asg::AnaToolHandle<CP::IIsolationCloseByCorrectionTool> ST::SUSYObjDef_xAOD::m_isoCloseByTool
protected

Definition at line 986 of file SUSYObjDef_xAOD.h.

◆ m_isoCorrTool

asg::AnaToolHandle<CP::IIsolationCorrectionTool> ST::SUSYObjDef_xAOD::m_isoCorrTool
protected

Definition at line 981 of file SUSYObjDef_xAOD.h.

◆ m_isoHighPtTool

asg::AnaToolHandle<CP::IIsolationSelectionTool> ST::SUSYObjDef_xAOD::m_isoHighPtTool
protected

Definition at line 985 of file SUSYObjDef_xAOD.h.

◆ m_isoTool

asg::AnaToolHandle<CP::IIsolationSelectionTool> ST::SUSYObjDef_xAOD::m_isoTool
protected

Definition at line 982 of file SUSYObjDef_xAOD.h.

◆ m_isPHYSLITE

bool ST::SUSYObjDef_xAOD::m_isPHYSLITE
protected

Definition at line 814 of file SUSYObjDef_xAOD.h.

◆ m_isRun3

bool ST::SUSYObjDef_xAOD::m_isRun3
protected

Definition at line 813 of file SUSYObjDef_xAOD.h.

◆ m_jesCalibArea

std::string ST::SUSYObjDef_xAOD::m_jesCalibArea
protected

Definition at line 875 of file SUSYObjDef_xAOD.h.

◆ m_jesCalibSeq

std::string ST::SUSYObjDef_xAOD::m_jesCalibSeq
protected

Definition at line 872 of file SUSYObjDef_xAOD.h.

◆ m_jesCalibSeqFat

std::string ST::SUSYObjDef_xAOD::m_jesCalibSeqFat
protected

Definition at line 874 of file SUSYObjDef_xAOD.h.

◆ m_jesCalibSeqJMS

std::string ST::SUSYObjDef_xAOD::m_jesCalibSeqJMS
protected

Definition at line 873 of file SUSYObjDef_xAOD.h.

◆ m_jesConfig

std::string ST::SUSYObjDef_xAOD::m_jesConfig
protected

Definition at line 866 of file SUSYObjDef_xAOD.h.

◆ m_jesConfigAFII

std::string ST::SUSYObjDef_xAOD::m_jesConfigAFII
protected

Definition at line 869 of file SUSYObjDef_xAOD.h.

◆ m_jesConfigFat

std::string ST::SUSYObjDef_xAOD::m_jesConfigFat
protected

Definition at line 870 of file SUSYObjDef_xAOD.h.

◆ m_jesConfigFatData

std::string ST::SUSYObjDef_xAOD::m_jesConfigFatData
protected

Definition at line 871 of file SUSYObjDef_xAOD.h.

◆ m_jesConfigJMS

std::string ST::SUSYObjDef_xAOD::m_jesConfigJMS
protected

Definition at line 867 of file SUSYObjDef_xAOD.h.

◆ m_jesConfigJMSData

std::string ST::SUSYObjDef_xAOD::m_jesConfigJMSData
protected

Definition at line 868 of file SUSYObjDef_xAOD.h.

◆ m_jetCalibTool

asg::AnaToolHandle<IJetCalibrationTool> ST::SUSYObjDef_xAOD::m_jetCalibTool
protected

Definition at line 838 of file SUSYObjDef_xAOD.h.

◆ m_jetCleanDFName

std::string ST::SUSYObjDef_xAOD::m_jetCleanDFName
protected

Definition at line 1002 of file SUSYObjDef_xAOD.h.

◆ m_jetCleaningTool

asg::AnaToolHandle<IJetSelector> ST::SUSYObjDef_xAOD::m_jetCleaningTool
protected

Definition at line 845 of file SUSYObjDef_xAOD.h.

◆ m_jetEta

double ST::SUSYObjDef_xAOD::m_jetEta
protected

Definition at line 750 of file SUSYObjDef_xAOD.h.

◆ m_jetFatCalibTool

asg::AnaToolHandle<IJetCalibrationTool> ST::SUSYObjDef_xAOD::m_jetFatCalibTool
protected

Definition at line 839 of file SUSYObjDef_xAOD.h.

◆ m_JetFatJetDR

double ST::SUSYObjDef_xAOD::m_JetFatJetDR
protected

Definition at line 802 of file SUSYObjDef_xAOD.h.

◆ m_jetfJvtEfficiencyTool

asg::AnaToolHandle<CP::IJvtEfficiencyTool> ST::SUSYObjDef_xAOD::m_jetfJvtEfficiencyTool
protected

Definition at line 853 of file SUSYObjDef_xAOD.h.

◆ m_jetfJvtSelectionTool

asg::AnaToolHandle<IAsgSelectionTool> ST::SUSYObjDef_xAOD::m_jetfJvtSelectionTool
protected

Definition at line 852 of file SUSYObjDef_xAOD.h.

◆ m_jetInputType

int ST::SUSYObjDef_xAOD::m_jetInputType
protected

Definition at line 520 of file SUSYObjDef_xAOD.h.

◆ m_jetJvt

double ST::SUSYObjDef_xAOD::m_jetJvt
protected

Definition at line 751 of file SUSYObjDef_xAOD.h.

◆ m_jetJvtMomentTool

asg::AnaToolHandle<JetVertexTaggerTool> ST::SUSYObjDef_xAOD::m_jetJvtMomentTool
protected

Definition at line 848 of file SUSYObjDef_xAOD.h.

◆ m_jetNNJvtEfficiencyTool

asg::AnaToolHandle<CP::IJvtEfficiencyTool> ST::SUSYObjDef_xAOD::m_jetNNJvtEfficiencyTool
protected

Definition at line 851 of file SUSYObjDef_xAOD.h.

◆ m_jetNNJvtMomentTool

asg::AnaToolHandle<JetPileupTag::JetVertexNNTagger> ST::SUSYObjDef_xAOD::m_jetNNJvtMomentTool
protected

Definition at line 849 of file SUSYObjDef_xAOD.h.

◆ m_jetNNJvtSelectionTool

asg::AnaToolHandle<IAsgSelectionTool> ST::SUSYObjDef_xAOD::m_jetNNJvtSelectionTool
protected

Definition at line 850 of file SUSYObjDef_xAOD.h.

◆ m_jetPileupLabelingTool

asg::AnaToolHandle<JetPileupLabelingTool> ST::SUSYObjDef_xAOD::m_jetPileupLabelingTool
protected

Definition at line 847 of file SUSYObjDef_xAOD.h.

◆ m_jetPt

double ST::SUSYObjDef_xAOD::m_jetPt
protected

Definition at line 749 of file SUSYObjDef_xAOD.h.

◆ m_jetTerm

std::string ST::SUSYObjDef_xAOD::m_jetTerm
protected

Definition at line 572 of file SUSYObjDef_xAOD.h.

◆ m_jetTruthLabelingTool

asg::AnaToolHandle<JetTruthLabelingTool> ST::SUSYObjDef_xAOD::m_jetTruthLabelingTool
protected

Definition at line 858 of file SUSYObjDef_xAOD.h.

◆ m_JetTruthLabelName

std::string ST::SUSYObjDef_xAOD::m_JetTruthLabelName
protected

Definition at line 564 of file SUSYObjDef_xAOD.h.

◆ m_jetUncertaintiesAnalysisFile

std::string ST::SUSYObjDef_xAOD::m_jetUncertaintiesAnalysisFile
protected

Definition at line 532 of file SUSYObjDef_xAOD.h.

◆ m_jetUncertaintiesCalibArea

std::string ST::SUSYObjDef_xAOD::m_jetUncertaintiesCalibArea
protected

Definition at line 533 of file SUSYObjDef_xAOD.h.

◆ m_jetUncertaintiesConfig

std::string ST::SUSYObjDef_xAOD::m_jetUncertaintiesConfig
protected

Prefix for trigger matchiing container name.

Definition at line 531 of file SUSYObjDef_xAOD.h.

◆ m_jetUncertaintiesMCType

std::string ST::SUSYObjDef_xAOD::m_jetUncertaintiesMCType
protected

Definition at line 534 of file SUSYObjDef_xAOD.h.

◆ m_jetUncertaintiesPDsmearing

bool ST::SUSYObjDef_xAOD::m_jetUncertaintiesPDsmearing
protected

Definition at line 536 of file SUSYObjDef_xAOD.h.

◆ m_jetUncertaintiesPDSmearTool

asg::AnaToolHandle<ICPJetUncertaintiesTool> ST::SUSYObjDef_xAOD::m_jetUncertaintiesPDSmearTool
protected

Definition at line 841 of file SUSYObjDef_xAOD.h.

◆ m_jetUncertaintiesTool

asg::AnaToolHandle<ICPJetUncertaintiesTool> ST::SUSYObjDef_xAOD::m_jetUncertaintiesTool
protected

Definition at line 840 of file SUSYObjDef_xAOD.h.

◆ m_JMScalib

bool ST::SUSYObjDef_xAOD::m_JMScalib
protected

Definition at line 767 of file SUSYObjDef_xAOD.h.

◆ m_JvtConfigRun2

std::string ST::SUSYObjDef_xAOD::m_JvtConfigRun2
protected

Definition at line 754 of file SUSYObjDef_xAOD.h.

◆ m_JvtConfigRun3

std::string ST::SUSYObjDef_xAOD::m_JvtConfigRun3
protected

Definition at line 755 of file SUSYObjDef_xAOD.h.

◆ m_JvtPtMax

double ST::SUSYObjDef_xAOD::m_JvtPtMax
protected

Definition at line 753 of file SUSYObjDef_xAOD.h.

◆ m_JvtWP

std::string ST::SUSYObjDef_xAOD::m_JvtWP
protected

Definition at line 752 of file SUSYObjDef_xAOD.h.

◆ m_label_truthKey

SG::ReadDecorHandleKey<xAOD::JetContainer> ST::SUSYObjDef_xAOD::m_label_truthKey
protected

Definition at line 863 of file SUSYObjDef_xAOD.h.

◆ m_legsPerTool

std::map<std::string,std::string> ST::SUSYObjDef_xAOD::m_legsPerTool
protected

Definition at line 835 of file SUSYObjDef_xAOD.h.

◆ m_legsPerTool_ph

std::map<std::string,std::string> ST::SUSYObjDef_xAOD::m_legsPerTool_ph
protected

Definition at line 836 of file SUSYObjDef_xAOD.h.

◆ m_LRTCollectionName

SG::ReadHandleKey<xAOD::TrackParticleContainer> ST::SUSYObjDef_xAOD::m_LRTCollectionName {this, "LRTCollectionName", "InDetLargeD0TrackParticles", "LRT collection name"}
private

Definition at line 481 of file SUSYObjDef_xAOD.h.

481{this, "LRTCollectionName", "InDetLargeD0TrackParticles", "LRT collection name"};

◆ m_LRTuncTool

asg::AnaToolHandle<InDet::IInclusiveTrackFilterTool> ST::SUSYObjDef_xAOD::m_LRTuncTool
protected

Definition at line 990 of file SUSYObjDef_xAOD.h.

◆ m_mcCampaign

std::string ST::SUSYObjDef_xAOD::m_mcCampaign
protected

Definition at line 602 of file SUSYObjDef_xAOD.h.

◆ m_mcChannel

int ST::SUSYObjDef_xAOD::m_mcChannel
protected

Definition at line 603 of file SUSYObjDef_xAOD.h.

◆ m_metDoMuonEloss

bool ST::SUSYObjDef_xAOD::m_metDoMuonEloss
protected

Definition at line 583 of file SUSYObjDef_xAOD.h.

◆ m_metDoRemoveMuonJets

bool ST::SUSYObjDef_xAOD::m_metDoRemoveMuonJets
protected

Definition at line 581 of file SUSYObjDef_xAOD.h.

◆ m_metDoSetMuonJetEMScale

bool ST::SUSYObjDef_xAOD::m_metDoSetMuonJetEMScale
protected

Definition at line 580 of file SUSYObjDef_xAOD.h.

◆ m_metGreedyPhotons

bool ST::SUSYObjDef_xAOD::m_metGreedyPhotons
protected

Definition at line 584 of file SUSYObjDef_xAOD.h.

◆ m_metJetSelection

std::string ST::SUSYObjDef_xAOD::m_metJetSelection
protected

Definition at line 816 of file SUSYObjDef_xAOD.h.

◆ m_metMaker

asg::AnaToolHandle<IMETMaker> ST::SUSYObjDef_xAOD::m_metMaker
protected

Definition at line 939 of file SUSYObjDef_xAOD.h.

◆ m_metRemoveOverlappingCaloTaggedMuons

bool ST::SUSYObjDef_xAOD::m_metRemoveOverlappingCaloTaggedMuons
protected

Definition at line 579 of file SUSYObjDef_xAOD.h.

◆ m_metSignif

asg::AnaToolHandle<IMETSignificance> ST::SUSYObjDef_xAOD::m_metSignif
protected

Definition at line 941 of file SUSYObjDef_xAOD.h.

◆ m_metsysConfigPrefix

std::string ST::SUSYObjDef_xAOD::m_metsysConfigPrefix
protected

Definition at line 586 of file SUSYObjDef_xAOD.h.

◆ m_metSystTool

asg::AnaToolHandle<IMETSystematicsTool> ST::SUSYObjDef_xAOD::m_metSystTool
protected

Definition at line 940 of file SUSYObjDef_xAOD.h.

◆ m_metUseGhostMuons

bool ST::SUSYObjDef_xAOD::m_metUseGhostMuons
protected

Definition at line 582 of file SUSYObjDef_xAOD.h.

◆ m_metVeryGreedyPhotons

bool ST::SUSYObjDef_xAOD::m_metVeryGreedyPhotons
protected

Definition at line 585 of file SUSYObjDef_xAOD.h.

◆ m_mu_id_support

int ST::SUSYObjDef_xAOD::m_mu_id_support
protected

Definition at line 631 of file SUSYObjDef_xAOD.h.

◆ m_mu_iso_fallback

std::map<std::string, std::string> ST::SUSYObjDef_xAOD::m_mu_iso_fallback
protected

Definition at line 638 of file SUSYObjDef_xAOD.h.

◆ m_mu_iso_support

std::vector<std::string> ST::SUSYObjDef_xAOD::m_mu_iso_support
protected

Definition at line 634 of file SUSYObjDef_xAOD.h.

◆ m_mubaselined0sig

double ST::SUSYObjDef_xAOD::m_mubaselined0sig
protected

Definition at line 719 of file SUSYObjDef_xAOD.h.

◆ m_muBaselineEta

double ST::SUSYObjDef_xAOD::m_muBaselineEta
protected

Definition at line 714 of file SUSYObjDef_xAOD.h.

◆ m_muBaselineIso_WP

std::string ST::SUSYObjDef_xAOD::m_muBaselineIso_WP
protected

Definition at line 675 of file SUSYObjDef_xAOD.h.

◆ m_muBaselinePt

double ST::SUSYObjDef_xAOD::m_muBaselinePt
protected

Definition at line 713 of file SUSYObjDef_xAOD.h.

◆ m_mubaselinez0

double ST::SUSYObjDef_xAOD::m_mubaselinez0
protected

Definition at line 720 of file SUSYObjDef_xAOD.h.

◆ m_muCalibrationMode

int ST::SUSYObjDef_xAOD::m_muCalibrationMode
protected

Definition at line 725 of file SUSYObjDef_xAOD.h.

◆ m_muCosmicd0

double ST::SUSYObjDef_xAOD::m_muCosmicd0
protected

Definition at line 723 of file SUSYObjDef_xAOD.h.

◆ m_muCosmicz0

double ST::SUSYObjDef_xAOD::m_muCosmicz0
protected

Definition at line 722 of file SUSYObjDef_xAOD.h.

◆ m_mud0sig

double ST::SUSYObjDef_xAOD::m_mud0sig
protected

Definition at line 717 of file SUSYObjDef_xAOD.h.

◆ m_muEffCorrForce1D

bool ST::SUSYObjDef_xAOD::m_muEffCorrForce1D
protected

Definition at line 680 of file SUSYObjDef_xAOD.h.

◆ m_muEta

double ST::SUSYObjDef_xAOD::m_muEta
protected

Definition at line 716 of file SUSYObjDef_xAOD.h.

◆ m_muHighPtExtraSmear

bool ST::SUSYObjDef_xAOD::m_muHighPtExtraSmear
protected

Definition at line 679 of file SUSYObjDef_xAOD.h.

◆ m_muId

int ST::SUSYObjDef_xAOD::m_muId
protected

Definition at line 652 of file SUSYObjDef_xAOD.h.

◆ m_muIdBaseline

int ST::SUSYObjDef_xAOD::m_muIdBaseline
protected

Definition at line 653 of file SUSYObjDef_xAOD.h.

◆ m_muIso_WP

std::string ST::SUSYObjDef_xAOD::m_muIso_WP
protected

Definition at line 676 of file SUSYObjDef_xAOD.h.

◆ m_muIsoHighPt_WP

std::string ST::SUSYObjDef_xAOD::m_muIsoHighPt_WP
protected

Definition at line 677 of file SUSYObjDef_xAOD.h.

◆ m_muIsoHighPtThresh

double ST::SUSYObjDef_xAOD::m_muIsoHighPtThresh
protected

Definition at line 678 of file SUSYObjDef_xAOD.h.

◆ m_muLRT

bool ST::SUSYObjDef_xAOD::m_muLRT
protected

Definition at line 726 of file SUSYObjDef_xAOD.h.

◆ m_muonCalibTool

asg::AnaToolHandle<CP::IMuonCalibrationAndSmearingTool> ST::SUSYObjDef_xAOD::m_muonCalibTool
protected

Definition at line 880 of file SUSYObjDef_xAOD.h.

◆ m_muonEfficiencyBMHighPtSFTool

asg::AnaToolHandle<CP::IMuonEfficiencyScaleFactors> ST::SUSYObjDef_xAOD::m_muonEfficiencyBMHighPtSFTool
protected

Definition at line 882 of file SUSYObjDef_xAOD.h.

◆ m_muonEfficiencySFTool

asg::AnaToolHandle<CP::IMuonEfficiencyScaleFactors> ST::SUSYObjDef_xAOD::m_muonEfficiencySFTool
protected

Definition at line 881 of file SUSYObjDef_xAOD.h.

◆ m_muonHighPtIsolationSFTool

asg::AnaToolHandle<CP::IMuonEfficiencyScaleFactors> ST::SUSYObjDef_xAOD::m_muonHighPtIsolationSFTool
protected

Definition at line 885 of file SUSYObjDef_xAOD.h.

◆ m_muonIsolationSFTool

asg::AnaToolHandle<CP::IMuonEfficiencyScaleFactors> ST::SUSYObjDef_xAOD::m_muonIsolationSFTool
protected

Definition at line 884 of file SUSYObjDef_xAOD.h.

◆ m_muonLRTORTool

asg::AnaToolHandle<CP::IMuonLRTOverlapRemovalTool> ST::SUSYObjDef_xAOD::m_muonLRTORTool
protected

Definition at line 888 of file SUSYObjDef_xAOD.h.

◆ m_muonSelectionHighPtTool

asg::AnaToolHandle<CP::IMuonSelectionTool> ST::SUSYObjDef_xAOD::m_muonSelectionHighPtTool
protected

Definition at line 878 of file SUSYObjDef_xAOD.h.

◆ m_muonSelectionTool

asg::AnaToolHandle<CP::IMuonSelectionTool> ST::SUSYObjDef_xAOD::m_muonSelectionTool
protected

Definition at line 877 of file SUSYObjDef_xAOD.h.

◆ m_muonSelectionToolBaseline

asg::AnaToolHandle<CP::IMuonSelectionTool> ST::SUSYObjDef_xAOD::m_muonSelectionToolBaseline
protected

Definition at line 879 of file SUSYObjDef_xAOD.h.

◆ m_muonTerm

std::string ST::SUSYObjDef_xAOD::m_muonTerm
protected

Definition at line 573 of file SUSYObjDef_xAOD.h.

◆ m_muonTriggerSFTool

asg::AnaToolHandle<CP::IMuonTriggerScaleFactors> ST::SUSYObjDef_xAOD::m_muonTriggerSFTool
protected

Definition at line 886 of file SUSYObjDef_xAOD.h.

◆ m_muonTrigSFTools

ToolHandleArray<CP::IMuonTriggerScaleFactors> ST::SUSYObjDef_xAOD::m_muonTrigSFTools
protected

Definition at line 887 of file SUSYObjDef_xAOD.h.

◆ m_muonTTVAEfficiencySFTool

asg::AnaToolHandle<CP::IMuonEfficiencyScaleFactors> ST::SUSYObjDef_xAOD::m_muonTTVAEfficiencySFTool
protected

Definition at line 883 of file SUSYObjDef_xAOD.h.

◆ m_muPt

double ST::SUSYObjDef_xAOD::m_muPt
protected

Definition at line 715 of file SUSYObjDef_xAOD.h.

◆ m_murequirepassedHighPtCuts

bool ST::SUSYObjDef_xAOD::m_murequirepassedHighPtCuts
protected

Definition at line 721 of file SUSYObjDef_xAOD.h.

◆ m_muTriggerSFCalibFilename

std::string ST::SUSYObjDef_xAOD::m_muTriggerSFCalibFilename
protected

Definition at line 682 of file SUSYObjDef_xAOD.h.

◆ m_muTriggerSFCalibRelease

std::string ST::SUSYObjDef_xAOD::m_muTriggerSFCalibRelease
protected

Definition at line 681 of file SUSYObjDef_xAOD.h.

◆ m_muz0

double ST::SUSYObjDef_xAOD::m_muz0
protected

Definition at line 718 of file SUSYObjDef_xAOD.h.

◆ m_orApplyRelPt

bool ST::SUSYObjDef_xAOD::m_orApplyRelPt
protected

Definition at line 788 of file SUSYObjDef_xAOD.h.

◆ m_orBJetPtUpperThres

double ST::SUSYObjDef_xAOD::m_orBJetPtUpperThres
protected

Definition at line 797 of file SUSYObjDef_xAOD.h.

◆ m_orBoostedElectronC1

double ST::SUSYObjDef_xAOD::m_orBoostedElectronC1
protected

Definition at line 781 of file SUSYObjDef_xAOD.h.

◆ m_orBoostedElectronC2

double ST::SUSYObjDef_xAOD::m_orBoostedElectronC2
protected

Definition at line 782 of file SUSYObjDef_xAOD.h.

◆ m_orBoostedElectronMaxConeSize

double ST::SUSYObjDef_xAOD::m_orBoostedElectronMaxConeSize
protected

Definition at line 783 of file SUSYObjDef_xAOD.h.

◆ m_orBoostedMuonC1

double ST::SUSYObjDef_xAOD::m_orBoostedMuonC1
protected

Definition at line 785 of file SUSYObjDef_xAOD.h.

◆ m_orBoostedMuonC2

double ST::SUSYObjDef_xAOD::m_orBoostedMuonC2
protected

Definition at line 786 of file SUSYObjDef_xAOD.h.

◆ m_orBoostedMuonMaxConeSize

double ST::SUSYObjDef_xAOD::m_orBoostedMuonMaxConeSize
protected

Definition at line 787 of file SUSYObjDef_xAOD.h.

◆ m_orBtagWP

std::string ST::SUSYObjDef_xAOD::m_orBtagWP
protected

Definition at line 794 of file SUSYObjDef_xAOD.h.

◆ m_orDoBjet

bool ST::SUSYObjDef_xAOD::m_orDoBjet
protected

Definition at line 776 of file SUSYObjDef_xAOD.h.

◆ m_orDoBoostedElectron

bool ST::SUSYObjDef_xAOD::m_orDoBoostedElectron
protected

Definition at line 780 of file SUSYObjDef_xAOD.h.

◆ m_orDoBoostedMuon

bool ST::SUSYObjDef_xAOD::m_orDoBoostedMuon
protected

Definition at line 784 of file SUSYObjDef_xAOD.h.

◆ m_orDoElBjet

bool ST::SUSYObjDef_xAOD::m_orDoElBjet
protected

Definition at line 777 of file SUSYObjDef_xAOD.h.

◆ m_orDoEleJet

bool ST::SUSYObjDef_xAOD::m_orDoEleJet
protected

Definition at line 772 of file SUSYObjDef_xAOD.h.

◆ m_orDoElEl

bool ST::SUSYObjDef_xAOD::m_orDoElEl
protected

Definition at line 773 of file SUSYObjDef_xAOD.h.

◆ m_orDoElMu

bool ST::SUSYObjDef_xAOD::m_orDoElMu
protected

Definition at line 774 of file SUSYObjDef_xAOD.h.

◆ m_orDoFatjets

bool ST::SUSYObjDef_xAOD::m_orDoFatjets
protected

Definition at line 800 of file SUSYObjDef_xAOD.h.

◆ m_orDoMuBjet

bool ST::SUSYObjDef_xAOD::m_orDoMuBjet
protected

Definition at line 778 of file SUSYObjDef_xAOD.h.

◆ m_orDoMuonJet

bool ST::SUSYObjDef_xAOD::m_orDoMuonJet
protected

Definition at line 775 of file SUSYObjDef_xAOD.h.

◆ m_orDoMuonJetGhostAssociation

bool ST::SUSYObjDef_xAOD::m_orDoMuonJetGhostAssociation
protected

Definition at line 792 of file SUSYObjDef_xAOD.h.

◆ m_orDoPhoton

bool ST::SUSYObjDef_xAOD::m_orDoPhoton
protected

Definition at line 771 of file SUSYObjDef_xAOD.h.

◆ m_orDoTau

bool ST::SUSYObjDef_xAOD::m_orDoTau
protected

Overlap removal options.

Definition at line 770 of file SUSYObjDef_xAOD.h.

◆ m_orDoTauBjet

bool ST::SUSYObjDef_xAOD::m_orDoTauBjet
protected

Definition at line 779 of file SUSYObjDef_xAOD.h.

◆ m_orInputLabel

std::string ST::SUSYObjDef_xAOD::m_orInputLabel
protected

Definition at line 795 of file SUSYObjDef_xAOD.h.

◆ m_orLinkOverlapObjects

bool ST::SUSYObjDef_xAOD::m_orLinkOverlapObjects
protected

Definition at line 798 of file SUSYObjDef_xAOD.h.

◆ m_orMuJetInnerDR

double ST::SUSYObjDef_xAOD::m_orMuJetInnerDR
protected

Definition at line 791 of file SUSYObjDef_xAOD.h.

◆ m_orMuJetPtRatio

double ST::SUSYObjDef_xAOD::m_orMuJetPtRatio
protected

Definition at line 789 of file SUSYObjDef_xAOD.h.

◆ m_orMuJetTrkPtRatio

double ST::SUSYObjDef_xAOD::m_orMuJetTrkPtRatio
protected

Definition at line 790 of file SUSYObjDef_xAOD.h.

◆ m_orPhotonFavoured

bool ST::SUSYObjDef_xAOD::m_orPhotonFavoured
protected

Definition at line 796 of file SUSYObjDef_xAOD.h.

◆ m_orRemoveCaloMuons

bool ST::SUSYObjDef_xAOD::m_orRemoveCaloMuons
protected

Definition at line 793 of file SUSYObjDef_xAOD.h.

◆ m_orToolbox

ORUtils::ToolBox ST::SUSYObjDef_xAOD::m_orToolbox
protected

Definition at line 993 of file SUSYObjDef_xAOD.h.

◆ m_outElectronLocation

SG::WriteHandleKey<xAOD::ElectronContainer> ST::SUSYObjDef_xAOD::m_outElectronLocation {this, "OutputElectronLocation", "StdWithLRTElectrons", "name of the muon container to write"}
protected

Definition at line 904 of file SUSYObjDef_xAOD.h.

904{this, "OutputElectronLocation", "StdWithLRTElectrons", "name of the muon container to write"};

◆ m_outMETTerm

std::string ST::SUSYObjDef_xAOD::m_outMETTerm
protected

Definition at line 578 of file SUSYObjDef_xAOD.h.

◆ m_outMuonLocation

SG::WriteHandleKey<xAOD::MuonContainer> ST::SUSYObjDef_xAOD::m_outMuonLocation {this, "OutputMuonLocation", "StdWithLRTMuons", "name of the muon container to write"}
protected

Definition at line 889 of file SUSYObjDef_xAOD.h.

889{this, "OutputMuonLocation", "StdWithLRTMuons", "name of the muon container to write"};

◆ m_outputMetaStore

MetaStore_t asg::AsgMetadataTool::m_outputMetaStore
privateinherited

Object accessing the output metadata store.

Definition at line 121 of file AsgMetadataTool.h.

◆ m_ph_id_support

std::vector<std::string> ST::SUSYObjDef_xAOD::m_ph_id_support
protected

Definition at line 630 of file SUSYObjDef_xAOD.h.

◆ m_photonAllowLate

bool ST::SUSYObjDef_xAOD::m_photonAllowLate
protected

Definition at line 734 of file SUSYObjDef_xAOD.h.

◆ m_photonBaselineCrackVeto

bool ST::SUSYObjDef_xAOD::m_photonBaselineCrackVeto
protected

Definition at line 732 of file SUSYObjDef_xAOD.h.

◆ m_photonBaselineEta

double ST::SUSYObjDef_xAOD::m_photonBaselineEta
protected

Definition at line 729 of file SUSYObjDef_xAOD.h.

◆ m_photonBaselineIso_WP

std::string ST::SUSYObjDef_xAOD::m_photonBaselineIso_WP
protected

Definition at line 672 of file SUSYObjDef_xAOD.h.

◆ m_photonBaselinePt

double ST::SUSYObjDef_xAOD::m_photonBaselinePt
protected

Definition at line 728 of file SUSYObjDef_xAOD.h.

◆ m_photonCrackVeto

bool ST::SUSYObjDef_xAOD::m_photonCrackVeto
protected

Definition at line 733 of file SUSYObjDef_xAOD.h.

◆ m_photonEfficiencySFTool

asg::AnaToolHandle<IAsgPhotonEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_photonEfficiencySFTool
protected

Definition at line 913 of file SUSYObjDef_xAOD.h.

◆ m_photonEfficiencySFTool_trigEff_AsymDiphoton

std::vector<asg::AnaToolHandle<IAsgPhotonEfficiencyCorrectionTool> > ST::SUSYObjDef_xAOD::m_photonEfficiencySFTool_trigEff_AsymDiphoton
protected

Definition at line 918 of file SUSYObjDef_xAOD.h.

◆ m_photonEfficiencySFTool_trigSF_AsymDiphoton

std::vector<asg::AnaToolHandle<IAsgPhotonEfficiencyCorrectionTool> > ST::SUSYObjDef_xAOD::m_photonEfficiencySFTool_trigSF_AsymDiphoton
protected

Definition at line 917 of file SUSYObjDef_xAOD.h.

◆ m_photonEta

double ST::SUSYObjDef_xAOD::m_photonEta
protected

Definition at line 730 of file SUSYObjDef_xAOD.h.

◆ m_photonId

std::string ST::SUSYObjDef_xAOD::m_photonId
protected

Definition at line 654 of file SUSYObjDef_xAOD.h.

◆ m_photonIdBaseline

std::string ST::SUSYObjDef_xAOD::m_photonIdBaseline
protected

Definition at line 655 of file SUSYObjDef_xAOD.h.

◆ m_photonIdBaselineDFName

std::string ST::SUSYObjDef_xAOD::m_photonIdBaselineDFName
protected

Definition at line 1000 of file SUSYObjDef_xAOD.h.

◆ m_photonIdDFName

std::string ST::SUSYObjDef_xAOD::m_photonIdDFName
protected

Definition at line 1001 of file SUSYObjDef_xAOD.h.

◆ m_photonIso_WP

std::string ST::SUSYObjDef_xAOD::m_photonIso_WP
protected

Definition at line 673 of file SUSYObjDef_xAOD.h.

◆ m_photonIsolationSFTool

asg::AnaToolHandle<IAsgPhotonEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_photonIsolationSFTool
protected

Definition at line 914 of file SUSYObjDef_xAOD.h.

◆ m_photonPt

double ST::SUSYObjDef_xAOD::m_photonPt
protected

Definition at line 731 of file SUSYObjDef_xAOD.h.

◆ m_photonSelIsEM

asg::AnaToolHandle<IAsgPhotonIsEMSelector> ST::SUSYObjDef_xAOD::m_photonSelIsEM
protected

Definition at line 910 of file SUSYObjDef_xAOD.h.

◆ m_photonSelIsEMBaseline

asg::AnaToolHandle<IAsgPhotonIsEMSelector> ST::SUSYObjDef_xAOD::m_photonSelIsEMBaseline
protected

Definition at line 911 of file SUSYObjDef_xAOD.h.

◆ m_photonTrigEffTools

ToolHandleArray<IAsgPhotonEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_photonTrigEffTools
protected

Definition at line 920 of file SUSYObjDef_xAOD.h.

◆ m_photonTriggerName

std::string ST::SUSYObjDef_xAOD::m_photonTriggerName
protected

Definition at line 674 of file SUSYObjDef_xAOD.h.

◆ m_photonTriggerSFTool

asg::AnaToolHandle<IAsgPhotonEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_photonTriggerSFTool
protected

Definition at line 915 of file SUSYObjDef_xAOD.h.

◆ m_photonTrigSFTools

ToolHandleArray<IAsgPhotonEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_photonTrigSFTools
protected

Definition at line 919 of file SUSYObjDef_xAOD.h.

◆ m_pmgSHnjetWeighter

asg::AnaToolHandle<IWeightTool> ST::SUSYObjDef_xAOD::m_pmgSHnjetWeighter
protected

Definition at line 995 of file SUSYObjDef_xAOD.h.

◆ m_pmgSHnjetWeighterWZ

asg::AnaToolHandle<IWeightTool> ST::SUSYObjDef_xAOD::m_pmgSHnjetWeighterWZ
protected

Definition at line 996 of file SUSYObjDef_xAOD.h.

◆ m_prwActualMu2017File

std::string ST::SUSYObjDef_xAOD::m_prwActualMu2017File
protected

Definition at line 616 of file SUSYObjDef_xAOD.h.

◆ m_prwActualMu2018File

std::string ST::SUSYObjDef_xAOD::m_prwActualMu2018File
protected

Definition at line 617 of file SUSYObjDef_xAOD.h.

◆ m_prwActualMu2022File

std::string ST::SUSYObjDef_xAOD::m_prwActualMu2022File
protected

Definition at line 618 of file SUSYObjDef_xAOD.h.

◆ m_prwActualMu2023File

std::string ST::SUSYObjDef_xAOD::m_prwActualMu2023File
protected

Definition at line 619 of file SUSYObjDef_xAOD.h.

◆ m_prwActualMu2024File

std::string ST::SUSYObjDef_xAOD::m_prwActualMu2024File
protected

Definition at line 620 of file SUSYObjDef_xAOD.h.

◆ m_prwActualMu2025File

std::string ST::SUSYObjDef_xAOD::m_prwActualMu2025File
protected

Definition at line 621 of file SUSYObjDef_xAOD.h.

◆ m_prwConfFiles

std::vector<std::string> ST::SUSYObjDef_xAOD::m_prwConfFiles
protected

Definition at line 614 of file SUSYObjDef_xAOD.h.

◆ m_prwDataSF

double ST::SUSYObjDef_xAOD::m_prwDataSF
protected

Definition at line 623 of file SUSYObjDef_xAOD.h.

◆ m_prwDataSF_DW

double ST::SUSYObjDef_xAOD::m_prwDataSF_DW
protected

Definition at line 625 of file SUSYObjDef_xAOD.h.

◆ m_prwDataSF_UP

double ST::SUSYObjDef_xAOD::m_prwDataSF_UP
protected

Definition at line 624 of file SUSYObjDef_xAOD.h.

◆ m_prwLcalcFiles

std::vector<std::string> ST::SUSYObjDef_xAOD::m_prwLcalcFiles
protected

Definition at line 615 of file SUSYObjDef_xAOD.h.

◆ m_prwTool

asg::AnaToolHandle<CP::IPileupReweightingTool> ST::SUSYObjDef_xAOD::m_prwTool
protected

Definition at line 988 of file SUSYObjDef_xAOD.h.

◆ m_runDepPrescaleWeightPRW

bool ST::SUSYObjDef_xAOD::m_runDepPrescaleWeightPRW
protected

Definition at line 626 of file SUSYObjDef_xAOD.h.

◆ m_runECIS

bool ST::SUSYObjDef_xAOD::m_runECIS
protected

Definition at line 671 of file SUSYObjDef_xAOD.h.

◆ m_showerType

int ST::SUSYObjDef_xAOD::m_showerType
protected

Definition at line 818 of file SUSYObjDef_xAOD.h.

◆ m_slices

std::map<std::string,bool> ST::SUSYObjDef_xAOD::m_slices
protected

Definition at line 812 of file SUSYObjDef_xAOD.h.

◆ m_softTermParam

int ST::SUSYObjDef_xAOD::m_softTermParam
protected

Definition at line 592 of file SUSYObjDef_xAOD.h.

◆ m_strictConfigCheck

bool ST::SUSYObjDef_xAOD::m_strictConfigCheck
protected

Definition at line 542 of file SUSYObjDef_xAOD.h.

◆ m_subtool_init

bool ST::SUSYObjDef_xAOD::m_subtool_init
protected

Definition at line 567 of file SUSYObjDef_xAOD.h.

◆ m_tau_id_fallback

std::map<int, int> ST::SUSYObjDef_xAOD::m_tau_id_fallback
protected

Definition at line 639 of file SUSYObjDef_xAOD.h.

◆ m_tau_id_support

std::vector<std::string> ST::SUSYObjDef_xAOD::m_tau_id_support
protected

Definition at line 632 of file SUSYObjDef_xAOD.h.

◆ m_tau_trig_support

std::map<std::string, std::string> ST::SUSYObjDef_xAOD::m_tau_trig_support
protected

Definition at line 644 of file SUSYObjDef_xAOD.h.

◆ m_tauConfigPath

std::string ST::SUSYObjDef_xAOD::m_tauConfigPath
protected

Definition at line 739 of file SUSYObjDef_xAOD.h.

◆ m_tauConfigPathBaseline

std::string ST::SUSYObjDef_xAOD::m_tauConfigPathBaseline
protected

Definition at line 740 of file SUSYObjDef_xAOD.h.

◆ m_tauConfigReader

TEnv ST::SUSYObjDef_xAOD::m_tauConfigReader
protected

Definition at line 747 of file SUSYObjDef_xAOD.h.

◆ m_tauDoTTM

bool ST::SUSYObjDef_xAOD::m_tauDoTTM
protected

Definition at line 743 of file SUSYObjDef_xAOD.h.

◆ m_tauEffTool

asg::AnaToolHandle<TauAnalysisTools::ITauEfficiencyCorrectionsTool> ST::SUSYObjDef_xAOD::m_tauEffTool
protected

Definition at line 930 of file SUSYObjDef_xAOD.h.

◆ m_tauEffToolRecommendationTag

std::string ST::SUSYObjDef_xAOD::m_tauEffToolRecommendationTag
protected

Definition at line 745 of file SUSYObjDef_xAOD.h.

◆ m_tauEleId

bool ST::SUSYObjDef_xAOD::m_tauEleId
protected

Definition at line 659 of file SUSYObjDef_xAOD.h.

◆ m_tauEleIdBaseline

bool ST::SUSYObjDef_xAOD::m_tauEleIdBaseline
protected

Definition at line 660 of file SUSYObjDef_xAOD.h.

◆ m_tauEta

double ST::SUSYObjDef_xAOD::m_tauEta
protected

Definition at line 738 of file SUSYObjDef_xAOD.h.

◆ m_tauId

std::string ST::SUSYObjDef_xAOD::m_tauId
protected

Definition at line 657 of file SUSYObjDef_xAOD.h.

◆ m_tauIdBaseline

std::string ST::SUSYObjDef_xAOD::m_tauIdBaseline
protected

Definition at line 658 of file SUSYObjDef_xAOD.h.

◆ m_tauInputFile

std::string ST::SUSYObjDef_xAOD::m_tauInputFile
protected

Definition at line 741 of file SUSYObjDef_xAOD.h.

◆ m_tauInputFileBaseline

std::string ST::SUSYObjDef_xAOD::m_tauInputFileBaseline
protected

Definition at line 742 of file SUSYObjDef_xAOD.h.

◆ m_tauJetORtool

asg::AnaToolHandle<ORUtils::IOverlapTool> ST::SUSYObjDef_xAOD::m_tauJetORtool
protected

Definition at line 992 of file SUSYObjDef_xAOD.h.

◆ m_tauMuOLR

bool ST::SUSYObjDef_xAOD::m_tauMuOLR
protected

Definition at line 661 of file SUSYObjDef_xAOD.h.

◆ m_tauMuOLRBaseline

bool ST::SUSYObjDef_xAOD::m_tauMuOLRBaseline
protected

Definition at line 662 of file SUSYObjDef_xAOD.h.

◆ m_tauPrePtCut

double ST::SUSYObjDef_xAOD::m_tauPrePtCut
protected

Definition at line 736 of file SUSYObjDef_xAOD.h.

◆ m_tauPt

double ST::SUSYObjDef_xAOD::m_tauPt
protected

Definition at line 737 of file SUSYObjDef_xAOD.h.

◆ m_tauSelTool

asg::AnaToolHandle<TauAnalysisTools::ITauSelectionTool> ST::SUSYObjDef_xAOD::m_tauSelTool
protected

Definition at line 926 of file SUSYObjDef_xAOD.h.

◆ m_tauSelToolBaseline

asg::AnaToolHandle<TauAnalysisTools::ITauSelectionTool> ST::SUSYObjDef_xAOD::m_tauSelToolBaseline
protected

Definition at line 927 of file SUSYObjDef_xAOD.h.

◆ m_tauSmearingTool

asg::AnaToolHandle<TauAnalysisTools::ITauSmearingTool> ST::SUSYObjDef_xAOD::m_tauSmearingTool
protected

Definition at line 928 of file SUSYObjDef_xAOD.h.

◆ m_tauSmearingToolRecommendationTag

std::string ST::SUSYObjDef_xAOD::m_tauSmearingToolRecommendationTag
protected

Definition at line 744 of file SUSYObjDef_xAOD.h.

◆ m_tauTagger

std::string ST::SUSYObjDef_xAOD::m_tauTagger
protected

Definition at line 656 of file SUSYObjDef_xAOD.h.

◆ m_tauTerm

std::string ST::SUSYObjDef_xAOD::m_tauTerm
protected

Definition at line 571 of file SUSYObjDef_xAOD.h.

◆ m_tauTrigEffTool

std::vector<asg::AnaToolHandle<TauAnalysisTools::ITauEfficiencyCorrectionsTool> > ST::SUSYObjDef_xAOD::m_tauTrigEffTool
protected

Definition at line 931 of file SUSYObjDef_xAOD.h.

◆ m_tauTruthMatch

asg::AnaToolHandle<TauAnalysisTools::ITauTruthMatchingTool> ST::SUSYObjDef_xAOD::m_tauTruthMatch
protected

Definition at line 929 of file SUSYObjDef_xAOD.h.

◆ m_tool_init

bool ST::SUSYObjDef_xAOD::m_tool_init
protected

Definition at line 566 of file SUSYObjDef_xAOD.h.

◆ m_TopconfigReader

TEnv ST::SUSYObjDef_xAOD::m_TopconfigReader
protected

Definition at line 552 of file SUSYObjDef_xAOD.h.

◆ m_TopDecorName

std::string ST::SUSYObjDef_xAOD::m_TopDecorName
protected

Definition at line 555 of file SUSYObjDef_xAOD.h.

◆ m_ToptagConfig

std::string ST::SUSYObjDef_xAOD::m_ToptagConfig
protected

Definition at line 558 of file SUSYObjDef_xAOD.h.

◆ m_TopTaggerCalibArea

std::string ST::SUSYObjDef_xAOD::m_TopTaggerCalibArea
protected

Definition at line 560 of file SUSYObjDef_xAOD.h.

◆ m_TopTaggerTool

asg::AnaToolHandle<JSSWTopTaggerDNN> ST::SUSYObjDef_xAOD::m_TopTaggerTool
protected

Definition at line 857 of file SUSYObjDef_xAOD.h.

◆ m_TopTagjetUncertaintiesTool

asg::AnaToolHandle<ICPJetUncertaintiesTool> ST::SUSYObjDef_xAOD::m_TopTagjetUncertaintiesTool
protected

Definition at line 861 of file SUSYObjDef_xAOD.h.

◆ m_TopTagUncConfig

std::string ST::SUSYObjDef_xAOD::m_TopTagUncConfig
protected

Definition at line 563 of file SUSYObjDef_xAOD.h.

◆ m_treatPUJets

bool ST::SUSYObjDef_xAOD::m_treatPUJets
protected

Definition at line 593 of file SUSYObjDef_xAOD.h.

◆ m_trig2015combination_diLep

std::string ST::SUSYObjDef_xAOD::m_trig2015combination_diLep
protected

Definition at line 952 of file SUSYObjDef_xAOD.h.

◆ m_trig2015combination_diPhoton

std::string ST::SUSYObjDef_xAOD::m_trig2015combination_diPhoton
protected

Definition at line 968 of file SUSYObjDef_xAOD.h.

◆ m_trig2015combination_multiLep

std::string ST::SUSYObjDef_xAOD::m_trig2015combination_multiLep
protected

Definition at line 960 of file SUSYObjDef_xAOD.h.

◆ m_trig2015combination_singleLep

std::string ST::SUSYObjDef_xAOD::m_trig2015combination_singleLep
protected

Definition at line 943 of file SUSYObjDef_xAOD.h.

◆ m_trig2016combination_diLep

std::string ST::SUSYObjDef_xAOD::m_trig2016combination_diLep
protected

Definition at line 953 of file SUSYObjDef_xAOD.h.

◆ m_trig2016combination_diPhoton

std::string ST::SUSYObjDef_xAOD::m_trig2016combination_diPhoton
protected

Definition at line 969 of file SUSYObjDef_xAOD.h.

◆ m_trig2016combination_multiLep

std::string ST::SUSYObjDef_xAOD::m_trig2016combination_multiLep
protected

Definition at line 961 of file SUSYObjDef_xAOD.h.

◆ m_trig2016combination_singleLep

std::string ST::SUSYObjDef_xAOD::m_trig2016combination_singleLep
protected

Definition at line 944 of file SUSYObjDef_xAOD.h.

◆ m_trig2017combination_diLep

std::string ST::SUSYObjDef_xAOD::m_trig2017combination_diLep
protected

Definition at line 954 of file SUSYObjDef_xAOD.h.

◆ m_trig2017combination_diPhoton

std::string ST::SUSYObjDef_xAOD::m_trig2017combination_diPhoton
protected

Definition at line 970 of file SUSYObjDef_xAOD.h.

◆ m_trig2017combination_multiLep

std::string ST::SUSYObjDef_xAOD::m_trig2017combination_multiLep
protected

Definition at line 962 of file SUSYObjDef_xAOD.h.

◆ m_trig2017combination_singleLep

std::string ST::SUSYObjDef_xAOD::m_trig2017combination_singleLep
protected

Definition at line 945 of file SUSYObjDef_xAOD.h.

◆ m_trig2018combination_diLep

std::string ST::SUSYObjDef_xAOD::m_trig2018combination_diLep
protected

Definition at line 955 of file SUSYObjDef_xAOD.h.

◆ m_trig2018combination_diPhoton

std::string ST::SUSYObjDef_xAOD::m_trig2018combination_diPhoton
protected

Definition at line 971 of file SUSYObjDef_xAOD.h.

◆ m_trig2018combination_multiLep

std::string ST::SUSYObjDef_xAOD::m_trig2018combination_multiLep
protected

Definition at line 963 of file SUSYObjDef_xAOD.h.

◆ m_trig2018combination_singleLep

std::string ST::SUSYObjDef_xAOD::m_trig2018combination_singleLep
protected

Definition at line 946 of file SUSYObjDef_xAOD.h.

◆ m_trig2022combination_diLep

std::string ST::SUSYObjDef_xAOD::m_trig2022combination_diLep
protected

Definition at line 956 of file SUSYObjDef_xAOD.h.

◆ m_trig2022combination_diPhoton

std::string ST::SUSYObjDef_xAOD::m_trig2022combination_diPhoton
protected

Definition at line 972 of file SUSYObjDef_xAOD.h.

◆ m_trig2022combination_multiLep

std::string ST::SUSYObjDef_xAOD::m_trig2022combination_multiLep
protected

Definition at line 964 of file SUSYObjDef_xAOD.h.

◆ m_trig2022combination_singleLep

std::string ST::SUSYObjDef_xAOD::m_trig2022combination_singleLep
protected

Definition at line 947 of file SUSYObjDef_xAOD.h.

◆ m_trig2023combination_singleLep

std::string ST::SUSYObjDef_xAOD::m_trig2023combination_singleLep
protected

Definition at line 948 of file SUSYObjDef_xAOD.h.

◆ m_trig2024combination_singleLep

std::string ST::SUSYObjDef_xAOD::m_trig2024combination_singleLep
protected

Definition at line 949 of file SUSYObjDef_xAOD.h.

◆ m_trigConfTool

asg::AnaToolHandle<TrigConf::ITrigConfigTool> ST::SUSYObjDef_xAOD::m_trigConfTool
protected

Definition at line 975 of file SUSYObjDef_xAOD.h.

◆ m_trigDecTool

asg::AnaToolHandle<Trig::TrigDecisionTool> ST::SUSYObjDef_xAOD::m_trigDecTool
protected

Definition at line 976 of file SUSYObjDef_xAOD.h.

◆ m_trigDRScoringTool

asg::AnaToolHandle<Trig::IMatchScoringTool> ST::SUSYObjDef_xAOD::m_trigDRScoringTool
protected

Definition at line 979 of file SUSYObjDef_xAOD.h.

◆ m_triggerCacheMutex

std::mutex ST::SUSYObjDef_xAOD::m_triggerCacheMutex
mutableprivate

Definition at line 446 of file SUSYObjDef_xAOD.h.

◆ m_trigGlobalEffCorrTool_diLep

asg::AnaToolHandle<ITrigGlobalEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_trigGlobalEffCorrTool_diLep
protected

Definition at line 957 of file SUSYObjDef_xAOD.h.

◆ m_trigGlobalEffCorrTool_diPhoton

asg::AnaToolHandle<ITrigGlobalEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_trigGlobalEffCorrTool_diPhoton
protected

Definition at line 973 of file SUSYObjDef_xAOD.h.

◆ m_trigGlobalEffCorrTool_multiLep

asg::AnaToolHandle<ITrigGlobalEfficiencyCorrectionTool> ST::SUSYObjDef_xAOD::m_trigGlobalEffCorrTool_multiLep
protected

Definition at line 965 of file SUSYObjDef_xAOD.h.

◆ m_trigMatchingPrefix

std::string ST::SUSYObjDef_xAOD::m_trigMatchingPrefix
protected

Use composite trigger matching tool if matching was done upstream.

Definition at line 529 of file SUSYObjDef_xAOD.h.

◆ m_trigMatchingTool

asg::AnaToolHandle<Trig::IMatchingTool> ST::SUSYObjDef_xAOD::m_trigMatchingTool
protected

Definition at line 977 of file SUSYObjDef_xAOD.h.

◆ m_trigMatchScoringTool

asg::AnaToolHandle<Trig::IMatchScoringTool> ST::SUSYObjDef_xAOD::m_trigMatchScoringTool
protected

Definition at line 978 of file SUSYObjDef_xAOD.h.

◆ m_trigNToys_diLep

int ST::SUSYObjDef_xAOD::m_trigNToys_diLep
protected

Definition at line 951 of file SUSYObjDef_xAOD.h.

◆ m_trigNToys_diPhoton

int ST::SUSYObjDef_xAOD::m_trigNToys_diPhoton
protected

Definition at line 967 of file SUSYObjDef_xAOD.h.

◆ m_trigNToys_multiLep

int ST::SUSYObjDef_xAOD::m_trigNToys_multiLep
protected

Definition at line 959 of file SUSYObjDef_xAOD.h.

◆ m_trkJetEta

double ST::SUSYObjDef_xAOD::m_trkJetEta
protected

Definition at line 758 of file SUSYObjDef_xAOD.h.

◆ m_trkJetPt

double ST::SUSYObjDef_xAOD::m_trkJetPt
protected

Definition at line 757 of file SUSYObjDef_xAOD.h.

◆ m_trkJetsyst

bool ST::SUSYObjDef_xAOD::m_trkJetsyst
protected

Definition at line 590 of file SUSYObjDef_xAOD.h.

◆ m_trkMETsyst

bool ST::SUSYObjDef_xAOD::m_trkMETsyst
protected

Definition at line 588 of file SUSYObjDef_xAOD.h.

◆ m_upstreamTriggerMatching

bool ST::SUSYObjDef_xAOD::m_upstreamTriggerMatching
protected

Definition at line 528 of file SUSYObjDef_xAOD.h.

◆ m_useBtagging

bool ST::SUSYObjDef_xAOD::m_useBtagging
protected

Definition at line 538 of file SUSYObjDef_xAOD.h.

◆ m_useBtagging_trkJet

bool ST::SUSYObjDef_xAOD::m_useBtagging_trkJet
protected

Definition at line 539 of file SUSYObjDef_xAOD.h.

◆ m_useCommonPRWFiles

bool ST::SUSYObjDef_xAOD::m_useCommonPRWFiles
protected

Definition at line 605 of file SUSYObjDef_xAOD.h.

◆ m_useIncidents

bool asg::AsgMetadataTool::m_useIncidents
privateinherited

Definition at line 128 of file AsgMetadataTool.h.

◆ m_useSigLepForIsoCloseByOR

bool ST::SUSYObjDef_xAOD::m_useSigLepForIsoCloseByOR
protected

Definition at line 809 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs15_cache_diLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs15_cache_diLep
private

Definition at line 468 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs15_cache_multiLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs15_cache_multiLep
private

Definition at line 474 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs15_cache_singleEle

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs15_cache_singleEle
private

Definition at line 452 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs15_cache_singleLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs15_cache_singleLep
private

Definition at line 460 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs16_cache_diLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs16_cache_diLep
private

Definition at line 469 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs16_cache_multiLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs16_cache_multiLep
private

Definition at line 475 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs16_cache_singleEle

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs16_cache_singleEle
private

Definition at line 453 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs16_cache_singleLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs16_cache_singleLep
private

Definition at line 461 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs17_cache_diLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs17_cache_diLep
private

Definition at line 470 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs17_cache_multiLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs17_cache_multiLep
private

Definition at line 476 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs17_cache_singleEle

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs17_cache_singleEle
private

Definition at line 454 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs17_cache_singleLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs17_cache_singleLep
private

Definition at line 462 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs18_cache_diLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs18_cache_diLep
private

Definition at line 471 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs18_cache_multiLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs18_cache_multiLep
private

Definition at line 477 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs18_cache_singleEle

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs18_cache_singleEle
private

Definition at line 455 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs18_cache_singleLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs18_cache_singleLep
private

Definition at line 463 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs22_cache_diLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs22_cache_diLep
private

Definition at line 472 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs22_cache_multiLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs22_cache_multiLep
private

Definition at line 478 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs22_cache_singleEle

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs22_cache_singleEle
private

Definition at line 456 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs22_cache_singleLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs22_cache_singleLep
private

Definition at line 464 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs23_cache_singleEle

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs23_cache_singleEle
private

Definition at line 457 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs23_cache_singleLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs23_cache_singleLep
private

Definition at line 465 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs24_cache_singleEle

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs24_cache_singleEle
private

Definition at line 458 of file SUSYObjDef_xAOD.h.

◆ m_v_trigs24_cache_singleLep

std::vector<std::string> ST::SUSYObjDef_xAOD::m_v_trigs24_cache_singleLep
private

Definition at line 466 of file SUSYObjDef_xAOD.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< AlgTool > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
privateinherited

Definition at line 398 of file AthCommonDataStore.h.

◆ m_WconfigReader

TEnv ST::SUSYObjDef_xAOD::m_WconfigReader
protected

Definition at line 550 of file SUSYObjDef_xAOD.h.

◆ m_WDecorName

std::string ST::SUSYObjDef_xAOD::m_WDecorName
protected

Definition at line 553 of file SUSYObjDef_xAOD.h.

◆ m_WtagConfig

std::string ST::SUSYObjDef_xAOD::m_WtagConfig
protected

Definition at line 556 of file SUSYObjDef_xAOD.h.

◆ m_WTaggerTool

asg::AnaToolHandle<SmoothedWZTagger> ST::SUSYObjDef_xAOD::m_WTaggerTool
protected

Definition at line 855 of file SUSYObjDef_xAOD.h.

◆ m_WTagjetUncertaintiesTool

asg::AnaToolHandle<ICPJetUncertaintiesTool> ST::SUSYObjDef_xAOD::m_WTagjetUncertaintiesTool
protected

Definition at line 859 of file SUSYObjDef_xAOD.h.

◆ m_WTagUncConfig

std::string ST::SUSYObjDef_xAOD::m_WTagUncConfig
protected

Definition at line 561 of file SUSYObjDef_xAOD.h.

◆ m_WZTaggerCalibArea

std::string ST::SUSYObjDef_xAOD::m_WZTaggerCalibArea
protected

Definition at line 559 of file SUSYObjDef_xAOD.h.

◆ m_ZconfigReader

TEnv ST::SUSYObjDef_xAOD::m_ZconfigReader
protected

Definition at line 551 of file SUSYObjDef_xAOD.h.

◆ m_ZDecorName

std::string ST::SUSYObjDef_xAOD::m_ZDecorName
protected

Definition at line 554 of file SUSYObjDef_xAOD.h.

◆ m_ZtagConfig

std::string ST::SUSYObjDef_xAOD::m_ZtagConfig
protected

Definition at line 557 of file SUSYObjDef_xAOD.h.

◆ m_ZTaggerTool

asg::AnaToolHandle<SmoothedWZTagger> ST::SUSYObjDef_xAOD::m_ZTaggerTool
protected

Definition at line 856 of file SUSYObjDef_xAOD.h.

◆ m_ZTagjetUncertaintiesTool

asg::AnaToolHandle<ICPJetUncertaintiesTool> ST::SUSYObjDef_xAOD::m_ZTagjetUncertaintiesTool
protected

Definition at line 860 of file SUSYObjDef_xAOD.h.

◆ m_ZTagUncConfig

std::string ST::SUSYObjDef_xAOD::m_ZTagUncConfig
protected

Definition at line 562 of file SUSYObjDef_xAOD.h.

◆ prompt_electrons

const xAOD::ElectronContainer* ST::SUSYObjDef_xAOD::prompt_electrons = nullptr

Definition at line 211 of file SUSYObjDef_xAOD.h.

◆ prompt_muons

const xAOD::MuonContainer* ST::SUSYObjDef_xAOD::prompt_muons = nullptr

Definition at line 205 of file SUSYObjDef_xAOD.h.


The documentation for this class was generated from the following files: