CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
L1TDTTFClient.cc
Go to the documentation of this file.
1 /*
2  * \file L1TDTTFClient.cc
3  *
4  * $Date: 2012/06/14 16:38:30 $
5  * $Revision: 1.9 $
6  * \author G. Codispoti
7  *
8  */
9 
10 
12 
19 
20 
22  : l1tdttffolder_ ( ps.getUntrackedParameter<std::string> ("l1tSourceFolder", "L1T/L1TDTTF") ),
23  dttfSource_( ps.getParameter< edm::InputTag >("dttfSource") ),
24  online_( ps.getUntrackedParameter<bool>("online", true) ),
25  resetafterlumi_( ps.getUntrackedParameter<int>("resetAfterLumi", 3) ),
26  counterLS_(0), occupancy_r_(0)
27 {
28  edm::LogInfo( "L1TDTTFClient");
29 }
30 
31 
32 //--------------------------------------------------------
34  edm::LogInfo("L1TDTTFClient")<<"[L1TDTTFClient]: ending... ";
35 }
36 
37 
38 //--------------------------------------------------------
40 {
41 
42  edm::LogInfo("L1TDTTFClient")<<"[L1TDTTFClient]: Begin Job";
43 
46 
47  wheelpath_[0] = l1tdttffolder_ + "/02-WHEEL_N2";
48  wheelpath_[1] = l1tdttffolder_ + "/03-WHEEL_N1";
49  wheelpath_[2] = l1tdttffolder_ + "/04-WHEEL_N0";
50  wheelpath_[3] = l1tdttffolder_ + "/05-WHEEL_P0";
51  wheelpath_[4] = l1tdttffolder_ + "/06-WHEEL_P1";
52  wheelpath_[5] = l1tdttffolder_ + "/07-WHEEL_P2";
53 
54  wheel_[0] = "N2";
55  wheel_[1] = "N1";
56  wheel_[2] = "N0";
57  wheel_[3] = "P0";
58  wheel_[4] = "P1";
59  wheel_[5] = "P2";
60 
61  inclusivepath_ = l1tdttffolder_ + "/01-INCLUSIVE";
62  gmtpath_ = l1tdttffolder_ + "/08-GMT_MATCH";
63  testpath_ = l1tdttffolder_ + "/09-TEST";
64 
66  char hname[100];//histo name
67  char mename[100];//ME name
68 
71 
73  sprintf(hname, "dttf_02_nTracks");
74  sprintf(mename, "DTTF Tracks by Wheel");
75  dttf_nTracks_integ = dbe_->book1D(hname, mename, 6, 0, 6);
77 
79  sprintf(hname, "dttf_03_tracks_occupancy_summary");
80  sprintf(mename, "DTTF Tracks Occupancy");
81  dttf_occupancySummary = dbe_->book2D( hname, mename, 6, 0, 6, 12, 1, 13 );
83  dttf_occupancySummary->setAxisTitle("Sector", 2);
84 
86 
88  sprintf(hname, "dttf_05_bx_occupancy");
89  sprintf(mename, "DTTF Tracks BX Distribution by Wheel");
90  dttf_bx_summary = dbe_->book2D( hname, mename, 6, 0, 6, 3, -1, 2 );
92  dttf_bx_summary->setAxisTitle("BX", 2 );
93 
95  sprintf(hname, "dttf_06_bx");
96  sprintf(mename, "DTTF Tracks BX w.r.t. Tracks with BX=0");
97  dttf_bx_integ = dbe_->book1D( hname, mename, 3, -1.5, 1.5 );
98  dttf_bx_integ->setAxisTitle("BX", 1);
99 
101  sprintf(hname, "dttf_07_quality");
102  sprintf(mename, "DTTF Tracks Quality distribution");
103  dttf_quality_integ = dbe_->book1D(hname, mename, 7, 1, 8);
105 
107  sprintf(hname, "dttf_08_quality_occupancy");
108  sprintf(mename, "DTTF Tracks Quality distribution by Wheel");
109  dttf_quality_summary = dbe_->book2D( hname, mename, 6, 0, 6, 7, 1, 8 );
110  dttf_quality_summary->setAxisTitle("Wheel", 1);
113 
115  sprintf(hname, "dttf_09_highQuality_Tracks");
116  sprintf(mename, "Fraction of DTTF Tracks with Quality>3");
117  dttf_highQual_Summary = dbe_->book2D( hname, mename, 6, 0, 6, 12, 1, 13 );
119  dttf_highQual_Summary->setAxisTitle("Sector", 2);
120 
121 
123  sprintf(hname, "dttf_10_phi_vs_etaCoarse");
124  sprintf(mename, "#eta-#phi DTTF Tracks occupancy (coarse #eta only, packed values)");
125  dttf_phi_eta_coarse_integ = dbe_->book2D( hname, mename, 64, 0, 64,
126  144, -6, 138. );
129 
131  sprintf(hname, "dttf_11_phi_vs_etaFine");
132  sprintf(mename, "#eta-#phi DTTF Tracks occupancy (fine #eta only, packed values)");
133  dttf_phi_eta_fine_integ = dbe_->book2D( hname, mename, 64, 0, 64,
134  144, -6, 138. );
137 
139  sprintf(hname, "dttf_12_phi_vs_eta");
140  sprintf(mename, "#eta-#phi DTTF Tracks occupancy");
141  dttf_phi_eta_integ = dbe_->book2D( hname, mename, 64, -1.2, 1.2,
142  144, -15, 345. );
143  dttf_phi_eta_integ->setAxisTitle("#eta", 1);
144  dttf_phi_eta_integ->setAxisTitle("#phi", 2);
145 
147  sprintf(hname, "dttf_13_eta_fine_fraction");
148  sprintf(mename, "Fraction of DTTF Tracks with Fine #eta Assignment");
149  dttf_eta_fine_fraction = dbe_->book1D( hname, mename, 6, 0, 6 );
152 
154 
156  sprintf(hname, "dttf_14_eta");
157  sprintf(mename, "DTTF Tracks #eta distribution (Packed values)");
158  dttf_eta_integ = dbe_->book1D(hname, mename, 64, -0.5, 63.5);
159  dttf_eta_integ->setAxisTitle("#eta", 1);
160 
162  sprintf(hname, "dttf_15_phi");
163  sprintf(mename, "DTTF Tracks Phi distribution (Packed values)");
164  dttf_phi_integ = dbe_->book1D(hname, mename, 144, -6, 138. );
165  dttf_phi_integ->setAxisTitle("#phi", 1);
166 
168  sprintf(hname, "dttf_16_pt");
169  sprintf(mename, "DTTF Tracks p_{T} distribution (Packed values)");
170  dttf_pt_integ = dbe_->book1D(hname, mename, 32, -0.5, 31.5);
171  dttf_pt_integ->setAxisTitle("p_{T}", 1);
172 
174  sprintf(hname, "dttf_17_charge");
175  sprintf(mename, "DTTF Tracks Charge distribution");
176  dttf_q_integ = dbe_->book1D(hname, mename, 2, -0.5, 1.5);
177  dttf_q_integ->setAxisTitle("Charge", 1);
178 
179 
180 
182  sprintf(hname, "dttf_18_2ndTrack_occupancy_summary");
183  sprintf(mename, "DTTF 2nd Tracks occupancy w.r.t. Tracks with BX=0");
184  dttf_2ndTrack_Summary = dbe_->book2D( hname, mename, 6, 0, 6, 12, 1, 13 );
186 
187 
188 
193  sprintf(hname, "dttf_gmt_fract_matching" );
194  sprintf(mename, "Fraction of DTTF tracks matching with GMT tracks" );
195  dttf_gmt_matching = dbe_->book1D( hname, mename, 3, 1, 4);
196  dttf_gmt_matching->setBinLabel(1, "GMT Only", 1);
197  dttf_gmt_matching->setBinLabel(2, "Matching", 1);
198  dttf_gmt_matching->setBinLabel(3, "DTTF Only", 1);
199 
200 
204 
206  sprintf(hname, "dttf_01_tracks_occupancy_test_summary");
207  sprintf(mename, "DTTF Tracks Occupancy");
208  dttf_occupancySummary_test = dbe_->book2D( hname, mename, 6, 0, 6, 12, 1, 13 );
211 
212 
216  dbe_->setCurrentFolder( inclusivepath_ + "/2ND_TRACK_ONLY");
217 
219  sprintf(hname, "dttf_01_nTracks_2ndTrack");
220  sprintf(mename, "DTTF 2nd Tracks per Wheel distribution");
221  dttf_nTracks_integ_2ndTrack = dbe_->book1D(hname, mename, 6, 0, 6);
223 
225  sprintf(hname, "dttf_02_occupancy_summary_2ndTrack");
226  sprintf(mename, "DTTF 2nd Tracks distribution by Sector and Wheel");
227  dttf_occupancySummary_2ndTrack = dbe_->book2D( hname, mename, 6, 0, 6,
228  12, 1, 13 );
230 
232  sprintf(hname, "dttf_03_bx_occupancy_2ndTrack");
233  sprintf(mename, "DTTF 2nd Tracks BX Distribution by Wheel");
234  dttf_bx_summary_2ndTrack = dbe_->book2D( hname, mename, 6, 0, 6, 3, -1, 2 );
237 
239  sprintf(hname, "dttf_04_bx_2ndTrack");
240  sprintf(mename, "Fraction of DTTF Tracks BX w.r.t. Tracks with BX=0");
241  dttf_bx_integ_2ndTrack = dbe_->book1D( hname, mename, 3, -1.5, 1.5 );
243 
245  sprintf(hname, "dttf_05_quality_2ndTrack");
246  sprintf(mename, "DTTF 2nd Tracks Quality distribution");
247  dttf_quality_integ_2ndTrack = dbe_->book1D(hname, mename, 7, 0.5, 7.5);
250 
252  sprintf(hname, "dttf_06_quality_occupancy_2ndTrack");
253  sprintf(mename, "DTTF 2nd Tracks Quality distribution by Wheel");
254  dttf_quality_summary_2ndTrack = dbe_->book2D( hname, mename,
255  6, 0, 6, 7, 1, 8 );
259 
261  sprintf(hname, "dttf_07_highQuality_Tracks_2ndTrack");
262  sprintf(mename, "Fraction of DTTF 2nd Tracks with Quality>3");
263  dttf_highQual_Summary_2ndTrack = dbe_->book2D( hname, mename, 6, 0, 6,
264  12, 1, 13 );
267 
269  sprintf(hname, "dttf_08_phi_vs_eta_2ndTrack");
270  sprintf(mename, "#eta-#phi DTTF Tracks occupancy for 2nd Tracks");
271  dttf_phi_eta_integ_2ndTrack = dbe_->book2D( hname, mename, 64, 0, 64,
272  144, -6, 138. );
275 
277  sprintf(hname, "dttf_09_eta_2ndTrack");
278  sprintf(mename, "DTTF 2nd Tracks #eta distribution (Packed values)");
279  dttf_eta_integ_2ndTrack = dbe_->book1D(hname, mename, 64, -0.5, 63.5);
281 
283  sprintf(hname, "dttf_10_phi_2ndTrack");
284  sprintf(mename, "DTTF 2nd Tracks Phi distribution (Packed values)");
285  dttf_phi_integ_2ndTrack = dbe_->book1D(hname, mename, 144, -6, 138 );
287 
289  sprintf(hname, "dttf_11_pt_2ndTrack");
290  sprintf(mename, "DTTF 2nd Tracks p_{T} distribution (Packed values)");
291  dttf_pt_integ_2ndTrack = dbe_->book1D(hname, mename, 32, -0.5, 31.5);
293 
295  sprintf(hname, "dttf_12_charge_2ndTrack");
296  sprintf(mename, "DTTF 2nd Tracks Charge distribution");
297  dttf_q_integ_2ndTrack = dbe_->book1D(hname, mename, 2, -0.5, 1.5);
298  dttf_q_integ_2ndTrack->setAxisTitle("Charge", 1);
299 
300 
301  for ( unsigned int wh = 0; wh < 6 ; ++wh ) {
303 
305  sprintf( hname, "dttf_02_nTracks_wh%s", wheel_[wh].c_str() );
306  sprintf( mename, "Wheel %s - Number of Tracks", wheel_[wh].c_str() );
307  dttf_nTracks_wheel[wh] = dbe_->book1D( hname, mename, 12, 1, 13);
308  dttf_nTracks_wheel[wh]->setAxisTitle("sector", 1);
309 
311  sprintf(hname, "dttf_03_bx_occupancy_wh%s", wheel_[wh].c_str() );
312  sprintf(mename, "Wheel %s - DTTF Tracks BX distribution by Sector",
313  wheel_[wh].c_str());
314  dttf_bx_wheel_summary[wh] = dbe_->book2D( hname, mename, 12, 1, 13, 3, -1, 2);
315  dttf_bx_wheel_summary[wh]->setAxisTitle("BX", 2 );
316  dttf_bx_wheel_summary[wh]->setAxisTitle("Sector", 1 );
317 
319  sprintf(hname, "dttf_04_bx_wh%s", wheel_[wh].c_str());
320  sprintf(mename, "Wheel %s - DTTF Tracks BX w.r.t. Tracks with BX=0", wheel_[wh].c_str());
321  dttf_bx_wheel_integ[wh] = dbe_->book1D(hname, mename, 3, -1.5, 1.5);
322  dttf_bx_wheel_integ[wh]->setAxisTitle("BX", 1);
323 
325  sprintf(hname, "dttf_05_quality_wh%s", wheel_[wh].c_str() );
326  sprintf(mename, "Wheel %s - Tracks Quality Distribution", wheel_[wh].c_str() );
327  dttf_quality_wheel[wh] = dbe_->book1D(hname, mename, 7, 1, 8);
328  dttf_quality_wheel[wh]->setAxisTitle("Quality", 1);
330 
332  sprintf(hname, "dttf_06_quality_summary_wh%s", wheel_[wh].c_str() );
333  sprintf(mename, "Wheel %s - Tracks Quality Distribution by Sector",
334  wheel_[wh].c_str() );
335  dttf_quality_summary_wheel[wh] = dbe_->book2D(hname, mename, 12, 1, 13, 7, 1, 8);
336  dttf_quality_summary_wheel[wh]->setAxisTitle("Sector", 1);
337  // dttf_quality_summary_wheel[wh]->setAxisTitle("Quality", 2);
339 
341  sprintf(hname, "dttf_09_etaFine_fraction_wh%s", wheel_[wh].c_str() );
342  sprintf(mename, "Wheel %s - Fraction of DTTF Tracks with fine #eta assignment",
343  wheel_[wh].c_str());
344  dttf_fine_fraction_wh[wh] = dbe_->book1D( hname, mename, 12, 1, 13);
345  dttf_fine_fraction_wh[wh]->setAxisTitle("Sector", 1 );
346 
347 
349  sprintf(hname, "dttf_10_eta_wh%s", wheel_[wh].c_str() );
350  sprintf(mename, "Wheel %s - DTTF Tracks #eta distribution (Packed values)",
351  wheel_[wh].c_str() );
352  dttf_eta_wheel[wh] = dbe_->book1D(hname, mename, 64, -0.5, 63.5 );
353  dttf_eta_wheel[wh]->setAxisTitle("#eta", 1 );
354 
356  sprintf(hname, "dttf_11_phi_wh%s", wheel_[wh].c_str() );
357  sprintf(mename, "Wheel %s - DTTF Tracks Phi distribution (Packed values)",
358  wheel_[wh].c_str() );
359  dttf_phi_wheel[wh] = dbe_->book1D(hname, mename, 144, -6, 138. );
360  dttf_phi_wheel[wh]->setAxisTitle("#phi", 1);
361 
363  sprintf(hname, "dttf_12_pt_wh%s", wheel_[wh].c_str() );
364  sprintf(mename, "Wheel %s - DTTF Tracks p_{T} distribution (Packed values)",
365  wheel_[wh].c_str() );
366  dttf_pt_wheel[wh] = dbe_->book1D(hname, mename, 32, -0.5, 31.5);
367  dttf_pt_wheel[wh]->setAxisTitle("p_{T}", 1);
368 
370  sprintf(hname, "dttf_13_charge_wh%s", wheel_[wh].c_str() );
371  sprintf(mename, "Wheel %s - DTTF Tracks Charge distribution",
372  wheel_[wh].c_str() );
373  dttf_q_wheel[wh] = dbe_->book1D(hname, mename, 2, -0.5, 1.5);
374  dttf_q_wheel[wh]->setAxisTitle("Charge", 1);
375 
376  }
377 
378 
380  for ( unsigned int wh = 0; wh < 6 ; ++wh ) {
381  dbe_->setCurrentFolder( wheelpath_[wh] + "/2ND_TRACK_ONLY" );
382 
384  sprintf( hname, "dttf_01_nTracks_wh%s_2ndTrack", wheel_[wh].c_str() );
385  sprintf( mename, "Wheel %s - DTTF Number of 2nd Tracks with BX=0",
386  wheel_[wh].c_str() );
387  dttf_nTracks_wheel_2ndTrack[wh] = dbe_->book1D( hname, mename,
388  12, 1, 13);
389  dttf_nTracks_wheel_2ndTrack[wh]->setAxisTitle("sector", 1);
390 
392  sprintf(hname, "dttf_02_bx_occupancy_wh%s_2ndTrack", wheel_[wh].c_str() );
393  sprintf(mename, "Wheel %s - DTTF 2nd Tracks BX distribution by Sector",
394  wheel_[wh].c_str());
395  dttf_bx_wheel_summary_2ndTrack[wh] = dbe_->book2D( hname, mename, 12, 1, 13, 3, -1, 2);
397  dttf_bx_wheel_summary_2ndTrack[wh]->setAxisTitle("Sector", 1 );
398 
400  sprintf(hname, "dttf_03_bx_wh%s_2ndTrack", wheel_[wh].c_str());
401  sprintf(mename, "Wheel %s - 2nd Tracks BX Distribution", wheel_[wh].c_str());
402  dttf_bx_wheel_integ_2ndTrack[wh] = dbe_->book1D(hname, mename, 3, -1.5, 1.5);
404 
405 
406  }
407 
408 
409 
410 }
411 
412 //--------------------------------------------------------
413 void L1TDTTFClient::beginRun(const edm::Run& r, const edm::EventSetup& context)
414 {
415 }
416 
417 //--------------------------------------------------------
419  const edm::EventSetup& context)
420 {
422  ++counterLS_;
423 
424  if ( online_ && !( counterLS_ % resetafterlumi_ ) ) {
425  char hname[60];
426  sprintf( hname, "%s/dttf_04_tracks_occupancy_by_lumi",
427  inclusivepath_.c_str() );
428 
429  occupancy_r_ = getTH2F(hname);
430  if ( ! occupancy_r_ ) {
431  edm::LogError("L1TDTTFClient::beginLuminosityBlock:ME")
432  << "Failed to get TH2D " << std::string(hname);
433  } else {
434  edm::LogInfo("L1TDTTFClient::beginLuminosityBlock:RESET") << "Reseting plots by lumi!";
435  occupancy_r_->Reset();
436  }
437  }
438 
439 }
440 
441 //--------------------------------------------------------
443  const edm::EventSetup& c)
444 {
445 
447  if ( online_ ) {
448  makeSummary();
450  }
451 
452 }
453 
454 //--------------------------------------------------------
456  const edm::EventSetup& context)
457 {
458 
459 
460 }
461 
462 //--------------------------------------------------------
463 void L1TDTTFClient::endRun(const edm::Run& r, const edm::EventSetup& context)
464 {
465  makeSummary();
466 }
467 
468 //--------------------------------------------------------
470 {
471 }
472 
473 
474 //--------------------------------------------------------
476 {
480  buildSummaries();
481 
485  double scale = 0;
486  double entries = dttf_occupancySummary->getTH2F()->Integral();
487 
488  if ( entries ) {
489 
492 
494  scale = 1 / entries;
497 
499  double physEntries = dttf_eta_integ->getTH1F()->Integral();
500  if ( physEntries > 0 ) {
501  double physScale = 1 / physEntries;
502 
503  normalize( dttf_phi_eta_integ->getTH2F(), physScale );
504 
505  normalize( dttf_phi_eta_fine_integ->getTH2F(), physScale );
507  normalize( dttf_quality_summary->getTH2F(), physScale );
508 
509  normalize( dttf_eta_integ->getTH1F(), physScale );
510  normalize( dttf_q_integ->getTH1F(), physScale );
511  normalize( dttf_pt_integ->getTH1F(), physScale );
512  normalize( dttf_phi_integ->getTH1F(), physScale );
513  normalize( dttf_quality_integ->getTH1F(), physScale );
514 
515  }
516 
517  }
518 
522 
523  double entries2ndTrack = dttf_occupancySummary_2ndTrack->getTH2F()->Integral();
524  if ( entries2ndTrack > 0 ) {
525 
528 
530  TH2F * ratio = dttf_occupancySummary_2ndTrack->getTH2F();
532  "%s/2ND_TRACK_ONLY/dttf_05_quality_summary_wh%s_2ndTrack" );
533 
535 
537  double scale2nd = 1 / entries2ndTrack;
539  normalize( dttf_nTracks_integ_2ndTrack->getTH1F(), scale2nd ); //
540 
541 
550 
551  }
552 
554  setGMTsummary();
555 
556 }
557 
558 
559 
560 
561 //--------------------------------------------------------
563 {
564 
565  char hname[100];
566  int wheelBx[4];
567  int wheelBx2nd[4];
568  int wheelSumBx[4];
569  int wheelSumBx2nd[4];
570  int qualities[8];
571 
572  memset( wheelSumBx, 0, 4 * sizeof(int) );
573  memset( wheelSumBx2nd, 0, 4 * sizeof(int) );
574 
577  dttf_q_integ->Reset();
578  dttf_pt_integ->Reset();
588 
592 
593  for ( unsigned int wh = 0; wh < 6 ; ++wh ) {
594 
595  dttf_eta_wheel[wh]->Reset();
596  dttf_q_wheel[wh]->Reset();
597  dttf_pt_wheel[wh]->Reset();
598  dttf_phi_wheel[wh]->Reset();
599  dttf_quality_wheel[wh]->Reset();
601 
602  double wheelEtaAll = 0;
603  double wheelEtaFine = 0;
604  memset( wheelBx, 0, 4 * sizeof(int) );
605  memset( wheelBx2nd, 0, 4 * sizeof(int) );
606 
608  memset( qualities, 0, 8 * sizeof(int) );
609 
615  "%s/dttf_07_phi_vs_etaFine_wh%s",
616  "%s/dttf_08_phi_vs_etaCoarse_wh%s", wh );
617 
619  "%s/2ND_TRACK_ONLY/dttf_06_phi_vs_eta_wh%s_2ndTrack",
620  wh );
621 
622 
626  for ( unsigned int sector = 1; sector < 13; ++sector ) {
627 
631  sprintf( hname, "%s/BX_BySector/dttf_bx_wh%s_se%d",
632  wheelpath_[wh].c_str(), wheel_[wh].c_str(), sector );
633 
634  TH1F * bxsector = getTH1F(hname);
635  if ( ! bxsector ) {
636  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get TH1D "
637  << std::string(hname);
638  } else {
639 
640  for ( unsigned int bx = 1; bx < 4 ; ++bx ) {
641 
642  int bxval = bxsector->GetBinContent( bx );
643 
644  if ( bx == 2 ) {
645  // if ( wh == 2 )
646  // dttf_occupancySummary->setBinContent( wh+1, sector, bxval*14 );
647  // else
648  // dttf_occupancySummary->setBinContent( wh+1, sector, bxval );
649  dttf_occupancySummary->setBinContent( wh+1, sector, bxval );
650  dttf_occupancySummary_test->setBinContent( wh+1, sector, bxval );
651  dttf_nTracks_wheel[wh]->setBinContent(sector, bxval );
652  }
653  wheelBx[bx] += bxval;
654  dttf_bx_wheel_summary[wh]->setBinContent( sector, bx, bxval );
655  }
656  }
657 
658 
662  sprintf( hname, "%s/BX_BySector/2ND_TRACK_ONLY/dttf_bx_2ndTrack_wh%s_se%d",
663  wheelpath_[wh].c_str(), wheel_[wh].c_str(), sector );
664 
665  TH1F * bxsector2nd = getTH1F(hname);
666  if ( ! bxsector2nd ) {
667  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get TH1D "
668  << std::string(hname);
669  } else {
670 
671  for ( unsigned int bx = 1; bx < 4 ; ++bx ) {
672  int bxval = bxsector2nd->GetBinContent( bx );
673 
674  if ( bx == 2 ) {
675  dttf_2ndTrack_Summary->setBinContent( wh+1, sector, bxval );
676  dttf_occupancySummary_2ndTrack->setBinContent(wh+1, sector, bxval);
677  dttf_nTracks_wheel_2ndTrack[wh]->setBinContent(sector, bxval );
678  }
679  wheelBx2nd[bx] += bxval;
680  dttf_bx_wheel_summary_2ndTrack[wh]->setBinContent(sector, bx, bxval);
681  }
682  }
683 
687  sprintf( hname, "%s/Charge/dttf_charge_wh%s_se%d",
688  wheelpath_[wh].c_str(), wheel_[wh].c_str(), sector );
689  TH1F * tmp = getTH1F(hname);
690  if ( ! tmp ) {
691  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get TH1D "
692  << std::string(hname);
693  } else {
694  dttf_q_integ->getTH1F()->Add( tmp );
695  dttf_q_wheel[wh]->getTH1F()->Add( tmp );
696  }
697 
701  sprintf( hname, "%s/PT/dttf_pt_wh%s_se%d",
702  wheelpath_[wh].c_str(), wheel_[wh].c_str(), sector );
703  tmp = getTH1F(hname);
704  if ( ! tmp ) {
705  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get TH1D "
706  << std::string(hname);
707  } else {
708  dttf_pt_integ->getTH1F()->Add( tmp );
709  dttf_pt_wheel[wh]->getTH1F()->Add( tmp );
710  }
711 
712 
716  sprintf( hname, "%s/Phi/dttf_phi_wh%s_se%d",
717  wheelpath_[wh].c_str(), wheel_[wh].c_str(), sector );
718  tmp = getTH1F(hname);
719  if ( ! tmp ) {
720  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get TH1D "
721  << std::string(hname);
722  } else {
723  dttf_phi_integ->getTH1F()->Add( tmp );
724  dttf_phi_wheel[wh]->getTH1F()->Add( tmp );
725  }
726 
727 
731  double highQual = 0;
732  double denHighQual = 0;
733  sprintf( hname, "%s/Quality/dttf_qual_wh%s_se%d",
734  wheelpath_[wh].c_str(), wheel_[wh].c_str(), sector );
735  tmp = getTH1F(hname);
736  if ( ! tmp ) {
737  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get TH1D "
738  << std::string(hname);
739  } else {
740 
741  dttf_quality_wheel[wh]->getTH1F()->Add( tmp );
742 
743 
744  for ( unsigned int qual = 1; qual < 4 ; ++qual ) {
745  double bincontent = tmp->GetBinContent( qual );
746  qualities[qual] += bincontent;
747  denHighQual += bincontent;
748  dttf_quality_summary_wheel[wh]->setBinContent(sector, qual, bincontent);
749  }
750 
751  for ( unsigned int qual = 4; qual < 8 ; ++qual ) {
752  double bincontent = tmp->GetBinContent( qual );
753  qualities[qual] += bincontent;
754  dttf_quality_summary_wheel[wh]->setBinContent(sector, qual, bincontent);
755  denHighQual += bincontent;
756  highQual += bincontent;
757  }
758 
759  }
760  if ( denHighQual > 0 ) highQual /= denHighQual;
761  dttf_highQual_Summary->setBinContent( wh+1, sector, highQual );
762 
763 
767  sprintf( hname, "%s/Eta/dttf_eta_wh%s_se%d",
768  wheelpath_[wh].c_str(), wheel_[wh].c_str(), sector );
769  tmp = getTH1F(hname);
770  if ( ! tmp ) {
771  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get TH1D "
772  << std::string(hname);
773  } else {
774  dttf_eta_integ->getTH1F()->Add( tmp );
775  dttf_eta_wheel[wh]->getTH1F()->Add( tmp );
776  }
777 
778 
782  sprintf( hname, "%s/EtaFineFraction/dttf_etaFine_fraction_wh%s_se%d",
783  wheelpath_[wh].c_str(), wheel_[wh].c_str(), sector );
784  tmp = getTH1F(hname);
785  if ( ! tmp ) {
786  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get TH1D "
787  << std::string(hname);
788  } else {
789  double fine = tmp->GetBinContent( 1 );
790  double coarse = tmp->GetBinContent( 2 );
791  double tot = fine + coarse;
792  wheelEtaAll += tot;
793  wheelEtaFine += fine;
794  if ( tot > 0 ) {
795  dttf_fine_fraction_wh[wh]->setBinContent( sector, fine/tot );
796  }
797  }
798 
799  }
800 
804  if ( wheelEtaAll > 0 ) {
805  dttf_eta_fine_fraction->setBinContent( wh+1, wheelEtaFine/wheelEtaAll );
806  }
807 
811  dttf_nTracks_integ->setBinContent( wh+1, wheelBx[2] );
812  dttf_nTracks_integ_2ndTrack->setBinContent( wh+1, wheelBx2nd[2] );
813 
817  for ( unsigned int bx = 1; bx < 4; ++bx ) {
818 
819  dttf_bx_wheel_integ[wh]->setBinContent( bx, wheelBx[bx] );
820  dttf_bx_summary->setBinContent( wh+1, bx, wheelBx[bx] );
821  wheelSumBx[bx] += wheelBx[bx];
822 
823  dttf_bx_wheel_integ_2ndTrack[wh]->setBinContent( bx, wheelBx2nd[bx] );
824  dttf_bx_summary_2ndTrack->setBinContent( wh+1, bx, wheelBx2nd[bx] );
825  wheelSumBx2nd[bx] += wheelBx2nd[bx];
826 
827  }
828 
829 
833  for ( unsigned int qual = 1; qual < 8 ; ++qual ) {
834  dttf_quality_summary->setBinContent( wh+1, qual, qualities[qual] );
835  dttf_quality_integ->getTH1F()->AddBinContent( qual, qualities[qual] );
836  }
837 
838 
848  normalize( dttf_eta_wheel[wh]->getTH1F() );
849  normalize( dttf_q_wheel[wh]->getTH1F() );
850  normalize( dttf_pt_wheel[wh]->getTH1F() );
851  normalize( dttf_phi_wheel[wh]->getTH1F() );
852 
856  double scale = wheelBx[2];
857  if ( scale > 0 ) {
858  scale = 1/scale;
859  normalize( dttf_bx_wheel_integ[wh]->getTH1F(), scale );
860  }
861 
862  scale = wheelBx2nd[2];
863  if ( scale > 0 ) {
864  scale = 1/scale;
866  }
867 
868 
869 
870 
876 
877 
881  sprintf( hname, "%s/2ND_TRACK_ONLY/dttf_07_eta_wh%s_2ndTrack",
882  wheelpath_[wh].c_str(), wheel_[wh].c_str() );
883 
884  TH1F * tmp = getTH1F(hname);
885  if ( ! tmp ) {
886  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get TH1D "
887  << std::string(hname);
888  } else {
889  dttf_eta_integ_2ndTrack->getTH1F()->Add( tmp );
890  }
891 
895  sprintf( hname, "%s/2ND_TRACK_ONLY/dttf_08_phi_wh%s_2ndTrack",
896  wheelpath_[wh].c_str(), wheel_[wh].c_str() );
897  tmp = getTH1F(hname);
898  if ( ! tmp ) {
899  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get TH1D "
900  << std::string(hname);
901  } else {
902  dttf_phi_integ_2ndTrack->getTH1F()->Add( tmp );
903  }
904 
905 
909  sprintf( hname, "%s/2ND_TRACK_ONLY/dttf_09_pt_wh%s_2ndTrack",
910  wheelpath_[wh].c_str(), wheel_[wh].c_str() );
911  tmp = getTH1F(hname);
912  if ( ! tmp ) {
913  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get TH1D "
914  << std::string(hname);
915  } else {
916  dttf_pt_integ_2ndTrack->getTH1F()->Add( tmp );
917  }
918 
922  sprintf( hname, "%s/2ND_TRACK_ONLY/dttf_10_charge_wh%s_2ndTrack",
923  wheelpath_[wh].c_str(), wheel_[wh].c_str() );
924  tmp = getTH1F(hname);
925  if ( ! tmp ) {
926  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get TH1D "
927  << std::string(hname);
928  } else {
929  dttf_q_integ_2ndTrack->getTH1F()->Add( tmp );
930  }
931 
935  sprintf( hname, "%s/2ND_TRACK_ONLY/dttf_04_quality_wh%s_2ndTrack",
936  wheelpath_[wh].c_str(), wheel_[wh].c_str() );
937  tmp = getTH1F(hname);
938  if ( ! tmp ) {
939  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get TH1D "
940  << std::string(hname);
941  } else {
942  for ( unsigned int qual = 1; qual < 8; ++qual ) {
943  double binqual = tmp->GetBinContent( qual );
944  dttf_quality_integ_2ndTrack->getTH1F()->AddBinContent( qual, binqual );
945  dttf_quality_summary_2ndTrack->setBinContent( wh+1, qual, binqual );
946  }
947  }
948 
949 
950  }
951 
955  for ( unsigned int bx = 1; bx < 4; ++bx ) {
956  dttf_bx_integ->setBinContent( bx, wheelSumBx[bx] );
957  dttf_bx_integ_2ndTrack->setBinContent( bx, wheelSumBx2nd[bx] );
958  }
959 
963  double scale = wheelSumBx[2];
964  if ( scale > 0 ) {
965  scale = 1./scale;
967  }
968 
969  scale = wheelSumBx2nd[2];
970  if ( scale > 0 ) {
971  scale = 1./scale;
973  }
974 
975 
976 }
977 
978 
979 
980 //--------------------------------------------------------
982 {
983  char hname[60];
984  sprintf( hname, "%s/dttf_tracks_with_gmt_match", gmtpath_.c_str() );
985  TH2F * gmt_match = getTH2F(hname);
986  if ( ! gmt_match ) {
987  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get TH1D "
988  << std::string(hname);
989  return;
990  }
991 
992 
993 
994  sprintf( hname, "%s/dttf_tracks_without_gmt_match", gmtpath_.c_str() );
995  TH2F * gmt_missed = getTH2F(hname);
996  if ( ! gmt_missed ) {
997  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get TH1D "
998  << std::string(hname);
999  return;
1000  }
1001 
1002 
1003  sprintf( hname, "%s/dttf_missing_tracks_in_gmt", gmtpath_.c_str() );
1004  TH2F * gmt_ghost = getTH2F(hname);
1005  if ( ! gmt_ghost ) {
1006  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get TH1D "
1007  << std::string(hname);
1008  return;
1009  }
1010 
1011  int match = gmt_match->Integral();
1012  int missed = gmt_missed->Integral();
1013  int ghost = gmt_ghost->Integral();
1014  float tot = match + missed + ghost;
1015  if ( tot > 0 ) {
1016  double val = ghost/tot;
1017  dttf_gmt_matching->setBinContent( 1, val );
1018  val = match/tot;
1019  dttf_gmt_matching->setBinContent( 2, val );
1020  val = missed/tot;
1021  dttf_gmt_matching->setBinContent( 3, val );
1022  }
1023 }
1024 
1025 
1026 
1027 //--------------------------------------------------------
1028 TH1F * L1TDTTFClient::getTH1F(const char * hname)
1029 {
1030 
1031  MonitorElement * me = dbe_->get(hname);
1032  if ( ! me ) {
1033  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get ME "
1034  << std::string(hname);
1035  return NULL;
1036  }
1037 
1038 
1039  // edm::LogInfo("L1TDTTFClient::getTH1F") << "#################### "
1040  // << std::string(hname);
1041 
1042  return me->getTH1F();
1043 
1044 }
1045 
1046 
1047 //--------------------------------------------------------
1048 TH2F * L1TDTTFClient::getTH2F(const char * hname)
1049 {
1050 
1051  MonitorElement * me = dbe_->get(hname);
1052  if ( ! me ) {
1053  edm::LogError("L1TDTTFClient::makeSummary:ME") << "Failed to get ME "
1054  << std::string(hname);
1055  return NULL;
1056  }
1057 
1058 
1059  // edm::LogInfo("L1TDTTFClient::getTH2F") << "#################### "
1060  // << std::string(hname);
1061 
1062  return me->getTH2F();
1063 
1064 }
1065 
1066 
1067 //--------------------------------------------------------
1068 
1069 //--------------------------------------------------------
1070 void L1TDTTFClient::buildHighQualityPlot( TH2F * occupancySummary,
1071  MonitorElement * highQual_Summary,
1072  const std::string & path )
1073 {
1074 
1075  char hname[150];
1076 
1080  for ( unsigned int wh = 0; wh < 6 ; ++wh ) {
1081  sprintf( hname, path.c_str(), wheelpath_[wh].c_str(), wheel_[wh].c_str() );
1082 
1083  TH2F * quality = getTH2F(hname);
1084  if ( ! quality ) {
1085  edm::LogError("L1TDTTFClient::buildHighQualityPlot")
1086  << "Failed to get TH2F " << std::string(hname);
1087  } else {
1088 
1089  for ( unsigned int sec = 1; sec < 13 ; ++sec ) {
1090  double denHighQual = occupancySummary->GetBinContent( wh+1, sec );
1091  double val = 0;
1092  if ( denHighQual > 0 ) {
1093  for ( unsigned int qual = 4; qual < 8 ; ++qual ) {
1094  val += quality->GetBinContent( qual, sec );
1095  }
1096  val /= denHighQual;
1097  }
1098  highQual_Summary->setBinContent( wh+1, sec, val );
1099  }
1100  }
1101  }
1102 }
1103 
1104 //--------------------------------------------------------
1106  MonitorElement * phi_eta_coarse_integ,
1107  MonitorElement * phi_eta_integ,
1108  const std::string & path_fine,
1109  const std::string & path_coarse,
1110  int wh )
1111 {
1112 
1113  char hname[150];
1114  sprintf( hname, path_fine.c_str(),
1115  wheelpath_[wh].c_str(), wheel_[wh].c_str() );
1116 
1117  TH2F * phi_vs_eta_fine = getTH2F(hname);
1118  if ( ! phi_vs_eta_fine ) {
1119  edm::LogError("L1TDTTFClient::buildPhiEtaPloOtFC")
1120  << "Failed to get TH1D " << std::string(hname);
1121  }
1122 
1123  sprintf( hname, path_coarse.c_str(),
1124  wheelpath_[wh].c_str(), wheel_[wh].c_str() );
1125  TH2F * phi_vs_eta_coarse = getTH2F(hname);
1126  if ( ! phi_vs_eta_coarse ) {
1127  edm::LogError("L1TDTTFClient::buildPhiEtaPlotOFC")
1128  << "Failed to get TH1D " << std::string(hname);
1129  }
1130 
1131  if ( ! phi_vs_eta_fine || ! phi_vs_eta_coarse ) {
1132  return;
1133  }
1134 
1135  for ( unsigned int phi = 1; phi < 145 ; ++phi ) {
1136  float start = 0;
1137  int nbins = 0;
1138  switch ( wh ) {
1139  case 0 : start = 0; nbins = 18; break; // N2
1140  case 1 : start = 8; nbins = 20; break; // N1
1141  case 2 : start = 22; nbins = 10; break; // N0
1142  case 3 : start = 22; nbins = 20; break; // P0
1143  case 4 : start = 36; nbins = 20; break; // P1
1144  case 5 : start = 46; nbins = 18; break; // P2
1145  default : start = 0; nbins = 0; break; // BOH
1146  }
1147 
1148  for ( int eta = 1; eta <= nbins ; ++eta ) {
1149  double setbin = eta + start;
1150 
1151  double valfine = phi_vs_eta_fine->GetBinContent( eta, phi )
1152  + phi_eta_fine_integ->getBinContent( setbin, phi );
1153 
1154  double valcoarse = phi_vs_eta_coarse->GetBinContent( eta, phi )
1155  + phi_eta_coarse_integ->getBinContent( setbin, phi );
1156 
1157  phi_eta_fine_integ->setBinContent( setbin, phi, valfine );
1158  phi_eta_coarse_integ->setBinContent( setbin, phi, valcoarse );
1159  phi_eta_integ->setBinContent( setbin, phi, valfine+valcoarse );
1160 
1161  }
1162 
1163  // double underflow_f = phi_vs_eta_fine->GetBinContent( 0, phi )
1164  // + phi_eta_fine_integ->getBinContent( 1, phi );
1165  // phi_eta_fine_integ->setBinContent( 1, phi, underflow_f );
1166  //
1167  // double underflow_c = phi_vs_eta_coarse->GetBinContent( 0, phi )
1168  // + phi_eta_coarse_integ->getBinContent( 1, phi );
1169  // phi_eta_coarse_integ->setBinContent( 1, phi, underflow_c );
1170  //
1171  // double overflow_f = phi_vs_eta_fine->GetBinContent( nbins+1, phi )
1172  // + phi_eta_fine_integ->getBinContent( 64 );
1173  // phi_eta_fine_integ->setBinContent( 64, phi, overflow_f );
1174  //
1175  // double overflow_c = phi_vs_eta_coarse->GetBinContent( nbins+1, phi )
1176  // + phi_eta_coarse_integ->getBinContent( 64, phi );
1177  // phi_eta_coarse_integ->setBinContent( 64, phi, overflow_c );
1178  //
1179  // double underflow = underflow_f + underflow_c;
1180  // phi_eta_integ->setBinContent( 1, phi, underflow );
1181  //
1182  // double overflow = overflow_f + overflow_c;
1183  // phi_eta_integ->setBinContent( 64, phi, overflow );
1184 
1185  }
1186 
1187 }
1188 
1189 
1190 //--------------------------------------------------------
1192  const std::string & path,
1193  int wh )
1194 {
1195  char hname[100];
1196  sprintf( hname, path.c_str(),
1197  wheelpath_[wh].c_str(), wheel_[wh].c_str() );
1198 
1199  TH2F * phi_vs_eta = getTH2F(hname);
1200  if ( ! phi_vs_eta ) {
1201  edm::LogError("L1TDTTFClient::buildPhiEtaPlotO:ME") << "Failed to get TH1D "
1202  << std::string(hname);
1203  } else {
1204 
1205  for ( unsigned int phi = 1; phi < 145 ; ++phi ) {
1206  float start = 0;
1207  int nbins = 0;
1208  switch ( wh ) {
1209  case 0 : start = 0; nbins = 18; break; // N2
1210  case 1 : start = 8; nbins = 20; break; // N1
1211  case 2 : start = 22; nbins = 10; break; // N0
1212  case 3 : start = 22; nbins = 20; break; // P0
1213  case 4 : start = 36; nbins = 20; break; // P1
1214  case 5 : start = 46; nbins = 18; break; // P2
1215  default : start = 0; nbins = 0; break; // BOH
1216  }
1217 
1218  for ( int eta = 1; eta <= nbins ; ++eta ) {
1219  double setbin = eta + start;
1220  double val = phi_vs_eta->GetBinContent( eta, phi )
1221  + phi_eta_integ->getBinContent( setbin, phi );
1222  phi_eta_integ->setBinContent( setbin, phi, val );
1223  }
1224 
1225  double underflow = phi_vs_eta->GetBinContent( 0, phi )
1226  + phi_eta_integ->getBinContent( 1, phi );
1227  phi_eta_integ->setBinContent( 1, phi, underflow );
1228 
1229  double overflow = phi_vs_eta->GetBinContent( nbins+1, phi )
1230  + phi_eta_integ->getBinContent( 64 );
1231  phi_eta_integ->setBinContent( 64, phi, overflow );
1232 
1233  }
1234  }
1235 }
1236 
1237 
1238 // //--------------------------------------------------------
1239 // void L1TDTTFClient::buildPhiEtaPlot( MonitorElement * phi_eta_integ,
1240 // const std::string & path ,
1241 // int wh)
1242 // {
1243 // char hname[60];
1244 // sprintf( hname, "%s/dttf_phi_eta_wh%s",
1245 // wheelpath_[wh].c_str(), wheel_[wh].c_str() );
1246 //
1247 // TH2F * phi_vs_eta = getTH2F(hname);
1248 // if ( ! phi_vs_eta ) {
1249 // edm::LogError("L1TDTTFClient::buildPhiEtaPlot:ME") << "Failed to get TH1D "
1250 // << std::string(hname);
1251 // } else {
1252 //
1253 //
1254 // for ( unsigned int phi = 1; phi < 145 ; ++phi ) {
1255 // for ( unsigned int eta = 1; eta < 65 ; ++eta ) {
1256 // double val = phi_vs_eta->GetBinContent( eta, phi )
1257 // + dttf_phi_eta_integ->getBinContent( eta, phi );
1258 // dttf_phi_eta_integ->setBinContent( eta, phi, val );
1259 // }
1260 //
1261 // }
1262 // }
1263 // }
1264 //
1265 //
1266 // //--------------------------------------------------------
1267 // void L1TDTTFClient::buildPhiEtaPlotFC( MonitorElement * phi_eta_fine_integ,
1268 // MonitorElement * phi_eta_coarse_integ,
1269 // MonitorElement * phi_eta_integ,
1270 // const std::string & path_fine,
1271 // const std::string & path_coarse,
1272 // int wh )
1273 // {
1274 //
1275 // char hname[60];
1276 //
1277 // sprintf( hname, path_fine.c_str(),
1278 // wheelpath_[wh].c_str(), wheel_[wh].c_str() );
1279 // TH2F * phi_vs_eta_fine = getTH2F(hname);
1280 // if ( ! phi_vs_eta_fine ) {
1281 // edm::LogError("L1TDTTFClient::buildPhiEtaPlotFC")
1282 // << "Failed to get TH1D " << std::string(hname);
1283 // }
1284 //
1285 //
1286 // sprintf( hname, path_coarse.c_str(),
1287 // wheelpath_[wh].c_str(), wheel_[wh].c_str() );
1288 // TH2F * phi_vs_eta_coarse = getTH2F(hname);
1289 // if ( ! phi_vs_eta_coarse ) {
1290 // edm::LogError("L1TDTTFClient::buildPhiEtaPlotFC")
1291 // << "Failed to get TH1D " << std::string(hname);
1292 // }
1293 //
1294 // if ( ! phi_vs_eta_fine || ! phi_vs_eta_coarse ) {
1295 // return;
1296 // }
1297 //
1298 // for ( unsigned int phi = 1; phi < 145 ; ++phi ) {
1299 // for ( unsigned int eta = 1; eta < 65 ; ++eta ) {
1300 //
1301 // double valfine = phi_vs_eta_fine->GetBinContent( eta, phi )
1302 // + dttf_phi_eta_fine_integ->getBinContent( eta, phi );
1303 // dttf_phi_eta_fine_integ->setBinContent( eta, phi, valfine );
1304 // double valcoarse = phi_vs_eta_coarse->GetBinContent( eta, phi )
1305 // + dttf_phi_eta_coarse_integ->getBinContent( eta, phi );
1306 // dttf_phi_eta_coarse_integ->setBinContent( eta, phi, valcoarse );
1307 //
1308 // dttf_phi_eta_integ->setBinContent( eta, phi, valfine + valcoarse );
1309 //
1310 // }
1311 //
1312 // }
1313 // }
1314 
1315 
1316 
1317 
1318 //--------------------------------------------------------
1320 {
1321  me->setAxisTitle("Wheel", 1);
1322  me->setBinLabel(1, "N2", 1);
1323  me->setBinLabel(2, "N1", 1);
1324  me->setBinLabel(3, "N0", 1);
1325  me->setBinLabel(4, "P0", 1);
1326  me->setBinLabel(5, "P1", 1);
1327  me->setBinLabel(6, "P2", 1);
1328 
1329 }
1330 
1331 
1332 //--------------------------------------------------------
1334 {
1335 
1336  if( axis == 1 )
1337  me->setAxisTitle("Quality", axis);
1338  me->setBinLabel(1, "T34", axis);
1339  me->setBinLabel(2, "T23/24", axis);
1340  me->setBinLabel(3, "T12/13/14", axis);
1341  me->setBinLabel(4, "T234", axis);
1342  me->setBinLabel(5, "T134", axis);
1343  me->setBinLabel(6, "T123/124", axis);
1344  me->setBinLabel(7, "T1234", axis);
1345 }
1346 
1347 
1348 
1349 
1350 
1351 
1352 
1353 
1354 
MonitorElement * dttf_bx_integ_2ndTrack
Definition: L1TDTTFClient.h:99
MonitorElement * dttf_gmt_matching
Definition: L1TDTTFClient.h:91
MonitorElement * dttf_occupancySummary
Definition: L1TDTTFClient.h:75
MonitorElement * dttf_quality_summary
Definition: L1TDTTFClient.h:80
void setBinContent(int binx, double content)
set content of bin (1-D)
L1TDTTFClient(const edm::ParameterSet &ps)
Constructor.
tuple start
Check for commandline option errors.
Definition: dqm_diff.py:58
MonitorElement * dttf_q_wheel[6]
TH2F * getTH2F(const char *hname)
MonitorElement * dttf_eta_integ_2ndTrack
MonitorElement * book1D(const char *name, const char *title, int nchX, double lowX, double highX)
Book 1D histogram.
Definition: DQMStore.cc:722
void buildPhiEtaPlotO(MonitorElement *phi_eta_integ, const std::string &path, int wh)
void setGMTsummary()
MonitorElement * dttf_quality_integ_2ndTrack
MonitorElement * dttf_eta_wheel[6]
void endLuminosityBlock(const edm::LuminosityBlock &lumiSeg, const edm::EventSetup &c)
DQM Client Diagnostic.
void beginJob(void)
BeginJob.
MonitorElement * dttf_nTracks_integ
Definition: L1TDTTFClient.h:74
MonitorElement * dttf_quality_integ
Definition: L1TDTTFClient.h:79
std::string wheelpath_[6]
Definition: L1TDTTFClient.h:69
void setBinLabel(int bin, const std::string &label, int axis=1)
set bin label for x, y or z axis (axis=1, 2, 3 respectively)
#define NULL
Definition: scimark2.h:8
MonitorElement * dttf_bx_wheel_integ_2ndTrack[6]
MonitorElement * dttf_bx_wheel_summary[6]
T eta() const
MonitorElement * dttf_pt_integ_2ndTrack
void endJob()
Endjob.
MonitorElement * dttf_bx_integ
Definition: L1TDTTFClient.h:77
MonitorElement * dttf_phi_eta_fine_integ
Definition: L1TDTTFClient.h:83
MonitorElement * dttf_highQual_Summary_2ndTrack
MonitorElement * dttf_phi_wheel[6]
MonitorElement * dttf_phi_eta_integ
Definition: L1TDTTFClient.h:84
MonitorElement * dttf_quality_summary_wheel[6]
MonitorElement * dttf_pt_integ
Definition: L1TDTTFClient.h:87
MonitorElement * dttf_phi_eta_coarse_integ
Definition: L1TDTTFClient.h:82
virtual ~L1TDTTFClient()
Destructor.
TH2F * occupancy_r_
counter
Definition: L1TDTTFClient.h:65
MonitorElement * dttf_occupancySummary_2ndTrack
Definition: L1TDTTFClient.h:97
void beginRun(const edm::Run &r, const edm::EventSetup &c)
BeginRun.
MonitorElement * dttf_eta_integ
Definition: L1TDTTFClient.h:88
MonitorElement * dttf_2ndTrack_Summary
Definition: L1TDTTFClient.h:92
std::string gmtpath_
Definition: L1TDTTFClient.h:71
MonitorElement * dttf_q_integ_2ndTrack
MonitorElement * get(const std::string &path) const
get ME from full pathname (e.g. &quot;my/long/dir/my_histo&quot;)
Definition: DQMStore.cc:1473
MonitorElement * dttf_bx_wheel_summary_2ndTrack[6]
DQMStore * dbe_
Definition: L1TDTTFClient.h:66
void beginLuminosityBlock(const edm::LuminosityBlock &lumiSeg, const edm::EventSetup &context)
void endRun(const edm::Run &r, const edm::EventSetup &c)
EndRun.
MonitorElement * dttf_bx_summary
Definition: L1TDTTFClient.h:76
MonitorElement * dttf_quality_wheel[6]
TH1F * getTH1F(void) const
void buildSummaries()
TH1F * getTH1F(const char *hname)
MonitorElement * dttf_eta_fine_fraction
Definition: L1TDTTFClient.h:85
std::vector< std::vector< double > > tmp
Definition: MVATrainer.cc:100
std::string l1tdttffolder_
Definition: L1TDTTFClient.h:59
double getBinContent(int binx) const
get content of bin (1-D)
void buildHighQualityPlot(TH2F *occupancySummary, MonitorElement *highQual_Summary, const std::string &path)
MonitorElement * dttf_occupancySummary_test
Definition: L1TDTTFClient.h:94
MonitorElement * dttf_fine_fraction_wh[6]
void setQualLabel(MonitorElement *me, int axis)
MonitorElement * dttf_nTracks_wheel[6]
void analyze(const edm::Event &e, const edm::EventSetup &c)
Fake Analyze.
void buildPhiEtaPlotOFC(MonitorElement *phi_eta_fine_integ, MonitorElement *phi_eta_coarse_integ, MonitorElement *phi_eta_integ, const std::string &path_fine, const std::string &path_coarse, int wh)
MonitorElement * dttf_bx_summary_2ndTrack
Definition: L1TDTTFClient.h:98
MonitorElement * dttf_nTracks_integ_2ndTrack
Definition: L1TDTTFClient.h:96
MonitorElement * dttf_phi_integ_2ndTrack
std::pair< typename Association::data_type::first_type, double > match(Reference key, Association association, bool bestMatchByMaxValue)
Generic matching function.
Definition: Utils.h:6
MonitorElement * dttf_pt_wheel[6]
MonitorElement * dttf_nTracks_wheel_2ndTrack[6]
TH2F * getTH2F(void) const
MonitorElement * book2D(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY)
Book 2D histogram.
Definition: DQMStore.cc:850
MonitorElement * dttf_phi_integ
Definition: L1TDTTFClient.h:86
MonitorElement * dttf_highQual_Summary
Definition: L1TDTTFClient.h:81
void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)
void Reset(void)
reset ME (ie. contents, errors, etc)
MonitorElement * dttf_q_integ
Definition: L1TDTTFClient.h:89
MonitorElement * dttf_bx_wheel_integ[6]
void normalize(T *me)
std::string inclusivepath_
Definition: L1TDTTFClient.h:70
std::string testpath_
Definition: L1TDTTFClient.h:72
void setCurrentFolder(const std::string &fullpath)
Definition: DQMStore.cc:434
Definition: Run.h:36
void setWheelLabel(MonitorElement *me)
std::string wheel_[6]
Definition: L1TDTTFClient.h:68
MonitorElement * dttf_quality_summary_2ndTrack
Definition: DDAxes.h:10
MonitorElement * dttf_phi_eta_integ_2ndTrack