source: trunk/MagicSoft/Mars/mpedestal/MPedCalcFromLoGain.h@ 4454

Last change on this file since 4454 was 4404, checked in by fgoebel, 20 years ago
*** empty log message ***
File size: 2.6 KB
Line 
1#ifndef MARS_MPedCalcFromLoGain
2#define MARS_MPedCalcFromLoGain
3
4#ifndef MARS_MExtractor
5#include "MExtractor.h"
6#endif
7
8#ifndef ROOT_TArrayD
9#include <TArrayD.h>
10#endif
11
12#ifndef ROOT_TArrayI
13#include <TArrayI.h>
14#endif
15
16class MGeomCam;
17class MBadPixelsCam;
18class MPedCalcFromLoGain : public MExtractor
19{
20
21 static const Byte_t fgHiGainFirst; // First FADC slice Hi-Gain (currently set to: 3)
22 static const Byte_t fgHiGainLast; // Last FADC slice Hi-Gain (currently set to: 14)
23 static const Byte_t fgLoGainFirst; // First FADC slice Lo-Gain (currently set to: 3)
24 static const Byte_t fgLoGainLast; // Last FADC slice Lo-Gain (currently set to: 14)
25 static const Byte_t fgHiGainWindowSize; // The extraction window Hi-Gain
26 static const Byte_t fgLoGainWindowSize; // The extraction window Lo-Gain
27 static const Byte_t fgMaxHiGainVar; // The maximum difference between the highest and lowest slice
28 // in the high gain window allowed in order to use low gain
29 // for pedestal calculation
30 Int_t fNumEventsDump; // Number of event after which MPedestalCam gets updated
31
32 Byte_t fMaxHiGainVar;
33 Byte_t fWindowSizeHiGain; // Number of Hi Gain slices in window
34 Byte_t fWindowSizeLoGain; // Number of Lo Gain slices in window
35
36 Bool_t fPedestalUpdate;
37
38 MGeomCam *fGeom; // Camera geometry
39 MBadPixelsCam *fBad; // Bad Pixels
40
41 TArrayI fNumEventsUsed; // Number of events used for pedestal calc for each pixel
42 TArrayI fTotalCounter; // Counter for dumping values to Pedestal Container
43 TArrayD fSumx; // sum of values
44 TArrayD fSumx2; // sum of squared values
45 TArrayD fSumAB0; // sum of ABFlag=0 slices
46 TArrayD fSumAB1; // sum of ABFlag=1 slices
47
48 Int_t PreProcess ( MParList *pList );
49 Bool_t ReInit ( MParList *pList );
50 Int_t Process ();
51 Int_t PostProcess();
52
53public:
54
55 MPedCalcFromLoGain(const char *name=NULL, const char *title=NULL);
56
57 void Clear(const Option_t *o="");
58 void SetRange(Byte_t hifirst=0, Byte_t hilast=0, Byte_t lofirst=0, Byte_t lolast=0);
59 void SetWindowSize(Byte_t windowh=0, Byte_t windowl=0);
60 void SetMaxHiGainVar(Byte_t maxvar=0);
61 void SetDumpEvents(UInt_t dumpevents = 0) {fNumEventsDump = dumpevents;}
62 void SetPedestalUpdate(Bool_t pedupdate) {fPedestalUpdate = pedupdate;}
63
64 TArrayI *GetNumEventsUsed() {return &fNumEventsUsed;};
65
66 ClassDef(MPedCalcFromLoGain, 0) // Task to calculate pedestals from pedestal runs raw data
67};
68
69#endif
Note: See TracBrowser for help on using the repository browser.