CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
HLTInclusiveVBFSource.h
Go to the documentation of this file.
1 #ifndef HLTInclusiveVBFSource_H
2 #define HLTInclusiveVBFSource_H
3 
4 // system include files
5 #include <memory>
6 #include <unistd.h>
7 
8 // user include files
17 
19 
22 
40 
41 //#include "RecoJets/JetProducers/interface/JetIDHelper.h"
42 
43 #include <iostream>
44 #include <fstream>
45 #include <vector>
46 #include <string>
47 
49  public:
52 
53  private:
54  virtual void beginJob() ;
55  virtual void analyze(const edm::Event&, const edm::EventSetup&);
56  virtual void endJob() ;
57 
58  void beginRun(const edm::Run& run, const edm::EventSetup& c);
59  void endRun(const edm::Run& run, const edm::EventSetup& c);
60 
61  void beginLuminosityBlock(const edm::LuminosityBlock& lumiSeg, const edm::EventSetup& c);
62  void endLuminosityBlock(const edm::LuminosityBlock& lumiSeg, const edm::EventSetup& c);
63  //void histobooking( const edm::EventSetup& c);
64 
65  virtual bool isBarrel(double eta);
66  virtual bool isEndCap(double eta);
67  virtual bool isForward(double eta);
68  virtual bool validPathHLT(std::string path);
71  //virtual double TriggerPosition(std::string trigName);
72 
73  // ----------member data ---------------------------
74  int nev_;
75  int nCount_;
77 
79 
80  std::vector<int> prescUsed_;
81 
84  //reco::helper::JetIDHelper *jetID; // JetID helper (Need to run with RECO, not AOD)
85  std::vector<std::string> path_;
86 
87  bool debug_;
88  bool isSetup_;
89 
90  double minPtHigh_;
91  double minPtLow_;
92  double minDeltaEta_;
93  double minInvMass_;
94  double deltaRMatch_;
95  bool etaOpposite_;
96 
101  edm::TriggerNames triggerNames_; // TriggerNames class
102 
107 
112 
116 
125 
128 
129  double reco_ejet1;
130  //double reco_etjet1;
131  double reco_pxjet1;
132  double reco_pyjet1;
133  double reco_pzjet1;
134  double reco_ptjet1;
135  double reco_etajet1;
136  double reco_phijet1;
137  //
138  double reco_ejet2;
139  //double reco_etjet2;
140  double reco_pxjet2;
141  double reco_pyjet2;
142  double reco_pzjet2;
143  double reco_ptjet2;
144  double reco_etajet2;
145  double reco_phijet2;
146  //
147  double hlt_ejet1;
148  //double hlt_etjet1;
149  double hlt_pxjet1;
150  double hlt_pyjet1;
151  double hlt_pzjet1;
152  double hlt_ptjet1;
153  double hlt_etajet1;
154  double hlt_phijet1;
155  //
156  double hlt_ejet2 ;
157  //double hlt_etjet2;
158  double hlt_pxjet2;
159  double hlt_pyjet2;
160  double hlt_pzjet2;
161  double hlt_ptjet2;
162  double hlt_etajet2;
163  double hlt_phijet2;
164  //
166  bool checkHLT;
168  //
175  //
182 
183  // data across paths
185  // helper class to store the data path
186 
187  class PathInfo {
189  pathIndex_(-1),
190  prescaleUsed_(-1),
191  pathName_("unset"),
192  filterName_("unset"),
193  processName_("unset"),
194  objectType_(-1),
195  triggerType_("unset"){};
196  //
197  public:
198  //
199  void setHistos(
200  MonitorElement* const RECO_deltaEta_DiJet,
201  MonitorElement* const RECO_deltaPhi_DiJet,
202  MonitorElement* const RECO_invMass_DiJet,
203  MonitorElement* const HLT_deltaEta_DiJet,
204  MonitorElement* const HLT_deltaPhi_DiJet,
205  MonitorElement* const HLT_invMass_DiJet,
206  MonitorElement* const RECO_deltaEta_DiJet_Match,
207  MonitorElement* const RECO_deltaPhi_DiJet_Match,
208  MonitorElement* const RECO_invMass_DiJet_Match,
209  MonitorElement* const RECOHLT_deltaEta,
210  MonitorElement* const RECOHLT_deltaPhi,
211  MonitorElement* const RECOHLT_invMass,
212  MonitorElement* const NumberOfMatches,
213  MonitorElement* const NumberOfEvents
214  )
215  {
216  RECO_deltaEta_DiJet_ = RECO_deltaEta_DiJet;
217  RECO_deltaPhi_DiJet_ = RECO_deltaPhi_DiJet;
218  RECO_invMass_DiJet_ = RECO_invMass_DiJet;
219  HLT_deltaEta_DiJet_ = HLT_deltaEta_DiJet;
220  HLT_deltaPhi_DiJet_ = HLT_deltaPhi_DiJet ;
221  HLT_invMass_DiJet_ = HLT_invMass_DiJet;
222  RECO_deltaEta_DiJet_Match_ = RECO_deltaEta_DiJet_Match;
223  RECO_deltaPhi_DiJet_Match_ = RECO_deltaPhi_DiJet_Match;
224  RECO_invMass_DiJet_Match_ = RECO_invMass_DiJet_Match;
225  RECOHLT_deltaEta_ = RECOHLT_deltaEta;
226  RECOHLT_deltaPhi_ = RECOHLT_deltaPhi ;
227  RECOHLT_invMass_ = RECOHLT_invMass;
228  NumberOfMatches_ = NumberOfMatches;
229  NumberOfEvents_ = NumberOfEvents;
230  };
231  ~PathInfo() {};
232  PathInfo(int prescaleUsed,
233  std::string pathName,
235  std::string processName,
236  size_t type,
237  std::string triggerType):
238  prescaleUsed_(prescaleUsed),
239  pathName_(pathName),
240  filterName_(filterName),
241  processName_(processName),
242  objectType_(type),
243  triggerType_(triggerType){};
244 
259 
260  const std::string getLabel(void ) const {
261  return filterName_;
262  }
263  void setLabel(std::string labelName){
264  filterName_ = labelName;
265  return;
266  }
267  const std::string getPath(void ) const {
268  return pathName_;
269  }
270  const int getprescaleUsed(void) const {
271  return prescaleUsed_;
272  }
273  const std::string getProcess(void ) const {
274  return processName_;
275  }
276  const int getObjectType(void ) const {
277  return objectType_;
278  }
279  const std::string getTriggerType(void ) const {
280  return triggerType_;
281  }
282  const edm::InputTag getTag(void) const{
284  return tagName;
285  }
286  bool operator==(const std::string v){
287  return v==pathName_;
288  }
289 
290  private:
298 
313  };
314 
315  // simple collection
316  class PathInfoCollection: public std::vector<PathInfo> {
317  public:
318  PathInfoCollection(): std::vector<PathInfo>()
319  {};
320  std::vector<PathInfo>::iterator find(std::string pathName) {
321  return std::find(begin(), end(), pathName);
322  }
323  };
325 };
326 #endif
MonitorElement * getMEhisto_RECO_deltaPhi_DiJet_Match()
type
Definition: HCALResponse.h:21
MonitorElement * getMEhisto_HLT_deltaEta_DiJet()
const int getprescaleUsed(void) const
void beginRun(const edm::Run &run, const edm::EventSetup &c)
MonitorElement * getMEhisto_RECO_invMass_DiJet()
virtual bool isForward(double eta)
PathInfoCollection hltPathsAll_
virtual bool isBarrel(double eta)
virtual void analyze(const edm::Event &, const edm::EventSetup &)
MonitorElement * getMEhisto_RECO_invMass_DiJet_Match()
edm::InputTag triggerSummaryLabel_
virtual bool validPathHLT(std::string path)
edm::Handle< trigger::TriggerEvent > triggerObj_
MonitorElement * getMEhisto_HLT_deltaPhi_DiJet()
void endRun(const edm::Run &run, const edm::EventSetup &c)
EndRun.
T eta() const
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Definition: FindCaloHit.cc:7
reco::PFJetCollection pfjet
PathInfo(int prescaleUsed, std::string pathName, std::string filterName, std::string processName, size_t type, std::string triggerType)
const edm::InputTag getTag(void) const
const std::string getProcess(void) const
void setHistos(MonitorElement *const RECO_deltaEta_DiJet, MonitorElement *const RECO_deltaPhi_DiJet, MonitorElement *const RECO_invMass_DiJet, MonitorElement *const HLT_deltaEta_DiJet, MonitorElement *const HLT_deltaPhi_DiJet, MonitorElement *const HLT_invMass_DiJet, MonitorElement *const RECO_deltaEta_DiJet_Match, MonitorElement *const RECO_deltaPhi_DiJet_Match, MonitorElement *const RECO_invMass_DiJet_Match, MonitorElement *const RECOHLT_deltaEta, MonitorElement *const RECOHLT_deltaPhi, MonitorElement *const RECOHLT_invMass, MonitorElement *const NumberOfMatches, MonitorElement *const NumberOfEvents)
HLTInclusiveVBFSource(const edm::ParameterSet &)
edm::Handle< reco::CaloJetCollection > calojetColl_
edm::Handle< reco::PFJetCollection > pfjetColl_
edm::Handle< reco::PFMETCollection > pfmetColl_
const std::string getTriggerType(void) const
void beginLuminosityBlock(const edm::LuminosityBlock &lumiSeg, const edm::EventSetup &c)
std::vector< int > prescUsed_
MonitorElement * getMEhisto_RECOHLT_deltaPhi()
#define end
Definition: vmac.h:37
edm::TriggerNames triggerNames_
bool operator==(const std::string v)
const std::string getLabel(void) const
std::vector< std::string > path_
const std::string getPath(void) const
HLTConfigProvider hltConfig_
edm::Handle< reco::CaloMETCollection > calometColl_
virtual bool isTriggerObjectFound(std::string objectName)
void endLuminosityBlock(const edm::LuminosityBlock &lumiSeg, const edm::EventSetup &c)
virtual bool isHLTPathAccepted(std::string pathName)
std::vector< PFJet > PFJetCollection
collection of PFJet objects
#define begin
Definition: vmac.h:30
MonitorElement * getMEhisto_RECOHLT_deltaEta()
MonitorElement * scalersSelect
edm::InputTag triggerResultsLabel_
MonitorElement * getMEhisto_RECO_deltaEta_DiJet_Match()
MonitorElement * getMEhisto_HLT_invMass_DiJet()
void setLabel(std::string labelName)
std::vector< PathInfo >::iterator find(std::string pathName)
reco::CaloJetCollection calojet
MonitorElement * getMEhisto_RECO_deltaEta_DiJet()
MonitorElement * getMEhisto_RECO_deltaPhi_DiJet()
Definition: Run.h:41
std::vector< CaloJet > CaloJetCollection
collection of CaloJet objects
edm::Handle< edm::TriggerResults > triggerResults_
virtual bool isEndCap(double eta)