ATLAS Offline Software
Classes | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Types | Private Member Functions | Static Private Member Functions | Private Attributes | Friends | List of all members
TrigGlobalEfficiencyCorrectionTool Class Reference

#include <TrigGlobalEfficiencyCorrectionTool.h>

Inheritance diagram for TrigGlobalEfficiencyCorrectionTool:
Collaboration diagram for TrigGlobalEfficiencyCorrectionTool:

Classes

struct  CachedRanking
 
struct  Hierarchy
 
struct  TagDecorator
 
struct  ToolKey
 

Public Member Functions

virtual StatusCode initialize () override
 Dummy implementation of the initialisation function. More...
 
virtual CP::CorrectionCode getEfficiencyScaleFactor (const std::vector< const xAOD::IParticle * > &particles, double &efficiencyScaleFactor) override
 
virtual CP::CorrectionCode getEfficiencyScaleFactor (unsigned runNumber, const std::vector< const xAOD::IParticle * > &particles, double &efficiencyScaleFactor) override
 These should in principle not be used (except by unit tests), as the CP tools require the EventInfo decoration "RandomRunNumber" to be present. More...
 
virtual CP::CorrectionCode getEfficiency (const std::vector< const xAOD::IParticle * > &particles, double &efficiencyData, double &efficiencyMc) override
 
virtual CP::CorrectionCode getEfficiency (unsigned runNumber, const std::vector< const xAOD::IParticle * > &particles, double &efficiencyData, double &efficiencyMc) override
 
virtual bool isAffectedBySystematic (const CP::SystematicVariation &systematic) const override
 Declare the interface that this class provides. More...
 
virtual CP::SystematicSet affectingSystematics () const override
 the list of all systematics this tool can be affected by More...
 
virtual CP::SystematicSet recommendedSystematics () const override
 the list of all systematics this tool recommends to use More...
 
virtual StatusCode applySystematicVariation (const CP::SystematicSet &systConfig) override
 effects: configure this tool for the given list of systematic variations. More...
 
virtual CP::CorrectionCode checkTriggerMatching (bool &matched, const std::vector< const xAOD::IParticle * > &particles) override
 
virtual CP::CorrectionCode getRelevantTriggers (std::vector< std::string > &triggers) override
 This will fill the 'triggers' argument with the names of the triggers relevant for the current run number, among those specified in the tool configuration. More...
 
virtual CP::CorrectionCode countTriggerLegs (const std::string &trigger, std::size_t &numberOfLegs) override
 This utility function provides the number of legs for the specified trigger. More...
 
template<class CPTool >
bool enumerateTools (ImportData &data, ToolHandleArray< CPTool > &suppliedTools, std::map< ToolKey, std::size_t > &toolIndex, flat_set< std::size_t > &collectedTags)
 
virtual void print () const
 Print the state of the tool. More...
 
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & evtStore () const
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc. More...
 
virtual StatusCode sysInitialize () override
 Perform system initialization for an algorithm. More...
 
virtual StatusCode sysStart () override
 Handle START transition. More...
 
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles. More...
 
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles. More...
 
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T, V, H > &t)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc="none")
 Declare a new Gaudi property. More...
 
void updateVHKA (Gaudi::Details::PropertyBase &)
 
MsgStream & msg () const
 
MsgStream & msg (const MSG::Level lvl) const
 
bool msgLvl (const MSG::Level lvl) const
 
template<typename... Args>
auto getEfficiencyScaleFactor (Args &... args) -> std::enable_if_t< validArgs< Args... >(1), CP::CorrectionCode >
 Alternatively, the list of particles can be supplied via one or several vectors of xAOD::Electron*‍/Muon*‍/Photon* The generic signature is getEfficiencyScaleFactor((const) vector<(const)Type1*>&, ..., (const) vector<(const)TypeN*>&, double& efficiencyScaleFactor) e.g. More...
 
template<typename... Args>
auto getEfficiency (Args &... args) -> std::enable_if_t< validArgs< Args... >(2), CP::CorrectionCode >
 
template<typename... Args>
auto checkTriggerMatching (bool &matched, Args &... args) -> std::enable_if_t< validArgs< Args... >(0), CP::CorrectionCode >
 

Static Public Member Functions

static CP::CorrectionCode suggestElectronMapKeys (const std::map< std::string, std::string > &triggerCombination, const std::string &version, std::map< std::string, std::string > &legsPerKey)
 
static CP::CorrectionCode suggestPhotonMapKeys (const std::map< std::string, std::string > &triggerCombination, const std::string &version, std::map< std::string, std::string > &legsPerKey)
 
static CP::CorrectionCode suggestEgammaMapKeys (const std::map< std::string, std::string > &triggerCombination, const std::string &version, std::map< std::string, std::string > &legsPerKey, xAOD::Type::ObjectType type)
 
template<typename Arg >
static constexpr bool validArgs (unsigned nTrailingDoubles)
 
template<typename Arg1 , typename Arg2 , typename... OtherArgs>
static constexpr bool validArgs (unsigned nTrailingDoubles)
 
static std::string toolnameForDefaultScaleFactor ()
 To be used with the ListOfLegsPerTool property: More...
 

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution More...
 
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. More...
 
double * handleArg (double &arg, std::vector< const xAOD::IParticle * > &)
 
template<typename P >
double * handleArg (const std::vector< P > &arg, std::vector< const xAOD::IParticle * > &particles)
 

Private Types

enum  TLE_RESULT { TLE_OK, TLE_UNAVAILABLE, TLE_ERROR }
 
using LeptonList = std::vector< TrigGlobEffCorr::Lepton >
 
template<typename Key >
using flat_set = boost::container::flat_set< Key >
 
typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

bool loadHierarchies ()
 Internal methods (I) – initialization of the tool. More...
 
template<class CPTool >
bool enumerateTools (TrigGlobEffCorr::ImportData &data, ToolHandleArray< CPTool > &suppliedTools, std::map< ToolKey, std::size_t > &toolIndex, flat_set< std::size_t > &collectedTags)
 
flat_set< ToolKeyparseListOfLegs (TrigGlobEffCorr::ImportData &data, const std::string &inputList, bool &success)
 
bool parseTagString (const std::string &tagstring, flat_set< std::size_t > &tags)
 
bool loadTriggerCombination (TrigGlobEffCorr::ImportData &data, bool useDefaultElectronTools, bool useDefaultPhotonTools)
 
bool loadTagDecorators (const flat_set< std::size_t > &collectedElectronTags, const flat_set< std::size_t > &collectedMuonTags, const flat_set< std::size_t > &collectedPhotonTags)
 
bool loadListOfLegsPerTag ()
 
bool processDeprecatedProperties ()
 
bool retrieveRunNumber (unsigned &runNumber)
 Internal methods (II) – core task. More...
 
bool retrieveEventNumber (unsigned long &eventNumber)
 
bool aboveThreshold (const TrigGlobEffCorr::Lepton &p, std::size_t leg) const
 
template<class... ListOfLegs>
unsigned long getCachedTriggerLegsRanking (const TrigGlobEffCorr::Lepton &lepton, ListOfLegs... legs)
 
std::size_t getLoosestLegAboveThreshold (const TrigGlobEffCorr::Lepton &lepton, const flat_set< std::size_t > &legs, bool &success)
 
std::size_t getLoosestLeg (const TrigGlobEffCorr::Lepton &lepton, std::size_t leg1, std::size_t leg2, bool &success)
 
std::pair< std::size_t, std::size_t > getTwoLoosestLegs (const TrigGlobEffCorr::Lepton &lepton, const flat_set< std::size_t > &legs, bool &success)
 
std::vector< std::size_t > getSortedLegs (const TrigGlobEffCorr::Lepton &lepton, const flat_set< std::size_t > &legs, bool &success)
 
template<class Container >
CachedRanking rankTriggerLegs (float pt, const Container &legs)
 
template<class Particle >
bool updateLeptonList (LeptonList &leptons, const std::vector< const Particle * > &particles)
 
void updateMuonTriggerNames (std::size_t leg, const std::string &name)
 
TLE_RESULT getTriggerLegEfficiencies (const xAOD::Electron *p, unsigned runNumber, std::size_t leg, std::size_t tag, TrigGlobEffCorr::Efficiencies &efficiencies)
 
TLE_RESULT getTriggerLegEfficiencies (const xAOD::Muon *p, unsigned runNumber, std::size_t leg, std::size_t tag, TrigGlobEffCorr::Efficiencies &efficiencies)
 
TLE_RESULT getTriggerLegEfficiencies (const xAOD::Photon *p, unsigned runNumber, std::size_t leg, std::size_t tag, TrigGlobEffCorr::Efficiencies &efficiencies)
 
