CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Private Attributes
ECALRecHitAnalyzer Class Reference

#include <ECALRecHitAnalyzer.h>

Inheritance diagram for ECALRecHitAnalyzer:
DQMEDAnalyzer edm::stream::EDProducer< edm::GlobalCache< DQMEDAnalyzerGlobalCache >, edm::EndRunProducer, edm::EndLuminosityBlockProducer, edm::Accumulator >

Public Member Functions

void analyze (const edm::Event &, const edm::EventSetup &) override
 
void bookHistograms (DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
 
virtual void dqmbeginRun (const edm::Run &, const edm::EventSetup &)
 
 ECALRecHitAnalyzer (const edm::ParameterSet &)
 
void FillGeometry (const edm::EventSetup &)
 
void WriteECALRecHits (const edm::Event &, const edm::EventSetup &)
 
- Public Member Functions inherited from DQMEDAnalyzer
void accumulate (edm::Event const &event, edm::EventSetup const &setup) final
 
void beginLuminosityBlock (edm::LuminosityBlock const &lumi, edm::EventSetup const &setup) final
 
void beginRun (edm::Run const &run, edm::EventSetup const &setup) final
 
void beginStream (edm::StreamID id) final
 
virtual void dqmBeginRun (edm::Run const &, edm::EventSetup const &)
 
 DQMEDAnalyzer ()
 
void endLuminosityBlock (edm::LuminosityBlock const &lumi, edm::EventSetup const &setup) final
 
void endRun (edm::Run const &run, edm::EventSetup const &setup) final
 
virtual bool getCanSaveByLumi ()
 
- Public Member Functions inherited from edm::stream::EDProducer< edm::GlobalCache< DQMEDAnalyzerGlobalCache >, edm::EndRunProducer, edm::EndLuminosityBlockProducer, edm::Accumulator >
 EDProducer ()=default
 
 EDProducer (const EDProducer &)=delete
 
bool hasAbilityToProduceInBeginLumis () const final
 
bool hasAbilityToProduceInBeginProcessBlocks () const final
 
bool hasAbilityToProduceInBeginRuns () const final
 
bool hasAbilityToProduceInEndLumis () const final
 
bool hasAbilityToProduceInEndProcessBlocks () const final
 
bool hasAbilityToProduceInEndRuns () const final
 
const EDProduceroperator= (const EDProducer &)=delete
 

Private Attributes

const CaloGeometrycaloGeom_
 
edm::ESGetToken< CaloGeometry,
CaloGeometryRecord
caloGeomToken_
 
int CurrentEvent
 
bool debug_
 
edm::EDGetTokenT
< EBRecHitCollection
EBRecHitsLabel_
 
edm::EDGetTokenT
< EERecHitCollection
EERecHitsLabel_
 
bool finebinning_
 
std::string FolderName_
 
MonitorElementhEB_energy_ieta_iphi
 
MonitorElementhEB_energyvsieta
 
MonitorElementhEB_ieta_detaMap
 
MonitorElementhEB_ieta_dphiMap
 
MonitorElementhEB_ieta_iphi_etaMap
 
MonitorElementhEB_ieta_iphi_phiMap
 
MonitorElementhEB_Maxenergy_ieta_iphi
 
MonitorElementhEB_Maxenergyvsieta
 
MonitorElementhEB_METPhivsieta
 
MonitorElementhEB_METvsieta
 
MonitorElementhEB_MExvsieta
 
MonitorElementhEB_MEyvsieta
 
MonitorElementhEB_Minenergy_ieta_iphi
 
MonitorElementhEB_Minenergyvsieta
 
MonitorElementhEB_Occ_ieta_iphi
 
MonitorElementhEB_Occvsieta
 
MonitorElementhEB_SETvsieta
 
MonitorElementhECAL_Nevents
 
MonitorElementhEEmZ_energy_ix_iy
 
MonitorElementhEEmZ_energyvsir
 
MonitorElementhEEmZ_ix_iy_dxMap
 
MonitorElementhEEmZ_ix_iy_dyMap
 
MonitorElementhEEmZ_ix_iy_irMap
 
MonitorElementhEEmZ_ix_iy_xMap
 
MonitorElementhEEmZ_ix_iy_yMap
 
MonitorElementhEEmZ_ix_iy_zMap
 
MonitorElementhEEmZ_Maxenergy_ix_iy
 
MonitorElementhEEmZ_Maxenergyvsir
 
MonitorElementhEEmZ_METPhivsir
 
MonitorElementhEEmZ_METvsir
 
MonitorElementhEEmZ_MExvsir
 
MonitorElementhEEmZ_MEyvsir
 
MonitorElementhEEmZ_Minenergy_ix_iy
 
MonitorElementhEEmZ_Minenergyvsir
 
MonitorElementhEEmZ_Occ_ix_iy
 
MonitorElementhEEmZ_Occvsir
 
MonitorElementhEEmZ_SETvsir
 
MonitorElementhEEpZ_energy_ix_iy
 
MonitorElementhEEpZ_energyvsir
 
MonitorElementhEEpZ_ix_iy_dxMap
 
MonitorElementhEEpZ_ix_iy_dyMap
 
MonitorElementhEEpZ_ix_iy_irMap
 
MonitorElementhEEpZ_ix_iy_xMap
 
MonitorElementhEEpZ_ix_iy_yMap
 
MonitorElementhEEpZ_ix_iy_zMap
 
MonitorElementhEEpZ_Maxenergy_ix_iy
 
MonitorElementhEEpZ_Maxenergyvsir
 
MonitorElementhEEpZ_METPhivsir
 
MonitorElementhEEpZ_METvsir
 
MonitorElementhEEpZ_MExvsir
 
MonitorElementhEEpZ_MEyvsir
 
MonitorElementhEEpZ_Minenergy_ix_iy
 
MonitorElementhEEpZ_Minenergyvsir
 
MonitorElementhEEpZ_Occ_ix_iy
 
MonitorElementhEEpZ_Occvsir
 
MonitorElementhEEpZ_SETvsir
 

Additional Inherited Members

- Public Types inherited from DQMEDAnalyzer
typedef dqm::reco::DQMStore DQMStore
 
typedef dqm::reco::MonitorElement MonitorElement
 
- Public Types inherited from edm::stream::EDProducer< edm::GlobalCache< DQMEDAnalyzerGlobalCache >, edm::EndRunProducer, edm::EndLuminosityBlockProducer, edm::Accumulator >
using CacheTypes = CacheContexts< T...>
 
using GlobalCache = typename CacheTypes::GlobalCache
 
using HasAbility = AbilityChecker< T...>
 
using InputProcessBlockCache = typename CacheTypes::InputProcessBlockCache
 
using LuminosityBlockCache = typename CacheTypes::LuminosityBlockCache
 
using LuminosityBlockContext = LuminosityBlockContextT< LuminosityBlockCache, RunCache, GlobalCache >
 
using LuminosityBlockSummaryCache = typename CacheTypes::LuminosityBlockSummaryCache
 
using RunCache = typename CacheTypes::RunCache
 
using RunContext = RunContextT< RunCache, GlobalCache >
 
using RunSummaryCache = typename CacheTypes::RunSummaryCache
 
- Static Public Member Functions inherited from DQMEDAnalyzer
static void globalEndJob (DQMEDAnalyzerGlobalCache const *)
 
static void globalEndLuminosityBlockProduce (edm::LuminosityBlock &lumi, edm::EventSetup const &setup, LuminosityBlockContext const *context)
 
static void globalEndRunProduce (edm::Run &run, edm::EventSetup const &setup, RunContext const *context)
 
static std::unique_ptr
< DQMEDAnalyzerGlobalCache
initializeGlobalCache (edm::ParameterSet const &)
 
- Protected Member Functions inherited from DQMEDAnalyzer
uint64_t meId () const
 
- Protected Attributes inherited from DQMEDAnalyzer
edm::EDPutTokenT< DQMTokenlumiToken_
 
edm::EDPutTokenT< DQMTokenrunToken_
 
unsigned int streamId_
 

Detailed Description

Definition at line 79 of file ECALRecHitAnalyzer.h.

Constructor & Destructor Documentation

ECALRecHitAnalyzer::ECALRecHitAnalyzer ( const edm::ParameterSet iConfig)

Definition at line 15 of file ECALRecHitAnalyzer.cc.

References caloGeomToken_, debug_, EBRecHitsLabel_, EERecHitsLabel_, FolderName_, edm::ParameterSet::getParameter(), edm::ParameterSet::getUntrackedParameter(), and AlCaHLTBitMon_QueryRunRegistry::string.

15  {
16  // Retrieve Information from the Configuration File
17  EBRecHitsLabel_ = consumes<EBRecHitCollection>(iConfig.getParameter<edm::InputTag>("EBRecHitsLabel"));
18  EERecHitsLabel_ = consumes<EERecHitCollection>(iConfig.getParameter<edm::InputTag>("EERecHitsLabel"));
19  caloGeomToken_ = esConsumes<edm::Transition::BeginRun>();
20  FolderName_ = iConfig.getUntrackedParameter<std::string>("FolderName");
21  debug_ = iConfig.getParameter<bool>("Debug");
22  // EBRecHitsLabel_= consumes<EcalRecHitCollection>(edm::InputTag(EBRecHitsLabel_));
23  // EERecHitsLabel_= consumes<EcalRecHitCollection>(edm::InputTag(EERecHitsLabel_));
24 }
T getUntrackedParameter(std::string const &, T const &) const
edm::ESGetToken< CaloGeometry, CaloGeometryRecord > caloGeomToken_
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
edm::EDGetTokenT< EERecHitCollection > EERecHitsLabel_
edm::EDGetTokenT< EBRecHitCollection > EBRecHitsLabel_

Member Function Documentation

void ECALRecHitAnalyzer::analyze ( const edm::Event iEvent,
const edm::EventSetup iSetup 
)
overridevirtual

Reimplemented from DQMEDAnalyzer.

Definition at line 295 of file ECALRecHitAnalyzer.cc.

References CurrentEvent, DEBUG, dqm::impl::MonitorElement::Fill(), hECAL_Nevents, and WriteECALRecHits().

295  {
296  CurrentEvent++;
297  DEBUG("Event: " << CurrentEvent);
298  WriteECALRecHits(iEvent, iSetup);
299  hECAL_Nevents->Fill(0.5);
300 }
#define DEBUG(X)
void Fill(long long x)
MonitorElement * hECAL_Nevents
void WriteECALRecHits(const edm::Event &, const edm::EventSetup &)
void ECALRecHitAnalyzer::bookHistograms ( DQMStore::IBooker ibooker,
edm::Run const &  iRun,
edm::EventSetup const &   
)
overridevirtual

Implements DQMEDAnalyzer.

Definition at line 33 of file ECALRecHitAnalyzer.cc.

References dqm::implementation::IBooker::book1D(), dqm::implementation::IBooker::book2D(), finebinning_, FolderName_, hEB_energy_ieta_iphi, hEB_energyvsieta, hEB_ieta_detaMap, hEB_ieta_dphiMap, hEB_ieta_iphi_etaMap, hEB_ieta_iphi_phiMap, hEB_Maxenergy_ieta_iphi, hEB_Maxenergyvsieta, hEB_METPhivsieta, hEB_METvsieta, hEB_MExvsieta, hEB_MEyvsieta, hEB_Minenergy_ieta_iphi, hEB_Minenergyvsieta, hEB_Occ_ieta_iphi, hEB_Occvsieta, hEB_SETvsieta, hECAL_Nevents, hEEmZ_energy_ix_iy, hEEmZ_energyvsir, hEEmZ_ix_iy_dxMap, hEEmZ_ix_iy_dyMap, hEEmZ_ix_iy_irMap, hEEmZ_ix_iy_xMap, hEEmZ_ix_iy_yMap, hEEmZ_ix_iy_zMap, hEEmZ_Maxenergy_ix_iy, hEEmZ_Maxenergyvsir, hEEmZ_METPhivsir, hEEmZ_METvsir, hEEmZ_MExvsir, hEEmZ_MEyvsir, hEEmZ_Minenergy_ix_iy, hEEmZ_Minenergyvsir, hEEmZ_Occ_ix_iy, hEEmZ_Occvsir, hEEmZ_SETvsir, hEEpZ_energy_ix_iy, hEEpZ_energyvsir, hEEpZ_ix_iy_dxMap, hEEpZ_ix_iy_dyMap, hEEpZ_ix_iy_irMap, hEEpZ_ix_iy_xMap, hEEpZ_ix_iy_yMap, hEEpZ_ix_iy_zMap, hEEpZ_Maxenergy_ix_iy, hEEpZ_Maxenergyvsir, hEEpZ_METPhivsir, hEEpZ_METvsir, hEEpZ_MExvsir, hEEpZ_MEyvsir, hEEpZ_Minenergy_ix_iy, hEEpZ_Minenergyvsir, hEEpZ_Occ_ix_iy, hEEpZ_Occvsir, hEEpZ_SETvsir, mps_fire::i, dqmiolumiharvest::j, dqm::impl::MonitorElement::setBinContent(), and dqm::implementation::NavigatorBase::setCurrentFolder().

33  {
34  // get ahold of back-end interface
35  // Book Geometry Histograms
36  ibooker.setCurrentFolder(FolderName_ + "/geometry");
37 
38  // ECAL barrel
39  hEB_ieta_iphi_etaMap = ibooker.book2D("hEB_ieta_iphi_etaMap", "", 171, -85, 86, 360, 1, 361);
40  hEB_ieta_iphi_phiMap = ibooker.book2D("hEB_ieta_iphi_phiMap", "", 171, -85, 86, 360, 1, 361);
41  hEB_ieta_detaMap = ibooker.book1D("hEB_ieta_detaMap", "", 171, -85, 86);
42  hEB_ieta_dphiMap = ibooker.book1D("hEB_ieta_dphiMap", "", 171, -85, 86);
43  // ECAL +endcap
44  hEEpZ_ix_iy_irMap = ibooker.book2D("hEEpZ_ix_iy_irMap", "", 100, 1, 101, 100, 1, 101);
45  hEEpZ_ix_iy_xMap = ibooker.book2D("hEEpZ_ix_iy_xMap", "", 100, 1, 101, 100, 1, 101);
46  hEEpZ_ix_iy_yMap = ibooker.book2D("hEEpZ_ix_iy_yMap", "", 100, 1, 101, 100, 1, 101);
47  hEEpZ_ix_iy_zMap = ibooker.book2D("hEEpZ_ix_iy_zMap", "", 100, 1, 101, 100, 1, 101);
48  hEEpZ_ix_iy_dxMap = ibooker.book2D("hEEpZ_ix_iy_dxMap", "", 100, 1, 101, 100, 1, 101);
49  hEEpZ_ix_iy_dyMap = ibooker.book2D("hEEpZ_ix_iy_dyMap", "", 100, 1, 101, 100, 1, 101);
50  // ECAL -endcap
51  hEEmZ_ix_iy_irMap = ibooker.book2D("hEEmZ_ix_iy_irMap", "", 100, 1, 101, 100, 1, 101);
52  hEEmZ_ix_iy_xMap = ibooker.book2D("hEEmZ_ix_iy_xMap", "", 100, 1, 101, 100, 1, 101);
53  hEEmZ_ix_iy_yMap = ibooker.book2D("hEEmZ_ix_iy_yMap", "", 100, 1, 101, 100, 1, 101);
54  hEEmZ_ix_iy_zMap = ibooker.book2D("hEEmZ_ix_iy_zMap", "", 100, 1, 101, 100, 1, 101);
55  hEEmZ_ix_iy_dxMap = ibooker.book2D("hEEmZ_ix_iy_dxMap", "", 100, 1, 101, 100, 1, 101);
56  hEEmZ_ix_iy_dyMap = ibooker.book2D("hEEmZ_ix_iy_dyMap", "", 100, 1, 101, 100, 1, 101);
57 
58  // Initialize bins for geometry to -999 because z = 0 is a valid entry
59  for (int i = 1; i <= 100; i++)
60  for (int j = 1; j <= 100; j++) {
67 
74  }
75 
76  for (int i = 1; i <= 171; i++) {
79  for (int j = 1; j <= 360; j++) {
82  }
83  }
84 
85  // Book Data Histograms
87 
88  hECAL_Nevents = ibooker.book1D("hECAL_Nevents", "", 1, 0, 1);
89 
90  // Energy Histograms by logical index
91  hEEpZ_energy_ix_iy = ibooker.book2D("hEEpZ_energy_ix_iy", "", 100, 1, 101, 100, 1, 101);
92  hEEmZ_energy_ix_iy = ibooker.book2D("hEEmZ_energy_ix_iy", "", 100, 1, 101, 100, 1, 101);
93  hEB_energy_ieta_iphi = ibooker.book2D("hEB_energy_ieta_iphi", "", 171, -85, 86, 360, 1, 361);
94 
95  hEEpZ_Minenergy_ix_iy = ibooker.book2D("hEEpZ_Minenergy_ix_iy", "", 100, 1, 101, 100, 1, 101);
96  hEEmZ_Minenergy_ix_iy = ibooker.book2D("hEEmZ_Minenergy_ix_iy", "", 100, 1, 101, 100, 1, 101);
97  hEB_Minenergy_ieta_iphi = ibooker.book2D("hEB_Minenergy_ieta_iphi", "", 171, -85, 86, 360, 1, 361);
98 
99  hEEpZ_Maxenergy_ix_iy = ibooker.book2D("hEEpZ_Maxenergy_ix_iy", "", 100, 1, 101, 100, 1, 101);
100  hEEmZ_Maxenergy_ix_iy = ibooker.book2D("hEEmZ_Maxenergy_ix_iy", "", 100, 1, 101, 100, 1, 101);
101  hEB_Maxenergy_ieta_iphi = ibooker.book2D("hEB_Maxenergy_ieta_iphi", "", 171, -85, 86, 360, 1, 361);
102 
103  // need to initialize those
104  for (int i = 1; i <= 171; i++)
105  for (int j = 1; j <= 360; j++) {
108  }
109  for (int i = 1; i <= 100; i++)
110  for (int j = 1; j <= 100; j++) {
115  }
116 
117  // Occupancy Histograms by logical index
118  hEEpZ_Occ_ix_iy = ibooker.book2D("hEEpZ_Occ_ix_iy", "", 100, 1, 101, 100, 1, 101);
119  hEEmZ_Occ_ix_iy = ibooker.book2D("hEEmZ_Occ_ix_iy", "", 100, 1, 101, 100, 1, 101);
120  hEB_Occ_ieta_iphi = ibooker.book2D("hEB_Occ_ieta_iphi", "", 171, -85, 86, 360, 1, 361);
121 
122  // Integrated Histograms
123  if (finebinning_) {
124  hEEpZ_energyvsir = ibooker.book2D("hEEpZ_energyvsir", "", 100, 1, 101, 20110, -10, 201);
125  hEEmZ_energyvsir = ibooker.book2D("hEEmZ_energyvsir", "", 100, 1, 101, 20110, -10, 201);
126  hEB_energyvsieta = ibooker.book2D("hEB_energyvsieta", "", 171, -85, 86, 20110, -10, 201);
127 
128  hEEpZ_Maxenergyvsir = ibooker.book2D("hEEpZ_Maxenergyvsir", "", 100, 1, 101, 20110, -10, 201);
129  hEEmZ_Maxenergyvsir = ibooker.book2D("hEEmZ_Maxenergyvsir", "", 100, 1, 101, 20110, -10, 201);
130  hEB_Maxenergyvsieta = ibooker.book2D("hEB_Maxenergyvsieta", "", 171, -85, 86, 20110, -10, 201);
131 
132  hEEpZ_Minenergyvsir = ibooker.book2D("hEEpZ_Minenergyvsir", "", 100, 1, 101, 20110, -10, 201);
133  hEEmZ_Minenergyvsir = ibooker.book2D("hEEmZ_Minenergyvsir", "", 100, 1, 101, 20110, -10, 201);
134  hEB_Minenergyvsieta = ibooker.book2D("hEB_Minenergyvsieta", "", 171, -85, 86, 20110, -10, 201);
135 
136  hEEpZ_SETvsir = ibooker.book2D("hEEpZ_SETvsir", "", 50, 1, 51, 20010, 0, 201);
137  hEEmZ_SETvsir = ibooker.book2D("hEEmZ_SETvsir", "", 50, 1, 51, 20010, 0, 201);
138  hEB_SETvsieta = ibooker.book2D("hEB_SETvsieta", "", 171, -85, 86, 20010, 0, 201);
139 
140  hEEpZ_METvsir = ibooker.book2D("hEEpZ_METvsir", "", 50, 1, 51, 20010, 0, 201);
141  hEEmZ_METvsir = ibooker.book2D("hEEmZ_METvsir", "", 50, 1, 51, 20010, 0, 201);
142  hEB_METvsieta = ibooker.book2D("hEB_METvsieta", "", 171, -85, 86, 20010, 0, 201);
143 
144  hEEpZ_METPhivsir = ibooker.book2D("hEEpZ_METPhivsir", "", 50, 1, 51, 80, -4, 4);
145  hEEmZ_METPhivsir = ibooker.book2D("hEEmZ_METPhivsir", "", 50, 1, 51, 80, -4, 4);
146  hEB_METPhivsieta = ibooker.book2D("hEB_METPhivsieta", "", 171, -85, 86, 80, -4, 4);
147 
148  hEEpZ_MExvsir = ibooker.book2D("hEEpZ_MExvsir", "", 50, 1, 51, 10010, -50, 51);
149  hEEmZ_MExvsir = ibooker.book2D("hEEmZ_MExvsir", "", 50, 1, 51, 10010, -50, 51);
150  hEB_MExvsieta = ibooker.book2D("hEB_MExvsieta", "", 171, -85, 86, 10010, -50, 51);
151 
152  hEEpZ_MEyvsir = ibooker.book2D("hEEpZ_MEyvsir", "", 50, 1, 51, 10010, -50, 51);
153  hEEmZ_MEyvsir = ibooker.book2D("hEEmZ_MEyvsir", "", 50, 1, 51, 10010, -50, 51);
154  hEB_MEyvsieta = ibooker.book2D("hEB_MEyvsieta", "", 171, -85, 86, 10010, -50, 51);
155 
156  hEEpZ_Occvsir = ibooker.book2D("hEEpZ_Occvsir", "", 50, 1, 51, 1000, 0, 1000);
157  hEEmZ_Occvsir = ibooker.book2D("hEEmZ_Occvsir", "", 50, 1, 51, 1000, 0, 1000);
158  hEB_Occvsieta = ibooker.book2D("hEB_Occvsieta", "", 171, -85, 86, 400, 0, 400);
159  } else {
160  hEEpZ_energyvsir = ibooker.book2D("hEEpZ_energyvsir", "", 100, 1, 101, 510, -10, 100);
161  hEEmZ_energyvsir = ibooker.book2D("hEEmZ_energyvsir", "", 100, 1, 101, 510, -10, 100);
162  hEB_energyvsieta = ibooker.book2D("hEB_energyvsieta", "", 171, -85, 86, 510, -10, 100);
163 
164  hEEpZ_Maxenergyvsir = ibooker.book2D("hEEpZ_Maxenergyvsir", "", 100, 1, 101, 510, -10, 100);
165  hEEmZ_Maxenergyvsir = ibooker.book2D("hEEmZ_Maxenergyvsir", "", 100, 1, 101, 510, -10, 100);
166  hEB_Maxenergyvsieta = ibooker.book2D("hEB_Maxenergyvsieta", "", 171, -85, 86, 510, -10, 100);
167 
168  hEEpZ_Minenergyvsir = ibooker.book2D("hEEpZ_Minenergyvsir", "", 100, 1, 101, 510, -10, 100);
169  hEEmZ_Minenergyvsir = ibooker.book2D("hEEmZ_Minenergyvsir", "", 100, 1, 101, 510, -10, 100);
170  hEB_Minenergyvsieta = ibooker.book2D("hEB_Minenergyvsieta", "", 171, -85, 86, 510, -10, 100);
171 
172  hEEpZ_SETvsir = ibooker.book2D("hEEpZ_SETvsir", "", 50, 1, 51, 510, 0, 100);
173  hEEmZ_SETvsir = ibooker.book2D("hEEmZ_SETvsir", "", 50, 1, 51, 510, 0, 100);
174  hEB_SETvsieta = ibooker.book2D("hEB_SETvsieta", "", 171, -85, 86, 510, 0, 100);
175 
176  hEEpZ_METvsir = ibooker.book2D("hEEpZ_METvsir", "", 50, 1, 51, 510, 0, 100);
177  hEEmZ_METvsir = ibooker.book2D("hEEmZ_METvsir", "", 50, 1, 51, 510, 0, 100);
178  hEB_METvsieta = ibooker.book2D("hEB_METvsieta", "", 171, -85, 86, 510, 0, 100);
179 
180  hEEpZ_METPhivsir = ibooker.book2D("hEEpZ_METPhivsir", "", 50, 1, 51, 80, -4, 4);
181  hEEmZ_METPhivsir = ibooker.book2D("hEEmZ_METPhivsir", "", 50, 1, 51, 80, -4, 4);
182  hEB_METPhivsieta = ibooker.book2D("hEB_METPhivsieta", "", 171, -85, 86, 80, -4, 4);
183 
184  hEEpZ_MExvsir = ibooker.book2D("hEEpZ_MExvsir", "", 50, 1, 51, 510, -50, 51);
185  hEEmZ_MExvsir = ibooker.book2D("hEEmZ_MExvsir", "", 50, 1, 51, 510, -50, 51);
186  hEB_MExvsieta = ibooker.book2D("hEB_MExvsieta", "", 171, -85, 86, 510, -50, 51);
187 
188  hEEpZ_MEyvsir = ibooker.book2D("hEEpZ_MEyvsir", "", 50, 1, 51, 510, -50, 51);
189  hEEmZ_MEyvsir = ibooker.book2D("hEEmZ_MEyvsir", "", 50, 1, 51, 510, -50, 51);
190  hEB_MEyvsieta = ibooker.book2D("hEB_MEyvsieta", "", 171, -85, 86, 510, -50, 51);
191 
192  hEEpZ_Occvsir = ibooker.book2D("hEEpZ_Occvsir", "", 50, 1, 51, 1000, 0, 1000);
193  hEEmZ_Occvsir = ibooker.book2D("hEEmZ_Occvsir", "", 50, 1, 51, 1000, 0, 1000);
194  hEB_Occvsieta = ibooker.book2D("hEB_Occvsieta", "", 171, -85, 86, 400, 0, 400);
195  }
196 }
MonitorElement * hEB_Maxenergyvsieta
MonitorElement * hEB_MExvsieta
MonitorElement * hEEmZ_ix_iy_dxMap
MonitorElement * hEEmZ_Occvsir
MonitorElement * hEEpZ_METPhivsir
MonitorElement * hEEmZ_METvsir
virtual void setCurrentFolder(std::string const &fullpath)
Definition: DQMStore.cc:32
MonitorElement * hEEpZ_METvsir
MonitorElement * hEB_Maxenergy_ieta_iphi
MonitorElement * hEB_METvsieta
MonitorElement * hEEpZ_ix_iy_irMap
MonitorElement * hEB_Occvsieta
MonitorElement * hEB_energyvsieta
MonitorElement * hEEpZ_ix_iy_zMap
MonitorElement * hEEpZ_Maxenergy_ix_iy
MonitorElement * hEB_METPhivsieta
MonitorElement * hEEmZ_Minenergyvsir
MonitorElement * hEEmZ_energy_ix_iy
MonitorElement * hEEmZ_energyvsir
MonitorElement * hEEmZ_ix_iy_dyMap
MonitorElement * hEEmZ_Occ_ix_iy
MonitorElement * hECAL_Nevents
MonitorElement * hEB_ieta_dphiMap
MonitorElement * hEEmZ_Maxenergyvsir
MonitorElement * hEEmZ_SETvsir
MonitorElement * hEB_Occ_ieta_iphi
MonitorElement * hEEpZ_Minenergyvsir
MonitorElement * hEEpZ_Minenergy_ix_iy
MonitorElement * hEB_Minenergy_ieta_iphi
MonitorElement * hEEmZ_METPhivsir
MonitorElement * hEEmZ_MEyvsir
MonitorElement * hEEpZ_energyvsir
MonitorElement * hEEpZ_ix_iy_dyMap
MonitorElement * hEB_ieta_detaMap
MonitorElement * hEEmZ_Minenergy_ix_iy
MonitorElement * hEB_energy_ieta_iphi
MonitorElement * hEB_MEyvsieta
MonitorElement * hEB_Minenergyvsieta
MonitorElement * hEEpZ_ix_iy_yMap
MonitorElement * hEEmZ_ix_iy_zMap
MonitorElement * hEEmZ_Maxenergy_ix_iy
virtual void setBinContent(int binx, double content)
set content of bin (1-D)
MonitorElement * hEB_ieta_iphi_etaMap
MonitorElement * hEEpZ_SETvsir
MonitorElement * book2D(TString const &name, TString const &title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, FUNC onbooking=NOOP())
Definition: DQMStore.h:177
MonitorElement * hEEpZ_Maxenergyvsir
MonitorElement * hEEmZ_MExvsir
MonitorElement * hEEmZ_ix_iy_yMap
MonitorElement * hEEmZ_ix_iy_xMap
MonitorElement * hEEpZ_MEyvsir
MonitorElement * hEB_SETvsieta
MonitorElement * hEEpZ_MExvsir
MonitorElement * hEEpZ_Occvsir
MonitorElement * hEEpZ_energy_ix_iy
MonitorElement * hEEpZ_Occ_ix_iy
MonitorElement * hEEmZ_ix_iy_irMap
MonitorElement * hEB_ieta_iphi_phiMap
MonitorElement * hEEpZ_ix_iy_xMap
MonitorElement * book1D(TString const &name, TString const &title, int const nchX, double const lowX, double const highX, FUNC onbooking=NOOP())
Definition: DQMStore.h:98
MonitorElement * hEEpZ_ix_iy_dxMap
void ECALRecHitAnalyzer::dqmbeginRun ( const edm::Run iRun,
const edm::EventSetup iSetup 
)
virtual

Definition at line 26 of file ECALRecHitAnalyzer.cc.

References caloGeom_, caloGeomToken_, CurrentEvent, FillGeometry(), and edm::EventSetup::getData().

26  {
27  CurrentEvent = -1;
28  caloGeom_ = &iSetup.getData(caloGeomToken_);
29  // Fill the geometry histograms
30  FillGeometry(iSetup);
31 }
bool getData(T &iHolder) const
Definition: EventSetup.h:128
const CaloGeometry * caloGeom_
edm::ESGetToken< CaloGeometry, CaloGeometryRecord > caloGeomToken_
void FillGeometry(const edm::EventSetup &)
void ECALRecHitAnalyzer::FillGeometry ( const edm::EventSetup iSetup)

Definition at line 198 of file ECALRecHitAnalyzer.cc.

References caloGeom_, DEBUG, DetId::Ecal, PVValHelper::eta, dqm::impl::MonitorElement::getBinContent(), CaloGeometry::getSubdetectorGeometry(), hEB_ieta_detaMap, hEB_ieta_dphiMap, hEB_ieta_iphi_etaMap, hEB_ieta_iphi_phiMap, hEEmZ_ix_iy_irMap, hEEmZ_ix_iy_xMap, hEEmZ_ix_iy_yMap, hEEmZ_ix_iy_zMap, hEEpZ_ix_iy_irMap, hEEpZ_ix_iy_xMap, hEEpZ_ix_iy_yMap, hEEpZ_ix_iy_zMap, mps_fire::i, EBDetId::ieta(), M_PI, dqmiodumpmetadata::n, dqm::impl::MonitorElement::setBinContent(), mathSSE::sqrt(), and EEDetId::zside().

Referenced by dqmbeginRun().

198  {
199  // Fill geometry histograms
200  using namespace edm;
201  //const auto& cG = iSetup.getData(caloGeomToken_);
202  //----Fill Ecal Barrel----//
204  int n = 0;
205  std::vector<DetId> EBids = EBgeom->getValidDetIds(DetId::Ecal, 1);
206  for (std::vector<DetId>::iterator i = EBids.begin(); i != EBids.end(); i++) {
207  n++;
208  auto cell = EBgeom->getGeometry(*i);
209  //GlobalPoint p = cell->getPosition();
210 
211  EBDetId EcalID(i->rawId());
212 
213  int Crystal_ieta = EcalID.ieta();
214  int Crystal_iphi = EcalID.iphi();
215  double Crystal_eta = cell->getPosition().eta();
216  double Crystal_phi = cell->getPosition().phi();
217  hEB_ieta_iphi_etaMap->setBinContent(Crystal_ieta + 86, Crystal_iphi, Crystal_eta);
218  hEB_ieta_iphi_phiMap->setBinContent(Crystal_ieta + 86, Crystal_iphi, (Crystal_phi * 180 / M_PI));
219 
220  DEBUG(" Crystal " << n);
221  DEBUG(" ieta, iphi = " << Crystal_ieta << ", " << Crystal_iphi);
222  DEBUG(" eta, phi = " << cell->getPosition().eta() << ", " << cell->getPosition().phi());
223  DEBUG(" ");
224  }
225  //----Fill Ecal Endcap----------//
227  n = 0;
228  std::vector<DetId> EEids = EEgeom->getValidDetIds(DetId::Ecal, 2);
229  for (std::vector<DetId>::iterator i = EEids.begin(); i != EEids.end(); i++) {
230  n++;
231  auto cell = EEgeom->getGeometry(*i);
232  //GlobalPoint p = cell->getPosition();
233  EEDetId EcalID(i->rawId());
234  int Crystal_zside = EcalID.zside();
235  int Crystal_ix = EcalID.ix();
236  int Crystal_iy = EcalID.iy();
237  Float_t ix_ = Crystal_ix - 50.5;
238  Float_t iy_ = Crystal_iy - 50.5;
239  Int_t ir = (Int_t)sqrt(ix_ * ix_ + iy_ * iy_);
240 
241  //double Crystal_eta = cell->getPosition().eta();
242  //double Crystal_phi = cell->getPosition().phi();
243  double Crystal_x = cell->getPosition().x();
244  double Crystal_y = cell->getPosition().y();
245  double Crystal_z = cell->getPosition().z();
246  // ECAL -endcap
247  if (Crystal_zside == -1) {
248  hEEmZ_ix_iy_irMap->setBinContent(Crystal_ix, Crystal_iy, ir);
249  hEEmZ_ix_iy_xMap->setBinContent(Crystal_ix, Crystal_iy, Crystal_x);
250  hEEmZ_ix_iy_yMap->setBinContent(Crystal_ix, Crystal_iy, Crystal_y);
251  hEEmZ_ix_iy_zMap->setBinContent(Crystal_ix, Crystal_iy, Crystal_z);
252  }
253  // ECAL +endcap
254  if (Crystal_zside == 1) {
255  hEEpZ_ix_iy_irMap->setBinContent(Crystal_ix, Crystal_iy, ir);
256  hEEpZ_ix_iy_xMap->setBinContent(Crystal_ix, Crystal_iy, Crystal_x);
257  hEEpZ_ix_iy_yMap->setBinContent(Crystal_ix, Crystal_iy, Crystal_y);
258  hEEpZ_ix_iy_zMap->setBinContent(Crystal_ix, Crystal_iy, Crystal_z);
259  }
260 
261  DEBUG(" Crystal " << n);
262  DEBUG(" side = " << Crystal_zside);
263  DEBUG(" ix, iy = " << Crystal_ix << ", " << Crystal_iy);
264  DEBUG(" x, y = " << Crystal_x << ", " << Crystal_y);
265  ;
266  DEBUG(" ");
267  }
268 
269  //-------Set the cell size for each (ieta, iphi) bin-------//
270  double currentLowEdge_eta = 0;
271  //double currentHighEdge_eta = 0;
272  for (int ieta = 1; ieta <= 85; ieta++) {
273  int ieta_ = 86 + ieta;
274 
275  double eta = hEB_ieta_iphi_etaMap->getBinContent(ieta_, 1);
276  double etam1 = -999;
277 
278  if (ieta == 1)
279  etam1 = hEB_ieta_iphi_etaMap->getBinContent(85, 1);
280  else
281  etam1 = hEB_ieta_iphi_etaMap->getBinContent(ieta_ - 1, 1);
282 
283  //double phi = hEB_ieta_iphi_phiMap->getBinContent(ieta_, 1);
284  double deta = fabs(eta - etam1);
285  double dphi = fabs(hEB_ieta_iphi_phiMap->getBinContent(ieta_, 1) - hEB_ieta_iphi_phiMap->getBinContent(ieta_, 2));
286 
287  currentLowEdge_eta += deta;
288  hEB_ieta_detaMap->setBinContent(ieta_, deta); // positive rings
289  hEB_ieta_dphiMap->setBinContent(ieta_, dphi); // positive rings
290  hEB_ieta_detaMap->setBinContent(86 - ieta, deta); // negative rings
291  hEB_ieta_dphiMap->setBinContent(86 - ieta, dphi); // negative rings
292  }
293 }
const CaloSubdetectorGeometry * getSubdetectorGeometry(const DetId &id) const
access the subdetector geometry for the given subdetector directly
Definition: CaloGeometry.cc:34
#define DEBUG(X)
MonitorElement * hEEpZ_ix_iy_irMap
MonitorElement * hEEpZ_ix_iy_zMap
MonitorElement * hEB_ieta_dphiMap
T sqrt(T t)
Definition: SSEVec.h:19
const CaloGeometry * caloGeom_
int zside() const
Definition: EEDetId.h:71
MonitorElement * hEB_ieta_detaMap
int ieta() const
get the crystal ieta
Definition: EBDetId.h:49
virtual double getBinContent(int binx) const
get content of bin (1-D)
#define M_PI
MonitorElement * hEEpZ_ix_iy_yMap
MonitorElement * hEEmZ_ix_iy_zMap
virtual void setBinContent(int binx, double content)
set content of bin (1-D)
MonitorElement * hEB_ieta_iphi_etaMap
MonitorElement * hEEmZ_ix_iy_yMap
MonitorElement * hEEmZ_ix_iy_xMap
MonitorElement * hEEmZ_ix_iy_irMap
MonitorElement * hEB_ieta_iphi_phiMap
MonitorElement * hEEpZ_ix_iy_xMap
void ECALRecHitAnalyzer::WriteECALRecHits ( const edm::Event iEvent,
const edm::EventSetup iSetup 
)

Definition at line 302 of file ECALRecHitAnalyzer.cc.

References DEBUG, egHLT::errCodes::EBRecHits, EBRecHitsLabel_, egHLT::errCodes::EERecHits, EERecHitsLabel_, ET, PVValHelper::eta, funct::exp(), dqm::impl::MonitorElement::Fill(), dqm::impl::MonitorElement::getBinContent(), edm::Event::getByToken(), hEB_energy_ieta_iphi, hEB_energyvsieta, hEB_ieta_iphi_etaMap, hEB_ieta_iphi_phiMap, hEB_Maxenergy_ieta_iphi, hEB_Maxenergyvsieta, hEB_METPhivsieta, hEB_METvsieta, hEB_MExvsieta, hEB_MEyvsieta, hEB_Minenergy_ieta_iphi, hEB_Minenergyvsieta, hEB_Occ_ieta_iphi, hEB_Occvsieta, hEB_SETvsieta, hEEmZ_energy_ix_iy, hEEmZ_energyvsir, hEEmZ_ix_iy_irMap, hEEmZ_ix_iy_xMap, hEEmZ_ix_iy_yMap, hEEmZ_ix_iy_zMap, hEEmZ_Maxenergy_ix_iy, hEEmZ_Maxenergyvsir, hEEmZ_METPhivsir, hEEmZ_METvsir, hEEmZ_MExvsir, hEEmZ_MEyvsir, hEEmZ_Minenergy_ix_iy, hEEmZ_Minenergyvsir, hEEmZ_Occ_ix_iy, hEEmZ_Occvsir, hEEmZ_SETvsir, hEEpZ_energy_ix_iy, hEEpZ_energyvsir, hEEpZ_ix_iy_irMap, hEEpZ_ix_iy_xMap, hEEpZ_ix_iy_yMap, hEEpZ_ix_iy_zMap, hEEpZ_Maxenergy_ix_iy, hEEpZ_Maxenergyvsir, hEEpZ_METPhivsir, hEEpZ_METvsir, hEEpZ_MExvsir, hEEpZ_MEyvsir, hEEpZ_Minenergy_ix_iy, hEEpZ_Minenergyvsir, hEEpZ_Occ_ix_iy, hEEpZ_Occvsir, hEEpZ_SETvsir, mps_fire::i, EBDetId::ieta(), EBDetId::iphi(), EEDetId::ix(), EEDetId::iy(), phi, colinearityKinematic::Phi, dqm::impl::MonitorElement::setBinContent(), theta(), x, y, z, and EEDetId::zside().

Referenced by analyze().

302  {
305  iEvent.getByToken(EBRecHitsLabel_, EBRecHits);
306  iEvent.getByToken(EERecHitsLabel_, EERecHits);
307  DEBUG("Got ECALRecHits");
308 
309  //const CaloSubdetectorGeometry* EBgeom=cG.getSubdetectorGeometry(DetId::Ecal,1);
310  //const CaloSubdetectorGeometry* EEgeom=cG.getSubdetectorGeometry(DetId::Ecal,2);
311  DEBUG("Got Geometry");
312 
313  TLorentzVector vEBMET_EtaRing[171];
314  int EBActiveRing[171];
315  int EBNActiveCells[171];
316  double EBSET_EtaRing[171];
317  double EBMaxEnergy_EtaRing[171];
318  double EBMinEnergy_EtaRing[171];
319  double EBenergy_EtaRing[171];
320 
321  for (int i = 0; i < 171; i++) {
322  EBActiveRing[i] = 0;
323  EBNActiveCells[i] = 0;
324  EBSET_EtaRing[i] = 0.0;
325  EBMaxEnergy_EtaRing[i] = -999;
326  EBMinEnergy_EtaRing[i] = 14E3;
327  EBenergy_EtaRing[i] = 0.0;
328  }
329 
330  edm::LogInfo("OutputInfo") << "Looping over EB" << std::endl;
331 
333  //int nEBrechit = 0;
334 
335  for (ebrechit = EBRecHits->begin(); ebrechit != EBRecHits->end(); ebrechit++) {
336  EBDetId det = ebrechit->id();
337  double Energy = ebrechit->energy();
338  Int_t ieta = det.ieta();
339  Int_t iphi = det.iphi();
340  int EtaRing = 85 + ieta; // this counts from 0
341  double eta = hEB_ieta_iphi_etaMap->getBinContent(EtaRing + 1, iphi);
342  double phi = hEB_ieta_iphi_phiMap->getBinContent(EtaRing + 1, iphi);
343  double theta = 2 * TMath::ATan(exp(-1 * eta));
344  double ET = Energy * TMath::Sin(theta);
345  TLorentzVector v_;
346 
347  if (Energy > EBMaxEnergy_EtaRing[EtaRing])
348  EBMaxEnergy_EtaRing[EtaRing] = Energy;
349  if (Energy < EBMinEnergy_EtaRing[EtaRing])
350  EBMinEnergy_EtaRing[EtaRing] = Energy;
351 
352  if (Energy > 0) {
353  EBActiveRing[EtaRing] = 1;
354  EBNActiveCells[EtaRing]++;
355  EBSET_EtaRing[EtaRing] += ET;
356  v_.SetPtEtaPhiE(ET, 0, phi, ET);
357  vEBMET_EtaRing[EtaRing] -= v_;
358  EBenergy_EtaRing[EtaRing] += Energy;
359  hEB_Occ_ieta_iphi->Fill(ieta, iphi);
360  }
361 
362  hEB_energy_ieta_iphi->Fill(ieta, iphi, Energy);
363  if (Energy > hEB_Maxenergy_ieta_iphi->getBinContent(EtaRing + 1, iphi))
364  hEB_Maxenergy_ieta_iphi->setBinContent(EtaRing + 1, iphi, Energy);
365  if (Energy < hEB_Minenergy_ieta_iphi->getBinContent(EtaRing + 1, iphi))
366  hEB_Minenergy_ieta_iphi->setBinContent(EtaRing + 1, iphi, Energy);
367 
368  } // loop over EB
369 
370  for (int iEtaRing = 0; iEtaRing < 171; iEtaRing++) {
371  hEB_Minenergyvsieta->Fill(iEtaRing - 85, EBMinEnergy_EtaRing[iEtaRing]);
372  hEB_Maxenergyvsieta->Fill(iEtaRing - 85, EBMaxEnergy_EtaRing[iEtaRing]);
373 
374  if (EBActiveRing[iEtaRing]) {
375  hEB_METvsieta->Fill(iEtaRing - 85, vEBMET_EtaRing[iEtaRing].Pt());
376  hEB_METPhivsieta->Fill(iEtaRing - 85, vEBMET_EtaRing[iEtaRing].Phi());
377  hEB_MExvsieta->Fill(iEtaRing - 85, vEBMET_EtaRing[iEtaRing].Px());
378  hEB_MEyvsieta->Fill(iEtaRing - 85, vEBMET_EtaRing[iEtaRing].Py());
379  hEB_SETvsieta->Fill(iEtaRing - 85, EBSET_EtaRing[iEtaRing]);
380  hEB_Occvsieta->Fill(iEtaRing - 85, EBNActiveCells[iEtaRing]);
381  hEB_energyvsieta->Fill(iEtaRing - 85, EBenergy_EtaRing[iEtaRing]);
382  }
383  }
384 
385  TLorentzVector vEEpZMET_EtaRing[101];
386  int EEpZActiveRing[101];
387  int EEpZNActiveCells[101];
388  double EEpZSET_EtaRing[101];
389  double EEpZMaxEnergy_EtaRing[101];
390  double EEpZMinEnergy_EtaRing[101];
391 
392  TLorentzVector vEEmZMET_EtaRing[101];
393  int EEmZActiveRing[101];
394  int EEmZNActiveCells[101];
395  double EEmZSET_EtaRing[101];
396  double EEmZMaxEnergy_EtaRing[101];
397  double EEmZMinEnergy_EtaRing[101];
398 
399  for (int i = 0; i < 101; i++) {
400  EEpZActiveRing[i] = 0;
401  EEpZNActiveCells[i] = 0;
402  EEpZSET_EtaRing[i] = 0.0;
403  EEpZMaxEnergy_EtaRing[i] = -999;
404  EEpZMinEnergy_EtaRing[i] = 14E3;
405 
406  EEmZActiveRing[i] = 0;
407  EEmZNActiveCells[i] = 0;
408  EEmZSET_EtaRing[i] = 0.0;
409  EEmZMaxEnergy_EtaRing[i] = -999;
410  EEmZMinEnergy_EtaRing[i] = 14E3;
411  }
412 
413  edm::LogInfo("OutputInfo") << "Looping over EE" << std::endl;
415  //int nEErechit = 0;
416  for (eerechit = EERecHits->begin(); eerechit != EERecHits->end(); eerechit++) {
417  EEDetId det = eerechit->id();
418  double Energy = eerechit->energy();
419  Int_t ix = det.ix();
420  Int_t iy = det.iy();
421  //Float_t ix_ = (Float_t)-999;
422  //Float_t iy_ = (Float_t)-999;
423  Int_t ir = -999;
424  // edm::LogInfo("OutputInfo") << ix << " " << iy << " " << ix_ << " " << iy_ << " " << ir << std::endl;
425 
426  double x = -999;
427  double y = -999;
428  double z = -999;
429  double theta = -999;
430  double phi = -999;
431 
432  int Crystal_zside = det.zside();
433 
434  if (Crystal_zside == -1) {
435  ir = (Int_t)hEEmZ_ix_iy_irMap->getBinContent(ix, iy);
436  x = hEEmZ_ix_iy_xMap->getBinContent(ix, iy);
437  y = hEEmZ_ix_iy_yMap->getBinContent(ix, iy);
438  z = hEEmZ_ix_iy_zMap->getBinContent(ix, iy);
439  }
440  if (Crystal_zside == 1) {
441  ir = (Int_t)hEEpZ_ix_iy_irMap->getBinContent(ix, iy);
442  x = hEEpZ_ix_iy_xMap->getBinContent(ix, iy);
443  y = hEEpZ_ix_iy_yMap->getBinContent(ix, iy);
444  z = hEEpZ_ix_iy_zMap->getBinContent(ix, iy);
445  }
446  TVector3 pos_vector(x, y, z);
447  phi = pos_vector.Phi();
448  theta = pos_vector.Theta();
449  double ET = Energy * TMath::Sin(theta);
450  TLorentzVector v_;
451 
452  if (Crystal_zside == -1) {
453  if (Energy > 0) {
454  EEmZActiveRing[ir] = 1;
455  EEmZNActiveCells[ir]++;
456  EEmZSET_EtaRing[ir] += ET;
457  v_.SetPtEtaPhiE(ET, 0, phi, ET);
458  vEEmZMET_EtaRing[ir] -= v_;
459  hEEmZ_Occ_ix_iy->Fill(ix, iy);
460  }
461  hEEmZ_energyvsir->Fill(ir, Energy);
462  hEEmZ_energy_ix_iy->Fill(ix, iy, Energy);
463 
464  if (Energy > EEmZMaxEnergy_EtaRing[ir])
465  EEmZMaxEnergy_EtaRing[ir] = Energy;
466  if (Energy < EEmZMinEnergy_EtaRing[ir])
467  EEmZMinEnergy_EtaRing[ir] = Energy;
468 
469  if (Energy > hEEmZ_Maxenergy_ix_iy->getBinContent(ix, iy))
470  hEEmZ_Maxenergy_ix_iy->setBinContent(ix, iy, Energy);
471  if (Energy < hEEmZ_Minenergy_ix_iy->getBinContent(ix, iy))
472  hEEmZ_Minenergy_ix_iy->setBinContent(ix, iy, Energy);
473  }
474  if (Crystal_zside == 1) {
475  if (Energy > 0) {
476  EEpZActiveRing[ir] = 1;
477  EEpZNActiveCells[ir]++;
478  EEpZSET_EtaRing[ir] += ET;
479  v_.SetPtEtaPhiE(ET, 0, phi, ET);
480  vEEpZMET_EtaRing[ir] -= v_;
481  hEEpZ_Occ_ix_iy->Fill(ix, iy);
482  }
483  hEEpZ_energyvsir->Fill(ir, Energy);
484  hEEpZ_energy_ix_iy->Fill(ix, iy, Energy);
485 
486  if (Energy > EEpZMaxEnergy_EtaRing[ir])
487  EEpZMaxEnergy_EtaRing[ir] = Energy;
488  if (Energy < EEpZMinEnergy_EtaRing[ir])
489  EEpZMinEnergy_EtaRing[ir] = Energy;
490  if (Energy > hEEpZ_Maxenergy_ix_iy->getBinContent(ix, iy))
491  hEEpZ_Maxenergy_ix_iy->setBinContent(ix, iy, Energy);
492  if (Energy < hEEpZ_Minenergy_ix_iy->getBinContent(ix, iy))
493  hEEpZ_Minenergy_ix_iy->setBinContent(ix, iy, Energy);
494  }
495  } // loop over EE
496  edm::LogInfo("OutputInfo") << "Done Looping over EE" << std::endl;
497  for (int iEtaRing = 0; iEtaRing < 101; iEtaRing++) {
498  hEEpZ_Maxenergyvsir->Fill(iEtaRing, EEpZMaxEnergy_EtaRing[iEtaRing]);
499  hEEpZ_Minenergyvsir->Fill(iEtaRing, EEpZMinEnergy_EtaRing[iEtaRing]);
500  hEEmZ_Maxenergyvsir->Fill(iEtaRing, EEmZMaxEnergy_EtaRing[iEtaRing]);
501  hEEmZ_Minenergyvsir->Fill(iEtaRing, EEmZMinEnergy_EtaRing[iEtaRing]);
502 
503  if (EEpZActiveRing[iEtaRing]) {
504  hEEpZ_METvsir->Fill(iEtaRing, vEEpZMET_EtaRing[iEtaRing].Pt());
505  hEEpZ_METPhivsir->Fill(iEtaRing, vEEpZMET_EtaRing[iEtaRing].Phi());
506  hEEpZ_MExvsir->Fill(iEtaRing, vEEpZMET_EtaRing[iEtaRing].Px());
507  hEEpZ_MEyvsir->Fill(iEtaRing, vEEpZMET_EtaRing[iEtaRing].Py());
508  hEEpZ_SETvsir->Fill(iEtaRing, EEpZSET_EtaRing[iEtaRing]);
509  hEEpZ_Occvsir->Fill(iEtaRing, EEpZNActiveCells[iEtaRing]);
510  }
511 
512  if (EEmZActiveRing[iEtaRing]) {
513  hEEmZ_METvsir->Fill(iEtaRing, vEEmZMET_EtaRing[iEtaRing].Pt());
514  hEEmZ_METPhivsir->Fill(iEtaRing, vEEmZMET_EtaRing[iEtaRing].Phi());
515  hEEmZ_MExvsir->Fill(iEtaRing, vEEmZMET_EtaRing[iEtaRing].Px());
516  hEEmZ_MEyvsir->Fill(iEtaRing, vEEmZMET_EtaRing[iEtaRing].Py());
517  hEEmZ_SETvsir->Fill(iEtaRing, EEmZSET_EtaRing[iEtaRing]);
518  hEEmZ_Occvsir->Fill(iEtaRing, EEmZNActiveCells[iEtaRing]);
519  }
520  }
521  edm::LogInfo("OutputInfo") << "Done ..." << std::endl;
522 } // loop over RecHits
#define DEBUG(X)
MonitorElement * hEB_Maxenergyvsieta
MonitorElement * hEB_MExvsieta
int ix() const
Definition: EEDetId.h:77
MonitorElement * hEEmZ_Occvsir
MonitorElement * hEEpZ_METPhivsir
MonitorElement * hEEmZ_METvsir
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:539
MonitorElement * hEEpZ_METvsir
MonitorElement * hEB_Maxenergy_ieta_iphi
MonitorElement * hEB_METvsieta
MonitorElement * hEEpZ_ix_iy_irMap
MonitorElement * hEB_Occvsieta
std::vector< EcalRecHit >::const_iterator const_iterator
Geom::Theta< T > theta() const
MonitorElement * hEB_energyvsieta
Exp< T >::type exp(const T &t)
Definition: Exp.h:22
MonitorElement * hEEpZ_ix_iy_zMap
MonitorElement * hEEpZ_Maxenergy_ix_iy
MonitorElement * hEB_METPhivsieta
MonitorElement * hEEmZ_Minenergyvsir
int iphi() const
get the crystal iphi
Definition: EBDetId.h:51
void Fill(long long x)
MonitorElement * hEEmZ_energy_ix_iy
MonitorElement * hEEmZ_energyvsir
MonitorElement * hEEmZ_Occ_ix_iy
MonitorElement * hEEmZ_Maxenergyvsir
MonitorElement * hEEmZ_SETvsir
MonitorElement * hEB_Occ_ieta_iphi
MonitorElement * hEEpZ_Minenergyvsir
int zside() const
Definition: EEDetId.h:71
MonitorElement * hEEpZ_Minenergy_ix_iy
MonitorElement * hEB_Minenergy_ieta_iphi
MonitorElement * hEEmZ_METPhivsir
MonitorElement * hEEmZ_MEyvsir
MonitorElement * hEEpZ_energyvsir
int iy() const
Definition: EEDetId.h:83
MonitorElement * hEEmZ_Minenergy_ix_iy
int ieta() const
get the crystal ieta
Definition: EBDetId.h:49
virtual double getBinContent(int binx) const
get content of bin (1-D)
MonitorElement * hEB_energy_ieta_iphi
MonitorElement * hEB_MEyvsieta
MonitorElement * hEB_Minenergyvsieta
Log< level::Info, false > LogInfo
MonitorElement * hEEpZ_ix_iy_yMap
MonitorElement * hEEmZ_ix_iy_zMap
MonitorElement * hEEmZ_Maxenergy_ix_iy
virtual void setBinContent(int binx, double content)
set content of bin (1-D)
MonitorElement * hEB_ieta_iphi_etaMap
MonitorElement * hEEpZ_SETvsir
MonitorElement * hEEpZ_Maxenergyvsir
MonitorElement * hEEmZ_MExvsir
MonitorElement * hEEmZ_ix_iy_yMap
MonitorElement * hEEmZ_ix_iy_xMap
MonitorElement * hEEpZ_MEyvsir
MonitorElement * hEB_SETvsieta
MonitorElement * hEEpZ_MExvsir
MonitorElement * hEEpZ_Occvsir
MonitorElement * hEEpZ_energy_ix_iy
MonitorElement * hEEpZ_Occ_ix_iy
#define ET
MonitorElement * hEEmZ_ix_iy_irMap
edm::EDGetTokenT< EERecHitCollection > EERecHitsLabel_
MonitorElement * hEB_ieta_iphi_phiMap
MonitorElement * hEEpZ_ix_iy_xMap
edm::EDGetTokenT< EBRecHitCollection > EBRecHitsLabel_

Member Data Documentation

const CaloGeometry* ECALRecHitAnalyzer::caloGeom_
private

Definition at line 97 of file ECALRecHitAnalyzer.h.

Referenced by dqmbeginRun(), and FillGeometry().

edm::ESGetToken<CaloGeometry, CaloGeometryRecord> ECALRecHitAnalyzer::caloGeomToken_
private

Definition at line 96 of file ECALRecHitAnalyzer.h.

Referenced by dqmbeginRun(), and ECALRecHitAnalyzer().

int ECALRecHitAnalyzer::CurrentEvent
private

Definition at line 101 of file ECALRecHitAnalyzer.h.

Referenced by analyze(), and dqmbeginRun().

bool ECALRecHitAnalyzer::debug_
private

Definition at line 98 of file ECALRecHitAnalyzer.h.

Referenced by ECALRecHitAnalyzer().

edm::EDGetTokenT<EBRecHitCollection> ECALRecHitAnalyzer::EBRecHitsLabel_
private

Definition at line 94 of file ECALRecHitAnalyzer.h.

Referenced by ECALRecHitAnalyzer(), and WriteECALRecHits().

edm::EDGetTokenT<EERecHitCollection> ECALRecHitAnalyzer::EERecHitsLabel_
private

Definition at line 95 of file ECALRecHitAnalyzer.h.

Referenced by ECALRecHitAnalyzer(), and WriteECALRecHits().

bool ECALRecHitAnalyzer::finebinning_
private

Definition at line 99 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms().

std::string ECALRecHitAnalyzer::FolderName_
private

Definition at line 100 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and ECALRecHitAnalyzer().

MonitorElement* ECALRecHitAnalyzer::hEB_energy_ieta_iphi
private

Definition at line 127 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEB_energyvsieta
private

Definition at line 143 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEB_ieta_detaMap
private

Definition at line 106 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and FillGeometry().

MonitorElement* ECALRecHitAnalyzer::hEB_ieta_dphiMap
private

Definition at line 107 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and FillGeometry().

MonitorElement* ECALRecHitAnalyzer::hEB_ieta_iphi_etaMap
private

Definition at line 104 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), FillGeometry(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEB_ieta_iphi_phiMap
private

Definition at line 105 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), FillGeometry(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEB_Maxenergy_ieta_iphi
private

Definition at line 135 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEB_Maxenergyvsieta
private

Definition at line 147 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEB_METPhivsieta
private

Definition at line 163 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEB_METvsieta
private

Definition at line 159 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEB_MExvsieta
private

Definition at line 167 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEB_MEyvsieta
private

Definition at line 171 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEB_Minenergy_ieta_iphi
private

Definition at line 131 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEB_Minenergyvsieta
private

Definition at line 151 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEB_Occ_ieta_iphi
private

Definition at line 139 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEB_Occvsieta
private

Definition at line 175 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEB_SETvsieta
private

Definition at line 155 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hECAL_Nevents
private

Definition at line 123 of file ECALRecHitAnalyzer.h.

Referenced by analyze(), and bookHistograms().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_energy_ix_iy
private

Definition at line 126 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_energyvsir
private

Definition at line 142 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_ix_iy_dxMap
private

Definition at line 120 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_ix_iy_dyMap
private

Definition at line 121 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_ix_iy_irMap
private

Definition at line 116 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), FillGeometry(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_ix_iy_xMap
private

Definition at line 117 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), FillGeometry(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_ix_iy_yMap
private

Definition at line 118 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), FillGeometry(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_ix_iy_zMap
private

Definition at line 119 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), FillGeometry(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_Maxenergy_ix_iy
private

Definition at line 134 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_Maxenergyvsir
private

Definition at line 146 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_METPhivsir
private

Definition at line 162 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_METvsir
private

Definition at line 158 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_MExvsir
private

Definition at line 166 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_MEyvsir
private

Definition at line 170 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_Minenergy_ix_iy
private

Definition at line 130 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_Minenergyvsir
private

Definition at line 150 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_Occ_ix_iy
private

Definition at line 138 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_Occvsir
private

Definition at line 174 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEmZ_SETvsir
private

Definition at line 154 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_energy_ix_iy
private

Definition at line 125 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_energyvsir
private

Definition at line 141 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_ix_iy_dxMap
private

Definition at line 113 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_ix_iy_dyMap
private

Definition at line 114 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_ix_iy_irMap
private

Definition at line 109 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), FillGeometry(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_ix_iy_xMap
private

Definition at line 110 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), FillGeometry(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_ix_iy_yMap
private

Definition at line 111 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), FillGeometry(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_ix_iy_zMap
private

Definition at line 112 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), FillGeometry(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_Maxenergy_ix_iy
private

Definition at line 133 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_Maxenergyvsir
private

Definition at line 145 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_METPhivsir
private

Definition at line 161 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_METvsir
private

Definition at line 157 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_MExvsir
private

Definition at line 165 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_MEyvsir
private

Definition at line 169 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_Minenergy_ix_iy
private

Definition at line 129 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_Minenergyvsir
private

Definition at line 149 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_Occ_ix_iy
private

Definition at line 137 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_Occvsir
private

Definition at line 173 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().

MonitorElement* ECALRecHitAnalyzer::hEEpZ_SETvsir
private

Definition at line 153 of file ECALRecHitAnalyzer.h.

Referenced by bookHistograms(), and WriteECALRecHits().