CMS 3D CMS Logo

PreMixingEcalWorker.cc
Go to the documentation of this file.
8 
16 
19 
21 public:
23  ~PreMixingEcalWorker() override = default;
24 
25  PreMixingEcalWorker(const PreMixingEcalWorker &) = delete;
27 
29 
30  void initializeEvent(edm::Event const &e, edm::EventSetup const &ES) override;
31  void addSignals(edm::Event const &e, edm::EventSetup const &ES) override;
32  void addPileups(PileUpEventPrincipal const &pep, edm::EventSetup const &es) override;
33  void put(edm::Event &e, edm::EventSetup const &iSetup, std::vector<PileupSummaryInfo> const &ps, int bs) override;
34 
35 private:
36  edm::InputTag EBPileInputTag_; // InputTag for Pileup Digis collection
37  edm::InputTag EEPileInputTag_; // InputTag for Pileup Digis collection
38  edm::InputTag ESPileInputTag_; // InputTag for Pileup Digis collection
39 
40  std::string EBDigiCollectionDM_; // secondary name to be given to collection of digis
41  std::string EEDigiCollectionDM_; // secondary name to be given to collection of digis
42  std::string ESDigiCollectionDM_; // secondary name to be given to collection of digis
43 
47 
48  const double m_EBs25notCont;
49  const double m_EEs25notCont;
50  const double m_peToABarrel;
51  const double m_peToAEndcap;
52  const bool m_timeDependent;
53 
58 };
59 
60 // Constructor
62  edm::ProducesCollector producesCollector,
64  : EBPileInputTag_(ps.getParameter<edm::InputTag>("EBPileInputTag")),
65  EEPileInputTag_(ps.getParameter<edm::InputTag>("EEPileInputTag")),
66  ESPileInputTag_(ps.getParameter<edm::InputTag>("ESPileInputTag")),
67  tok_eb_(iC.consumes<EBDigitizerTraits::DigiCollection>(EBPileInputTag_)),
68  tok_ee_(iC.consumes<EEDigitizerTraits::DigiCollection>(EEPileInputTag_)),
69  tok_es_(iC.consumes<ESDigitizerTraits::DigiCollection>(ESPileInputTag_)),
70  m_EBs25notCont(ps.getParameter<double>("EBs25notContainment")),
71  m_EEs25notCont(ps.getParameter<double>("EEs25notContainment")),
72  m_peToABarrel(ps.getParameter<double>("photoelectronsToAnalogBarrel")),
73  m_peToAEndcap(ps.getParameter<double>("photoelectronsToAnalogEndcap")),
74  m_timeDependent(ps.getParameter<bool>("timeDependent")),
75  theEBSignalGenerator(
76  EBPileInputTag_, tok_eb_, m_EBs25notCont, m_EEs25notCont, m_peToABarrel, m_peToAEndcap, m_timeDependent),
77  theEESignalGenerator(
78  EEPileInputTag_, tok_ee_, m_EBs25notCont, m_EEs25notCont, m_peToABarrel, m_peToAEndcap, m_timeDependent),
79  theESSignalGenerator(ESPileInputTag_, tok_es_, m_EBs25notCont, m_EEs25notCont, m_peToABarrel, m_peToAEndcap),
80  myEcalDigitizer_(ps, iC) {
81  EBDigiCollectionDM_ = ps.getParameter<std::string>("EBDigiCollectionDM");
82  EEDigiCollectionDM_ = ps.getParameter<std::string>("EEDigiCollectionDM");
83  ESDigiCollectionDM_ = ps.getParameter<std::string>("ESDigiCollectionDM");
84 
85  producesCollector.produces<EBDigiCollection>(EBDigiCollectionDM_);
86  producesCollector.produces<EEDigiCollection>(EEDigiCollectionDM_);
87  producesCollector.produces<ESDigiCollection>(ESDigiCollectionDM_);
88 
92 }
93 
96 }
97 
100 }
101 
103  LogDebug("PreMixingEcalWorker") << "\n===============> adding pileups from event " << pep.principal().id()
104  << " for bunchcrossing " << pep.bunchCrossing();
105 
109 
110  // add noise signals using incoming digis
114 }
115 
117  const edm::EventSetup &ES,
118  std::vector<PileupSummaryInfo> const &ps,
119  int bs) {
121 }
122 
125 }
126 
EcalDigiProducer::accumulate
void accumulate(edm::Event const &e, edm::EventSetup const &c) override
Definition: EcalDigiProducer.cc:320
EcalDigiProducer::beginLuminosityBlock
void beginLuminosityBlock(edm::LuminosityBlock const &lumi, edm::EventSetup const &setup) override
Definition: EcalDigiProducer.cc:420
PreMixingEcalWorker::addPileups
void addPileups(PileUpEventPrincipal const &pep, edm::EventSetup const &es) override
Definition: PreMixingEcalWorker.cc:102
Handle.h
electrons_cff.bool
bool
Definition: electrons_cff.py:393
PreMixingEcalWorker
Definition: PreMixingEcalWorker.cc:20
MessageLogger.h
PreMixingEcalWorker::put
void put(edm::Event &e, edm::EventSetup const &iSetup, std::vector< PileupSummaryInfo > const &ps, int bs) override
Definition: PreMixingEcalWorker.cc:116
PreMixingEcalWorker::initializeEvent
void initializeEvent(edm::Event const &e, edm::EventSetup const &ES) override
Definition: PreMixingEcalWorker.cc:94
edm::LuminosityBlock
Definition: LuminosityBlock.h:50
EcalDigiProducer.h
edm::EDGetTokenT
Definition: EDGetToken.h:33
PreMixingEcalWorker::myEcalDigitizer_
EcalDigiProducer myEcalDigitizer_
Definition: PreMixingEcalWorker.cc:57
PreMixingEcalWorker::ESDigiCollectionDM_
std::string ESDigiCollectionDM_
Definition: PreMixingEcalWorker.cc:42
edm
HLT enums.
Definition: AlignableModifier.h:19
PreMixingEcalWorker::theEBSignalGenerator
EBSignalGenerator theEBSignalGenerator
Definition: PreMixingEcalWorker.cc:54
HLT_FULL_cff.InputTag
InputTag
Definition: HLT_FULL_cff.py:85964
PreMixingEcalWorker::EEPileInputTag_
edm::InputTag EEPileInputTag_
Definition: PreMixingEcalWorker.cc:37
PileUpEventPrincipal::bunchCrossing
int bunchCrossing() const
Definition: PileUpEventPrincipal.h:30
PileUpEventPrincipal
Definition: PileUpEventPrincipal.h:19
PreMixingEcalWorker::ESPileInputTag_
edm::InputTag ESPileInputTag_
Definition: PreMixingEcalWorker.cc:38
PreMixingEcalWorker::tok_ee_
edm::EDGetTokenT< EEDigitizerTraits::DigiCollection > tok_ee_
Definition: PreMixingEcalWorker.cc:45
edm::EventPrincipal::id
EventID const & id() const
Definition: EventPrincipal.h:92
singleTopDQM_cfi.setup
setup
Definition: singleTopDQM_cfi.py:37
ProducesCollector.h
ESDataFrame.h
PreMixingEcalWorker::m_EBs25notCont
const double m_EBs25notCont
Definition: PreMixingEcalWorker.cc:48
PreMixingEcalWorker::EBPileInputTag_
edm::InputTag EBPileInputTag_
Definition: PreMixingEcalWorker.cc:36
PileUpEventPrincipal::moduleCallingContext
edm::ModuleCallingContext const * moduleCallingContext() const
Definition: PileUpEventPrincipal.h:28
cms::cuda::bs
bs
Definition: HistoContainer.h:127
PreMixingEcalWorker::m_peToAEndcap
const double m_peToAEndcap
Definition: PreMixingEcalWorker.cc:51
PreMixingEcalWorker::m_EEs25notCont
const double m_EEs25notCont
Definition: PreMixingEcalWorker.cc:49
PreMixingWorker.h
EBDigitizerTraits
Definition: EcalDigitizerTraits.h:19
EcalDigiProducer::finalizeEvent
void finalizeEvent(edm::Event &e, edm::EventSetup const &c) override
Definition: EcalDigiProducer.cc:373
PreMixingEcalWorker::~PreMixingEcalWorker
~PreMixingEcalWorker() override=default
PreMixingEcalWorker::m_timeDependent
const bool m_timeDependent
Definition: PreMixingEcalWorker.cc:52
PileUpEventPrincipal::principal
edm::EventPrincipal const & principal()
Definition: PileUpEventPrincipal.h:24
EcalDigiCollections.h
PileUpEventPrincipal.h
PreMixingEcalWorker::tok_eb_
edm::EDGetTokenT< EBDigitizerTraits::DigiCollection > tok_eb_
Definition: PreMixingEcalWorker.cc:44
PreMixingEcalWorker::beginLuminosityBlock
void beginLuminosityBlock(edm::LuminosityBlock const &lumi, edm::EventSetup const &setup) override
Definition: PreMixingEcalWorker.cc:123
ESDigiCollection
Definition: EcalDigiCollections.h:82
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
LogDebug
#define LogDebug(id)
Definition: MessageLogger.h:223
edm::ParameterSet
Definition: ParameterSet.h:47
Event.h
EBDigiCollection
Definition: EcalDigiCollections.h:56
EEDigiCollection
Definition: EcalDigiCollections.h:69
EcalSignalGenerator::fill
virtual void fill(edm::ModuleCallingContext const *mcc)
Definition: EcalSignalGenerator.h:208
EcalSignalGenerator< EBDigitizerTraits >
PreMixingEcalWorker::PreMixingEcalWorker
PreMixingEcalWorker(const edm::ParameterSet &ps, edm::ProducesCollector, edm::ConsumesCollector &&iC)
Definition: PreMixingEcalWorker.cc:61
edm::ProducesCollector::produces
ProductRegistryHelper::BranchAliasSetterT< ProductType > produces()
Definition: ProducesCollector.h:52
EBDataFrame.h
edm::EventSetup
Definition: EventSetup.h:57
PreMixingEcalWorker::theESSignalGenerator
ESSignalGenerator theESSignalGenerator
Definition: PreMixingEcalWorker.cc:56
ESDigitizerTraits
Definition: EcalDigitizerTraits.h:45
EcalDigiProducer::initializeEvent
void initializeEvent(edm::Event const &e, edm::EventSetup const &c) override
Definition: EcalDigiProducer.cc:271
EEDataFrame.h
EcalSignalGenerator.h
PreMixingWorkerFactory.h
EEDigitizerTraits
Definition: EcalDigitizerTraits.h:32
siStripShotFilter_cfi.DigiCollection
DigiCollection
Definition: siStripShotFilter_cfi.py:6
EcalDigiProducer
Definition: EcalDigiProducer.h:59
PreMixingEcalWorker::operator=
PreMixingEcalWorker & operator=(const PreMixingEcalWorker &)=delete
PreMixingEcalWorker::tok_es_
edm::EDGetTokenT< ESDigitizerTraits::DigiCollection > tok_es_
Definition: PreMixingEcalWorker.cc:46
edm::ProducesCollector
Definition: ProducesCollector.h:43
EcalDigiProducer::setESNoiseSignalGenerator
void setESNoiseSignalGenerator(EcalBaseSignalGenerator *noiseGenerator)
Definition: EcalDigiProducer.cc:606
PreMixingEcalWorker::addSignals
void addSignals(edm::Event const &e, edm::EventSetup const &ES) override
Definition: PreMixingEcalWorker.cc:98
DEFINE_PREMIXING_WORKER
#define DEFINE_PREMIXING_WORKER(TYPE)
Definition: PreMixingWorkerFactory.h:16
PreMixingEcalWorker::EBDigiCollectionDM_
std::string EBDigiCollectionDM_
Definition: PreMixingEcalWorker.cc:40
EventSetup.h
PreMixingEcalWorker::theEESignalGenerator
EESignalGenerator theEESignalGenerator
Definition: PreMixingEcalWorker.cc:55
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
EcalSignalGenerator::initializeEvent
void initializeEvent(const edm::Event *event, const edm::EventSetup *eventSetup)
Definition: EcalSignalGenerator.h:84
PreMixingWorker
Definition: PreMixingWorker.h:14
ConsumesCollector.h
ParameterSet.h
EcalDigiProducer::setEENoiseSignalGenerator
void setEENoiseSignalGenerator(EcalBaseSignalGenerator *noiseGenerator)
Definition: EcalDigiProducer.cc:600
PreMixingEcalWorker::EEDigiCollectionDM_
std::string EEDigiCollectionDM_
Definition: PreMixingEcalWorker.cc:41
edm::Event
Definition: Event.h:73
lumi
Definition: LumiSectionData.h:20
PreMixingEcalWorker::m_peToABarrel
const double m_peToABarrel
Definition: PreMixingEcalWorker.cc:50
edm::InputTag
Definition: InputTag.h:15
edm::ConsumesCollector
Definition: ConsumesCollector.h:45
EcalDigiProducer::setEBNoiseSignalGenerator
void setEBNoiseSignalGenerator(EcalBaseSignalGenerator *noiseGenerator)
Definition: EcalDigiProducer.cc:594
MillePedeFileConverter_cfg.e
e
Definition: MillePedeFileConverter_cfg.py:37