31 #include "CLHEP/Units/GlobalPhysicalConstants.h"
88 verbosity_ =
pset.getUntrackedParameter<
int>(
"Verbosity");
90 fastSim_ =
pset.getParameter<
bool>(
"fastSim");
91 isRunCentrally_ =
pset.getParameter<
bool>(
"isRunCentrally");
93 photonCollectionProducer_ =
pset.getParameter<
std::string>(
"phoProducer");
95 photonCollectionToken_ =
96 consumes<reco::PhotonCollection>(
edm::InputTag(photonCollectionProducer_, photonCollection_));
98 token_tp_ = consumes<TrackingParticleCollection>(
pset.getParameter<
edm::InputTag>(
"label_tp"));
100 barrelEcalHits_ = consumes<EcalRecHitCollection>(
pset.getParameter<
edm::InputTag>(
"barrelEcalHits"));
101 endcapEcalHits_ = consumes<EcalRecHitCollection>(
pset.getParameter<
edm::InputTag>(
"endcapEcalHits"));
103 conversionOITrackProducer_ =
pset.getParameter<
std::string>(
"conversionOITrackProducer");
104 conversionIOTrackProducer_ =
pset.getParameter<
std::string>(
"conversionIOTrackProducer");
105 conversionOITrackPr_Token_ = consumes<edm::View<reco::Track> >(
edm::InputTag(conversionOITrackProducer_));
106 conversionIOTrackPr_Token_ = consumes<edm::View<reco::Track> >(
edm::InputTag(conversionIOTrackProducer_));
108 pfCandidates_ = consumes<reco::PFCandidateCollection>(
pset.getParameter<
edm::InputTag>(
"pfCandidates"));
109 valueMapPhoPFCandIso_ =
pset.getParameter<
std::string>(
"valueMapPhoToParticleBasedIso");
110 particleBasedIso_token =
111 consumes<edm::ValueMap<std::vector<reco::PFCandidateRef> > >(
pset.getUntrackedParameter<
edm::InputTag>(
112 "particleBasedIso",
edm::InputTag(
"particleBasedIsolation", valueMapPhoPFCandIso_)));
114 minPhoEtCut_ =
pset.getParameter<
double>(
"minPhoEtCut");
115 convTrackMinPtCut_ =
pset.getParameter<
double>(
"convTrackMinPtCut");
116 likelihoodCut_ =
pset.getParameter<
double>(
"likelihoodCut");
118 trkIsolExtRadius_ =
pset.getParameter<
double>(
"trkIsolExtR");
119 trkIsolInnRadius_ =
pset.getParameter<
double>(
"trkIsolInnR");
120 trkPtLow_ =
pset.getParameter<
double>(
"minTrackPtCut");
121 lip_ =
pset.getParameter<
double>(
"lipCut");
122 ecalIsolRadius_ =
pset.getParameter<
double>(
"ecalIsolR");
123 bcEtLow_ =
pset.getParameter<
double>(
"minBcEtCut");
124 hcalIsolExtRadius_ =
pset.getParameter<
double>(
"hcalIsolExtR");
125 hcalIsolInnRadius_ =
pset.getParameter<
double>(
"hcalIsolInnR");
126 hcalHitEtLow_ =
pset.getParameter<
double>(
"minHcalHitEtCut");
128 numOfTracksInCone_ =
pset.getParameter<
int>(
"maxNumOfTracksInCone");
129 trkPtSumCut_ =
pset.getParameter<
double>(
"trkPtSumCut");
130 ecalEtSumCut_ =
pset.getParameter<
double>(
"ecalEtSumCut");
131 hcalEtSumCut_ =
pset.getParameter<
double>(
"hcalEtSumCut");
132 dCotCutOn_ =
pset.getParameter<
bool>(
"dCotCutOn");
133 dCotCutValue_ =
pset.getParameter<
double>(
"dCotCutValue");
134 dCotHardCutValue_ =
pset.getParameter<
double>(
"dCotHardCutValue");
136 offline_pvToken_ = consumes<reco::VertexCollection>(
138 g4_simTk_Token_ = consumes<edm::SimTrackContainer>(
edm::InputTag(
"g4SimHits"));
139 g4_simVtx_Token_ = consumes<edm::SimVertexContainer>(
edm::InputTag(
"g4SimHits"));
140 famos_simTk_Token_ = consumes<edm::SimTrackContainer>(
edm::InputTag(
"fastSimProducer"));
141 famos_simVtx_Token_ = consumes<edm::SimVertexContainer>(
edm::InputTag(
"fastSimProducer"));
142 hepMC_Token_ = consumes<edm::HepMCProduct>(
edm::InputTag(
"generatorSmeared"));
143 genjets_Token_ = consumes<reco::GenJetCollection>(
edm::InputTag(
"ak4GenJets"));
145 genpartToken_ = consumes<reco::GenParticleCollection>(
edm::InputTag(
"genParticles"));
147 consumes<reco::TrackToTrackingParticleAssociator>(
edm::InputTag(
"trackAssociatorByHitsForPhotonValidation"));
153 nRecConvAssWithEcal_ = 0;
160 double resMin = parameters_.getParameter<
double>(
"resMin");
161 double resMax = parameters_.getParameter<
double>(
"resMax");
162 int resBin = parameters_.getParameter<
int>(
"resBin");
164 double eMin = parameters_.getParameter<
double>(
"eMin");
165 double eMax = parameters_.getParameter<
double>(
"eMax");
166 int eBin = parameters_.getParameter<
int>(
"eBin");
168 double etMin = parameters_.getParameter<
double>(
"etMin");
169 double etMax = parameters_.getParameter<
double>(
"etMax");
170 int etBin = parameters_.getParameter<
int>(
"etBin");
172 double etScale = parameters_.getParameter<
double>(
"etScale");
174 double etaMin = parameters_.getParameter<
double>(
"etaMin");
175 double etaMax = parameters_.getParameter<
double>(
"etaMax");
176 int etaBin = parameters_.getParameter<
int>(
"etaBin");
177 int etaBin2 = parameters_.getParameter<
int>(
"etaBin2");
179 double dEtaMin = parameters_.getParameter<
double>(
"dEtaMin");
180 double dEtaMax = parameters_.getParameter<
double>(
"dEtaMax");
181 int dEtaBin = parameters_.getParameter<
int>(
"dEtaBin");
183 double phiMin = parameters_.getParameter<
double>(
"phiMin");
184 double phiMax = parameters_.getParameter<
double>(
"phiMax");
185 int phiBin = parameters_.getParameter<
int>(
"phiBin");
187 double dPhiMin = parameters_.getParameter<
double>(
"dPhiMin");
188 double dPhiMax = parameters_.getParameter<
double>(
"dPhiMax");
189 int dPhiBin = parameters_.getParameter<
int>(
"dPhiBin");
191 double rMin = parameters_.getParameter<
double>(
"rMin");
192 double rMax = parameters_.getParameter<
double>(
"rMax");
193 int rBin = parameters_.getParameter<
int>(
"rBin");
195 double zMin = parameters_.getParameter<
double>(
"zMin");
196 double zMax = parameters_.getParameter<
double>(
"zMax");
197 int zBin = parameters_.getParameter<
int>(
"zBin");
199 double r9Min = parameters_.getParameter<
double>(
"r9Min");
200 double r9Max = parameters_.getParameter<
double>(
"r9Max");
201 int r9Bin = parameters_.getParameter<
int>(
"r9Bin");
203 double dPhiTracksMin = parameters_.getParameter<
double>(
"dPhiTracksMin");
204 double dPhiTracksMax = parameters_.getParameter<
double>(
"dPhiTracksMax");
205 int dPhiTracksBin = parameters_.getParameter<
int>(
"dPhiTracksBin");
207 double dEtaTracksMin = parameters_.getParameter<
double>(
"dEtaTracksMin");
208 double dEtaTracksMax = parameters_.getParameter<
double>(
"dEtaTracksMax");
209 int dEtaTracksBin = parameters_.getParameter<
int>(
"dEtaTracksBin");
211 double dCotTracksMin = parameters_.getParameter<
double>(
"dCotTracksMin");
212 double dCotTracksMax = parameters_.getParameter<
double>(
"dCotTracksMax");
213 int dCotTracksBin = parameters_.getParameter<
int>(
"dCotTracksBin");
215 double povereMin = parameters_.getParameter<
double>(
"povereMin");
216 double povereMax = parameters_.getParameter<
double>(
"povereMax");
217 int povereBin = parameters_.getParameter<
int>(
"povereBin");
219 double eoverpMin = parameters_.getParameter<
double>(
"eoverpMin");
220 double eoverpMax = parameters_.getParameter<
double>(
"eoverpMax");
221 int eoverpBin = parameters_.getParameter<
int>(
"eoverpBin");
223 double chi2Min = parameters_.getParameter<
double>(
"chi2Min");
224 double chi2Max = parameters_.getParameter<
double>(
"chi2Max");
226 int ggMassBin = parameters_.getParameter<
int>(
"ggMassBin");
227 double ggMassMin = parameters_.getParameter<
double>(
"ggMassMin");
228 double ggMassMax = parameters_.getParameter<
double>(
"ggMassMax");
230 double rMinForXray = parameters_.getParameter<
double>(
"rMinForXray");
231 double rMaxForXray = parameters_.getParameter<
double>(
"rMaxForXray");
232 int rBinForXray = parameters_.getParameter<
int>(
"rBinForXray");
233 double zMinForXray = parameters_.getParameter<
double>(
"zMinForXray");
234 double zMaxForXray = parameters_.getParameter<
double>(
"zMaxForXray");
235 int zBinForXray = parameters_.getParameter<
int>(
"zBinForXray");
236 int zBin2ForXray = parameters_.getParameter<
int>(
"zBin2ForXray");
245 if (!isRunCentrally_) {
246 h_nSimPho_[0] = iBooker.
book1D(histname,
"# of Sim photons per event ", 20, -0.5, 19.5);
247 histname =
"SimPhoMotherEt";
248 h_SimPhoMotherEt_[0] = iBooker.
book1D(histname,
"Sim photon Mother tranverse energy spectrum",
etBin,
etMin,
etMax);
250 histname =
"SimPhoMotherEtMatched";
251 h_SimPhoMotherEt_[1] = iBooker.
book1D(
252 histname,
"Sim photon matched by a reco Photon: Mother tranverse energy spectrum",
etBin,
etMin,
etMax);
253 h_SimPhoMotherEta_[1] = iBooker.
book1D(
254 "SimPhoMotherEtaMatched",
" Sim Photon matched by a reco Photon: Mother Eta ",
etaBin,
etaMin,
etaMax);
257 histname =
"h_SimPhoEta";
259 histname =
"h_SimPhoPhi";
261 histname =
"h_SimPhoEt";
264 histname =
"nOfSimPhotonsMatched";
265 h_nSimPho_[1] = iBooker.
book1D(histname,
"# of Sim photons matched by a reco Photon per event ", 20, -0.5, 19.5);
266 histname =
"h_MatchedSimPhoEta";
268 histname =
"h_MatchedSimPhoPhi";
270 histname =
"h_MatchedSimPhoEt";
271 h_MatchedSimPho_[2] = iBooker.
book1D(histname,
" Matching photons simulated Et",
etBin,
etMin,
etMax);
273 histname =
"h_MatchedSimPhoBadChEta";
275 histname =
"h_MatchedSimPhoBadChPhi";
277 histname =
"h_MatchedSimPhoBadChEt";
278 h_MatchedSimPhoBadCh_[2] = iBooker.
book1D(histname,
" Matching photons simulated Et",
etBin,
etMin,
etMax);
281 histname =
"nOfSimConversions";
282 if (!isRunCentrally_) {
283 h_nSimConv_[0] = iBooker.
book1D(histname,
"# of Sim conversions per event ", 20, -0.5, 19.5);
284 histname =
"nOfVisSimConversions";
285 h_nSimConv_[1] = iBooker.
book1D(histname,
"# of Sim conversions per event ", 20, -0.5, 19.5);
288 histname =
"h_AllSimConvEta";
290 histname =
"h_AllSimConvPhi";
292 histname =
"h_AllSimConvR";
293 h_AllSimConv_[2] = iBooker.
book1D(histname,
" All conversions: simulated R",
rBin,
rMin,
rMax);
294 histname =
"h_AllSimConvZ";
295 h_AllSimConv_[3] = iBooker.
book1D(histname,
" All conversions: simulated Z",
zBin,
zMin,
zMax);
296 histname =
"h_AllSimConvEt";
299 histname =
"h_VisSimConvEta";
301 histname =
"h_VisSimConvPhi";
303 histname =
"h_VisSimConvR";
304 h_VisSimConv_[2] = iBooker.
book1D(histname,
" All vis conversions: simulated R",
rBin,
rMin,
rMax);
305 histname =
"h_VisSimConvZ";
306 h_VisSimConv_[3] = iBooker.
book1D(histname,
" All vis conversions: simulated Z",
zBin,
zMin,
zMax);
307 histname =
"h_VisSimConvEt";
308 h_VisSimConv_[4] = iBooker.
book1D(histname,
" All vis conversions: simulated Et",
etBin,
etMin,
etMax);
310 histname =
"h_SimConvOneTracksEta";
311 h_SimConvOneTracks_[0] =
313 histname =
"h_SimConvOneTracksPhi";
314 h_SimConvOneTracks_[1] =
316 histname =
"h_SimConvOneTracksR";
317 h_SimConvOneTracks_[2] =
318 iBooker.
book1D(histname,
" All vis conversions with 1 reco tracks: simulated R",
rBin,
rMin,
rMax);
319 histname =
"h_SimConvOneTracksZ";
320 h_SimConvOneTracks_[3] =
321 iBooker.
book1D(histname,
" All vis conversions with 1 reco tracks: simulated Z",
zBin,
zMin,
zMax);
322 histname =
"h_SimConvOneTracksEt";
323 h_SimConvOneTracks_[4] =
324 iBooker.
book1D(histname,
" All vis conversions with 1 reco tracks: simulated Et",
etBin,
etMin,
etMax);
326 histname =
"h_SimConvTwoMTracksEta";
327 h_SimConvTwoMTracks_[0] = iBooker.
book1D(
328 histname,
" All vis conversions with 2 reco-matching tracks: simulated #eta",
etaBin2,
etaMin,
etaMax);
329 histname =
"h_SimConvTwoMTracksPhi";
330 h_SimConvTwoMTracks_[1] = iBooker.
book1D(
331 histname,
" All vis conversions with 2 reco-matching tracks: simulated #phi",
phiBin,
phiMin,
phiMax);
332 histname =
"h_SimConvTwoMTracksR";
333 h_SimConvTwoMTracks_[2] =
334 iBooker.
book1D(histname,
" All vis conversions with 2 reco-matching tracks: simulated R",
rBin,
rMin,
rMax);
335 histname =
"h_SimConvTwoMTracksZ";
336 h_SimConvTwoMTracks_[3] =
337 iBooker.
book1D(histname,
" All vis conversions with 2 reco-matching tracks: simulated Z",
zBin,
zMin,
zMax);
338 histname =
"h_SimConvTwoMTracksEt";
339 h_SimConvTwoMTracks_[4] =
340 iBooker.
book1D(histname,
" All vis conversions with 2 reco-matching tracks: simulated Et",
etBin,
etMin,
etMax);
342 histname =
"h_SimConvTwoTracksEta";
343 h_SimConvTwoTracks_[0] =
345 histname =
"h_SimConvTwoTracksPhi";
346 h_SimConvTwoTracks_[1] =
348 histname =
"h_SimConvTwoTracksR";
349 h_SimConvTwoTracks_[2] =
350 iBooker.
book1D(histname,
" All vis conversions with 2 reco tracks: simulated R",
rBin,
rMin,
rMax);
351 histname =
"h_SimConvTwoTracksZ";
352 h_SimConvTwoTracks_[3] =
353 iBooker.
book1D(histname,
" All vis conversions with 2 reco tracks: simulated Z",
zBin,
zMin,
zMax);
354 histname =
"h_SimConvTwoTracksEt";
355 h_SimConvTwoTracks_[4] =
356 iBooker.
book1D(histname,
" All vis conversions with 2 reco tracks: simulated Et",
etBin,
etMin,
etMax);
358 histname =
"h_SimConvOneMTracksEta";
359 h_SimConvOneMTracks_[0] = iBooker.
book1D(
360 histname,
" All vis conversions with 1 reco-matching tracks: simulated #eta",
etaBin2,
etaMin,
etaMax);
361 histname =
"h_SimConvOneMTracksPhi";
362 h_SimConvOneMTracks_[1] = iBooker.
book1D(
363 histname,
" All vis conversions with 1 reco-matching tracks: simulated #phi",
phiBin,
phiMin,
phiMax);
364 histname =
"h_SimConvOneMTracksR";
365 h_SimConvOneMTracks_[2] =
366 iBooker.
book1D(histname,
" All vis conversions with 1 reco-matching tracks: simulated R",
rBin,
rMin,
rMax);
367 histname =
"h_SimConvOneMTracksZ";
368 h_SimConvOneMTracks_[3] =
369 iBooker.
book1D(histname,
" All vis conversions with 1 reco-matching tracks: simulated Z",
zBin,
zMin,
zMax);
370 histname =
"h_SimConvOneMTracksEt";
371 h_SimConvOneMTracks_[4] =
372 iBooker.
book1D(histname,
" All vis conversions with 1 reco-matching tracks: simulated Et",
etBin,
etMin,
etMax);
374 histname =
"h_SimConvTwoMTracksEtaAndVtxPGT0";
375 h_SimConvTwoMTracksAndVtxPGT0_[0] = iBooker.
book1D(
376 histname,
" All vis conversions with 2 reco-matching tracks + vertex: simulated #eta",
etaBin2,
etaMin,
etaMax);
377 histname =
"h_SimConvTwoMTracksPhiAndVtxPGT0";
378 h_SimConvTwoMTracksAndVtxPGT0_[1] = iBooker.
book1D(
379 histname,
" All vis conversions with 2 reco-matching tracks + vertex: simulated #phi",
phiBin,
phiMin,
phiMax);
380 histname =
"h_SimConvTwoMTracksRAndVtxPGT0";
381 h_SimConvTwoMTracksAndVtxPGT0_[2] = iBooker.
book1D(
382 histname,
" All vis conversions with 2 reco-matching tracks + vertex: simulated R",
rBin,
rMin,
rMax);
383 histname =
"h_SimConvTwoMTracksZAndVtxPGT0";
384 h_SimConvTwoMTracksAndVtxPGT0_[3] = iBooker.
book1D(
385 histname,
" All vis conversions with 2 reco-matching tracks + vertex: simulated Z",
zBin,
zMin,
zMax);
386 histname =
"h_SimConvTwoMTracksEtAndVtxPGT0";
387 h_SimConvTwoMTracksAndVtxPGT0_[4] = iBooker.
book1D(
388 histname,
" All vis conversions with 2 reco-matching tracks + vertex: simulated Et",
etBin,
etMin,
etMax);
390 histname =
"h_SimConvTwoMTracksEtaAndVtxPGT0005";
391 h_SimConvTwoMTracksAndVtxPGT0005_[0] = iBooker.
book1D(
392 histname,
" All vis conversions with 2 reco-matching tracks + vertex: simulated #eta",
etaBin2,
etaMin,
etaMax);
393 histname =
"h_SimConvTwoMTracksPhiAndVtxPGT0005";
394 h_SimConvTwoMTracksAndVtxPGT0005_[1] = iBooker.
book1D(
395 histname,
" All vis conversions with 2 reco-matching tracks + vertex: simulated #phi",
phiBin,
phiMin,
phiMax);
396 histname =
"h_SimConvTwoMTracksRAndVtxPGT0005";
397 h_SimConvTwoMTracksAndVtxPGT0005_[2] = iBooker.
book1D(
398 histname,
" All vis conversions with 2 reco-matching tracks + vertex: simulated R",
rBin,
rMin,
rMax);
399 histname =
"h_SimConvTwoMTracksZAndVtxPGT0005";
400 h_SimConvTwoMTracksAndVtxPGT0005_[3] = iBooker.
book1D(
401 histname,
" All vis conversions with 2 reco-matching tracks + vertex: simulated Z",
zBin,
zMin,
zMax);
402 histname =
"h_SimConvTwoMTracksEtAndVtxPGT0005";
403 h_SimConvTwoMTracksAndVtxPGT0005_[4] = iBooker.
book1D(
404 histname,
" All vis conversions with 2 reco-matching tracks + vertex: simulated Et",
etBin,
etMin,
etMax);
406 if (!isRunCentrally_) {
408 h_simTkPt_ = iBooker.
book1D(
"simTkPt",
"Sim conversion tracks pt ",
etBin * 3, 0.,
etMax);
410 h_simConvVtxRvsZ_[0] = iBooker.
book2D(
"simConvVtxRvsZAll",
411 " Photon Sim conversion vtx position",
418 h_simConvVtxRvsZ_[1] = iBooker.
book2D(
"simConvVtxRvsZBarrel",
419 " Photon Sim conversion vtx position",
426 h_simConvVtxRvsZ_[2] = iBooker.
book2D(
"simConvVtxRvsZEndcap",
427 " Photon Sim conversion vtx position",
434 h_simConvVtxYvsX_ = iBooker.
book2D(
435 "simConvVtxYvsXTrkBarrel",
" Photon Sim conversion vtx position, (x,y) eta<1 ", 100, -80., 80., 100, -80., 80.);
439 histname =
"h_SimJetEta";
441 histname =
"h_SimJetPhi";
443 histname =
"h_SimJetEt";
446 histname =
"h_MatchedSimJetEta";
448 histname =
"h_MatchedSimJetPhi";
450 histname =
"h_MatchedSimJetEt";
453 histname =
"h_MatchedSimJetBadChEta";
455 histname =
"h_MatchedSimJetBadChPhi";
457 histname =
"h_MatchedSimJetBadChEt";
458 h_MatchedSimJetBadCh_[2] = iBooker.
book1D(histname,
" Matching jet simulated Et",
etBin,
etMin,
etMax);
462 histname =
"nOfPhotons";
463 h_nPho_ = iBooker.
book1D(histname,
"# of Reco photons per event ", 20, -0.5, 19.5);
474 histname =
"phoBkgE";
475 h_phoBkgE_[0] = iBooker.
book1D(histname +
"All",
" Photon Bkg Energy: All ecal ",
eBin,
eMin,
eMax);
476 h_phoBkgE_[1] = iBooker.
book1D(histname +
"Barrel",
" Photon Bkg Energy: barrel ",
eBin,
eMin,
eMax);
477 h_phoBkgE_[2] = iBooker.
book1D(histname +
"Endcap",
" Photon Bkg Energy: Endcap ",
eBin,
eMin,
eMax);
479 histname =
"phoBkgEt";
480 h_phoBkgEt_[0] = iBooker.
book1D(histname +
"All",
" Photon Bkg Transverse Energy: All ecal ",
etBin,
etMin,
etMax);
481 h_phoBkgEt_[1] = iBooker.
book1D(histname +
"Barrel",
" Photon Bkg Transverse Energy: Barrel ",
etBin,
etMin,
etMax);
482 h_phoBkgEt_[2] = iBooker.
book1D(histname +
"Endcap",
" Photon BkgTransverse Energy: Endcap ",
etBin,
etMin,
etMax);
486 h_scBkgE_[0] = iBooker.
book1D(histname +
"All",
" SC bkg Energy: All Ecal ",
eBin,
eMin,
eMax);
487 h_scBkgE_[1] = iBooker.
book1D(histname +
"Barrel",
" SC bkg Energy: Barrel ",
eBin,
eMin,
eMax);
488 h_scBkgE_[2] = iBooker.
book1D(histname +
"Endcap",
" SC bkg Energy: Endcap ",
eBin,
eMin,
eMax);
489 histname =
"scBkgEt";
490 h_scBkgEt_[0] = iBooker.
book1D(histname +
"All",
" SC bkg Et: All Ecal ",
eBin,
eMin,
eMax);
491 h_scBkgEt_[1] = iBooker.
book1D(histname +
"Barrel",
" SC bkg Et: Barrel ",
eBin,
eMin,
eMax);
492 h_scBkgEt_[2] = iBooker.
book1D(histname +
"Endcap",
" SC bkg Et: Endcap ",
eBin,
eMin,
eMax);
499 histname =
"R9VsEtaBkg";
500 if (!isRunCentrally_)
504 histname =
"R9VsEtBkg";
505 if (!isRunCentrally_)
507 iBooker.
book2D(histname +
"All",
" Bkg photons r9 vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 1.1);
510 h_r1Bkg_[0] = iBooker.
book1D(histname +
"All",
" Bkg photon e1x5/e5x5: All Ecal",
r9Bin,
r9Min,
r9Max);
511 h_r1Bkg_[1] = iBooker.
book1D(histname +
"Barrel",
" Bkg photon e1x5/e5x5: Barrel ",
r9Bin,
r9Min,
r9Max);
512 h_r1Bkg_[2] = iBooker.
book1D(histname +
"Endcap",
" Bkg photon e1x5/e5x5: Endcap ",
r9Bin,
r9Min,
r9Max);
514 histname =
"R1VsEtaBkg";
515 if (!isRunCentrally_)
516 h2_r1VsEtaBkg_ = iBooker.
book2D(
517 histname +
"All",
" Bkg photons e1x5/e5x5 vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 1.1);
518 histname =
"pR1VsEtaBkg";
519 if (!isRunCentrally_)
521 histname +
"All",
" Bkg photons e1x5/e5x5 vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 1.1);
523 histname =
"R1VsEtBkg";
524 if (!isRunCentrally_)
526 iBooker.
book2D(histname +
"All",
" Bkg photons e1x5/e5x5 vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 1.1);
527 histname =
"pR1VsEtBkg";
528 if (!isRunCentrally_)
530 histname +
"All",
" Bkg photons e2x5/e5x5 vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 1.1);
533 h_r2Bkg_[0] = iBooker.
book1D(histname +
"All",
" Bkg photon e2x5/e5x5: All Ecal",
r9Bin,
r9Min,
r9Max);
534 h_r2Bkg_[1] = iBooker.
book1D(histname +
"Barrel",
" Bkg photon e2x5/e5x5: Barrel ",
r9Bin,
r9Min,
r9Max);
535 h_r2Bkg_[2] = iBooker.
book1D(histname +
"Endcap",
" Bkg photon e2x5/e5x5: Endcap ",
r9Bin,
r9Min,
r9Max);
537 histname =
"R2VsEtaBkg";
538 if (!isRunCentrally_)
539 h2_r2VsEtaBkg_ = iBooker.
book2D(
540 histname +
"All",
" Bkg photons e2x5/e5x5 vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 1.1);
541 histname =
"pR2VsEtaBkg";
542 if (!isRunCentrally_)
544 histname +
"All",
" Bkg photons e2x5/e5x5 vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 1.1);
546 histname =
"R2VsEtBkg";
547 if (!isRunCentrally_)
549 iBooker.
book2D(histname +
"All",
" Bkg photons e2x5/e5x5 vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 1.1);
550 histname =
"pR2VsEtBkg";
551 if (!isRunCentrally_)
553 histname +
"All",
" Bkg photons e2x5/e5x5 vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 1.1);
555 histname =
"sigmaIetaIetaBkg";
556 h_sigmaIetaIetaBkg_[0] = iBooker.
book1D(histname +
"All",
"Bkg sigmaIetaIeta: All Ecal", 100, 0., 0.1);
557 h_sigmaIetaIetaBkg_[1] = iBooker.
book1D(histname +
"Barrel",
"Bkg sigmaIetaIeta: Barrel ", 100, 0., 0.05);
558 h_sigmaIetaIetaBkg_[2] = iBooker.
book1D(histname +
"Endcap",
"Bkg sigmaIetaIeta: Endcap ", 100, 0., 0.1);
560 histname =
"sigmaIetaIetaVsEtaBkg";
561 if (!isRunCentrally_)
562 h2_sigmaIetaIetaVsEtaBkg_ = iBooker.
book2D(
563 histname +
"All",
" Bkg photons sigmaIetaIeta vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 0.1);
564 histname =
"pSigmaIetaIetaVsEtaBkg";
565 if (!isRunCentrally_)
567 histname +
"All",
" Bkg photons sigmaIetaIeta vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 0.1);
569 histname =
"sigmaIetaIetaVsEtBkg";
570 if (!isRunCentrally_)
571 h2_sigmaIetaIetaVsEtBkg_[0] = iBooker.
book2D(
572 histname +
"All",
" Bkg photons sigmaIetaIeta vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 0.1);
573 if (!isRunCentrally_)
574 h2_sigmaIetaIetaVsEtBkg_[1] = iBooker.
book2D(
575 histname +
"Barrel",
" Bkg photons sigmaIetaIeta vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 0.1);
576 if (!isRunCentrally_)
577 h2_sigmaIetaIetaVsEtBkg_[2] = iBooker.
book2D(
578 histname +
"Endcap",
" Bkg photons sigmaIetaIeta vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 0.1);
580 histname =
"pSigmaIetaIetaVsEtBkg";
581 if (!isRunCentrally_)
583 histname +
"All",
" Bkg photons sigmaIetaIeta vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 0.1);
584 if (!isRunCentrally_)
586 histname +
"Barrel",
" Bkg photons sigmaIetaIeta vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 0.1);
587 if (!isRunCentrally_)
589 histname +
"Endcap",
" Bkg photons sigmaIetaIeta vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 0.1);
591 histname =
"hOverEBkg";
592 h_hOverEBkg_[0] = iBooker.
book1D(histname +
"All",
"H/E bkg: All Ecal", 100, 0., 1.);
593 h_hOverEBkg_[1] = iBooker.
book1D(histname +
"Barrel",
"H/E bkg: Barrel ", 100, 0., 1.);
594 h_hOverEBkg_[2] = iBooker.
book1D(histname +
"Endcap",
"H/E bkg: Endcap ", 100, 0., 1.);
596 histname =
"pHOverEVsEtaBkg";
597 if (!isRunCentrally_)
600 histname =
"pHOverEVsEtBkg";
601 if (!isRunCentrally_)
604 if (!isRunCentrally_) {
605 histname =
"hOverEVsEtaBkg";
609 histname =
"hOverEVsEtBkg";
611 iBooker.
book2D(histname +
"All",
" Bkg photons H/E vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 0.1);
614 histname =
"ecalRecHitSumEtConeDR04Bkg";
615 h_ecalRecHitSumEtConeDR04Bkg_[0] =
616 iBooker.
book1D(histname +
"All",
"bkg ecalRecHitSumEtDR04: All Ecal",
etBin,
etMin, 50.);
617 h_ecalRecHitSumEtConeDR04Bkg_[1] =
618 iBooker.
book1D(histname +
"Barrel",
"bkg ecalRecHitSumEtDR04: Barrel ",
etBin,
etMin, 50.);
619 h_ecalRecHitSumEtConeDR04Bkg_[2] =
620 iBooker.
book1D(histname +
"Endcap",
"bkg ecalRecHitSumEtDR04: Endcap ",
etBin,
etMin, 50.);
622 if (!isRunCentrally_) {
623 histname =
"ecalRecHitSumEtConeDR04VsEtaBkg";
624 h2_ecalRecHitSumEtConeDR04VsEtaBkg_ = iBooker.
book2D(histname +
"All",
625 " bkg ecalRecHitSumEtDR04 vs #eta: all Ecal ",
632 histname =
"ecalRecHitSumEtConeDR04VsEtBkg";
633 h2_ecalRecHitSumEtConeDR04VsEtBkg_[0] = iBooker.
book2D(histname +
"All",
634 " Bkg ecalRecHitSumEtDR04 vs Et: all Ecal ",
641 h2_ecalRecHitSumEtConeDR04VsEtBkg_[1] = iBooker.
book2D(histname +
"Barrel",
642 " Bkg ecalRecHitSumEtDR04 vs Et: Barrel ",
649 h2_ecalRecHitSumEtConeDR04VsEtBkg_[2] = iBooker.
book2D(histname +
"Endcap",
650 " Bkg ecalRecHitSumEtDR04 vs Et: Endcap ",
657 histname =
"hcalTowerSumEtConeDR04VsEtaBkg";
658 h2_hcalTowerSumEtConeDR04VsEtaBkg_ = iBooker.
book2D(histname +
"All",
659 " bkg hcalTowerSumEtDR04 vs #eta: all Ecal ",
666 histname =
"hcalTowerSumEtConeDR04VsEtBkg";
667 h2_hcalTowerSumEtConeDR04VsEtBkg_[0] = iBooker.
book2D(histname +
"All",
668 " Bkg hcalTowerSumEtDR04 vs Et: all Ecal ",
675 h2_hcalTowerSumEtConeDR04VsEtBkg_[1] = iBooker.
book2D(histname +
"Barrel",
676 " Bkg hcalTowerSumEtDR04 vs Et: Barrel ",
683 h2_hcalTowerSumEtConeDR04VsEtBkg_[2] = iBooker.
book2D(histname +
"Endcap",
684 " Bkg hcalTowerSumEtDR04 vs Et: Endcap ",
693 histname =
"pEcalRecHitSumEtConeDR04VsEtaBkg";
694 if (!isRunCentrally_)
695 p_ecalRecHitSumEtConeDR04VsEtaBkg_ = iBooker.
bookProfile(histname +
"All",
696 "bkg photons ecalRecHitSumEtDR04 vs #eta: all Ecal ",
705 histname =
"pEcalRecHitSumEtConeDR04VsEtBkg";
706 if (!isRunCentrally_)
707 p_ecalRecHitSumEtConeDR04VsEtBkg_[0] = iBooker.
bookProfile(histname +
"All",
708 "Bkg ecalRecHitSumEtDR04 vs Et: all Ecal ",
716 if (!isRunCentrally_)
717 p_ecalRecHitSumEtConeDR04VsEtBkg_[1] = iBooker.
bookProfile(histname +
"Barrel",
718 "Bkg ecalRecHitSumEtDR04 vs Et: all Ecal ",
726 if (!isRunCentrally_)
727 p_ecalRecHitSumEtConeDR04VsEtBkg_[2] = iBooker.
bookProfile(histname +
"Endcap",
728 "Bkg ecalRecHitSumEtDR04 vs Et: all Ecal ",
737 histname =
"hcalTowerSumEtConeDR04Bkg";
738 h_hcalTowerSumEtConeDR04Bkg_[0] =
739 iBooker.
book1D(histname +
"All",
"bkg hcalTowerSumEtDR04: All Ecal",
etBin,
etMin, 20.);
740 h_hcalTowerSumEtConeDR04Bkg_[1] =
741 iBooker.
book1D(histname +
"Barrel",
"bkg hcalTowerSumEtDR04: Barrel ",
etBin,
etMin, 20.);
742 h_hcalTowerSumEtConeDR04Bkg_[2] =
743 iBooker.
book1D(histname +
"Endcap",
"bkg hcalTowerSumEtDR04: Endcap ",
etBin,
etMin, 20.);
745 histname =
"pHcalTowerSumEtConeDR04VsEtaBkg";
746 if (!isRunCentrally_)
747 p_hcalTowerSumEtConeDR04VsEtaBkg_ = iBooker.
bookProfile(histname +
"All",
748 "bkg photons hcalTowerSumEtDR04 vs #eta: all Ecal ",
757 histname =
"pHcalTowerSumEtConeDR04VsEtBkg";
758 if (!isRunCentrally_)
759 p_hcalTowerSumEtConeDR04VsEtBkg_[0] = iBooker.
bookProfile(histname +
"All",
760 "Bkg hcalTowerSumEtDR04 vs Et: all Ecal ",
768 if (!isRunCentrally_)
769 p_hcalTowerSumEtConeDR04VsEtBkg_[1] = iBooker.
bookProfile(histname +
"Barrel",
770 "Bkg hcalTowerSumEtDR04 vs Et: all Ecal ",
778 if (!isRunCentrally_)
779 p_hcalTowerSumEtConeDR04VsEtBkg_[2] = iBooker.
bookProfile(histname +
"Endcap",
780 "Bkg hcalTowerSumEtDR04 vs Et: all Ecal ",
789 histname =
"isoTrkSolidConeDR04Bkg";
790 h_isoTrkSolidConeDR04Bkg_[0] =
792 h_isoTrkSolidConeDR04Bkg_[1] =
794 h_isoTrkSolidConeDR04Bkg_[2] =
797 histname =
"isoTrkSolidConeDR04VsEtaBkg";
798 if (!isRunCentrally_)
799 h2_isoTrkSolidConeDR04VsEtaBkg_ = iBooker.
book2D(histname +
"All",
800 " Bkg photons isoTrkSolidConeDR04 vs #eta: all Ecal ",
807 histname =
"pIsoTrkSolidConeDR04VsEtaBkg";
808 if (!isRunCentrally_)
809 p_isoTrkSolidConeDR04VsEtaBkg_ = iBooker.
bookProfile(histname +
"All",
810 " Bkg photons isoTrkSolidConeDR04 vs #eta: all Ecal ",
818 histname =
"isoTrkSolidConeDR04VsEtBkg";
819 if (!isRunCentrally_)
820 h2_isoTrkSolidConeDR04VsEtBkg_[0] = iBooker.
book2D(histname +
"All",
821 " Bkg photons isoTrkSolidConeDR04 vs Et: all Ecal ",
828 if (!isRunCentrally_)
829 h2_isoTrkSolidConeDR04VsEtBkg_[1] = iBooker.
book2D(histname +
"Barrel",
830 " Bkg photons isoTrkSolidConeDR04 vs Et: all Ecal ",
837 if (!isRunCentrally_)
838 h2_isoTrkSolidConeDR04VsEtBkg_[2] = iBooker.
book2D(histname +
"Endcap",
839 " Bkg photons isoTrkSolidConeDR04 vs Et: all Ecal ",
846 histname =
"pIsoTrkSolidConeDR04VsEtBkg";
847 if (!isRunCentrally_)
848 p_isoTrkSolidConeDR04VsEtBkg_[0] = iBooker.
bookProfile(histname +
"All",
849 " Bkg photons isoTrkSolidConeDR04 vs Et: all Ecal ",
856 if (!isRunCentrally_)
857 p_isoTrkSolidConeDR04VsEtBkg_[1] = iBooker.
bookProfile(histname +
"Barrel",
858 " Bkg photons isoTrkSolidConeDR04 vs Et: all Ecal ",
865 if (!isRunCentrally_)
866 p_isoTrkSolidConeDR04VsEtBkg_[2] = iBooker.
bookProfile(histname +
"Endcap",
867 " Bkg photons isoTrkSolidConeDR04 vs Et: all Ecal ",
875 histname =
"nTrkSolidConeDR04Bkg";
876 h_nTrkSolidConeDR04Bkg_[0] = iBooker.
book1D(histname +
"All",
"Bkg nTrkSolidConeDR04: All Ecal", 20, 0., 20);
877 h_nTrkSolidConeDR04Bkg_[1] = iBooker.
book1D(histname +
"Barrel",
"Bkg nTrkSolidConeDR04: Barrel ", 20, 0., 20);
878 h_nTrkSolidConeDR04Bkg_[2] = iBooker.
book1D(histname +
"Endcap",
"Bkg nTrkSolidConeDR04: Endcap ", 20, 0., 20);
880 histname =
"nTrkSolidConeDR04VsEtaBkg";
881 if (!isRunCentrally_)
882 h2_nTrkSolidConeDR04VsEtaBkg_ = iBooker.
book2D(
883 histname +
"All",
" Bkg photons nTrkSolidConeDR04 vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 20, 0., 20);
884 histname =
"p_nTrkSolidConeDR04VsEtaBkg";
885 if (!isRunCentrally_)
886 p_nTrkSolidConeDR04VsEtaBkg_ = iBooker.
bookProfile(
887 histname +
"All",
" Bkg photons nTrkSolidConeDR04 vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 20, 0., 20);
889 histname =
"nTrkSolidConeDR04VsEtBkg";
890 if (!isRunCentrally_)
891 h2_nTrkSolidConeDR04VsEtBkg_[0] = iBooker.
book2D(
892 histname +
"All",
"Bkg photons nTrkSolidConeDR04 vs Et: all Ecal ",
etBin,
etMin,
etMax, 20, 0., 20);
893 if (!isRunCentrally_)
894 h2_nTrkSolidConeDR04VsEtBkg_[1] = iBooker.
book2D(
895 histname +
"Barrel",
"Bkg photons nTrkSolidConeDR04 vs Et: all Ecal ",
etBin,
etMin,
etMax, 20, 0., 20);
896 if (!isRunCentrally_)
897 h2_nTrkSolidConeDR04VsEtBkg_[2] = iBooker.
book2D(
898 histname +
"Endcap",
"Bkg photons nTrkSolidConeDR04 vs Et: all Ecal ",
etBin,
etMin,
etMax, 20, 0., 20);
900 histname =
"pnTrkSolidConeDR04VsEtBkg";
901 if (!isRunCentrally_)
902 p_nTrkSolidConeDR04VsEtBkg_[0] = iBooker.
bookProfile(
903 histname +
"All",
"Bkg photons nTrkSolidConeDR04 vs Et: all Ecal ",
etBin,
etMin,
etMax, 20, 0., 20);
904 if (!isRunCentrally_)
905 p_nTrkSolidConeDR04VsEtBkg_[1] = iBooker.
bookProfile(
906 histname +
"Barrel",
"Bkg photons nTrkSolidConeDR04 vs Et: all Ecal ",
etBin,
etMin,
etMax, 20, 0., 20);
907 if (!isRunCentrally_)
908 p_nTrkSolidConeDR04VsEtBkg_[2] = iBooker.
bookProfile(
909 histname +
"Endcap",
"Bkg photons nTrkSolidConeDR04 vs Et: all Ecal ",
etBin,
etMin,
etMax, 20, 0., 20);
914 histname =
"mvaOutBkg";
915 h_mvaOutBkg_[0] = iBooker.
book1D(histname +
"All",
" mvaOut conversions bkg : All Ecal", 100, 0., 1.);
916 h_mvaOutBkg_[1] = iBooker.
book1D(histname +
"Barrel",
" mvaOut conversions bkg: Barrel Ecal", 100, 0., 1.);
917 h_mvaOutBkg_[2] = iBooker.
book1D(histname +
"Endcap",
" mvaOut conversions bkg: Endcap Ecal", 100, 0., 1.);
919 histname =
"PoverEtracksBkg";
920 h_PoverETracksBkg_[0] =
922 h_PoverETracksBkg_[1] =
924 h_PoverETracksBkg_[2] =
927 histname =
"EoverPtracksBkg";
928 h_EoverPTracksBkg_[0] =
930 h_EoverPTracksBkg_[1] =
932 h_EoverPTracksBkg_[2] =
935 histname =
"hDCotTracksBkg";
936 h_DCotTracksBkg_[0] = iBooker.
book1D(histname +
"All",
937 " bkg Photons:Tracks from conversions #delta cotg(#Theta) Tracks: all Ecal ",
941 h_DCotTracksBkg_[1] = iBooker.
book1D(histname +
"Barrel",
942 " bkg Photons:Tracks from conversions #delta cotg(#Theta) Tracks: Barrel Ecal ",
946 h_DCotTracksBkg_[2] = iBooker.
book1D(histname +
"Endcap",
947 " bkg Photons:Tracks from conversions #delta cotg(#Theta) Tracks: Endcap Ecal ",
952 histname =
"hDPhiTracksAtVtxBkg";
953 h_DPhiTracksAtVtxBkg_[0] =
954 iBooker.
book1D(histname +
"All",
955 " Bkg Photons:Tracks from conversions: #delta#phi Tracks at vertex: all Ecal",
959 h_DPhiTracksAtVtxBkg_[1] =
960 iBooker.
book1D(histname +
"Barrel",
961 " Bkg Photons:Tracks from conversions: #delta#phi Tracks at vertex: Barrel Ecal",
965 h_DPhiTracksAtVtxBkg_[2] =
966 iBooker.
book1D(histname +
"Endcap",
967 " Bkg Photons:Tracks from conversions: #delta#phi Tracks at vertex: Endcap Ecal",
972 if (!isRunCentrally_) {
973 h_convVtxRvsZBkg_[0] = iBooker.
book2D(
"convVtxRvsZAllBkg",
974 " Bkg Photon Reco conversion vtx position",
981 h_convVtxRvsZBkg_[1] = iBooker.
book2D(
"convVtxRvsZBarrelBkg",
982 " Bkg Photon Reco conversion vtx position",
989 h_convVtxYvsXBkg_ = iBooker.
book2D(
"convVtxYvsXTrkBarrelBkg",
990 " Bkg Photon Reco conversion vtx position, (x,y) eta<1 ",
1002 histname =
"nOfflineVtx";
1003 h_nRecoVtx_ = iBooker.
book1D(histname,
"# of Offline Vertices", 200, -0.5, 199.5);
1014 if (!isRunCentrally_) {
1015 h_scEtaWidth_[0] = iBooker.
book1D(
"scEtaWidth",
" SC Eta Width ", 100, 0., 0.1);
1016 h_scPhiWidth_[0] = iBooker.
book1D(
"scPhiWidth",
" SC Phi Width ", 100, 0., 1.);
1020 h_scE_[0][0] = iBooker.
book1D(histname +
"All",
" SC Energy: All Ecal ",
eBin,
eMin,
eMax);
1021 h_scE_[0][1] = iBooker.
book1D(histname +
"Barrel",
" SC Energy: Barrel ",
eBin,
eMin,
eMax);
1022 h_scE_[0][2] = iBooker.
book1D(histname +
"Endcap",
" SC Energy: Endcap ",
eBin,
eMin,
eMax);
1025 h_psE_ = iBooker.
book1D(histname +
"Endcap",
" ES Energy ",
eBin,
eMin, 50.);
1038 if (!isRunCentrally_) {
1039 histname =
"r9ConvFromMC";
1044 histname =
"r9ConvFromReco";
1049 histname =
"EtR9Less093";
1050 h_EtR9Less093_[0][0] = iBooker.
book1D(histname +
"All",
" r9 < 0.94 or 0.95 : All Ecal",
etBin,
etMin,
etMax);
1051 h_EtR9Less093_[0][1] = iBooker.
book1D(histname +
"Barrel",
" r9 < 0.94 : Barrel ",
etBin,
etMin,
etMax);
1052 h_EtR9Less093_[0][2] = iBooker.
book1D(histname +
"Endcap",
" r9 < 0.95 : Endcap ",
etBin,
etMin,
etMax);
1053 histname =
"EtR9Less093Conv";
1054 h_EtR9Less093_[1][0] =
1056 h_EtR9Less093_[1][1] =
1058 h_EtR9Less093_[1][2] =
1063 histname =
"pR9VsEta";
1065 histname +
"All",
" All photons r9 vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 1.1);
1067 histname +
"Unconv",
" Unconv photons r9 vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 1.1);
1069 histname +
"Conv",
" Conv photons r9 vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 1.1);
1071 histname =
"R9VsEt";
1072 if (!isRunCentrally_)
1074 iBooker.
book2D(histname +
"All",
" All photons r9 vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 1.1);
1075 if (!isRunCentrally_)
1077 iBooker.
book2D(histname +
"Unconv",
" All photons r9 vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 1.1);
1084 histname =
"R1VsEta";
1085 if (!isRunCentrally_)
1086 h2_r1VsEta_[0] = iBooker.
book2D(
1087 histname +
"All",
" All photons e1x5/e5x5 vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 1.1);
1088 if (!isRunCentrally_)
1089 h2_r1VsEta_[1] = iBooker.
book2D(
1090 histname +
"Unconv",
" All photons e1x5/e5x5 vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 1.1);
1092 histname =
"R1VsEt";
1093 if (!isRunCentrally_)
1095 iBooker.
book2D(histname +
"All",
" All photons e1x5/e5x5 vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 1.1);
1096 if (!isRunCentrally_)
1097 h2_r1VsEt_[1] = iBooker.
book2D(
1098 histname +
"Unconv",
" All photons e1x5/e5x5 vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 1.1);
1105 histname =
"R2VsEta";
1106 if (!isRunCentrally_)
1107 h2_r2VsEta_[0] = iBooker.
book2D(
1108 histname +
"All",
" All photons e2x5/e5x5 vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 1.1);
1109 if (!isRunCentrally_)
1110 h2_r2VsEta_[1] = iBooker.
book2D(
1111 histname +
"Unconv",
" All photons e2x5/e5x5 vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 1.1);
1113 histname =
"R2VsEt";
1114 if (!isRunCentrally_)
1116 iBooker.
book2D(histname +
"All",
" All photons e2x5/e5x5 vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 1.1);
1117 if (!isRunCentrally_)
1118 h2_r2VsEt_[1] = iBooker.
book2D(
1119 histname +
"Unconv",
" All photons e2x5/e5x5 vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 1.1);
1121 histname =
"sigmaIetaIeta";
1122 h_sigmaIetaIeta_[0][0] = iBooker.
book1D(histname +
"All",
"sigmaIetaIeta: All Ecal", 100, 0., 0.1);
1123 h_sigmaIetaIeta_[0][1] = iBooker.
book1D(histname +
"Barrel",
"sigmaIetaIeta: Barrel ", 100, 0., 0.05);
1124 h_sigmaIetaIeta_[0][2] = iBooker.
book1D(histname +
"Endcap",
"sigmaIetaIeta: Endcap ", 100, 0., 0.1);
1126 histname =
"sigmaIetaIetaVsEta";
1127 if (!isRunCentrally_)
1128 h2_sigmaIetaIetaVsEta_[0] = iBooker.
book2D(
1129 histname +
"All",
" All photons sigmaIetaIeta vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 0.1);
1130 if (!isRunCentrally_)
1131 h2_sigmaIetaIetaVsEta_[1] = iBooker.
book2D(
1132 histname +
"Unconv",
" All photons sigmaIetaIeta vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 0.1);
1134 histname =
"sigmaIetaIetaVsEt";
1135 if (!isRunCentrally_)
1136 h2_sigmaIetaIetaVsEt_[0] = iBooker.
book2D(
1137 histname +
"All",
" All photons sigmaIetaIeta vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 0.1);
1138 if (!isRunCentrally_)
1139 h2_sigmaIetaIetaVsEt_[1] = iBooker.
book2D(
1140 histname +
"Unconv",
" All photons sigmaIetaIeta vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 0.1);
1142 histname =
"hOverE";
1143 h_hOverE_[0][0] = iBooker.
book1D(histname +
"All",
"H/E: All Ecal", 100, 0., 0.1);
1144 h_hOverE_[0][1] = iBooker.
book1D(histname +
"Barrel",
"H/E: Barrel ", 100, 0., 0.1);
1145 h_hOverE_[0][2] = iBooker.
book1D(histname +
"Endcap",
"H/E: Endcap ", 100, 0., 0.1);
1147 histname =
"newhOverE";
1148 h_newhOverE_[0][0] = iBooker.
book1D(histname +
"All",
"new H/E: All Ecal", 100, 0., 0.1);
1149 h_newhOverE_[0][1] = iBooker.
book1D(histname +
"Barrel",
"new H/E: Barrel ", 100, 0., 0.1);
1150 h_newhOverE_[0][2] = iBooker.
book1D(histname +
"Endcap",
"new H/E: Endcap ", 100, 0., 0.1);
1153 if (!isRunCentrally_) {
1154 histname =
"hOverEVsEta";
1155 h2_hOverEVsEta_[0] =
1157 h2_hOverEVsEta_[1] = iBooker.
book2D(
1158 histname +
"Unconv",
" All photons H/E vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 0.1);
1160 histname =
"hOverEVsEt";
1162 iBooker.
book2D(histname +
"All",
" All photons H/E vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 0.1);
1164 iBooker.
book2D(histname +
"Unconv",
" All photons H/E vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 0.1);
1167 histname =
"pHoverEVsEta";
1169 histname +
"All",
" All photons H/E vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 0.1);
1171 histname +
"Unconv",
" All photons H/E vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 0.1);
1173 histname =
"pHoverEVsEt";
1179 histname =
"pnewHoverEVsEta";
1181 histname +
"All",
" All photons new H/E vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 0.1);
1183 histname +
"Unconv",
" All photons new H/E vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 0.1);
1185 histname =
"pnewHoverEVsEt";
1186 p_newhOverEVsEt_[0] =
1189 histname +
"Unconv",
" All photons new H/E vs Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0., 0.1);
1191 histname =
"ecalRecHitSumEtConeDR04";
1192 h_ecalRecHitSumEtConeDR04_[0][0] =
1193 iBooker.
book1D(histname +
"All",
"ecalRecHitSumEtDR04: All Ecal",
etBin,
etMin, 20.);
1194 h_ecalRecHitSumEtConeDR04_[0][1] =
1195 iBooker.
book1D(histname +
"Barrel",
"ecalRecHitSumEtDR04: Barrel ",
etBin,
etMin, 20.);
1196 h_ecalRecHitSumEtConeDR04_[0][2] =
1197 iBooker.
book1D(histname +
"Endcap",
"ecalRecHitSumEtDR04: Endcap ",
etBin,
etMin, 20.);
1200 if (!isRunCentrally_) {
1201 histname =
"ecalRecHitSumEtConeDR04VsEta";
1202 h2_ecalRecHitSumEtConeDR04VsEta_[0] = iBooker.
book2D(histname +
"All",
1203 " All photons ecalRecHitSumEtDR04 vs #eta: all Ecal ",
1210 h2_ecalRecHitSumEtConeDR04VsEta_[1] = iBooker.
book2D(histname +
"Unconv",
1211 " All photons ecalRecHitSumEtDR04 vs #eta: all Ecal ",
1219 histname =
"pEcalRecHitSumEtConeDR04VsEta";
1220 p_ecalRecHitSumEtConeDR04VsEta_[0] = iBooker.
bookProfile(histname +
"All",
1221 "All photons ecalRecHitSumEtDR04 vs #eta: all Ecal ",
1229 p_ecalRecHitSumEtConeDR04VsEta_[1] = iBooker.
bookProfile(histname +
"Unconv",
1230 "All photons ecalRecHitSumEtDR04 vs #eta: all Ecal ",
1239 if (!isRunCentrally_) {
1240 histname =
"ecalRecHitSumEtConeDR04VsEt";
1241 h2_ecalRecHitSumEtConeDR04VsEt_[0] = iBooker.
book2D(histname +
"All",
1242 " All photons ecalRecHitSumEtDR04 vs Et: all Ecal ",
1249 h2_ecalRecHitSumEtConeDR04VsEt_[1] = iBooker.
book2D(histname +
"Barrel",
1250 " All photons ecalRecHitSumEtDR04 vs Et: Barrel ",
1257 h2_ecalRecHitSumEtConeDR04VsEt_[2] = iBooker.
book2D(histname +
"Endcap",
1258 " All photons ecalRecHitSumEtDR04 vs Et: Endcap ",
1266 histname =
"pEcalRecHitSumEtConeDR04VsEt";
1267 if (!isRunCentrally_)
1268 p_ecalRecHitSumEtConeDR04VsEt_[0] = iBooker.
bookProfile(histname +
"All",
1269 "All photons ecalRecHitSumEtDR04 vs Et: all Ecal ",
1277 p_ecalRecHitSumEtConeDR04VsEt_[1] = iBooker.
bookProfile(histname +
"Barrel",
1278 "All photons ecalRecHitSumEtDR04 vs Et: all Ecal ",
1286 p_ecalRecHitSumEtConeDR04VsEt_[2] = iBooker.
bookProfile(histname +
"Endcap",
1287 "All photons ecalRecHitSumEtDR04 vs Et: all Ecal ",
1296 histname =
"hcalTowerSumEtConeDR04";
1297 h_hcalTowerSumEtConeDR04_[0][0] =
1298 iBooker.
book1D(histname +
"All",
"hcalTowerSumEtConeDR04: All Ecal",
etBin,
etMin, 20.);
1299 h_hcalTowerSumEtConeDR04_[0][1] =
1300 iBooker.
book1D(histname +
"Barrel",
"hcalTowerSumEtConeDR04: Barrel ",
etBin,
etMin, 20.);
1301 h_hcalTowerSumEtConeDR04_[0][2] =
1302 iBooker.
book1D(histname +
"Endcap",
"hcalTowerSumEtConeDR04: Endcap ",
etBin,
etMin, 20.);
1304 histname =
"hcalTowerBcSumEtConeDR04";
1305 if (!isRunCentrally_)
1306 h_hcalTowerBcSumEtConeDR04_[0][0] =
1307 iBooker.
book1D(histname +
"All",
"hcalTowerBcSumEtConeDR04: All Ecal",
etBin,
etMin, 20.);
1308 h_hcalTowerBcSumEtConeDR04_[0][1] =
1309 iBooker.
book1D(histname +
"Barrel",
"hcalTowerBcSumEtConeDR04: Barrel ",
etBin,
etMin, 20.);
1310 h_hcalTowerBcSumEtConeDR04_[0][2] =
1311 iBooker.
book1D(histname +
"Endcap",
"hcalTowerBcSumEtConeDR04: Endcap ",
etBin,
etMin, 20.);
1314 if (!isRunCentrally_) {
1315 histname =
"hcalTowerSumEtConeDR04VsEta";
1316 h2_hcalTowerSumEtConeDR04VsEta_[0] = iBooker.
book2D(histname +
"All",
1317 " All photons hcalTowerSumEtConeDR04 vs #eta: all Ecal ",
1324 h2_hcalTowerSumEtConeDR04VsEta_[1] = iBooker.
book2D(histname +
"Unconv",
1325 " All photons hcalTowerSumEtConeDR04 vs #eta: all Ecal ",
1333 histname =
"pHcalTowerSumEtConeDR04VsEta";
1334 p_hcalTowerSumEtConeDR04VsEta_[0] = iBooker.
bookProfile(histname +
"All",
1335 "All photons hcalTowerSumEtDR04 vs #eta: all Ecal ",
1343 p_hcalTowerSumEtConeDR04VsEta_[1] = iBooker.
bookProfile(histname +
"Unconv",
1344 "All photons hcalTowerSumEtDR04 vs #eta: all Ecal ",
1352 histname =
"pHcalTowerBcSumEtConeDR04VsEta";
1353 p_hcalTowerBcSumEtConeDR04VsEta_[0] = iBooker.
bookProfile(histname +
"All",
1354 "All photons hcalTowerBcSumEtDR04 vs #eta: all Ecal ",
1362 p_hcalTowerBcSumEtConeDR04VsEta_[1] = iBooker.
bookProfile(histname +
"Unconv",
1363 "All photons hcalTowerBcSumEtDR04 vs #eta: all Ecal ",
1372 if (!isRunCentrally_) {
1373 histname =
"hcalTowerSumEtConeDR04VsEt";
1374 h2_hcalTowerSumEtConeDR04VsEt_[0] = iBooker.
book2D(histname +
"All",
1375 " All photons hcalTowerSumEtConeDR04 vs Et: all Ecal ",
1382 h2_hcalTowerSumEtConeDR04VsEt_[1] = iBooker.
book2D(histname +
"Barrel",
1383 " All photons hcalTowerSumEtConeDR04 vs Et: Barrel ",
1390 h2_hcalTowerSumEtConeDR04VsEt_[2] = iBooker.
book2D(histname +
"Endcap",
1391 " All photons hcalTowerSumEtConeDR04 vs Et: Endcap ",
1399 histname =
"pHcalTowerSumEtConeDR04VsEt";
1400 if (!isRunCentrally_)
1401 p_hcalTowerSumEtConeDR04VsEt_[0] = iBooker.
bookProfile(histname +
"All",
1402 "All photons hcalTowerSumEtDR04 vs Et: all Ecal ",
1410 p_hcalTowerSumEtConeDR04VsEt_[1] = iBooker.
bookProfile(histname +
"Barrel",
1411 "All photons hcalTowerSumEtDR04 vs Et: all Ecal ",
1419 p_hcalTowerSumEtConeDR04VsEt_[2] = iBooker.
bookProfile(histname +
"Endcap",
1420 "All photons hcalTowerSumEtDR04 vs Et: all Ecal ",
1429 histname =
"pHcalTowerBcSumEtConeDR04VsEt";
1430 if (!isRunCentrally_)
1431 p_hcalTowerBcSumEtConeDR04VsEt_[0] = iBooker.
bookProfile(histname +
"All",
1432 "All photons hcalTowerBcSumEtDR04 vs Et: all Ecal ",
1440 p_hcalTowerBcSumEtConeDR04VsEt_[1] = iBooker.
bookProfile(histname +
"Barrel",
1441 "All photons hcalTowerBcSumEtDR04 vs Et: all Ecal ",
1449 p_hcalTowerBcSumEtConeDR04VsEt_[2] = iBooker.
bookProfile(histname +
"Endcap",
1450 "All photons hcalTowerBcSumEtDR04 vs Et: all Ecal ",
1460 histname =
"isoTrkSolidConeDR04";
1461 h_isoTrkSolidConeDR04_[0][0] =
1463 h_isoTrkSolidConeDR04_[0][1] =
1465 h_isoTrkSolidConeDR04_[0][2] =
1469 histname =
"isoTrkSolidConeDR04VsEta";
1470 if (!isRunCentrally_)
1471 h2_isoTrkSolidConeDR04VsEta_[0] = iBooker.
book2D(histname +
"All",
1472 " All photons isoTrkSolidConeDR04 vs #eta: all Ecal ",
1479 if (!isRunCentrally_)
1480 h2_isoTrkSolidConeDR04VsEta_[1] = iBooker.
book2D(histname +
"Unconv",
1481 " All photons isoTrkSolidConeDR04 vs #eta: all Ecal ",
1490 histname =
"isoTrkSolidConeDR04VsEt";
1491 if (!isRunCentrally_)
1492 h2_isoTrkSolidConeDR04VsEt_[0] = iBooker.
book2D(histname +
"All",
1493 " All photons isoTrkSolidConeDR04 vs Et: all Ecal ",
1500 if (!isRunCentrally_)
1501 h2_isoTrkSolidConeDR04VsEt_[1] = iBooker.
book2D(histname +
"Unconv",
1502 " All photons isoTrkSolidConeDR04 vs Et: all Ecal ",
1510 histname =
"nTrkSolidConeDR04";
1511 h_nTrkSolidConeDR04_[0][0] = iBooker.
book1D(histname +
"All",
"nTrkSolidConeDR04: All Ecal", 20, 0., 20);
1512 h_nTrkSolidConeDR04_[0][1] = iBooker.
book1D(histname +
"Barrel",
"nTrkSolidConeDR04: Barrel ", 20, 0., 20);
1513 h_nTrkSolidConeDR04_[0][2] = iBooker.
book1D(histname +
"Endcap",
"nTrkSolidConeDR04: Endcap ", 20, 0., 20);
1515 histname =
"nTrkSolidConeDR04VsEta";
1516 if (!isRunCentrally_)
1517 h2_nTrkSolidConeDR04VsEta_[0] = iBooker.
book2D(
1518 histname +
"All",
" All photons nTrkSolidConeDR04 vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 20, 0., 20);
1519 if (!isRunCentrally_)
1520 h2_nTrkSolidConeDR04VsEta_[1] = iBooker.
book2D(
1521 histname +
"Unconv",
" All photons nTrkSolidConeDR04 vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 20, 0., 20);
1523 histname =
"nTrkSolidConeDR04VsEt";
1524 if (!isRunCentrally_)
1525 h2_nTrkSolidConeDR04VsEt_[0] = iBooker.
book2D(
1526 histname +
"All",
" All photons nTrkSolidConeDR04 vs Et: all Ecal ",
etBin,
etMin,
etMax, 20, 0., 20);
1527 if (!isRunCentrally_)
1528 h2_nTrkSolidConeDR04VsEt_[1] = iBooker.
book2D(
1529 histname +
"Unconv",
" All photons nTrkSolidConeDR04 vs Et: all Ecal ",
etBin,
etMin,
etMax, 20, 0., 20);
1532 h_phoE_[0][0] = iBooker.
book1D(histname +
"All",
" Photon Energy: All ecal ",
eBin,
eMin,
eMax);
1533 h_phoE_[0][1] = iBooker.
book1D(histname +
"Barrel",
" Photon Energy: barrel ",
eBin,
eMin,
eMax);
1534 h_phoE_[0][2] = iBooker.
book1D(histname +
"Endcap",
" Photon Energy: Endcap ",
eBin,
eMin,
eMax);
1537 h_phoEt_[0][0] = iBooker.
book1D(histname +
"All",
" Photon Transverse Energy: All ecal ",
etBin,
etMin,
etMax);
1538 h_phoEt_[0][1] = iBooker.
book1D(histname +
"Barrel",
" Photon Transverse Energy: Barrel ",
etBin,
etMin,
etMax);
1539 h_phoEt_[0][2] = iBooker.
book1D(histname +
"Endcap",
" Photon Transverse Energy: Endcap ",
etBin,
etMin,
etMax);
1549 h_phoERes_[1][0] = iBooker.
book1D(
1550 histname +
"unconvAll",
" Photon E/E_{true} if r9>0.94, 0.95: All ecal; E/E_{true} (GeV)",
resBin,
resMin,
resMax);
1551 h_phoERes_[1][1] = iBooker.
book1D(
1552 histname +
"unconvBarrel",
" Photon E/E_{true} if r9>0.94: Barrel; E/E_{true} (GeV)",
resBin,
resMin,
resMax);
1553 h_phoERes_[1][2] = iBooker.
book1D(
1554 histname +
"unconvEndcap",
" Photon E/E_{true} if r9>0.95: Endcap; E/E_{true} (GeV)",
resBin,
resMin,
resMax);
1556 h_phoERes_[2][0] = iBooker.
book1D(
1557 histname +
"convAll",
" Photon E/E_{true} if r9<0.0.94, 0.95: All ecal; E/E_{true} (GeV)",
resBin,
resMin,
resMax);
1558 h_phoERes_[2][1] = iBooker.
book1D(
1559 histname +
"convBarrel",
" Photon E/E_{true} if r9<0.94: Barrel; E/E_{true} (GeV)",
resBin,
resMin,
resMax);
1560 h_phoERes_[2][2] = iBooker.
book1D(
1561 histname +
"convEndcap",
" Photon E/E_{true} if r9<0.95: Endcap; E/E_{true} (GeV)",
resBin,
resMin,
resMax);
1563 histname =
"sigmaEoE";
1564 h_phoSigmaEoE_[0][0] = iBooker.
book1D(histname +
"All",
"#sigma_{E}/E: All ecal; #sigma_{E}/E", 100, 0., 0.08);
1565 h_phoSigmaEoE_[0][1] = iBooker.
book1D(histname +
"Barrel",
"#sigma_{E}/E: Barrel; #sigma_{E}/E", 100, 0., 0.08);
1566 h_phoSigmaEoE_[0][2] = iBooker.
book1D(histname +
"Endcap",
"#sigma_{E}/E: Endcap, #sigma_{E}/E", 100, 0., 0.08);
1568 h_phoSigmaEoE_[1][0] =
1569 iBooker.
book1D(histname +
"unconvAll",
"#sigma_{E}/E if r9>0.94, 0.95: All ecal; #sigma_{E}/E", 100, 0., 0.08);
1570 h_phoSigmaEoE_[1][1] =
1571 iBooker.
book1D(histname +
"unconvBarrel",
"#sigma_{E}/E if r9>0.94: Barrel; #sigma_{E}/E", 100, 0., 0.08);
1572 h_phoSigmaEoE_[1][2] =
1573 iBooker.
book1D(histname +
"unconvEndcap",
"#sigma_{E}/E r9>0.95: Endcap; #sigma_{E}/E", 100, 0., 0.08);
1575 h_phoSigmaEoE_[2][0] =
1576 iBooker.
book1D(histname +
"convAll",
"#sigma_{E}/E if r9<0.0.94, 0.95: All ecal, #sigma_{E}/E", 100, 0., 0.08);
1577 h_phoSigmaEoE_[2][1] =
1578 iBooker.
book1D(histname +
"convBarrel",
"#sigma_{E}/E if r9<0.94: Barrel, #sigma_{E}/E", 100, 0., 0.08);
1579 h_phoSigmaEoE_[2][2] =
1580 iBooker.
book1D(histname +
"convEndcap",
"#sigma_{E}/E if r9<0.95: Endcap, #sigma_{E}/E", 100, 0., 0.08);
1582 histname =
"eResVsEta";
1583 if (!isRunCentrally_)
1584 h2_eResVsEta_[0] = iBooker.
book2D(
1585 histname +
"All",
" All photons E/Etrue vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 2.5);
1586 if (!isRunCentrally_)
1587 h2_eResVsEta_[1] = iBooker.
book2D(
1588 histname +
"Unconv",
" Unconv photons E/Etrue vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 2.5);
1590 histname =
"pEResVsEta";
1593 p_eResVsEta_[1] = iBooker.
bookProfile(histname +
"Unconv",
1594 "Unconv photons E/Etrue vs #eta: all Ecal",
1605 histname =
"pSigmaEoEVsEta";
1606 p_sigmaEoEVsEta_[0] = iBooker.
bookProfile(histname +
"All",
1607 "All photons: #sigma_{E}/E vs #eta: all Ecal; #eta; #sigma_{E}/E",
1615 p_sigmaEoEVsEta_[1] = iBooker.
bookProfile(histname +
"Unconv",
1616 "Unconv photons #sigma_{E}/E vs #eta: all Ecal; #eta; #sigma_{E}/E ",
1624 p_sigmaEoEVsEta_[2] = iBooker.
bookProfile(histname +
"Conv",
1625 "Conv photons #sigma_{E}/E vs #eta: all Ecal; #eta; #sigma_{E}/E",
1634 histname =
"pSigmaEoEVsEt";
1635 p_sigmaEoEVsEt_[1][0] = iBooker.
bookProfile(histname +
"Barrel",
1636 "All photons #sigma_{E}/E vs E_{T}: Barrel; E_{T} (GeV); #sigma_{E}/E ",
1644 p_sigmaEoEVsEt_[1][1] =
1646 "Unconv photons #sigma_{E}/E vs E_{T}: Barrel; E_{T} (GeV); #sigma_{E}/E ",
1654 p_sigmaEoEVsEt_[1][2] = iBooker.
bookProfile(histname +
"convBarrel",
1655 "Conv photons #sigma_{E}/E vs E_{T}: Barrel; E_{T} (GeV); #sigma_{E}/E",
1663 p_sigmaEoEVsEt_[2][0] = iBooker.
bookProfile(histname +
"Endcap",
1664 "All photons #sigma_{E}/E vs E_{T}: Endcap; E_{T} (GeV); #sigma_{E}/E ",
1672 p_sigmaEoEVsEt_[2][1] =
1674 "Unconv photons #sigma_{E}/E vs E_{T}: Endcap; E_{T} (GeV); #sigma_{E}/E ",
1682 p_sigmaEoEVsEt_[2][2] = iBooker.
bookProfile(histname +
"convEndcap",
1683 "Conv photons #sigma_{E}/E vs E_{T}: Endcap; E_{T} (GeV); #sigma_{E}/E",
1692 histname =
"pSigmaEoEVsNVtx";
1693 p_sigmaEoEVsNVtx_[1][0] = iBooker.
bookProfile(histname +
"Barrel",
1694 "All photons: #sigma_{E}/E vs N_{vtx}: Barrel; N_{vtx}; #sigma_{E}/E",
1702 p_sigmaEoEVsNVtx_[1][1] =
1704 "Unconv photons #sigma_{E}/E vs N_{vtx}: Barrel; N_{vtx}; #sigma_{E}/E ",
1712 p_sigmaEoEVsNVtx_[1][2] = iBooker.
bookProfile(histname +
"convBarrel",
1713 "Conv photons #sigma_{E}/E vs N_{vtx}: Barrel; N_{vtx}; #sigma_{E}/E",
1721 p_sigmaEoEVsNVtx_[2][0] = iBooker.
bookProfile(histname +
"Endcap",
1722 "All photons: #sigma_{E}/E vs N_{vtx}: Endcap; N_{vtx}; #sigma_{E}/E",
1730 p_sigmaEoEVsNVtx_[2][1] =
1732 "Unconv photons #sigma_{E}/E vs N_{vtx}: Endcap; N_{vtx}; #sigma_{E}/E ",
1740 p_sigmaEoEVsNVtx_[2][2] = iBooker.
bookProfile(histname +
"convEndcap",
1741 "Conv photons #sigma_{E}/E vs N_{vtx}: Endcap; N_{vtx}; #sigma_{E}/E",
1750 if (!isRunCentrally_) {
1751 histname =
"eResVsEt";
1752 h2_eResVsEt_[0][0] = iBooker.
book2D(
1753 histname +
"All",
" All photons E/Etrue vs true Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0.9, 1.1);
1754 h2_eResVsEt_[0][1] = iBooker.
book2D(
1755 histname +
"unconv",
" All photons E/Etrue vs true Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0.9, 1.1);
1756 h2_eResVsEt_[0][2] = iBooker.
book2D(
1757 histname +
"conv",
" All photons E/Etrue vs true Et: all Ecal ",
etBin,
etMin,
etMax, 100, 0.9, 1.1);
1758 h2_eResVsEt_[1][0] = iBooker.
book2D(
1759 histname +
"Barrel",
" All photons E/Etrue vs true Et: Barrel ",
etBin,
etMin,
etMax, 100, 0.9, 1.1);
1760 h2_eResVsEt_[1][1] = iBooker.
book2D(
1761 histname +
"unconvBarrel",
" All photons E/Etrue vs true Et: Barrel ",
etBin,
etMin,
etMax, 100, 0.9, 1.1);
1762 h2_eResVsEt_[1][2] = iBooker.
book2D(
1763 histname +
"convBarrel",
" All photons E/Etrue vs true Et: Barrel ",
etBin,
etMin,
etMax, 100, 0.9, 1.1);
1764 h2_eResVsEt_[2][0] = iBooker.
book2D(
1765 histname +
"Endcap",
" All photons E/Etrue vs true Et: Endcap ",
etBin,
etMin,
etMax, 100, 0.9, 1.1);
1766 h2_eResVsEt_[2][1] = iBooker.
book2D(
1767 histname +
"unconvEndcap",
" All photons E/Etrue vs true Et: Endcap ",
etBin,
etMin,
etMax, 100, 0.9, 1.1);
1768 h2_eResVsEt_[2][2] = iBooker.
book2D(
1769 histname +
"convEndcap",
" All photons E/Etrue vs true Et: Endcap ",
etBin,
etMin,
etMax, 100, 0.9, 1.1);
1772 histname =
"pEResVsEt";
1792 histname =
"pEResVsNVtx";
1793 p_eResVsNVtx_[1][0] = iBooker.
bookProfile(histname +
"Barrel",
1794 "All photons E/E_{true} vs N_{vtx}: Barrel; N_{vtx}; E}/E_{true}",
1802 p_eResVsNVtx_[1][1] =
1804 "Unconverted photons E/E_{true} vs N_{vtx}: Barrel; N_{vtx}; E}/E_{true} ",
1812 p_eResVsNVtx_[1][2] =
1814 " Converted photons E/E_{true} vs N_{vtx}: Barrel; N_{vtx}; E}/E_{true} ",
1822 p_eResVsNVtx_[2][0] = iBooker.
bookProfile(histname +
"Endcap",
1823 "All photons E/E_{true} vs N_{vtx}: Endcap; N_{vtx}; E}/E_{true} ",
1831 p_eResVsNVtx_[2][1] =
1833 "Uncoverted photons E/E_{true} vs N_{vtx}: Endcap; N_{vtx}; E}/E_{true} ",
1841 p_eResVsNVtx_[2][2] = iBooker.
bookProfile(histname +
"convEndcap",
1842 "Converted photons E/E_{true} vs N_{vtx}: Endcap; N_{vtx}; E}/E_{true} ",
1851 histname =
"eResVsR9";
1852 if (!isRunCentrally_)
1853 h2_eResVsR9_[0] = iBooker.
book2D(
1854 histname +
"All",
" All photons E/Etrue vs R9: all Ecal ",
r9Bin * 2,
r9Min,
r9Max, 100, 0., 2.5);
1855 if (!isRunCentrally_)
1856 h2_eResVsR9_[1] = iBooker.
book2D(
1857 histname +
"Barrel",
" All photons E/Etrue vs R9: Barrel ",
r9Bin * 2,
r9Min,
r9Max, 100, 0., 2.5);
1858 if (!isRunCentrally_)
1859 h2_eResVsR9_[2] = iBooker.
book2D(
1860 histname +
"Endcap",
" All photons E/Etrue vs R9: Endcap ",
r9Bin * 2,
r9Min,
r9Max, 100, 0., 2.5);
1861 histname =
"pEResVsR9";
1862 if (!isRunCentrally_)
1869 histname =
"sceResVsR9";
1870 if (!isRunCentrally_)
1871 h2_sceResVsR9_[0] = iBooker.
book2D(
1872 histname +
"All",
" All photons scE/Etrue vs R9: all Ecal ",
r9Bin * 2,
r9Min,
r9Max, 100, 0., 2.5);
1873 if (!isRunCentrally_)
1874 h2_sceResVsR9_[1] = iBooker.
book2D(
1875 histname +
"Barrel",
" All photons scE/Etrue vs R9: Barrel ",
r9Bin * 2,
r9Min,
r9Max, 100, 0., 2.5);
1876 if (!isRunCentrally_)
1877 h2_sceResVsR9_[2] = iBooker.
book2D(
1878 histname +
"Endcap",
" All photons scE/Etrue vs R9: Endcap ",
r9Bin * 2,
r9Min,
r9Max, 100, 0., 2.5);
1879 histname =
"scpEResVsR9";
1880 if (!isRunCentrally_)
1881 p_sceResVsR9_[0] = iBooker.
bookProfile(histname +
"All",
1882 " All photons scE/Etrue vs R9: all Ecal ",
1890 p_sceResVsR9_[1] = iBooker.
bookProfile(histname +
"Barrel",
1891 " All photons scE/Etrue vs R9: Barrel ",
1899 p_sceResVsR9_[2] = iBooker.
bookProfile(histname +
"Endcap",
1900 " All photons scE/Etrue vs R9: Endcap ",
1910 histname =
"eResRegr1";
1911 h_phoEResRegr1_[0][0] =
1913 h_phoEResRegr1_[0][1] =
1915 h_phoEResRegr1_[0][2] =
1918 h_phoEResRegr1_[1][0] = iBooker.
book1D(histname +
"unconvAll",
1919 " Photon rec/true Energy from Regression1 if r9>0.94, 0.95: All ecal ",
1923 h_phoEResRegr1_[1][1] = iBooker.
book1D(
1924 histname +
"unconvBarrel",
" Photon rec/true Energy from Regression1 if r9>0.94: Barrel ",
resBin,
resMin,
resMax);
1925 h_phoEResRegr1_[1][2] = iBooker.
book1D(
1926 histname +
"unconvEndcap",
" Photon rec/true Energy from Regression1 if r9>0.95: Endcap ",
resBin,
resMin,
resMax);
1928 h_phoEResRegr1_[2][0] = iBooker.
book1D(histname +
"convAll",
1929 " Photon rec/true Energy from Regression1if r9<0.0.94, 0.95: All ecal ",
1933 h_phoEResRegr1_[2][1] = iBooker.
book1D(
1934 histname +
"convBarrel",
" Photon rec/true Energy from Regression1 if r9<0.94: Barrel ",
resBin,
resMin,
resMax);
1935 h_phoEResRegr1_[2][2] = iBooker.
book1D(
1936 histname +
"convEndcap",
" Photon rec/true Energy from Regression1 if r9<0.95: Endcap ",
resBin,
resMin,
resMax);
1938 histname =
"eResRegr2";
1939 h_phoEResRegr2_[0][0] =
1941 h_phoEResRegr2_[0][1] =
1943 h_phoEResRegr2_[0][2] =
1946 h_phoEResRegr2_[1][0] = iBooker.
book1D(histname +
"unconvAll",
1947 " Photon rec/true Energy from Regression2 if r9>0.94, 0.95: All ecal ",
1951 h_phoEResRegr2_[1][1] = iBooker.
book1D(
1952 histname +
"unconvBarrel",
" Photon rec/true Energy from Regression2 if r9>0.94: Barrel ",
resBin,
resMin,
resMax);
1953 h_phoEResRegr2_[1][2] = iBooker.
book1D(
1954 histname +
"unconvEndcap",
" Photon rec/true Energy from Regression2 if r9>0.95: Endcap ",
resBin,
resMin,
resMax);
1956 h_phoEResRegr2_[2][0] = iBooker.
book1D(histname +
"convAll",
1957 " Photon rec/true Energy from Regression2 if r9<0.0.94, 0.95: All ecal ",
1961 h_phoEResRegr2_[2][1] = iBooker.
book1D(
1962 histname +
"convBarrel",
" Photon rec/true Energy from Regression2 if r9<0.94: Barrel ",
resBin,
resMin,
resMax);
1963 h_phoEResRegr2_[2][2] = iBooker.
book1D(
1964 histname +
"convEndcap",
" Photon rec/true Energy from Regression2 if r9<0.95: Endcap ",
resBin,
resMin,
resMax);
1966 histname =
"phoPixSeedSize";
1967 h_phoPixSeedSize_[0] = iBooker.
book1D(histname +
"Barrel",
"Pixel seeds size ", 100, 0., 100.);
1968 h_phoPixSeedSize_[1] = iBooker.
book1D(histname +
"Endcap",
"Pixel seeds size ", 100, 0., 100.);
1971 histname =
"chargedHadIso";
1972 h_chHadIso_[0] = iBooker.
book1D(histname +
"All",
"PF chargedHadIso: All Ecal",
etBin,
etMin, 20.);
1973 h_chHadIso_[1] = iBooker.
book1D(histname +
"Barrel",
"PF chargedHadIso: Barrel",
etBin,
etMin, 20.);
1974 h_chHadIso_[2] = iBooker.
book1D(histname +
"Endcap",
"PF chargedHadIso: Endcap",
etBin,
etMin, 20.);
1975 histname =
"neutralHadIso";
1976 h_nHadIso_[0] = iBooker.
book1D(histname +
"All",
"PF neutralHadIso: All Ecal",
etBin,
etMin, 20.);
1977 h_nHadIso_[1] = iBooker.
book1D(histname +
"Barrel",
"PF neutralHadIso: Barrel",
etBin,
etMin, 20.);
1978 h_nHadIso_[2] = iBooker.
book1D(histname +
"Endcap",
"PF neutralHadIso: Endcap",
etBin,
etMin, 20.);
1979 histname =
"photonIso";
1980 h_phoIso_[0] = iBooker.
book1D(histname +
"All",
"PF photonIso: All Ecal",
etBin,
etMin, 20.);
1981 h_phoIso_[1] = iBooker.
book1D(histname +
"Barrel",
"PF photonIso: Barrel",
etBin,
etMin, 20.);
1982 h_phoIso_[2] = iBooker.
book1D(histname +
"Endcap",
"PF photonIso: Endcap",
etBin,
etMin, 20.);
1983 histname =
"nCluOutMustache";
1984 h_nCluOutsideMustache_[0] =
1985 iBooker.
book1D(histname +
"All",
"PF number of clusters outside Mustache: All Ecal", 50, 0., 50.);
1986 h_nCluOutsideMustache_[1] =
1987 iBooker.
book1D(histname +
"Barrel",
"PF number of clusters outside Mustache: Barrel", 50, 0., 50.);
1988 h_nCluOutsideMustache_[2] =
1989 iBooker.
book1D(histname +
"Endcap",
"PF number of clusters outside Mustache: Endcap", 50, 0., 50.);
1990 histname =
"etOutMustache";
1991 h_etOutsideMustache_[0] = iBooker.
book1D(histname +
"All",
"PF et outside Mustache: All Ecal",
etBin,
etMin, 20.);
1992 h_etOutsideMustache_[1] = iBooker.
book1D(histname +
"Barrel",
"PF et outside Mustache: Barrel",
etBin,
etMin, 20.);
1993 h_etOutsideMustache_[2] = iBooker.
book1D(histname +
"Endcap",
"PF et outside Mustache: Endcap",
etBin,
etMin, 20.);
1995 h_pfMva_[0] = iBooker.
book1D(histname +
"All",
"PF MVA output: All Ecal", 50, -1., 2.);
1996 h_pfMva_[1] = iBooker.
book1D(histname +
"Barrel",
"PF MVA output: Barrel", 50, -1., 2.);
1997 h_pfMva_[2] = iBooker.
book1D(histname +
"Endcap",
"PF MVA output: Endcap", 50, -1, 2.);
1999 histname =
"SumPtOverPhoPt_ChHad_Cleaned";
2000 h_SumPtOverPhoPt_ChHad_Cleaned_[0] =
2001 iBooker.
book1D(histname +
"All",
"Pf Cand SumPt/P_{T}_{#gamma}: Charged Hadrons: All Ecal",
etBin,
etMin, 2.);
2002 h_SumPtOverPhoPt_ChHad_Cleaned_[1] =
2003 iBooker.
book1D(histname +
"Barrel",
"PF Cand SumPt/P_{T}_{#gamma}: Charged Hadrons: Barrel",
etBin,
etMin, 2.);
2004 h_SumPtOverPhoPt_ChHad_Cleaned_[2] =
2005 iBooker.
book1D(histname +
"Endcap",
"PF Cand SumPt/P_{T}_{#gamma}: Charged Hadrons: Endcap",
etBin,
etMin, 2.);
2006 histname =
"SumPtOverPhoPt_NeuHad_Cleaned";
2007 h_SumPtOverPhoPt_NeuHad_Cleaned_[0] =
2008 iBooker.
book1D(histname +
"All",
"Pf Cand SumPt/P_{T}_{#gamma}: Neutral Hadrons: All Ecal",
etBin,
etMin, 2.);
2009 h_SumPtOverPhoPt_NeuHad_Cleaned_[1] =
2010 iBooker.
book1D(histname +
"Barrel",
"PF Cand SumPt/P_{T}_{#gamma}: Neutral Hadrons: Barrel",
etBin,
etMin, 2.);
2011 h_SumPtOverPhoPt_NeuHad_Cleaned_[2] =
2012 iBooker.
book1D(histname +
"Endcap",
"PF Cand SumPt/P_{T}_{#gamma}: Neutral Hadrons: Endcap",
etBin,
etMin, 2.);
2013 histname =
"SumPtOverPhoPt_Pho_Cleaned";
2014 h_SumPtOverPhoPt_Pho_Cleaned_[0] =
2015 iBooker.
book1D(histname +
"All",
"Pf Cand SumPt/P_{T}_{#gamma}: Photons: All Ecal",
etBin,
etMin, 2.);
2016 h_SumPtOverPhoPt_Pho_Cleaned_[1] =
2017 iBooker.
book1D(histname +
"Barrel",
"PF Cand SumPt/P_{T}_{#gamma}: Photons: Barrel",
etBin,
etMin, 2.);
2018 h_SumPtOverPhoPt_Pho_Cleaned_[2] =
2019 iBooker.
book1D(histname +
"Endcap",
"PF Cand SumPt/P_{T}_{#gamma}: Photons: Endcap",
etBin,
etMin, 2.);
2021 histname =
"dRPhoPFcand_ChHad_Cleaned";
2022 h_dRPhoPFcand_ChHad_Cleaned_[0] =
2023 iBooker.
book1D(histname +
"All",
"dR(pho,cand) Charged Hadrons : All Ecal",
etBin,
etMin, 0.7);
2024 h_dRPhoPFcand_ChHad_Cleaned_[1] =
2025 iBooker.
book1D(histname +
"Barrel",
"dR(pho,cand) Charged Hadrons : Barrel",
etBin,
etMin, 0.7);
2026 h_dRPhoPFcand_ChHad_Cleaned_[2] =
2027 iBooker.
book1D(histname +
"Endcap",
"dR(pho,cand) Charged Hadrons : Endcap",
etBin,
etMin, 0.7);
2028 histname =
"dRPhoPFcand_NeuHad_Cleaned";
2029 h_dRPhoPFcand_NeuHad_Cleaned_[0] =
2030 iBooker.
book1D(histname +
"All",
"dR(pho,cand) Neutral Hadrons : All Ecal",
etBin,
etMin, 0.7);
2031 h_dRPhoPFcand_NeuHad_Cleaned_[1] =
2032 iBooker.
book1D(histname +
"Barrel",
"dR(pho,cand) Neutral Hadrons : Barrel",
etBin,
etMin, 0.7);
2033 h_dRPhoPFcand_NeuHad_Cleaned_[2] =
2034 iBooker.
book1D(histname +
"Endcap",
"dR(pho,cand) Neutral Hadrons : Endcap",
etBin,
etMin, 0.7);
2035 histname =
"dRPhoPFcand_Pho_Cleaned";
2036 h_dRPhoPFcand_Pho_Cleaned_[0] =
2037 iBooker.
book1D(histname +
"All",
"dR(pho,cand) Photons : All Ecal",
etBin,
etMin, 0.7);
2038 h_dRPhoPFcand_Pho_Cleaned_[1] =
2039 iBooker.
book1D(histname +
"Barrel",
"dR(pho,cand) Photons : Barrel",
etBin,
etMin, 0.7);
2040 h_dRPhoPFcand_Pho_Cleaned_[2] =
2041 iBooker.
book1D(histname +
"Endcap",
"dR(pho,cand) Photons : Endcap",
etBin,
etMin, 0.7);
2044 histname =
"SumPtOverPhoPt_ChHad_unCleaned";
2045 h_SumPtOverPhoPt_ChHad_unCleaned_[0] =
2046 iBooker.
book1D(histname +
"All",
"Pf Cand Sum Pt Over photon pt Charged Hadrons : All Ecal",
etBin,
etMin, 2.);
2047 h_SumPtOverPhoPt_ChHad_unCleaned_[1] =
2048 iBooker.
book1D(histname +
"Barrel",
"PF Cand Sum Pt Over photon pt Charged Hadrons: Barrel",
etBin,
etMin, 2.);
2049 h_SumPtOverPhoPt_ChHad_unCleaned_[2] =
2050 iBooker.
book1D(histname +
"Endcap",
"PF Cand Sum Pt Over photon pt Charged Hadrons: Endcap",
etBin,
etMin, 2.);
2051 histname =
"SumPtOverPhoPt_NeuHad_unCleaned";
2052 h_SumPtOverPhoPt_NeuHad_unCleaned_[0] =
2053 iBooker.
book1D(histname +
"All",
"Pf Cand Sum Pt Over photon pt Neutral Hadrons : All Ecal",
etBin,
etMin, 2.);
2054 h_SumPtOverPhoPt_NeuHad_unCleaned_[1] =
2055 iBooker.
book1D(histname +
"Barrel",
"PF Cand Sum Pt Over photon pt Neutral Hadrons: Barrel",
etBin,
etMin, 2.);
2056 h_SumPtOverPhoPt_NeuHad_unCleaned_[2] =
2057 iBooker.
book1D(histname +
"Endcap",
"PF Cand Sum Pt Over photon pt Neutral Hadrons: Endcap",
etBin,
etMin, 2.);
2058 histname =
"SumPtOverPhoPt_Pho_unCleaned";
2059 h_SumPtOverPhoPt_Pho_unCleaned_[0] =
2060 iBooker.
book1D(histname +
"All",
"Pf Cand Sum Pt Over photon pt Photons: All Ecal",
etBin,
etMin, 2.);
2061 h_SumPtOverPhoPt_Pho_unCleaned_[1] =
2062 iBooker.
book1D(histname +
"Barrel",
"PF Cand Sum Pt Over photon pt Photons: Barrel",
etBin,
etMin, 2.);
2063 h_SumPtOverPhoPt_Pho_unCleaned_[2] =
2064 iBooker.
book1D(histname +
"Endcap",
"PF Cand Sum Pt Over photon pt Photons: Endcap",
etBin,
etMin, 2.);
2065 histname =
"dRPhoPFcand_ChHad_unCleaned";
2066 h_dRPhoPFcand_ChHad_unCleaned_[0] =
2067 iBooker.
book1D(histname +
"All",
"dR(pho,cand) Charged Hadrons : All Ecal",
etBin,
etMin, 0.7);
2068 h_dRPhoPFcand_ChHad_unCleaned_[1] =
2069 iBooker.
book1D(histname +
"Barrel",
"dR(pho,cand) Charged Hadrons : Barrel",
etBin,
etMin, 0.7);
2070 h_dRPhoPFcand_ChHad_unCleaned_[2] =
2071 iBooker.
book1D(histname +
"Endcap",
"dR(pho,cand) Charged Hadrons : Endcap",
etBin,
etMin, 0.7);
2072 histname =
"dRPhoPFcand_NeuHad_unCleaned";
2073 h_dRPhoPFcand_NeuHad_unCleaned_[0] =
2074 iBooker.
book1D(histname +
"All",
"dR(pho,cand) Neutral Hadrons : All Ecal",
etBin,
etMin, 0.7);
2075 h_dRPhoPFcand_NeuHad_unCleaned_[1] =
2076 iBooker.
book1D(histname +
"Barrel",
"dR(pho,cand) Neutral Hadrons : Barrel",
etBin,
etMin, 0.7);
2077 h_dRPhoPFcand_NeuHad_unCleaned_[2] =
2078 iBooker.
book1D(histname +
"Endcap",
"dR(pho,cand) Neutral Hadrons : Endcap",
etBin,
etMin, 0.7);
2079 histname =
"dRPhoPFcand_Pho_unCleaned";
2080 h_dRPhoPFcand_Pho_unCleaned_[0] =
2081 iBooker.
book1D(histname +
"All",
"dR(pho,cand) Photons: All Ecal",
etBin,
etMin, 0.7);
2082 h_dRPhoPFcand_Pho_unCleaned_[1] =
2083 iBooker.
book1D(histname +
"Barrel",
"dR(pho,cand) Photons: Barrel",
etBin,
etMin, 0.7);
2084 h_dRPhoPFcand_Pho_unCleaned_[2] =
2085 iBooker.
book1D(histname +
"Endcap",
"dR(pho,cand) Photons: Endcap",
etBin,
etMin, 0.7);
2089 histname =
"gamgamMass";
2090 h_gamgamMass_[0][0] =
2092 h_gamgamMass_[0][1] =
2094 h_gamgamMass_[0][2] =
2097 histname =
"gamgamMassNoConv";
2098 h_gamgamMass_[1][0] = iBooker.
book1D(
2100 h_gamgamMass_[1][1] = iBooker.
book1D(
2102 h_gamgamMass_[1][2] = iBooker.
book1D(
2105 histname =
"gamgamMassConv";
2106 h_gamgamMass_[2][0] = iBooker.
book1D(
2108 h_gamgamMass_[2][1] = iBooker.
book1D(
2110 h_gamgamMass_[2][2] = iBooker.
book1D(
2113 histname =
"gamgamMassRegr1";
2114 h_gamgamMassRegr1_[0][0] =
2116 h_gamgamMassRegr1_[0][1] =
2118 h_gamgamMassRegr1_[0][2] =
2121 histname =
"gamgamMassRegr1NoConv";
2122 h_gamgamMassRegr1_[1][0] = iBooker.
book1D(
2124 h_gamgamMassRegr1_[1][1] = iBooker.
book1D(histname +
"Barrel",
2125 "2 photons with no conversion invariant mass Regr1: Barrel ",
2129 h_gamgamMassRegr1_[1][2] = iBooker.
book1D(histname +
"Endcap",
2130 "2 photons with no conversion invariant mass Regr1: Endcap ",
2135 histname =
"gamgamMassRegr1Conv";
2136 h_gamgamMassRegr1_[2][0] = iBooker.
book1D(
2138 h_gamgamMassRegr1_[2][1] = iBooker.
book1D(histname +
"Barrel",
2139 "2 photons with conversion invariant mass Regr1: Barrel ",
2143 h_gamgamMassRegr1_[2][2] = iBooker.
book1D(histname +
"Endcap",
2144 "2 photons with conversion invariant mass Regr1: Endcap ",
2149 histname =
"gamgamMassRegr2";
2150 h_gamgamMassRegr2_[0][0] =
2152 h_gamgamMassRegr2_[0][1] =
2154 h_gamgamMassRegr2_[0][2] =
2157 histname =
"gamgamMassRegr2NoConv";
2158 h_gamgamMassRegr2_[1][0] = iBooker.
book1D(
2160 h_gamgamMassRegr2_[1][1] = iBooker.
book1D(histname +
"Barrel",
2161 "2 photons with no conversion invariant mass Regr2: Barrel ",
2165 h_gamgamMassRegr2_[1][2] = iBooker.
book1D(histname +
"Endcap",
2166 "2 photons with no conversion invariant mass Regr2: Endcap ",
2171 histname =
"gamgamMassRegr2Conv";
2172 h_gamgamMassRegr2_[2][0] = iBooker.
book1D(
2174 h_gamgamMassRegr2_[2][1] = iBooker.
book1D(histname +
"Barrel",
2175 "2 photons with conversion invariant mass Regr2: Barrel ",
2179 h_gamgamMassRegr2_[2][2] = iBooker.
book1D(histname +
"Endcap",
2180 "2 photons with conversion invariant mass Regr2: Endcap ",
2192 h_phoE_miniAOD_[0][0] = iBooker.
book1D(histname +
"All_miniAOD",
" Photon Energy: All ecal ",
eBin,
eMin,
eMax);
2193 h_phoE_miniAOD_[0][1] = iBooker.
book1D(histname +
"Barrel_miniAOD",
" Photon Energy: barrel ",
eBin,
eMin,
eMax);
2194 h_phoE_miniAOD_[0][2] = iBooker.
book1D(histname +
"Endcap_miniAOD",
" Photon Energy: Endcap ",
eBin,
eMin,
eMax);
2197 h_phoEt_miniAOD_[0][0] =
2198 iBooker.
book1D(histname +
"All_miniAOD",
" Photon Transverse Energy: All ecal ",
etBin,
etMin,
etMax);
2199 h_phoEt_miniAOD_[0][1] =
2200 iBooker.
book1D(histname +
"Barrel_miniAOD",
" Photon Transverse Energy: Barrel ",
etBin,
etMin,
etMax);
2201 h_phoEt_miniAOD_[0][2] =
2202 iBooker.
book1D(histname +
"Endcap_miniAOD",
" Photon Transverse Energy: Endcap ",
etBin,
etMin,
etMax);
2205 h_phoERes_miniAOD_[0][0] = iBooker.
book1D(
2206 histname +
"All_miniAOD",
" Photon E/E_{true}: All ecal; E/E_{true} (GeV)",
resBin,
resMin,
resMax);
2207 h_phoERes_miniAOD_[0][1] = iBooker.
book1D(
2208 histname +
"Barrel_miniAOD",
"Photon E/E_{true}: Barrel; E/E_{true} (GeV)",
resBin,
resMin,
resMax);
2209 h_phoERes_miniAOD_[0][2] = iBooker.
book1D(
2210 histname +
"Endcap_miniAOD",
" Photon E/E_{true}: Endcap; E/E_{true} (GeV)",
resBin,
resMin,
resMax);
2212 histname =
"sigmaEoE";
2213 h_phoSigmaEoE_miniAOD_[0][0] =
2214 iBooker.
book1D(histname +
"All_miniAOD",
"#sigma_{E}/E: All ecal; #sigma_{E}/E", 100, 0., 0.08);
2215 h_phoSigmaEoE_miniAOD_[0][1] =
2216 iBooker.
book1D(histname +
"Barrel_miniAOD",
"#sigma_{E}/E: Barrel; #sigma_{E}/E", 100, 0., 0.08);
2217 h_phoSigmaEoE_miniAOD_[0][2] =
2218 iBooker.
book1D(histname +
"Endcap_miniAOD",
"#sigma_{E}/E: Endcap, #sigma_{E}/E", 100, 0., 0.08);
2221 h_r9_miniAOD_[0][0] = iBooker.
book1D(histname +
"All_miniAOD",
" r9: All Ecal",
r9Bin,
r9Min,
r9Max);
2222 h_r9_miniAOD_[0][1] = iBooker.
book1D(histname +
"Barrel_miniAOD",
" r9: Barrel ",
r9Bin,
r9Min,
r9Max);
2223 h_r9_miniAOD_[0][2] = iBooker.
book1D(histname +
"Endcap_miniAOD",
" r9: Endcap ",
r9Bin,
r9Min,
r9Max);
2224 histname =
"full5x5_r9";
2225 h_full5x5_r9_miniAOD_[0][0] = iBooker.
book1D(histname +
"All_miniAOD",
" r9: All Ecal",
r9Bin,
r9Min,
r9Max);
2226 h_full5x5_r9_miniAOD_[0][1] = iBooker.
book1D(histname +
"Barrel_miniAOD",
" r9: Barrel ",
r9Bin,
r9Min,
r9Max);
2227 h_full5x5_r9_miniAOD_[0][2] = iBooker.
book1D(histname +
"Endcap_miniAOD",
" r9: Endcap ",
r9Bin,
r9Min,
r9Max);
2229 h_r1_miniAOD_[0][0] = iBooker.
book1D(histname +
"All_miniAOD",
" e1x5/e5x5: All Ecal",
r9Bin,
r9Min,
r9Max);
2230 h_r1_miniAOD_[0][1] = iBooker.
book1D(histname +
"Barrel_miniAOD",
" e1x5/e5x5: Barrel ",
r9Bin,
r9Min,
r9Max);
2231 h_r1_miniAOD_[0][2] = iBooker.
book1D(histname +
"Endcap_miniAOD",
" e1x5/e5x5: Endcap ",
r9Bin,
r9Min,
r9Max);
2233 h_r2_miniAOD_[0][0] = iBooker.
book1D(histname +
"All_miniAOD",
" e2x5/e5x5: All Ecal",
r9Bin,
r9Min,
r9Max);
2234 h_r2_miniAOD_[0][1] = iBooker.
book1D(histname +
"Barrel_miniAOD",
" e2x5/e5x5: Barrel ",
r9Bin,
r9Min,
r9Max);
2235 h_r2_miniAOD_[0][2] = iBooker.
book1D(histname +
"Endcap_miniAOD",
" e2x5/e5x5: Endcap ",
r9Bin,
r9Min,
r9Max);
2236 histname =
"hOverE";
2237 h_hOverE_miniAOD_[0][0] = iBooker.
book1D(histname +
"All_miniAOD",
"H/E: All Ecal", 100, 0., 0.2);
2238 h_hOverE_miniAOD_[0][1] = iBooker.
book1D(histname +
"Barrel_miniAOD",
"H/E: Barrel ", 100, 0., 0.2);
2239 h_hOverE_miniAOD_[0][2] = iBooker.
book1D(histname +
"Endcap_miniAOD",
"H/E: Endcap ", 100, 0., 0.2);
2241 histname =
"newhOverE";
2242 h_newhOverE_miniAOD_[0][0] = iBooker.
book1D(histname +
"All_miniAOD",
"new H/E: All Ecal", 100, 0., 0.2);
2243 h_newhOverE_miniAOD_[0][1] = iBooker.
book1D(histname +
"Barrel_miniAOD",
"new H/E: Barrel ", 100, 0., 0.2);
2244 h_newhOverE_miniAOD_[0][2] = iBooker.
book1D(histname +
"Endcap_miniAOD",
"new H/E: Endcap ", 100, 0., 0.2);
2246 histname =
"sigmaIetaIeta";
2247 h_sigmaIetaIeta_miniAOD_[0][0] = iBooker.
book1D(histname +
"All_miniAOD",
"sigmaIetaIeta: All Ecal", 100, 0., 0.1);
2248 h_sigmaIetaIeta_miniAOD_[0][1] = iBooker.
book1D(histname +
"Barrel_miniAOD",
"sigmaIetaIeta: Barrel ", 100, 0., 0.05);
2249 h_sigmaIetaIeta_miniAOD_[0][2] = iBooker.
book1D(histname +
"Endcap_miniAOD",
"sigmaIetaIeta: Endcap ", 100, 0., 0.1);
2250 histname =
"full5x5_sigmaIetaIeta";
2251 h_full5x5_sigmaIetaIeta_miniAOD_[0][0] =
2252 iBooker.
book1D(histname +
"All_miniAOD",
"Full5x5 sigmaIetaIeta: All Ecal", 100, 0., 0.1);
2253 h_full5x5_sigmaIetaIeta_miniAOD_[0][1] =
2254 iBooker.
book1D(histname +
"Barrel_miniAOD",
"Full5x5 sigmaIetaIeta: Barrel ", 100, 0., 0.05);
2255 h_full5x5_sigmaIetaIeta_miniAOD_[0][2] =
2256 iBooker.
book1D(histname +
"Endcap_miniAOD",
"Full5x5 sigmaIetaIeta: Endcap ", 100, 0., 0.1);
2258 histname =
"ecalRecHitSumEtConeDR04";
2259 h_ecalRecHitSumEtConeDR04_miniAOD_[0][0] =
2260 iBooker.
book1D(histname +
"All_miniAOD",
"ecalRecHitSumEtDR04: All Ecal",
etBin,
etMin, 20.);
2261 h_ecalRecHitSumEtConeDR04_miniAOD_[0][1] =
2262 iBooker.
book1D(histname +
"Barrel_miniAOD",
"ecalRecHitSumEtDR04: Barrel ",
etBin,
etMin, 20.);
2263 h_ecalRecHitSumEtConeDR04_miniAOD_[0][2] =
2264 iBooker.
book1D(histname +
"Endcap_miniAOD",
"ecalRecHitSumEtDR04: Endcap ",
etBin,
etMin, 20.);
2265 histname =
"hcalTowerSumEtConeDR04";
2266 h_hcalTowerSumEtConeDR04_miniAOD_[0][0] =
2267 iBooker.
book1D(histname +
"All_miniAOD",
"hcalTowerSumEtConeDR04: All Ecal",
etBin,
etMin, 20.);
2268 h_hcalTowerSumEtConeDR04_miniAOD_[0][1] =
2269 iBooker.
book1D(histname +
"Barrel_miniAOD",
"hcalTowerSumEtConeDR04: Barrel ",
etBin,
etMin, 20.);
2270 h_hcalTowerSumEtConeDR04_miniAOD_[0][2] =
2271 iBooker.
book1D(histname +
"Endcap_miniAOD",
"hcalTowerSumEtConeDR04: Endcap ",
etBin,
etMin, 20.);
2273 histname =
"hcalTowerBcSumEtConeDR04";
2274 h_hcalTowerBcSumEtConeDR04_miniAOD_[0][0] =
2275 iBooker.
book1D(histname +
"All_miniAOD",
"hcalTowerBcSumEtConeDR04: All Ecal",
etBin,
etMin, 20.);
2276 h_hcalTowerBcSumEtConeDR04_miniAOD_[0][1] =
2277 iBooker.
book1D(histname +
"Barrel_miniAOD",
"hcalTowerBcSumEtConeDR04: Barrel ",
etBin,
etMin, 20.);
2278 h_hcalTowerBcSumEtConeDR04_miniAOD_[0][2] =
2279 iBooker.
book1D(histname +
"Endcap_miniAOD",
"hcalTowerBcSumEtConeDR04: Endcap ",
etBin,
etMin, 20.);
2280 histname =
"isoTrkSolidConeDR04";
2281 h_isoTrkSolidConeDR04_miniAOD_[0][0] =
2282 iBooker.
book1D(histname +
"All_miniAOD",
"isoTrkSolidConeDR04: All Ecal",
etBin,
etMin,
etMax * 0.1);
2283 h_isoTrkSolidConeDR04_miniAOD_[0][1] =
2284 iBooker.
book1D(histname +
"Barrel_miniAOD",
"isoTrkSolidConeDR04: Barrel ",
etBin,
etMin,
etMax * 0.1);
2285 h_isoTrkSolidConeDR04_miniAOD_[0][2] =
2286 iBooker.
book1D(histname +
"Endcap_miniAOD",
"isoTrkSolidConeDR04: Endcap ",
etBin,
etMin,
etMax * 0.1);
2287 histname =
"nTrkSolidConeDR04";
2288 h_nTrkSolidConeDR04_miniAOD_[0][0] =
2289 iBooker.
book1D(histname +
"All_miniAOD",
"nTrkSolidConeDR04: All Ecal", 20, 0., 20);
2290 h_nTrkSolidConeDR04_miniAOD_[0][1] =
2291 iBooker.
book1D(histname +
"Barrel_miniAOD",
"nTrkSolidConeDR04: Barrel ", 20, 0., 20);
2292 h_nTrkSolidConeDR04_miniAOD_[0][2] =
2293 iBooker.
book1D(histname +
"Endcap_miniAOD",
"nTrkSolidConeDR04: Endcap ", 20, 0., 20);
2296 histname =
"chargedHadIso";
2297 h_chHadIso_miniAOD_[0] = iBooker.
book1D(histname +
"All_miniAOD",
"PF chargedHadIso: All Ecal",
etBin,
etMin, 20.);
2298 h_chHadIso_miniAOD_[1] = iBooker.
book1D(histname +
"Barrel_miniAOD",
"PF chargedHadIso: Barrel",
etBin,
etMin, 20.);
2299 h_chHadIso_miniAOD_[2] = iBooker.
book1D(histname +
"Endcap_miniAOD",
"PF chargedHadIso: Endcap",
etBin,
etMin, 20.);
2300 histname =
"neutralHadIso";
2301 h_nHadIso_miniAOD_[0] = iBooker.
book1D(histname +
"All_miniAOD",
"PF neutralHadIso: All Ecal",
etBin,
etMin, 20.);
2302 h_nHadIso_miniAOD_[1] = iBooker.
book1D(histname +
"Barrel_miniAOD",
"PF neutralHadIso: Barrel",
etBin,
etMin, 20.);
2303 h_nHadIso_miniAOD_[2] = iBooker.
book1D(histname +
"Endcap_miniAOD",
"PF neutralHadIso: Endcap",
etBin,
etMin, 20.);
2304 histname =
"photonIso";
2305 h_phoIso_miniAOD_[0] = iBooker.
book1D(histname +
"All_miniAOD",
"PF photonIso: All Ecal",
etBin,
etMin, 20.);
2306 h_phoIso_miniAOD_[1] = iBooker.
book1D(histname +
"Barrel_miniAOD",
"PF photonIso: Barrel",
etBin,
etMin, 20.);
2307 h_phoIso_miniAOD_[2] = iBooker.
book1D(histname +
"Endcap_miniAOD",
"PF photonIso: Endcap",
etBin,
etMin, 20.);
2312 h_nConv_[0][0] = iBooker.
book1D(histname +
"All",
2313 "Number Of two-tracks Conversions per isolated candidates per events: All Ecal ",
2317 h_nConv_[0][1] = iBooker.
book1D(histname +
"Barrel",
2318 "Number Of two-tracks Conversions per isolated candidates per events: Ecal Barrel ",
2322 h_nConv_[0][2] = iBooker.
book1D(histname +
"Endcap",
2323 "Number Of two-tracks Conversions per isolated candidates per events: Ecal Endcap ",
2327 h_nConv_[1][0] = iBooker.
book1D(histname +
"OneLegAll",
2328 "Number Of single leg Conversions per isolated candidates per events: All Ecal ",
2332 h_nConv_[1][1] = iBooker.
book1D(histname +
"OneLegBarrel",
2333 "Number Of single leg Conversions per isolated candidates per events: Ecal Barrel ",
2337 h_nConv_[1][2] = iBooker.
book1D(histname +
"OneLegEndcap",
2338 "Number Of single leg Conversions per isolated candidates per events: Ecal Endcap ",
2345 h_convEta_[2] = iBooker.
book1D(
"convEta2ass",
" converted Photon Eta =2 tracks, both ass ",
etaBin,
etaMin,
etaMax);
2348 histname =
"convERes";
2356 histname =
"p_EResVsR";
2358 histname +
"All",
" photons conversion E/Etrue vs R: all Ecal ",
rBin,
rMin,
rMax, 100, 0., 1.5,
"");
2360 histname =
"convPtRes";
2361 h_convPtRes_[1][0] =
2362 iBooker.
book1D(histname +
"All",
" Conversion Pt rec/true from tracks : All ecal ",
resBin, 0., 1.5);
2363 h_convPtRes_[1][1] =
2364 iBooker.
book1D(histname +
"Barrel",
" Conversion Pt rec/true from tracks: Barrel ",
resBin, 0., 1.5);
2365 h_convPtRes_[1][2] =
2366 iBooker.
book1D(histname +
"Endcap",
" Conversion Pt rec/true from tracks: Endcap ",
resBin, 0., 1.5);
2368 if (!isRunCentrally_) {
2369 histname =
"r9VsTracks";
2370 h_r9VsNofTracks_[0][0] = iBooker.
book2D(
2371 histname +
"All",
" photons r9 vs nTracks from conversions: All Ecal",
r9Bin,
r9Min,
r9Max, 3, -0.5, 2.5);
2372 h_r9VsNofTracks_[0][1] = iBooker.
book2D(
2373 histname +
"Barrel",
" photons r9 vs nTracks from conversions: Barrel Ecal",
r9Bin,
r9Min,
r9Max, 3, -0.5, 2.5);
2374 h_r9VsNofTracks_[0][2] = iBooker.
book2D(
2375 histname +
"Endcap",
" photons r9 vs nTracks from conversions: Endcap Ecal",
r9Bin,
r9Min,
r9Max, 3, -0.5, 2.5);
2378 histname =
"mvaOut";
2379 h_mvaOut_[0] = iBooker.
book1D(histname +
"All",
" mvaOut for all conversions : All Ecal", 100, 0., 1.);
2380 h_mvaOut_[1] = iBooker.
book1D(histname +
"Barrel",
" mvaOut for all conversions : Barrel Ecal", 100, 0., 1.);
2381 h_mvaOut_[2] = iBooker.
book1D(histname +
"Endcap",
" mvaOut for all conversions : Endcap Ecal", 100, 0., 1.);
2383 histname =
"EoverPtracks";
2384 h_EoverPTracks_[0][0] =
2386 h_EoverPTracks_[0][1] =
2388 h_EoverPTracks_[0][2] =
2391 h_EoverPTracks_[1][0] = iBooker.
book1D(histname +
"All",
" photons conversion E/p: all Ecal ", 100, 0., 5.);
2392 h_EoverPTracks_[1][1] = iBooker.
book1D(histname +
"Barrel",
" photons conversion E/p: Barrel Ecal", 100, 0., 5.);
2393 h_EoverPTracks_[1][2] = iBooker.
book1D(histname +
"Endcap",
" photons conversion E/p: Endcap Ecal ", 100, 0., 5.);
2394 histname =
"EoverP_SL";
2395 h_EoverP_SL_[0] = iBooker.
book1D(histname +
"All",
" photons single leg conversion E/p: all Ecal ", 100, 0., 5.);
2396 h_EoverP_SL_[1] = iBooker.
book1D(histname +
"Barrel",
" photons single leg conversion E/p: Barrel Ecal", 100, 0., 5.);
2398 iBooker.
book1D(histname +
"Endcap",
" photons single leg conversion E/p: Endcap Ecal ", 100, 0., 5.);
2400 histname =
"PoverEtracks";
2401 h_PoverETracks_[1][0] =
2403 h_PoverETracks_[1][1] =
2405 h_PoverETracks_[1][2] =
2408 histname =
"pEoverEtrueVsEta";
2409 p_EoverEtrueVsEta_[0] =
2411 " photons conversion with 2 (associated) reco tracks E/Etrue vs #eta: all Ecal ",
2420 histname =
"pEoverEtrueVsR";
2422 histname +
"All",
" photons conversion E/Etrue vs R: all Ecal ",
rBin,
rMin,
rMax, 100, 0., 2.5,
"");
2424 histname =
"pEoverEtrueVsEta";
2425 p_EoverEtrueVsEta_[1] = iBooker.
bookProfile(histname +
"All2",
2426 " photons conversion 2 reco tracks E/Etrue vs #eta: all Ecal ",
2435 histname =
"pPoverPtrueVsEta";
2437 histname +
"All",
" photons conversion P/Ptrue vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 5.,
"");
2439 histname =
"pEoverPVsEta";
2441 histname +
"All",
" photons conversion E/P vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 5.,
"");
2443 if (!isRunCentrally_) {
2444 histname =
"EoverEtrueVsEoverP";
2445 h2_EoverEtrueVsEoverP_[0] =
2446 iBooker.
book2D(histname +
"All",
" photons conversion E/Etrue vs E/P: all Ecal ", 100, 0., 5., 100, 0.5, 1.5);
2447 h2_EoverEtrueVsEoverP_[1] = iBooker.
book2D(
2448 histname +
"Barrel",
" photons conversion E/Etrue vs E/: Barrel Ecal", 100, 0., 5., 100, 0.5, 1.5);
2449 h2_EoverEtrueVsEoverP_[2] = iBooker.
book2D(
2450 histname +
"Endcap",
" photons conversion E/Etrue vs E/: Endcap Ecal ", 100, 0., 5., 100, 0.5, 1.5);
2451 histname =
"PoverPtrueVsEoverP";
2452 h2_PoverPtrueVsEoverP_[0] =
2453 iBooker.
book2D(histname +
"All",
" photons conversion P/Ptrue vs E/P: all Ecal ", 100, 0., 5., 100, 0., 2.5);
2454 h2_PoverPtrueVsEoverP_[1] = iBooker.
book2D(
2455 histname +
"Barrel",
" photons conversion P/Ptrue vs E/: Barrel Ecal", 100, 0., 5., 100, 0., 2.5);
2456 h2_PoverPtrueVsEoverP_[2] = iBooker.
book2D(
2457 histname +
"Endcap",
" photons conversion P/Ptrue vs E/: Endcap Ecal ", 100, 0., 5., 100, 0., 2.5);
2459 histname =
"EoverEtrueVsEta";
2460 h2_EoverEtrueVsEta_[0] =
2461 iBooker.
book2D(histname +
"All",
2462 " photons conversion with 2 (associated) reco tracks E/Etrue vs #eta: all Ecal ",
2470 histname =
"EoverEtrueVsEta";
2471 h2_EoverEtrueVsEta_[1] = iBooker.
book2D(histname +
"All2",
2472 " photons conversion 2 reco tracks E/Etrue vs #eta: all Ecal ",
2480 histname =
"EoverEtrueVsR";
2481 h2_EoverEtrueVsR_[0] =
2482 iBooker.
book2D(histname +
"All",
" photons conversion E/Etrue vs R: all Ecal ",
rBin,
rMin,
rMax, 100, 0., 2.5);
2484 histname =
"PoverPtrueVsEta";
2485 h2_PoverPtrueVsEta_[0] = iBooker.
book2D(
2486 histname +
"All",
" photons conversion P/Ptrue vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 5.);
2488 histname =
"EoverPVsEta";
2489 h2_EoverPVsEta_[0] = iBooker.
book2D(
2490 histname +
"All",
" photons conversion E/P vs #eta: all Ecal ",
etaBin2,
etaMin,
etaMax, 100, 0., 5.);
2492 histname =
"EoverPVsR";
2494 iBooker.
book2D(histname +
"All",
" photons conversion E/P vs R: all Ecal ",
rBin,
rMin,
rMax, 100, 0., 5.);
2496 histname =
"etaVsRsim";
2497 h2_etaVsRsim_[0] = iBooker.
book2D(histname +
"All",
2498 " eta(sim) vs R (sim) for associated conversions: all Ecal ",
2505 histname =
"etaVsRreco";
2506 h2_etaVsRreco_[0] = iBooker.
book2D(histname +
"All",
2507 " eta(reco) vs R (reco) for associated conversions: all Ecal ",
2516 histname =
"pEoverPVsR";
2518 histname +
"All",
" photons conversion E/P vs R: all Ecal ",
rBin,
rMin,
rMax, 100, 0., 5.,
"");
2520 histname =
"hInvMass";
2521 h_invMass_[0][0] = iBooker.
book1D(
2522 histname +
"All_AllTracks",
" Photons:Tracks from conversion: Pair invariant mass: all Ecal ", 100, 0., 1.5);
2523 h_invMass_[0][1] = iBooker.
book1D(
2524 histname +
"Barrel_AllTracks",
" Photons:Tracks from conversion: Pair invariant mass: Barrel Ecal ", 100, 0., 1.5);
2525 h_invMass_[0][2] = iBooker.
book1D(
2526 histname +
"Endcap_AllTracks",
" Photons:Tracks from conversion: Pair invariant mass: Endcap Ecal ", 100, 0., 1.5);
2527 histname =
"hInvMass";
2528 h_invMass_[1][0] = iBooker.
book1D(
2529 histname +
"All_AssTracks",
" Photons:Tracks from conversion: Pair invariant mass: all Ecal ", 100, 0., 1.5);
2530 h_invMass_[1][1] = iBooker.
book1D(
2531 histname +
"Barrel_AssTracks",
" Photons:Tracks from conversion: Pair invariant mass: Barrel Ecal ", 100, 0., 1.5);
2532 h_invMass_[1][2] = iBooker.
book1D(
2533 histname +
"Endcap_AssTracks",
" Photons:Tracks from conversion: Pair invariant mass: Endcap Ecal ", 100, 0., 1.5);
2535 histname =
"hDPhiTracksAtVtx";
2536 h_DPhiTracksAtVtx_[1][0] = iBooker.
book1D(histname +
"All",
2537 " Photons:Tracks from conversions: #delta#phi Tracks at vertex: all Ecal",
2541 h_DPhiTracksAtVtx_[1][1] =
2542 iBooker.
book1D(histname +
"Barrel",
2543 " Photons:Tracks from conversions: #delta#phi Tracks at vertex: Barrel Ecal",
2547 h_DPhiTracksAtVtx_[1][2] =
2548 iBooker.
book1D(histname +
"Endcap",
2549 " Photons:Tracks from conversions: #delta#phi Tracks at vertex: Endcap Ecal",
2554 if (!isRunCentrally_) {
2555 histname =
"hDPhiTracksAtVtxVsEta";
2556 h2_DPhiTracksAtVtxVsEta_ = iBooker.
book2D(histname +
"All",
2557 " Photons:Tracks from conversions: #delta#phi Tracks at vertex vs #eta",
2565 histname =
"hDPhiTracksAtVtxVsR";
2566 h2_DPhiTracksAtVtxVsR_ = iBooker.
book2D(histname +
"All",
2567 " Photons:Tracks from conversions: #delta#phi Tracks at vertex vs R",
2575 histname =
"hDCotTracksVsEta";
2576 h2_DCotTracksVsEta_ = iBooker.
book2D(histname +
"All",
2577 " Photons:Tracks from conversions: #delta cotg(#Theta) Tracks vs #eta",
2585 histname =
"hDCotTracksVsR";
2586 h2_DCotTracksVsR_ = iBooker.
book2D(histname +
"All",
2587 " Photons:Tracks from conversions: #delta cotg(#Theta) Tracks at vertex vs R",
2595 histname =
"h2_DPhiTracksAtEcalVsR";
2596 if (fName_ !=
"pfPhotonValidator" && fName_ !=
"oldpfPhotonValidator")
2597 h2_DPhiTracksAtEcalVsR_ = iBooker.
book2D(histname +
"All",
2598 " Photons:Tracks from conversions: #delta#phi at Ecal vs R : all Ecal ",
2606 histname =
"h2_DPhiTracksAtEcalVsEta";
2607 if (fName_ !=
"pfPhotonValidator" && fName_ !=
"oldpfPhotonValidator")
2608 h2_DPhiTracksAtEcalVsEta_ =
2609 iBooker.
book2D(histname +
"All",
2610 " Photons:Tracks from conversions: #delta#phi at Ecal vs #eta : all Ecal ",
2619 histname =
"pDPhiTracksAtVtxVsEta";
2620 p_DPhiTracksAtVtxVsEta_ =
2622 " Photons:Tracks from conversions: #delta#phi Tracks at vertex vs #eta ",
2631 histname =
"pDPhiTracksAtVtxVsR";
2632 p_DPhiTracksAtVtxVsR_ = iBooker.
bookProfile(histname +
"All",
2633 " Photons:Tracks from conversions: #delta#phi Tracks at vertex vs R ",
2642 histname =
"hDCotTracks";
2643 h_DCotTracks_[1][0] = iBooker.
book1D(histname +
"All",
2644 " Photons:Tracks from conversions #delta cotg(#Theta) Tracks: all Ecal ",
2648 h_DCotTracks_[1][1] = iBooker.
book1D(histname +
"Barrel",
2649 " Photons:Tracks from conversions #delta cotg(#Theta) Tracks: Barrel Ecal ",
2653 h_DCotTracks_[1][2] = iBooker.
book1D(histname +
"Endcap",
2654 " Photons:Tracks from conversions #delta cotg(#Theta) Tracks: Endcap Ecal ",
2659 histname =
"pDCotTracksVsEta";
2660 p_DCotTracksVsEta_ = iBooker.
bookProfile(histname +
"All",
2661 " Photons:Tracks from conversions: #delta cotg(#Theta) Tracks vs #eta ",
2670 histname =
"pDCotTracksVsR";
2673 " Photons:Tracks from conversions: #delta cotg(#Theta) Tracks at vertex vs R ",
2682 histname =
"hDistMinAppTracks";
2683 h_distMinAppTracks_[1][0] = iBooker.
book1D(histname +
"All",
2684 " Photons:Tracks from conversions Min Approach Dist Tracks: all Ecal ",
2688 h_distMinAppTracks_[1][1] = iBooker.
book1D(histname +
"Barrel",
2689 " Photons:Tracks from conversions Min Approach Dist Tracks: Barrel Ecal ",
2693 h_distMinAppTracks_[1][2] = iBooker.
book1D(histname +
"Endcap",
2694 " Photons:Tracks from conversions Min Approach Dist Tracks: Endcap Ecal ",
2700 histname =
"hDPhiTracksAtEcal";
2701 h_DPhiTracksAtEcal_[1][0] = iBooker.
book1D(histname +
"All",
2702 " Photons:Tracks from conversions: #delta#phi at Ecal : all Ecal ",
2706 h_DPhiTracksAtEcal_[1][1] = iBooker.
book1D(histname +
"Barrel",
2707 " Photons:Tracks from conversions: #delta#phi at Ecal : Barrel Ecal ",
2711 h_DPhiTracksAtEcal_[1][2] = iBooker.
book1D(histname +
"Endcap",
2712 " Photons:Tracks from conversions: #delta#phi at Ecal : Endcap Ecal ",
2717 histname =
"pDPhiTracksAtEcalVsR";
2718 p_DPhiTracksAtEcalVsR_ = iBooker.
bookProfile(histname +
"All",
2719 " Photons:Tracks from conversions: #delta#phi at Ecal vs R ",
2728 histname =
"pDPhiTracksAtEcalVsEta";
2729 p_DPhiTracksAtEcalVsEta_ = iBooker.
bookProfile(histname +
"All",
2730 " Photons:Tracks from conversions: #delta#phi at Ecal vs #eta ",
2739 histname =
"hDEtaTracksAtEcal";
2740 h_DEtaTracksAtEcal_[1][0] = iBooker.
book1D(histname +
"All",
2741 " Photons:Tracks from conversions: #delta#eta at Ecal : all Ecal ",
2745 h_DEtaTracksAtEcal_[1][1] = iBooker.
book1D(histname +
"Barrel",
2746 " Photons:Tracks from conversions: #delta#eta at Ecal : Barrel Ecal ",
2750 h_DEtaTracksAtEcal_[1][2] = iBooker.
book1D(histname +
"Endcap",
2751 " Photons:Tracks from conversions: #delta#eta at Ecal : Endcap Ecal ",
2758 h_convVtxRvsZ_[0] = iBooker.
book2D(
"convVtxRvsZAll",
2759 " Photon Reco conversion vtx position",
2766 h_convVtxRvsZ_[1] = iBooker.
book2D(
"convVtxRvsZBarrel",
2767 " Photon Reco conversion vtx position",
2774 h_convVtxRvsZ_[2] = iBooker.
book2D(
"convVtxRvsZEndcap",
2775 " Photon Reco conversion vtx position",
2782 h_convVtxYvsX_ = iBooker.
book2D(
2783 "convVtxYvsXTrkBarrel",
" Photon Reco conversion vtx position, (x,y) eta<1 ", 100, -80., 80., 100, -80., 80.);
2785 h_convSLVtxRvsZ_[0] = iBooker.
book2D(
"convSLVtxRvsZAll",
2786 " Photon Reco single leg conversion innermost hit position",
2793 h_convSLVtxRvsZ_[1] = iBooker.
book2D(
"convSLVtxRvsZBarrel",
2794 " Photon Reco single leg conversion innermost hit position",
2801 h_convSLVtxRvsZ_[2] = iBooker.
book2D(
"convSLVtxRvsZEndcap",
2802 " Photon Reco single leg conversion innermost hit position",
2811 if (!isRunCentrally_) {
2812 h_convVtxRvsZ_zoom_[0] = iBooker.
book2D(
"convVtxRvsZBarrelZoom1",
2813 " Photon Reco conversion vtx position",
2820 h_convVtxRvsZ_zoom_[1] = iBooker.
book2D(
"convVtxRvsZBarrelZoom2",
2821 " Photon Reco conversion vtx position",
2828 h_convVtxYvsX_zoom_[0] = iBooker.
book2D(
"convVtxYvsXTrkBarrelZoom1",
2829 " Photon Reco conversion vtx position, (x,y) eta<1 ",
2836 h_convVtxYvsX_zoom_[1] = iBooker.
book2D(
"convVtxYvsXTrkBarrelZoom2",
2837 " Photon Reco conversion vtx position, (x,y) eta<1 ",
2846 h_convVtxdX_ = iBooker.
book1D(
"convVtxdX",
" Photon Reco conversion vtx dX", 100, -20., 20.);
2847 h_convVtxdY_ = iBooker.
book1D(
"convVtxdY",
" Photon Reco conversion vtx dY", 100, -20., 20.);
2848 h_convVtxdZ_ = iBooker.
book1D(
"convVtxdZ",
" Photon Reco conversion vtx dZ", 100, -20., 20.);
2849 h_convVtxdR_ = iBooker.
book1D(
"convVtxdR",
" Photon Reco conversion vtx dR", 100, -20., 20.);
2851 h_convVtxdX_barrel_ =
2852 iBooker.
book1D(
"convVtxdX_barrel",
" Photon Reco conversion vtx dX, |eta|<=1.2", 100, -20., 20.);
2853 h_convVtxdY_barrel_ =
2854 iBooker.
book1D(
"convVtxdY_barrel",
" Photon Reco conversion vtx dY, |eta|<=1.2 ", 100, -20., 20.);
2855 h_convVtxdZ_barrel_ =
2856 iBooker.
book1D(
"convVtxdZ_barrel",
" Photon Reco conversion vtx dZ, |eta|<=1.2,", 100, -20., 20.);
2857 h_convVtxdR_barrel_ =
2858 iBooker.
book1D(
"convVtxdR_barrel",
" Photon Reco conversion vtx dR, |eta|<=1.2", 100, -20., 20.);
2859 h_convVtxdX_endcap_ =
2860 iBooker.
book1D(
"convVtxdX_endcap",
" Photon Reco conversion vtx dX, |eta|>1.2", 100, -20., 20.);
2861 h_convVtxdY_endcap_ =
2862 iBooker.
book1D(
"convVtxdY_endcap",
" Photon Reco conversion vtx dY, |eta|>1.2", 100, -20., 20.);
2863 h_convVtxdZ_endcap_ =
2864 iBooker.
book1D(
"convVtxdZ_endcap",
" Photon Reco conversion vtx dZ, |eta|>1.2", 100, -20., 20.);
2865 h_convVtxdR_endcap_ =
2866 iBooker.
book1D(
"convVtxdR_endcap",
" Photon Reco conversion vtx dR, |eta|>1.2 ", 100, -20., 20.);
2868 h_convVtxdPhi_ = iBooker.
book1D(
"convVtxdPhi",
" Photon Reco conversion vtx dPhi", 100, -0.005, 0.005);
2869 h_convVtxdEta_ = iBooker.
book1D(
"convVtxdEta",
" Photon Reco conversion vtx dEta", 100, -0.5, 0.5);
2871 if (!isRunCentrally_) {
2873 iBooker.
book2D(
"h2ConvVtxdRVsR",
"Photon Reco conversion vtx dR vsR",
rBin,
rMin,
rMax, 100, -20., 20.);
2874 h2_convVtxdRVsEta_ = iBooker.
book2D(
2875 "h2ConvVtxdRVsEta",
"Photon Reco conversion vtx dR vs Eta",
etaBin2,
etaMin,
etaMax, 100, -20., 20.);
2879 iBooker.
bookProfile(
"pConvVtxdRVsR",
"Photon Reco conversion vtx dR vsR",
rBin,
rMin,
rMax, 100, -20., 20.,
"");
2881 "pConvVtxdRVsEta",
"Photon Reco conversion vtx dR vs Eta",
etaBin2,
etaMin,
etaMax, 100, -20., 20.,
"");
2882 p_convVtxdXVsX_ = iBooker.
bookProfile(
"pConvVtxdXVsX",
"Conversion vtx dX vs X", 120, -60, 60, 100, -20., 20.,
"");
2883 p_convVtxdYVsY_ = iBooker.
bookProfile(
"pConvVtxdYVsY",
"Conversion vtx dY vs Y", 120, -60, 60, 100, -20., 20.,
"");
2887 if (!isRunCentrally_) {
2888 h2_convVtxRrecVsTrue_ = iBooker.
book2D(
2892 histname =
"vtxChi2";
2893 h_vtxChi2_[0] = iBooker.
book1D(histname +
"All",
"vertex #chi^{2} all", 100,
chi2Min,
chi2Max);
2894 h_vtxChi2_[1] = iBooker.
book1D(histname +
"Barrel",
"vertex #chi^{2} barrel", 100,
chi2Min,
chi2Max);
2895 h_vtxChi2_[2] = iBooker.
book1D(histname +
"Endcap",
"vertex #chi^{2} endcap", 100,
chi2Min,
chi2Max);
2896 histname =
"vtxChi2Prob";
2897 h_vtxChi2Prob_[0] = iBooker.
book1D(histname +
"All",
"vertex #chi^{2} all", 100, 0., 1.);
2898 h_vtxChi2Prob_[1] = iBooker.
book1D(histname +
"Barrel",
"vertex #chi^{2} barrel", 100, 0., 1.);
2899 h_vtxChi2Prob_[2] = iBooker.
book1D(histname +
"Endcap",
"vertex #chi^{2} endcap", 100, 0., 1.);
2901 histname =
"zPVFromTracks";
2902 h_zPVFromTracks_[0] = iBooker.
book1D(histname +
"All",
" Photons: PV z from conversion tracks", 100, -30., 30.);
2903 h_zPVFromTracks_[1] = iBooker.
book1D(histname +
"Barrel",
" Photons: PV z from conversion tracks", 100, -30., 30.);
2904 h_zPVFromTracks_[2] = iBooker.
book1D(histname +
"Endcap",
" Photons: PV z from conversion tracks", 100, -30., 30.);
2905 h_zPVFromTracks_[3] = iBooker.
book1D(histname +
"EndcapP",
" Photons: PV z from conversion tracks", 100, -30., 30.);
2906 h_zPVFromTracks_[4] = iBooker.
book1D(histname +
"EndcapM",
" Photons: PV z from conversion tracks", 100, -30., 30.);
2907 histname =
"dzPVFromTracks";
2908 h_dzPVFromTracks_[0] =
2909 iBooker.
book1D(histname +
"All",
" Photons: PV Z_rec - Z_true from conversion tracks", 100, -10., 10.);
2910 h_dzPVFromTracks_[1] =
2911 iBooker.
book1D(histname +
"Barrel",
" Photons: PV Z_rec - Z_true from conversion tracks", 100, -10., 10.);
2912 h_dzPVFromTracks_[2] =
2913 iBooker.
book1D(histname +
"Endcap",
" Photons: PV Z_rec - Z_true from conversion tracks", 100, -10., 10.);
2914 h_dzPVFromTracks_[3] =
2915 iBooker.
book1D(histname +
"EndcapP",
" Photons: PV Z_rec - Z_true from conversion tracks", 100, -10., 10.);
2916 h_dzPVFromTracks_[4] =
2917 iBooker.
book1D(histname +
"EndcapM",
" Photons: PV Z_rec - Z_true from conversion tracks", 100, -10., 10.);
2921 "pdzPVVsEta",
"Photon Reco conversions: dz(PV) vs Eta",
etaBin,
etaMin,
etaMax, 100, -3., 3.,
"");
2923 if (!isRunCentrally_) {
2924 h2_dzPVVsR_ = iBooker.
book2D(
"h2dzPVVsR",
"Photon Reco conversions: dz(PV) vs R",
rBin,
rMin,
rMax, 100, -3., 3.);
2928 if (!isRunCentrally_) {
2929 histname =
"nHitsVsEta";
2930 nHitsVsEta_[0] = iBooker.
book2D(histname +
"AllTracks",
2931 "Photons:Tracks from conversions: # of hits vs #eta all tracks",
2939 histname =
"nHitsVsEta";
2940 nHitsVsEta_[1] = iBooker.
book2D(histname +
"AssTracks",
2941 "Photons:Tracks from conversions: # of hits vs #eta associated tracks",
2949 histname =
"nHitsVsR";
2950 nHitsVsR_[0] = iBooker.
book2D(histname +
"AllTracks",
2951 "Photons:Tracks from conversions: # of hits vs radius all tracks",
2959 histname =
"nHitsVsR";
2960 nHitsVsR_[1] = iBooker.
book2D(histname +
"AssTracks",
2961 "Photons:Tracks from conversions: # of hits vs radius associated tracks",
2969 histname =
"h2Chi2VsEta";
2970 h2_Chi2VsEta_[0] = iBooker.
book2D(
2973 histname =
"h2Chi2VsR";
2978 histname =
"h_nHitsVsEta";
2979 p_nHitsVsEta_[0] = iBooker.
bookProfile(histname +
"AllTracks",
2980 "Photons:Tracks from conversions: # of hits vs #eta all tracks",
2989 histname =
"h_nHitsVsEta";
2990 p_nHitsVsEta_[1] = iBooker.
bookProfile(histname +
"AssTracks",
2991 "Photons:Tracks from conversions: # of hits vs #eta associated tracks",
3000 histname =
"p_nHitsVsEtaSL";
3001 p_nHitsVsEtaSL_[0] = iBooker.
bookProfile(histname +
"AllTracks",
3002 "Photons:Tracks from single leg conversions: # of hits vs #eta all tracks",
3011 histname =
"h_nHitsVsR";
3012 p_nHitsVsR_[0] = iBooker.
bookProfile(histname +
"AllTracks",
3013 "Photons:Tracks from conversions: # of hits vs radius all tracks",
3021 histname =
"p_nHitsVsRSL";
3022 p_nHitsVsRSL_[0] = iBooker.
bookProfile(histname +
"AllTracks",
3023 "Photons:Tracks from single leg conversions: # of hits vs radius all tracks",
3032 histname =
"tkChi2";
3033 h_tkChi2_[0] = iBooker.
book1D(
3034 histname +
"AllTracks",
"Photons:Tracks from conversions: #chi^{2} of all tracks", 100,
chi2Min,
chi2Max);
3035 histname =
"tkChi2SL";
3036 h_tkChi2SL_[0] = iBooker.
book1D(histname +
"AllTracks",
3037 "Photons:Tracks from single leg conversions: #chi^{2} of associated tracks",
3041 histname =
"tkChi2Large";
3042 h_tkChi2Large_[0] = iBooker.
book1D(
3043 histname +
"AllTracks",
"Photons:Tracks from conversions: #chi^{2} of all tracks", 1000, 0., 5000.0);
3045 histname =
"h_nHitsVsR";
3046 p_nHitsVsR_[1] = iBooker.
bookProfile(histname +
"AssTracks",
3047 "Photons:Tracks from conversions: # of hits vs radius associated tracks",
3056 histname =
"tkChi2";
3057 h_tkChi2_[1] = iBooker.
book1D(
3058 histname +
"AssTracks",
"Photons:Tracks from conversions: #chi^{2} of associated tracks", 100,
chi2Min,
chi2Max);
3059 histname =
"tkChi2Large";
3060 h_tkChi2Large_[1] = iBooker.
book1D(
3061 histname +
"AssTracks",
"Photons:Tracks from conversions: #chi^{2} of associated tracks", 1000, 0., 5000.0);
3063 histname =
"pChi2VsEta";
3067 histname =
"pChi2VsR";
3072 h_TkD0_[0] = iBooker.
book1D(histname +
"All",
" Reco Track D0*q: All ", 100, -0.1, 0.6);
3073 h_TkD0_[1] = iBooker.
book1D(histname +
"Barrel",
" Reco Track D0*q: Barrel ", 100, -0.1, 0.6);
3074 h_TkD0_[2] = iBooker.
book1D(histname +
"Endcap",
" Reco Track D0*q: Endcap ", 100, -0.1, 0.6);
3076 histname =
"hTkPtPull";
3077 h_TkPtPull_[0] = iBooker.
book1D(histname +
"All",
" Reco Track Pt pull: All ", 100, -10., 10.);
3078 histname =
"hTkPtPull";
3079 h_TkPtPull_[1] = iBooker.
book1D(histname +
"Barrel",
" Reco Track Pt pull: Barrel ", 100, -10., 10.);
3080 histname =
"hTkPtPull";
3081 h_TkPtPull_[2] = iBooker.
book1D(histname +
"Endcap",
" Reco Track Pt pull: Endcap ", 100, -10., 10.);
3083 histname =
"pTkPtPullEta";
3087 if (!isRunCentrally_) {
3088 histname =
"h2TkPtPullEta";
3092 histname =
"PtRecVsPtSim";
3093 h2_PtRecVsPtSim_[0] =
3095 h2_PtRecVsPtSim_[1] =
3097 h2_PtRecVsPtSim_[2] =
3099 histname =
"PtRecVsPtSimMixProv";
3100 h2_PtRecVsPtSimMixProv_ = iBooker.
book2D(
3105 histname =
"eBcOverTkPout";
3106 hBCEnergyOverTrackPout_[0] = iBooker.
book1D(histname +
"All",
"Matrching BC E/P_out: all Ecal ", 100, 0., 5.);
3107 hBCEnergyOverTrackPout_[1] = iBooker.
book1D(histname +
"Barrel",
"Matrching BC E/P_out: Barrel ", 100, 0., 5.);
3108 hBCEnergyOverTrackPout_[2] = iBooker.
book1D(histname +
"Endcap",
"Matrching BC E/P_out: Endcap ", 100, 0., 5.);
3112 h_OIinnermostHitR_ = iBooker.
book1D(
"OIinnermostHitR",
" R innermost hit for OI tracks ", 50, 0., 25);
3113 h_IOinnermostHitR_ = iBooker.
book1D(
"IOinnermostHitR",
" R innermost hit for IO tracks ", 50, 0., 25);
3116 h_trkProv_[0] = iBooker.
book1D(
"allTrkProv",
" Track pair provenance ", 4, 0., 4.);
3117 h_trkProv_[1] = iBooker.
book1D(
"assTrkProv",
" Track pair provenance ", 4, 0., 4.);
3121 h_convAlgo_ = iBooker.
book1D(
"allConvAlgo",
" Conv Algo ", 5, -0.5, 4.5);
3122 h_convQuality_ = iBooker.
book1D(
"allConvQuality",
"Conv quality ", 11, -0.5, 11.);
3125 histname =
"h_RecoConvTwoTracksEta";
3126 h_RecoConvTwoTracks_[0] =
3128 histname =
"h_RecoConvTwoTracksPhi";
3129 h_RecoConvTwoTracks_[1] =
3131 histname =
"h_RecoConvTwoTracksR";
3132 h_RecoConvTwoTracks_[2] =
3133 iBooker.
book1D(histname,
" All reco conversions with 2 reco tracks: simulated R",
rBin,
rMin,
rMax);
3134 histname =
"h_RecoConvTwoTracksZ";
3135 h_RecoConvTwoTracks_[3] =
3136 iBooker.
book1D(histname,
" All reco conversions with 2 reco tracks: simulated Z",
zBin,
zMin,
zMax);
3137 histname =
"h_RecoConvTwoTracksEt";
3138 h_RecoConvTwoTracks_[4] =
3139 iBooker.
book1D(histname,
" All reco conversions with 2 reco tracks: simulated Et",
etBin,
etMin,
etMax);
3141 histname =
"h_RecoConvTwoMTracksEta";
3142 h_RecoConvTwoMTracks_[0] =
3144 histname =
"h_RecoConvTwoMTracksPhi";
3145 h_RecoConvTwoMTracks_[1] =
3147 histname =
"h_RecoConvTwoMTracksR";
3148 h_RecoConvTwoMTracks_[2] =
3149 iBooker.
book1D(histname,
" All reco conversions with 2 reco-ass tracks: simulated R",
rBin,
rMin,
rMax);
3150 histname =
"h_RecoConvTwoMTracksZ";
3151 h_RecoConvTwoMTracks_[3] =
3152 iBooker.
book1D(histname,
" All reco conversions with 2 reco-ass tracks: simulated Z",
zBin,
zMin,
zMax);
3153 histname =
"h_RecoConvTwoMTracksEt";
3154 h_RecoConvTwoMTracks_[4] =
3155 iBooker.
book1D(histname,
" All reco conversions with 2 reco-ass tracks: simulated Et",
etBin,
etMin,
etMax);
3160 edm::LogInfo(
"ConvertedPhotonProducer") <<
" get magnetic field"
3168 thePhotonMCTruthFinder_.reset();
3172 thePhotonMCTruthFinder_->clear();
3173 using namespace edm;
3177 const float BARL = 1.4442;
3179 const float END_HI = 2.5;
3184 e.getByLabel(
"trackAssociatorByHitsForPhotonValidation", theHitsAssociator);
3188 LogInfo(
"PhotonValidator") <<
"PhotonValidator Analyzing event number: " <<
e.id() <<
" Global Counter " << nEvt_
3195 e.getByToken(offline_pvToken_, vtxH);
3196 h_nRecoVtx_->Fill(
float(vtxH->size()));
3204 e.getByToken(photonCollectionToken_, photonHandle);
3206 if (!photonHandle.
isValid()) {
3207 edm::LogError(
"PhotonProducer") <<
"Error! Can't get the Photon collection " << std::endl;
3213 e.getByToken(pfCandidates_, pfCandidateHandle);
3214 if (!pfCandidateHandle.
isValid()) {
3215 edm::LogError(
"PhotonValidator") <<
"Error! Can't get the product pfCandidates " << std::endl;
3220 if (fName_ ==
"pfPhotonValidator") {
3221 e.getByToken(particleBasedIso_token, phoToParticleBasedIsoMapHandle);
3222 if (!phoToParticleBasedIsoMapHandle.
isValid()) {
3223 edm::LogInfo(
"PhotonValidator") <<
"Error! Can't get the product: valueMap photons to particle based iso "
3226 phoToParticleBasedIsoMap = *(phoToParticleBasedIsoMapHandle.
product());
3233 e.getByToken(conversionOITrackPr_Token_, outInTrkHandle);
3235 e.getByToken(conversionIOTrackPr_Token_, inOutTrkHandle);
3241 h_OIinnermostHitR_->Fill(
sqrt(iTk->innerPosition().Perp2()));
3244 if ((*itHits)->isValid()) {
3255 h_IOinnermostHitR_->Fill(
sqrt(iTk->innerPosition().Perp2()));
3259 if ((*itHits)->isValid()) {
3270 std::vector<SimTrack> theSimTracks;
3271 std::vector<SimVertex> theSimVertices;
3276 e.getByToken(g4_simTk_Token_, SimTk);
3277 e.getByToken(g4_simVtx_Token_, SimVtx);
3279 e.getByToken(famos_simTk_Token_, SimTk);
3280 e.getByToken(famos_simVtx_Token_, SimVtx);
3283 theSimTracks.insert(theSimTracks.end(), SimTk->begin(), SimTk->end());
3284 theSimVertices.insert(theSimVertices.end(), SimVtx->begin(), SimVtx->end());
3285 std::vector<PhotonMCTruth> mcPhotons = thePhotonMCTruthFinder_->find(theSimTracks, theSimVertices);
3288 e.getByToken(hepMC_Token_,
hepMC);
3296 e.getByToken(genjets_Token_, GenJetsHandle);
3300 bool useTP = parameters_.getParameter<
bool>(
"useTP");
3305 e.getByToken(token_tp_, ElectronTPHandle);
3311 std::vector<reco::PhotonCollection::const_iterator> StoRMatchedConvertedPhotons;
3321 OISimToReco =
trackAssociator->associateSimToReco(outInTrkHandle, ElectronTPHandle);
3322 IOSimToReco =
trackAssociator->associateSimToReco(inOutTrkHandle, ElectronTPHandle);
3324 OIRecoToSim =
trackAssociator->associateRecoToSim(outInTrkHandle, ElectronTPHandle);
3325 IORecoToSim =
trackAssociator->associateRecoToSim(inOutTrkHandle, ElectronTPHandle);
3329 vector<reco::SimToRecoCollection*> StoRCollPtrs;
3330 StoRCollPtrs.push_back(&OISimToReco);
3331 StoRCollPtrs.push_back(&IOSimToReco);
3332 vector<reco::RecoToSimCollection*> RtoSCollPtrs;
3333 RtoSCollPtrs.push_back(&OIRecoToSim);
3334 RtoSCollPtrs.push_back(&IORecoToSim);
3336 for (
int i = 0;
i < 2;
i++)
3338 for (
int i = 0;
i < 2;
i++)
3341 std::vector<reco::PhotonRef> myPhotons;
3343 for (
unsigned int iPho = 0; iPho < photonHandle->size(); iPho++) {
3346 if (fabs(phoRef->eta()) > 2.5)
3348 myPhotons.push_back(phoRef);
3351 std::sort(myPhotons.begin(), myPhotons.end(),
sortPhotons());
3353 if (myPhotons.size() >= 2) {
3354 if (myPhotons[0]->
et() > 40 && myPhotons[1]->et() > 25) {
3360 float gamgamMass2 = p12.Dot(p12);
3361 float gamgamMass2_regr1 = p12_regr1.Dot(p12_regr1);
3362 float gamgamMass2_regr2 = p12_regr2.Dot(p12_regr2);
3365 if (gamgamMass2 > 0) {
3367 h_gamgamMass_[0][0]->Fill(
sqrt(gamgamMass2));
3368 if (myPhotons[0]->isEB() && myPhotons[1]->isEB())
3369 h_gamgamMass_[0][1]->Fill(
sqrt(gamgamMass2));
3370 if ((myPhotons[0]->isEE() && myPhotons[1]->isEE()) || (myPhotons[0]->isEE() && myPhotons[1]->isEB()) ||
3371 (myPhotons[0]->isEB() && myPhotons[1]->isEE()))
3372 h_gamgamMass_[0][2]->Fill(
sqrt(gamgamMass2));
3374 if (myPhotons[0]->
r9() > 0.94 && myPhotons[1]->
r9() > 0.94) {
3375 h_gamgamMass_[1][0]->Fill(
sqrt(gamgamMass2));
3376 if (myPhotons[0]->isEB() && myPhotons[1]->isEB())
3377 h_gamgamMass_[1][1]->Fill(
sqrt(gamgamMass2));
3378 if ((myPhotons[0]->isEE() && myPhotons[1]->isEE()) || (myPhotons[0]->isEE() && myPhotons[1]->isEB()) ||
3379 (myPhotons[0]->isEB() && myPhotons[1]->isEE()))
3380 h_gamgamMass_[1][2]->Fill(
sqrt(gamgamMass2));
3389 if (chi2Prob1 > 0.0005 && chi2Prob2 > 0.0005) {
3390 h_gamgamMass_[2][0]->Fill(
sqrt(gamgamMass2));
3391 if (myPhotons[0]->isEB() && myPhotons[1]->isEB()) {
3392 h_gamgamMass_[2][1]->Fill(
sqrt(gamgamMass2));
3394 if ((myPhotons[0]->isEE() && myPhotons[1]->isEE()) || (myPhotons[0]->isEE() && myPhotons[1]->isEB()) ||
3395 (myPhotons[0]->isEB() && myPhotons[1]->isEE())) {
3396 h_gamgamMass_[2][2]->Fill(
sqrt(gamgamMass2));
3401 myPhotons[1]->
r9() > 0.93) {
3405 if (chi2Prob1 > 0.0005) {
3406 h_gamgamMass_[2][0]->Fill(
sqrt(gamgamMass2));
3407 if (myPhotons[0]->isEB() && myPhotons[1]->isEB()) {
3408 h_gamgamMass_[2][1]->Fill(
sqrt(gamgamMass2));
3410 if (myPhotons[0]->isEE() || myPhotons[1]->isEE()) {
3411 h_gamgamMass_[2][2]->Fill(
sqrt(gamgamMass2));
3416 myPhotons[0]->
r9() > 0.93) {
3420 if (chi2Prob1 > 0.0005) {
3421 h_gamgamMass_[2][0]->Fill(
sqrt(gamgamMass2));
3422 if (myPhotons[0]->isEB() && myPhotons[1]->isEB()) {
3423 h_gamgamMass_[2][1]->Fill(
sqrt(gamgamMass2));
3425 if (myPhotons[0]->isEE() || myPhotons[1]->isEE()) {
3426 h_gamgamMass_[2][2]->Fill(
sqrt(gamgamMass2));
3434 if (gamgamMass2_regr1 > 0) {
3436 h_gamgamMassRegr1_[0][0]->Fill(
sqrt(gamgamMass2_regr1));
3437 if (myPhotons[0]->isEB() && myPhotons[1]->isEB())
3438 h_gamgamMassRegr1_[0][1]->Fill(
sqrt(gamgamMass2_regr1));
3439 if ((myPhotons[0]->isEE() && myPhotons[1]->isEE()) || (myPhotons[0]->isEE() && myPhotons[1]->isEB()) ||
3440 (myPhotons[0]->isEB() && myPhotons[1]->isEE()))
3441 h_gamgamMassRegr1_[0][2]->Fill(
sqrt(gamgamMass2_regr1));
3443 if (myPhotons[0]->
r9() > 0.94 && myPhotons[1]->
r9() > 0.94) {
3444 h_gamgamMassRegr1_[1][0]->Fill(
sqrt(gamgamMass2_regr1));
3445 if (myPhotons[0]->isEB() && myPhotons[1]->isEB())
3446 h_gamgamMassRegr1_[1][1]->Fill(
sqrt(gamgamMass2_regr1));
3447 if ((myPhotons[0]->isEE() && myPhotons[1]->isEE()) || (myPhotons[0]->isEE() && myPhotons[1]->isEB()) ||
3448 (myPhotons[0]->isEB() && myPhotons[1]->isEE()))
3449 h_gamgamMassRegr1_[1][2]->Fill(
sqrt(gamgamMass2_regr1));
3459 if (chi2Prob1 > 0.0005 && chi2Prob2 > 0.0005) {
3460 h_gamgamMassRegr1_[2][0]->Fill(
sqrt(gamgamMass2_regr1));
3461 if (myPhotons[0]->isEB() && myPhotons[1]->isEB()) {
3462 h_gamgamMassRegr1_[2][1]->Fill(
sqrt(gamgamMass2_regr1));
3464 if ((myPhotons[0]->isEE() && myPhotons[1]->isEE()) || (myPhotons[0]->isEE() && myPhotons[1]->isEB()) ||
3465 (myPhotons[0]->isEB() && myPhotons[1]->isEE())) {
3466 h_gamgamMassRegr1_[2][2]->Fill(
sqrt(gamgamMass2_regr1));
3471 myPhotons[1]->
r9() > 0.93) {
3475 if (chi2Prob1 > 0.0005) {
3476 h_gamgamMassRegr1_[2][0]->Fill(
sqrt(gamgamMass2_regr1));
3477 if (myPhotons[0]->isEB() && myPhotons[1]->isEB()) {
3478 h_gamgamMassRegr1_[2][1]->Fill(
sqrt(gamgamMass2_regr1));
3480 if (myPhotons[0]->isEE() || myPhotons[1]->isEE()) {
3481 h_gamgamMassRegr1_[2][2]->Fill(
sqrt(gamgamMass2_regr1));
3486 myPhotons[0]->
r9() > 0.93) {
3490 if (chi2Prob1 > 0.0005) {
3491 h_gamgamMassRegr1_[2][0]->Fill(
sqrt(gamgamMass2_regr1));
3492 if (myPhotons[0]->isEB() && myPhotons[1]->isEB()) {
3493 h_gamgamMassRegr1_[2][1]->Fill(
sqrt(gamgamMass2_regr1));
3495 if (myPhotons[0]->isEE() || myPhotons[1]->isEE()) {
3496 h_gamgamMassRegr1_[2][2]->Fill(
sqrt(gamgamMass2_regr1));
3504 if (gamgamMass2_regr2 > 0) {
3506 h_gamgamMassRegr2_[0][0]->Fill(
sqrt(gamgamMass2_regr2));
3507 if (myPhotons[0]->isEB() && myPhotons[1]->isEB())
3508 h_gamgamMassRegr2_[0][1]->Fill(
sqrt(gamgamMass2_regr2));
3509 if ((myPhotons[0]->isEE() && myPhotons[1]->isEE()) || (myPhotons[0]->isEE() && myPhotons[1]->isEB()) ||
3510 (myPhotons[0]->isEB() && myPhotons[1]->isEE()))
3511 h_gamgamMassRegr2_[0][2]->Fill(
sqrt(gamgamMass2_regr2));
3513 if (myPhotons[0]->
r9() > 0.94 && myPhotons[1]->
r9() > 0.94) {
3514 h_gamgamMassRegr2_[1][0]->Fill(
sqrt(gamgamMass2_regr2));
3515 if (myPhotons[0]->isEB() && myPhotons[1]->isEB())
3516 h_gamgamMassRegr2_[1][1]->Fill(
sqrt(gamgamMass2_regr2));
3517 if ((myPhotons[0]->isEE() && myPhotons[1]->isEE()) || (myPhotons[0]->isEE() && myPhotons[1]->isEB()) ||
3518 (myPhotons[0]->isEB() && myPhotons[1]->isEE()))
3519 h_gamgamMassRegr2_[1][2]->Fill(
sqrt(gamgamMass2_regr2));
3529 if (chi2Prob1 > 0.0005 && chi2Prob2 > 0.0005) {
3530 h_gamgamMassRegr2_[2][0]->Fill(
sqrt(gamgamMass2_regr2));
3531 if (myPhotons[0]->isEB() && myPhotons[1]->isEB()) {
3532 h_gamgamMassRegr2_[2][1]->Fill(
sqrt(gamgamMass2_regr2));
3534 if ((myPhotons[0]->isEE() && myPhotons[1]->isEE()) || (myPhotons[0]->isEE() && myPhotons[1]->isEB()) ||
3535 (myPhotons[0]->isEB() && myPhotons[1]->isEE())) {
3536 h_gamgamMassRegr2_[2][2]->Fill(
sqrt(gamgamMass2_regr2));
3541 myPhotons[1]->
r9() > 0.93) {
3545 if (chi2Prob1 > 0.0005) {
3546 h_gamgamMassRegr2_[2][0]->Fill(
sqrt(gamgamMass2_regr2));
3547 if (myPhotons[0]->isEB() && myPhotons[1]->isEB()) {
3548 h_gamgamMassRegr2_[2][1]->Fill(
sqrt(gamgamMass2_regr2));
3550 if (myPhotons[0]->isEE() || myPhotons[1]->isEE()) {
3551 h_gamgamMassRegr2_[2][2]->Fill(
sqrt(gamgamMass2_regr2));
3556 myPhotons[0]->
r9() > 0.93) {
3560 if (chi2Prob1 > 0.0005) {
3561 h_gamgamMassRegr2_[2][0]->Fill(
sqrt(gamgamMass2_regr2));
3562 if (myPhotons[0]->isEB() && myPhotons[1]->isEB()) {
3563 h_gamgamMassRegr2_[2][1]->Fill(
sqrt(gamgamMass2_regr2));
3565 if (myPhotons[0]->isEE() || myPhotons[1]->isEE()) {
3566 h_gamgamMassRegr2_[2][2]->Fill(
sqrt(gamgamMass2_regr2));
3576 for (std::vector<PhotonMCTruth>::const_iterator mcPho = mcPhotons.begin(); mcPho != mcPhotons.end(); mcPho++) {
3577 if ((*mcPho).fourMomentum().et() < minPhoEtCut_)
3580 for (HepMC::GenEvent::particle_const_iterator mcIter = myGenEvent->particles_begin();
3581 mcIter != myGenEvent->particles_end();
3583 if ((*mcIter)->pdg_id() != 22)
3585 bool isTheSame =
false;
3587 if ((*mcIter)->production_vertex()) {
3588 if ((*mcIter)->production_vertex()->particles_begin(
HepMC::parents) !=
3590 mother = *((*mcIter)->production_vertex()->particles_begin(
HepMC::parents));
3593 float mcPhi = (*mcPho).fourMomentum().phi();
3594 mcPhi_ = phiNormalization(mcPhi);
3595 mcEta_ = (*mcPho).fourMomentum().pseudoRapidity();
3596 mcEta_ = etaTransformation(mcEta_, (*mcPho).primaryVertex().z());
3597 mcConvR_ = (*mcPho).vertex().perp();
3598 mcConvX_ = (*mcPho).vertex().x();
3599 mcConvY_ = (*mcPho).vertex().y();
3600 mcConvZ_ = (*mcPho).vertex().z();
3601 mcConvEta_ = (*mcPho).vertex().eta();
3602 mcConvPhi_ = (*mcPho).vertex().phi();
3604 if (fabs(mcEta_) > END_HI)
3607 if (mother ==
nullptr || (mother !=
nullptr && mother->pdg_id() == 22) ||
3608 (mother !=
nullptr && mother->pdg_id() == 25) || (mother !=
nullptr && mother->pdg_id() == 35)) {
3609 double dPt = fabs((*mcIter)->momentum().perp() - (*mcPho).fourMomentum().et());
3610 float phiMother = (*mcIter)->momentum().phi();
3611 double dPhi = phiNormalization(phiMother) - mcPhi_;
3612 double dEta = fabs((*mcIter)->momentum().eta() - (*mcPho).fourMomentum().pseudoRapidity());
3614 if (
dEta <= 0.0001 &&
dPhi <= 0.0001 && dPt <= 0.0001)
3621 if (!isRunCentrally_) {
3622 h_SimPhoMotherEt_[0]->Fill((*mcPho).motherMomentum().et());
3623 h_SimPhoMotherEta_[0]->Fill((*mcPho).motherMomentum().pseudoRapidity());
3626 h_SimPho_[0]->Fill(mcEta_);
3627 h_SimPho_[1]->Fill(mcPhi_);
3628 h_SimPho_[2]->Fill((*mcPho).fourMomentum().et());
3632 bool goodSimConversion =
false;
3633 bool visibleConversion =
false;
3634 bool visibleConversionsWithTwoSimTracks =
false;
3635 if ((*mcPho).isAConversion() == 1) {
3637 h_AllSimConv_[0]->Fill(mcEta_);
3638 h_AllSimConv_[1]->Fill(mcPhi_);
3639 h_AllSimConv_[2]->Fill(mcConvR_);
3640 h_AllSimConv_[3]->Fill(mcConvZ_);
3641 h_AllSimConv_[4]->Fill((*mcPho).fourMomentum().et());
3643 if (!isRunCentrally_) {
3645 h_SimConvEtaPix_[0]->Fill(mcEta_);
3648 if ((fabs(mcEta_) <= BARL && mcConvR_ < 85) ||
3649 (fabs(mcEta_) > BARL && fabs(mcEta_) <= END_HI && fabs((*mcPho).vertex().z()) < 210))
3650 visibleConversion =
true;
3655 if (fabs(
tp->vx() - (*mcPho).vertex().x()) < 0.001 && fabs(
tp->vy() - (*mcPho).vertex().y()) < 0.001 &&
3656 fabs(
tp->vz() - (*mcPho).vertex().z()) < 0.001) {
3657 theConvTP_.push_back(
tp);
3660 if (theConvTP_.size() == 2)
3661 visibleConversionsWithTwoSimTracks =
true;
3662 goodSimConversion =
false;
3664 if (visibleConversion && visibleConversionsWithTwoSimTracks)
3665 goodSimConversion =
true;
3666 if (goodSimConversion) {
3668 h_VisSimConv_[0]->Fill(mcEta_);
3669 h_VisSimConv_[1]->Fill(mcPhi_);
3670 h_VisSimConv_[2]->Fill(mcConvR_);
3671 h_VisSimConv_[3]->Fill(mcConvZ_);
3672 h_VisSimConv_[4]->Fill((*mcPho).fourMomentum().et());
3675 if (!isRunCentrally_) {
3677 iTrk != theConvTP_.end();
3679 h_simTkPt_->Fill((*iTrk)->pt());
3680 h_simTkEta_->Fill((*iTrk)->eta());
3687 float minDelta = 10000.;
3688 std::vector<reco::PhotonRef> thePhotons;
3693 for (
unsigned int iPho = 0; iPho < photonHandle->size(); iPho++) {
3695 thePhotons.push_back(aPho);
3696 float phiPho = aPho->phi();
3697 float etaPho = aPho->eta();
3718 if (!isRunCentrally_) {
3719 h_SimPhoMotherEt_[1]->Fill((*mcPho).motherMomentum().et());
3720 h_SimPhoMotherEta_[1]->Fill((*mcPho).motherMomentum().pseudoRapidity());
3722 h_MatchedSimPho_[0]->Fill(mcEta_);
3723 h_MatchedSimPho_[1]->Fill(mcPhi_);
3724 h_MatchedSimPho_[2]->Fill((*mcPho).fourMomentum().et());
3730 bool phoIsInBarrel =
false;
3731 bool phoIsInEndcap =
false;
3732 bool phoIsInEndcapP =
false;
3733 bool phoIsInEndcapM =
false;
3737 if (fabs(matchingPho->superCluster()->position().eta()) < 1.479) {
3738 phoIsInBarrel =
true;
3740 phoIsInEndcap =
true;
3741 if (matchingPho->superCluster()->position().eta() > 0)
3742 phoIsInEndcapP =
true;
3743 if (matchingPho->superCluster()->position().eta() < 0)
3744 phoIsInEndcapM =
true;
3748 if (phoIsInBarrel) {
3750 e.getByToken(barrelEcalHits_, ecalRecHitHandle);
3751 if (!ecalRecHitHandle.
isValid()) {
3753 labelsForToken(barrelEcalHits_,
l);
3754 edm::LogError(
"PhotonProducer") <<
"Error! Can't get the product " <<
l.module;
3758 }
else if (phoIsInEndcap) {
3760 e.getByToken(endcapEcalHits_, ecalRecHitHandle);
3761 if (!ecalRecHitHandle.
isValid()) {
3763 labelsForToken(barrelEcalHits_,
l);
3764 edm::LogError(
"PhotonProducer") <<
"Error! Can't get the product " <<
l.module;
3771 float photonE = matchingPho->energy();
3772 float sigmaEoE = matchingPho->getCorrectedEnergyError(matchingPho->getCandidateP4type()) / matchingPho->energy();
3774 float photonEt = matchingPho->pt();
3777 float r9 = matchingPho->r9();
3779 float r1 = matchingPho->r1x5();
3780 float r2 = matchingPho->r2x5();
3781 float sigmaIetaIeta = matchingPho->sigmaIetaIeta();
3783 float hOverE = matchingPho->hadronicOverEm();
3784 float newhOverE = matchingPho->hadTowOverEm();
3785 float ecalIso = matchingPho->ecalRecHitSumEtConeDR04();
3786 float hcalIso = matchingPho->hcalTowerSumEtConeDR04();
3787 float newhcalIso = matchingPho->hcalTowerSumEtBcConeDR04();
3788 float trkIso = matchingPho->trkSumPtSolidConeDR04();
3789 float nIsoTrk = matchingPho->nTrkSolidConeDR04();
3791 float chargedHadIso = matchingPho->chargedHadronIso();
3792 float neutralHadIso = matchingPho->neutralHadronIso();
3793 float photonIso = matchingPho->photonIso();
3794 float etOutsideMustache = matchingPho->etOutsideMustache();
3795 int nClusterOutsideMustache = matchingPho->nClusterOutsideMustache();
3796 float pfMVA = matchingPho->pfMVA();
3798 std::vector<std::pair<DetId, float> >::const_iterator rhIt;
3799 bool atLeastOneDeadChannel =
false;
3801 bcIt != matchingPho->superCluster()->clustersEnd();
3803 for (rhIt = (*bcIt)->hitsAndFractions().begin(); rhIt != (*bcIt)->hitsAndFractions().end(); ++rhIt) {
3806 if (rhIt->first == (*it).id()) {
3807 if ((*it).recoFlag() == 9) {
3808 atLeastOneDeadChannel =
true;
3816 if (atLeastOneDeadChannel) {
3817 h_MatchedSimPhoBadCh_[0]->Fill(mcEta_);
3818 h_MatchedSimPhoBadCh_[1]->Fill(mcPhi_);
3819 h_MatchedSimPhoBadCh_[2]->Fill((*mcPho).fourMomentum().et());
3823 h_phoPixSeedSize_[0]->Fill(matchingPho->electronPixelSeeds().size());
3825 h_phoPixSeedSize_[1]->Fill(matchingPho->electronPixelSeeds().size());
3827 h_scEta_[
type]->Fill(matchingPho->superCluster()->eta());
3828 h_scPhi_[
type]->Fill(matchingPho->superCluster()->phi());
3829 if (!isRunCentrally_) {
3830 h_scEtaWidth_[
type]->Fill(matchingPho->superCluster()->etaWidth());
3831 h_scPhiWidth_[
type]->Fill(matchingPho->superCluster()->phiWidth());
3833 h_scE_[
type][0]->Fill(matchingPho->superCluster()->energy());
3834 h_scEt_[
type][0]->Fill(matchingPho->superCluster()->energy() / cosh(matchingPho->superCluster()->eta()));
3836 h_psE_->Fill(matchingPho->superCluster()->preshowerEnergy());
3838 h_r9_[
type][0]->Fill(
r9);
3840 h_r1_[
type][0]->Fill(
r1);
3842 h_r2_[
type][0]->Fill(
r2);
3844 h_sigmaIetaIeta_[
type][0]->Fill(sigmaIetaIeta);
3847 p_r9VsEta_[0]->Fill(mcEta_,
r9);
3849 if (!isRunCentrally_) {
3850 h2_r9VsEt_[0]->Fill((*mcPho).fourMomentum().et(),
r9);
3851 h2_r1VsEta_[0]->Fill(mcEta_,
r1);
3852 h2_r1VsEt_[0]->Fill((*mcPho).fourMomentum().et(),
r1);
3853 h2_r2VsEta_[0]->Fill(mcEta_,
r2);
3854 h2_r2VsEt_[0]->Fill((*mcPho).fourMomentum().et(),
r2);
3855 h2_sigmaIetaIetaVsEta_[0]->Fill(mcEta_, sigmaIetaIeta);
3856 h2_sigmaIetaIetaVsEt_[0]->Fill((*mcPho).fourMomentum().et(), sigmaIetaIeta);
3857 h2_hOverEVsEta_[0]->Fill(mcEta_,
hOverE);
3858 h2_hOverEVsEt_[0]->Fill((*mcPho).fourMomentum().et(),
hOverE);
3860 p_hOverEVsEta_[0]->Fill(mcEta_,
hOverE);
3861 p_hOverEVsEt_[0]->Fill((*mcPho).fourMomentum().et(),
hOverE);
3863 h_newhOverE_[
type][0]->Fill(newhOverE);
3864 p_newhOverEVsEta_[0]->Fill(mcEta_, newhOverE);
3865 p_newhOverEVsEt_[0]->Fill((*mcPho).fourMomentum().et(), newhOverE);
3868 h_ecalRecHitSumEtConeDR04_[
type][0]->Fill(ecalIso);
3869 if (!isRunCentrally_) {
3870 h2_ecalRecHitSumEtConeDR04VsEta_[0]->Fill(mcEta_, ecalIso);
3871 h2_ecalRecHitSumEtConeDR04VsEt_[0]->Fill((*mcPho).fourMomentum().et(), ecalIso);
3872 h2_hcalTowerSumEtConeDR04VsEta_[0]->Fill(mcEta_, hcalIso);
3873 h2_hcalTowerSumEtConeDR04VsEt_[0]->Fill((*mcPho).fourMomentum().et(), hcalIso);
3875 p_ecalRecHitSumEtConeDR04VsEta_[0]->Fill(mcEta_, ecalIso);
3876 if (!isRunCentrally_)
3877 p_ecalRecHitSumEtConeDR04VsEt_[0]->Fill((*mcPho).fourMomentum().et(), ecalIso);
3879 h_hcalTowerSumEtConeDR04_[
type][0]->Fill(hcalIso);
3880 p_hcalTowerSumEtConeDR04VsEta_[0]->Fill(mcEta_, hcalIso);
3881 if (!isRunCentrally_)
3882 p_hcalTowerSumEtConeDR04VsEt_[0]->Fill((*mcPho).fourMomentum().et(), hcalIso);
3884 if (!isRunCentrally_)
3885 h_hcalTowerBcSumEtConeDR04_[
type][0]->Fill(newhcalIso);
3886 p_hcalTowerBcSumEtConeDR04VsEta_[0]->Fill(mcEta_, newhcalIso);
3887 if (!isRunCentrally_)
3888 p_hcalTowerBcSumEtConeDR04VsEt_[0]->Fill((*mcPho).fourMomentum().et(), newhcalIso);
3890 h_isoTrkSolidConeDR04_[
type][0]->Fill(
trkIso);
3891 h_nTrkSolidConeDR04_[
type][0]->Fill(nIsoTrk);
3893 if (!isRunCentrally_) {
3894 h2_isoTrkSolidConeDR04VsEta_[0]->Fill(mcEta_,
trkIso);
3895 h2_isoTrkSolidConeDR04VsEt_[0]->Fill((*mcPho).fourMomentum().et(),
trkIso);
3896 h2_nTrkSolidConeDR04VsEta_[0]->Fill(mcEta_, nIsoTrk);
3897 h2_nTrkSolidConeDR04VsEt_[0]->Fill((*mcPho).fourMomentum().et(), nIsoTrk);
3900 h_chHadIso_[0]->Fill(chargedHadIso);
3901 h_nHadIso_[0]->Fill(neutralHadIso);
3903 h_nCluOutsideMustache_[0]->Fill(
float(nClusterOutsideMustache));
3904 h_etOutsideMustache_[0]->Fill(etOutsideMustache);
3905 h_pfMva_[0]->Fill(pfMVA);
3907 h_phoEta_[
type]->Fill(matchingPho->eta());
3908 h_phoPhi_[
type]->Fill(matchingPho->phi());
3909 h_phoDEta_[0]->Fill(matchingPho->eta() - (*mcPho).fourMomentum().eta());
3910 h_phoDPhi_[0]->Fill(matchingPho->phi() - mcPhi_);
3911 h_phoE_[
type][0]->Fill(photonE);
3912 h_phoEt_[
type][0]->Fill(photonEt);
3913 h_nConv_[0][0]->Fill(
float(matchingPho->conversions().size()));
3914 h_nConv_[1][0]->Fill(
float(matchingPho->conversionsOneLeg().size()));
3917 h_phoERes_[0][0]->Fill(photonE / (*mcPho).fourMomentum().e());
3918 h_phoSigmaEoE_[0][0]->Fill(sigmaEoE);
3919 h_phoEResRegr1_[0][0]->Fill(photonERegr1 / (*mcPho).fourMomentum().e());
3920 h_phoEResRegr2_[0][0]->Fill(photonERegr2 / (*mcPho).fourMomentum().e());
3922 p_eResVsEta_[0]->Fill(mcEta_, photonE / (*mcPho).fourMomentum().e());
3923 p_sigmaEoEVsEta_[0]->Fill(mcEta_, sigmaEoE);
3924 p_eResVsEt_[0][0]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
3926 if (!isRunCentrally_)
3927 h2_eResVsEta_[0]->Fill(mcEta_, photonE / (*mcPho).fourMomentum().e());
3928 if (!isRunCentrally_)
3929 h2_eResVsEt_[0][0]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
3930 if (!isRunCentrally_)
3931 h2_eResVsR9_[0]->Fill(
r9, photonE / (*mcPho).fourMomentum().e());
3932 if (!isRunCentrally_)
3933 h2_sceResVsR9_[0]->Fill(
r9, matchingPho->superCluster()->energy() / (*mcPho).fourMomentum().e());
3934 if (!isRunCentrally_)
3935 p_eResVsR9_[0]->Fill(
r9, photonE / (*mcPho).fourMomentum().e());
3936 if (!isRunCentrally_)
3937 p_sceResVsR9_[0]->Fill(
r9, matchingPho->superCluster()->energy() / (*mcPho).fourMomentum().e());
3939 if ((*mcPho).isAConversion() == 0) {
3940 if (!isRunCentrally_) {
3941 h2_eResVsEta_[1]->Fill(mcEta_, photonE / (*mcPho).fourMomentum().e());
3942 h2_r9VsEt_[1]->Fill((*mcPho).fourMomentum().et(),
r9);
3944 h2_r1VsEta_[1]->Fill(mcEta_,
r1);
3945 h2_r1VsEt_[1]->Fill((*mcPho).fourMomentum().et(),
r1);
3947 h2_r2VsEta_[1]->Fill(mcEta_,
r2);
3948 h2_r2VsEt_[1]->Fill((*mcPho).fourMomentum().et(),
r2);
3950 h2_sigmaIetaIetaVsEta_[1]->Fill(mcEta_, sigmaIetaIeta);
3951 h2_sigmaIetaIetaVsEt_[1]->Fill((*mcPho).fourMomentum().et(), sigmaIetaIeta);
3953 h2_hOverEVsEta_[1]->Fill(mcEta_,
hOverE);
3954 h2_hOverEVsEt_[1]->Fill((*mcPho).fourMomentum().et(),
hOverE);
3957 if (!isRunCentrally_) {
3958 h2_ecalRecHitSumEtConeDR04VsEta_[1]->Fill(mcEta_, ecalIso);
3959 h2_hcalTowerSumEtConeDR04VsEta_[1]->Fill(mcEta_, hcalIso);
3960 h2_isoTrkSolidConeDR04VsEta_[1]->Fill(mcEta_,
trkIso);
3961 h2_isoTrkSolidConeDR04VsEt_[1]->Fill((*mcPho).fourMomentum().et(),
trkIso);
3962 h2_nTrkSolidConeDR04VsEta_[1]->Fill(mcEta_, nIsoTrk);
3963 h2_nTrkSolidConeDR04VsEt_[1]->Fill((*mcPho).fourMomentum().et(), nIsoTrk);
3965 p_ecalRecHitSumEtConeDR04VsEta_[1]->Fill(mcEta_, ecalIso);
3966 if (!isRunCentrally_)
3967 p_hcalTowerSumEtConeDR04VsEta_[1]->Fill(mcEta_, hcalIso);
3970 if (photonE / (*mcPho).fourMomentum().e() < 0.3 && photonE / (*mcPho).fourMomentum().e() > 0.1) {
3973 if ((
r9 > 0.94 && phoIsInBarrel) || (
r9 > 0.95 && phoIsInEndcap)) {
3974 h_phoERes_[1][0]->Fill(photonE / (*mcPho).fourMomentum().e());
3975 h_phoSigmaEoE_[1][0]->Fill(sigmaEoE);
3976 h_phoEResRegr1_[1][0]->Fill(photonERegr1 / (*mcPho).fourMomentum().e());
3977 h_phoEResRegr2_[1][0]->Fill(photonERegr2 / (*mcPho).fourMomentum().e());
3978 if (!isRunCentrally_)
3979 h2_eResVsEt_[0][1]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
3980 p_eResVsEt_[0][1]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
3981 p_eResVsEta_[1]->Fill(mcEta_, photonE / (*mcPho).fourMomentum().e());
3982 p_r9VsEta_[1]->Fill(mcEta_,
r9);
3983 p_sigmaEoEVsEta_[1]->Fill(mcEta_, sigmaEoE);
3985 }
else if ((
r9 <= 0.94 && phoIsInBarrel) || (
r9 <= 0.95 && phoIsInEndcap)) {
3986 h_phoERes_[2][0]->Fill(photonE / (*mcPho).fourMomentum().e());
3987 h_phoSigmaEoE_[2][0]->Fill(sigmaEoE);
3988 h_phoEResRegr1_[2][0]->Fill(photonERegr1 / (*mcPho).fourMomentum().e());
3989 h_phoEResRegr2_[2][0]->Fill(photonERegr2 / (*mcPho).fourMomentum().e());
3990 p_eResVsEt_[0][2]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
3991 p_eResVsEta_[2]->Fill(mcEta_, photonE / (*mcPho).fourMomentum().e());
3992 p_r9VsEta_[2]->Fill(mcEta_,
r9);
3993 p_sigmaEoEVsEta_[2]->Fill(mcEta_, sigmaEoE);
3995 if (!isRunCentrally_) {
3996 h2_eResVsEt_[0][2]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
3997 h_EtR9Less093_[0][0]->Fill(photonEt);
4001 if (phoIsInBarrel) {
4002 h_scE_[
type][1]->Fill(matchingPho->superCluster()->energy());
4003 h_scEt_[
type][1]->Fill(matchingPho->superCluster()->energy() / cosh(matchingPho->superCluster()->eta()));
4004 h_r9_[
type][1]->Fill(
r9);
4005 h_r1_[
type][1]->Fill(
r1);
4006 h_r2_[
type][1]->Fill(
r2);
4007 h_sigmaIetaIeta_[
type][1]->Fill(sigmaIetaIeta);
4009 h_newhOverE_[
type][1]->Fill(newhOverE);
4010 h_ecalRecHitSumEtConeDR04_[
type][1]->Fill(ecalIso);
4011 p_ecalRecHitSumEtConeDR04VsEt_[1]->Fill((*mcPho).fourMomentum().et(), ecalIso);
4012 h_hcalTowerSumEtConeDR04_[
type][1]->Fill(hcalIso);
4013 p_hcalTowerSumEtConeDR04VsEt_[1]->Fill((*mcPho).fourMomentum().et(), hcalIso);
4014 h_hcalTowerBcSumEtConeDR04_[
type][1]->Fill(newhcalIso);
4015 p_hcalTowerBcSumEtConeDR04VsEt_[1]->Fill((*mcPho).fourMomentum().et(), newhcalIso);
4016 h_isoTrkSolidConeDR04_[
type][1]->Fill(
trkIso);
4017 h_nTrkSolidConeDR04_[
type][1]->Fill(nIsoTrk);
4018 h_chHadIso_[1]->Fill(chargedHadIso);
4019 h_nHadIso_[1]->Fill(neutralHadIso);
4021 h_nCluOutsideMustache_[1]->Fill(
float(nClusterOutsideMustache));
4022 h_etOutsideMustache_[1]->Fill(etOutsideMustache);
4023 h_pfMva_[1]->Fill(pfMVA);
4024 h_phoE_[
type][1]->Fill(photonE);
4025 h_phoEt_[
type][1]->Fill(photonEt);
4026 h_nConv_[
type][1]->Fill(
float(matchingPho->conversions().size()));
4027 h_nConv_[1][1]->Fill(
float(matchingPho->conversionsOneLeg().size()));
4028 h_phoERes_[0][1]->Fill(photonE / (*mcPho).fourMomentum().e());
4029 h_phoSigmaEoE_[0][1]->Fill(sigmaEoE);
4030 h_phoEResRegr1_[0][1]->Fill(photonERegr1 / (*mcPho).fourMomentum().e());
4031 h_phoEResRegr2_[0][1]->Fill(photonERegr2 / (*mcPho).fourMomentum().e());
4032 p_eResVsR9_[1]->Fill(
r9, photonE / (*mcPho).fourMomentum().e());
4033 p_sceResVsR9_[1]->Fill(
r9, matchingPho->superCluster()->energy() / (*mcPho).fourMomentum().e());
4034 if (!isRunCentrally_) {
4035 h2_eResVsR9_[1]->Fill(
r9, photonE / (*mcPho).fourMomentum().e());
4036 h2_sceResVsR9_[1]->Fill(
r9, matchingPho->superCluster()->energy() / (*mcPho).fourMomentum().e());
4037 h2_ecalRecHitSumEtConeDR04VsEt_[1]->Fill((*mcPho).fourMomentum().et(), ecalIso);
4038 h2_hcalTowerSumEtConeDR04VsEt_[1]->Fill((*mcPho).fourMomentum().et(), hcalIso);
4039 h2_eResVsEt_[1][0]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
4041 p_eResVsEt_[1][0]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
4042 p_eResVsNVtx_[1][0]->Fill(
float(vtxH->size()), photonE / (*mcPho).fourMomentum().e());
4043 p_sigmaEoEVsEt_[1][0]->Fill((*mcPho).fourMomentum().et(), sigmaEoE);
4044 p_sigmaEoEVsNVtx_[1][0]->Fill(
float(vtxH->size()), sigmaEoE);
4047 h_phoERes_[1][1]->Fill(photonE / (*mcPho).fourMomentum().e());
4048 h_phoSigmaEoE_[1][1]->Fill(sigmaEoE);
4049 h_phoEResRegr1_[1][1]->Fill(photonERegr1 / (*mcPho).fourMomentum().e());
4050 h_phoEResRegr2_[1][1]->Fill(photonERegr2 / (*mcPho).fourMomentum().e());
4051 if (!isRunCentrally_)
4052 h2_eResVsEt_[1][1]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
4053 p_eResVsEt_[1][1]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
4054 p_eResVsNVtx_[1][1]->Fill(
float(vtxH->size()), photonE / (*mcPho).fourMomentum().e());
4055 p_sigmaEoEVsEt_[1][1]->Fill((*mcPho).fourMomentum().et(), sigmaEoE);
4056 p_sigmaEoEVsNVtx_[1][1]->Fill(
float(vtxH->size()), sigmaEoE);
4059 h_phoERes_[2][1]->Fill(photonE / (*mcPho).fourMomentum().e());
4060 h_phoSigmaEoE_[2][1]->Fill(sigmaEoE);
4061 h_phoEResRegr1_[2][1]->Fill(photonERegr1 / (*mcPho).fourMomentum().e());
4062 h_phoEResRegr2_[2][1]->Fill(photonERegr2 / (*mcPho).fourMomentum().e());
4063 p_eResVsEt_[1][2]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
4064 p_eResVsNVtx_[1][2]->Fill(
float(vtxH->size()), photonE / (*mcPho).fourMomentum().e());
4065 p_sigmaEoEVsEt_[1][2]->Fill((*mcPho).fourMomentum().et(), sigmaEoE);
4066 p_sigmaEoEVsNVtx_[1][2]->Fill(
float(vtxH->size()), sigmaEoE);
4067 if (!isRunCentrally_) {
4068 h2_eResVsEt_[1][2]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
4069 h_EtR9Less093_[0][1]->Fill(photonEt);
4073 if (phoIsInEndcap) {
4074 h_scE_[
type][2]->Fill(matchingPho->superCluster()->energy());
4075 h_scEt_[
type][2]->Fill(matchingPho->superCluster()->energy() / cosh(matchingPho->superCluster()->eta()));
4076 h_r9_[
type][2]->Fill(
r9);
4077 h_r1_[
type][2]->Fill(
r1);
4078 h_r2_[
type][2]->Fill(
r2);
4079 h_sigmaIetaIeta_[
type][2]->Fill(sigmaIetaIeta);
4081 h_newhOverE_[
type][2]->Fill(newhOverE);
4082 h_ecalRecHitSumEtConeDR04_[
type][2]->Fill(ecalIso);
4083 p_ecalRecHitSumEtConeDR04VsEt_[2]->Fill((*mcPho).fourMomentum().et(), ecalIso);
4084 h_hcalTowerSumEtConeDR04_[
type][2]->Fill(hcalIso);
4085 p_hcalTowerSumEtConeDR04VsEt_[2]->Fill((*mcPho).fourMomentum().et(), hcalIso);
4086 h_hcalTowerBcSumEtConeDR04_[
type][2]->Fill(newhcalIso);
4087 p_hcalTowerBcSumEtConeDR04VsEt_[2]->Fill((*mcPho).fourMomentum().et(), newhcalIso);
4088 h_isoTrkSolidConeDR04_[
type][2]->Fill(
trkIso);
4089 h_nTrkSolidConeDR04_[
type][2]->Fill(nIsoTrk);
4090 h_chHadIso_[2]->Fill(chargedHadIso);
4091 h_nHadIso_[2]->Fill(neutralHadIso);
4093 h_nCluOutsideMustache_[2]->Fill(
float(nClusterOutsideMustache));
4094 h_etOutsideMustache_[2]->Fill(etOutsideMustache);
4095 h_pfMva_[2]->Fill(pfMVA);
4096 h_phoE_[
type][2]->Fill(photonE);
4097 h_phoEt_[
type][2]->Fill(photonEt);
4098 h_nConv_[
type][2]->Fill(
float(matchingPho->conversions().size()));
4099 h_nConv_[1][2]->Fill(
float(matchingPho->conversionsOneLeg().size()));
4100 h_phoERes_[0][2]->Fill(photonE / (*mcPho).fourMomentum().e());
4101 h_phoSigmaEoE_[0][2]->Fill(sigmaEoE);
4102 h_phoEResRegr1_[0][2]->Fill(photonERegr1 / (*mcPho).fourMomentum().e());
4103 h_phoEResRegr2_[0][2]->Fill(photonERegr2 / (*mcPho).fourMomentum().e());
4104 p_eResVsR9_[2]->Fill(
r9, photonE / (*mcPho).fourMomentum().e());
4105 p_sceResVsR9_[2]->Fill(
r9, matchingPho->superCluster()->energy() / (*mcPho).fourMomentum().e());
4106 if (!isRunCentrally_) {
4107 h2_eResVsR9_[2]->Fill(
r9, photonE / (*mcPho).fourMomentum().e());
4108 h2_sceResVsR9_[2]->Fill(
r9, matchingPho->superCluster()->energy() / (*mcPho).fourMomentum().e());
4109 h2_ecalRecHitSumEtConeDR04VsEt_[2]->Fill((*mcPho).fourMomentum().et(), ecalIso);
4110 h2_hcalTowerSumEtConeDR04VsEt_[2]->Fill((*mcPho).fourMomentum().et(), hcalIso);
4111 h2_eResVsEt_[2][0]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
4114 p_eResVsEt_[2][0]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
4115 p_eResVsNVtx_[2][0]->Fill(
float(vtxH->size()), photonE / (*mcPho).fourMomentum().e());
4116 p_sigmaEoEVsEt_[2][0]->Fill((*mcPho).fourMomentum().et(), sigmaEoE);
4117 p_sigmaEoEVsNVtx_[2][0]->Fill(
float(vtxH->size()), sigmaEoE);
4120 h_phoERes_[1][2]->Fill(photonE / (*mcPho).fourMomentum().e());
4121 h_phoSigmaEoE_[1][2]->Fill(sigmaEoE);
4122 h_phoEResRegr1_[1][2]->Fill(photonERegr1 / (*mcPho).fourMomentum().e());
4123 h_phoEResRegr2_[1][2]->Fill(photonERegr2 / (*mcPho).fourMomentum().e());
4124 if (!isRunCentrally_)
4125 h2_eResVsEt_[2][1]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
4126 p_eResVsEt_[2][1]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
4127 p_eResVsNVtx_[2][1]->Fill(
float(vtxH->size()), photonE / (*mcPho).fourMomentum().e());
4128 p_sigmaEoEVsEt_[2][1]->Fill((*mcPho).fourMomentum().et(), sigmaEoE);
4129 p_sigmaEoEVsNVtx_[2][1]->Fill(
float(vtxH->size()), sigmaEoE);
4132 h_phoERes_[2][2]->Fill(photonE / (*mcPho).fourMomentum().e());
4133 h_phoSigmaEoE_[2][2]->Fill(sigmaEoE);
4134 h_phoEResRegr1_[2][2]->Fill(photonERegr1 / (*mcPho).fourMomentum().e());
4135 h_phoEResRegr2_[2][2]->Fill(photonERegr2 / (*mcPho).fourMomentum().e());
4136 p_eResVsEt_[2][2]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
4137 p_eResVsNVtx_[2][2]->Fill(
float(vtxH->size()), photonE / (*mcPho).fourMomentum().e());
4138 p_sigmaEoEVsEt_[2][2]->Fill((*mcPho).fourMomentum().et(), sigmaEoE);
4139 p_sigmaEoEVsNVtx_[2][2]->Fill(
float(vtxH->size()), sigmaEoE);
4141 if (!isRunCentrally_) {
4142 h2_eResVsEt_[2][2]->Fill((*mcPho).fourMomentum().et(), photonE / (*mcPho).fourMomentum().e());
4143 h_EtR9Less093_[0][2]->Fill(photonEt);
4149 if (fName_ ==
"pfPhotonValidator") {
4150 float SumPtIsoValCh = 0.;
4151 float SumPtIsoValNh = 0.;
4152 float SumPtIsoValPh = 0.;
4154 float SumPtIsoValCleanCh = 0.;
4155 float SumPtIsoValCleanNh = 0.;
4156 float SumPtIsoValCleanPh = 0.;
4158 for (
unsigned int lCand = 0; lCand < pfCandidateHandle->size(); lCand++) {
4160 float dR =
deltaR(matchingPho->eta(), matchingPho->phi(), pfCandRef->eta(), pfCandRef->phi());
4170 SumPtIsoValCh += pfCandRef->pt();
4171 h_dRPhoPFcand_ChHad_unCleaned_[0]->Fill(
dR);
4173 h_dRPhoPFcand_ChHad_unCleaned_[1]->Fill(
dR);
4175 h_dRPhoPFcand_ChHad_unCleaned_[2]->Fill(
dR);
4178 SumPtIsoValNh += pfCandRef->pt();
4179 h_dRPhoPFcand_NeuHad_unCleaned_[0]->Fill(
dR);
4181 h_dRPhoPFcand_NeuHad_unCleaned_[1]->Fill(
dR);
4183 h_dRPhoPFcand_NeuHad_unCleaned_[2]->Fill(
dR);
4186 SumPtIsoValPh += pfCandRef->pt();
4187 h_dRPhoPFcand_Pho_unCleaned_[0]->Fill(
dR);
4189 h_dRPhoPFcand_Pho_unCleaned_[1]->Fill(
dR);
4191 h_dRPhoPFcand_Pho_unCleaned_[2]->Fill(
dR);
4195 for (std::vector<reco::PFCandidateRef>::const_iterator
i = phoToParticleBasedIsoMap[matchingPho].
begin();
4196 i != phoToParticleBasedIsoMap[matchingPho].
end();
4198 if ((*
i) == pfCandRef) {
4206 SumPtIsoValCleanCh += pfCandRef->pt();
4207 h_dRPhoPFcand_ChHad_Cleaned_[0]->Fill(
dR);
4209 h_dRPhoPFcand_ChHad_Cleaned_[1]->Fill(
dR);
4211 h_dRPhoPFcand_ChHad_Cleaned_[2]->Fill(
dR);
4214 SumPtIsoValCleanNh += pfCandRef->pt();
4215 h_dRPhoPFcand_NeuHad_Cleaned_[0]->Fill(
dR);
4217 h_dRPhoPFcand_NeuHad_Cleaned_[1]->Fill(
dR);
4219 h_dRPhoPFcand_NeuHad_Cleaned_[2]->Fill(
dR);
4222 SumPtIsoValCleanPh += pfCandRef->pt();
4223 h_dRPhoPFcand_Pho_Cleaned_[0]->Fill(
dR);
4225 h_dRPhoPFcand_Pho_Cleaned_[1]->Fill(
dR);
4227 h_dRPhoPFcand_Pho_Cleaned_[2]->Fill(
dR);
4233 h_SumPtOverPhoPt_ChHad_Cleaned_[0]->Fill(SumPtIsoValCleanCh / matchingPho->pt());
4234 h_SumPtOverPhoPt_NeuHad_Cleaned_[0]->Fill(SumPtIsoValCleanNh / matchingPho->pt());
4235 h_SumPtOverPhoPt_Pho_Cleaned_[0]->Fill(SumPtIsoValCleanPh / matchingPho->pt());
4236 h_SumPtOverPhoPt_ChHad_unCleaned_[0]->Fill(SumPtIsoValCh / matchingPho->pt());
4237 h_SumPtOverPhoPt_NeuHad_unCleaned_[0]->Fill(SumPtIsoValNh / matchingPho->pt());
4238 h_SumPtOverPhoPt_Pho_unCleaned_[0]->Fill(SumPtIsoValPh / matchingPho->pt());
4239 if (phoIsInBarrel) {
4240 h_SumPtOverPhoPt_ChHad_Cleaned_[1]->Fill(SumPtIsoValCleanCh / matchingPho->pt());
4241 h_SumPtOverPhoPt_NeuHad_Cleaned_[1]->Fill(SumPtIsoValCleanNh / matchingPho->pt());
4242 h_SumPtOverPhoPt_Pho_Cleaned_[1]->Fill(SumPtIsoValCleanPh / matchingPho->pt());
4243 h_SumPtOverPhoPt_ChHad_unCleaned_[1]->Fill(SumPtIsoValCh / matchingPho->pt());
4244 h_SumPtOverPhoPt_NeuHad_unCleaned_[1]->Fill(SumPtIsoValNh / matchingPho->pt());
4245 h_SumPtOverPhoPt_Pho_unCleaned_[1]->Fill(SumPtIsoValPh / matchingPho->pt());
4247 h_SumPtOverPhoPt_ChHad_Cleaned_[2]->Fill(SumPtIsoValCleanCh / matchingPho->pt());
4248 h_SumPtOverPhoPt_NeuHad_Cleaned_[2]->Fill(SumPtIsoValCleanNh / matchingPho->pt());
4249 h_SumPtOverPhoPt_Pho_Cleaned_[2]->Fill(SumPtIsoValCleanPh / matchingPho->pt());
4250 h_SumPtOverPhoPt_ChHad_unCleaned_[2]->Fill(SumPtIsoValCh / matchingPho->pt());
4251 h_SumPtOverPhoPt_NeuHad_unCleaned_[2]->Fill(SumPtIsoValNh / matchingPho->pt());
4252 h_SumPtOverPhoPt_Pho_unCleaned_[2]->Fill(SumPtIsoValPh / matchingPho->pt());
4257 if (!(visibleConversion && visibleConversionsWithTwoSimTracks))
4260 if (!isRunCentrally_) {
4261 h_r9_[1][0]->Fill(
r9);
4263 h_r9_[1][1]->Fill(
r9);
4265 h_r9_[1][2]->Fill(
r9);
4267 h_simConvVtxRvsZ_[0]->Fill(fabs(mcConvZ_), mcConvR_);
4268 if (fabs(mcEta_) <= 1.) {
4269 h_simConvVtxRvsZ_[1]->Fill(fabs(mcConvZ_), mcConvR_);
4270 h_simConvVtxYvsX_->Fill(mcConvX_, mcConvY_);
4272 h_simConvVtxRvsZ_[2]->Fill(fabs(mcConvZ_), mcConvR_);
4278 bool atLeastOneRecoTwoTrackConversion =
false;
4279 for (
unsigned int iConv = 0; iConv <
conversions.size(); iConv++) {
4281 double like = aConv->MVAout();
4282 if (like < likelihoodCut_)
4285 if (!isRunCentrally_)
4286 h2_EoverEtrueVsEta_[1]->Fill(mcEta_, matchingPho->superCluster()->energy() / (*mcPho).fourMomentum().e());
4287 p_EoverEtrueVsEta_[1]->Fill(mcEta_, matchingPho->superCluster()->energy() / (*mcPho).fourMomentum().e());
4290 const std::vector<edm::RefToBase<reco::Track> >
tracks = aConv->tracks();
4293 atLeastOneRecoTwoTrackConversion =
true;
4295 h_mvaOut_[0]->Fill(like);
4297 if (
tracks.size() == 2) {
4298 if (
sqrt(aConv->tracksPin()[0].Perp2()) < convTrackMinPtCut_ ||
4299 sqrt(aConv->tracksPin()[1].Perp2()) < convTrackMinPtCut_)
4304 if ((fabs(mcEta_) > 1.1 && fabs(mcEta_) < 1.4) && fabs(aConv->pairCotThetaSeparation()) > dCotHardCutValue_)
4306 if (fabs(aConv->pairCotThetaSeparation()) > dCotCutValue_)
4312 std::map<const reco::Track*, TrackingParticleRef> myAss;
4313 std::map<const reco::Track*, TrackingParticleRef>::const_iterator itAss;
4314 std::map<reco::TrackRef, TrackingParticleRef>::const_iterator itAssMin;
4315 std::map<reco::TrackRef, TrackingParticleRef>::const_iterator itAssMax;
4319 for (
unsigned int i = 0;
i <
tracks.size();
i++) {
4323 if (!isRunCentrally_)
4325 if (!isRunCentrally_)
4336 std::vector<std::pair<RefToBase<reco::Track>,
double> > trackV;
4339 if (
q.find(theConvTP_[0]) !=
q.end()) {
4340 trackV = (std::vector<std::pair<RefToBase<reco::Track>,
double> >)
q[theConvTP_[0]];
4341 }
else if (
q.find(theConvTP_[1]) !=
q.end()) {
4342 trackV = (std::vector<std::pair<RefToBase<reco::Track>,
double> >)
q[theConvTP_[1]];
4349 myAss.insert(std::make_pair(tr.
get(), theConvTP_[tpI]));
4356 float refP = -99999.;
4357 float refPt = -99999.;
4358 if (aConv->conversionVertex().isValid()) {
4359 refP =
sqrt(aConv->refittedPairMomentum().Mag2());
4360 refPt =
sqrt(aConv->refittedPairMomentum().perp2());
4362 float invM = aConv->pairInvariantMass();
4364 h_invMass_[
type][0]->Fill(invM);
4366 h_invMass_[
type][1]->Fill(invM);
4368 h_invMass_[
type][2]->Fill(invM);
4371 if (
tracks.size() == 2) {
4372 h_SimConvTwoTracks_[0]->Fill(mcEta_);
4373 h_SimConvTwoTracks_[1]->Fill(mcPhi_);
4374 h_SimConvTwoTracks_[2]->Fill(mcConvR_);
4375 h_SimConvTwoTracks_[3]->Fill(mcConvZ_);
4376 h_SimConvTwoTracks_[4]->Fill((*mcPho).fourMomentum().et());
4378 if (!aConv->caloCluster().empty())
4379 h_convEta_[1]->
Fill(aConv->caloCluster()[0]->eta());
4381 float trkProvenance = 3;
4382 if (
tracks[0]->
algoName() ==
"outInEcalSeededConv" &&
tracks[1]->algoName() ==
"outInEcalSeededConv")
4384 if (
tracks[0]->
algoName() ==
"inOutEcalSeededConv" &&
tracks[1]->algoName() ==
"inOutEcalSeededConv")
4387 (
tracks[1]->algoName() ==
"outInEcalSeededConv" &&
tracks[0]->algoName() ==
"inOutEcalSeededConv"))
4389 if (trkProvenance == 3) {
4391 h_trkProv_[0]->Fill(trkProvenance);
4394 h_convAlgo_->Fill(aConv->algo());
4398 if (!isRunCentrally_) {
4399 h_r9_[2][0]->Fill(
r9);
4401 h_r9_[2][1]->Fill(
r9);
4403 h_r9_[2][2]->Fill(
r9);
4406 if (!aConv->caloCluster().empty())
4407 h_convEta_[2]->
Fill(aConv->caloCluster()[0]->eta());
4410 h_SimConvTwoMTracks_[0]->Fill(mcEta_);
4411 h_SimConvTwoMTracks_[1]->Fill(mcPhi_);
4412 h_SimConvTwoMTracks_[2]->Fill(mcConvR_);
4413 h_SimConvTwoMTracks_[3]->Fill(mcConvZ_);
4414 h_SimConvTwoMTracks_[4]->Fill((*mcPho).fourMomentum().et());
4416 if (aConv->conversionVertex().isValid()) {
4420 h_SimConvTwoMTracksAndVtxPGT0_[0]->Fill(mcEta_);
4421 h_SimConvTwoMTracksAndVtxPGT0_[1]->Fill(mcPhi_);
4422 h_SimConvTwoMTracksAndVtxPGT0_[2]->Fill(mcConvR_);
4423 h_SimConvTwoMTracksAndVtxPGT0_[3]->Fill(mcConvZ_);
4424 h_SimConvTwoMTracksAndVtxPGT0_[4]->Fill((*mcPho).fourMomentum().et());
4426 if (chi2Prob > 0.0005) {
4427 h_SimConvTwoMTracksAndVtxPGT0005_[0]->Fill(mcEta_);
4428 h_SimConvTwoMTracksAndVtxPGT0005_[1]->Fill(mcPhi_);
4429 h_SimConvTwoMTracksAndVtxPGT0005_[2]->Fill(mcConvR_);
4430 h_SimConvTwoMTracksAndVtxPGT0005_[3]->Fill(mcConvZ_);
4431 h_SimConvTwoMTracksAndVtxPGT0005_[4]->Fill((*mcPho).fourMomentum().et());
4434 if (chi2Prob > 0.0005) {
4435 if (!aConv->caloCluster().empty()) {
4436 h_convEta_[0]->Fill(aConv->caloCluster()[0]->eta());
4437 h_convPhi_[0]->Fill(aConv->caloCluster()[0]->phi());
4438 h_convERes_[0][0]->Fill(aConv->caloCluster()[0]->energy() / (*mcPho).fourMomentum().e());
4440 if (!isRunCentrally_) {
4441 h_r9VsNofTracks_[0][0]->Fill(
r9, aConv->nTracks());
4442 h_EtR9Less093_[1][0]->Fill(photonEt);
4444 h_EtR9Less093_[1][1]->Fill(photonEt);
4446 h_EtR9Less093_[1][2]->Fill(photonEt);
4448 if (phoIsInBarrel) {
4449 if (!aConv->caloCluster().empty())
4450 h_convERes_[0][1]->
Fill(aConv->caloCluster()[0]->energy() / (*mcPho).fourMomentum().e());
4451 if (!isRunCentrally_)
4452 h_r9VsNofTracks_[0][1]->Fill(
r9, aConv->nTracks());
4453 h_mvaOut_[1]->Fill(like);
4455 if (phoIsInEndcap) {
4456 if (!aConv->caloCluster().empty())
4457 h_convERes_[0][2]->
Fill(aConv->caloCluster()[0]->energy() / (*mcPho).fourMomentum().e());
4458 if (!isRunCentrally_)
4459 h_r9VsNofTracks_[0][2]->Fill(
r9, aConv->nTracks());
4460 h_mvaOut_[2]->Fill(like);
4468 h_trkProv_[1]->Fill(trkProvenance);
4469 h_invMass_[
type][0]->Fill(invM);
4471 float eoverp = -99999.;
4473 if (aConv->conversionVertex().isValid()) {
4474 eoverp = photonE /
sqrt(aConv->refittedPairMomentum().Mag2());
4476 h_convPtRes_[
type][0]->Fill(refPt / (*mcPho).fourMomentum().et());
4477 h_EoverPTracks_[
type][0]->Fill(eoverp);
4478 h_PoverETracks_[
type][0]->Fill(1. / eoverp);
4479 if (!isRunCentrally_)
4480 h2_EoverEtrueVsEoverP_[0]->Fill(eoverp,
4481 matchingPho->superCluster()->energy() / (*mcPho).fourMomentum().e());
4482 if (!isRunCentrally_)
4483 h2_PoverPtrueVsEoverP_[0]->Fill(eoverp, refP / (*mcPho).fourMomentum().e());
4484 if (!isRunCentrally_)
4485 h2_EoverPVsEta_[0]->Fill(mcEta_, eoverp);
4486 if (!isRunCentrally_)
4487 h2_EoverPVsR_[0]->Fill(mcConvR_, eoverp);
4488 p_EoverPVsEta_[0]->Fill(mcEta_, eoverp);
4489 p_EoverPVsR_[0]->Fill(mcConvR_, eoverp);
4490 p_eResVsR_->Fill(mcConvR_, photonE / (*mcPho).fourMomentum().e());
4491 if (!isRunCentrally_)
4492 h2_PoverPtrueVsEta_[0]->Fill(mcEta_, refP / (*mcPho).fourMomentum().e());
4493 p_PoverPtrueVsEta_[0]->Fill(mcEta_, refP / (*mcPho).fourMomentum().e());
4496 if (!isRunCentrally_)
4497 h2_EoverEtrueVsEta_[0]->Fill(mcEta_,
4498 matchingPho->superCluster()->energy() / (*mcPho).fourMomentum().e());
4499 if (!isRunCentrally_)
4500 h2_EoverEtrueVsR_[0]->Fill(mcConvR_,
4501 matchingPho->superCluster()->energy() / (*mcPho).fourMomentum().e());
4502 p_EoverEtrueVsEta_[0]->Fill(mcEta_, matchingPho->superCluster()->energy() / (*mcPho).fourMomentum().e());
4503 p_EoverEtrueVsR_[0]->Fill(mcConvR_, matchingPho->superCluster()->energy() / (*mcPho).fourMomentum().e());
4505 if (!isRunCentrally_)
4506 h2_etaVsRsim_[0]->Fill(mcEta_, mcConvR_);
4509 float dPhiTracksAtVtx = aConv->dPhiTracksAtVtx();
4510 h_DPhiTracksAtVtx_[
type][0]->Fill(dPhiTracksAtVtx);
4511 if (!isRunCentrally_)
4512 h2_DPhiTracksAtVtxVsEta_->Fill(mcEta_, dPhiTracksAtVtx);
4513 if (!isRunCentrally_)
4514 h2_DPhiTracksAtVtxVsR_->Fill(mcConvR_, dPhiTracksAtVtx);
4515 p_DPhiTracksAtVtxVsEta_->Fill(mcEta_, dPhiTracksAtVtx);
4516 p_DPhiTracksAtVtxVsR_->Fill(mcConvR_, dPhiTracksAtVtx);
4518 h_DCotTracks_[
type][0]->Fill(aConv->pairCotThetaSeparation());
4519 if (!isRunCentrally_)
4520 h2_DCotTracksVsEta_->Fill(mcEta_, aConv->pairCotThetaSeparation());
4521 if (!isRunCentrally_)
4522 h2_DCotTracksVsR_->Fill(mcConvR_, aConv->pairCotThetaSeparation());
4523 p_DCotTracksVsEta_->Fill(mcEta_, aConv->pairCotThetaSeparation());
4524 p_DCotTracksVsR_->Fill(mcConvR_, aConv->pairCotThetaSeparation());
4526 if (phoIsInBarrel) {
4527 h_invMass_[
type][1]->Fill(invM);
4528 if (aConv->conversionVertex().isValid()) {
4529 h_convPtRes_[
type][1]->Fill(refPt / (*mcPho).fourMomentum().et());
4530 h_EoverPTracks_[
type][1]->Fill(eoverp);
4532 h_EoverPTracks_[0][0]->Fill(eoverp);
4533 if (mcConvR_ > 15 && mcConvR_ < 58)
4534 h_EoverPTracks_[0][1]->Fill(eoverp);
4536 h_EoverPTracks_[0][2]->Fill(eoverp);
4537 h_PoverETracks_[
type][1]->Fill(1. / eoverp);
4538 if (!isRunCentrally_)
4539 h2_EoverEtrueVsEoverP_[1]->Fill(
4540 eoverp, matchingPho->superCluster()->energy() / (*mcPho).fourMomentum().e());
4541 if (!isRunCentrally_)
4542 h2_PoverPtrueVsEoverP_[1]->Fill(eoverp, refP / (*mcPho).fourMomentum().e());
4544 h_DPhiTracksAtVtx_[
type][1]->Fill(dPhiTracksAtVtx);
4545 h_DCotTracks_[
type][1]->Fill(aConv->pairCotThetaSeparation());
4548 if (phoIsInEndcap) {
4549 h_invMass_[
type][2]->Fill(invM);
4550 if (aConv->conversionVertex().isValid()) {
4551 h_convPtRes_[
type][2]->Fill(refPt / (*mcPho).fourMomentum().et());
4552 h_EoverPTracks_[
type][2]->Fill(eoverp);
4553 h_PoverETracks_[
type][2]->Fill(1. / eoverp);
4554 if (!isRunCentrally_)
4555 h2_EoverEtrueVsEoverP_[2]->Fill(
4556 eoverp, matchingPho->superCluster()->energy() / (*mcPho).fourMomentum().e());
4557 if (!isRunCentrally_)
4558 h2_PoverPtrueVsEoverP_[2]->Fill(eoverp, refP / (*mcPho).fourMomentum().e());
4560 h_DPhiTracksAtVtx_[
type][2]->Fill(dPhiTracksAtVtx);
4561 h_DCotTracks_[
type][2]->Fill(aConv->pairCotThetaSeparation());
4564 if (aConv->conversionVertex().isValid()) {
4565 h_convVtxdX_->Fill(aConv->conversionVertex().position().x() - mcConvX_);
4566 h_convVtxdY_->Fill(aConv->conversionVertex().position().y() - mcConvY_);
4567 h_convVtxdZ_->Fill(aConv->conversionVertex().position().z() - mcConvZ_);
4568 h_convVtxdR_->Fill(
sqrt(aConv->conversionVertex().position().perp2()) - mcConvR_);
4570 if (fabs(mcConvEta_) <= 1.2) {
4571 h_convVtxdX_barrel_->Fill(aConv->conversionVertex().position().x() - mcConvX_);
4572 h_convVtxdY_barrel_->Fill(aConv->conversionVertex().position().y() - mcConvY_);
4573 h_convVtxdZ_barrel_->Fill(aConv->conversionVertex().position().z() - mcConvZ_);
4574 h_convVtxdR_barrel_->Fill(
sqrt(aConv->conversionVertex().position().perp2()) - mcConvR_);
4576 h_convVtxdX_endcap_->Fill(aConv->conversionVertex().position().x() - mcConvX_);
4577 h_convVtxdY_endcap_->Fill(aConv->conversionVertex().position().y() - mcConvY_);
4578 h_convVtxdZ_endcap_->Fill(aConv->conversionVertex().position().z() - mcConvZ_);
4579 h_convVtxdR_endcap_->Fill(
sqrt(aConv->conversionVertex().position().perp2()) - mcConvR_);
4582 h_convVtxdPhi_->Fill(aConv->conversionVertex().position().phi() - mcConvPhi_);
4583 h_convVtxdEta_->Fill(aConv->conversionVertex().position().eta() - mcConvEta_);
4584 if (!isRunCentrally_)
4585 h2_convVtxdRVsR_->Fill(mcConvR_,
sqrt(aConv->conversionVertex().position().perp2()) - mcConvR_);
4586 if (!isRunCentrally_)
4587 h2_convVtxdRVsEta_->Fill(mcEta_,
sqrt(aConv->conversionVertex().position().perp2()) - mcConvR_);
4588 p_convVtxdRVsR_->Fill(mcConvR_,
sqrt(aConv->conversionVertex().position().perp2()) - mcConvR_);
4589 p_convVtxdRVsEta_->Fill(mcEta_,
sqrt(aConv->conversionVertex().position().perp2()) - mcConvR_);
4590 float signX = aConv->refittedPairMomentum().x() / fabs(aConv->refittedPairMomentum().x());
4591 float signY = aConv->refittedPairMomentum().y() / fabs(aConv->refittedPairMomentum().y());
4592 float signZ = aConv->refittedPairMomentum().z() / fabs(aConv->refittedPairMomentum().z());
4593 p_convVtxdXVsX_->Fill(mcConvX_, (aConv->conversionVertex().position().x() - mcConvX_) * signX);
4594 p_convVtxdYVsY_->Fill(mcConvY_, (aConv->conversionVertex().position().y() - mcConvY_) * signY);
4595 p_convVtxdZVsZ_->Fill(mcConvZ_, (aConv->conversionVertex().position().z() - mcConvZ_) * signZ);
4597 if (!isRunCentrally_)
4598 h2_convVtxRrecVsTrue_->Fill(mcConvR_,
sqrt(aConv->conversionVertex().position().perp2()));
4601 float thetaConv = aConv->refittedPairMomentum().Theta();
4602 float thetaSC = matchingPho->superCluster()->position().theta();
4604 sqrt(matchingPho->superCluster()->position().x() * matchingPho->superCluster()->position().x() +
4605 matchingPho->superCluster()->position().y() * matchingPho->superCluster()->position().y());
4606 float zSC = matchingPho->superCluster()->position().z();
4607 float zPV =
sqrt(rSC * rSC + zSC * zSC) *
sin(thetaConv - thetaSC) /
sin(thetaConv);
4609 h_zPVFromTracks_[0]->Fill(zPV);
4610 h_dzPVFromTracks_[0]->Fill(zPV - (*mcPho).primaryVertex().z());
4612 if (phoIsInBarrel) {
4613 h_zPVFromTracks_[1]->Fill(zPV);
4614 h_dzPVFromTracks_[1]->Fill(zPV - (*mcPho).primaryVertex().z());
4615 }
else if (phoIsInEndcap) {
4616 h_zPVFromTracks_[2]->Fill(zPV);
4617 h_dzPVFromTracks_[2]->Fill(zPV - (*mcPho).primaryVertex().z());
4618 }
else if (phoIsInEndcapP) {
4619 h_zPVFromTracks_[3]->Fill(zPV);
4620 h_dzPVFromTracks_[3]->Fill(zPV - (*mcPho).primaryVertex().z());
4621 }
else if (phoIsInEndcapM) {
4622 h_zPVFromTracks_[4]->Fill(zPV);
4623 h_dzPVFromTracks_[4]->Fill(zPV - (*mcPho).primaryVertex().z());
4626 p_dzPVVsR_->Fill(mcConvR_, zPV - (*mcPho).primaryVertex().z());
4627 p_dzPVVsEta_->Fill(mcConvEta_, zPV - (*mcPho).primaryVertex().z());
4628 if (!isRunCentrally_)
4629 h2_dzPVVsR_->Fill(mcConvR_, zPV - (*mcPho).primaryVertex().z());
4632 float dPhiTracksAtEcal = -99;
4633 float dEtaTracksAtEcal = -99;
4634 if (!aConv->bcMatchingWithTracks().empty() && aConv->bcMatchingWithTracks()[0].
isNonnull() &&
4635 aConv->bcMatchingWithTracks()[1].
isNonnull()) {
4636 nRecConvAssWithEcal_++;
4637 float recoPhi1 = aConv->ecalImpactPosition()[0].phi();
4638 float recoPhi2 = aConv->ecalImpactPosition()[1].phi();
4639 float recoEta1 = aConv->ecalImpactPosition()[0].eta();
4640 float recoEta2 = aConv->ecalImpactPosition()[1].eta();
4645 recoPhi1 = phiNormalization(recoPhi1);
4646 recoPhi2 = phiNormalization(recoPhi2);
4647 dPhiTracksAtEcal = recoPhi1 - recoPhi2;
4648 dPhiTracksAtEcal = phiNormalization(dPhiTracksAtEcal);
4649 dEtaTracksAtEcal = recoEta1 - recoEta2;
4651 h_DPhiTracksAtEcal_[
type][0]->Fill(fabs(dPhiTracksAtEcal));
4652 if (!isRunCentrally_)
4653 h2_DPhiTracksAtEcalVsR_->Fill(mcConvR_, fabs(dPhiTracksAtEcal));
4654 if (!isRunCentrally_)
4655 h2_DPhiTracksAtEcalVsEta_->Fill(mcEta_, fabs(dPhiTracksAtEcal));
4656 p_DPhiTracksAtEcalVsR_->Fill(mcConvR_, fabs(dPhiTracksAtEcal));
4657 p_DPhiTracksAtEcalVsEta_->Fill(mcEta_, fabs(dPhiTracksAtEcal));
4659 h_DEtaTracksAtEcal_[
type][0]->Fill(dEtaTracksAtEcal);
4661 if (phoIsInBarrel) {
4662 h_DPhiTracksAtEcal_[
type][1]->Fill(fabs(dPhiTracksAtEcal));
4663 h_DEtaTracksAtEcal_[
type][1]->Fill(dEtaTracksAtEcal);
4665 if (phoIsInEndcap) {
4666 h_DPhiTracksAtEcal_[
type][2]->Fill(fabs(dPhiTracksAtEcal));
4667 h_DEtaTracksAtEcal_[
type][2]->Fill(dEtaTracksAtEcal);
4671 for (
unsigned int i = 0;
i <
tracks.size();
i++) {
4673 itAss = myAss.find(tfrb.
get());
4674 if (itAss == myAss.end())
4677 float trkProvenance = 3;
4678 if (
tracks[0]->
algoName() ==
"outInEcalSeededConv" &&
tracks[1]->algoName() ==
"outInEcalSeededConv")
4680 if (
tracks[0]->
algoName() ==
"inOutEcalSeededConv" &&
tracks[1]->algoName() ==
"inOutEcalSeededConv")
4684 (
tracks[1]->algoName() ==
"outInEcalSeededConv" &&
tracks[0]->algoName() ==
"inOutEcalSeededConv"))
4687 if (!isRunCentrally_)
4689 if (!isRunCentrally_)
4695 if (!isRunCentrally_)
4697 if (!isRunCentrally_)
4702 float simPt =
sqrt(((*itAss).second)->momentum().perp2());
4704 float refPt = -9999.;
4705 float px = 0,
py = 0;
4707 if (aConv->conversionVertex().isValid()) {
4708 reco::Track refTrack = aConv->conversionVertex().refittedTracks()[
i];
4713 float ptres = refPt - simPt;
4715 float pterror = aConv->conversionVertex().refittedTracks()[
i].ptError();
4716 if (!isRunCentrally_) {
4717 h2_PtRecVsPtSim_[0]->Fill(simPt, refPt);
4718 if (trkProvenance == 3)
4719 h2_PtRecVsPtSimMixProv_->Fill(simPt, refPt);
4722 h_TkPtPull_[0]->Fill(ptres / pterror);
4723 if (!isRunCentrally_)
4724 h2_TkPtPull_[0]->Fill(mcEta_, ptres / pterror);
4729 if (!aConv->bcMatchingWithTracks().empty() && aConv->bcMatchingWithTracks()[
i].
isNonnull())
4730 hBCEnergyOverTrackPout_[0]->
Fill(aConv->bcMatchingWithTracks()[
i]->energy() /
4731 sqrt(aConv->tracks()[
i]->outerMomentum().Mag2()));
4733 if (phoIsInBarrel) {
4735 h_TkPtPull_[1]->Fill(ptres / pterror);
4736 if (!isRunCentrally_)
4737 h2_PtRecVsPtSim_[1]->Fill(simPt, refPt);
4739 if (!aConv->bcMatchingWithTracks().empty() && aConv->bcMatchingWithTracks()[
i].
isNonnull())
4740 hBCEnergyOverTrackPout_[1]->
Fill(aConv->bcMatchingWithTracks()[
i]->energy() /
4741 sqrt(aConv->tracks()[
i]->outerMomentum().Mag2()));
4743 if (phoIsInEndcap) {
4745 h_TkPtPull_[2]->Fill(ptres / pterror);
4746 if (!isRunCentrally_)
4747 h2_PtRecVsPtSim_[2]->Fill(simPt, refPt);
4749 if (!aConv->bcMatchingWithTracks().empty() && aConv->bcMatchingWithTracks()[
i].
isNonnull())
4750 hBCEnergyOverTrackPout_[2]->
Fill(aConv->bcMatchingWithTracks()[
i]->energy() /
4751 sqrt(aConv->tracks()[
i]->outerMomentum().Mag2()));
4764 if (!atLeastOneRecoTwoTrackConversion) {
4765 for (
unsigned int iConv = 0; iConv < conversionsOneLeg.
size(); iConv++) {
4767 const std::vector<edm::RefToBase<reco::Track> >
tracks = aConv->tracks();
4770 h_convAlgo_->Fill(aConv->algo());
4773 std::map<const reco::Track*, TrackingParticleRef> myAss;
4774 for (
unsigned int i = 0;
i <
tracks.size();
i++) {
4779 float eoverp = photonE /
tracks[0]->p();
4780 h_EoverP_SL_[0]->Fill(eoverp);
4781 if (phoIsInBarrel) {
4782 h_EoverP_SL_[1]->Fill(eoverp);
4784 h_EoverP_SL_[2]->Fill(eoverp);
4786 h_convSLVtxRvsZ_[0]->Fill(
tracks[0]->innerPosition().z(),
sqrt(
tracks[0]->innerPosition().Perp2()));
4787 if (fabs(mcEta_) <= 1.) {
4788 h_convSLVtxRvsZ_[1]->Fill(
tracks[0]->innerPosition().z(),
sqrt(
tracks[0]->innerPosition().Perp2()));
4790 h_convSLVtxRvsZ_[2]->Fill(
tracks[0]->innerPosition().z(),
sqrt(
tracks[0]->innerPosition().Perp2()));
4797 std::vector<std::pair<RefToBase<reco::Track>,
double> > trackV;
4800 if (
q.find(theConvTP_[0]) !=
q.end()) {
4801 trackV = (std::vector<std::pair<RefToBase<reco::Track>,
double> >)
q[theConvTP_[0]];
4802 }
else if (
q.find(theConvTP_[1]) !=
q.end()) {
4803 trackV = (std::vector<std::pair<RefToBase<reco::Track>,
double> >)
q[theConvTP_[1]];
4810 myAss.insert(std::make_pair(tr.
get(), theConvTP_[tpI]));
4815 h_SimConvOneMTracks_[0]->Fill(mcEta_);
4816 h_SimConvOneMTracks_[1]->Fill(mcPhi_);
4817 h_SimConvOneMTracks_[2]->Fill(mcConvR_);
4818 h_SimConvOneMTracks_[3]->Fill(mcConvZ_);
4819 h_SimConvOneMTracks_[4]->Fill((*mcPho).fourMomentum().et());
4828 if (!isRunCentrally_) {
4829 h_nSimPho_[0]->Fill(
float(nSimPho_[0]));
4830 h_nSimPho_[1]->Fill(
float(nSimPho_[1]));
4831 h_nSimConv_[0]->Fill(
float(nSimConv_[0]));
4832 h_nSimConv_[1]->Fill(
float(nSimConv_[1]));
4842 for (
unsigned int iConv = 0; iConv <
conversions.size(); iConv++) {
4844 double like = aConv->MVAout();
4845 if (like < likelihoodCut_)
4848 const std::vector<edm::RefToBase<reco::Track> >
tracks = aConv->tracks();
4858 bool phoIsInBarrel =
false;
4859 bool phoIsInEndcap =
false;
4860 if (fabs(aPho.
superCluster()->position().eta()) < 1.479) {
4861 phoIsInBarrel =
true;
4863 phoIsInEndcap =
true;
4867 if ((fabs(mcEta_) > 1.1 && fabs(mcEta_) < 1.4) && fabs(aConv->pairCotThetaSeparation()) > dCotHardCutValue_)
4869 if (fabs(aConv->pairCotThetaSeparation()) > dCotCutValue_)
4873 h_RecoConvTwoTracks_[0]->Fill(aPho.
eta());
4874 h_RecoConvTwoTracks_[1]->Fill(aPho.
phi());
4875 if (aConv->conversionVertex().isValid())
4876 h_RecoConvTwoTracks_[2]->
Fill(aConv->conversionVertex().position().perp2());
4877 h_RecoConvTwoTracks_[3]->Fill(aConv->conversionVertex().position().z());
4878 h_RecoConvTwoTracks_[4]->Fill(aPho.
et());
4881 for (std::vector<PhotonMCTruth>::const_iterator mcPho = mcPhotons.begin(); mcPho != mcPhotons.end(); mcPho++) {
4883 float mcPhi = (*mcPho).fourMomentum().phi();
4885 mcPhi_ = phiNormalization(mcPhi);
4886 mcEta_ = (*mcPho).fourMomentum().pseudoRapidity();
4887 mcEta_ = etaTransformation(mcEta_, (*mcPho).primaryVertex().z());
4894 if (fabs(mcEta_) > END_HI)
4901 if ((*mcPho).isAConversion() != 1)
4903 if (!((fabs(mcEta_) <= BARL && mcConvR_ < 85) ||
4904 (fabs(mcEta_) > BARL && fabs(mcEta_) <= END_HI && fabs((*mcPho).vertex().z()) < 210)))
4910 if (fabs(
tp->vx() - (*mcPho).vertex().x()) < 0.0001 && fabs(
tp->vy() - (*mcPho).vertex().y()) < 0.0001 &&
4911 fabs(
tp->vz() - (*mcPho).vertex().z()) < 0.0001) {
4912 theConvTP_.push_back(
tp);
4916 if (theConvTP_.size() < 2)
4921 std::vector<std::pair<RefToBase<reco::Track>,
double> > trackV1, trackV2;
4923 auto itP1 =
p1.find(tk1);
4924 auto itP2 =
p2.find(tk2);
4925 bool good = (itP1 !=
p1.end()) and (not itP1->val.empty()) and (itP2 !=
p2.end()) and (not itP2->val.empty());
4927 itP1 =
p1.find(tk2);
4928 itP2 =
p2.find(tk1);
4929 good = (itP1 !=
p1.end()) and (not itP1->val.empty()) and (itP2 !=
p2.end()) and (not itP2->val.empty());
4932 std::vector<std::pair<TrackingParticleRef, double> >
const& tp1 = itP1->val;
4933 std::vector<std::pair<TrackingParticleRef, double> >
const& tp2 = itP2->val;
4938 if (
abs(tpr1->pdgId()) == 11 &&
abs(tpr2->pdgId()) == 11) {
4939 if ((tpr1->parentVertex()->sourceTracks_end() - tpr1->parentVertex()->sourceTracks_begin() == 1) &&
4940 (tpr2->parentVertex()->sourceTracks_end() - tpr2->parentVertex()->sourceTracks_begin() == 1)) {
4941 if (tpr1->parentVertex().
key() == tpr2->parentVertex().
key() &&
4942 ((*tpr1->parentVertex()->sourceTracks_begin())->
pdgId() == 22)) {
4953 h_RecoConvTwoMTracks_[0]->Fill(aPho.
eta());
4954 h_RecoConvTwoMTracks_[1]->Fill(aPho.
phi());
4955 if (aConv->conversionVertex().isValid())
4956 h_RecoConvTwoMTracks_[2]->
Fill(aConv->conversionVertex().position().perp2());
4957 h_RecoConvTwoMTracks_[3]->Fill(aConv->conversionVertex().position().z());
4958 h_RecoConvTwoMTracks_[4]->Fill(aPho.
et());
4962 if (aConv->conversionVertex().isValid()) {
4963 float chi2Prob =
ChiSquaredProbability(aConv->conversionVertex().chi2(), aConv->conversionVertex().ndof());
4964 double convR =
sqrt(aConv->conversionVertex().position().perp2());
4965 double scalar = aConv->conversionVertex().position().x() * aConv->pairMomentum().x() +
4966 aConv->conversionVertex().position().y() * aConv->pairMomentum().y();
4969 convR = -
sqrt(aConv->conversionVertex().position().perp2());
4970 h_convVtxRvsZ_[0]->Fill(fabs(aConv->conversionVertex().position().z()),
4971 sqrt(aConv->conversionVertex().position().perp2()));
4973 if (!aConv->caloCluster().empty()) {
4974 if (!isRunCentrally_)
4975 h2_etaVsRreco_[0]->Fill(aConv->caloCluster()[0]->eta(),
4976 sqrt(aConv->conversionVertex().position().perp2()));
4977 if (fabs(aConv->caloCluster()[0]->eta()) <= 1.) {
4978 h_convVtxYvsX_->Fill(aConv->conversionVertex().position().y(), aConv->conversionVertex().position().x());
4979 h_convVtxRvsZ_[1]->Fill(fabs(aConv->conversionVertex().position().z()), convR);
4981 if (!isRunCentrally_) {
4982 h_convVtxYvsX_zoom_[0]->Fill(aConv->conversionVertex().position().y(),
4983 aConv->conversionVertex().position().x());
4984 h_convVtxYvsX_zoom_[1]->Fill(aConv->conversionVertex().position().y(),
4985 aConv->conversionVertex().position().x());
4986 h_convVtxRvsZ_zoom_[0]->Fill(fabs(aConv->conversionVertex().position().z()), convR);
4987 h_convVtxRvsZ_zoom_[1]->Fill(fabs(aConv->conversionVertex().position().z()), convR);
4990 if (fabs(aConv->caloCluster()[0]->eta()) > 1.)
4991 h_convVtxRvsZ_[2]->Fill(fabs(aConv->conversionVertex().position().z()), convR);
4994 h_vtxChi2Prob_[0]->Fill(chi2Prob);
4995 h_vtxChi2_[0]->Fill(aConv->conversionVertex().normalizedChi2());
4996 if (phoIsInBarrel) {
4997 h_vtxChi2Prob_[1]->Fill(chi2Prob);
4998 h_vtxChi2_[1]->Fill(aConv->conversionVertex().normalizedChi2());
5000 if (phoIsInEndcap) {
5001 h_vtxChi2Prob_[2]->Fill(chi2Prob);
5002 h_vtxChi2_[2]->Fill(aConv->conversionVertex().normalizedChi2());
5012 for (reco::GenJetCollection::const_iterator genJetIter =
genJetCollection.begin();
5015 if (genJetIter->pt() < minPhoEtCut_)
5017 if (fabs(genJetIter->eta()) > 2.5)
5020 float mcJetPhi = genJetIter->phi();
5021 mcJetPhi_ = phiNormalization(mcJetPhi);
5022 mcJetEta_ = genJetIter->eta();
5023 float mcJetPt = genJetIter->pt();
5025 h_SimJet_[0]->Fill(mcJetEta_);
5026 h_SimJet_[1]->Fill(mcJetPhi_);
5027 h_SimJet_[2]->Fill(mcJetPt);
5029 std::vector<reco::Photon> thePhotons;
5036 float phiPho = aPho.
phi();
5037 float etaPho = aPho.
eta();
5038 float deltaPhi = phiPho - mcJetPhi_;
5039 float deltaEta = etaPho - mcJetEta_;
5048 matchingPho = *iPho;
5057 h_MatchedSimJet_[0]->Fill(mcJetEta_);
5058 h_MatchedSimJet_[1]->Fill(mcJetPhi_);
5059 h_MatchedSimJet_[2]->Fill(mcJetPt);
5061 bool phoIsInBarrel =
false;
5062 bool phoIsInEndcap =
false;
5063 if (fabs(matchingPho.
superCluster()->position().eta()) < 1.479) {
5064 phoIsInBarrel =
true;
5066 phoIsInEndcap =
true;
5069 if (phoIsInBarrel) {
5071 e.getByToken(barrelEcalHits_, ecalRecHitHandle);
5072 if (!ecalRecHitHandle.
isValid()) {
5074 labelsForToken(barrelEcalHits_,
l);
5075 edm::LogError(
"PhotonProducer") <<
"Error! Can't get the product " <<
l.module;
5079 }
else if (phoIsInEndcap) {
5081 e.getByToken(endcapEcalHits_, ecalRecHitHandle);
5082 if (!ecalRecHitHandle.
isValid()) {
5084 labelsForToken(barrelEcalHits_,
l);
5085 edm::LogError(
"PhotonProducer") <<
"Error! Can't get the product " <<
l.module;
5091 float photonE = matchingPho.
energy();
5092 float photonEt = matchingPho.
et();
5093 float r9 = matchingPho.
r9();
5094 float r1 = matchingPho.
r1x5();
5095 float r2 = matchingPho.
r2x5();
5102 std::vector<std::pair<DetId, float> >::const_iterator rhIt;
5104 bool atLeastOneDeadChannel =
false;
5108 for (rhIt = (*bcIt)->hitsAndFractions().begin(); rhIt != (*bcIt)->hitsAndFractions().end(); ++rhIt) {
5111 if (rhIt->first == (*it).id()) {
5112 if ((*it).recoFlag() == 9) {
5113 atLeastOneDeadChannel =
true;
5121 if (atLeastOneDeadChannel) {
5122 h_MatchedSimJetBadCh_[0]->Fill(mcJetEta_);
5123 h_MatchedSimJetBadCh_[1]->Fill(mcJetPhi_);
5124 h_MatchedSimJetBadCh_[2]->Fill(mcJetPt);
5129 h_scBkgE_[0]->Fill(matchingPho.
superCluster()->energy());
5132 h_phoBkgEta_->Fill(matchingPho.
eta());
5133 h_phoBkgPhi_->Fill(matchingPho.
phi());
5134 h_phoBkgE_[0]->Fill(photonE);
5135 h_phoBkgEt_[0]->Fill(photonEt);
5136 h_phoBkgDEta_->Fill(matchingPho.
eta() - mcJetEta_);
5137 h_phoBkgDPhi_->Fill(matchingPho.
phi() - mcJetPhi_);
5139 h_r9Bkg_[0]->Fill(
r9);
5140 h_r1Bkg_[0]->Fill(
r1);
5141 h_r2Bkg_[0]->Fill(
r2);
5142 h_sigmaIetaIetaBkg_[0]->Fill(sigmaIetaIeta);
5143 h_hOverEBkg_[0]->Fill(
hOverE);
5144 h_ecalRecHitSumEtConeDR04Bkg_[0]->Fill(ecalIso);
5145 h_hcalTowerSumEtConeDR04Bkg_[0]->Fill(hcalIso);
5146 h_isoTrkSolidConeDR04Bkg_[0]->Fill(
trkIso);
5147 h_nTrkSolidConeDR04Bkg_[0]->Fill(nIsoTrk);
5149 if (!isRunCentrally_) {
5150 h2_r9VsEtaBkg_->Fill(mcJetEta_,
r9);
5151 h2_r9VsEtBkg_->Fill(mcJetPt,
r9);
5152 h2_r1VsEtaBkg_->Fill(mcJetEta_,
r1);
5153 h2_r1VsEtBkg_->Fill(mcJetPt,
r1);
5154 h2_r2VsEtaBkg_->Fill(mcJetEta_,
r2);
5155 h2_r2VsEtBkg_->Fill(mcJetPt,
r2);
5156 h2_sigmaIetaIetaVsEtaBkg_->Fill(mcJetEta_, sigmaIetaIeta);
5157 h2_sigmaIetaIetaVsEtBkg_[0]->Fill(mcJetPt, sigmaIetaIeta);
5158 h2_hOverEVsEtaBkg_->Fill(mcJetEta_,
hOverE);
5159 h2_hOverEVsEtBkg_->Fill(mcJetPt,
hOverE);
5161 p_r1VsEtaBkg_->Fill(mcJetEta_,
r1);
5162 p_r1VsEtBkg_->Fill(mcJetPt,
r1);
5163 p_r2VsEtaBkg_->Fill(mcJetEta_,
r2);
5164 p_r2VsEtBkg_->Fill(mcJetPt,
r2);
5165 p_sigmaIetaIetaVsEtaBkg_->Fill(mcJetEta_, sigmaIetaIeta);
5166 p_sigmaIetaIetaVsEtBkg_[0]->Fill(mcJetPt, sigmaIetaIeta);
5167 p_hOverEVsEtaBkg_->Fill(mcJetEta_,
hOverE);
5168 p_hOverEVsEtBkg_->Fill(mcJetPt,
hOverE);
5171 if (!isRunCentrally_) {
5172 h2_ecalRecHitSumEtConeDR04VsEtaBkg_->Fill(mcJetEta_, ecalIso);
5173 h2_ecalRecHitSumEtConeDR04VsEtBkg_[0]->Fill(mcJetPt, ecalIso);
5174 h2_hcalTowerSumEtConeDR04VsEtaBkg_->Fill(mcJetEta_, hcalIso);
5175 h2_hcalTowerSumEtConeDR04VsEtBkg_[0]->Fill(mcJetPt, hcalIso);
5176 p_ecalRecHitSumEtConeDR04VsEtaBkg_->Fill(mcJetEta_, ecalIso);
5177 p_ecalRecHitSumEtConeDR04VsEtBkg_[0]->Fill(mcJetPt, ecalIso);
5178 p_hcalTowerSumEtConeDR04VsEtaBkg_->Fill(mcJetEta_, hcalIso);
5179 p_hcalTowerSumEtConeDR04VsEtBkg_[0]->Fill(mcJetPt, hcalIso);
5180 p_isoTrkSolidConeDR04VsEtaBkg_->Fill(mcJetEta_,
trkIso);
5181 p_isoTrkSolidConeDR04VsEtBkg_[0]->Fill(mcJetPt,
trkIso);
5182 p_nTrkSolidConeDR04VsEtaBkg_->Fill(mcJetEta_, nIsoTrk);
5183 p_nTrkSolidConeDR04VsEtBkg_[0]->Fill(mcJetPt, nIsoTrk);
5184 h2_isoTrkSolidConeDR04VsEtaBkg_->Fill(mcJetEta_,
trkIso);
5185 h2_isoTrkSolidConeDR04VsEtBkg_[0]->Fill(mcJetPt,
trkIso);
5186 h2_nTrkSolidConeDR04VsEtaBkg_->Fill(mcJetEta_, nIsoTrk);
5187 h2_nTrkSolidConeDR04VsEtBkg_[0]->Fill(mcJetPt, nIsoTrk);
5190 if (phoIsInBarrel) {
5191 h_r9Bkg_[1]->Fill(
r9);
5192 h_r1Bkg_[1]->Fill(
r1);
5193 h_r2Bkg_[1]->Fill(
r2);
5195 h_sigmaIetaIetaBkg_[1]->Fill(sigmaIetaIeta);
5196 h_hOverEBkg_[1]->Fill(
hOverE);
5197 h_ecalRecHitSumEtConeDR04Bkg_[1]->Fill(ecalIso);
5198 h_hcalTowerSumEtConeDR04Bkg_[1]->Fill(hcalIso);
5199 h_isoTrkSolidConeDR04Bkg_[1]->Fill(
trkIso);
5200 h_nTrkSolidConeDR04Bkg_[1]->Fill(nIsoTrk);
5202 if (!isRunCentrally_) {
5203 h2_sigmaIetaIetaVsEtBkg_[1]->Fill(mcJetPt, sigmaIetaIeta);
5204 h2_isoTrkSolidConeDR04VsEtBkg_[1]->Fill(mcJetPt,
trkIso);
5205 h2_nTrkSolidConeDR04VsEtBkg_[1]->Fill(mcJetPt, nIsoTrk);
5206 h2_ecalRecHitSumEtConeDR04VsEtBkg_[1]->Fill(mcJetPt, ecalIso);
5207 h2_hcalTowerSumEtConeDR04VsEtBkg_[1]->Fill(mcJetPt, hcalIso);
5208 p_sigmaIetaIetaVsEtBkg_[1]->Fill(mcJetPt, sigmaIetaIeta);
5209 p_ecalRecHitSumEtConeDR04VsEtBkg_[1]->Fill(mcJetPt, ecalIso);
5210 p_hcalTowerSumEtConeDR04VsEtBkg_[1]->Fill(mcJetPt, hcalIso);
5211 p_isoTrkSolidConeDR04VsEtBkg_[1]->Fill(mcJetPt,
trkIso);
5212 p_nTrkSolidConeDR04VsEtBkg_[1]->Fill(mcJetPt, nIsoTrk);
5214 }
else if (phoIsInEndcap) {
5215 h_r9Bkg_[2]->Fill(
r9);
5216 h_r1Bkg_[2]->Fill(
r1);
5217 h_r2Bkg_[2]->Fill(
r2);
5219 h_sigmaIetaIetaBkg_[2]->Fill(sigmaIetaIeta);
5220 h_hOverEBkg_[2]->Fill(
hOverE);
5221 h_ecalRecHitSumEtConeDR04Bkg_[2]->Fill(ecalIso);
5222 h_hcalTowerSumEtConeDR04Bkg_[2]->Fill(hcalIso);
5223 h_isoTrkSolidConeDR04Bkg_[2]->Fill(
trkIso);
5224 h_nTrkSolidConeDR04Bkg_[2]->Fill(nIsoTrk);
5226 if (!isRunCentrally_) {
5227 h2_sigmaIetaIetaVsEtBkg_[2]->Fill(mcJetPt, sigmaIetaIeta);
5228 h2_isoTrkSolidConeDR04VsEtBkg_[2]->Fill(mcJetPt,
trkIso);
5229 h2_nTrkSolidConeDR04VsEtBkg_[2]->Fill(mcJetPt, nIsoTrk);
5230 h2_ecalRecHitSumEtConeDR04VsEtBkg_[2]->Fill(mcJetPt, ecalIso);
5231 h2_hcalTowerSumEtConeDR04VsEtBkg_[2]->Fill(mcJetPt, hcalIso);
5232 p_sigmaIetaIetaVsEtBkg_[2]->Fill(mcJetPt, sigmaIetaIeta);
5233 p_ecalRecHitSumEtConeDR04VsEtBkg_[2]->Fill(mcJetPt, ecalIso);
5234 p_hcalTowerSumEtConeDR04VsEtBkg_[2]->Fill(mcJetPt, hcalIso);
5235 p_isoTrkSolidConeDR04VsEtBkg_[2]->Fill(mcJetPt,
trkIso);
5236 p_nTrkSolidConeDR04VsEtBkg_[2]->Fill(mcJetPt, nIsoTrk);
5243 for (
unsigned int iConv = 0; iConv <
conversions.size(); iConv++) {
5246 const std::vector<edm::RefToBase<reco::Track> >
tracks = aConv->tracks();
5247 double like = aConv->MVAout();
5248 if (like < likelihoodCut_)
5252 if (!aConv->caloCluster().empty()) {
5253 h_convEtaBkg_->Fill(aConv->caloCluster()[0]->eta());
5254 h_convPhiBkg_->Fill(aConv->caloCluster()[0]->phi());
5256 h_mvaOutBkg_[0]->Fill(like);
5257 float eoverp = aConv->EoverP();
5258 h_EoverPTracksBkg_[0]->Fill(eoverp);
5259 h_PoverETracksBkg_[0]->Fill(1. / eoverp);
5260 h_DCotTracksBkg_[0]->Fill(aConv->pairCotThetaSeparation());
5261 float dPhiTracksAtVtx = aConv->dPhiTracksAtVtx();
5262 h_DPhiTracksAtVtxBkg_[0]->Fill(dPhiTracksAtVtx);
5264 if (phoIsInBarrel) {
5265 h_mvaOutBkg_[1]->Fill(like);
5266 h_EoverPTracksBkg_[1]->Fill(eoverp);
5267 h_PoverETracksBkg_[1]->Fill(1. / eoverp);
5268 h_DCotTracksBkg_[1]->Fill(aConv->pairCotThetaSeparation());
5269 h_DPhiTracksAtVtxBkg_[1]->Fill(dPhiTracksAtVtx);
5270 }
else if (phoIsInEndcap) {
5271 h_mvaOutBkg_[2]->Fill(like);
5272 h_EoverPTracksBkg_[2]->Fill(eoverp);
5273 h_PoverETracksBkg_[2]->Fill(1. / eoverp);
5274 h_DCotTracksBkg_[2]->Fill(aConv->pairCotThetaSeparation());
5275 h_DPhiTracksAtVtxBkg_[2]->Fill(dPhiTracksAtVtx);
5278 if (aConv->conversionVertex().isValid()) {
5279 double convR =
sqrt(aConv->conversionVertex().position().perp2());
5280 double scalar = aConv->conversionVertex().position().x() * aConv->pairMomentum().x() +
5281 aConv->conversionVertex().position().y() * aConv->pairMomentum().y();
5283 convR = -
sqrt(aConv->conversionVertex().position().perp2());
5285 if (!isRunCentrally_) {
5286 h_convVtxRvsZBkg_[0]->Fill(fabs(aConv->conversionVertex().position().z()),
5287 sqrt(aConv->conversionVertex().position().perp2()));
5288 if (!aConv->caloCluster().empty() && fabs(aConv->caloCluster()[0]->eta()) <= 1.) {
5289 h_convVtxYvsXBkg_->Fill(aConv->conversionVertex().position().y(),
5290 aConv->conversionVertex().position().x());
5291 h_convVtxRvsZBkg_[1]->Fill(fabs(aConv->conversionVertex().position().z()), convR);
5304 if (!(mcIter->pdgId() == 22))
5306 if (mcIter->mother() !=
nullptr and !(mcIter->mother()->pdgId() == 25))
5308 if (fabs(mcIter->eta()) > 2.5)
5311 float mcPhi = mcIter->phi();
5312 float mcEta = mcIter->eta();
5314 float mcEnergy = mcIter->energy();
5316 double dR = 9999999.;
5317 float minDr = 10000.;
5321 for (
unsigned int ipho = 0; ipho < photonHandle->size(); ipho++) {
5324 double dphi = pho->phi() - mcPhi;
5326 dphi = dphi < 0 ? (CLHEP::twopi) + dphi : dphi - CLHEP::twopi;
5328 double deta = pho->superCluster()->position().eta() - mcEta;
5331 if (
dR < 0.1 &&
dR < minDr) {
5344 bool phoIsInBarrel =
false;
5345 bool phoIsInEndcap =
false;
5347 float phoEta = matchingPho->superCluster()->position().eta();
5348 if (fabs(phoEta) < 1.479) {
5349 phoIsInBarrel =
true;
5351 phoIsInEndcap =
true;
5354 float photonE = matchingPho->energy();
5355 float sigmaEoE = matchingPho->getCorrectedEnergyError(matchingPho->getCandidateP4type()) / matchingPho->energy();
5356 float photonEt = matchingPho->energy() / cosh(matchingPho->eta());
5359 float r9 = matchingPho->r9();
5360 float full5x5_r9 = matchingPho->full5x5_r9();
5361 float r1 = matchingPho->r1x5();
5362 float r2 = matchingPho->r2x5();
5363 float sigmaIetaIeta = matchingPho->sigmaIetaIeta();
5364 float full5x5_sieie = matchingPho->full5x5_sigmaIetaIeta();
5365 float hOverE = matchingPho->hadronicOverEm();
5366 float newhOverE = matchingPho->hadTowOverEm();
5367 float ecalIso = matchingPho->ecalRecHitSumEtConeDR04();
5368 float hcalIso = matchingPho->hcalTowerSumEtConeDR04();
5369 float newhcalIso = matchingPho->hcalTowerSumEtBcConeDR04();
5370 float trkIso = matchingPho->trkSumPtSolidConeDR04();
5371 float nIsoTrk = matchingPho->nTrkSolidConeDR04();
5373 float chargedHadIso = matchingPho->chargedHadronIso();
5374 float neutralHadIso = matchingPho->neutralHadronIso();
5375 float photonIso = matchingPho->photonIso();
5380 if ((photonEt > 14 && newhOverE < 0.15) || (photonEt > 10 && photonEt < 14 && chargedHadIso < 10)) {
5381 h_scEta_miniAOD_[0]->Fill(matchingPho->superCluster()->eta());
5382 h_scPhi_miniAOD_[0]->Fill(matchingPho->superCluster()->phi());
5384 h_phoE_miniAOD_[0][0]->Fill(photonE);
5385 h_phoEt_miniAOD_[0][0]->Fill(photonEt);
5387 h_phoERes_miniAOD_[0][0]->Fill(photonE / mcEnergy);
5388 h_phoSigmaEoE_miniAOD_[0][0]->Fill(sigmaEoE);
5390 h_r9_miniAOD_[0][0]->Fill(
r9);
5391 h_full5x5_r9_miniAOD_[0][0]->Fill(full5x5_r9);
5392 h_r1_miniAOD_[0][0]->Fill(
r1);
5393 h_r2_miniAOD_[0][0]->Fill(
r2);
5395 h_sigmaIetaIeta_miniAOD_[0][0]->Fill(sigmaIetaIeta);
5396 h_full5x5_sigmaIetaIeta_miniAOD_[0][0]->Fill(full5x5_sieie);
5397 h_hOverE_miniAOD_[0][0]->Fill(
hOverE);
5398 h_newhOverE_miniAOD_[0][0]->Fill(newhOverE);
5400 h_ecalRecHitSumEtConeDR04_miniAOD_[0][0]->Fill(ecalIso);
5401 h_hcalTowerSumEtConeDR04_miniAOD_[0][0]->Fill(hcalIso);
5402 h_hcalTowerBcSumEtConeDR04_miniAOD_[0][0]->Fill(newhcalIso);
5403 h_isoTrkSolidConeDR04_miniAOD_[0][0]->Fill(
trkIso);
5404 h_nTrkSolidConeDR04_miniAOD_[0][0]->Fill(nIsoTrk);
5407 h_chHadIso_miniAOD_[0]->Fill(chargedHadIso);
5408 h_nHadIso_miniAOD_[0]->Fill(neutralHadIso);
5412 if (phoIsInBarrel) {
5413 h_phoE_miniAOD_[0][1]->Fill(photonE);
5414 h_phoEt_miniAOD_[0][1]->Fill(photonEt);
5416 h_phoERes_miniAOD_[0][1]->Fill(photonE / mcEnergy);
5417 h_phoSigmaEoE_miniAOD_[0][1]->Fill(sigmaEoE);
5419 h_r9_miniAOD_[0][1]->Fill(
r9);
5420 h_full5x5_r9_miniAOD_[0][1]->Fill(full5x5_r9);
5421 h_r1_miniAOD_[0][1]->Fill(
r1);
5422 h_r2_miniAOD_[0][1]->Fill(
r2);
5423 h_sigmaIetaIeta_miniAOD_[0][1]->Fill(sigmaIetaIeta);
5424 h_full5x5_sigmaIetaIeta_miniAOD_[0][1]->Fill(full5x5_sieie);
5425 h_hOverE_miniAOD_[0][1]->Fill(
hOverE);
5426 h_newhOverE_miniAOD_[0][1]->Fill(newhOverE);
5427 h_ecalRecHitSumEtConeDR04_miniAOD_[0][1]->Fill(ecalIso);
5428 h_hcalTowerSumEtConeDR04_miniAOD_[0][1]->Fill(hcalIso);
5429 h_hcalTowerBcSumEtConeDR04_miniAOD_[0][1]->Fill(newhcalIso);
5430 h_isoTrkSolidConeDR04_miniAOD_[0][1]->Fill(
trkIso);
5431 h_nTrkSolidConeDR04_miniAOD_[0][1]->Fill(nIsoTrk);
5432 h_chHadIso_miniAOD_[1]->Fill(chargedHadIso);
5433 h_nHadIso_miniAOD_[1]->Fill(neutralHadIso);
5436 if (phoIsInEndcap) {
5437 h_phoE_miniAOD_[0][2]->Fill(photonE);
5438 h_phoEt_miniAOD_[0][2]->Fill(photonEt);
5440 h_phoERes_miniAOD_[0][2]->Fill(photonE / mcEnergy);
5441 h_phoSigmaEoE_miniAOD_[0][2]->Fill(sigmaEoE);
5442 h_r9_miniAOD_[0][2]->Fill(
r9);
5443 h_full5x5_r9_miniAOD_[0][2]->Fill(full5x5_r9);
5444 h_r1_miniAOD_[0][2]->Fill(
r1);
5445 h_r2_miniAOD_[0][2]->Fill(
r2);
5446 h_sigmaIetaIeta_miniAOD_[0][2]->Fill(sigmaIetaIeta);
5447 h_full5x5_sigmaIetaIeta_miniAOD_[0][2]->Fill(full5x5_sieie);
5448 h_hOverE_miniAOD_[0][2]->Fill(
hOverE);
5449 h_newhOverE_miniAOD_[0][2]->Fill(newhOverE);
5450 h_ecalRecHitSumEtConeDR04_miniAOD_[0][2]->Fill(ecalIso);
5451 h_hcalTowerSumEtConeDR04_miniAOD_[0][2]->Fill(hcalIso);
5452 h_hcalTowerBcSumEtConeDR04_miniAOD_[0][2]->Fill(newhcalIso);
5453 h_isoTrkSolidConeDR04_miniAOD_[0][2]->Fill(
trkIso);
5454 h_nTrkSolidConeDR04_miniAOD_[0][2]->Fill(nIsoTrk);
5455 h_chHadIso_miniAOD_[2]->Fill(chargedHadIso);
5456 h_nHadIso_miniAOD_[2]->Fill(neutralHadIso);
5463 h_nPho_->Fill(
float(nPho));
5468 const float PI = 3.1415927;
5483 const float PI = 3.1415927;
5486 const float R_ECAL = 136.5;
5493 float ZEcal =
R_ECAL * sinh(EtaParticle) + Zvertex;
5503 if (EtaParticle < 0.0)
5505 float Zlen = Zend - Zvertex;
5506 float RR = Zlen / sinh(EtaParticle);
5507 Theta = atan(RR / Zend);