Loading [MathJax]/jax/input/TeX/config.js
ATLAS Offline Software
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
Public Member Functions | Protected Member Functions | Protected Attributes | Private Types | Private Member Functions | Private Attributes | Friends | List of all members
TauAnalysisTools::TauSelectionTool Class Referenceabstract

#include <TauSelectionTool.h>

Inheritance diagram for TauAnalysisTools::TauSelectionTool:
Collaboration diagram for TauAnalysisTools::TauSelectionTool:

Public Member Functions

 TauSelectionTool (const std::string &name)
 Constructor for standalone usage. More...
 
virtual ~TauSelectionTool ()
 
virtual StatusCode initialize () override
 Function initialising the tool. More...
 
virtual const asg::AcceptInfogetAcceptInfo () const override
 Get an object describing the "selection steps" of the tool. More...
 
virtual asg::AcceptData accept (const xAOD::IParticle *p) const override
 Get the decision using a generic IParticle pointer. More...
 
virtual asg::AcceptData accept (const xAOD::TauJet &tau) const override
 Get the decision for a specific TauJet object. More...
 
virtual void setOutFile (TFile *fOutFile) override
 Set output file for control histograms. More...
 
virtual void writeControlHistograms () override
 Write control histograms to output file. More...
 
virtual void print () const =0
 Print the state of the tool. More...
 
virtual StatusCode sysInitialize ()
 Function initialising the tool in the correct way in Athena. More...
 
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 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 > &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
 

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

Protected Attributes

TFile * m_fOutFile
 
std::shared_ptr< TH1F > m_hCutFlow
 
bool m_bCreateControlPlots
 
asg::AcceptInfo m_aAccept
 Object used to store selection information. More...
 

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

 ASG_TOOL_CLASS2 (TauSelectionTool, IAsgSelectionTool, TauAnalysisTools::ITauSelectionTool) friend class TauEfficiencyCorrectionsTool
 Create a proper constructor for Athena. More...
 
virtual StatusCode beginEvent () override
 Function called when a new events is loaded. More...
 
template<typename T , typename U >
void FillRegionVector (std::vector< T > &vRegion, U tMin, U tMax) const
 
template<typename T , typename U >
void FillValueVector (std::vector< T > &vRegion, U tVal) const
 
template<typename T >
void PrintConfigRegion (const std::string &sCutName, std::vector< T > &vRegion) const
 
template<typename T >
void PrintConfigValue (const std::string &sCutName, std::vector< T > &vRegion) const
 
template<typename T >
void PrintConfigValue (const std::string &sCutName, T &sVal) const
 
void setupCutFlowHistogram ()
 
int convertStrToJetIDWP (const std::string &sJetIDWP) const
 
int convertStrToEleIDWP (const std::string &sEleIDWP) const
 
std::string convertJetIDWPToStr (int iJetIDWP) const
 
std::string convertEleIDWPToStr (int iEleIDWP) const
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Private Attributes

int m_iSelectionCuts
 
std::vector< float > m_vPtRegion
 
std::vector< float > m_vAbsEtaRegion
 
std::vector< int > m_vAbsCharges
 
std::vector< unsigned > m_vNTracks
 
std::vector< float > m_vJetRNNSigTransRegion
 
std::vector< float > m_vGNTauSigTransRegion
 
std::string m_sJetIDWP
 
int m_iJetIDWP
 
std::vector< float > m_vEleRNNRegion
 
std::string m_sEleIDWP
 
int m_iEleIDWP
 
int m_iEleIDVersion
 
bool m_bMuonOLR
 
float m_dPtMin
 
float m_dPtMax
 
float m_dAbsEtaMin
 
float m_dAbsEtaMax
 
float m_iAbsCharge
 
float m_iNTrack
 
float m_dJetRNNSigTransMin
 
float m_dJetRNNSigTransMax
 
float m_dGNTauSigTransMin
 
float m_dGNTauSigTransMax
 
float m_dEleRNNMin
 
float m_dEleRNNMax
 
std::string m_sConfigPath
 
SG::ReadHandleKey< xAOD::MuonContainerm_muonContainerKey {this, "MuonContainerName", "Muons", "Muon container name"}
 
SG::ReadHandleKey< xAOD::TauJetContainerm_tauContainerKey {this, "TauContainerName", "TauJets", "Tau container name"}
 
SG::ReadDecorHandleKey< xAOD::TauJetContainerm_eVetoDecorKey {this, "eVetoDecorName", "", "Name of eVeto decoration"}
 
SG::ReadDecorHandleKey< xAOD::TauJetContainerm_GNTauDecorKey {this, "GNTauDecorName", "", "Name of GnTauID decoration"}
 
std::map< SelectionCuts, std::unique_ptr< TauAnalysisTools::TauSelectionCut > > m_cMap
 
MetaStore_t m_inputMetaStore
 Object accessing the input metadata store. More...
 
MetaStore_t m_outputMetaStore
 Object accessing the output metadata store. More...
 
bool m_beginInputFileCalled
 Flag helping to discover when the tool misses the opening of the first input file. More...
 
bool m_useIncidents
 
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 TauSelectionCut
 need to define cut classes to be friends to access protected variables, needed for access of cut thresholds More...
 
class TauSelectionCutPt
 
class TauSelectionCutAbsEta
 
class TauSelectionCutAbsCharge
 
class TauSelectionCutNTracks
 
class TauSelectionCutJetIDWP
 
class TauSelectionCutRNNJetScoreSigTrans
 
class TauSelectionCutGNTauScoreSigTrans
 
class TauSelectionCutRNNEleScore
 
class TauSelectionCutEleIDWP
 
class TauSelectionCutMuonOLR
 

Callback functions helping in metadata reading/writing

void setUseIncidents (const bool flag)
 
virtual void handle (const Incident &inc)
 Function receiving incidents from IncidentSvc/TEvent. More...
 
virtual StatusCode beginInputFile ()
 Function called when a new input file is opened. More...
 
virtual StatusCode endInputFile ()
 Function called when the currently open input file got completely processed. More...
 
virtual StatusCode metaDataStop ()
 Function called when the tool should write out its metadata. More...
 

Detailed Description

Definition at line 50 of file TauSelectionTool.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.

Constructor & Destructor Documentation

◆ TauSelectionTool()

TauSelectionTool::TauSelectionTool ( const std::string &  name)

Constructor for standalone usage.

Definition at line 24 of file TauSelectionTool.cxx.

26  , m_sJetIDWP("JETIDNONE")
27  , m_sEleIDWP("ELEIDNONE")
28  , m_fOutFile(nullptr)
29  , m_aAccept( "TauSelection" )
30 {
31  declareProperty( "CreateControlPlots", m_bCreateControlPlots = false);
32  /*
33  Baseline properties declaration:
34  properties containing 'Region' are a vector of lower and upper bounds
35  other properties named in plural are a list of exact values to cut on
36  other properties are single cuts
37  */
38  declareProperty( "ConfigPath", m_sConfigPath = "TauAnalysisTools/"+std::string(sSharedFilesVersion)+"/Selection/recommended_selection_r22.conf");
39  declareProperty( "SelectionCuts", m_iSelectionCuts = NoCut); // initialize with 'no' cuts
40  declareProperty( "PtRegion", m_vPtRegion = {}); // in GeV
41  declareProperty( "PtMin", m_dPtMin = NAN); // in GeV
42  declareProperty( "PtMax", m_dPtMax = NAN); // in GeV
43  declareProperty( "AbsEtaRegion", m_vAbsEtaRegion = {});
44  declareProperty( "AbsEtaMin", m_dAbsEtaMin = NAN);
45  declareProperty( "AbsEtaMax", m_dAbsEtaMax = NAN);
46  declareProperty( "AbsCharges", m_vAbsCharges = {});
47  declareProperty( "AbsCharge", m_iAbsCharge = NAN);
48  declareProperty( "NTracks", m_vNTracks = {});
49  declareProperty( "NTrack", m_iNTrack = NAN);
50  declareProperty( "JetRNNSigTransRegion", m_vJetRNNSigTransRegion = {});
51  declareProperty( "JetRNNSigTransMin", m_dJetRNNSigTransMin = NAN);
52  declareProperty( "JetRNNSigTransMax", m_dJetRNNSigTransMax = NAN);
53  declareProperty( "GNTauSigTransRegion", m_vGNTauSigTransRegion = {});
54  declareProperty( "GNTauSigTransMin", m_dGNTauSigTransMin = NAN);
55  declareProperty( "GNTauSigTransMax", m_dGNTauSigTransMax = NAN);
56  declareProperty( "JetIDWP", m_iJetIDWP = 0);
57  declareProperty( "EleRNNRegion", m_vEleRNNRegion = {});
58  declareProperty( "EleRNNMin", m_dEleRNNMin = NAN);
59  declareProperty( "EleRNNMax", m_dEleRNNMax = NAN);
60  declareProperty( "EleIDWP", m_iEleIDWP = 0);
61  declareProperty( "EleIDVersion", m_iEleIDVersion = 1);
62  declareProperty( "MuonOLR", m_bMuonOLR = false);
63 }

