CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes
TrackingOfflineDQM Class Reference

#include <DQM/TrackingMonitorCluster/interface/TrackingOfflineDQM.h>

Inheritance diagram for TrackingOfflineDQM:
DQMEDHarvester edm::one::EDProducer< edm::Accumulator, edm::EndLuminosityBlockProducer, edm::EndRunProducer, edm::one::WatchLuminosityBlocks, edm::one::WatchRuns, edm::one::SharedResources > edm::one::EDProducerBase edm::ProducerBase edm::EDConsumerBase edm::ProductRegistryHelper

Public Member Functions

 TrackingOfflineDQM (const edm::ParameterSet &ps)
 Constructor. More...
 
 ~TrackingOfflineDQM () override
 Destructor. More...
 
- Public Member Functions inherited from DQMEDHarvester
void accumulate (edm::Event const &ev, edm::EventSetup const &es) final
 
void beginLuminosityBlock (edm::LuminosityBlock const &, edm::EventSetup const &) final
 
void beginRun (edm::Run const &, edm::EventSetup const &) override
 
 DQMEDHarvester ()
 
void endJob () final
 
void endLuminosityBlock (edm::LuminosityBlock const &, edm::EventSetup const &) final
 
void endLuminosityBlockProduce (edm::LuminosityBlock &, edm::EventSetup const &) final
 
void endRun (edm::Run const &, edm::EventSetup const &) override
 
void endRunProduce (edm::Run &run, edm::EventSetup const &setup) override
 
 ~DQMEDHarvester () override=default
 
- Public Member Functions inherited from edm::one::EDProducer< edm::Accumulator, edm::EndLuminosityBlockProducer, edm::EndRunProducer, edm::one::WatchLuminosityBlocks, edm::one::WatchRuns, edm::one::SharedResources >
 EDProducer ()=default
 
SerialTaskQueueglobalLuminosityBlocksQueue () final
 
SerialTaskQueueglobalRunsQueue () final
 
bool hasAbilityToProduceInLumis () const final
 
bool hasAbilityToProduceInRuns () const final
 
bool wantsGlobalLuminosityBlocks () const final
 
bool wantsGlobalRuns () 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 () 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
 
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::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
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
virtual ~EDConsumerBase () noexcept(false)
 

Private Member Functions

void beginJob () override
 BeginJob. More...
 
void beginRun (edm::Run const &run, edm::EventSetup const &eSetup) override
 BeginRun. More...
 
void dqmEndJob (DQMStore::IBooker &ibooker_, DQMStore::IGetter &igetter_) override
 Endjob. More...
 
void dqmEndLuminosityBlock (DQMStore::IBooker &ibooker_, DQMStore::IGetter &igetter_, edm::LuminosityBlock const &lumiSeg, edm::EventSetup const &eSetup) override
 End Luminosity Block. More...
 
bool openInputFile ()
 

Private Attributes

TrackingActionExecutoractionExecutor_
 
bool allpixelFEDsFound_
 
edm::ParameterSet configPar_
 
int globalStatusFilling_
 
std::string inputFileName_
 
std::string outputFileName_
 
bool trackerFEDsFound_
 
bool usedWithEDMtoMEConverter_
 

Additional Inherited Members

- 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 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 inherited from DQMEDHarvester
edm::EDPutTokenT< DQMTokenlumiToken_
 
edm::EDPutTokenT< DQMTokenrunToken_
 

Detailed Description

Description: <one line="" class="" summary>="">

Implementation: <Notes on="" implementation>="">

Description: DQM class to perform Summary creation Quality Test on a merged Root file after CAF processing Usage: <usage>

Definition at line 43 of file TrackingOfflineDQM.h.

Constructor & Destructor Documentation

TrackingOfflineDQM::TrackingOfflineDQM ( const edm::ParameterSet ps)

Constructor.

Construct object.

Parameters
roPARAMETER_SETRegular Parameter Set that represent read configuration file

Definition at line 58 of file TrackingOfflineDQM.cc.

