CMS 3D CMS Logo

List of all members | Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Types | Private Attributes
HcalHardcodeCalibrations Class Reference

#include <HcalHardcodeCalibrations.h>

Inheritance diagram for HcalHardcodeCalibrations:
edm::ESProducer edm::EventSetupRecordIntervalFinder edm::ESProductResolverFactoryProducer edm::eventsetup::ESProductResolverProvider

Public Member Functions

 HcalHardcodeCalibrations (const edm::ParameterSet &)
 
 ~HcalHardcodeCalibrations () override
 
- Public Member Functions inherited from edm::ESProducer
 ESProducer ()
 
 ESProducer (const ESProducer &)=delete
 
 ESProducer (ESProducer &&)=delete
 
ESResolverIndex const * getTokenIndices (unsigned int iIndex) const
 
ESRecordIndex const * getTokenRecordIndices (unsigned int iIndex) const
 
bool hasMayConsumes () const noexcept
 
size_t numberOfTokenIndices (unsigned int iIndex) const
 
ESProduceroperator= (const ESProducer &)=delete
 
ESProduceroperator= (ESProducer &&)=delete
 
SerialTaskQueueChainqueue ()
 
template<typename Record >
std::optional< std::vector< ESResolverIndex > > updateFromMayConsumes (unsigned int iIndex, const Record &iRecord) const
 
void updateLookup (eventsetup::ESRecordsToProductResolverIndices const &) final
 
 ~ESProducer () noexcept(false) override
 
- Public Member Functions inherited from edm::ESProductResolverFactoryProducer
 ESProductResolverFactoryProducer ()
 
 ESProductResolverFactoryProducer (const ESProductResolverFactoryProducer &)=delete
 
const ESProductResolverFactoryProduceroperator= (const ESProductResolverFactoryProducer &)=delete
 
 ~ESProductResolverFactoryProducer () noexcept(false) override
 
- Public Member Functions inherited from edm::eventsetup::ESProductResolverProvider
void createKeyedResolvers (EventSetupRecordKey const &key, unsigned int nConcurrentIOVs)
 
const ComponentDescriptiondescription () const
 
 ESProductResolverProvider ()
 
 ESProductResolverProvider (const ESProductResolverProvider &)=delete
 
void fillRecordsNotAllowingConcurrentIOVs (std::set< EventSetupRecordKey > &recordsNotAllowingConcurrentIOVs) const
 
virtual void initConcurrentIOVs (EventSetupRecordKey const &key, unsigned int nConcurrentIOVs)
 
bool isUsingRecord (const EventSetupRecordKey &key) const
 
KeyedResolverskeyedResolvers (const EventSetupRecordKey &iRecordKey, unsigned int iovIndex=0)
 
const ESProductResolverProvideroperator= (const ESProductResolverProvider &)=delete
 
void setAppendToDataLabel (const edm::ParameterSet &)
 
void setDescription (const ComponentDescription &iDescription)
 
std::set< EventSetupRecordKeyusingRecords () const
 
virtual ~ESProductResolverProvider () 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)
 

Static Public Member Functions

static void fillDescriptions (edm::ConfigurationDescriptions &descriptions)
 
- Static Public Member Functions inherited from edm::eventsetup::ESProductResolverProvider
static void prevalidate (ConfigurationDescriptions &)
 

Protected Member Functions

std::unique_ptr< HcalChannelQualityproduceChannelQuality (const HcalChannelQualityRcd &rcd)
 
std::unique_ptr< HcalDcsMapproduceDcsMap (const HcalDcsMapRcd &rcd)
 
std::unique_ptr< HcalDcsValuesproduceDcsValues (const HcalDcsRcd &rcd)
 
std::unique_ptr< HcalPedestalsproduceEffectivePedestals (const HcalPedestalsRcd &rcd)
 
std::unique_ptr< HcalPedestalWidthsproduceEffectivePedestalWidths (const HcalPedestalWidthsRcd &rcd)
 
std::unique_ptr< HcalElectronicsMapproduceElectronicsMap (const HcalElectronicsMapRcd &rcd)
 
std::unique_ptr< HcalFlagHFDigiTimeParamsproduceFlagHFDigiTimeParams (const HcalFlagHFDigiTimeParamsRcd &rcd)
 
std::unique_ptr< HcalFrontEndMapproduceFrontEndMap (const HcalFrontEndMapRcd &rcd)
 
std::unique_ptr< HcalGainsproduceGains (const HcalGainsRcd &rcd)
 
std::unique_ptr< HcalGainWidthsproduceGainWidths (const HcalGainWidthsRcd &rcd)
 
std::unique_ptr< HcalL1TriggerObjectsproduceL1TriggerObjects (const HcalL1TriggerObjectsRcd &rcd)
 
std::unique_ptr< HcalLongRecoParamsproduceLongRecoParams (const HcalLongRecoParamsRcd &rcd)
 
std::unique_ptr< HcalLUTCorrsproduceLUTCorrs (const HcalLUTCorrsRcd &rcd)
 
std::unique_ptr< HcalLutMetadataproduceLutMetadata (const HcalLutMetadataRcd &rcd)
 
std::unique_ptr< HcalMCParamsproduceMCParams (const HcalMCParamsRcd &rcd)
 
std::unique_ptr< HcalPedestalsproducePedestals (const HcalPedestalsRcd &rcd)
 
std::unique_ptr< HcalPedestalsproducePedestals_ (const HcalPedestalsRcd &rcd, const edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > &, const edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > &, bool eff)
 
std::unique_ptr< HcalPedestalWidthsproducePedestalWidths (const HcalPedestalWidthsRcd &rcd)
 
std::unique_ptr< HcalPedestalWidthsproducePedestalWidths_ (const HcalPedestalWidthsRcd &rcd, const edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > &, const edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > &, bool eff)
 
std::unique_ptr< HcalPFCorrsproducePFCorrs (const HcalPFCorrsRcd &rcd)
 
std::unique_ptr< HcalPFCutsproducePFCuts (const HcalPFCutsRcd &rcd)
 
std::unique_ptr< HcalQIEDataproduceQIEData (const HcalQIEDataRcd &rcd)
 
std::unique_ptr< HcalQIETypesproduceQIETypes (const HcalQIETypesRcd &rcd)
 
std::unique_ptr< HcalRecoParamsproduceRecoParams (const HcalRecoParamsRcd &rcd)
 
std::unique_ptr< HcalRespCorrsproduceRespCorrs (const HcalRespCorrsRcd &rcd)
 
std::unique_ptr< HcalSiPMCharacteristicsproduceSiPMCharacteristics (const HcalSiPMCharacteristicsRcd &rcd)
 
std::unique_ptr< HcalSiPMParametersproduceSiPMParameters (const HcalSiPMParametersRcd &rcd)
 
std::unique_ptr< HcalTimeCorrsproduceTimeCorrs (const HcalTimeCorrsRcd &rcd)
 
std::unique_ptr< HcalTimingParamsproduceTimingParams (const HcalTimingParamsRcd &rcd)
 
std::unique_ptr< HcalTPChannelParametersproduceTPChannelParameters (const HcalTPChannelParametersRcd &rcd)
 
std::unique_ptr< HcalTPParametersproduceTPParameters (const HcalTPParametersRcd &rcd)
 
std::unique_ptr< HcalValidationCorrsproduceValidationCorrs (const HcalValidationCorrsRcd &rcd)
 
std::unique_ptr< HcalZDCLowGainFractionsproduceZDCLowGainFractions (const HcalZDCLowGainFractionsRcd &rcd)
 
std::unique_ptr< HcalZSThresholdsproduceZSThresholds (const HcalZSThresholdsRcd &rcd)
 
void setIntervalFor (const edm::eventsetup::EventSetupRecordKey &, const edm::IOVSyncValue &, edm::ValidityInterval &) override
 
- Protected Member Functions inherited from edm::ESProducer
ESConsumesInfoconsumesInfoPushBackNew ()
 
unsigned int consumesInfoSize () const
 
template<typename CallbackT , typename TList , typename TRecord >
void registerProducts (std::shared_ptr< std::pair< unsigned int, std::shared_ptr< CallbackT >>> iCallback, const TList *, const TRecord *iRecord, const es::Label &iLabel)
 
template<typename CallbackT , typename TRecord >
void registerProducts (std::shared_ptr< std::pair< unsigned int, std::shared_ptr< CallbackT >>>, const eventsetup::produce::Null *, const TRecord *, const es::Label &)
 
template<typename T >
auto setWhatProduced (T *iThis, const es::Label &iLabel={})
 
template<typename T >
auto setWhatProduced (T *iThis, const char *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 TDecorator >
auto setWhatProduced (T *iThis, TReturn(T ::*iMethod)(const TRecord &), const TDecorator &iDec, const es::Label &iLabel={})
 
template<typename TFunc >
auto setWhatProduced (TFunc &&func, const es::Label &iLabel={})
 
template<typename TReturn , typename TRecord , typename TFunc , typename TDecorator >
ESConsumesCollectorT< TRecord > setWhatProduced (TFunc &&func, TDecorator &&iDec, const es::Label &iLabel={})
 
void usesResources (std::vector< std::string > const &)
 
- Protected Member Functions inherited from edm::ESProductResolverFactoryProducer
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::ESProductResolverFactoryBase > iFactory, const std::string &iLabel=std::string())
 
KeyedResolversVector registerResolvers (const EventSetupRecordKey &, unsigned int iovIndex) override
 
- Protected Member Functions inherited from edm::eventsetup::ESProductResolverProvider
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 &)
 

Private Types

enum  {
  kPedestals, kPedestalWidths, kEffectivePedestals, kEffectivePedestalWidths,
  kGains, kGainWidths, kPFCuts, kQIEData,
  kQIETypes, kChannelQuality, kRespCorrs, kLUTCorrs,
  kPFCorrs, kTimeCorrs, kZSThresholds, kL1TriggerObjects,
  kElectronicsMap, kValidationCorrs, kLutMetadata, kRecoParams,
  kTimingParams, kLongRecoParams, kZDCLowGainFractions, kMCParams,
  kFlagHFDigiTimeParams, kFrontEndMap, kSiPMParameters, kTPChannelParameters
}
 

Private Attributes

HcalDbHardcode dbHardcode
 
std::unique_ptr< HBHERecalibrationhb_recalibration
 
edm::ESGetToken< HBHEDarkening, HBHEDarkeningRecordhbDarkeningToken_
 
std::unique_ptr< HBHERecalibrationhe_recalibration
 
edm::ESGetToken< HBHEDarkening, HBHEDarkeningRecordheDarkeningToken_
 
std::unique_ptr< HFRecalibrationhf_recalibration
 
double iLumi
 
bool setHBdsegm
 
bool setHEdsegm
 
bool switchGainWidthsForTrigPrims
 
bool testHEPlan1
 
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_
 
bool useIeta18depth1
 
bool useLayer0Weight
 
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
 

Additional Inherited Members

- Protected Types inherited from edm::ESProductResolverFactoryProducer
using EventSetupRecordKey = eventsetup::EventSetupRecordKey
 
- Protected Types inherited from edm::eventsetup::ESProductResolverProvider
using KeyedResolversVector = std::vector< std::pair< DataKey, std::shared_ptr< ESProductResolver > >>
 

