]> git.uio.no Git - u/mrichter/AliRoot.git/blame - TPC/AliTPCCalibPedestal.h
GraphErrors * FitSlices
[u/mrichter/AliRoot.git] / TPC / AliTPCCalibPedestal.h
CommitLineData
8bc7e885 1#ifndef ALITPCCALIBPEDESTAL_H
2#define ALITPCCALIBPEDESTAL_H
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
f1b14fa2 6#include <TObjArray.h>
880c3382 7#include "AliTPCCalibRawBase.h"
8bc7e885 8
bdf99a93 9class TArrayF;
8bc7e885 10class TH2F;
8bc7e885 11class TTreeSRedirector;
12class AliTPCROC;
bc331d5b 13class AliTPCCalROC;
a7dce0bc 14class AliTPCRawStream;
08205ed7 15class AliTPCRawStreamFast;
aa983e4f 16class AliRawReader;
ac940b58 17class TMap;
8bc7e885 18
bdf99a93 19struct eventHeaderStruct;
8bc7e885 20
880c3382 21class AliTPCCalibPedestal : public AliTPCCalibRawBase {
8bc7e885 22
23public:
24 AliTPCCalibPedestal();
bc331d5b 25 AliTPCCalibPedestal(const AliTPCCalibPedestal &ped);
ac940b58 26 AliTPCCalibPedestal(const TMap *config);
8bc7e885 27 virtual ~AliTPCCalibPedestal();
bc331d5b 28
29 AliTPCCalibPedestal& operator = (const AliTPCCalibPedestal &source);
30
880c3382 31 virtual Int_t Update(const Int_t isector, const Int_t iRow, const Int_t iPad,
bdf99a93 32 const Int_t iTimeBin, const Float_t signal);
880c3382 33 virtual void Analyse();
8bc7e885 34 //
bc331d5b 35 AliTPCCalROC* GetCalRocPedestal (Int_t sector, Bool_t force=kFALSE); // get calibration object - sector
1542c62d 36 AliTPCCalROC* GetCalRocSigma(Int_t sector, Bool_t force=kFALSE); // get calibration object - sector
bc331d5b 37 const TObjArray* GetCalPadPedestal (){return &fCalRocArrayPedestal;} // get calibration object
1542c62d 38 const TObjArray* GetCalPadSigma(){return &fCalRocArraySigma;} // get calibration object
39
40 AliTPCCalROC* GetCalRocMean (Int_t sector, Bool_t force=kFALSE); // get calibration object - sector
41 AliTPCCalROC* GetCalRocRMS(Int_t sector, Bool_t force=kFALSE); // get calibration object - sector
42 const TObjArray* GetCalPadMean (){return &fCalRocArrayMean;} // get calibration object
bc331d5b 43 const TObjArray* GetCalPadRMS(){return &fCalRocArrayRMS;} // get calibration object
aa983e4f 44
bc331d5b 45 TH2F* GetHistoPedestal (Int_t sector, Bool_t force=kFALSE); // get refernce histogram
8bc7e885 46 //
bdf99a93 47 void SetTimeAnalysis(Bool_t time = kTRUE); // Use ONLY in TPCPEDESTALda on LDC for one sector!
48 void AnalyseTime(Int_t nevents); // Makes sense only in TPCPEDESTALda on LDC!
49 TArrayF **GetTimePedestals() const { return fTimeSignal; } // Get array with time dependent pedestals (for one sector!)
50 //
1542c62d 51 Int_t GetAdcMin() const { return fAdcMin; }
52 Int_t GetAdcMax() const { return fAdcMax; }
53 Float_t GetAnaMeanDown() const { return fAnaMeanDown; }
54 Float_t GetAnaMeanUp() const { return fAnaMeanUp; }
55
aa983e4f 56 void SetRangeAdc (Int_t aMin, Int_t aMax){ fAdcMin=aMin; fAdcMax=aMax; } // Set adc range for the pedestal calibration
1542c62d 57 void SetAnalysisTruncationRange(Float_t down, Float_t up) {fAnaMeanDown=down; fAnaMeanUp=up;} //Set range for truncated mean analysis of the channel information
8bc7e885 58
bdf99a93 59 void Merge(AliTPCCalibPedestal *ped);
8bc7e885 60
bdf99a93 61 Bool_t TestEvent(); // Test the fast approach to fill histogram - used for test purposes
8bc7e885 62
63private:
8bc7e885 64 Int_t fAdcMin; // min adc channel of pedestal value
65 Int_t fAdcMax; // max adc channel of pedestal value
bdf99a93 66
1542c62d 67 Float_t fAnaMeanDown; // Truncated mean channel analysis - lower cut
68 Float_t fAnaMeanUp; // Truncated mean channel analysis - upper cut
69
bdf99a93 70 Bool_t fTimeAnalysis; //! Should we use the time dependent analysis? ONLY ON LDC!
a7dce0bc 71
1542c62d 72 TObjArray fCalRocArrayPedestal; // Array of AliTPCCalROC class for pedestal values from gaus fit
73 TObjArray fCalRocArraySigma; // Array of AliTPCCalROC class for noise values from gaus fit
bdf99a93 74
8bc7e885 75 TObjArray fHistoPedestalArray; // Calibration histograms for Pedestal distribution
bdf99a93 76
77 TArrayF **fTimeSignal; //! Arrays which hold time dependent signals
1542c62d 78
79 TObjArray fCalRocArrayMean; // Array of AliTPCCalROC class for pedestal values, simple mean
80 TObjArray fCalRocArrayRMS; // Array of AliTPCCalROC class for noise values, simple rms
bdf99a93 81
bc331d5b 82 TH2F* GetHisto(Int_t sector, TObjArray *arr,
8bc7e885 83 Int_t nbinsY, Float_t ymin, Float_t ymax,
a6e0ebfe 84 const Char_t *type, Bool_t force);
bdf99a93 85
8bc7e885 86 AliTPCCalROC* GetCalRoc(Int_t sector, TObjArray* arr, Bool_t force);
87
88public:
880c3382 89 ClassDef(AliTPCCalibPedestal, 7) // Implementation of the TPC pedestal and noise calibration
8bc7e885 90};
91
92
93
94#endif
95