References actionExecutor_, configPar_, edm::ParameterSet::getUntrackedParameter(), globalStatusFilling_, inputFileName_, outputFileName_, AlCaHLTBitMon_QueryRunRegistry::string, and usedWithEDMtoMEConverter_.

58  :
59  configPar_(pSet)
60 {
61 
62  // Action Executor
64 
65  usedWithEDMtoMEConverter_= configPar_.getUntrackedParameter<bool>("UsedWithEDMtoMEConverter",false);
68  globalStatusFilling_ = configPar_.getUntrackedParameter<int>("GlobalStatusFilling", 1);
69 
70 }
std::string inputFileName_
T getUntrackedParameter(std::string const &, T const &) const
std::string outputFileName_
TrackingActionExecutor * actionExecutor_
edm::ParameterSet configPar_
TrackingOfflineDQM::~TrackingOfflineDQM ( )
override

Destructor.

Definition at line 76 of file TrackingOfflineDQM.cc.

76  {
77 
78 }

Member Function Documentation

void TrackingOfflineDQM::beginJob ( void  )
overrideprivatevirtual

BeginJob.

Executed at the begining of application.

Parameters
eSetupEvent Setup object

Reimplemented from edm::one::EDProducerBase.

Definition at line 86 of file TrackingOfflineDQM.cc.

86  {
87 
88  edm::LogInfo("BeginJobDone") << "TrackingOfflineDQM::beginJob done";
89 }
void TrackingOfflineDQM::beginRun ( edm::Run const &  run,
edm::EventSetup const &  eSetup 
)
overrideprivate

BeginRun.

Executed at the begining a Run.

Parameters
runRun object
eSetupEvent Setup object with Geometry, Magnetic Field, etc.

Definition at line 99 of file TrackingOfflineDQM.cc.

References allpixelFEDsFound_, edm::EventSetup::find(), edm::eventsetup::heterocontainer::HCTypeTag::findType(), edm::EventSetup::get(), edm::ESHandleBase::isValid(), RunInfo::m_fed_in, FEDNumbering::MAXSiPixelFEDID, FEDNumbering::MAXSiStripFEDID, FEDNumbering::MINSiPixelFEDID, FEDNumbering::MINSiStripFEDID, and trackerFEDsFound_.

99  {
100  edm::LogInfo ("BeginRun") <<"TrackingOfflineDQM:: Begining of Run";
101 
102  int nFEDs = 0;
103  int nPixelFEDs = 0;
105  if( eSetup.find( recordKey ) != nullptr) {
106 
107  edm::ESHandle<RunInfo> sumFED;
108  eSetup.get<RunInfoRcd>().get(sumFED);
109  if ( sumFED.isValid() ) {
110 
111  const int siStripFedIdMin = FEDNumbering::MINSiStripFEDID;
112  const int siStripFedIdMax = FEDNumbering::MAXSiStripFEDID;
113  const int siPixelFedIdMin = FEDNumbering::MINSiPixelFEDID;
114  const int siPixelFedIdMax = FEDNumbering::MAXSiPixelFEDID;
115 
116  std::vector<int> FedsInIds= sumFED->m_fed_in;
117  for ( auto fedID : FedsInIds ) {
118  if ( fedID >= siPixelFedIdMin && fedID <= siPixelFedIdMax ) {
119  ++nPixelFEDs;
120  ++nFEDs;
121  }
122  if ( fedID >= siStripFedIdMin && fedID <= siStripFedIdMax )
123  ++nFEDs;
124  }
125  }
126  }
128  allpixelFEDsFound_ = (nPixelFEDs == siPixelFedN);
129  trackerFEDsFound_ = (nFEDs > 0);
130 
131 }
static HCTypeTag findType(char const *iTypeName)
find a type based on the types name, if not found will return default HCTypeTag
std::vector< int > m_fed_in
Definition: RunInfo.h:26
bool isValid() const
Definition: ESHandle.h:47
void TrackingOfflineDQM::dqmEndJob ( DQMStore::IBooker ibooker_,
DQMStore::IGetter igetter_ 
)
overrideprivatevirtual

Endjob.

End Run.

Implements DQMEDHarvester.