template<class ParticleType >
TLE_RESULT getEgammaTriggerLegEfficiencies (const ParticleType *p, unsigned runNumber, std::size_t leg, std::size_t tag, TrigGlobEffCorr::Efficiencies &efficiencies)
 
decltype(m_electronSfToolIndex) & GetScaleFactorToolIndex (const xAOD::Electron *)
 
decltype(m_photonSfToolIndex) & GetScaleFactorToolIndex (const xAOD::Photon *)
 
decltype(m_electronEffToolIndex) & GetEfficiencyToolIndex (const xAOD::Electron *)
 
decltype(m_photonEffToolIndex) & GetEfficiencyToolIndex (const xAOD::Photon *)
 
IAsgElectronEfficiencyCorrectionToolGetScaleFactorTool (const xAOD::Electron *, std::size_t index)
 
IAsgPhotonEfficiencyCorrectionToolGetScaleFactorTool (const xAOD::Photon *, std::size_t index)
 
IAsgElectronEfficiencyCorrectionToolGetEfficiencyTool (const xAOD::Electron *, std::size_t index)
 
IAsgPhotonEfficiencyCorrectionToolGetEfficiencyTool (const xAOD::Photon *, std::size_t index)
 
std::size_t getCombinedHash (const flat_set< std::size_t > &legs)
 
std::size_t getCombinedHash (std::size_t leg1, std::size_t leg2)
 
bool checkAndRecord (CP::CorrectionCode &&cc)
 Internal methods (III) – misc. helpers. More...
 
flat_set< std::size_t > listNonOrderedCSValues (const std::string &s, bool &success)
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Static Private Member Functions

static constexpr const flat_set< std::size_t > & forwardLegs (const flat_set< std::size_t > &legs)
 
static constexpr std::array< std::size_t, 2 > forwardLegs (std::size_t leg1, std::size_t leg2)
 

Private Attributes

ToolHandleArray< IAsgElectronEfficiencyCorrectionToolm_suppliedElectronEfficiencyTools
 Properties: More...
 
ToolHandleArray< IAsgElectronEfficiencyCorrectionToolm_suppliedElectronScaleFactorTools
 
ToolHandleArray< IAsgPhotonEfficiencyCorrectionToolm_suppliedPhotonEfficiencyTools
 
ToolHandleArray< IAsgPhotonEfficiencyCorrectionToolm_suppliedPhotonScaleFactorTools
 
ToolHandleArray< CP::IMuonTriggerScaleFactorsm_suppliedMuonTools
 
std::map< std::string, std::string > m_legsPerTool
 
std::map< std::string, std::string > m_triggerCb
 
std::map< std::string, std::string > m_triggerCbPerYear
 
std::string m_leptonTagDecorations
 
std::map< std::string, std::string > m_tagsPerTool
 
std::map< std::string, std::string > m_electronLegsPerTag
 
std::map< std::string, std::string > m_muonLegsPerTag
 deprecated More...
 
std::map< std::string, std::string > m_legsPerTag
 deprecated More...
 
std::map< std::string, std::string > m_overrideThresholds
 
unsigned long m_numberOfToys
 
bool m_useInternalSeed
 
ToolHandle< Trig::IMatchingToolm_trigMatchTool
 
std::hash< std::string > m_hasher
 
std::map< std::size_t, float > m_thresholds
 
std::multimap< std::size_t, CachedRankingm_cachedLegRankings
 
std::map< ToolKey, std::size_t > m_electronSfToolIndex
 
std::map< ToolKey, std::size_t > m_electronEffToolIndex
 
std::map< ToolKey, std::size_t > m_photonSfToolIndex
 
std::map< ToolKey, std::size_t > m_photonEffToolIndex
 
std::map< ToolKey, std::size_t > m_muonToolIndex
 
std::set< std::size_t > m_validLegTagPairs
 
bool m_checkElectronLegTag
 
bool m_checkMuonLegTag
 
bool m_checkPhotonLegTag
 
std::map< std::size_t, std::string > m_dictionary
 
std::set< ToolKeym_unsupportedLegs
 
std::vector< Hierarchym_hierarchyMeta
 
std::vector< std::size_t > m_hierarchyData
 
bool m_initialized = false
 
CP::CorrectionCode m_cpCode = CP::CorrectionCode::Ok
 
unsigned long m_seed
 
bool m_validTrigMatchTool
 
std::vector< TagDecoratorm_leptonTagDecorators
 
SG::AuxElement::ConstAccessor< unsigned int > m_runNumberDecorator
 
std::unique_ptr< TrigGlobEffCorr::Calculatorm_calculator
 
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default) More...
 
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default) More...
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
bool m_varHandleArraysDeclared
 

Friends

class TrigGlobEffCorr::ImportData
 
class TrigGlobEffCorr::CheckConfig
 
class TrigGlobEffCorr::Calculator
 

Detailed Description

Definition at line 35 of file TrigGlobalEfficiencyCorrectionTool.h.

Member Typedef Documentation

◆ flat_set

template<typename Key >
using TrigGlobalEfficiencyCorrectionTool::flat_set = boost::container::flat_set<Key>
private

Definition at line 193 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ LeptonList

Definition at line 140 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ StoreGateSvc_t

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

Definition at line 388 of file AthCommonDataStore.h.

Member Enumeration Documentation

◆ TLE_RESULT

Enumerator
TLE_OK 
TLE_UNAVAILABLE 
TLE_ERROR 

Definition at line 240 of file TrigGlobalEfficiencyCorrectionTool.h.

Member Function Documentation

◆ aboveThreshold()

bool TrigGlobalEfficiencyCorrectionTool::aboveThreshold ( const TrigGlobEffCorr::Lepton p,
std::size_t  leg 
) const
private

◆ affectingSystematics()

virtual CP::SystematicSet TrigGlobalEfficiencyCorrectionTool::affectingSystematics ( ) const
overridevirtual

the list of all systematics this tool can be affected by

Implements CP::IReentrantSystematicsTool.

◆ applySystematicVariation()

virtual StatusCode TrigGlobalEfficiencyCorrectionTool::applySystematicVariation ( const CP::SystematicSet systConfig)
overridevirtual

effects: configure this tool for the given list of systematic variations.

any requested systematics that are not affecting this tool will be silently ignored (unless they cause other errors). failures: systematic unknown failures: requesting multiple variations on the same systematic (e.g. up & down) failures: requesting an unsupported variation on an otherwise supported systematic (e.g. a 2 sigma variation and the tool only supports 1 sigma variations) failures: unsupported combination of supported systematic failures: other tool specific errors

Implements CP::ISystematicsTool.

◆ checkAndRecord()

bool TrigGlobalEfficiencyCorrectionTool::checkAndRecord ( CP::CorrectionCode &&  cc)
inlineprivate

Internal methods (III) – misc. helpers.

◆ checkTriggerMatching() [1/2]

template<typename... Args>
auto ITrigGlobalEfficiencyCorrectionTool::checkTriggerMatching ( bool &  matched,
Args &...  args 
) -> std::enable_if_t<validArgs<Args...>(0), CP::CorrectionCode>
inherited

Definition at line 110 of file ITrigGlobalEfficiencyCorrectionTool.h.

112 {
113  std::vector<const xAOD::IParticle*> particles;
114  double* eff[] __attribute__((unused)) = { nullptr, handleArg(args, particles)... };
116 }

◆ checkTriggerMatching() [2/2]

virtual CP::CorrectionCode TrigGlobalEfficiencyCorrectionTool::checkTriggerMatching ( bool &  matched,
const std::vector< const xAOD::IParticle * > &  particles 
)
overridevirtual

◆ countTriggerLegs()

virtual CP::CorrectionCode TrigGlobalEfficiencyCorrectionTool::countTriggerLegs ( const std::string &  trigger,
std::size_t &  numberOfLegs 
)
overridevirtual

This utility function provides the number of legs for the specified trigger.

Implements ITrigGlobalEfficiencyCorrectionTool.

◆ declareGaudiProperty() [1/4]

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

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

Definition at line 170 of file AthCommonDataStore.h.

172  {
173  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
174  hndl.value(),
175  hndl.documentation());
176 
177  }

◆ declareGaudiProperty() [2/4]

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  {
159  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
160  hndl.value(),
161  hndl.documentation());
162 
163  }

◆ declareGaudiProperty() [3/4]

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

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

Definition at line 184 of file AthCommonDataStore.h.

186  {
187  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
188  hndl.value(),
189  hndl.documentation());
190  }

◆ declareGaudiProperty() [4/4]

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

specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>

Definition at line 199 of file AthCommonDataStore.h.

200  {
201  return PBASE::declareProperty(t);
202  }