Detailed Description

Definition at line 58 of file HcalHardcodeCalibrations.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
private
Enumerator
kPedestals 
kPedestalWidths 
kEffectivePedestals 
kEffectivePedestalWidths 
kGains 
kGainWidths 
kPFCuts 
kQIEData 
kQIETypes 
kChannelQuality 
kRespCorrs 
kLUTCorrs 
kPFCorrs 
kTimeCorrs 
kZSThresholds 
kL1TriggerObjects 
kElectronicsMap 
kValidationCorrs 
kLutMetadata 
kRecoParams 
kTimingParams 
kLongRecoParams 
kZDCLowGainFractions 
kMCParams 
kFlagHFDigiTimeParams 
kFrontEndMap 
kSiPMParameters 
kTPChannelParameters 

Definition at line 119 of file HcalHardcodeCalibrations.h.

119  {
120  kPedestals,
124  kGains,
125  kGainWidths,
126  kPFCuts,
127  kQIEData,
128  kQIETypes,
130  kRespCorrs,
131  kLUTCorrs,
132  kPFCorrs,
133  kTimeCorrs,
138  kLutMetadata,
139  kRecoParams,
143  kMCParams,
145  kFrontEndMap,
148  };

Constructor & Destructor Documentation

◆ HcalHardcodeCalibrations()

HcalHardcodeCalibrations::HcalHardcodeCalibrations ( const edm::ParameterSet iConfig)

Definition at line 163 of file HcalHardcodeCalibrations.cc.

References python.cmstools::all(), DummyCfis::c, dbHardcode, edm::ParameterSet::empty(), edm::ParameterSet::exists(), edm::FileInPath::fullPath(), edm::ParameterSet::getParameter(), edm::ParameterSet::getUntrackedParameter(), hb_recalibration, hbDarkeningToken_, he_recalibration, heDarkeningToken_, hf_recalibration, iLumi, kChannelQuality, kEffectivePedestals, kEffectivePedestalWidths, kElectronicsMap, kFlagHFDigiTimeParams, kFrontEndMap, kGains, kGainWidths, kL1TriggerObjects, kLongRecoParams, kLUTCorrs, kLutMetadata, kMCParams, kPedestals, kPedestalWidths, kPFCorrs, kPFCuts, kQIEData, kQIETypes, kRecoParams, kRespCorrs, kSiPMParameters, kTimeCorrs, kTPChannelParameters, kValidationCorrs, kZDCLowGainFractions, kZSThresholds, summarizeEdmComparisonLogfiles::objectName, produceChannelQuality(), produceDcsMap(), produceDcsValues(), produceEffectivePedestals(), produceEffectivePedestalWidths(), produceElectronicsMap(), produceFlagHFDigiTimeParams(), produceFrontEndMap(), produceGains(), produceGainWidths(), produceL1TriggerObjects(), produceLongRecoParams(), produceLUTCorrs(), produceLutMetadata(), produceMCParams(), producePedestals(), producePedestalWidths(), producePFCorrs(), producePFCuts(), produceQIEData(), produceQIETypes(), produceRecoParams(), produceRespCorrs(), produceSiPMCharacteristics(), produceSiPMParameters(), produceTimeCorrs(), produceTPChannelParameters(), produceTPParameters(), produceValidationCorrs(), produceZDCLowGainFractions(), produceZSThresholds(), HcalDbHardcode::setHB(), HcalDbHardcode::setHBUpgrade(), HcalDbHardcode::setHE(), HcalDbHardcode::setHEUpgrade(), HcalDbHardcode::setHF(), HcalDbHardcode::setHFUpgrade(), HcalDbHardcode::setHO(), HcalDbHardcode::setKillHE(), HcalDbHardcode::setSiPMCharacteristics(), edm::ESProducer::setWhatProduced(), switchGainWidthsForTrigPrims, HcalDbHardcode::testHEPlan1(), testHEPlan1, HcalDbHardcode::testHFQIE10(), GlobalPosition_Frontier_DevDB_cff::toGet, topoTokens_, HcalDbHardcode::useHBUpgrade(), HcalDbHardcode::useHEUpgrade(), HcalDbHardcode::useHFUpgrade(), HcalDbHardcode::useHOUpgrade(), useIeta18depth1, useLayer0Weight, and zdcTopoTokens_.

