CMS 3D CMS Logo

List of all members | Public Member Functions | Protected Member Functions | Protected Attributes
UMNioTask Class Reference

#include <UMNioTask.h>

Inheritance diagram for UMNioTask:
hcaldqm::DQTask DQMEDAnalyzer hcaldqm::DQModule edm::stream::EDAnalyzer< edm::RunSummaryCache< dqmDetails::NoCache >, edm::LuminosityBlockSummaryCache< dqmDetails::NoCache > > edm::stream::EDAnalyzerBase edm::EDConsumerBase

Public Member Functions

virtual void bookHistograms (DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &)
 
virtual void endLuminosityBlock (edm::LuminosityBlock const &, edm::EventSetup const &)
 
virtual void endRun (edm::Run const &r, edm::EventSetup const &)
 
 UMNioTask (edm::ParameterSet const &)
 
virtual ~UMNioTask ()
 
- Public Member Functions inherited from hcaldqm::DQTask
virtual void analyze (edm::Event const &, edm::EventSetup const &)
 
virtual void beginLuminosityBlock (edm::LuminosityBlock const &, edm::EventSetup const &)
 
virtual void dqmBeginRun (edm::Run const &, edm::EventSetup const &)
 
 DQTask (edm::ParameterSet const &)
 
virtual ~DQTask ()
 
- Public Member Functions inherited from DQMEDAnalyzer
virtual void beginRun (edm::Run const &, edm::EventSetup const &) final
 
virtual void beginStream (edm::StreamID id) final
 
 DQMEDAnalyzer (void)
 
virtual void endLuminosityBlockSummary (edm::LuminosityBlock const &, edm::EventSetup const &, dqmDetails::NoCache *) const final
 
virtual void endRunSummary (edm::Run const &, edm::EventSetup const &, dqmDetails::NoCache *) const final
 
uint32_t streamId () const
 
- Public Member Functions inherited from edm::stream::EDAnalyzer< edm::RunSummaryCache< dqmDetails::NoCache >, edm::LuminosityBlockSummaryCache< dqmDetails::NoCache > >
 EDAnalyzer ()=default
 
- Public Member Functions inherited from edm::stream::EDAnalyzerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzerBase ()
 
ModuleDescription const & moduleDescription () const
 
virtual ~EDAnalyzerBase ()
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
 EDConsumerBase ()
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
 EDConsumerBase (EDConsumerBase &&)=default
 
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 & itemsToGetFromEvent () const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, 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 updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
virtual ~EDConsumerBase () noexcept(false)
 
- Public Member Functions inherited from hcaldqm::DQModule
 DQModule (edm::ParameterSet const &)
 
virtual ~DQModule ()(false)
 

Protected Member Functions

virtual void _process (edm::Event const &, edm::EventSetup const &)
 
- Protected Member Functions inherited from hcaldqm::DQTask
virtual int _getCalibType (edm::Event const &)
 
virtual bool _isApplicable (edm::Event const &)
 
virtual void _resetMonitors (UpdateFreq)
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
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 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)
 

Protected Attributes

hcaldqm::ContainerSingle2D _cEventType
 
hcaldqm::ContainerSingle2D _cTotalCharge
 
hcaldqm::ContainerSingleProf2D _cTotalChargeProfile
 
hcaldqm::electronicsmap::ElectronicsMap _ehashmap
 
HcalElectronicsMap const * _emap
 
std::vector< uint32_t > _eventtypes
 
hcaldqm::filter::HashFilter _filter_uTCA
 
hcaldqm::filter::HashFilter _filter_VME
 
double _lowHBHE
 
double _lowHF
 
double _lowHO
 
edm::InputTag _tagHBHE
 
edm::InputTag _tagHF
 
edm::InputTag _tagHO
 
edm::InputTag _taguMN
 
edm::EDGetTokenT< HBHEDigiCollection_tokHBHE
 
edm::EDGetTokenT< HFDigiCollection_tokHF
 
edm::EDGetTokenT< HODigiCollection_tokHO
 
edm::EDGetTokenT< HcalUMNioDigi_tokuMN
 
- Protected Attributes inherited from hcaldqm::DQTask
ContainerI _cEvsPerLS
 
ContainerI _cEvsTotal
 
ContainerS _cProcessingTypeName
 