◆ declareProperty() [1/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleBase hndl,
const std::string &  doc,
const SG::VarHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleBase. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 245 of file AthCommonDataStore.h.

249  {
250  this->declare(hndl.vhKey());
251  hndl.vhKey().setOwner(this);
252 
253  return PBASE::declareProperty(name,hndl,doc);
254  }

◆ declareProperty() [2/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKey hndl,
const std::string &  doc,
const SG::VarHandleKeyType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleKey. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 221 of file AthCommonDataStore.h.

225  {
226  this->declare(hndl);
227  hndl.setOwner(this);
228 
229  return PBASE::declareProperty(name,hndl,doc);
230  }

◆ declareProperty() [3/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKeyArray hndArr,
const std::string &  doc,
const SG::VarHandleKeyArrayType  
)
inlineinherited

Definition at line 259 of file AthCommonDataStore.h.

263  {
264 
265  // std::ostringstream ost;
266  // ost << Algorithm::name() << " VHKA declareProp: " << name
267  // << " size: " << hndArr.keys().size()
268  // << " mode: " << hndArr.mode()
269  // << " vhka size: " << m_vhka.size()
270  // << "\n";
271  // debug() << ost.str() << endmsg;
272 
273  hndArr.setOwner(this);
274  m_vhka.push_back(&hndArr);
275 
276  Gaudi::Details::PropertyBase* p = PBASE::declareProperty(name, hndArr, doc);
277  if (p != 0) {
278  p->declareUpdateHandler(&AthCommonDataStore<PBASE>::updateVHKA, this);
279  } else {
280  ATH_MSG_ERROR("unable to call declareProperty on VarHandleKeyArray "
281  << name);
282  }
283 
284  return p;
285 
286  }

◆ declareProperty() [4/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc,
const SG::NotHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This is the generic version, for types that do not derive from SG::VarHandleKey. It just forwards to the base class version of declareProperty.

Definition at line 333 of file AthCommonDataStore.h.

337  {
338  return PBASE::declareProperty(name, property, doc);
339  }

◆ declareProperty() [5/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc = "none" 
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This dispatches to either the generic declareProperty or the one for VarHandle/Key/KeyArray.

Definition at line 352 of file AthCommonDataStore.h.

355  {
356  typedef typename SG::HandleClassifier<T>::type htype;
357  return declareProperty (name, property, doc, htype());
358  }

◆ declareProperty() [6/6]

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  }

◆ 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.

95 { return m_detStore; }

◆ enumerateTools() [1/2]

template<class CPTool >
bool TrigGlobalEfficiencyCorrectionTool::enumerateTools ( ImportData data,
ToolHandleArray< CPTool > &  suppliedTools,
std::map< ToolKey, std::size_t > &  toolIndex,
flat_set< std::size_t > &  collectedTags 
)

Find the legs associated to this tool ("ListOfLegsPerTool" property)

Find the tags associated to this tool ("ListOfTagsPerTool" property)

Store

Definition at line 240 of file TrigGlobalEfficiencyCorrectionTool.cxx.

243  {
244  bool success = true;
245  for (unsigned index = 0; index < suppliedTools.size(); ++index) {
246  auto& handle = suppliedTools[index];
247  const std::string& name = handle.name();
248  const std::string& altname = handle->name(); // athena: not always the same
249  flat_set<ToolKey> listOfLegs;
251  if (suppliedTools.size() != 1 || m_legsPerTool.size() != 0) {
252  auto itrLegs = m_legsPerTool.find(name);
253  if (itrLegs == m_legsPerTool.end())
254  itrLegs = m_legsPerTool.find(altname);
255  if (itrLegs != m_legsPerTool.end()) {
256  listOfLegs = parseListOfLegs(data, itrLegs->second, success);
257  if (!success) {
259  "The 'ListOfLegsPerTool' property has an invalid entry for the "
260  "tool'"
261  << name << "'");
262  continue;
263  }
264  } else if (std::is_same<CPTool,
266  std::is_same<CPTool,
268  ATH_MSG_ERROR("Property 'ListOfLegsPerTool' empty for tool '" << name
269  << "'");
270  success = false;
271  continue;
272  } else {
273  listOfLegs.emplace();
274  }
275  } else
276  listOfLegs.emplace();
279  auto itrTags = m_tagsPerTool.find(name);
280  if (itrTags == m_tagsPerTool.end())
281  itrTags = m_tagsPerTool.find(altname);
282  if (itrTags != m_tagsPerTool.end()) {
283  success = success && parseTagString(itrTags->second, tags);
284  collectedTags.insert(tags.begin(), tags.end());
285  } else
286  tags.emplace(0);
287 
289  unsigned short nUncheckedLegs = 0;
290  for (auto& key : listOfLegs) {
291  std::size_t leg = key.hash;
292  if (leg) {
293  auto flavour = data.associatedLeptonFlavour(leg, success);
294  if (!(flavour == xAOD::Type::Electron &&
295  std::is_same<CPTool,
297  !(flavour == xAOD::Type::Photon &&
298  std::is_same<CPTool,
300  ATH_MSG_ERROR("Unexpected association of trigger leg '"
301  << m_dictionary[leg] << "' to tool '" << name << "'");
302  success = false;
303  }
304  }
305  for (std::size_t tag : tags) {
306  if (!toolIndex.emplace(ToolKey(leg, tag, key.boundaries), index)
307  .second) {
308  if (leg && tag)
309  ATH_MSG_ERROR("Multiple tools associated to the selection tag '"
310  << m_dictionary[tag] << "' for the trigger leg '"
311  << m_dictionary[leg] << "'");
312  else if (leg)
313  ATH_MSG_ERROR("Multiple tools associated to the trigger leg '"
314  << m_dictionary[leg] << "'");
315  else if (tag)
316  ATH_MSG_ERROR("Multiple tools associated to the selection tag '"
317  << m_dictionary[tag] << "'");
318  else
320  "Multiple tools not associated to any trigger leg / selection "
321  "tag");
322  success = false;
323  }
324  }
325  ++nUncheckedLegs;
326  }
327  if (!nUncheckedLegs) {
328  ATH_MSG_ERROR("Tool " << name
329  << " hasn't been associated to any trigger leg");
330  success = false;
331  }
332  }
333  return success;
334 }

◆ enumerateTools() [2/2]

template<class CPTool >
bool TrigGlobalEfficiencyCorrectionTool::enumerateTools ( TrigGlobEffCorr::ImportData data,
ToolHandleArray< CPTool > &  suppliedTools,
std::map< ToolKey, std::size_t > &  toolIndex,
flat_set< std::size_t > &  collectedTags 
)
private

◆ evtStore() [1/2]

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.

85 { return m_evtStore; }

◆ evtStore() [2/2]

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

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

Definition at line 90 of file AthCommonDataStore.h.

90 { return m_evtStore; }

◆ 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

◆ forwardLegs() [1/2]

static constexpr const flat_set<std::size_t>& TrigGlobalEfficiencyCorrectionTool::forwardLegs ( const flat_set< std::size_t > &  legs)
inlinestaticconstexprprivate

◆ forwardLegs() [2/2]

static constexpr std::array<std::size_t, 2> TrigGlobalEfficiencyCorrectionTool::forwardLegs ( std::size_t  leg1,
std::size_t  leg2 
)
inlinestaticconstexprprivate

◆ getCachedTriggerLegsRanking()

template<class... ListOfLegs>
unsigned long TrigGlobalEfficiencyCorrectionTool::getCachedTriggerLegsRanking ( const TrigGlobEffCorr::Lepton lepton,
ListOfLegs...  legs 
)
private

◆ getCombinedHash() [1/2]

std::size_t TrigGlobalEfficiencyCorrectionTool::getCombinedHash ( const flat_set< std::size_t > &  legs)
private

◆ getCombinedHash() [2/2]

std::size_t TrigGlobalEfficiencyCorrectionTool::getCombinedHash ( std::size_t  leg1,
std::size_t  leg2 
)
private

◆ getEfficiency() [1/3]

template<typename... Args>
auto ITrigGlobalEfficiencyCorrectionTool::getEfficiency ( Args &...  args) -> std::enable_if_t<validArgs<Args...>(2), CP::CorrectionCode>
inherited

Definition at line 101 of file ITrigGlobalEfficiencyCorrectionTool.h.

103 {
104  std::vector<const xAOD::IParticle*> particles;
105  double* eff[] = { nullptr, handleArg(args, particles)... };
106  return getEfficiency(particles, *eff[sizeof...(Args)-1], *eff[sizeof...(Args)]);
107 }

◆ getEfficiency() [2/3]

virtual CP::CorrectionCode TrigGlobalEfficiencyCorrectionTool::getEfficiency ( const std::vector< const xAOD::IParticle * > &  particles,
double &  efficiencyData,
double &  efficiencyMc 
)
overridevirtual

◆ getEfficiency() [3/3]

virtual CP::CorrectionCode TrigGlobalEfficiencyCorrectionTool::getEfficiency ( unsigned  runNumber,
const std::vector< const xAOD::IParticle * > &  particles,
double &  efficiencyData,
double &  efficiencyMc 
)
overridevirtual

◆ getEfficiencyScaleFactor() [1/3]

template<typename... Args>
auto ITrigGlobalEfficiencyCorrectionTool::getEfficiencyScaleFactor ( Args &...  args) -> std::enable_if_t<validArgs<Args...>(1), CP::CorrectionCode>
inherited

Alternatively, the list of particles can be supplied via one or several vectors of xAOD::Electron*‍/Muon*‍/Photon* The generic signature is getEfficiencyScaleFactor((const) vector<(const)Type1*>&, ..., (const) vector<(const)TypeN*>&, double& efficiencyScaleFactor) e.g.

getEfficiencyScaleFactor(electrons, muons, sf); getEfficiencyScaleFactor(photons, sf); getEfficiencyScaleFactor(muons, electrons, photons, sf); don't forget the last argument(s)! (scale factor for getEfficiencyScaleFactor(), data and MC efficiencies for getEfficiency())

Definition at line 92 of file ITrigGlobalEfficiencyCorrectionTool.h.

94 {
95  std::vector<const xAOD::IParticle*> particles;
96  double* sf[] = { nullptr, handleArg(args, particles)... };
97  return getEfficiencyScaleFactor(particles, *sf[sizeof...(Args)]);
98 }

◆ getEfficiencyScaleFactor() [2/3]

virtual CP::CorrectionCode TrigGlobalEfficiencyCorrectionTool::getEfficiencyScaleFactor ( const std::vector< const xAOD::IParticle * > &  particles,
double &  efficiencyScaleFactor 
)
overridevirtual

◆ getEfficiencyScaleFactor() [3/3]

virtual CP::CorrectionCode TrigGlobalEfficiencyCorrectionTool::getEfficiencyScaleFactor ( unsigned  runNumber,
const std::vector< const xAOD::IParticle * > &  particles,
double &  efficiencyScaleFactor 
)
overridevirtual

These should in principle not be used (except by unit tests), as the CP tools require the EventInfo decoration "RandomRunNumber" to be present.

Implements ITrigGlobalEfficiencyCorrectionTool.

◆ GetEfficiencyTool() [1/2]

IAsgElectronEfficiencyCorrectionTool& TrigGlobalEfficiencyCorrectionTool::GetEfficiencyTool ( const xAOD::Electron ,
std::size_t  index 
)
inlineprivate

Definition at line 276 of file TrigGlobalEfficiencyCorrectionTool.h.

277  {
279  }

◆ GetEfficiencyTool() [2/2]

IAsgPhotonEfficiencyCorrectionTool& TrigGlobalEfficiencyCorrectionTool::GetEfficiencyTool ( const xAOD::Photon ,
std::size_t  index 
)
inlineprivate

Definition at line 280 of file TrigGlobalEfficiencyCorrectionTool.h.

281  {
283  }

◆ GetEfficiencyToolIndex() [1/2]

decltype(m_electronEffToolIndex) & TrigGlobalEfficiencyCorrectionTool::GetEfficiencyToolIndex ( const xAOD::Electron )
inlineprivate

Definition at line 261 of file TrigGlobalEfficiencyCorrectionTool.h.

262  {
263  return m_electronEffToolIndex;
264  }

◆ GetEfficiencyToolIndex() [2/2]

decltype(m_photonEffToolIndex) & TrigGlobalEfficiencyCorrectionTool::GetEfficiencyToolIndex ( const xAOD::Photon )
inlineprivate

Definition at line 265 of file TrigGlobalEfficiencyCorrectionTool.h.

265  {
266  return m_photonEffToolIndex;
267  }

◆ getEgammaTriggerLegEfficiencies()

template<class ParticleType >
TLE_RESULT TrigGlobalEfficiencyCorrectionTool::getEgammaTriggerLegEfficiencies ( const ParticleType p,
unsigned  runNumber,
std::size_t  leg,
std::size_t  tag,
TrigGlobEffCorr::Efficiencies efficiencies 
)
private

◆ 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::TEvent 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::TEvent, 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  }

◆ getLoosestLeg()

std::size_t TrigGlobalEfficiencyCorrectionTool::getLoosestLeg ( const TrigGlobEffCorr::Lepton lepton,
std::size_t  leg1,
std::size_t  leg2,
bool &  success 
)
private

◆ getLoosestLegAboveThreshold()

std::size_t TrigGlobalEfficiencyCorrectionTool::getLoosestLegAboveThreshold ( const TrigGlobEffCorr::Lepton lepton,
const flat_set< std::size_t > &  legs,
bool &  success 
)
private

◆ 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::TEvent 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::TEvent, 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  }

◆ getProperty()

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

Get one of the tool's properties.

◆ getRelevantTriggers()

virtual CP::CorrectionCode TrigGlobalEfficiencyCorrectionTool::getRelevantTriggers ( std::vector< std::string > &  triggers)
overridevirtual

This will fill the 'triggers' argument with the names of the triggers relevant for the current run number, among those specified in the tool configuration.

Implements ITrigGlobalEfficiencyCorrectionTool.

◆ GetScaleFactorTool() [1/2]

IAsgElectronEfficiencyCorrectionTool& TrigGlobalEfficiencyCorrectionTool::GetScaleFactorTool ( const xAOD::Electron ,
std::size_t  index 
)
inlineprivate

Definition at line 268 of file TrigGlobalEfficiencyCorrectionTool.h.

269  {
271  }

◆ GetScaleFactorTool() [2/2]

IAsgPhotonEfficiencyCorrectionTool& TrigGlobalEfficiencyCorrectionTool::GetScaleFactorTool ( const xAOD::Photon ,
std::size_t  index 
)
inlineprivate

Definition at line 272 of file TrigGlobalEfficiencyCorrectionTool.h.

273  {
275  }

◆ GetScaleFactorToolIndex() [1/2]

decltype(m_electronSfToolIndex) & TrigGlobalEfficiencyCorrectionTool::GetScaleFactorToolIndex ( const xAOD::Electron )
inlineprivate

Definition at line 254 of file TrigGlobalEfficiencyCorrectionTool.h.

255  {
256  return m_electronSfToolIndex;
257  }

◆ GetScaleFactorToolIndex() [2/2]

decltype(m_photonSfToolIndex) & TrigGlobalEfficiencyCorrectionTool::GetScaleFactorToolIndex ( const xAOD::Photon )
inlineprivate

Definition at line 258 of file TrigGlobalEfficiencyCorrectionTool.h.

258  {
259  return m_photonSfToolIndex;
260  }

◆ getSortedLegs()

std::vector<std::size_t> TrigGlobalEfficiencyCorrectionTool::getSortedLegs ( const TrigGlobEffCorr::Lepton lepton,
const flat_set< std::size_t > &  legs,
bool &  success 
)
private

◆ getTriggerLegEfficiencies() [1/3]

TLE_RESULT TrigGlobalEfficiencyCorrectionTool::getTriggerLegEfficiencies ( const xAOD::Electron p,
unsigned  runNumber,
std::size_t  leg,
std::size_t  tag,
TrigGlobEffCorr::Efficiencies efficiencies 
)
private

◆ getTriggerLegEfficiencies() [2/3]

TLE_RESULT TrigGlobalEfficiencyCorrectionTool::getTriggerLegEfficiencies ( const xAOD::Muon p,
unsigned  runNumber,
std::size_t  leg,
std::size_t  tag,
TrigGlobEffCorr::Efficiencies efficiencies 
)
private

◆ getTriggerLegEfficiencies() [3/3]

TLE_RESULT TrigGlobalEfficiencyCorrectionTool::getTriggerLegEfficiencies ( const xAOD::Photon p,
unsigned  runNumber,
std::size_t  leg,
std::size_t  tag,
TrigGlobEffCorr::Efficiencies efficiencies 
)
private

◆ getTwoLoosestLegs()

std::pair<std::size_t, std::size_t> TrigGlobalEfficiencyCorrectionTool::getTwoLoosestLegs ( const TrigGlobEffCorr::Lepton lepton,
const flat_set< std::size_t > &  legs,
bool &  success 
)
private

◆ handleArg() [1/2]

template<typename P >
double* ITrigGlobalEfficiencyCorrectionTool::handleArg ( const std::vector< P > &  arg,
std::vector< const xAOD::IParticle * > &  particles 
)
inlineprotectedinherited

Definition at line 59 of file ITrigGlobalEfficiencyCorrectionTool.h.

60  {
61  for(auto ptr : arg) particles.push_back(static_cast<const xAOD::IParticle*>(ptr));
62  return nullptr;
63  }

◆ handleArg() [2/2]

double* ITrigGlobalEfficiencyCorrectionTool::handleArg ( double &  arg,
std::vector< const xAOD::IParticle * > &   
)
inlineprotectedinherited

Definition at line 58 of file ITrigGlobalEfficiencyCorrectionTool.h.

58 { return &arg; }

◆ initialize()

StatusCode TrigGlobalEfficiencyCorrectionTool::initialize ( )
overridevirtual

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...

Copy the following variables from data as the latter is short-lived

Reimplemented from asg::AsgTool.

Definition at line 100 of file TrigGlobalEfficiencyCorrectionTool.cxx.

100  {
101  if (m_initialized) {
102  ATH_MSG_ERROR("Tool has already been initialized");
103  return StatusCode::FAILURE;
104  }
105  ATH_MSG_INFO("Initializing " << name() << "...");
106 
107  m_dictionary.emplace(0, "");
108 
110  return StatusCode::FAILURE;
111 
112  ATH_MSG_DEBUG("Importing data from configuration files");
113  ImportData data(*this);
114  if (!data.importAll(m_overrideThresholds))
115  return StatusCode::FAILURE;
117  m_hierarchyMeta = data.getHierarchyMeta();
118  m_hierarchyData = data.getHierarchyData();
119  m_thresholds = data.getTriggerThresholds();
120 
121  ATH_MSG_DEBUG("Retrieving tools");
122  if (m_suppliedElectronEfficiencyTools.retrieve() != StatusCode::SUCCESS ||
123  m_suppliedElectronScaleFactorTools.retrieve() != StatusCode::SUCCESS ||
124  m_suppliedMuonTools.retrieve() != StatusCode::SUCCESS ||
125  m_suppliedPhotonEfficiencyTools.retrieve() != StatusCode::SUCCESS ||
126  m_suppliedPhotonScaleFactorTools.retrieve() != StatusCode::SUCCESS) {
127  ATH_MSG_ERROR("Unable to retrieve CP tools");
128  return StatusCode::FAILURE;
129  }
130 
131  ATH_MSG_DEBUG("Retrieving trigger matching tool (if provided)");
132  m_validTrigMatchTool = false;
133  if (m_trigMatchTool.name() != "") {
134  if (m_trigMatchTool.retrieve() != StatusCode::SUCCESS) {
135  ATH_MSG_ERROR("Unable to retrieve trigger matching tool");
136  return StatusCode::FAILURE;
137  }
138  ATH_MSG_DEBUG("Trigger matching support enabled");
139  m_validTrigMatchTool = true;
140  }
141 
142  ATH_MSG_DEBUG("Basic checks");
143  CheckConfig checks(*this);
144  if (!checks.basicConfigChecks())
145  return StatusCode::FAILURE;
146 
147  ATH_MSG_DEBUG("Enumerating tools");
148  flat_set<std::size_t> collectedElectronTags, collectedMuonTags,
149  collectedPhotonTags;
151  m_electronEffToolIndex, collectedElectronTags) ||
153  m_electronSfToolIndex, collectedElectronTags) ||
155  collectedMuonTags) ||
157  m_photonEffToolIndex, collectedPhotonTags) ||
159  m_photonSfToolIndex, collectedPhotonTags)) {
160  return StatusCode::FAILURE;
161  }
162  // List legs (if any) for which a dummy scale factor should be returned.
163  auto itr = m_legsPerTool.find(toolnameForDefaultScaleFactor());
164  if (itr != m_legsPerTool.end()) {
165  bool success = true;
166  for (ToolKey leg : parseListOfLegs(data, itr->second, success)) {
167  m_unsupportedLegs.insert(leg);
168  }
169  }
170 
171  ATH_MSG_DEBUG("Loading user-defined trigger combination");
172  bool useDefaultElectronTools =
173  (m_suppliedElectronEfficiencyTools.size() == 1) &&
174  (m_suppliedElectronScaleFactorTools.size() == 1) &&
175  (m_legsPerTool.size() == 0);
176  bool useDefaultPhotonTools = (m_suppliedPhotonEfficiencyTools.size() == 1) &&
177  (m_suppliedPhotonScaleFactorTools.size() == 1) &&
178  (m_legsPerTool.size() == 0);
179  if (!loadTriggerCombination(data, useDefaultElectronTools,
180  useDefaultPhotonTools))
181  return StatusCode::FAILURE;
182 
183  ATH_MSG_DEBUG("Loading lepton selection tags decorators");
184  if (!loadTagDecorators(collectedElectronTags, collectedMuonTags,
185  collectedPhotonTags))
186  return StatusCode::FAILURE;
187 
188  ATH_MSG_DEBUG("Loading list of legs allowed for each tag");
189  if (!loadListOfLegsPerTag())
190  return StatusCode::FAILURE;
191 
192  ATH_MSG_DEBUG("Advanced checks");
193  if (!checks.advancedConfigChecks())
194  return StatusCode::FAILURE;
195 
196  ATH_MSG_INFO("Initialization successful");
197  m_initialized = true;
198  return StatusCode::SUCCESS;
199 }

