CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
EcalDigiProducer.cc
Go to the documentation of this file.
28 
37 
38 
40  m_APDDigitizer ( 0 ) ,
41  m_BarrelDigitizer ( 0 ) ,
42  m_EndcapDigitizer ( 0 ) ,
43  m_ESDigitizer ( 0 ) ,
44  m_ESDigitizerFast ( 0 ) ,
45  m_ParameterMap ( 0 ) ,
46  m_APDShape ( params.getParameter<double>( "apdShapeTstart" ) ,
47  params.getParameter<double>( "apdShapeTau" ) ) ,
48  m_EBShape ( ) ,
49  m_EEShape ( ) ,
50  m_ESShape ( new ESShape() ) ,
51  m_APDResponse ( 0 ) ,
52  m_EBResponse ( 0 ) ,
53  m_EEResponse ( 0 ) ,
54  m_ESResponse ( 0 ) ,
55  m_ElectronicsSim ( 0 ) ,
56  m_ESElectronicsSim ( 0 ) ,
57  m_ESElectronicsSimFast ( 0 ) ,
58  m_Coder ( 0 ) ,
59  m_APDElectronicsSim ( 0 ) ,
60  m_APDCoder ( 0 ) ,
61  m_Geometry ( 0 ) ,
62  m_apdParameters ( 0 )
63 {
65 
66  m_EBdigiCollection = params.getParameter<std::string>("EBdigiCollection");
67  m_EEdigiCollection = params.getParameter<std::string>("EEdigiCollection");
68  m_ESdigiCollection = params.getParameter<std::string>("ESdigiCollection");
69  const bool addNoise = params.getParameter<bool> ("doNoise");
70  const double simHitToPhotoelectronsBarrel = params.getParameter<double> ("simHitToPhotoelectronsBarrel");
71  const double simHitToPhotoelectronsEndcap = params.getParameter<double> ("simHitToPhotoelectronsEndcap");
72  const double photoelectronsToAnalogBarrel = params.getParameter<double> ("photoelectronsToAnalogBarrel");
73  const double photoelectronsToAnalogEndcap = params.getParameter<double> ("photoelectronsToAnalogEndcap");
74  const double samplingFactor = params.getParameter<double> ("samplingFactor");
75  const double timePhase = params.getParameter<double> ("timePhase");
76  const unsigned int readoutFrameSize = params.getParameter<int> ("readoutFrameSize");
77  const int binOfMaximum = params.getParameter<int> ("binOfMaximum");
78  const bool doPhotostatistics = params.getParameter<bool> ("doPhotostatistics");
79  const bool syncPhase = params.getParameter<bool> ("syncPhase");
80  const bool cosmicsPhase = params.getParameter<bool> ("cosmicsPhase");
81  const double cosmicsShift = params.getParameter<double> ("cosmicsShift");
82  const std::vector<double> ebCorMatG12 = params.getParameter< std::vector<double> >("EBCorrNoiseMatrixG12");
83  const std::vector<double> eeCorMatG12 = params.getParameter< std::vector<double> >("EECorrNoiseMatrixG12");
84  const std::vector<double> ebCorMatG06 = params.getParameter< std::vector<double> >("EBCorrNoiseMatrixG06");
85  const std::vector<double> eeCorMatG06 = params.getParameter< std::vector<double> >("EECorrNoiseMatrixG06");
86  const std::vector<double> ebCorMatG01 = params.getParameter< std::vector<double> >("EBCorrNoiseMatrixG01");
87  const std::vector<double> eeCorMatG01 = params.getParameter< std::vector<double> >("EECorrNoiseMatrixG01");
88  const bool applyConstantTerm = params.getParameter<bool> ("applyConstantTerm");
89  const double rmsConstantTerm = params.getParameter<double> ("ConstantTerm");
90  const bool addESNoise = params.getParameter<bool> ("doESNoise");
91  const int numESdetId = params.getParameter<int> ("numESdetId");
92  m_doFast = params.getParameter<bool> ("doFast");
93  m_EBs25notCont = params.getParameter<double> ("EBs25notContainment");
94  m_EEs25notCont = params.getParameter<double> ("EEs25notContainment");
95  m_hitsProducerTag = params.getParameter<std::string>("hitsProducer");
96 
97  const bool apdAddToBarrel ( params.getParameter<bool> ("apdAddToBarrel") ) ;
98  const bool apdSeparateDigi ( params.getParameter<bool> ("apdSeparateDigi") ) ;
99  const double apdSimToPELow ( params.getParameter<double> ("apdSimToPELow" ) ) ;
100  const double apdSimToPEHigh ( params.getParameter<double> ("apdSimToPEHigh") ) ;
101  const double apdTimeOffset ( params.getParameter<double> ("apdTimeOffset" ) ) ;
102  const double apdTimeOffWidth ( params.getParameter<double> ("apdTimeOffWidth" ) ) ;
103  const bool apdDoPEStats ( params.getParameter<bool> ("apdDoPEStats" ) ) ;
104  const std::string apdDigiTag ( params.getParameter<std::string>("apdDigiTag") ) ;
105 
106 //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
107 
108  if( apdSeparateDigi ) produces<EBDigiCollection>( apdDigiTag ) ;
109  produces<EBDigiCollection>( m_EBdigiCollection ) ;
110  produces<EEDigiCollection>( m_EEdigiCollection ) ;
111  produces<ESDigiCollection>( m_ESdigiCollection ) ;
112 
113  // initialize the default valuer for hardcoded parameters and the EB/EE shape
114 
115  m_ParameterMap = new EcalSimParameterMap( simHitToPhotoelectronsBarrel ,
116  simHitToPhotoelectronsEndcap ,
117  photoelectronsToAnalogBarrel ,
118  photoelectronsToAnalogEndcap ,
119  samplingFactor ,
120  timePhase ,
121  readoutFrameSize ,
122  binOfMaximum ,
123  doPhotostatistics ,
124  syncPhase ) ;
125 
126  m_apdParameters = new APDSimParameters( apdAddToBarrel ,
127  apdSeparateDigi ,
128  apdSimToPELow ,
129  apdSimToPEHigh ,
130  apdTimeOffset ,
131  apdTimeOffWidth ,
132  apdDoPEStats ,
133  apdDigiTag ) ;
134 
135 
136 
137  if( apdSeparateDigi )
138  m_APDResponse = new EBHitResponse( m_ParameterMap ,
139  &m_EBShape ,
140  true ,
142  &m_APDShape ) ;
143 
144  m_EBResponse = new EBHitResponse( m_ParameterMap ,
145  &m_EBShape ,
146  false , // barrel
148  &m_APDShape ) ;
149 
150  m_EEResponse = new CaloHitRespoNew( m_ParameterMap, &m_EEShape ) ;
151  m_ESResponse = new CaloHitResponse( m_ParameterMap, m_ESShape ) ;
152 
153  // further phase for cosmics studies
154  if( cosmicsPhase )
155  {
156  m_EBResponse->setPhaseShift( 1. + cosmicsShift ) ;
157  m_EEResponse->setPhaseShift( 1. + cosmicsShift ) ;
158  }
159 
160  EcalCorrMatrix ebMatrix[ 3 ] ;
161  EcalCorrMatrix eeMatrix[ 3 ] ;
162 
163  assert( ebCorMatG12.size() == readoutFrameSize ) ;
164  assert( eeCorMatG12.size() == readoutFrameSize ) ;
165  assert( ebCorMatG06.size() == readoutFrameSize ) ;
166  assert( eeCorMatG06.size() == readoutFrameSize ) ;
167  assert( ebCorMatG01.size() == readoutFrameSize ) ;
168  assert( eeCorMatG01.size() == readoutFrameSize ) ;
169 
170  assert( 1.e-7 > fabs( ebCorMatG12[0] - 1.0 ) ) ;
171  assert( 1.e-7 > fabs( ebCorMatG06[0] - 1.0 ) ) ;
172  assert( 1.e-7 > fabs( ebCorMatG01[0] - 1.0 ) ) ;
173  assert( 1.e-7 > fabs( eeCorMatG12[0] - 1.0 ) ) ;
174  assert( 1.e-7 > fabs( eeCorMatG06[0] - 1.0 ) ) ;
175  assert( 1.e-7 > fabs( eeCorMatG01[0] - 1.0 ) ) ;
176 
177  for ( unsigned int row ( 0 ) ; row != readoutFrameSize ; ++row )
178  {
179  assert( 0 == row || 1. >= ebCorMatG12[row] ) ;
180  assert( 0 == row || 1. >= ebCorMatG06[row] ) ;
181  assert( 0 == row || 1. >= ebCorMatG01[row] ) ;
182  assert( 0 == row || 1. >= eeCorMatG12[row] ) ;
183  assert( 0 == row || 1. >= eeCorMatG06[row] ) ;
184  assert( 0 == row || 1. >= eeCorMatG01[row] ) ;
185  for ( unsigned int column ( 0 ) ; column <= row ; ++column )
186  {
187  const unsigned int index ( row - column ) ;
188  ebMatrix[0]( row, column ) = ebCorMatG12[ index ] ;
189  eeMatrix[0]( row, column ) = eeCorMatG12[ index ] ;
190  ebMatrix[1]( row, column ) = ebCorMatG06[ index ] ;
191  eeMatrix[1]( row, column ) = eeCorMatG06[ index ] ;
192  ebMatrix[2]( row, column ) = ebCorMatG01[ index ] ;
193  eeMatrix[2]( row, column ) = eeCorMatG01[ index ] ;
194  }
195  }
196 
197  m_EBCorrNoise[0] = new CorrelatedNoisifier<EcalCorrMatrix>( ebMatrix[0] ) ;
198  m_EECorrNoise[0] = new CorrelatedNoisifier<EcalCorrMatrix>( eeMatrix[0] ) ;
199  m_EBCorrNoise[1] = new CorrelatedNoisifier<EcalCorrMatrix>( ebMatrix[1] ) ;
200  m_EECorrNoise[1] = new CorrelatedNoisifier<EcalCorrMatrix>( eeMatrix[1] ) ;
201  m_EBCorrNoise[2] = new CorrelatedNoisifier<EcalCorrMatrix>( ebMatrix[2] ) ;
202  m_EECorrNoise[2] = new CorrelatedNoisifier<EcalCorrMatrix>( eeMatrix[2] ) ;
203 
204  m_Coder = new EcalCoder( addNoise ,
205  m_EBCorrNoise[0] ,
206  m_EECorrNoise[0] ,
207  m_EBCorrNoise[1] ,
208  m_EECorrNoise[1] ,
209  m_EBCorrNoise[2] ,
210  m_EECorrNoise[2] ) ;
211 
212  m_ElectronicsSim = new EcalElectronicsSim( m_ParameterMap ,
213  m_Coder ,
214  applyConstantTerm ,
215  rmsConstantTerm ) ;
216 
217 
218  if( apdSeparateDigi )
219  {
220  m_APDCoder = new EcalCoder( false ,
221  m_EBCorrNoise[0] ,
222  m_EECorrNoise[0] ,
223  m_EBCorrNoise[1] ,
224  m_EECorrNoise[1] ,
225  m_EBCorrNoise[2] ,
226  m_EECorrNoise[2] ) ;
227 
228  m_APDElectronicsSim = new EcalElectronicsSim( m_ParameterMap ,
229  m_APDCoder ,
230  applyConstantTerm ,
231  rmsConstantTerm ) ;
232 
235  false ) ;
236  }
237 
240  addNoise ) ;
241 
244  addNoise ) ;
245 
246  if( !m_doFast )
247  {
248  m_ESElectronicsSim = new ESElectronicsSim( addESNoise ) ;
249 
252  addESNoise );
253  }
254  else
255  {
256  m_ESElectronicsSimFast = new ESElectronicsSimFast( addESNoise ) ;
257 
260  addESNoise ,
261  numESdetId ) ;
262  }
263 }
264 
266 {
267  delete m_APDDigitizer ;
268  delete m_BarrelDigitizer ;
269  delete m_EndcapDigitizer ;
270  delete m_ESDigitizer ;
271  delete m_ESDigitizerFast ;
272  delete m_ParameterMap ;
273  delete m_ESShape ;
274  delete m_APDResponse ;
275  delete m_EBResponse ;
276  delete m_EEResponse ;
277  delete m_ESResponse ;
278  delete m_EBCorrNoise[0] ;
279  delete m_EECorrNoise[0] ;
280  delete m_EBCorrNoise[1] ;
281  delete m_EECorrNoise[1] ;
282  delete m_EBCorrNoise[2] ;
283  delete m_EECorrNoise[2] ;
284  delete m_ElectronicsSim ;
285  delete m_ESElectronicsSim ;
286  delete m_ESElectronicsSimFast ;
287  delete m_Coder ;
288  delete m_APDElectronicsSim ;
289  delete m_APDCoder ;
290  delete m_apdParameters ;
291 }
292 
293 void
295  const edm::EventSetup& eventSetup )
296 {
297  // Step A: Get Inputs
298 
299  checkGeometry( eventSetup );
300  checkCalibrations( eventSetup );
301 
302  // Get input
303  edm::Handle<CrossingFrame<PCaloHit> > crossingFrame;
304 
305  // test access to SimHits
306  const std::string barrelHitsName ( m_hitsProducerTag + "EcalHitsEB" ) ;
307  const std::string endcapHitsName ( m_hitsProducerTag + "EcalHitsEE" ) ;
308  const std::string preshowerHitsName ( m_hitsProducerTag + "EcalHitsES" ) ;
309 
310  event.getByLabel( "mix",
311  barrelHitsName ,
312  crossingFrame ) ;
313 
314  MixCollection<PCaloHit>* EBHits (
315  !crossingFrame.isValid() ? 0 :
316  new MixCollection<PCaloHit>( crossingFrame.product() ) ) ;
317 
318  const bool isEB ( crossingFrame.isValid() &&
319  0 != EBHits &&
320  EBHits->inRegistry() ) ;
321 
322  if( !crossingFrame.isValid() )
323  edm::LogError("EcalDigiProducer") << "Error! can't get the product "
324  << barrelHitsName.c_str() ;
325 
326  event.getByLabel( "mix",
327  endcapHitsName ,
328  crossingFrame ) ;
329 
330  MixCollection<PCaloHit>* EEHits (
331  !crossingFrame.isValid() ? 0 :
332  new MixCollection<PCaloHit>( crossingFrame.product() ) ) ;
333 
334  const bool isEE ( crossingFrame.isValid() &&
335  0 != EEHits &&
336  EEHits->inRegistry() ) ;
337 
338  if( !crossingFrame.isValid() )
339  edm::LogError("EcalDigiProducer") << "Error! can't get the product "
340  << endcapHitsName.c_str() ;
341 
342  event.getByLabel( "mix",
343  preshowerHitsName ,
344  crossingFrame ) ;
345 
346  MixCollection<PCaloHit>* ESHits (
347  !crossingFrame.isValid() ? 0 :
348  new MixCollection<PCaloHit>( crossingFrame.product() ) ) ;
349 
350  const bool isES ( crossingFrame.isValid() &&
351  0 != ESHits &&
352  ESHits->inRegistry() ) ;
353 
354  if( !crossingFrame.isValid() )
355  edm::LogError("EcalDigiProducer") << "Error! can't get the product "
356  << preshowerHitsName.c_str() ;
357 
358  const bool apdSeparateDigi ( 0 != m_APDResponse ) ;
359 
360  // Step B: Create empty output
361  std::auto_ptr<EBDigiCollection> apdResult ( !apdSeparateDigi ? 0 :
362  new EBDigiCollection() ) ;
363  std::auto_ptr<EBDigiCollection> barrelResult ( new EBDigiCollection() ) ;
364  std::auto_ptr<EEDigiCollection> endcapResult ( new EEDigiCollection() ) ;
365  std::auto_ptr<ESDigiCollection> preshowerResult( new ESDigiCollection() ) ;
366 
367  // run the algorithm
368 
369  if( isEB )
370  {
371  std::auto_ptr<MixCollection<PCaloHit> > barrelHits( EBHits ) ;
372  m_BarrelDigitizer->run( *barrelHits ,
373  *barrelResult ) ;
374 
375  edm::LogInfo("DigiInfo") << "EB Digis: " << barrelResult->size() ;
376 
377  if( apdSeparateDigi )
378  {
379  m_APDDigitizer->run( *barrelHits ,
380  *apdResult ) ;
381 
382  edm::LogInfo("DigiInfo") << "APD Digis: " << apdResult->size() ;
383  }
384  }
385 
386  if( isEE )
387  {
388  std::auto_ptr<MixCollection<PCaloHit> > endcapHits( EEHits ) ;
389  m_EndcapDigitizer->run( *endcapHits ,
390  *endcapResult ) ;
391  edm::LogInfo("EcalDigi") << "EE Digis: " << endcapResult->size() ;
392  }
393 
394  if( isES )
395  {
396  std::auto_ptr<MixCollection<PCaloHit> > preshowerHits( ESHits ) ;
397  if (!m_doFast)
398  {
399  m_ESDigitizer->run( *preshowerHits ,
400  *preshowerResult ) ;
401  }
402  else
403  {
404  m_ESDigitizerFast->run(*preshowerHits, *preshowerResult);
405  }
406  edm::LogInfo("EcalDigi") << "ES Digis: " << preshowerResult->size();
407  }
408 
409  const std::string& apdDigiTag ( m_apdParameters->digiTag() ) ;
410 
411  // Step D: Put outputs into event
412  if( apdSeparateDigi )
413  event.put( apdResult, apdDigiTag ) ;
414  event.put( barrelResult, m_EBdigiCollection ) ;
415  event.put( endcapResult, m_EEdigiCollection ) ;
416  event.put( preshowerResult, m_ESdigiCollection ) ;
417 
418 }
419 
420 void
422 {
423  // Pedestals from event setup
424 
426  eventSetup.get<EcalPedestalsRcd>().get( dbPed ) ;
427  const EcalPedestals* pedestals ( dbPed.product() ) ;
428 
429  m_Coder->setPedestals( pedestals ) ;
430  if( 0 != m_APDCoder ) m_APDCoder->setPedestals( pedestals ) ;
431 
432  // Ecal Intercalibration Constants
434  eventSetup.get<EcalIntercalibConstantsMCRcd>().get( pIcal ) ;
435  const EcalIntercalibConstantsMC* ical ( pIcal.product() ) ;
436 
438  if( 0 != m_APDCoder) m_APDCoder->setIntercalibConstants( ical ) ;
439 
440  m_EBResponse->setIntercal( ical ) ;
441  if( 0 != m_APDResponse ) m_APDResponse->setIntercal( ical ) ;
442 
443  // ADC -> GeV Scale
445  eventSetup.get<EcalADCToGeVConstantRcd>().get(pAgc);
446  const EcalADCToGeVConstant* agc = pAgc.product();
447 
448  // Gain Ratios
450  eventSetup.get<EcalGainRatiosRcd>().get(pRatio);
451  const EcalGainRatios* gr = pRatio.product();
452 
453  m_Coder->setGainRatios( gr );
454  if( 0 != m_APDCoder) m_APDCoder->setGainRatios( gr );
455 
456  EcalMGPAGainRatio * defaultRatios = new EcalMGPAGainRatio();
457 
458  double theGains[m_Coder->NGAINS+1];
459  theGains[0] = 0.;
460  theGains[3] = 1.;
461  theGains[2] = defaultRatios->gain6Over1() ;
462  theGains[1] = theGains[2]*(defaultRatios->gain12Over6()) ;
463 
464  LogDebug("EcalDigi") << " Gains: " << "\n" << " g1 = " << theGains[1]
465  << "\n" << " g2 = " << theGains[2]
466  << "\n" << " g3 = " << theGains[3] ;
467 
468  delete defaultRatios;
469 
470  const double EBscale (
471  ( agc->getEBValue())*theGains[1]*(m_Coder->MAXADC)*m_EBs25notCont ) ;
472 
473  LogDebug("EcalDigi") << " GeV/ADC = " << agc->getEBValue()
474  << "\n" << " notCont = " << m_EBs25notCont
475  << "\n" << " saturation for EB = " << EBscale
476  << ", " << m_EBs25notCont ;
477 
478  const double EEscale (
479  (agc->getEEValue())*theGains[1]*(m_Coder->MAXADC)*m_EEs25notCont ) ;
480 
481  LogDebug("EcalDigi") << " GeV/ADC = " << agc->getEEValue()
482  << "\n" << " notCont = " << m_EEs25notCont
483  << "\n" << " saturation for EB = " << EEscale
484  << ", " << m_EEs25notCont ;
485 
486  m_Coder->setFullScaleEnergy( EBscale ,
487  EEscale ) ;
488  if( 0 != m_APDCoder ) m_APDCoder->setFullScaleEnergy( EBscale ,
489  EEscale ) ;
490 
491 
492  // ES condition objects
493  edm::ESHandle<ESGain> hesgain ;
495  edm::ESHandle<ESPedestals> hesPedestals ;
497 
498  eventSetup.get<ESGainRcd>(). get( hesgain ) ;
499  eventSetup.get<ESMIPToGeVConstantRcd>(). get( hesMIPToGeV ) ;
500  eventSetup.get<ESPedestalsRcd>(). get( hesPedestals ) ;
501  eventSetup.get<ESIntercalibConstantsRcd>().get( hesMIPs ) ;
502 
503  const ESGain* esgain ( hesgain.product() ) ;
504  const ESPedestals* espeds ( hesPedestals.product() ) ;
505  const ESIntercalibConstants* esmips ( hesMIPs.product() ) ;
506  const ESMIPToGeVConstant* esMipToGeV ( hesMIPToGeV.product() ) ;
507  const int ESGain ( 1.1 > esgain->getESGain() ? 1 : 2 ) ;
508  const double ESMIPToGeV ( ( 1 == ESGain ) ?
509  esMipToGeV->getESValueLow() :
510  esMipToGeV->getESValueHigh() ) ;
511 
513 
514  if( !m_doFast )
515  {
517  m_ESElectronicsSim->setPedestals( espeds ) ;
518  m_ESElectronicsSim->setMIPs( esmips ) ;
519  m_ESElectronicsSim->setMIPToGeV( ESMIPToGeV ) ;
520  }
521  else
522  {
526  m_ESElectronicsSimFast->setMIPs( esmips ) ;
527  m_ESElectronicsSimFast->setMIPToGeV( ESMIPToGeV ) ;
528  }
529 }
530 
531 void
533 {
534  // TODO find a way to avoid doing this every event
535  edm::ESHandle<CaloGeometry> hGeometry ;
536  eventSetup.get<CaloGeometryRecord>().get( hGeometry ) ;
537 
538  const CaloGeometry* pGeometry = &*hGeometry;
539 
540  if( pGeometry != m_Geometry )
541  {
542  m_Geometry = pGeometry;
543  updateGeometry();
544  }
545 }
546 
547 void
549 {
557 // m_Geometry->getSubdetectorGeometry( DetId::Ecal, EcalPreshower ) ) ;
558 
559 
560  const std::vector<DetId>& theESDets (
563 
564  if( !m_doFast )
565  {
566  m_ESDigitizer->setDetIds( theESDets ) ;
567  }
568  else
569  {
570  m_ESDigitizerFast->setDetIds( theESDets ) ;
571  }
572 }
#define LogDebug(id)
EEDigitizer * m_EndcapDigitizer
T getParameter(std::string const &) const
const CaloSubdetectorGeometry * getSubdetectorGeometry(const DetId &id) const
access the subdetector geometry for the given subdetector directly
Definition: CaloGeometry.cc:43
void setGain(const int gain)
CaloHitRespoNew * m_EEResponse
void setGeometry(const CaloGeometry *geometry)
geometry needed for time-of-flight
void setGain(const int gain)
virtual ~EcalDigiProducer()
EcalTDigitizer< EEDigitizerTraits > EEDigitizer
void setMIPToGeV(const double MIPToGeV)
EcalCoder * m_Coder
CorrelatedNoisifier< EcalCorrMatrix > * m_EBCorrNoise[3]
const APDShape m_APDShape
EcalDigiProducer(const edm::ParameterSet &params)
const EcalSimParameterMap * m_ParameterMap
Creates electronics signals from EB hits , including APD.
Definition: EBHitResponse.h:17
Definition: ESGain.h:5
void setGain(const int gain)
Definition: ESShape.h:26
Creates electronics signals from hits.
void run(MixCollection< PCaloHit > &input, DigiCollection &output)
bool inRegistry() const
Definition: MixCollection.h:27
void setMIPs(const ESIntercalibConstants *mips)
void setMIPToGeV(const double MIPToGeV)
void setIntercalibConstants(const EcalIntercalibConstantsMC *ical)
Definition: EcalCoder.cc:58
void run(MixCollection< PCaloHit > &input, ESDigiCollection &output)
turns hits into digis
ESElectronicsSimFast * m_ESElectronicsSimFast
ESDigitizer * m_ESDigitizer
virtual const std::vector< DetId > & getValidDetIds(DetId::Detector det=DetId::Detector(0), int subdet=0) const
Get a list of valid detector ids (for the given subdetector)
void setPedestals(const ESPedestals *peds)
void setPedestals(const ESPedestals *peds)
CorrelatedNoisifier< EcalCorrMatrix > * m_EECorrNoise[3]
void setGeometry(const CaloSubdetectorGeometry *geometry)
EcalElectronicsSim * m_ElectronicsSim
CaloHitResponse * m_ESResponse
std::string m_EBdigiCollection
void setIntercal(const EcalIntercalibConstantsMC *ical)
EBHitResponse * m_APDResponse
Creates electronics signals from hits.
void setPedestals(const EcalPedestals *pedestals)
can be fetched every event from the EventSetup
Definition: EcalCoder.cc:46
void run(MixCollection< PCaloHit > &input, DigiCollection &output)
turns hits into digis
EBHitResponse * m_EBResponse
ESElectronicsSim * m_ESElectronicsSim
APDSimParameters * m_apdParameters
EBDigitizer * m_BarrelDigitizer
float gain6Over1() const
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
math::ErrorD< CaloSamples::MAXSAMPLES >::type EcalCorrMatrix
bool isValid() const
Definition: HandleBase.h:76
const CaloGeometry * m_Geometry
void setPhaseShift(double phaseShift)
EcalCoder * m_APDCoder
void checkGeometry(const edm::EventSetup &eventSetup)
void setGainRatios(const EcalGainRatios *gainRatios)
Definition: EcalCoder.cc:52
void setFullScaleEnergy(double EBscale, double EEscale)
Definition: EcalCoder.cc:37
CaloTDigitizer< ESDigitizerTraits > ESDigitizer
std::string m_ESdigiCollection
EcalTDigitizer< EBDigitizerTraits > EBDigitizer
const T & get() const
Definition: EventSetup.h:55
T const * product() const
Definition: ESHandle.h:62
edm::SortedCollection< ESDataFrame > ESDigiCollection
float gain12Over6() const
void setDetIds(const std::vector< DetId > &detIds)
tell the digitizer which cells exist
void setGain(const int gain)
set ES Gain
T const * product() const
Definition: Handle.h:74
EBDigitizer * m_APDDigitizer
const std::string & digiTag() const
ESFastTDigitizer * m_ESDigitizerFast
void setDetIds(const std::vector< DetId > &detIds)
virtual void produce(edm::Event &event, const edm::EventSetup &eventSetup)
const EEShape m_EEShape
std::string m_hitsProducerTag
void setMIPs(const ESIntercalibConstants *mips)
const EBShape m_EBShape
void checkCalibrations(const edm::EventSetup &eventSetup)
EcalElectronicsSim * m_APDElectronicsSim
std::string m_EEdigiCollection