ContainerS _cRunKeyName
 
ContainerI _cRunKeyVal
 
int _procLSs
 
edm::InputTag _tagRaw
 
edm::EDGetTokenT< FEDRawDataCollection_tokRaw
 
std::vector< uint32_t > _vcdaqEids
 
ContainerXXX< uint32_t > _xQuality
 
- Protected Attributes inherited from hcaldqm::DQModule
int _currentLS
 
int _debug
 
int _evsPerLS
 
int _evsTotal
 
Logger _logger
 
int _maxLS
 
ModuleType _mtype
 
std::string _name
 
ProcessingType _ptype
 
std::string _runkeyName
 
int _runkeyVal
 
std::string _subsystem
 

Additional Inherited Members

- Public Types inherited from edm::stream::EDAnalyzer< edm::RunSummaryCache< dqmDetails::NoCache >, edm::LuminosityBlockSummaryCache< dqmDetails::NoCache > >
typedef CacheContexts< T... > CacheTypes
 
typedef CacheTypes::GlobalCache GlobalCache
 
typedef AbilityChecker< T... > HasAbility
 
typedef CacheTypes::LuminosityBlockCache LuminosityBlockCache
 
typedef LuminosityBlockContextT< LuminosityBlockCache, RunCache, GlobalCacheLuminosityBlockContext
 
typedef CacheTypes::LuminosityBlockSummaryCache LuminosityBlockSummaryCache
 
typedef CacheTypes::RunCache RunCache
 
typedef RunContextT< RunCache, GlobalCacheRunContext
 
typedef CacheTypes::RunSummaryCache RunSummaryCache
 
- Public Types inherited from edm::stream::EDAnalyzerBase
typedef EDAnalyzerAdaptorBase ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from DQMEDAnalyzer
static std::shared_ptr< dqmDetails::NoCacheglobalBeginLuminosityBlockSummary (edm::LuminosityBlock const &, edm::EventSetup const &, LuminosityBlockContext const *)
 
static std::shared_ptr< dqmDetails::NoCacheglobalBeginRunSummary (edm::Run const &, edm::EventSetup const &, RunContext const *)
 
static void globalEndLuminosityBlockSummary (edm::LuminosityBlock const &, edm::EventSetup const &, LuminosityBlockContext const *, dqmDetails::NoCache *)
 
static void globalEndRunSummary (edm::Run const &, edm::EventSetup const &, RunContext const *, dqmDetails::NoCache *)
 
- Static Public Member Functions inherited from edm::stream::EDAnalyzerBase
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 

Detailed Description

Definition at line 22 of file UMNioTask.h.

Constructor & Destructor Documentation

UMNioTask::UMNioTask ( edm::ParameterSet const &  ps)

Definition at line 6 of file UMNioTask.cc.

References _eventtypes, _lowHBHE, _lowHF, _lowHO, _tagHBHE, _tagHF, _tagHO, _taguMN, _tokHBHE, _tokHF, _tokHO, _tokuMN, edm::ParameterSet::getUntrackedParameter(), hcaldqm::constants::nOrbitGapType, and hcaldqm::constants::tNull.

