ATLAS Offline Software
SystematicsTool.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 
7 
8 #ifndef PATINTERFACES_SYSTEMATICS_TOOL_H
9 #define PATINTERFACES_SYSTEMATICS_TOOL_H
10 
11 // System include(s):
12 #include <unordered_map>
13 
14 // Local include(s):
19 
20 namespace CP {
21 
48  class SystematicsTool : virtual public ISystematicsTool {
49 
50  public:
54  SystematicsTool ();
55 
58  virtual bool
59  isAffectedBySystematic( const SystematicVariation& systematic ) const;
60 
65  virtual SystematicSet
66  affectingSystematics() const;
67 
72  virtual SystematicSet
73  recommendedSystematics() const;
74 
79  const SystematicSet& appliedSystematics() const;
80 
87  std::string appliedSystematicsString () const;
88 
104  ( const SystematicSet& systConfig );
105 
106  protected:
114  ( const SystematicVariation& systematic, bool recommended );
115 
119  ( const SystematicVariation& systematic );
120 
123  ( const SystematicSet& systematics );
124 
127  ( const SystematicSet& systematics );
128 
137  ( const SystematicSet& systConfig ) = 0;
138 
139  public:
142  void testInvariant() const;
143 
144  protected:
148 
149  private:
152 
154  std::unordered_map<SystematicSet, SystematicSet> m_systFilterMap;
155 
156  }; // class SystematicsTool
157 
158 } // namespace CP
159 
160 #endif // PATINTERFACES_SYSTEMATICS_TOOL_H
CP::SystematicsTool::testInvariant
void testInvariant() const
effects: test the invariance of this object guarantee: no-fail
Definition: SystematicsTool.cxx:165
CP::SystematicsTool::m_appliedSystematics
SystematicSet * m_appliedSystematics
description: pointer to currenty applied systematics
Definition: SystematicsTool.h:151
SystematicSet.h
CP::SystematicSet
Class to wrap a set of SystematicVariations.
Definition: SystematicSet.h:31
CP::SystematicsTool::affectingSystematics
virtual SystematicSet affectingSystematics() const
returns: the list of all systematics this tool can be affected by guarantee: strong failures: out of ...
Definition: SystematicsTool.cxx:40
CP::SystematicsTool::addAffectingSystematics
void addAffectingSystematics(const SystematicSet &systematics)
effects: add a SystematicSet to the registered systematics.
Definition: SystematicsTool.cxx:142
CP::SystematicsTool::m_affectingSystematics
SystematicSet m_affectingSystematics
description: members directly corresponding to accessors
Definition: SystematicsTool.h:146
CP::SystematicsTool::applySystematicVariation
virtual StatusCode applySystematicVariation(const SystematicSet &systConfig)
effects: configure this tool for the given list of systematic variations.
Definition: SystematicsTool.cxx:74
CP::SystematicVariation
Definition: SystematicVariation.h:47
CP
Select isolated Photons, Electrons and Muons.
Definition: Control/xAODRootAccess/xAODRootAccess/TEvent.h:48
ISystematicsTool.h
CP::SystematicsTool::recommendedSystematics
virtual SystematicSet recommendedSystematics() const
returns: the list of all systematics this tool can be affected by guarantee: strong failures: out of ...
Definition: SystematicsTool.cxx:47
CP::SystematicsTool::isAffectedBySystematic
virtual bool isAffectedBySystematic(const SystematicVariation &systematic) const
returns: whether this tool is affected by the given systematic guarantee: no-fail
Definition: SystematicsTool.cxx:32
CP::SystematicsTool::addRecommendedSystematic
StatusCode addRecommendedSystematic(const SystematicVariation &systematic)
effects: add a systematic to the list of recommended systematics failures: unsupported systematic
Definition: SystematicsTool.cxx:128
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
CP::SystematicsTool::m_systFilterMap
std::unordered_map< SystematicSet, SystematicSet > m_systFilterMap
map of cached systematics filtering
Definition: SystematicsTool.h:154
CP::SystematicsTool::sysApplySystematicVariation
virtual StatusCode sysApplySystematicVariation(const SystematicSet &systConfig)=0
effects: configure this tool for the given list of systematic variations.
CP::SystematicsTool::appliedSystematicsString
std::string appliedSystematicsString() const
returns: a string representation of appliedSystematics() guarantee: strong failures: out of memory II...
Definition: SystematicsTool.cxx:67
StatusCode.h
CheckAppliedSFs.systematics
def systematics
Definition: CheckAppliedSFs.py:231
CP::SystematicsTool::SystematicsTool
SystematicsTool()
effects: standard constructor guarantee: strong failures: out of memory I
Definition: SystematicsTool.cxx:25
CP::ISystematicsTool
Interface for all CP tools supporting systematic variations.
Definition: ISystematicsTool.h:32
CP::SystematicsTool
Base class for CP tools providing systematic variations.
Definition: SystematicsTool.h:48
CP::SystematicsTool::m_recommendedSystematics
SystematicSet m_recommendedSystematics
Definition: SystematicsTool.h:147
CP::SystematicsTool::addAffectingSystematic
StatusCode addAffectingSystematic(const SystematicVariation &systematic, bool recommended)
effects: add a systematic to the list of registered systematics.
Definition: SystematicsTool.cxx:112
CP::SystematicsTool::addRecommendedSystematics
StatusCode addRecommendedSystematics(const SystematicSet &systematics)
effects: add a SystematicSet to the recommended systematics.
Definition: SystematicsTool.cxx:152
CP::SystematicsTool::appliedSystematics
const SystematicSet & appliedSystematics() const
returns: the list of systematics that have been applied to this tool.
Definition: SystematicsTool.cxx:54
SystematicVariation.h