CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
EcalTrivialConditionRetriever.h
Go to the documentation of this file.
1 //
2 // Created: 2 Mar 2006
3 // Shahram Rahatlou, University of Rome & INFN
4 //
5 #ifndef CalibCalorimetry_EcalPlugins_EcalTrivialConditionRetriever_H
6 #define CalibCalorimetry_EcalPlugins_EcalTrivialConditionRetriever_H
7 // system include files
8 #include <string>
9 #include <vector>
10 
11 // user include files
14 
17 
22 
26 
31 
34 
37 
38 
41 
44 
47 
50 
53 
57 
60 
63 
66 
69 
72 
77 
92 
94 
99 
102 
105 
108 
111 
112 // forward declarations
113 
114 namespace edm{
115  class ParameterSet;
116 }
117 
120 {
121 
122 public:
125 
126  // ---------- member functions ---------------------------
127  virtual std::auto_ptr<EcalPedestals> produceEcalPedestals( const EcalPedestalsRcd& );
128  virtual std::auto_ptr<EcalWeightXtalGroups> produceEcalWeightXtalGroups( const EcalWeightXtalGroupsRcd& );
129  virtual std::auto_ptr<EcalLinearCorrections> produceEcalLinearCorrections( const EcalLinearCorrectionsRcd& );
130  virtual std::auto_ptr<EcalIntercalibConstants> produceEcalIntercalibConstants( const EcalIntercalibConstantsRcd& );
131  virtual std::auto_ptr<EcalIntercalibConstantsMC> produceEcalIntercalibConstantsMC( const EcalIntercalibConstantsMCRcd& );
132  virtual std::auto_ptr<EcalIntercalibErrors> produceEcalIntercalibErrors( const EcalIntercalibErrorsRcd& );
133  virtual std::auto_ptr<EcalTimeCalibConstants> produceEcalTimeCalibConstants( const EcalTimeCalibConstantsRcd& );
134  virtual std::auto_ptr<EcalTimeCalibErrors> produceEcalTimeCalibErrors( const EcalTimeCalibErrorsRcd& );
135  virtual std::auto_ptr<EcalGainRatios> produceEcalGainRatios( const EcalGainRatiosRcd& );
136  virtual std::auto_ptr<EcalADCToGeVConstant> produceEcalADCToGeVConstant( const EcalADCToGeVConstantRcd& );
137  virtual std::auto_ptr<EcalTBWeights> produceEcalTBWeights( const EcalTBWeightsRcd& );
138  virtual std::auto_ptr<EcalIntercalibConstants> getIntercalibConstantsFromConfiguration ( const EcalIntercalibConstantsRcd& ) ;
139  virtual std::auto_ptr<EcalIntercalibConstantsMC> getIntercalibConstantsMCFromConfiguration ( const EcalIntercalibConstantsMCRcd& ) ;
140  virtual std::auto_ptr<EcalIntercalibErrors> getIntercalibErrorsFromConfiguration ( const EcalIntercalibErrorsRcd& ) ;
141  virtual std::auto_ptr<EcalTimeCalibConstants> getTimeCalibConstantsFromConfiguration ( const EcalTimeCalibConstantsRcd& ) ;
142  virtual std::auto_ptr<EcalTimeCalibErrors> getTimeCalibErrorsFromConfiguration ( const EcalTimeCalibErrorsRcd& ) ;
143  virtual std::auto_ptr<EcalTimeOffsetConstant> produceEcalTimeOffsetConstant( const EcalTimeOffsetConstantRcd& );
144 
145 
146  virtual std::auto_ptr<EcalLaserAlphas> produceEcalLaserAlphas( const EcalLaserAlphasRcd& );
147  virtual std::auto_ptr<EcalLaserAPDPNRatiosRef> produceEcalLaserAPDPNRatiosRef( const EcalLaserAPDPNRatiosRefRcd& );
148  virtual std::auto_ptr<EcalLaserAPDPNRatios> produceEcalLaserAPDPNRatios( const EcalLaserAPDPNRatiosRcd& );
149 
150  virtual std::auto_ptr<EcalClusterLocalContCorrParameters> produceEcalClusterLocalContCorrParameters( const EcalClusterLocalContCorrParametersRcd& );
151  virtual std::auto_ptr<EcalClusterCrackCorrParameters> produceEcalClusterCrackCorrParameters( const EcalClusterCrackCorrParametersRcd& );
152  virtual std::auto_ptr<EcalClusterEnergyCorrectionParameters> produceEcalClusterEnergyCorrectionParameters( const EcalClusterEnergyCorrectionParametersRcd& );
153  virtual std::auto_ptr<EcalClusterEnergyUncertaintyParameters> produceEcalClusterEnergyUncertaintyParameters( const EcalClusterEnergyUncertaintyParametersRcd& );
154  virtual std::auto_ptr<EcalClusterEnergyCorrectionObjectSpecificParameters> produceEcalClusterEnergyCorrectionObjectSpecificParameters( const EcalClusterEnergyCorrectionObjectSpecificParametersRcd& );
155 
156  virtual std::auto_ptr<EcalChannelStatus> produceEcalChannelStatus( const EcalChannelStatusRcd& );
157  virtual std::auto_ptr<EcalChannelStatus> getChannelStatusFromConfiguration( const EcalChannelStatusRcd& );
158 
159  virtual std::auto_ptr<EcalTPGCrystalStatus> produceEcalTrgChannelStatus( const EcalTPGCrystalStatusRcd& );
160  virtual std::auto_ptr<EcalTPGCrystalStatus> getTrgChannelStatusFromConfiguration( const EcalTPGCrystalStatusRcd& );
161 
162  virtual std::auto_ptr<EcalDCSTowerStatus> produceEcalDCSTowerStatus( const EcalDCSTowerStatusRcd& );
163  virtual std::auto_ptr<EcalDAQTowerStatus> produceEcalDAQTowerStatus( const EcalDAQTowerStatusRcd& );
164  virtual std::auto_ptr<EcalDQMTowerStatus> produceEcalDQMTowerStatus( const EcalDQMTowerStatusRcd& );
165  virtual std::auto_ptr<EcalDQMChannelStatus> produceEcalDQMChannelStatus( const EcalDQMChannelStatusRcd& );
166 
167  virtual std::auto_ptr<EcalMappingElectronics> produceEcalMappingElectronics( const EcalMappingElectronicsRcd& );
168  virtual std::auto_ptr<EcalMappingElectronics> getMappingFromConfiguration( const EcalMappingElectronicsRcd& );
169 
170  // virtual std::auto_ptr<EcalAlignmentEB> produceEcalAlignmentEB( const EcalAlignmentEBRcd& );
171  // virtual std::auto_ptr<EcalAlignmentEE> produceEcalAlignmentEE( const EcalAlignmentEERcd& );
172  // virtual std::auto_ptr<EcalAlignmentES> produceEcalAlignmentES( const EcalAlignmentESRcd& );
173  virtual std::auto_ptr<Alignments> produceEcalAlignmentEB( const EBAlignmentRcd& );
174  virtual std::auto_ptr<Alignments> produceEcalAlignmentEE( const EEAlignmentRcd& );
175  virtual std::auto_ptr<Alignments> produceEcalAlignmentES( const ESAlignmentRcd& );
176 
177  virtual std::auto_ptr<EcalSampleMask> produceEcalSampleMask( const EcalSampleMaskRcd& );
178 
179  virtual std::auto_ptr<EcalTimeBiasCorrections> produceEcalTimeBiasCorrections( const EcalTimeBiasCorrectionsRcd& );
180 
181  virtual std::auto_ptr<EcalSamplesCorrelation> produceEcalSamplesCorrelation( const EcalSamplesCorrelationRcd& );
182 
183 protected:
184  //overriding from ContextRecordIntervalFinder
186  const edm::IOVSyncValue& ,
188 private:
191 
193 
194  // data members
195  double adcToGeVEBConstant_; // ADC -> GeV scale for barrel
196  double adcToGeVEEConstant_; // ADC -> GeV scale for endcap
197 
198 
199  double intercalibConstantMean_; // mean of intercalib constant. default: 1.0
200  double intercalibConstantSigma_; // sigma of intercalib constant
201 
202  double intercalibConstantMeanMC_; // mean of intercalib constant. default: 1.0
203  double intercalibConstantSigmaMC_; // sigma of intercalib constant
204  // Gaussian used to generate intercalib constants for
205  // each channel. no smearing if sigma=0.0 (default)
206  double intercalibErrorMean_; // mean of intercalib constant error
207 
211 
214 
215  // cluster corrections
216  std::vector<double> localContCorrParameters_;
217  std::vector<double> crackCorrParameters_;
218  std::vector<double> energyCorrectionParameters_;
219  std::vector<double> energyUncertaintyParameters_;
221 
222  // ageing parameters
223  double totLumi_;
224  double instLumi_;
225 
226  // laser
233  unsigned long laserAPDPNTime1_;
234  unsigned long laserAPDPNTime2_;
235  unsigned long laserAPDPNTime3_;
236 
237  double linCorrMean_; // mean of lin corr
238  double linCorrSigma_; // sigma of lin corr
239 
240  unsigned long linearTime1_;
241  unsigned long linearTime2_;
242  unsigned long linearTime3_;
243 
244  double EBpedMeanX12_; // pedestal mean pedestal at gain 12
245  double EBpedRMSX12_; // pedestal rms at gain 12
246  double EBpedMeanX6_; // pedestal mean pedestal at gain 6
247  double EBpedRMSX6_; // pedestal rms at gain 6
248  double EBpedMeanX1_; // pedestal mean pedestal at gain 1
249  double EBpedRMSX1_; // pedestal rms at gain 1
250 
251  double EEpedMeanX12_; // pedestal mean pedestal at gain 12
252  double EEpedRMSX12_; // pedestal rms at gain 12
253  double EEpedMeanX6_; // pedestal mean pedestal at gain 6
254  double EEpedRMSX6_; // pedestal rms at gain 6
255  double EEpedMeanX1_; // pedestal mean pedestal at gain 1
256  double EEpedRMSX1_; // pedestal rms at gain 1
257 
258  double gainRatio12over6_; // ratio of MGPA gain12 / gain6
259  double gainRatio6over1_; // ratio of MGPA gain6 / gain1
260 
261  std::vector< ROOT::Math::SVector<double,EcalDataFrame::MAXSAMPLES> > amplWeights_; // weights to compute amplitudes after ped subtraction
262  std::vector< ROOT::Math::SVector<double,EcalDataFrame::MAXSAMPLES> > amplWeightsAft_; // weights to compute amplitudes after ped subtraction
263 
264  std::vector< ROOT::Math::SVector<double,EcalDataFrame::MAXSAMPLES> > pedWeights_; // weights to compute amplitudes w/o ped subtraction
265  std::vector< ROOT::Math::SVector<double,EcalDataFrame::MAXSAMPLES> > pedWeightsAft_; // weights to compute amplitudes w/o ped subtraction
266 
267  std::vector< ROOT::Math::SVector<double,EcalDataFrame::MAXSAMPLES> > jittWeights_; // weights to compute jitter
268  std::vector< ROOT::Math::SVector<double,EcalDataFrame::MAXSAMPLES> > jittWeightsAft_; // weights to compute jitter
269 
270  std::vector< EcalWeightSet::EcalChi2WeightMatrix > chi2Matrix_;
271  std::vector< EcalWeightSet::EcalChi2WeightMatrix > chi2MatrixAft_;
272 
295  unsigned int sampleMaskEB_; // Mask to discard sample in barrel
296  unsigned int sampleMaskEE_; // Mask to discard sample in endcaps
297  std::vector<double> EBtimeCorrAmplitudeBins_;
298  std::vector<double> EBtimeCorrShiftBins_;
299  std::vector<double> EEtimeCorrAmplitudeBins_;
300  std::vector<double> EEtimeCorrShiftBins_;
301 
302  std::vector<double> EBG12samplesCorrelation_;
303  std::vector<double> EBG6samplesCorrelation_;
304  std::vector<double> EBG1samplesCorrelation_;
305  std::vector<double> EEG12samplesCorrelation_;
306  std::vector<double> EEG6samplesCorrelation_;
307  std::vector<double> EEG1samplesCorrelation_;
309 
311 
349 
350  int verbose_; // verbosity
351 
352 };
353 #endif
virtual std::auto_ptr< EcalTimeCalibConstants > produceEcalTimeCalibConstants(const EcalTimeCalibConstantsRcd &)
virtual std::auto_ptr< EcalChannelStatus > produceEcalChannelStatus(const EcalChannelStatusRcd &)
virtual std::auto_ptr< EcalIntercalibConstants > getIntercalibConstantsFromConfiguration(const EcalIntercalibConstantsRcd &)
virtual void setIntervalFor(const edm::eventsetup::EventSetupRecordKey &, const edm::IOVSyncValue &, edm::ValidityInterval &)
std::vector< ROOT::Math::SVector< double, EcalDataFrame::MAXSAMPLES > > jittWeightsAft_
virtual std::auto_ptr< EcalClusterCrackCorrParameters > produceEcalClusterCrackCorrParameters(const EcalClusterCrackCorrParametersRcd &)
virtual std::auto_ptr< EcalTPGCrystalStatus > produceEcalTrgChannelStatus(const EcalTPGCrystalStatusRcd &)
virtual std::auto_ptr< EcalIntercalibConstantsMC > getIntercalibConstantsMCFromConfiguration(const EcalIntercalibConstantsMCRcd &)
std::vector< double > energyCorrectionObjectSpecificParameters_
virtual std::auto_ptr< EcalChannelStatus > getChannelStatusFromConfiguration(const EcalChannelStatusRcd &)
virtual std::auto_ptr< EcalTBWeights > produceEcalTBWeights(const EcalTBWeightsRcd &)
virtual std::auto_ptr< EcalMappingElectronics > produceEcalMappingElectronics(const EcalMappingElectronicsRcd &)
virtual std::auto_ptr< EcalTimeBiasCorrections > produceEcalTimeBiasCorrections(const EcalTimeBiasCorrectionsRcd &)
std::vector< ROOT::Math::SVector< double, EcalDataFrame::MAXSAMPLES > > pedWeightsAft_
virtual std::auto_ptr< EcalSamplesCorrelation > produceEcalSamplesCorrelation(const EcalSamplesCorrelationRcd &)
void getWeightsFromConfiguration(const edm::ParameterSet &ps)
const EcalTrivialConditionRetriever & operator=(const EcalTrivialConditionRetriever &)
virtual std::auto_ptr< EcalPedestals > produceEcalPedestals(const EcalPedestalsRcd &)
virtual std::auto_ptr< EcalLaserAPDPNRatios > produceEcalLaserAPDPNRatios(const EcalLaserAPDPNRatiosRcd &)
virtual std::auto_ptr< EcalLaserAlphas > produceEcalLaserAlphas(const EcalLaserAlphasRcd &)
virtual std::auto_ptr< EcalTimeCalibConstants > getTimeCalibConstantsFromConfiguration(const EcalTimeCalibConstantsRcd &)
virtual std::auto_ptr< EcalDAQTowerStatus > produceEcalDAQTowerStatus(const EcalDAQTowerStatusRcd &)
virtual std::auto_ptr< Alignments > produceEcalAlignmentEE(const EEAlignmentRcd &)
virtual std::auto_ptr< EcalADCToGeVConstant > produceEcalADCToGeVConstant(const EcalADCToGeVConstantRcd &)
virtual std::auto_ptr< EcalClusterLocalContCorrParameters > produceEcalClusterLocalContCorrParameters(const EcalClusterLocalContCorrParametersRcd &)
virtual std::auto_ptr< EcalWeightXtalGroups > produceEcalWeightXtalGroups(const EcalWeightXtalGroupsRcd &)
virtual std::auto_ptr< EcalIntercalibErrors > getIntercalibErrorsFromConfiguration(const EcalIntercalibErrorsRcd &)
virtual std::auto_ptr< Alignments > produceEcalAlignmentEB(const EBAlignmentRcd &)
virtual std::auto_ptr< EcalDQMTowerStatus > produceEcalDQMTowerStatus(const EcalDQMTowerStatusRcd &)
std::vector< ROOT::Math::SVector< double, EcalDataFrame::MAXSAMPLES > > pedWeights_
virtual std::auto_ptr< EcalClusterEnergyUncertaintyParameters > produceEcalClusterEnergyUncertaintyParameters(const EcalClusterEnergyUncertaintyParametersRcd &)
virtual std::auto_ptr< EcalMappingElectronics > getMappingFromConfiguration(const EcalMappingElectronicsRcd &)
virtual std::auto_ptr< EcalIntercalibErrors > produceEcalIntercalibErrors(const EcalIntercalibErrorsRcd &)
virtual std::auto_ptr< EcalTimeCalibErrors > produceEcalTimeCalibErrors(const EcalTimeCalibErrorsRcd &)
virtual std::auto_ptr< EcalTPGCrystalStatus > getTrgChannelStatusFromConfiguration(const EcalTPGCrystalStatusRcd &)
virtual std::auto_ptr< EcalClusterEnergyCorrectionParameters > produceEcalClusterEnergyCorrectionParameters(const EcalClusterEnergyCorrectionParametersRcd &)
virtual std::auto_ptr< EcalSampleMask > produceEcalSampleMask(const EcalSampleMaskRcd &)
std::vector< ROOT::Math::SVector< double, EcalDataFrame::MAXSAMPLES > > amplWeights_
virtual std::auto_ptr< EcalDCSTowerStatus > produceEcalDCSTowerStatus(const EcalDCSTowerStatusRcd &)
std::vector< EcalWeightSet::EcalChi2WeightMatrix > chi2MatrixAft_
virtual std::auto_ptr< EcalIntercalibConstants > produceEcalIntercalibConstants(const EcalIntercalibConstantsRcd &)
virtual std::auto_ptr< EcalIntercalibConstantsMC > produceEcalIntercalibConstantsMC(const EcalIntercalibConstantsMCRcd &)
EcalTrivialConditionRetriever(const edm::ParameterSet &pset)
virtual std::auto_ptr< EcalLaserAPDPNRatiosRef > produceEcalLaserAPDPNRatiosRef(const EcalLaserAPDPNRatiosRefRcd &)
std::vector< ROOT::Math::SVector< double, EcalDataFrame::MAXSAMPLES > > amplWeightsAft_
virtual std::auto_ptr< Alignments > produceEcalAlignmentES(const ESAlignmentRcd &)
virtual std::auto_ptr< EcalTimeCalibErrors > getTimeCalibErrorsFromConfiguration(const EcalTimeCalibErrorsRcd &)
virtual std::auto_ptr< EcalTimeOffsetConstant > produceEcalTimeOffsetConstant(const EcalTimeOffsetConstantRcd &)
virtual std::auto_ptr< EcalClusterEnergyCorrectionObjectSpecificParameters > produceEcalClusterEnergyCorrectionObjectSpecificParameters(const EcalClusterEnergyCorrectionObjectSpecificParametersRcd &)
virtual std::auto_ptr< EcalLinearCorrections > produceEcalLinearCorrections(const EcalLinearCorrectionsRcd &)
virtual std::auto_ptr< EcalDQMChannelStatus > produceEcalDQMChannelStatus(const EcalDQMChannelStatusRcd &)
virtual std::auto_ptr< EcalGainRatios > produceEcalGainRatios(const EcalGainRatiosRcd &)
std::vector< EcalWeightSet::EcalChi2WeightMatrix > chi2Matrix_
std::vector< ROOT::Math::SVector< double, EcalDataFrame::MAXSAMPLES > > jittWeights_