ATLAS Offline Software
METMaker.h
Go to the documentation of this file.
1 
3 /*
4  Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
5 */
6 
7 // METMaker.h
8 // Header file for class METMaker
9 // Author: T.J.Khoo<khoo@cern.ch>
11 #ifndef METUTILITIES_MET_METMAKER_H
12 #define METUTILITIES_MET_METMAKER_H 1
13 
14 // STL includes
15 #include <string>
16 
17 // FrameWork includes
19 #include "AsgTools/ToolHandle.h"
20 #include "AsgTools/AsgTool.h"
21 
22 // METInterface includes
23 #include "METInterface/IMETMaker.h"
24 
25 // EDM includes
26 #include "xAODJet/JetContainer.h"
27 #include "xAODPFlow/PFOContainer.h"
28 
29 // Tracking Tool
31 
32 
33 // Forward declaration
34 
35 namespace met {
36 
37  // typedefs
39 
40  class METMaker
41  : public asg::AsgTool,
42  virtual public IMETMaker
43 
44  {
45  // This macro defines the constructor with the interface declaration
47 
48 
49  // Public methods:
51  public:
52 
53  // Copy constructor:
54 
56  METMaker(const std::string& name);
57 
59  virtual ~METMaker();
60 
61  // Athena algtool's Hooks
62  virtual StatusCode initialize() override final;
63 
64  virtual StatusCode rebuildMET(
65  const std::string& metKey,
66  xAOD::Type::ObjectType metType,
67  xAOD::MissingETContainer* metCont,
68  const xAOD::IParticleContainer* collection,
70  MissingETBase::UsageHandler::Policy objScale) override final;
71  //
72  virtual StatusCode rebuildMET(
73  xAOD::MissingET* met,
74  const xAOD::IParticleContainer* collection,
76  MissingETBase::UsageHandler::Policy objScale) override final;
77  //
78  virtual StatusCode rebuildMET(
79  xAOD::MissingET* met,
80  const xAOD::IParticleContainer* collection,
82  MissingETBase::UsageHandler::Policy p,
83  bool removeOverlap,
84  MissingETBase::UsageHandler::Policy objScale) override final;
85 
86  virtual StatusCode rebuildJetMET(
87  const std::string& metJetKey,
88  const std::string& softClusKey,
89  const std::string& softTrkKey,
90  xAOD::MissingETContainer* metCont,
92  const xAOD::MissingETContainer* metCoreCont,
94  bool doJetJVT) override final;
95 
96  virtual StatusCode rebuildJetMET(
97  const std::string& metJetKey,
98  const std::string& metSoftKey,
99  xAOD::MissingETContainer* metCont,
101  const xAOD::MissingETContainer* metCoreCont,
103  bool doJetJVT) override final;
104 
105  virtual StatusCode rebuildJetMET(
106  xAOD::MissingET* metJet,
109  xAOD::MissingET* metSoftClus,
110  const xAOD::MissingET* coreSoftClus,
111  xAOD::MissingET* metSoftTrk,
112  const xAOD::MissingET* coreSoftTrk,
113  bool doJetJVT,
114  bool tracksForHardJets = false,
115  std::vector<const xAOD::IParticle*>* softConst = 0) override final;
116 
117  virtual StatusCode rebuildTrackMET(
118  const std::string& metJetKey,
119  const std::string& softTrkKey,
120  xAOD::MissingETContainer* metCont,
122  const xAOD::MissingETContainer* metCoreCont,
124  bool doJetJVT) override final;
125 
127  const xAOD::PFOContainer* cpfo,
128  const xAOD::PFOContainer* npfo,
129  xAOD::MissingETAssociationHelper& metHelper,
130  xAOD::PFOContainer* OR_cpfos,
131  xAOD::PFOContainer* OR_npfos,
132  bool retainMuon = false,
133  const xAOD::IParticleContainer* muonCollection = 0) override final; //,
134  // MissingETBase::UsageHandler::Policy p);
135 
137  const xAOD::PFOContainer* pfo,
138  xAOD::MissingETAssociationHelper& metHelper,
139  const xAOD::PFOContainer** OR_pfos,
140  bool retainMuon,
141  const xAOD::IParticleContainer* muonCollection) override final;
142 
146  bool retainMuon = false,
147  const xAOD::IParticleContainer* muonCollection = 0,
148  MissingETBase::UsageHandler::Policy p =
149  MissingETBase::UsageHandler::ParticleFlow) override final;
150 
151  virtual StatusCode rebuildTrackMET(xAOD::MissingET* metJet,
154  xAOD::MissingET* metSoftTrk,
155  const xAOD::MissingET* coreSoftTrk,
156  bool doJetJVT) override final;
157 
158  virtual StatusCode markInvisible(
159  const xAOD::IParticleContainer* collection,
161  xAOD::MissingETContainer* metCont) override final;
162 
164  // Private data:
166  private:
167 
170 
171 
172  SG::ReadHandleKey<xAOD::VertexContainer> m_PVkey;
173  // std::string m_pvcoll;
174 
175  // configurable accessors
176  std::unique_ptr<SG::AuxElement::ConstAccessor<float > > m_acc_jetJvtMoment;
177  std::unique_ptr<SG::AuxElement::ConstAccessor<char > > m_acc_jetRejectionDec;
178 
179  // pT threshold for suppressing warnings of objects missing in association map
181 
185  std::string m_jetConstitScaleMom;
186  std::string m_jetJvtMomentName;
187  std::string m_jetRejectionDec;
188 
189  double m_CenJetPtCut, m_FwdJetPtCut ; // jet pt cut for central/forward jets
190  double m_JvtCut, m_JvtPtMax; // JVT cut and pt region of jets to apply a JVT selection
191  double m_JetEtaMax;
192  double m_JetEtaForw;
193 
194  std::string m_jetSelection;
195  std::string m_JvtWP;
197 
198  // thresholds and Jvt cut values for Tenacious WP
201 
202  // Extra configurables for custom WP
205  std::string m_customJvtWP;
206 
207  bool m_doPFlow;
210 
217 
218  bool m_muEloss;
222 
223  // muon overlap variables
230 
231  ToolHandle<InDet::IInDetTrackSelectionTool> m_trkseltool;
233 
236 
237  };
238 
239 } //> end namespace met
240 #endif //> !METUTILITIES_MET_METMAKER_H
met::METMaker::m_muEloss
bool m_muEloss
Definition: METMaker.h:218
met::METMaker
Definition: METMaker.h:44
asg::AsgTool
Base class for the dual-use tool implementation classes.
Definition: AsgTool.h:47
met::METMaker::m_jetTrkNMuOlap
int m_jetTrkNMuOlap
Definition: METMaker.h:224
met::METMaker::m_skipSystematicJetSelection
bool m_skipSystematicJetSelection
Definition: METMaker.h:216
met::METMaker::rebuildJetMET
virtual StatusCode rebuildJetMET(const std::string &metJetKey, const std::string &softClusKey, const std::string &softTrkKey, xAOD::MissingETContainer *metCont, const xAOD::JetContainer *jets, const xAOD::MissingETContainer *metCoreCont, xAOD::MissingETAssociationHelper &helper, bool doJetJVT) override final
Definition: METMaker.cxx:564
SG
Forward declaration.
Definition: CaloCellPacker_400_500.h:32
met::METMaker::m_customFwdJetPtCut
double m_customFwdJetPtCut
Definition: METMaker.h:203
met::METMaker::rebuildTrackMET
virtual StatusCode rebuildTrackMET(const std::string &metJetKey, const std::string &softTrkKey, xAOD::MissingETContainer *metCont, const xAOD::JetContainer *jets, const xAOD::MissingETContainer *metCoreCont, xAOD::MissingETAssociationHelper &helper, bool doJetJVT) override final
Definition: METMaker.cxx:527
met::METMaker::m_jetPsEMuOlap
double m_jetPsEMuOlap
Definition: METMaker.h:226
met::obj_link_t
ElementLink< xAOD::IParticleContainer > obj_link_t
Definition: METMaker.h:38
met::METMaker::m_JvtPtMax
double m_JvtPtMax
Definition: METMaker.h:190
met::METMaker::m_missObjWarningPtThreshold
float m_missObjWarningPtThreshold
Definition: METMaker.h:180
ObjectType
ObjectType
Definition: BaseObject.h:11
met::METMaker::m_acc_jetJvtMoment
std::unique_ptr< SG::AuxElement::ConstAccessor< float > > m_acc_jetJvtMoment
Definition: METMaker.h:176
met::METMaker::m_doSetMuonJetEMScale
bool m_doSetMuonJetEMScale
Definition: METMaker.h:215
met::METMaker::m_doPFlow
bool m_doPFlow
Definition: METMaker.h:207
InDet
Primary Vertex Finder.
Definition: VP1ErrorUtils.h:36
met::METMaker::m_jetConstitScaleMom
std::string m_jetConstitScaleMom
Definition: METMaker.h:185
met::METMaker::m_jetCorrectPhi
bool m_jetCorrectPhi
Definition: METMaker.h:182
met::METMaker::initialize
virtual StatusCode initialize() override final
Dummy implementation of the initialisation function.
Definition: METMaker.cxx:172
met::METMaker::m_jetSelection
std::string m_jetSelection
Definition: METMaker.h:194
met::METMaker::m_CenJetPtCut
double m_CenJetPtCut
Definition: METMaker.h:189
PFOContainer.h
met::METMaker::m_JetEtaForw
double m_JetEtaForw
Definition: METMaker.h:192
MissingETBase
General namespace for MET EDM software.
Definition: MissingETAssociation_v1.h:454
IMETMaker.h
xAOD
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
Definition: ICaloAffectedTool.h:24
met::METMaker::m_jetEmfMuOlap
double m_jetEmfMuOlap
Definition: METMaker.h:227
met::METMaker::m_FwdJetPtCut
double m_FwdJetPtCut
Definition: METMaker.h:189
const
bool const RAWDATA *ch2 const
Definition: LArRodBlockPhysicsV0.cxx:560
IAsgSelectionTool
Definition: IAsgSelectionTool.h:28
xAOD::IParticle
Class providing the definition of the 4-vector interface.
Definition: Event/xAOD/xAODBase/xAODBase/IParticle.h:41
met::METMaker::markInvisible
virtual StatusCode markInvisible(const xAOD::IParticleContainer *collection, xAOD::MissingETAssociationHelper &helper, xAOD::MissingETContainer *metCont) override final
Definition: METMaker.cxx:1242
met::METMaker::m_muIDPTJetPtRatioMuOlap
double m_muIDPTJetPtRatioMuOlap
Definition: METMaker.h:229
met::METMaker::m_customJvtCut
double m_customJvtCut
Definition: METMaker.h:204
met::METMaker::m_customCenJetPtCut
double m_customCenJetPtCut
Definition: METMaker.h:203
met::METMaker::~METMaker
virtual ~METMaker()
Destructor:
met::METMaker::m_doRemoveMuonJets
bool m_doRemoveMuonJets
Definition: METMaker.h:212
runBeamSpotCalibration.helper
helper
Definition: runBeamSpotCalibration.py:112
met::METMaker::m_JetEtaMax
double m_JetEtaMax
Definition: METMaker.h:191
IMETMaker
Definition: IMETMaker.h:28
met
Definition: IMETSignificance.h:24
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
met::METMaker::m_JvtWP
std::string m_JvtWP
Definition: METMaker.h:195
met::METMaker::m_doSoftTruth
bool m_doSoftTruth
Definition: METMaker.h:208
met::METMaker::m_jetTrkPtMuPt
double m_jetTrkPtMuPt
Definition: METMaker.h:228
met::METMaker::m_customJvtPtMax
double m_customJvtPtMax
Definition: METMaker.h:204
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ReadHandleKey.h
Property holding a SG store/key/clid from which a ReadHandle is made.
met::METMaker::m_jetMinEfrac
double m_jetMinEfrac
Definition: METMaker.h:183
met::METMaker::m_useGhostMuons
bool m_useGhostMuons
Definition: METMaker.h:211
met::METMaker::m_JvtMediumPtMax
double m_JvtMediumPtMax
Definition: METMaker.h:200
met::METMaker::m_PVkey
SG::ReadHandleKey< xAOD::VertexContainer > m_PVkey
Definition: METMaker.h:172
xAOD::MissingET_v1
Principal data object for Missing ET.
Definition: MissingET_v1.h:25
met::METMaker::m_customJvtWP
std::string m_customJvtWP
Definition: METMaker.h:205
xAODType::ParticleFlow
@ ParticleFlow
The object is a particle-flow object.
Definition: ObjectType.h:41
met::METMaker::m_useR21JvtFallback
bool m_useR21JvtFallback
Definition: METMaker.h:196
met::METMaker::m_doConstJet
bool m_doConstJet
Definition: METMaker.h:209
xAODType
Definition: ObjectType.h:13
DataVector
Derived DataVector<T>.
Definition: DataVector.h:581
IInDetTrackSelectionTool.h
python.L1.Config.LegacyTopoMergerMap.signals
signals
Definition: LegacyTopoMergerMap.py:13
met::METMaker::m_doRemoveElecTrksEM
bool m_doRemoveElecTrksEM
Definition: METMaker.h:214
MissingETBase::UsageHandler::Policy
Policy
Policies on usage checks.
Definition: MissingETCompositionBase.h:182
xAOD::MissingETContainer_v1
Container for xAOD::MissingET_v1 objects.
Definition: MissingETContainer_v1.h:21
private
#define private
Definition: DetDescrConditionsDict_dict_fixes.cxx:13
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
met::METMaker::m_acc_jetRejectionDec
std::unique_ptr< SG::AuxElement::ConstAccessor< char > > m_acc_jetRejectionDec
Definition: METMaker.h:177
xAOD::MissingETAssociationHelper
Definition: MissingETAssociationHelper.h:26
met::METMaker::m_JvtTightPtMax
double m_JvtTightPtMax
Definition: METMaker.h:199
met::METMaker::m_jetMinWeightedPt
double m_jetMinWeightedPt
Definition: METMaker.h:184
met::METMaker::rebuildMET
virtual StatusCode rebuildMET(const std::string &metKey, xAOD::Type::ObjectType metType, xAOD::MissingETContainer *metCont, const xAOD::IParticleContainer *collection, xAOD::MissingETAssociationHelper &helper, MissingETBase::UsageHandler::Policy objScale) override final
Definition: METMaker.cxx:249
met::METMaker::m_doRemoveElecTrks
bool m_doRemoveElecTrks
Definition: METMaker.h:213
met::METMaker::m_JvtCutMedium
double m_JvtCutMedium
Definition: METMaker.h:200
met::METMaker::m_jetWidthMuOlap
double m_jetWidthMuOlap
Definition: METMaker.h:225
xAOD::Vertex_v1
Class describing a Vertex.
Definition: Vertex_v1.h:42
JetContainer.h
met::METMaker::getPV
const xAOD::Vertex * getPV() const
Definition: METMaker.cxx:1398
ASG_TOOL_CLASS
#define ASG_TOOL_CLASS(CLASSNAME, INT1)
Definition: AsgToolMacros.h:68
met::METMaker::acceptTrack
bool acceptTrack(const xAOD::TrackParticle *trk, const xAOD::Vertex *vx) const
Definition: METMaker.cxx:1393
met::METMaker::m_JvtCutTight
double m_JvtCutTight
Definition: METMaker.h:199
met::METMaker::m_jetJvtMomentName
std::string m_jetJvtMomentName
Definition: METMaker.h:186
met::METMaker::METMaker
METMaker()
Default constructor:
met::METMaker::m_veryGreedyPhotons
bool m_veryGreedyPhotons
Definition: METMaker.h:221
defineDB.jets
list jets
Definition: JetTagCalibration/share/defineDB.py:24
xAOD::TrackParticle_v1
Class describing a TrackParticle.
Definition: TrackParticle_v1.h:43
ToolHandle.h
met::METMaker::m_greedyPhotons
bool m_greedyPhotons
Definition: METMaker.h:220
AsgTool.h
met::METMaker::retrieveOverlapRemovedConstituents
virtual StatusCode retrieveOverlapRemovedConstituents(const xAOD::PFOContainer *cpfo, const xAOD::PFOContainer *npfo, xAOD::MissingETAssociationHelper &metHelper, xAOD::PFOContainer *OR_cpfos, xAOD::PFOContainer *OR_npfos, bool retainMuon=false, const xAOD::IParticleContainer *muonCollection=0) override final
Definition: METMaker.cxx:1263
met::METMaker::m_JvtTool
ToolHandle< IAsgSelectionTool > m_JvtTool
Definition: METMaker.h:232
met::METMaker::m_orCaloTaggedMuon
bool m_orCaloTaggedMuon
Definition: METMaker.h:219
met::METMaker::m_jetRejectionDec
std::string m_jetRejectionDec
Definition: METMaker.h:187
met::METMaker::m_trkseltool
ToolHandle< InDet::IInDetTrackSelectionTool > m_trkseltool
Definition: METMaker.h:231
met::METMaker::m_JvtCut
double m_JvtCut
Definition: METMaker.h:190