CMS 3D CMS Logo

METTesterPostProcessor.cc
Go to the documentation of this file.
1 // -*- C++ -*-
2 //
3 // Package: Validation/RecoMET
4 // Class: METTesterPostProcessor
5 //
6 // Original Author: "Matthias Weber"
7 // Created: Sun Feb 22 14:35:25 CET 2015
8 //
9 
13 
14 // Some switches
15 //
16 // constructors and destructor
17 //
19 
21 
22 // ------------ method called right after a run ends ------------
24  std::vector<std::string> subDirVec;
25  std::string RunDir = "JetMET/METValidation/";
26  iget_.setCurrentFolder(RunDir);
27  met_dirs = iget_.getSubdirs();
28  // bin definition for resolution plot -> last bin contains overflow too, but
29  // for plotting purposes show up to 1 TeV only
30  int nBins = 11;
31  float bins[] = {0., 20., 40., 60., 80., 100., 150., 200., 300., 400., 500., 1000};
32  // loop over met subdirectories
33  for (int i = 0; i < int(met_dirs.size()); i++) {
34  ibook_.setCurrentFolder(met_dirs[i]);
36  ibook_.book1D("METResolution_GenMETTrue_InMETBins", "METResolution_GenMETTrue_InMETBins", nBins, bins);
37  FillMETRes(met_dirs[i], iget_);
38  }
39 }
40 
53 
54  mMETDifference_GenMETTrue_MET0to20 = iget.get(metdir + "/METResolution_GenMETTrue_MET0to20");
55  mMETDifference_GenMETTrue_MET20to40 = iget.get(metdir + "/METResolution_GenMETTrue_MET20to40");
56  mMETDifference_GenMETTrue_MET40to60 = iget.get(metdir + "/METResolution_GenMETTrue_MET40to60");
57  mMETDifference_GenMETTrue_MET60to80 = iget.get(metdir + "/METResolution_GenMETTrue_MET60to80");
58  mMETDifference_GenMETTrue_MET80to100 = iget.get(metdir + "/METResolution_GenMETTrue_MET80to100");
59  mMETDifference_GenMETTrue_MET100to150 = iget.get(metdir + "/METResolution_GenMETTrue_MET100to150");
60  mMETDifference_GenMETTrue_MET150to200 = iget.get(metdir + "/METResolution_GenMETTrue_MET150to200");
61  mMETDifference_GenMETTrue_MET200to300 = iget.get(metdir + "/METResolution_GenMETTrue_MET200to300");
62  mMETDifference_GenMETTrue_MET300to400 = iget.get(metdir + "/METResolution_GenMETTrue_MET300to400");
63  mMETDifference_GenMETTrue_MET400to500 = iget.get(metdir + "/METResolution_GenMETTrue_MET400to500");
64  mMETDifference_GenMETTrue_MET500 = iget.get(metdir + "/METResolution_GenMETTrue_MET500");
66  mMETDifference_GenMETTrue_MET0to20->getRootObject()) { // check one object, if existing, then the
67  // remaining ME's exist too
68  // for genmet none of these ME's are filled
80 
81  // the error computation should be done in a postProcessor in the harvesting
82  // step otherwise the histograms will be just summed
94  }
95 }
std::vector< std::string > met_dirs
MonitorElement * mMETDifference_GenMETTrue_MET20to40
virtual void setCurrentFolder(std::string const &fullpath)
Definition: DQMStore.cc:36
MonitorElement * mMETDifference_GenMETTrue_MET200to300
MonitorElement * mMETDifference_GenMETTrue_MET300to400
void dqmEndJob(DQMStore::IBooker &, DQMStore::IGetter &) override
MonitorElement * mMETDifference_GenMETTrue_MET0to20
virtual double getRMS(int axis=1) const
get RMS of histogram along x, y or z axis (axis=1, 2, 3 respectively)
MonitorElement * mMETDifference_GenMETTrue_MET60to80
MonitorElement * mMETDifference_GenMETTrue_MET80to100
MonitorElement * mMETDifference_GenMETTrue_MET400to500
MonitorElement * mMETDifference_GenMETTrue_MET150to200
virtual void setBinContent(int binx, double content)
set content of bin (1-D)
virtual MonitorElement * get(std::string const &fullpath) const
Definition: DQMStore.cc:690
MonitorElement * mMETDifference_GenMETTrue_MET500
MonitorElement * mMETDifference_GenMETTrue_METResolution
virtual double getMean(int axis=1) const
get mean value of histogram along x, y or z axis (axis=1, 2, 3 respectively)
MonitorElement * mMETDifference_GenMETTrue_MET40to60
TObject * getRootObject() const override
virtual void setBinError(int binx, double error)
set uncertainty on content of bin (1-D)
MonitorElement * book1D(TString const &name, TString const &title, int const nchX, double const lowX, double const highX, FUNC onbooking=NOOP())
Definition: DQMStore.h:98
METTesterPostProcessor(const edm::ParameterSet &)
void FillMETRes(std::string metdir, DQMStore::IGetter &)
MonitorElement * mMETDifference_GenMETTrue_MET100to150
virtual DQM_DEPRECATED std::vector< std::string > getSubdirs() const
Definition: DQMStore.cc:717