coverity fix
[u/mrichter/AliRoot.git] / TPC / AliTPCclustererKr.h
e2a4d72c 1#ifndef ALITPCCLUSTERERKR_H\r
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *\r
4 * See cxx source for full Copyright notice */\r
98b76430 6/* $Id: AliTPCclustererKr.h,v 1.8 2008/02/07 16:07:15 matyja Exp $ */\r
e2a4d72c 7\r
9// TPC Kr Clusterer Class\r
11// Origin: Adam Matyja, INP PAN,\r
14#include "TObject.h"\r
16class AliTPCclusterKr;\r
17class AliPadMax;\r
18class AliSimDigits;\r
19class AliTPCv4;\r
20class AliTPCParam;\r
21class AliTPCDigitsArray;\r
22class AliTPCvtpr;\r
23class AliTPCClustersRow;\r
24class TTree;\r
25class TH1F;\r
26class TH2F;\r
28class AliTPCTransform;\r
30//used in raw data finder\r
31class AliTPCROC;\r
32class AliTPCCalPad;\r
33class AliTPCAltroMapping;\r
34class AliTPCcalibDB;\r
35class AliTPCRawStream;\r
36class AliTPCRecoParam;\r
37class AliTPCReconstructor;\r
38class AliRawReader;\r
39class AliTPCCalROC;\r
40class TTreeSRedirector;\r
98b76430 41class AliRawEventHeaderBase;\r
e2a4d72c 42//_____________________________________________________________________________\r
43class AliTPCclustererKr: public TObject{\r
45 AliTPCclustererKr();\r
46 AliTPCclustererKr(const AliTPCclustererKr &param);//copy constructor\r
47 AliTPCclustererKr &operator = (const AliTPCclustererKr & param); \r
48 virtual ~AliTPCclustererKr();\r
50 //finders\r
51 virtual Int_t FinderIO();//for MC\r
52 virtual Int_t FinderIO(AliRawReader* rawReader);//for data\r
98b76430 53 virtual Int_t FinderIOold(AliRawReader* rawReader);//for data\r
e2a4d72c 54 virtual Int_t FindClusterKrIO();//main routine for finding clusters\r
55 virtual void CleanSector(Int_t sector); // clean isolated digits\r
57 //other\r
58 void GetXY(Int_t sec,Int_t row,Int_t pad,Double_t& xGlob,Double_t& yGlob);//give XY coordinate of the pad\r
60 virtual void SetInput(TTree * tree); //set input tree with digits \r
61 virtual void SetOutput(TTree * tree); //set output tree with clusters\r
62 virtual void SetParam(AliTPCParam *param){fParam=param;}//set TPC parameters\r
63 virtual void SetDigArr(AliTPCDigitsArray *digarr){fDigarr=digarr;}//set current array of digits\r
64 virtual void SetRecoParam(AliTPCRecoParam *recoParam=0);//set reconstruction parameters\r
98b76430 66 virtual void SetTimeStamp(UInt_t timestamp){ fTimeStamp = timestamp; }\r
f5178f60 67 virtual void SetRun(UInt_t run){ fRun = run; }\r
e2a4d72c 68\r
69 //setters for cluster finder parameters\r
70 virtual void SetZeroSup(Int_t v){fZeroSup=v;}//set zero suppresion parameter\r
71 virtual void SetFirstBin(Int_t v){fFirstBin=v;}//set first considered timebin\r
72 virtual void SetLastBin(Int_t v){fLastBin=v;}//set last considered timebin\r
73 virtual void SetMaxNoiseAbs(Float_t v){fMaxNoiseAbs=v;}//set maximal noise value\r
74 virtual void SetMaxNoiseSigma(Float_t v){fMaxNoiseSigma=v;}//set maximal noise sigma\r
76 virtual void SetMinAdc(Int_t v){v<=0?fMinAdc=1:fMinAdc=v;}//set fMinAdc\r
77 virtual void SetMinTimeBins(Int_t v){fMinTimeBins=v;}//set fMinTimeBins\r
78// virtual void SetMaxPadRange(Int_t v){fMaxPadRange=v;}//set fMaxPadRange\r
79// virtual void SetMaxRowRange(Int_t v){fMaxRowRange=v;}//set fMaxRowRange\r
80 virtual void SetMaxTimeRange(Int_t v){fMaxTimeRange=v;}//set fMaxTimeRange\r
81 virtual void SetValueToSize(Float_t v){fValueToSize=v;}//set fValueToSize\r
83 virtual void SetMaxPadRangeCm(Double_t v){fMaxPadRangeCm=v;}//set fMaxPadRangeCm\r
84 virtual void SetMaxRowRangeCm(Double_t v){fMaxRowRangeCm=v;}//set fMaxRowRangeCm\r
86 virtual void SetIsolCut(Short_t v){fIsolCut=v;}\r
88 virtual void SetDebugLevel(Int_t debug){fDebugLevel=debug;}\r
89 //debug = 0 to 71 -sector number to print\r
90 // = 72 - all sectors\r
91 // = 73 - inners\r
92 // = 74 - outers\r
94 virtual void SetHistoRow(TH1F *histo) {fHistoRow =histo;}\r
95 virtual void SetHistoPad(TH1F *histo) {fHistoPad =histo;}\r
96 virtual void SetHistoTime(TH1F *histo) {fHistoTime =histo;}\r
97 virtual void SetHistoRowPad(TH2F *histo){fHistoRowPad=histo;}\r
99 //getters for cluster finder parameters\r
100 Int_t GetZeroSup() const {return fZeroSup;}//get zero suppresion parameter\r
101 Int_t GetFirstBin() const {return fFirstBin;}//get first considered timebin\r
102 Int_t GetLastBin() const {return fLastBin;}//get last considered timebin\r
103 Float_t GetMaxNoiseAbs() const {return fMaxNoiseAbs;}//get maximal noise value\r
104 Float_t GetMaxNoiseSigma() const {return fMaxNoiseSigma;}//get maximal noise sigma\r
106 Int_t GetMinAdc() const {return fMinAdc;}//get fMinAdc\r
107 Int_t GetMinTimeBins() const {return fMinTimeBins;}//get fMinTimeBins\r
108// Int_t GetMaxPadRange() const {return fMaxPadRange;}//get fMaxPadRange\r
109// Int_t GetMaxRowRange() const {return fMaxRowRange;}//get fMaxRowRange\r
110 Int_t GetMaxTimeRange() const {return fMaxTimeRange;}//get fMaxTimeRange\r
111 Float_t GetValueToSize() const {return fValueToSize;}//get fValueToSize\r
113 Double_t GetMaxPadRangeCm() const {return fMaxPadRangeCm;}//get fMaxPadRangeCm\r
114 Double_t GetMaxRowRangeCm() const {return fMaxRowRangeCm;}//get fMaxRowRangeCm\r
116 Short_t GetIsolCut() const {return fIsolCut;}\r
118 Int_t GetDebugLevel() const {return fDebugLevel;}\r
119 TH1F * GetHistoRow(){return fHistoRow;} \r
120 TH1F * GetHistoPad(){return fHistoPad;}\r
121 TH1F * GetHistoTime(){return fHistoTime;}\r
122 TH2F * GetHistoRowPad(){return fHistoRowPad;}\r
98b76430 124 UInt_t GetTimeStamp() const {return fTimeStamp;}\r
f5178f60 125 UInt_t GetRun() const {return fRun;}\r
98b76430 126\r
e2a4d72c 127private:\r
128 void MakeClusters(TObjArray * maximaInSector, Int_t iSec, Int_t &clusterCounter);\r
129 Bool_t fRawData; //flag =0 for MC =1 for real data\r
131 TTree * fInput; //!input tree with digits - object not owner\r
132 TTreeSRedirector * fOutput; //!output tree with clusters - object not owner\r
134 AliTPCParam * fParam;//!TPC parameters\r
135 AliTPCDigitsArray *fDigarr;//! pointer to current array if digits\r
137 //only for raw data :)\r
138 const AliTPCRecoParam * fRecoParam; //! reconstruction parameters\r
140 //cluster finder parameters\r
141 Int_t fZeroSup;//zero suppresion parameter = 2 def.\r
142 Int_t fFirstBin;//first considered time bin used by cluster finder = 60 def.\r
143 Int_t fLastBin;//last considered time bin used by cluster finder = 950 def.\r
144 Float_t fMaxNoiseAbs;// maximal noise value on pad used in cluster finder = 2 def.\r
145 Float_t fMaxNoiseSigma;// maximal noise sigma on pad used in cluster finder = 3 def.\r
147 Int_t fMinAdc;//minimal value of acd count in each timebin = 3 def.\r
148 Int_t fMinTimeBins;//minimal value of time bins one after each other = 2 def.\r
149// Int_t fMaxPadRange;//maximal pad range from maximum = 4 def.\r
150// Int_t fMaxRowRange;//maximal row range from maximum = 3 def.\r
151 Int_t fMaxTimeRange;//maximal time bin range from maximum = 7 def.\r
152 Float_t fValueToSize;//ratio cluster value to cluster size = 3.5 def.\r
154 Double_t fMaxPadRangeCm;//maximal pad range in cm from maximum = 2.5cm def.\r
155 Double_t fMaxRowRangeCm;//maximal row range in cm from maximum = 3.5cm def.\r
157 Short_t fIsolCut;//isolation cut in 3D = 5 def.\r
159 Int_t fDebugLevel;//! debug level variable\r
160 TH1F *fHistoRow;//!debug histo for rows\r
161 TH1F *fHistoPad;//!debug histo for pads\r
162 TH1F *fHistoTime;//!debug histo for timebins\r
163 TH2F *fHistoRowPad;//!debug histo for rows and pads\r
98b76430 165 UInt_t fTimeStamp; //!time stamp from event header\r
f5178f60 166 UInt_t fRun; //!run from event header\r
167 ClassDef(AliTPCclustererKr,8) // Time Projection Chamber Kr clusters\r
e2a4d72c 168};\r