CMS 3D CMS Logo

List of all members | Public Member Functions | Private Types | Private Member Functions | Private Attributes
PreMixingPhase2TrackerWorker Class Reference
Inheritance diagram for PreMixingPhase2TrackerWorker:
PreMixingWorker

Public Member Functions

void addPileups (PileUpEventPrincipal const &pep, edm::EventSetup const &es) override
 
void addSignals (edm::Event const &e, edm::EventSetup const &es) override
 
void beginLuminosityBlock (edm::LuminosityBlock const &lumi, edm::EventSetup const &es) override
 
void initializeEvent (edm::Event const &e, edm::EventSetup const &es) override
 
 PreMixingPhase2TrackerWorker (const edm::ParameterSet &ps, edm::ProducesCollector, edm::ConsumesCollector &&iC)
 
void put (edm::Event &e, edm::EventSetup const &iSetup, std::vector< PileupSummaryInfo > const &ps, int bs) override
 
 ~PreMixingPhase2TrackerWorker () override=default
 
- Public Member Functions inherited from PreMixingWorker
virtual void beginRun (edm::Run const &iRun, edm::EventSetup const &iSetup)
 
virtual void endRun ()
 
virtual void finalizeBunchCrossing (edm::Event &iEvent, edm::EventSetup const &iSetup, int bunchCrossing)
 
virtual void initializeBunchCrossing (edm::Event const &iEvent, edm::EventSetup const &iSetup, int bunchCrossing)
 
 PreMixingWorker ()=default
 
virtual ~PreMixingWorker ()=default
 

Private Types

using SignalMap = std::map< uint32_t, std::map< int, float > >
 

Private Member Functions

void accumulate (const edm::DetSetVector< PixelDigi > &digis, const float electronsPerADC)
 

Private Attributes

SignalMap accumulator_
 
cms::Phase2TrackerDigitizer digitizer_
 
float pixelElectronPerAdc_
 
edm::InputTag pixelPileupLabel_
 
edm::EDGetTokenT< edm::DetSetVector< PixelDigi > > pixelSignalToken_
 
float trackerElectronPerAdc_
 
edm::InputTag trackerPileupLabel_
 
edm::EDGetTokenT< edm::DetSetVector< PixelDigi > > trackerSignalToken_
 

Detailed Description

Definition at line 21 of file PreMixingPhase2TrackerWorker.cc.

Member Typedef Documentation

◆ SignalMap

using PreMixingPhase2TrackerWorker::SignalMap = std::map<uint32_t, std::map<int, float> >
private

Definition at line 47 of file PreMixingPhase2TrackerWorker.cc.

Constructor & Destructor Documentation

◆ PreMixingPhase2TrackerWorker()

PreMixingPhase2TrackerWorker::PreMixingPhase2TrackerWorker ( const edm::ParameterSet ps,
edm::ProducesCollector  producesCollector,
edm::ConsumesCollector &&  iC 
)

Definition at line 51 of file PreMixingPhase2TrackerWorker.cc.

54  : digitizer_(ps, producesCollector, iC),
57  pixelPileupLabel_(ps.getParameter<edm::InputTag>("pixelPileInputTag")),
58  trackerPileupLabel_(ps.getParameter<edm::InputTag>("trackerPileInputTag")),
59  pixelElectronPerAdc_(ps.getParameter<double>("pixelPmxStage1ElectronPerAdc")),
60  trackerElectronPerAdc_(ps.getParameter<double>("trackerPmxStage1ElectronPerAdc")) {}

◆ ~PreMixingPhase2TrackerWorker()

PreMixingPhase2TrackerWorker::~PreMixingPhase2TrackerWorker ( )
overridedefault

Member Function Documentation

◆ accumulate()

void PreMixingPhase2TrackerWorker::accumulate ( const edm::DetSetVector< PixelDigi > &  digis,
const float  electronsPerADC 
)
private

Definition at line 88 of file PreMixingPhase2TrackerWorker.cc.

88  {
89  for (const auto& detset : digis) {
90  auto& accDet = accumulator_[detset.detId()];
91  for (const auto& digi : detset) {
92  // note: according to C++ standard operator[] does
93  // value-initializiation, which for float means initial value of 0
94  auto& acc = accDet[digi.channel()];
95  acc += digi.adc() * electronPerADC;
96  }
97  }
98 }

References accumulator_.

Referenced by addPileups(), and addSignals().

◆ addPileups()

void PreMixingPhase2TrackerWorker::addPileups ( PileUpEventPrincipal const &  pep,
edm::EventSetup const &  es 
)
overridevirtual

◆ addSignals()

void PreMixingPhase2TrackerWorker::addSignals ( edm::Event const &  e,
edm::EventSetup const &  es 
)
overridevirtual

◆ beginLuminosityBlock()

void PreMixingPhase2TrackerWorker::beginLuminosityBlock ( edm::LuminosityBlock const &  lumi,
edm::EventSetup const &  es 
)
overridevirtual

Reimplemented from PreMixingWorker.

Definition at line 62 of file PreMixingPhase2TrackerWorker.cc.

62  {
64 }

References DigiAccumulatorMixMod::beginLuminosityBlock(), and digitizer_.

◆ initializeEvent()

void PreMixingPhase2TrackerWorker::initializeEvent ( edm::Event const &  e,
edm::EventSetup const &  es 
)
overridevirtual