◆ ~TauSelectionTool()

TauSelectionTool::~TauSelectionTool ( )
virtual

Definition at line 66 of file TauSelectionTool.cxx.

67 {
68  m_cMap.clear();
69 }

Member Function Documentation

◆ accept() [1/2]

asg::AcceptData TauSelectionTool::accept ( const xAOD::IParticle p) const
overridevirtual

Get the decision using a generic IParticle pointer.

Implements IAsgSelectionTool.

Definition at line 393 of file TauSelectionTool.cxx.

394 {
395  // Check if this is a tau:
396  if( xP->type() != xAOD::Type::Tau )
397  {
398  ATH_MSG_ERROR( "accept(...) Function received a non-tau" );
399  return asg::AcceptData (&m_aAccept);
400  }
401 
402  // Cast it to a tau:
403  const xAOD::TauJet* xTau = dynamic_cast< const xAOD::TauJet* >( xP );
404  if( ! xTau )
405  {
406  ATH_MSG_FATAL( "accept(...) Failed to cast particle to tau" );
407  return asg::AcceptData (&m_aAccept);
408  }
409 
410  // Let the specific function do the work:
411  return accept( *xTau );
412 }

◆ accept() [2/2]

asg::AcceptData TauSelectionTool::accept ( const xAOD::TauJet tau) const
overridevirtual

Get the decision for a specific TauJet object.

Implements TauAnalysisTools::ITauSelectionTool.

Definition at line 415 of file TauSelectionTool.cxx.

416 {
417  asg::AcceptData acceptData (&m_aAccept);
418 
419  int iNBin = 0;
420 
422  {
423  // fill cutflow 'All' bin
424  m_hCutFlow->Fill(iNBin);
425  // fill main distributions before all cuts
426  for (const auto& entry : m_cMap)
427  entry.second->fillHistogramCutPre(xTau);
428  }
429  try
430  {
431  for (const auto& entry : m_cMap)
432  {
433  if (m_iSelectionCuts & entry.first)
434  {
435  if (!entry.second->accept(xTau, acceptData))
436  return acceptData;
437  else
438  {
440  {
441  // fill cutflow after each passed cut
442  iNBin++;
443  m_hCutFlow->Fill(iNBin);
444  }
445  }
446  }
447  }
448  }
449  catch (const std::runtime_error& error)
450  {
451  // LEGACY: In practical terms this should probably just throw, not
452  // print a warning/error and then continue on. However, I leave
453  // that to the experts who probably had a reason not to let the
454  // exception escape. For now I just downgraded it from error to
455  // warning and limited the number of warnings (04 Jan 22).
456  static std::atomic<uint64_t> warning_count (0u);
457  auto mycount = ++ warning_count;
458  if (mycount < 10u)
459  {
460  ATH_MSG_WARNING(error.what());
461  if (mycount == 9u)
462  ATH_MSG_WARNING ("this is your last warning");
463  }
464  }
465 
466  // fill main distributions after all cuts
468  {
469  for (const auto& entry : m_cMap)
470  entry.second->fillHistogramCut(xTau);
471  }
472 
473  // // Return the result:
474  return acceptData;
475 }

◆ ASG_TOOL_CLASS2()

TauAnalysisTools::TauSelectionTool::ASG_TOOL_CLASS2 ( TauSelectionTool  ,
IAsgSelectionTool  ,
TauAnalysisTools::ITauSelectionTool   
)
private

Create a proper constructor for Athena.

◆ beginEvent()

StatusCode TauSelectionTool::beginEvent ( )
overrideprivatevirtual

Function called when a new events is loaded.

Dummy implementation that can be overridden by the derived tool.

Reimplemented from asg::AsgMetadataTool.

Definition at line 381 of file TauSelectionTool.cxx.

382 {
383  return StatusCode::SUCCESS;
384 }

◆ 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, TrigConf::xAODConfigTool, PMGTools::PMGTruthWeightTool, BookkeeperTool, xAODMaker::FileMetaDataTool, BookkeeperDumperTool, Trig::TrigDecisionTool, xAODMaker::TriggerMenuMetaDataTool, xAODMaker::TruthMetaDataTool, Trig::xAODBunchCrossingTool, TauAnalysisTools::TauEfficiencyCorrectionsTool, and TauAnalysisTools::TauSmearingTool.

Definition at line 180 of file AsgMetadataTool.cxx.

180  {
181 
182  // Return gracefully:
183  return StatusCode::SUCCESS;
184  }

◆ convertEleIDWPToStr()

std::string TauSelectionTool::convertEleIDWPToStr ( int  iEleIDWP) const
private

Definition at line 640 of file TauSelectionTool.cxx.

641 {
642  switch (iEleIDWP)
643  {
645  return "ELEIDNONE";
646  case ELEIDNONE:
647  return "ELEIDNONE";
648  case ELEIDRNNLOOSE:
649  return "ELEIDRNNLOOSE";
650  case ELEIDRNNMEDIUM:
651  return "ELEIDRNNMEDIUM";
652  case ELEIDRNNTIGHT:
653  return "ELEIDRNNTIGHT";
654  default:
655  ATH_MSG_WARNING( "EleID working point with enum " << iEleIDWP << " is unknown, the EleIDWP cut will not accept any tau!" );
656  return "";
657  }
658 }

◆ convertJetIDWPToStr()

std::string TauSelectionTool::convertJetIDWPToStr ( int  iJetIDWP) const
private

Definition at line 608 of file TauSelectionTool.cxx.

609 {
610  switch (iJetIDWP)
611  {
613  return "JETIDNONE";
614  case JETIDNONE:
615  return "JETIDNONE";
616  case JETIDRNNVERYLOOSE:
617  return "JETIDRNNVERYLOOSE";
618  case JETIDRNNLOOSE:
619  return "JETIDRNNLOOSE";
620  case JETIDRNNMEDIUM:
621  return "JETIDRNNMEDIUM";
622  case JETIDRNNTIGHT:
623  return "JETIDRNNTIGHT";
624  case JETIDGNTAUVERYLOOSE:
625  return "JETIDGNTAUVERYLOOSE";
626  case JETIDGNTAULOOSE:
627  return "JETIDGNTAULOOSE";
628  case JETIDGNTAUMEDIUM:
629  return "JETIDGNTAUMEDIUM";
630  case JETIDGNTAUTIGHT:
631  return "JETIDGNTAUTIGHT";
632 
633  default:
634  ATH_MSG_WARNING( "JetID working point with enum " << iJetIDWP << " is unknown, the JetIDWP cut will not accept any tau!" );
635  return "";
636  }
637 }

◆ convertStrToEleIDWP()

int TauSelectionTool::convertStrToEleIDWP ( const std::string &  sEleIDWP) const
private

Definition at line 596 of file TauSelectionTool.cxx.

597 {
598  if (sEleIDWP == "ELEIDNONE") return int(ELEIDNONE);
599  else if (sEleIDWP == "ELEIDRNNLOOSE") return int(ELEIDRNNLOOSE);
600  else if (sEleIDWP == "ELEIDRNNMEDIUM") return int(ELEIDRNNMEDIUM);
601  else if (sEleIDWP == "ELEIDRNNTIGHT") return int(ELEIDRNNTIGHT);
602 
603  ATH_MSG_ERROR( "electron ID working point " << sEleIDWP << " is unknown, the EleIDWP cut will not accept any tau!" );
604  return -1;
605 }

◆ convertStrToJetIDWP()

int TauSelectionTool::convertStrToJetIDWP ( const std::string &  sJetIDWP) const
private

Definition at line 579 of file TauSelectionTool.cxx.

