#include <EcalDigiProducer.h>
Definition at line 51 of file EcalDigiProducer.h.
typedef edm::Handle<std::vector<PCaloHit> > EcalDigiProducer::HitsHandle [private] |
Definition at line 67 of file EcalDigiProducer.h.
EcalDigiProducer::EcalDigiProducer | ( | const edm::ParameterSet & | params, |
edm::EDProducer & | mixMod | ||
) |
Definition at line 50 of file EcalDigiProducer.cc.
References alignCSCRings::e, edm::ParameterSet::getParameter(), getHLTprescales::index, m_APDCoder, m_apdDigiTag, m_APDDigitizer, m_APDElectronicsSim, m_APDResponse, m_apdSeparateDigi, m_BarrelDigitizer, m_Coder, m_EBCorrNoise, m_EBdigiCollection, m_EBResponse, m_EECorrNoise, m_EEdigiCollection, m_EEResponse, m_ElectronicsSim, m_EndcapDigitizer, m_ESdigiCollection, m_ParameterMap, m_readoutFrameSize, and EcalHitResponse::setPhaseShift().
: DigiAccumulatorMixMod(), m_APDShape ( params.getParameter<double>( "apdShapeTstart" ) , params.getParameter<double>( "apdShapeTau" ) ) , m_EBShape ( ) , m_EEShape ( ) , m_ESShape ( ) , m_EBdigiCollection ( params.getParameter<std::string>("EBdigiCollection") ) , m_EEdigiCollection ( params.getParameter<std::string>("EEdigiCollection") ) , m_ESdigiCollection ( params.getParameter<std::string>("ESdigiCollection") ) , m_hitsProducerTag ( params.getParameter<std::string>("hitsProducer" ) ) , m_useLCcorrection ( params.getUntrackedParameter<bool>("UseLCcorrection") ) , m_apdSeparateDigi ( params.getParameter<bool> ("apdSeparateDigi") ) , m_EBs25notCont ( params.getParameter<double> ("EBs25notContainment") ) , m_EEs25notCont ( params.getParameter<double> ("EEs25notContainment") ) , m_readoutFrameSize ( params.getParameter<int> ("readoutFrameSize") ) , m_ParameterMap ( new EcalSimParameterMap( params.getParameter<double> ("simHitToPhotoelectronsBarrel") , params.getParameter<double> ("simHitToPhotoelectronsEndcap") , params.getParameter<double> ("photoelectronsToAnalogBarrel") , params.getParameter<double> ("photoelectronsToAnalogEndcap") , params.getParameter<double> ("samplingFactor") , params.getParameter<double> ("timePhase") , m_readoutFrameSize , params.getParameter<int> ("binOfMaximum") , params.getParameter<bool> ("doPhotostatistics") , params.getParameter<bool> ("syncPhase") ) ) , m_apdDigiTag ( params.getParameter<std::string> ("apdDigiTag" ) ) , m_apdParameters ( new APDSimParameters( params.getParameter<bool> ("apdAddToBarrel" ) , m_apdSeparateDigi , params.getParameter<double> ("apdSimToPELow" ) , params.getParameter<double> ("apdSimToPEHigh" ) , params.getParameter<double> ("apdTimeOffset" ) , params.getParameter<double> ("apdTimeOffWidth" ) , params.getParameter<bool> ("apdDoPEStats" ) , m_apdDigiTag , params.getParameter<std::vector<double> > ( "apdNonlParms" ) ) ) , m_APDResponse ( !m_apdSeparateDigi ? 0 : new EBHitResponse( m_ParameterMap , &m_EBShape , true , m_apdParameters , &m_APDShape ) ) , m_EBResponse ( new EBHitResponse( m_ParameterMap , &m_EBShape , false , // barrel m_apdParameters , &m_APDShape ) ) , m_EEResponse ( new EEHitResponse( m_ParameterMap, &m_EEShape ) ) , m_ESResponse ( new ESHitResponse( m_ParameterMap, &m_ESShape ) ) , m_ESOldResponse ( new CaloHitResponse( m_ParameterMap, &m_ESShape ) ) , m_addESNoise ( params.getParameter<bool> ("doESNoise") ) , m_doFastES ( params.getParameter<bool> ("doFast" ) ) , m_ESElectronicsSim ( m_doFastES ? 0 : new ESElectronicsSim( m_addESNoise ) ) , m_ESOldDigitizer ( m_doFastES ? 0 : new ESOldDigitizer( m_ESOldResponse , m_ESElectronicsSim , m_addESNoise ) ) , m_ESElectronicsSimFast ( !m_doFastES ? 0 : new ESElectronicsSimFast( m_addESNoise ) ) , m_ESDigitizer ( !m_doFastES ? 0 : new ESDigitizer( m_ESResponse , m_ESElectronicsSimFast , m_addESNoise ) ) , m_APDDigitizer ( 0 ) , m_BarrelDigitizer ( 0 ) , m_EndcapDigitizer ( 0 ) , m_ElectronicsSim ( 0 ) , m_Coder ( 0 ) , m_APDElectronicsSim ( 0 ) , m_APDCoder ( 0 ) , m_Geometry ( 0 ) , m_EBCorrNoise ( ) , m_EECorrNoise ( ) { if(m_apdSeparateDigi) mixMod.produces<EBDigiCollection>(m_apdDigiTag); mixMod.produces<EBDigiCollection>(m_EBdigiCollection); mixMod.produces<EEDigiCollection>(m_EEdigiCollection); mixMod.produces<ESDigiCollection>(m_ESdigiCollection); const std::vector<double> ebCorMatG12 = params.getParameter< std::vector<double> >("EBCorrNoiseMatrixG12"); const std::vector<double> eeCorMatG12 = params.getParameter< std::vector<double> >("EECorrNoiseMatrixG12"); const std::vector<double> ebCorMatG06 = params.getParameter< std::vector<double> >("EBCorrNoiseMatrixG06"); const std::vector<double> eeCorMatG06 = params.getParameter< std::vector<double> >("EECorrNoiseMatrixG06"); const std::vector<double> ebCorMatG01 = params.getParameter< std::vector<double> >("EBCorrNoiseMatrixG01"); const std::vector<double> eeCorMatG01 = params.getParameter< std::vector<double> >("EECorrNoiseMatrixG01"); const bool applyConstantTerm = params.getParameter<bool> ("applyConstantTerm"); const double rmsConstantTerm = params.getParameter<double> ("ConstantTerm"); const bool addNoise = params.getParameter<bool> ("doNoise"); const bool cosmicsPhase = params.getParameter<bool> ("cosmicsPhase"); const double cosmicsShift = params.getParameter<double> ("cosmicsShift"); //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ // further phase for cosmics studies if( cosmicsPhase ) { m_EBResponse->setPhaseShift( 1. + cosmicsShift ) ; m_EEResponse->setPhaseShift( 1. + cosmicsShift ) ; } EcalCorrMatrix ebMatrix[ 3 ] ; EcalCorrMatrix eeMatrix[ 3 ] ; assert( ebCorMatG12.size() == m_readoutFrameSize ) ; assert( eeCorMatG12.size() == m_readoutFrameSize ) ; assert( ebCorMatG06.size() == m_readoutFrameSize ) ; assert( eeCorMatG06.size() == m_readoutFrameSize ) ; assert( ebCorMatG01.size() == m_readoutFrameSize ) ; assert( eeCorMatG01.size() == m_readoutFrameSize ) ; assert( 1.e-7 > fabs( ebCorMatG12[0] - 1.0 ) ) ; assert( 1.e-7 > fabs( ebCorMatG06[0] - 1.0 ) ) ; assert( 1.e-7 > fabs( ebCorMatG01[0] - 1.0 ) ) ; assert( 1.e-7 > fabs( eeCorMatG12[0] - 1.0 ) ) ; assert( 1.e-7 > fabs( eeCorMatG06[0] - 1.0 ) ) ; assert( 1.e-7 > fabs( eeCorMatG01[0] - 1.0 ) ) ; for ( unsigned int row ( 0 ) ; row != m_readoutFrameSize ; ++row ) { assert( 0 == row || 1. >= ebCorMatG12[row] ) ; assert( 0 == row || 1. >= ebCorMatG06[row] ) ; assert( 0 == row || 1. >= ebCorMatG01[row] ) ; assert( 0 == row || 1. >= eeCorMatG12[row] ) ; assert( 0 == row || 1. >= eeCorMatG06[row] ) ; assert( 0 == row || 1. >= eeCorMatG01[row] ) ; for ( unsigned int column ( 0 ) ; column <= row ; ++column ) { const unsigned int index ( row - column ) ; ebMatrix[0]( row, column ) = ebCorMatG12[ index ] ; eeMatrix[0]( row, column ) = eeCorMatG12[ index ] ; ebMatrix[1]( row, column ) = ebCorMatG06[ index ] ; eeMatrix[1]( row, column ) = eeCorMatG06[ index ] ; ebMatrix[2]( row, column ) = ebCorMatG01[ index ] ; eeMatrix[2]( row, column ) = eeCorMatG01[ index ] ; } } m_EBCorrNoise[0] = new CorrelatedNoisifier<EcalCorrMatrix>( ebMatrix[0] ) ; m_EECorrNoise[0] = new CorrelatedNoisifier<EcalCorrMatrix>( eeMatrix[0] ) ; m_EBCorrNoise[1] = new CorrelatedNoisifier<EcalCorrMatrix>( ebMatrix[1] ) ; m_EECorrNoise[1] = new CorrelatedNoisifier<EcalCorrMatrix>( eeMatrix[1] ) ; m_EBCorrNoise[2] = new CorrelatedNoisifier<EcalCorrMatrix>( ebMatrix[2] ) ; m_EECorrNoise[2] = new CorrelatedNoisifier<EcalCorrMatrix>( eeMatrix[2] ) ; m_Coder = new EcalCoder( addNoise , m_EBCorrNoise[0] , m_EECorrNoise[0] , m_EBCorrNoise[1] , m_EECorrNoise[1] , m_EBCorrNoise[2] , m_EECorrNoise[2] ) ; m_ElectronicsSim = new EcalElectronicsSim( m_ParameterMap , m_Coder , applyConstantTerm , rmsConstantTerm ) ; if( m_apdSeparateDigi ) { m_APDCoder = new EcalCoder( false , m_EBCorrNoise[0] , m_EECorrNoise[0] , m_EBCorrNoise[1] , m_EECorrNoise[1] , m_EBCorrNoise[2] , m_EECorrNoise[2] ) ; m_APDElectronicsSim = new EcalElectronicsSim( m_ParameterMap , m_APDCoder , applyConstantTerm , rmsConstantTerm ) ; m_APDDigitizer = new EBDigitizer( m_APDResponse , m_APDElectronicsSim , false ) ; } m_BarrelDigitizer = new EBDigitizer( m_EBResponse , m_ElectronicsSim , addNoise ) ; m_EndcapDigitizer = new EEDigitizer( m_EEResponse , m_ElectronicsSim , addNoise ) ; }
EcalDigiProducer::~EcalDigiProducer | ( | ) | [virtual] |
Definition at line 254 of file EcalDigiProducer.cc.
References m_APDCoder, m_APDDigitizer, m_APDElectronicsSim, m_apdParameters, m_APDResponse, m_BarrelDigitizer, m_Coder, m_EBCorrNoise, m_EBResponse, m_EECorrNoise, m_EEResponse, m_ElectronicsSim, m_EndcapDigitizer, m_ESDigitizer, m_ESElectronicsSim, m_ESElectronicsSimFast, m_ESOldDigitizer, m_ESOldResponse, m_ESResponse, and m_ParameterMap.
{ delete m_EndcapDigitizer ; delete m_BarrelDigitizer ; delete m_APDDigitizer ; delete m_APDElectronicsSim ; delete m_APDCoder ; delete m_ElectronicsSim ; delete m_Coder ; delete m_EBCorrNoise[0] ; delete m_EECorrNoise[0] ; delete m_EBCorrNoise[1] ; delete m_EECorrNoise[1] ; delete m_EBCorrNoise[2] ; delete m_EECorrNoise[2] ; delete m_ESDigitizer ; delete m_ESElectronicsSimFast ; delete m_ESOldDigitizer ; delete m_ESElectronicsSim ; delete m_ESOldResponse ; delete m_ESResponse ; delete m_EEResponse ; delete m_EBResponse ; delete m_APDResponse ; delete m_apdParameters ; delete m_ParameterMap ; }
void EcalDigiProducer::accumulate | ( | edm::Event const & | e, |
edm::EventSetup const & | c | ||
) | [virtual] |
Implements DigiAccumulatorMixMod.
Definition at line 325 of file EcalDigiProducer.cc.
References accumulateCaloHits(), edm::Event::getByLabel(), and m_hitsProducerTag.
{ // Step A: Get Inputs edm::InputTag ebTag(m_hitsProducerTag, "EcalHitsEB"); edm::Handle<std::vector<PCaloHit> > ebHandle; e.getByLabel(ebTag, ebHandle); edm::InputTag eeTag(m_hitsProducerTag, "EcalHitsEE"); edm::Handle<std::vector<PCaloHit> > eeHandle; e.getByLabel(eeTag, eeHandle); edm::InputTag esTag(m_hitsProducerTag, "EcalHitsES"); edm::Handle<std::vector<PCaloHit> > esHandle; e.getByLabel(esTag, esHandle); accumulateCaloHits(ebHandle, eeHandle, esHandle, 0); }
void EcalDigiProducer::accumulate | ( | PileUpEventPrincipal const & | e, |
edm::EventSetup const & | c | ||
) | [virtual] |
Implements DigiAccumulatorMixMod.
Definition at line 343 of file EcalDigiProducer.cc.
References accumulateCaloHits(), PileUpEventPrincipal::bunchCrossing(), PileUpEventPrincipal::getByLabel(), and m_hitsProducerTag.
{ // Step A: Get Inputs edm::InputTag ebTag(m_hitsProducerTag, "EcalHitsEB"); edm::Handle<std::vector<PCaloHit> > ebHandle; e.getByLabel(ebTag, ebHandle); edm::InputTag eeTag(m_hitsProducerTag, "EcalHitsEE"); edm::Handle<std::vector<PCaloHit> > eeHandle; e.getByLabel(eeTag, eeHandle); edm::InputTag esTag(m_hitsProducerTag, "EcalHitsES"); edm::Handle<std::vector<PCaloHit> > esHandle; e.getByLabel(esTag, esHandle); accumulateCaloHits(ebHandle, eeHandle, esHandle, e.bunchCrossing()); }
void EcalDigiProducer::accumulateCaloHits | ( | HitsHandle const & | ebHandle, |
HitsHandle const & | eeHandle, | ||
HitsHandle const & | esHandle, | ||
int | bunchCrossing | ||
) | [private] |
Definition at line 302 of file EcalDigiProducer.cc.
References CaloTDigitizer< Traits >::add(), EcalTDigitizer< Traits >::add(), edm::HandleBase::isValid(), m_APDDigitizer, m_apdSeparateDigi, m_BarrelDigitizer, m_doFastES, m_EndcapDigitizer, m_ESDigitizer, m_ESOldDigitizer, and edm::Handle< T >::product().
Referenced by accumulate().
{ if(ebHandle.isValid()) { m_BarrelDigitizer->add(*ebHandle.product(), bunchCrossing); if(m_apdSeparateDigi) { m_APDDigitizer->add(*ebHandle.product(), bunchCrossing); } } if(eeHandle.isValid()) { m_EndcapDigitizer->add(*eeHandle.product(), bunchCrossing); } if(esHandle.isValid()) { if(m_doFastES) { m_ESDigitizer->add(*esHandle.product(), bunchCrossing); } else { m_ESOldDigitizer->add(*esHandle.product(), bunchCrossing); } } }
virtual void EcalDigiProducer::cacheEBDigis | ( | const EBDigiCollection * | ebDigiPtr | ) | const [inline, private, virtual] |
Reimplemented in EcalTBDigiProducer.
Definition at line 64 of file EcalDigiProducer.h.
Referenced by finalizeEvent().
{ }
virtual void EcalDigiProducer::cacheEEDigis | ( | const EEDigiCollection * | eeDigiPtr | ) | const [inline, private, virtual] |
Reimplemented in EcalTBDigiProducer.
Definition at line 65 of file EcalDigiProducer.h.
Referenced by finalizeEvent().
{ }
void EcalDigiProducer::checkCalibrations | ( | const edm::Event & | event, |
const edm::EventSetup & | eventSetup | ||
) | [private] |
Definition at line 404 of file EcalDigiProducer.cc.
References EcalMGPAGainRatio::gain12Over6(), EcalMGPAGainRatio::gain6Over1(), edm::EventSetup::get(), EcalADCToGeVConstant::getEBValue(), EcalADCToGeVConstant::getEEValue(), LogDebug, m_APDCoder, m_APDResponse, m_Coder, m_doFastES, m_EBResponse, m_EBs25notCont, m_EEResponse, m_EEs25notCont, m_ESDigitizer, m_ESElectronicsSim, m_ESElectronicsSimFast, m_ESOldDigitizer, m_ESShape, m_useLCcorrection, EcalCoder::MAXADC, EcalCoder::NGAINS, edm::ESHandle< T >::product(), EcalHitResponse::setEventTime(), EcalCoder::setFullScaleEnergy(), ESDigitizer::setGain(), ESShape::setGain(), ESElectronicsSim::setGain(), EcalCoder::setGainRatios(), EBHitResponse::setIntercal(), EcalCoder::setIntercalibConstants(), EcalHitResponse::setLaserConstants(), ESElectronicsSimFast::setMIPs(), ESElectronicsSim::setMIPs(), ESElectronicsSimFast::setMIPToGeV(), ESElectronicsSim::setMIPToGeV(), EcalCoder::setPedestals(), ESElectronicsSimFast::setPedestals(), and ESElectronicsSim::setPedestals().
Referenced by initializeEvent().
{ // Pedestals from event setup edm::ESHandle<EcalPedestals> dbPed ; eventSetup.get<EcalPedestalsRcd>().get( dbPed ) ; const EcalPedestals* pedestals ( dbPed.product() ) ; m_Coder->setPedestals( pedestals ) ; if( 0 != m_APDCoder ) m_APDCoder->setPedestals( pedestals ) ; // Ecal Intercalibration Constants edm::ESHandle<EcalIntercalibConstantsMC> pIcal ; eventSetup.get<EcalIntercalibConstantsMCRcd>().get( pIcal ) ; const EcalIntercalibConstantsMC* ical ( pIcal.product() ) ; m_Coder->setIntercalibConstants( ical ) ; if( 0 != m_APDCoder) m_APDCoder->setIntercalibConstants( ical ) ; m_EBResponse->setIntercal( ical ) ; if( 0 != m_APDResponse ) m_APDResponse->setIntercal( ical ) ; // Ecal LaserCorrection Constants edm::ESHandle<EcalLaserDbService> laser; eventSetup.get<EcalLaserDbRecord>().get(laser); const edm::TimeValue_t eventTimeValue = event.time().value(); m_EBResponse->setEventTime(eventTimeValue); m_EBResponse->setLaserConstants(laser.product(), m_useLCcorrection); m_EEResponse->setEventTime(eventTimeValue); m_EEResponse->setLaserConstants(laser.product(), m_useLCcorrection); // ADC -> GeV Scale edm::ESHandle<EcalADCToGeVConstant> pAgc; eventSetup.get<EcalADCToGeVConstantRcd>().get(pAgc); const EcalADCToGeVConstant* agc = pAgc.product(); // Gain Ratios edm::ESHandle<EcalGainRatios> pRatio; eventSetup.get<EcalGainRatiosRcd>().get(pRatio); const EcalGainRatios* gr = pRatio.product(); m_Coder->setGainRatios( gr ); if( 0 != m_APDCoder) m_APDCoder->setGainRatios( gr ); EcalMGPAGainRatio * defaultRatios = new EcalMGPAGainRatio(); double theGains[m_Coder->NGAINS+1]; theGains[0] = 0.; theGains[3] = 1.; theGains[2] = defaultRatios->gain6Over1() ; theGains[1] = theGains[2]*(defaultRatios->gain12Over6()) ; LogDebug("EcalDigi") << " Gains: " << "\n" << " g1 = " << theGains[1] << "\n" << " g2 = " << theGains[2] << "\n" << " g3 = " << theGains[3] ; delete defaultRatios; const double EBscale ( ( agc->getEBValue())*theGains[1]*(m_Coder->MAXADC)*m_EBs25notCont ) ; LogDebug("EcalDigi") << " GeV/ADC = " << agc->getEBValue() << "\n" << " notCont = " << m_EBs25notCont << "\n" << " saturation for EB = " << EBscale << ", " << m_EBs25notCont ; const double EEscale ( (agc->getEEValue())*theGains[1]*(m_Coder->MAXADC)*m_EEs25notCont ) ; LogDebug("EcalDigi") << " GeV/ADC = " << agc->getEEValue() << "\n" << " notCont = " << m_EEs25notCont << "\n" << " saturation for EB = " << EEscale << ", " << m_EEs25notCont ; m_Coder->setFullScaleEnergy( EBscale , EEscale ) ; if( 0 != m_APDCoder ) m_APDCoder->setFullScaleEnergy( EBscale , EEscale ) ; if( 0 != m_ESOldDigitizer || 0 != m_ESDigitizer ) { // ES condition objects edm::ESHandle<ESGain> hesgain ; edm::ESHandle<ESMIPToGeVConstant> hesMIPToGeV ; edm::ESHandle<ESPedestals> hesPedestals ; edm::ESHandle<ESIntercalibConstants> hesMIPs ; eventSetup.get<ESGainRcd>(). get( hesgain ) ; eventSetup.get<ESMIPToGeVConstantRcd>(). get( hesMIPToGeV ) ; eventSetup.get<ESPedestalsRcd>(). get( hesPedestals ) ; eventSetup.get<ESIntercalibConstantsRcd>().get( hesMIPs ) ; const ESGain* esgain ( hesgain.product() ) ; const ESPedestals* espeds ( hesPedestals.product() ) ; const ESIntercalibConstants* esmips ( hesMIPs.product() ) ; const ESMIPToGeVConstant* esMipToGeV ( hesMIPToGeV.product() ) ; const int ESGain ( 1.1 > esgain->getESGain() ? 1 : 2 ) ; const double ESMIPToGeV ( ( 1 == ESGain ) ? esMipToGeV->getESValueLow() : esMipToGeV->getESValueHigh() ) ; m_ESShape.setGain( ESGain ); if( !m_doFastES ) { m_ESElectronicsSim->setGain( ESGain ) ; m_ESElectronicsSim->setPedestals( espeds ) ; m_ESElectronicsSim->setMIPs( esmips ) ; m_ESElectronicsSim->setMIPToGeV( ESMIPToGeV ) ; } else { m_ESDigitizer->setGain( ESGain ) ; m_ESElectronicsSimFast->setPedestals( espeds ) ; m_ESElectronicsSimFast->setMIPs( esmips ) ; m_ESElectronicsSimFast->setMIPToGeV( ESMIPToGeV ) ; } } }
void EcalDigiProducer::checkGeometry | ( | const edm::EventSetup & | eventSetup | ) | [private] |
Definition at line 528 of file EcalDigiProducer.cc.
References edm::EventSetup::get(), m_Geometry, and updateGeometry().
Referenced by initializeEvent().
{ // TODO find a way to avoid doing this every event edm::ESHandle<CaloGeometry> hGeometry ; eventSetup.get<CaloGeometryRecord>().get( hGeometry ) ; const CaloGeometry* pGeometry = &*hGeometry; if( pGeometry != m_Geometry ) { m_Geometry = pGeometry; updateGeometry(); } }
void EcalDigiProducer::finalizeEvent | ( | edm::Event & | e, |
edm::EventSetup const & | c | ||
) | [virtual] |
Implements DigiAccumulatorMixMod.
Reimplemented in EcalTBDigiProducer.
Definition at line 361 of file EcalDigiProducer.cc.
References cacheEBDigis(), cacheEEDigis(), m_apdDigiTag, m_APDDigitizer, m_apdSeparateDigi, m_BarrelDigitizer, m_doFastES, m_EBdigiCollection, m_EEdigiCollection, m_EndcapDigitizer, m_ESdigiCollection, m_ESDigitizer, m_ESOldDigitizer, ESDigitizer::run(), CaloTDigitizer< Traits >::run(), and EcalTDigitizer< Traits >::run().
{ // Step B: Create empty output std::auto_ptr<EBDigiCollection> apdResult ( !m_apdSeparateDigi ? 0 : new EBDigiCollection() ) ; std::auto_ptr<EBDigiCollection> barrelResult ( new EBDigiCollection() ) ; std::auto_ptr<EEDigiCollection> endcapResult ( new EEDigiCollection() ) ; std::auto_ptr<ESDigiCollection> preshowerResult( new ESDigiCollection() ) ; // run the algorithm m_BarrelDigitizer->run( *barrelResult ) ; cacheEBDigis( &*barrelResult ) ; edm::LogInfo("DigiInfo") << "EB Digis: " << barrelResult->size() ; if( m_apdSeparateDigi ) { m_APDDigitizer->run( *apdResult ) ; edm::LogInfo("DigiInfo") << "APD Digis: " << apdResult->size() ; } m_EndcapDigitizer->run( *endcapResult ) ; edm::LogInfo("EcalDigi") << "EE Digis: " << endcapResult->size() ; cacheEEDigis( &*endcapResult ) ; if(m_doFastES) { m_ESDigitizer->run( *preshowerResult ) ; } else { m_ESOldDigitizer->run( *preshowerResult ) ; } edm::LogInfo("EcalDigi") << "ES Digis: " << preshowerResult->size(); // Step D: Put outputs into event if( m_apdSeparateDigi ) { event.put( apdResult, m_apdDigiTag ) ; } event.put( barrelResult, m_EBdigiCollection ) ; event.put( endcapResult, m_EEdigiCollection ) ; event.put( preshowerResult, m_ESdigiCollection ) ; }
void EcalDigiProducer::initializeEvent | ( | edm::Event const & | e, |
edm::EventSetup const & | c | ||
) | [virtual] |
Implements DigiAccumulatorMixMod.
Reimplemented in EcalTBDigiProducer.
Definition at line 286 of file EcalDigiProducer.cc.
References checkCalibrations(), checkGeometry(), EcalTDigitizer< Traits >::initializeHits(), CaloTDigitizer< Traits >::initializeHits(), m_APDDigitizer, m_apdSeparateDigi, m_BarrelDigitizer, m_doFastES, m_EndcapDigitizer, m_ESDigitizer, and m_ESOldDigitizer.
{ checkGeometry( eventSetup ); checkCalibrations( event, eventSetup ); m_BarrelDigitizer->initializeHits(); if(m_apdSeparateDigi) { m_APDDigitizer->initializeHits(); } m_EndcapDigitizer->initializeHits(); if(m_doFastES) { m_ESDigitizer->initializeHits(); } else { m_ESOldDigitizer->initializeHits(); } }
void EcalDigiProducer::updateGeometry | ( | ) | [private] |
Definition at line 544 of file EcalDigiProducer.cc.
References DetId::Ecal, EcalBarrel, EcalEndcap, EcalPreshower, CaloGeometry::getSubdetectorGeometry(), CaloSubdetectorGeometry::getValidDetIds(), m_APDResponse, m_doFastES, m_EBResponse, m_EEResponse, m_ESDigitizer, m_ESOldDigitizer, m_ESOldResponse, m_ESResponse, m_Geometry, ESDigitizer::setDetIds(), CaloTDigitizer< Traits >::setDetIds(), CaloHitResponse::setGeometry(), and EcalHitResponse::setGeometry().
Referenced by checkGeometry().
{ if( 0 != m_APDResponse ) m_APDResponse->setGeometry( m_Geometry->getSubdetectorGeometry( DetId::Ecal, EcalBarrel ) ) ; m_EBResponse->setGeometry( m_Geometry->getSubdetectorGeometry( DetId::Ecal, EcalBarrel ) ) ; m_EEResponse->setGeometry( m_Geometry->getSubdetectorGeometry( DetId::Ecal, EcalEndcap ) ) ; m_ESResponse->setGeometry( m_Geometry->getSubdetectorGeometry( DetId::Ecal, EcalPreshower ) ) ; m_ESOldResponse->setGeometry( m_Geometry ) ; const std::vector<DetId>* theESDets ( 0 != m_Geometry->getSubdetectorGeometry(DetId::Ecal, EcalPreshower) ? &m_Geometry->getSubdetectorGeometry(DetId::Ecal, EcalPreshower)->getValidDetIds() : 0 ) ; if( !m_doFastES ) { if( 0 != m_ESOldDigitizer && 0 != theESDets ) m_ESOldDigitizer->setDetIds( *theESDets ) ; } else { if( 0 != m_ESDigitizer && 0 != theESDets ) m_ESDigitizer->setDetIds( *theESDets ) ; } }
const bool EcalDigiProducer::m_addESNoise [private] |
Definition at line 108 of file EcalDigiProducer.h.
EcalCoder* EcalDigiProducer::m_APDCoder [private] |
Definition at line 125 of file EcalDigiProducer.h.
Referenced by checkCalibrations(), EcalDigiProducer(), and ~EcalDigiProducer().
const std::string EcalDigiProducer::m_apdDigiTag [private] |
Definition at line 97 of file EcalDigiProducer.h.
Referenced by EcalDigiProducer(), and finalizeEvent().
EBDigitizer* EcalDigiProducer::m_APDDigitizer [private] |
Definition at line 117 of file EcalDigiProducer.h.
Referenced by accumulateCaloHits(), EcalDigiProducer(), finalizeEvent(), initializeEvent(), and ~EcalDigiProducer().
Definition at line 124 of file EcalDigiProducer.h.
Referenced by EcalDigiProducer(), and ~EcalDigiProducer().
const APDSimParameters* EcalDigiProducer::m_apdParameters [private] |
Definition at line 98 of file EcalDigiProducer.h.
Referenced by ~EcalDigiProducer().
EBHitResponse* EcalDigiProducer::m_APDResponse [private] |
Definition at line 100 of file EcalDigiProducer.h.
Referenced by checkCalibrations(), EcalDigiProducer(), updateGeometry(), and ~EcalDigiProducer().
const bool EcalDigiProducer::m_apdSeparateDigi [private] |
Definition at line 88 of file EcalDigiProducer.h.
Referenced by accumulateCaloHits(), EcalDigiProducer(), finalizeEvent(), and initializeEvent().
const APDShape EcalDigiProducer::m_APDShape [private] |
Definition at line 76 of file EcalDigiProducer.h.
EBDigitizer* EcalDigiProducer::m_BarrelDigitizer [private] |
Definition at line 118 of file EcalDigiProducer.h.
Referenced by accumulateCaloHits(), EcalDigiProducer(), finalizeEvent(), initializeEvent(), and ~EcalDigiProducer().
EcalCoder* EcalDigiProducer::m_Coder [private] |
Definition at line 122 of file EcalDigiProducer.h.
Referenced by checkCalibrations(), EcalDigiProducer(), and ~EcalDigiProducer().
const bool EcalDigiProducer::m_doFastES [private] |
Definition at line 110 of file EcalDigiProducer.h.
Referenced by accumulateCaloHits(), checkCalibrations(), finalizeEvent(), initializeEvent(), and updateGeometry().
CorrelatedNoisifier<EcalCorrMatrix>* EcalDigiProducer::m_EBCorrNoise[3] [private] |
Definition at line 129 of file EcalDigiProducer.h.
Referenced by EcalDigiProducer(), and ~EcalDigiProducer().
const std::string EcalDigiProducer::m_EBdigiCollection [private] |
Definition at line 81 of file EcalDigiProducer.h.
Referenced by EcalDigiProducer(), and finalizeEvent().
EBHitResponse* EcalDigiProducer::m_EBResponse [protected] |
Definition at line 102 of file EcalDigiProducer.h.
Referenced by checkCalibrations(), EcalDigiProducer(), EcalTBDigiProducer::setPhaseShift(), updateGeometry(), and ~EcalDigiProducer().
const double EcalDigiProducer::m_EBs25notCont [private] |
Definition at line 90 of file EcalDigiProducer.h.
Referenced by checkCalibrations().
const EBShape EcalDigiProducer::m_EBShape [private] |
Definition at line 77 of file EcalDigiProducer.h.
CorrelatedNoisifier<EcalCorrMatrix>* EcalDigiProducer::m_EECorrNoise[3] [private] |
Definition at line 130 of file EcalDigiProducer.h.
Referenced by EcalDigiProducer(), and ~EcalDigiProducer().
const std::string EcalDigiProducer::m_EEdigiCollection [private] |
Definition at line 82 of file EcalDigiProducer.h.
Referenced by EcalDigiProducer(), and finalizeEvent().
EEHitResponse* EcalDigiProducer::m_EEResponse [protected] |
Definition at line 103 of file EcalDigiProducer.h.
Referenced by checkCalibrations(), EcalDigiProducer(), EcalTBDigiProducer::setPhaseShift(), updateGeometry(), and ~EcalDigiProducer().
const double EcalDigiProducer::m_EEs25notCont [private] |
Definition at line 91 of file EcalDigiProducer.h.
Referenced by checkCalibrations().
const EEShape EcalDigiProducer::m_EEShape [private] |
Definition at line 78 of file EcalDigiProducer.h.
Definition at line 121 of file EcalDigiProducer.h.
Referenced by EcalDigiProducer(), and ~EcalDigiProducer().
EEDigitizer* EcalDigiProducer::m_EndcapDigitizer [private] |
Definition at line 119 of file EcalDigiProducer.h.
Referenced by accumulateCaloHits(), EcalDigiProducer(), finalizeEvent(), initializeEvent(), and ~EcalDigiProducer().
const std::string EcalDigiProducer::m_ESdigiCollection [private] |
Definition at line 83 of file EcalDigiProducer.h.
Referenced by EcalDigiProducer(), and finalizeEvent().
ESDigitizer* EcalDigiProducer::m_ESDigitizer [private] |
Definition at line 115 of file EcalDigiProducer.h.
Referenced by accumulateCaloHits(), checkCalibrations(), finalizeEvent(), initializeEvent(), updateGeometry(), and ~EcalDigiProducer().
Definition at line 112 of file EcalDigiProducer.h.
Referenced by checkCalibrations(), and ~EcalDigiProducer().
Definition at line 114 of file EcalDigiProducer.h.
Referenced by checkCalibrations(), and ~EcalDigiProducer().
ESOldDigitizer* EcalDigiProducer::m_ESOldDigitizer [private] |
Definition at line 113 of file EcalDigiProducer.h.
Referenced by accumulateCaloHits(), checkCalibrations(), finalizeEvent(), initializeEvent(), updateGeometry(), and ~EcalDigiProducer().
CaloHitResponse* EcalDigiProducer::m_ESOldResponse [private] |
Definition at line 106 of file EcalDigiProducer.h.
Referenced by updateGeometry(), and ~EcalDigiProducer().
ESHitResponse* EcalDigiProducer::m_ESResponse [private] |
Definition at line 105 of file EcalDigiProducer.h.
Referenced by updateGeometry(), and ~EcalDigiProducer().
ESShape EcalDigiProducer::m_ESShape [private] |
Definition at line 79 of file EcalDigiProducer.h.
Referenced by checkCalibrations().
const CaloGeometry* EcalDigiProducer::m_Geometry [private] |
Definition at line 127 of file EcalDigiProducer.h.
Referenced by checkGeometry(), and updateGeometry().
const std::string EcalDigiProducer::m_hitsProducerTag [private] |
Definition at line 84 of file EcalDigiProducer.h.
Referenced by accumulate().
const EcalSimParameterMap* EcalDigiProducer::m_ParameterMap [protected] |
Definition at line 95 of file EcalDigiProducer.h.
Referenced by EcalDigiProducer(), EcalTBDigiProducer::setPhaseShift(), and ~EcalDigiProducer().
const unsigned int EcalDigiProducer::m_readoutFrameSize [private] |
Definition at line 93 of file EcalDigiProducer.h.
Referenced by EcalDigiProducer().
bool EcalDigiProducer::m_useLCcorrection [private] |
Definition at line 86 of file EcalDigiProducer.h.
Referenced by checkCalibrations().