2 // Original: AliHLTClustFinderNew.h,v 1.13 2004/06/18 10:55:26 loizides
4 #ifndef AliHLTTPC_ClusterFinder
5 #define AliHLTTPC_ClusterFinder
7 #include "AliHLTLogging.h"
9 class AliHLTTPCSpacePointData;
10 class AliHLTTPCDigitReader;
12 class AliHLTTPCClusterFinder : public AliHLTLogging {
17 UInt_t fTotalCharge; //tot charge of cluster
18 UInt_t fPad; //pad value
19 UInt_t fTime; //time value
20 ULong64_t fPad2; //for error in XY direction
21 ULong64_t fTime2; //for error in Z direction
22 UInt_t fMean; //mean in time
23 UInt_t fFlags; //different flags
24 UInt_t fChargeFalling; //for deconvolution
25 UInt_t fLastCharge; //for deconvolution
26 UInt_t fLastMergedPad; //dont merge twice per pad
28 typedef struct AliClusterData AliClusterData; //!
31 AliHLTTPCSpacePointData *fSpacePointData; //! array of space points
32 AliHLTTPCDigitReader *fDigitReader; //! reader instance
34 UChar_t* fPtr; //! pointer to packed block
35 unsigned long fSize; //packed block size
36 Bool_t fDeconvTime; //deconv in time direction
37 Bool_t fDeconvPad; //deconv in pad direction
38 Bool_t fStdout; //have print out in write clusters
39 Bool_t fCalcerr; //calculate centroid sigmas
40 Bool_t fRawSP; //store centroids in raw system
43 Int_t fFirstRow; //first row
44 Int_t fLastRow; //last row
45 Int_t fCurrentRow; //current active row
46 Int_t fCurrentSlice; //current slice
47 Int_t fCurrentPatch; //current patch
48 Int_t fMatch; //size of match
49 UInt_t fThreshold; //threshold for clusters
50 /** threshold for zero suppression (applied per bin) */
51 Int_t fSignalThreshold;
52 Int_t fNClusters; //number of found clusters
53 Int_t fMaxNClusters; //max. number of clusters
54 Float_t fXYErr; //fixed error in XY
55 Float_t fZErr; //fixed error in Z
57 Float_t fOccupancyLimit; // Occupancy Limit
61 void GetTrackID(Int_t pad,Int_t time,Int_t *trackID);
65 /** standard constructor */
66 AliHLTTPCClusterFinder();
67 /** not a valid copy constructor, defined according to effective C++ style */
68 AliHLTTPCClusterFinder(const AliHLTTPCClusterFinder&);
69 /** not a valid assignment op, but defined according to effective C++ style */
70 AliHLTTPCClusterFinder& operator=(const AliHLTTPCClusterFinder&);
72 virtual ~AliHLTTPCClusterFinder();
74 void Read(void* ptr,unsigned long size);
76 void InitSlice(Int_t slice,Int_t patch,Int_t firstrow, Int_t lastrow,Int_t maxpoints);
77 void InitSlice(Int_t slice,Int_t patch,Int_t maxpoints);
80 void SetOutputArray(AliHLTTPCSpacePointData *pt);
81 void WriteClusters(Int_t n_clusters,AliClusterData *list);
83 void SetXYError(Float_t f) {fXYErr=f;}
84 void SetZError(Float_t f) {fZErr=f;}
85 void SetDeconv(Bool_t f) {fDeconvPad=f; fDeconvTime=f;}
86 void SetThreshold(UInt_t i) {fThreshold=i;}
87 void SetOccupancyLimit(Float_t f) {fOccupancyLimit=f;}
88 void SetSignalThreshold(Int_t i) {fSignalThreshold=i;}
89 void SetMatchWidth(UInt_t i) {fMatch=i;}
90 void SetSTDOutput(Bool_t f=kFALSE) {fStdout=f;}
91 void SetCalcErr(Bool_t f=kTRUE) {fCalcerr=f;}
92 void SetRawSP(Bool_t f=kFALSE) {fRawSP=f;}
93 void SetReader(AliHLTTPCDigitReader* f){fDigitReader = f;}
94 Int_t GetNumberOfClusters() const {return fNClusters;}
96 ClassDef(AliHLTTPCClusterFinder,0) //Fast cluster finder