CMS 3D CMS Logo

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

#include <CastorHardcodeCalibrations.h>

Inheritance diagram for CastorHardcodeCalibrations:
edm::ESProducer edm::EventSetupRecordIntervalFinder edm::ESProxyFactoryProducer edm::eventsetup::DataProxyProvider

Public Member Functions

 CastorHardcodeCalibrations (const edm::ParameterSet &)
 
void produce ()
 
 ~CastorHardcodeCalibrations () override
 
- Public Member Functions inherited from edm::ESProducer
 ESProducer ()
 
 ESProducer (const ESProducer &)=delete
 
ESProxyIndex const * getTokenIndices (unsigned int iIndex) const
 
ESRecordIndex const * getTokenRecordIndices (unsigned int iIndex) const
 
bool hasMayConsumes () const noexcept
 
size_t numberOfTokenIndices (unsigned int iIndex) const
 
ESProducer const & operator= (const ESProducer &)=delete
 
SerialTaskQueueChainqueue ()
 
template<typename Record >
std::optional< std::vector< ESProxyIndex > > updateFromMayConsumes (unsigned int iIndex, const Record &iRecord) const
 
void updateLookup (eventsetup::ESRecordsToProxyIndices const &) final
 
 ~ESProducer () noexcept(false) override
 
- Public Member Functions inherited from edm::ESProxyFactoryProducer
 ESProxyFactoryProducer ()
 
 ESProxyFactoryProducer (const ESProxyFactoryProducer &)=delete
 
const ESProxyFactoryProduceroperator= (const ESProxyFactoryProducer &)=delete
 
 ~ESProxyFactoryProducer () noexcept(false) override
 
- Public Member Functions inherited from edm::eventsetup::DataProxyProvider
void createKeyedProxies (EventSetupRecordKey const &key, unsigned int nConcurrentIOVs)
 
 DataProxyProvider ()
 
 DataProxyProvider (const DataProxyProvider &)=delete
 
const ComponentDescriptiondescription () const
 
void fillRecordsNotAllowingConcurrentIOVs (std::set< EventSetupRecordKey > &recordsNotAllowingConcurrentIOVs) const
 
virtual void initConcurrentIOVs (EventSetupRecordKey const &key, unsigned int nConcurrentIOVs)
 
bool isUsingRecord (const EventSetupRecordKey &key) const
 
KeyedProxieskeyedProxies (const EventSetupRecordKey &iRecordKey, unsigned int iovIndex=0)
 
const DataProxyProvideroperator= (const DataProxyProvider &)=delete
 
void setAppendToDataLabel (const edm::ParameterSet &)
 
void setDescription (const ComponentDescription &iDescription)
 
std::set< EventSetupRecordKeyusingRecords () const
 
virtual ~DataProxyProvider () noexcept(false)
 
- Public Member Functions inherited from edm::EventSetupRecordIntervalFinder
bool concurrentFinder () const
 
const eventsetup::ComponentDescriptiondescriptionForFinder () const
 
 EventSetupRecordIntervalFinder ()
 
 EventSetupRecordIntervalFinder (const EventSetupRecordIntervalFinder &)=delete
 
std::set< eventsetup::EventSetupRecordKeyfindingForRecords () const
 
const ValidityIntervalfindIntervalFor (const eventsetup::EventSetupRecordKey &, const IOVSyncValue &)
 
bool nonconcurrentAndIOVNeedsUpdate (const eventsetup::EventSetupRecordKey &key, const IOVSyncValue &syncValue) const
 
const EventSetupRecordIntervalFinderoperator= (const EventSetupRecordIntervalFinder &)=delete
 
void resetInterval (const eventsetup::EventSetupRecordKey &)
 
void setDescriptionForFinder (const eventsetup::ComponentDescription &iDescription)
 
virtual ~EventSetupRecordIntervalFinder () noexcept(false)
 

Protected Member Functions

std::unique_ptr< CastorChannelQualityproduceChannelQuality (const CastorChannelQualityRcd &rcd)
 
std::unique_ptr< CastorElectronicsMapproduceElectronicsMap (const CastorElectronicsMapRcd &rcd)
 