580 {
581  if (sJetIDWP == "JETIDNONE") return int(JETIDNONE);
582  else if (sJetIDWP == "JETIDRNNVERYLOOSE") return int(JETIDRNNVERYLOOSE);
583  else if (sJetIDWP == "JETIDRNNLOOSE") return int(JETIDRNNLOOSE);
584  else if (sJetIDWP == "JETIDRNNMEDIUM") return int(JETIDRNNMEDIUM);
585  else if (sJetIDWP == "JETIDRNNTIGHT") return int(JETIDRNNTIGHT);
586  else if (sJetIDWP == "JETIDGNTAUVERYLOOSE") return int(JETIDGNTAUVERYLOOSE);
587  else if (sJetIDWP == "JETIDGNTAULOOSE") return int(JETIDGNTAULOOSE);
588  else if (sJetIDWP == "JETIDGNTAUMEDIUM") return int(JETIDGNTAUMEDIUM);
589  else if (sJetIDWP == "JETIDGNTAUTIGHT") return int(JETIDGNTAUTIGHT);
590 
591  ATH_MSG_ERROR( "jet ID working point "<<sJetIDWP<<" is unknown, the JetIDWP cut will not accept any tau!" );
592  return -1;
593 }

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  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 > &  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 > &  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 > &  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 > &  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; }

◆ 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 BookkeeperTool, xAODMaker::FileMetaDataTool, BookkeeperDumperTool, xAODMaker::TriggerMenuMetaDataTool, and xAODMaker::TruthMetaDataTool.

Definition at line 188 of file AsgMetadataTool.cxx.

188  {
189 
190  // Return gracefully:
191  return StatusCode::SUCCESS;
192  }

◆ 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

◆ FillRegionVector()

template<typename T , typename U >
void TauSelectionTool::FillRegionVector ( std::vector< T > &  vRegion,
tMin,
tMax 
) const
private

Definition at line 527 of file TauSelectionTool.cxx.

528 {
529  if (!vRegion.empty())
530  return;
531  if (tMin == tMin) // if tMin is NAN, then this assumption fails and -inf is added to the vector
532  vRegion.push_back(tMin);
533  else
534  vRegion.push_back(-std::numeric_limits<T>::infinity());
535 
536  if (tMax == tMax) // if tMax is NAN, then this assumption fails and inf is added to the vector
537  vRegion.push_back(tMax);
538  else
539  vRegion.push_back(std::numeric_limits<T>::infinity());
540 }

◆ FillValueVector()

template<typename T , typename U >
void TauSelectionTool::FillValueVector ( std::vector< T > &  vRegion,
tVal 
) const
private

Definition at line 544 of file TauSelectionTool.cxx.

545 {
546  if (!vRegion.empty())
547  return;
548  if (tVal == tVal) // if tMax is NAN, then this assumption fails and nothing is added to the vector
549  vRegion.push_back(tVal);
550 }

◆ getAcceptInfo()

const asg::AcceptInfo & TauSelectionTool::getAcceptInfo ( ) const
overridevirtual

Get an object describing the "selection steps" of the tool.

Implements IAsgSelectionTool.

Definition at line 387 of file TauSelectionTool.cxx.

388 {
389  return m_aAccept;
390 }

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

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

◆ handle()

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

Function receiving incidents from IncidentSvc/TEvent.

Reimplemented in Trig::TrigDecisionTool.

Definition at line 130 of file AsgMetadataTool.cxx.

130  {
131 
132  // Tell the user what's happening:
133  ATH_MSG_VERBOSE( "Callback received with incident: " << inc.type() );
134 
135  // Call the appropriate member function:
136  if( inc.type() == IncidentType::BeginInputFile ) {
137  m_beginInputFileCalled = true;
138  if( beginInputFile().isFailure() ) {
139  ATH_MSG_FATAL( "Failed to call beginInputFile()" );
140  throw std::runtime_error( "Couldn't call beginInputFile()" );
141  }
142  } else if( inc.type() == IncidentType::EndInputFile ) {
143  if( endInputFile().isFailure() ) {
144  ATH_MSG_FATAL( "Failed to call endInputFile()" );
145  throw std::runtime_error( "Couldn't call endInputFile()" );
146  }
147  } else if( inc.type() == IncidentType::BeginEvent ) {
148  // If the tool didn't catch the begin input file incident for the
149  // first input file of the job, then call the appropriate function
150  // now.
151  if( ! m_beginInputFileCalled ) {
152  m_beginInputFileCalled = true;
153  if( beginInputFile().isFailure() ) {
154  ATH_MSG_FATAL( "Failed to call beginInputFile()" );
155  throw std::runtime_error( "Couldn't call beginInputFile()" );
156  }
157  }
158  if( beginEvent().isFailure() ) {
159  ATH_MSG_FATAL( "Failed to call beginEvent()" );
160  throw std::runtime_error( "Couldn't call beginEvent()" );
161  }
162 
163  #ifdef XAOD_STANDALONE
164  } else if( inc.type() == IncidentType::MetaDataStop ) {
165  if( metaDataStop().isFailure() ) {
166  ATH_MSG_FATAL( "Failed to call metaDataStop()" );
167  throw std::runtime_error( "Couldn't call metaDataStop()" );
168  }
169 
170  #endif // XAOD_STANDALONE
171  } else {
172  ATH_MSG_WARNING( "Unknown incident type received in AsgMetaDataTool: " << inc.type() );
173  }
174 
175  return;
176  }

◆ initialize()

StatusCode TauSelectionTool::initialize ( )
overridevirtual

Function initialising the tool.

Implements TauAnalysisTools::ITauSelectionTool.

Definition at line 72 of file TauSelectionTool.cxx.