6  :
7  DQTask(ps)
8 {
9  _tagHBHE = ps.getUntrackedParameter<edm::InputTag>("tagHBHE",
10  edm::InputTag("hcalDigis"));
11  _tagHO = ps.getUntrackedParameter<edm::InputTag>("tagHO",
12  edm::InputTag("hcalDigis"));
13  _tagHF = ps.getUntrackedParameter<edm::InputTag>("tagHF",
14  edm::InputTag("hcalDigis"));
15  _taguMN = ps.getUntrackedParameter<edm::InputTag>("taguMN",
16  edm::InputTag("hcalDigis"));
17 
18  _tokHBHE = consumes<HBHEDigiCollection>(_tagHBHE);
19  _tokHO = consumes<HODigiCollection>(_tagHO);
20  _tokHF = consumes<HFDigiCollection>(_tagHF);
21  _tokuMN = consumes<HcalUMNioDigi>(_taguMN);
22 
23  _lowHBHE = ps.getUntrackedParameter<double>("lowHBHE",
24  20);
25  _lowHO = ps.getUntrackedParameter<double>("lowHO",
26  20);
27  _lowHF = ps.getUntrackedParameter<double>("lowHF",
28  20);
29 
30  // push all the event types to monitor - whole range basically
32  _eventtypes.push_back(type);
33 }
edm::InputTag _tagHBHE
Definition: UMNioTask.h:50
edm::EDGetTokenT< HFDigiCollection > _tokHF
Definition: UMNioTask.h:55
type
Definition: HCALResponse.h:21
std::vector< uint32_t > _eventtypes
Definition: UMNioTask.h:46
DQTask(edm::ParameterSet const &)
Definition: DQTask.cc:7
edm::EDGetTokenT< HODigiCollection > _tokHO
Definition: UMNioTask.h:54
edm::EDGetTokenT< HcalUMNioDigi > _tokuMN
Definition: UMNioTask.h:56
edm::InputTag _tagHF
Definition: UMNioTask.h:52
double _lowHO
Definition: UMNioTask.h:59
edm::InputTag _taguMN
Definition: UMNioTask.h:49
edm::InputTag _tagHO
Definition: UMNioTask.h:51
double _lowHBHE
Definition: UMNioTask.h:59
edm::EDGetTokenT< HBHEDigiCollection > _tokHBHE
Definition: UMNioTask.h:53
double _lowHF
Definition: UMNioTask.h:59
virtual UMNioTask::~UMNioTask ( )
inlinevirtual

Definition at line 26 of file UMNioTask.h.

References bookHistograms().

27  {}

Member Function Documentation

void UMNioTask::_process ( edm::Event const &  e,
edm::EventSetup const &  es 
)
protectedvirtual

Implements hcaldqm::DQTask.

Definition at line 65 of file UMNioTask.cc.

References _cEventType, _cTotalCharge, _cTotalChargeProfile, hcaldqm::DQModule::_currentLS, hcaldqm::DQModule::_logger, _tagHBHE, _tagHF, _tagHO, _tokHBHE, _tokHF, _tokHO, _tokuMN, edm::SortedCollection< T, SORT >::begin(), Logger::dqmthrow(), edm::SortedCollection< T, SORT >::end(), HcalUMNioDigi::eventType(), hcaldqm::constants::EVENTTYPE_PEDESTAL, hcaldqm::ContainerSingle2D::fill(), edm::Event::getByToken(), edm::InputTag::instance(), edm::InputTag::label(), hcaldqm::utilities::sumQ(), and HcalUMNioDigi::valueUserWord().

Referenced by endRun().

67 {
69  if (!e.getByToken(_tokuMN, cumn))
70  return;
71 
72  uint8_t eventType = cumn->eventType();
73  uint32_t laserType = cumn->valueUserWord(0);
75  (int)eventType : (int)laserType);
76 
77  // Compute the Total Charge in the Detector...
81 
82  if (!e.getByToken(_tokHBHE, chbhe))
83  _logger.dqmthrow("Collection HBHEDigiCollection isn't available "
84  + _tagHBHE.label() + " " + _tagHBHE.instance());
85  if (!e.getByToken(_tokHO, cho))
86  _logger.dqmthrow("Collection HODigiCollection isn't available "
87  + _tagHO.label() + " " + _tagHO.instance());
88  if (!e.getByToken(_tokHF, chf))
89  _logger.dqmthrow("Collection HFDigiCollection isn't available "
90  + _tagHF.label() + " " + _tagHF.instance());
91 
93  it!=chbhe->end(); ++it)
94  {
95  double sumQ = hcaldqm::utilities::sumQ<HBHEDataFrame>(*it, 2.5, 0, it->size()-1);
96  _cTotalCharge.fill(it->id(), _currentLS, sumQ);
98  }
100  it!=cho->end(); ++it)
101  {
102  double sumQ = hcaldqm::utilities::sumQ<HODataFrame>(*it, 8.5, 0, it->size()-1);
103  _cTotalCharge.fill(it->id(), _currentLS, sumQ);
105  }
107  it!=chf->end(); ++it)
108  {
109  double sumQ = hcaldqm::utilities::sumQ<HFDataFrame>(*it, 2.5, 0, it->size()-1);
110  _cTotalCharge.fill(it->id(), _currentLS, sumQ);
112  }
113 }
edm::InputTag _tagHBHE
Definition: UMNioTask.h:50
edm::EDGetTokenT< HFDigiCollection > _tokHF
Definition: UMNioTask.h:55
edm::EDGetTokenT< HODigiCollection > _tokHO
Definition: UMNioTask.h:54
edm::EDGetTokenT< HcalUMNioDigi > _tokuMN
Definition: UMNioTask.h:56
std::vector< HBHEDataFrame >::const_iterator const_iterator
edm::InputTag _tagHF
Definition: UMNioTask.h:52
hcaldqm::ContainerSingleProf2D _cTotalChargeProfile
Definition: UMNioTask.h:70
void dqmthrow(std::string const &msg) const
Definition: Logger.h:15
uint32_t valueUserWord(int iword) const
uint8_t eventType() const
Logger _logger
Definition: DQModule.h:70
edm::InputTag _tagHO
Definition: UMNioTask.h:51
const_iterator end() const
std::string const & label() const
Definition: InputTag.h:36
uint8_t const EVENTTYPE_PEDESTAL
Definition: Constants.h:273
edm::EDGetTokenT< HBHEDigiCollection > _tokHBHE
Definition: UMNioTask.h:53
hcaldqm::ContainerSingle2D _cTotalCharge
Definition: UMNioTask.h:69
virtual void fill(int, int)
hcaldqm::ContainerSingle2D _cEventType
Definition: UMNioTask.h:68
std::string const & instance() const
Definition: InputTag.h:37
const_iterator begin() const
double sumQ(DIGI const &digi, double ped, int i=0, int j=3)
Definition: Utilities.h:79
void UMNioTask::bookHistograms ( DQMStore::IBooker ib,
edm::Run const &  r,
edm::EventSetup const &  es 
)
virtual

