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 | Protected Member Functions | Private Attributes
DQMHcalPhiSymAlCaReco Class Reference
Inheritance diagram for DQMHcalPhiSymAlCaReco:
DQMOneEDAnalyzer<> edm::one::EDProducer< edm::EndRunProducer, edm::one::WatchRuns, edm::Accumulator, Args...> edm::one::EDProducerBase edm::ProducerBase edm::EDConsumerBase edm::ProductRegistryHelper

Public Member Functions

 DQMHcalPhiSymAlCaReco (const edm::ParameterSet &)
 
 ~DQMHcalPhiSymAlCaReco () override
 
- Public Member Functions inherited from DQMOneEDAnalyzer<>
void accumulate (edm::Event const &event, edm::EventSetup const &setup) override
 
void beginRun (edm::Run const &run, edm::EventSetup const &setup) final
 
 DQMOneEDAnalyzer ()
 
void endRun (edm::Run const &, edm::EventSetup const &) final
 
void endRunProduce (edm::Run &run, edm::EventSetup const &setup) final
 
virtual bool getCanSaveByLumi ()
 
- Public Member Functions inherited from edm::one::EDProducer< edm::EndRunProducer, edm::one::WatchRuns, edm::Accumulator, Args...>
 EDProducer ()=default
 
 EDProducer (const EDProducer &)=delete
 
SerialTaskQueueglobalLuminosityBlocksQueue () final
 
SerialTaskQueueglobalRunsQueue () final
 
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
 
bool wantsGlobalLuminosityBlocks () const final
 
bool wantsGlobalRuns () const final
 
bool wantsInputProcessBlocks () const final
 
bool wantsProcessBlocks () const final
 
- Public Member Functions inherited from edm::one::EDProducerBase
 EDProducerBase ()
 
ModuleDescription const & moduleDescription () const
 
bool wantsStreamLuminosityBlocks () const
 
bool wantsStreamRuns () const
 
 ~EDProducerBase () override
 
- Public Member Functions inherited from edm::ProducerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
std::vector
< edm::ProductResolverIndex >
const & 
indiciesForPutProducts (BranchType iBranchType) const
 
 ProducerBase ()
 
std::vector
< edm::ProductResolverIndex >
const & 
putTokenIndexToProductResolverIndex () const
 
void registerProducts (ProducerBase *, ProductRegistry *, ModuleDescription const &)
 
std::function< void(BranchDescription
const &)> 
registrationCallback () const
 used by the fwk to register list of products More...
 
void resolvePutIndicies (BranchType iBranchType, ModuleToResolverIndicies const &iIndicies, std::string const &moduleLabel)
 
 ~ProducerBase () noexcept(false) override
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
void convertCurrentProcessAlias (std::string const &processName)
 Convert "@currentProcess" in InputTag process names to the actual current process name. More...
 
 EDConsumerBase ()
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
 EDConsumerBase (EDConsumerBase &&)=default
 
ESProxyIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
std::vector< ESProxyIndex > const & esGetTokenIndicesVector (edm::Transition iTrans) const
 
std::vector< ESRecordIndex >
const & 
esGetTokenRecordIndicesVector (edm::Transition iTrans) const
 
ProductResolverIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
std::vector
< ProductResolverIndexAndSkipBit >
const & 
itemsToGetFrom (BranchType iType) const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesWhoseProductsAreConsumed (std::array< std::vector< ModuleDescription const * > *, NumBranchTypes > &modulesAll, std::vector< ModuleProcessName > &modulesInPreviousProcesses, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
bool registeredToConsume (ProductResolverIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
void selectInputProcessBlocks (ProductRegistry const &productRegistry, ProcessBlockHelperBase const &processBlockHelperBase)
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProxyIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Protected Member Functions

void analyze (const edm::Event &e, const edm::EventSetup &c) override
 
void bookHistograms (DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
 
void dqmEndRun (const edm::Run &r, const edm::EventSetup &c) override
 
- Protected Member Functions inherited from DQMOneEDAnalyzer<>
virtual void dqmBeginRun (edm::Run const &, edm::EventSetup const &)
 
- Protected Member Functions inherited from edm::ProducerBase
ProducesCollector producesCollector ()
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
template<BranchType B = InEvent>
EDConsumerBaseAdaptor< Bconsumes (edm::InputTag tag) noexcept
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes ()
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
template<Transition Tr = Transition::Event>
constexpr auto esConsumes ()
 
template<Transition Tr = Transition::Event>
auto esConsumes (ESInputTag tag)
 
template<Transition Tr = Transition::Event>
ESGetTokenGeneric esConsumes (eventsetup::EventSetupRecordKey const &iRecord, eventsetup::DataKey const &iKey)
 Used with EventSetupRecord::doGet. More...
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
void resetItemsToGetFrom (BranchType iType)
 

Private Attributes

int eventCounter_
 
std::string fileName_
 Output file name if required. More...
 
std::string folderName_
 DQM folder name. More...
 
edm::EDGetTokenT
< HBHERecHitCollection
hbherecoMB
 object to monitor More...
 
edm::EDGetTokenT
< HBHERecHitCollection
hbherecoNoise
 
MonitorElementhFEDsize
 
edm::EDGetTokenT
< HFRecHitCollection
hfrecoMB
 
edm::EDGetTokenT
< HFRecHitCollection
hfrecoNoise
 
MonitorElementhHcalIsZS
 
int hiDistr_r_nbin_
 
double hiDistr_x_max_
 
double hiDistr_x_min_
 
int hiDistr_x_nbin_
 
double hiDistr_y_max_
 
double hiDistr_y_min_
 
int hiDistr_y_nbin_
 
MonitorElementhiDistrHBHEsize1D_
 
MonitorElementhiDistrHFsize1D_
 
MonitorElementhiDistrMB2Min2D_
 
MonitorElementhiDistrMB2Pl2D_
 
MonitorElementhiDistrMBMin2D_
 
MonitorElementhiDistrMBPl2D_
 
MonitorElementhiDistrNoise2Min2D_
 
MonitorElementhiDistrNoise2Pl2D_
 
MonitorElementhiDistrNoiseMin2D_
 
MonitorElementhiDistrNoisePl2D_
 
MonitorElementhiDistrVarMBMin2D_
 
MonitorElementhiDistrVarMBPl2D_
 
MonitorElementhiDistrVarNoiseMin2D_
 
MonitorElementhiDistrVarNoisePl2D_
 
MonitorElementhL1Id
 
edm::InputTag horecoMB
 
edm::InputTag horecoNoise
 
double ihbhe_size_
 
double ihf_size_
 
unsigned int period_
 
bool perLSsaving_
 
edm::EDGetTokenT
< FEDRawDataCollection
rawInLabel_
 
bool saveToFile_
 Write to file. More...
 

Additional Inherited Members

- Public Types inherited from DQMOneEDAnalyzer<>
typedef dqm::reco::DQMStore DQMStore
 
typedef dqm::reco::MonitorElement MonitorElement
 
- Public Types inherited from edm::one::EDProducerBase
typedef EDProducerBase ModuleType
 
- Public Types inherited from edm::ProducerBase
using ModuleToResolverIndicies = std::unordered_multimap< std::string, std::tuple< edm::TypeID const *, const char *, edm::ProductResolverIndex >>
 
typedef
ProductRegistryHelper::TypeLabelList 
TypeLabelList
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::one::EDProducerBase
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 
- Protected Attributes inherited from DQMOneEDAnalyzer<>
edm::EDPutTokenT< DQMTokenrunToken_
 

Detailed Description

Definition at line 40 of file DQMHcalPhiSymAlCaReco.cc.

Constructor & Destructor Documentation

DQMHcalPhiSymAlCaReco::DQMHcalPhiSymAlCaReco ( const edm::ParameterSet ps)

Definition at line 122 of file DQMHcalPhiSymAlCaReco.cc.

References fileName_, folderName_, edm::ParameterSet::getParameter(), edm::ParameterSet::getUntrackedParameter(), hbherecoMB, hbherecoNoise, hfrecoMB, hfrecoNoise, hiDistr_r_nbin_, hiDistr_x_max_, hiDistr_x_min_, hiDistr_x_nbin_, hiDistr_y_max_, hiDistr_y_min_, hiDistr_y_nbin_, horecoMB, horecoNoise, ihbhe_size_, ihf_size_, period_, perLSsaving_, rawInLabel_, saveToFile_, and AlCaHLTBitMon_QueryRunRegistry::string.

122  : eventCounter_(0) {
123  //
124  // Input from configurator file
125  //
126  folderName_ = ps.getUntrackedParameter<std::string>("FolderName", "ALCAStreamHcalPhiSym");
127 
128  hbherecoMB = consumes<HBHERecHitCollection>(ps.getParameter<edm::InputTag>("hbheInputMB"));
129  horecoMB = ps.getParameter<edm::InputTag>("hoInputMB");
130  hfrecoMB = consumes<HFRecHitCollection>(ps.getParameter<edm::InputTag>("hfInputMB"));
131 
132  hbherecoNoise = consumes<HBHERecHitCollection>(ps.getParameter<edm::InputTag>("hbheInputNoise"));
133  horecoNoise = ps.getParameter<edm::InputTag>("hoInputNoise");
134  hfrecoNoise = consumes<HFRecHitCollection>(ps.getParameter<edm::InputTag>("hfInputNoise"));
135 
136  rawInLabel_ = consumes<FEDRawDataCollection>(ps.getParameter<edm::InputTag>("rawInputLabel"));
137 
138  period_ = ps.getParameter<unsigned int>("period");
139 
140  saveToFile_ = ps.getUntrackedParameter<bool>("SaveToFile", false);
141  fileName_ = ps.getUntrackedParameter<std::string>("FileName", "MonitorAlCaHcalPhiSym.root");
142 
143  perLSsaving_ = (ps.getUntrackedParameter<bool>("perLSsaving", false));
144 
145  // histogram parameters
146 
147  // Distribution of rechits in iPhi, iEta
148  hiDistr_y_nbin_ = ps.getUntrackedParameter<int>("hiDistr_y_nbin", 72);
149  hiDistr_y_min_ = ps.getUntrackedParameter<double>("hiDistr_y_min", 0.5);
150  hiDistr_y_max_ = ps.getUntrackedParameter<double>("hiDistr_y_max", 72.5);
151  hiDistr_x_nbin_ = ps.getUntrackedParameter<int>("hiDistr_x_nbin", 41);
152  hiDistr_x_min_ = ps.getUntrackedParameter<double>("hiDistr_x_min", 0.5);
153  hiDistr_x_max_ = ps.getUntrackedParameter<double>("hiDistr_x_max", 41.5);
154  // Check for NZS
155  hiDistr_r_nbin_ = ps.getUntrackedParameter<int>("hiDistr_r_nbin", 100);
156  ihbhe_size_ = ps.getUntrackedParameter<double>("ihbhe_size_", 5184.);
157  ihf_size_ = ps.getUntrackedParameter<double>("ihf_size_", 1728.);
158 }
T getUntrackedParameter(std::string const &, T const &) const
bool saveToFile_
Write to file.
edm::EDGetTokenT< HBHERecHitCollection > hbherecoNoise
edm::EDGetTokenT< FEDRawDataCollection > rawInLabel_
edm::EDGetTokenT< HFRecHitCollection > hfrecoNoise
std::string folderName_
DQM folder name.
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
edm::EDGetTokenT< HFRecHitCollection > hfrecoMB
std::string fileName_
Output file name if required.
edm::EDGetTokenT< HBHERecHitCollection > hbherecoMB
object to monitor
DQMHcalPhiSymAlCaReco::~DQMHcalPhiSymAlCaReco ( )
override

Definition at line 160 of file DQMHcalPhiSymAlCaReco.cc.

160 {}

Member Function Documentation

void DQMHcalPhiSymAlCaReco::analyze ( const edm::Event e,
const edm::EventSetup c 
)
overrideprotectedvirtual

Reimplemented from DQMOneEDAnalyzer<>.

Definition at line 349 of file DQMHcalPhiSymAlCaReco.cc.

References edm::SortedCollection< T, SORT >::begin(), FEDRawData::data(), HcalDetId::depth(), edm::SortedCollection< T, SORT >::end(), eventCounter_, FEDRawDataCollection::FEDData(), dqm::impl::MonitorElement::Fill(), edm::Event::getByToken(), HcalDCCHeader::getSpigotData(), HcalDCCHeader::getSpigotPresent(), hbherecoMB, hbherecoNoise, hFEDsize, hfrecoMB, hfrecoNoise, hHcalIsZS, hiDistrHBHEsize1D_, hiDistrHFsize1D_, hiDistrMB2Min2D_, hiDistrMB2Pl2D_, hiDistrMBMin2D_, hiDistrMBPl2D_, hiDistrNoise2Min2D_, hiDistrNoise2Pl2D_, hiDistrNoiseMin2D_, hiDistrNoisePl2D_, hL1Id, mps_fire::i, HcalDetId::ieta(), ihbhe_size_, ihf_size_, HcalDetId::iphi(), HcalHTRData::isUnsuppressed(), edm::HandleBase::isValid(), isotrackApplyRegressor::k, LogDebug, FEDHeader::lvl1ID(), FEDNumbering::MAXHCALFEDID, FEDNumbering::MINHCALFEDID, period_, funct::pow(), edm::Handle< T >::product(), rawInLabel_, FEDRawData::size(), edm::SortedCollection< T, SORT >::size(), and HcalDCCHeader::SPIGOT_COUNT.

349  {
350  eventCounter_++;
351 
353  iEvent.getByToken(rawInLabel_, rawIn);
354 
355  if (!rawIn.isValid()) {
356  LogDebug("") << "HcalCalibAlgos: Error! can't get hbhe product!" << std::endl;
357  return;
358  }
359 
360  // get HCAL FEDs:
361  std::vector<int> selFEDs;
363  selFEDs.push_back(i);
364  }
365 
366  // std::cout<<" Size of FED "<<selFEDs.size()<<std::endl;
367 
368  const FEDRawDataCollection *rdc = rawIn.product();
369 
370  bool hcalIsZS = false;
371  int lvl1ID = 0;
372  bool lvl1IDFound = false;
373  for (unsigned int k = 0; k < selFEDs.size(); k++) {
374  const FEDRawData &fedData = rdc->FEDData(selFEDs[k]);
375  // std::cout<<fedData.size()*std::pow(1024.,-1)<<std::endl;
376  hFEDsize->Fill(fedData.size() * std::pow(1024., -1), 1);
377 
378  // get HCAL DCC Header for each FEDRawData
379  const HcalDCCHeader *dccHeader = (const HcalDCCHeader *)(fedData.data());
380  if (dccHeader) {
381  // walk through the HTR data...
382  HcalHTRData htr;
383 
384  int nspigot = 0;
385  for (int spigot = 0; spigot < HcalDCCHeader::SPIGOT_COUNT; spigot++) {
386  nspigot++;
387 
388  if (!dccHeader->getSpigotPresent(spigot))
389  continue;
390 
391  // Load the given decoder with the pointer and length from this spigot.
392  dccHeader->getSpigotData(spigot, htr, fedData.size());
393 
394  if (k != 20 && nspigot != 14) {
395  if (!htr.isUnsuppressed()) {
396  hcalIsZS = true;
397  }
398  }
399  }
400  }
401 
402  // try to get the lvl1ID from the HCAL fed
403  if (!lvl1IDFound && (fedData.size() > 0)) {
404  // get FED Header for FEDRawData
405  FEDHeader fedHeader(fedData.data());
406  lvl1ID = fedHeader.lvl1ID();
407  lvl1IDFound = true;
408  }
409  } // loop over HcalFEDs
410 
411  hHcalIsZS->Fill(hcalIsZS);
412  hL1Id->Fill(lvl1ID % period_);
413 
415  iEvent.getByToken(hbherecoNoise, hbheNS);
416 
417  if (!hbheNS.isValid()) {
418  LogDebug("") << "HcalCalibAlgos: Error! can't get hbhe product!" << std::endl;
419  return;
420  }
421 
423  iEvent.getByToken(hbherecoMB, hbheMB);
424 
425  if (!hbheMB.isValid()) {
426  LogDebug("") << "HcalCalibAlgos: Error! can't get hbhe product!" << std::endl;
427  return;
428  }
429 
431  iEvent.getByToken(hfrecoNoise, hfNS);
432 
433  if (!hfNS.isValid()) {
434  LogDebug("") << "HcalCalibAlgos: Error! can't get hbhe product!" << std::endl;
435  return;
436  }
437 
439  iEvent.getByToken(hfrecoMB, hfMB);
440 
441  if (!hfMB.isValid()) {
442  LogDebug("") << "HcalCalibAlgos: Error! can't get hbhe product!" << std::endl;
443  return;
444  }
445 
446  const HBHERecHitCollection HithbheNS = *(hbheNS.product());
447 
448  hiDistrHBHEsize1D_->Fill(HithbheNS.size() / ihbhe_size_);
449 
450  for (HBHERecHitCollection::const_iterator hbheItr = HithbheNS.begin(); hbheItr != HithbheNS.end(); hbheItr++) {
451  DetId id = (*hbheItr).detid();
452  HcalDetId hid = HcalDetId(id);
453 
454  if (hid.depth() == 1) {
455  if (hid.ieta() > 0) {
456  hiDistrNoisePl2D_->Fill(hid.ieta(), hid.iphi(), hbheItr->energy());
457  hiDistrNoise2Pl2D_->Fill(hid.ieta(), hid.iphi(), hbheItr->energy() * hbheItr->energy());
458  } else {
459  hiDistrNoiseMin2D_->Fill(fabs(hid.ieta()), hid.iphi(), hbheItr->energy());
460  hiDistrNoise2Min2D_->Fill(fabs(hid.ieta()), hid.iphi(), hbheItr->energy() * hbheItr->energy());
461  }
462  }
463  }
464 
465  const HBHERecHitCollection HithbheMB = *(hbheMB.product());
466 
467  for (HBHERecHitCollection::const_iterator hbheItr = HithbheMB.begin(); hbheItr != HithbheMB.end(); hbheItr++) {
468  DetId id = (*hbheItr).detid();
469  HcalDetId hid = HcalDetId(id);
470 
471  if (hid.depth() == 1) {
472  if (hid.ieta() > 0) {
473  hiDistrMBPl2D_->Fill(hid.ieta(), hid.iphi(), hbheItr->energy());
474  hiDistrMB2Pl2D_->Fill(hid.ieta(), hid.iphi(), hbheItr->energy() * hbheItr->energy());
475  } else {
476  hiDistrMBMin2D_->Fill(fabs(hid.ieta()), hid.iphi(), hbheItr->energy());
477  hiDistrMB2Min2D_->Fill(fabs(hid.ieta()), hid.iphi(), hbheItr->energy() * hbheItr->energy());
478  }
479  }
480  }
481 
482  const HFRecHitCollection HithfNS = *(hfNS.product());
483 
484  hiDistrHFsize1D_->Fill(HithfNS.size() / ihf_size_);
485 
486  for (HFRecHitCollection::const_iterator hbheItr = HithfNS.begin(); hbheItr != HithfNS.end(); hbheItr++) {
487  DetId id = (*hbheItr).detid();
488  HcalDetId hid = HcalDetId(id);
489 
490  if (hid.depth() == 1) {
491  if (hid.ieta() > 0) {
492  hiDistrNoisePl2D_->Fill(hid.ieta(), hid.iphi(), hbheItr->energy());
493  hiDistrNoise2Pl2D_->Fill(hid.ieta(), hid.iphi(), hbheItr->energy() * hbheItr->energy());
494  } else {
495  hiDistrNoiseMin2D_->Fill(fabs(hid.ieta()), hid.iphi(), hbheItr->energy());
496  hiDistrNoise2Min2D_->Fill(fabs(hid.ieta()), hid.iphi(), hbheItr->energy() * hbheItr->energy());
497  }
498  }
499  }
500 
501  const HFRecHitCollection HithfMB = *(hfMB.product());
502 
503  for (HFRecHitCollection::const_iterator hbheItr = HithfMB.begin(); hbheItr != HithfMB.end(); hbheItr++) {
504  DetId id = (*hbheItr).detid();
505  HcalDetId hid = HcalDetId(id);
506 
507  if (hid.depth() == 1) {
508  if (hid.ieta() > 0) {
509  hiDistrMBPl2D_->Fill(hid.ieta(), hid.iphi(), hbheItr->energy());
510  hiDistrMB2Pl2D_->Fill(hid.ieta(), hid.iphi(), hbheItr->energy() * hbheItr->energy());
511  } else {
512  hiDistrMBMin2D_->Fill(fabs(hid.ieta()), hid.iphi(), hbheItr->energy());
513  hiDistrMB2Min2D_->Fill(fabs(hid.ieta()), hid.iphi(), hbheItr->energy() * hbheItr->energy());
514  }
515  }
516  }
517 
518 } // analyze
MonitorElement * hiDistrNoisePl2D_
edm::EDGetTokenT< HBHERecHitCollection > hbherecoNoise
std::vector< T >::const_iterator const_iterator
edm::EDGetTokenT< FEDRawDataCollection > rawInLabel_
int getSpigotData(int nspigot, HcalHTRData &decodeTool, int validSize) const
size_t size() const
Lenght of the data buffer in bytes.
Definition: FEDRawData.h:45
bool isUnsuppressed() const
Is this event an unsuppresed event?
Definition: HcalHTRData.cc:378
void Fill(long long x)
MonitorElement * hiDistrMBPl2D_
MonitorElement * hiDistrHFsize1D_
edm::EDGetTokenT< HFRecHitCollection > hfrecoNoise
int iEvent
Definition: GenABIO.cc:224
const FEDRawData & FEDData(int fedid) const
retrieve data for fed
constexpr int iphi() const
get the cell iphi
Definition: HcalDetId.h:157
constexpr int ieta() const
get the cell ieta
Definition: HcalDetId.h:155
bool getSpigotPresent(unsigned int nspigot) const
Read the &quot;PRESENT&quot; bit for this spigot.
MonitorElement * hiDistrMB2Pl2D_
bool isValid() const
Definition: HandleBase.h:70
MonitorElement * hiDistrNoise2Min2D_
const_iterator end() const
Definition: DetId.h:17
T const * product() const
Definition: Handle.h:70
MonitorElement * hiDistrMBMin2D_
edm::EDGetTokenT< HFRecHitCollection > hfrecoMB
static const int SPIGOT_COUNT
Definition: HcalDCCHeader.h:19
size_type size() const
const unsigned char * data() const
Return a const pointer to the beginning of the data buffer.
Definition: FEDRawData.cc:24
MonitorElement * hiDistrNoise2Pl2D_
MonitorElement * hiDistrNoiseMin2D_
uint32_t lvl1ID() const
Level-1 event number generated by the TTC system.
Definition: FEDHeader.cc:15
constexpr int depth() const
get the tower depth
Definition: HcalDetId.h:164
edm::EDGetTokenT< HBHERecHitCollection > hbherecoMB
object to monitor
Power< A, B >::type pow(const A &a, const B &b)
Definition: Power.h:29
const_iterator begin() const
MonitorElement * hiDistrHBHEsize1D_
MonitorElement * hiDistrMB2Min2D_
#define LogDebug(id)
void DQMHcalPhiSymAlCaReco::bookHistograms ( DQMStore::IBooker ibooker,
edm::Run const &  irun,
edm::EventSetup const &  isetup 
)
overrideprotectedvirtual

Implements DQMOneEDAnalyzer<>.

Definition at line 163 of file DQMHcalPhiSymAlCaReco.cc.

References dqm::implementation::IBooker::book1D(), dqm::implementation::IBooker::book2D(), eventCounter_, folderName_, hFEDsize, hHcalIsZS, hiDistr_r_nbin_, hiDistr_x_max_, hiDistr_x_min_, hiDistr_x_nbin_, hiDistr_y_max_, hiDistr_y_min_, hiDistr_y_nbin_, hiDistrHBHEsize1D_, hiDistrHFsize1D_, hiDistrMB2Min2D_, hiDistrMB2Pl2D_, hiDistrMBMin2D_, hiDistrMBPl2D_, hiDistrNoise2Min2D_, hiDistrNoise2Pl2D_, hiDistrNoiseMin2D_, hiDistrNoisePl2D_, hiDistrVarMBMin2D_, hiDistrVarMBPl2D_, hiDistrVarNoiseMin2D_, hiDistrVarNoisePl2D_, hL1Id, period_, dqm::impl::MonitorElement::setAxisTitle(), dqm::impl::MonitorElement::setBinLabel(), dqm::implementation::NavigatorBase::setCurrentFolder(), hlt_dqm_clientPB-live_cfg::xmax, and hlt_dqm_clientPB-live_cfg::xmin.

165  {
166  // create and cd into new folder
167  ibooker.setCurrentFolder(folderName_);
168 
169  eventCounter_ = 0;
170 
171  hFEDsize = ibooker.book1D("hFEDsize", "HCAL FED size (kB)", 200, -0.5, 20.5);
172  hFEDsize->setAxisTitle("kB", 1);
173 
174  hHcalIsZS = ibooker.book1D("hHcalIsZS", "Hcal Is ZS", 4, -1.5, 2.5);
175  hHcalIsZS->setBinLabel(2, "NZS");
176  hHcalIsZS->setBinLabel(3, "ZS");
177 
178  char hname[50];
179  sprintf(hname, "L1 Event Number %% %i", period_);
180  hL1Id = ibooker.book1D("hL1Id", hname, 4200, -99.5, 4099.5);
181  hL1Id->setAxisTitle(hname);
182 
183  // book some histograms 1D
184  double xmin = 0.1;
185  double xmax = 1.1;
186  hiDistrHBHEsize1D_ = ibooker.book1D("DistrHBHEsize", "Size of HBHE Collection", hiDistr_r_nbin_, xmin, xmax);
187  hiDistrHFsize1D_ = ibooker.book1D("DistrHFsize", "Size of HF Collection", hiDistr_r_nbin_, xmin, xmax);
188 
189  // First moment
190  hiDistrMBPl2D_ = ibooker.book2D("MBdepthPl1",
191  "iphi- +ieta signal distribution at depth1",
198 
199  hiDistrMBPl2D_->setAxisTitle("i#phi ", 2);
200  hiDistrMBPl2D_->setAxisTitle("i#eta ", 1);
201 
202  hiDistrNoisePl2D_ = ibooker.book2D("NoisedepthPl1",
203  "iphi-ieta noise distribution at depth1",
204  hiDistr_x_nbin_ + 1,
205  hiDistr_x_min_ - 1.,
207  hiDistr_y_nbin_ + 1,
208  hiDistr_y_min_ - 1.,
210 
211  hiDistrNoisePl2D_->setAxisTitle("i#phi ", 2);
212  hiDistrNoisePl2D_->setAxisTitle("i#eta ", 1);
213  // Second moment
214  hiDistrMB2Pl2D_ = ibooker.book2D("MB2depthPl1",
215  "iphi- +ieta signal distribution at depth1",
222 
223  hiDistrMB2Pl2D_->setAxisTitle("i#phi ", 2);
224  hiDistrMB2Pl2D_->setAxisTitle("i#eta ", 1);
225 
226  hiDistrNoise2Pl2D_ = ibooker.book2D("Noise2depthPl1",
227  "iphi-ieta noise distribution at depth1",
234 
235  hiDistrNoise2Pl2D_->setAxisTitle("i#phi ", 2);
236  hiDistrNoise2Pl2D_->setAxisTitle("i#eta ", 1);
237 
238  // Variance
239  hiDistrVarMBPl2D_ = ibooker.book2D("VarMBdepthPl1",
240  "iphi- +ieta signal distribution at depth1",
247 
248  hiDistrVarMBPl2D_->setAxisTitle("i#phi ", 2);
249  hiDistrVarMBPl2D_->setAxisTitle("i#eta ", 1);
250 
251  hiDistrVarNoisePl2D_ = ibooker.book2D("VarNoisedepthPl1",
252  "iphi-ieta noise distribution at depth1",
259 
260  hiDistrVarNoisePl2D_->setAxisTitle("i#phi ", 2);
261  hiDistrVarNoisePl2D_->setAxisTitle("i#eta ", 1);
262 
263  //==================================================================================
264  // First moment
265  hiDistrMBMin2D_ = ibooker.book2D("MBdepthMin1",
266  "iphi- +ieta signal distribution at depth1",
273 
274  hiDistrMBMin2D_->setAxisTitle("i#phi ", 2);
275  hiDistrMBMin2D_->setAxisTitle("i#eta ", 1);
276 
277  hiDistrNoiseMin2D_ = ibooker.book2D("NoisedepthMin1",
278  "iphi-ieta noise distribution at depth1",
285 
286  hiDistrNoiseMin2D_->setAxisTitle("i#phi ", 2);
287  hiDistrNoiseMin2D_->setAxisTitle("i#eta ", 1);
288  // Second moment
289  hiDistrMB2Min2D_ = ibooker.book2D("MB2depthMin1",
290  "iphi- +ieta signal distribution at depth1",
297 
298  hiDistrMB2Min2D_->setAxisTitle("i#phi ", 2);
299  hiDistrMB2Min2D_->setAxisTitle("i#eta ", 1);
300 
301  hiDistrNoise2Min2D_ = ibooker.book2D("Noise2depthMin1",
302  "iphi-ieta noise distribution at depth1",
309 
310  hiDistrNoise2Min2D_->setAxisTitle("i#phi ", 2);
311  hiDistrNoise2Min2D_->setAxisTitle("i#eta ", 1);
312 
313  // Variance
314  hiDistrVarMBMin2D_ = ibooker.book2D("VarMBdepthMin1",
315  "iphi- +ieta signal distribution at depth1",
322 
323  hiDistrVarMBMin2D_->setAxisTitle("i#phi ", 2);
324  hiDistrVarMBMin2D_->setAxisTitle("i#eta ", 1);
325 
326  hiDistrVarNoiseMin2D_ = ibooker.book2D("VarNoisedepthMin1",
327  "iphi-ieta noise distribution at depth1",
334 
335  hiDistrVarNoiseMin2D_->setAxisTitle("i#phi ", 2);
336  hiDistrVarNoiseMin2D_->setAxisTitle("i#eta ", 1);
337 }
MonitorElement * hiDistrNoisePl2D_
MonitorElement * hiDistrVarMBPl2D_
MonitorElement * hiDistrVarNoiseMin2D_
virtual void setCurrentFolder(std::string const &fullpath)
Definition: DQMStore.cc:32
MonitorElement * hiDistrMBPl2D_
MonitorElement * hiDistrHFsize1D_
MonitorElement * hiDistrVarMBMin2D_
MonitorElement * hiDistrVarNoisePl2D_
std::string folderName_
DQM folder name.
MonitorElement * hiDistrMB2Pl2D_
virtual void setBinLabel(int bin, const std::string &label, int axis=1)
set bin label for x, y or z axis (axis=1, 2, 3 respectively)
MonitorElement * hiDistrNoise2Min2D_
MonitorElement * hiDistrMBMin2D_
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 * hiDistrNoise2Pl2D_
MonitorElement * hiDistrNoiseMin2D_
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 * hiDistrHBHEsize1D_
MonitorElement * hiDistrMB2Min2D_
virtual void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)
void DQMHcalPhiSymAlCaReco::dqmEndRun ( const edm::Run r,
const edm::EventSetup c 
)
overrideprotectedvirtual

Reimplemented from DQMOneEDAnalyzer<>.

Definition at line 522 of file DQMHcalPhiSymAlCaReco.cc.

References eventCounter_, dqm::impl::MonitorElement::getBinContent(), hiDistr_x_nbin_, hiDistr_y_nbin_, hiDistrMB2Min2D_, hiDistrMB2Pl2D_, hiDistrMBMin2D_, hiDistrMBPl2D_, hiDistrNoise2Min2D_, hiDistrNoise2Pl2D_, hiDistrNoiseMin2D_, hiDistrNoisePl2D_, hiDistrVarMBMin2D_, hiDistrVarMBPl2D_, hiDistrVarNoiseMin2D_, hiDistrVarNoisePl2D_, dqmiolumiharvest::j, isotrackApplyRegressor::k, perLSsaving_, and dqm::impl::MonitorElement::setBinContent().

522  {
523  // Keep Variances
524  if (eventCounter_ > 0 && !perLSsaving_) {
525  for (int k = 0; k <= hiDistr_x_nbin_; k++) {
526  for (int j = 0; j <= hiDistr_y_nbin_; j++) {
527  // First moment
528  float cc1 = hiDistrMBPl2D_->getBinContent(k, j);
529  cc1 = cc1 * 1. / eventCounter_;
530  float cc2 = hiDistrNoisePl2D_->getBinContent(k, j);
531  cc2 = cc2 * 1. / eventCounter_;
532  float cc3 = hiDistrMBMin2D_->getBinContent(k, j);
533  cc3 = cc3 * 1. / eventCounter_;
534  float cc4 = hiDistrNoiseMin2D_->getBinContent(k, j);
535  cc4 = cc4 * 1. / eventCounter_;
536  // Second moment
537  float cc11 = hiDistrMB2Pl2D_->getBinContent(k, j);
538  cc11 = cc11 * 1. / eventCounter_;
539  hiDistrVarMBPl2D_->setBinContent(k, j, cc11 - cc1 * cc1);
540  float cc22 = hiDistrNoise2Pl2D_->getBinContent(k, j);
541  cc22 = cc22 * 1. / eventCounter_;
542  hiDistrVarNoisePl2D_->setBinContent(k, j, cc22 - cc2 * cc2);
543  float cc33 = hiDistrMB2Min2D_->getBinContent(k, j);
544  cc33 = cc33 * 1. / eventCounter_;
545  hiDistrVarMBMin2D_->setBinContent(k, j, cc33 - cc3 * cc3);
546  float cc44 = hiDistrNoise2Min2D_->getBinContent(k, j);
547  cc44 = cc44 * 1. / eventCounter_;
548  hiDistrVarNoiseMin2D_->setBinContent(k, j, cc44 - cc4 * cc4);
549  }
550  }
551  }
552 }
MonitorElement * hiDistrNoisePl2D_
MonitorElement * hiDistrVarMBPl2D_
MonitorElement * hiDistrVarNoiseMin2D_
MonitorElement * hiDistrMBPl2D_
MonitorElement * hiDistrVarMBMin2D_
MonitorElement * hiDistrVarNoisePl2D_
MonitorElement * hiDistrMB2Pl2D_
virtual double getBinContent(int binx) const
get content of bin (1-D)
MonitorElement * hiDistrNoise2Min2D_
virtual void setBinContent(int binx, double content)
set content of bin (1-D)
MonitorElement * hiDistrMBMin2D_
MonitorElement * hiDistrNoise2Pl2D_
MonitorElement * hiDistrNoiseMin2D_
MonitorElement * hiDistrMB2Min2D_

Member Data Documentation

int DQMHcalPhiSymAlCaReco::eventCounter_
private

Definition at line 53 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), bookHistograms(), and dqmEndRun().

std::string DQMHcalPhiSymAlCaReco::fileName_
private

Output file name if required.

Definition at line 115 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by DQMHcalPhiSymAlCaReco().

std::string DQMHcalPhiSymAlCaReco::folderName_
private

DQM folder name.

Definition at line 106 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by bookHistograms(), and DQMHcalPhiSymAlCaReco().

edm::EDGetTokenT<HBHERecHitCollection> DQMHcalPhiSymAlCaReco::hbherecoMB
private

object to monitor

Definition at line 95 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), and DQMHcalPhiSymAlCaReco().

edm::EDGetTokenT<HBHERecHitCollection> DQMHcalPhiSymAlCaReco::hbherecoNoise
private

Definition at line 99 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), and DQMHcalPhiSymAlCaReco().

MonitorElement* DQMHcalPhiSymAlCaReco::hFEDsize
private

Definition at line 76 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), and bookHistograms().

edm::EDGetTokenT<HFRecHitCollection> DQMHcalPhiSymAlCaReco::hfrecoMB
private

Definition at line 97 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), and DQMHcalPhiSymAlCaReco().

edm::EDGetTokenT<HFRecHitCollection> DQMHcalPhiSymAlCaReco::hfrecoNoise
private

Definition at line 101 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), and DQMHcalPhiSymAlCaReco().

MonitorElement* DQMHcalPhiSymAlCaReco::hHcalIsZS
private

Definition at line 77 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), and bookHistograms().

int DQMHcalPhiSymAlCaReco::hiDistr_r_nbin_
private

Definition at line 87 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by bookHistograms(), and DQMHcalPhiSymAlCaReco().

double DQMHcalPhiSymAlCaReco::hiDistr_x_max_
private

Definition at line 85 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by bookHistograms(), and DQMHcalPhiSymAlCaReco().

double DQMHcalPhiSymAlCaReco::hiDistr_x_min_
private

Definition at line 84 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by bookHistograms(), and DQMHcalPhiSymAlCaReco().

int DQMHcalPhiSymAlCaReco::hiDistr_x_nbin_
private

Definition at line 81 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by bookHistograms(), dqmEndRun(), and DQMHcalPhiSymAlCaReco().

double DQMHcalPhiSymAlCaReco::hiDistr_y_max_
private

Definition at line 83 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by bookHistograms(), and DQMHcalPhiSymAlCaReco().

double DQMHcalPhiSymAlCaReco::hiDistr_y_min_
private

Definition at line 82 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by bookHistograms(), and DQMHcalPhiSymAlCaReco().

int DQMHcalPhiSymAlCaReco::hiDistr_y_nbin_
private

Definition at line 80 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by bookHistograms(), dqmEndRun(), and DQMHcalPhiSymAlCaReco().

MonitorElement* DQMHcalPhiSymAlCaReco::hiDistrHBHEsize1D_
private

Definition at line 73 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), and bookHistograms().

MonitorElement* DQMHcalPhiSymAlCaReco::hiDistrHFsize1D_
private

Definition at line 74 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), and bookHistograms().

MonitorElement* DQMHcalPhiSymAlCaReco::hiDistrMB2Min2D_
private

Definition at line 65 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), bookHistograms(), and dqmEndRun().

MonitorElement* DQMHcalPhiSymAlCaReco::hiDistrMB2Pl2D_
private

Definition at line 63 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), bookHistograms(), and dqmEndRun().

MonitorElement* DQMHcalPhiSymAlCaReco::hiDistrMBMin2D_
private

Definition at line 60 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), bookHistograms(), and dqmEndRun().

MonitorElement* DQMHcalPhiSymAlCaReco::hiDistrMBPl2D_
private

Definition at line 58 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), bookHistograms(), and dqmEndRun().

