1 | #ifndef MARS_MHCalibrationChargeCam
|
---|
2 | #define MARS_MHCalibrationChargeCam
|
---|
3 |
|
---|
4 | #ifndef MARS_MHCalibrationCam
|
---|
5 | #include "MHCalibrationCam.h"
|
---|
6 | #endif
|
---|
7 |
|
---|
8 | #ifndef MARS_MArrayI
|
---|
9 | #include "MArrayI.h"
|
---|
10 | #endif
|
---|
11 |
|
---|
12 | #ifndef MARS_MArrayD
|
---|
13 | #include "MArrayD.h"
|
---|
14 | #endif
|
---|
15 |
|
---|
16 | class TH1F;
|
---|
17 | class MRawEvtData;
|
---|
18 | class MExtractedSignalCam;
|
---|
19 | class MCalibrationChargePix;
|
---|
20 | class MHCalibrationChargePix;
|
---|
21 |
|
---|
22 | class MHCalibrationChargeCam : public MHCalibrationCam
|
---|
23 | {
|
---|
24 | private:
|
---|
25 |
|
---|
26 | static const Int_t fgChargeHiGainNbins; //! Nr. bins of HiGain Histograms (now set to: 550 )
|
---|
27 | static const Axis_t fgChargeHiGainFirst; //! First Bin of HiGain Histograms (now set to: -100.5)
|
---|
28 | static const Axis_t fgChargeHiGainLast; //! Last Bin of HiGain Histograms (now set to: 999.5)
|
---|
29 | static const Int_t fgChargeLoGainNbins; //! First Bin of LoGain Histograms (now set to: 325 )
|
---|
30 | static const Axis_t fgChargeLoGainFirst; //! First Bin of LoGain Histograms (now set to: -150.5)
|
---|
31 | static const Axis_t fgChargeLoGainLast; //! Last Bin of LoGain Histograms (now set to: 499.5)
|
---|
32 |
|
---|
33 | static const TString gsHistName; //! Default Histogram names
|
---|
34 | static const TString gsHistTitle; //! Default Histogram titles
|
---|
35 | static const TString gsHistXTitle; //! Default Histogram x-axis titles
|
---|
36 | static const TString gsHistYTitle; //! Default Histogram y-axis titles
|
---|
37 |
|
---|
38 | static const TString gsAbsHistName; //! Default Histogram names abs.times
|
---|
39 | static const TString gsAbsHistTitle; //! Default Histogram titles abs.times
|
---|
40 | static const TString gsAbsHistXTitle; //! Default Histogram x-axis titles abs.times
|
---|
41 | static const TString gsAbsHistYTitle; //! Default Histogram y-axis titles abs.times
|
---|
42 |
|
---|
43 | static const Float_t fgNumHiGainSaturationLimit; //! The default for fNumHiGainSaturationLimit (now at: 0.01)
|
---|
44 | static const Float_t fgNumLoGainSaturationLimit; //! The default for fNumLoGainSaturationLimit (now at: 0.005)
|
---|
45 | static const Float_t fgTimeLowerLimit; //! Default for fTimeLowerLimit (now set to: 1.)
|
---|
46 | static const Float_t fgTimeUpperLimit; //! Default for fTimeUpperLimit (now set to: 2.)
|
---|
47 |
|
---|
48 | static const Float_t gkHiGainInnerRefLines[7]; //!
|
---|
49 | static const Float_t gkHiGainOuterRefLines[7]; //!
|
---|
50 | static const Float_t gkLoGainInnerRefLines[7]; //!
|
---|
51 | static const Float_t gkLoGainOuterRefLines[7]; //!
|
---|
52 |
|
---|
53 | Int_t fLoGainNbins; // Number of LoGain bins
|
---|
54 | Axis_t fLoGainFirst; // Lower histogram limit low gain
|
---|
55 | Axis_t fLoGainLast; // Upper histogram limit low gain
|
---|
56 |
|
---|
57 | TString fAbsHistName; // Histogram names abs.times
|
---|
58 | TString fAbsHistTitle; // Histogram titles abs. times
|
---|
59 | TString fAbsHistXTitle; // Histogram x-axis titles abs. times
|
---|
60 | TString fAbsHistYTitle; // Histogram y-axis titles abs. times
|
---|
61 |
|
---|
62 | MArrayD fSumhiarea ; //!
|
---|
63 | MArrayD fSumloarea ; //!
|
---|
64 | MArrayD fTimehiarea ; //!
|
---|
65 | MArrayD fTimeloarea ; //!
|
---|
66 | MArrayD fSumhisector; //!
|
---|
67 | MArrayD fSumlosector; //!
|
---|
68 | MArrayD fTimehisector; //!
|
---|
69 | MArrayD fTimelosector; //!
|
---|
70 |
|
---|
71 | MArrayI fSathiarea ; //!
|
---|
72 | MArrayI fSatloarea ; //!
|
---|
73 | MArrayI fSathisector; //!
|
---|
74 | MArrayI fSatlosector; //!
|
---|
75 |
|
---|
76 | Float_t fTimeLowerLimit; // Limit dist. to first signal slice (in units of FADC slices)
|
---|
77 | Float_t fTimeUpperLimit; // Limit dist. to last signal slice (in units of FADC slices)
|
---|
78 | Byte_t fFirstHiGain; // First used slice High Gain
|
---|
79 | Byte_t fLastHiGain; // Last used slice High Gain
|
---|
80 | Byte_t fFirstLoGain; // First used slice Low Gain
|
---|
81 | Byte_t fLastLoGain; // Last used slice Low Gain
|
---|
82 |
|
---|
83 | MRawEvtData *fRawEvt; //! Raw event data
|
---|
84 |
|
---|
85 | Bool_t SetupHists(const MParList *pList);
|
---|
86 | Bool_t ReInitHists(MParList *pList);
|
---|
87 | Bool_t FillHists(const MParContainer *par, const Stat_t w=1);
|
---|
88 |
|
---|
89 | void InitHiGainArrays( const Int_t npix, const Int_t nareas, const Int_t nsectors );
|
---|
90 | void InitLoGainArrays( const Int_t npix, const Int_t nareas, const Int_t nsectors );
|
---|
91 |
|
---|
92 | void FinalizeAbsTimes (MHCalibrationChargePix &hist, MCalibrationChargePix &pix, MBadPixelsPix &bad,
|
---|
93 | Byte_t first, Byte_t last);
|
---|
94 | Bool_t FinalizeHists();
|
---|
95 | void FinalizeBadPixels();
|
---|
96 |
|
---|
97 | void DrawDataCheckPixel(MHCalibrationChargePix &pix, const Float_t refline[]);
|
---|
98 | void DisplayRefLines ( const TH1F *hist, const Float_t refline[]) const;
|
---|
99 |
|
---|
100 | Int_t ReadEnv ( const TEnv &env, TString prefix, Bool_t print);
|
---|
101 |
|
---|
102 | public:
|
---|
103 |
|
---|
104 | MHCalibrationChargeCam(const char *name=NULL, const char *title=NULL);
|
---|
105 | ~MHCalibrationChargeCam() {}
|
---|
106 |
|
---|
107 | // Clone
|
---|
108 | TObject *Clone(const char *name="") const;
|
---|
109 |
|
---|
110 | void SetLoGainNbins ( const Int_t i ) { fLoGainNbins = i; }
|
---|
111 | void SetLoGainFirst ( const Axis_t f ) { fLoGainFirst = f; }
|
---|
112 | void SetLoGainLast ( const Axis_t f ) { fLoGainLast = f; }
|
---|
113 |
|
---|
114 | void SetTimeLowerLimit ( const Float_t f=fgTimeLowerLimit ) { fTimeLowerLimit = f; }
|
---|
115 | void SetTimeUpperLimit ( const Float_t f=fgTimeUpperLimit ) { fTimeUpperLimit = f; }
|
---|
116 |
|
---|
117 | void SetAbsHistName ( const char *name ) { fAbsHistName = name; }
|
---|
118 | void SetAbsHistTitle ( const char *name ) { fAbsHistTitle = name; }
|
---|
119 | void SetAbsHistXTitle( const char *name ) { fAbsHistXTitle = name; }
|
---|
120 | void SetAbsHistYTitle( const char *name ) { fAbsHistYTitle = name; }
|
---|
121 |
|
---|
122 | Bool_t GetPixelContent ( Double_t &val, Int_t idx, const MGeomCam &cam, Int_t type=0) const { return kTRUE; }
|
---|
123 | void DrawPixelContent( Int_t num ) const;
|
---|
124 |
|
---|
125 | // Draw
|
---|
126 | void Draw(const Option_t *opt);
|
---|
127 |
|
---|
128 | ClassDef(MHCalibrationChargeCam, 1) // Histogram class for Charge Camera Calibration
|
---|
129 | };
|
---|
130 |
|
---|
131 | #endif
|
---|