std::unique_ptr< CastorGainsproduceGains (const CastorGainsRcd &rcd)
 
std::unique_ptr< CastorGainWidthsproduceGainWidths (const CastorGainWidthsRcd &rcd)
 
std::unique_ptr< CastorPedestalsproducePedestals (const CastorPedestalsRcd &rcd)
 
std::unique_ptr< CastorPedestalWidthsproducePedestalWidths (const CastorPedestalWidthsRcd &rcd)
 
std::unique_ptr< CastorQIEDataproduceQIEData (const CastorQIEDataRcd &rcd)
 
std::unique_ptr< CastorRecoParamsproduceRecoParams (const CastorRecoParamsRcd &rcd)
 
std::unique_ptr< CastorSaturationCorrsproduceSaturationCorrs (const CastorSaturationCorrsRcd &rcd)
 
void setIntervalFor (const edm::eventsetup::EventSetupRecordKey &, const edm::IOVSyncValue &, edm::ValidityInterval &) override
 
- Protected Member Functions inherited from edm::ESProducer
template<typename T >
auto setWhatProduced (T *iThis, const char *iLabel)
 
template<typename T >
auto setWhatProduced (T *iThis, const es::Label &iLabel={})
 
template<typename T >
auto setWhatProduced (T *iThis, const std::string &iLabel)
 
template<typename T , typename TDecorator >
auto setWhatProduced (T *iThis, const TDecorator &iDec, const es::Label &iLabel={})
 
template<typename T , typename TReturn , typename TRecord >
auto setWhatProduced (T *iThis, TReturn(T ::*iMethod)(const TRecord &), const es::Label &iLabel={})
 
template<typename T , typename TReturn , typename TRecord , typename TArg >
ESConsumesCollectorT< TRecord > setWhatProduced (T *iThis, TReturn(T ::*iMethod)(const TRecord &), const TArg &iDec, const es::Label &iLabel={})
 
void usesResources (std::vector< std::string > const &)
 
- Protected Member Functions inherited from edm::ESProxyFactoryProducer
template<class TFactory >
void registerFactory (std::unique_ptr< TFactory > iFactory, const std::string &iLabel=std::string())
 
virtual void registerFactoryWithKey (const EventSetupRecordKey &iRecord, std::unique_ptr< eventsetup::ProxyFactoryBase > iFactory, const std::string &iLabel=std::string())
 
KeyedProxiesVector registerProxies (const EventSetupRecordKey &, unsigned int iovIndex) override
 
- Protected Member Functions inherited from edm::eventsetup::DataProxyProvider
template<class T >
void usingRecord ()
 
void usingRecordWithKey (const EventSetupRecordKey &key)
 
- Protected Member Functions inherited from edm::EventSetupRecordIntervalFinder
template<class T >
void findingRecord ()
 
void findingRecordWithKey (const eventsetup::EventSetupRecordKey &)
 

Protected Attributes

bool h2mode_
 

Additional Inherited Members

- Static Public Member Functions inherited from edm::eventsetup::DataProxyProvider
static void prevalidate (ConfigurationDescriptions &)
 
- Protected Types inherited from edm::ESProxyFactoryProducer
using EventSetupRecordKey = eventsetup::EventSetupRecordKey
 
- Protected Types inherited from edm::eventsetup::DataProxyProvider
using KeyedProxiesVector = std::vector< std::pair< DataKey, std::shared_ptr< DataProxy > >>
 

Detailed Description

Definition at line 23 of file CastorHardcodeCalibrations.h.

Constructor & Destructor Documentation

◆ CastorHardcodeCalibrations()

CastorHardcodeCalibrations::CastorHardcodeCalibrations ( const edm::ParameterSet iConfig)

Definition at line 72 of file CastorHardcodeCalibrations.cc.