MonitorElement* DQMHcalPhiSymAlCaReco::hiDistrNoise2Min2D_
private

Definition at line 66 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), bookHistograms(), and dqmEndRun().

MonitorElement* DQMHcalPhiSymAlCaReco::hiDistrNoise2Pl2D_
private

Definition at line 64 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), bookHistograms(), and dqmEndRun().

MonitorElement* DQMHcalPhiSymAlCaReco::hiDistrNoiseMin2D_
private

Definition at line 61 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), bookHistograms(), and dqmEndRun().

MonitorElement* DQMHcalPhiSymAlCaReco::hiDistrNoisePl2D_
private

Definition at line 59 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), bookHistograms(), and dqmEndRun().

MonitorElement* DQMHcalPhiSymAlCaReco::hiDistrVarMBMin2D_
private

Definition at line 70 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by bookHistograms(), and dqmEndRun().

MonitorElement* DQMHcalPhiSymAlCaReco::hiDistrVarMBPl2D_
private

Definition at line 68 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by bookHistograms(), and dqmEndRun().

MonitorElement* DQMHcalPhiSymAlCaReco::hiDistrVarNoiseMin2D_
private

Definition at line 71 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by bookHistograms(), and dqmEndRun().

MonitorElement* DQMHcalPhiSymAlCaReco::hiDistrVarNoisePl2D_
private

