CMS 3D CMS Logo

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

#include <HcalLutGenerator.h>

Inheritance diagram for HcalLutGenerator:
edm::one::EDAnalyzer<> edm::one::EDAnalyzerBase edm::EDConsumerBase

Public Member Functions

void analyze (const edm::Event &, const edm::EventSetup &) override
 
void endJob () override
 
 HcalLutGenerator (const edm::ParameterSet &)
 
 ~HcalLutGenerator () override
 
- Public Member Functions inherited from edm::one::EDAnalyzer<>
 EDAnalyzer ()=default
 
 EDAnalyzer (const EDAnalyzer &)=delete
 
SerialTaskQueueglobalLuminosityBlocksQueue () final
 
SerialTaskQueueglobalRunsQueue () final
 
const EDAnalyzeroperator= (const EDAnalyzer &)=delete
 
bool wantsGlobalLuminosityBlocks () const noexcept final
 
bool wantsGlobalRuns () const noexcept final
 
bool wantsInputProcessBlocks () const noexcept final
 
bool wantsProcessBlocks () const noexcept final
 
- Public Member Functions inherited from edm::one::EDAnalyzerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzerBase ()
 
ModuleDescription const & moduleDescription () const
 
bool wantsStreamLuminosityBlocks () const noexcept
 
bool wantsStreamRuns () const noexcept
 
 ~EDAnalyzerBase () 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)
 

Private Attributes

std::string _lin_file
 
uint32_t _status_word_to_mask
 
std::string _tag
 
edm::ESGetToken< HcalDbService, HcalDbRecordtok_dbservice_
 
edm::ESGetToken< HcalChannelQuality, HcalChannelQualityRcdtok_hcalChStatus_
 
edm::ESGetToken< CaloTPGTranscoder, CaloTPGRecordtok_hcalCoder_
 
edm::ESGetToken< HcalTPGCoder, HcalTPGRecordtok_inCoder_
 

Additional Inherited Members

- Public Types inherited from edm::one::EDAnalyzerBase
typedef EDAnalyzerBase ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::one::EDAnalyzerBase
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)
 
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)
 

Detailed Description

Definition at line 17 of file HcalLutGenerator.h.

Constructor & Destructor Documentation

◆ HcalLutGenerator()

HcalLutGenerator::HcalLutGenerator ( const edm::ParameterSet iConfig)
explicit

Definition at line 12 of file HcalLutGenerator.cc.

References _lin_file, _status_word_to_mask, _tag, edm::ParameterSet::getParameter(), AlCaHLTBitMon_QueryRunRegistry::string, tok_dbservice_, tok_hcalChStatus_, tok_hcalCoder_, and tok_inCoder_.

12  {
13  _tag = iConfig.getParameter<std::string>("tag");
14  _lin_file = iConfig.getParameter<std::string>("HO_master_file");
15  _status_word_to_mask = iConfig.getParameter<uint32_t>("status_word_to_mask");
16  tok_inCoder_ = esConsumes<HcalTPGCoder, HcalTPGRecord>();
17  tok_dbservice_ = esConsumes<HcalDbService, HcalDbRecord>();
18  tok_hcalChStatus_ = esConsumes<HcalChannelQuality, HcalChannelQualityRcd>(edm::ESInputTag("", "withTopo"));
19  tok_hcalCoder_ = esConsumes<CaloTPGTranscoder, CaloTPGRecord>();
20 }
T getParameter(std::string const &) const
Definition: ParameterSet.h:307
edm::ESGetToken< HcalChannelQuality, HcalChannelQualityRcd > tok_hcalChStatus_
uint32_t _status_word_to_mask
edm::ESGetToken< HcalDbService, HcalDbRecord > tok_dbservice_
std::string _lin_file
edm::ESGetToken< HcalTPGCoder, HcalTPGRecord > tok_inCoder_
edm::ESGetToken< CaloTPGTranscoder, CaloTPGRecord > tok_hcalCoder_

◆ ~HcalLutGenerator()

HcalLutGenerator::~HcalLutGenerator ( )
inlineoverride

