CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
PhotonOfflineClient.cc
Go to the documentation of this file.
1 #include <iostream>
2 //
3 
5 
6 
7 //#define TWOPI 6.283185308
8 //
9 
22 using namespace std;
23 using std::cout;
24 
26 {
27 
28  //dbe_ = 0;
29  //dbe_ = edm::Service<DQMStore>().operator->();
30  // dbe_->setVerbose(0);
31  parameters_ = pset;
32 
33  analyzerName_ = pset.getParameter<string>("analyzerName");
34  cutStep_ = pset.getParameter<double>("cutStep");
35  numberOfSteps_ = pset.getParameter<int>("numberOfSteps");
36 
37  etMin = pset.getParameter<double>("etMin");
38  etMax = pset.getParameter<double>("etMax");
39  etBin = pset.getParameter<int>("etBin");
40  etaMin = pset.getParameter<double>("etaMin");
41  etaMax = pset.getParameter<double>("etaMax");
42  etaBin = pset.getParameter<int>("etaBin");
43  phiMin = pset.getParameter<double>("phiMin");
44  phiMax = pset.getParameter<double>("phiMax");
45  phiBin = pset.getParameter<int>("phiBin");
46 
47  standAlone_ = pset.getParameter<bool>("standAlone");
48  batch_ = pset.getParameter<bool>("batch");
49  excludeBkgHistos_ = pset.getParameter<bool>("excludeBkgHistos");
50 
51  outputFileName_ = pset.getParameter<string>("OutputFileName");
52  inputFileName_ = pset.getUntrackedParameter<string>("InputFileName");
53 
54  histo_index_photons_ = 0;
55  histo_index_conversions_ = 0;
56  histo_index_efficiency_ = 0;
57  histo_index_invMass_ = 0;
58 
59  types_.push_back("All");
60  types_.push_back("GoodCandidate");
61  if (!excludeBkgHistos_) types_.push_back("Background");
62 
63  parts_.push_back("AllEcal");
64  parts_.push_back("Barrel");
65  parts_.push_back("Endcaps");
66 
67 }
68 
70 {}
71 //void PhotonOfflineClient::beginJob(){}
72 //void PhotonOfflineClient::analyze(const edm::Event& e, const edm::EventSetup& esup){}
73 //void PhotonOfflineClient::endLuminosityBlock( const edm::LuminosityBlock& , const edm::EventSetup& setup){}
74 
76 {
77  if(!standAlone_) runClient(iBooker, iGetter);
78 }
79 //void PhotonOfflineClient::endRun(const edm::Run& run, const edm::EventSetup& setup){ if(!standAlone_) runClient();}
80 
82 {
83  // if(!dbe_) return;
84 
85  //if(batch_) dbe_->open(inputFileName_);
86 
87  //std::cout << " PostProcessing analyzer name " << analyzerName_ << std::endl;
88  if(!iGetter.dirExists("Egamma/"+analyzerName_)){
89  std::cout << "Folder Egamma/"+analyzerName_+" does not exist - Abort the efficiency calculation " << std::endl;
90  return;
91  }
92 
93  //find out how many histograms are in the various folders
94  histo_index_photons_ = iGetter.get("Egamma/"+analyzerName_+"/numberOfHistogramsInPhotonsFolder")->getIntValue();
95  histo_index_conversions_ = iGetter.get("Egamma/"+analyzerName_+"/numberOfHistogramsInConversionsFolder")->getIntValue();
96  histo_index_efficiency_ = iGetter.get("Egamma/"+analyzerName_+"/numberOfHistogramsInEfficiencyFolder")->getIntValue();
97  histo_index_invMass_ = iGetter.get("Egamma/"+analyzerName_+"/numberOfHistogramsInInvMassFolder")->getIntValue();
98 
99  iGetter.setCurrentFolder("Egamma/"+analyzerName_+"/");
100  iGetter.removeElement("numberOfHistogramsInPhotonsFolder");
101  iGetter.removeElement("numberOfHistogramsInConversionsFolder");
102  iGetter.removeElement("numberOfHistogramsInEfficiencyFolder");
103  iGetter.removeElement("numberOfHistogramsInInvMassFolder");
104 
105  string AllPath = "Egamma/"+analyzerName_+"/AllPhotons/";
106  string IsoPath = "Egamma/"+analyzerName_+"/GoodCandidatePhotons/";
107  string NonisoPath = "Egamma/"+analyzerName_+"/BackgroundPhotons/";
108  string EffPath = "Egamma/"+analyzerName_+"/Efficiencies/";
109 
110  //booking efficiency histograms
111  iGetter.setCurrentFolder(EffPath);
112 
113  p_efficiencyVsEtaLoose_ = bookHisto(iBooker,"EfficiencyVsEtaLoose","Fraction of Photons passing Loose Isolation vs #eta;#eta",etaBin,etaMin, etaMax);
114  p_efficiencyVsEtLoose_ = bookHisto(iBooker,"EfficiencyVsEtLoose", "Fraction of Photons passing Loose Isolation vs E_{T};E_{T} (GeV)",etBin,etMin,etMax);
115  p_efficiencyVsEtaTight_ = bookHisto(iBooker,"EfficiencyVsEtaTight","Fraction of Photons passing Tight Isolation vs #eta;#eta",etaBin,etaMin, etaMax);
116  p_efficiencyVsEtTight_ = bookHisto(iBooker,"EfficiencyVsEtTight", "Fraction of Photons passing Tight Isolation vs E_{T};E_{T} (GeV)",etBin,etMin,etMax);
117 
118  p_efficiencyVsEtaHLT_ = bookHisto(iBooker,"EfficiencyVsEtaHLT","Fraction of Photons firing HLT vs #eta;#eta",etaBin,etaMin, etaMax);
119  p_efficiencyVsEtHLT_ = bookHisto(iBooker,"EfficiencyVsEtHLT", "Fraction of Photons firing HLT vs E_{T};E_{T} (GeV)",etBin,etMin,etMax);
120 
121  p_convFractionVsEtaLoose_ = bookHisto(iBooker,"ConvFractionVsEtaLoose","Fraction of Loosely Isolated Photons which are matched to two tracks vs #eta;#eta",etaBin,etaMin, etaMax);
122  p_convFractionVsEtLoose_ = bookHisto(iBooker,"ConvFractionVsEtLoose", "Fraction of Loosely Isolated Photons which are matched to two tracks vs E_{T};E_{T} (GeV)",etBin,etMin,etMax);
123  p_convFractionVsEtaTight_ = bookHisto(iBooker,"ConvFractionVsEtaTight","Fraction of Tightly Isolated Photons which are matched to two tracks vs #eta;#eta",etaBin,etaMin, etaMax);
124  p_convFractionVsEtTight_ = bookHisto(iBooker,"ConvFractionVsEtTight", "Fraction of Tightly Isolated Photons which are matched to two tracks vs E_{T};E_{T} (GeV)",etBin,etMin,etMax);
125 
126  p_vertexReconstructionEfficiencyVsEta_ = bookHisto(iBooker,"VertexReconstructionEfficiencyVsEta","Fraction of Converted Photons which have a valid vertex vs #eta;#eta",etaBin,etaMin, etaMax);
127 
128  //booking conversion fraction histograms
129  iGetter.setCurrentFolder(AllPath+"Et above 20 GeV/Conversions");
130  book2DHistoVector(iBooker, p_convFractionVsEt_, "1D","convFractionVsEt", "Fraction of Converted Photons vs E_{T};E_{T} (GeV)",etBin,etMin,etMax);
131  book3DHistoVector(iBooker, p_convFractionVsPhi_,"1D","convFractionVsPhi","Fraction of Converted Photons vs #phi;#phi",phiBin,phiMin,phiMax);
132  book2DHistoVector(iBooker, p_convFractionVsEta_, "1D","convFractionVsEta","Fraction of Converted Photons vs #eta;#eta",etaBin,etaMin,etaMax);
133 
134  //booking bad channel fraction histograms
135  iGetter.setCurrentFolder(AllPath+"Et above 20 GeV/");
136  book2DHistoVector(iBooker, p_badChannelsFractionVsPhi_, "1D","badChannelsFractionVsPhi","Fraction of Photons which have at least one bad channel vs #phi;#phi",phiBin,phiMin,phiMax);
137  book2DHistoVector(iBooker, p_badChannelsFractionVsEta_, "1D","badChannelsFractionVsEta","Fraction of Photons which have at least one bad channel vs #eta;#eta",etaBin,etaMin, etaMax);
138  book2DHistoVector(iBooker, p_badChannelsFractionVsEt_, "1D","badChannelsFractionVsEt", "Fraction of Photons which have at least one bad channel vs E_{T};E_{T} (GeV)",etBin,etMin,etMax);
139 
140  //making efficiency plots
141  MonitorElement * dividend;
144 
145  currentFolder_.str("");
146  currentFolder_ << AllPath << "Et above 20 GeV/";
147 
148  //HLT efficiency plots
149  dividend = retrieveHisto(iGetter,EffPath,"EfficiencyVsEtaHLT");
150  numerator = retrieveHisto(iGetter,EffPath,"phoEtaPostHLT");
151  denominator = retrieveHisto(iGetter,EffPath,"phoEtaPreHLT");
152  dividePlots(dividend,numerator,denominator);
153 
154  dividend = retrieveHisto(iGetter,EffPath,"EfficiencyVsEtHLT");
155  numerator = retrieveHisto(iGetter,EffPath,"phoEtPostHLT");
156  denominator = retrieveHisto(iGetter,EffPath,"phoEtPreHLT");
157  dividePlots(dividend,numerator,denominator);
158 
159  //efficiencies vs Eta
160  denominator = retrieveHisto(iGetter,currentFolder_.str(),"phoEta");
161 
162  dividend = retrieveHisto(iGetter,EffPath,"EfficiencyVsEtaLoose");
163  numerator = retrieveHisto(iGetter,EffPath,"phoEtaLoose");
164  dividePlots(dividend,numerator,denominator);
165 
166  dividend = retrieveHisto(iGetter,EffPath,"EfficiencyVsEtaTight");
167  numerator = retrieveHisto(iGetter,EffPath,"phoEtaTight");
168  dividePlots(dividend,numerator,denominator);
169 
170  //efficiencies vs Et
171  denominator = retrieveHisto(iGetter,currentFolder_.str(),"phoEtAllEcal");
172 
173  dividend = retrieveHisto(iGetter,EffPath,"EfficiencyVsEtLoose");
174  numerator = retrieveHisto(iGetter,EffPath,"phoEtLoose");
175  dividePlots(dividend,numerator,denominator);
176 
177  dividend = retrieveHisto(iGetter,EffPath,"EfficiencyVsEtTight");
178  numerator = retrieveHisto(iGetter,EffPath,"phoEtTight");
179  dividePlots(dividend,numerator,denominator);
180 
181  //conversion fractions vs Eta
182  dividend = retrieveHisto(iGetter,EffPath,"ConvFractionVsEtaLoose");
183  numerator = retrieveHisto(iGetter,EffPath,"convEtaLoose");
184  denominator = retrieveHisto(iGetter,EffPath,"phoEtaLoose");
185  dividePlots(dividend,numerator,denominator);
186 
187  dividend = retrieveHisto(iGetter,EffPath,"ConvFractionVsEtaTight");
188  numerator = retrieveHisto(iGetter,EffPath,"convEtaTight");
189  denominator = retrieveHisto(iGetter,EffPath,"phoEtaTight");
190  dividePlots(dividend,numerator,denominator);
191 
192  //conversion fractions vs Et
193  dividend = retrieveHisto(iGetter,EffPath,"ConvFractionVsEtLoose");
194  numerator = retrieveHisto(iGetter,EffPath,"convEtLoose");
195  denominator = retrieveHisto(iGetter,EffPath,"phoEtLoose");
196  dividePlots(dividend,numerator,denominator);
197 
198  dividend = retrieveHisto(iGetter,EffPath,"ConvFractionVsEtTight");
199  numerator = retrieveHisto(iGetter,EffPath,"convEtTight");
200  denominator = retrieveHisto(iGetter,EffPath,"phoEtTight");
201  dividePlots(dividend,numerator,denominator);
202 
203  //conversion vertex recontruction efficiency
204  dividend = retrieveHisto(iGetter,EffPath,"VertexReconstructionEfficiencyVsEta");
205  numerator = retrieveHisto(iGetter,currentFolder_.str()+"Conversions/","phoConvEta");
206  denominator = retrieveHisto(iGetter,EffPath,"phoEtaVertex");
207  dividePlots(dividend,numerator,denominator);
208 
209  iGetter.setCurrentFolder(EffPath);
210 
211  iGetter.removeElement("phoEtaPreHLT");
212  iGetter.removeElement("phoEtPreHLT");
213  iGetter.removeElement("phoEtaPostHLT");
214  iGetter.removeElement("phoEtPostHLT");
215  iGetter.removeElement("phoEtaLoose");
216  iGetter.removeElement("phoEtaTight");
217  iGetter.removeElement("phoEtLoose");
218  iGetter.removeElement("phoEtTight");
219  iGetter.removeElement("phoEtaVertex");
220  iGetter.removeElement("convEtaLoose");
221  iGetter.removeElement("convEtaTight");
222  iGetter.removeElement("convEtLoose");
223  iGetter.removeElement("convEtTight");
224 
225  for(uint type=0;type!=types_.size();++type){
226 
227  for (int cut = 0; cut !=numberOfSteps_; ++cut) {
228 
229  currentFolder_.str("");
230  currentFolder_ << "Egamma/"+analyzerName_+"/" << types_[type] << "Photons/Et above " << (cut+1)*cutStep_ << " GeV/";
231 
232  //making bad channel histograms
233 
234  //vs Et
235  dividend = retrieveHisto(iGetter,currentFolder_.str(),"badChannelsFractionVsEt");
236  numerator = retrieveHisto(iGetter,currentFolder_.str(),"phoEtBadChannels");
237  denominator = retrieveHisto(iGetter,currentFolder_.str(),"phoEtAllEcal");
238  dividePlots(dividend,numerator,denominator);
239 
240  //vs eta
241  dividend = retrieveHisto(iGetter,currentFolder_.str(),"badChannelsFractionVsEta");
242  numerator = retrieveHisto(iGetter,currentFolder_.str(),"phoEtaBadChannels");
243  denominator = retrieveHisto(iGetter,currentFolder_.str(),"phoEta");
244  dividePlots(dividend,numerator,denominator);
245 
246  //vs phi
247  dividend = retrieveHisto(iGetter,currentFolder_.str(),"badChannelsFractionVsPhi");
248  numerator = retrieveHisto(iGetter,currentFolder_.str(),"phoPhiBadChannels");
249  denominator = retrieveHisto(iGetter,currentFolder_.str(),"phoPhiAllEcal");
250  dividePlots(dividend,numerator,denominator);
251 
252  //making conversion fraction histograms
253 
254  //vs Et
255  dividend = retrieveHisto(iGetter,currentFolder_.str()+"Conversions/","convFractionVsEt");
256  numerator = retrieveHisto(iGetter,currentFolder_.str()+"Conversions/","phoConvEtAllEcal");
257  denominator = retrieveHisto(iGetter,currentFolder_.str(),"phoEtAllEcal");
258  dividePlots(dividend,numerator,denominator);
259 
260  //vs eta
261  dividend = retrieveHisto(iGetter,currentFolder_.str()+"Conversions/","convFractionVsEta");
262  numerator = retrieveHisto(iGetter,currentFolder_.str()+"Conversions/","phoConvEtaForEfficiency");
263  denominator = retrieveHisto(iGetter,currentFolder_.str(),"phoEta");
264  dividePlots(dividend,numerator,denominator);
265 
266  //vs phi
267  dividend = retrieveHisto(iGetter,currentFolder_.str()+"Conversions/","convFractionVsPhiAllEcal");
268  numerator = retrieveHisto(iGetter,currentFolder_.str()+"Conversions/","phoConvPhiForEfficiencyAllEcal");
269  denominator = retrieveHisto(iGetter,currentFolder_.str(),"phoPhiAllEcal");
270  dividePlots(dividend,numerator,denominator);
271  dividend = retrieveHisto(iGetter,currentFolder_.str()+"Conversions/","convFractionVsPhiBarrel");
272  numerator = retrieveHisto(iGetter,currentFolder_.str()+"Conversions/","phoConvPhiForEfficiencyBarrel");
273  denominator = retrieveHisto(iGetter,currentFolder_.str(),"phoPhiBarrel");
274  dividePlots(dividend,numerator,denominator);
275  dividend = retrieveHisto(iGetter,currentFolder_.str()+"Conversions/","convFractionVsPhiEndcaps");
276  numerator = retrieveHisto(iGetter,currentFolder_.str()+"Conversions/","phoConvPhiForEfficiencyEndcaps");
277  denominator = retrieveHisto(iGetter,currentFolder_.str(),"phoPhiEndcaps");
278  dividePlots(dividend,numerator,denominator);
279 
280 
281  iGetter.setCurrentFolder(currentFolder_.str()+"Conversions/");
282  iGetter.removeElement("phoConvEtaForEfficiency");
283  iGetter.removeElement("phoConvPhiForEfficiencyAllEcal");
284  iGetter.removeElement("phoConvPhiForEfficiencyBarrel");
285  iGetter.removeElement("phoConvPhiForEfficiencyEndcaps");
286  }
287  }
288 
289  // if(standAlone_) dbe_->save(outputFileName_);
290  //else if(batch_) dbe_->save(inputFileName_);
291 
292 }
293 
295  double value,err;
296 
297  dividend->setEfficiencyFlag();
298  if(denominator->getEntries()==0) return;
299 
300  for (int j=1; j<=numerator->getNbinsX(); j++){
301  if (denominator->getBinContent(j)!=0){
302  value = ((double) numerator->getBinContent(j))/((double) denominator->getBinContent(j));
303  err = sqrt( value*(1-value) / ((double) denominator->getBinContent(j)) );
304  dividend->setBinContent(j, value);
305  dividend->setBinError(j,err);
306  }
307  else {
308  dividend->setBinContent(j, 0);
309  dividend->setBinError(j,0);
310  }
311  dividend->setEntries(numerator->getEntries());
312  }
313 }
314 
315 
317  double value,err;
318 
319  dividend->setEfficiencyFlag();
320  for (int j=1; j<=numerator->getNbinsX(); j++){
321  if (denominator!=0){
322  value = ((double) numerator->getBinContent(j))/denominator;
323  err = sqrt( value*(1-value) / denominator);
324  dividend->setBinContent(j, value);
325  dividend->setBinError(j,err);
326  }
327  else {
328  dividend->setBinContent(j, 0);
329  }
330  }
331 
332 }
333 
335 {
336 
337  int histo_index = 0;
338  stringstream histo_number_stream;
339 
340 
341  //determining which folder we're in
342  if(iBooker.pwd().find( "InvMass" ) != string::npos){
343  histo_index_invMass_++;
344  histo_index = histo_index_invMass_;
345  }
346  if(iBooker.pwd().find( "Efficiencies" ) != string::npos){
347  histo_index_efficiency_++;
348  histo_index = histo_index_efficiency_;
349  }
350  histo_number_stream << "h_";
351  if(histo_index<10) histo_number_stream << "0";
352  histo_number_stream << histo_index;
353 
354  return iBooker.book1D(histo_number_stream.str()+"_"+histoName,title,bin,min,max);
355 
356 }
357 
358 
359 
360 void PhotonOfflineClient::book2DHistoVector(DQMStore::IBooker& iBooker, std::vector<vector<MonitorElement*> >& temp2DVector,
362  int xbin, double xmin,double xmax,
363  int ybin, double ymin, double ymax)
364 {
365  int histo_index = 0;
366 
367  vector<MonitorElement*> temp1DVector;
368 
369  //determining which folder we're in
370  bool conversionPlot = false;
371  if(iBooker.pwd().find( "Conversions" ) != string::npos) conversionPlot = true;
372 
373 
374  if(conversionPlot){
375  histo_index_conversions_++;
376  histo_index = histo_index_conversions_;
377  }
378  else{
379  histo_index_photons_++;
380  histo_index = histo_index_photons_;
381  }
382 
383 
384  stringstream histo_number_stream;
385  histo_number_stream << "h_";
386  if(histo_index<10) histo_number_stream << "0";
387  histo_number_stream << histo_index << "_";
388 
389 
390  for(int cut = 0; cut != numberOfSteps_; ++cut){ //looping over Et cut values
391 
392  for(uint type=0;type!=types_.size();++type){ //looping over isolation type
393 
394  currentFolder_.str("");
395  currentFolder_ << "Egamma/"+analyzerName_+"/" << types_[type] << "Photons/Et above " << (cut+1)*cutStep_ << " GeV";
396  if(conversionPlot) currentFolder_ << "/Conversions";
397 
398  iBooker.setCurrentFolder(currentFolder_.str());
399 
400  string kind;
401  if(conversionPlot) kind = " Conversions: ";
402  else kind = " Photons: ";
403 
404  if(histoType=="1D") temp1DVector.push_back(iBooker.book1D(histo_number_stream.str()+histoName,types_[type]+kind+title,xbin,xmin,xmax));
405  else if(histoType=="2D") temp1DVector.push_back(iBooker.book2D(histo_number_stream.str()+histoName,types_[type]+kind+title,xbin,xmin,xmax,ybin,ymin,ymax));
406  else if(histoType=="Profile") temp1DVector.push_back(iBooker.bookProfile(histo_number_stream.str()+histoName,types_[type]+kind+title,xbin,xmin,xmax,ybin,ymin,ymax,""));
407  //else cout << "bad histoType\n";
408  }
409 
410  temp2DVector.push_back(temp1DVector);
411  temp1DVector.clear();
412  }
413 
414 
415 
416 }
417 
418 
419 
420 
421 void PhotonOfflineClient::book3DHistoVector(DQMStore::IBooker& iBooker, std::vector<vector<vector<MonitorElement*> > >& temp3DVector,
423  int xbin, double xmin,double xmax,
424  int ybin, double ymin, double ymax)
425 {
426  int histo_index = 0;
427 
428  vector<MonitorElement*> temp1DVector;
429  vector<vector<MonitorElement*> > temp2DVector;
430 
431  //determining which folder we're in
432  bool conversionPlot = false;
433  if(iBooker.pwd().find( "Conversions" ) != string::npos) conversionPlot = true;
434 
435 
436  if(conversionPlot){
437  histo_index_conversions_++;
438  histo_index = histo_index_conversions_;
439  }
440  else{
441  histo_index_photons_++;
442  histo_index = histo_index_photons_;
443  }
444 
445  stringstream histo_number_stream;
446  histo_number_stream << "h_";
447  if(histo_index<10) histo_number_stream << "0";
448  histo_number_stream << histo_index << "_";
449 
450 
451  for(int cut = 0; cut != numberOfSteps_; ++cut){ //looping over Et cut values
452 
453  for(uint type=0;type!=types_.size();++type){ //looping over isolation type
454 
455  for(uint part=0;part!=parts_.size();++part){ //looping over different parts of the ecal
456 
457  currentFolder_.str("");
458  currentFolder_ << "Egamma/"+analyzerName_+"/" << types_[type] << "Photons/Et above " << (cut+1)*cutStep_ << " GeV";
459  if(conversionPlot) currentFolder_ << "/Conversions";
460 
461  iBooker.setCurrentFolder(currentFolder_.str());
462 
463  string kind;
464  if(conversionPlot) kind = " Conversions: ";
465  else kind = " Photons: ";
466 
467  if(histoType=="1D") temp1DVector.push_back(iBooker.book1D( histo_number_stream.str()+histoName+parts_[part],types_[type]+kind+parts_[part]+": "+title,xbin,xmin,xmax));
468  else if(histoType=="2D") temp1DVector.push_back(iBooker.book2D( histo_number_stream.str()+histoName+parts_[part],types_[type]+kind+parts_[part]+": "+title,xbin,xmin,xmax,ybin,ymin,ymax));
469  else if(histoType=="Profile") temp1DVector.push_back(iBooker.bookProfile( histo_number_stream.str()+histoName+parts_[part],types_[type]+kind+parts_[part]+": "+title,xbin,xmin,xmax,ybin,ymin,ymax,""));
470  //else cout << "bad histoType\n";
471 
472 
473  }
474 
475  temp2DVector.push_back(temp1DVector);
476  temp1DVector.clear();
477  }
478 
479  temp3DVector.push_back(temp2DVector);
480  temp2DVector.clear();
481  }
482 
483 
484 }
485 
486 
488  //cout << "dir = " << dir << endl;
489  //cout << "name = " << name << endl;
490  vector<MonitorElement*> histoVector;
491  uint indexOfRelevantHistogram=0;
492  string fullMEName = "";
493  histoVector = iGetter.getContents(dir);
494  for(uint index=0;index!=histoVector.size();index++){
495  string MEName = histoVector[index]->getName();
496  if(MEName.find( name ) != string::npos){
497  indexOfRelevantHistogram = index;
498  break;
499  }
500  }
501  return histoVector[indexOfRelevantHistogram];
502 }
503 
type
Definition: HCALResponse.h:21
std::vector< MonitorElement * > getContents(Args &&...args)
Definition: DQMStore.h:196
T getParameter(std::string const &) const
T getUntrackedParameter(std::string const &, T const &) const
void setBinContent(int binx, double content)
set content of bin (1-D)
list numerator
Definition: cuy.py:483
MonitorElement * bookProfile(Args &&...args)
Definition: DQMStore.h:157
MonitorElement * get(const std::string &path)
Definition: DQMStore.cc:298
const std::string & pwd(void)
Definition: DQMStore.cc:282
PhotonOfflineClient(const edm::ParameterSet &pset)
void dqmEndJob(DQMStore::IBooker &, DQMStore::IGetter &) override
double getEntries(void) const
get # of entries
void book2DHistoVector(DQMStore::IBooker &iBooker, std::vector< std::vector< MonitorElement * > > &vecOfHist, std::string histoType, std::string histoName, std::string title, int xbin, double xmin, double xmax, int ybin=1, double ymin=1, double ymax=2)
MonitorElement * retrieveHisto(DQMStore::IGetter &iGetter, std::string dir, std::string name)
list denominator
Definition: cuy.py:484
T sqrt(T t)
Definition: SSEVec.h:48
void dividePlots(MonitorElement *dividend, MonitorElement *numerator, MonitorElement *denominator)
MonitorElement * book1D(Args &&...args)
Definition: DQMStore.h:115
int j
Definition: DBlmapReader.cc:9
void setBinError(int binx, double error)
set uncertainty on content of bin (1-D)
T min(T a, T b)
Definition: MathUtil.h:58
void setEntries(double nentries)
set # of entries
bool dirExists(const std::string &path)
Definition: DQMStore.cc:314
void setCurrentFolder(const std::string &fullpath)
Definition: DQMStore.cc:274
MonitorElement * book2D(Args &&...args)
Definition: DQMStore.h:133
part
Definition: HCALResponse.h:20
int64_t getIntValue(void) const
void book3DHistoVector(DQMStore::IBooker &iBooker, std::vector< std::vector< std::vector< MonitorElement * > > > &vecOfHist, std::string histoType, std::string histoName, std::string title, int xbin, double xmin, double xmax, int ybin=1, double ymin=1, double ymax=2)
virtual void runClient(DQMStore::IBooker &iBooker, DQMStore::IGetter &iGetter)
void setCurrentFolder(const std::string &fullpath)
Definition: DQMStore.cc:326
double getBinContent(int binx) const
get content of bin (1-D)
int getNbinsX(void) const
get # of bins in X-axis
tuple cout
Definition: gather_cfg.py:121
void setEfficiencyFlag(void)
dbl *** dir
Definition: mlp_gen.cc:35
MonitorElement * bookHisto(DQMStore::IBooker &iBooker, std::string histoName, std::string title, int bin, double min, double max)
void removeElement(Args &&...args)
Definition: DQMStore.h:201