Definition at line 157 of file TrackingOfflineDQM.cc.

References actionExecutor_, TrackingActionExecutor::createGlobalStatus(), DEFINE_FWK_MODULE, TrackingActionExecutor::fillDummyGlobalStatus(), TrackingActionExecutor::fillGlobalStatus(), globalStatusFilling_, and trackerFEDsFound_.

158 {
159 
160  edm::LogInfo("TrackingOfflineDQM") << "TrackingOfflineDQM::dqmEndJob";
161 
162  if (globalStatusFilling_ > 0) {
163  actionExecutor_->createGlobalStatus(ibooker_,igetter_);
164 
165  if ( !trackerFEDsFound_ ) {
167  return;
168  } else {
169  actionExecutor_->fillGlobalStatus(ibooker_,igetter_);
170  }
171  }
172 }
void fillGlobalStatus(DQMStore::IBooker &ibooker, DQMStore::IGetter &igetter)
TrackingActionExecutor * actionExecutor_
void createGlobalStatus(DQMStore::IBooker &ibooker, DQMStore::IGetter &igetter)
void TrackingOfflineDQM::dqmEndLuminosityBlock ( DQMStore::IBooker ibooker_,
DQMStore::IGetter igetter_,
edm::LuminosityBlock const &  lumiSeg,
edm::EventSetup const &  eSetup 
)
overrideprivatevirtual

End Luminosity Block.

End Lumi.

Reimplemented from DQMEDHarvester.

Definition at line 139 of file TrackingOfflineDQM.cc.

References actionExecutor_, TrackingActionExecutor::createLSStatus(), TrackingActionExecutor::fillDummyLSStatus(), TrackingActionExecutor::fillStatusAtLumi(), globalStatusFilling_, and trackerFEDsFound_.

139  {
140 
141 
142  edm::LogInfo("TrackingOfflineDQM") << "TrackingOfflineDQM::dqmBeginLuminosityBlock";
143 
144  if (globalStatusFilling_ > 0) {
145  actionExecutor_->createLSStatus(ibooker_,igetter_);
146 
147  if (trackerFEDsFound_) actionExecutor_->fillStatusAtLumi(ibooker_,igetter_);
149  }
150 }
void fillStatusAtLumi(DQMStore::IBooker &ibooker, DQMStore::IGetter &igetter)
void createLSStatus(DQMStore::IBooker &ibooker, DQMStore::IGetter &igetter)
TrackingActionExecutor * actionExecutor_
bool TrackingOfflineDQM::openInputFile ( )
private

Member Data Documentation

TrackingActionExecutor* TrackingOfflineDQM::actionExecutor_
private

Definition at line 72 of file TrackingOfflineDQM.h.

Referenced by dqmEndJob(), dqmEndLuminosityBlock(), and TrackingOfflineDQM().

bool TrackingOfflineDQM::allpixelFEDsFound_
private

Definition at line 79 of file TrackingOfflineDQM.h.

Referenced by beginRun().

edm::ParameterSet TrackingOfflineDQM::configPar_
private

Definition at line 81 of file TrackingOfflineDQM.h.

Referenced by TrackingOfflineDQM().

int TrackingOfflineDQM::globalStatusFilling_
private

Definition at line 76 of file TrackingOfflineDQM.h.

Referenced by dqmEndJob(), dqmEndLuminosityBlock(), and TrackingOfflineDQM().

std::string TrackingOfflineDQM::inputFileName_
private

Definition at line 74 of file TrackingOfflineDQM.h.

Referenced by TrackingOfflineDQM().

std::string TrackingOfflineDQM::outputFileName_
private

Definition at line 75 of file TrackingOfflineDQM.h.

Referenced by TrackingOfflineDQM().

bool TrackingOfflineDQM::trackerFEDsFound_
private

Definition at line 78 of file TrackingOfflineDQM.h.

Referenced by beginRun(), dqmEndJob(), and dqmEndLuminosityBlock().

bool TrackingOfflineDQM::usedWithEDMtoMEConverter_
private

Definition at line 77 of file TrackingOfflineDQM.h.

Referenced by TrackingOfflineDQM().