CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Protected Member Functions | Protected Attributes
DQMGlobalEDAnalyzerBase< H, Args > Class Template Referenceabstract

#include <DQMGlobalEDAnalyzer.h>

Inheritance diagram for DQMGlobalEDAnalyzerBase< H, Args >:
edm::global::EDProducer< edm::RunCache< H >, edm::EndRunProducer, edm::Accumulator, Args... > edm::global::EDProducerBase edm::ProducerBase edm::EDConsumerBase edm::ProductRegistryHelper

Public Types

typedef dqm::reco::DQMStore DQMStore
 
typedef dqm::reco::MonitorElement MonitorElement
 
- Public Types inherited from edm::global::EDProducerBase
typedef EDProducerBase ModuleType
 
- Public Types inherited from edm::ProducerBase
template<typename T >
using BranchAliasSetterT = ProductRegistryHelper::BranchAliasSetterT< T >
 
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
 

Public Member Functions

void accumulate (edm::StreamID id, edm::Event const &event, edm::EventSetup const &setup) const final
 
virtual void bookHistograms (DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &, H &) const =0
 
virtual void dqmAnalyze (edm::Event const &, edm::EventSetup const &, H const &) const =0
 
virtual void dqmBeginRun (edm::Run const &, edm::EventSetup const &, H &) const
 
 DQMGlobalEDAnalyzerBase ()
 
std::shared_ptr< H > globalBeginRun (edm::Run const &run, edm::EventSetup const &setup) const final
 
void globalEndRun (edm::Run const &, edm::EventSetup const &) const final
 
- Public Member Functions inherited from edm::global::EDProducer< edm::RunCache< H >, edm::EndRunProducer, edm::Accumulator, Args... >
 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
 
EDProduceroperator= (const EDProducer &)=delete
 
bool wantsGlobalLuminosityBlocks () const noexcept final
 
bool wantsGlobalRuns () const noexcept final
 
bool wantsInputProcessBlocks () const noexcept final
 
bool wantsProcessBlocks () const noexcept final
 
bool wantsStreamLuminosityBlocks () const noexcept final
 
bool wantsStreamRuns () const noexcept final
 
- Public Member Functions inherited from edm::global::EDProducerBase
 EDProducerBase ()
 
ModuleDescription const & moduleDescription () 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
 
std::vector< bool > const & recordProvenanceList () 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)
 
TypeLabelList const & typeLabelList () const
 used by the fwk to register the list of products of this module More...
 
 ~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
 
ESResolverIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
std::vector< ESResolverIndex > 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
 
void selectInputProcessBlocks (ProductRegistry const &productRegistry, ProcessBlockHelperBase const &processBlockHelperBase)
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProductResolverIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Protected Member Functions

uint64_t meId (edm::Run const &run) const
 
- Protected Member Functions inherited from edm::ProducerBase
template<Transition Tr = Transition::Event>
auto produces (std::string instanceName) noexcept
 declare what type of product will make and with which optional label More...
 
template<Transition B>
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
template<BranchType B>
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
template<typename ProductType , Transition B>
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
template<class ProductType >
BranchAliasSetterT< ProductType > produces ()
 
template<typename ProductType , BranchType B>
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
template<typename ProductType , BranchType B>
BranchAliasSetterT< ProductType > produces ()
 
template<class ProductType >
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
template<typename ProductType , Transition B>
BranchAliasSetterT< ProductType > produces ()
 
template<Transition Tr = Transition::Event>
auto produces () noexcept
 
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 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)
 

Protected Attributes

DQMStoredqmstore_
 
edm::EDPutTokenT< DQMTokenrunToken_
 

Additional Inherited Members

- Static Public Member Functions inherited from edm::global::EDProducerBase
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 

Detailed Description

template<typename H, typename... Args>
class DQMGlobalEDAnalyzerBase< H, Args >

Definition at line 13 of file DQMGlobalEDAnalyzer.h.

Member Typedef Documentation

◆ DQMStore

template<typename H, typename... Args>
typedef dqm::reco::DQMStore DQMGlobalEDAnalyzerBase< H, Args >::DQMStore

Definition at line 21 of file DQMGlobalEDAnalyzer.h.

◆ MonitorElement

template<typename H, typename... Args>
typedef dqm::reco::MonitorElement DQMGlobalEDAnalyzerBase< H, Args >::MonitorElement

Definition at line 22 of file DQMGlobalEDAnalyzer.h.

Constructor & Destructor Documentation

◆ DQMGlobalEDAnalyzerBase()

template<typename H, typename... Args>
DQMGlobalEDAnalyzerBase< H, Args >::DQMGlobalEDAnalyzerBase ( )
inline

Definition at line 25 of file DQMGlobalEDAnalyzer.h.

