ATLAS Offline Software
Loading...
Searching...
No Matches
CommonDiTauSmearingTool.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef TAUANALYSISTOOLS_COMMONDITAUSMEARINGTOOL_H
6#define TAUANALYSISTOOLS_COMMONDITAUSMEARINGTOOL_H
7
8/*
9 author: David Kirchmeier
10 mail: david.kirchmeier@cern.ch
11 documentation in: ../doc/README-DiTauSmearingTool.rst
12*/
13
14// Framework include(s):
17
18// EDM include(s):
19#include "xAODTau/DiTauJet.h"
21
22// Local include(s):
27
28#include "TH3.h"
29
30namespace TauAnalysisTools
31{
32
34 : public virtual IDiTauSmearingTool
36{
39
40public:
41
42 CommonDiTauSmearingTool(const std::string& sName);
43
44 virtual StatusCode initialize();
45
47 virtual CP::CorrectionCode applyCorrection( xAOD::DiTauJet& xDiTau ) const;
49 virtual CP::CorrectionCode correctedCopy( const xAOD::DiTauJet& xDiTau,
50 xAOD::DiTauJet*& xDiTauCopy) const;
51
53 virtual bool isAffectedBySystematic( const CP::SystematicVariation& systematic ) const;
54
57
60
63 virtual StatusCode applySystematicVariation ( const CP::SystematicSet& sSystematicSet);
64
65protected:
66
67 std::map<std::string, TH3*> m_mDTSF;
68 std::unordered_map < CP::SystematicSet, std::string > m_mSystematicSets;
70 std::map<std::string, int> m_mSystematics;
71 std::map<std::string, std::string> m_mSystematicsHistNames;
72
73 double (*m_fX)(const xAOD::DiTauJet& xDiTau);
74 double (*m_fY)(const xAOD::DiTauJet& xDiTau);
75 double (*m_fZ)(const xAOD::DiTauJet& xDiTau);
76
77 template<class T>
78 void ReadInputs(TFile* fFile, std::map<std::string, T>& mMap);
79 virtual CP::CorrectionCode getValue(const std::string& sHistName,
80 const xAOD::DiTauJet& xDiTau,
81 double& dCorrectionFactor) const;
83
84 Gaudi::Property<std::string> m_sInputFilePath{this, "InputFilePath", ""};
85 Gaudi::Property<bool> m_bSkipTruthMatchCheck{this, "SkipTruthMatchCheck", false};
86
88
92
93
94};
95} // namespace TauAnalysisTools
96
97#endif // TAUANALYSISTOOLS_COMMONEFFICIENCYTOOL_H
98
99
100
#define ASG_TOOL_CLASS(CLASSNAME, INT1)
Return value from object correction CP tools.
Class to wrap a set of SystematicVariations.
double(* m_fY)(const xAOD::DiTauJet &xDiTau)
CommonDiTauSmearingTool(const std::string &sName)
Create a proper constructor for Athena.
virtual CP::SystematicSet recommendedSystematics() const
returns: the list of all systematics this tool recommends to use
virtual CP::CorrectionCode applyCorrection(xAOD::DiTauJet &xDiTau) const
Apply the correction on a modifiable object.
std::unordered_map< CP::SystematicSet, std::string > m_mSystematicSets
std::map< std::string, std::string > m_mSystematicsHistNames
double(* m_fX)(const xAOD::DiTauJet &xDiTau)
virtual CP::CorrectionCode correctedCopy(const xAOD::DiTauJet &xDiTau, xAOD::DiTauJet *&xDiTauCopy) const
Create a corrected copy from a constant ditau.
virtual bool isAffectedBySystematic(const CP::SystematicVariation &systematic) const
returns: whether this tool is affected by the given systematics
double(* m_fZ)(const xAOD::DiTauJet &xDiTau)
virtual StatusCode applySystematicVariation(const CP::SystematicSet &sSystematicSet)
configure this tool for the given list of systematic variations.
virtual CP::SystematicSet affectingSystematics() const
returns: the list of all systematics this tool can be affected by
virtual CP::CorrectionCode getValue(const std::string &sHistName, const xAOD::DiTauJet &xDiTau, double &dCorrectionFactor) const
void ReadInputs(TFile *fFile, std::map< std::string, T > &mMap)
Gaudi::Property< std::string > m_sInputFilePath
virtual StatusCode initialize()
Dummy implementation of the initialisation function.
Base class for dual-use tools that provide file metadata access.
DiTauJet_v1 DiTauJet
Definition of the current version.
Definition DiTauJet.h:17