164  : hb_recalibration(nullptr),
165  he_recalibration(nullptr),
166  hf_recalibration(nullptr),
167  setHEdsegm(false),
168  setHBdsegm(false) {
169 #ifdef EDM_ML_DEBUG
170  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::HcalHardcodeCalibrations->...";
171 #endif
172 
173  if (iConfig.exists("GainWidthsForTrigPrims"))
174  switchGainWidthsForTrigPrims = iConfig.getParameter<bool>("GainWidthsForTrigPrims");
175  else
177 
178  //DB helper preparation
186  dbHardcode.useHBUpgrade(iConfig.getParameter<bool>("useHBUpgrade"));
187  dbHardcode.useHEUpgrade(iConfig.getParameter<bool>("useHEUpgrade"));
188  dbHardcode.useHFUpgrade(iConfig.getParameter<bool>("useHFUpgrade"));
189  dbHardcode.useHOUpgrade(iConfig.getParameter<bool>("useHOUpgrade"));
190  dbHardcode.testHFQIE10(iConfig.getParameter<bool>("testHFQIE10"));
191  dbHardcode.testHEPlan1(iConfig.getParameter<bool>("testHEPlan1"));
192  dbHardcode.setKillHE(iConfig.getParameter<bool>("killHE"));
193  dbHardcode.setSiPMCharacteristics(iConfig.getParameter<std::vector<edm::ParameterSet>>("SiPMCharacteristics"));
194 
195  useLayer0Weight = iConfig.getParameter<bool>("useLayer0Weight");
196  useIeta18depth1 = iConfig.getParameter<bool>("useIeta18depth1");
197  testHEPlan1 = iConfig.getParameter<bool>("testHEPlan1");
198  // HB, HE, HF recalibration preparation
199  iLumi = iConfig.getParameter<double>("iLumi");
200 
201  if (iLumi > 0.0) {
202  bool hb_recalib = iConfig.getParameter<bool>("HBRecalibration");
203  bool he_recalib = iConfig.getParameter<bool>("HERecalibration");
204  bool hf_recalib = iConfig.getParameter<bool>("HFRecalibration");
205  if (hb_recalib) {
207  std::make_unique<HBHERecalibration>(iLumi,
208  iConfig.getParameter<double>("HBreCalibCutoff"),
209  iConfig.getParameter<edm::FileInPath>("HBmeanenergies").fullPath());
210  }
211  if (he_recalib) {
213  std::make_unique<HBHERecalibration>(iLumi,
214  iConfig.getParameter<double>("HEreCalibCutoff"),
215  iConfig.getParameter<edm::FileInPath>("HEmeanenergies").fullPath());
216  }
217  if (hf_recalib && !iConfig.getParameter<edm::ParameterSet>("HFRecalParameterBlock").empty())
219  std::make_unique<HFRecalibration>(iConfig.getParameter<edm::ParameterSet>("HFRecalParameterBlock"));
220 
221 #ifdef EDM_ML_DEBUG
222  edm::LogVerbatim("HcalCalib") << " HcalHardcodeCalibrations: iLumi = " << iLumi;
223 #endif
224  }
225 
226  std::vector<std::string> toGet = iConfig.getUntrackedParameter<std::vector<std::string>>("toGet");
227  for (auto& objectName : toGet) {
228  bool all = objectName == "all";
229 #ifdef EDM_ML_DEBUG
230  edm::LogVerbatim("HcalCalib") << "Load parameters for " << objectName;
231 #endif
232  if ((objectName == "Pedestals") || all) {
234  topoTokens_[kPedestals] = c.consumes();
235  zdcTopoTokens_[kPedestals] = c.consumes();
236  findingRecord<HcalPedestalsRcd>();
237  }
238  if ((objectName == "PedestalWidths") || all) {
240  topoTokens_[kPedestalWidths] = c.consumes();
241  zdcTopoTokens_[kPedestalWidths] = c.consumes();
242  findingRecord<HcalPedestalWidthsRcd>();
243  }
244  if ((objectName == "EffectivePedestals") || all) {
246  topoTokens_[kEffectivePedestals] = c.consumes();
247  zdcTopoTokens_[kEffectivePedestals] = c.consumes();
248  findingRecord<HcalPedestalsRcd>();
249  }
250  if ((objectName == "EffectivePedestalWidths") || all) {
251  auto c =
253  topoTokens_[kEffectivePedestalWidths] = c.consumes();
255  findingRecord<HcalPedestalWidthsRcd>();
256  }
257  if ((objectName == "Gains") || all) {
259  topoTokens_[kGains] = c.consumes();
260  zdcTopoTokens_[kGains] = c.consumes();
261  findingRecord<HcalGainsRcd>();
262  }
263  if ((objectName == "GainWidths") || all) {
265  topoTokens_[kGainWidths] = c.consumes();
266  zdcTopoTokens_[kGainWidths] = c.consumes();
267  findingRecord<HcalGainWidthsRcd>();
268  }
269  if ((objectName == "PFCuts") || all) {
271  topoTokens_[kPFCuts] = c.consumes();
272  zdcTopoTokens_[kPFCuts] = c.consumes();
273  findingRecord<HcalPFCutsRcd>();
274  }
275  if ((objectName == "QIEData") || all) {
277  topoTokens_[kQIEData] = c.consumes();
278  zdcTopoTokens_[kQIEData] = c.consumes();
279  findingRecord<HcalQIEDataRcd>();
280  }
281  if ((objectName == "QIETypes") || all) {
283  topoTokens_[kQIETypes] = c.consumes();
284  zdcTopoTokens_[kQIETypes] = c.consumes();
285  findingRecord<HcalQIETypesRcd>();
286  }
287  if ((objectName == "ChannelQuality") || (objectName == "channelQuality") || all) {
289  topoTokens_[kChannelQuality] = c.consumes();
290  zdcTopoTokens_[kChannelQuality] = c.consumes();
291  findingRecord<HcalChannelQualityRcd>();
292  }
293  if ((objectName == "ElectronicsMap") || (objectName == "electronicsMap") || all) {
295  topoTokens_[kElectronicsMap] = c.consumes();
296  zdcTopoTokens_[kElectronicsMap] = c.consumes();
297  findingRecord<HcalElectronicsMapRcd>();
298  }
299  if ((objectName == "ZSThresholds") || (objectName == "zsThresholds") || all) {
301  topoTokens_[kZSThresholds] = c.consumes();
302  zdcTopoTokens_[kZSThresholds] = c.consumes();
303  findingRecord<HcalZSThresholdsRcd>();
304  }
305  if ((objectName == "RespCorrs") || (objectName == "ResponseCorrection") || all) {
307  topoTokens_[kRespCorrs] = c.consumes();
308  zdcTopoTokens_[kRespCorrs] = c.consumes();
309  if (he_recalibration) {
310  heDarkeningToken_ = c.consumes(edm::ESInputTag("", "HE"));
311  }
312  if (hb_recalibration) {
313  hbDarkeningToken_ = c.consumes(edm::ESInputTag("", "HB"));
314  }
315  findingRecord<HcalRespCorrsRcd>();
316  }
317  if ((objectName == "LUTCorrs") || (objectName == "LUTCorrection") || all) {
319  topoTokens_[kLUTCorrs] = c.consumes();
320  zdcTopoTokens_[kLUTCorrs] = c.consumes();
321  findingRecord<HcalLUTCorrsRcd>();
322  }
323  if ((objectName == "PFCorrs") || (objectName == "PFCorrection") || all) {
325  topoTokens_[kPFCorrs] = c.consumes();
326  zdcTopoTokens_[kPFCorrs] = c.consumes();
327  findingRecord<HcalPFCorrsRcd>();
328  }
329  if ((objectName == "TimeCorrs") || (objectName == "TimeCorrection") || all) {
331  topoTokens_[kTimeCorrs] = c.consumes();
332  zdcTopoTokens_[kTimeCorrs] = c.consumes();
333  findingRecord<HcalTimeCorrsRcd>();
334  }
335  if ((objectName == "L1TriggerObjects") || (objectName == "L1Trigger") || all) {
337  topoTokens_[kL1TriggerObjects] = c.consumes();
338  zdcTopoTokens_[kL1TriggerObjects] = c.consumes();
339  findingRecord<HcalL1TriggerObjectsRcd>();
340  }
341  if ((objectName == "ValidationCorrs") || (objectName == "ValidationCorrection") || all) {
343  topoTokens_[kValidationCorrs] = c.consumes();
344  zdcTopoTokens_[kValidationCorrs] = c.consumes();
345  findingRecord<HcalValidationCorrsRcd>();
346  }
347  if ((objectName == "LutMetadata") || (objectName == "lutMetadata") || all) {
349  topoTokens_[kLutMetadata] = c.consumes();
350  zdcTopoTokens_[kLutMetadata] = c.consumes();
351  findingRecord<HcalLutMetadataRcd>();
352  }
353  if ((objectName == "DcsValues") || all) {
355  findingRecord<HcalDcsRcd>();
356  }
357  if ((objectName == "DcsMap") || (objectName == "dcsMap") || all) {
359  findingRecord<HcalDcsMapRcd>();
360  }
361  if ((objectName == "RecoParams") || all) {
363  topoTokens_[kRecoParams] = c.consumes();
364  zdcTopoTokens_[kRecoParams] = c.consumes();
365  findingRecord<HcalRecoParamsRcd>();
366  }
367  if ((objectName == "LongRecoParams") || all) {
369  topoTokens_[kLongRecoParams] = c.consumes();
370  zdcTopoTokens_[kLongRecoParams] = c.consumes();
371  findingRecord<HcalLongRecoParamsRcd>();
372  }
373  if ((objectName == "ZDCLowGainFractions") || all) {
375  topoTokens_[kZDCLowGainFractions] = c.consumes();
376  zdcTopoTokens_[kZDCLowGainFractions] = c.consumes();
377  findingRecord<HcalZDCLowGainFractionsRcd>();
378  }
379  if ((objectName == "MCParams") || all) {
381  topoTokens_[kMCParams] = c.consumes();
382  zdcTopoTokens_[kMCParams] = c.consumes();
383  findingRecord<HcalMCParamsRcd>();
384  }
385  if ((objectName == "FlagHFDigiTimeParams") || all) {
387  topoTokens_[kFlagHFDigiTimeParams] = c.consumes();
388  zdcTopoTokens_[kFlagHFDigiTimeParams] = c.consumes();
389  findingRecord<HcalFlagHFDigiTimeParamsRcd>();
390  }
391  if ((objectName == "FrontEndMap") || (objectName == "frontEndMap") || all) {
393  topoTokens_[kFrontEndMap] = c.consumes();
394  zdcTopoTokens_[kFrontEndMap] = c.consumes();
395  findingRecord<HcalFrontEndMapRcd>();
396  }
397  if ((objectName == "SiPMParameters") || all) {
399  topoTokens_[kSiPMParameters] = c.consumes();
400  zdcTopoTokens_[kSiPMParameters] = c.consumes();
401  findingRecord<HcalSiPMParametersRcd>();
402  }
403  if ((objectName == "SiPMCharacteristics") || all) {
405  findingRecord<HcalSiPMCharacteristicsRcd>();
406  }
407  if ((objectName == "TPChannelParameters") || all) {
409  topoTokens_[kTPChannelParameters] = c.consumes();
410  zdcTopoTokens_[kTPChannelParameters] = c.consumes();
411  findingRecord<HcalTPChannelParametersRcd>();
412  }
413  if ((objectName == "TPParameters") || all) {
415  findingRecord<HcalTPParametersRcd>();
416  }
417  }
418 }
std::unique_ptr< HcalPedestals > producePedestals(const HcalPedestalsRcd &rcd)
std::unique_ptr< HcalPFCuts > producePFCuts(const HcalPFCutsRcd &rcd)
Log< level::Info, true > LogVerbatim
auto setWhatProduced(T *iThis, const es::Label &iLabel={})
Definition: ESProducer.h:166
std::unique_ptr< HcalGains > produceGains(const HcalGainsRcd &rcd)
T getParameter(std::string const &) const
Definition: ParameterSet.h:307
void useHBUpgrade(bool b)
std::unique_ptr< HcalPedestalWidths > produceEffectivePedestalWidths(const HcalPedestalWidthsRcd &rcd)
std::unique_ptr< HcalPFCorrs > producePFCorrs(const HcalPFCorrsRcd &rcd)
std::unique_ptr< HcalQIEData > produceQIEData(const HcalQIEDataRcd &rcd)
void setHBUpgrade(HcalHardcodeParameters p)
def all(container)
workaround iterator generators for ROOT classes
Definition: cmstools.py:25
std::string fullPath() const
Definition: FileInPath.cc:161
void testHEPlan1(bool b)
std::unique_ptr< HcalTimeCorrs > produceTimeCorrs(const HcalTimeCorrsRcd &rcd)
void useHFUpgrade(bool b)
std::unique_ptr< HcalLongRecoParams > produceLongRecoParams(const HcalLongRecoParamsRcd &rcd)
std::unique_ptr< HcalPedestals > produceEffectivePedestals(const HcalPedestalsRcd &rcd)
std::unique_ptr< HcalSiPMCharacteristics > produceSiPMCharacteristics(const HcalSiPMCharacteristicsRcd &rcd)
bool exists(std::string const &parameterName) const
checks if a parameter exists
edm::ESGetToken< HBHEDarkening, HBHEDarkeningRecord > hbDarkeningToken_
std::unique_ptr< HcalElectronicsMap > produceElectronicsMap(const HcalElectronicsMapRcd &rcd)
void setHF(HcalHardcodeParameters p)
std::unique_ptr< HcalDcsValues > produceDcsValues(const HcalDcsRcd &rcd)
T getUntrackedParameter(std::string const &, T const &) const
std::unique_ptr< HcalPedestalWidths > producePedestalWidths(const HcalPedestalWidthsRcd &rcd)
std::unique_ptr< HFRecalibration > hf_recalibration
std::unique_ptr< HcalRespCorrs > produceRespCorrs(const HcalRespCorrsRcd &rcd)
std::unique_ptr< HcalLutMetadata > produceLutMetadata(const HcalLutMetadataRcd &rcd)
void setHO(HcalHardcodeParameters p)
bool empty() const
Definition: ParameterSet.h:202
void setHFUpgrade(HcalHardcodeParameters p)
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
void setHE(HcalHardcodeParameters p)
void setKillHE(bool b)
std::unique_ptr< HcalFlagHFDigiTimeParams > produceFlagHFDigiTimeParams(const HcalFlagHFDigiTimeParamsRcd &rcd)
std::unique_ptr< HcalFrontEndMap > produceFrontEndMap(const HcalFrontEndMapRcd &rcd)
std::unique_ptr< HBHERecalibration > hb_recalibration
void useHOUpgrade(bool b)
std::unique_ptr< HcalSiPMParameters > produceSiPMParameters(const HcalSiPMParametersRcd &rcd)
std::unique_ptr< HBHERecalibration > he_recalibration
std::unique_ptr< HcalRecoParams > produceRecoParams(const HcalRecoParamsRcd &rcd)
void setHB(HcalHardcodeParameters p)
std::unique_ptr< HcalTPParameters > produceTPParameters(const HcalTPParametersRcd &rcd)
std::unique_ptr< HcalGainWidths > produceGainWidths(const HcalGainWidthsRcd &rcd)
std::unique_ptr< HcalTPChannelParameters > produceTPChannelParameters(const HcalTPChannelParametersRcd &rcd)
std::unique_ptr< HcalL1TriggerObjects > produceL1TriggerObjects(const HcalL1TriggerObjectsRcd &rcd)
std::unique_ptr< HcalZSThresholds > produceZSThresholds(const HcalZSThresholdsRcd &rcd)
std::unique_ptr< HcalZDCLowGainFractions > produceZDCLowGainFractions(const HcalZDCLowGainFractionsRcd &rcd)
void setSiPMCharacteristics(std::vector< edm::ParameterSet > vps)
std::unique_ptr< HcalMCParams > produceMCParams(const HcalMCParamsRcd &rcd)
void useHEUpgrade(bool b)
std::unique_ptr< HcalQIETypes > produceQIETypes(const HcalQIETypesRcd &rcd)
std::unique_ptr< HcalChannelQuality > produceChannelQuality(const HcalChannelQualityRcd &rcd)
edm::ESGetToken< HBHEDarkening, HBHEDarkeningRecord > heDarkeningToken_
void setHEUpgrade(HcalHardcodeParameters p)
std::unique_ptr< HcalDcsMap > produceDcsMap(const HcalDcsMapRcd &rcd)
std::unique_ptr< HcalLUTCorrs > produceLUTCorrs(const HcalLUTCorrsRcd &rcd)
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_
void testHFQIE10(bool b)
std::unique_ptr< HcalValidationCorrs > produceValidationCorrs(const HcalValidationCorrsRcd &rcd)

◆ ~HcalHardcodeCalibrations()

HcalHardcodeCalibrations::~HcalHardcodeCalibrations ( )
override

Definition at line 420 of file HcalHardcodeCalibrations.cc.

420 {}

Member Function Documentation

◆ fillDescriptions()

void HcalHardcodeCalibrations::fillDescriptions ( edm::ConfigurationDescriptions descriptions)
static

Definition at line 1044 of file HcalHardcodeCalibrations.cc.

References edm::ParameterSetDescription::add(), edm::ConfigurationDescriptions::addDefault(), and submitPVResolutionJobs::desc.

