CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
TriggerValidator.h
Go to the documentation of this file.
1 #ifndef SusyBsmTriggerPerformance_TriggerValidator_TriggerValidator_h
2 #define SusyBsmTriggerPerformance_TriggerValidator_TriggerValidator_h
3 
4 // -*- C++ -*-
5 //
6 // Package: TriggerValidator
7 // Class: TriggerValidator
8 //
16 //
17 // Original Author: Massimiliano Chiorboli
18 // Maurizio Pierini
19 // Maria Spiropulu
20 // Created: Wed Aug 29 15:10:56 CEST 2007
21 // $Id: TriggerValidator.h,v 1.16 2010/12/14 17:20:35 vlimant Exp $
22 //
23 //
24 
25 // system include files
26 #include <memory>
27 #include <fstream>
28 #include <iostream>
29 
30 // user include files
35 
38 
39 //To be included in a second stage
43 //#include "HLTriggerOffline/SUSYBSM/interface/TurnOnMaker.h"
44 
45 //included for DQM
50 
51 
52 
53 
55  public:
56  explicit TriggerValidator(const edm::ParameterSet&);
58 
59  TFile* theHistoFile;
60 
61  private:
62  virtual void beginJob() ;
63  virtual void analyze(const edm::Event&, const edm::EventSetup&);
64  virtual void endJob() ;
65 
66 
67  void beginRun(const edm::Run& run, const edm::EventSetup& c);
68  void endRun(const edm::Run& run, const edm::EventSetup& c);
69 
70 
71  std::map<int,std::string> l1NameMap;
72  // ----------member data ---------------------------
74  std::string dirname_;
76  // --- names of the folders in the dbe ---
77  std::string triggerBitsDir ;
78  std::string recoSelBitsDir ;
79  std::string mcSelBitsDir ;
80 
81 
82 
83  unsigned int nHltPaths;
84  int nL1Bits;
85 
86 
87  //RecoSelector
88  std::vector<RecoSelector*> myRecoSelector;
89  std::vector<McSelector*> myMcSelector;
90 
91  //For the moment I switch off the more complex plots
94 /* TurnOnMaker* myTurnOnMaker; */
95 
96  //Histo
97  std::string HistoFileName;
98  std::string StatFileName;
101 
102  //McFlag
103  bool mcFlag;
104  bool l1Flag;
105 
106  //Cut parameters decided by the user
107  std::vector<edm::ParameterSet> reco_parametersets;
108  std::vector<edm::ParameterSet> mc_parametersets;
112 
115  std::string processName_;
116  std::string triggerName_;
117  // name of each L1 algorithm
118  std::vector<std::string> l1Names_;
119  // name of each hlt algorithm
120  std::vector<std::string> hlNames_;
121 
122 
123  //Counters for L1 and HLT
124  std::vector<int> numTotL1BitsBeforeCuts;
125  std::vector<int> numTotHltBitsBeforeCuts;
126  std::vector< std::vector<int> > numTotL1BitsAfterRecoCuts;
127  std::vector< std::vector<int> > numTotHltBitsAfterRecoCuts;
128  std::vector< std::vector<int> > numTotL1BitsAfterMcCuts;
129  std::vector< std::vector<int> > numTotHltBitsAfterMcCuts;
130 
131  std::vector<double> effL1BeforeCuts;
132  std::vector<double> effHltBeforeCuts;
133  std::vector<double> effL1AfterRecoCuts;
134  std::vector<double> effHltAfterRecoCuts;
135  std::vector<double> effL1AfterMcCuts;
136  std::vector<double> effHltAfterMcCuts;
137 
138 
139 
140  std::vector< std::vector<int> > vCorrL1;
141  std::vector< std::vector<int> > vCorrHlt;
142  std::vector< std::vector<double> > vCorrNormL1;
143  std::vector< std::vector<double> > vCorrNormHlt;
144 
145  int nEvTot;
146  std::vector<int> nEvRecoSelected;
147  std::vector<int> nEvMcSelected;
148 
149 
150 
151 
152  //Histos for L1 and HLT bits
155  std::vector<MonitorElement*> hL1BitsAfterRecoCuts;
156  std::vector<MonitorElement*> hHltBitsAfterRecoCuts;
157  std::vector<MonitorElement*> hL1BitsAfterMcCuts;
158  std::vector<MonitorElement*> hHltBitsAfterMcCuts;
159 
162  std::vector<MonitorElement*> hL1PathsAfterRecoCuts;
163  std::vector<MonitorElement*> hHltPathsAfterRecoCuts;
164  std::vector<MonitorElement*> hL1PathsAfterMcCuts;
165  std::vector<MonitorElement*> hHltPathsAfterMcCuts;
166 
167 
168  //if we want to keep these, probably thay have to move to the client
169 /* TH2D* hL1OverlapNormToTotal; */
170 /* TH2D* hHltOverlapNormToTotal; */
171 /* TH2D* hL1OverlapNormToLargestPath; */
172 /* TH2D* hHltOverlapNormToLargestPath; */
173 
174  std::vector<int> l1bits;
175  std::vector<int> hltbits;
176 
178 
180 };
181 
182 
183 
184 #endif
std::vector< MonitorElement * > hHltBitsAfterRecoCuts
std::vector< std::vector< double > > vCorrNormL1
std::string dirname_
std::vector< McSelector * > myMcSelector
std::string StatFileName
std::vector< MonitorElement * > hL1PathsAfterRecoCuts
void endRun(const edm::Run &run, const edm::EventSetup &c)
std::vector< double > effL1BeforeCuts
std::vector< MonitorElement * > hHltPathsAfterRecoCuts
unsigned int nHltPaths
std::vector< double > effHltAfterMcCuts
std::vector< int > numTotHltBitsBeforeCuts
std::vector< MonitorElement * > hHltPathsAfterMcCuts
MuonAnalyzerSBSM * myMuonAnalyzer
PlotMakerReco * myPlotMakerReco
std::vector< std::string > l1Names_
std::vector< MonitorElement * > hL1BitsAfterMcCuts
std::vector< std::vector< int > > vCorrL1
std::vector< int > nEvRecoSelected
std::vector< std::vector< int > > numTotHltBitsAfterMcCuts
std::vector< MonitorElement * > hL1PathsAfterMcCuts
std::vector< MonitorElement * > hL1BitsAfterRecoCuts
std::vector< int > nEvMcSelected
std::vector< RecoSelector * > myRecoSelector
std::string triggerName_
MonitorElement * hHltPathsBeforeCuts
void beginRun(const edm::Run &run, const edm::EventSetup &c)
std::string recoSelBitsDir
virtual void beginJob()
edm::InputTag triggerTag_
PlotMakerL1 * myPlotMakerL1
std::string mcSelBitsDir
MonitorElement * hL1PathsBeforeCuts
std::string triggerBitsDir
std::vector< std::string > hlNames_
edm::InputTag hltLabel
std::vector< std::vector< double > > vCorrNormHlt
std::vector< int > numTotL1BitsBeforeCuts
std::vector< int > l1bits
edm::ParameterSet turnOn_params
std::string HistoFileName
std::vector< MonitorElement * > hHltBitsAfterMcCuts
std::vector< double > effL1AfterRecoCuts
std::vector< double > effL1AfterMcCuts
std::vector< int > hltbits
std::string processName_
std::vector< double > effHltBeforeCuts
std::vector< std::vector< int > > numTotHltBitsAfterRecoCuts
std::vector< edm::ParameterSet > reco_parametersets
edm::ParameterSet plotMakerRecoInput
virtual void analyze(const edm::Event &, const edm::EventSetup &)
std::vector< double > effHltAfterRecoCuts
std::vector< std::vector< int > > numTotL1BitsAfterRecoCuts
HLTConfigProvider hltConfig_
virtual void endJob()
std::vector< std::vector< int > > vCorrHlt
edm::ParameterSet plotMakerL1Input
MonitorElement * hL1BitsBeforeCuts
std::vector< std::vector< int > > numTotL1BitsAfterMcCuts
TriggerValidator(const edm::ParameterSet &)
edm::InputTag muonTag_
MonitorElement * hHltBitsBeforeCuts
edm::InputTag l1Label
Definition: Run.h:33
std::map< int, std::string > l1NameMap
std::vector< edm::ParameterSet > mc_parametersets