Reimplemented from hcaldqm::DQTask.

Definition at line 35 of file UMNioTask.cc.

References _cEventType, _cTotalCharge, _cTotalChargeProfile, _emap, _eventtypes, hcaldqm::DQModule::_maxLS, hcaldqm::DQModule::_name, hcaldqm::DQModule::_ptype, hcaldqm::DQModule::_subsystem, hcaldqm::ContainerSingleProf2D::book(), hcaldqm::ContainerSingle2D::book(), bookHistograms(), hcaldqm::quantity::ffC_10000, hcaldqm::fLocal, hcaldqm::quantity::fN, hcaldqm::quantity::fSubdetPM, edm::EventSetup::get(), HcalDbService::getHcalMapping(), hcaldqm::ContainerSingleProf2D::initialize(), hcaldqm::ContainerSingle2D::initialize(), edm::RunAuxiliary::run(), and edm::Run::runAuxiliary().

Referenced by ~UMNioTask().

37 {
38  if (_ptype==fLocal)
39  if (r.runAuxiliary().run()==1)
40  return;
41 
42  DQTask::bookHistograms(ib, r, es);
43 
45  es.get<HcalDbRecord>().get(dbService);
46  _emap = dbService->getHcalMapping();
47 
48  _cEventType.initialize(_name, "EventType",
52  _cTotalCharge.initialize(_name, "TotalCharge",
56  _cTotalChargeProfile.initialize(_name, "TotalChargeProfile",
63 }
std::vector< uint32_t > _eventtypes
Definition: UMNioTask.h:46
virtual void book(DQMStore::IBooker &, std::string subsystem="Hcal", std::string aux="")
hcaldqm::ContainerSingleProf2D _cTotalChargeProfile
Definition: UMNioTask.h:70
void bookHistograms(fwlite::EventContainer &eventCont)
virtual void initialize(std::string const &folder, Quantity *, Quantity *, Quantity *qz=new ValueQuantity(quantity::fN), int debug=0)
virtual void book(DQMStore::IBooker &, std::string subsystem="Hcal", std::string aux="")
ProcessingType _ptype
Definition: DQModule.h:59
std::string _name
Definition: DQModule.h:57
virtual void initialize(std::string const &folder, Quantity *, Quantity *, Quantity *qz=new ValueQuantity(quantity::fN), int debug=0)
const HcalElectronicsMap * getHcalMapping() const
std::string _subsystem
Definition: DQModule.h:64
hcaldqm::ContainerSingle2D _cTotalCharge
Definition: UMNioTask.h:69
HcalElectronicsMap const * _emap
Definition: UMNioTask.h:62
hcaldqm::ContainerSingle2D _cEventType
Definition: UMNioTask.h:68
void UMNioTask::endLuminosityBlock ( edm::LuminosityBlock const &  lb,
edm::EventSetup const &  es 
)
virtual

Reimplemented from hcaldqm::DQTask.

Definition at line 114 of file UMNioTask.cc.

References DEFINE_FWK_MODULE.

Referenced by endRun().

116 {
117  DQTask::endLuminosityBlock(lb, es);
118 }
virtual void UMNioTask::endRun ( edm::Run const &  r,
edm::EventSetup const &   
)
inlinevirtual

Reimplemented from edm::stream::EDAnalyzerBase.

Definition at line 31 of file UMNioTask.h.

References _process(), hcaldqm::DQModule::_ptype, endLuminosityBlock(), hcaldqm::fLocal, edm::RunAuxiliary::run(), and edm::Run::runAuxiliary().

32  {
34  {
35  if (r.runAuxiliary().run()==1)
36  return;
37  }
38  }
ProcessingType _ptype
Definition: DQModule.h:59

Member Data Documentation

hcaldqm::ContainerSingle2D UMNioTask::_cEventType
protected

Definition at line 68 of file UMNioTask.h.

Referenced by _process(), and bookHistograms().

hcaldqm::ContainerSingle2D UMNioTask::_cTotalCharge
protected

Definition at line 69 of file UMNioTask.h.

Referenced by _process(), and bookHistograms().

hcaldqm::ContainerSingleProf2D UMNioTask::_cTotalChargeProfile
protected

Definition at line 70 of file UMNioTask.h.

Referenced by _process(), and bookHistograms().

hcaldqm::electronicsmap::ElectronicsMap UMNioTask::_ehashmap
protected

Definition at line 63 of file UMNioTask.h.

HcalElectronicsMap const* UMNioTask::_emap
protected

Definition at line 62 of file UMNioTask.h.

Referenced by bookHistograms().

std::vector<uint32_t> UMNioTask::_eventtypes
protected

Definition at line 46 of file UMNioTask.h.

Referenced by bookHistograms(), and UMNioTask().

hcaldqm::filter::HashFilter UMNioTask::_filter_uTCA
protected

Definition at line 64 of file UMNioTask.h.

hcaldqm::filter::HashFilter UMNioTask::_filter_VME
protected

Definition at line 65 of file UMNioTask.h.

double UMNioTask::_lowHBHE
protected

Definition at line 59 of file UMNioTask.h.

Referenced by UMNioTask().

double UMNioTask::_lowHF
protected

Definition at line 59 of file UMNioTask.h.

Referenced by UMNioTask().

double UMNioTask::_lowHO
protected

Definition at line 59 of file UMNioTask.h.

Referenced by UMNioTask().

edm::InputTag UMNioTask::_tagHBHE
protected

Definition at line 50 of file UMNioTask.h.

Referenced by _process(), and UMNioTask().

edm::InputTag UMNioTask::_tagHF
protected

Definition at line 52 of file UMNioTask.h.

Referenced by _process(), and UMNioTask().

edm::InputTag UMNioTask::_tagHO
protected

Definition at line 51 of file UMNioTask.h.

Referenced by _process(), and UMNioTask().

edm::InputTag UMNioTask::_taguMN
protected

Definition at line 49 of file UMNioTask.h.

Referenced by UMNioTask().

edm::EDGetTokenT<HBHEDigiCollection> UMNioTask::_tokHBHE
protected

Definition at line 53 of file UMNioTask.h.

Referenced by _process(), and UMNioTask().

edm::EDGetTokenT<HFDigiCollection> UMNioTask::_tokHF
protected

Definition at line 55 of file UMNioTask.h.

Referenced by _process(), and UMNioTask().

edm::EDGetTokenT<HODigiCollection> UMNioTask::_tokHO
protected

Definition at line 54 of file UMNioTask.h.

Referenced by _process(), and UMNioTask().

edm::EDGetTokenT<HcalUMNioDigi> UMNioTask::_tokuMN
protected

Definition at line 56 of file UMNioTask.h.

Referenced by _process(), and UMNioTask().