73 {
74  bool bConfigViaConfigFile = !m_sConfigPath.empty();
75  bool bConfigViaProperties = false;
76  if (!bConfigViaProperties and !m_vPtRegion.empty()) bConfigViaProperties = true;
77  if (!bConfigViaProperties and m_dPtMin == m_dPtMin) bConfigViaProperties = true;
78  if (!bConfigViaProperties and m_dPtMax == m_dPtMax) bConfigViaProperties = true;
79  if (!bConfigViaProperties and !m_vAbsEtaRegion.empty()) bConfigViaProperties = true;
80  if (!bConfigViaProperties and m_dAbsEtaMin == m_dAbsEtaMin) bConfigViaProperties = true;
81  if (!bConfigViaProperties and m_dAbsEtaMax == m_dAbsEtaMax) bConfigViaProperties = true;
82  if (!bConfigViaProperties and !m_vAbsCharges.empty()) bConfigViaProperties = true;
83  if (!bConfigViaProperties and m_iAbsCharge == m_iAbsCharge) bConfigViaProperties = true;
84  if (!bConfigViaProperties and !m_vNTracks.empty()) bConfigViaProperties = true;
85  if (!bConfigViaProperties and m_iNTrack == m_iNTrack) bConfigViaProperties = true;
86  if (!bConfigViaProperties and !m_vJetRNNSigTransRegion.empty()) bConfigViaProperties = true;
87  if (!bConfigViaProperties and m_dJetRNNSigTransMin == m_dJetRNNSigTransMin) bConfigViaProperties = true;
88  if (!bConfigViaProperties and m_dJetRNNSigTransMax == m_dJetRNNSigTransMax) bConfigViaProperties = true;
89  if (!bConfigViaProperties and !m_vGNTauSigTransRegion.empty()) bConfigViaProperties = true;
90  if (!bConfigViaProperties and m_dGNTauSigTransMin == m_dGNTauSigTransMin) bConfigViaProperties = true;
91  if (!bConfigViaProperties and m_dGNTauSigTransMax == m_dGNTauSigTransMax) bConfigViaProperties = true;
92  if (!bConfigViaProperties and m_iJetIDWP != 0) bConfigViaProperties = true;
93  if (!bConfigViaProperties and !m_vEleRNNRegion.empty()) bConfigViaProperties = true;
94  if (!bConfigViaProperties and m_dEleRNNMin == m_dEleRNNMin) bConfigViaProperties = true;
95  if (!bConfigViaProperties and m_dEleRNNMax == m_dEleRNNMax) bConfigViaProperties = true;
96  if (!bConfigViaProperties and m_iEleIDWP != 0) bConfigViaProperties = true;
97  if (!bConfigViaProperties and m_bMuonOLR) bConfigViaProperties = true;
98 
99  if (bConfigViaConfigFile and bConfigViaProperties)
100  {
101  ATH_MSG_WARNING("Configured tool via setProperty and configuration file, which may lead to unexpected configuration.");
102  ATH_MSG_WARNING("In doubt check the configuration that is printed when the tool is initialized and the message level is set to debug");
103  ATH_MSG_WARNING("For further details please refer to the documentation:");
104  ATH_MSG_WARNING("https://gitlab.cern.ch/atlas/athena/blob/main/PhysicsAnalysis/TauID/TauAnalysisTools/doc/README-TauSelectionTool.rst");
105  }
106  if (!bConfigViaConfigFile and !bConfigViaProperties)
107  {
108  ATH_MSG_WARNING("No cut configuration provided, the tool will not do anything. For further details please refer to the documentation:");
109  ATH_MSG_WARNING("https://gitlab.cern.ch/atlas/athena/blob/main/PhysicsAnalysis/TauID/TauAnalysisTools/doc/README-TauSelectionTool.rst");
110  return StatusCode::SUCCESS;
111  }
112 
113  if (bConfigViaConfigFile)
114  {
115  TEnv rEnv;
116  std::string sInputFilePath = PathResolverFindCalibFile(m_sConfigPath);
117 
118  if (!testFileForEOFContainsCharacters(sInputFilePath))
119  ATH_MSG_WARNING("Config file for TauSelectionTool with path "<<sInputFilePath<<" does not contain an empty last line. The tool might not be properly configured!");
120 
121  rEnv.ReadFile(sInputFilePath.c_str(),
122  kEnvAll);
123 
124  std::vector<std::string> vCuts;
125  // if Cuts are specified in the config file take these ones, if not take all
126  // specified in the config
127  if (rEnv.Defined("SelectionCuts"))
128  TauAnalysisTools::split(rEnv, "SelectionCuts", ' ', vCuts);
129  else
130  {
131  auto lList = rEnv.GetTable();
132  for( Int_t i = 0; i < lList->GetEntries(); ++i )
133  {
134  vCuts.push_back( lList->At( i )->GetName() );
135  }
136  }
137 
138  int iSelectionCuts = 0;
139 
140  for (const std::string& sCut : vCuts)
141  {
142  if (sCut == "PtRegion")
143  {
144  iSelectionCuts = iSelectionCuts | CutPt;
145  if (m_vPtRegion.empty())
146  TauAnalysisTools::split(rEnv,"PtRegion", ';', m_vPtRegion);
147  }
148  else if (sCut == "PtMin")
149  {
150  iSelectionCuts = iSelectionCuts | CutPt;
151  if (m_dPtMin != m_dPtMin)
152  m_dPtMin = rEnv.GetValue("PtMin",NAN);
153  }
154  else if (sCut == "PtMax")
155  {
156  iSelectionCuts = iSelectionCuts | CutPt;
157  if (m_dPtMax != m_dPtMax)
158  m_dPtMax = rEnv.GetValue("PtMax",NAN);
159  }
160  else if (sCut == "AbsEtaRegion")
161  {
162  iSelectionCuts = iSelectionCuts | CutAbsEta;
163  if (m_vAbsEtaRegion.empty())
164  TauAnalysisTools::split(rEnv,"AbsEtaRegion", ';', m_vAbsEtaRegion);
165  }
166  else if (sCut == "AbsEtaMin")
167  {
168  iSelectionCuts = iSelectionCuts | CutAbsEta;
169  if (m_dAbsEtaMin != m_dAbsEtaMin)
170  m_dAbsEtaMin = rEnv.GetValue("AbsEtaMin",NAN);
171  }
172  else if (sCut == "AbsEtaMax")
173  {
174  iSelectionCuts = iSelectionCuts | CutAbsEta;
175  if (m_dAbsEtaMax != m_dAbsEtaMax)
176  m_dAbsEtaMax = rEnv.GetValue("AbsEtaMax",NAN);
177  }
178  else if (sCut == "AbsCharges")
179  {
180  iSelectionCuts = iSelectionCuts | CutAbsCharge;
181  if (m_vAbsCharges.empty())
182  TauAnalysisTools::split(rEnv,"AbsCharges", ';', m_vAbsCharges);
183  }
184  else if (sCut == "AbsCharge")
185  {
186  iSelectionCuts = iSelectionCuts | CutAbsCharge;
187  if (m_iAbsCharge != m_iAbsCharge)
188  m_iAbsCharge = rEnv.GetValue("AbsCharge",NAN);
189  }
190  else if (sCut == "NTracks")
191  {
192  iSelectionCuts = iSelectionCuts | CutNTrack;
193  if (m_vNTracks.empty())
194  TauAnalysisTools::split(rEnv,"NTracks", ';', m_vNTracks);
195  }
196  else if (sCut == "NTrack")
197  {
198  iSelectionCuts = iSelectionCuts | CutNTrack;
199  if (m_iNTrack != m_iNTrack)
200  m_iNTrack = rEnv.GetValue("NTrack",NAN);
201  }
202  else if (sCut == "JetRNNSigTransRegion")
203  {
204  iSelectionCuts = iSelectionCuts | CutJetRNNScoreSigTrans;
205  if (m_vJetRNNSigTransRegion.empty())
206  TauAnalysisTools::split(rEnv,"JetRNNSigTransRegion", ';', m_vJetRNNSigTransRegion);
207  }
208  else if (sCut == "JetRNNSigTransMin")
209  {
210  iSelectionCuts = iSelectionCuts | CutJetRNNScoreSigTrans;
212  m_dJetRNNSigTransMin = rEnv.GetValue("JetRNNSigTransMin",NAN);
213  }
214  else if (sCut == "JetRNNSigTransMax")
215  {
216  iSelectionCuts = iSelectionCuts | CutJetRNNScoreSigTrans;
218  m_dJetRNNSigTransMax = rEnv.GetValue("JetRNNSigTransMax",NAN);
219  }
220  else if (sCut == "GNTauSigTransRegion")
221  {
222  iSelectionCuts = iSelectionCuts | CutGNTauScoreSigTrans;
223  if (m_vGNTauSigTransRegion.empty())
224  TauAnalysisTools::split(rEnv,"GNTauSigTransRegion", ';', m_vGNTauSigTransRegion);
225  }
226  else if (sCut == "GNTauSigTransMin")
227  {
228  iSelectionCuts = iSelectionCuts | CutGNTauScoreSigTrans;
230  m_dGNTauSigTransMin = rEnv.GetValue("GNTauSigTransMin",NAN);
231  }
232  else if (sCut == "GNTauSigTransMax")
233  {
234  iSelectionCuts = iSelectionCuts | CutGNTauScoreSigTrans;
236  m_dGNTauSigTransMax = rEnv.GetValue("GNTauSigTransMax",NAN);
237  }
238  else if (sCut == "EleRNNRegion")
239  {
240  iSelectionCuts = iSelectionCuts | CutEleRNNScore;
241  if (m_vEleRNNRegion.empty())
242  TauAnalysisTools::split(rEnv,"EleRNNRegion", ';', m_vEleRNNRegion);
243  }
244  else if (sCut == "EleRNNMin")
245  {
246  iSelectionCuts = iSelectionCuts | CutEleRNNScore;
247  if (m_dEleRNNMin != m_dEleRNNMin)
248  m_dEleRNNMin = rEnv.GetValue("EleRNNMin",NAN);
249  }
250  else if (sCut == "EleRNNMax")
251  {
252  iSelectionCuts = iSelectionCuts | CutEleRNNScore;
253  if (m_dEleRNNMax != m_dEleRNNMax)
254  m_dEleRNNMax = rEnv.GetValue("EleRNNMax",NAN);
255  }
256  else if (sCut == "JetIDWP")
257  {
258  iSelectionCuts = iSelectionCuts | CutJetIDWP;
260  m_iJetIDWP = convertStrToJetIDWP(rEnv.GetValue("JetIDWP","JETIDNONE"));
261  }
262 
263  // check for possible mis-config in Tau selection
264  for (const std::string& checkCut : vCuts){
265  if (checkCut.find("SigTrans") != std::string::npos) {
266  ATH_MSG_ERROR("Misconfig due to JetIDWP and SigTrans cuts both present in the config file. Please CHECK carefully config file again");
267  return StatusCode::FAILURE;
268  }
269  }
270  }
271  else if (sCut == "EleIDWP")
272  {
273  iSelectionCuts = iSelectionCuts | CutEleIDWP;
275  m_iEleIDWP = convertStrToEleIDWP(rEnv.GetValue("EleIDWP","ELEIDNONE"));
276  }
277  else if (sCut == "MuonOLR")
278  {
279  iSelectionCuts = iSelectionCuts | CutMuonOLR;
280  if (!m_bMuonOLR)
281  m_bMuonOLR = rEnv.GetValue("MuonOLR",false);
282  }
283  else ATH_MSG_WARNING("Cut " << sCut << " is not available");
284  }
285 
286  if (m_iSelectionCuts == NoCut)
287  m_iSelectionCuts = iSelectionCuts;
288  }
289 
292 
293  // initialise the ReadHandleKey of the muon container when the muon veto is applied
295 
296  ATH_CHECK( m_tauContainerKey.initialize() );
297 
298  // initialise the ReadDecorHandleKey if GNTau is applied
300  ATH_CHECK( m_GNTauDecorKey.assign(m_tauContainerKey.key()+".GNTauScoreSigTrans_v0prune"));
301  }
303 
304  // initialise the ReadDecorHandleKey if eVeto is applied
306  ATH_CHECK( m_eVetoDecorKey.assign(m_tauContainerKey.key()+".RNNEleScoreSigTrans_v"+std::to_string(m_iEleIDVersion)) );
307  }
309 
310  // specify all available cut descriptions
311  using map_type = std::map<SelectionCuts, std::unique_ptr<TauAnalysisTools::TauSelectionCut>>;
312  using pair_type = map_type::value_type;
313 
314  pair_type elements[] =
315  {
316  {CutPt, std::make_unique<TauAnalysisTools::TauSelectionCutPt>(this)},
317  {CutAbsEta, std::make_unique<TauAnalysisTools::TauSelectionCutAbsEta>(this)},
318  {CutAbsCharge, std::make_unique<TauAnalysisTools::TauSelectionCutAbsCharge>(this)},
319  {CutNTrack, std::make_unique<TauAnalysisTools::TauSelectionCutNTracks>(this)},
320  {CutJetRNNScoreSigTrans, std::make_unique<TauAnalysisTools::TauSelectionCutRNNJetScoreSigTrans>(this)},
321  {CutGNTauScoreSigTrans, std::make_unique<TauAnalysisTools::TauSelectionCutGNTauScoreSigTrans>(this)},
322  {CutJetIDWP, std::make_unique<TauAnalysisTools::TauSelectionCutJetIDWP>(this)},
323  {CutEleRNNScore, std::make_unique<TauAnalysisTools::TauSelectionCutRNNEleScore>(this)},
324  {CutEleIDWP, std::make_unique<TauAnalysisTools::TauSelectionCutEleIDWP>(this)},
325  {CutMuonOLR, std::make_unique<TauAnalysisTools::TauSelectionCutMuonOLR>(this)}
326  };
327 
328  m_cMap = { std::make_move_iterator( begin(elements) ), std::make_move_iterator( end(elements) ) };
329 
330  ATH_MSG_INFO( "Initializing TauSelectionTool" );
338 
341  PrintConfigValue ("AbsCharge", m_vAbsCharges);
342  PrintConfigValue ("NTrack", m_vNTracks);
343  PrintConfigRegion ("RNNJetScoreSigTrans", m_vJetRNNSigTransRegion);
344  PrintConfigRegion ("GNTauScoreSigTrans", m_vGNTauSigTransRegion);
345  PrintConfigRegion ("RNNEleScore", m_vEleRNNRegion);
346  PrintConfigValue ("JetIDWP", m_sJetIDWP);
347  PrintConfigValue ("JetIDWP ENUM",m_iJetIDWP);
348  PrintConfigValue ("EleIDWP", m_sEleIDWP);
349  PrintConfigValue ("EleIDWP ENUM",m_iEleIDWP);
350  PrintConfigValue ("EleIDVersion",m_iEleIDVersion);
351  PrintConfigValue ("MuonOLR", m_bMuonOLR);
352 
353  std::string sCuts = "";
354  if (m_iSelectionCuts & CutPt) sCuts += "Pt ";
355  if (m_iSelectionCuts & CutAbsEta) sCuts += "AbsEta ";
356  if (m_iSelectionCuts & CutAbsCharge) sCuts += "AbsCharge ";
357  if (m_iSelectionCuts & CutNTrack) sCuts += "NTrack ";
358  if (m_iSelectionCuts & CutJetRNNScoreSigTrans) sCuts += "JetRNNScoreSigTrans ";
359  if (m_iSelectionCuts & CutGNTauScoreSigTrans) sCuts += "GNTauScoreSigTrans ";
360  if (m_iSelectionCuts & CutJetIDWP) sCuts += "JetIDWP ";
361  if (m_iSelectionCuts & CutEleRNNScore) sCuts += "EleRNNScore ";
362  if (m_iSelectionCuts & CutEleIDWP) sCuts += "EleIDWP ";
363  if (m_iSelectionCuts & CutMuonOLR) sCuts += "MuonOLR ";
364 
365  ATH_MSG_DEBUG( "cuts: " << sCuts);
366 
369 
370  for ( const auto& entry : m_cMap ) {
371  if ( m_iSelectionCuts &entry.first ) {
372  entry.second->setAcceptInfo(m_aAccept);
373  }
374  }
375 
376  return StatusCode::SUCCESS;
377 }

