ATLAS Offline Software
PhysValMET.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 // PhysValMET.h
6 // Header file for class PhysValMET
7 // Author: Daniel Buescher <daniel.buescher@cern.ch>, Philipp Mogg <philipp.mogg@cern.ch>
9 #ifndef MISSINGETDQA_PHYSVALMET_H
10 #define MISSINGETDQA_PHYSVALMET_H 1
11 
12 // STL includes
13 #include <string>
14 
15 // FrameWork includes
16 #include "GaudiKernel/ServiceHandle.h"
17 
18 // Local includes
20 
25 #include "METInterface/IMETMaker.h"
27 
28 #include "AsgTools/ToolHandle.h"
29 
30 // Root includes
31 #include "TH1.h"
32 
33 // Forward declaration
34 class IMETMaker;
37 namespace TauAnalysisTools {
38  class ITauSelectionTool;
39 }
40 
41 using namespace xAOD;
42 
43 namespace MissingEtDQA {
44 
46  : public ManagedMonitorToolBase
47 {
49  // Public methods:
51  public:
52 
53  // Copy constructor:
54 
56  PhysValMET( const std::string& type,
57  const std::string& name,
58  const IInterface* parent);
59 
61  virtual ~PhysValMET();
62 
63  // Athena algtool's Hooks
64  virtual StatusCode initialize();
65  virtual StatusCode bookHistograms();
66  virtual StatusCode fillHistograms();
67  virtual StatusCode procHistograms();
68 
69 
71  // Const methods:
73 
75  // Non-const methods:
77 
78 
80  // Private data:
82  private:
83  bool m_doTruth;
86 
89 
90  // Containers
91  std::string m_eleColl;
92  std::string m_gammaColl;
93  std::string m_tauColl;
94  std::string m_muonColl;
95  std::string m_mapname;
96  std::string m_corename;
97 
98  // Methods
99  bool Accept(const xAOD::Electron* el);
100  bool Accept(const xAOD::Photon* ph);
101  bool Accept(const xAOD::TauJet* tau);
102  bool Accept(const xAOD::Muon* muon);
103  bool Accept(const xAOD::Jet* jet, double JvtCut, ToolHandle<IJetUpdateJvt>* jvtTool);
104 
105  // vector of collections
106  std::vector <std::string> m_types;
107 
108  // vector of terms
109  std::vector <std::string> m_terms;
110 
111  // Map for names
112  std::map <std::string,std::string> m_names;
113 
114  // Hists
115  TH1D *m_MET_Track = nullptr, *m_MET_Track_x = nullptr, *m_MET_Track_y = nullptr, *m_MET_Track_phi = nullptr, *m_MET_Track_sum = nullptr;
116  TH1D *m_MET_PVTrack_Nominal = nullptr, *m_MET_PVTrack_Nominal_x = nullptr, *m_MET_PVTrack_Nominal_y = nullptr, *m_MET_PVTrack_Nominal_phi = nullptr, *m_MET_PVTrack_Nominal_sum = nullptr;
117  TH1D *m_MET_PVTrack_Pileup = nullptr, *m_MET_PVTrack_Pileup_x = nullptr, *m_MET_PVTrack_Pileup_y = nullptr, *m_MET_PVTrack_Pileup_phi = nullptr, *m_MET_PVTrack_Pileup_sum = nullptr;
118  TH1D *m_MET_Calo = nullptr, *m_MET_Calo_x = nullptr, *m_MET_Calo_y = nullptr, *m_MET_Calo_phi = nullptr, *m_MET_Calo_sum = nullptr;
119 
120  //Maps
121  std::map<std::string,std::vector<TH1D*> > m_MET_Ref;
122  std::map<std::string,std::vector<TH1D*> > m_MET_Ref_x;
123  std::map<std::string,std::vector<TH1D*> > m_MET_Ref_y;
124  std::map<std::string,std::vector<TH1D*> > m_MET_Ref_phi;
125  std::map<std::string,std::vector<TH1D*> > m_MET_Ref_sum;
126  std::map<std::string,std::vector<TH1D*> > m_MET_Diff_Ref;
127  std::map<std::string,std::vector<TH1D*> > m_MET_Diff_Ref_x;
128  std::map<std::string,std::vector<TH1D*> > m_MET_Diff_Ref_y;
129  std::map<std::string,std::vector<TH1D*> > m_MET_Diff_Ref_phi;
130  std::map<std::string,std::vector<TH1D*> > m_MET_Diff_Ref_sum;
131  std::map<std::string,std::vector<TH1D*> > m_MET_Cumu_Ref;
132  std::map<std::string,std::vector<TH1D*> > m_MET_Resolution_Ref;
133  std::map<std::string,std::vector<TH1D*> > m_MET_Significance_Ref;
134  std::map<std::string,std::vector<TH1D*> > m_MET_dPhi_Ref;
135  std::map<std::string,std::vector<TH2D*> > m_MET_CorrFinalTrk_Ref;
136  std::map<std::string,std::vector<TH2D*> > m_MET_CorrFinalClus_Ref;
137  std::map<std::string,std::vector<TH1D*> > m_MET_Reb;
138  std::map<std::string,std::vector<TH1D*> > m_MET_Reb_x;
139  std::map<std::string,std::vector<TH1D*> > m_MET_Reb_y;
140  std::map<std::string,std::vector<TH1D*> > m_MET_Reb_phi;
141  std::map<std::string,std::vector<TH1D*> > m_MET_Reb_sum;
142  std::map<std::string,std::vector<TH1D*> > m_MET_Diff_Reb;
143  std::map<std::string,std::vector<TH1D*> > m_MET_Diff_Reb_x;
144  std::map<std::string,std::vector<TH1D*> > m_MET_Diff_Reb_y;
145  std::map<std::string,std::vector<TH1D*> > m_MET_Diff_Reb_phi;
146  std::map<std::string,std::vector<TH1D*> > m_MET_Diff_Reb_sum;
147  std::map<std::string,std::vector<TH1D*> > m_MET_Cumu_Reb;
148  std::map<std::string,std::vector<TH1D*> > m_MET_Resolution_Reb;
149  std::map<std::string,std::vector<TH1D*> > m_MET_Significance_Reb;
150  std::map<std::string,std::vector<TH1D*> > m_MET_dPhi_Reb;
151  std::map<std::string,std::vector<TH2D*> > m_MET_CorrFinalTrk_Reb;
152  std::map<std::string,std::vector<TH2D*> > m_MET_CorrFinalClus_Reb;
153 
154  std::vector<std::string> m_dir_met;
155 
156  ToolHandle<CP::IMuonSelectionTool> m_muonSelTool {this, "MuonSelectionTool", "", "Muon selection tool"};
157  ToolHandle<IAsgElectronLikelihoodTool> m_elecSelLHTool {this, "ElectronLHSelectionTool", "", "Electron likelihood selection tool"};
158  ToolHandle<IAsgPhotonIsEMSelector> m_photonSelIsEMTool {this, "PhotonIsEMSelectionTool" , "", "Photon selection tool"};
159  ToolHandle<IJetUpdateJvt> m_jvtToolEM {this, "JVTToolEMTopo", "", "JVT tool for EMTopo jets"};
160  ToolHandle<IJetUpdateJvt> m_jvtToolPFlow {this, "JVTToolEMPFlow", "", "JVT tool forEMPFlow jets"};
161  ToolHandle<IMETMaker> m_metmakerTopo {this, "METMakerTopo", "", "METMaker for EMTopo jets"};
162  ToolHandle<IMETMaker> m_metmakerPFlow {this, "METMakerPFlow", "", "METMaker for EMPFlow jets"};
163  ToolHandle<TauAnalysisTools::ITauSelectionTool> m_tauSelTool{this, "TauSelectionTool", "", "Tau selection tool"};
164  ToolHandle<IMETMaker>* m_metmaker;
165 };
166 
167 }
168 
169 #endif //> !MISSINGETDQA_PHYSVALMET_H
MissingEtDQA::PhysValMET::m_MET_Reb_phi
std::map< std::string, std::vector< TH1D * > > m_MET_Reb_phi
Definition: PhysValMET.h:140
TauAnalysisTools
Definition: TruthCollectionMakerTau.h:16
MissingEtDQA::PhysValMET::m_MET_Diff_Reb
std::map< std::string, std::vector< TH1D * > > m_MET_Diff_Reb
Definition: PhysValMET.h:142
xAOD::muon
@ muon
Definition: TrackingPrimitives.h:195
xAOD::name
name
Definition: TriggerMenuJson_v1.cxx:29
MissingEtDQA::PhysValMET::m_muonColl
std::string m_muonColl
Definition: PhysValMET.h:94
IAsgPhotonIsEMSelector.h
ManagedMonitorToolBase
Provides functionality for users to implement and save histograms, ntuples, and summary data,...
Definition: ManagedMonitorToolBase.h:74
MissingEtDQA::PhysValMET::m_eleColl
std::string m_eleColl
Definition: PhysValMET.h:91
initialize
void initialize()
Definition: run_EoverP.cxx:894
MissingEtDQA::PhysValMET::m_tauColl
std::string m_tauColl
Definition: PhysValMET.h:93
MissingEtDQA::PhysValMET::m_corename
std::string m_corename
Definition: PhysValMET.h:96
IMETMaker.h
xAOD
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
Definition: ICaloAffectedTool.h:24
MissingEtDQA
Definition: PhysValMET.cxx:45
ITauSelectionTool.h
MissingEtDQA::PhysValMET::m_MET_Diff_Reb_y
std::map< std::string, std::vector< TH1D * > > m_MET_Diff_Reb_y
Definition: PhysValMET.h:144
MissingEtDQA::PhysValMET::PhysValMET
PhysValMET()
Default constructor:
xAOD::Muon_v1
Class describing a Muon.
Definition: Muon_v1.h:38
MissingEtDQA::PhysValMET::m_MET_CorrFinalClus_Reb
std::map< std::string, std::vector< TH2D * > > m_MET_CorrFinalClus_Reb
Definition: PhysValMET.h:152
MissingEtDQA::PhysValMET::m_names
std::map< std::string, std::string > m_names
Definition: PhysValMET.h:112
MissingEtDQA::PhysValMET::m_terms
std::vector< std::string > m_terms
Definition: PhysValMET.h:109
MissingEtDQA::PhysValMET::m_MET_dPhi_Ref
std::map< std::string, std::vector< TH1D * > > m_MET_dPhi_Ref
Definition: PhysValMET.h:134
IMuonSelectionTool.h
ManagedMonitorToolBase.h
MissingEtDQA::PhysValMET::m_doTruth
bool m_doTruth
Definition: PhysValMET.h:83
IMETMaker
Definition: IMETMaker.h:28
IAsgElectronLikelihoodTool.h
MissingEtDQA::PhysValMET::m_MET_Ref_phi
std::map< std::string, std::vector< TH1D * > > m_MET_Ref_phi
Definition: PhysValMET.h:124
MissingEtDQA::PhysValMET::m_MET_Diff_Reb_x
std::map< std::string, std::vector< TH1D * > > m_MET_Diff_Reb_x
Definition: PhysValMET.h:143
jet
Definition: JetCalibTools_PlotJESFactors.cxx:23
MissingEtDQA::PhysValMET::m_gammaColl
std::string m_gammaColl
Definition: PhysValMET.h:92
MissingEtDQA::PhysValMET::m_MET_Reb_y
std::map< std::string, std::vector< TH1D * > > m_MET_Reb_y
Definition: PhysValMET.h:139
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
xAOD::TauJet_v3
Class describing a tau jet.
Definition: TauJet_v3.h:41
MissingEtDQA::PhysValMET::m_MET_Significance_Ref
std::map< std::string, std::vector< TH1D * > > m_MET_Significance_Ref
Definition: PhysValMET.h:133
MissingEtDQA::PhysValMET
Definition: PhysValMET.h:47
MissingEtDQA::PhysValMET::m_MET_Resolution_Reb
std::map< std::string, std::vector< TH1D * > > m_MET_Resolution_Reb
Definition: PhysValMET.h:148
test_pyathena.parent
parent
Definition: test_pyathena.py:15
IAsgPhotonIsEMSelector
Interface to tool to select photons.
Definition: IAsgPhotonIsEMSelector.h:25
plotIsoValidation.el
el
Definition: plotIsoValidation.py:197
MissingEtDQA::PhysValMET::m_MET_Resolution_Ref
std::map< std::string, std::vector< TH1D * > > m_MET_Resolution_Ref
Definition: PhysValMET.h:132
MissingEtDQA::PhysValMET::m_mapname
std::string m_mapname
Definition: PhysValMET.h:95
MissingEtDQA::PhysValMET::m_MET_dPhi_Reb
std::map< std::string, std::vector< TH1D * > > m_MET_dPhi_Reb
Definition: PhysValMET.h:150
MissingEtDQA::PhysValMET::m_MET_Ref
std::map< std::string, std::vector< TH1D * > > m_MET_Ref
Definition: PhysValMET.h:121
MissingEtDQA::PhysValMET::m_MET_Significance_Reb
std::map< std::string, std::vector< TH1D * > > m_MET_Significance_Reb
Definition: PhysValMET.h:149
MissingEtDQA::PhysValMET::m_MET_Reb_x
std::map< std::string, std::vector< TH1D * > > m_MET_Reb_x
Definition: PhysValMET.h:138
MissingEtDQA::PhysValMET::m_MET_Diff_Reb_sum
std::map< std::string, std::vector< TH1D * > > m_MET_Diff_Reb_sum
Definition: PhysValMET.h:146
MissingEtDQA::PhysValMET::m_MET_Diff_Reb_phi
std::map< std::string, std::vector< TH1D * > > m_MET_Diff_Reb_phi
Definition: PhysValMET.h:145
MissingEtDQA::PhysValMET::m_dir_met
std::vector< std::string > m_dir_met
Definition: PhysValMET.h:154
MissingEtDQA::PhysValMET::m_MET_Cumu_Reb
std::map< std::string, std::vector< TH1D * > > m_MET_Cumu_Reb
Definition: PhysValMET.h:147
MissingEtDQA::PhysValMET::m_MET_Cumu_Ref
std::map< std::string, std::vector< TH1D * > > m_MET_Cumu_Ref
Definition: PhysValMET.h:131
MissingEtDQA::PhysValMET::m_metmaker
ToolHandle< IMETMaker > * m_metmaker
Definition: PhysValMET.h:164
xAOD::Electron_v1
Definition: Electron_v1.h:34
MissingEtDQA::PhysValMET::m_MET_Ref_sum
std::map< std::string, std::vector< TH1D * > > m_MET_Ref_sum
Definition: PhysValMET.h:125
IAsgElectronLikelihoodTool
Interface to tool to select electrons.
Definition: IAsgElectronLikelihoodTool.h:27
xAOD::Jet_v1
Class describing a jet.
Definition: Jet_v1.h:57
MissingEtDQA::PhysValMET::m_MET_Reb
std::map< std::string, std::vector< TH1D * > > m_MET_Reb
Definition: PhysValMET.h:137
xAOD::Photon_v1
Definition: Photon_v1.h:37
MissingEtDQA::PhysValMET::m_MET_Diff_Ref
std::map< std::string, std::vector< TH1D * > > m_MET_Diff_Ref
Definition: PhysValMET.h:126
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
MissingEtDQA::PhysValMET::m_MET_Ref_x
std::map< std::string, std::vector< TH1D * > > m_MET_Ref_x
Definition: PhysValMET.h:122
IJetUpdateJvt.h
MissingEtDQA::PhysValMET::m_MET_Diff_Ref_phi
std::map< std::string, std::vector< TH1D * > > m_MET_Diff_Ref_phi
Definition: PhysValMET.h:129
MissingEtDQA::PhysValMET::m_types
std::vector< std::string > m_types
Definition: PhysValMET.h:106
MissingEtDQA::PhysValMET::m_MET_CorrFinalTrk_Reb
std::map< std::string, std::vector< TH2D * > > m_MET_CorrFinalTrk_Reb
Definition: PhysValMET.h:151
MissingEtDQA::PhysValMET::m_MET_CorrFinalTrk_Ref
std::map< std::string, std::vector< TH2D * > > m_MET_CorrFinalTrk_Ref
Definition: PhysValMET.h:135
MissingEtDQA::PhysValMET::m_MET_CorrFinalClus_Ref
std::map< std::string, std::vector< TH2D * > > m_MET_CorrFinalClus_Ref
Definition: PhysValMET.h:136
MissingEtDQA::PhysValMET::m_doMETRefPlots
bool m_doMETRefPlots
Definition: PhysValMET.h:85
ToolHandle.h
Accept
Templated class containing a cut, name of cut and description of cut(optional) Typically,...
Definition: CutFlow.h:28
MissingEtDQA::PhysValMET::m_MET_Diff_Ref_sum
std::map< std::string, std::vector< TH1D * > > m_MET_Diff_Ref_sum
Definition: PhysValMET.h:130
MissingEtDQA::PhysValMET::m_MET_Reb_sum
std::map< std::string, std::vector< TH1D * > > m_MET_Reb_sum
Definition: PhysValMET.h:141
MissingEtDQA::PhysValMET::m_MET_Diff_Ref_x
std::map< std::string, std::vector< TH1D * > > m_MET_Diff_Ref_x
Definition: PhysValMET.h:127
MissingEtDQA::PhysValMET::m_MET_Diff_Ref_y
std::map< std::string, std::vector< TH1D * > > m_MET_Diff_Ref_y
Definition: PhysValMET.h:128
MissingEtDQA::PhysValMET::m_inputIsDAOD
bool m_inputIsDAOD
Definition: PhysValMET.h:84
MissingEtDQA::PhysValMET::m_MET_Ref_y
std::map< std::string, std::vector< TH1D * > > m_MET_Ref_y
Definition: PhysValMET.h:123