CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
TrigResRateMon.h
Go to the documentation of this file.
1 #ifndef TRIGRESRATEMON_H
2 #define TRIGRESRATEMON_H
3 // -*- C++ -*-
4 //
5 // Package: TrigResRateMon
6 // Class: TrigResRateMon
7 //
15 // Original Author:
16 // Vladimir Rekovic, July 2010
17 //
18 //
19 //
20 //
21 
22 // system include files
23 #include <memory>
24 #include <unistd.h>
25 
26 
27 // user include files
30 
36 
42 
43 // added VR
49 
51 
59 
60 /*
61  needs cleaining of include statments (VR)
62 */
63 
66 
69 
71 
72 //for LumiScalers in getByToken method
74 
75 #include <iostream>
76 #include <fstream>
77 #include <vector>
78 #include <set>
79 
80 namespace edm {
81  class TriggerNames;
82 }
83 
84 //typedef std::multimap<float,int> fimmap ;
85 //typedef std::set<fimmap , less<fimmap> > mmset;
86 
88 
89  public:
90  explicit TrigResRateMon(const edm::ParameterSet&);
92 
93  //void cleanDRMatchSet(mmset& tempSet);
94 
96  //edm::Handle<reco::BeamSpot> fBeamSpotHandle;
97 
98  private:
99  virtual void beginJob() ;
100  virtual void analyze(const edm::Event&, const edm::EventSetup&);
101  virtual void endJob() ;
102 
103  // BeginRun
104  void beginRun(const edm::Run& run, const edm::EventSetup& c);
105 
106  // EndRun
107  void endRun(const edm::Run& run, const edm::EventSetup& c);
108  void setupHltMatrix(const std::string& label, std::vector<std::string> & paths);
109  void setupStreamMatrix(const std::string& label, std::vector<std::string> & paths);
110  void setupHltLsPlots();
111  void setupHltBxPlots();
112  void countHLTPathHitsEndLumiBlock(const int & lumi);
113  void countHLTGroupHitsEndLumiBlock(const int & lumi);
114  void countHLTGroupL1HitsEndLumiBlock(const int & lumi);
115  void countHLTGroupBXHitsEndLumiBlock(const int & lumi);
116 
117  void fillHltMatrix(const edm::TriggerNames & triggerNames, const edm::Event& iEvent, const edm::EventSetup& iSetup);
118 
119 
120  // JMS counts
121  // need to fill counts per path with the prescales
122  void fillCountsPerPath(const edm::Event& iEvent, const edm::EventSetup& iSetup);
123  void bookCountsPerPath();
125  void clearCountsPerPath();
126  void fillXsecPerDataset(const int& lumi);
127 
128  void filltestHisto(const int& lumi); //Robin
129  void bookTestHisto(); //Robin
130  // JMS lumi average
131  void addLumiToAverage (double lumi);
132  void clearLumiAverage ();
133 
134 
135  void normalizeHLTMatrix();
136 
139  bool hasL1Passed(const std::string & pathname, const edm::TriggerNames & triggerNames);
140  bool hasHLTPassed(const std::string & pathname, const edm::TriggerNames& triggerNames);
142 
143 
144  void beginLuminosityBlock(const edm::LuminosityBlock& lumiSeg, const edm::EventSetup& c);
145  void endLuminosityBlock(const edm::LuminosityBlock& lumiSeg, const edm::EventSetup& c);
146 
147  // ----------member data ---------------------------
148  int nev_;
149  int nStream_; //Robin
150  int nPass_; //Robin
151  bool passAny; //Robin
153  bool fLumiFlag;
154  bool fIsSetup;
155 
156  // JetID helper
157  //reco::helper::JetIDHelper *jetID;
158 
159  bool jmsDebug;
161  unsigned int zbIndex;
163 
167  std::vector<MonitorElement*> v_ME_HLTAll_LS;
168  std::vector<MonitorElement*> v_ME_Total_BX;
169  std::vector<MonitorElement*> v_ME_Total_BX_Norm;
170 
171  std::vector<MonitorElement*> v_ME_HLTPassPass;
172  std::vector<MonitorElement*> v_ME_HLTPassPass_Normalized;
173  std::vector<MonitorElement*> v_ME_HLTPass_Normalized_Any;
174 
185 
186  std::vector<std::string> fGroupName;
187 
188 
189  // JMS Keep track of rates and average lumi
190  std::vector<unsigned> rawCountsPerPD; //Robin
191  std::vector<unsigned> rawCountsPerPath; //Robin
192  std::vector<unsigned> finalCountsPerPath; //Robin
196 
197  //Robin---
204  // MonitorElement * meXsecPerLS;
205  // MonitorElement * meXsec;
206  // MonitorElement * meXsecPerIL;
207 
209  std::vector<MonitorElement*> v_ME_XsecPerLS;
210  std::vector<MonitorElement*> v_ME_CountsPerLS;
211  std::vector<MonitorElement*> v_ME_Xsec;
212 
213  // JMS Mask off some paths so that they don't mess with your plots
214 
215  std::vector< std::string > maskedPaths_;
216  std::vector< std::string > testPaths_; //Robin
217 
218  // JMS calcuate a reference cross section
219  // then scale
225  // unsigned testTrigCountsPS_; //Robin
227  //unsigned referenceTrigCounts_;
228 
229 
230  unsigned int nLS_;
231  double LSsize_ ;
233  unsigned int referenceBX_;
234  unsigned int Nbx_;
235 
236  bool plotAll_;
240 
241  unsigned int nBins_;
242  unsigned int nBins2D_;
243  unsigned int nBinsDR_;
244  unsigned int nBinsOneOverEt_;
245  double ptMin_ ;
246  double ptMax_ ;
247  double dRMax_ ;
249 
254  double muonEtaMax_;
255  double muonEtMin_;
256  double muonDRMatch_;
258  double tauEtaMax_;
259  double tauEtMin_;
260  double tauDRMatch_;
262  double jetEtaMax_;
263  double jetEtMin_;
264  double jetDRMatch_;
266  double bjetEtaMax_;
267  double bjetEtMin_;
268  double bjetDRMatch_;
271  double photonEtMin_;
274  double trackEtaMax_;
275  double trackEtMin_;
278  double metEtaMax_;
279  double metMin_;
280  double metDRMatch_;
282  double htEtaMax_;
283  double htMin_;
284  double htDRMatch_;
285  double htL1DRMatch_;
286  double sumEtMin_;
287 
288  // Muon quality cuts
289  double dxyCut_;
296 
297  std::vector<std::pair<std::string, std::string> > custompathnamepairs_;
298 
299  std::vector <std::vector <std::string> > triggerFilters_;
300  std::vector <std::vector <uint> > triggerFilterIndices_;
301  std::vector <std::pair<std::string, float> > fPathTempCountPair;
302  std::vector <std::pair<std::string, std::vector<int> > > fPathBxTempCountPair;
303  std::vector <std::pair<std::string, float> > fGroupTempCountPair;
304  std::vector <std::pair<std::string, float> > fGroupL1TempCountPair;
305 
306 
307  // This variable contains the list of PD, then the list of paths per PD
308 
309  std::vector <std::pair<std::string, std::vector<std::string> > > fGroupNamePathsPair;
310 
311  std::vector<std::string> specialPaths_;
312 
322  // data across paths
324  // helper class to store the data path
325 
327 
328  //define Token(-s)
332 
333 
334 
335  // create a class that can store all the strings
336  // associated with a primary dataset
337  // the
338  class DatasetInfo {
339 
340  public:
342  std::vector<std::string> pathNames;
343  std::set<std::string> maskedPaths;
344  std::set<std::string> testPaths; //Robin
345  // this tells you the name of the monitor element
346  // that has the counts per path saved
348 
349  // name of monitor element that has xsec per path saved
351 
352  // name of monitor element that has xsec per path saved
354 
356  // this tells you the name of the ME that has
357  // raw counts (no prescale accounting)
358  // for each path
359 
361 
362  // counts per path
363 
364  std::map<std::string, unsigned int> countsPerPath;
365 
366  //empty default constructor
367  DatasetInfo () {};
368 
369  // do we need a copy constructor?
370 
371  // function to set the paths and
372  // create zeroed counts per path
373 
374  void setPaths (const std::vector<std::string>& inputPaths){
375  pathNames = inputPaths;
376  for (std::vector<std::string>::const_iterator iPath = pathNames.begin();
377  iPath != pathNames.end();
378  iPath++) {
379  countsPerPath[*iPath] = 0;
380  }
381  }//end setPaths
382 
384  std::map<std::string, unsigned int>::iterator iCounts;
385  for (iCounts = countsPerPath.begin();
386  iCounts != countsPerPath.end();
387  iCounts++){
388  iCounts->second = 0;
389  }
390 
391  }// end clearCountsPerPath
392 
393  // put this here so that external people
394  // don't care how you store counts
396  countsPerPath[targetPath]++;
397  }
398 
399  void incrementCountsForPath (std::string targetPath, unsigned preScale){
400  countsPerPath[targetPath] += preScale;
401  }
402 
403  void printCountsPerPath () const {
404  std::map<std::string, unsigned int>::const_iterator iCounts;
405  for (iCounts = countsPerPath.begin();
406  iCounts != countsPerPath.end();
407  iCounts++){
409  << " " << iCounts->first
410  << " " << iCounts->second
411  << std::endl;
412  }
413 
414  }// end clearCountsPerPath
415 
416 
417  void fillXsecPlot (MonitorElement * myXsecPlot, double currentInstLumi, double secondsPerLS, double referenceXSec) {
418  // this will put the reference cross section in the denominator
419  fillXsecPlot( myXsecPlot, currentInstLumi*referenceXSec, secondsPerLS);
420  }
421 
422  void fillXsecPlot (MonitorElement * myXsecPlot, double currentInstLumi, double secondsPerLS) {
423 
424 
425  for (unsigned iPath = 0;
426  iPath < pathNames.size();
427  iPath++) {
428  std::string thisPathName = pathNames[iPath];
429  unsigned thisPathCounts = countsPerPath[thisPathName];
430 
431  // if this is a masked path, then skip it
432  if (maskedPaths.find(thisPathName) != maskedPaths.end()) {
433  //std::cout << "Path " << thisPathName << " is masked, not filling it " << std::endl;
434  continue;
435  }
437  TString thisName = thisPathName.c_str();
438  if ( thisName.Contains("L1") || thisName.Contains("L2") ){
439  continue;
440  }
441 
442  double xsec = 1.0;
443  // what should we fill when averageLumi == 0 ???
444  if (currentInstLumi > 0) {
445  xsec = thisPathCounts / (currentInstLumi*secondsPerLS);
446  } else if ( secondsPerLS > 0) {
447  xsec = (9e-10) ;
448  // xsec = thisPathCounts / secondsPerLS;
449  } else {
450  xsec = (9e-20) ;
451  // xsec = thisPathCounts;
452  }
453 
454  myXsecPlot->Fill(iPath, xsec);
455  //Robin ???
456  // if (currentInstLumi > 0) myXsecPlot->Fill(iPath, xsec);
457  //std::cout << datasetName << " " << thisPathName << " filled with xsec " << xsec << std::endl;
458 
459  }
460  } // end fill Xsec plot
461 
463  TH1F* tempRawCounts = myRawCountsPlot->getTH1F();
464  int binNumber = tempRawCounts->GetXaxis()->FindBin(pathName.c_str());
465  if (binNumber > 0) {
466  tempRawCounts->Fill(binNumber);
467  } else {
468  //std::cout << "Problem finding bin " << pathName << " in plot " << tempRawCounts->GetTitle() << std::endl;
469  }
470  }// end fill RawCountsForPath
471 
472  void setMaskedPaths (const std::vector<std::string>& inputPaths) {
473  for (unsigned i=0; i < inputPaths.size(); i++) {
474  std::string maskSubString = inputPaths[i];
475  for (unsigned j=0; j < pathNames.size(); j++) {
476  // If a path in the DS contains a masked substring
477  // Then mask that path
478  //
479  std::string candidateForRemoval = pathNames[j];
480  TString pNameTS (candidateForRemoval);
481  if ( pNameTS.Contains(maskSubString)){
482 
483  maskedPaths.insert(candidateForRemoval);
484  } // end if path contains substring
485  }// end for each path in ds
486  }
487  }// end setMaskedPaths
488 
490  std::cout << "======== Printing masked paths for " << datasetName <<" ======== " << std::endl;
491  for ( std::set<std::string>::const_iterator iMask = maskedPaths.begin();
492  iMask != maskedPaths.end();
493  iMask++) {
494  std::cout << (*iMask) << std::endl;
495  }
496  std::cout << "======DONE PRINTING=====" << std::endl;
497  }
498 
499  };
500 
501  // create a vector of the information
502  std::vector<DatasetInfo> primaryDataSetInformation;
503 
504  class PathInfo {
505 
507  pathIndex_(-1), denomPathName_("unset"), pathName_("unset"), l1pathName_("unset"), filterName_("unset"), processName_("unset"), objectType_(-1) {};
508 
509  public:
510 
512  {
513  filters_ = filters;
514  }
515 
516  void setHistos(
517 
518  MonitorElement* const NOn,
519  MonitorElement* const onEtOn,
520  MonitorElement* const onOneOverEtOn,
521  MonitorElement* const onEtavsonPhiOn,
522  MonitorElement* const NOff,
523  MonitorElement* const offEtOff,
524  MonitorElement* const offEtavsoffPhiOff,
525  MonitorElement* const NL1,
526  MonitorElement* const l1EtL1,
527  MonitorElement* const l1Etavsl1PhiL1,
528  MonitorElement* const NL1On,
529  MonitorElement* const l1EtL1On,
530  MonitorElement* const l1Etavsl1PhiL1On,
531  MonitorElement* const NL1Off,
532  MonitorElement* const offEtL1Off,
533  MonitorElement* const offEtavsoffPhiL1Off,
534  MonitorElement* const NOnOff,
535  MonitorElement* const offEtOnOff,
536  MonitorElement* const offEtavsoffPhiOnOff,
537  MonitorElement* const NL1OnUM,
538  MonitorElement* const l1EtL1OnUM,
539  MonitorElement* const l1Etavsl1PhiL1OnUM,
540  MonitorElement* const NL1OffUM,
541  MonitorElement* const offEtL1OffUM,
542  MonitorElement* const offEtavsoffPhiL1OffUM,
543  MonitorElement* const NOnOffUM,
544  MonitorElement* const offEtOnOffUM,
545  MonitorElement* const offEtavsoffPhiOnOffUM,
546  MonitorElement* const offDRL1Off,
547  MonitorElement* const offDROnOff,
548  MonitorElement* const l1DRL1On)
549  {
550 
551  NOn_ = NOn;
552  onEtOn_ = onEtOn;
553  onOneOverEtOn_ = onOneOverEtOn;
554  onEtavsonPhiOn_ = onEtavsonPhiOn;
555  NOff_ = NOff;
556  offEtOff_ = offEtOff;
557  offEtavsoffPhiOff_ = offEtavsoffPhiOff;
558  NL1_ = NL1;
559  l1EtL1_ = l1EtL1;
560  l1Etavsl1PhiL1_ = l1Etavsl1PhiL1;
561  NL1On_ = NL1On;
562  l1EtL1On_ = l1EtL1On;
563  l1Etavsl1PhiL1On_ = l1Etavsl1PhiL1On;
564  NL1Off_ = NL1Off;
565  offEtL1Off_ = offEtL1Off;
566  offEtavsoffPhiL1Off_ = offEtavsoffPhiL1Off;
567  NOnOff_ = NOnOff;
568  offEtOnOff_ = offEtOnOff;
569  offEtavsoffPhiOnOff_ = offEtavsoffPhiOnOff;
570  NL1OnUM_ = NL1OnUM;
571  l1EtL1OnUM_ = l1EtL1OnUM;
572  l1Etavsl1PhiL1OnUM_ = l1Etavsl1PhiL1OnUM;
573  NL1OffUM_ = NL1OffUM;
574  offEtL1OffUM_ = offEtL1OffUM;
575  offEtavsoffPhiL1OffUM_ = offEtavsoffPhiL1OffUM;
576  NOnOffUM_ = NOnOffUM;
577  offEtOnOffUM_ = offEtOnOffUM;
578  offEtavsoffPhiOnOffUM_ = offEtavsoffPhiOnOffUM;
579  offDRL1Off_ = offDRL1Off;
580  offDROnOff_ = offDROnOff;
581  l1DRL1On_ = l1DRL1On;
582 
583  }
584 
586  return NOn_;
587  }
589  return onEtOn_;
590  }
592  return onOneOverEtOn_;
593  }
595  return onEtavsonPhiOn_;
596  }
598  return NOff_;
599  }
601  return offEtOff_;
602  }
604  return offEtavsoffPhiOff_;
605  }
607  return NL1_;
608  }
610  return l1EtL1_;
611  }
613  return l1Etavsl1PhiL1_;
614  }
616  return NL1On_;
617  }
619  return l1EtL1On_;
620  }
622  return l1Etavsl1PhiL1On_;
623  }
625  return NL1Off_;
626  }
628  return offEtL1Off_;
629  }
631  return offEtavsoffPhiL1Off_;
632  }
634  return NOnOff_;
635  }
637  return offEtOnOff_;
638  }
640  return offEtavsoffPhiOnOff_;
641  }
643  return NL1OnUM_;
644  }
646  return l1EtL1OnUM_;
647  }
649  return l1Etavsl1PhiL1OnUM_;
650  }
652  return NL1OffUM_;
653  }
655  return offEtL1OffUM_;
656  }
658  return offEtavsoffPhiL1OffUM_;
659  }
661  return NOnOffUM_;
662  }
664  return offEtOnOffUM_;
665  }
667  return offEtavsoffPhiOnOffUM_;
668  }
670  return offDRL1Off_;
671  }
673  return offDROnOff_;
674  }
676  return l1DRL1On_;
677  }
679  return filters_;
680  }
681  const std::string getLabel(void ) const {
682  return filterName_;
683  }
684  void setLabel(std::string labelName){
685  filterName_ = labelName;
686  return;
687  }
688  const std::string & getPath(void ) const {
689  return pathName_;
690  }
691  const std::string & getl1Path(void ) const {
692  return l1pathName_;
693  }
694  const int getL1ModuleIndex(void ) const {
695  return l1ModuleIndex_;
696  }
697  const std::string & getDenomPath(void ) const {
698  return denomPathName_;
699  }
700  const std::string & getProcess(void ) const {
701  return processName_;
702  }
703  const int getObjectType(void ) const {
704  return objectType_;
705  }
706 
707  const edm::InputTag getTag(void) const{
709  return tagName;
710  }
711 
712  ~PathInfo() {};
713 
714  PathInfo(std::string denomPathName, std::string pathName, std::string l1pathName, int l1ModuleIndex, std::string filterName, std::string processName, size_t type, float ptmin, float ptmax, float hltThreshold, float l1Threshold):
715 
716  denomPathName_(denomPathName),
717  pathName_(pathName),
718  l1pathName_(l1pathName),
719  l1ModuleIndex_(l1ModuleIndex),
720  filterName_(filterName),
721  processName_(processName),
722  objectType_(type),
723  NOn_(0), onEtOn_(0), onOneOverEtOn_(0), onEtavsonPhiOn_(0),
725  NL1_(0), l1EtL1_(0), l1Etavsl1PhiL1_(0),
732  offDRL1Off_(0), offDROnOff_(0), l1DRL1On_(0), filters_(0),
733  ptmin_(ptmin), ptmax_(ptmax),
734  hltThreshold_(hltThreshold), l1Threshold_(l1Threshold)
735 
736  {
737  };
738 
739  PathInfo(std::string denomPathName, std::string pathName, std::string l1pathName, std::string filterName, std::string processName, size_t type,
740  MonitorElement *NOn,
741  MonitorElement *onEtOn,
742  MonitorElement *onOneOverEtOn,
743  MonitorElement *onEtavsonPhiOn,
744  MonitorElement *NOff,
745  MonitorElement *offEtOff,
746  MonitorElement *offEtavsoffPhiOff,
747  MonitorElement *NL1,
748  MonitorElement *l1EtL1,
749  MonitorElement *l1Etavsl1PhiL1,
750  MonitorElement *NL1On,
751  MonitorElement *l1EtL1On,
752  MonitorElement *l1Etavsl1PhiL1On,
753  MonitorElement *NL1Off,
754  MonitorElement *offEtL1Off,
755  MonitorElement *offEtavsoffPhiL1Off,
756  MonitorElement *NOnOff,
757  MonitorElement *offEtOnOff,
758  MonitorElement *offEtavsoffPhiOnOff,
759  MonitorElement *NL1OnUM,
760  MonitorElement *l1EtL1OnUM,
761  MonitorElement *l1Etavsl1PhiL1OnUM,
762  MonitorElement *NL1OffUM,
763  MonitorElement *offEtL1OffUM,
764  MonitorElement *offEtavsoffPhiL1OffUM,
765  MonitorElement *NOnOffUM,
766  MonitorElement *offEtOnOffUM,
767  MonitorElement *offEtavsoffPhiOnOffUM,
768  MonitorElement *offDRL1Off,
769  MonitorElement *offDROnOff,
770  MonitorElement *l1DRL1On,
772  float ptmin, float ptmax
773  ):
774 
775  denomPathName_(denomPathName),
776  pathName_(pathName), l1pathName_(l1pathName),
777  filterName_(filterName), processName_(processName), objectType_(type),
778  NOn_(NOn), onEtOn_(onEtOn), onOneOverEtOn_(onOneOverEtOn), onEtavsonPhiOn_(onEtavsonPhiOn),
779  NOff_(NOff), offEtOff_(offEtOff), offEtavsoffPhiOff_(offEtavsoffPhiOff),
780  NL1_(NL1), l1EtL1_(l1EtL1), l1Etavsl1PhiL1_(l1Etavsl1PhiL1),
781  NL1On_(NL1On), l1EtL1On_(l1EtL1On), l1Etavsl1PhiL1On_(l1Etavsl1PhiL1On),
782  NL1Off_(NL1Off), offEtL1Off_(offEtL1Off), offEtavsoffPhiL1Off_(offEtavsoffPhiL1Off),
783  NOnOff_(NOnOff), offEtOnOff_(offEtOnOff), offEtavsoffPhiOnOff_(offEtavsoffPhiOnOff),
784  NL1OnUM_(NL1OnUM), l1EtL1OnUM_(l1EtL1OnUM), l1Etavsl1PhiL1OnUM_(l1Etavsl1PhiL1OnUM),
785  NL1OffUM_(NL1OffUM), offEtL1OffUM_(offEtL1OffUM), offEtavsoffPhiL1OffUM_(offEtavsoffPhiL1OffUM),
786  NOnOffUM_(NOnOffUM), offEtOnOffUM_(offEtOnOffUM), offEtavsoffPhiOnOffUM_(offEtavsoffPhiOnOffUM),
787  offDRL1Off_(offDRL1Off),
788  offDROnOff_(offDROnOff),
789  l1DRL1On_(l1DRL1On),
790  filters_(filters),
791  ptmin_(ptmin), ptmax_(ptmax)
792  {
793  };
794 
795  bool operator==(const std::string& v)
796  {
797  return v==filterName_;
798  }
799 
800  bool operator!=(const std::string& v)
801  {
802  return v!=filterName_;
803  }
804 
805  float getPtMin() const { return ptmin_; }
806  float getPtMax() const { return ptmax_; }
807  float getHltThreshold() const { return hltThreshold_; }
808  float getL1Threshold() const { return l1Threshold_; }
809 
810  std::vector< std::pair<std::string,unsigned int> > filtersAndIndices;
811 
812 
813  private:
814 
823 
824  // we don't own this data
836 
837  float ptmin_, ptmax_;
839 
840  const int index() {
841  return pathIndex_;
842  }
843  const int type() {
844  return objectType_;
845  }
846 
847 
848  };
849 
850 
851  public:
852 
853  // simple collection - just
854  class PathInfoCollection: public std::vector<PathInfo> {
855  public:
856 
857  PathInfoCollection(): std::vector<PathInfo>()
858  {};
859  std::vector<PathInfo>::iterator find(std::string pathName) {
860  return std::find(begin(), end(), pathName);
861  }
862  };
863 
865 
867 
868 };
869 
870 
871 
872 
873 
874 #endif
std::vector< std::pair< std::string, std::string > > custompathnamepairs_
std::vector< unsigned > rawCountsPerPD
std::vector< std::pair< std::string, float > > fGroupL1TempCountPair
edm::InputTag triggerResultsLabel_
double normalizedChi2Cut_
type
Definition: HCALResponse.h:21
int getThresholdFromName(const std::string &pathname)
double electronL1DRMatch_
unsigned int nBinsOneOverEt_
int i
Definition: DBlmapReader.cc:9
const std::string & getDenomPath(void) const
std::vector< std::string > pathNames
MonitorElement * getNOnOffUMHisto()
std::string pathsSummaryFilterCountsFolder_
TrigResRateMon(const edm::ParameterSet &)
HLTConfigProvider hltConfig_
edm::Handle< trigger::TriggerEvent > fTriggerObj
std::vector< std::string > fGroupName
MonitorElement * getFiltersHisto()
float getL1Threshold() const
void countHLTGroupBXHitsEndLumiBlock(const int &lumi)
void fillHltMatrix(const edm::TriggerNames &triggerNames, const edm::Event &iEvent, const edm::EventSetup &iSetup)
std::vector< std::string > testPaths_
std::vector< std::pair< std::string, float > > fPathTempCountPair
const std::string getLabel(void) const
void setPaths(const std::vector< std::string > &inputPaths)
MonitorElement * getNL1OffUMHisto()
std::vector< std::pair< std::string, unsigned int > > filtersAndIndices
void incrementCountsForPath(std::string targetPath, unsigned preScale)
std::vector< unsigned > finalCountsPerPath
bool operator!=(const std::string &v)
bool operator==(const std::string &v)
MonitorElement * getOffEtOnOffHisto()
std::vector< std::pair< std::string, std::vector< std::string > > > fGroupNamePathsPair
MonitorElement * offDROnOff_
MonitorElement * ME_HLTAll_LS
void setFilterHistos(MonitorElement *const filters)
MonitorElement * NOnOffUM_
MonitorElement * filters_
std::string fCustomBXPath
MonitorElement * meAverageLumiPerLS
MonitorElement * l1Etavsl1PhiL1OnUM_
MonitorElement * onOneOverEtOn_
MonitorElement * getOffDRL1OffHisto()
tuple lumi
Definition: fjr2json.py:35
edm::InputTag recHitsEBTag_
MonitorElement * NL1Off_
double averageInstLumi3LS
MonitorElement * scalersSelect
bool hasL1Passed(const std::string &pathname, const edm::TriggerNames &triggerNames)
MonitorElement * offEtavsoffPhiOff_
MonitorElement * getOffEtaVsOffPhiL1OffHisto()
MonitorElement * getL1EtL1OnHisto()
void countHLTGroupHitsEndLumiBlock(const int &lumi)
PathInfoCollection hltPaths_
void fillXsecPlot(MonitorElement *myXsecPlot, double currentInstLumi, double secondsPerLS, double referenceXSec)
std::vector< MonitorElement * > v_ME_HLTAll_LS
std::vector< MonitorElement * > v_ME_Xsec
MonitorElement * l1Etavsl1PhiL1On_
std::string pathsSummaryHLTPathsPerLSFolder_
double thresholdFactor_
MonitorElement * NL1OffUM_
double dRMaxElectronMuon_
void setupHltMatrix(const std::string &label, std::vector< std::string > &paths)
MonitorElement * onEtOn_
const edm::InputTag getTag(void) const
edm::EDGetTokenT< LumiScalersCollection > lumiScalersToken_
MonitorElement * getL1EtL1Histo()
std::vector< unsigned > rawCountsPerPath
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Definition: FindCaloHit.cc:7
MonitorElement * getOffEtOffHisto()
MonitorElement * l1EtL1On_
MonitorElement * getOnOneOverEtOnHisto()
void countHLTGroupL1HitsEndLumiBlock(const int &lumi)
std::string dirname_
MonitorElement * l1EtL1_
std::vector< TPRegexp > filters
Definition: eve_filter.cc:25
std::vector< DatasetInfo > primaryDataSetInformation
PathInfoCollection hltPathsDiagonal_
double averageInstLumi
MonitorElement * offEtavsoffPhiOnOffUM_
MonitorElement * l1Etavsl1PhiL1_
void Fill(long long x)
void addLumiToAverage(double lumi)
const std::string & getProcess(void) const
edm::EDGetTokenT< edm::TriggerResults > triggerResultsToken_
bool hasHLTPassed(const std::string &pathname, const edm::TriggerNames &triggerNames)
MonitorElement * getOffEtaVsOffPhiOnOffUMHisto()
MonitorElement * NL1On_
MonitorElement * getNL1OnHisto()
std::vector< std::string > specialPaths_
double electronDRMatch_
PathInfo(std::string denomPathName, std::string pathName, std::string l1pathName, std::string filterName, std::string processName, size_t type, MonitorElement *NOn, MonitorElement *onEtOn, MonitorElement *onOneOverEtOn, MonitorElement *onEtavsonPhiOn, MonitorElement *NOff, MonitorElement *offEtOff, MonitorElement *offEtavsoffPhiOff, MonitorElement *NL1, MonitorElement *l1EtL1, MonitorElement *l1Etavsl1PhiL1, MonitorElement *NL1On, MonitorElement *l1EtL1On, MonitorElement *l1Etavsl1PhiL1On, MonitorElement *NL1Off, MonitorElement *offEtL1Off, MonitorElement *offEtavsoffPhiL1Off, MonitorElement *NOnOff, MonitorElement *offEtOnOff, MonitorElement *offEtavsoffPhiOnOff, MonitorElement *NL1OnUM, MonitorElement *l1EtL1OnUM, MonitorElement *l1Etavsl1PhiL1OnUM, MonitorElement *NL1OffUM, MonitorElement *offEtL1OffUM, MonitorElement *offEtavsoffPhiL1OffUM, MonitorElement *NOnOffUM, MonitorElement *offEtOnOffUM, MonitorElement *offEtavsoffPhiOnOffUM, MonitorElement *offDRL1Off, MonitorElement *offDROnOff, MonitorElement *l1DRL1On, MonitorElement *filters, float ptmin, float ptmax)
int iEvent
Definition: GenABIO.cc:230
MonitorElement * getOffEtL1OffHisto()
MonitorElement * getNOffHisto()
MonitorElement * NOnOff_
const std::string & getPath(void) const
void beginLuminosityBlock(const edm::LuminosityBlock &lumiSeg, const edm::EventSetup &c)
MonitorElement * getOffEtL1OffUMHisto()
std::string pathsSummaryFilterEfficiencyFolder_
bool foundReferenceTrigger_
std::string pathsSummaryStreamsFolder_
MonitorElement * getOffEtaVsOffPhiL1OffUMHisto()
void setupStreamMatrix(const std::string &label, std::vector< std::string > &paths)
double photonL1DRMatch_
std::vector< std::pair< std::string, float > > fGroupTempCountPair
unsigned int nBinsDR_
MonitorElement * offEtOff_
std::vector< MonitorElement * > v_ME_HLTPassPass_Normalized
edm::InputTag recHitsEETag_
void fillRawCountsForPath(MonitorElement *myRawCountsPlot, std::string pathName)
MonitorElement * getL1EtaVsL1PhiL1OnHisto()
int j
Definition: DBlmapReader.cc:9
void setLabel(std::string labelName)
virtual void endJob()
const int getL1ModuleIndex(void) const
const std::string & getl1Path(void) const
std::map< std::string, unsigned int > countsPerPath
std::set< std::string > testPaths
#define end
Definition: vmac.h:37
void countHLTPathHitsEndLumiBlock(const int &lumi)
MonitorElement * getL1EtaVsL1PhiL1OnUMHisto()
std::vector< MonitorElement * > v_ME_HLTPassPass
std::vector< MonitorElement * > v_ME_Total_BX
void filltestHisto(const int &lumi)
std::vector< MonitorElement * > v_ME_CountsPerLS
edm::EDGetTokenT< edm::TriggerResults > triggerResultsTokenFU_
MonitorElement * ME_HLT_BX
edm::InputTag triggerSummaryLabel_
MonitorElement * getOffDROnOffHisto()
unsigned int referenceBX_
std::string referenceTrigName_
MonitorElement * meXsecPerTestPath
double trackL1DRMatch_
unsigned referenceTrigIndex_
std::vector< MonitorElement * > v_ME_Total_BX_Norm
std::vector< std::vector< uint > > triggerFilterIndices_
unsigned int Nbx_
MonitorElement * getOffEtOnOffUMHisto()
std::string pathsSummaryFolder_
unsigned int nLS_
MonitorElement * getOffEtaVsOffPhiOnOffHisto()
std::string testPathsFolder_
MonitorElement * meCountsDroppedPerLS
MonitorElement * getOnEtOnHisto()
void fillXsecPerDataset(const int &lumi)
MonitorElement * getNL1OnUMHisto()
void findReferenceTriggerIndex()
MonitorElement * getL1EtaVsL1PhiL1Histo()
std::string pathsIndividualHLTPathsPerLSFolder_
MonitorElement * getL1DROnL1Histo()
edm::Handle< edm::TriggerResults > triggerResults_
MonitorElement * offEtOnOffUM_
MonitorElement * meXsecStreamPerLS
void setHistos(MonitorElement *const NOn, MonitorElement *const onEtOn, MonitorElement *const onOneOverEtOn, MonitorElement *const onEtavsonPhiOn, MonitorElement *const NOff, MonitorElement *const offEtOff, MonitorElement *const offEtavsoffPhiOff, MonitorElement *const NL1, MonitorElement *const l1EtL1, MonitorElement *const l1Etavsl1PhiL1, MonitorElement *const NL1On, MonitorElement *const l1EtL1On, MonitorElement *const l1Etavsl1PhiL1On, MonitorElement *const NL1Off, MonitorElement *const offEtL1Off, MonitorElement *const offEtavsoffPhiL1Off, MonitorElement *const NOnOff, MonitorElement *const offEtOnOff, MonitorElement *const offEtavsoffPhiOnOff, MonitorElement *const NL1OnUM, MonitorElement *const l1EtL1OnUM, MonitorElement *const l1Etavsl1PhiL1OnUM, MonitorElement *const NL1OffUM, MonitorElement *const offEtL1OffUM, MonitorElement *const offEtavsoffPhiL1OffUM, MonitorElement *const NOnOffUM, MonitorElement *const offEtOnOffUM, MonitorElement *const offEtavsoffPhiOnOffUM, MonitorElement *const offDRL1Off, MonitorElement *const offDROnOff, MonitorElement *const l1DRL1On)
void beginRun(const edm::Run &run, const edm::EventSetup &c)
std::string referenceTrigInput_
MonitorElement * meDiagnostic
TH1F * getTH1F(void) const
MonitorElement * l1DRL1On_
MonitorElement * getNL1OffHisto()
MonitorElement * offEtOnOff_
MonitorElement * getNL1Histo()
std::vector< MonitorElement * > v_ME_XsecPerLS
MonitorElement * getL1EtL1OnUMHisto()
virtual void analyze(const edm::Event &, const edm::EventSetup &)
std::vector< PathInfo >::iterator find(std::string pathName)
MonitorElement * offEtL1Off_
MonitorElement * getOnEtaVsOnPhiOnHisto()
MonitorElement * offDRL1Off_
std::string pathsSummaryHLTCorrelationsFolder_
double ptmin
Definition: HydjetWrapper.h:85
MonitorElement * onEtavsonPhiOn_
void endRun(const edm::Run &run, const edm::EventSetup &c)
EndRun.
void printCountsPerPathThisLumi()
#define begin
Definition: vmac.h:30
MonitorElement * l1EtL1OnUM_
std::vector< std::string > maskedPaths_
MonitorElement * getOffEtaVsOffPhiOffHisto()
MonitorElement * meCountsStreamPerLS
MonitorElement * offEtavsoffPhiOnOff_
std::vector< MonitorElement * > v_ME_HLTPass_Normalized_Any
float getHltThreshold() const
MonitorElement * getNOnOffHisto()
void setMaskedPaths(const std::vector< std::string > &inputPaths)
unsigned int zbIndex
int64_t TotalDroppedCounts
std::string muonRecoCollectionName_
tuple cout
Definition: gather_cfg.py:121
MonitorElement * offEtavsoffPhiL1OffUM_
unsigned int nBins2D_
double electronEtaMax_
MonitorElement * offEtavsoffPhiL1Off_
void incrementCountsForPath(std::string targetPath)
DQMStore * dbe_
virtual void beginJob()
std::set< std::string > maskedPaths
std::string pathsSummaryHLTPathsPerBXFolder_
void fillXsecPlot(MonitorElement *myXsecPlot, double currentInstLumi, double secondsPerLS)
int getTriggerTypeParsePathName(const std::string &pathname)
std::vector< std::vector< std::string > > triggerFilters_
const int getObjectType(void) const
std::string processname_
std::vector< std::pair< std::string, std::vector< int > > > fPathBxTempCountPair
unsigned int nBins_
MonitorElement * NOff_
MonitorElement * NL1OnUM_
void endLuminosityBlock(const edm::LuminosityBlock &lumiSeg, const edm::EventSetup &c)
MonitorElement * ME_HLT_CUSTOM_BX
MonitorElement * meCountsPassPerLS
const std::string getL1ConditionModuleName(const std::string &pathname)
Definition: Run.h:41
unsigned referenceTrigCountsPS_
MonitorElement * getNOnHisto()
void fillCountsPerPath(const edm::Event &iEvent, const edm::EventSetup &iSetup)
MonitorElement * offEtL1OffUM_
PathInfo(std::string denomPathName, std::string pathName, std::string l1pathName, int l1ModuleIndex, std::string filterName, std::string processName, size_t type, float ptmin, float ptmax, float hltThreshold, float l1Threshold)