From 26ccad54a7455aa940894bbbc46e7f09090ff2dc Mon Sep 17 00:00:00 2001 From: Andrea Date: Wed, 26 Feb 2020 11:32:50 +0100 Subject: [PATCH 1/2] Delete dead branches in CondCore/EcalPlugins --- .../plugins/EcalPulseCovariances_PayloadInspector.cc | 9 --------- .../plugins/EcalPulseShapes_PayloadInspector.cc | 9 --------- .../plugins/EcalTimeOffsetConstant_PayloadInspector.cc | 8 +++----- 3 files changed, 3 insertions(+), 23 deletions(-) diff --git a/CondCore/EcalPlugins/plugins/EcalPulseCovariances_PayloadInspector.cc b/CondCore/EcalPlugins/plugins/EcalPulseCovariances_PayloadInspector.cc index 7d493d47c4c60..8dc01b8aff950 100644 --- a/CondCore/EcalPlugins/plugins/EcalPulseCovariances_PayloadInspector.cc +++ b/CondCore/EcalPlugins/plugins/EcalPulseCovariances_PayloadInspector.cc @@ -232,17 +232,8 @@ namespace { std::shared_ptr payload = fetchPayload(std::get<1>(iov)); unsigned int run = std::get<0>(iov); if (payload.get()) { - // int chan = 0; for (int ieta = -MAX_IETA; ieta <= MAX_IETA; ieta++) { - Double_t eta = (Double_t)ieta; - if (ieta == 0) - continue; - else if (ieta > 0.) - eta = eta - 0.5; // 0.5 to 84.5 - else - eta = eta + 0.5; // -84.5 to -0.5 for (int iphi = 1; iphi <= MAX_IPHI; iphi++) { - //Double_t phi = (Double_t)iphi - 0.5; EBDetId id(ieta, iphi); for (int i = 0; i < TEMPLATESAMPLES; ++i) { for (int j = 0; j < TEMPLATESAMPLES; ++j) { diff --git a/CondCore/EcalPlugins/plugins/EcalPulseShapes_PayloadInspector.cc b/CondCore/EcalPlugins/plugins/EcalPulseShapes_PayloadInspector.cc index e8377772436ea..7ea24259bf918 100644 --- a/CondCore/EcalPlugins/plugins/EcalPulseShapes_PayloadInspector.cc +++ b/CondCore/EcalPlugins/plugins/EcalPulseShapes_PayloadInspector.cc @@ -204,17 +204,8 @@ namespace { std::shared_ptr payload = fetchPayload(std::get<1>(iov)); unsigned int run = std::get<0>(iov); if (payload.get()) { - // int chan = 0; for (int ieta = -MAX_IETA; ieta <= MAX_IETA; ieta++) { - Double_t eta = (Double_t)ieta; - if (ieta == 0) - continue; - else if (ieta > 0.) - eta = eta - 0.5; // 0.5 to 84.5 - else - eta = eta + 0.5; // -84.5 to -0.5 for (int iphi = 1; iphi <= MAX_IPHI; iphi++) { - //Double_t phi = (Double_t)iphi - 0.5; EBDetId id(ieta, iphi); EcalPulseShape pulse = (*payload)[id.rawId()]; for (int s = 0; s < TEMPLATESAMPLES; s++) { diff --git a/CondCore/EcalPlugins/plugins/EcalTimeOffsetConstant_PayloadInspector.cc b/CondCore/EcalPlugins/plugins/EcalTimeOffsetConstant_PayloadInspector.cc index 024ddd15faaea..6cb51c4ce582d 100644 --- a/CondCore/EcalPlugins/plugins/EcalTimeOffsetConstant_PayloadInspector.cc +++ b/CondCore/EcalPlugins/plugins/EcalTimeOffsetConstant_PayloadInspector.cc @@ -106,17 +106,15 @@ namespace { align = new TH2F("Ecal Time Offset Constant [ns]", "EB EE", 2, 0, 2, NbRows, 0, NbRows); EcalTimeOffsetConstant it = (*payload); - double row = NbRows - 0.5; if (irun == 0) { val[0] = it.getEBValue(); val[1] = it.getEEValue(); } else { - align->Fill(0.5, row, it.getEBValue() - val[0]); + double row = NbRows - 0.5; + align->Fill(0.5, row, it.getEBValue() - val[0]); align->Fill(1.5, row, it.getEEValue() - val[1]); - - row = row - 1.; } } // if payload.get() @@ -161,4 +159,4 @@ namespace { PAYLOAD_INSPECTOR_MODULE(EcalTimeOffsetConstant) { PAYLOAD_INSPECTOR_CLASS(EcalTimeOffsetConstantPlot); PAYLOAD_INSPECTOR_CLASS(EcalTimeOffsetConstantDiff); -} \ No newline at end of file +} From 67ddf53c09b865eec9e240b85f5807a3f3a84e39 Mon Sep 17 00:00:00 2001 From: Andrea Date: Wed, 26 Feb 2020 11:36:33 +0100 Subject: [PATCH 2/2] clang code format --- .../plugins/EcalTimeOffsetConstant_PayloadInspector.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CondCore/EcalPlugins/plugins/EcalTimeOffsetConstant_PayloadInspector.cc b/CondCore/EcalPlugins/plugins/EcalTimeOffsetConstant_PayloadInspector.cc index 6cb51c4ce582d..4310077535983 100644 --- a/CondCore/EcalPlugins/plugins/EcalTimeOffsetConstant_PayloadInspector.cc +++ b/CondCore/EcalPlugins/plugins/EcalTimeOffsetConstant_PayloadInspector.cc @@ -112,8 +112,8 @@ namespace { val[1] = it.getEEValue(); } else { - double row = NbRows - 0.5; - align->Fill(0.5, row, it.getEBValue() - val[0]); + double row = NbRows - 0.5; + align->Fill(0.5, row, it.getEBValue() - val[0]); align->Fill(1.5, row, it.getEEValue() - val[1]); }