◆ 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.

◆ isAffectedBySystematic()

virtual bool TrigGlobalEfficiencyCorrectionTool::isAffectedBySystematic ( const CP::SystematicVariation systematic) const
overridevirtual

Declare the interface that this class provides.

returns: whether this tool is affected by the given systematics

Implements CP::ISystematicsTool.

◆ listNonOrderedCSValues()

flat_set<std::size_t> TrigGlobalEfficiencyCorrectionTool::listNonOrderedCSValues ( const std::string &  s,
bool &  success 
)
private

◆ loadHierarchies()

bool TrigGlobalEfficiencyCorrectionTool::loadHierarchies ( )
private

Internal methods (I) – initialization of the tool.

◆ loadListOfLegsPerTag()

bool TrigGlobalEfficiencyCorrectionTool::loadListOfLegsPerTag ( )
private

◆ loadTagDecorators()

bool TrigGlobalEfficiencyCorrectionTool::loadTagDecorators ( const flat_set< std::size_t > &  collectedElectronTags,
const flat_set< std::size_t > &  collectedMuonTags,
const flat_set< std::size_t > &  collectedPhotonTags 
)
private

◆ loadTriggerCombination()

bool TrigGlobalEfficiencyCorrectionTool::loadTriggerCombination ( TrigGlobEffCorr::ImportData data,
bool  useDefaultElectronTools,
bool  useDefaultPhotonTools 
)
private

