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 nCount_;
76 
77  std::vector<int> prescUsed_;
78 
81  //reco::helper::JetIDHelper *jetID; // JetID helper (Need to run with RECO, not AOD)
82  std::vector<std::string> path_;
83 
84  bool debug_;
85  bool isSetup_;
86 
87  double minPtHigh_;
88  double minPtLow_;
89  double minDeltaEta_;
90  double minInvMass_;
91  double deltaRMatch_;
92  bool etaOpposite_;
93 
98  edm::TriggerNames triggerNames_; // TriggerNames class
99 
104 
109 
114 
118 
127 
130 
131  double reco_ejet1;
132  //double reco_etjet1;
133  double reco_pxjet1;
134  double reco_pyjet1;
135  double reco_pzjet1;
136  double reco_ptjet1;
137  double reco_etajet1;
138  double reco_phijet1;
139  //
140  double reco_ejet2;
141  //double reco_etjet2;
142  double reco_pxjet2;
143  double reco_pyjet2;
144  double reco_pzjet2;
145  double reco_ptjet2;
146  double reco_etajet2;
147  double reco_phijet2;
148  //
149  double hlt_ejet1;
150  //double hlt_etjet1;
151  double hlt_pxjet1;
152  double hlt_pyjet1;
153  double hlt_pzjet1;
154  double hlt_ptjet1;
155  double hlt_etajet1;
156  double hlt_phijet1;
157  //
158  double hlt_ejet2 ;
159  //double hlt_etjet2;
160  double hlt_pxjet2;
161  double hlt_pyjet2;
162  double hlt_pzjet2;
163  double hlt_ptjet2;
164  double hlt_etajet2;
165  double hlt_phijet2;
166  //
168  bool checkHLT;
170  //
177  //
184 
185  // helper class to store the data path
186 
187  class PathInfo {
189  prescaleUsed_(-1),
190  pathName_("unset"),
191  filterName_("unset"),
192  processName_("unset"),
193  objectType_(-1),
194  triggerType_("unset"){};
195  //
196  public:
197  //
198  void setHistos(
199  MonitorElement* const RECO_deltaEta_DiJet,
200  MonitorElement* const RECO_deltaPhi_DiJet,
201  MonitorElement* const RECO_invMass_DiJet,
202  MonitorElement* const HLT_deltaEta_DiJet,
203  MonitorElement* const HLT_deltaPhi_DiJet,
204  MonitorElement* const HLT_invMass_DiJet,
205  MonitorElement* const RECO_deltaEta_DiJet_Match,
206  MonitorElement* const RECO_deltaPhi_DiJet_Match,
207  MonitorElement* const RECO_invMass_DiJet_Match,
208  MonitorElement* const RECOHLT_deltaEta,
209  MonitorElement* const RECOHLT_deltaPhi,
210  MonitorElement* const RECOHLT_invMass,
211  MonitorElement* const NumberOfMatches,
212  MonitorElement* const NumberOfEvents
213  )
214  {
215  RECO_deltaEta_DiJet_ = RECO_deltaEta_DiJet;
216  RECO_deltaPhi_DiJet_ = RECO_deltaPhi_DiJet;
217  RECO_invMass_DiJet_ = RECO_invMass_DiJet;
218  HLT_deltaEta_DiJet_ = HLT_deltaEta_DiJet;
219  HLT_deltaPhi_DiJet_ = HLT_deltaPhi_DiJet ;
220  HLT_invMass_DiJet_ = HLT_invMass_DiJet;
221  RECO_deltaEta_DiJet_Match_ = RECO_deltaEta_DiJet_Match;
222  RECO_deltaPhi_DiJet_Match_ = RECO_deltaPhi_DiJet_Match;
223  RECO_invMass_DiJet_Match_ = RECO_invMass_DiJet_Match;
224  RECOHLT_deltaEta_ = RECOHLT_deltaEta;
225  RECOHLT_deltaPhi_ = RECOHLT_deltaPhi ;
226  RECOHLT_invMass_ = RECOHLT_invMass;
227  NumberOfMatches_ = NumberOfMatches;
228  NumberOfEvents_ = NumberOfEvents;
229  };
230  ~PathInfo() {};
231  PathInfo(int prescaleUsed,
232  std::string pathName,
234  std::string processName,
235  size_t type,
236  std::string triggerType):
237  prescaleUsed_(prescaleUsed),
238  pathName_(pathName),
239  filterName_(filterName),
240  processName_(processName),
241  objectType_(type),
242  triggerType_(triggerType){};
243 
258 
259  const std::string getLabel(void ) const {
260  return filterName_;
261  }
262  void setLabel(std::string labelName){
263  filterName_ = labelName;
264  return;
265  }
266  const std::string getPath(void ) const {
267  return pathName_;
268  }
269  const int getprescaleUsed(void) const {
270  return prescaleUsed_;
271  }
272  const std::string getProcess(void ) const {
273  return processName_;
274  }
275  const int getObjectType(void ) const {
276  return objectType_;
277  }
278  const std::string getTriggerType(void ) const {
279  return triggerType_;
280  }
281  const edm::InputTag getTag(void) const{
283  return tagName;
284  }
285  bool operator==(const std::string v){
286  return v==pathName_;
287  }
288 
289  private:
296 
311  };
312 
313  // simple collection
314  class PathInfoCollection: public std::vector<PathInfo> {
315  public:
316  PathInfoCollection(): std::vector<PathInfo>()
317  {};
318  std::vector<PathInfo>::iterator find(std::string pathName) {
319  return std::find(begin(), end(), pathName);
320  }
321  };
323 };
324 #endif
MonitorElement * getMEhisto_RECO_deltaPhi_DiJet_Match()
type
Definition: HCALResponse.h:21
MonitorElement * getMEhisto_HLT_deltaEta_DiJet()
edm::EDGetTokenT< edm::TriggerResults > triggerResultsFUToken
const int getprescaleUsed(void) const
void beginRun(const edm::Run &run, const edm::EventSetup &c)
edm::EDGetTokenT< reco::CaloMETCollection > caloMetToken
MonitorElement * getMEhisto_RECO_invMass_DiJet()
virtual bool isForward(double eta)
PathInfoCollection hltPathsAll_
edm::EDGetTokenT< trigger::TriggerEvent > triggerSummaryToken
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_
edm::EDGetTokenT< edm::TriggerResults > triggerResultsToken
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 &)
tuple path
else: Piece not in the list, fine.
edm::Handle< reco::CaloJetCollection > calojetColl_
edm::EDGetTokenT< reco::CaloJetCollection > caloJetsToken
edm::EDGetTokenT< edm::View< reco::PFJet > > pfJetsToken
edm::Handle< reco::PFJetCollection > pfjetColl_
edm::Handle< reco::PFMETCollection > pfmetColl_
const std::string getTriggerType(void) const
edm::EDGetTokenT< edm::View< reco::PFMET > > pfMetToken
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()
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
edm::EDGetTokenT< trigger::TriggerEvent > triggerSummaryFUToken
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)