◆ 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 88 of file AsgMetadataTool.cxx.

88  {
89 
90 #ifdef XAOD_STANDALONE
91  return &m_inputMetaStore;
92 #else // XAOD_STANDALONE
93  return m_inputMetaStore;
94 #endif // XAOD_STANDALONE
95  }

◆ 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 xAODMaker::FileMetaDataTool, BookkeeperTool, BookkeeperDumperTool, xAODMaker::TriggerMenuMetaDataTool, and xAODMaker::TruthMetaDataTool.

Definition at line 204 of file AsgMetadataTool.cxx.

204  {
205 
206  // Return gracefully:
207  return StatusCode::SUCCESS;
208  }

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

◆ outputMetaStore()

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

Accessor for the output metadata store.

Definition at line 97 of file AsgMetadataTool.cxx.

97  {
98 
99 #ifdef XAOD_STANDALONE
100  return &m_outputMetaStore;
101 #else // XAOD_STANDALONE
102  return m_outputMetaStore;
103 #endif // XAOD_STANDALONE
104  }

◆ print() [1/2]

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

◆ print() [2/2]

virtual void asg::IAsgTool::print ( ) const
pure virtualinherited

◆ PrintConfigRegion()

template<typename T >
void TauSelectionTool::PrintConfigRegion ( const std::string &  sCutName,
std::vector< T > &  vRegion 
) const
private

Definition at line 554 of file TauSelectionTool.cxx.

555 {
556  unsigned int iNumRegion = vRegion.size()/2;
557  for( unsigned int iRegion = 0; iRegion < iNumRegion; iRegion++ )
558  {
559  ATH_MSG_DEBUG( sCutName<<": " << vRegion.at(iRegion*2) << " to " << vRegion.at(iRegion*2+1) );
560  }
561 }

◆ PrintConfigValue() [1/2]

template<typename T >
void TauSelectionTool::PrintConfigValue ( const std::string &  sCutName,
std::vector< T > &  vRegion 
) const
private

Definition at line 565 of file TauSelectionTool.cxx.

566 {
567  for (auto tVal : vRegion)
568  ATH_MSG_DEBUG( sCutName<<": " << tVal );
569 }

◆ PrintConfigValue() [2/2]

template<typename T >
void TauSelectionTool::PrintConfigValue ( const std::string &  sCutName,
T &  sVal 
) const
private

Definition at line 573 of file TauSelectionTool.cxx.

574 {
575  ATH_MSG_DEBUG( sCutName<<": " << tVal );
576 }

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

◆ setOutFile()

void TauSelectionTool::setOutFile ( TFile *  fOutFile)
overridevirtual

Set output file for control histograms.

Implements TauAnalysisTools::ITauSelectionTool.

Definition at line 478 of file TauSelectionTool.cxx.

479 {
480  m_fOutFile = fOutFile;
481 }

◆ setupCutFlowHistogram()

void TauSelectionTool::setupCutFlowHistogram ( )
private

Definition at line 503 of file TauSelectionTool.cxx.

504 {
505  // count number of cuts
506  int iNBins = 0;
507  for (const auto& entry : m_cMap)
508  if (m_iSelectionCuts & entry.first)
509  iNBins++;
510  // create cutflow histogram with iNBins+1 bins, where first bin is 'All' bin
511  m_hCutFlow = std::make_shared<TH1F>("hCutFlow","CutFlow;; events",iNBins+1,0,iNBins+1);
512  m_hCutFlow->GetXaxis()->SetBinLabel(1,"All");
513 
514  // reusing this variable to reduce overhead
515  iNBins = 2;
516  // set bin labels
517  for (const auto& entry : m_cMap)
518  if (m_iSelectionCuts & entry.first)
519  {
520  m_hCutFlow->GetXaxis()->SetBinLabel(iNBins, entry.second->getName().c_str());
521  iNBins++;
522  }
523 }