◆ msg() [1/2]

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

Definition at line 24 of file AthCommonMsg.h.

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

◆ msg() [2/2]

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

Definition at line 27 of file AthCommonMsg.h.

27  {
28  return this->msgStream(lvl);
29  }

◆ 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  }

◆ 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  }

◆ 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.

◆ parseListOfLegs()

auto TrigGlobalEfficiencyCorrectionTool::parseListOfLegs ( TrigGlobEffCorr::ImportData data,
const std::string &  inputList,
bool &  success 
)
private

Definition at line 336 of file TrigGlobalEfficiencyCorrectionTool.cxx.

◆ parseTagString()

bool TrigGlobalEfficiencyCorrectionTool::parseTagString ( const std::string &  tagstring,
flat_set< std::size_t > &  tags 
)
private

Definition at line 225 of file TrigGlobalEfficiencyCorrectionTool.cxx.

226  {
227  bool success = true;
228  const std::size_t star = m_hasher("*");
229  for (std::size_t tag : listNonOrderedCSValues(tagstring, success)) {
230  allTags.insert((tag != star) ? tag : 0);
231  }
232  if (!success) {
233  ATH_MSG_ERROR("List of tags \"" << tagstring
234  << "\" is not provided in a valid format");
235  }
236  return success;
237 }

◆ print()

void asg::AsgTool::print ( ) const
virtualinherited

◆ processDeprecatedProperties()

bool TrigGlobalEfficiencyCorrectionTool::processDeprecatedProperties ( )
private

Definition at line 201 of file TrigGlobalEfficiencyCorrectionTool.cxx.

201  {
202  if (m_electronLegsPerTag.size()) {
204  "The property 'ElectronLegsPerTag' is deprecated, please use "
205  "'ListOfLegsPerTag' instead");
206  for (auto& kv : m_electronLegsPerTag) {
207  auto insert = m_legsPerTag.insert(kv);
208  if (!insert.second)
209  insert.first->second += "," + kv.second;
210  }
211  }
212  if (m_muonLegsPerTag.size()) {
214  "The property 'MuonLegsPerTag' is deprecated, please use "
215  "'ListOfLegsPerTag' instead");
216  for (auto& kv : m_muonLegsPerTag) {
217  auto insert = m_legsPerTag.insert(kv);
218  if (!insert.second)
219  insert.first->second += "," + kv.second;
220  }
221  }
222  return true;
223 }