74 {
75  edm::LogInfo("HCAL") << "CastorHardcodeCalibrations::CastorHardcodeCalibrations->...";
76  //parsing record parameters
77  h2mode_ = iConfig.getUntrackedParameter<bool>("H2Mode", false);
78  std::vector<std::string> toGet = iConfig.getUntrackedParameter<std::vector<std::string> >("toGet");
79  for (std::vector<std::string>::iterator objectName = toGet.begin(); objectName != toGet.end(); ++objectName) {
80  bool all = *objectName == "all";
81  if ((*objectName == "Pedestals") || all) {
83  findingRecord<CastorPedestalsRcd>();
84  }
85  if ((*objectName == "PedestalWidths") || all) {
87  findingRecord<CastorPedestalWidthsRcd>();
88  }
89  if ((*objectName == "Gains") || all) {
91  findingRecord<CastorGainsRcd>();
92  }
93  if ((*objectName == "GainWidths") || all) {
95  findingRecord<CastorGainWidthsRcd>();
96  }
97  if ((*objectName == "QIEData") || all) {
99  findingRecord<CastorQIEDataRcd>();
100  }
101  if ((*objectName == "ChannelQuality") || (*objectName == "channelQuality") || all) {
103  findingRecord<CastorChannelQualityRcd>();
104  }
105  if ((*objectName == "ElectronicsMap") || (*objectName == "electronicsMap") || all) {
107  findingRecord<CastorElectronicsMapRcd>();
108  }
109  if ((*objectName == "RecoParams") || all) {
111  findingRecord<CastorRecoParamsRcd>();
112  }
113  if ((*objectName == "SaturationCorrs") || all) {
115  findingRecord<CastorSaturationCorrsRcd>();
116  }
117  }
118 }

References python.cmstools::all(), edm::ParameterSet::getUntrackedParameter(), summarizeEdmComparisonLogfiles::objectName, produceChannelQuality(), produceElectronicsMap(), produceGains(), produceGainWidths(), producePedestals(), producePedestalWidths(), produceQIEData(), produceRecoParams(), produceSaturationCorrs(), and GlobalPosition_Frontier_DevDB_cff::toGet.

◆ ~CastorHardcodeCalibrations()

CastorHardcodeCalibrations::~CastorHardcodeCalibrations ( )
override

Definition at line 120 of file CastorHardcodeCalibrations.cc.

120 {}

Member Function Documentation

◆ produce()

void CastorHardcodeCalibrations::produce ( )
inline

Definition at line 28 of file CastorHardcodeCalibrations.h.

28 {};

◆ produceChannelQuality()

std::unique_ptr< CastorChannelQuality > CastorHardcodeCalibrations::produceChannelQuality ( const CastorChannelQualityRcd rcd)
protected

Definition at line 189 of file CastorHardcodeCalibrations.cc.

190  {
191  edm::LogInfo("HCAL") << "CastorHardcodeCalibrations::produceChannelQuality-> ...";
192  auto result = std::make_unique<CastorChannelQuality>();
193  std::vector<HcalGenericDetId> cells = allCells(h2mode_);
194  for (std::vector<HcalGenericDetId>::const_iterator cell = cells.begin(); cell != cells.end(); ++cell) {
196  result->addValues(item);
197  }
198  return result;
199 }

References cells, CastorChannelStatus::GOOD, B2GTnPMonitor_cfi::item, DetId::rawId(), and mps_fire::result.

Referenced by CastorHardcodeCalibrations().

◆ produceElectronicsMap()

std::unique_ptr< CastorElectronicsMap > CastorHardcodeCalibrations::produceElectronicsMap ( const CastorElectronicsMapRcd rcd)
protected

Definition at line 201 of file CastorHardcodeCalibrations.cc.

202  {
203  edm::LogInfo("HCAL") << "CastorHardcodeCalibrations::produceElectronicsMap-> ...";
204 
205  auto result = std::make_unique<CastorElectronicsMap>();
207  return result;
208 }

References CastorDbHardcode::makeHardcodeMap(), and mps_fire::result.

Referenced by CastorHardcodeCalibrations().

◆ produceGains()

std::unique_ptr< CastorGains > CastorHardcodeCalibrations::produceGains ( const CastorGainsRcd rcd)
protected

Definition at line 156 of file CastorHardcodeCalibrations.cc.

