source: trunk/MagicSoft/Mars/mcalib/MCalibCalcFromPast.h@ 7256

Last change on this file since 7256 was 7189, checked in by tbretz, 20 years ago
*** empty log message ***
File size: 3.7 KB
Line 
1#ifndef MARS_MCalibCalcFromPast
2#define MARS_MCalibCalcFromPast
3
4#ifndef MARS_MTask
5#include "MTask.h"
6#endif
7
8#ifndef ROOT_TArrayF
9#include <TArrayF.h>
10#endif
11
12class MParList;
13class MGeomCam;
14class MRawRunHeader;
15class MPedCalcFromLoGain;
16class MCalibrationChargeCalc;
17class MCalibrationRelTimeCalc;
18class MCalibrateData;
19class MCalibrationIntensityChargeCam;
20class MCalibrationIntensityBlindCam;
21class MCalibrationIntensityQECam;
22class MCalibrationIntensityRelTimeCam;
23class MCalibrationIntensityConstCam;
24class MBadPixelsIntensityCam;
25
26class MCalibCalcFromPast : public MTask
27{
28private:
29 static const UInt_t fgNumEventsDump; //! Default for fNumEventsDump
30 static const UInt_t fgNumPhesDump; //! Default for fNumPhesDump
31
32 MGeomCam *fGeom; //! Camera Geometry
33 MParList *fParList; //! Parameter List
34 MRawRunHeader *fRunHeader; //! Run header storing the run number
35 MCalibrationIntensityChargeCam *fIntensCharge; //! Intensity Charge Cam (to be created)
36 MCalibrationIntensityBlindCam *fIntensBlind; //! Intensity Blind Cam (to be created)
37 MCalibrationIntensityQECam *fIntensQE; //! Intensity QE Cam (to be created)
38 MCalibrationIntensityRelTimeCam *fIntensRelTime; //! Intensity Rel. Time Cam (to be created)
39 MCalibrationIntensityConstCam *fIntensConst; //! Intensity Rel. Time Cam (to be created)
40 MBadPixelsIntensityCam *fIntensBad; //! Intensity Bad Pixels Cam (to be created)
41
42 MCalibrationChargeCalc *fChargeCalc; //! Charge Calibration Task
43 MCalibrationRelTimeCalc *fRelTimeCalc; //! Rel. Times Calibratio Task
44 MCalibrateData *fCalibrate; //! Data Calibration Task
45
46 UInt_t fNumCam; //! Number of currently used Calibration Cam
47 UInt_t fNumEventsDump; // Number of event after which the MCalibrationCams gets updated
48 UInt_t fNumEvents; //! Event counter only for calibration events
49 UInt_t fNumPhesDump; // Number of cams after which the number of phes gets averaged
50 UInt_t fNumPhes; //! Event counter for photo-electron updates
51
52 Float_t fMeanPhes;
53 Float_t fMeanPhesRelVar;
54
55 Bool_t fUpdateWithFFactorMethod; // Update the interlaced calib events with the full F-Factor method
56 Bool_t fUpdateNumPhes; // Update the number of photo-electrons only after fNumPhesDump number of Cams
57
58 TArrayF fPhes;
59 TArrayF fPhesVar;
60
61 // MTask
62 Int_t PreProcess(MParList *pList);
63 Int_t Process();
64 Int_t PostProcess();
65
66 // MCalibCalcFromPast
67 Bool_t ReInitialize();
68 Bool_t Finalize(const char* name);
69
70 Bool_t UpdateMeanPhes();
71
72 // MParContainer
73 Int_t ReadEnv(const TEnv &env, TString prefix, Bool_t print);
74
75public:
76 MCalibCalcFromPast(const char *name=NULL, const char *title=NULL);
77
78 // Getter
79 UInt_t GetNumEventsDump() const { return fNumEventsDump; }
80
81 // Setter
82 void SetNumEventsDump( const UInt_t i=fgNumEventsDump ) { fNumEventsDump = i; }
83 void SetNumPhesDump ( const UInt_t i=fgNumPhesDump ) { fNumPhesDump = i; }
84
85 void SetCalibrate ( MCalibrateData *c ) { fCalibrate = c; }
86 void SetChargeCalc ( MCalibrationChargeCalc *c ) { fChargeCalc = c; }
87 void SetRelTimeCalc ( MCalibrationRelTimeCalc *c ) { fRelTimeCalc = c; }
88 void SetUpdateNumPhes ( const Bool_t b=kTRUE ) { fUpdateNumPhes = b; }
89
90 void SetUpdateWithFFactorMethod(const Bool_t b=kTRUE){ fUpdateWithFFactorMethod = b; }
91
92 ClassDef(MCalibCalcFromPast, 2) // Task to steer the processing of interlace calibration events
93};
94
95#endif
96
Note: See TracBrowser for help on using the repository browser.