CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups 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 
40 
43 
46 
49 
52 
56 
59 
62 
65 
68 
71 
76 
93 
95 
100 
103 
106 
109 
112 
115 
117 // forward declarations
118 
119 namespace edm {
120  class ParameterSet;
121 }
122 
124 public:
126  EcalTrivialConditionRetriever(const EcalTrivialConditionRetriever&) = delete; // stop default
127  const EcalTrivialConditionRetriever& operator=(const EcalTrivialConditionRetriever&) = delete; // stop default
129 
130  // ---------- member functions ---------------------------
131  virtual std::unique_ptr<EcalPedestals> produceEcalPedestals(const EcalPedestalsRcd&);
132  virtual std::unique_ptr<EcalWeightXtalGroups> produceEcalWeightXtalGroups(const EcalWeightXtalGroupsRcd&);
133  virtual std::unique_ptr<EcalLinearCorrections> produceEcalLinearCorrections(const EcalLinearCorrectionsRcd&);
134  virtual std::unique_ptr<EcalIntercalibConstants> produceEcalIntercalibConstants(const EcalIntercalibConstantsRcd&);
135  virtual std::unique_ptr<EcalIntercalibConstantsMC> produceEcalIntercalibConstantsMC(
137  virtual std::unique_ptr<EcalIntercalibErrors> produceEcalIntercalibErrors(const EcalIntercalibErrorsRcd&);
138  virtual std::unique_ptr<EcalTimeCalibConstants> produceEcalTimeCalibConstants(const EcalTimeCalibConstantsRcd&);
139  virtual std::unique_ptr<EcalTimeCalibErrors> produceEcalTimeCalibErrors(const EcalTimeCalibErrorsRcd&);
140  virtual std::unique_ptr<EcalGainRatios> produceEcalGainRatios(const EcalGainRatiosRcd&);
141  virtual std::unique_ptr<EcalADCToGeVConstant> produceEcalADCToGeVConstant(const EcalADCToGeVConstantRcd&);
142  virtual std::unique_ptr<EcalTBWeights> produceEcalTBWeights(const EcalTBWeightsRcd&);
143  virtual std::unique_ptr<EcalIntercalibConstants> getIntercalibConstantsFromConfiguration(
145  virtual std::unique_ptr<EcalIntercalibConstantsMC> getIntercalibConstantsMCFromConfiguration(
147  virtual std::unique_ptr<EcalSimPulseShape> getEcalSimPulseShapeFromConfiguration(const EcalSimPulseShapeRcd&);
148  virtual std::unique_ptr<EcalIntercalibErrors> getIntercalibErrorsFromConfiguration(const EcalIntercalibErrorsRcd&);
149  virtual std::unique_ptr<EcalTimeCalibConstants> getTimeCalibConstantsFromConfiguration(
151  virtual std::unique_ptr<EcalTimeCalibErrors> getTimeCalibErrorsFromConfiguration(const EcalTimeCalibErrorsRcd&);
152  virtual std::unique_ptr<EcalTimeOffsetConstant> produceEcalTimeOffsetConstant(const EcalTimeOffsetConstantRcd&);
153 
154  virtual std::unique_ptr<EcalLaserAlphas> produceEcalLaserAlphas(const EcalLaserAlphasRcd&);
155  virtual std::unique_ptr<EcalLaserAPDPNRatiosRef> produceEcalLaserAPDPNRatiosRef(const EcalLaserAPDPNRatiosRefRcd&);
156  virtual std::unique_ptr<EcalLaserAPDPNRatios> produceEcalLaserAPDPNRatios(const EcalLaserAPDPNRatiosRcd&);
157 
158  virtual std::unique_ptr<EcalClusterLocalContCorrParameters> produceEcalClusterLocalContCorrParameters(
160  virtual std::unique_ptr<EcalClusterCrackCorrParameters> produceEcalClusterCrackCorrParameters(
162  virtual std::unique_ptr<EcalClusterEnergyCorrectionParameters> produceEcalClusterEnergyCorrectionParameters(
164  virtual std::unique_ptr<EcalClusterEnergyUncertaintyParameters> produceEcalClusterEnergyUncertaintyParameters(
166  virtual std::unique_ptr<EcalClusterEnergyCorrectionObjectSpecificParameters>
169  virtual std::unique_ptr<EcalPFRecHitThresholds> produceEcalPFRecHitThresholds(const EcalPFRecHitThresholdsRcd&);
170  virtual std::unique_ptr<EcalPFRecHitThresholds> getPFRecHitThresholdsFromConfiguration(
172 
173  virtual std::unique_ptr<EcalChannelStatus> produceEcalChannelStatus(const EcalChannelStatusRcd&);
174  virtual std::unique_ptr<EcalChannelStatus> getChannelStatusFromConfiguration(const EcalChannelStatusRcd&);
175 
176  virtual std::unique_ptr<EcalTPGCrystalStatus> produceEcalTrgChannelStatus(const EcalTPGCrystalStatusRcd&);
177  virtual std::unique_ptr<EcalTPGCrystalStatus> getTrgChannelStatusFromConfiguration(const EcalTPGCrystalStatusRcd&);
178 
179  virtual std::unique_ptr<EcalDCSTowerStatus> produceEcalDCSTowerStatus(const EcalDCSTowerStatusRcd&);
180  virtual std::unique_ptr<EcalDAQTowerStatus> produceEcalDAQTowerStatus(const EcalDAQTowerStatusRcd&);
181  virtual std::unique_ptr<EcalDQMTowerStatus> produceEcalDQMTowerStatus(const EcalDQMTowerStatusRcd&);
182  virtual std::unique_ptr<EcalDQMChannelStatus> produceEcalDQMChannelStatus(const EcalDQMChannelStatusRcd&);
183 
184  virtual std::unique_ptr<EcalMappingElectronics> produceEcalMappingElectronics(const EcalMappingElectronicsRcd&);
185  virtual std::unique_ptr<EcalMappingElectronics> getMappingFromConfiguration(const EcalMappingElectronicsRcd&);
186 
187  // virtual std::unique_ptr<EcalAlignmentEB> produceEcalAlignmentEB( const EcalAlignmentEBRcd& );
188  // virtual std::unique_ptr<EcalAlignmentEE> produceEcalAlignmentEE( const EcalAlignmentEERcd& );
189  // virtual std::unique_ptr<EcalAlignmentES> produceEcalAlignmentES( const EcalAlignmentESRcd& );
190  virtual std::unique_ptr<Alignments> produceEcalAlignmentEB(const EBAlignmentRcd&);
191  virtual std::unique_ptr<Alignments> produceEcalAlignmentEE(const EEAlignmentRcd&);
192  virtual std::unique_ptr<Alignments> produceEcalAlignmentES(const ESAlignmentRcd&);
193 
194  virtual std::unique_ptr<EcalSampleMask> produceEcalSampleMask(const EcalSampleMaskRcd&);
195 
196  virtual std::unique_ptr<EcalTimeBiasCorrections> produceEcalTimeBiasCorrections(const EcalTimeBiasCorrectionsRcd&);
197 
198  virtual std::unique_ptr<EcalSamplesCorrelation> produceEcalSamplesCorrelation(const EcalSamplesCorrelationRcd&);
199 
200 protected:
201  //overriding from ContextRecordIntervalFinder
203  const edm::IOVSyncValue&,
204  edm::ValidityInterval&) override;
205 
206 private:
208 
209  // data members
210  double adcToGeVEBConstant_; // ADC -> GeV scale for barrel
211  double adcToGeVEEConstant_; // ADC -> GeV scale for endcap
212 
213  double intercalibConstantMean_; // mean of intercalib constant. default: 1.0
214  double intercalibConstantSigma_; // sigma of intercalib constant
215 
216  double intercalibConstantMeanMC_; // mean of intercalib constant. default: 1.0
217  double intercalibConstantSigmaMC_; // sigma of intercalib constant
218  // Gaussian used to generate intercalib constants for
219  // each channel. no smearing if sigma=0.0 (default)
220  double intercalibErrorMean_; // mean of intercalib constant error
221 
225 
228 
229  // cluster corrections
230  std::vector<double> localContCorrParameters_;
231  std::vector<double> crackCorrParameters_;
232  std::vector<double> energyCorrectionParameters_;
233  std::vector<double> energyUncertaintyParameters_;
239 
244 
247 
250 
252 
253  // ageing parameters
254  double totLumi_;
255  double instLumi_;
256 
257  // laser
264 
269  unsigned long laserAPDPNTime1_;
270  unsigned long laserAPDPNTime2_;
271  unsigned long laserAPDPNTime3_;
272 
273  double linCorrMean_; // mean of lin corr
274  double linCorrSigma_; // sigma of lin corr
275 
276  unsigned long linearTime1_;
277  unsigned long linearTime2_;
278  unsigned long linearTime3_;
279 
280  double EBpedMeanX12_; // pedestal mean pedestal at gain 12
281  double EBpedRMSX12_; // pedestal rms at gain 12
282  double EBpedMeanX6_; // pedestal mean pedestal at gain 6
283  double EBpedRMSX6_; // pedestal rms at gain 6
284  double EBpedMeanX1_; // pedestal mean pedestal at gain 1
285  double EBpedRMSX1_; // pedestal rms at gain 1
286 
287  double EEpedMeanX12_; // pedestal mean pedestal at gain 12
288  double EEpedRMSX12_; // pedestal rms at gain 12
289  double EEpedMeanX6_; // pedestal mean pedestal at gain 6
290  double EEpedRMSX6_; // pedestal rms at gain 6
291  double EEpedMeanX1_; // pedestal mean pedestal at gain 1
292  double EEpedRMSX1_; // pedestal rms at gain 1
293 
294  double gainRatio12over6_; // ratio of MGPA gain12 / gain6
295  double gainRatio6over1_; // ratio of MGPA gain6 / gain1
296 
297  std::vector<ROOT::Math::SVector<double, EcalDataFrame::MAXSAMPLES> >
298  amplWeights_; // weights to compute amplitudes after ped subtraction
299  std::vector<ROOT::Math::SVector<double, EcalDataFrame::MAXSAMPLES> >
300  amplWeightsAft_; // weights to compute amplitudes after ped subtraction
301 
302  std::vector<ROOT::Math::SVector<double, EcalDataFrame::MAXSAMPLES> >
303  pedWeights_; // weights to compute amplitudes w/o ped subtraction
304  std::vector<ROOT::Math::SVector<double, EcalDataFrame::MAXSAMPLES> >
305  pedWeightsAft_; // weights to compute amplitudes w/o ped subtraction
306 
307  std::vector<ROOT::Math::SVector<double, EcalDataFrame::MAXSAMPLES> > jittWeights_; // weights to compute jitter
308  std::vector<ROOT::Math::SVector<double, EcalDataFrame::MAXSAMPLES> > jittWeightsAft_; // weights to compute jitter
309 
310  std::vector<EcalWeightSet::EcalChi2WeightMatrix> chi2Matrix_;
311  std::vector<EcalWeightSet::EcalChi2WeightMatrix> chi2MatrixAft_;
312 
335  unsigned int sampleMaskEB_; // Mask to discard sample in barrel
336  unsigned int sampleMaskEE_; // Mask to discard sample in endcaps
337  std::vector<double> EBtimeCorrAmplitudeBins_;
338  std::vector<double> EBtimeCorrShiftBins_;
339  std::vector<double> EEtimeCorrAmplitudeBins_;
340  std::vector<double> EEtimeCorrShiftBins_;
341 
342  std::vector<double> EBG12samplesCorrelation_;
343  std::vector<double> EBG6samplesCorrelation_;
344  std::vector<double> EBG1samplesCorrelation_;
345  std::vector<double> EEG12samplesCorrelation_;
346  std::vector<double> EEG6samplesCorrelation_;
347  std::vector<double> EEG1samplesCorrelation_;
352 
354 
389 
391 
400 
401  int verbose_; // verbosity
402 };
403 #endif
void setIntervalFor(const edm::eventsetup::EventSetupRecordKey &, const edm::IOVSyncValue &, edm::ValidityInterval &) override
virtual std::unique_ptr< EcalDQMChannelStatus > produceEcalDQMChannelStatus(const EcalDQMChannelStatusRcd &)
virtual std::unique_ptr< EcalIntercalibConstants > produceEcalIntercalibConstants(const EcalIntercalibConstantsRcd &)
std::vector< ROOT::Math::SVector< double, EcalDataFrame::MAXSAMPLES > > pedWeights_
virtual std::unique_ptr< EcalIntercalibErrors > produceEcalIntercalibErrors(const EcalIntercalibErrorsRcd &)
virtual std::unique_ptr< EcalLaserAPDPNRatiosRef > produceEcalLaserAPDPNRatiosRef(const EcalLaserAPDPNRatiosRefRcd &)
virtual std::unique_ptr< EcalSamplesCorrelation > produceEcalSamplesCorrelation(const EcalSamplesCorrelationRcd &)
std::vector< double > energyCorrectionObjectSpecificParameters_
virtual std::unique_ptr< EcalTimeCalibConstants > produceEcalTimeCalibConstants(const EcalTimeCalibConstantsRcd &)
std::vector< ROOT::Math::SVector< double, EcalDataFrame::MAXSAMPLES > > jittWeights_
virtual std::unique_ptr< EcalMappingElectronics > getMappingFromConfiguration(const EcalMappingElectronicsRcd &)
virtual std::unique_ptr< EcalADCToGeVConstant > produceEcalADCToGeVConstant(const EcalADCToGeVConstantRcd &)
virtual std::unique_ptr< EcalWeightXtalGroups > produceEcalWeightXtalGroups(const EcalWeightXtalGroupsRcd &)
std::vector< ROOT::Math::SVector< double, EcalDataFrame::MAXSAMPLES > > amplWeightsAft_
virtual std::unique_ptr< EcalChannelStatus > produceEcalChannelStatus(const EcalChannelStatusRcd &)
void getWeightsFromConfiguration(const edm::ParameterSet &ps)
virtual std::unique_ptr< EcalLaserAlphas > produceEcalLaserAlphas(const EcalLaserAlphasRcd &)
virtual std::unique_ptr< EcalClusterEnergyUncertaintyParameters > produceEcalClusterEnergyUncertaintyParameters(const EcalClusterEnergyUncertaintyParametersRcd &)
virtual std::unique_ptr< Alignments > produceEcalAlignmentEB(const EBAlignmentRcd &)
const EcalTrivialConditionRetriever & operator=(const EcalTrivialConditionRetriever &)=delete
virtual std::unique_ptr< EcalClusterEnergyCorrectionParameters > produceEcalClusterEnergyCorrectionParameters(const EcalClusterEnergyCorrectionParametersRcd &)
virtual std::unique_ptr< EcalIntercalibConstantsMC > getIntercalibConstantsMCFromConfiguration(const EcalIntercalibConstantsMCRcd &)
virtual std::unique_ptr< EcalDQMTowerStatus > produceEcalDQMTowerStatus(const EcalDQMTowerStatusRcd &)
virtual std::unique_ptr< Alignments > produceEcalAlignmentEE(const EEAlignmentRcd &)
virtual std::unique_ptr< EcalLinearCorrections > produceEcalLinearCorrections(const EcalLinearCorrectionsRcd &)
virtual std::unique_ptr< EcalMappingElectronics > produceEcalMappingElectronics(const EcalMappingElectronicsRcd &)
virtual std::unique_ptr< EcalLaserAPDPNRatios > produceEcalLaserAPDPNRatios(const EcalLaserAPDPNRatiosRcd &)
virtual std::unique_ptr< EcalChannelStatus > getChannelStatusFromConfiguration(const EcalChannelStatusRcd &)
virtual std::unique_ptr< EcalTimeBiasCorrections > produceEcalTimeBiasCorrections(const EcalTimeBiasCorrectionsRcd &)
virtual std::unique_ptr< EcalIntercalibConstants > getIntercalibConstantsFromConfiguration(const EcalIntercalibConstantsRcd &)
virtual std::unique_ptr< EcalIntercalibConstantsMC > produceEcalIntercalibConstantsMC(const EcalIntercalibConstantsMCRcd &)
std::vector< EcalWeightSet::EcalChi2WeightMatrix > chi2Matrix_
virtual std::unique_ptr< Alignments > produceEcalAlignmentES(const ESAlignmentRcd &)
virtual std::unique_ptr< EcalPedestals > produceEcalPedestals(const EcalPedestalsRcd &)
virtual std::unique_ptr< EcalClusterEnergyCorrectionObjectSpecificParameters > produceEcalClusterEnergyCorrectionObjectSpecificParameters(const EcalClusterEnergyCorrectionObjectSpecificParametersRcd &)
virtual std::unique_ptr< EcalDCSTowerStatus > produceEcalDCSTowerStatus(const EcalDCSTowerStatusRcd &)
EcalTrivialConditionRetriever(const edm::ParameterSet &pset)
virtual std::unique_ptr< EcalClusterLocalContCorrParameters > produceEcalClusterLocalContCorrParameters(const EcalClusterLocalContCorrParametersRcd &)
virtual std::unique_ptr< EcalTimeCalibErrors > getTimeCalibErrorsFromConfiguration(const EcalTimeCalibErrorsRcd &)
virtual std::unique_ptr< EcalGainRatios > produceEcalGainRatios(const EcalGainRatiosRcd &)
std::vector< ROOT::Math::SVector< double, EcalDataFrame::MAXSAMPLES > > pedWeightsAft_
virtual std::unique_ptr< EcalTPGCrystalStatus > produceEcalTrgChannelStatus(const EcalTPGCrystalStatusRcd &)
virtual std::unique_ptr< EcalTimeCalibErrors > produceEcalTimeCalibErrors(const EcalTimeCalibErrorsRcd &)
virtual std::unique_ptr< EcalTBWeights > produceEcalTBWeights(const EcalTBWeightsRcd &)
virtual std::unique_ptr< EcalTimeOffsetConstant > produceEcalTimeOffsetConstant(const EcalTimeOffsetConstantRcd &)
virtual std::unique_ptr< EcalPFRecHitThresholds > getPFRecHitThresholdsFromConfiguration(const EcalPFRecHitThresholdsRcd &)
virtual std::unique_ptr< EcalTimeCalibConstants > getTimeCalibConstantsFromConfiguration(const EcalTimeCalibConstantsRcd &)
virtual std::unique_ptr< EcalTPGCrystalStatus > getTrgChannelStatusFromConfiguration(const EcalTPGCrystalStatusRcd &)
virtual std::unique_ptr< EcalPFRecHitThresholds > produceEcalPFRecHitThresholds(const EcalPFRecHitThresholdsRcd &)
std::vector< ROOT::Math::SVector< double, EcalDataFrame::MAXSAMPLES > > jittWeightsAft_
virtual std::unique_ptr< EcalSampleMask > produceEcalSampleMask(const EcalSampleMaskRcd &)
virtual std::unique_ptr< EcalIntercalibErrors > getIntercalibErrorsFromConfiguration(const EcalIntercalibErrorsRcd &)
std::vector< ROOT::Math::SVector< double, EcalDataFrame::MAXSAMPLES > > amplWeights_
std::vector< EcalWeightSet::EcalChi2WeightMatrix > chi2MatrixAft_
virtual std::unique_ptr< EcalDAQTowerStatus > produceEcalDAQTowerStatus(const EcalDAQTowerStatusRcd &)
virtual std::unique_ptr< EcalSimPulseShape > getEcalSimPulseShapeFromConfiguration(const EcalSimPulseShapeRcd &)
virtual std::unique_ptr< EcalClusterCrackCorrParameters > produceEcalClusterCrackCorrParameters(const EcalClusterCrackCorrParametersRcd &)