156  {
157  edm::LogInfo("HCAL") << "CastorHardcodeCalibrations::produceGains-> ...";
158  auto result = std::make_unique<CastorGains>();
159  std::vector<HcalGenericDetId> cells = allCells(h2mode_);
160  for (std::vector<HcalGenericDetId>::const_iterator cell = cells.begin(); cell != cells.end(); ++cell) {
162  result->addValues(item);
163  }
164  return result;
165 }

References cells, B2GTnPMonitor_cfi::item, CastorDbHardcode::makeGain(), and mps_fire::result.

Referenced by CastorHardcodeCalibrations().

◆ produceGainWidths()

std::unique_ptr< CastorGainWidths > CastorHardcodeCalibrations::produceGainWidths ( const CastorGainWidthsRcd rcd)
protected

Definition at line 167 of file CastorHardcodeCalibrations.cc.

167  {
168  edm::LogInfo("HCAL") << "CastorHardcodeCalibrations::produceGainWidths-> ...";
169  auto result = std::make_unique<CastorGainWidths>();
170  std::vector<HcalGenericDetId> cells = allCells(h2mode_);
171  for (std::vector<HcalGenericDetId>::const_iterator cell = cells.begin(); cell != cells.end(); ++cell) {
173  result->addValues(item);
174  }
175  return result;
176 }

References cells, B2GTnPMonitor_cfi::item, CastorDbHardcode::makeGainWidth(), and mps_fire::result.

Referenced by CastorHardcodeCalibrations().

◆ producePedestals()

std::unique_ptr< CastorPedestals > CastorHardcodeCalibrations::producePedestals ( const CastorPedestalsRcd rcd)
protected

Definition at line 134 of file CastorHardcodeCalibrations.cc.

134  {
135  edm::LogInfo("HCAL") << "CastorHardcodeCalibrations::producePedestals-> ...";
136  auto result = std::make_unique<CastorPedestals>(false);
137  std::vector<HcalGenericDetId> cells = allCells(h2mode_);
138  for (std::vector<HcalGenericDetId>::const_iterator cell = cells.begin(); cell != cells.end(); ++cell) {
140  result->addValues(item);
141  }
142  return result;
143 }

References cells, B2GTnPMonitor_cfi::item, CastorDbHardcode::makePedestal(), and mps_fire::result.

Referenced by CastorHardcodeCalibrations().

◆ producePedestalWidths()

std::unique_ptr< CastorPedestalWidths > CastorHardcodeCalibrations::producePedestalWidths ( const CastorPedestalWidthsRcd rcd)
protected

Definition at line 145 of file CastorHardcodeCalibrations.cc.

145  {
146  edm::LogInfo("HCAL") << "CastorHardcodeCalibrations::producePedestalWidths-> ...";
147  auto result = std::make_unique<CastorPedestalWidths>(false);
148  std::vector<HcalGenericDetId> cells = allCells(h2mode_);
149  for (std::vector<HcalGenericDetId>::const_iterator cell = cells.begin(); cell != cells.end(); ++cell) {
151  result->addValues(item);
152  }
153  return result;
154 }

References cells, B2GTnPMonitor_cfi::item, CastorDbHardcode::makePedestalWidth(), and mps_fire::result.

Referenced by CastorHardcodeCalibrations().

◆ produceQIEData()

std::unique_ptr< CastorQIEData > CastorHardcodeCalibrations::produceQIEData ( const CastorQIEDataRcd rcd)
protected

Definition at line 178 of file CastorHardcodeCalibrations.cc.

178  {
179  edm::LogInfo("HCAL") << "CastorHardcodeCalibrations::produceQIEData-> ...";
180  auto result = std::make_unique<CastorQIEData>();
181  std::vector<HcalGenericDetId> cells = allCells(h2mode_);
182  for (std::vector<HcalGenericDetId>::const_iterator cell = cells.begin(); cell != cells.end(); ++cell) {
184  result->addCoder(coder);
185  }
186  return result;
187 }

References cells, CastorDbHardcode::makeQIECoder(), and mps_fire::result.

Referenced by CastorHardcodeCalibrations().

◆ produceRecoParams()

std::unique_ptr< CastorRecoParams > CastorHardcodeCalibrations::produceRecoParams ( const CastorRecoParamsRcd rcd)
protected

Definition at line 210 of file CastorHardcodeCalibrations.cc.

