ATLAS Offline Software
Loading...
Searching...
No Matches
IDPerfMonWenu.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
3*/
4
5// **********************************************************************
6// IDPerfMonWenu.cxx
7// AUTHORS: Beate Heinemann, Tobias Golling, Sara Strandberg
8// **********************************************************************
9
10
11#include "TH1.h"
12#include "TH2.h"
13#include "TH1F.h"
14#include "TH2F.h"
15#include "TProfile.h"
16#include "TLorentzVector.h"
17
19
22
23#include "xAODEgamma/Electron.h"
24#include "xAODEgamma/Egamma.h"
25#include "xAODEgamma/Photon.h"
27
30
33
34#include "GaudiKernel/SystemOfUnits.h"
35#include "GaudiKernel/PhysicalConstants.h"
36#include <cmath>
37#include <stdexcept>
38
39// *********************************************************************
40// Public Methods
41// *********************************************************************
42
43namespace{
44template <class T>
45 const T *
46 getCollectionWithCheck(const ServiceHandle<StoreGateSvc> & evtStore,const std::string &contName){
47 const T * container{};
48 if (evtStore->contains<T>(contName)){
49 //retrieve
50 if(evtStore->retrieve(container,contName).isFailure()) return nullptr;
51 }
52 return container;
53 }
54}
55
56IDPerfMonWenu::IDPerfMonWenu( const std::string & type, const std::string & name, const IInterface* parent )
57 :ManagedMonitorToolBase( type, name, parent ),
58 m_region_strings{"incl", "barrel", "eca", "ecc"},
59 m_triggerChainName("NoTriggerSelection")
60{
61 declareProperty("tracksName",m_tracksName);
62 declareProperty("electronsName",m_electronsName="Electrons");
63 declareProperty("photonsName",m_photonsName="Photons");
64 declareProperty("VxPrimContainerName",m_VxPrimContainerName="PrimaryVertices");
65 declareProperty("emclustersName",m_emclustersName="LArClusterEM");
66 declareProperty("metName",m_metName="MET_Reference_AntiKt4LCTopo");
67 declareProperty("METFinalName",m_metRefFinalName="FinalClus");
68 declareProperty("eoverp_standard_min",m_eoverp_standard_min=0.5);
69 declareProperty("eoverp_standard_max",m_eoverp_standard_max=4.0);
70 declareProperty("eoverp_tight_min",m_eoverp_tight_min=0.7);
71 declareProperty("eoverp_tight_max",m_eoverp_tight_max=1.3);
72 declareProperty("CheckRate",m_checkrate=1000);
73 declareProperty("triggerChainName",m_triggerChainName);
74 declareProperty("rejectSecondCluster",m_rejectSecondCluster = true);
75 declareProperty("electronIDLevel",m_electronIDLevel = "Tight");
76}
77
79
82 if (m_tracksName.empty() ){
83 ATH_MSG_WARNING( " no track collection given" );
84 }
86 if (sc.isFailure()){
87 ATH_MSG_WARNING( "Could not initialize ManagedMonitorToolBase" );
88 }
89 //---Electron Likelihood tool---
90 ATH_MSG_DEBUG("IDPerfMonWenu::Initialize() -- Setting up electron LH tool.");
91 m_LHTool2015=std::make_unique<AsgElectronLikelihoodTool> ("m_LHTool2015");
92 if((m_LHTool2015->setProperty("primaryVertexContainer",m_VxPrimContainerName)).isFailure()){
93 ATH_MSG_WARNING("Failure setting primary vertex container " << m_VxPrimContainerName << "in electron likelihood tool");
94 }
95 //Set up electron LH level
96 m_doIDCuts = true;
97 std::string confDir = "ElectronPhotonSelectorTools/offline/mc15_20150712/";
99 ATH_MSG_WARNING("electronIDLevel is set to empty! No electron ID cuts will be applied.");
100 m_doIDCuts = false;
101 } else {
102 if((m_electronIDLevel != "Loose") && (m_electronIDLevel != "Medium") && (m_electronIDLevel != "Tight")){
103 ATH_MSG_WARNING("Unknown electronIDLevel!! (Accepted values: Loose, Medium, Tight)");
104 m_doIDCuts = false;
105 } else {
106 std::string configFile = confDir+"ElectronLikelihood"+m_electronIDLevel+"OfflineConfig2015.conf";
107 ATH_MSG_INFO("Likelihood configuration file: " << configFile);
108 if((m_LHTool2015->setProperty("ConfigFile",configFile)).isFailure()){
109 ATH_MSG_WARNING("Failure loading ConfigFile in electron likelihood tool.");
110 }
111 }
112 }
113 StatusCode lh = m_LHTool2015->initialize();
114 if(lh.isFailure()){
115 ATH_MSG_WARNING("Electron likelihood tool initialize() failed! Turning off electron LH cuts!");
116 m_doIDCuts = false;
117 }
118 return StatusCode::SUCCESS;
119}
120
122{
123 MonGroup al_Wenu_mon ( this, "IDPerfMon/Wenu/" + m_triggerChainName, run);
124 if( newRunFlag() ) {
125 //if user environment specified we don't want to book new histograms at every run boundary
126 //we instead want one histogram per job
127 if(m_histosBooked!=0 && AthenaMonManager::environment()==AthenaMonManager::user) return StatusCode::SUCCESS;
128
129 // ***********************
130 // Book event histograms
131 // ***********************
132
133 m_Nevents = new TH1F("Nevents", "Number of events processed", 1, -.5, 0.5);
134 RegisterHisto(al_Wenu_mon,m_Nevents);
135 m_Wenu_met_sel = new TH1F("Wenu_met_sel","met", 50, 0., 100.);
136 RegisterHisto(al_Wenu_mon,m_Wenu_met_sel);
137 m_Wenu_transmass_sel = new TH1F("Wenu_transmass_sel","Transverse mass of the leading em cluster and the met", 90, 0., 180.);
139 m_Wenu_trk_transmass_sel = new TH1F("Wenu_trk_transmass_sel","Transverse mass of the track and the met", 90, 0., 180.);
141 m_Wenu_trk_transmass_sel_scaled = new TH1F("Wenu_trk_transmass_sel_scaled","Transverse mass of the track and the met scaled to per event", 90, 0., 180.);
143 m_Wenu_clus_pt = new TH1F("Wenu_cluster_pt","Transverse momentum of the leading em cluster",50,0.,100.);
144 RegisterHisto(al_Wenu_mon,m_Wenu_clus_pt);
145
146 // ***********************
147 // Book cluster histograms
148 // ***********************
149
150 // first take care to clear all histogram vectors
151 m_Wenu_Eop.clear();
152 m_Wenu_Eopdiff.clear();
153 m_Wenu_Eop_plus.clear();
154 m_Wenu_Eop_minus.clear();
155 m_Wenu_eta.clear();
156 m_Wenu_phi.clear();
157 m_Wenu_deta.clear();
158 m_Wenu_deta_vs_eta.clear();
159 m_Wenu_deta_vs_phi.clear();
160 m_Wenu_absdeta_vs_eta.clear();
161 m_Wenu_absdeta_vs_phi.clear();
162 m_Wenu_dphi.clear();
163 m_Wenu_dphi_vs_eta.clear();
164 m_Wenu_dphi_vs_phi.clear();
165 m_Wenu_absdphi_vs_eta.clear();
166 m_Wenu_absdphi_vs_phi.clear();
179 m_Wenu_meanEop_vs_p.clear();
181 m_Wenu_meanEop_vs_E.clear();
184 m_Wenu_meanEop_vs_phi.clear();
185 m_Wenu_meanEop_vs_eta.clear();
196 m_Wenu_Eop_lt1_gt1.clear();
197 m_Wenu_Eopdiff_vs_p.clear();
199 m_Wenu_Eopdiff_vs_E.clear();
200 m_Wenu_Eopdiff_vs_phi.clear();
201 m_Wenu_Eopdiff_vs_eta.clear();
202 m_Wenu_Eop_lt1_vs_eta.clear();
203 m_Wenu_Eop_lt1_vs_phi.clear();
204 m_Wenu_Eop_gt1_vs_eta.clear();
205 m_Wenu_Eop_gt1_vs_phi.clear();
208 m_Wenu_Eop_05_25.clear();
209 m_Wenu_Eop_15_25.clear();
211
212 for (int region=0; region!=Nregions; ++region) {
213 std::string title;
214 std::string name;
215
216 name = "Wenu_Eop_" + m_region_strings[region];
217 title = "E/p for Wenu EM-clusters in " + m_region_strings[region];
218 m_Wenu_Eop.push_back(new TH1F(name.c_str(),title.c_str(), 60, 0., 10.));
219
220 RegisterHisto(al_Wenu_mon,m_Wenu_Eop[region]);
221 name = "Wenu_Eopdiff_" + m_region_strings[region];
222 title = "E/p difference (pos-neg) for Wenu EM-clusters in " + m_region_strings[region];
223 m_Wenu_Eopdiff.push_back(new TH1F(name.c_str(),title.c_str(), 10, 0., 2.));
224
225 RegisterHisto(al_Wenu_mon,m_Wenu_Eopdiff[region],true);
226 name = "Wenu_Eop_plus_" + m_region_strings[region];
227 title = "E/p for pos. charged Wenu EM-clusters in " + m_region_strings[region];
228 m_Wenu_Eop_plus.push_back(new TH1F(name.c_str(),title.c_str(), 10, 0., 2.));
229 RegisterHisto(al_Wenu_mon,m_Wenu_Eop_plus[region],true);
230
231 name = "Wenu_Eop_minus_" + m_region_strings[region];
232 title = "E/p for neg. charged Wenu EM-clusters in " + m_region_strings[region];
233 m_Wenu_Eop_minus.push_back(new TH1F(name.c_str(),title.c_str(), 10, 0., 2.));
234 RegisterHisto(al_Wenu_mon,m_Wenu_Eop_minus[region],true);
235
236 if (region != incl) continue;
237
238 m_Wenu_eta.push_back(new TH1F("Wenu_eta","Eta of Wenu EM-clusters", 15, -3., 3.));
239 RegisterHisto(al_Wenu_mon,m_Wenu_eta[region]);
240 m_Wenu_phi.push_back(new TH1F("Wenu_phi","Phi of Wenu EM-clusters", 15, -3.15, 3.15));
241 RegisterHisto(al_Wenu_mon,m_Wenu_phi[region]);
242
243 m_Wenu_deta.push_back(new TH1F("Wenu_deta","deltaEta(EM-cluster,track) in Wenu events", 50, -0.5, 0.5));
244 RegisterHisto(al_Wenu_mon,m_Wenu_deta[region]);
245 m_Wenu_deta_vs_eta.push_back(new TProfile("Wenu_deta_vs_eta","deltaEta(EM-cluster,track) vs. eta in Wenu events", 15, -3., 3.));
246 RegisterHisto(al_Wenu_mon,m_Wenu_deta_vs_eta[region]);
247 m_Wenu_deta_vs_phi.push_back(new TProfile("Wenu_deta_vs_phi","deltaEta(EM-cluster,track) vs. phi in Wenu events", 15, -3.15, 3.15));
248 RegisterHisto(al_Wenu_mon,m_Wenu_deta_vs_phi[region]);
249 m_Wenu_absdeta_vs_eta.push_back(new TProfile("Wenu_absdeta_vs_eta","Abs(deltaEta(EM-cluster,track)) vs. eta in Wenu events", 15, -3., 3.));
250 RegisterHisto(al_Wenu_mon,m_Wenu_absdeta_vs_eta[region]);
251 m_Wenu_absdeta_vs_phi.push_back(new TProfile("Wenu_absdeta_vs_phi","Abs(deltaEta(EM-cluster,track)) vs. phi in Wenu events", 15, -3.15, 3.15));
252 RegisterHisto(al_Wenu_mon,m_Wenu_absdeta_vs_phi[region]);
253 m_Wenu_dphi.push_back(new TH1F("Wenu_dphi","deltaPhi(EM-cluster,track) in Wenu events", 50, -0.5, 0.5));
254 RegisterHisto(al_Wenu_mon,m_Wenu_dphi[region]);
255 m_Wenu_dphi_vs_eta.push_back(new TProfile("Wenu_dphi_vs_eta","deltaPhi(EM-cluster,track) vs. eta in Wenu events", 15, -3., 3.));
256 RegisterHisto(al_Wenu_mon,m_Wenu_dphi_vs_eta[region]);
257 m_Wenu_dphi_vs_phi.push_back(new TProfile("Wenu_dphi_vs_phi","deltaPhi(EM-cluster,track) vs. phi in Wenu events", 15, -3.15, 3.15));
258 RegisterHisto(al_Wenu_mon,m_Wenu_dphi_vs_phi[region]);
259 m_Wenu_absdphi_vs_eta.push_back(new TProfile("Wenu_absdphi_vs_eta","Abs(deltaPhi(EM-cluster,track)) vs. eta in Wenu events", 15, -3., 3.));
260 RegisterHisto(al_Wenu_mon,m_Wenu_absdphi_vs_eta[region]);
261 m_Wenu_absdphi_vs_phi.push_back(new TProfile("Wenu_absdphi_vs_phi","Abs(deltaPhi(EM-cluster,track)) vs. phi in Wenu events", 15, -3.15, 3.15));
262 RegisterHisto(al_Wenu_mon,m_Wenu_absdphi_vs_phi[region]);
263
264 m_Wenu_trackmatched_eta.push_back(new TH1F("Wenu_trackmatched_eta","Eta of track-matched Wenu EM-clusters", 15, -3., 3.));
265 RegisterHisto(al_Wenu_mon,m_Wenu_trackmatched_eta[region]);
266 m_Wenu_trackmatched_phi.push_back(new TH1F("Wenu_trackmatched_phi","Phi of track-matched Wenu EM-clusters", 15, -3.15, 3.15));
267 RegisterHisto(al_Wenu_mon,m_Wenu_trackmatched_phi[region]);
268 m_Wenu_trackmatched_Eopmatched_eta.push_back(new TH1F("Wenu_trackmatched_Eopmatched_eta","Eta of track-matched and E/p-matched Wenu EM-clusters", 15, -3., 3.));
270 m_Wenu_trackmatched_Eopmatched_phi.push_back(new TH1F("Wenu_trackmatched_Eopmatched_phi","Phi of track-matched and E/p-matched Wenu EM-clusters", 15, -3.15, 3.15));
272 m_Wenu_trackmatched_tightEopmatched_eta.push_back(new TH1F("Wenu_trackmatched_tightEopmatched_eta","Eta of track-matched and tight E/p-matched Wenu EM-clusters", 15, -3., 3.));
274 m_Wenu_trackmatched_tightEopmatched_phi.push_back(new TH1F("Wenu_trackmatched_tightEopmatched_phi","Phi of track-matched and tight E/p-matched Wenu EM-clusters", 15, -3.15, 3.15));
276
277 m_Wenu_trackmatch_eff_vs_eta.push_back(new TH1F("Wenu_trackmatch_eff_vs_eta","Track-match efficiency for Wenu EM-clusters vs. eta", 15, -3., 3.));
278 RegisterHisto(al_Wenu_mon,m_Wenu_trackmatch_eff_vs_eta[region],1);
279 m_Wenu_trackmatch_eff_vs_phi.push_back(new TH1F("Wenu_trackmatch_eff_vs_phi","Track-match efficiency for Wenu EM-clusters vs. phi", 15, -3.15, 3.15));
280 RegisterHisto(al_Wenu_mon,m_Wenu_trackmatch_eff_vs_phi[region],1);
281 m_Wenu_Eopmatch_eff_vs_eta.push_back(new TH1F("Wenu_Eopmatch_eff_vs_eta","E/p-match efficiency for Wenu EM-clusters vs. eta", 15, -3., 3.));
282 RegisterHisto(al_Wenu_mon,m_Wenu_Eopmatch_eff_vs_eta[region],1);
283 m_Wenu_Eopmatch_eff_vs_phi.push_back(new TH1F("Wenu_Eopmatch_eff_vs_phi","E/p-match efficiency for Wenu EM-clusters vs. phi", 15, -3.15, 3.15));
284 RegisterHisto(al_Wenu_mon,m_Wenu_Eopmatch_eff_vs_phi[region],1);
285 m_Wenu_tightEopmatch_eff_vs_eta.push_back(new TH1F("Wenu_tightEopmatch_eff_vs_eta","Tight E/p-match efficiency for Wenu EM-clusters vs. eta", 15, -3., 3.));
286 RegisterHisto(al_Wenu_mon,m_Wenu_tightEopmatch_eff_vs_eta[region],1);
287 m_Wenu_tightEopmatch_eff_vs_phi.push_back(new TH1F("Wenu_tightEopmatch_eff_vs_phi","Tight E/p-match efficiency for Wenu EM-clusters vs. phi", 15, -3.15, 3.15));
288 RegisterHisto(al_Wenu_mon,m_Wenu_tightEopmatch_eff_vs_phi[region],1);
289
290 m_Wenu_meanEop_vs_p.push_back(new TProfile("Wenu_meanEop_vs_p", "Mean E/p vs p for Wenu EM-clusters", 15, 0., 300.));
291 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_p[region]);
292 m_Wenu_meanEop_vs_invp.push_back(new TProfile("Wenu_meanEop_vs_invp", "Mean E/p vs 1/p for Wenu EM-clusters", 15, 0., 0.05));
293 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_invp[region]);
294 m_Wenu_meanEop_vs_E.push_back(new TProfile("Wenu_meanEop_vs_E", "Mean E/p vs E for Wenu EM-clusters", 15, 0., 300.));
295 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_E[region]);
296 m_Wenu_meanEop_vs_chargedp.push_back(new TProfile("Wenu_meanEop_vs_chargedp", "Mean E/p vs charge*p for Wenu EM-clusters", 30, -300., 300.));
297 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_chargedp[region]);
298 m_Wenu_meanEop_vs_chargedE.push_back(new TProfile("Wenu_meanEop_vs_chargedE", "Mean E/p vs charge*E for Wenu EM-clusters", 30, -300., 300.));
299 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_chargedE[region]);
300 m_Wenu_meanEop_vs_phi.push_back(new TProfile("Wenu_meanEop_vs_phi", "Mean E/p vs phi for Wenu EM-clusters", 15, -3.15, 3.15));
301 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_phi[region]);
302 m_Wenu_meanEop_vs_eta.push_back(new TProfile("Wenu_meanEop_vs_eta", "Mean E/p vs eta for Wenu EM-clusters", 15, -3., 3.));
303 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_eta[region]);
304
305 m_Wenu_meanEop_vs_p_plus.push_back(new TProfile("Wenu_meanEop_vs_p_plus", "Mean E/p vs p for pos. charged Wenu EM-clusters", 15, 0., 300.));
306 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_p_plus[region]);
307 m_Wenu_meanEop_vs_invp_plus.push_back(new TProfile("Wenu_meanEop_vs_invp_plus", "Mean E/p vs 1/p for pos. charged Wenu EM-clusters", 15, 0., 0.05));
308 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_invp_plus[region]);
309 m_Wenu_meanEop_vs_E_plus.push_back(new TProfile("Wenu_meanEop_vs_E_plus", "Mean E/p vs E for pos. charged Wenu EM-clusters", 15, 0., 300.));
310 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_E_plus[region]);
311 m_Wenu_meanEop_vs_phi_plus.push_back(new TProfile("Wenu_meanEop_vs_phi_plus", "Mean E/p vs phi for pos. charged Wenu EM-clusters", 15, -3.15, 3.15));
312 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_phi_plus[region]);
313 m_Wenu_meanEop_vs_eta_plus.push_back(new TProfile("Wenu_meanEop_vs_eta_plus", "Mean E/p vs eta for pos. charged Wenu EM-clusters", 15, -3., 3.));
314 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_eta_plus[region]);
315
316 m_Wenu_meanEop_vs_p_minus.push_back(new TProfile("Wenu_meanEop_vs_p_minus", "Mean E/p vs p for neg. charged Wenu EM-clusters", 15, 0., 300.));
317 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_p_minus[region]);
318 m_Wenu_meanEop_vs_invp_minus.push_back(new TProfile("Wenu_meanEop_vs_invp_minus", "Mean E/p vs 1/p for neg. charged Wenu EM-clusters", 15, 0., 0.05));
319 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_invp_minus[region]);
320 m_Wenu_meanEop_vs_E_minus.push_back(new TProfile("Wenu_meanEop_vs_E_minus", "Mean E/p vs E for neg. charged Wenu EM-clusters", 15, 0., 300.));
321 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_E_minus[region]);
322 m_Wenu_meanEop_vs_phi_minus.push_back(new TProfile("Wenu_meanEop_vs_phi_minus", "Mean E/p vs phi for neg. charged Wenu EM-clusters", 15, -3.15, 3.15));
323 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_phi_minus[region]);
324 m_Wenu_meanEop_vs_eta_minus.push_back(new TProfile("Wenu_meanEop_vs_eta_minus", "Mean E/p vs eta for neg. charged Wenu EM-clusters", 15, -3., 3.));
325 RegisterHisto(al_Wenu_mon,m_Wenu_meanEop_vs_eta_minus[region]);
326
327 m_Wenu_Eop_lt1_gt1.push_back(new TH1F("Wenu_Eop_lt1_gt1", "E/p below/above 1 for Wenu EM-clusters", 2, 0.5, 1.5));
328 RegisterHisto(al_Wenu_mon,m_Wenu_Eop_lt1_gt1[region]);
329
330 m_Wenu_Eopdiff_vs_p.push_back(new TProfile("Wenu_Eopdiff_vs_p", "E/p difference (pos-neg) vs p for Wenu EM-clusters", 15, 0., 300.));
331 RegisterHisto(al_Wenu_mon,m_Wenu_Eopdiff_vs_p[region]);
332 m_Wenu_Eopdiff_vs_invp.push_back(new TProfile("Wenu_Eopdiff_vs_invp", "E/p difference (pos-neg) vs 1/p for Wenu EM-clusters", 15, 0., 0.05));
333 RegisterHisto(al_Wenu_mon,m_Wenu_Eopdiff_vs_invp[region]);
334 m_Wenu_Eopdiff_vs_E.push_back(new TProfile("Wenu_Eopdiff_vs_E", "E/p difference (pos-neg) vs E for Wenu EM-clusters", 15, 0., 300.));
335 RegisterHisto(al_Wenu_mon,m_Wenu_Eopdiff_vs_E[region]);
336 m_Wenu_Eopdiff_vs_phi.push_back(new TProfile("Wenu_Eopdiff_vs_phi", "E/p difference (pos-neg) vs phi for Wenu EM-clusters", 15, -3.15, 3.15));
337 RegisterHisto(al_Wenu_mon,m_Wenu_Eopdiff_vs_phi[region]);
338 m_Wenu_Eopdiff_vs_eta.push_back(new TProfile("Wenu_Eopdiff_vs_eta", "E/p difference (pos-neg) vs eta for Wenu EM-clusters", 15, -3., 3.));
339 RegisterHisto(al_Wenu_mon,m_Wenu_Eopdiff_vs_eta[region]);
340
341 m_Wenu_Eop_lt1_vs_eta.push_back(new TH1F("Wenu_Eop_lt1_vs_eta","Eta of Wenu EM-clusters with E/p < 1 (not incl. small E/p)", 15, -3., 3.));
342 RegisterHisto(al_Wenu_mon,m_Wenu_Eop_lt1_vs_eta[region]);
343 m_Wenu_Eop_lt1_vs_phi.push_back(new TH1F("Wenu_Eop_lt1_vs_phi","Phi of Wenu EM-clusters with E/p < 1 (not incl. small E/p)", 15, -3.15, 3.15));
344 RegisterHisto(al_Wenu_mon,m_Wenu_Eop_lt1_vs_phi[region]);
345 m_Wenu_Eop_gt1_vs_eta.push_back(new TH1F("Wenu_Eop_gt1_vs_eta","Eta of Wenu EM-clusters with E/p < 1 (not incl. small E/p)", 15, -3., 3.));
346 RegisterHisto(al_Wenu_mon,m_Wenu_Eop_gt1_vs_eta[region]);
347 m_Wenu_Eop_gt1_vs_phi.push_back(new TH1F("Wenu_Eop_gt1_vs_phi","Phi of Wenu EM-clusters with E/p < 1 (not incl. small E/p)", 15, -3.15, 3.15));
348 RegisterHisto(al_Wenu_mon,m_Wenu_Eop_gt1_vs_phi[region]);
349 m_Wenu_frac_Eop_lt1_vs_eta.push_back(new TH1F("Wenu_frac_Eop_lt1_vs_eta","Fraction of Wenu EM-clusters with E/p < 1 (not incl. small E/p) vs Eta", 15, -3., 3.));
350 RegisterHisto(al_Wenu_mon,m_Wenu_frac_Eop_lt1_vs_eta[region],1);
351 m_Wenu_frac_Eop_lt1_vs_phi.push_back(new TH1F("Wenu_frac_Eop_lt1_vs_phi","Fraction of Wenu EM-clusters with E/p < 1 (not incl. small E/p) vs Phi", 15, -3.15, 3.15));
352 RegisterHisto(al_Wenu_mon,m_Wenu_frac_Eop_lt1_vs_phi[region],1);
353
354 m_Wenu_Eop_05_25.push_back(new TH1F("Wenu_Eop_05_25","Number of Wenu events with 0.5 < E/p 2.5", 1, 0., 1.));
355 RegisterHisto(al_Wenu_mon,m_Wenu_Eop_05_25[region]);
356 m_Wenu_Eop_15_25.push_back(new TH1F("Wenu_Eop_15_25","Number of Wenu events with 1.5 < E/p 2.5", 1, 0., 1.));
357 RegisterHisto(al_Wenu_mon,m_Wenu_Eop_15_25[region]);
358 m_Wenu_frac_Eop_05_25_15_25.push_back(new TH1F("Wenu_frac_Eop_05_25_15_25","Fraction of Wenu EM-clusters with 1.5 < E/p < 2.5 and 0.5 < E/p < 2.5", 1, 0., 1.));
359 RegisterHisto(al_Wenu_mon,m_Wenu_frac_Eop_05_25_15_25[region],1);
360 }
361
363 }
364 return StatusCode::SUCCESS;
365}
366
367void IDPerfMonWenu::RegisterHisto(MonGroup& mon, TH1* histo, bool doSumw2) {
368 if (doSumw2) histo->Sumw2();
369 StatusCode sc = mon.regHist(histo);
370 if (sc.isFailure() ) {
371 ATH_MSG_DEBUG( "Cannot book TH1 Histogram:" );
372 }
373}
374
375void IDPerfMonWenu::RegisterHisto(MonGroup& mon, TProfile* histo) {
376 if (mon.regHist(histo).isFailure() ) {
377 ATH_MSG_DEBUG( "Cannot book TProfile Histogram:" );
378 }
379}
380
381void IDPerfMonWenu::RegisterHisto(MonGroup& mon, TH2* histo, bool doSumw2) {
382 if (doSumw2) histo->Sumw2();
383 if (mon.regHist(histo).isFailure() ) {
384 ATH_MSG_WARNING( "Cannot book TH2 Histogram:" );
385 }
386}
387
388StatusCode IDPerfMonWenu::fillHistograms(const EventContext& /*ctx*/)
389{
390 int nevents = (int) m_Nevents->GetEntries();
391 const bool firstEvent{nevents == 1};
392 // get electron container from storegate
393 auto formErrorMessage = [] (const std::string & contName)->std::string {
394 return std::string(std::string("No Collection with name ") + contName + std::string(" found in StoreGate"));
395 };
397
398 if (not electrons){
399 const std::string & errMsg=formErrorMessage(m_electronsName);
400 if (firstEvent) ATH_MSG_WARNING( errMsg );
401 else ATH_MSG_DEBUG(errMsg);
402 return StatusCode::RECOVERABLE;
403 }
404 // get photon container from storegate
405 const xAOD::PhotonContainer* photons = getCollectionWithCheck<xAOD::PhotonContainer>(evtStore(),m_photonsName);
406 if (not photons){
407 const std::string & errMsg = formErrorMessage(m_photonsName);
408 if (firstEvent) ATH_MSG_WARNING( errMsg );
409 else ATH_MSG_DEBUG(errMsg);
410 return StatusCode::RECOVERABLE;
411 }
412 // get emcluster container from storegate
413 const xAOD::CaloClusterContainer* emclusters = getCollectionWithCheck<xAOD::CaloClusterContainer>(evtStore(),m_emclustersName);
414 if (not emclusters){
415 const std::string & errMsg = formErrorMessage(m_emclustersName);
416 if (firstEvent) ATH_MSG_WARNING( errMsg );
417 else ATH_MSG_DEBUG(errMsg);
418 return StatusCode::RECOVERABLE;
419 }
420 // get track container from storegate
421 const xAOD::TrackParticleContainer* tracks = getCollectionWithCheck<xAOD::TrackParticleContainer>(evtStore(),m_tracksName);
422 if (not tracks){
423 const std::string & errMsg = formErrorMessage(m_tracksName);
424 if (firstEvent) ATH_MSG_WARNING( errMsg );
425 else ATH_MSG_DEBUG(errMsg);
426 return StatusCode::RECOVERABLE;
427 }
428 // get met container from storegate
429 const xAOD::MissingETContainer* final_met = getCollectionWithCheck<xAOD::MissingETContainer>(evtStore(),m_metName);
430 if (not final_met){
431 const std::string & errMsg = formErrorMessage(m_metName);
432 if (firstEvent) ATH_MSG_WARNING( errMsg );
433 else ATH_MSG_DEBUG(errMsg);
434 return StatusCode::RECOVERABLE;
435 }
436 m_Nevents->Fill(0.);
437 // ******************
438 // Get the missing ET
439 // ******************
440 const xAOD::MissingET *MET;
441 MET = (*final_met)[m_metRefFinalName];
442 double met = MET->met();
443 msg(MSG::DEBUG) << "MET = " << met << endmsg;
444 // *******************
445 // Look at EM clusters
446 // *******************
447 const xAOD::CaloCluster* LeadingEMcluster = getLeadingEMcluster(photons, electrons);
448 const xAOD::CaloCluster* SecondLeadingEMcluster = getLeadingEMcluster(photons, electrons, LeadingEMcluster);
449 if (LeadingEMcluster) {
450 int leading_eta_region = etaRegion(LeadingEMcluster->eta());
451 double leading_dPhi = electronTrackMatchEta(tracks,LeadingEMcluster);
452 double leading_dEta = electronTrackMatchPhi(tracks,LeadingEMcluster);
453 const xAOD::TrackParticle* track_leading_emcluster = electronTrackMatch(tracks,LeadingEMcluster);
454 int selected = isWenu(LeadingEMcluster, SecondLeadingEMcluster, met);
455 if (selected == 0) {
456 // *********************
457 // Fill event histograms
458 // *********************
459 m_Wenu_met_sel->Fill(met/Gaudi::Units::GeV);
460 m_Wenu_clus_pt->Fill(LeadingEMcluster->pt()/Gaudi::Units::GeV);
461 double cluster_met_transmass = TransMass(LeadingEMcluster,MET);
462 if (cluster_met_transmass > 0.) m_Wenu_transmass_sel->Fill(cluster_met_transmass);
463 double track_met_transmass = 0.;
464 if (track_leading_emcluster ) {
465 track_met_transmass = TransMass(track_leading_emcluster,MET);
466 if (track_met_transmass > 0.) m_Wenu_trk_transmass_sel->Fill(track_met_transmass);
467 }
468 // ***********************
469 // Fill cluster histograms
470 // ***********************
471 FillHistosPerCluster(LeadingEMcluster, track_leading_emcluster, leading_eta_region, leading_dEta, leading_dPhi);
472 FillHistosPerCluster(LeadingEMcluster, track_leading_emcluster, incl, leading_dEta, leading_dPhi);
473 }
474 }
475 return StatusCode::SUCCESS;
476}
477
478void IDPerfMonWenu::makeEffHisto(TH1F* h_num, TH1F* h_denom, TH1F* h_eff) {
479 h_eff->Divide(h_num,h_denom,1.,1.,"B");
480}
481
483{
484 if( endOfRunFlag() ) {
485 // PostProcess Wenu histograms
486 for (int region=0; region!=1; ++region) {
493 // commented out for some reason?
494 m_Wenu_Eopdiff[region]->Add(m_Wenu_Eop_plus[region],m_Wenu_Eop_minus[region],1.,-1);
500 //
504 }
505 }
506 return StatusCode::SUCCESS;
507}
508
509
511 const xAOD::CaloCluster* leading_emcluster{nullptr};
512 float max_pt = 0.;
513 for (const auto cl: *clusters) {
514 if (cl == omitCluster) continue;
515 double deltaR = std::sqrt(std::pow(std::abs(cl->phi() - omitCluster->phi()),2) + std::pow(std::abs(cl->eta() - omitCluster->eta()),2));
516 if(deltaR < 0.005) continue;
517 if (cl->pt()/Gaudi::Units::GeV < 10.) continue;
518 if (cl->pt() > max_pt) {
519 leading_emcluster = cl;
520 max_pt = cl->pt();
521 }
522 }
523 return leading_emcluster;
524}
525
527 const xAOD::CaloCluster* leading_emcluster = nullptr;
528 bool LHSel;
529 float max_pt = 0.;
530 for (const auto em: *electrons) {
531 // check ID
532 if(m_doIDCuts){
533 LHSel = false;
534 LHSel = (bool) m_LHTool2015->accept(em);
535 if(!LHSel) continue;
536 ATH_MSG_DEBUG("Electron passes " << m_electronIDLevel << " likelihood selection");
537 }
538 const xAOD::CaloCluster* cl = em->caloCluster();
539 if (cl == omitCluster) continue;
540 if (cl->pt()/Gaudi::Units::GeV < 10.) continue;
541 if (cl->pt() > max_pt) {
542 leading_emcluster = cl;
543 max_pt = cl->pt();
544 }
545 }
546 return leading_emcluster;
547
548}
549
550const xAOD::TrackParticle* IDPerfMonWenu::electronTrackMatch(const xAOD::TrackParticleContainer* tracks, const xAOD::CaloCluster* cluster, double dEta, double dPhi) const {
551 const xAOD::TrackParticle* matched_track = nullptr;
552 double min_dR = 1.0e+20;
553 for (const auto track: *tracks) {
554 double deta = cluster->eta()-track->eta();
555 double dphi = cluster->phi()-track->phi();
556 double dr = std::sqrt(deta*deta + dphi*dphi);
557 if (dr < min_dR && std::abs(deta) < dEta && std::abs(dphi) < dPhi) {
558 min_dR = dr;
559 matched_track = track;
560 }
561 }
562 return matched_track;
563}
564
565double IDPerfMonWenu::electronTrackMatchEta(const xAOD::TrackParticleContainer* tracks, const xAOD::CaloCluster* cluster, double dEta) const {
566 const xAOD::TrackParticle* matched_track = nullptr;
567 double min_dEta = 1.0e+20;
568 for (const auto track: *tracks) {
569 double deta = std::abs(cluster->eta()-track->eta());
570 if (deta < min_dEta && deta < dEta) {
571 min_dEta = deta;
572 matched_track = track;
573 }
574 }
575 double dPhi = 1.0e+20;
576 if (matched_track != nullptr) dPhi = signedDeltaPhi(cluster->phi(),matched_track->phi());
577 return dPhi;
578}
579
580double IDPerfMonWenu::electronTrackMatchPhi(const xAOD::TrackParticleContainer* tracks, const xAOD::CaloCluster* cluster, double dPhi) const {
581 const xAOD::TrackParticle* matched_track = nullptr;
582 double min_dPhi = 1.0e+20;
583 for (const auto track : *tracks) {
584 double dphi = std::abs(signedDeltaPhi(cluster->phi(),track->phi()));
585 if (dphi < min_dPhi && dphi < dPhi) {
586 min_dPhi = dphi;
587 matched_track = track;
588 }
589 }
590 double dEta = 1.0e+20;
591 if (matched_track != nullptr) dEta = cluster->eta()-matched_track->eta();
592 return dEta;
593
594}
595
596int IDPerfMonWenu::isWenu(const xAOD::CaloCluster* em, const xAOD::CaloCluster* em2, double met) const {
597 int selected = 2;
598 if(em->pt()/Gaudi::Units::GeV > 25.) --selected;
599 if(met/Gaudi::Units::GeV > 20.) --selected; // was at 0 for some reason?
600 if(!m_rejectSecondCluster) return selected;
601 // else check 2nd EM cluster veto
602 if(em2 != nullptr){
603 if(em2->pt()/Gaudi::Units::GeV > 25.){
604 ATH_MSG_DEBUG("Event rejected due to second EM cluster w/ pT > 25 GeV");
605 selected++;
606 }
607 }
608 return selected;
609}
610
611double IDPerfMonWenu::InvMass(const xAOD::CaloCluster* EM1, const xAOD::CaloCluster* EM2) const {
612 if (EM1 == nullptr || EM2 == nullptr) return -99.;
613 double invmass = 0.;
614 if (EM1->pt() != 0 && EM2->pt() != 0.) {
615 TLorentzVector particle1;
616 TLorentzVector particle2;
617 particle1.SetPtEtaPhiE(EM1->pt()/Gaudi::Units::GeV,EM1->eta(),EM1->phi(),EM1->e()/Gaudi::Units::GeV);
618 particle2.SetPtEtaPhiE(EM2->pt()/Gaudi::Units::GeV,EM2->eta(),EM2->phi(),EM2->e()/Gaudi::Units::GeV);
619 invmass = (particle1+particle2).Mag();
620 }
621 return invmass;
622}
623
624double IDPerfMonWenu::InvMass(const xAOD::TrackParticle* trk1, const xAOD::TrackParticle* trk2) const {
625 if (trk1 == nullptr || trk2 == nullptr) return -99.;
626 double invmass = 0.;
627 if (trk1->pt() != 0 && trk2->pt() != 0.) {
628 TLorentzVector particle1;
629 TLorentzVector particle2;
630 particle1.SetPtEtaPhiE(trk1->pt()/Gaudi::Units::GeV,trk1->eta(),trk1->phi(),trk1->e()/Gaudi::Units::GeV);
631 particle2.SetPtEtaPhiE(trk2->pt()/Gaudi::Units::GeV,trk2->eta(),trk2->phi(),trk2->e()/Gaudi::Units::GeV);
632 invmass = (particle1+particle2).Mag();
633 }
634 return invmass;
635}
636
638 if (EM == nullptr || met == nullptr) return -99.;
639 double transmass = 0.;
640 float dphi = signedDeltaPhi(EM->phi(),met->phi());
641 transmass = std::sqrt(2.*EM->et()*met->met()*(1.-std::cos(dphi)));
642 return transmass/Gaudi::Units::GeV;
643
644}
645
646double IDPerfMonWenu::TransMass(const xAOD::TrackParticle* track, const xAOD::MissingET* met) const {
647 if (track == nullptr || met == nullptr) return -99.;
648 double transmass = 0.;
649 float dphi = signedDeltaPhi(track->phi(),met->phi());
650 transmass = std::sqrt(2.*(track->p4().Et()/Gaudi::Units::GeV)*(met->met()/Gaudi::Units::GeV)*(1.-std::cos(dphi)));
651 return transmass;
652}
653
654double IDPerfMonWenu::deltaR(const xAOD::CaloCluster* cluster, const xAOD::TrackParticle* track) const {
655 double dr =-999.;
656 if (cluster == nullptr || track == nullptr) return dr;
657 double deta = cluster->eta()-track->eta();
658 double dphi = cluster->phi()-track->phi();
659 if(std::abs(dphi) > M_PI) dphi = 2.*M_PI-std::abs(dphi);
660 dr = std::sqrt(deta*deta + dphi*dphi);
661 return dr;
662
663}
664
665double IDPerfMonWenu::signedDeltaPhi(double phi1, double phi2) const {
666 double phia=phi1;
667 if(phi1>Gaudi::Units::pi) phia=phi1-2.*Gaudi::Units::pi;
668 double phib=phi2;
669 if(phi2>Gaudi::Units::pi) phib=phi2-2.*Gaudi::Units::pi;
670 double dphi=phia-phib;
671 if(dphi>Gaudi::Units::pi) dphi-=2.*Gaudi::Units::pi;
672 if(dphi<-Gaudi::Units::pi) dphi+=2.*Gaudi::Units::pi;
673 return dphi;
674}
675
677 int region = -99;
678 if (std::abs(eta) <= 1.) region = barrel;
679 else if (eta > 1.) region = eca; // eca
680 else if (eta < -1.) region = ecc; // ecc
681 return region;
682
683}
684
685void IDPerfMonWenu::FillHistosPerCluster(const xAOD::CaloCluster* cluster, const xAOD::TrackParticle* track, int region, float dEta, float dPhi) {
686 if (not cluster) return;
687 if (region<0){
688 throw std::out_of_range("Region is negative in IDPerfMonWenu::FillHistosPerCluster");
689 }
690 // THERE IS A CLUSTER
691 if (region == incl) { // inclusive only
692 m_Wenu_eta[region]->Fill(cluster->eta());
693 m_Wenu_phi[region]->Fill(cluster->phi());
694 // match in eta and phi separately and make dEta and dPhi plots
695 if (dEta < 1.0e+20) {
696 m_Wenu_deta[region]->Fill(dEta);
697 if (std::abs(dEta) < 0.05) { // calculate mean only for those in matching window
698 m_Wenu_deta_vs_eta[region]->Fill(cluster->eta(),dEta);
699 m_Wenu_deta_vs_phi[region]->Fill(cluster->phi(),dEta);
700 m_Wenu_absdeta_vs_eta[region]->Fill(cluster->eta(),std::abs(dEta));
701 m_Wenu_absdeta_vs_phi[region]->Fill(cluster->phi(),std::abs(dEta));
702 }
703 }
704 if (dPhi < 1.0e+20) {
705 m_Wenu_dphi[region]->Fill(dPhi);
706 if (std::abs(dPhi) < 0.1) { // calculate mean only for those in matching window
707 m_Wenu_dphi_vs_eta[region]->Fill(cluster->eta(),dPhi);
708 m_Wenu_dphi_vs_phi[region]->Fill(cluster->phi(),dPhi);
709 m_Wenu_absdphi_vs_eta[region]->Fill(cluster->eta(),std::abs(dPhi));
710 m_Wenu_absdphi_vs_phi[region]->Fill(cluster->phi(),std::abs(dPhi));
711 }
712 }
713
714 } // end inclusive only
715
716 if (track == nullptr) return;
717 // TRACK-MATCHED
718 float eoverp = 0.;
719 float track_p = track->pt()*std::cosh(track->eta());
720 if (track_p != 0.) eoverp = cluster->e()/track_p;
721 m_Wenu_Eop[region]->Fill(eoverp);
722 if (track->charge() == 1.) {
723 m_Wenu_Eop_plus[region]->Fill(eoverp);
724 }
725 else if (track->charge() == -1.) {
726 m_Wenu_Eop_minus[region]->Fill(eoverp);
727 }
728 if (region == incl) { // inclusive only
729 auto safeInverseMom = [](float p){
730 if (p == 0.) return 10e10; //arbitrary very large number
731 return 1./(p/Gaudi::Units::GeV);
732 };
733 m_Wenu_trackmatched_eta[region]->Fill(cluster->eta());
734 m_Wenu_trackmatched_phi[region]->Fill(cluster->phi());
735 if (eoverp > m_eoverp_tight_min && eoverp < m_eoverp_tight_max) {
736 m_Wenu_meanEop_vs_p[region]->Fill(track_p/Gaudi::Units::GeV,eoverp);
737 m_Wenu_meanEop_vs_invp[region]->Fill(safeInverseMom(track_p),eoverp);
738 m_Wenu_meanEop_vs_E[region]->Fill(cluster->e()/Gaudi::Units::GeV,eoverp);
739 m_Wenu_meanEop_vs_chargedp[region]->Fill(double(track->charge())*track_p/Gaudi::Units::GeV,eoverp);
740 m_Wenu_meanEop_vs_chargedE[region]->Fill(double(track->charge())*cluster->e()/Gaudi::Units::GeV,eoverp);
741 m_Wenu_meanEop_vs_phi[region]->Fill(track->phi(),eoverp);
742 m_Wenu_meanEop_vs_eta[region]->Fill(track->eta(),eoverp);
743 }
744 if (track->charge() == 1.) {
745 if (eoverp > m_eoverp_tight_min && eoverp < m_eoverp_tight_max) {
746 m_Wenu_meanEop_vs_p_plus[region]->Fill(track_p/Gaudi::Units::GeV,eoverp);
747 m_Wenu_meanEop_vs_invp_plus[region]->Fill(safeInverseMom(track_p),eoverp);
748 m_Wenu_meanEop_vs_E_plus[region]->Fill(cluster->e()/Gaudi::Units::GeV,eoverp);
749 m_Wenu_meanEop_vs_phi_plus[region]->Fill(track->phi(),eoverp);
750 m_Wenu_meanEop_vs_eta_plus[region]->Fill(track->eta(),eoverp);
751 }
752 }
753 else if (track->charge() == -1.) {
754 if (eoverp > m_eoverp_tight_min && eoverp < m_eoverp_tight_max) {
755 m_Wenu_meanEop_vs_p_minus[region]->Fill(track_p/Gaudi::Units::GeV,eoverp);
756 m_Wenu_meanEop_vs_invp_minus[region]->Fill(safeInverseMom(track_p),eoverp);
757 m_Wenu_meanEop_vs_E_minus[region]->Fill(cluster->e()/Gaudi::Units::GeV,eoverp);
758 m_Wenu_meanEop_vs_phi_minus[region]->Fill(track->phi(),eoverp);
759 m_Wenu_meanEop_vs_eta_minus[region]->Fill(track->eta(),eoverp);
760 }
761 }
762 if (eoverp < m_eoverp_standard_max && eoverp > m_eoverp_standard_min) {
763 m_Wenu_trackmatched_Eopmatched_eta[region]->Fill(cluster->eta());
764 m_Wenu_trackmatched_Eopmatched_phi[region]->Fill(cluster->phi());
765 }
766 if (eoverp < m_eoverp_tight_max && eoverp > m_eoverp_tight_min) {
767 m_Wenu_trackmatched_tightEopmatched_eta[region]->Fill(cluster->eta());
768 m_Wenu_trackmatched_tightEopmatched_phi[region]->Fill(cluster->phi());
769 }
770 if (eoverp > m_eoverp_tight_min && eoverp < 1.) {
771 m_Wenu_Eop_lt1_vs_eta[region]->Fill(cluster->eta());
772 m_Wenu_Eop_lt1_vs_phi[region]->Fill(cluster->phi());
773 m_Wenu_Eop_lt1_gt1[region]->Fill(0.75);
774 }
775 else if (eoverp > 1. && eoverp < m_eoverp_tight_max) {
776 m_Wenu_Eop_gt1_vs_eta[region]->Fill(cluster->eta());
777 m_Wenu_Eop_gt1_vs_phi[region]->Fill(cluster->phi());
778 m_Wenu_Eop_lt1_gt1[region]->Fill(1.25);
779 }
780 if (eoverp > 0.5 && eoverp < 2.5) m_Wenu_Eop_05_25[region]->Fill(0.5);
781 if (eoverp > 1.5 && eoverp < 2.5) m_Wenu_Eop_15_25[region]->Fill(0.5);
782
783 } // end inclusive only
784
785}
#define M_PI
Scalar eta() const
pseudorapidity method
#define endmsg
#define ATH_MSG_DEBUG(x,...)
#define ATH_MSG_WARNING(x,...)
#define ATH_MSG_INFO(x,...)
static Double_t sc
static const Attributes_t empty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
ServiceHandle< StoreGateSvc > & evtStore()
static Environment_t environment()
Returns the running environment of the monitoring application to help ManagedMonitorToolBase objects ...
virtual ~IDPerfMonWenu()
TH1F * m_Wenu_transmass_sel
double m_eoverp_tight_max
std::vector< TProfile * > m_Wenu_meanEop_vs_chargedE
void makeEffHisto(TH1F *h_num, TH1F *h_denom, TH1F *h_eff)
std::vector< TH1F * > m_Wenu_phi
TH1F * m_Wenu_trk_transmass_sel
std::vector< TH1F * > m_Wenu_frac_Eop_lt1_vs_eta
std::string m_photonsName
std::vector< TProfile * > m_Wenu_Eopdiff_vs_E
std::vector< TH1F * > m_Wenu_tightEopmatch_eff_vs_eta
std::vector< TProfile * > m_Wenu_meanEop_vs_phi_minus
std::string m_metRefFinalName
std::vector< TH1F * > m_Wenu_frac_Eop_lt1_vs_phi
std::vector< TProfile * > m_Wenu_dphi_vs_phi
std::vector< TH1F * > m_Wenu_trackmatch_eff_vs_eta
TH1F * m_Wenu_met_sel
std::vector< TProfile * > m_Wenu_meanEop_vs_phi
std::vector< TProfile * > m_Wenu_Eopdiff_vs_p
std::vector< TProfile * > m_Wenu_meanEop_vs_chargedp
std::vector< TH1F * > m_Wenu_trackmatched_eta
std::vector< TProfile * > m_Wenu_meanEop_vs_p_minus
std::vector< TProfile * > m_Wenu_meanEop_vs_invp_plus
std::vector< TProfile * > m_Wenu_deta_vs_phi
std::vector< TH1F * > m_Wenu_Eop_gt1_vs_phi
std::vector< TH1F * > m_Wenu_Eop_plus
std::vector< TH1F * > m_Wenu_trackmatched_tightEopmatched_eta
std::vector< TProfile * > m_Wenu_Eopdiff_vs_invp
int etaRegion(double eta)
double signedDeltaPhi(double phi1, double phi2) const
std::vector< TProfile * > m_Wenu_meanEop_vs_phi_plus
std::string m_electronsName
std::vector< TH1F * > m_Wenu_Eopdiff
std::string m_metName
double electronTrackMatchPhi(const xAOD::TrackParticleContainer *tracks, const xAOD::CaloCluster *cluster, double dPhi=0.1) const
std::vector< TH1F * > m_Wenu_Eopmatch_eff_vs_eta
IDPerfMonWenu(const std::string &type, const std::string &name, const IInterface *parent)
std::vector< TH1F * > m_Wenu_deta
std::vector< TH1F * > m_Wenu_tightEopmatch_eff_vs_phi
TH1F * m_Wenu_trk_transmass_sel_scaled
double electronTrackMatchEta(const xAOD::TrackParticleContainer *tracks, const xAOD::CaloCluster *cluster, double dEta=0.05) const
std::vector< TH1F * > m_Wenu_Eop_gt1_vs_eta
double m_eoverp_standard_max
double InvMass(const xAOD::CaloCluster *EM1, const xAOD::CaloCluster *EM2) const
std::vector< TProfile * > m_Wenu_meanEop_vs_p
const xAOD::TrackParticle * electronTrackMatch(const xAOD::TrackParticleContainer *tracks, const xAOD::CaloCluster *cluster, double dEta=0.05, double dPhi=0.1) const
std::string m_triggerChainName
double m_eoverp_standard_min
virtual StatusCode bookHistograms()
An inheriting class should either override this function or bookHists().
std::vector< TProfile * > m_Wenu_dphi_vs_eta
std::vector< TProfile * > m_Wenu_meanEop_vs_eta_plus
std::vector< TProfile * > m_Wenu_meanEop_vs_E
std::vector< TProfile * > m_Wenu_absdphi_vs_eta
std::vector< TProfile * > m_Wenu_meanEop_vs_invp_minus
TH1F * m_Wenu_clus_pt
std::unique_ptr< AsgElectronLikelihoodTool > m_LHTool2015
void RegisterHisto(MonGroup &mon, TH1 *histo, bool doSumw2=false)
std::vector< TH1F * > m_Wenu_Eop_05_25
double m_eoverp_tight_min
std::vector< TProfile * > m_Wenu_deta_vs_eta
std::vector< TProfile * > m_Wenu_absdphi_vs_phi
std::string m_VxPrimContainerName
virtual StatusCode procHistograms()
An inheriting class should either override this function or finalHists().
double TransMass(const xAOD::CaloCluster *EM, const xAOD::MissingET *met) const
std::string m_electronIDLevel
virtual StatusCode fillHistograms(const EventContext &ctx)
An inheriting class should either override this function or fillHists().
const xAOD::CaloCluster * getLeadingEMcluster(const xAOD::CaloClusterContainer *clusters, const xAOD::CaloCluster *omitCluster=0) const
std::vector< TProfile * > m_Wenu_meanEop_vs_invp
std::vector< TProfile * > m_Wenu_Eopdiff_vs_phi
std::vector< TProfile * > m_Wenu_absdeta_vs_phi
double deltaR(const xAOD::CaloCluster *cluster, const xAOD::TrackParticle *track) const
std::vector< TH1F * > m_Wenu_trackmatched_Eopmatched_eta
void FillHistosPerCluster(const xAOD::CaloCluster *cluster, const xAOD::TrackParticle *track, int region, float dEta, float dPhi)
std::vector< std::string > m_region_strings
std::vector< TH1F * > m_Wenu_trackmatched_phi
std::vector< TH1F * > m_Wenu_trackmatch_eff_vs_phi
virtual StatusCode initialize()
std::vector< TH1F * > m_Wenu_dphi
std::vector< TH1F * > m_Wenu_eta
std::vector< TH1F * > m_Wenu_Eop_lt1_vs_eta
std::string m_emclustersName
std::string m_tracksName
std::vector< TProfile * > m_Wenu_meanEop_vs_E_minus
std::vector< TProfile * > m_Wenu_meanEop_vs_eta
std::vector< TH1F * > m_Wenu_trackmatched_tightEopmatched_phi
std::vector< TProfile * > m_Wenu_meanEop_vs_E_plus
std::vector< TProfile * > m_Wenu_meanEop_vs_p_plus
std::vector< TProfile * > m_Wenu_absdeta_vs_eta
std::vector< TH1F * > m_Wenu_trackmatched_Eopmatched_phi
bool m_rejectSecondCluster
std::vector< TH1F * > m_Wenu_Eop_minus
std::vector< TH1F * > m_Wenu_Eop_lt1_vs_phi
std::vector< TProfile * > m_Wenu_meanEop_vs_eta_minus
std::vector< TH1F * > m_Wenu_Eopmatch_eff_vs_phi
std::vector< TH1F * > m_Wenu_frac_Eop_05_25_15_25
std::vector< TH1F * > m_Wenu_Eop
int isWenu(const xAOD::CaloCluster *em, const xAOD::CaloCluster *em2, double met) const
std::vector< TProfile * > m_Wenu_Eopdiff_vs_eta
std::vector< TH1F * > m_Wenu_Eop_15_25
std::vector< TH1F * > m_Wenu_Eop_lt1_gt1
A container of information describing a monitoring object.
ManagedMonitorToolBase(const std::string &type, const std::string &name, const IInterface *parent)
static const T * getContainer(CONTAINERS eContainer)
virtual double pt() const
The transverse momentum ( ) of the particle (negative for negative-energy clusters).
virtual double eta() const
The pseudorapidity ( ) of the particle.
virtual double e() const
The total energy of the particle.
virtual double phi() const
The azimuthal angle ( ) of the particle.
virtual double phi() const override final
The azimuthal angle ( ) of the particle (has range to .).
virtual double pt() const override final
The transverse momentum ( ) of the particle.
virtual double eta() const override final
The pseudorapidity ( ) of the particle.
virtual double e() const override final
The total energy of the particle.
Definition MET.py:1
const SG::AuxVectorData * container() const
Return the container holding this element.
PhotonContainer_v1 PhotonContainer
Definition of the current "photon container version".
ElectronContainer_v1 ElectronContainer
Definition of the current "electron container version".
MissingET_v1 MissingET
Version control by type defintion.
Definition MissingET.h:15
CaloCluster_v1 CaloCluster
Define the latest version of the calorimeter cluster class.
TrackParticle_v1 TrackParticle
Reference the current persistent version:
MissingETContainer_v1 MissingETContainer
TrackParticleContainer_v1 TrackParticleContainer
Definition of the current "TrackParticle container version".
CaloClusterContainer_v1 CaloClusterContainer
Define the latest version of the calorimeter cluster container.
MsgStream & msg
Definition testRead.cxx:32