Definition at line 69 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by bookHistograms(), and dqmEndRun().

MonitorElement* DQMHcalPhiSymAlCaReco::hL1Id
private

Definition at line 78 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), and bookHistograms().

edm::InputTag DQMHcalPhiSymAlCaReco::horecoMB
private

Definition at line 96 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by DQMHcalPhiSymAlCaReco().

edm::InputTag DQMHcalPhiSymAlCaReco::horecoNoise
private

Definition at line 100 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by DQMHcalPhiSymAlCaReco().

double DQMHcalPhiSymAlCaReco::ihbhe_size_
private

Definition at line 88 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), and DQMHcalPhiSymAlCaReco().

double DQMHcalPhiSymAlCaReco::ihf_size_
private

Definition at line 89 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), and DQMHcalPhiSymAlCaReco().

unsigned int DQMHcalPhiSymAlCaReco::period_
private

Definition at line 112 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), bookHistograms(), and DQMHcalPhiSymAlCaReco().

bool DQMHcalPhiSymAlCaReco::perLSsaving_
private

Definition at line 91 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by dqmEndRun(), and DQMHcalPhiSymAlCaReco().

edm::EDGetTokenT<FEDRawDataCollection> DQMHcalPhiSymAlCaReco::rawInLabel_
private

Definition at line 103 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by analyze(), and DQMHcalPhiSymAlCaReco().

bool DQMHcalPhiSymAlCaReco::saveToFile_
private

Write to file.

Definition at line 109 of file DQMHcalPhiSymAlCaReco.cc.

Referenced by DQMHcalPhiSymAlCaReco().