00001 #ifndef PhotonPostprocessing_H 00002 #define PhotonPostprocessing_H 00003 00004 #include "FWCore/ServiceRegistry/interface/Service.h" 00005 #include "CommonTools/UtilAlgos/interface/TFileService.h" 00006 // 00007 #include "FWCore/Framework/interface/MakerMacros.h" 00008 #include "FWCore/MessageLogger/interface/MessageLogger.h" 00009 #include "FWCore/Utilities/interface/Exception.h" 00010 00011 #include "TFile.h" 00012 #include "TH1.h" 00013 #include "TH2.h" 00014 #include "TTree.h" 00015 #include "TVector3.h" 00016 #include "TProfile.h" 00017 // 00018 00019 00020 #include "FWCore/Framework/interface/EDAnalyzer.h" 00021 #include "FWCore/ParameterSet/interface/ParameterSet.h" 00022 #include "FWCore/Framework/interface/Event.h" 00023 #include "FWCore/Framework/interface/EventSetup.h" 00024 00025 //DQM services 00026 #include "DQMServices/Core/interface/DQMStore.h" 00027 #include "FWCore/ServiceRegistry/interface/Service.h" 00028 #include "DQMServices/Core/interface/MonitorElement.h" 00029 00030 // 00031 00032 #include <vector> 00033 00045 // forward declarations 00046 class TFile; 00047 class TH1F; 00048 class TH2F; 00049 class TProfile; 00050 class TTree; 00051 00052 00053 class PhotonPostprocessing : public edm::EDAnalyzer 00054 { 00055 00056 public: 00057 00058 // 00059 explicit PhotonPostprocessing( const edm::ParameterSet& pset ) ; 00060 virtual ~PhotonPostprocessing(); 00061 00062 00063 virtual void analyze(const edm::Event&, const edm::EventSetup& ) ; 00064 virtual void beginJob() ; 00065 virtual void endJob() ; 00066 virtual void endLuminosityBlock( const edm::LuminosityBlock& , const edm::EventSetup& ) ; 00067 virtual void endRun(const edm::Run& , const edm::EventSetup& ) ; 00068 00069 00070 private: 00071 // 00072 00073 00074 00075 void dividePlots(MonitorElement* dividend, MonitorElement* numerator, MonitorElement* denominator,std::string type); 00076 void dividePlots(MonitorElement* dividend, MonitorElement* numerator, double denominator); 00077 virtual void runPostprocessing(); 00078 00079 DQMStore *dbe_; 00080 int verbosity_; 00081 00082 edm::ParameterSet parameters_; 00083 00084 00085 bool standAlone_; 00086 bool batch_; 00087 bool isRunCentrally_; 00088 bool fastSim_; 00089 std::string outputFileName_; 00090 std::string inputFileName_; 00091 00092 std::stringstream currentFolder_; 00093 00094 00095 double etMin; 00096 double etMax; 00097 int etBin; 00098 double etaMin; 00099 double etaMax; 00100 int etaBin; 00101 int etaBin2; 00102 double phiMin; 00103 double phiMax; 00104 int phiBin; 00105 double rMin; 00106 double rMax; 00107 int rBin; 00108 double zMin; 00109 double zMax; 00110 int zBin; 00111 00112 00113 00114 MonitorElement* phoRecoEffEta_; 00115 MonitorElement* phoRecoEffPhi_; 00116 MonitorElement* phoRecoEffEt_; 00117 00118 MonitorElement* phoDeadChEta_; 00119 MonitorElement* phoDeadChPhi_; 00120 MonitorElement* phoDeadChEt_; 00121 00122 00123 MonitorElement* convEffEtaTwoTracks_; 00124 MonitorElement* convEffPhiTwoTracks_; 00125 MonitorElement* convEffRTwoTracks_; 00126 MonitorElement* convEffZTwoTracks_; 00127 MonitorElement* convEffEtTwoTracks_; 00128 00129 MonitorElement* convEffEtaTwoTracksAndVtxProbGT0_; 00130 MonitorElement* convEffEtaTwoTracksAndVtxProbGT0005_; 00131 MonitorElement* convEffRTwoTracksAndVtxProbGT0_; 00132 MonitorElement* convEffRTwoTracksAndVtxProbGT0005_; 00133 00134 MonitorElement* convEffEtaOneTrack_; 00135 MonitorElement* convEffROneTrack_; 00136 MonitorElement* convEffEtOneTrack_; 00137 00138 MonitorElement* convFakeRateEtaTwoTracks_; 00139 MonitorElement* convFakeRatePhiTwoTracks_; 00140 MonitorElement* convFakeRateRTwoTracks_; 00141 MonitorElement* convFakeRateZTwoTracks_; 00142 MonitorElement* convFakeRateEtTwoTracks_; 00143 00144 MonitorElement* bkgRecoEffEta_; 00145 MonitorElement* bkgRecoEffPhi_; 00146 MonitorElement* bkgRecoEffEt_; 00147 00148 MonitorElement* bkgDeadChEta_; 00149 MonitorElement* bkgDeadChPhi_; 00150 MonitorElement* bkgDeadChEt_; 00151 00152 MonitorElement* convVsEt_[2]; 00153 00154 00155 }; 00156 00157 00158 00159 00160 00161 #endif