◆ setUseIncidents()

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

Definition at line 132 of file AsgMetadataTool.h.

133  {
135  }

◆ 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 110 of file AsgMetadataTool.cxx.

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

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

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

◆ writeControlHistograms()

void TauSelectionTool::writeControlHistograms ( )
overridevirtual

Write control histograms to output file.

create output directory

write cutflow histogram

Implements TauAnalysisTools::ITauSelectionTool.

Definition at line 484 of file TauSelectionTool.cxx.

485 {
487  ATH_MSG_WARNING("CreateControlPlots was set to true, but no valid file pointer was provided");
489  {
491  m_fOutFile->mkdir((this->name()+"_control").c_str());
492  m_fOutFile->cd((this->name()+"_control").c_str());
494  m_hCutFlow->Write();
495 
496  for (const auto& entry : m_cMap)
497  entry.second->writeControlHistograms();
498  }
499 }

Friends And Related Function Documentation

◆ TauSelectionCut

friend class TauSelectionCut
friend

need to define cut classes to be friends to access protected variables, needed for access of cut thresholds

Definition at line 56 of file TauSelectionTool.h.

◆ TauSelectionCutAbsCharge

friend class TauSelectionCutAbsCharge
friend

Definition at line 59 of file TauSelectionTool.h.

◆ TauSelectionCutAbsEta

friend class TauSelectionCutAbsEta
friend

Definition at line 58 of file TauSelectionTool.h.

◆ TauSelectionCutEleIDWP

friend class TauSelectionCutEleIDWP
friend

Definition at line 65 of file TauSelectionTool.h.

◆ TauSelectionCutGNTauScoreSigTrans

friend class TauSelectionCutGNTauScoreSigTrans
friend

Definition at line 63 of file TauSelectionTool.h.

◆ TauSelectionCutJetIDWP

friend class TauSelectionCutJetIDWP
friend

Definition at line 61 of file TauSelectionTool.h.

◆ TauSelectionCutMuonOLR

friend class TauSelectionCutMuonOLR
friend

Definition at line 66 of file TauSelectionTool.h.

◆ TauSelectionCutNTracks

friend class TauSelectionCutNTracks
friend

Definition at line 60 of file TauSelectionTool.h.

◆ TauSelectionCutPt

friend class TauSelectionCutPt
friend

Definition at line 57 of file TauSelectionTool.h.

◆ TauSelectionCutRNNEleScore

friend class TauSelectionCutRNNEleScore
friend

Definition at line 64 of file TauSelectionTool.h.

◆ TauSelectionCutRNNJetScoreSigTrans

Definition at line 62 of file TauSelectionTool.h.

Member Data Documentation

◆ m_aAccept

asg::AcceptInfo TauAnalysisTools::TauSelectionTool::m_aAccept
protected

Object used to store selection information.

Definition at line 179 of file TauSelectionTool.h.

◆ m_bCreateControlPlots

bool TauAnalysisTools::TauSelectionTool::m_bCreateControlPlots
protected

Definition at line 176 of file TauSelectionTool.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_bMuonOLR

bool TauAnalysisTools::TauSelectionTool::m_bMuonOLR
private

Definition at line 140 of file TauSelectionTool.h.

◆ m_cMap

std::map<SelectionCuts, std::unique_ptr<TauAnalysisTools::TauSelectionCut> > TauAnalysisTools::TauSelectionTool::m_cMap
private

Definition at line 167 of file TauSelectionTool.h.

◆ m_dAbsEtaMax

float TauAnalysisTools::TauSelectionTool::m_dAbsEtaMax
private

Definition at line 145 of file TauSelectionTool.h.

◆ m_dAbsEtaMin

float TauAnalysisTools::TauSelectionTool::m_dAbsEtaMin
private

Definition at line 144 of file TauSelectionTool.h.

◆ m_dEleRNNMax

float TauAnalysisTools::TauSelectionTool::m_dEleRNNMax
private

Definition at line 153 of file TauSelectionTool.h.

◆ m_dEleRNNMin

float TauAnalysisTools::TauSelectionTool::m_dEleRNNMin
private

Definition at line 152 of file TauSelectionTool.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_dGNTauSigTransMax

float TauAnalysisTools::TauSelectionTool::m_dGNTauSigTransMax
private

Definition at line 151 of file TauSelectionTool.h.

◆ m_dGNTauSigTransMin

float TauAnalysisTools::TauSelectionTool::m_dGNTauSigTransMin
private

Definition at line 150 of file TauSelectionTool.h.

◆ m_dJetRNNSigTransMax

float TauAnalysisTools::TauSelectionTool::m_dJetRNNSigTransMax
private

Definition at line 149 of file TauSelectionTool.h.

◆ m_dJetRNNSigTransMin

float TauAnalysisTools::TauSelectionTool::m_dJetRNNSigTransMin
private

Definition at line 148 of file TauSelectionTool.h.

◆ m_dPtMax

float TauAnalysisTools::TauSelectionTool::m_dPtMax
private

Definition at line 143 of file TauSelectionTool.h.

◆ m_dPtMin

float TauAnalysisTools::TauSelectionTool::m_dPtMin
private

Definition at line 142 of file TauSelectionTool.h.

◆ m_eVetoDecorKey

SG::ReadDecorHandleKey<xAOD::TauJetContainer> TauAnalysisTools::TauSelectionTool::m_eVetoDecorKey {this, "eVetoDecorName", "", "Name of eVeto decoration"}
private

Definition at line 164 of file TauSelectionTool.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_fOutFile

TFile* TauAnalysisTools::TauSelectionTool::m_fOutFile
protected

Definition at line 156 of file TauSelectionTool.h.

◆ m_GNTauDecorKey

SG::ReadDecorHandleKey<xAOD::TauJetContainer> TauAnalysisTools::TauSelectionTool::m_GNTauDecorKey {this, "GNTauDecorName", "", "Name of GnTauID decoration"}
private

Definition at line 165 of file TauSelectionTool.h.

◆ m_hCutFlow

std::shared_ptr<TH1F> TauAnalysisTools::TauSelectionTool::m_hCutFlow
protected

Definition at line 157 of file TauSelectionTool.h.

◆ m_iAbsCharge

float TauAnalysisTools::TauSelectionTool::m_iAbsCharge
private

Definition at line 146 of file TauSelectionTool.h.

◆ m_iEleIDVersion

int TauAnalysisTools::TauSelectionTool::m_iEleIDVersion
private

Definition at line 138 of file TauSelectionTool.h.

◆ m_iEleIDWP

int TauAnalysisTools::TauSelectionTool::m_iEleIDWP
private

Definition at line 137 of file TauSelectionTool.h.

◆ m_iJetIDWP

int TauAnalysisTools::TauSelectionTool::m_iJetIDWP
private

Definition at line 132 of file TauSelectionTool.h.

◆ m_inputMetaStore

MetaStore_t asg::AsgMetadataTool::m_inputMetaStore
privateinherited

Object accessing the input metadata store.

Definition at line 119 of file AsgMetadataTool.h.

◆ m_iNTrack

float TauAnalysisTools::TauSelectionTool::m_iNTrack
private

Definition at line 147 of file TauSelectionTool.h.

◆ m_iSelectionCuts

int TauAnalysisTools::TauSelectionTool::m_iSelectionCuts
private

Definition at line 117 of file TauSelectionTool.h.

◆ m_muonContainerKey

SG::ReadHandleKey<xAOD::MuonContainer> TauAnalysisTools::TauSelectionTool::m_muonContainerKey {this, "MuonContainerName", "Muons", "Muon container name"}
private

Definition at line 162 of file TauSelectionTool.h.

◆ m_outputMetaStore

MetaStore_t asg::AsgMetadataTool::m_outputMetaStore
privateinherited

Object accessing the output metadata store.

Definition at line 121 of file AsgMetadataTool.h.

◆ m_sConfigPath

std::string TauAnalysisTools::TauSelectionTool::m_sConfigPath
private

Definition at line 160 of file TauSelectionTool.h.

◆ m_sEleIDWP

std::string TauAnalysisTools::TauSelectionTool::m_sEleIDWP
private

