1 | #ifndef MARS_MJPedestal
|
---|
2 | #define MARS_MJPedestal
|
---|
3 |
|
---|
4 | #ifndef MARS_MPedestalCam
|
---|
5 | #include "MPedestalCam.h"
|
---|
6 | #endif
|
---|
7 | #ifndef MARS_MBadPixelsCam
|
---|
8 | #include "MBadPixelsCam.h"
|
---|
9 | #endif
|
---|
10 |
|
---|
11 | class TCanvas;
|
---|
12 | class MParList;
|
---|
13 | class MRunIter;
|
---|
14 | class MHCamera;
|
---|
15 | class TH1D;
|
---|
16 | class MExtractor;
|
---|
17 | class MJPedestal : public MParContainer
|
---|
18 | {
|
---|
19 | private:
|
---|
20 |
|
---|
21 | static const Double_t fgPedestalMin;
|
---|
22 | static const Double_t fgPedestalMax;
|
---|
23 | static const Double_t fgPedRmsMin;
|
---|
24 | static const Double_t fgPedRmsMax;
|
---|
25 |
|
---|
26 | static const Float_t fgRefPedClosedLids;
|
---|
27 | static const Float_t fgRefPedExtraGalactic;
|
---|
28 | static const Float_t fgRefPedGalactic;
|
---|
29 |
|
---|
30 | static const Float_t fgRefPedRmsClosedLids;
|
---|
31 | static const Float_t fgRefPedRmsExtraGalactic;
|
---|
32 | static const Float_t fgRefPedRmsGalactic;
|
---|
33 |
|
---|
34 | TString fOutputPath;
|
---|
35 |
|
---|
36 | MRunIter *fRuns;
|
---|
37 | MExtractor *fExtractor; // Signal extractor, used to find the nr. of used FADC slices
|
---|
38 |
|
---|
39 | MPedestalCam fPedestalCam;
|
---|
40 | MBadPixelsCam fBadPixels;
|
---|
41 |
|
---|
42 | Bool_t fDataCheck; // Flag if the data check is run on raw data
|
---|
43 |
|
---|
44 | Bool_t ReadPedestalCam();
|
---|
45 | Bool_t WriteResult();
|
---|
46 |
|
---|
47 | void DisplayResult(MParList &plist);
|
---|
48 | void DisplayReferenceLines(MHCamera *cam, const Int_t what) const;
|
---|
49 | void DisplayOutliers( TH1D *hist) const;
|
---|
50 |
|
---|
51 | public:
|
---|
52 |
|
---|
53 | MJPedestal(const char *name=NULL, const char *title=NULL);
|
---|
54 |
|
---|
55 | MPedestalCam &GetPedestalCam() { return fPedestalCam; }
|
---|
56 | const MBadPixelsCam &GetBadPixels() const { return fBadPixels; }
|
---|
57 |
|
---|
58 | const char* GetOutputFile() const;
|
---|
59 | const Bool_t IsDataCheck() const { return fDataCheck; }
|
---|
60 |
|
---|
61 | Bool_t Process();
|
---|
62 | Bool_t ProcessFile();
|
---|
63 |
|
---|
64 | void SetBadPixels ( const MBadPixelsCam &bad) { bad.Copy(fBadPixels); }
|
---|
65 | void SetDataCheck ( const Bool_t b=kTRUE ) { fDataCheck = b; }
|
---|
66 | void SetExtractor ( MExtractor* ext ) { fExtractor = ext; }
|
---|
67 | void SetInput ( MRunIter *iter ) { fRuns = iter; }
|
---|
68 | void SetOutputPath( const char *path="." );
|
---|
69 |
|
---|
70 | ClassDef(MJPedestal, 0) // Tool to create a pedestal file (MPedestalCam)
|
---|
71 | };
|
---|
72 |
|
---|
73 | #endif
|
---|