1044  {
1046  desc.add<double>("iLumi", -1.);
1047  desc.add<bool>("HBRecalibration", false);
1048  desc.add<double>("HBreCalibCutoff", 20.);
1049  desc.add<edm::FileInPath>("HBmeanenergies", edm::FileInPath("CalibCalorimetry/HcalPlugins/data/meanenergiesHB.txt"));
1050  desc.add<bool>("HERecalibration", false);
1051  desc.add<double>("HEreCalibCutoff", 20.);
1052  desc.add<edm::FileInPath>("HEmeanenergies", edm::FileInPath("CalibCalorimetry/HcalPlugins/data/meanenergiesHE.txt"));
1053  desc.add<bool>("HFRecalibration", false);
1054  desc.add<bool>("GainWidthsForTrigPrims", false);
1055  desc.add<bool>("useHBUpgrade", false);
1056  desc.add<bool>("useHEUpgrade", false);
1057  desc.add<bool>("useHFUpgrade", false);
1058  desc.add<bool>("useHOUpgrade", true);
1059  desc.add<bool>("testHFQIE10", false);
1060  desc.add<bool>("testHEPlan1", false);
1061  desc.add<bool>("killHE", false);
1062  desc.add<bool>("useLayer0Weight", false);
1063  desc.add<bool>("useIeta18depth1", true);
1064  desc.addUntracked<std::vector<std::string>>("toGet", std::vector<std::string>());
1065  desc.addUntracked<bool>("fromDDD", false);
1066 
1068  desc_hb.add<std::vector<double>>("gain", std::vector<double>({0.19}));
1069  desc_hb.add<std::vector<double>>("gainWidth", std::vector<double>({0.0}));
1070  desc_hb.add<double>("pedestal", 3.0);
1071  desc_hb.add<double>("pedestalWidth", 0.55);
1072  desc_hb.add<int>("zsThreshold", 8);
1073  desc_hb.add<std::vector<double>>("qieOffset", std::vector<double>({-0.49, 1.8, 7.2, 37.9}));
1074  desc_hb.add<std::vector<double>>("qieSlope", std::vector<double>({0.912, 0.917, 0.922, 0.923}));
1075  desc_hb.add<int>("qieType", 0);
1076  desc_hb.add<int>("mcShape", 125);
1077  desc_hb.add<int>("recoShape", 105);
1078  desc_hb.add<double>("photoelectronsToAnalog", 0.0);
1079  desc_hb.add<std::vector<double>>("darkCurrent", std::vector<double>({0.0}));
1080  desc_hb.add<std::vector<double>>("noiseCorrelation", std::vector<double>({0.0}));
1081  desc_hb.add<bool>("doRadiationDamage", false);
1082  desc_hb.add<double>("noiseThreshold", 0.0);
1083  desc_hb.add<double>("seedThreshold", 0.1);
1084  desc.add<edm::ParameterSetDescription>("hb", desc_hb);
1085 
1086  edm::ParameterSetDescription desc_hbRaddam;
1087  desc_hbRaddam.add<double>("temperatureBase", 20.0);
1088  desc_hbRaddam.add<double>("temperatureNew", -5.0);
1089  desc_hbRaddam.add<double>("intlumiOffset", 150);
1090  desc_hbRaddam.add<double>("depVsTemp", 0.0631);
1091  desc_hbRaddam.add<double>("intlumiToNeutrons", 3.67e8);
1092  desc_hbRaddam.add<std::vector<double>>("depVsNeutrons", {5.69e-11, 7.90e-11});
1093 
1094  edm::ParameterSetDescription desc_hbUpgrade;
1095  desc_hbUpgrade.add<std::vector<double>>("gain", std::vector<double>({0.00111111111111}));
1096  desc_hbUpgrade.add<std::vector<double>>("gainWidth", std::vector<double>({0}));
1097  desc_hbUpgrade.add<double>("pedestal", 18.0);
1098  desc_hbUpgrade.add<double>("pedestalWidth", 5.0);
1099  desc_hbUpgrade.add<int>("zsThreshold", 3);
1100  desc_hbUpgrade.add<std::vector<double>>("qieOffset", std::vector<double>({0.0, 0.0, 0.0, 0.0}));
1101  desc_hbUpgrade.add<std::vector<double>>("qieSlope", std::vector<double>({0.333, 0.333, 0.333, 0.333}));
1102  desc_hbUpgrade.add<int>("qieType", 2);
1103  desc_hbUpgrade.add<int>("mcShape", 206);
1104  desc_hbUpgrade.add<int>("recoShape", 206);
1105  desc_hbUpgrade.add<double>("photoelectronsToAnalog", 57.5);
1106  desc_hbUpgrade.add<std::vector<double>>("darkCurrent", std::vector<double>({0.055}));
1107  desc_hbUpgrade.add<std::vector<double>>("noiseCorrelation", std::vector<double>({0.26}));
1108  desc_hbUpgrade.add<bool>("doRadiationDamage", true);
1109  desc_hbUpgrade.add<edm::ParameterSetDescription>("radiationDamage", desc_hbRaddam);
1110  desc_hbUpgrade.add<double>("noiseThreshold", 0.0);
1111  desc_hbUpgrade.add<double>("seedThreshold", 0.1);
1112  desc.add<edm::ParameterSetDescription>("hbUpgrade", desc_hbUpgrade);
1113 
1115  desc_he.add<std::vector<double>>("gain", std::vector<double>({0.23}));
1116  desc_he.add<std::vector<double>>("gainWidth", std::vector<double>({0}));
1117  desc_he.add<double>("pedestal", 3.0);
1118  desc_he.add<double>("pedestalWidth", 0.79);
1119  desc_he.add<int>("zsThreshold", 9);
1120  desc_he.add<std::vector<double>>("qieOffset", std::vector<double>({-0.38, 2.0, 7.6, 39.6}));
1121  desc_he.add<std::vector<double>>("qieSlope", std::vector<double>({0.912, 0.916, 0.92, 0.922}));
1122  desc_he.add<int>("qieType", 0);
1123  desc_he.add<int>("mcShape", 125);
1124  desc_he.add<int>("recoShape", 105);
1125  desc_he.add<double>("photoelectronsToAnalog", 0.0);
1126  desc_he.add<std::vector<double>>("darkCurrent", std::vector<double>({0.0}));
1127  desc_he.add<std::vector<double>>("noiseCorrelation", std::vector<double>({0.0}));
1128  desc_he.add<bool>("doRadiationDamage", false);
1129  desc_he.add<double>("noiseThreshold", 0.0);
1130  desc_he.add<double>("seedThreshold", 0.1);
1131  desc.add<edm::ParameterSetDescription>("he", desc_he);
1132 
1133  edm::ParameterSetDescription desc_heRaddam;
1134  desc_heRaddam.add<double>("temperatureBase", 20.0);
1135  desc_heRaddam.add<double>("temperatureNew", 5.0);
1136  desc_heRaddam.add<double>("intlumiOffset", 75);
1137  desc_heRaddam.add<double>("depVsTemp", 0.0631);
1138  desc_heRaddam.add<double>("intlumiToNeutrons", 2.92e8);
1139  desc_heRaddam.add<std::vector<double>>("depVsNeutrons", {5.69e-11, 7.90e-11});
1140 
1141  edm::ParameterSetDescription desc_heUpgrade;
1142  desc_heUpgrade.add<std::vector<double>>("gain", std::vector<double>({0.00111111111111}));
1143  desc_heUpgrade.add<std::vector<double>>("gainWidth", std::vector<double>({0}));
1144  desc_heUpgrade.add<double>("pedestal", 18.0);
1145  desc_heUpgrade.add<double>("pedestalWidth", 5.0);
1146  desc_heUpgrade.add<int>("zsThreshold", 3);
1147  desc_heUpgrade.add<std::vector<double>>("qieOffset", std::vector<double>({0.0, 0.0, 0.0, 0.0}));
1148  desc_heUpgrade.add<std::vector<double>>("qieSlope", std::vector<double>({0.333, 0.333, 0.333, 0.333}));
1149  desc_heUpgrade.add<int>("qieType", 2);
1150  desc_heUpgrade.add<int>("mcShape", 206);
1151  desc_heUpgrade.add<int>("recoShape", 206);
1152  desc_heUpgrade.add<double>("photoelectronsToAnalog", 57.5);
1153  desc_heUpgrade.add<std::vector<double>>("darkCurrent", std::vector<double>({0.055}));
1154  desc_heUpgrade.add<std::vector<double>>("noiseCorrelation", std::vector<double>({0.26}));
1155  desc_heUpgrade.add<bool>("doRadiationDamage", true);
1156  desc_heUpgrade.add<edm::ParameterSetDescription>("radiationDamage", desc_heRaddam);
1157  desc_heUpgrade.add<double>("noiseThreshold", 0.0);
1158  desc_heUpgrade.add<double>("seedThreshold", 0.1);
1159  desc.add<edm::ParameterSetDescription>("heUpgrade", desc_heUpgrade);
1160 
1162  desc_hf.add<std::vector<double>>("gain", std::vector<double>({0.14, 0.135}));
1163  desc_hf.add<std::vector<double>>("gainWidth", std::vector<double>({0.0, 0.0}));
1164  desc_hf.add<double>("pedestal", 3.0);
1165  desc_hf.add<double>("pedestalWidth", 0.84);
1166  desc_hf.add<int>("zsThreshold", -9999);
1167  desc_hf.add<std::vector<double>>("qieOffset", std::vector<double>({-0.87, 1.4, 7.8, -29.6}));
1168  desc_hf.add<std::vector<double>>("qieSlope", std::vector<double>({0.359, 0.358, 0.36, 0.367}));
1169  desc_hf.add<int>("qieType", 0);
1170  desc_hf.add<int>("mcShape", 301);
1171  desc_hf.add<int>("recoShape", 301);
1172  desc_hf.add<double>("photoelectronsToAnalog", 0.0);
1173  desc_hf.add<std::vector<double>>("darkCurrent", std::vector<double>({0.0}));
1174  desc_hf.add<std::vector<double>>("noiseCorrelation", std::vector<double>({0.0}));
1175  desc_hf.add<bool>("doRadiationDamage", false);
1176  desc_hf.add<double>("noiseThreshold", 0.0);
1177  desc_hf.add<double>("seedThreshold", 0.1);
1178  desc.add<edm::ParameterSetDescription>("hf", desc_hf);
1179 
1180  edm::ParameterSetDescription desc_hfUpgrade;
1181  desc_hfUpgrade.add<std::vector<double>>("gain", std::vector<double>({0.14, 0.135}));
1182  desc_hfUpgrade.add<std::vector<double>>("gainWidth", std::vector<double>({0.0, 0.0}));
1183  desc_hfUpgrade.add<double>("pedestal", 13.33);
1184  desc_hfUpgrade.add<double>("pedestalWidth", 3.33);
1185  desc_hfUpgrade.add<int>("zsThreshold", -9999);
1186  desc_hfUpgrade.add<std::vector<double>>("qieOffset", std::vector<double>({0.0697, -0.7405, 12.38, -671.9}));
1187  desc_hfUpgrade.add<std::vector<double>>("qieSlope", std::vector<double>({0.297, 0.298, 0.298, 0.313}));
1188  desc_hfUpgrade.add<int>("qieType", 1);
1189  desc_hfUpgrade.add<int>("mcShape", 301);
1190  desc_hfUpgrade.add<int>("recoShape", 301);
1191  desc_hfUpgrade.add<double>("photoelectronsToAnalog", 0.0);
1192  desc_hfUpgrade.add<std::vector<double>>("darkCurrent", std::vector<double>({0.0}));
1193  desc_hfUpgrade.add<std::vector<double>>("noiseCorrelation", std::vector<double>({0.0}));
1194  desc_hfUpgrade.add<bool>("doRadiationDamage", false);
1195  desc_hfUpgrade.add<double>("noiseThreshold", 0.0);
1196  desc_hfUpgrade.add<double>("seedThreshold", 0.1);
1197  desc.add<edm::ParameterSetDescription>("hfUpgrade", desc_hfUpgrade);
1198 
1199  edm::ParameterSetDescription desc_hfrecal;
1200  desc_hfrecal.add<std::vector<double>>("HFdepthOneParameterA", std::vector<double>());
1201  desc_hfrecal.add<std::vector<double>>("HFdepthOneParameterB", std::vector<double>());
1202  desc_hfrecal.add<std::vector<double>>("HFdepthTwoParameterA", std::vector<double>());
1203  desc_hfrecal.add<std::vector<double>>("HFdepthTwoParameterB", std::vector<double>());
1204  desc.add<edm::ParameterSetDescription>("HFRecalParameterBlock", desc_hfrecal);
1205 
1207  desc_ho.add<std::vector<double>>("gain", std::vector<double>({0.006, 0.0087}));
1208  desc_ho.add<std::vector<double>>("gainWidth", std::vector<double>({0.0, 0.0}));
1209  desc_ho.add<double>("pedestal", 11.0);
1210  desc_ho.add<double>("pedestalWidth", 0.57);
1211  desc_ho.add<int>("zsThreshold", 24);
1212  desc_ho.add<std::vector<double>>("qieOffset", std::vector<double>({-0.44, 1.4, 7.1, 38.5}));
1213  desc_ho.add<std::vector<double>>("qieSlope", std::vector<double>({0.907, 0.915, 0.92, 0.921}));
1214  desc_ho.add<int>("qieType", 0);
1215  desc_ho.add<int>("mcShape", 201);
1216  desc_ho.add<int>("recoShape", 201);
1217  desc_ho.add<double>("photoelectronsToAnalog", 4.0);
1218  desc_ho.add<std::vector<double>>("darkCurrent", std::vector<double>({0.0}));
1219  desc_ho.add<std::vector<double>>("noiseCorrelation", std::vector<double>({0.0}));
1220  desc_ho.add<bool>("doRadiationDamage", false);
1221  desc_ho.add<double>("noiseThreshold", 0.0);
1222  desc_ho.add<double>("seedThreshold", 0.1);
1223  desc.add<edm::ParameterSetDescription>("ho", desc_ho);
1224 
1225  edm::ParameterSetDescription validator_sipm;
1226  validator_sipm.add<int>("pixels", 1);
1227  validator_sipm.add<double>("crosstalk", 0);
1228  validator_sipm.add<double>("nonlin1", 1);
1229  validator_sipm.add<double>("nonlin2", 0);
1230  validator_sipm.add<double>("nonlin3", 0);
1231  std::vector<edm::ParameterSet> default_sipm(1);
1232  desc.addVPSet("SiPMCharacteristics", validator_sipm, default_sipm);
1233 
1234  descriptions.addDefault(desc);
1235 }
void addDefault(ParameterSetDescription const &psetDescription)
ParameterDescriptionBase * add(U const &iLabel, T const &value)