◆ rankTriggerLegs()

template<class Container >
CachedRanking TrigGlobalEfficiencyCorrectionTool::rankTriggerLegs ( float  pt,
const Container legs 
)
private

◆ recommendedSystematics()

virtual CP::SystematicSet TrigGlobalEfficiencyCorrectionTool::recommendedSystematics ( ) const
overridevirtual

the list of all systematics this tool recommends to use

Implements CP::IReentrantSystematicsTool.

◆ 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();
383  PBASE::renounce (h);
384  }

◆ 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  {
365  handlesArray.renounce();
366  }

◆ retrieveEventNumber()

bool TrigGlobalEfficiencyCorrectionTool::retrieveEventNumber ( unsigned long &  eventNumber)
private

◆ retrieveRunNumber()

bool TrigGlobalEfficiencyCorrectionTool::retrieveRunNumber ( unsigned &  runNumber)
private

Internal methods (II) – core task.

◆ suggestEgammaMapKeys()

static CP::CorrectionCode TrigGlobalEfficiencyCorrectionTool::suggestEgammaMapKeys ( const std::map< std::string, std::string > &  triggerCombination,
const std::string &  version,
std::map< std::string, std::string > &  legsPerKey,
xAOD::Type::ObjectType  type 
)
static

◆ suggestElectronMapKeys()

static CP::CorrectionCode TrigGlobalEfficiencyCorrectionTool::suggestElectronMapKeys ( const std::map< std::string, std::string > &  triggerCombination,
const std::string &  version,
std::map< std::string, std::string > &  legsPerKey 
)
inlinestatic

Definition at line 75 of file TrigGlobalEfficiencyCorrectionTool.h.

78  {
79  return suggestEgammaMapKeys(triggerCombination, version, legsPerKey,
81  }

◆ suggestPhotonMapKeys()

static CP::CorrectionCode TrigGlobalEfficiencyCorrectionTool::suggestPhotonMapKeys ( const std::map< std::string, std::string > &  triggerCombination,
const std::string &  version,
std::map< std::string, std::string > &  legsPerKey 
)
inlinestatic

Definition at line 82 of file TrigGlobalEfficiencyCorrectionTool.h.

85  {
86  return suggestEgammaMapKeys(triggerCombination, version, legsPerKey,
88  }

◆ sysInitialize()

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

Perform system initialization for an algorithm.

We override this to declare all the elements of handle key arrays at the end of initialization. See comments on updateVHKA.

Reimplemented in DerivationFramework::CfAthAlgTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and asg::AsgMetadataTool.

◆ 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.

◆ toolnameForDefaultScaleFactor()

static std::string ITrigGlobalEfficiencyCorrectionTool::toolnameForDefaultScaleFactor ( )
inlinestaticinherited

To be used with the ListOfLegsPerTool property:

Definition at line 56 of file ITrigGlobalEfficiencyCorrectionTool.h.

56 { return "RETURN_DEFAULT_SCALE_FACTOR"; }

◆ updateLeptonList()

template<class Particle >
bool TrigGlobalEfficiencyCorrectionTool::updateLeptonList ( LeptonList leptons,
const std::vector< const Particle * > &  particles 
)
private

◆ updateMuonTriggerNames()

void TrigGlobalEfficiencyCorrectionTool::updateMuonTriggerNames ( std::size_t  leg,
const std::string &  name 
)
private

◆ 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) {
312  std::vector<SG::VarHandleKey*> keys = a->keys();
313  for (auto k : keys) {
314  k->setOwner(this);
315  }
316  }
317  }

◆ validArgs() [1/2]

template<typename Arg >
constexpr bool ITrigGlobalEfficiencyCorrectionTool::validArgs ( unsigned  nTrailingDoubles)
staticconstexprinherited

Definition at line 67 of file ITrigGlobalEfficiencyCorrectionTool.h.

68 {
69  if(std::is_same<double, Arg>::value) return (nTrailingDoubles==1);
70  using P = std::remove_cv_t<Arg>;
71  return std::is_same<P, std::vector<xAOD::Electron*>>::value
72  || std::is_same<P, std::vector<const xAOD::Electron*>>::value
73  || std::is_same<P, std::vector<xAOD::Muon*>>::value
74  || std::is_same<P, std::vector<const xAOD::Muon*>>::value
75  || std::is_same<P, std::vector<xAOD::Photon*>>::value
76  || std::is_same<P, std::vector<const xAOD::Photon*>>::value;
77 }

◆ validArgs() [2/2]

template<typename Arg1 , typename Arg2 , typename... OtherArgs>
constexpr bool ITrigGlobalEfficiencyCorrectionTool::validArgs ( unsigned  nTrailingDoubles)
staticconstexprinherited

Definition at line 80 of file ITrigGlobalEfficiencyCorrectionTool.h.

81 {
82  bool xs [] = { std::is_same<OtherArgs, double>::value..., true };
83  for(bool x : xs) if(!x) return validArgs<Arg1>(0) && validArgs<Arg2, OtherArgs...>(nTrailingDoubles);
84  unsigned nTD = sizeof...(OtherArgs);
85  if(nTD == nTrailingDoubles) return validArgs<Arg1>(0) && validArgs<Arg2>(0);
86  if(nTD == nTrailingDoubles-1) return validArgs<Arg1>(0) && std::is_same<Arg2, double>::value;
87  if(nTD == nTrailingDoubles-2) return std::is_same<Arg1, double>::value && std::is_same<Arg2, double>::value;
88  return false;
89 }

Friends And Related Function Documentation

◆ TrigGlobEffCorr::Calculator

friend class TrigGlobEffCorr::Calculator
friend

Definition at line 298 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ TrigGlobEffCorr::CheckConfig

friend class TrigGlobEffCorr::CheckConfig
friend

Definition at line 297 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ TrigGlobEffCorr::ImportData

friend class TrigGlobEffCorr::ImportData
friend

Definition at line 296 of file TrigGlobalEfficiencyCorrectionTool.h.

Member Data Documentation

◆ m_cachedLegRankings

std::multimap<std::size_t, CachedRanking> TrigGlobalEfficiencyCorrectionTool::m_cachedLegRankings
private

Definition at line 167 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_calculator

std::unique_ptr<TrigGlobEffCorr::Calculator> TrigGlobalEfficiencyCorrectionTool::m_calculator
private

Definition at line 190 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_checkElectronLegTag

bool TrigGlobalEfficiencyCorrectionTool::m_checkElectronLegTag
private

Definition at line 174 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_checkMuonLegTag

bool TrigGlobalEfficiencyCorrectionTool::m_checkMuonLegTag
private

Definition at line 175 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_checkPhotonLegTag

bool TrigGlobalEfficiencyCorrectionTool::m_checkPhotonLegTag
private

Definition at line 176 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_cpCode

CP::CorrectionCode TrigGlobalEfficiencyCorrectionTool::m_cpCode = CP::CorrectionCode::Ok
private

Definition at line 184 of file TrigGlobalEfficiencyCorrectionTool.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_dictionary

std::map<std::size_t, std::string> TrigGlobalEfficiencyCorrectionTool::m_dictionary
private

Definition at line 177 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_electronEffToolIndex

std::map<ToolKey, std::size_t> TrigGlobalEfficiencyCorrectionTool::m_electronEffToolIndex
private

Definition at line 169 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_electronLegsPerTag

std::map<std::string, std::string> TrigGlobalEfficiencyCorrectionTool::m_electronLegsPerTag
private

Definition at line 157 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_electronSfToolIndex

std::map<ToolKey, std::size_t> TrigGlobalEfficiencyCorrectionTool::m_electronSfToolIndex
private

Definition at line 168 of file TrigGlobalEfficiencyCorrectionTool.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_hasher

std::hash<std::string> TrigGlobalEfficiencyCorrectionTool::m_hasher
private

Definition at line 165 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_hierarchyData

std::vector<std::size_t> TrigGlobalEfficiencyCorrectionTool::m_hierarchyData
private

Definition at line 181 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_hierarchyMeta

std::vector<Hierarchy> TrigGlobalEfficiencyCorrectionTool::m_hierarchyMeta
private

Definition at line 180 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_initialized

bool TrigGlobalEfficiencyCorrectionTool::m_initialized = false
private

Definition at line 183 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_legsPerTag

std::map<std::string, std::string> TrigGlobalEfficiencyCorrectionTool::m_legsPerTag
private

deprecated

Definition at line 159 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_legsPerTool

std::map<std::string, std::string> TrigGlobalEfficiencyCorrectionTool::m_legsPerTool
private

Definition at line 152 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_leptonTagDecorations

std::string TrigGlobalEfficiencyCorrectionTool::m_leptonTagDecorations
private

Definition at line 155 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_leptonTagDecorators