Definition at line 136 of file TauSelectionTool.h.

◆ m_sJetIDWP

std::string TauAnalysisTools::TauSelectionTool::m_sJetIDWP
private

Definition at line 131 of file TauSelectionTool.h.

◆ m_tauContainerKey

SG::ReadHandleKey<xAOD::TauJetContainer> TauAnalysisTools::TauSelectionTool::m_tauContainerKey {this, "TauContainerName", "TauJets", "Tau container name"}
private

Definition at line 163 of file TauSelectionTool.h.

◆ m_useIncidents

bool asg::AsgMetadataTool::m_useIncidents
privateinherited

Definition at line 128 of file AsgMetadataTool.h.

◆ m_vAbsCharges

std::vector<int> TauAnalysisTools::TauSelectionTool::m_vAbsCharges
private

Definition at line 123 of file TauSelectionTool.h.

◆ m_vAbsEtaRegion

std::vector<float> TauAnalysisTools::TauSelectionTool::m_vAbsEtaRegion
private

Definition at line 121 of file TauSelectionTool.h.

◆ m_varHandleArraysDeclared

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

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vEleRNNRegion

std::vector<float> TauAnalysisTools::TauSelectionTool::m_vEleRNNRegion
private

Definition at line 134 of file TauSelectionTool.h.

◆ m_vGNTauSigTransRegion

std::vector<float> TauAnalysisTools::TauSelectionTool::m_vGNTauSigTransRegion
private

Definition at line 129 of file TauSelectionTool.h.

◆ m_vhka

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

Definition at line 398 of file AthCommonDataStore.h.

◆ m_vJetRNNSigTransRegion

std::vector<float> TauAnalysisTools::TauSelectionTool::m_vJetRNNSigTransRegion
private

Definition at line 127 of file TauSelectionTool.h.

◆ m_vNTracks

std::vector<unsigned> TauAnalysisTools::TauSelectionTool::m_vNTracks
private

Definition at line 125 of file TauSelectionTool.h.

◆ m_vPtRegion

std::vector<float> TauAnalysisTools::TauSelectionTool::m_vPtRegion
private

Definition at line 119 of file TauSelectionTool.h.


