]> git.uio.no Git - u/mrichter/AliRoot.git/blame - TPC/AliTPCdataQA.h
Updates to accomodate change in DP name syntax
[u/mrichter/AliRoot.git] / TPC / AliTPCdataQA.h
CommitLineData
0ffacf98 1#ifndef ALITPCDATAQA_H
2#define ALITPCDATAQA_H
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6
7
336156cc 8#include <TH1F.h>
0ffacf98 9#include <TObjArray.h>
10
11class TArrayF;
12class TH2F;
13class TTreeSRedirector;
14class AliTPCROC;
15class AliTPCCalROC;
16class AliTPCRawStream;
17class AliTPCRawStreamFast;
18class AliRawReader;
19class AliTPCAltroMapping;
20class AliTPCCalPad;
21struct eventHeaderStruct;
22
336156cc 23class AliTPCdataQA : public TH1F {
0ffacf98 24
25public:
26 AliTPCdataQA();
27 AliTPCdataQA(const AliTPCdataQA &ped);
28 virtual ~AliTPCdataQA();
29
30 AliTPCdataQA& operator = (const AliTPCdataQA &source);
31 void DumpToFile(const Char_t *filename, const Char_t *dir="", const Bool_t append=kFALSE);
258cd111 32 void MakeTree(const char *fname="QApad.root");
33
0ffacf98 34 //
35 Bool_t ProcessEventFast(AliTPCRawStreamFast *rawStreamFast);
36 Bool_t ProcessEventFast(AliRawReader *rawReader);
37 Bool_t ProcessEvent(AliTPCRawStream *rawStream);
38 Bool_t ProcessEvent(AliRawReader *rawReader);
39 Bool_t ProcessEvent(eventHeaderStruct *event);
40
41 Int_t Update(const Int_t isector, const Int_t iRow, const Int_t iPad,
42 const Int_t iTimeBin, const Float_t signal);
43 void Analyse();
44 //
45 //
f11b3071 46 void SetPedestal(AliTPCCalPad *pedestalCal){ fPedestal = pedestalCal;}
47 void SetNoise(AliTPCCalPad *noiseCal){ fNoise = noiseCal;}
48
0ffacf98 49 AliTPCCalPad *GetMaxCharge(){ return fMaxCharge;}
f11b3071 50 AliTPCCalPad *GetMeanCharge(){ return fMeanCharge;}
51 AliTPCCalPad *GetNoThreshold(){ return fNoThreshold;}
0ffacf98 52 AliTPCCalPad *GetOverThreshold0(){ return fOverThreshold0;}
53 AliTPCCalPad *GetOverThreshold5(){ return fOverThreshold5;}
54 AliTPCCalPad *GetOverThreshold10(){ return fOverThreshold10;}
55 AliTPCCalPad *GetOverThreshold20(){ return fOverThreshold20;}
56 AliTPCCalPad *GetOverThreshold30(){ return fOverThreshold30;}
57
58 //
59 AliTPCAltroMapping **GetAltroMapping() { return fMapping; };
60 void SetAltroMapping(AliTPCAltroMapping **mapp) { fMapping = mapp; };
61 //
62 //
63 Int_t GetFirstTimeBin() const { return fFirstTimeBin; }
64 Int_t GetLastTimeBin() const { return fLastTimeBin; }
65 Int_t GetAdcMin() const { return fAdcMin; }
66 Int_t GetAdcMax() const { return fAdcMax; }
c322f08a 67 void SetRangeTime(Int_t tMin, Int_t tMax){ fFirstTimeBin=tMin; fLastTimeBin=tMax;} // Set time bin range that is used for the pedestal calibration
0ffacf98 68 void SetRangeAdc (Int_t aMin, Int_t aMax){ fAdcMin=aMin; fAdcMax=aMax; } // Set adc range for the pedestal calibration
69
70 void SetOldRCUformat(Bool_t format=kTRUE) { fOldRCUformat = format; }
0ffacf98 71
c322f08a 72
0ffacf98 73private:
f11b3071 74 void UpdateSignalHistograms(const Int_t icsector, const Int_t icRow,
75 const Int_t icPad, const Int_t icTimeBin,
76 const Float_t signal);
c322f08a 77
78 void MakeArrays(); // create arrays for random data acces
79 void CleanArrays(); // clean arrays for random data acces
80 Float_t* GetExpandDigit(Int_t row, Int_t pad, Int_t time); // get pointer to the digit
f11b3071 81
0ffacf98 82 Int_t fFirstTimeBin; // First Time bin needed for analysis
83 Int_t fLastTimeBin; // Last Time bin needed for analysis
c322f08a 84 Int_t fMaxTime; // Maximum number of time bins
0ffacf98 85 Int_t fAdcMin; // min adc channel of pedestal value
86 Int_t fAdcMax; // max adc channel of pedestal value
87 Bool_t fOldRCUformat; //! Should we use the old RCU format for data reading
f11b3071 88
0ffacf98 89
90 AliTPCROC *fROC; //! ROC information
91 AliTPCAltroMapping **fMapping; //! Altro Mapping object
92 //
93 //
336156cc 94 AliTPCCalPad * fPedestal; //! option to set pedestal cal object
95 AliTPCCalPad * fNoise; //! option to set noise cal object
f11b3071 96 AliTPCCalPad * fMaxCharge; // max charge
97 AliTPCCalPad * fMeanCharge; // mean charge
98 AliTPCCalPad * fNoThreshold; // number of digits
0ffacf98 99 AliTPCCalPad * fOverThreshold0; // number of digits over threshold
100 AliTPCCalPad * fOverThreshold5; // number of digits over threshold
f11b3071 101 AliTPCCalPad * fOverThreshold10; // number of digits over threshold
102 AliTPCCalPad * fOverThreshold20; // number of digits over threshold
336156cc 103 AliTPCCalPad * fOverThreshold30; //! number of digits over threshold
f11b3071 104
105 Int_t fEventCounter; // event Counter
106 Int_t fSectorLast; //! last sector with signal
107 Int_t fRowLast; //! last row with signal
108 Int_t fPadLast; //! last pad with signal
109 Int_t fTimeBinLast; //! last time bin with signal
110 Float_t fSignalLast; //! last signal value
111 Int_t fNAboveThreshold; //! number of signals above threshold
c322f08a 112 //
113 // Expand buffer
114 //
115 Float_t** fAllBins; //! array for digit using random access
116 Int_t** fAllSigBins; //! array of pointers to the indexes over threshold
117 Int_t* fAllNSigBins; //!
118
0ffacf98 119
120public:
121 ClassDef(AliTPCdataQA, 1) // Implementation of the TPC pedestal and noise calibration
122};
123
124
125
126#endif
127