std::vector<TagDecorator> TrigGlobalEfficiencyCorrectionTool::m_leptonTagDecorators
private

Definition at line 188 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_muonLegsPerTag

std::map<std::string, std::string> TrigGlobalEfficiencyCorrectionTool::m_muonLegsPerTag
private

deprecated

Definition at line 158 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_muonToolIndex

std::map<ToolKey, std::size_t> TrigGlobalEfficiencyCorrectionTool::m_muonToolIndex
private

Definition at line 172 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_numberOfToys

unsigned long TrigGlobalEfficiencyCorrectionTool::m_numberOfToys
private

Definition at line 161 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_overrideThresholds

std::map<std::string, std::string> TrigGlobalEfficiencyCorrectionTool::m_overrideThresholds
private

Definition at line 160 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_photonEffToolIndex

std::map<ToolKey, std::size_t> TrigGlobalEfficiencyCorrectionTool::m_photonEffToolIndex
private

Definition at line 171 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_photonSfToolIndex

std::map<ToolKey, std::size_t> TrigGlobalEfficiencyCorrectionTool::m_photonSfToolIndex
private

Definition at line 170 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_runNumberDecorator

SG::AuxElement::ConstAccessor<unsigned int> TrigGlobalEfficiencyCorrectionTool::m_runNumberDecorator
private

Definition at line 189 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_seed

unsigned long TrigGlobalEfficiencyCorrectionTool::m_seed
private

Definition at line 185 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_suppliedElectronEfficiencyTools

ToolHandleArray<IAsgElectronEfficiencyCorrectionTool> TrigGlobalEfficiencyCorrectionTool::m_suppliedElectronEfficiencyTools
private

Properties:

Definition at line 144 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_suppliedElectronScaleFactorTools

ToolHandleArray<IAsgElectronEfficiencyCorrectionTool> TrigGlobalEfficiencyCorrectionTool::m_suppliedElectronScaleFactorTools
private

Definition at line 146 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_suppliedMuonTools

ToolHandleArray<CP::IMuonTriggerScaleFactors> TrigGlobalEfficiencyCorrectionTool::m_suppliedMuonTools
private

Definition at line 151 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_suppliedPhotonEfficiencyTools

ToolHandleArray<IAsgPhotonEfficiencyCorrectionTool> TrigGlobalEfficiencyCorrectionTool::m_suppliedPhotonEfficiencyTools
private

Definition at line 148 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_suppliedPhotonScaleFactorTools

ToolHandleArray<IAsgPhotonEfficiencyCorrectionTool> TrigGlobalEfficiencyCorrectionTool::m_suppliedPhotonScaleFactorTools
private

Definition at line 150 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_tagsPerTool

std::map<std::string, std::string> TrigGlobalEfficiencyCorrectionTool::m_tagsPerTool
private

Definition at line 156 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_thresholds

std::map<std::size_t, float> TrigGlobalEfficiencyCorrectionTool::m_thresholds
private

Definition at line 166 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_triggerCb

std::map<std::string, std::string> TrigGlobalEfficiencyCorrectionTool::m_triggerCb
private

Definition at line 153 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_triggerCbPerYear

std::map<std::string, std::string> TrigGlobalEfficiencyCorrectionTool::m_triggerCbPerYear
private

Definition at line 154 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_trigMatchTool

ToolHandle<Trig::IMatchingTool> TrigGlobalEfficiencyCorrectionTool::m_trigMatchTool
private

Definition at line 163 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_unsupportedLegs

std::set<ToolKey> TrigGlobalEfficiencyCorrectionTool::m_unsupportedLegs
private

Definition at line 178 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_useInternalSeed

bool TrigGlobalEfficiencyCorrectionTool::m_useInternalSeed
private

Definition at line 162 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_validLegTagPairs

std::set<std::size_t> TrigGlobalEfficiencyCorrectionTool::m_validLegTagPairs
private

Definition at line 173 of file TrigGlobalEfficiencyCorrectionTool.h.

◆ m_validTrigMatchTool

bool TrigGlobalEfficiencyCorrectionTool::m_validTrigMatchTool
private

Definition at line 186 of file TrigGlobalEfficiencyCorrectionTool.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.