◆ produceChannelQuality()

std::unique_ptr< HcalChannelQuality > HcalHardcodeCalibrations::produceChannelQuality ( const HcalChannelQualityRcd rcd)
protected

Definition at line 588 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, hcalRecHitTable_cff::depth, HcalDetId::depth(), edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), hcalRecHitTable_cff::ieta, HcalDetId::ieta(), HcalDetId::ietaAbs(), hcalRecHitTable_cff::iphi, HcalDetId::iphi(), B2GTnPMonitor_cfi::item, kChannelQuality, HcalDbHardcode::killHE(), mps_fire::result, mps_update::status, testHEPlan1, topoTokens_, useIeta18depth1, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

588  {
589 #ifdef EDM_ML_DEBUG
590  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceChannelQuality-> ...";
591 #endif
592  auto const& topo = rcd.get(topoTokens_[kChannelQuality]);
593  auto const& zdcTopo = rcd.get(zdcTopoTokens_[kChannelQuality]);
594 
595  auto result = std::make_unique<HcalChannelQuality>(&topo);
596  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
597  for (auto cell : cells) {
598  // Special: removal of (non-instrumented) layer "-1"("nose") = depth 1
599  // from Upgrade HE, either from
600  // (i) HEP17 sector in 2017 or
601  // (ii) the entire HE rin=18 from 2018 through Run 3.
602  // May require a revision by 2021.
603 
604  uint32_t status = 0;
605 
606  if (!(cell.isHcalZDCDetId())) {
607  HcalDetId hid = HcalDetId(cell);
608  int iphi = hid.iphi();
609  int ieta = hid.ieta();
610  int absieta = hid.ietaAbs();
611  int depth = hid.depth();
612 
613  // specific HEP17 sector (2017 only)
614  bool isHEP17 = (iphi >= 63) && (iphi <= 66) && (ieta > 0);
615  // |ieta|=18, depth=1
616  bool is18d1 = (absieta == 18) && (depth == 1);
617 
618  if ((!useIeta18depth1 && is18d1) && ((testHEPlan1 && isHEP17) || (!testHEPlan1))) {
619  status = 0x8002; // dead cell
620  }
621  }
622 
623  HcalChannelStatus item(cell.rawId(), status);
624  result->addValues(item);
625  }
626 
627  return result;
628 }
Log< level::Info, true > LogVerbatim
constexpr int ietaAbs() const
get the absolute value of the cell ieta
Definition: HcalDetId.h:148
const bool killHE() const
constexpr int ieta() const
get the cell ieta
Definition: HcalDetId.h:155
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
constexpr int iphi() const
get the cell iphi
Definition: HcalDetId.h:157
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_
constexpr int depth() const
get the tower depth
Definition: HcalDetId.h:164

◆ produceDcsMap()

std::unique_ptr< HcalDcsMap > HcalHardcodeCalibrations::produceDcsMap ( const HcalDcsMapRcd rcd)
protected

Definition at line 852 of file HcalHardcodeCalibrations.cc.

References dbHardcode, and HcalDbHardcode::makeHardcodeDcsMap().

Referenced by HcalHardcodeCalibrations().

852  {
853 #ifdef EDM_ML_DEBUG
854  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceDcsMap-> ...";
855 #endif
857 }
Log< level::Info, true > LogVerbatim
std::unique_ptr< HcalDcsMap > makeHardcodeDcsMap() const

◆ produceDcsValues()

std::unique_ptr< HcalDcsValues > HcalHardcodeCalibrations::produceDcsValues ( const HcalDcsRcd rcd)
protected

Definition at line 844 of file HcalHardcodeCalibrations.cc.

References mps_fire::result.

Referenced by HcalHardcodeCalibrations().

844  {
845 #ifdef EDM_ML_DEBUG
846  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceDcsValues-> ...";
847 #endif
848  auto result = std::make_unique<HcalDcsValues>();
849  return result;
850 }
Log< level::Info, true > LogVerbatim

◆ produceEffectivePedestals()

std::unique_ptr< HcalPedestals > HcalHardcodeCalibrations::produceEffectivePedestals ( const HcalPedestalsRcd rcd)
protected

Definition at line 480 of file HcalHardcodeCalibrations.cc.

References kEffectivePedestals, producePedestals_(), topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

480  {
482 }
std::unique_ptr< HcalPedestals > producePedestals_(const HcalPedestalsRcd &rcd, const edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > &, const edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > &, bool eff)
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceEffectivePedestalWidths()

std::unique_ptr< HcalPedestalWidths > HcalHardcodeCalibrations::produceEffectivePedestalWidths ( const HcalPedestalWidthsRcd rcd)
protected

Definition at line 488 of file HcalHardcodeCalibrations.cc.

References kEffectivePedestalWidths, producePedestalWidths_(), topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

489  {
490  return producePedestalWidths_(
492 }
std::unique_ptr< HcalPedestalWidths > producePedestalWidths_(const HcalPedestalWidthsRcd &rcd, const edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > &, const edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > &, bool eff)
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceElectronicsMap()

std::unique_ptr< HcalElectronicsMap > HcalHardcodeCalibrations::produceElectronicsMap ( const HcalElectronicsMapRcd rcd)
protected

Definition at line 787 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), kElectronicsMap, HcalDbHardcode::killHE(), HcalDbHardcode::makeHardcodeMap(), topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

787  {
788 #ifdef EDM_ML_DEBUG
789  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceElectronicsMap-> ...";
790 #endif
791  auto const& topo = rcd.get(topoTokens_[kElectronicsMap]);
792  auto const& zdcTopo = rcd.get(zdcTopoTokens_[kElectronicsMap]);
793 
794  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
796 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
std::unique_ptr< HcalElectronicsMap > makeHardcodeMap(const std::vector< HcalGenericDetId > &cells) const
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceFlagHFDigiTimeParams()

std::unique_ptr< HcalFlagHFDigiTimeParams > HcalHardcodeCalibrations::produceFlagHFDigiTimeParams ( const HcalFlagHFDigiTimeParamsRcd rcd)
protected

Definition at line 949 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), B2GTnPMonitor_cfi::item, kFlagHFDigiTimeParams, HcalDbHardcode::killHE(), mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

950  {
951 #ifdef EDM_ML_DEBUG
952  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceFlagHFDigiTimeParams-> ...";
953 #endif
954  auto const& topo = rec.get(topoTokens_[kFlagHFDigiTimeParams]);
955  auto const& zdcTopo = rec.get(zdcTopoTokens_[kFlagHFDigiTimeParams]);
956 
957  auto result = std::make_unique<HcalFlagHFDigiTimeParams>(&topo);
958  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
959 
960  std::vector<double> coef;
961  coef.push_back(0.93);
962  coef.push_back(-0.38275);
963  coef.push_back(-0.012667);
964 
965  for (auto cell : cells) {
966  HcalFlagHFDigiTimeParam item(cell.rawId(),
967  1, //firstsample
968  3, // samplestoadd
969  2, //expectedpeak
970  40., // min energy threshold
971  coef // coefficients
972  );
973  result->addValues(item);
974  }
975  return result;
976 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceFrontEndMap()

std::unique_ptr< HcalFrontEndMap > HcalHardcodeCalibrations::produceFrontEndMap ( const HcalFrontEndMapRcd rcd)
protected

Definition at line 978 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), kFrontEndMap, HcalDbHardcode::killHE(), HcalDbHardcode::makeHardcodeFrontEndMap(), topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

978  {
979 #ifdef EDM_ML_DEBUG
980  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceFrontEndMap-> ...";
981 #endif
982  auto const& topo = rec.get(topoTokens_[kFrontEndMap]);
983  auto const& zdcTopo = rec.get(zdcTopoTokens_[kFrontEndMap]);
984 
985  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
986 
988 }
Log< level::Info, true > LogVerbatim
void makeHardcodeFrontEndMap(HcalFrontEndMap &emap, const std::vector< HcalGenericDetId > &cells) const
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceGains()

std::unique_ptr< HcalGains > HcalHardcodeCalibrations::produceGains ( const HcalGainsRcd rcd)
protected

Definition at line 494 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, B2GTnPMonitor_cfi::item, kGains, HcalDbHardcode::killHE(), HcalDbHardcode::makeGain(), mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

