CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
RPCEfficiency.h
Go to the documentation of this file.
1 
17 
20 
26 
27 #include<string>
28 #include<map>
29 #include<fstream>
30 
31 class RPCDetId;
32 class TFile;
33 class TH1F;
34 class TFile;
35 class TCanvas;
36 class TH2F;
37 class TString;
38 
39 
41 public:
43  DTStationIndex(int region, int wheel, int sector, int station) :
44  _region(region),
45  _wheel(wheel),
46  _sector(sector),
47  _station(station){}
49  int region() const {return _region;}
50  int wheel() const {return _wheel;}
51  int sector() const {return _sector;}
52  int station() const {return _station;}
53  bool operator<(const DTStationIndex& dtind) const{
54  if(dtind.region()!=this->region())
55  return dtind.region()<this->region();
56  else if(dtind.wheel()!=this->wheel())
57  return dtind.wheel()<this->wheel();
58  else if(dtind.sector()!=this->sector())
59  return dtind.sector()<this->sector();
60  else if(dtind.station()!=this->station())
61  return dtind.station()<this->station();
62  return false;
63  }
64 private:
65  int _region;
66  int _wheel;
67  int _sector;
68  int _station;
69 };
70 
71 
73 public:
75  CSCStationIndex(int region, int station, int ring, int chamber):
76  _region(region),
77  _station(station),
78  _ring(ring),
79  _chamber(chamber){}
81  int region() const {return _region;}
82  int station() const {return _station;}
83  int ring() const {return _ring;}
84  int chamber() const {return _chamber;}
85  bool operator<(const CSCStationIndex& cscind) const{
86  if(cscind.region()!=this->region())
87  return cscind.region()<this->region();
88  else if(cscind.station()!=this->station())
89  return cscind.station()<this->station();
90  else if(cscind.ring()!=this->ring())
91  return cscind.ring()<this->ring();
92  else if(cscind.chamber()!=this->chamber())
93  return cscind.chamber()<this->chamber();
94  return false;
95  }
96 
97 private:
98  int _region;
99  int _station;
100  int _ring;
101  int _chamber;
102 };
103 
105  public:
106  explicit RPCEfficiency(const edm::ParameterSet&);
107  ~RPCEfficiency();
108  virtual void beginJob() ;
109  virtual void beginRun(const edm::Run&, const edm::EventSetup&);
110  virtual void analyze(const edm::Event&, const edm::EventSetup&);
111  virtual void endJob() ;
112  std::map<std::string, MonitorElement*> bookDetUnitSeg(RPCDetId & detId,int nstrips, std::string folder);
113  virtual void endRun(const edm::Run& r, const edm::EventSetup& iSetup);
114  std::map<DTStationIndex,std::set<RPCDetId> > rollstoreDT;
115  std::map<CSCStationIndex,std::set<RPCDetId> > rollstoreCSC;
119 
122  //Distance Strip
129 
136 
143 
144  //Ang Dependence
151 
158 
165 
166  //Residuals
167 
174 
181 
188 
189  //Endcap
196 
203 
210 
211  private:
212  std::vector<std::map<RPCDetId, int> > counter;
213  std::vector<int> totalcounter;
214  std::ofstream ofrej;
215  bool incldt;
216  bool incldtMB4;
217  bool inclcsc;
218  bool debug;
219  bool paper;
220  bool inves;
221  double rangestrips;
223  double MinCosAng;
224  double MaxD;
225  double MaxDrb4;
226  int dupli;
227  std::string muonRPCDigis;
228  std::string cscSegments;
229  std::string dt4DSegments;
230  std::string folderPath;
231  std::string rejected;
232  std::string rollseff;
233 
234  std::map<int, std::map<std::string, MonitorElement*> > meCollection;
235 
237  std::string EffRootFileName;
238  std::string nameInLog;
239 
241 };
MonitorElement * DistBorderClu1La3
MonitorElement * DistBorderClu3La4
int chamber() const
Definition: RPCEfficiency.h:84
MonitorElement * AngClu2La6
MonitorElement * AngClu2La2
MonitorElement * hGlobalResClu1La3
int wheel() const
Definition: RPCEfficiency.h:50
virtual void endJob()
edm::ESHandle< RPCGeometry > rpcGeo
MonitorElement * hGlobalResClu1R2A
MonitorElement * AngClu3La1
RPCEfficiency(const edm::ParameterSet &)
MonitorElement * AngClu1La6
MonitorElement * DistBorderClu1La1
MonitorElement * AngClu3La4
MonitorElement * hGlobalResClu1R3A
MonitorElement * DistBorderClu1La5
std::string muonRPCDigis
MonitorElement * DistBorderClu3La5
std::map< std::string, MonitorElement * > bookDetUnitSeg(RPCDetId &detId, int nstrips, std::string folder)
MonitorElement * hGlobalResClu3R2C
MonitorElement * hGlobalResClu3La1
MonitorElement * hGlobalResClu3R3C
MonitorElement * AngClu3La6
MonitorElement * hGlobalResClu2La2
virtual void beginJob()
std::map< int, std::map< std::string, MonitorElement * > > meCollection
std::ofstream ofrej
MonitorElement * DistBorderClu1La4
CSCStationIndex(int region, int station, int ring, int chamber)
Definition: RPCEfficiency.h:75
MonitorElement * DistBorderClu1La2
int station() const
Definition: RPCEfficiency.h:82
MonitorElement * DistBorderClu3La6
DQMStore * dbe
std::string EffRootFileName
MonitorElement * AngClu2La5
MonitorElement * hGlobalResClu3La3
edm::ESHandle< DTGeometry > dtGeo
MonitorElement * hGlobalResClu1La6
virtual void endRun(const edm::Run &r, const edm::EventSetup &iSetup)
DTStationIndex(int region, int wheel, int sector, int station)
Definition: RPCEfficiency.h:43
MonitorElement * AngClu1La4
MonitorElement * AngClu2La1
std::string dt4DSegments
MonitorElement * AngClu2La4
std::string folderPath
int ring() const
Definition: RPCEfficiency.h:83
MonitorElement * hGlobalResClu3R2A
MonitorElement * hGlobalResClu2La5
MonitorElement * DistBorderClu3La2
double rangestripsRB4
MonitorElement * DistBorderClu2La4
MonitorElement * hGlobalResClu1La4
std::vector< int > totalcounter
MonitorElement * hGlobalResClu1R3B
MonitorElement * hGlobalResClu1R2C
MonitorElement * DistBorderClu2La5
MonitorElement * hGlobalResClu2R3C
MonitorElement * hGlobalResClu3R3A
MonitorElement * DistBorderClu2La6
std::map< CSCStationIndex, std::set< RPCDetId > > rollstoreCSC
MonitorElement * DistBorderClu2La1
MonitorElement * statistics
MonitorElement * hGlobalResClu2La4
std::string nameInLog
MonitorElement * DistBorderClu2La2
std::map< DTStationIndex, std::set< RPCDetId > > rollstoreDT
MonitorElement * hGlobalResClu1La1
edm::ESHandle< CSCGeometry > cscGeo
MonitorElement * hGlobalResClu2La6
MonitorElement * DistBorderClu3La3
MonitorElement * hGlobalResClu2R2A
MonitorElement * AngClu3La5
MonitorElement * hGlobalResClu2R3A
MonitorElement * AngClu2La3
std::vector< std::map< RPCDetId, int > > counter
MonitorElement * AngClu1La2
MonitorElement * AngClu3La2
MonitorElement * AngClu1La5
edm::InputTag RPCRecHitLabel_
int station() const
Definition: RPCEfficiency.h:52
int region() const
Definition: RPCEfficiency.h:49
bool operator<(const CSCStationIndex &cscind) const
Definition: RPCEfficiency.h:85
double rangestrips
MonitorElement * hGlobalResClu3La2
MonitorElement * hGlobalResClu3La5
bool operator<(const DTStationIndex &dtind) const
Definition: RPCEfficiency.h:53
MonitorElement * hGlobalResClu2La1
MonitorElement * DistBorderClu3La1
MonitorElement * hGlobalResClu2La3
MonitorElement * hGlobalResClu3La6
MonitorElement * DistBorderClu2La3
int region() const
Definition: RPCEfficiency.h:81
virtual void analyze(const edm::Event &, const edm::EventSetup &)
MonitorElement * hGlobalResClu1R3C
MonitorElement * hGlobalResClu2R2B
int sector() const
Definition: RPCEfficiency.h:51
MonitorElement * AngClu1La3
MonitorElement * AngClu1La1
MonitorElement * hGlobalResClu3R3B
MonitorElement * DistBorderClu1La6
std::string rollseff
std::string rejected
virtual void beginRun(const edm::Run &, const edm::EventSetup &)
MonitorElement * hGlobalResClu1La5
MonitorElement * hGlobalResClu3R2B
std::string cscSegments
MonitorElement * hGlobalResClu2R3B
MonitorElement * hGlobalResClu3La4
MonitorElement * hGlobalResClu1R2B
MonitorElement * hGlobalResClu2R2C
MonitorElement * hGlobalResClu1La2
Definition: Run.h:31
MonitorElement * AngClu3La3