◆ put()

void PreMixingPhase2TrackerWorker::put ( edm::Event e,
edm::EventSetup const &  iSetup,
std::vector< PileupSummaryInfo > const &  ps,
int  bs 
)
overridevirtual

Member Data Documentation

◆ accumulator_

SignalMap PreMixingPhase2TrackerWorker::accumulator_
private

Definition at line 48 of file PreMixingPhase2TrackerWorker.cc.

Referenced by accumulate(), and put().

◆ digitizer_

cms::Phase2TrackerDigitizer PreMixingPhase2TrackerWorker::digitizer_
private

Definition at line 36 of file PreMixingPhase2TrackerWorker.cc.

Referenced by beginLuminosityBlock(), initializeEvent(), and put().

◆ pixelElectronPerAdc_

float PreMixingPhase2TrackerWorker::pixelElectronPerAdc_
private

Definition at line 42 of file PreMixingPhase2TrackerWorker.cc.

Referenced by addPileups(), and addSignals().

◆ pixelPileupLabel_

edm::InputTag PreMixingPhase2TrackerWorker::pixelPileupLabel_
private

Definition at line 40 of file PreMixingPhase2TrackerWorker.cc.

Referenced by addPileups().

◆ pixelSignalToken_

edm::EDGetTokenT<edm::DetSetVector<PixelDigi> > PreMixingPhase2TrackerWorker::pixelSignalToken_
private

Definition at line 38 of file PreMixingPhase2TrackerWorker.cc.

Referenced by addSignals().

◆ trackerElectronPerAdc_

float PreMixingPhase2TrackerWorker::trackerElectronPerAdc_
private

Definition at line 43 of file PreMixingPhase2TrackerWorker.cc.

Referenced by addPileups(), and addSignals().

◆ trackerPileupLabel_

edm::InputTag PreMixingPhase2TrackerWorker::trackerPileupLabel_
private

Definition at line 41 of file PreMixingPhase2TrackerWorker.cc.

Referenced by addPileups().

◆ trackerSignalToken_

edm::EDGetTokenT<edm::DetSetVector<PixelDigi> > PreMixingPhase2TrackerWorker::trackerSignalToken_
private

Definition at line 39 of file PreMixingPhase2TrackerWorker.cc.

Referenced by addSignals().

edm::DetSetVector< PixelDigi >
DigiAccumulatorMixMod::beginLuminosityBlock
virtual void beginLuminosityBlock(edm::LuminosityBlock const &lumi, edm::EventSetup const &setup)
Definition: DigiAccumulatorMixMod.h:74
PreMixingPhase2TrackerWorker::pixelPileupLabel_
edm::InputTag pixelPileupLabel_
Definition: PreMixingPhase2TrackerWorker.cc:40
PreMixingPhase2TrackerWorker::trackerSignalToken_
edm::EDGetTokenT< edm::DetSetVector< PixelDigi > > trackerSignalToken_
Definition: PreMixingPhase2TrackerWorker.cc:39
cms::Phase2TrackerDigitizer::finalizeEvent
void finalizeEvent(edm::Event &e, edm::EventSetup const &c) override
Definition: Phase2TrackerDigitizer.cc:216
edm::Handle
Definition: AssociativeIterator.h:50
cms::Phase2TrackerDigitizer::initializeEvent
void initializeEvent(edm::Event const &e, edm::EventSetup const &c) override
Definition: Phase2TrackerDigitizer.cc:132
PreMixingPhase2TrackerWorker::digitizer_
cms::Phase2TrackerDigitizer digitizer_
Definition: PreMixingPhase2TrackerWorker.cc:36
PreMixingPhase2TrackerWorker::accumulate
void accumulate(const edm::DetSetVector< PixelDigi > &digis, const float electronsPerADC)
Definition: PreMixingPhase2TrackerWorker.cc:88
edm::ConsumesCollector::consumes
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
Definition: ConsumesCollector.h:55
cms::Phase2TrackerDigitizer::loadAccumulator
void loadAccumulator(const std::map< uint32_t, std::map< int, float > > &accumulator)
Definition: Phase2TrackerDigitizer.cc:208
PreMixingPhase2TrackerWorker::trackerElectronPerAdc_
float trackerElectronPerAdc_
Definition: PreMixingPhase2TrackerWorker.cc:43
PreMixingPhase2TrackerWorker::pixelSignalToken_
edm::EDGetTokenT< edm::DetSetVector< PixelDigi > > pixelSignalToken_
Definition: PreMixingPhase2TrackerWorker.cc:38
PreMixingPhase2TrackerWorker::pixelElectronPerAdc_
float pixelElectronPerAdc_
Definition: PreMixingPhase2TrackerWorker.cc:42
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
PreMixingPhase2TrackerWorker::accumulator_
SignalMap accumulator_
Definition: PreMixingPhase2TrackerWorker.cc:48
lumi
Definition: LumiSectionData.h:20
edm::InputTag
Definition: InputTag.h:15
PreMixingPhase2TrackerWorker::trackerPileupLabel_
edm::InputTag trackerPileupLabel_
Definition: PreMixingPhase2TrackerWorker.cc:41
MillePedeFileConverter_cfg.e
e
Definition: MillePedeFileConverter_cfg.py:37