The documentation for this class was generated from the following files:
TauAnalysisTools::TauSelectionTool::m_vPtRegion
std::vector< float > m_vPtRegion
Definition: TauSelectionTool.h:119
TauAnalysisTools::CutAbsEta
@ CutAbsEta
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:43
TauAnalysisTools::TauSelectionTool::convertStrToEleIDWP
int convertStrToEleIDWP(const std::string &sEleIDWP) const
Definition: TauSelectionTool.cxx:596
ATH_MSG_FATAL
#define ATH_MSG_FATAL(x)
Definition: AthMsgStreamMacros.h:34
TauAnalysisTools::TauSelectionTool::m_dAbsEtaMax
float m_dAbsEtaMax
Definition: TauSelectionTool.h:145
asg::AsgMetadataTool::beginEvent
virtual StatusCode beginEvent()
Function called when a new events is loaded.
Definition: AsgMetadataTool.cxx:196
TauAnalysisTools::ELEIDNONEUNCONFIGURED
@ ELEIDNONEUNCONFIGURED
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:31
StateLessPT_NewConfig.proxy
proxy
Definition: StateLessPT_NewConfig.py:395
TauAnalysisTools::TauSelectionTool::m_dEleRNNMin
float m_dEleRNNMin
Definition: TauSelectionTool.h:152
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
TauAnalysisTools::CutMuonOLR
@ CutMuonOLR
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:50
TauAnalysisTools::TauSelectionTool::setupCutFlowHistogram
void setupCutFlowHistogram()
Definition: TauSelectionTool.cxx:503
TauAnalysisTools::TauSelectionTool::m_sJetIDWP
std::string m_sJetIDWP
Definition: TauSelectionTool.h:131
TauAnalysisTools::JETIDRNNTIGHT
@ JETIDRNNTIGHT
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:22
TauAnalysisTools::TauSelectionTool::m_hCutFlow
std::shared_ptr< TH1F > m_hCutFlow
Definition: TauSelectionTool.h:157
AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
TauAnalysisTools::JETIDRNNMEDIUM
@ JETIDRNNMEDIUM
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:21
TauAnalysisTools::TauSelectionTool::m_dPtMin
float m_dPtMin
Definition: TauSelectionTool.h:142
TauAnalysisTools::JETIDGNTAULOOSE
@ JETIDGNTAULOOSE
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:24
PlotCalibFromCool.begin
begin
Definition: PlotCalibFromCool.py:94
TauAnalysisTools::TauSelectionTool::FillRegionVector
void FillRegionVector(std::vector< T > &vRegion, U tMin, U tMax) const
Definition: TauSelectionTool.cxx:527
TauAnalysisTools::TauSelectionTool::m_vJetRNNSigTransRegion
std::vector< float > m_vJetRNNSigTransRegion
Definition: TauSelectionTool.h:127
TauAnalysisTools::TauSelectionTool::m_sConfigPath
std::string m_sConfigPath
Definition: TauSelectionTool.h:160
TauAnalysisTools::TauSelectionTool::m_vGNTauSigTransRegion
std::vector< float > m_vGNTauSigTransRegion
Definition: TauSelectionTool.h:129
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
TauAnalysisTools::JETIDRNNLOOSE
@ JETIDRNNLOOSE
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:20
asg::AsgMetadataTool::m_beginInputFileCalled
bool m_beginInputFileCalled
Flag helping to discover when the tool misses the opening of the first input file.
Definition: AsgMetadataTool.h:126
asg::AsgMetadataTool::endInputFile
virtual StatusCode endInputFile()
Function called when the currently open input file got completely processed.
Definition: AsgMetadataTool.cxx:188
asg::AsgMetadataTool::m_outputMetaStore
MetaStore_t m_outputMetaStore
Object accessing the output metadata store.
Definition: AsgMetadataTool.h:121
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
dbg::ptr
void * ptr(T *p)
Definition: SGImplSvc.cxx:74
TauAnalysisTools::testFileForEOFContainsCharacters
bool testFileForEOFContainsCharacters(const std::string &sFileName)
returns true if last line in file is empty or the line starts with the number sign
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/Root/HelperFunctions.cxx:279
TauAnalysisTools::JETIDNONE
@ JETIDNONE
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:14
TauAnalysisTools::CutJetIDWP
@ CutJetIDWP
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:47
TauAnalysisTools::TauSelectionTool::m_dJetRNNSigTransMax
float m_dJetRNNSigTransMax
Definition: TauSelectionTool.h:149
Trk::u
@ u
Enums for curvilinear frames.
Definition: ParamDefs.h:77
TauAnalysisTools::TauSelectionTool::PrintConfigValue
void PrintConfigValue(const std::string &sCutName, std::vector< T > &vRegion) const
Definition: TauSelectionTool.cxx:565
mergePhysValFiles.end
end
Definition: DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:93
python.iconfTool.models.loaders.level
level
Definition: loaders.py:20
TauAnalysisTools::ELEIDRNNLOOSE
@ ELEIDRNNLOOSE
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:33
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:29
TauAnalysisTools::TauSelectionTool::m_cMap
std::map< SelectionCuts, std::unique_ptr< TauAnalysisTools::TauSelectionCut > > m_cMap
Definition: TauSelectionTool.h:167
TauAnalysisTools::TauSelectionTool::FillValueVector
void FillValueVector(std::vector< T > &vRegion, U tVal) const
Definition: TauSelectionTool.cxx:544
AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore
ServiceHandle< StoreGateSvc > & evtStore()
The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
Definition: AthCommonDataStore.h:85
TauAnalysisTools::TauSelectionTool::m_vEleRNNRegion
std::vector< float > m_vEleRNNRegion
Definition: TauSelectionTool.h:134
TauAnalysisTools::TauSelectionTool::m_dGNTauSigTransMin
float m_dGNTauSigTransMin
Definition: TauSelectionTool.h:150
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
AthCommonDataStore
Definition: AthCommonDataStore.h:52
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
TauAnalysisTools::JETIDGNTAUVERYLOOSE
@ JETIDGNTAUVERYLOOSE
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:23
TauAnalysisTools::TauSelectionTool::m_iEleIDWP
int m_iEleIDWP
Definition: TauSelectionTool.h:137
TauAnalysisTools::ELEIDNONE
@ ELEIDNONE
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:32
lumiFormat.i
int i
Definition: lumiFormat.py:85
TauAnalysisTools::TauSelectionTool::m_dEleRNNMax
float m_dEleRNNMax
Definition: TauSelectionTool.h:153
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
TauAnalysisTools::TauSelectionTool::convertEleIDWPToStr
std::string convertEleIDWPToStr(int iEleIDWP) const
Definition: TauSelectionTool.cxx:640
xAOD::TauJet_v3
Class describing a tau jet.
Definition: TauJet_v3.h:41
python.LArMinBiasAlgConfig.int
int
Definition: LArMinBiasAlgConfig.py:59
TauAnalysisTools::TauSelectionTool::m_vNTracks
std::vector< unsigned > m_vNTracks
Definition: TauSelectionTool.h:125
TauAnalysisTools::TauSelectionTool::m_fOutFile
TFile * m_fOutFile
Definition: TauSelectionTool.h:156
asg::AsgMetadataTool::beginInputFile
virtual StatusCode beginInputFile()
Function called when a new input file is opened.
Definition: AsgMetadataTool.cxx:180
master.flag
bool flag
Definition: master.py:29
TauAnalysisTools::TauSelectionTool::PrintConfigRegion
void PrintConfigRegion(const std::string &sCutName, std::vector< T > &vRegion) const
Definition: TauSelectionTool.cxx:554
TauAnalysisTools::CutGNTauScoreSigTrans
@ CutGNTauScoreSigTrans
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:52
asg::AsgMetadataTool::metaDataStop
virtual StatusCode metaDataStop()
Function called when the tool should write out its metadata.
Definition: AsgMetadataTool.cxx:204
TauAnalysisTools::TauSelectionTool::m_sEleIDWP
std::string m_sEleIDWP
Definition: TauSelectionTool.h:136
python.xAODType.dummy
dummy
Definition: xAODType.py:4
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
MSG::name
const std::string & name(Level lvl)
Convenience function for translating message levels to strings.
Definition: MsgLevel.cxx:19
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
SG::VarHandleKey::initialize
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:103
TauAnalysisTools::ELEIDRNNMEDIUM
@ ELEIDRNNMEDIUM
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:34
TauAnalysisTools::TauSelectionTool::m_dGNTauSigTransMax
float m_dGNTauSigTransMax
Definition: TauSelectionTool.h:151
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
TauAnalysisTools::TauSelectionTool::m_dAbsEtaMin
float m_dAbsEtaMin
Definition: TauSelectionTool.h:144
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
GetAllXsec.entry
list entry
Definition: GetAllXsec.py:132
TauAnalysisTools::TauSelectionTool::m_vAbsCharges
std::vector< int > m_vAbsCharges
Definition: TauSelectionTool.h:123
TauAnalysisTools::TauSelectionTool::m_iSelectionCuts
int m_iSelectionCuts
Definition: TauSelectionTool.h:117
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
asg::AsgMetadataTool::m_inputMetaStore
MetaStore_t m_inputMetaStore
Object accessing the input metadata store.
Definition: AsgMetadataTool.h:119
TauAnalysisTools::CutNTrack
@ CutNTrack
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:45
TauAnalysisTools::ELEIDRNNTIGHT
@ ELEIDRNNTIGHT
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:35
TauAnalysisTools::TauSelectionTool::m_eVetoDecorKey
SG::ReadDecorHandleKey< xAOD::TauJetContainer > m_eVetoDecorKey
Definition: TauSelectionTool.h:164
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:240
TauAnalysisTools::CutEleRNNScore
@ CutEleRNNScore
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:48
ActsTrk::to_string
std::string to_string(const DetectorType &type)
Definition: GeometryDefs.h:34
TauAnalysisTools::CutJetRNNScoreSigTrans
@ CutJetRNNScoreSigTrans
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:51
TauAnalysisTools::TauSelectionTool::m_bCreateControlPlots
bool m_bCreateControlPlots
Definition: TauSelectionTool.h:176
TauAnalysisTools::TauSelectionTool::accept
virtual asg::AcceptData accept(const xAOD::IParticle *p) const override
Get the decision using a generic IParticle pointer.
Definition: TauSelectionTool.cxx:393
TauAnalysisTools::TauSelectionTool::m_vAbsEtaRegion
std::vector< float > m_vAbsEtaRegion
Definition: TauSelectionTool.h:121
TauAnalysisTools::TauSelectionTool::convertStrToJetIDWP
int convertStrToJetIDWP(const std::string &sJetIDWP) const
Definition: TauSelectionTool.cxx:579
TauAnalysisTools::CutEleIDWP
@ CutEleIDWP
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:49
PathResolverFindCalibFile
std::string PathResolverFindCalibFile(const std::string &logical_file_name)
Definition: PathResolver.cxx:431
TauAnalysisTools::CutAbsCharge
@ CutAbsCharge
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:46
TauAnalysisTools::TauSelectionTool::m_muonContainerKey
SG::ReadHandleKey< xAOD::MuonContainer > m_muonContainerKey
Definition: TauSelectionTool.h:162
TauAnalysisTools::TauSelectionTool::m_GNTauDecorKey
SG::ReadDecorHandleKey< xAOD::TauJetContainer > m_GNTauDecorKey
Definition: TauSelectionTool.h:165
a
TList * a
Definition: liststreamerinfos.cxx:10
h
asg::AsgMetadataTool
Base class for dual-use tools that provide file metadata access.
Definition: AsgMetadataTool.h:48
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
AthCommonMsg< AlgTool >::msg
MsgStream & msg() const
Definition: AthCommonMsg.h:24
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:629
TauAnalysisTools::TauSelectionTool::m_tauContainerKey
SG::ReadHandleKey< xAOD::TauJetContainer > m_tauContainerKey
Definition: TauSelectionTool.h:163
TauAnalysisTools::TauSelectionTool::m_aAccept
asg::AcceptInfo m_aAccept
Object used to store selection information.
Definition: TauSelectionTool.h:179
TauAnalysisTools::TauSelectionTool::m_iJetIDWP
int m_iJetIDWP
Definition: TauSelectionTool.h:132
xAODType::Tau
@ Tau
The object is a tau (jet)
Definition: ObjectType.h:49
TauAnalysisTools::JETIDGNTAUTIGHT
@ JETIDGNTAUTIGHT
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:26
TauAnalysisTools::TauSelectionTool::m_iEleIDVersion
int m_iEleIDVersion
Definition: TauSelectionTool.h:138
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
TauAnalysisTools::TauSelectionTool::m_dJetRNNSigTransMin
float m_dJetRNNSigTransMin
Definition: TauSelectionTool.h:148
TauAnalysisTools::JETIDGNTAUMEDIUM
@ JETIDGNTAUMEDIUM
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:25
TauAnalysisTools::NoCut
@ NoCut
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:41
TauAnalysisTools::JETIDRNNVERYLOOSE
@ JETIDRNNVERYLOOSE
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:19
TauAnalysisTools::CutPt
@ CutPt
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:42
TauAnalysisTools::TauSelectionTool::m_iAbsCharge
float m_iAbsCharge
Definition: TauSelectionTool.h:146
TauAnalysisTools::JETIDNONEUNCONFIGURED
@ JETIDNONEUNCONFIGURED
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/TauAnalysisTools/Enums.h:13
asg::AcceptData
Definition: AcceptData.h:30
SG::DataProxy
Definition: DataProxy.h:45
error
Definition: IImpactPoint3dEstimator.h:70
TauAnalysisTools::TauSelectionTool::m_dPtMax
float m_dPtMax
Definition: TauSelectionTool.h:143
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
TauAnalysisTools::TauSelectionTool::convertJetIDWPToStr
std::string convertJetIDWPToStr(int iJetIDWP) const
Definition: TauSelectionTool.cxx:608
TauAnalysisTools::TauSelectionTool::m_iNTrack
float m_iNTrack
Definition: TauSelectionTool.h:147
fitman.k
k
Definition: fitman.py:528
TauAnalysisTools::TauSelectionTool::m_bMuonOLR
bool m_bMuonOLR
Definition: TauSelectionTool.h:140
ServiceHandle< IIncidentSvc >
TauAnalysisTools::split
void split(const std::string &sInput, const char cDelim, std::vector< std::string > &vOut)
Definition: PhysicsAnalysis/TauID/TauAnalysisTools/Root/HelperFunctions.cxx:23
asg::AsgMetadataTool::m_useIncidents
bool m_useIncidents
Definition: AsgMetadataTool.h:128