CMS 3D CMS Logo

MTVHistoProducerAlgoForTracker.cc
Go to the documentation of this file.
4 
9 
11 
12 #include "TMath.h"
13 #include <TF1.h>
14 #include <cassert>
15 
16 using namespace std;
17 
18 namespace {
20 
21  void BinLogX(TH1* h) {
22  TAxis* axis = h->GetXaxis();
23  int bins = axis->GetNbins();
24 
25  float from = axis->GetXmin();
26  float to = axis->GetXmax();
27  float width = (to - from) / bins;
28  std::vector<float> new_bins(bins + 1, 0);
29 
30  for (int i = 0; i <= bins; i++) {
31  new_bins[i] = TMath::Power(10, from + i * width);
32  }
33  axis->Set(bins, new_bins.data());
34  }
35 
36  void BinLogY(TH1* h) {
37  TAxis* axis = h->GetYaxis();
38  int bins = axis->GetNbins();
39 
40  float from = axis->GetXmin();
41  float to = axis->GetXmax();
42  float width = (to - from) / bins;
43  std::vector<float> new_bins(bins + 1, 0);
44 
45  for (int i = 0; i <= bins; i++) {
46  new_bins[i] = TMath::Power(10, from + i * width);
47  }
48  axis->Set(bins, new_bins.data());
49  }
50 
51  template <typename... Args>
52  dqm::reco::MonitorElement* make1DIfLogX(DQMStore::IBooker& ibook, bool logx, Args&&... args) {
53  auto h = std::make_unique<TH1F>(std::forward<Args>(args)...);
54  if (logx)
55  BinLogX(h.get());
56  const auto& name = h->GetName();
57  return ibook.book1D(name, h.release());
58  }
59 
60  template <typename... Args>
61  dqm::reco::MonitorElement* makeProfileIfLogX(DQMStore::IBooker& ibook, bool logx, Args&&... args) {
62  auto h = std::make_unique<TProfile>(std::forward<Args>(args)...);
63  if (logx)
64  BinLogX(h.get());
65  const auto& name = h->GetName();
66  return ibook.bookProfile(name, h.release());
67  }
68 
69  template <typename... Args>
70  dqm::reco::MonitorElement* make2DIfLogX(DQMStore::IBooker& ibook, bool logx, Args&&... args) {
71  auto h = std::make_unique<TH2F>(std::forward<Args>(args)...);
72  if (logx)
73  BinLogX(h.get());
74  const auto& name = h->GetName();
75  return ibook.book2D(name, h.release());
76  }
77 
78  template <typename... Args>
79  dqm::reco::MonitorElement* make2DIfLogY(DQMStore::IBooker& ibook, bool logy, Args&&... args) {
80  auto h = std::make_unique<TH2F>(std::forward<Args>(args)...);
81  if (logy)
82  BinLogY(h.get());
83  const auto& name = h->GetName();
84  return ibook.book2D(name, h.release());
85  }
86 
87  void setBinLabels(dqm::reco::MonitorElement*& h, const std::vector<std::string>& labels) {
88  for (size_t i = 0; i < labels.size(); ++i) {
89  h->setBinLabel(i + 1, labels[i]);
90  }
91  h->disableAlphanumeric();
92  }
93 
94  void setBinLabelsAlgo(dqm::reco::MonitorElement*& h, int axis = 1) {
95  for (size_t i = 0; i < reco::TrackBase::algoSize; ++i) {
96  h->setBinLabel(i + 1, reco::TrackBase::algoName(static_cast<reco::TrackBase::TrackAlgorithm>(i)), axis);
97  }
98  h->disableAlphanumeric();
99  }
100 
101  void fillMVAHistos(const std::vector<dqm::reco::MonitorElement*>& h_mva,
102  const std::vector<dqm::reco::MonitorElement*>& h_mvacut,
103  const std::vector<dqm::reco::MonitorElement*>& h_mva_hp,
104  const std::vector<dqm::reco::MonitorElement*>& h_mvacut_hp,
105  const std::vector<float>& mvas,
106  unsigned int selectsLoose,
107  unsigned int selectsHP) {
108  // Fill MVA1 histos with all tracks, MVA2 histos only with tracks
109  // not selected by MVA1, etc.
110  for (size_t i = 0; i < mvas.size(); ++i) {
111  if (i <= selectsLoose) {
112  h_mva[i]->Fill(mvas[i]);
113  h_mvacut[i]->Fill(mvas[i]);
114  }
115  if (i >= 1 && i <= selectsHP) {
116  h_mva_hp[i]->Fill(mvas[i]);
117  h_mvacut_hp[i]->Fill(mvas[i]);
118  }
119  }
120  }
121 
122  void fillMVAHistos(double xval,
123  const std::vector<dqm::reco::MonitorElement*>& h_mva,
124  const std::vector<dqm::reco::MonitorElement*>& h_mva_hp,
125  const std::vector<float>& mvas,
126  unsigned int selectsLoose,
127  unsigned int selectsHP) {
128  // Fill MVA1 histos with all tracks, MVA2 histos only with tracks
129  // not selected by MVA1, etc.
130  for (size_t i = 0; i < mvas.size(); ++i) {
131  if (i <= selectsLoose) {
132  h_mva[i]->Fill(xval, mvas[i]);
133  }
134  if (i >= 1 && i <= selectsHP) {
135  h_mva_hp[i]->Fill(xval, mvas[i]);
136  }
137  }
138  }
139 } // namespace
140 
142  : doSeedPlots_(doSeedPlots), doMTDPlots_(pset.getUntrackedParameter<bool>("doMTDPlots")) {
143  //parameters for _vs_eta plots
144  minEta = pset.getParameter<double>("minEta");
145  maxEta = pset.getParameter<double>("maxEta");
146  nintEta = pset.getParameter<int>("nintEta");
147  useFabsEta = pset.getParameter<bool>("useFabsEta");
148 
149  //parameters for _vs_pt plots
150  minPt = pset.getParameter<double>("minPt");
151  maxPt = pset.getParameter<double>("maxPt");
152  nintPt = pset.getParameter<int>("nintPt");
153  useInvPt = pset.getParameter<bool>("useInvPt");
154  useLogPt = pset.getUntrackedParameter<bool>("useLogPt", false);
155 
156  //parameters for _vs_Hit plots
157  minHit = pset.getParameter<double>("minHit");
158  maxHit = pset.getParameter<double>("maxHit");
159  nintHit = pset.getParameter<int>("nintHit");
160 
161  //parameters for _vs_Pu plots
162  minPu = pset.getParameter<double>("minPu");
163  maxPu = pset.getParameter<double>("maxPu");
164  nintPu = pset.getParameter<int>("nintPu");
165 
166  //parameters for _vs_Layer plots
167  minLayers = pset.getParameter<double>("minLayers");
168  maxLayers = pset.getParameter<double>("maxLayers");
169  nintLayers = pset.getParameter<int>("nintLayers");
170 
171  //parameters for _vs_phi plots
172  minPhi = pset.getParameter<double>("minPhi");
173  maxPhi = pset.getParameter<double>("maxPhi");
174  nintPhi = pset.getParameter<int>("nintPhi");
175 
176  //parameters for _vs_Dxy plots
177  minDxy = pset.getParameter<double>("minDxy");
178  maxDxy = pset.getParameter<double>("maxDxy");
179  nintDxy = pset.getParameter<int>("nintDxy");
180 
181  //parameters for _vs_Dz plots
182  minDz = pset.getParameter<double>("minDz");
183  maxDz = pset.getParameter<double>("maxDz");
184  nintDz = pset.getParameter<int>("nintDz");
185 
186  dxyDzZoom = pset.getParameter<double>("dxyDzZoom");
187 
188  //parameters for _vs_ProductionVertexTransvPosition plots
189  minVertpos = pset.getParameter<double>("minVertpos");
190  maxVertpos = pset.getParameter<double>("maxVertpos");
191  nintVertpos = pset.getParameter<int>("nintVertpos");
192  useLogVertpos = pset.getUntrackedParameter<bool>("useLogVertpos");
193 
194  //parameters for _vs_ProductionVertexZPosition plots
195  minZpos = pset.getParameter<double>("minZpos");
196  maxZpos = pset.getParameter<double>("maxZpos");
197  nintZpos = pset.getParameter<int>("nintZpos");
198 
199  //parameters for _vs_dR plots
200  mindr = pset.getParameter<double>("mindr");
201  maxdr = pset.getParameter<double>("maxdr");
202  nintdr = pset.getParameter<int>("nintdr");
203 
204  //parameters for _vs_dR_jet plots
205  mindrj = pset.getParameter<double>("mindrj");
206  maxdrj = pset.getParameter<double>("maxdrj");
207  nintdrj = pset.getParameter<int>("nintdrj");
208 
209  // paramers for _vs_chi2 plots
210  minChi2 = pset.getParameter<double>("minChi2");
211  maxChi2 = pset.getParameter<double>("maxChi2");
212  nintChi2 = pset.getParameter<int>("nintChi2");
213 
214  //parameters for dE/dx plots
215  minDeDx = pset.getParameter<double>("minDeDx");
216  maxDeDx = pset.getParameter<double>("maxDeDx");
217  nintDeDx = pset.getParameter<int>("nintDeDx");
218 
219  //parameters for Pileup plots
220  minVertcount = pset.getParameter<double>("minVertcount");
221  maxVertcount = pset.getParameter<double>("maxVertcount");
222  nintVertcount = pset.getParameter<int>("nintVertcount");
223 
224  //parameters for number of tracks plots
225  minTracks = pset.getParameter<double>("minTracks");
226  maxTracks = pset.getParameter<double>("maxTracks");
227  nintTracks = pset.getParameter<int>("nintTracks");
228 
229  //parameters for vs. PV z plots
230  minPVz = pset.getParameter<double>("minPVz");
231  maxPVz = pset.getParameter<double>("maxPVz");
232  nintPVz = pset.getParameter<int>("nintPVz");
233 
234  //parameters for vs. MVA plots
235  minMVA = pset.getParameter<double>("minMVA");
236  maxMVA = pset.getParameter<double>("maxMVA");
237  nintMVA = pset.getParameter<int>("nintMVA");
238 
239  //parameters for resolution plots
240  ptRes_rangeMin = pset.getParameter<double>("ptRes_rangeMin");
241  ptRes_rangeMax = pset.getParameter<double>("ptRes_rangeMax");
242  ptRes_nbin = pset.getParameter<int>("ptRes_nbin");
243 
244  phiRes_rangeMin = pset.getParameter<double>("phiRes_rangeMin");
245  phiRes_rangeMax = pset.getParameter<double>("phiRes_rangeMax");
246  phiRes_nbin = pset.getParameter<int>("phiRes_nbin");
247 
248  cotThetaRes_rangeMin = pset.getParameter<double>("cotThetaRes_rangeMin");
249  cotThetaRes_rangeMax = pset.getParameter<double>("cotThetaRes_rangeMax");
250  cotThetaRes_nbin = pset.getParameter<int>("cotThetaRes_nbin");
251 
252  dxyRes_rangeMin = pset.getParameter<double>("dxyRes_rangeMin");
253  dxyRes_rangeMax = pset.getParameter<double>("dxyRes_rangeMax");
254  dxyRes_nbin = pset.getParameter<int>("dxyRes_nbin");
255 
256  dzRes_rangeMin = pset.getParameter<double>("dzRes_rangeMin");
257  dzRes_rangeMax = pset.getParameter<double>("dzRes_rangeMax");
258  dzRes_nbin = pset.getParameter<int>("dzRes_nbin");
259 
260  maxDzpvCum = pset.getParameter<double>("maxDzpvCumulative");
261  nintDzpvCum = pset.getParameter<int>("nintDzpvCumulative");
262 
263  maxDzpvsigCum = pset.getParameter<double>("maxDzpvsigCumulative");
264  nintDzpvsigCum = pset.getParameter<int>("nintDzpvsigCumulative");
265 
266  //--- tracking particle selectors for efficiency measurements
267  using namespace edm;
268  using namespace reco::modules;
269  auto initTPselector = [&](auto& sel, auto& name) {
270  sel = std::make_unique<TrackingParticleSelector>(
272  };
273  auto initTrackSelector = [&](auto& sel, auto& name) {
275  };
276  auto initGPselector = [&](auto& sel, auto& name) {
277  sel = std::make_unique<GenParticleCustomSelector>(
279  };
280 
281  initTPselector(generalTpSelector, "generalTpSelector");
282  initTPselector(TpSelectorForEfficiencyVsEta, "TpSelectorForEfficiencyVsEta");
283  initTPselector(TpSelectorForEfficiencyVsPhi, "TpSelectorForEfficiencyVsPhi");
284  initTPselector(TpSelectorForEfficiencyVsPt, "TpSelectorForEfficiencyVsPt");
285  initTPselector(TpSelectorForEfficiencyVsVTXR, "TpSelectorForEfficiencyVsVTXR");
286  initTPselector(TpSelectorForEfficiencyVsVTXZ, "TpSelectorForEfficiencyVsVTXZ");
287 
288  initTrackSelector(trackSelectorVsEta, "TpSelectorForEfficiencyVsEta");
289  initTrackSelector(trackSelectorVsPhi, "TpSelectorForEfficiencyVsPhi");
290  initTrackSelector(trackSelectorVsPt, "TpSelectorForEfficiencyVsPt");
291 
292  initGPselector(generalGpSelector, "generalGpSelector");
293  initGPselector(GpSelectorForEfficiencyVsEta, "GpSelectorForEfficiencyVsEta");
294  initGPselector(GpSelectorForEfficiencyVsPhi, "GpSelectorForEfficiencyVsPhi");
295  initGPselector(GpSelectorForEfficiencyVsPt, "GpSelectorForEfficiencyVsPt");
296  initGPselector(GpSelectorForEfficiencyVsVTXR, "GpSelectorForEfficiencyVsVTXR");
297  initGPselector(GpSelectorForEfficiencyVsVTXZ, "GpSelectorForEfficiencyVsVTXZ");
298 
299  // SeedingLayerSets
300  // If enabled, use last bin to denote other or unknown cases
301  seedingLayerSetNames = pset.getParameter<std::vector<std::string>>("seedingLayerSets");
302  std::vector<std::pair<SeedingLayerSetId, std::string>> stripPairSets;
303  if (!seedingLayerSetNames.empty()) {
304  std::vector<std::vector<std::string>> layerSets = SeedingLayerSetsBuilder::layerNamesInSets(seedingLayerSetNames);
305  for (size_t i = 0; i < layerSets.size(); ++i) {
306  const auto& layerSet = layerSets[i];
307  if (layerSet.size() > std::tuple_size<SeedingLayerSetId>::value) {
308  throw cms::Exception("Configuration")
309  << "Got seedingLayerSet " << seedingLayerSetNames[i] << " with " << layerSet.size()
310  << " elements, but I have a hard-coded maximum of " << std::tuple_size<SeedingLayerSetId>::value
311  << ". Please increase the maximum in MTVHistoProducerAlgoForTracker.h";
312  }
313  SeedingLayerSetId setId;
314  for (size_t j = 0; j < layerSet.size(); ++j) {
315  // SeedingLayerSetsBuilder::fillDescriptions() kind-of
316  // suggests that the 'M' prefix stands for strip mono hits
317  // (maybe it should force), so making the assumption here is
318  // (still) a bit ugly. But, this is the easiest way.
319  bool isStripMono = !layerSet[j].empty() && layerSet[j][0] == 'M';
320  setId[j] = std::make_tuple(SeedingLayerSetsBuilder::nameToEnumId(layerSet[j]), isStripMono);
321  }
322  // Account for the fact that strip triplet seeding may give pairs
323  if (layerSet.size() == 3 && isTrackerStrip(std::get<GeomDetEnumerators::SubDetector>(std::get<0>(setId[0])))) {
324  SeedingLayerSetId pairId;
325  pairId[0] = setId[0];
326  pairId[1] = setId[1];
327  stripPairSets.emplace_back(pairId, layerSet[0] + "+" + layerSet[1]);
328  }
329 
330  auto inserted = seedingLayerSetToBin.insert(std::make_pair(setId, i));
331  if (!inserted.second)
332  throw cms::Exception("Configuration") << "SeedingLayerSet " << seedingLayerSetNames[i]
333  << " is specified twice, while the set list should be unique.";
334  }
335 
336  // Add the "strip pairs from strip triplets" if they don't otherwise exist
337  for (const auto& setIdName : stripPairSets) {
338  auto inserted = seedingLayerSetToBin.insert(std::make_pair(setIdName.first, seedingLayerSetNames.size()));
339  if (inserted.second)
340  seedingLayerSetNames.push_back(setIdName.second);
341  }
342 
343  seedingLayerSetNames.emplace_back("Other/Unknown");
344  }
345 
346  // fix for the LogScale by Ryan
347  if (useLogPt) {
348  maxPt = log10(maxPt);
349  if (minPt > 0) {
350  minPt = log10(minPt);
351  } else {
352  edm::LogWarning("MultiTrackValidator")
353  << "minPt = " << minPt << " <= 0 out of range while requesting log scale. Using minPt = 0.1.";
354  minPt = log10(0.1);
355  }
356  }
357  if (useLogVertpos) {
358  maxVertpos = std::log10(maxVertpos);
359  if (minVertpos > 0) {
360  minVertpos = std::log10(minVertpos);
361  } else {
362  edm::LogWarning("MultiTrackValidator")
363  << "minVertpos = " << minVertpos << " <= 0 out of range while requesting log scale. Using minVertpos = 0.1.";
364  minVertpos = -1;
365  }
366  }
367 }
368 
370 
372  const edm::ParameterSet& pset) {
373  edm::ParameterSet psetTrack;
374  psetTrack.copyForModify(pset);
375  psetTrack.eraseSimpleParameter("minHit");
376  psetTrack.eraseSimpleParameter("signalOnly");
377  psetTrack.eraseSimpleParameter("intimeOnly");
378  psetTrack.eraseSimpleParameter("chargedOnly");
379  psetTrack.eraseSimpleParameter("stableOnly");
380  psetTrack.addParameter("maxChi2", 1e10);
381  psetTrack.addParameter("minHit", 0);
382  psetTrack.addParameter("minPixelHit", 0);
383  psetTrack.addParameter("minLayer", 0);
384  psetTrack.addParameter("min3DLayer", 0);
385  psetTrack.addParameter("quality", std::vector<std::string>{});
386  psetTrack.addParameter("algorithm", std::vector<std::string>{});
387  psetTrack.addParameter("originalAlgorithm", std::vector<std::string>{});
388  psetTrack.addParameter("algorithmMaskContains", std::vector<std::string>{});
389  psetTrack.addParameter("invertRapidityCut", false);
390  psetTrack.addParameter("minPhi", -3.2);
391  psetTrack.addParameter("maxPhi", 3.2);
392  return std::make_unique<RecoTrackSelectorBase>(psetTrack);
393 }
394 
396  histograms.h_ptSIM = make1DIfLogX(ibook, useLogPt, "ptSIM", "generated p_{t}", nintPt, minPt, maxPt);
397  histograms.h_etaSIM = ibook.book1D("etaSIM", "generated pseudorapidity", nintEta, minEta, maxEta);
398  histograms.h_phiSIM = ibook.book1D("phiSIM", "generated phi", nintPhi, minPhi, maxPhi);
399  histograms.h_tracksSIM =
400  ibook.book1D("tracksSIM", "number of simulated tracks", nintTracks, minTracks, maxTracks * 10);
401  histograms.h_vertposSIM =
402  ibook.book1D("vertposSIM", "Transverse position of sim vertices", nintVertpos, minVertpos, maxVertpos);
403  histograms.h_bunchxSIM = ibook.book1D("bunchxSIM", "bunch crossing", 21, -15.5, 5.5);
404 }
405 
408  bool doResolutionPlots) {
409  histograms.h_assoceta.push_back(
410  ibook.book1D("num_assoc(simToReco)_eta", "N of associated tracks (simToReco) vs eta", nintEta, minEta, maxEta));
411  histograms.h_simuleta.push_back(
412  ibook.book1D("num_simul_eta", "N of simulated tracks vs eta", nintEta, minEta, maxEta));
413 
414  histograms.h_assocpT.push_back(make1DIfLogX(
415  ibook, useLogPt, "num_assoc(simToReco)_pT", "N of associated tracks (simToReco) vs pT", nintPt, minPt, maxPt));
416  histograms.h_simulpT.push_back(
417  make1DIfLogX(ibook, useLogPt, "num_simul_pT", "N of simulated tracks vs pT", nintPt, minPt, maxPt));
418 
419  histograms.h_assocpTvseta.push_back(make2DIfLogY(ibook,
420  useLogPt,
421  "num_assoc(simToReco)_pTvseta",
422  "N of associated tracks (simToReco) in (pT-eta) please",
423  nintEta,
424  minEta,
425  maxEta,
426  nintPt,
427  minPt,
428  maxPt));
429  histograms.h_simulpTvseta.push_back(make2DIfLogY(ibook,
430  useLogPt,
431  "num_simul_pTvseta",
432  "N of simulated tracks in (pT-eta) plane",
433  nintEta,
434  minEta,
435  maxEta,
436  nintPt,
437  minPt,
438  maxPt));
439 
440  histograms.h_assochit.push_back(
441  ibook.book1D("num_assoc(simToReco)_hit", "N of associated tracks (simToReco) vs hit", nintHit, minHit, maxHit));
442  histograms.h_simulhit.push_back(
443  ibook.book1D("num_simul_hit", "N of simulated tracks vs hit", nintHit, minHit, maxHit));
444 
445  histograms.h_assoclayer.push_back(ibook.book1D(
446  "num_assoc(simToReco)_layer", "N of associated tracks (simToReco) vs layer", nintLayers, minLayers, maxLayers));
447  histograms.h_simullayer.push_back(
448  ibook.book1D("num_simul_layer", "N of simulated tracks vs layer", nintLayers, minLayers, maxLayers));
449 
450  histograms.h_assocpixellayer.push_back(ibook.book1D("num_assoc(simToReco)_pixellayer",
451  "N of associated tracks (simToReco) vs pixel layer",
452  nintLayers,
453  minLayers,
454  maxLayers));
455  histograms.h_simulpixellayer.push_back(
456  ibook.book1D("num_simul_pixellayer", "N of simulated tracks vs pixel layer", nintLayers, minLayers, maxLayers));
457 
458  histograms.h_assoc3Dlayer.push_back(ibook.book1D("num_assoc(simToReco)_3Dlayer",
459  "N of associated tracks (simToReco) vs 3D layer",
460  nintLayers,
461  minLayers,
462  maxLayers));
463  histograms.h_simul3Dlayer.push_back(
464  ibook.book1D("num_simul_3Dlayer", "N of simulated tracks vs 3D layer", nintLayers, minLayers, maxLayers));
465 
466  histograms.h_assocpu.push_back(
467  ibook.book1D("num_assoc(simToReco)_pu", "N of associated tracks (simToReco) vs pu", nintPu, minPu, maxPu));
468  histograms.h_simulpu.push_back(ibook.book1D("num_simul_pu", "N of simulated tracks vs pu", nintPu, minPu, maxPu));
469 
470  histograms.h_assocphi.push_back(
471  ibook.book1D("num_assoc(simToReco)_phi", "N of associated tracks (simToReco) vs phi", nintPhi, minPhi, maxPhi));
472  histograms.h_simulphi.push_back(
473  ibook.book1D("num_simul_phi", "N of simulated tracks vs phi", nintPhi, minPhi, maxPhi));
474 
475  histograms.h_assocdxy.push_back(
476  ibook.book1D("num_assoc(simToReco)_dxy", "N of associated tracks (simToReco) vs dxy", nintDxy, minDxy, maxDxy));
477  histograms.h_simuldxy.push_back(
478  ibook.book1D("num_simul_dxy", "N of simulated tracks vs dxy", nintDxy, minDxy, maxDxy));
479 
480  histograms.h_assocdz.push_back(
481  ibook.book1D("num_assoc(simToReco)_dz", "N of associated tracks (simToReco) vs dz", nintDz, minDz, maxDz));
482  histograms.h_simuldz.push_back(ibook.book1D("num_simul_dz", "N of simulated tracks vs dz", nintDz, minDz, maxDz));
483 
484  histograms.h_assocvertpos.push_back(make1DIfLogX(ibook,
486  "num_assoc(simToReco)_vertpos",
487  "N of associated tracks (simToReco) vs transverse vert position",
488  nintVertpos,
489  minVertpos,
490  maxVertpos));
491  histograms.h_simulvertpos.push_back(make1DIfLogX(ibook,
493  "num_simul_vertpos",
494  "N of simulated tracks vs transverse vert position",
495  nintVertpos,
496  minVertpos,
497  maxVertpos));
498 
499  histograms.h_assoczpos.push_back(ibook.book1D(
500  "num_assoc(simToReco)_zpos", "N of associated tracks (simToReco) vs z vert position", nintZpos, minZpos, maxZpos));
501  histograms.h_simulzpos.push_back(
502  ibook.book1D("num_simul_zpos", "N of simulated tracks vs z vert position", nintZpos, minZpos, maxZpos));
503 
504  histograms.h_assocdr.push_back(make1DIfLogX(ibook,
505  true,
506  "num_assoc(simToReco)_dr",
507  "N of associated tracks (simToReco) vs dR",
508  nintdr,
509  log10(mindr),
510  log10(maxdr)));
511  histograms.h_simuldr.push_back(
512  make1DIfLogX(ibook, true, "num_simul_dr", "N of simulated tracks vs dR", nintdr, log10(mindr), log10(maxdr)));
513 
514  histograms.h_assocdrj.push_back(make1DIfLogX(ibook,
515  true,
516  "num_assoc(simToReco)_drj",
517  "N of associated tracks (simToReco) vs dR(TP,jet)",
518  nintdrj,
519  log10(mindrj),
520  log10(maxdrj)));
521  histograms.h_simuldrj.push_back(make1DIfLogX(
522  ibook, true, "num_simul_drj", "N of simulated tracks vs dR(TP,jet)", nintdrj, log10(mindrj), log10(maxdrj)));
523 
524  histograms.h_simul_simpvz.push_back(
525  ibook.book1D("num_simul_simpvz", "N of simulated tracks vs. sim PV z", nintPVz, minPVz, maxPVz));
526  histograms.h_assoc_simpvz.push_back(ibook.book1D(
527  "num_assoc(simToReco)_simpvz", "N of associated tracks (simToReco) vs. sim PV z", nintPVz, minPVz, maxPVz));
528 
529  histograms.nrecHit_vs_nsimHit_sim2rec.push_back(doResolutionPlots ? ibook.book2D("nrecHit_vs_nsimHit_sim2rec",
530  "nrecHit vs nsimHit (Sim2RecAssoc)",
531  nintHit,
532  minHit,
533  maxHit,
534  nintHit,
535  minHit,
536  maxHit)
537  : nullptr);
538 
539  // TODO: use the dynamic track algo priority order also here
540  constexpr auto nalgos = reco::TrackBase::algoSize;
541  histograms.h_duplicates_oriAlgo_vs_oriAlgo.push_back(ibook.book2D("duplicates_oriAlgo_vs_oriAlgo",
542  "Duplicate tracks: originalAlgo vs originalAlgo",
543  nalgos,
544  0,
545  nalgos,
546  nalgos,
547  0,
548  nalgos));
549  setBinLabelsAlgo(histograms.h_duplicates_oriAlgo_vs_oriAlgo.back(), 1);
550  setBinLabelsAlgo(histograms.h_duplicates_oriAlgo_vs_oriAlgo.back(), 2);
551 }
552 
554  histograms.h_assocdxypv.push_back(ibook.book1D(
555  "num_assoc(simToReco)_dxypv", "N of associated tracks (simToReco) vs dxy(PV)", nintDxy, minDxy, maxDxy));
556  histograms.h_simuldxypv.push_back(
557  ibook.book1D("num_simul_dxypv", "N of simulated tracks vs dxy(PV)", nintDxy, minDxy, maxDxy));
558 
559  histograms.h_assocdzpv.push_back(
560  ibook.book1D("num_assoc(simToReco)_dzpv", "N of associated tracks (simToReco) vs dz(PV)", nintDz, minDz, maxDz));
561  histograms.h_simuldzpv.push_back(
562  ibook.book1D("num_simul_dzpv", "N of simulated tracks vs dz(PV)", nintDz, minDz, maxDz));
563 
564  histograms.h_assocdxypvzoomed.push_back(ibook.book1D("num_assoc(simToReco)_dxypv_zoomed",
565  "N of associated tracks (simToReco) vs dxy(PV)",
566  nintDxy,
567  minDxy / dxyDzZoom,
568  maxDxy / dxyDzZoom));
569  histograms.h_simuldxypvzoomed.push_back(ibook.book1D(
570  "num_simul_dxypv_zoomed", "N of simulated tracks vs dxy(PV)", nintDxy, minDxy / dxyDzZoom, maxDxy / dxyDzZoom));
571 
572  histograms.h_assocdzpvzoomed.push_back(ibook.book1D("num_assoc(simToReco)_dzpv_zoomed",
573  "N of associated tracks (simToReco) vs dz(PV)",
574  nintDz,
575  minDz / dxyDzZoom,
576  maxDz / dxyDzZoom));
577  histograms.h_simuldzpvzoomed.push_back(ibook.book1D(
578  "num_simul_dzpv_zoomed", "N of simulated tracks vs dz(PV)", nintDz, minDz / dxyDzZoom, maxDz / dxyDzZoom));
579 
580  histograms.h_assoc_dzpvcut.push_back(ibook.book1D(
581  "num_assoc(simToReco)_dzpvcut", "N of associated tracks (simToReco) vs dz(PV)", nintDzpvCum, 0, maxDzpvCum));
582  histograms.h_simul_dzpvcut.push_back(
583  ibook.book1D("num_simul_dzpvcut", "N of simulated tracks from sim PV", nintDzpvCum, 0, maxDzpvCum));
584  histograms.h_simul2_dzpvcut.push_back(ibook.book1D(
585  "num_simul2_dzpvcut", "N of simulated tracks (associated to any track) from sim PV", nintDzpvCum, 0, maxDzpvCum));
586 
587  histograms.h_assoc_dzpvcut_pt.push_back(ibook.book1D("num_assoc(simToReco)_dzpvcut_pt",
588  "#sump_{T} of associated tracks (simToReco) vs dz(PV)",
589  nintDzpvCum,
590  0,
591  maxDzpvCum));
592  histograms.h_simul_dzpvcut_pt.push_back(
593  ibook.book1D("num_simul_dzpvcut_pt", "#sump_{T} of simulated tracks from sim PV", nintDzpvCum, 0, maxDzpvCum));
594  histograms.h_simul2_dzpvcut_pt.push_back(
595  ibook.book1D("num_simul2_dzpvcut_pt",
596  "#sump_{T} of simulated tracks (associated to any track) from sim PV",
597  nintDzpvCum,
598  0,
599  maxDzpvCum));
600  histograms.h_assoc_dzpvcut_pt.back()->enableSumw2();
601  histograms.h_simul_dzpvcut_pt.back()->enableSumw2();
602  histograms.h_simul2_dzpvcut_pt.back()->enableSumw2();
603 
604  histograms.h_assoc_dzpvsigcut.push_back(ibook.book1D("num_assoc(simToReco)_dzpvsigcut",
605  "N of associated tracks (simToReco) vs dz(PV)/dzError",
607  0,
608  maxDzpvsigCum));
609  histograms.h_simul_dzpvsigcut.push_back(ibook.book1D(
610  "num_simul_dzpvsigcut", "N of simulated tracks from sim PV/dzError", nintDzpvsigCum, 0, maxDzpvsigCum));
611  histograms.h_simul2_dzpvsigcut.push_back(
612  ibook.book1D("num_simul2_dzpvsigcut",
613  "N of simulated tracks (associated to any track) from sim PV/dzError",
615  0,
616  maxDzpvsigCum));
617 
618  histograms.h_assoc_dzpvsigcut_pt.push_back(
619  ibook.book1D("num_assoc(simToReco)_dzpvsigcut_pt",
620  "#sump_{T} of associated tracks (simToReco) vs dz(PV)/dzError",
622  0,
623  maxDzpvsigCum));
624  histograms.h_simul_dzpvsigcut_pt.push_back(ibook.book1D(
625  "num_simul_dzpvsigcut_pt", "#sump_{T} of simulated tracks from sim PV/dzError", nintDzpvsigCum, 0, maxDzpvsigCum));
626  histograms.h_simul2_dzpvsigcut_pt.push_back(
627  ibook.book1D("num_simul2_dzpvsigcut_pt",
628  "#sump_{T} of simulated tracks (associated to any track) from sim PV/dzError",
630  0,
631  maxDzpvsigCum));
632  histograms.h_assoc_dzpvsigcut_pt.back()->enableSumw2();
633  histograms.h_simul_dzpvsigcut_pt.back()->enableSumw2();
634  histograms.h_simul2_dzpvsigcut_pt.back()->enableSumw2();
635 }
636 
639  bool doResolutionPlots) {
640  histograms.h_tracks.push_back(
641  ibook.book1D("tracks", "number of reconstructed tracks", nintTracks, minTracks, maxTracks));
642  histograms.h_fakes.push_back(ibook.book1D("fakes", "number of fake reco tracks", nintTracks, minTracks, maxTracks));
643  histograms.h_charge.push_back(ibook.book1D("charge", "charge", 3, -1.5, 1.5));
644 
645  histograms.h_hits.push_back(ibook.book1D("hits", "number of hits per track", nintHit, minHit, maxHit));
646  histograms.h_losthits.push_back(ibook.book1D("losthits", "number of lost hits per track", nintHit, minHit, maxHit));
647  histograms.h_nchi2.push_back(ibook.book1D("chi2", "normalized #chi^{2}", 200, 0, 20));
648  histograms.h_nchi2_prob.push_back(ibook.book1D("chi2_prob", "normalized #chi^{2} probability", 100, 0, 1));
649 
650  histograms.h_nmisslayers_inner.push_back(
651  ibook.book1D("missing_inner_layers", "number of missing inner layers", nintLayers, minLayers, maxLayers));
652  histograms.h_nmisslayers_outer.push_back(
653  ibook.book1D("missing_outer_layers", "number of missing outer layers", nintLayers, minLayers, maxLayers));
654 
655  histograms.h_algo.push_back(
656  ibook.book1D("h_algo", "Tracks by algo", reco::TrackBase::algoSize, 0., double(reco::TrackBase::algoSize)));
657  for (size_t ibin = 0; ibin < reco::TrackBase::algoSize - 1; ibin++)
658  histograms.h_algo.back()->setBinLabel(ibin + 1, reco::TrackBase::algoNames[ibin]);
659  histograms.h_algo.back()->disableAlphanumeric();
660 
662  histograms.h_recoeta.push_back(ibook.book1D("num_reco_eta", "N of reco track vs eta", nintEta, minEta, maxEta));
663  histograms.h_reco2eta.push_back(
664  ibook.book1D("num_reco2_eta", "N of selected reco track vs eta", nintEta, minEta, maxEta));
665  histograms.h_assoc2eta.push_back(
666  ibook.book1D("num_assoc(recoToSim)_eta", "N of associated (recoToSim) tracks vs eta", nintEta, minEta, maxEta));
667  histograms.h_loopereta.push_back(ibook.book1D(
668  "num_duplicate_eta", "N of associated (recoToSim) duplicate tracks vs eta", nintEta, minEta, maxEta));
669  if (!doSeedPlots_)
670  histograms.h_misideta.push_back(ibook.book1D(
671  "num_chargemisid_eta", "N of associated (recoToSim) charge misIDed tracks vs eta", nintEta, minEta, maxEta));
672  histograms.h_pileupeta.push_back(
673  ibook.book1D("num_pileup_eta", "N of associated (recoToSim) pileup tracks vs eta", nintEta, minEta, maxEta));
674  //
675  histograms.h_recopT.push_back(
676  make1DIfLogX(ibook, useLogPt, "num_reco_pT", "N of reco track vs pT", nintPt, minPt, maxPt));
677  histograms.h_reco2pT.push_back(
678  make1DIfLogX(ibook, useLogPt, "num_reco2_pT", "N of selected reco track vs pT", nintPt, minPt, maxPt));
679  histograms.h_assoc2pT.push_back(make1DIfLogX(
680  ibook, useLogPt, "num_assoc(recoToSim)_pT", "N of associated (recoToSim) tracks vs pT", nintPt, minPt, maxPt));
681  histograms.h_looperpT.push_back(make1DIfLogX(
682  ibook, useLogPt, "num_duplicate_pT", "N of associated (recoToSim) duplicate tracks vs pT", nintPt, minPt, maxPt));
683  if (!doSeedPlots_)
684  histograms.h_misidpT.push_back(make1DIfLogX(ibook,
685  useLogPt,
686  "num_chargemisid_pT",
687  "N of associated (recoToSim) charge misIDed tracks vs pT",
688  nintPt,
689  minPt,
690  maxPt));
691  histograms.h_pileuppT.push_back(make1DIfLogX(
692  ibook, useLogPt, "num_pileup_pT", "N of associated (recoToSim) pileup tracks vs pT", nintPt, minPt, maxPt));
693  //
694  histograms.h_recopTvseta.push_back(make2DIfLogY(ibook,
695  useLogPt,
696  "num_reco_pTvseta",
697  "N of reco track in (pT-eta) plane",
698  nintEta,
699  minEta,
700  maxEta,
701  nintPt,
702  minPt,
703  maxPt));
704  histograms.h_reco2pTvseta.push_back(make2DIfLogY(ibook,
705  useLogPt,
706  "num_reco2_pTvseta",
707  "N of selected reco track in (pT-eta) plane",
708  nintEta,
709  minEta,
710  maxEta,
711  nintPt,
712  minPt,
713  maxPt));
714  histograms.h_assoc2pTvseta.push_back(make2DIfLogY(ibook,
715  useLogPt,
716  "num_assoc(recoToSim)_pTvseta",
717  "N of associated (recoToSim) tracks in (pT-eta) plane",
718  nintEta,
719  minEta,
720  maxEta,
721  nintPt,
722  minPt,
723  maxPt));
724  histograms.h_looperpTvseta.push_back(make2DIfLogY(ibook,
725  useLogPt,
726  "num_duplicate_pTvseta",
727  "N of associated (recoToSim) duplicate tracks in (pT-eta) plane",
728  nintEta,
729  minEta,
730  maxEta,
731  nintPt,
732  minPt,
733  maxPt));
734  if (!doSeedPlots_)
735  histograms.h_misidpTvseta.push_back(
736  make2DIfLogY(ibook,
737  useLogPt,
738  "num_chargemisid_pTvseta",
739  "N of associated (recoToSim) charge misIDed tracks in (pT-eta) plane",
740  nintEta,
741  minEta,
742  maxEta,
743  nintPt,
744  minPt,
745  maxPt));
746  histograms.h_pileuppTvseta.push_back(make2DIfLogY(ibook,
747  useLogPt,
748  "num_pileup_pTvseta",
749  "N of associated (recoToSim) pileup tracks in (pT-eta) plane",
750  nintEta,
751  minEta,
752  maxEta,
753  nintPt,
754  minPt,
755  maxPt));
756  //
757  histograms.h_recohit.push_back(ibook.book1D("num_reco_hit", "N of reco track vs hit", nintHit, minHit, maxHit));
758  histograms.h_assoc2hit.push_back(
759  ibook.book1D("num_assoc(recoToSim)_hit", "N of associated (recoToSim) tracks vs hit", nintHit, minHit, maxHit));
760  histograms.h_looperhit.push_back(ibook.book1D(
761  "num_duplicate_hit", "N of associated (recoToSim) duplicate tracks vs hit", nintHit, minHit, maxHit));
762  if (!doSeedPlots_)
763  histograms.h_misidhit.push_back(ibook.book1D(
764  "num_chargemisid_hit", "N of associated (recoToSim) charge misIDed tracks vs hit", nintHit, minHit, maxHit));
765  histograms.h_pileuphit.push_back(
766  ibook.book1D("num_pileup_hit", "N of associated (recoToSim) pileup tracks vs hit", nintHit, minHit, maxHit));
767  //
768  histograms.h_recolayer.push_back(
769  ibook.book1D("num_reco_layer", "N of reco track vs layer", nintLayers, minLayers, maxLayers));
770  histograms.h_assoc2layer.push_back(ibook.book1D(
771  "num_assoc(recoToSim)_layer", "N of associated (recoToSim) tracks vs layer", nintLayers, minLayers, maxLayers));
772  histograms.h_looperlayer.push_back(ibook.book1D(
773  "num_duplicate_layer", "N of associated (recoToSim) duplicate tracks vs layer", nintLayers, minLayers, maxLayers));
774  if (!doSeedPlots_)
775  histograms.h_misidlayer.push_back(ibook.book1D("num_chargemisid_layer",
776  "N of associated (recoToSim) charge misIDed tracks vs layer",
777  nintLayers,
778  minLayers,
779  maxLayers));
780  histograms.h_pileuplayer.push_back(ibook.book1D(
781  "num_pileup_layer", "N of associated (recoToSim) pileup tracks vs layer", nintLayers, minLayers, maxLayers));
782  //
783  histograms.h_recopixellayer.push_back(
784  ibook.book1D("num_reco_pixellayer", "N of reco track vs pixellayer", nintLayers, minLayers, maxLayers));
785  histograms.h_assoc2pixellayer.push_back(ibook.book1D("num_assoc(recoToSim)_pixellayer",
786  "N of associated (recoToSim) tracks vs pixellayer",
787  nintLayers,
788  minLayers,
789  maxLayers));
790  histograms.h_looperpixellayer.push_back(ibook.book1D("num_duplicate_pixellayer",
791  "N of associated (recoToSim) duplicate tracks vs pixellayer",
792  nintLayers,
793  minLayers,
794  maxLayers));
795  if (!doSeedPlots_)
796  histograms.h_misidpixellayer.push_back(
797  ibook.book1D("num_chargemisid_pixellayer",
798  "N of associated (recoToSim) charge misIDed tracks vs pixellayer",
799  nintLayers,
800  minLayers,
801  maxLayers));
802  histograms.h_pileuppixellayer.push_back(ibook.book1D("num_pileup_pixellayer",
803  "N of associated (recoToSim) pileup tracks vs pixellayer",
804  nintLayers,
805  minLayers,
806  maxLayers));
807  //
808  histograms.h_reco3Dlayer.push_back(
809  ibook.book1D("num_reco_3Dlayer", "N of reco track vs 3D layer", nintLayers, minLayers, maxLayers));
810  histograms.h_assoc23Dlayer.push_back(ibook.book1D("num_assoc(recoToSim)_3Dlayer",
811  "N of associated (recoToSim) tracks vs 3D layer",
812  nintLayers,
813  minLayers,
814  maxLayers));
815  histograms.h_looper3Dlayer.push_back(ibook.book1D("num_duplicate_3Dlayer",
816  "N of associated (recoToSim) duplicate tracks vs 3D layer",
817  nintLayers,
818  minLayers,
819  maxLayers));
820  if (!doSeedPlots_)
821  histograms.h_misid3Dlayer.push_back(ibook.book1D("num_chargemisid_3Dlayer",
822  "N of associated (recoToSim) charge misIDed tracks vs 3D layer",
823  nintLayers,
824  minLayers,
825  maxLayers));
826  histograms.h_pileup3Dlayer.push_back(ibook.book1D(
827  "num_pileup_3Dlayer", "N of associated (recoToSim) pileup tracks vs 3D layer", nintLayers, minLayers, maxLayers));
828  //
829  histograms.h_recopu.push_back(ibook.book1D("num_reco_pu", "N of reco track vs pu", nintPu, minPu, maxPu));
830  histograms.h_reco2pu.push_back(ibook.book1D("num_reco2_pu", "N of selected reco track vs pu", nintPu, minPu, maxPu));
831  histograms.h_assoc2pu.push_back(
832  ibook.book1D("num_assoc(recoToSim)_pu", "N of associated (recoToSim) tracks vs pu", nintPu, minPu, maxPu));
833  histograms.h_looperpu.push_back(
834  ibook.book1D("num_duplicate_pu", "N of associated (recoToSim) duplicate tracks vs pu", nintPu, minPu, maxPu));
835  if (!doSeedPlots_)
836  histograms.h_misidpu.push_back(ibook.book1D(
837  "num_chargemisid_pu", "N of associated (recoToSim) charge misIDed tracks vs pu", nintPu, minPu, maxPu));
838  histograms.h_pileuppu.push_back(
839  ibook.book1D("num_pileup_pu", "N of associated (recoToSim) pileup tracks vs pu", nintPu, minPu, maxPu));
840  //
841  histograms.h_recophi.push_back(ibook.book1D("num_reco_phi", "N of reco track vs phi", nintPhi, minPhi, maxPhi));
842  histograms.h_assoc2phi.push_back(
843  ibook.book1D("num_assoc(recoToSim)_phi", "N of associated (recoToSim) tracks vs phi", nintPhi, minPhi, maxPhi));
844  histograms.h_looperphi.push_back(ibook.book1D(
845  "num_duplicate_phi", "N of associated (recoToSim) duplicate tracks vs phi", nintPhi, minPhi, maxPhi));
846  if (!doSeedPlots_)
847  histograms.h_misidphi.push_back(ibook.book1D(
848  "num_chargemisid_phi", "N of associated (recoToSim) charge misIDed tracks vs phi", nintPhi, minPhi, maxPhi));
849  histograms.h_pileupphi.push_back(
850  ibook.book1D("num_pileup_phi", "N of associated (recoToSim) pileup tracks vs phi", nintPhi, minPhi, maxPhi));
851 
852  histograms.h_recodxy.push_back(ibook.book1D("num_reco_dxy", "N of reco track vs dxy", nintDxy, minDxy, maxDxy));
853  histograms.h_assoc2dxy.push_back(
854  ibook.book1D("num_assoc(recoToSim)_dxy", "N of associated (recoToSim) tracks vs dxy", nintDxy, minDxy, maxDxy));
855  histograms.h_looperdxy.push_back(
856  ibook.book1D("num_duplicate_dxy", "N of associated (recoToSim) looper tracks vs dxy", nintDxy, minDxy, maxDxy));
857  if (!doSeedPlots_)
858  histograms.h_misiddxy.push_back(ibook.book1D(
859  "num_chargemisid_dxy", "N of associated (recoToSim) charge misIDed tracks vs dxy", nintDxy, minDxy, maxDxy));
860  histograms.h_pileupdxy.push_back(
861  ibook.book1D("num_pileup_dxy", "N of associated (recoToSim) pileup tracks vs dxy", nintDxy, minDxy, maxDxy));
862 
863  histograms.h_recodz.push_back(ibook.book1D("num_reco_dz", "N of reco track vs dz", nintDz, minDz, maxDz));
864  histograms.h_assoc2dz.push_back(
865  ibook.book1D("num_assoc(recoToSim)_dz", "N of associated (recoToSim) tracks vs dz", nintDz, minDz, maxDz));
866  histograms.h_looperdz.push_back(
867  ibook.book1D("num_duplicate_dz", "N of associated (recoToSim) looper tracks vs dz", nintDz, minDz, maxDz));
868  if (!doSeedPlots_)
869  histograms.h_misiddz.push_back(ibook.book1D(
870  "num_chargemisid_versus_dz", "N of associated (recoToSim) charge misIDed tracks vs dz", nintDz, minDz, maxDz));
871  histograms.h_pileupdz.push_back(
872  ibook.book1D("num_pileup_dz", "N of associated (recoToSim) pileup tracks vs dz", nintDz, minDz, maxDz));
873 
874  histograms.h_recovertpos.push_back(make1DIfLogX(ibook,
876  "num_reco_vertpos",
877  "N of reconstructed tracks vs transverse ref point position",
878  nintVertpos,
879  minVertpos,
880  maxVertpos));
881  histograms.h_assoc2vertpos.push_back(
882  make1DIfLogX(ibook,
884  "num_assoc(recoToSim)_vertpos",
885  "N of associated (recoToSim) tracks vs transverse ref point position",
886  nintVertpos,
887  minVertpos,
888  maxVertpos));
889  histograms.h_loopervertpos.push_back(
890  make1DIfLogX(ibook,
892  "num_duplicate_vertpos",
893  "N of associated (recoToSim) looper tracks vs transverse ref point position",
894  nintVertpos,
895  minVertpos,
896  maxVertpos));
897  histograms.h_pileupvertpos.push_back(
898  make1DIfLogX(ibook,
900  "num_pileup_vertpos",
901  "N of associated (recoToSim) pileup tracks vs transverse ref point position",
902  nintVertpos,
903  minVertpos,
904  maxVertpos));
905 
906  histograms.h_recozpos.push_back(ibook.book1D(
907  "num_reco_zpos", "N of reconstructed tracks vs transverse ref point position", nintZpos, minZpos, maxZpos));
908  histograms.h_assoc2zpos.push_back(ibook.book1D("num_assoc(recoToSim)_zpos",
909  "N of associated (recoToSim) tracks vs transverse ref point position",
910  nintZpos,
911  minZpos,
912  maxZpos));
913  histograms.h_looperzpos.push_back(
914  ibook.book1D("num_duplicate_zpos",
915  "N of associated (recoToSim) looper tracks vs transverse ref point position",
916  nintZpos,
917  minZpos,
918  maxZpos));
919  histograms.h_pileupzpos.push_back(
920  ibook.book1D("num_pileup_zpos",
921  "N of associated (recoToSim) pileup tracks vs transverse ref point position",
922  nintZpos,
923  minZpos,
924  maxZpos));
925 
926  histograms.h_recodr.push_back(
927  make1DIfLogX(ibook, true, "num_reco_dr", "N of reconstructed tracks vs dR", nintdr, log10(mindr), log10(maxdr)));
928  histograms.h_assoc2dr.push_back(make1DIfLogX(ibook,
929  true,
930  "num_assoc(recoToSim)_dr",
931  "N of associated tracks (recoToSim) vs dR",
932  nintdr,
933  log10(mindr),
934  log10(maxdr)));
935  histograms.h_looperdr.push_back(make1DIfLogX(ibook,
936  true,
937  "num_duplicate_dr",
938  "N of associated (recoToSim) looper tracks vs dR",
939  nintdr,
940  log10(mindr),
941  log10(maxdr)));
942  histograms.h_pileupdr.push_back(make1DIfLogX(ibook,
943  true,
944  "num_pileup_dr",
945  "N of associated (recoToSim) pileup tracks vs dR",
946  nintdr,
947  log10(mindr),
948  log10(maxdr)));
949 
950  histograms.h_recodrj.push_back(make1DIfLogX(
951  ibook, true, "num_reco_drj", "N of reconstructed tracks vs dR(track,jet)", nintdrj, log10(mindrj), log10(maxdrj)));
952  histograms.h_assoc2drj.push_back(make1DIfLogX(ibook,
953  true,
954  "num_assoc(recoToSim)_drj",
955  "N of associated tracks (recoToSim) vs dR(track,jet)",
956  nintdrj,
957  log10(mindrj),
958  log10(maxdrj)));
959  histograms.h_looperdrj.push_back(make1DIfLogX(ibook,
960  true,
961  "num_duplicate_drj",
962  "N of associated (recoToSim) looper tracks vs dR(track,jet)",
963  nintdrj,
964  log10(mindrj),
965  log10(maxdrj)));
966  histograms.h_pileupdrj.push_back(make1DIfLogX(ibook,
967  true,
968  "num_pileup_drj",
969  "N of associated (recoToSim) pileup tracks vs dR(track,jet)",
970  nintdrj,
971  log10(mindrj),
972  log10(maxdrj)));
973 
974  histograms.h_reco_simpvz.push_back(
975  ibook.book1D("num_reco_simpvz", "N of reco track vs. sim PV z", nintPVz, minPVz, maxPVz));
976  histograms.h_assoc2_simpvz.push_back(ibook.book1D(
977  "num_assoc(recoToSim)_simpvz", "N of associated tracks (recoToSim) vs. sim PV z", nintPVz, minPVz, maxPVz));
978  histograms.h_looper_simpvz.push_back(ibook.book1D(
979  "num_duplicate_simpvz", "N of associated (recoToSim) looper tracks vs. sim PV z", nintPVz, minPVz, maxPVz));
980  histograms.h_pileup_simpvz.push_back(ibook.book1D(
981  "num_pileup_simpvz", "N of associated (recoToSim) pileup tracks vs. sim PV z", nintPVz, minPVz, maxPVz));
982 
983  histograms.h_recochi2.push_back(
984  ibook.book1D("num_reco_chi2", "N of reco track vs normalized #chi^{2}", nintChi2, minChi2, maxChi2));
985  histograms.h_assoc2chi2.push_back(ibook.book1D("num_assoc(recoToSim)_chi2",
986  "N of associated (recoToSim) tracks vs normalized #chi^{2}",
987  nintChi2,
988  minChi2,
989  maxChi2));
990  histograms.h_looperchi2.push_back(ibook.book1D("num_duplicate_chi2",
991  "N of associated (recoToSim) looper tracks vs normalized #chi^{2}",
992  nintChi2,
993  minChi2,
994  maxChi2));
995  if (!doSeedPlots_)
996  histograms.h_misidchi2.push_back(
997  ibook.book1D("num_chargemisid_chi2",
998  "N of associated (recoToSim) charge misIDed tracks vs normalized #chi^{2}",
999  nintChi2,
1000  minChi2,
1001  maxChi2));
1002  histograms.h_pileupchi2.push_back(ibook.book1D("num_pileup_chi2",
1003  "N of associated (recoToSim) pileup tracks vs normalized #chi^{2}",
1004  nintChi2,
1005  minChi2,
1006  maxChi2));
1007 
1008  histograms.h_recochi2prob.push_back(
1009  ibook.book1D("num_reco_chi2prob", "N of reco track vs normalized #chi^{2}", 100, 0., 1.));
1010  histograms.h_assoc2chi2prob.push_back(ibook.book1D(
1011  "num_assoc(recoToSim)_chi2prob", "N of associated (recoToSim) tracks vs normalized #chi^{2}", 100, 0., 1.));
1012  histograms.h_looperchi2prob.push_back(ibook.book1D(
1013  "num_duplicate_chi2prob", "N of associated (recoToSim) looper tracks vs normalized #chi^{2}", 100, 0., 1.));
1014  if (!doSeedPlots_)
1015  histograms.h_misidchi2prob.push_back(
1016  ibook.book1D("num_chargemisid_chi2prob",
1017  "N of associated (recoToSim) charge misIDed tracks vs normalized #chi^{2}",
1018  100,
1019  0.,
1020  1.));
1021  histograms.h_pileupchi2prob.push_back(ibook.book1D(
1022  "num_pileup_chi2prob", "N of associated (recoToSim) pileup tracks vs normalized #chi^{2}", 100, 0., 1.));
1023 
1024  if (!seedingLayerSetNames.empty()) {
1025  const auto size = seedingLayerSetNames.size();
1026  histograms.h_reco_seedingLayerSet.push_back(
1027  ibook.book1D("num_reco_seedingLayerSet", "N of reco track vs. seedingLayerSet", size, 0, size));
1028  histograms.h_assoc2_seedingLayerSet.push_back(
1029  ibook.book1D("num_assoc(recoToSim)_seedingLayerSet",
1030  "N of associated track (recoToSim) tracks vs. seedingLayerSet",
1031  size,
1032  0,
1033  size));
1034  histograms.h_looper_seedingLayerSet.push_back(ibook.book1D(
1035  "num_duplicate_seedingLayerSet", "N of reco associated (recoToSim) looper vs. seedingLayerSet", size, 0, size));
1036  histograms.h_pileup_seedingLayerSet.push_back(ibook.book1D(
1037  "num_pileup_seedingLayerSet", "N of reco associated (recoToSim) pileup vs. seedingLayerSet", size, 0, size));
1038 
1039  setBinLabels(histograms.h_reco_seedingLayerSet.back(), seedingLayerSetNames);
1040  setBinLabels(histograms.h_assoc2_seedingLayerSet.back(), seedingLayerSetNames);
1041  setBinLabels(histograms.h_looper_seedingLayerSet.back(), seedingLayerSetNames);
1042  setBinLabels(histograms.h_pileup_seedingLayerSet.back(), seedingLayerSetNames);
1043  }
1044 
1046 
1047  auto bookResolutionPlots1D = [&](std::vector<dqm::reco::MonitorElement*>& vec, auto&&... params) {
1048  vec.push_back(doResolutionPlots ? ibook.book1D(std::forward<decltype(params)>(params)...) : nullptr);
1049  };
1050  auto bookResolutionPlots2D = [&](std::vector<dqm::reco::MonitorElement*>& vec, bool logx, auto&&... params) {
1051  vec.push_back(doResolutionPlots ? make2DIfLogX(ibook, logx, std::forward<decltype(params)>(params)...) : nullptr);
1052  };
1053  auto bookResolutionPlotsProfile2D = [&](std::vector<dqm::reco::MonitorElement*>& vec, auto&&... params) {
1054  vec.push_back(doResolutionPlots ? ibook.bookProfile2D(std::forward<decltype(params)>(params)...) : nullptr);
1055  };
1056 
1057  bookResolutionPlots1D(histograms.h_eta, "eta", "pseudorapidity residue", 1000, -0.1, 0.1);
1058  bookResolutionPlots1D(histograms.h_pt, "pullPt", "pull of p_{t}", 100, -10, 10);
1059  bookResolutionPlots1D(histograms.h_pullTheta, "pullTheta", "pull of #theta parameter", 250, -25, 25);
1060  bookResolutionPlots1D(histograms.h_pullPhi, "pullPhi", "pull of #phi parameter", 250, -25, 25);
1061  bookResolutionPlots1D(histograms.h_pullDxy, "pullDxy", "pull of dxy parameter", 250, -25, 25);
1062  bookResolutionPlots1D(histograms.h_pullDz, "pullDz", "pull of dz parameter", 250, -25, 25);
1063  bookResolutionPlots1D(histograms.h_pullQoverp, "pullQoverp", "pull of qoverp parameter", 250, -25, 25);
1064 
1065  /* TO BE FIXED -----------
1066  if (associators[ww]=="TrackAssociatorByChi2"){
1067  histograms.h_assochi2.push_back( ibook.book1D("assocChi2","track association #chi^{2}",1000000,0,100000) );
1068  histograms.h_assochi2_prob.push_back(ibook.book1D("assocChi2_prob","probability of association #chi^{2}",100,0,1));
1069  } else if (associators[ww]=="quickTrackAssociatorByHits"){
1070  histograms.h_assocFraction.push_back( ibook.book1D("assocFraction","fraction of shared hits",200,0,2) );
1071  histograms.h_assocSharedHit.push_back(ibook.book1D("assocSharedHit","number of shared hits",20,0,20));
1072  }
1073  */
1074  histograms.h_assocFraction.push_back(ibook.book1D("assocFraction", "fraction of shared hits", 200, 0, 2));
1075  histograms.h_assocSharedHit.push_back(ibook.book1D("assocSharedHit", "number of shared hits", 41, -0.5, 40.5));
1076  // ----------------------
1077 
1078  // use the standard error of the mean as the errors in the profile
1079  histograms.chi2_vs_nhits.push_back(
1080  ibook.bookProfile("chi2mean_vs_nhits", "mean #chi^{2} vs nhits", nintHit, minHit, maxHit, 100, 0, 10, " "));
1081 
1082  bookResolutionPlots2D(
1083  histograms.etares_vs_eta, false, "etares_vs_eta", "etaresidue vs eta", nintEta, minEta, maxEta, 200, -0.1, 0.1);
1084  bookResolutionPlots2D(
1085  histograms.nrec_vs_nsim,
1086  false,
1087  "nrec_vs_nsim",
1088  "Number of selected reco tracks vs. number of selected sim tracks;TrackingParticles;Reco tracks",
1089  nintTracks,
1090  minTracks,
1091  maxTracks,
1092  nintTracks,
1093  minTracks,
1094  maxTracks);
1095 
1096  histograms.chi2_vs_eta.push_back(
1097  ibook.bookProfile("chi2mean", "mean #chi^{2} vs #eta", nintEta, minEta, maxEta, 200, 0, 20, " "));
1098  histograms.chi2_vs_phi.push_back(
1099  ibook.bookProfile("chi2mean_vs_phi", "mean #chi^{2} vs #phi", nintPhi, minPhi, maxPhi, 200, 0, 20, " "));
1100  histograms.chi2_vs_pt.push_back(
1101  makeProfileIfLogX(ibook, useLogPt, "chi2mean_vs_pt", "mean #chi^{2} vs p_{T}", nintPt, minPt, maxPt, 0, 20));
1102  histograms.chi2_vs_drj.push_back(makeProfileIfLogX(
1103  ibook, true, "chi2mean_vs_drj", "mean #chi^{2} vs dR(track,jet)", nintdrj, log10(mindrj), log10(maxdrj), 0, 20));
1104 
1105  histograms.assoc_chi2_vs_eta.push_back(
1106  ibook.bookProfile("assoc_chi2mean", "mean #chi^{2} vs #eta", nintEta, minEta, maxEta, 200, 0., 20., " "));
1107  histograms.assoc_chi2prob_vs_eta.push_back(ibook.bookProfile(
1108  "assoc_chi2prob_vs_eta", "mean #chi^{2} probability vs #eta", nintEta, minEta, maxEta, 100, 0., 1., " "));
1109  histograms.assoc_chi2_vs_pt.push_back(makeProfileIfLogX(
1110  ibook, useLogPt, "assoc_chi2mean_vs_pt", "mean #chi^{2} vs p_{T}", nintPt, minPt, maxPt, 0., 20.));
1111  histograms.assoc_chi2prob_vs_pt.push_back(makeProfileIfLogX(
1112  ibook, useLogPt, "assoc_chi2prob_vs_pt", "mean #chi^{2} probability vs p_{T}", nintPt, minPt, maxPt, 0., 1.));
1113  histograms.assoc_chi2_vs_drj.push_back(makeProfileIfLogX(ibook,
1114  true,
1115  "assoc_chi2mean_vs_drj",
1116  "mean #chi^{2} vs dR(track,jet)",
1117  nintdrj,
1118  log10(mindrj),
1119  log10(maxdrj),
1120  0.,
1121  20));
1122  histograms.assoc_chi2prob_vs_drj.push_back(makeProfileIfLogX(ibook,
1123  true,
1124  "assoc_chi2prob_vs_drj",
1125  "mean #chi^{2} probability vs dR(track,jet)",
1126  nintdrj,
1127  log10(mindrj),
1128  log10(maxdrj),
1129  0.,
1130  1.));
1131 
1132  histograms.nhits_vs_eta.push_back(
1133  ibook.bookProfile("hits_eta", "mean hits vs eta", nintEta, minEta, maxEta, nintHit, minHit, maxHit, " "));
1134  histograms.nPXBhits_vs_eta.push_back(ibook.bookProfile(
1135  "PXBhits_vs_eta", "mean # PXB its vs eta", nintEta, minEta, maxEta, nintHit, minHit, maxHit, " "));
1136  histograms.nPXFhits_vs_eta.push_back(ibook.bookProfile(
1137  "PXFhits_vs_eta", "mean # PXF hits vs eta", nintEta, minEta, maxEta, nintHit, minHit, maxHit, " "));
1138  histograms.nPXLhits_vs_eta.push_back(ibook.bookProfile(
1139  "PXLhits_vs_eta", "mean # PXL hits vs eta", nintEta, minEta, maxEta, nintHit, minHit, maxHit, " "));
1140  histograms.nTIBhits_vs_eta.push_back(ibook.bookProfile(
1141  "TIBhits_vs_eta", "mean # TIB hits vs eta", nintEta, minEta, maxEta, nintHit, minHit, maxHit, " "));
1142  histograms.nTIDhits_vs_eta.push_back(ibook.bookProfile(
1143  "TIDhits_vs_eta", "mean # TID hits vs eta", nintEta, minEta, maxEta, nintHit, minHit, maxHit, " "));
1144  histograms.nTOBhits_vs_eta.push_back(ibook.bookProfile(
1145  "TOBhits_vs_eta", "mean # TOB hits vs eta", nintEta, minEta, maxEta, nintHit, minHit, maxHit, " "));
1146  histograms.nTEChits_vs_eta.push_back(ibook.bookProfile(
1147  "TEChits_vs_eta", "mean # TEC hits vs eta", nintEta, minEta, maxEta, nintHit, minHit, maxHit, " "));
1148  histograms.nSTRIPhits_vs_eta.push_back(ibook.bookProfile(
1149  "STRIPhits_vs_eta", "mean # STRIP hits vs eta", nintEta, minEta, maxEta, nintHit, minHit, maxHit, " "));
1150 
1151  histograms.nLayersWithMeas_vs_eta.push_back(ibook.bookProfile("LayersWithMeas_eta",
1152  "mean # Layers with measurement vs eta",
1153  nintEta,
1154  minEta,
1155  maxEta,
1156  nintLayers,
1157  minLayers,
1158  maxLayers,
1159  " "));
1160  histograms.nPXLlayersWithMeas_vs_eta.push_back(ibook.bookProfile("PXLlayersWithMeas_vs_eta",
1161  "mean # PXL Layers with measurement vs eta",
1162  nintEta,
1163  minEta,
1164  maxEta,
1165  nintLayers,
1166  minLayers,
1167  maxLayers,
1168  " "));
1169  histograms.nSTRIPlayersWithMeas_vs_eta.push_back(ibook.bookProfile("STRIPlayersWithMeas_vs_eta",
1170  "mean # STRIP Layers with measurement vs eta",
1171  nintEta,
1172  minEta,
1173  maxEta,
1174  nintLayers,
1175  minLayers,
1176  maxLayers,
1177  " "));
1178  histograms.nSTRIPlayersWith1dMeas_vs_eta.push_back(ibook.bookProfile("STRIPlayersWith1dMeas_vs_eta",
1179  "mean # STRIP Layers with 1D measurement vs eta",
1180  nintEta,
1181  minEta,
1182  maxEta,
1183  nintLayers,
1184  minLayers,
1185  maxLayers,
1186  " "));
1187  histograms.nSTRIPlayersWith2dMeas_vs_eta.push_back(ibook.bookProfile("STRIPlayersWith2dMeas_vs_eta",
1188  "mean # STRIP Layers with 2D measurement vs eta",
1189  nintEta,
1190  minEta,
1191  maxEta,
1192  nintLayers,
1193  minLayers,
1194  maxLayers,
1195  " "));
1196 
1197  if (doMTDPlots_) {
1198  histograms.nMTDhits_vs_eta.push_back(ibook.bookProfile(
1199  "MTDhits_vs_eta", "mean # MTD hits vs eta", nintEta, minEta, maxEta, nintHit, minHit, maxHit, " "));
1200 
1201  histograms.nBTLhits_vs_eta.push_back(ibook.bookProfile(
1202  "BTLhits_vs_eta", "mean # BTL hits vs eta", nintEta, minEta, maxEta, nintHit, minHit, maxHit, " "));
1203 
1204  histograms.nETLhits_vs_eta.push_back(ibook.bookProfile(
1205  "ETLhits_vs_eta", "mean # ETL hits vs eta", nintEta, minEta, maxEta, nintHit, minHit, maxHit, " "));
1206  }
1207 
1208  histograms.nhits_vs_phi.push_back(
1209  ibook.bookProfile("hits_phi", "mean # hits vs #phi", nintPhi, minPhi, maxPhi, nintHit, minHit, maxHit, " "));
1210 
1211  histograms.nlosthits_vs_eta.push_back(ibook.bookProfile(
1212  "losthits_vs_eta", "mean # lost hits vs eta", nintEta, minEta, maxEta, nintHit, minHit, maxHit, " "));
1213 
1214  //resolution of track parameters
1215  // dPt/Pt cotTheta Phi TIP LIP
1216  // log10(pt)<0.5 100,0.1 240,0.08 100,0.015 100,0.1000 150,0.3000
1217  // 0.5<log10(pt)<1.5 100,0.1 120,0.01 100,0.003 100,0.0100 150,0.0500
1218  // >1.5 100,0.3 100,0.005 100,0.0008 100,0.0060 120,0.0300
1219 
1220  bookResolutionPlots2D(histograms.ptres_vs_eta,
1221  false,
1222  "ptres_vs_eta",
1223  "ptres_vs_eta",
1224  nintEta,
1225  minEta,
1226  maxEta,
1227  ptRes_nbin,
1229  ptRes_rangeMax);
1230 
1231  bookResolutionPlots2D(histograms.ptres_vs_phi,
1232  false,
1233  "ptres_vs_phi",
1234  "p_{t} res vs #phi",
1235  nintPhi,
1236  minPhi,
1237  maxPhi,
1238  ptRes_nbin,
1240  ptRes_rangeMax);
1241 
1242  bookResolutionPlots2D(histograms.ptres_vs_pt,
1243  useLogPt,
1244  "ptres_vs_pt",
1245  "ptres_vs_pt",
1246  nintPt,
1247  minPt,
1248  maxPt,
1249  ptRes_nbin,
1251  ptRes_rangeMax);
1252 
1253  bookResolutionPlots2D(histograms.cotThetares_vs_eta,
1254  false,
1255  "cotThetares_vs_eta",
1256  "cotThetares_vs_eta",
1257  nintEta,
1258  minEta,
1259  maxEta,
1263 
1264  bookResolutionPlots2D(histograms.cotThetares_vs_pt,
1265  useLogPt,
1266  "cotThetares_vs_pt",
1267  "cotThetares_vs_pt",
1268  nintPt,
1269  minPt,
1270  maxPt,
1274 
1275  bookResolutionPlots2D(histograms.phires_vs_eta,
1276  false,
1277  "phires_vs_eta",
1278  "phires_vs_eta",
1279  nintEta,
1280  minEta,
1281  maxEta,
1282  phiRes_nbin,
1284  phiRes_rangeMax);
1285 
1286  bookResolutionPlots2D(histograms.phires_vs_pt,
1287  useLogPt,
1288  "phires_vs_pt",
1289  "phires_vs_pt",
1290  nintPt,
1291  minPt,
1292  maxPt,
1293  phiRes_nbin,
1295  phiRes_rangeMax);
1296 
1297  bookResolutionPlots2D(histograms.phires_vs_phi,
1298  false,
1299  "phires_vs_phi",
1300  "#phi res vs #phi",
1301  nintPhi,
1302  minPhi,
1303  maxPhi,
1304  phiRes_nbin,
1306  phiRes_rangeMax);
1307 
1308  bookResolutionPlots2D(histograms.dxyres_vs_eta,
1309  false,
1310  "dxyres_vs_eta",
1311  "dxyres_vs_eta",
1312  nintEta,
1313  minEta,
1314  maxEta,
1315  dxyRes_nbin,
1317  dxyRes_rangeMax);
1318 
1319  bookResolutionPlots2D(histograms.dxyres_vs_pt,
1320  useLogPt,
1321  "dxyres_vs_pt",
1322  "dxyres_vs_pt",
1323  nintPt,
1324  minPt,
1325  maxPt,
1326  dxyRes_nbin,
1328  dxyRes_rangeMax);
1329 
1330  bookResolutionPlots2D(histograms.dxyres_vs_phi,
1331  false,
1332  "dxyres_vs_phi",
1333  "dxyres_vs_phi",
1334  nintPhi,
1335  minPhi,
1336  maxPhi,
1337  dxyRes_nbin,
1339  dxyRes_rangeMax);
1340 
1341  bookResolutionPlots2D(histograms.dzres_vs_eta,
1342  false,
1343  "dzres_vs_eta",
1344  "dzres_vs_eta",
1345  nintEta,
1346  minEta,
1347  maxEta,
1348  dzRes_nbin,
1350  dzRes_rangeMax);
1351 
1352  bookResolutionPlots2D(histograms.dzres_vs_pt,
1353  useLogPt,
1354  "dzres_vs_pt",
1355  "dzres_vs_pt",
1356  nintPt,
1357  minPt,
1358  maxPt,
1359  dzRes_nbin,
1361  dzRes_rangeMax);
1362 
1363  bookResolutionPlots2D(histograms.dzres_vs_phi,
1364  false,
1365  "dzres_vs_phi",
1366  "dzres_vs_phi",
1367  nintPhi,
1368  minPhi,
1369  maxPhi,
1370  dzRes_nbin,
1372  dzRes_rangeMax);
1373 
1374  bookResolutionPlotsProfile2D(histograms.ptmean_vs_eta_phi,
1375  "ptmean_vs_eta_phi",
1376  "mean p_{t} vs #eta and #phi",
1377  nintPhi,
1378  minPhi,
1379  maxPhi,
1380  nintEta,
1381  minEta,
1382  maxEta,
1383  1000,
1384  0,
1385  1000);
1386  bookResolutionPlotsProfile2D(histograms.phimean_vs_eta_phi,
1387  "phimean_vs_eta_phi",
1388  "mean #phi vs #eta and #phi",
1389  nintPhi,
1390  minPhi,
1391  maxPhi,
1392  nintEta,
1393  minEta,
1394  maxEta,
1395  nintPhi,
1396  minPhi,
1397  maxPhi);
1398 
1399  //pulls of track params vs eta: to be used with fitslicesytool
1400  bookResolutionPlots2D(
1401  histograms.dxypull_vs_eta, false, "dxypull_vs_eta", "dxypull_vs_eta", nintEta, minEta, maxEta, 100, -10, 10);
1402  bookResolutionPlots2D(
1403  histograms.ptpull_vs_eta, false, "ptpull_vs_eta", "ptpull_vs_eta", nintEta, minEta, maxEta, 100, -10, 10);
1404  bookResolutionPlots2D(
1405  histograms.dzpull_vs_eta, false, "dzpull_vs_eta", "dzpull_vs_eta", nintEta, minEta, maxEta, 100, -10, 10);
1406  bookResolutionPlots2D(
1407  histograms.phipull_vs_eta, false, "phipull_vs_eta", "phipull_vs_eta", nintEta, minEta, maxEta, 100, -10, 10);
1408  bookResolutionPlots2D(
1409  histograms.thetapull_vs_eta, false, "thetapull_vs_eta", "thetapull_vs_eta", nintEta, minEta, maxEta, 100, -10, 10);
1410  bookResolutionPlots2D(
1411  histograms.dxypull_vs_pt, useLogPt, "dxypull_vs_pt", "dxypull_vs_pt", nintPt, minPt, maxPt, 100, -10, 10);
1412  bookResolutionPlots2D(
1413  histograms.ptpull_vs_pt, useLogPt, "ptpull_vs_pt", "ptpull_vs_pt", nintPt, minPt, maxPt, 100, -10, 10);
1414  bookResolutionPlots2D(
1415  histograms.dzpull_vs_pt, useLogPt, "dzpull_vs_pt", "dzpull_vs_pt", nintPt, minPt, maxPt, 100, -10, 10);
1416  bookResolutionPlots2D(
1417  histograms.phipull_vs_pt, useLogPt, "phipull_vs_pt", "phipull_vs_pt", nintPt, minPt, maxPt, 100, -10, 10);
1418  bookResolutionPlots2D(
1419  histograms.thetapull_vs_pt, useLogPt, "thetapull_vs_pt", "thetapull_vs_pt", nintPt, minPt, maxPt, 100, -10, 10);
1420 
1421  // histograms.h_ptshiftetamean.push_back( ibook.book1D("h_ptshifteta_Mean","<#deltapT/pT>[%] vs #eta",nintEta,minEta,maxEta) );
1422 
1423  //pulls of track params vs phi
1424  bookResolutionPlots2D(
1425  histograms.ptpull_vs_phi, false, "ptpull_vs_phi", "p_{t} pull vs #phi", nintPhi, minPhi, maxPhi, 100, -10, 10);
1426  bookResolutionPlots2D(
1427  histograms.phipull_vs_phi, false, "phipull_vs_phi", "#phi pull vs #phi", nintPhi, minPhi, maxPhi, 100, -10, 10);
1428  bookResolutionPlots2D(histograms.thetapull_vs_phi,
1429  false,
1430  "thetapull_vs_phi",
1431  "#theta pull vs #phi",
1432  nintPhi,
1433  minPhi,
1434  maxPhi,
1435  100,
1436  -10,
1437  10);
1438 
1439  bookResolutionPlots2D(histograms.nrecHit_vs_nsimHit_rec2sim,
1440  false,
1441  "nrecHit_vs_nsimHit_rec2sim",
1442  "nrecHit vs nsimHit (Rec2simAssoc)",
1443  nintHit,
1444  minHit,
1445  maxHit,
1446  nintHit,
1447  minHit,
1448  maxHit);
1449 }
1450 
1452  histograms.h_recodxypv.push_back(
1453  ibook.book1D("num_reco_dxypv", "N of reco track vs dxy(PV)", nintDxy, minDxy, maxDxy));
1454  histograms.h_assoc2dxypv.push_back(ibook.book1D(
1455  "num_assoc(recoToSim)_dxypv", "N of associated (recoToSim) tracks vs dxy(PV)", nintDxy, minDxy, maxDxy));
1456  histograms.h_looperdxypv.push_back(ibook.book1D(
1457  "num_duplicate_dxypv", "N of associated (recoToSim) looper tracks vs dxy(PV)", nintDxy, minDxy, maxDxy));
1458  if (!doSeedPlots_)
1459  histograms.h_misiddxypv.push_back(ibook.book1D("num_chargemisid_dxypv",
1460  "N of associated (recoToSim) charge misIDed tracks vs dxy(PV)",
1461  nintDxy,
1462  minDxy,
1463  maxDxy));
1464  histograms.h_pileupdxypv.push_back(ibook.book1D(
1465  "num_pileup_dxypv", "N of associated (recoToSim) pileup tracks vs dxy(PV)", nintDxy, minDxy, maxDxy));
1466 
1467  histograms.h_recodzpv.push_back(ibook.book1D("num_reco_dzpv", "N of reco track vs dz(PV)", nintDz, minDz, maxDz));
1468  histograms.h_assoc2dzpv.push_back(
1469  ibook.book1D("num_assoc(recoToSim)_dzpv", "N of associated (recoToSim) tracks vs dz(PV)", nintDz, minDz, maxDz));
1470  histograms.h_looperdzpv.push_back(
1471  ibook.book1D("num_duplicate_dzpv", "N of associated (recoToSim) looper tracks vs dz(PV)", nintDz, minDz, maxDz));
1472  if (!doSeedPlots_)
1473  histograms.h_misiddzpv.push_back(ibook.book1D("num_chargemisid_versus_dzpv",
1474  "N of associated (recoToSim) charge misIDed tracks vs dz(PV)",
1475  nintDz,
1476  minDz,
1477  maxDz));
1478  histograms.h_pileupdzpv.push_back(
1479  ibook.book1D("num_pileup_dzpv", "N of associated (recoToSim) pileup tracks vs dz(PV)", nintDz, minDz, maxDz));
1480 
1481  histograms.h_recodxypvzoomed.push_back(ibook.book1D(
1482  "num_reco_dxypv_zoomed", "N of reco track vs dxy(PV)", nintDxy, minDxy / dxyDzZoom, maxDxy / dxyDzZoom));
1483  histograms.h_assoc2dxypvzoomed.push_back(ibook.book1D("num_assoc(recoToSim)_dxypv_zoomed",
1484  "N of associated (recoToSim) tracks vs dxy(PV)",
1485  nintDxy,
1486  minDxy / dxyDzZoom,
1487  maxDxy / dxyDzZoom));
1488  histograms.h_looperdxypvzoomed.push_back(ibook.book1D("num_duplicate_dxypv_zoomed",
1489  "N of associated (recoToSim) looper tracks vs dxy(PV)",
1490  nintDxy,
1491  minDxy / dxyDzZoom,
1492  maxDxy / dxyDzZoom));
1493  if (!doSeedPlots_)
1494  histograms.h_misiddxypvzoomed.push_back(ibook.book1D("num_chargemisid_dxypv_zoomed",
1495  "N of associated (recoToSim) charge misIDed tracks vs dxy(PV)",
1496  nintDxy,
1497  minDxy / dxyDzZoom,
1498  maxDxy / dxyDzZoom));
1499  histograms.h_pileupdxypvzoomed.push_back(ibook.book1D("num_pileup_dxypv_zoomed",
1500  "N of associated (recoToSim) pileup tracks vs dxy(PV)",
1501  nintDxy,
1502  minDxy / dxyDzZoom,
1503  maxDxy / dxyDzZoom));
1504 
1505  histograms.h_recodzpvzoomed.push_back(
1506  ibook.book1D("num_reco_dzpv_zoomed", "N of reco track vs dz(PV)", nintDz, minDz / dxyDzZoom, maxDz / dxyDzZoom));
1507  histograms.h_assoc2dzpvzoomed.push_back(ibook.book1D("num_assoc(recoToSim)_dzpv_zoomed",
1508  "N of associated (recoToSim) tracks vs dz(PV)",
1509  nintDz,
1510  minDz / dxyDzZoom,
1511  maxDz / dxyDzZoom));
1512  histograms.h_looperdzpvzoomed.push_back(ibook.book1D("num_duplicate_dzpv_zoomed",
1513  "N of associated (recoToSim) looper tracks vs dz(PV)",
1514  nintDz,
1515  minDz / dxyDzZoom,
1516  maxDz / dxyDzZoom));
1517  if (!doSeedPlots_)
1518  histograms.h_misiddzpvzoomed.push_back(ibook.book1D("num_chargemisid_versus_dzpv_zoomed",
1519  "N of associated (recoToSim) charge misIDed tracks vs dz(PV)",
1520  nintDz,
1521  minDz / dxyDzZoom,
1522  maxDz / dxyDzZoom));
1523  histograms.h_pileupdzpvzoomed.push_back(ibook.book1D("num_pileup_dzpv_zoomed",
1524  "N of associated (recoToSim) pileup tracks vs dz(PV)",
1525  nintDz,
1526  minDz / dxyDzZoom,
1527  maxDz / dxyDzZoom));
1528 
1529  histograms.h_reco_dzpvcut.push_back(
1530  ibook.book1D("num_reco_dzpvcut", "N of reco track vs dz(PV)", nintDzpvCum, 0, maxDzpvCum));
1531  histograms.h_assoc2_dzpvcut.push_back(ibook.book1D(
1532  "num_assoc(recoToSim)_dzpvcut", "N of associated (recoToSim) tracks vs dz(PV)", nintDzpvCum, 0, maxDzpvCum));
1533  histograms.h_pileup_dzpvcut.push_back(ibook.book1D(
1534  "num_pileup_dzpvcut", "N of associated (recoToSim) pileup tracks vs dz(PV)", nintDzpvCum, 0, maxDzpvCum));
1535 
1536  histograms.h_reco_dzpvcut_pt.push_back(
1537  ibook.book1D("num_reco_dzpvcut_pt", "#sump_{T} of reco track vs dz(PV)", nintDzpvCum, 0, maxDzpvCum));
1538  histograms.h_assoc2_dzpvcut_pt.push_back(ibook.book1D("num_assoc(recoToSim)_dzpvcut_pt",
1539  "#sump_{T} of associated (recoToSim) tracks vs dz(PV)",
1540  nintDzpvCum,
1541  0,
1542  maxDzpvCum));
1543  histograms.h_pileup_dzpvcut_pt.push_back(ibook.book1D("num_pileup_dzpvcut_pt",
1544  "#sump_{T} of associated (recoToSim) pileup tracks vs dz(PV)",
1545  nintDzpvCum,
1546  0,
1547  maxDzpvCum));
1548  histograms.h_reco_dzpvcut_pt.back()->enableSumw2();
1549  histograms.h_assoc2_dzpvcut_pt.back()->enableSumw2();
1550  histograms.h_pileup_dzpvcut_pt.back()->enableSumw2();
1551 
1552  histograms.h_reco_dzpvsigcut.push_back(
1553  ibook.book1D("num_reco_dzpvsigcut", "N of reco track vs dz(PV)/dzError", nintDzpvsigCum, 0, maxDzpvsigCum));
1554  histograms.h_assoc2_dzpvsigcut.push_back(ibook.book1D("num_assoc(recoToSim)_dzpvsigcut",
1555  "N of associated (recoToSim) tracks vs dz(PV)/dzError",
1557  0,
1558  maxDzpvsigCum));
1559  histograms.h_pileup_dzpvsigcut.push_back(ibook.book1D("num_pileup_dzpvsigcut",
1560  "N of associated (recoToSim) pileup tracks vs dz(PV)/dzError",
1562  0,
1563  maxDzpvsigCum));
1564 
1565  histograms.h_reco_dzpvsigcut_pt.push_back(ibook.book1D(
1566  "num_reco_dzpvsigcut_pt", "#sump_{T} of reco track vs dz(PV)/dzError", nintDzpvsigCum, 0, maxDzpvsigCum));
1567  histograms.h_assoc2_dzpvsigcut_pt.push_back(
1568  ibook.book1D("num_assoc(recoToSim)_dzpvsigcut_pt",
1569  "#sump_{T} of associated (recoToSim) tracks vs dz(PV)/dzError",
1571  0,
1572  maxDzpvsigCum));
1573  histograms.h_pileup_dzpvsigcut_pt.push_back(
1574  ibook.book1D("num_pileup_dzpvsigcut_pt",
1575  "#sump_{T} of associated (recoToSim) pileup tracks vs dz(PV)/dzError",
1577  0,
1578  maxDzpvsigCum));
1579  histograms.h_reco_dzpvsigcut_pt.back()->enableSumw2();
1580  histograms.h_assoc2_dzpvsigcut_pt.back()->enableSumw2();
1581  histograms.h_pileup_dzpvsigcut_pt.back()->enableSumw2();
1582 }
1583 
1585  // dE/dx stuff
1586  histograms.h_dedx_estim.emplace_back();
1587  histograms.h_dedx_estim.back().push_back(
1588  ibook.book1D("h_dedx_estim1", "dE/dx estimator 1", nintDeDx, minDeDx, maxDeDx));
1589  histograms.h_dedx_estim.back().push_back(
1590  ibook.book1D("h_dedx_estim2", "dE/dx estimator 2", nintDeDx, minDeDx, maxDeDx));
1591 
1592  histograms.h_dedx_nom.emplace_back();
1593  histograms.h_dedx_nom.back().push_back(
1594  ibook.book1D("h_dedx_nom1", "dE/dx number of measurements", nintHit, minHit, maxHit));
1595  histograms.h_dedx_nom.back().push_back(
1596  ibook.book1D("h_dedx_nom2", "dE/dx number of measurements", nintHit, minHit, maxHit));
1597 
1598  histograms.h_dedx_sat.emplace_back();
1599  histograms.h_dedx_sat.back().push_back(
1600  ibook.book1D("h_dedx_sat1", "dE/dx number of measurements with saturation", nintHit, minHit, maxHit));
1601  histograms.h_dedx_sat.back().push_back(
1602  ibook.book1D("h_dedx_sat2", "dE/dx number of measurements with saturation", nintHit, minHit, maxHit));
1603 }
1604 
1606  histograms.h_seedsFitFailed.push_back(
1607  ibook.book1D("seeds_fitFailed", "Number of seeds for which the fit failed", nintTracks, minTracks, maxTracks));
1608  histograms.h_seedsFitFailedFraction.push_back(
1609  ibook.book1D("seeds_fitFailedFraction", "Fraction of seeds for which the fit failed", 100, 0, 1));
1610 }
1611 
1613  histograms.h_reco_mva.emplace_back();
1614  histograms.h_assoc2_mva.emplace_back();
1615 
1616  histograms.h_reco_mvacut.emplace_back();
1617  histograms.h_assoc_mvacut.emplace_back();
1618  histograms.h_assoc2_mvacut.emplace_back();
1619  histograms.h_simul2_mvacut.emplace_back();
1620 
1621  histograms.h_reco_mva_hp.emplace_back();
1622  histograms.h_assoc2_mva_hp.emplace_back();
1623 
1624  histograms.h_reco_mvacut_hp.emplace_back();
1625  histograms.h_assoc_mvacut_hp.emplace_back();
1626  histograms.h_assoc2_mvacut_hp.emplace_back();
1627  histograms.h_simul2_mvacut_hp.emplace_back();
1628 
1629  histograms.h_assoc2_mva_vs_pt.emplace_back();
1630  histograms.h_fake_mva_vs_pt.emplace_back();
1631  histograms.h_assoc2_mva_vs_pt_hp.emplace_back();
1632  histograms.h_fake_mva_vs_pt_hp.emplace_back();
1633  histograms.h_assoc2_mva_vs_eta.emplace_back();
1634  histograms.h_fake_mva_vs_eta.emplace_back();
1635  histograms.h_assoc2_mva_vs_eta_hp.emplace_back();
1636  histograms.h_fake_mva_vs_eta_hp.emplace_back();
1637 
1638  for (size_t i = 1; i <= nMVAs; ++i) {
1639  auto istr = std::to_string(i);
1640  std::string pfix;
1641 
1642  if (i == 1) {
1643  histograms.h_reco_mva_hp.back().emplace_back();
1644  histograms.h_assoc2_mva_hp.back().emplace_back();
1645 
1646  histograms.h_reco_mvacut_hp.back().emplace_back();
1647  histograms.h_assoc_mvacut_hp.back().emplace_back();
1648  histograms.h_assoc2_mvacut_hp.back().emplace_back();
1649  histograms.h_simul2_mvacut_hp.back().emplace_back();
1650 
1651  histograms.h_assoc2_mva_vs_pt_hp.back().emplace_back();
1652  histograms.h_fake_mva_vs_pt_hp.back().emplace_back();
1653  histograms.h_assoc2_mva_vs_eta_hp.back().emplace_back();
1654  histograms.h_fake_mva_vs_eta_hp.back().emplace_back();
1655  } else {
1656  pfix = " (not loose-selected)";
1657  std::string pfix2 = " (not HP-selected)";
1658 
1659  histograms.h_reco_mva_hp.back().push_back(ibook.book1D(
1660  "num_reco_mva" + istr + "_hp", "N of reco track after vs MVA" + istr + pfix2, nintMVA, minMVA, maxMVA));
1661  histograms.h_assoc2_mva_hp.back().push_back(
1662  ibook.book1D("num_assoc(recoToSim)_mva" + istr + "_hp",
1663  "N of associated tracks (recoToSim) vs MVA" + istr + pfix2,
1664  nintMVA,
1665  minMVA,
1666  maxMVA));
1667 
1668  histograms.h_reco_mvacut_hp.back().push_back(ibook.book1D("num_reco_mva" + istr + "cut" + "_hp",
1669  "N of reco track vs cut on MVA" + istr + pfix2,
1670  nintMVA,
1671  minMVA,
1672  maxMVA));
1673  histograms.h_assoc_mvacut_hp.back().push_back(
1674  ibook.book1D("num_assoc(simToReco)_mva" + istr + "cut_hp",
1675  "N of associated tracks (simToReco) vs cut on MVA" + istr + pfix2,
1676  nintMVA,
1677  minMVA,
1678  maxMVA));
1679  histograms.h_assoc2_mvacut_hp.back().push_back(
1680  ibook.book1D("num_assoc(recoToSim)_mva" + istr + "cut_hp",
1681  "N of associated tracks (recoToSim) vs cut on MVA" + istr + pfix2,
1682  nintMVA,
1683  minMVA,
1684  maxMVA));
1685  histograms.h_simul2_mvacut_hp.back().push_back(
1686  ibook.book1D("num_simul2_mva" + istr + "cut_hp",
1687  "N of simulated tracks (associated to any track) vs cut on MVA" + istr + pfix2,
1688  nintMVA,
1689  minMVA,
1690  maxMVA));
1691 
1692  histograms.h_assoc2_mva_vs_pt_hp.back().push_back(
1693  makeProfileIfLogX(ibook,
1694  useLogPt,
1695  ("mva_assoc(recoToSim)_mva" + istr + "_pT_hp").c_str(),
1696  ("MVA" + istr + " of associated tracks (recoToSim) vs. track p_{T}" + pfix2).c_str(),
1697  nintPt,
1698  minPt,
1699  maxPt,
1700  minMVA,
1701  maxMVA));
1702  histograms.h_fake_mva_vs_pt_hp.back().push_back(
1703  makeProfileIfLogX(ibook,
1704  useLogPt,
1705  ("mva_fake_mva" + istr + "pT_hp").c_str(),
1706  ("MVA" + istr + " of non-associated tracks (recoToSim) vs. track p_{T}" + pfix2).c_str(),
1707  nintPt,
1708  minPt,
1709  maxPt,
1710  minMVA,
1711  maxMVA));
1712  histograms.h_assoc2_mva_vs_eta_hp.back().push_back(
1713  ibook.bookProfile("mva_assoc(recoToSim)_mva" + istr + "_eta_hp",
1714  "MVA" + istr + " of associated tracks (recoToSim) vs. track #eta" + pfix2,
1715  nintEta,
1716  minEta,
1717  maxEta,
1718  nintMVA,
1719  minMVA,
1720  maxMVA));
1721  histograms.h_fake_mva_vs_eta_hp.back().push_back(
1722  ibook.bookProfile("mva_fake_mva" + istr + "eta_hp",
1723  "MVA" + istr + " of non-associated tracks (recoToSim) vs. track #eta" + pfix2,
1724  nintEta,
1725  minEta,
1726  maxEta,
1727  nintMVA,
1728  minMVA,
1729  maxMVA));
1730  }
1731 
1732  histograms.h_reco_mva.back().push_back(
1733  ibook.book1D("num_reco_mva" + istr, "N of reco track vs MVA" + istr + pfix, nintMVA, minMVA, maxMVA));
1734  histograms.h_assoc2_mva.back().push_back(ibook.book1D("num_assoc(recoToSim)_mva" + istr,
1735  "N of associated tracks (recoToSim) vs MVA" + istr + pfix,
1736  nintMVA,
1737  minMVA,
1738  maxMVA));
1739 
1740  histograms.h_reco_mvacut.back().push_back(ibook.book1D(
1741  "num_reco_mva" + istr + "cut", "N of reco track vs cut on MVA" + istr + pfix, nintMVA, minMVA, maxMVA));
1742  histograms.h_assoc_mvacut.back().push_back(
1743  ibook.book1D("num_assoc(simToReco)_mva" + istr + "cut",
1744  "N of associated tracks (simToReco) vs cut on MVA" + istr + pfix,
1745  nintMVA,
1746  minMVA,
1747  maxMVA));
1748  histograms.h_assoc2_mvacut.back().push_back(
1749  ibook.book1D("num_assoc(recoToSim)_mva" + istr + "cut",
1750  "N of associated tracks (recoToSim) vs cut on MVA" + istr + pfix,
1751  nintMVA,
1752  minMVA,
1753  maxMVA));
1754  histograms.h_simul2_mvacut.back().push_back(
1755  ibook.book1D("num_simul2_mva" + istr + "cut",
1756  "N of simulated tracks (associated to any track) vs cut on MVA" + istr + pfix,
1757  nintMVA,
1758  minMVA,
1759  maxMVA));
1760 
1761  histograms.h_assoc2_mva_vs_pt.back().push_back(
1762  makeProfileIfLogX(ibook,
1763  useLogPt,
1764  ("mva_assoc(recoToSim)_mva" + istr + "_pT").c_str(),
1765  ("MVA" + istr + " of associated tracks (recoToSim) vs. track p_{T}" + pfix).c_str(),
1766  nintPt,
1767  minPt,
1768  maxPt,
1769  minMVA,
1770  maxMVA));
1771  histograms.h_fake_mva_vs_pt.back().push_back(
1772  makeProfileIfLogX(ibook,
1773  useLogPt,
1774  ("mva_fake_mva" + istr + "_pT").c_str(),
1775  ("MVA" + istr + " of non-associated tracks (recoToSim) vs. track p_{T}" + pfix).c_str(),
1776  nintPt,
1777  minPt,
1778  maxPt,
1779  minMVA,
1780  maxMVA));
1781  histograms.h_assoc2_mva_vs_eta.back().push_back(
1782  ibook.bookProfile("mva_assoc(recoToSim)_mva" + istr + "_eta",
1783  "MVA" + istr + " of associated tracks (recoToSim) vs. track #eta" + pfix,
1784  nintEta,
1785  minEta,
1786  maxEta,
1787  nintMVA,
1788  minMVA,
1789  maxMVA));
1790  histograms.h_fake_mva_vs_eta.back().push_back(
1791  ibook.bookProfile("mva_fake_mva" + istr + "_eta",
1792  "MVA" + istr + " of non-associated tracks (recoToSim) vs. track #eta" + pfix,
1793  nintEta,
1794  minEta,
1795  maxEta,
1796  nintMVA,
1797  minMVA,
1798  maxMVA));
1799  }
1800 }
1801 
1803  const TrackingParticle::Vector& momentumTP,
1804  const TrackingParticle::Point& vertexTP,
1805  int bx) const {
1806  if (bx == 0) {
1807  histograms.h_ptSIM->Fill(sqrt(momentumTP.perp2()));
1808  histograms.h_etaSIM->Fill(momentumTP.eta());
1809  histograms.h_phiSIM->Fill(momentumTP.phi());
1810  histograms.h_vertposSIM->Fill(sqrt(vertexTP.perp2()));
1811  }
1812  histograms.h_bunchxSIM->Fill(bx);
1813 }
1814 
1816  const Histograms& histograms,
1817  int count,
1818  const TrackingParticle& tp,
1819  const TrackingParticle::Vector& momentumTP,
1820  const TrackingParticle::Point& vertexTP,
1821  double dxySim,
1822  double dzSim,
1823  double dxyPVSim,
1824  double dzPVSim,
1825  int nSimHits,
1826  int nSimLayers,
1827  int nSimPixelLayers,
1828  int nSimStripMonoAndStereoLayers,
1829  const reco::Track* track,
1830  int numVertices,
1831  double dR,
1832  double dRJet,
1833  const math::XYZPoint* pvPosition,
1834  const TrackingVertex::LorentzVector* simPVPosition,
1835  const math::XYZPoint& bsPosition,
1836  const std::vector<float>& mvas,
1837  unsigned int selectsLoose,
1838  unsigned int selectsHP) const {
1839  bool isMatched = track;
1840  const auto eta = getEta(momentumTP.eta());
1841  const auto phi = momentumTP.phi();
1842  const auto pt = getPt(sqrt(momentumTP.perp2()));
1843  const auto nSim3DLayers = nSimPixelLayers + nSimStripMonoAndStereoLayers;
1844 
1845  const auto vertexTPwrtBS = vertexTP - bsPosition;
1846  const auto vertxy = std::sqrt(vertexTPwrtBS.perp2());
1847  const auto vertz = vertexTPwrtBS.z();
1848 
1849  //efficiency vs. cut on MVA
1850  //
1851  // Note that this includes also pileup TPs, as "signalOnly"
1852  // selection is applied only in the TpSelector*. Have to think if
1853  // this is really what we want.
1854  if (isMatched) {
1855  for (size_t i = 0; i < mvas.size(); ++i) {
1856  if (i <= selectsLoose) {
1857  histograms.h_simul2_mvacut[count][i]->Fill(maxMVA);
1858  histograms.h_assoc_mvacut[count][i]->Fill(mvas[i]);
1859  }
1860  if (i >= 1 && i <= selectsHP) {
1861  histograms.h_simul2_mvacut_hp[count][i]->Fill(maxMVA);
1862  histograms.h_assoc_mvacut_hp[count][i]->Fill(mvas[i]);
1863  }
1864  }
1865  }
1866 
1867  if ((*TpSelectorForEfficiencyVsEta)(tp)) {
1868  //effic vs eta
1869  histograms.h_simuleta[count]->Fill(eta);
1870  if (isMatched)
1871  histograms.h_assoceta[count]->Fill(eta);
1872  }
1873 
1874  if ((*TpSelectorForEfficiencyVsPhi)(tp)) {
1875  histograms.h_simulphi[count]->Fill(phi);
1876  if (isMatched)
1877  histograms.h_assocphi[count]->Fill(phi);
1878  //effic vs hits
1879  histograms.h_simulhit[count]->Fill(nSimHits);
1880  histograms.h_simullayer[count]->Fill(nSimLayers);
1881  histograms.h_simulpixellayer[count]->Fill(nSimPixelLayers);
1882  histograms.h_simul3Dlayer[count]->Fill(nSim3DLayers);
1883  if (isMatched) {
1884  histograms.h_assochit[count]->Fill(nSimHits);
1885  histograms.h_assoclayer[count]->Fill(nSimLayers);
1886  histograms.h_assocpixellayer[count]->Fill(nSimPixelLayers);
1887  histograms.h_assoc3Dlayer[count]->Fill(nSim3DLayers);
1888  if (histograms.nrecHit_vs_nsimHit_sim2rec[count])
1889  histograms.nrecHit_vs_nsimHit_sim2rec[count]->Fill(track->numberOfValidHits(), nSimHits);
1890  }
1891  //effic vs pu
1892  histograms.h_simulpu[count]->Fill(numVertices);
1893  if (isMatched)
1894  histograms.h_assocpu[count]->Fill(numVertices);
1895  //efficiency vs dR
1896  histograms.h_simuldr[count]->Fill(dR);
1897  if (isMatched)
1898  histograms.h_assocdr[count]->Fill(dR);
1899  //efficiency vs dR jet
1900  histograms.h_simuldrj[count]->Fill(dRJet);
1901  if (isMatched)
1902  histograms.h_assocdrj[count]->Fill(dRJet);
1903  }
1904 
1905  if ((*TpSelectorForEfficiencyVsPt)(tp)) {
1906  histograms.h_simulpT[count]->Fill(pt);
1907  if (isMatched)
1908  histograms.h_assocpT[count]->Fill(pt);
1909  }
1910 
1912  histograms.h_simuldxy[count]->Fill(dxySim);
1913  if (isMatched)
1914  histograms.h_assocdxy[count]->Fill(dxySim);
1915  if (pvPosition) {
1916  histograms.h_simuldxypv[count]->Fill(dxyPVSim);
1917  histograms.h_simuldxypvzoomed[count]->Fill(dxyPVSim);
1918  if (isMatched) {
1919  histograms.h_assocdxypv[count]->Fill(dxyPVSim);
1920  histograms.h_assocdxypvzoomed[count]->Fill(dxyPVSim);
1921  }
1922  }
1923 
1924  histograms.h_simulvertpos[count]->Fill(vertxy);
1925  if (isMatched)
1926  histograms.h_assocvertpos[count]->Fill(vertxy);
1927  }
1928 
1930  histograms.h_simuldz[count]->Fill(dzSim);
1931  if (isMatched)
1932  histograms.h_assocdz[count]->Fill(dzSim);
1933 
1934  histograms.h_simulzpos[count]->Fill(vertz);
1935  if (isMatched)
1936  histograms.h_assoczpos[count]->Fill(vertz);
1937 
1938  if (pvPosition) {
1939  histograms.h_simuldzpv[count]->Fill(dzPVSim);
1940  histograms.h_simuldzpvzoomed[count]->Fill(dzPVSim);
1941 
1942  histograms.h_simul_dzpvcut[count]->Fill(0);
1943  histograms.h_simul_dzpvsigcut[count]->Fill(0);
1944  histograms.h_simul_dzpvcut_pt[count]->Fill(0, pt);
1945  histograms.h_simul_dzpvsigcut_pt[count]->Fill(0, pt);
1946 
1947  if (isMatched) {
1948  histograms.h_assocdzpv[count]->Fill(dzPVSim);
1949  histograms.h_assocdzpvzoomed[count]->Fill(dzPVSim);
1950 
1951  histograms.h_simul2_dzpvcut[count]->Fill(0);
1952  histograms.h_simul2_dzpvsigcut[count]->Fill(0);
1953  histograms.h_simul2_dzpvcut_pt[count]->Fill(0, pt);
1954  histograms.h_simul2_dzpvsigcut_pt[count]->Fill(0, pt);
1955  const double dzpvcut = std::abs(track->dz(*pvPosition));
1956  const double dzpvsigcut = dzpvcut / track->dzError();
1957  histograms.h_assoc_dzpvcut[count]->Fill(dzpvcut);
1958  histograms.h_assoc_dzpvsigcut[count]->Fill(dzpvsigcut);
1959  histograms.h_assoc_dzpvcut_pt[count]->Fill(dzpvcut, pt);
1960  histograms.h_assoc_dzpvsigcut_pt[count]->Fill(dzpvsigcut, pt);
1961  }
1962  }
1963  if (simPVPosition) {
1964  const auto simpvz = simPVPosition->z();
1965  histograms.h_simul_simpvz[count]->Fill(simpvz);
1966  if (isMatched) {
1967  histograms.h_assoc_simpvz[count]->Fill(simpvz);
1968  }
1969  }
1970  }
1971 }
1972 
1974  int count,
1975  const reco::Track& track1,
1976  const reco::Track& track2) const {
1977  histograms.h_duplicates_oriAlgo_vs_oriAlgo[count]->Fill(track1.originalAlgo(), track2.originalAlgo());
1978 }
1979 
1981  histograms.h_tracksSIM->Fill(numSimTracks);
1982 }
1983 
1984 // dE/dx
1986  const Histograms& histograms,
1987  int count,
1988  const edm::RefToBase<reco::Track>& trackref,
1989  const std::vector<const edm::ValueMap<reco::DeDxData>*>& v_dEdx) const {
1990  for (unsigned int i = 0; i < v_dEdx.size(); i++) {
1991  const edm::ValueMap<reco::DeDxData>& dEdxTrack = *(v_dEdx[i]);
1992  const reco::DeDxData& dedx = dEdxTrack[trackref];
1993  histograms.h_dedx_estim[count][i]->Fill(dedx.dEdx());
1994  histograms.h_dedx_nom[count][i]->Fill(dedx.numberOfMeasurements());
1995  histograms.h_dedx_sat[count][i]->Fill(dedx.numberOfSaturatedMeasurements());
1996  }
1997 }
1998 
2000  int count,
2001  const reco::Track& track,
2002  const TrackerTopology& ttopo,
2003  const math::XYZPoint& bsPosition,
2004  const math::XYZPoint* pvPosition,
2005  const TrackingVertex::LorentzVector* simPVPosition,
2006  bool isMatched,
2007  bool isSigMatched,
2008  bool isChargeMatched,
2009  int numAssocRecoTracks,
2010  int numVertices,
2011  int nSimHits,
2012  double sharedFraction,
2013  double dR,
2014  double dRJet,
2015  const std::vector<float>& mvas,
2016  unsigned int selectsLoose,
2017  unsigned int selectsHP) const {
2018  //Fill track algo histogram
2019  histograms.h_algo[count]->Fill(track.algo());
2020  int sharedHits = sharedFraction * track.numberOfValidHits();
2021 
2022  //Compute fake rate vs eta
2023  const auto eta = getEta(track.momentum().eta());
2024  const auto phi = track.momentum().phi();
2025  const auto pt = getPt(sqrt(track.momentum().perp2()));
2026  const auto dxy = track.dxy(bsPosition);
2027  const auto dz = track.dz(bsPosition);
2028  const auto dxypv = pvPosition ? track.dxy(*pvPosition) : 0.0;
2029  const auto dzpv = pvPosition ? track.dz(*pvPosition) : 0.0;
2030  const auto dzpvsig = pvPosition ? dzpv / track.dzError() : 0.0;
2031  const auto nhits = track.found();
2032  const auto nlayers = track.hitPattern().trackerLayersWithMeasurement();
2033  const auto nPixelLayers = track.hitPattern().pixelLayersWithMeasurement();
2034  const auto n3DLayers = nPixelLayers + track.hitPattern().numberOfValidStripLayersWithMonoAndStereo();
2035  const auto refPointWrtBS = track.referencePoint() - bsPosition;
2036  const auto vertxy = std::sqrt(refPointWrtBS.perp2());
2037  const auto vertz = refPointWrtBS.z();
2038  const auto chi2 = track.normalizedChi2();
2039  const auto chi2prob = TMath::Prob(track.chi2(), (int)track.ndof());
2040  const bool fillSeedingLayerSets = !seedingLayerSetNames.empty();
2041  const unsigned int seedingLayerSetBin = fillSeedingLayerSets ? getSeedingLayerSetBin(track, ttopo) : 0;
2042  const auto simpvz = simPVPosition ? simPVPosition->z() : 0.0;
2043 
2044  const bool paramsValid = !trackFromSeedFitFailed(track);
2045 
2046  if (paramsValid) {
2047  histograms.h_recoeta[count]->Fill(eta);
2048  histograms.h_recophi[count]->Fill(phi);
2049  histograms.h_recopT[count]->Fill(pt);
2050  histograms.h_recopTvseta[count]->Fill(eta, pt);
2051  histograms.h_recodxy[count]->Fill(dxy);
2052  histograms.h_recodz[count]->Fill(dz);
2053  histograms.h_recochi2[count]->Fill(chi2);
2054  histograms.h_recochi2prob[count]->Fill(chi2prob);
2055  histograms.h_recovertpos[count]->Fill(vertxy);
2056  histograms.h_recozpos[count]->Fill(vertz);
2057  histograms.h_recodr[count]->Fill(dR);
2058  histograms.h_recodrj[count]->Fill(dRJet);
2059  if (dRJet <= 99999) //dRJet can be set to numeric_limits max^2, this is a protection
2060  histograms.chi2_vs_drj[count]->Fill(dRJet, chi2);
2061  if (fillSeedingLayerSets)
2062  histograms.h_reco_seedingLayerSet[count]->Fill(seedingLayerSetBin);
2063  if (pvPosition) {
2064  histograms.h_recodxypv[count]->Fill(dxypv);
2065  histograms.h_recodzpv[count]->Fill(dzpv);
2066  histograms.h_recodxypvzoomed[count]->Fill(dxypv);
2067  histograms.h_recodzpvzoomed[count]->Fill(dzpv);
2068 
2069  histograms.h_reco_dzpvcut[count]->Fill(std::abs(dzpv));
2070  histograms.h_reco_dzpvsigcut[count]->Fill(std::abs(dzpvsig));
2071  histograms.h_reco_dzpvcut_pt[count]->Fill(std::abs(dzpv), pt);
2072  histograms.h_reco_dzpvsigcut_pt[count]->Fill(std::abs(dzpvsig), pt);
2073  }
2074  if (simPVPosition) {
2075  histograms.h_reco_simpvz[count]->Fill(simpvz);
2076  }
2077  if ((*trackSelectorVsEta)(track, bsPosition)) {
2078  histograms.h_reco2eta[count]->Fill(eta);
2079  }
2080  if ((*trackSelectorVsPt)(track, bsPosition)) {
2081  histograms.h_reco2pT[count]->Fill(pt);
2082  histograms.h_reco2pTvseta[count]->Fill(eta, pt);
2083  }
2084  }
2085  histograms.h_recohit[count]->Fill(nhits);
2086  histograms.h_recolayer[count]->Fill(nlayers);
2087  histograms.h_recopixellayer[count]->Fill(nPixelLayers);
2088  histograms.h_reco3Dlayer[count]->Fill(n3DLayers);
2089  histograms.h_recopu[count]->Fill(numVertices);
2090  if ((*trackSelectorVsPhi)(track, bsPosition)) {
2091  histograms.h_reco2pu[count]->Fill(numVertices);
2092  }
2093 
2094  if (!mvas.empty()) {
2095  assert(histograms.h_reco_mva.size() > static_cast<size_t>(count));
2096  assert(histograms.h_reco_mvacut.size() > static_cast<size_t>(count));
2097  assert(histograms.h_reco_mva_hp.size() > static_cast<size_t>(count));
2098  assert(histograms.h_reco_mvacut_hp.size() > static_cast<size_t>(count));
2099 
2100  fillMVAHistos(histograms.h_reco_mva[count],
2101  histograms.h_reco_mvacut[count],
2102  histograms.h_reco_mva_hp[count],
2103  histograms.h_reco_mvacut_hp[count],
2104  mvas,
2105  selectsLoose,
2106  selectsHP);
2107  }
2108 
2109  if (isMatched) {
2110  if (paramsValid) {
2111  histograms.h_assoc2eta[count]->Fill(eta);
2112  histograms.h_assoc2phi[count]->Fill(phi);
2113  histograms.h_assoc2pT[count]->Fill(pt);
2114  histograms.h_assoc2pTvseta[count]->Fill(eta, pt);
2115  histograms.h_assoc2dxy[count]->Fill(dxy);
2116  histograms.h_assoc2dz[count]->Fill(dz);
2117  histograms.h_assoc2hit[count]->Fill(nhits);
2118  histograms.h_assoc2chi2[count]->Fill(chi2);
2119  histograms.h_assoc2chi2prob[count]->Fill(chi2prob);
2120  histograms.assoc_chi2_vs_eta[count]->Fill(eta, chi2);
2121  histograms.assoc_chi2prob_vs_eta[count]->Fill(eta, chi2prob);
2122  histograms.assoc_chi2_vs_pt[count]->Fill(pt, chi2);
2123  histograms.assoc_chi2prob_vs_pt[count]->Fill(pt, chi2prob);
2124  if (dRJet <= 99999) { //dRJet can be set to numeric_limits max^2, this is a protection
2125  histograms.assoc_chi2_vs_drj[count]->Fill(dRJet, chi2);
2126  histograms.assoc_chi2prob_vs_drj[count]->Fill(dRJet, chi2prob);
2127  }
2128  histograms.h_assoc2vertpos[count]->Fill(vertxy);
2129  histograms.h_assoc2zpos[count]->Fill(vertz);
2130  histograms.h_assoc2dr[count]->Fill(dR);
2131  histograms.h_assoc2drj[count]->Fill(dRJet);
2132  if (fillSeedingLayerSets)
2133  histograms.h_assoc2_seedingLayerSet[count]->Fill(seedingLayerSetBin);
2134  if (pvPosition) {
2135  histograms.h_assoc2dxypv[count]->Fill(dxypv);
2136  histograms.h_assoc2dzpv[count]->Fill(dzpv);
2137  histograms.h_assoc2dxypvzoomed[count]->Fill(dxypv);
2138  histograms.h_assoc2dzpvzoomed[count]->Fill(dzpv);
2139 
2140  histograms.h_assoc2_dzpvcut[count]->Fill(std::abs(dzpv));
2141  histograms.h_assoc2_dzpvsigcut[count]->Fill(std::abs(dzpvsig));
2142  histograms.h_assoc2_dzpvcut_pt[count]->Fill(std::abs(dzpv), pt);
2143  histograms.h_assoc2_dzpvsigcut_pt[count]->Fill(std::abs(dzpvsig), pt);
2144  }
2145  if (simPVPosition) {
2146  histograms.h_assoc2_simpvz[count]->Fill(simpvz);
2147  }
2148  }
2149  histograms.h_assoc2layer[count]->Fill(nlayers);
2150  histograms.h_assoc2pixellayer[count]->Fill(nPixelLayers);
2151  histograms.h_assoc23Dlayer[count]->Fill(n3DLayers);
2152  histograms.h_assoc2pu[count]->Fill(numVertices);
2153 
2154  if (!mvas.empty()) {
2155  assert(histograms.h_reco_mva.size() > static_cast<size_t>(count));
2156  assert(histograms.h_reco_mvacut.size() > static_cast<size_t>(count));
2157  assert(histograms.h_reco_mva_hp.size() > static_cast<size_t>(count));
2158  assert(histograms.h_reco_mvacut_hp.size() > static_cast<size_t>(count));
2159  fillMVAHistos(histograms.h_assoc2_mva[count],
2160  histograms.h_assoc2_mvacut[count],
2161  histograms.h_assoc2_mva_hp[count],
2162  histograms.h_assoc2_mvacut_hp[count],
2163  mvas,
2164  selectsLoose,
2165  selectsHP);
2166  assert(histograms.h_assoc2_mva_vs_pt.size() > static_cast<size_t>(count));
2167  assert(histograms.h_assoc2_mva_vs_pt_hp.size() > static_cast<size_t>(count));
2168  fillMVAHistos(pt,
2169  histograms.h_assoc2_mva_vs_pt[count],
2170  histograms.h_assoc2_mva_vs_pt_hp[count],
2171  mvas,
2172  selectsLoose,
2173  selectsHP);
2174  assert(histograms.h_assoc2_mva_vs_eta.size() > static_cast<size_t>(count));
2175  assert(histograms.h_assoc2_mva_vs_eta_hp.size() > static_cast<size_t>(count));
2176  fillMVAHistos(eta,
2177  histograms.h_assoc2_mva_vs_eta[count],
2178  histograms.h_assoc2_mva_vs_eta_hp[count],
2179  mvas,
2180  selectsLoose,
2181  selectsHP);
2182  }
2183 
2184  if (histograms.nrecHit_vs_nsimHit_rec2sim[count])
2185  histograms.nrecHit_vs_nsimHit_rec2sim[count]->Fill(track.numberOfValidHits(), nSimHits);
2186  histograms.h_assocFraction[count]->Fill(sharedFraction);
2187  histograms.h_assocSharedHit[count]->Fill(sharedHits);
2188 
2189  if (!doSeedPlots_ && !isChargeMatched) {
2190  histograms.h_misideta[count]->Fill(eta);
2191  histograms.h_misidphi[count]->Fill(phi);
2192  histograms.h_misidpT[count]->Fill(pt);
2193  histograms.h_misidpTvseta[count]->Fill(eta, pt);
2194  histograms.h_misiddxy[count]->Fill(dxy);
2195  histograms.h_misiddz[count]->Fill(dz);
2196  histograms.h_misidhit[count]->Fill(nhits);
2197  histograms.h_misidlayer[count]->Fill(nlayers);
2198  histograms.h_misidpixellayer[count]->Fill(nPixelLayers);
2199  histograms.h_misid3Dlayer[count]->Fill(n3DLayers);
2200  histograms.h_misidpu[count]->Fill(numVertices);
2201  histograms.h_misidchi2[count]->Fill(chi2);
2202  histograms.h_misidchi2prob[count]->Fill(chi2prob);
2203  if (pvPosition) {
2204  histograms.h_misiddxypv[count]->Fill(dxypv);
2205  histograms.h_misiddzpv[count]->Fill(dzpv);
2206  histograms.h_misiddxypvzoomed[count]->Fill(dxypv);
2207  histograms.h_misiddzpvzoomed[count]->Fill(dzpv);
2208  }
2209  }
2210 
2211  if (numAssocRecoTracks > 1) {
2212  if (paramsValid) {
2213  histograms.h_loopereta[count]->Fill(eta);
2214  histograms.h_looperphi[count]->Fill(phi);
2215  histograms.h_looperpT[count]->Fill(pt);
2216  histograms.h_looperpTvseta[count]->Fill(eta, pt);
2217  histograms.h_looperdxy[count]->Fill(dxy);
2218  histograms.h_looperdz[count]->Fill(dz);
2219  histograms.h_looperchi2[count]->Fill(chi2);
2220  histograms.h_looperchi2prob[count]->Fill(chi2prob);
2221  histograms.h_loopervertpos[count]->Fill(vertxy);
2222  histograms.h_looperzpos[count]->Fill(vertz);
2223  histograms.h_looperdr[count]->Fill(dR);
2224  histograms.h_looperdrj[count]->Fill(dRJet);
2225  if (fillSeedingLayerSets)
2226  histograms.h_looper_seedingLayerSet[count]->Fill(seedingLayerSetBin);
2227  if (pvPosition) {
2228  histograms.h_looperdxypv[count]->Fill(dxypv);
2229  histograms.h_looperdzpv[count]->Fill(dzpv);
2230  histograms.h_looperdxypvzoomed[count]->Fill(dxypv);
2231  histograms.h_looperdzpvzoomed[count]->Fill(dzpv);
2232  }
2233  if (simPVPosition) {
2234  histograms.h_looper_simpvz[count]->Fill(simpvz);
2235  }
2236  }
2237  histograms.h_looperhit[count]->Fill(nhits);
2238  histograms.h_looperlayer[count]->Fill(nlayers);
2239  histograms.h_looperpixellayer[count]->Fill(nPixelLayers);
2240  histograms.h_looper3Dlayer[count]->Fill(n3DLayers);
2241  histograms.h_looperpu[count]->Fill(numVertices);
2242  }
2243  if (!isSigMatched) {
2244  if (paramsValid) {
2245  histograms.h_pileupeta[count]->Fill(eta);
2246  histograms.h_pileupphi[count]->Fill(phi);
2247  histograms.h_pileuppT[count]->Fill(pt);
2248  histograms.h_pileuppTvseta[count]->Fill(eta, pt);
2249  histograms.h_pileupdxy[count]->Fill(dxy);
2250  histograms.h_pileupdz[count]->Fill(dz);
2251  histograms.h_pileupchi2[count]->Fill(chi2);
2252  histograms.h_pileupchi2prob[count]->Fill(chi2prob);
2253  histograms.h_pileupvertpos[count]->Fill(vertxy);
2254  histograms.h_pileupzpos[count]->Fill(vertz);
2255  histograms.h_pileupdr[count]->Fill(dR);
2256  histograms.h_pileupdrj[count]->Fill(dRJet);
2257  if (fillSeedingLayerSets)
2258  histograms.h_pileup_seedingLayerSet[count]->Fill(seedingLayerSetBin);
2259  if (pvPosition) {
2260  histograms.h_pileupdxypv[count]->Fill(dxypv);
2261  histograms.h_pileupdzpv[count]->Fill(dzpv);
2262  histograms.h_pileupdxypvzoomed[count]->Fill(dxypv);
2263  histograms.h_pileupdzpvzoomed[count]->Fill(dzpv);
2264 
2265  histograms.h_pileup_dzpvcut[count]->Fill(std::abs(dzpv));
2266  histograms.h_pileup_dzpvsigcut[count]->Fill(std::abs(dzpvsig));
2267  histograms.h_pileup_dzpvcut_pt[count]->Fill(std::abs(dzpv), pt);
2268  histograms.h_pileup_dzpvsigcut_pt[count]->Fill(std::abs(dzpvsig), pt);
2269  }
2270  if (simPVPosition) {
2271  histograms.h_pileup_simpvz[count]->Fill(simpvz);
2272  }
2273  }
2274  histograms.h_pileuphit[count]->Fill(nhits);
2275  histograms.h_pileuplayer[count]->Fill(nlayers);
2276  histograms.h_pileuppixellayer[count]->Fill(nPixelLayers);
2277  histograms.h_pileup3Dlayer[count]->Fill(n3DLayers);
2278  histograms.h_pileuppu[count]->Fill(numVertices);
2279  }
2280  } else { // !isMatched
2281  if (!mvas.empty()) {
2282  assert(histograms.h_fake_mva_vs_pt.size() > static_cast<size_t>(count));
2283  assert(histograms.h_fake_mva_vs_pt_hp.size() > static_cast<size_t>(count));
2284  assert(histograms.h_fake_mva_vs_eta.size() > static_cast<size_t>(count));
2285  assert(histograms.h_fake_mva_vs_eta_hp.size() > static_cast<size_t>(count));
2286  fillMVAHistos(
2287  pt, histograms.h_fake_mva_vs_pt[count], histograms.h_fake_mva_vs_pt_hp[count], mvas, selectsLoose, selectsHP);
2288  fillMVAHistos(eta,
2289  histograms.h_fake_mva_vs_eta[count],
2290  histograms.h_fake_mva_vs_eta_hp[count],
2291  mvas,
2292  selectsLoose,
2293  selectsHP);
2294  }
2295  }
2296 }
2297 
2299  int count,
2300  const reco::Track& track) const {
2301  //nchi2 and hits global distributions
2302  histograms.h_hits[count]->Fill(track.numberOfValidHits());
2303  histograms.h_losthits[count]->Fill(track.numberOfLostHits());
2304  histograms.h_nmisslayers_inner[count]->Fill(
2305  track.hitPattern().numberOfLostHits(reco::HitPattern::MISSING_INNER_HITS));
2306  histograms.h_nmisslayers_outer[count]->Fill(
2307  track.hitPattern().numberOfLostHits(reco::HitPattern::MISSING_OUTER_HITS));
2309  return;
2310 
2311  histograms.h_nchi2[count]->Fill(track.normalizedChi2());
2312  histograms.h_nchi2_prob[count]->Fill(TMath::Prob(track.chi2(), (int)track.ndof()));
2313  histograms.chi2_vs_nhits[count]->Fill(track.numberOfValidHits(), track.normalizedChi2());
2314  histograms.h_charge[count]->Fill(track.charge());
2315 
2316  //chi2 and #hit vs eta: fill 2D histos
2317  const auto eta = getEta(track.eta());
2318  histograms.chi2_vs_eta[count]->Fill(eta, track.normalizedChi2());
2319  histograms.nhits_vs_eta[count]->Fill(eta, track.numberOfValidHits());
2320  const auto pt = getPt(sqrt(track.momentum().perp2()));
2321  histograms.chi2_vs_pt[count]->Fill(pt, track.normalizedChi2());
2322  const auto pxbHits = track.hitPattern().numberOfValidPixelBarrelHits();
2323  const auto pxfHits = track.hitPattern().numberOfValidPixelEndcapHits();
2324  const auto tibHits = track.hitPattern().numberOfValidStripTIBHits();
2325  const auto tidHits = track.hitPattern().numberOfValidStripTIDHits();
2326  const auto tobHits = track.hitPattern().numberOfValidStripTOBHits();
2327  const auto tecHits = track.hitPattern().numberOfValidStripTECHits();
2328  histograms.nPXBhits_vs_eta[count]->Fill(eta, pxbHits);
2329  histograms.nPXFhits_vs_eta[count]->Fill(eta, pxfHits);
2330  histograms.nPXLhits_vs_eta[count]->Fill(eta, pxbHits + pxfHits);
2331  histograms.nTIBhits_vs_eta[count]->Fill(eta, tibHits);
2332  histograms.nTIDhits_vs_eta[count]->Fill(eta, tidHits);
2333  histograms.nTOBhits_vs_eta[count]->Fill(eta, tobHits);
2334  histograms.nTEChits_vs_eta[count]->Fill(eta, tecHits);
2335  histograms.nSTRIPhits_vs_eta[count]->Fill(eta, tibHits + tidHits + tobHits + tecHits);
2336  histograms.nLayersWithMeas_vs_eta[count]->Fill(eta, track.hitPattern().trackerLayersWithMeasurement());
2337  histograms.nPXLlayersWithMeas_vs_eta[count]->Fill(eta, track.hitPattern().pixelLayersWithMeasurement());
2338  if (doMTDPlots_) {
2339  // const auto mtdHits = track.hitPattern().numberOfValidTimingHits();
2340  const auto btlHits = track.hitPattern().numberOfValidTimingBTLHits();
2341  const auto etlHits = track.hitPattern().numberOfValidTimingETLHits();
2342  histograms.nMTDhits_vs_eta[count]->Fill(eta, btlHits + etlHits);
2343  histograms.nBTLhits_vs_eta[count]->Fill(eta, btlHits);
2344  histograms.nETLhits_vs_eta[count]->Fill(eta, etlHits);
2345  }
2346  int LayersAll = track.hitPattern().stripLayersWithMeasurement();
2347  int Layers2D = track.hitPattern().numberOfValidStripLayersWithMonoAndStereo();
2348  int Layers1D = LayersAll - Layers2D;
2349  histograms.nSTRIPlayersWithMeas_vs_eta[count]->Fill(eta, LayersAll);
2350  histograms.nSTRIPlayersWith1dMeas_vs_eta[count]->Fill(eta, Layers1D);
2351  histograms.nSTRIPlayersWith2dMeas_vs_eta[count]->Fill(eta, Layers2D);
2352 
2353  histograms.nlosthits_vs_eta[count]->Fill(eta, track.numberOfLostHits());
2354 }
2355 
2357  int count,
2358  int assTracks,
2359  int numRecoTracks,
2360  int numRecoTracksSelected,
2361  int numSimTracksSelected) const {
2362  histograms.h_tracks[count]->Fill(assTracks);
2363  histograms.h_fakes[count]->Fill(numRecoTracks - assTracks);
2364  if (histograms.nrec_vs_nsim[count])
2365  histograms.nrec_vs_nsim[count]->Fill(numSimTracksSelected, numRecoTracksSelected);
2366 }
2367 
2369  int count,
2370  const TrackingParticle::Vector& momentumTP,
2371  const TrackingParticle::Point& vertexTP,
2372  int chargeTP,
2373  const reco::Track& track,
2374  const math::XYZPoint& bsPosition) const {
2376  return;
2377 
2378  // evaluation of TP parameters
2379  double qoverpSim = chargeTP / sqrt(momentumTP.x() * momentumTP.x() + momentumTP.y() * momentumTP.y() +
2380  momentumTP.z() * momentumTP.z());
2381  double lambdaSim = M_PI / 2 - momentumTP.theta();
2382  double phiSim = momentumTP.phi();
2383  double dxySim = TrackingParticleIP::dxy(vertexTP, momentumTP, bsPosition);
2384  double dzSim = TrackingParticleIP::dz(vertexTP, momentumTP, bsPosition);
2385 
2386  // reco::Track::ParameterVector rParameters = track.parameters(); // UNUSED
2387 
2388  double qoverpRec(0);
2389  double qoverpErrorRec(0);
2390  double ptRec(0);
2391  double ptErrorRec(0);
2392  double lambdaRec(0);
2393  double lambdaErrorRec(0);
2394  double phiRec(0);
2395  double phiErrorRec(0);
2396 
2397  /* TO BE FIXED LATER -----------
2398  //loop to decide whether to take gsfTrack (utilisation of mode-function) or common track
2399  const GsfTrack* gsfTrack(0);
2400  if(useGsf){
2401  gsfTrack = dynamic_cast<const GsfTrack*>(&(*track));
2402  if (gsfTrack==0) edm::LogInfo("TrackValidator") << "Trying to access mode for a non-GsfTrack";
2403  }
2404 
2405  if (gsfTrack) {
2406  // get values from mode
2407  getRecoMomentum(*gsfTrack, ptRec, ptErrorRec, qoverpRec, qoverpErrorRec,
2408  lambdaRec,lambdaErrorRec, phiRec, phiErrorRec);
2409  }
2410 
2411  else {
2412  // get values from track (without mode)
2413  getRecoMomentum(*track, ptRec, ptErrorRec, qoverpRec, qoverpErrorRec,
2414  lambdaRec,lambdaErrorRec, phiRec, phiErrorRec);
2415  }
2416  */
2417  getRecoMomentum(track, ptRec, ptErrorRec, qoverpRec, qoverpErrorRec, lambdaRec, lambdaErrorRec, phiRec, phiErrorRec);
2418  // -------------
2419 
2420  double ptError = ptErrorRec;
2421  double ptres = ptRec - sqrt(momentumTP.perp2());
2422  double etares = track.eta() - momentumTP.Eta();
2423 
2424  double dxyRec = track.dxy(bsPosition);
2425  double dzRec = track.dz(bsPosition);
2426 
2427  const auto phiRes = phiRec - phiSim;
2428  const auto dxyRes = dxyRec - dxySim;
2429  const auto dzRes = dzRec - dzSim;
2430  const auto cotThetaRes = 1 / tan(M_PI * 0.5 - lambdaRec) - 1 / tan(M_PI * 0.5 - lambdaSim);
2431 
2432  // eta residue; pt, k, theta, phi, dxy, dz pulls
2433  double qoverpPull = (qoverpRec - qoverpSim) / qoverpErrorRec;
2434  double thetaPull = (lambdaRec - lambdaSim) / lambdaErrorRec;
2435  double phiPull = phiRes / phiErrorRec;
2436  double dxyPull = dxyRes / track.dxyError();
2437  double dzPull = dzRes / track.dzError();
2438 
2439 #ifdef EDM_ML_DEBUG
2440  double contrib_Qoverp = ((qoverpRec - qoverpSim) / qoverpErrorRec) * ((qoverpRec - qoverpSim) / qoverpErrorRec) / 5;
2441  double contrib_dxy = ((dxyRec - dxySim) / track.dxyError()) * ((dxyRec - dxySim) / track.dxyError()) / 5;
2442  double contrib_dz = ((dzRec - dzSim) / track.dzError()) * ((dzRec - dzSim) / track.dzError()) / 5;
2443  double contrib_theta = ((lambdaRec - lambdaSim) / lambdaErrorRec) * ((lambdaRec - lambdaSim) / lambdaErrorRec) / 5;
2444  double contrib_phi = ((phiRec - phiSim) / phiErrorRec) * ((phiRec - phiSim) / phiErrorRec) / 5;
2445 
2446  LogTrace("TrackValidatorTEST")
2447  //<< "assocChi2=" << tp.begin()->second << "\n"
2448  << ""
2449  << "\n"
2450  << "ptREC=" << ptRec << "\n"
2451  << "etaREC=" << track.eta() << "\n"
2452  << "qoverpREC=" << qoverpRec << "\n"
2453  << "dxyREC=" << dxyRec << "\n"
2454  << "dzREC=" << dzRec << "\n"
2455  << "thetaREC=" << track.theta() << "\n"
2456  << "phiREC=" << phiRec << "\n"
2457  << ""
2458  << "\n"
2459  << "qoverpError()=" << qoverpErrorRec << "\n"
2460  << "dxyError()=" << track.dxyError() << "\n"
2461  << "dzError()=" << track.dzError() << "\n"
2462  << "thetaError()=" << lambdaErrorRec << "\n"
2463  << "phiError()=" << phiErrorRec << "\n"
2464  << ""
2465  << "\n"
2466  << "ptSIM=" << sqrt(momentumTP.perp2()) << "\n"
2467  << "etaSIM=" << momentumTP.Eta() << "\n"
2468  << "qoverpSIM=" << qoverpSim << "\n"
2469  << "dxySIM=" << dxySim << "\n"
2470  << "dzSIM=" << dzSim << "\n"
2471  << "thetaSIM=" << M_PI / 2 - lambdaSim << "\n"
2472  << "phiSIM=" << phiSim << "\n"
2473  << ""
2474  << "\n"
2475  << "contrib_Qoverp=" << contrib_Qoverp << "\n"
2476  << "contrib_dxy=" << contrib_dxy << "\n"
2477  << "contrib_dz=" << contrib_dz << "\n"
2478  << "contrib_theta=" << contrib_theta << "\n"
2479  << "contrib_phi=" << contrib_phi << "\n"
2480  << ""
2481  << "\n"
2482  << "chi2PULL=" << contrib_Qoverp + contrib_dxy + contrib_dz + contrib_theta + contrib_phi << "\n";
2483 #endif
2484 
2485  histograms.h_pullQoverp[count]->Fill(qoverpPull);
2486  histograms.h_pullTheta[count]->Fill(thetaPull);
2487  histograms.h_pullPhi[count]->Fill(phiPull);
2488  histograms.h_pullDxy[count]->Fill(dxyPull);
2489  histograms.h_pullDz[count]->Fill(dzPull);
2490 
2491  const auto etaSim = getEta(momentumTP.eta());
2492  const auto ptSim = getPt(sqrt(momentumTP.perp2()));
2493 
2494  histograms.h_pt[count]->Fill(ptres / ptError);
2495  histograms.h_eta[count]->Fill(etares);
2496  //histograms.etares_vs_eta[count]->Fill(getEta(track.eta()),etares);
2497  histograms.etares_vs_eta[count]->Fill(etaSim, etares);
2498 
2499  //resolution of track params: fill 2D histos
2500  histograms.dxyres_vs_eta[count]->Fill(etaSim, dxyRes);
2501  histograms.ptres_vs_eta[count]->Fill(etaSim, ptres / ptRec);
2502  histograms.dzres_vs_eta[count]->Fill(etaSim, dzRes);
2503  histograms.phires_vs_eta[count]->Fill(etaSim, phiRes);
2504  histograms.cotThetares_vs_eta[count]->Fill(etaSim, cotThetaRes);
2505 
2506  //same as before but vs pT
2507  histograms.dxyres_vs_pt[count]->Fill(ptSim, dxyRes);
2508  histograms.ptres_vs_pt[count]->Fill(ptSim, ptres / ptRec);
2509  histograms.dzres_vs_pt[count]->Fill(ptSim, dzRes);
2510  histograms.phires_vs_pt[count]->Fill(ptSim, phiRes);
2511  histograms.cotThetares_vs_pt[count]->Fill(ptSim, cotThetaRes);
2512 
2513  //pulls of track params vs eta: fill 2D histos
2514  histograms.dxypull_vs_eta[count]->Fill(etaSim, dxyPull);
2515  histograms.ptpull_vs_eta[count]->Fill(etaSim, ptres / ptError);
2516  histograms.dzpull_vs_eta[count]->Fill(etaSim, dzPull);
2517  histograms.phipull_vs_eta[count]->Fill(etaSim, phiPull);
2518  histograms.thetapull_vs_eta[count]->Fill(etaSim, thetaPull);
2519 
2520  //pulls of track params vs pt: fill 2D histos
2521  histograms.dxypull_vs_pt[count]->Fill(ptSim, dxyPull);
2522  histograms.ptpull_vs_pt[count]->Fill(ptSim, ptres / ptError);
2523  histograms.dzpull_vs_pt[count]->Fill(ptSim, dzPull);
2524  histograms.phipull_vs_pt[count]->Fill(ptSim, phiPull);
2525  histograms.thetapull_vs_pt[count]->Fill(ptSim, thetaPull);
2526 
2527  //plots vs phi
2528  histograms.nhits_vs_phi[count]->Fill(phiRec, track.numberOfValidHits());
2529  histograms.chi2_vs_phi[count]->Fill(phiRec, track.normalizedChi2());
2530  histograms.ptmean_vs_eta_phi[count]->Fill(phiRec, getEta(track.eta()), ptRec);
2531  histograms.phimean_vs_eta_phi[count]->Fill(phiRec, getEta(track.eta()), phiRec);
2532 
2533  histograms.dxyres_vs_phi[count]->Fill(phiSim, dxyRes);
2534  histograms.ptres_vs_phi[count]->Fill(phiSim, ptres / ptRec);
2535  histograms.dzres_vs_phi[count]->Fill(phiSim, dzRes);
2536  histograms.phires_vs_phi[count]->Fill(phiSim, phiRes);
2537 
2538  histograms.ptpull_vs_phi[count]->Fill(phiSim, ptres / ptError);
2539  histograms.phipull_vs_phi[count]->Fill(phiSim, phiPull);
2540  histograms.thetapull_vs_phi[count]->Fill(phiSim, thetaPull);
2541 }
2542 
2544  double& pt,
2545  double& ptError,
2546  double& qoverp,
2547  double& qoverpError,
2548  double& lambda,
2549  double& lambdaError,
2550  double& phi,
2551  double& phiError) const {
2552  pt = track.pt();
2553  ptError = track.ptError();
2554  qoverp = track.qoverp();
2555  qoverpError = track.qoverpError();
2556  lambda = track.lambda();
2557  lambdaError = track.lambdaError();
2558  phi = track.phi();
2559  phiError = track.phiError();
2560  // cout <<"test1" << endl;
2561 }
2562 
2564  double& pt,
2565  double& ptError,
2566  double& qoverp,
2567  double& qoverpError,
2568  double& lambda,
2569  double& lambdaError,
2570  double& phi,
2571  double& phiError) const {
2572  pt = gsfTrack.ptMode();
2573  ptError = gsfTrack.ptModeError();
2574  qoverp = gsfTrack.qoverpMode();
2575  qoverpError = gsfTrack.qoverpModeError();
2576  lambda = gsfTrack.lambdaMode();
2577  lambdaError = gsfTrack.lambdaModeError();
2578  phi = gsfTrack.phiMode();
2579  phiError = gsfTrack.phiModeError();
2580  // cout <<"test2" << endl;
2581 }
2582 
2584  if (useFabsEta)
2585  return fabs(eta);
2586  else
2587  return eta;
2588 }
2589 
2591  if (useInvPt && pt != 0)
2592  return 1 / pt;
2593  else
2594  return pt;
2595 }
2596 
2598  const TrackerTopology& ttopo) const {
2599  if (track.seedRef().isNull() || !track.seedRef().isAvailable())
2600  return seedingLayerSetNames.size() - 1;
2601 
2602  const TrajectorySeed& seed = *(track.seedRef());
2603  SeedingLayerSetId searchId;
2604  const int nhits = seed.nHits();
2605  if (nhits > static_cast<int>(std::tuple_size<SeedingLayerSetId>::value)) {
2606  LogDebug("TrackValidator") << "Got seed with " << nhits << " hits, but I have a hard-coded maximum of "
2608  << ", classifying the seed as 'unknown'. Please increase the maximum in "
2609  "MTVHistoProducerAlgoForTracker.h if needed.";
2610  return seedingLayerSetNames.size() - 1;
2611  }
2612  int i = 0;
2613  for (auto const& recHit : seed.recHits()) {
2614  DetId detId = recHit.geographicalId();
2615 
2616  if (detId.det() != DetId::Tracker) {
2617  throw cms::Exception("LogicError") << "Encountered seed hit detId " << detId.rawId() << " not from Tracker, but "
2618  << detId.det();
2619  }
2620 
2622  bool subdetStrip = false;
2623  switch (detId.subdetId()) {
2626  break;
2629  break;
2630  case StripSubdetector::TIB:
2631  subdet = GeomDetEnumerators::TIB;
2632  subdetStrip = true;
2633  break;
2634  case StripSubdetector::TID:
2635  subdet = GeomDetEnumerators::TID;
2636  subdetStrip = true;
2637  break;
2638  case StripSubdetector::TOB:
2639  subdet = GeomDetEnumerators::TOB;
2640  subdetStrip = true;
2641  break;
2642  case StripSubdetector::TEC:
2643  subdet = GeomDetEnumerators::TEC;
2644  subdetStrip = true;
2645  break;
2646  default:
2647  throw cms::Exception("LogicError") << "Unknown subdetId " << detId.subdetId();
2648  };
2649 
2650  TrackerDetSide side = static_cast<TrackerDetSide>(ttopo.side(detId));
2651 
2652  // Even with the recent addition of
2653  // SeedingLayerSetsBuilder::fillDescription() this assumption is a
2654  // bit ugly.
2655  const bool isStripMono = subdetStrip && trackerHitRTTI::isSingle(recHit);
2656  searchId[i] =
2657  SeedingLayerId(SeedingLayerSetsBuilder::SeedingLayerId(subdet, side, ttopo.layer(detId)), isStripMono);
2658  ++i;
2659  }
2660  auto found = seedingLayerSetToBin.find(searchId);
2661  if (found == seedingLayerSetToBin.end()) {
2662  return seedingLayerSetNames.size() - 1;
2663  }
2664  return found->second;
2665 }
2666 
2668  int count,
2669  const reco::GenParticle& tp,
2670  const TrackingParticle::Vector& momentumTP,
2671  const TrackingParticle::Point& vertexTP,
2672  double dxySim,
2673  double dzSim,
2674  int nSimHits,
2675  const reco::Track* track,
2676  int numVertices) const {
2677  bool isMatched = track;
2678 
2679  if ((*GpSelectorForEfficiencyVsEta)(tp)) {
2680  //effic vs eta
2681  histograms.h_simuleta[count]->Fill(getEta(momentumTP.eta()));
2682  if (isMatched)
2683  histograms.h_assoceta[count]->Fill(getEta(momentumTP.eta()));
2684  }
2685 
2686  if ((*GpSelectorForEfficiencyVsPhi)(tp)) {
2687  histograms.h_simulphi[count]->Fill(momentumTP.phi());
2688  if (isMatched)
2689  histograms.h_assocphi[count]->Fill(momentumTP.phi());
2690  //effic vs hits
2691  histograms.h_simulhit[count]->Fill((int)nSimHits);
2692  if (isMatched) {
2693  histograms.h_assochit[count]->Fill((int)nSimHits);
2694  if (histograms.nrecHit_vs_nsimHit_sim2rec[count])
2695  histograms.nrecHit_vs_nsimHit_sim2rec[count]->Fill(track->numberOfValidHits(), nSimHits);
2696  }
2697  //effic vs pu
2698  histograms.h_simulpu[count]->Fill(numVertices);
2699  if (isMatched)
2700  histograms.h_assocpu[count]->Fill(numVertices);
2701  //efficiency vs dR
2702  //not implemented for now
2703  }
2704 
2705  if ((*GpSelectorForEfficiencyVsPt)(tp)) {
2706  histograms.h_simulpT[count]->Fill(getPt(sqrt(momentumTP.perp2())));
2707  histograms.h_simulpTvseta[count]->Fill(getEta(momentumTP.eta()), getPt(sqrt(momentumTP.perp2())));
2708  if (isMatched) {
2709  histograms.h_assocpT[count]->Fill(getPt(sqrt(momentumTP.perp2())));
2710  histograms.h_assocpTvseta[count]->Fill(getEta(momentumTP.eta()), getPt(sqrt(momentumTP.perp2())));
2711  }
2712  }
2713 
2715  histograms.h_simuldxy[count]->Fill(dxySim);
2716  if (isMatched)
2717  histograms.h_assocdxy[count]->Fill(dxySim);
2718 
2719  histograms.h_simulvertpos[count]->Fill(sqrt(vertexTP.perp2()));
2720  if (isMatched)
2721  histograms.h_assocvertpos[count]->Fill(sqrt(vertexTP.perp2()));
2722  }
2723 
2725  histograms.h_simuldz[count]->Fill(dzSim);
2726  if (isMatched)
2727  histograms.h_assocdz[count]->Fill(dzSim);
2728 
2729  histograms.h_simulzpos[count]->Fill(vertexTP.z());
2730  if (isMatched)
2731  histograms.h_assoczpos[count]->Fill(vertexTP.z());
2732  }
2733 }
2734 
2736  int count,
2737  int seedsFitFailed,
2738  int seedsTotal) const {
2739  histograms.h_seedsFitFailed[count]->Fill(seedsFitFailed);
2740  histograms.h_seedsFitFailedFraction[count]->Fill(static_cast<double>(seedsFitFailed) / seedsTotal);
2741 }
MTVHistoProducerAlgoForTracker::trackSelectorVsEta
std::unique_ptr< RecoTrackSelectorBase > trackSelectorVsEta
Definition: MTVHistoProducerAlgoForTracker.h:291
reco::GsfTrack::ptMode
double ptMode() const
track transverse momentum from mode
Definition: GsfTrack.h:47
MTVHistoProducerAlgoForTracker::maxPt
double maxPt
Definition: MTVHistoProducerAlgoForTracker.h:305
SummaryClient_cfi.labels
labels
Definition: SummaryClient_cfi.py:61
writedatasetfile.args
args
Definition: writedatasetfile.py:18
GeomDetEnumerators::SubDetector
SubDetector
Definition: GeomDetEnumerators.h:10
reco::HitPattern::MISSING_OUTER_HITS
Definition: HitPattern.h:155
MTVHistoProducerAlgoForTracker::bookRecoPVAssociationHistos
void bookRecoPVAssociationHistos(DQMStore::IBooker &ibook, Histograms &histograms)
Definition: MTVHistoProducerAlgoForTracker.cc:1451
dqm::impl::MonitorElement
Definition: MonitorElement.h:98
reco::GsfTrack::lambdaModeError
double lambdaModeError() const
error on lambda from mode
Definition: GsfTrack.h:92
MTVHistoProducerAlgoForTracker::maxHit
double maxHit
Definition: MTVHistoProducerAlgoForTracker.h:309
TrackerTopology::side
unsigned int side(const DetId &id) const
Definition: TrackerTopology.cc:28
reco::GsfTrack::phiModeError
double phiModeError() const
error on phi from mode
Definition: GsfTrack.h:96
ApeEstimator_cff.width
width
Definition: ApeEstimator_cff.py:24
MTVHistoProducerAlgoForTracker::nintTracks
int nintTracks
Definition: MTVHistoProducerAlgoForTracker.h:338
MTVHistoProducerAlgoForTracker::useInvPt
bool useInvPt
Definition: MTVHistoProducerAlgoForTracker.h:307
MTVHistoProducerAlgoForTracker::maxTracks
double maxTracks
Definition: MTVHistoProducerAlgoForTracker.h:337
electrons_cff.bool
bool
Definition: electrons_cff.py:393
mps_fire.i
i
Definition: mps_fire.py:428
MTVHistoProducerAlgoForTracker::minPu
double minPu
Definition: MTVHistoProducerAlgoForTracker.h:311
MTVHistoProducerAlgoForTracker::fill_duplicate_histos
void fill_duplicate_histos(const Histograms &histograms, int count, const reco::Track &track1, const reco::Track &track2) const
Definition: MTVHistoProducerAlgoForTracker.cc:1973
MTVHistoProducerAlgoForTracker::generalGpSelector
std::unique_ptr< GenParticleCustomSelector > generalGpSelector
Definition: MTVHistoProducerAlgoForTracker.h:295
HLT_FULL_cff.track
track
Definition: HLT_FULL_cff.py:11713
MTVHistoProducerAlgoForTracker::minDxy
double minDxy
Definition: MTVHistoProducerAlgoForTracker.h:317
reco::GsfTrack::qoverpMode
double qoverpMode() const
q/p from mode
Definition: GsfTrack.h:39
MessageLogger.h
MTVHistoProducerAlgoForTracker::getSeedingLayerSetBin
unsigned int getSeedingLayerSetBin(const reco::Track &track, const TrackerTopology &ttopo) const
Definition: MTVHistoProducerAlgoForTracker.cc:2597
PixelSubdetector::PixelEndcap
Definition: PixelSubdetector.h:11
MTVHistoProducerAlgoForTracker::minDz
double minDz
Definition: MTVHistoProducerAlgoForTracker.h:319
PixelSubdetector::PixelBarrel
Definition: PixelSubdetector.h:11
GeomDetEnumerators::TID
Definition: GeomDetEnumerators.h:15
DeDxData.h
MTVHistoProducerAlgoForTracker::phiRes_rangeMin
double phiRes_rangeMin
Definition: MTVHistoProducerAlgoForTracker.h:350
MTVHistoProducerAlgoForTracker::bookSeedHistos
void bookSeedHistos(DQMStore::IBooker &ibook, Histograms &histograms)
Definition: MTVHistoProducerAlgoForTracker.cc:1605
MTVHistoProducerAlgoForTracker::GpSelectorForEfficiencyVsEta
std::unique_ptr< GenParticleCustomSelector > GpSelectorForEfficiencyVsEta
Definition: MTVHistoProducerAlgoForTracker.h:296
trackerHitRTTI::isSingle
bool isSingle(TrackingRecHit const &hit)
Definition: trackerHitRTTI.h:26
reco::GenParticle
Definition: GenParticle.h:21
DiDispStaMuonMonitor_cfi.pt
pt
Definition: DiDispStaMuonMonitor_cfi.py:39
MTVHistoProducerAlgoForTracker::TpSelectorForEfficiencyVsVTXR
std::unique_ptr< TrackingParticleSelector > TpSelectorForEfficiencyVsVTXR
Definition: MTVHistoProducerAlgoForTracker.h:288
MTVHistoProducerAlgoForTracker::nintDeDx
int nintDeDx
Definition: MTVHistoProducerAlgoForTracker.h:334
MTVHistoProducerAlgoForTracker::useFabsEta
bool useFabsEta
Definition: MTVHistoProducerAlgoForTracker.h:304
CalibrationSummaryClient_cfi.params
params
Definition: CalibrationSummaryClient_cfi.py:14
MTVHistoProducerAlgoForTracker::useLogPt
bool useLogPt
Definition: MTVHistoProducerAlgoForTracker.h:308
MTVHistoProducerAlgoForTracker::GpSelectorForEfficiencyVsPt
std::unique_ptr< GenParticleCustomSelector > GpSelectorForEfficiencyVsPt
Definition: MTVHistoProducerAlgoForTracker.h:298
MTVHistoProducerAlgoForTracker::GpSelectorForEfficiencyVsVTXZ
std::unique_ptr< GenParticleCustomSelector > GpSelectorForEfficiencyVsVTXZ
Definition: MTVHistoProducerAlgoForTracker.h:300
edm
HLT enums.
Definition: AlignableModifier.h:19
TrackerTopology
Definition: TrackerTopology.h:16
dqm::implementation::IBooker::bookProfile2D
MonitorElement * bookProfile2D(TString const &name, TString const &title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, double lowZ, double highZ, char const *option="s", FUNC onbooking=NOOP())
Definition: DQMStore.h:399
DetId::det
constexpr Detector det() const
get the detector field from this detid
Definition: DetId.h:46
reco::GsfTrack::lambdaMode
double lambdaMode() const
Lambda angle from mode.
Definition: GsfTrack.h:43
GeomDetEnumerators::TIB
Definition: GeomDetEnumerators.h:13
MTVHistoProducerAlgoForTracker::maxMVA
double maxMVA
Definition: MTVHistoProducerAlgoForTracker.h:341
MTVHistoProducerAlgoForTracker::maxDeDx
double maxDeDx
Definition: MTVHistoProducerAlgoForTracker.h:333
l1GtPatternGenerator_cfi.bx
bx
Definition: l1GtPatternGenerator_cfi.py:18
MTVHistoProducerAlgoForTracker::fill_trackBased_histos
void fill_trackBased_histos(const Histograms &histograms, int count, int assTracks, int numRecoTracks, int numRecoTracksSelected, int numSimTracksSelected) const
Definition: MTVHistoProducerAlgoForTracker.cc:2356
MTVHistoProducerAlgoForTracker::maxLayers
double maxLayers
Definition: MTVHistoProducerAlgoForTracker.h:313
to
cms::cuda::assert
assert(be >=bs)
MTVHistoProducerAlgoForTracker::maxdr
double maxdr
Definition: MTVHistoProducerAlgoForTracker.h:327
TrackerTopology::layer
unsigned int layer(const DetId &id) const
Definition: TrackerTopology.cc:47
GeomDetEnumerators::TOB
Definition: GeomDetEnumerators.h:14
MTVHistoProducerAlgoForTracker::TpSelectorForEfficiencyVsEta
std::unique_ptr< TrackingParticleSelector > TpSelectorForEfficiencyVsEta
Definition: MTVHistoProducerAlgoForTracker.h:285
MTVHistoProducerAlgoForTracker::nintDzpvCum
int nintDzpvCum
Definition: MTVHistoProducerAlgoForTracker.h:360
MTVHistoProducerAlgoForTracker::trackSelectorVsPhi
std::unique_ptr< RecoTrackSelectorBase > trackSelectorVsPhi
Definition: MTVHistoProducerAlgoForTracker.h:292
MTVHistoProducerAlgoForTracker::fill_ResoAndPull_recoTrack_histos
void fill_ResoAndPull_recoTrack_histos(const Histograms &histograms, int count, const TrackingParticle::Vector &momentumTP, const TrackingParticle::Point &vertexTP, int chargeTP, const reco::Track &track, const math::XYZPoint &bsPosition) const
Definition: MTVHistoProducerAlgoForTracker.cc:2368
MTVHistoProducerAlgoForTracker::TpSelectorForEfficiencyVsPt
std::unique_ptr< TrackingParticleSelector > TpSelectorForEfficiencyVsPt
Definition: MTVHistoProducerAlgoForTracker.h:287
reco::TrackBase::originalAlgo
TrackAlgorithm originalAlgo() const
Definition: TrackBase.h:548
MTVHistoProducerAlgoForTracker::maxChi2
double maxChi2
Definition: MTVHistoProducerAlgoForTracker.h:331
TrackingParticle::Vector
math::XYZVectorD Vector
point in the space
Definition: TrackingParticle.h:37
edm::ParameterSet::copyForModify
void copyForModify(ParameterSet const &other)
Definition: ParameterSet.cc:100
reco::GsfTrack::phiMode
double phiMode() const
azimuthal angle of momentum vector from mode
Definition: GsfTrack.h:55
hltPixelTracks_cff.chi2
chi2
Definition: hltPixelTracks_cff.py:25
muonCosmicCompatibility_cfi.sharedHits
sharedHits
Definition: muonCosmicCompatibility_cfi.py:31
newFWLiteAna.found
found
Definition: newFWLiteAna.py:118
edm::LogWarning
Log< level::Warning, false > LogWarning
Definition: MessageLogger.h:122
rpcPointValidation_cfi.recHit
recHit
Definition: rpcPointValidation_cfi.py:7
MTVHistoProducerAlgoForTracker::GpSelectorForEfficiencyVsPhi
std::unique_ptr< GenParticleCustomSelector > GpSelectorForEfficiencyVsPhi
Definition: MTVHistoProducerAlgoForTracker.h:297
MTVHistoProducerAlgoForTracker::minHit
double minHit
Definition: MTVHistoProducerAlgoForTracker.h:309
MTVHistoProducerAlgoForTracker::dxyRes_rangeMax
double dxyRes_rangeMax
Definition: MTVHistoProducerAlgoForTracker.h:354
fileCollector.seed
seed
Definition: fileCollector.py:127
DetId
Definition: DetId.h:17
GeomDetEnumerators::PixelBarrel
Definition: GeomDetEnumerators.h:11
MTVHistoProducerAlgoForTracker::nintEta
int nintEta
Definition: MTVHistoProducerAlgoForTracker.h:303
MTVHistoProducerAlgoForTracker::minPt
double minPt
Definition: MTVHistoProducerAlgoForTracker.h:305
reco::GsfTrack
Definition: GsfTrack.h:12
MTVHistoProducerAlgoForTracker::nintPt
int nintPt
Definition: MTVHistoProducerAlgoForTracker.h:306
TrackingParticleIP::dxy
auto dxy(const T_Vertex &vertex, const T_Momentum &momentum, const T_Point &point)
Definition: TrackingParticleIP.h:11
h
MTVHistoProducerAlgoForTracker::mindr
double mindr
Definition: MTVHistoProducerAlgoForTracker.h:327
TrackFwd.h
MTVHistoProducerAlgoForTracker::maxEta
double maxEta
Definition: MTVHistoProducerAlgoForTracker.h:302
dqm::legacy::DQMStore
Definition: DQMStore.h:727
MTVHistoProducerAlgoForTracker::bookSimTrackPVAssociationHistos
void bookSimTrackPVAssociationHistos(DQMStore::IBooker &ibook, Histograms &histograms)
Definition: MTVHistoProducerAlgoForTracker.cc:553
MTVHistoProducerAlgoForTracker::dzRes_rangeMin
double dzRes_rangeMin
Definition: MTVHistoProducerAlgoForTracker.h:356
MTVHistoProducerAlgoForTracker::minEta
double minEta
Definition: MTVHistoProducerAlgoForTracker.h:302
PVValHelper::eta
Definition: PVValidationHelpers.h:69
MTVHistoProducerAlgoForTracker::minZpos
double minZpos
Definition: MTVHistoProducerAlgoForTracker.h:325
MTVHistoProducerAlgoForTracker::phiRes_nbin
int phiRes_nbin
Definition: MTVHistoProducerAlgoForTracker.h:351
reco::DeDxData::numberOfMeasurements
unsigned int numberOfMeasurements() const
Definition: DeDxData.cc:18
mathSSE::sqrt
T sqrt(T t)
Definition: SSEVec.h:19
TrackingParticle
Monte Carlo truth information used for tracking validation.
Definition: TrackingParticle.h:29
MTVHistoProducerAlgoForTracker::minVertpos
double minVertpos
Definition: MTVHistoProducerAlgoForTracker.h:322
MTVHistoProducerAlgoForTracker::nintLayers
int nintLayers
Definition: MTVHistoProducerAlgoForTracker.h:314
reco::DeDxData::numberOfSaturatedMeasurements
int numberOfSaturatedMeasurements() const
Definition: DeDxData.cc:20
reco::Track
Definition: Track.h:27
TrackerDetSide
TrackerDetSide
Definition: TrackerDetSide.h:4
dqm::implementation::IBooker::bookProfile
MonitorElement * bookProfile(TString const &name, TString const &title, int nchX, double lowX, double highX, int, double lowY, double highY, char const *option="s", FUNC onbooking=NOOP())
Definition: DQMStore.h:322
MTVHistoProducerAlgoForTracker::bookSimHistos
void bookSimHistos(DQMStore::IBooker &ibook, Histograms &histograms)
Definition: MTVHistoProducerAlgoForTracker.cc:395
MTVHistoProducerAlgoForTracker::maxZpos
double maxZpos
Definition: MTVHistoProducerAlgoForTracker.h:325
MTVHistoProducerAlgoForTracker::nintDz
int nintDz
Definition: MTVHistoProducerAlgoForTracker.h:320
MTVHistoProducerAlgoForTracker.h
SeedingLayerSetsBuilder::SeedingLayerId
std::tuple< GeomDetEnumerators::SubDetector, TrackerDetSide, int > SeedingLayerId
Definition: SeedingLayerSetsBuilder.h:33
submitPVResolutionJobs.count
count
Definition: submitPVResolutionJobs.py:352
MTVHistoProducerAlgoForTracker::nintDxy
int nintDxy
Definition: MTVHistoProducerAlgoForTracker.h:318
StripSubdetector::TIB
static constexpr auto TIB
Definition: StripSubdetector.h:16
reco::TrackBase::algoName
std::string algoName() const
Definition: TrackBase.h:550
MTVHistoProducerAlgoForTracker::minPhi
double minPhi
Definition: MTVHistoProducerAlgoForTracker.h:315
MTVHistoProducerAlgoForTracker::fill_simTrackBased_histos
void fill_simTrackBased_histos(const Histograms &histograms, int numSimTracks) const
Definition: MTVHistoProducerAlgoForTracker.cc:1980
nhits
Definition: HIMultiTrackSelector.h:42
Args
Definition: hcalPublishConditions.cc:31
cmsswSequenceInfo.tp
tp
Definition: cmsswSequenceInfo.py:17
DetId::subdetId
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector's numbering enum)
Definition: DetId.h:48
MTVHistoProducerAlgoForTracker::minVertcount
double minVertcount
Definition: MTVHistoProducerAlgoForTracker.h:335
MTVHistoProducerAlgoForTracker::maxPVz
double maxPVz
Definition: MTVHistoProducerAlgoForTracker.h:339
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
MTVHistoProducerAlgoForTracker::nintVertpos
int nintVertpos
Definition: MTVHistoProducerAlgoForTracker.h:323
MTVHistoProducerAlgoForTracker::bookMVAHistos
void bookMVAHistos(DQMStore::IBooker &ibook, Histograms &histograms, size_t nMVAs)
Definition: MTVHistoProducerAlgoForTracker.cc:1612
edm::ParameterSet::eraseSimpleParameter
void eraseSimpleParameter(std::string const &name)
Definition: ParameterSet.cc:131
trackFromSeedFitFailed
bool trackFromSeedFitFailed(const reco::Track &track)
Definition: trackFromSeedFitFailed.h:6
trackerHitRTTI::isMatched
bool isMatched(TrackingRecHit const &hit)
Definition: trackerHitRTTI.h:33
LogDebug
#define LogDebug(id)
Definition: MessageLogger.h:223
trackFromSeedFitFailed.h
MTVHistoProducerAlgoForTracker::minPVz
double minPVz
Definition: MTVHistoProducerAlgoForTracker.h:339
edm::ParameterSet
Definition: ParameterSet.h:47
math::XYZPoint
XYZPointD XYZPoint
point in space with cartesian internal representation
Definition: Point3D.h:12
reco::modules
Definition: IMASelector.h:46
DetId::Tracker
Definition: DetId.h:25
MTVHistoProducerAlgoForTracker::phiRes_rangeMax
double phiRes_rangeMax
Definition: MTVHistoProducerAlgoForTracker.h:350
MTVHistoProducerAlgoForTracker::minLayers
double minLayers
Definition: MTVHistoProducerAlgoForTracker.h:313
MTVHistoProducerAlgoForTracker::doMTDPlots_
const bool doMTDPlots_
Definition: MTVHistoProducerAlgoForTracker.h:345
MTVHistoProducerAlgoForTracker::doSeedPlots_
const bool doSeedPlots_
Definition: MTVHistoProducerAlgoForTracker.h:344
MultiTrackValidator_cfi.doSeedPlots
doSeedPlots
Definition: MultiTrackValidator_cfi.py:97
MTVHistoProducerAlgoForTracker::SeedingLayerSetId
std::array< SeedingLayerId, 4 > SeedingLayerSetId
Definition: MTVHistoProducerAlgoForTracker.h:367
MTVHistoProducerAlgoForTracker::trackSelectorVsPt
std::unique_ptr< RecoTrackSelectorBase > trackSelectorVsPt
Definition: MTVHistoProducerAlgoForTracker.h:293
MTVHistoProducerAlgoForTracker::SeedingLayerId
std::tuple< SeedingLayerSetsBuilder::SeedingLayerId, bool > SeedingLayerId
Definition: MTVHistoProducerAlgoForTracker.h:366
GeomDetEnumerators::TEC
Definition: GeomDetEnumerators.h:16
MTVHistoProducerAlgoForTracker::minMVA
double minMVA
Definition: MTVHistoProducerAlgoForTracker.h:341
MTVHistoProducerAlgoForTracker::nintPhi
int nintPhi
Definition: MTVHistoProducerAlgoForTracker.h:316
MTVHistoProducerAlgoForTracker::maxVertcount
double maxVertcount
Definition: MTVHistoProducerAlgoForTracker.h:335
MTVHistoProducerAlgoForTracker::maxDz
double maxDz
Definition: MTVHistoProducerAlgoForTracker.h:319
edm::ParameterSet::addParameter
void addParameter(std::string const &name, T const &value)
Definition: ParameterSet.h:135
funct::tan
Tan< T >::type tan(const T &t)
Definition: Tan.h:22
MTVHistoProducerAlgoForTracker::maxVertpos
double maxVertpos
Definition: MTVHistoProducerAlgoForTracker.h:322
createfilelist.int
int
Definition: createfilelist.py:10
MTVHistoProducerAlgoForTracker::maxDxy
double maxDxy
Definition: MTVHistoProducerAlgoForTracker.h:317
MTVHistoProducerAlgoForTracker::nintdrj
int nintdrj
Definition: MTVHistoProducerAlgoForTracker.h:330
MTVHistoProducerAlgoForTracker::TpSelectorForEfficiencyVsVTXZ
std::unique_ptr< TrackingParticleSelector > TpSelectorForEfficiencyVsVTXZ
Definition: MTVHistoProducerAlgoForTracker.h:289
M_PI
#define M_PI
Definition: BXVectorInputProducer.cc:49
trackerHitRTTI::vector
Definition: trackerHitRTTI.h:21
HcalObjRepresent::setBinLabels
void setBinLabels(std::vector< TH2F > &depth)
Definition: HcalObjRepresent.h:548
MTVHistoProducerAlgoForTracker::maxDzpvCum
double maxDzpvCum
Definition: MTVHistoProducerAlgoForTracker.h:359
histograms
Definition: histograms.py:1
MTVHistoProducerAlgoForTracker::cotThetaRes_rangeMin
double cotThetaRes_rangeMin
Definition: MTVHistoProducerAlgoForTracker.h:352
MTVHistoProducerAlgoForTracker::nintdr
int nintdr
Definition: MTVHistoProducerAlgoForTracker.h:328
MTVHistoProducerAlgoForTracker::useLogVertpos
bool useLogVertpos
Definition: MTVHistoProducerAlgoForTracker.h:324
MTVHistoProducerAlgoForTrackerHistograms
Definition: MTVHistoProducerAlgoForTracker.h:29
SeedingLayerSetsBuilder::nameToEnumId
static SeedingLayerId nameToEnumId(const std::string &name)
Definition: SeedingLayerSetsBuilder.cc:32
MTVHistoProducerAlgoForTracker::getRecoMomentum
void getRecoMomentum(const reco::Track &track, double &pt, double &ptError, double &qoverp, double &qoverpError, double &lambda, double &lambdaError, double &phi, double &phiError) const
retrieval of reconstructed momentum components from reco::Track (== mean values for GSF)
Definition: MTVHistoProducerAlgoForTracker.cc:2543
ValueMap.h
MTVHistoProducerAlgoForTracker::minDeDx
double minDeDx
Definition: MTVHistoProducerAlgoForTracker.h:333
MTVHistoProducerAlgoForTracker::nintHit
int nintHit
Definition: MTVHistoProducerAlgoForTracker.h:310
DDAxes::phi
MTVHistoProducerAlgoForTracker::mindrj
double mindrj
Definition: MTVHistoProducerAlgoForTracker.h:329
MTVHistoProducerAlgoForTracker::getEta
double getEta(double eta) const
Definition: MTVHistoProducerAlgoForTracker.cc:2583
MTVHistoProducerAlgoForTracker::minTracks
double minTracks
Definition: MTVHistoProducerAlgoForTracker.h:337
MTVHistoProducerAlgoForTracker::fill_dedx_recoTrack_histos
void fill_dedx_recoTrack_histos(const Histograms &histograms, int count, const edm::RefToBase< reco::Track > &trackref, const std::vector< const edm::ValueMap< reco::DeDxData > * > &v_dEdx) const
Definition: MTVHistoProducerAlgoForTracker.cc:1985
std
Definition: JetResolutionObject.h:76
DetId::rawId
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:57
Ref.h
MTVHistoProducerAlgoForTracker::ptRes_rangeMin
double ptRes_rangeMin
Definition: MTVHistoProducerAlgoForTracker.h:348
StripSubdetector::TEC
static constexpr auto TEC
Definition: StripSubdetector.h:19
MTVHistoProducerAlgoForTracker::getPt
double getPt(double pt) const
Definition: MTVHistoProducerAlgoForTracker.cc:2590
reco::DeDxData::dEdx
float dEdx() const
Definition: DeDxData.cc:11
PVValHelper::dxy
Definition: PVValidationHelpers.h:47
MTVHistoProducerAlgoForTracker::dxyDzZoom
double dxyDzZoom
Definition: MTVHistoProducerAlgoForTracker.h:321
MTVHistoProducerAlgoForTracker::nintZpos
int nintZpos
Definition: MTVHistoProducerAlgoForTracker.h:326
reco::TrackBase::algoSize
Definition: TrackBase.h:141
MTVHistoProducerAlgoForTracker::fill_generic_recoTrack_histos
void fill_generic_recoTrack_histos(const Histograms &histograms, int count, const reco::Track &track, const TrackerTopology &ttopo, const math::XYZPoint &bsPosition, const math::XYZPoint *pvPosition, const TrackingVertex::LorentzVector *simPVPosition, bool isMatched, bool isSigMatched, bool isChargeMatched, int numAssocRecoTracks, int numVertices, int nSimHits, double sharedFraction, double dR, double dR_jet, const std::vector< float > &mvas, unsigned int selectsLoose, unsigned int selectsHP) const
Definition: MTVHistoProducerAlgoForTracker.cc:1999
PVValHelper::dz
Definition: PVValidationHelpers.h:50
edm::ValueMap
Definition: ValueMap.h:107
relativeConstraints.value
value
Definition: relativeConstraints.py:53
dqm::implementation::IBooker::book2D
MonitorElement * book2D(TString const &name, TString const &title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, FUNC onbooking=NOOP())
Definition: DQMStore.h:177
Exception
Definition: hltDiff.cc:246
reco::HitPattern::MISSING_INNER_HITS
Definition: HitPattern.h:155
phase2tkutil::DQMStore
dqm::reco::DQMStore DQMStore
Definition: TrackerPhase2DQMUtil.h:16
MTVHistoProducerAlgoForTracker::nintPu
int nintPu
Definition: MTVHistoProducerAlgoForTracker.h:312
MTVHistoProducerAlgoForTracker::nintDzpvsigCum
int nintDzpvsigCum
Definition: MTVHistoProducerAlgoForTracker.h:362
MTVHistoProducerAlgoForTracker::seedingLayerSetNames
std::vector< std::string > seedingLayerSetNames
Definition: MTVHistoProducerAlgoForTracker.h:364
MTVHistoProducerAlgoForTracker::generalTpSelector
std::unique_ptr< TrackingParticleSelector > generalTpSelector
Definition: MTVHistoProducerAlgoForTracker.h:284
StripSubdetector::TOB
static constexpr auto TOB
Definition: StripSubdetector.h:18
SeedingLayerSetsBuilder::layerNamesInSets
static std::vector< std::vector< std::string > > layerNamesInSets(const std::vector< std::string > &namesPSet)
Definition: SeedingLayerSetsBuilder.cc:275
TrajectorySeed
Definition: TrajectorySeed.h:18
Skims_PA_cff.name
name
Definition: Skims_PA_cff.py:17
edm::RefToBase< reco::Track >
GeomDetEnumerators::PixelEndcap
Definition: GeomDetEnumerators.h:12
MTVHistoProducerAlgoForTracker::nintChi2
int nintChi2
Definition: MTVHistoProducerAlgoForTracker.h:332
dqm::implementation::IBooker
Definition: DQMStore.h:43
MTVHistoProducerAlgoForTracker::ptRes_rangeMax
double ptRes_rangeMax
Definition: MTVHistoProducerAlgoForTracker.h:348
MTVHistoProducerAlgoForTracker::nintMVA
int nintMVA
Definition: MTVHistoProducerAlgoForTracker.h:342
minChi2
Definition: JetCombinatorics.h:265
MTVHistoProducerAlgoForTracker::nintPVz
int nintPVz
Definition: MTVHistoProducerAlgoForTracker.h:340
MTVHistoProducerAlgoForTracker::ptRes_nbin
int ptRes_nbin
Definition: MTVHistoProducerAlgoForTracker.h:349
MTVHistoProducerAlgoForTracker::maxdrj
double maxdrj
Definition: MTVHistoProducerAlgoForTracker.h:329
reco::DeDxData
Definition: DeDxData.h:8
funct::abs
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
reco::GsfTrack::ptModeError
double ptModeError() const
error on Pt (set to 1000 TeV if charge==0 for safety) from mode
Definition: GsfTrack.h:81
MTVHistoProducerAlgoForTracker::fill_generic_simTrack_histos
void fill_generic_simTrack_histos(const Histograms &histograms, const TrackingParticle::Vector &, const TrackingParticle::Point &vertex, int bx) const
Definition: MTVHistoProducerAlgoForTracker.cc:1802
MTVHistoProducerAlgoForTracker::bookSimTrackHistos
void bookSimTrackHistos(DQMStore::IBooker &ibook, Histograms &histograms, bool doResolutionPlots)
Definition: MTVHistoProducerAlgoForTracker.cc:406
LogTrace
#define LogTrace(id)
Definition: MessageLogger.h:224
trigObjTnPSource_cfi.bins
bins
Definition: trigObjTnPSource_cfi.py:20
HGC3DClusterGenMatchSelector_cfi.dR
dR
Definition: HGC3DClusterGenMatchSelector_cfi.py:7
MTVHistoProducerAlgoForTracker::dzRes_rangeMax
double dzRes_rangeMax
Definition: MTVHistoProducerAlgoForTracker.h:356
MTVHistoProducerAlgoForTracker::nintVertcount
int nintVertcount
Definition: MTVHistoProducerAlgoForTracker.h:336
EgammaValidation_Wenu_cff.sel
sel
Definition: EgammaValidation_Wenu_cff.py:33
MTVHistoProducerAlgoForTracker::maxPu
double maxPu
Definition: MTVHistoProducerAlgoForTracker.h:311
dqmiolumiharvest.j
j
Definition: dqmiolumiharvest.py:66
MTVHistoProducerAlgoForTracker::dxyRes_nbin
int dxyRes_nbin
Definition: MTVHistoProducerAlgoForTracker.h:355
MTVHistoProducerAlgoForTracker::cotThetaRes_nbin
int cotThetaRes_nbin
Definition: MTVHistoProducerAlgoForTracker.h:353
TrackingParticle::Point
math::XYZPointD Point
point in the space
Definition: TrackingParticle.h:36
TrackingParticleIP.h
MTVHistoProducerAlgoForTracker::GpSelectorForEfficiencyVsVTXR
std::unique_ptr< GenParticleCustomSelector > GpSelectorForEfficiencyVsVTXR
Definition: MTVHistoProducerAlgoForTracker.h:299
reco::TrackBase::algoNames
static const std::string algoNames[]
Definition: TrackBase.h:147
MTVHistoProducerAlgoForTracker::fill_simAssociated_recoTrack_histos
void fill_simAssociated_recoTrack_histos(const Histograms &histograms, int count, const reco::Track &track) const
Definition: MTVHistoProducerAlgoForTracker.cc:2298
MTVHistoProducerAlgoForTracker::makeRecoTrackSelectorFromTPSelectorParameters
static std::unique_ptr< RecoTrackSelectorBase > makeRecoTrackSelectorFromTPSelectorParameters(const edm::ParameterSet &pset)
Definition: MTVHistoProducerAlgoForTracker.cc:371
MTVHistoProducerAlgoForTracker::MTVHistoProducerAlgoForTracker
MTVHistoProducerAlgoForTracker(const edm::ParameterSet &pset, const bool doSeedPlots)
Definition: MTVHistoProducerAlgoForTracker.cc:141
MTVHistoProducerAlgoForTracker::dzRes_nbin
int dzRes_nbin
Definition: MTVHistoProducerAlgoForTracker.h:357
MTVHistoProducerAlgoForTracker::bookRecoHistos
void bookRecoHistos(DQMStore::IBooker &ibook, Histograms &histograms, bool doResolutionPlots)
Definition: MTVHistoProducerAlgoForTracker.cc:637
GeomDetEnumerators::isTrackerStrip
bool isTrackerStrip(GeomDetEnumerators::SubDetector m)
Definition: GeomDetEnumerators.cc:64
MTVHistoProducerAlgoForTracker::cotThetaRes_rangeMax
double cotThetaRes_rangeMax
Definition: MTVHistoProducerAlgoForTracker.h:352
MTVHistoProducerAlgoForTracker::maxDzpvsigCum
double maxDzpvsigCum
Definition: MTVHistoProducerAlgoForTracker.h:361
MTVHistoProducerAlgoForTracker::~MTVHistoProducerAlgoForTracker
~MTVHistoProducerAlgoForTracker()
Definition: MTVHistoProducerAlgoForTracker.cc:369
StripSubdetector::TID
static constexpr auto TID
Definition: StripSubdetector.h:17
reco::modules::ParameterAdapter
Definition: ParameterAdapter.h:12
MTVHistoProducerAlgoForTracker::dxyRes_rangeMin
double dxyRes_rangeMin
Definition: MTVHistoProducerAlgoForTracker.h:354
muonDTDigis_cfi.pset
pset
Definition: muonDTDigis_cfi.py:27
reco::GsfTrack::qoverpModeError
double qoverpModeError() const
error on signed transverse curvature from mode
Definition: GsfTrack.h:79
dqm::implementation::IBooker::book1D
MonitorElement * book1D(TString const &name, TString const &title, int const nchX, double const lowX, double const highX, FUNC onbooking=NOOP())
Definition: DQMStore.h:98
MTVHistoProducerAlgoForTracker::bookRecodEdxHistos
void bookRecodEdxHistos(DQMStore::IBooker &ibook, Histograms &histograms)
Definition: MTVHistoProducerAlgoForTracker.cc:1584
MTVHistoProducerAlgoForTracker::seedingLayerSetToBin
std::map< SeedingLayerSetId, unsigned int > seedingLayerSetToBin
Definition: MTVHistoProducerAlgoForTracker.h:368
muonME0PseudoDigis_cfi.phiError
phiError
Definition: muonME0PseudoDigis_cfi.py:9
TrackingVertex::LorentzVector
math::XYZTLorentzVectorD LorentzVector
Definition: TrackingVertex.h:28
MTVHistoProducerAlgoForTracker::TpSelectorForEfficiencyVsPhi
std::unique_ptr< TrackingParticleSelector > TpSelectorForEfficiencyVsPhi
Definition: MTVHistoProducerAlgoForTracker.h:286
findQualityFiles.size
size
Write out results.
Definition: findQualityFiles.py:443
nlayers
Definition: HIMultiTrackSelector.h:48
MTVHistoProducerAlgoForTracker::maxPhi
double maxPhi
Definition: MTVHistoProducerAlgoForTracker.h:315
TrackingParticleIP::dz
auto dz(const T_Vertex &vertex, const T_Momentum &momentum, const T_Point &point)
Definition: TrackingParticleIP.h:16
MTVHistoProducerAlgoForTracker::fill_seed_histos
void fill_seed_histos(const Histograms &histograms, int count, int seedsFitFailed, int seedsTotal) const
Definition: MTVHistoProducerAlgoForTracker.cc:2735
MTVHistoProducerAlgoForTracker::fill_recoAssociated_simTrack_histos
void fill_recoAssociated_simTrack_histos(const Histograms &histograms, int count, const TrackingParticle &tp, const TrackingParticle::Vector &momentumTP, const TrackingParticle::Point &vertexTP, double dxy, double dz, double dxyPV, double dzPV, int nSimHits, int nSimLayers, int nSimPixelLayers, int nSimStripMonoAndStereoLayers, const reco::Track *track, int numVertices, double dR, double dR_jet, const math::XYZPoint *pvPosition, const TrackingVertex::LorentzVector *simPVPosition, const math::XYZPoint &bsPosition, const std::vector< float > &mvas, unsigned int selectsLoose, unsigned int selectsHP) const
Definition: MTVHistoProducerAlgoForTracker.cc:1815