25  {
26  // for whatever reason we need the explicit `template` keyword here.
27  runToken_ = this->template produces<DQMToken, edm::Transition::EndRun>("DQMGenerationRecoRun");
29  }
edm::EDPutTokenT< DQMToken > runToken_

Member Function Documentation

◆ accumulate()

template<typename H, typename... Args>
void DQMGlobalEDAnalyzerBase< H, Args >::accumulate ( edm::StreamID  id,
edm::Event const &  event,
edm::EventSetup const &  setup 
) const
inlinefinal

Definition at line 53 of file DQMGlobalEDAnalyzer.h.

53  {
54  auto const& h = *this->runCache(event.getRun().index());
56  }
virtual void dqmAnalyze(edm::Event const &, edm::EventSetup const &, H const &) const =0
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
Definition: Activities.doc:4
Definition: event.py:1

◆ bookHistograms()

template<typename H, typename... Args>
virtual void DQMGlobalEDAnalyzerBase< H, Args >::bookHistograms ( DQMStore::IBooker ,
edm::Run const &  ,
edm::EventSetup const &  ,
H &   
) const
pure virtual

◆ dqmAnalyze()

template<typename H, typename... Args>
virtual void DQMGlobalEDAnalyzerBase< H, Args >::dqmAnalyze ( edm::Event const &  ,
edm::EventSetup const &  ,
H const &   
) const
pure virtual

◆ dqmBeginRun()

template<typename H, typename... Args>
virtual void DQMGlobalEDAnalyzerBase< H, Args >::dqmBeginRun ( edm::Run const &  ,
edm::EventSetup const &  ,
H &   
) const
inlinevirtual

◆ globalBeginRun()

template<typename H, typename... Args>
std::shared_ptr<H> DQMGlobalEDAnalyzerBase< H, Args >::globalBeginRun ( edm::Run const &  run,
edm::EventSetup const &  setup 
) const
inlinefinal

Definition at line 31 of file DQMGlobalEDAnalyzer.h.

31  {
32  auto h = std::make_shared<H>();
33 
34  dqmBeginRun(run, setup, *h);
35 
36  // in case of concurrent runs, this will create clones of the already
37  // booked MEs.
39  [&, this](DQMStore::IBooker& b) {
40  // this runs while holding the DQMStore lock
41  b.cd();
42  bookHistograms(b, run, setup, *h);
43  },
44  // The run number is part of the module ID here, since we want distinct
45  // local MEs for each run cache.
46  meId(run),
47  /* canSaveByLumi */ false);
48  dqmstore_->initLumi(run.run(), /* lumi */ 0, meId(run));
49  dqmstore_->enterLumi(run.run(), /* lumi */ 0, meId(run));
50  return h;
51  }
virtual void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &, H &) const =0
void bookTransaction(iFunc f, uint64_t moduleId, bool canSaveByLumi)
Definition: DQMStore.h:665
void initLumi(edm::RunNumber_t run, edm::LuminosityBlockNumber_t lumi)
Definition: DQMStore.cc:392
void enterLumi(edm::RunNumber_t run, edm::LuminosityBlockNumber_t lumi, uint64_t moduleID)
Definition: DQMStore.cc:480
double b
Definition: hdecay.h:120
virtual void dqmBeginRun(edm::Run const &, edm::EventSetup const &, H &) const
uint64_t meId(edm::Run const &run) const
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
Definition: Activities.doc:4

◆ globalEndRun()

template<typename H, typename... Args>
void DQMGlobalEDAnalyzerBase< H, Args >::globalEndRun ( edm::Run const &  ,
edm::EventSetup const &   
) const
inlinefinal

Definition at line 60 of file DQMGlobalEDAnalyzer.h.

60 {};

◆ meId()

template<typename H, typename... Args>
uint64_t DQMGlobalEDAnalyzerBase< H, Args >::meId ( edm::Run const &  run) const
inlineprotected

Definition at line 71 of file DQMGlobalEDAnalyzer.h.

Referenced by DQMGlobalEDAnalyzerBase< dtsegment2dsl::Histograms, Args... >::globalBeginRun().

71 { return (((uint64_t)run.run()) << 32) + this->moduleDescription().id(); }
unsigned int id() const
ModuleDescription const & moduleDescription() const
unsigned long long uint64_t
Definition: Time.h:13

Member Data Documentation

◆ dqmstore_

template<typename H, typename... Args>
DQMStore* DQMGlobalEDAnalyzerBase< H, Args >::dqmstore_
protected

◆ runToken_

template<typename H, typename... Args>
edm::EDPutTokenT<DQMToken> DQMGlobalEDAnalyzerBase< H, Args >::runToken_
protected