The documentation for this class was generated from the following files:
data
char data[hepevt_bytes_allocation_ATLAS]
Definition: HepEvt.cxx:11
xAOD::Electron
Electron_v1 Electron
Definition of the current "egamma version".
Definition: Event/xAOD/xAODEgamma/xAODEgamma/Electron.h:17
TrigGlobalEfficiencyCorrectionTool::listNonOrderedCSValues
flat_set< std::size_t > listNonOrderedCSValues(const std::string &s, bool &success)
StateLessPT_NewConfig.proxy
proxy
Definition: StateLessPT_NewConfig.py:407
TrigGlobalEfficiencyCorrectionTool::enumerateTools
bool enumerateTools(TrigGlobEffCorr::ImportData &data, ToolHandleArray< CPTool > &suppliedTools, std::map< ToolKey, std::size_t > &toolIndex, flat_set< std::size_t > &collectedTags)
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
TrigGlobalEfficiencyCorrectionTool::m_legsPerTool
std::map< std::string, std::string > m_legsPerTool
Definition: TrigGlobalEfficiencyCorrectionTool.h:152
python.CaloAddPedShiftConfig.args
args
Definition: CaloAddPedShiftConfig.py:47
TrigGlobalEfficiencyCorrectionTool::m_suppliedPhotonEfficiencyTools
ToolHandleArray< IAsgPhotonEfficiencyCorrectionTool > m_suppliedPhotonEfficiencyTools
Definition: TrigGlobalEfficiencyCorrectionTool.h:148
TrigGlobalEfficiencyCorrectionTool::m_photonEffToolIndex
std::map< ToolKey, std::size_t > m_photonEffToolIndex
Definition: TrigGlobalEfficiencyCorrectionTool.h:171
TrigGlobalEfficiencyCorrectionTool::m_muonLegsPerTag
std::map< std::string, std::string > m_muonLegsPerTag
deprecated
Definition: TrigGlobalEfficiencyCorrectionTool.h:158
index
Definition: index.py:1
TrigGlobalEfficiencyCorrectionTool::m_hierarchyData
std::vector< std::size_t > m_hierarchyData
Definition: TrigGlobalEfficiencyCorrectionTool.h:181
DMTest::P
P_v1 P
Definition: P.h:23
IAsgPhotonEfficiencyCorrectionTool
Definition: IAsgPhotonEfficiencyCorrectionTool.h:23
TrigGlobalEfficiencyCorrectionTool::suggestEgammaMapKeys
static CP::CorrectionCode suggestEgammaMapKeys(const std::map< std::string, std::string > &triggerCombination, const std::string &version, std::map< std::string, std::string > &legsPerKey, xAOD::Type::ObjectType type)
ITrigGlobalEfficiencyCorrectionTool::handleArg
double * handleArg(double &arg, std::vector< const xAOD::IParticle * > &)
Definition: ITrigGlobalEfficiencyCorrectionTool.h:58
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
TrigGlobalEfficiencyCorrectionTool::m_muonToolIndex
std::map< ToolKey, std::size_t > m_muonToolIndex
Definition: TrigGlobalEfficiencyCorrectionTool.h:172
TrigGlobalEfficiencyCorrectionTool::m_suppliedElectronScaleFactorTools
ToolHandleArray< IAsgElectronEfficiencyCorrectionTool > m_suppliedElectronScaleFactorTools
Definition: TrigGlobalEfficiencyCorrectionTool.h:146
athena.value
value
Definition: athena.py:124
TrigGlobalEfficiencyCorrectionTool::m_legsPerTag
std::map< std::string, std::string > m_legsPerTag
deprecated
Definition: TrigGlobalEfficiencyCorrectionTool.h:159
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
dbg::ptr
void * ptr(T *p)
Definition: SGImplSvc.cxx:74
Args
Definition: test_lwtnn_fastgraph.cxx:12
xAOD::IParticle
Class providing the definition of the 4-vector interface.
Definition: Event/xAOD/xAODBase/xAODBase/IParticle.h:41
x
#define x
flat_set
boost::container::flat_set< Key > flat_set
Definition: CheckConfig.cxx:14
TrigGlobalEfficiencyCorrectionTool::parseTagString
bool parseTagString(const std::string &tagstring, flat_set< std::size_t > &tags)
Definition: TrigGlobalEfficiencyCorrectionTool.cxx:225
python.iconfTool.models.loaders.level
level
Definition: loaders.py:20
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:29
ITrigGlobalEfficiencyCorrectionTool::validArgs
static constexpr bool validArgs(unsigned nTrailingDoubles)
Definition: ITrigGlobalEfficiencyCorrectionTool.h:67
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
Definition: AthCommonDataStore.h:85
TrigGlobalEfficiencyCorrectionTool::TLE_ERROR
@ TLE_ERROR
Definition: TrigGlobalEfficiencyCorrectionTool.h:240
TrigGlobalEfficiencyCorrectionTool::m_electronLegsPerTag
std::map< std::string, std::string > m_electronLegsPerTag
Definition: TrigGlobalEfficiencyCorrectionTool.h:157
tags
std::vector< std::string > tags
Definition: hcg.cxx:102
TrigGlobalEfficiencyCorrectionTool::loadTriggerCombination
bool loadTriggerCombination(TrigGlobEffCorr::ImportData &data, bool useDefaultElectronTools, bool useDefaultPhotonTools)
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:209
TrigGlobalEfficiencyCorrectionTool::m_unsupportedLegs
std::set< ToolKey > m_unsupportedLegs
Definition: TrigGlobalEfficiencyCorrectionTool.h:178
AthCommonDataStore
Definition: AthCommonDataStore.h:52
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
TrigGlobalEfficiencyCorrectionTool::m_overrideThresholds
std::map< std::string, std::string > m_overrideThresholds
Definition: TrigGlobalEfficiencyCorrectionTool.h:160
TrigGlobEffCorr::ImportData
Definition: ImportData.h:86
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
AthCommonDataStore::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
Definition: AthCommonDataStore.h:145
CalibDbCompareRT.dummy
dummy
Definition: CalibDbCompareRT.py:59
TrigGlobEffCorr::CheckConfig
Definition: CheckConfig.h:18
compute_lumi.leg
leg
Definition: compute_lumi.py:95
MSG::name
const std::string & name(Level lvl)
Convenience function for translating message levels to strings.
Definition: MsgLevel.cxx:19
TrigGlobalEfficiencyCorrectionTool::parseListOfLegs
flat_set< ToolKey > parseListOfLegs(TrigGlobEffCorr::ImportData &data, const std::string &inputList, bool &success)
Definition: TrigGlobalEfficiencyCorrectionTool.cxx:336
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
TrigGlobalEfficiencyCorrectionTool::m_validTrigMatchTool
bool m_validTrigMatchTool
Definition: TrigGlobalEfficiencyCorrectionTool.h:186
TrigGlobalEfficiencyCorrectionTool::TLE_OK
@ TLE_OK
Definition: TrigGlobalEfficiencyCorrectionTool.h:240
TrigGlobalEfficiencyCorrectionTool::m_suppliedPhotonScaleFactorTools
ToolHandleArray< IAsgPhotonEfficiencyCorrectionTool > m_suppliedPhotonScaleFactorTools
Definition: TrigGlobalEfficiencyCorrectionTool.h:150
TrigGlobalEfficiencyCorrectionTool::m_hierarchyMeta
std::vector< Hierarchy > m_hierarchyMeta
Definition: TrigGlobalEfficiencyCorrectionTool.h:180
TrigGlobalEfficiencyCorrectionTool::processDeprecatedProperties
bool processDeprecatedProperties()
Definition: TrigGlobalEfficiencyCorrectionTool.cxx:201
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
TrigGlobalEfficiencyCorrectionTool::TLE_UNAVAILABLE
@ TLE_UNAVAILABLE
Definition: TrigGlobalEfficiencyCorrectionTool.h:240
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
create_dcsc_inputs_sqlite.arg
list arg
Definition: create_dcsc_inputs_sqlite.py:48
TrigGlobalEfficiencyCorrectionTool::m_tagsPerTool
std::map< std::string, std::string > m_tagsPerTool
Definition: TrigGlobalEfficiencyCorrectionTool.h:156
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:240
TrigGlobalEfficiencyCorrectionTool::m_photonSfToolIndex
std::map< ToolKey, std::size_t > m_photonSfToolIndex
Definition: TrigGlobalEfficiencyCorrectionTool.h:170
python.ElectronD3PDObject.matched
matched
Definition: ElectronD3PDObject.py:138
xAOD::Photon
Photon_v1 Photon
Definition of the current "egamma version".
Definition: Event/xAOD/xAODEgamma/xAODEgamma/Photon.h:17
get_generator_info.version
version
Definition: get_generator_info.py:33
unused
void unused(Args &&...)
Definition: VP1ExpertSettings.cxx:39
TrigGlobalEfficiencyCorrectionTool::m_electronEffToolIndex
std::map< ToolKey, std::size_t > m_electronEffToolIndex
Definition: TrigGlobalEfficiencyCorrectionTool.h:169
ITrigGlobalEfficiencyCorrectionTool::getEfficiencyScaleFactor
virtual CP::CorrectionCode getEfficiencyScaleFactor(const std::vector< const xAOD::IParticle * > &particles, double &efficiencyScaleFactor)=0
DeMoScan.index
string index
Definition: DeMoScan.py:362
__attribute__
__attribute__((always_inline)) inline uint16_t TileCalibDrawerBase
Definition: TileCalibDrawerBase.h:190
a
TList * a
Definition: liststreamerinfos.cxx:10
TrigGlobalEfficiencyCorrectionTool::m_electronSfToolIndex
std::map< ToolKey, std::size_t > m_electronSfToolIndex
Definition: TrigGlobalEfficiencyCorrectionTool.h:168
ITrigGlobalEfficiencyCorrectionTool::checkTriggerMatching
virtual CP::CorrectionCode checkTriggerMatching(bool &matched, const std::vector< const xAOD::IParticle * > &particles)=0
h
TrigGlobalEfficiencyCorrectionTool::m_suppliedMuonTools
ToolHandleArray< CP::IMuonTriggerScaleFactors > m_suppliedMuonTools
Definition: TrigGlobalEfficiencyCorrectionTool.h:151
TrigGlobalEfficiencyCorrectionTool::loadTagDecorators
bool loadTagDecorators(const flat_set< std::size_t > &collectedElectronTags, const flat_set< std::size_t > &collectedMuonTags, const flat_set< std::size_t > &collectedPhotonTags)
mapkey::sf
@ sf
Definition: TElectronEfficiencyCorrectionTool.cxx:38
TrigGlobalEfficiencyCorrectionTool::m_trigMatchTool
ToolHandle< Trig::IMatchingTool > m_trigMatchTool
Definition: TrigGlobalEfficiencyCorrectionTool.h:163
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
ITrigGlobalEfficiencyCorrectionTool::getEfficiency
virtual CP::CorrectionCode getEfficiency(const std::vector< const xAOD::IParticle * > &particles, double &efficiencyData, double &efficiencyMc)=0
AthCommonMsg< AlgTool >::msg
MsgStream & msg() const
Definition: AthCommonMsg.h:24
LArG4FSStartPointFilter.particles
list particles
Definition: LArG4FSStartPointFilter.py:84
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:629
ITrigGlobalEfficiencyCorrectionTool::toolnameForDefaultScaleFactor
static std::string toolnameForDefaultScaleFactor()
To be used with the ListOfLegsPerTool property:
Definition: ITrigGlobalEfficiencyCorrectionTool.h:56
dqt_zlumi_alleff_HIST.eff
int eff
Definition: dqt_zlumi_alleff_HIST.py:113
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:801
TrigGlobalEfficiencyCorrectionTool::m_suppliedElectronEfficiencyTools
ToolHandleArray< IAsgElectronEfficiencyCorrectionTool > m_suppliedElectronEfficiencyTools
Properties:
Definition: TrigGlobalEfficiencyCorrectionTool.h:144
IAsgElectronEfficiencyCorrectionTool
Definition: IAsgElectronEfficiencyCorrectionTool.h:18
CaloCondBlobAlgs_fillNoiseFromASCII.tag
string tag
Definition: CaloCondBlobAlgs_fillNoiseFromASCII.py:23
TrigGlobalEfficiencyCorrectionTool::loadListOfLegsPerTag
bool loadListOfLegsPerTag()
SG::DataProxy
Definition: DataProxy.h:45
TrigGlobalEfficiencyCorrectionTool::m_initialized
bool m_initialized
Definition: TrigGlobalEfficiencyCorrectionTool.h:183
TrigGlobalEfficiencyCorrectionTool::m_dictionary
std::map< std::size_t, std::string > m_dictionary
Definition: TrigGlobalEfficiencyCorrectionTool.h:177
TrigGlobalEfficiencyCorrectionTool::m_hasher
std::hash< std::string > m_hasher
Definition: TrigGlobalEfficiencyCorrectionTool.h:165
fitman.k
k
Definition: fitman.py:528
mapkey::key
key
Definition: TElectronEfficiencyCorrectionTool.cxx:37
TrigGlobalEfficiencyCorrectionTool::m_thresholds
std::map< std::size_t, float > m_thresholds
Definition: TrigGlobalEfficiencyCorrectionTool.h:166