494  {
495 #ifdef EDM_ML_DEBUG
496  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceGains-> ...";
497 #endif
498  auto const& topo = rec.get(topoTokens_[kGains]);
499  auto const& zdcTopo = rec.get(zdcTopoTokens_[kGains]);
500  auto result = std::make_unique<HcalGains>(&topo);
501  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
502  for (auto cell : cells) {
504  result->addValues(item);
505  }
506  return result;
507 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
HcalGain makeGain(HcalGenericDetId fId, bool fSmear=false) const
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceGainWidths()

std::unique_ptr< HcalGainWidths > HcalHardcodeCalibrations::produceGainWidths ( const HcalGainWidthsRcd rcd)
protected

Definition at line 509 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, TauDecayModes::dec, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), B2GTnPMonitor_cfi::item, kGainWidths, HcalDbHardcode::killHE(), HcalDbHardcode::makeGainWidth(), mps_fire::result, switchGainWidthsForTrigPrims, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

509  {
510 #ifdef EDM_ML_DEBUG
511  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceGainWidths-> ...";
512 #endif
513  auto const& topo = rec.get(topoTokens_[kGainWidths]);
514  auto const& zdcTopo = rec.get(zdcTopoTokens_[kGainWidths]);
515  auto result = std::make_unique<HcalGainWidths>(&topo);
516  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
517  for (auto cell : cells) {
518  // for Upgrade - include TrigPrims, for regular case - only HcalDetId
520 #ifdef EDM_ML_DEBUG
521  edm::LogVerbatim("HcalCalib") << " HcalGainWidths cell (with TPs) : " << std::hex << cell.rawId() << std::dec
522  << " " << cell;
523 #endif
525  result->addValues(item);
526  } else if (!cell.isHcalTrigTowerDetId()) {
527 #ifdef EDM_ML_DEBUG
528  edm::LogVerbatim("HcalCalib") << " HcalGainWidths cell (without TPs) : " << std::hex << cell.rawId() << std::dec
529  << " " << cell;
530 #endif
532  result->addValues(item);
533  }
534  }
535  return result;
536 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
HcalGainWidth makeGainWidth(HcalGenericDetId fId) const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceL1TriggerObjects()

std::unique_ptr< HcalL1TriggerObjects > HcalHardcodeCalibrations::produceL1TriggerObjects ( const HcalL1TriggerObjectsRcd rcd)
protected

Definition at line 767 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kL1TriggerObjects, mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

