#include <emcRawDataCalibratorV1.h>
Inherits emcCalibrator.
Inheritance diagram for emcRawDataCalibratorV1:
? FIXME ?
This class should probably be re-written some days. It has lots of hard-wiring, some parts are quite not easy to maintain... etc... The whole calibration design should probably be rethought.
First thing is to remove dependency on emcFEMtuple hierarchy which is to disappear. That should be no big problem.
L.A.
Definition at line 50 of file emcRawDataCalibratorV1.h.
Public Member Functions | |
emcRawDataCalibratorV1 () | |
ctor | |
virtual | ~emcRawDataCalibratorV1 () |
dtor | |
virtual bool | Calibrate (const emcRawDataObject &rdo, emcMixedDataObject &mdo, const PHTimeStamp &when) |
Changes raw data into mixed data. | |
virtual bool | Calibrate (const emcMixedDataObject &mdo, emcCalibratedDataObject &cdo, const PHTimeStamp &when) |
Changes mixed data into calibrated data. | |
virtual bool | Calibrate (const emcRawDataObject &rdo, emcCalibratedDataObject &cdo, const PHTimeStamp &when) |
short cut to go from raw to calibrated | |
void | ForceDBCollection (const PHTimeStamp &when) |
virtual void | SetCollectionStatus (const char *type) |
Set status of collecting data if they were collected outside of calibrator For the moment type can be "Pedestals", "HLRatios", "Tofs", "Gains" or "*" (i.e. | |
virtual bool | GetCollectionStatus (const char *type) const |
Get status of last try of collecting data. | |
virtual void | Print () const |
the print utility to inform what the calibrator is doing | |
virtual void | printData (const emcRawDataObject &rdo, const int towerId) const |
the print utility to print data for individual tower | |
virtual void | Reset (void) |
Complete reset. | |
virtual bool | SelectSource (const char *type, emcManageable::EStorage source) |
select the source of the calibration parameters. | |
virtual void | SetExtraRejectListFilename (const char *filename="") |
Set the filename of a file containing a list of extra towers to be rejected, as compared to those in Q&A objects. | |
virtual void | SetSMBasedCorrectionFilename (const char *filename="") |
Set the filename of a file containing a list of corrections to be applied to calibration coefficients in individual supermodules. | |
virtual void | SetTwrGlobalT0 (char *filename=0) |
Set Global T0 for every calorimeter Tower. | |
bool | CalibrateEnergy (Float_t &adc, const Int_t index, const Int_t TowerId, int incrementalTime) |
bool | CalibrateTime (Float_t &tdc, float adc, const Int_t index, const Int_t TowerId, int incrementalTime) |
void | CollectForMDO (const PHTimeStamp &when) |
void | CollectForCDO (const PHTimeStamp &when) |
bool | GetECalAtT0 (const PHTimeStamp &when, bool normalizationON=false) |
Private Attributes | |
std::string | fExtraRejectListFilename |
std::string | fSMBasedCorrectionFilename |
emcQAs * | fQA |
Q&A object. | |
std::vector< float > | fECalAtT0 |
energy calibration at time 0 | |
emcManageable::EStorage | fPedestalsSource |
tells where to load pedestals data from | |
emcManageable::EStorage | fHLRatiosSource |
tells where to load high/low gain ratios data from | |
emcManageable::EStorage | fGainsSource |
tells where to load gain data from | |
emcManageable::EStorage | fTofSource |
tells where to load ToF data from | |
emcManageable::EStorage | fQASource |
tells where to load Q&A data from | |
emcManageable::EStorage | fIniCalSource |
tells where to load Initial Calibration data from | |
bool | fCollectPedestalStatus |
Status of the last try of collecting Pedestals. | |
bool | fCollectHLRatioStatus |
Status of the last try of collecting HLRatios. | |
bool | fCollectGainStatus |
Status of the last try of collecting Gains. | |
bool | fCollectTofStatus |
Status of the last try of collecting TOF LC and WALKS. | |
Int_t | maxFailPed |
Maximum Number of failed attempts to collect Monitoring Data of a given kind. | |
Int_t | maxFailHLR |
Int_t | maxFailGain |
Int_t | maxFailTof |
emcPedestals5 * | fPedestals |
emcHLRatios * | fHLRatios |
emcGains * | fGains |
emcLCTofs * | fLCTofs |
emcWalkTofs * | fWalkTofs |
emcTofT0s * | fTofT0s |
emcTacPeds * | fTacPeds |
bool | fMustCollectForMDO |
bool | fMustCollectForCDO |
pbscTimingFixes * | tf |
|
ctor
Definition at line 60 of file emcRawDataCalibratorV1.C. References emcCalibrator::fName, and Reset(). |
|
dtor
Definition at line 67 of file emcRawDataCalibratorV1.C. |
|
short cut to go from raw to calibrated This method only call the 2 other Calibrate methods. It makes the calling program simpler, but has an efficiency pay-off, due to the re-allocation of a new mdo at each call. Implements emcCalibrator. Definition at line 329 of file emcRawDataCalibratorV1.C. References Calibrate(). |
|
Changes mixed data into calibrated data.
Implements emcCalibrator. Definition at line 248 of file emcRawDataCalibratorV1.C. References fECalAtT0, and GetECalAtT0(). |
|
Changes raw data into mixed data.
Implements emcCalibrator. Definition at line 72 of file emcRawDataCalibratorV1.C. References emcDataObject::AddDataError(), CollectForMDO(), fCollectHLRatioStatus, fCollectPedestalStatus, fMustCollectForMDO, fQA, emcDataObject::GetDataDescriptionPointers(), emcDataObject::GetDead(), emcQAs::GetDeadMap(), emcDataObject::GetMaxSize(), emcDataObject::GetSize(), emcQAs::GetWarnMap(), emcQAs::IamDeadMask(), scale(), emcDataObject::SetDataDescriptionPointers(), emcMixedDataObject::SetHLRatioFlag(), emcMixedDataObject::SetMaxSize(), emcMixedDataObject::SetPedestalFlag(), and emcMixedDataObject::SetToZero(). Referenced by Calibrate(). |
|
Definition at line 345 of file emcRawDataCalibratorV1.C. References fCollectGainStatus, fECalAtT0, fGains, emcFEMtuple::getValue(), EmcIndexer::isPbGl(), and EmcIndexer::isPbSc(). |
|
Definition at line 368 of file emcRawDataCalibratorV1.C. References fCollectTofStatus, fLCTofs, fTacPeds, fWalkTofs, emcCalibrator::GetGlobalT0(), emcFEMtuple::getValue(), emcWalkTofs::GetValue1(), emcLCTofs::GetValue1(), emcWalkTofs::GetValue2(), EmcIndexer::iPXiSiSMiSMT(), and tf. |
|
Definition at line 438 of file emcRawDataCalibratorV1.C. References emcDataManager::Collect(), fCollectGainStatus, fCollectTofStatus, fGains, fGainsSource, fLCTofs, fTacPeds, fTofSource, emcCalibrator::fVerbose, fWalkTofs, emcDataManager::GetInstance(), emcManageable::kNone, maxFailGain, maxFailTof, and emcManageable::SetSource(). Referenced by ForceDBCollection(). |
|
Definition at line 507 of file emcRawDataCalibratorV1.C. References emcDataManager::Collect(), fCollectHLRatioStatus, fCollectPedestalStatus, fExtraRejectListFilename, fHLRatios, fHLRatiosSource, fPedestals, fPedestalsSource, fQA, fQASource, emcCalibrator::fVerbose, emcDataManager::GetInstance(), emcManageable::kNone, maxFailHLR, maxFailPed, emcQAs::SetExtraRejectListFilename(), and emcManageable::SetSource(). Referenced by Calibrate(), and ForceDBCollection(). |
|
Reimplemented from emcCalibrator. Definition at line 570 of file emcRawDataCalibratorV1.C. References CollectForCDO(), CollectForMDO(), fMustCollectForCDO, fMustCollectForMDO, and GetECalAtT0(). |
|
Get status of last try of collecting data. For the moment type can be "Pedestals", "HLRatios", "Tofs", or "*" (i.e. all) Reimplemented from emcCalibrator. Definition at line 681 of file emcRawDataCalibratorV1.C. References fCollectGainStatus, fCollectHLRatioStatus, fCollectPedestalStatus, and fCollectTofStatus. |
|
Definition at line 581 of file emcRawDataCalibratorV1.C. References fECalAtT0. Referenced by Calibrate(), and ForceDBCollection(). |
|
the print utility to inform what the calibrator is doing
Implements emcCalibrator. Definition at line 733 of file emcRawDataCalibratorV1.C. References fGainsSource, fHLRatiosSource, fIniCalSource, fPedestalsSource, fQASource, fTofSource, emcCalibrator::fZeroSuppression, emcCalibrator::GetHighLowLimit(), emcCalibrator::GetThresholdADC(), emcManageable::kDB_Objy, and emcManageable::kFile_ASCII. |
|
the print utility to print data for individual tower
Implements emcCalibrator. Definition at line 91 of file emcRawDataCalibratorV1.h. |
|
Complete reset.
Implements emcCalibrator. Definition at line 811 of file emcRawDataCalibratorV1.C. References fCollectGainStatus, fCollectHLRatioStatus, fCollectPedestalStatus, fCollectTofStatus, fECalAtT0, fGains, fGainsSource, fHLRatios, fHLRatiosSource, fIniCalSource, fLCTofs, fMustCollectForCDO, fMustCollectForMDO, fPedestals, fPedestalsSource, fQA, fQASource, fTofSource, fTofT0s, fWalkTofs, emcCalibrator::fZeroSuppression, emcManageable::kNone, maxFailGain, maxFailHLR, maxFailPed, maxFailTof, SetExtraRejectListFilename(), and tf. Referenced by emcRawDataCalibratorV1(). |
|
select the source of the calibration parameters. Valid types are: Pedestals, HLRatios, ToF, QAs, IniCal Valid sources are: kDB_Objy = Objectivity Data base, kFile_ASCII = ASCII Files. Implements emcCalibrator. Definition at line 838 of file emcRawDataCalibratorV1.C. References emcRawDataAccessor::GetDynamicData(), emcRawDataAccessor::GetInstance(), EmcDynamicData::getMapStyle(), and emcManageable::kNone. |
|
Set status of collecting data if they were collected outside of calibrator For the moment type can be "Pedestals", "HLRatios", "Tofs", "Gains" or "*" (i.e. all) Definition at line 708 of file emcRawDataCalibratorV1.C. References fCollectGainStatus, fCollectHLRatioStatus, fCollectPedestalStatus, and fCollectTofStatus. |
|
Set the filename of a file containing a list of extra towers to be rejected, as compared to those in Q&A objects.
Reimplemented from emcCalibrator. Definition at line 105 of file emcRawDataCalibratorV1.h. References fExtraRejectListFilename. Referenced by Reset(). |
|
Set the filename of a file containing a list of corrections to be applied to calibration coefficients in individual supermodules.
Reimplemented from emcCalibrator. Definition at line 108 of file emcRawDataCalibratorV1.h. References fSMBasedCorrectionFilename. |
|
Set Global T0 for every calorimeter Tower.
Reimplemented from emcCalibrator. Definition at line 905 of file emcRawDataCalibratorV1.C. References emcCalibrator::fTwrGlobalT0, emcRawDataAccessor::GetInstance(), emcDataObject::GetMaxSize(), and emcRawDataAccessor::GetRawDataObject(). |
|
Status of the last try of collecting Gains.
Definition at line 152 of file emcRawDataCalibratorV1.h. Referenced by CalibrateEnergy(), CollectForCDO(), GetCollectionStatus(), Reset(), and SetCollectionStatus(). |
|
Status of the last try of collecting HLRatios.
Definition at line 150 of file emcRawDataCalibratorV1.h. Referenced by Calibrate(), CollectForMDO(), GetCollectionStatus(), Reset(), and SetCollectionStatus(). |
|
Status of the last try of collecting Pedestals.
Definition at line 148 of file emcRawDataCalibratorV1.h. Referenced by Calibrate(), CollectForMDO(), GetCollectionStatus(), Reset(), and SetCollectionStatus(). |
|
Status of the last try of collecting TOF LC and WALKS.
Definition at line 154 of file emcRawDataCalibratorV1.h. Referenced by CalibrateTime(), CollectForCDO(), GetCollectionStatus(), Reset(), and SetCollectionStatus(). |
|
energy calibration at time 0
Definition at line 133 of file emcRawDataCalibratorV1.h. Referenced by Calibrate(), CalibrateEnergy(), GetECalAtT0(), and Reset(). |
|
Definition at line 127 of file emcRawDataCalibratorV1.h. Referenced by CollectForMDO(), and SetExtraRejectListFilename(). |
|
Definition at line 160 of file emcRawDataCalibratorV1.h. Referenced by CalibrateEnergy(), CollectForCDO(), and Reset(). |
|
tells where to load gain data from
Definition at line 139 of file emcRawDataCalibratorV1.h. Referenced by CollectForCDO(), Print(), and Reset(). |
|
Definition at line 159 of file emcRawDataCalibratorV1.h. Referenced by CollectForMDO(), and Reset(). |
|
tells where to load high/low gain ratios data from
Definition at line 137 of file emcRawDataCalibratorV1.h. Referenced by CollectForMDO(), Print(), and Reset(). |
|
tells where to load Initial Calibration data from
Definition at line 145 of file emcRawDataCalibratorV1.h. |
|
Definition at line 161 of file emcRawDataCalibratorV1.h. Referenced by CalibrateTime(), CollectForCDO(), and Reset(). |
|
Definition at line 167 of file emcRawDataCalibratorV1.h. Referenced by ForceDBCollection(), and Reset(). |
|
Definition at line 166 of file emcRawDataCalibratorV1.h. Referenced by Calibrate(), ForceDBCollection(), and Reset(). |
|
Definition at line 158 of file emcRawDataCalibratorV1.h. Referenced by CollectForMDO(), and Reset(). |
|
tells where to load pedestals data from
Definition at line 135 of file emcRawDataCalibratorV1.h. Referenced by CollectForMDO(), Print(), and Reset(). |
|
Q&A object.
Definition at line 131 of file emcRawDataCalibratorV1.h. Referenced by Calibrate(), CollectForMDO(), and Reset(). |
|
tells where to load Q&A data from
Definition at line 143 of file emcRawDataCalibratorV1.h. Referenced by CollectForMDO(), Print(), and Reset(). |
|
Definition at line 128 of file emcRawDataCalibratorV1.h. Referenced by SetSMBasedCorrectionFilename(). |
|
Definition at line 164 of file emcRawDataCalibratorV1.h. Referenced by CalibrateTime(), and CollectForCDO(). |
|
tells where to load ToF data from
Definition at line 141 of file emcRawDataCalibratorV1.h. Referenced by CollectForCDO(), Print(), and Reset(). |
|
Definition at line 163 of file emcRawDataCalibratorV1.h. Referenced by Reset(). |
|
Definition at line 162 of file emcRawDataCalibratorV1.h. Referenced by CalibrateTime(), CollectForCDO(), and Reset(). |
|
Definition at line 156 of file emcRawDataCalibratorV1.h. Referenced by CollectForCDO(), and Reset(). |
|
Definition at line 156 of file emcRawDataCalibratorV1.h. Referenced by CollectForMDO(), and Reset(). |
|
Maximum Number of failed attempts to collect Monitoring Data of a given kind.
Definition at line 156 of file emcRawDataCalibratorV1.h. Referenced by CollectForMDO(), and Reset(). |
|
Definition at line 156 of file emcRawDataCalibratorV1.h. Referenced by CollectForCDO(), and Reset(). |
|
Definition at line 168 of file emcRawDataCalibratorV1.h. Referenced by CalibrateTime(), and Reset(). |