Definition at line 20 of file HcalLutGenerator.h.

20 {}

Member Function Documentation

◆ analyze()

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

Implements edm::one::EDAnalyzerBase.

Definition at line 22 of file HcalLutGenerator.cc.

References _lin_file, _status_word_to_mask, _tag, HcalLutManager::createLutXmlFiles_HBEFFromCoder_HOFromAscii_ZDC(), edm::EventSetup::getData(), edm::EventSetup::getHandle(), edm::ESHandleBase::swap(), tok_dbservice_, tok_hcalChStatus_, tok_hcalCoder_, and tok_inCoder_.

22  {
23  const HcalTPGCoder* inputCoder = &iSetup.getData(tok_inCoder_);
24  const HcalDbService* hcalcond = &iSetup.getData(tok_dbservice_);
25  const HcalChannelQuality* _cq = &iSetup.getData(tok_hcalChStatus_);
26 
29  transcoder.swap(outTranscoder);
30 
31  HcalLutManager manager(hcalcond, _cq, _status_word_to_mask);
32  bool split_by_crate = true;
33 
34  manager.createLutXmlFiles_HBEFFromCoder_HOFromAscii_ZDC(_tag, *inputCoder, *transcoder, _lin_file, split_by_crate);
35 }
T const & getData(const ESGetToken< T, R > &iToken) const noexcept(false)
Definition: EventSetup.h:119
edm::ESGetToken< HcalChannelQuality, HcalChannelQualityRcd > tok_hcalChStatus_
Various manipulations with trigger Lookup Tables.
uint32_t _status_word_to_mask
edm::ESGetToken< HcalDbService, HcalDbRecord > tok_dbservice_
ESHandle< T > getHandle(const ESGetToken< T, R > &iToken) const
Definition: EventSetup.h:130
std::string _lin_file
edm::ESGetToken< HcalTPGCoder, HcalTPGRecord > tok_inCoder_
edm::ESGetToken< CaloTPGTranscoder, CaloTPGRecord > tok_hcalCoder_
void swap(ESHandleBase &iOther)
Definition: ESHandle.h:52

◆ endJob()

void HcalLutGenerator::endJob ( void  )
inlineoverridevirtual

Reimplemented from edm::one::EDAnalyzerBase.

Definition at line 22 of file HcalLutGenerator.h.

Referenced by o2olib.O2ORunMgr::executeJob().

22 {}

Member Data Documentation

◆ _lin_file

std::string HcalLutGenerator::_lin_file
private

Definition at line 26 of file HcalLutGenerator.h.

Referenced by analyze(), and HcalLutGenerator().

◆ _status_word_to_mask

uint32_t HcalLutGenerator::_status_word_to_mask
private

Definition at line 27 of file HcalLutGenerator.h.

Referenced by analyze(), and HcalLutGenerator().

◆ _tag

std::string HcalLutGenerator::_tag
private

Definition at line 25 of file HcalLutGenerator.h.

Referenced by analyze(), and HcalLutGenerator().

◆ tok_dbservice_

edm::ESGetToken<HcalDbService, HcalDbRecord> HcalLutGenerator::tok_dbservice_
private

Definition at line 29 of file HcalLutGenerator.h.

Referenced by analyze(), and HcalLutGenerator().

◆ tok_hcalChStatus_

edm::ESGetToken<HcalChannelQuality, HcalChannelQualityRcd> HcalLutGenerator::tok_hcalChStatus_
private

Definition at line 30 of file HcalLutGenerator.h.

Referenced by analyze(), and HcalLutGenerator().

◆ tok_hcalCoder_

edm::ESGetToken<CaloTPGTranscoder, CaloTPGRecord> HcalLutGenerator::tok_hcalCoder_
private

Definition at line 31 of file HcalLutGenerator.h.

Referenced by analyze(), and HcalLutGenerator().

◆ tok_inCoder_

edm::ESGetToken<HcalTPGCoder, HcalTPGRecord> HcalLutGenerator::tok_inCoder_
private

Definition at line 28 of file HcalLutGenerator.h.

Referenced by analyze(), and HcalLutGenerator().