768  {
769 #ifdef EDM_ML_DEBUG
770  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceL1TriggerObjects-> ...";
771 #endif
772  auto const& topo = rcd.get(topoTokens_[kL1TriggerObjects]);
773  auto const& zdcTopo = rcd.get(zdcTopoTokens_[kL1TriggerObjects]);
774 
775  auto result = std::make_unique<HcalL1TriggerObjects>(&topo);
776  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
777  for (auto cell : cells) {
778  HcalL1TriggerObject item(cell.rawId(), 0., 1., 0);
779  result->addValues(item);
780  }
781  // add tag and algo values
782  result->setTagString("hardcoded");
783  result->setAlgoString("hardcoded");
784  return result;
785 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceLongRecoParams()

std::unique_ptr< HcalLongRecoParams > HcalHardcodeCalibrations::produceLongRecoParams ( const HcalLongRecoParamsRcd rcd)
protected

Definition at line 891 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kLongRecoParams, mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

891  {
892 #ifdef EDM_ML_DEBUG
893  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceLongRecoParams-> ...";
894 #endif
895  auto const& topo = rec.get(topoTokens_[kLongRecoParams]);
896  auto const& zdcTopo = rec.get(zdcTopoTokens_[kLongRecoParams]);
897 
898  auto result = std::make_unique<HcalLongRecoParams>(&topo);
899  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
900  std::vector<unsigned int> mSignal;
901  mSignal.push_back(4);
902  mSignal.push_back(5);
903  mSignal.push_back(6);
904  std::vector<unsigned int> mNoise;
905  mNoise.push_back(1);
906  mNoise.push_back(2);
907  mNoise.push_back(3);
908  for (auto cell : cells) {
909  if (cell.isHcalZDCDetId()) {
910  HcalLongRecoParam item(cell.rawId(), mSignal, mNoise);
911  result->addValues(item);
912  }
913  }
914  return result;
915 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceLUTCorrs()

std::unique_ptr< HcalLUTCorrs > HcalHardcodeCalibrations::produceLUTCorrs ( const HcalLUTCorrsRcd rcd)
protected

Definition at line 703 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kLUTCorrs, mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

703  {
704 #ifdef EDM_ML_DEBUG
705  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceLUTCorrs-> ...";
706 #endif
707  auto const& topo = rcd.get(topoTokens_[kLUTCorrs]);
708  auto const& zdcTopo = rcd.get(zdcTopoTokens_[kLUTCorrs]);
709 
710  auto result = std::make_unique<HcalLUTCorrs>(&topo);
711  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
712  for (auto cell : cells) {
713  HcalLUTCorr item(cell.rawId(), 1.0);
714  result->addValues(item);
715  }
716  return result;
717 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceLutMetadata()

std::unique_ptr< HcalLutMetadata > HcalHardcodeCalibrations::produceLutMetadata ( const HcalLutMetadataRcd rcd)
protected

Definition at line 815 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kLutMetadata, mps_fire::result, DiMuonV_cfg::threshold, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

815  {
816 #ifdef EDM_ML_DEBUG
817  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceLutMetadata-> ...";
818 #endif
819  auto const& topo = rcd.get(topoTokens_[kLutMetadata]);
820  auto const& zdcTopo = rcd.get(zdcTopoTokens_[kLutMetadata]);
821 
822  auto result = std::make_unique<HcalLutMetadata>(&topo);
823 
824  result->setRctLsb(0.5);
825  result->setNominalGain(0.177); // for HBHE SiPMs
826 
827  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
828  for (const auto& cell : cells) {
829  float rcalib = 1.;
830  int granularity = 1;
831  int threshold = 0;
832 
833  if (cell.isHcalTrigTowerDetId()) {
834  rcalib = 0.;
835  }
836 
837  HcalLutMetadatum item(cell.rawId(), rcalib, granularity, threshold);
838  result->addValues(item);
839  }
840 
841  return result;
842 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceMCParams()

std::unique_ptr< HcalMCParams > HcalHardcodeCalibrations::produceMCParams ( const HcalMCParamsRcd rcd)
protected

Definition at line 934 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kMCParams, HcalDbHardcode::makeMCParam(), mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

934  {
935 #ifdef EDM_ML_DEBUG
936  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceMCParams-> ...";
937 #endif
938  auto const& topo = rec.get(topoTokens_[kMCParams]);
939  auto const& zdcTopo = rec.get(zdcTopoTokens_[kMCParams]);
940  auto result = std::make_unique<HcalMCParams>(&topo);
941  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
942  for (auto cell : cells) {
944  result->addValues(item);
945  }
946  return result;
947 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
HcalMCParam makeMCParam(HcalGenericDetId fId) const
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ producePedestals()

std::unique_ptr< HcalPedestals > HcalHardcodeCalibrations::producePedestals ( const HcalPedestalsRcd rcd)
protected

Definition at line 476 of file HcalHardcodeCalibrations.cc.

References kPedestals, producePedestals_(), topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

476  {
478 }
std::unique_ptr< HcalPedestals > producePedestals_(const HcalPedestalsRcd &rcd, const edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > &, const edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > &, bool eff)
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ producePedestals_()

std::unique_ptr< HcalPedestals > HcalHardcodeCalibrations::producePedestals_ ( const HcalPedestalsRcd rcd,
const edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > &  token,
const edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > &  zdctoken,
bool  eff 
)
protected

Definition at line 436 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), iLumi, B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), HcalDbHardcode::makePedestal(), mps_fire::result, AlCaHLTBitMon_QueryRunRegistry::string, and unpackBuffers-CaloStage2::token.

Referenced by produceEffectivePedestals(), and producePedestals().

440  {
441  std::string seff = eff ? "Effective" : "";
442 #ifdef EDM_ML_DEBUG
443  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produce" << seff << "Pedestals-> ...";
444 #endif
445  auto const& topo = rec.get(token);
446  auto const& zdcTopo = rec.get(zdctoken);
447  auto result = std::make_unique<HcalPedestals>(&topo, false);
448  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
449  for (auto cell : cells) {
450  HcalPedestal item = dbHardcode.makePedestal(cell, false, eff, &topo, iLumi);
451  result->addValues(item);
452  }
453  return result;
454 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
HcalPedestal makePedestal(HcalGenericDetId fId, bool fSmear, bool eff, const HcalTopology *topo, double intlumi)

◆ producePedestalWidths()

std::unique_ptr< HcalPedestalWidths > HcalHardcodeCalibrations::producePedestalWidths ( const HcalPedestalWidthsRcd rcd)
protected

Definition at line 484 of file HcalHardcodeCalibrations.cc.

References kPedestalWidths, producePedestalWidths_(), topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

484  {
486 }
std::unique_ptr< HcalPedestalWidths > producePedestalWidths_(const HcalPedestalWidthsRcd &rcd, const edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > &, const edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > &, bool eff)
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ producePedestalWidths_()

std::unique_ptr< HcalPedestalWidths > HcalHardcodeCalibrations::producePedestalWidths_ ( const HcalPedestalWidthsRcd rcd,
const edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > &  token,
const edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > &  zdctoken,
bool  eff 
)
protected

Definition at line 456 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), iLumi, B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), HcalDbHardcode::makePedestalWidth(), mps_fire::result, AlCaHLTBitMon_QueryRunRegistry::string, and unpackBuffers-CaloStage2::token.

Referenced by produceEffectivePedestalWidths(), and producePedestalWidths().

460  {
461  std::string seff = eff ? "Effective" : "";
462 #ifdef EDM_ML_DEBUG
463  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produce" << seff << "PedestalWidths-> ...";
464 #endif
465  auto const& topo = rec.get(token);
466  auto const& zdcTopo = rec.get(zdctoken);
467  auto result = std::make_unique<HcalPedestalWidths>(&topo, false);
468  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
469  for (auto cell : cells) {
471  result->addValues(item);
472  }
473  return result;
474 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
HcalPedestalWidth makePedestalWidth(HcalGenericDetId fId, bool eff, const HcalTopology *topo, double intlumi)

◆ producePFCorrs()

std::unique_ptr< HcalPFCorrs > HcalHardcodeCalibrations::producePFCorrs ( const HcalPFCorrsRcd rcd)
protected

Definition at line 719 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kPFCorrs, mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

719  {
720 #ifdef EDM_ML_DEBUG
721  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::producePFCorrs-> ...";
722 #endif
723  auto const& topo = rcd.get(topoTokens_[kPFCorrs]);
724  auto const& zdcTopo = rcd.get(zdcTopoTokens_[kPFCorrs]);
725 
726  auto result = std::make_unique<HcalPFCorrs>(&topo);
727  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
728  for (auto cell : cells) {
729  HcalPFCorr item(cell.rawId(), 1.0);
730  result->addValues(item);
731  }
732  return result;
733 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ producePFCuts()

std::unique_ptr< HcalPFCuts > HcalHardcodeCalibrations::producePFCuts ( const HcalPFCutsRcd rcd)
protected

Definition at line 538 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, iLumi, B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kPFCuts, HcalDbHardcode::makePFCut(), mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

538  {
539 #ifdef EDM_ML_DEBUG
540  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::producePFCuts-> ...";
541 #endif
542  auto const& topo = rec.get(topoTokens_[kPFCuts]);
543  auto const& zdcTopo = rec.get(zdcTopoTokens_[kPFCuts]);
544  auto result = std::make_unique<HcalPFCuts>(&topo);
545  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
546  for (auto cell : cells) {
547  // Use only standard Hcal channels for now, no TrigPrims
548  if (!cell.isHcalTrigTowerDetId()) {
550  result->addValues(item);
551  }
552  }
553  return result;
554 }
Log< level::Info, true > LogVerbatim
HcalPFCut makePFCut(HcalGenericDetId fId, double intlumi, bool noHE) const
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceQIEData()

std::unique_ptr< HcalQIEData > HcalHardcodeCalibrations::produceQIEData ( const HcalQIEDataRcd rcd)
protected

Definition at line 556 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), HcalDbHardcode::killHE(), kQIEData, HcalDbHardcode::makeQIECoder(), mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

556  {
557 #ifdef EDM_ML_DEBUG
558  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceQIEData-> ...";
559 #endif
560 
561  auto const& topo = rcd.get(topoTokens_[kQIEData]);
562  auto const& zdcTopo = rcd.get(zdcTopoTokens_[kQIEData]);
563  auto result = std::make_unique<HcalQIEData>(&topo);
564  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
565  for (auto cell : cells) {
566  HcalQIECoder coder = dbHardcode.makeQIECoder(cell);
567  result->addCoder(coder);
568  }
569  return result;
570 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
HcalQIECoder makeQIECoder(HcalGenericDetId fId) const
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceQIETypes()

std::unique_ptr< HcalQIETypes > HcalHardcodeCalibrations::produceQIETypes ( const HcalQIETypesRcd rcd)
protected

Definition at line 572 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kQIETypes, HcalDbHardcode::makeQIEType(), mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

572  {
573 #ifdef EDM_ML_DEBUG
574  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceQIETypes-> ...";
575 #endif
576  auto const& topo = rcd.get(topoTokens_[kQIETypes]);
577  auto const& zdcTopo = rcd.get(zdcTopoTokens_[kQIETypes]);
578 
579  auto result = std::make_unique<HcalQIETypes>(&topo);
580  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
581  for (auto cell : cells) {
583  result->addValues(item);
584  }
585  return result;
586 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
HcalQIEType makeQIEType(HcalGenericDetId fId) const
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceRecoParams()

std::unique_ptr< HcalRecoParams > HcalHardcodeCalibrations::produceRecoParams ( const HcalRecoParamsRcd rcd)
protected

Definition at line 859 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kRecoParams, HcalDbHardcode::makeRecoParam(), mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

859  {
860 #ifdef EDM_ML_DEBUG
861  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceRecoParams-> ...";
862 #endif
863  auto const& topo = rec.get(topoTokens_[kRecoParams]);
864  auto const& zdcTopo = rec.get(zdcTopoTokens_[kRecoParams]);
865 
866  auto result = std::make_unique<HcalRecoParams>(&topo);
867  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
868  for (auto cell : cells) {
870  result->addValues(item);
871  }
872  return result;
873 }
Log< level::Info, true > LogVerbatim
HcalRecoParam makeRecoParam(HcalGenericDetId fId) const
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceRespCorrs()

std::unique_ptr< HcalRespCorrs > HcalHardcodeCalibrations::produceRespCorrs ( const HcalRespCorrsRcd rcd)
protected

Definition at line 630 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, alignCSCRings::corr, dbHardcode, hcalRecHitTable_cff::depth, HcalDetId::depth(), edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), HcalDbHardcode::getLayersInDepth(), hb_recalibration, hbDarkeningToken_, HcalGenericDetId::HcalGenBarrel, HcalGenericDetId::HcalGenEndcap, HcalGenericDetId::HcalGenForward, he_recalibration, heDarkeningToken_, hf_recalibration, mps_fire::i, HcalDetId::ieta(), ALPAKA_ACCELERATOR_NAMESPACE::ecal::reconstruction::internal::barrel::ietaAbs(), iLumi, B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kRespCorrs, razorScouting_cff::maxEta, mps_fire::result, setHBdsegm, setHEdsegm, topoTokens_, useLayer0Weight, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

630  {
631 #ifdef EDM_ML_DEBUG
632  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceRespCorrs-> ...";
633 #endif
634  auto const& topo = rcd.get(topoTokens_[kRespCorrs]);
635  auto const& zdcTopo = rcd.get(zdcTopoTokens_[kRespCorrs]);
636 
637  //set depth segmentation for HB/HE recalib - only happens once
639  std::vector<std::vector<int>> m_segmentation;
640  int maxEta = topo.lastHBHERing();
641  m_segmentation.resize(maxEta);
642  for (int i = 0; i < maxEta; i++) {
643  topo.getDepthSegmentation(i + 1, m_segmentation[i]);
644  }
645  if (he_recalibration && !setHEdsegm) {
646  he_recalibration->setup(m_segmentation, &rcd.get(heDarkeningToken_));
647  setHEdsegm = true;
648  }
649  if (hb_recalibration && !setHBdsegm) {
650  hb_recalibration->setup(m_segmentation, &rcd.get(hbDarkeningToken_));
651  setHBdsegm = true;
652  }
653  }
654 
655  auto result = std::make_unique<HcalRespCorrs>(&topo);
656  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
657  for (const auto& cell : cells) {
658  double corr = 1.0;
659 
660  //check for layer 0 reweighting: when depth 1 has only one layer, it is layer 0
661  if (useLayer0Weight &&
662  ((cell.genericSubdet() == HcalGenericDetId::HcalGenEndcap) ||
663  (cell.genericSubdet() == HcalGenericDetId::HcalGenBarrel)) &&
664  (HcalDetId(cell).depth() == 1 &&
665  dbHardcode.getLayersInDepth(HcalDetId(cell).ietaAbs(), HcalDetId(cell).depth(), &topo) == 1)) {
666  //layer 0 is thicker than other layers (9mm vs 3.7mm) and brighter (Bicron vs SCSN81)
667  //in Run1/Run2 (pre-2017 for HE), ODU for layer 0 had neutral density filter attached
668  //NDF was simulated as weight of 0.5 applied to Geant energy deposits
669  //for Phase1, NDF is removed - simulated as weight of 1.2 applied to Geant energy deposits
670  //to maintain RECO calibrations, move the layer 0 energy scale back to its previous state using respcorrs
671  corr = 0.5 / 1.2;
672  }
673 
674  if ((hb_recalibration != nullptr) && (cell.genericSubdet() == HcalGenericDetId::HcalGenBarrel)) {
675  int depth_ = HcalDetId(cell).depth();
676  int ieta_ = HcalDetId(cell).ieta();
677  corr *= hb_recalibration->getCorr(ieta_, depth_);
678 #ifdef EDM_ML_DEBUG
679  edm::LogVerbatim("HcalCalib") << "HB ieta, depth = " << ieta_ << ", " << depth_ << " corr = " << corr;
680 #endif
681  } else if ((he_recalibration != nullptr) && (cell.genericSubdet() == HcalGenericDetId::HcalGenEndcap)) {
682  int depth_ = HcalDetId(cell).depth();
683  int ieta_ = HcalDetId(cell).ieta();
684  corr *= he_recalibration->getCorr(ieta_, depth_);
685 #ifdef EDM_ML_DEBUG
686  edm::LogVerbatim("HcalCalib") << "HE ieta, depth = " << ieta_ << ", " << depth_ << " corr = " << corr;
687 #endif
688  } else if ((hf_recalibration != nullptr) && (cell.genericSubdet() == HcalGenericDetId::HcalGenForward)) {
689  int depth_ = HcalDetId(cell).depth();
690  int ieta_ = HcalDetId(cell).ieta();
691  corr = hf_recalibration->getCorr(ieta_, depth_, iLumi);
692 #ifdef EDM_ML_DEBUG
693  edm::LogVerbatim("HcalCalib") << "HF ieta, depth = " << ieta_ << ", " << depth_ << " corr = " << corr;
694 #endif
695  }
696 
697  HcalRespCorr item(cell.rawId(), corr);
698  result->addValues(item);
699  }
700  return result;
701 }
Log< level::Info, true > LogVerbatim
edm::ESGetToken< HBHEDarkening, HBHEDarkeningRecord > hbDarkeningToken_
ALPAKA_FN_ACC ALPAKA_FN_INLINE uint32_t ietaAbs(uint32_t id)
const bool killHE() const
std::unique_ptr< HFRecalibration > hf_recalibration
dictionary corr
constexpr int ieta() const
get the cell ieta
Definition: HcalDetId.h:155
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
std::unique_ptr< HBHERecalibration > hb_recalibration
std::unique_ptr< HBHERecalibration > he_recalibration
int getLayersInDepth(int ieta, int depth, const HcalTopology *topo)
edm::ESGetToken< HBHEDarkening, HBHEDarkeningRecord > heDarkeningToken_
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_
constexpr int depth() const
get the tower depth
Definition: HcalDetId.h:164

◆ produceSiPMCharacteristics()

std::unique_ptr< HcalSiPMCharacteristics > HcalHardcodeCalibrations::produceSiPMCharacteristics ( const HcalSiPMCharacteristicsRcd rcd)
protected

Definition at line 1006 of file HcalHardcodeCalibrations.cc.

References dbHardcode, and HcalDbHardcode::makeHardcodeSiPMCharacteristics().

Referenced by HcalHardcodeCalibrations().

1007  {
1008 #ifdef EDM_ML_DEBUG
1009  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceSiPMCharacteristics-> ...";
1010 #endif
1012 }
Log< level::Info, true > LogVerbatim
std::unique_ptr< HcalSiPMCharacteristics > makeHardcodeSiPMCharacteristics() const

◆ produceSiPMParameters()

std::unique_ptr< HcalSiPMParameters > HcalHardcodeCalibrations::produceSiPMParameters ( const HcalSiPMParametersRcd rcd)
protected

Definition at line 990 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), iLumi, B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kSiPMParameters, HcalDbHardcode::makeHardcodeSiPMParameter(), mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

990  {
991 #ifdef EDM_ML_DEBUG
992  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceSiPMParameters-> ...";
993 #endif
994  auto const& topo = rec.get(topoTokens_[kSiPMParameters]);
995  auto const& zdcTopo = rec.get(zdcTopoTokens_[kSiPMParameters]);
996 
997  auto result = std::make_unique<HcalSiPMParameters>(&topo);
998  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
999  for (auto cell : cells) {
1001  result->addValues(item);
1002  }
1003  return result;
1004 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
HcalSiPMParameter makeHardcodeSiPMParameter(HcalGenericDetId fId, const HcalTopology *topo, double intlumi)
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceTimeCorrs()

std::unique_ptr< HcalTimeCorrs > HcalHardcodeCalibrations::produceTimeCorrs ( const HcalTimeCorrsRcd rcd)
protected

Definition at line 735 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kTimeCorrs, mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

735  {
736 #ifdef EDM_ML_DEBUG
737  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceTimeCorrs-> ...";
738 #endif
739  auto const& topo = rcd.get(topoTokens_[kTimeCorrs]);
740  auto const& zdcTopo = rcd.get(zdcTopoTokens_[kTimeCorrs]);
741 
742  auto result = std::make_unique<HcalTimeCorrs>(&topo);
743  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
744  for (auto cell : cells) {
745  HcalTimeCorr item(cell.rawId(), 0.0);
746  result->addValues(item);
747  }
748  return result;
749 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceTimingParams()

std::unique_ptr< HcalTimingParams > HcalHardcodeCalibrations::produceTimingParams ( const HcalTimingParamsRcd rcd)
protected

Definition at line 875 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kTimingParams, HcalDbHardcode::makeTimingParam(), mps_fire::result, topoTokens_, and zdcTopoTokens_.

875  {
876 #ifdef EDM_ML_DEBUG
877  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceTimingParams-> ...";
878 #endif
879  auto const& topo = rec.get(topoTokens_[kTimingParams]);
880  auto const& zdcTopo = rec.get(zdcTopoTokens_[kTimingParams]);
881 
882  auto result = std::make_unique<HcalTimingParams>(&topo);
883  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
884  for (auto cell : cells) {
886  result->addValues(item);
887  }
888  return result;
889 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
HcalTimingParam makeTimingParam(HcalGenericDetId fId) const
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceTPChannelParameters()

std::unique_ptr< HcalTPChannelParameters > HcalHardcodeCalibrations::produceTPChannelParameters ( const HcalTPChannelParametersRcd rcd)
protected

Definition at line 1014 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), HcalTriggerTower, B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kTPChannelParameters, HcalDbHardcode::makeHardcodeTPChannelParameter(), mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

1015  {
1016 #ifdef EDM_ML_DEBUG
1017  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceTPChannelParameters-> ...";
1018 #endif
1019  auto const& topo = rec.get(topoTokens_[kTPChannelParameters]);
1020  auto const& zdcTopo = rec.get(zdcTopoTokens_[kTPChannelParameters]);
1021 
1022  auto result = std::make_unique<HcalTPChannelParameters>(&topo);
1023  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
1024  for (auto cell : cells) {
1025  // Thinking about Phase2 and the new FIR filter,
1026  // for now, don't put TT in TPChannelParams
1027  if (cell.subdetId() == HcalTriggerTower)
1028  continue;
1030  result->addValues(item);
1031  }
1032  return result;
1033 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
HcalTPChannelParameter makeHardcodeTPChannelParameter(HcalGenericDetId fId) const
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceTPParameters()

std::unique_ptr< HcalTPParameters > HcalHardcodeCalibrations::produceTPParameters ( const HcalTPParametersRcd rcd)
protected

Definition at line 1035 of file HcalHardcodeCalibrations.cc.

References dbHardcode, HcalDbHardcode::makeHardcodeTPParameters(), and mps_fire::result.

Referenced by HcalHardcodeCalibrations().

1035  {
1036 #ifdef EDM_ML_DEBUG
1037  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceTPParameters-> ...";
1038 #endif
1039  auto result = std::make_unique<HcalTPParameters>();
1041  return result;
1042 }
Log< level::Info, true > LogVerbatim
void makeHardcodeTPParameters(HcalTPParameters &tppar) const

◆ produceValidationCorrs()

std::unique_ptr< HcalValidationCorrs > HcalHardcodeCalibrations::produceValidationCorrs ( const HcalValidationCorrsRcd rcd)
protected

Definition at line 798 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kValidationCorrs, mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

799  {
800 #ifdef EDM_ML_DEBUG
801  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceValidationCorrs-> ...";
802 #endif
803  auto const& topo = rcd.get(topoTokens_[kValidationCorrs]);
804  auto const& zdcTopo = rcd.get(zdcTopoTokens_[kValidationCorrs]);
805 
806  auto result = std::make_unique<HcalValidationCorrs>(&topo);
807  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
808  for (auto cell : cells) {
809  HcalValidationCorr item(cell.rawId(), 1.0);
810  result->addValues(item);
811  }
812  return result;
813 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceZDCLowGainFractions()

std::unique_ptr< HcalZDCLowGainFractions > HcalHardcodeCalibrations::produceZDCLowGainFractions ( const HcalZDCLowGainFractionsRcd rcd)
protected

Definition at line 917 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kZDCLowGainFractions, mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

918  {
919 #ifdef EDM_ML_DEBUG
920  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceZDCLowGainFractions-> ...";
921 #endif
922  auto const& topo = rec.get(topoTokens_[kZDCLowGainFractions]);
923  auto const& zdcTopo = rec.get(zdcTopoTokens_[kZDCLowGainFractions]);
924 
925  auto result = std::make_unique<HcalZDCLowGainFractions>(&topo);
926  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
927  for (auto cell : cells) {
928  HcalZDCLowGainFraction item(cell.rawId(), 0.0);
929  result->addValues(item);
930  }
931  return result;
932 }
Log< level::Info, true > LogVerbatim
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ produceZSThresholds()

std::unique_ptr< HcalZSThresholds > HcalHardcodeCalibrations::produceZSThresholds ( const HcalZSThresholdsRcd rcd)
protected

Definition at line 751 of file HcalHardcodeCalibrations.cc.

References hgcalTBTopologyTester_cfi::cells, dbHardcode, edm::eventsetup::DependentRecordImplementation< RecordT, ListT >::get(), B2GTnPMonitor_cfi::item, HcalDbHardcode::killHE(), kZSThresholds, HcalDbHardcode::makeZSThreshold(), mps_fire::result, topoTokens_, and zdcTopoTokens_.

Referenced by HcalHardcodeCalibrations().

751  {
752 #ifdef EDM_ML_DEBUG
753  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::produceZSThresholds-> ...";
754 #endif
755  auto const& topo = rcd.get(topoTokens_[kZSThresholds]);
756  auto const& zdcTopo = rcd.get(zdcTopoTokens_[kZSThresholds]);
757 
758  auto result = std::make_unique<HcalZSThresholds>(&topo);
759  const std::vector<HcalGenericDetId>& cells = allCells(topo, zdcTopo, dbHardcode.killHE());
760  for (auto cell : cells) {
762  result->addValues(item);
763  }
764  return result;
765 }
Log< level::Info, true > LogVerbatim
HcalZSThreshold makeZSThreshold(HcalGenericDetId fId) const
const bool killHE() const
std::unordered_map< int, edm::ESGetToken< ZdcTopology, HcalRecNumberingRecord > > zdcTopoTokens_
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
std::unordered_map< int, edm::ESGetToken< HcalTopology, HcalRecNumberingRecord > > topoTokens_

◆ setIntervalFor()

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

Implements edm::EventSetupRecordIntervalFinder.

Definition at line 425 of file HcalHardcodeCalibrations.cc.

References edm::IOVSyncValue::beginOfTime(), edm::IOVSyncValue::endOfTime(), edm::IOVSyncValue::eventID(), edm::eventsetup::EventSetupRecordKey::name(), AlCaHarvesting_cff::record, AlCaHLTBitMon_QueryRunRegistry::string, edm::IOVSyncValue::time(), and edm::Timestamp::value().

427  {
428  std::string record = iKey.name();
429 #ifdef EDM_ML_DEBUG
430  edm::LogVerbatim("HCAL") << "HcalHardcodeCalibrations::setIntervalFor-> key: " << record
431  << " time: " << iTime.eventID() << '/' << iTime.time().value();
432 #endif
434 }
Log< level::Info, true > LogVerbatim
static const IOVSyncValue & endOfTime()
Definition: IOVSyncValue.cc:82
std::pair< Time_t, Time_t > ValidityInterval
Definition: Time.h:17
static const IOVSyncValue & beginOfTime()
Definition: IOVSyncValue.cc:88
TimeValue_t value() const
Definition: Timestamp.h:38
const EventID & eventID() const
Definition: IOVSyncValue.h:40
const Timestamp & time() const
Definition: IOVSyncValue.h:42

Member Data Documentation

◆ dbHardcode

HcalDbHardcode HcalHardcodeCalibrations::dbHardcode
private

◆ hb_recalibration

std::unique_ptr<HBHERecalibration> HcalHardcodeCalibrations::hb_recalibration
private

Definition at line 151 of file HcalHardcodeCalibrations.h.

Referenced by HcalHardcodeCalibrations(), and produceRespCorrs().

◆ hbDarkeningToken_

edm::ESGetToken<HBHEDarkening, HBHEDarkeningRecord> HcalHardcodeCalibrations::hbDarkeningToken_
private

Definition at line 157 of file HcalHardcodeCalibrations.h.

Referenced by HcalHardcodeCalibrations(), and produceRespCorrs().

◆ he_recalibration

std::unique_ptr<HBHERecalibration> HcalHardcodeCalibrations::he_recalibration
private

Definition at line 152 of file HcalHardcodeCalibrations.h.

Referenced by HcalHardcodeCalibrations(), and produceRespCorrs().

◆ heDarkeningToken_

edm::ESGetToken<HBHEDarkening, HBHEDarkeningRecord> HcalHardcodeCalibrations::heDarkeningToken_
private

Definition at line 156 of file HcalHardcodeCalibrations.h.

Referenced by HcalHardcodeCalibrations(), and produceRespCorrs().

◆ hf_recalibration

std::unique_ptr<HFRecalibration> HcalHardcodeCalibrations::hf_recalibration
private

Definition at line 153 of file HcalHardcodeCalibrations.h.

Referenced by HcalHardcodeCalibrations(), and produceRespCorrs().

◆ iLumi

double HcalHardcodeCalibrations::iLumi
private

◆ setHBdsegm

bool HcalHardcodeCalibrations::setHBdsegm
private

Definition at line 160 of file HcalHardcodeCalibrations.h.

Referenced by produceRespCorrs().

◆ setHEdsegm

bool HcalHardcodeCalibrations::setHEdsegm
private

Definition at line 159 of file HcalHardcodeCalibrations.h.

Referenced by produceRespCorrs().

◆ switchGainWidthsForTrigPrims

bool HcalHardcodeCalibrations::switchGainWidthsForTrigPrims
private

Definition at line 158 of file HcalHardcodeCalibrations.h.

Referenced by HcalHardcodeCalibrations(), and produceGainWidths().

◆ testHEPlan1

bool HcalHardcodeCalibrations::testHEPlan1
private

Definition at line 163 of file HcalHardcodeCalibrations.h.

Referenced by HcalHardcodeCalibrations(), and produceChannelQuality().

◆ topoTokens_

std::unordered_map<int, edm::ESGetToken<HcalTopology, HcalRecNumberingRecord> > HcalHardcodeCalibrations::topoTokens_
private

◆ useIeta18depth1

bool HcalHardcodeCalibrations::useIeta18depth1
private

Definition at line 162 of file HcalHardcodeCalibrations.h.

Referenced by HcalHardcodeCalibrations(), and produceChannelQuality().

◆ useLayer0Weight

bool HcalHardcodeCalibrations::useLayer0Weight
private

Definition at line 161 of file HcalHardcodeCalibrations.h.

Referenced by HcalHardcodeCalibrations(), and produceRespCorrs().

◆ zdcTopoTokens_

std::unordered_map<int, edm::ESGetToken<ZdcTopology, HcalRecNumberingRecord> > HcalHardcodeCalibrations::zdcTopoTokens_
private