CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
HcalDigisValidation.h
Go to the documentation of this file.
1 #ifndef HCALDIGISVALIDATION_H
2 #define HCALDIGISVALIDATION_H
3 
4 #include <memory>
5 
9 
11 
15 
18 
20 
25 
30 
32 
33 
36 
37 /*TP Code*/
42 /*~TP Code*/
43 
44 
45 #include <map>
46 #include <vector>
47 #include <utility>
48 #include <ostream>
49 #include <string>
50 #include <algorithm>
51 #include <cmath>
52 #include <iostream>
53 
55 public:
56  explicit HcalDigisValidation(const edm::ParameterSet&);
57 
59 
60  virtual void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &);
61 
62 private:
63 
64  struct HistLim {
65 
66  HistLim(int nbin, double mini, double maxi)
67  : n(nbin), min(mini), max(maxi) {
68  }
69  int n;
70  double min;
71  double max;
72  };
73 
74  virtual void analyze(const edm::Event&, const edm::EventSetup&);
75 
76  std::map<std::string, MonitorElement*> *msm_;
77 
78  void book1D(DQMStore::IBooker &ib, std::string name, int n, double min, double max);
79 
80  void book1D(DQMStore::IBooker &ib, std::string name, const HistLim& limX);
81 
82  void fill1D(std::string name, double X, double weight = 1);
83 
84  void book2D(DQMStore::IBooker &ib, std::string name, const HistLim& limX, const HistLim& limY);
85 
86  void fill2D(std::string name, double X, double Y, double weight = 1);
87 
88  void bookPf(DQMStore::IBooker &ib, std::string name, const HistLim& limX, const HistLim& limY);
89 
90  void bookPf(DQMStore::IBooker &ib, std::string name, const HistLim& limX, const HistLim& limY, const char *option);
91 
92  void fillPf(std::string name, double X, double Y);
93 
95 
96  void booking(DQMStore::IBooker &ib, std::string subdetopt, int bnoise, int bmc);
97 
98  std::string str(int x);
99 
100  template<class Digi> void reco(const edm::Event& iEvent, const edm::EventSetup& iSetup, const edm::EDGetTokenT<edm::SortedCollection<Digi> > &tok);
101  void eval_occupancy();
102 
110  int noise_;
111 
118 
121 
122  //TP Code
124  //~TP Code
125 
126  int nevent1;
127  int nevent2;
128  int nevent3;
129  int nevent4;
130  int nevtot;
131 
132 };
133 
134 #endif
135 
136 
virtual void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &)
edm::ESHandle< CaloGeometry > geometry
int ib
Definition: cuy.py:660
edm::EDGetTokenT< edm::SortedCollection< HBHEDataFrame > > tok_hbhe_
edm::EDGetTokenT< edm::SortedCollection< HODataFrame > > tok_ho_
#define X(str)
Definition: MuonsGrabber.cc:48
void reco(const edm::Event &iEvent, const edm::EventSetup &iSetup, const edm::EDGetTokenT< edm::SortedCollection< Digi > > &tok)
virtual void analyze(const edm::Event &, const edm::EventSetup &)
std::map< std::string, MonitorElement * > * msm_
int iEvent
Definition: GenABIO.cc:230
MonitorElement * monitor(std::string name)
void fillPf(std::string name, double X, double Y)
void fill2D(std::string name, double X, double Y, double weight=1)
edm::ESHandle< HcalTopology > htopo
HcalDigisValidation(const edm::ParameterSet &)
void bookPf(DQMStore::IBooker &ib, std::string name, const HistLim &limX, const HistLim &limY)
T min(T a, T b)
Definition: MathUtil.h:58
void book2D(DQMStore::IBooker &ib, std::string name, const HistLim &limX, const HistLim &limY)
edm::EDGetTokenT< edm::SortedCollection< HFDataFrame > > tok_hf_
void fill1D(std::string name, double X, double weight=1)
edm::EDGetTokenT< edm::PCaloHitContainer > tok_mc_
void booking(DQMStore::IBooker &ib, std::string subdetopt, int bnoise, int bmc)
edm::EDGetTokenT< HcalTrigPrimDigiCollection > tok_emulTPs_
std::string str(int x)
edm::EDGetTokenT< HcalTrigPrimDigiCollection > tok_dataTPs_
edm::ESHandle< HcalDbService > conditions
void book1D(DQMStore::IBooker &ib, std::string name, int n, double min, double max)
HistLim(int nbin, double mini, double maxi)
Definition: Run.h:43