210  {
211  edm::LogInfo("HCAL") << "CastorHardcodeCalibrations::produceRecoParams-> ...";
212  auto result = std::make_unique<CastorRecoParams>();
213  std::vector<HcalGenericDetId> cells = allCells(h2mode_);
214  for (std::vector<HcalGenericDetId>::const_iterator cell = cells.begin(); cell != cells.end(); ++cell) {
216  result->addValues(item);
217  }
218  return result;
219 }

References cells, B2GTnPMonitor_cfi::item, CastorDbHardcode::makeRecoParam(), and mps_fire::result.

Referenced by CastorHardcodeCalibrations().

◆ produceSaturationCorrs()

std::unique_ptr< CastorSaturationCorrs > CastorHardcodeCalibrations::produceSaturationCorrs ( const CastorSaturationCorrsRcd rcd)
protected

Definition at line 221 of file CastorHardcodeCalibrations.cc.

222  {
223  edm::LogInfo("HCAL") << "CastorHardcodeCalibrations::produceSaturationCorrs-> ...";
224  auto result = std::make_unique<CastorSaturationCorrs>();
225  std::vector<HcalGenericDetId> cells = allCells(h2mode_);
226  for (std::vector<HcalGenericDetId>::const_iterator cell = cells.begin(); cell != cells.end(); ++cell) {
228  result->addValues(item);
229  }
230  return result;
231 }

References cells, B2GTnPMonitor_cfi::item, CastorDbHardcode::makeSaturationCorr(), and mps_fire::result.

Referenced by CastorHardcodeCalibrations().

◆ setIntervalFor()

void CastorHardcodeCalibrations::setIntervalFor ( const edm::eventsetup::EventSetupRecordKey iKey,
const edm::IOVSyncValue iTime,
edm::ValidityInterval oInterval 
)
overrideprotectedvirtual

Member Data Documentation

◆ h2mode_

bool CastorHardcodeCalibrations::h2mode_
protected

Definition at line 44 of file CastorHardcodeCalibrations.h.

