50 static constexpr
double partR2 = 0.3 * 0.3;
121 constexpr
auto size = 100;
125 -5.191, -4.889, -4.716, -4.538, -4.363, -4.191, -4.013, -3.839, -3.664, -3.489, -3.314, -3.139, -2.964, -2.853,
126 -2.65, -2.5, -2.322, -2.172, -2.043, -1.93, -1.83, -1.74, -1.653, -1.566, -1.479, -1.392, -1.305, -1.218,
127 -1.131, -1.044, -0.957, -0.879, -0.783, -0.696, -0.609, -0.522, -0.435, -0.348, -0.261, -0.174, -0.087, 0,
128 0.087, 0.174, 0.261, 0.348, 0.435, 0.522, 0.609, 0.696, 0.783, 0.879, 0.957, 1.044, 1.131, 1.218,
129 1.305, 1.392, 1.479, 1.566, 1.653, 1.74, 1.83, 1.93, 2.043, 2.172, 2.322, 2.5, 2.65, 2.853,
130 2.964, 3.139, 3.314, 3.489, 3.664, 3.839, 4.013, 4.191, 4.363, 4.538, 4.716, 4.889, 5.191};
131 constexpr
int etaBins =
std::size(etaBinsOffset) - 1;
137 strncpy(histo,
"emean_vs_eta_E", size);
139 strncpy(histo,
"emean_vs_eta_H", size);
141 strncpy(histo,
"emean_vs_eta_EH", size);
144 strncpy(histo,
"emean_vs_eta_HF", size);
146 strncpy(histo,
"emean_vs_eta_HO", size);
149 strncpy(histo,
"emean_vs_eta_EHF", size);
151 strncpy(histo,
"emean_vs_eta_EHFO", size);
156 strncpy(histo,
"Ratio_Esummed_ECAL_0", size);
158 strncpy(histo,
"Ratio_Esummed_HCAL_0", size);
160 strncpy(histo,
"Ratio_Esummed_HO_0", size);
162 strncpy(histo,
"Ratio_Esummed_ECAL_HCAL_0", size);
164 strncpy(histo,
"Ratio_Esummed_ECAL_HCAL_HO_0", size);
167 strncpy(histo,
"Ratio_Esummed_ECAL_1", size);
169 strncpy(histo,
"Ratio_Esummed_HCAL_1", size);
171 strncpy(histo,
"Ratio_Esummed_HO_1", size);
173 strncpy(histo,
"Ratio_Esummed_ECAL_HCAL_1", size);
175 strncpy(histo,
"Ratio_Esummed_ECAL_HCAL_HO_1", size);
178 strncpy(histo,
"Ratio_Esummed_ECAL_2", size);
180 strncpy(histo,
"Ratio_Esummed_HCAL_2", size);
182 strncpy(histo,
"Ratio_Esummed_HO_2", size);
184 strncpy(histo,
"Ratio_Esummed_ECAL_HCAL_2", size);
186 strncpy(histo,
"Ratio_Esummed_ECAL_HCAL_HO_2", size);
189 strncpy(histo,
"Ratio_Esummed_ECAL_3", size);
191 strncpy(histo,
"Ratio_Esummed_HCAL_3", size);
193 strncpy(histo,
"Ratio_Esummed_HO_3", size);
195 strncpy(histo,
"Ratio_Esummed_ECAL_HCAL_3", size);
197 strncpy(histo,
"Ratio_Esummed_ECAL_HCAL_HO_3", size);
200 strncpy(histo,
"Ratio_Esummed_ECAL_4", size);
202 strncpy(histo,
"Ratio_Esummed_HCAL_4", size);
204 strncpy(histo,
"Ratio_Esummed_HO_4", size);
206 strncpy(histo,
"Ratio_Esummed_ECAL_HCAL_4", size);
208 strncpy(histo,
"Ratio_Esummed_ECAL_HCAL_HO_4", size);
211 strncpy(histo,
"Ratio_Esummed_HF_5", size);
213 strncpy(histo,
"Ratio_Esummed_HF_6", size);
216 strncpy(histo,
"Egen_MC", size);
223 double energy_MC = 0.;
233 double maxPt = -99999.;
235 for (
auto p = myGenEvent->particles_begin();
p != myGenEvent->particles_end(); ++
p) {
236 double phip = (*p)->momentum().phi();
237 double etap = (*p)->momentum().eta();
238 double pt = (*p)->momentum().perp();
239 double energy = (*p)->momentum().e();
263 const double Econe =
sumEnergy(pfClusterECAL, eta_MC, phi_MC);
264 const double Hcone =
sumEnergy(pfClusterHCAL, eta_MC, phi_MC);
265 const double HOcone =
sumEnergy(pfClusterHO, eta_MC, phi_MC);
266 const double HFcone =
sumEnergy(pfClusterHF, eta_MC, phi_MC);
268 if (energy_MC > 0.) {
322 for (
auto pf = pfClusters->begin(); pf != pfClusters->end(); ++pf) {
T getUntrackedParameter(std::string const &, T const &) const
const edm::EventSetup & c
MonitorElement * ratio_Esummed_HCAL_4_
MonitorElement * ratio_Esummed_ECAL_4_
void analyze(edm::Event const &e, edm::EventSetup const &c) override
PFClusterValidation(edm::ParameterSet const &conf)
MonitorElement * emean_vs_eta_EHFO_
virtual void setCurrentFolder(std::string const &fullpath)
MonitorElement * emean_vs_eta_E_
edm::EDGetTokenT< reco::PFClusterCollection > pfClusterHCALTok_
#define DEFINE_FWK_MODULE(type)
edm::EDGetTokenT< reco::PFClusterCollection > pfClusterHOTok_
MonitorElement * ratio_Esummed_HO_3_
MonitorElement * ratio_Esummed_HCAL_0_
MonitorElement * ratio_Esummed_ECAL_0_
MonitorElement * ratio_Esummed_HO_2_
MonitorElement * ratio_Esummed_ECAL_HCAL_2_
MonitorElement * ratio_Esummed_ECAL_HCAL_1_
MonitorElement * emean_vs_eta_EH_
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
MonitorElement * ratio_Esummed_HF_5_
MonitorElement * ratio_Esummed_HCAL_3_
MonitorElement * ratio_Esummed_ECAL_1_
MonitorElement * ratio_Esummed_HF_6_
MonitorElement * emean_vs_eta_EHF_
MonitorElement * emean_vs_eta_H_
MonitorElement * bookProfile(TString const &name, TString const &title, int nchX, double lowX, double highX, int, double lowY, double highY, char const *option="s", FUNC onbooking=NOOP())
MonitorElement * ratio_Esummed_ECAL_HCAL_0_
MonitorElement * ratio_Esummed_HCAL_2_
MonitorElement * ratio_Esummed_ECAL_3_
Abs< T >::type abs(const T &t)
MonitorElement * ratio_Esummed_HO_4_
edm::EDGetTokenT< reco::PFClusterCollection > pfClusterHFTok_
MonitorElement * ratio_Esummed_ECAL_HCAL_HO_0_
MonitorElement * egen_MC_
edm::EDGetTokenT< edm::HepMCProduct > hepMCTok_
MonitorElement * ratio_Esummed_ECAL_HCAL_HO_4_
~PFClusterValidation() override
static double sumEnergy(edm::Handle< reco::PFClusterCollection > const &pfClusters, double eta, double phi)
constexpr auto deltaR2(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
MonitorElement * ratio_Esummed_HCAL_1_
MonitorElement * ratio_Esummed_ECAL_HCAL_3_
MonitorElement * ratio_Esummed_ECAL_HCAL_4_
MonitorElement * ratio_Esummed_HO_0_
MonitorElement * ratio_Esummed_ECAL_HCAL_HO_3_
MonitorElement * ratio_Esummed_ECAL_HCAL_HO_2_
MonitorElement * ratio_Esummed_ECAL_HCAL_HO_1_
Log< level::Warning, false > LogWarning
MonitorElement * book1D(TString const &name, TString const &title, int const nchX, double const lowX, double const highX, FUNC onbooking=NOOP())
static constexpr double partR2
tuple size
Write out results.
MonitorElement * ratio_Esummed_HO_1_
MonitorElement * emean_vs_eta_HF_
MonitorElement * emean_vs_eta_HO_
edm::EDGetTokenT< reco::PFClusterCollection > pfClusterECALTok_
MonitorElement * ratio_Esummed_ECAL_2_