CastorHardcodeCalibrations::h2mode_
bool h2mode_
Definition: CastorHardcodeCalibrations.h:44
CastorDbHardcode::makePedestalWidth
CastorPedestalWidth makePedestalWidth(HcalGenericDetId fId)
Definition: CastorDbHardcode.cc:28
CastorDbHardcode::makeRecoParam
CastorRecoParam makeRecoParam(HcalGenericDetId fId)
Definition: CastorDbHardcode.cc:96
CastorDbHardcode::makeGain
CastorGain makeGain(HcalGenericDetId fId, bool fSmear=false)
Definition: CastorDbHardcode.cc:47
CastorHardcodeCalibrations::produceGains
std::unique_ptr< CastorGains > produceGains(const CastorGainsRcd &rcd)
Definition: CastorHardcodeCalibrations.cc:156
CastorDbHardcode::makeSaturationCorr
CastorSaturationCorr makeSaturationCorr(HcalGenericDetId fId)
Definition: CastorDbHardcode.cc:101
edm::ESProducer::setWhatProduced
auto setWhatProduced(T *iThis, const es::Label &iLabel={})
Definition: ESProducer.h:163
cells
const caConstants::TupleMultiplicity const CAHitNtupletGeneratorKernelsGPU::HitToTuple cms::cuda::AtomicPairCounter const GPUCACell *__restrict__ cells
Definition: CAHitNtupletGeneratorKernelsImpl.h:43
CastorHardcodeCalibrations::produceElectronicsMap
std::unique_ptr< CastorElectronicsMap > produceElectronicsMap(const CastorElectronicsMapRcd &rcd)
Definition: CastorHardcodeCalibrations.cc:201
edm::ParameterSet::getUntrackedParameter
T getUntrackedParameter(std::string const &, T const &) const
edm::Timestamp::value
TimeValue_t value() const
Definition: Timestamp.h:45
edm::LogInfo
Log< level::Info, false > LogInfo
Definition: MessageLogger.h:125
CastorPedestal
Definition: CastorPedestal.h:16
CastorPedestalWidth
Definition: CastorPedestalWidth.h:16
GlobalPosition_Frontier_DevDB_cff.toGet
toGet
Definition: GlobalPosition_Frontier_DevDB_cff.py:9
CastorHardcodeCalibrations::produceGainWidths
std::unique_ptr< CastorGainWidths > produceGainWidths(const CastorGainWidthsRcd &rcd)
Definition: CastorHardcodeCalibrations.cc:167
python.cmstools.all
def all(container)
workaround iterator generators for ROOT classes
Definition: cmstools.py:25
CastorRecoParam
Definition: CastorRecoParam.h:13
CastorDbHardcode::makeGainWidth
CastorGainWidth makeGainWidth(HcalGenericDetId fId)
Definition: CastorDbHardcode.cc:66
CastorHardcodeCalibrations::producePedestals
std::unique_ptr< CastorPedestals > producePedestals(const CastorPedestalsRcd &rcd)
Definition: CastorHardcodeCalibrations.cc:134
CastorChannelStatus::GOOD
Definition: CastorChannelStatus.h:27
edm::eventsetup::EventSetupRecordKey::name
const char * name() const
Definition: EventSetupRecordKey.h:46
CastorGainWidth
Definition: CastorGainWidth.h:12
edm::IOVSyncValue::eventID
const EventID & eventID() const
Definition: IOVSyncValue.h:40
CastorDbHardcode::makeHardcodeMap
void makeHardcodeMap(CastorElectronicsMap &emap)
Definition: CastorDbHardcode.cc:117
edm::IOVSyncValue::endOfTime
static const IOVSyncValue & endOfTime()
Definition: IOVSyncValue.cc:82
CastorHardcodeCalibrations::produceSaturationCorrs
std::unique_ptr< CastorSaturationCorrs > produceSaturationCorrs(const CastorSaturationCorrsRcd &rcd)
Definition: CastorHardcodeCalibrations.cc:221
CastorHardcodeCalibrations::produceRecoParams
std::unique_ptr< CastorRecoParams > produceRecoParams(const CastorRecoParamsRcd &rcd)
Definition: CastorHardcodeCalibrations.cc:210
CastorGain
Definition: CastorGain.h:13
B2GTnPMonitor_cfi.item
item
Definition: B2GTnPMonitor_cfi.py:147
AlCaHarvesting_cff.record
record
Definition: AlCaHarvesting_cff.py:42
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
CastorDbHardcode::makePedestal
CastorPedestal makePedestal(HcalGenericDetId fId, bool fSmear=false)
Definition: CastorDbHardcode.cc:12
CastorChannelStatus
Definition: CastorChannelStatus.h:15
edm::IOVSyncValue::time
const Timestamp & time() const
Definition: IOVSyncValue.h:42
CastorHardcodeCalibrations::produceQIEData
std::unique_ptr< CastorQIEData > produceQIEData(const CastorQIEDataRcd &rcd)
Definition: CastorHardcodeCalibrations.cc:178
cond::ValidityInterval
std::pair< Time_t, Time_t > ValidityInterval
Definition: Time.h:17
CastorHardcodeCalibrations::produceChannelQuality
std::unique_ptr< CastorChannelQuality > produceChannelQuality(const CastorChannelQualityRcd &rcd)
Definition: CastorHardcodeCalibrations.cc:189
CastorHardcodeCalibrations::producePedestalWidths
std::unique_ptr< CastorPedestalWidths > producePedestalWidths(const CastorPedestalWidthsRcd &rcd)
Definition: CastorHardcodeCalibrations.cc:145
CastorSaturationCorr
Definition: CastorSaturationCorr.h:13
edm::IOVSyncValue::beginOfTime
static const IOVSyncValue & beginOfTime()
Definition: IOVSyncValue.cc:88
CastorDbHardcode::makeQIECoder
CastorQIECoder makeQIECoder(HcalGenericDetId fId)
Definition: CastorDbHardcode.cc:72
CastorQIECoder
Definition: CastorQIECoder.h:21
mps_fire.result
result
Definition: mps_fire.py:311
summarizeEdmComparisonLogfiles.objectName
objectName
Definition: summarizeEdmComparisonLogfiles.py:104