]>
Commit | Line | Data |
---|---|---|
27de2dfb | 1 | #ifndef ALIHFEEXTRACUTS_H |
2 | #define ALIHFEEXTRACUTS_H | |
3 | ||
809a4336 | 4 | /************************************************************************** |
5 | * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
6 | * * | |
7 | * Author: The ALICE Off-line Project. * | |
8 | * Contributors are mentioned in the code where appropriate. * | |
9 | * * | |
10 | * Permission to use, copy, modify and distribute this software and its * | |
11 | * documentation strictly for non-commercial purposes is hereby granted * | |
12 | * without fee, provided that the above copyright notice appears in all * | |
13 | * copies and that both the copyright notice and this permission notice * | |
14 | * appear in the supporting documentation. The authors make no claims * | |
15 | * about the suitability of this software for any purpose. It is * | |
16 | * provided "as is" without express or implied warranty. * | |
17 | **************************************************************************/ | |
27de2dfb | 18 | |
19 | /* $Id$ */ | |
20 | ||
50685501 | 21 | // |
22 | // Extra Cuts from the ALICE HFE Group | |
23 | // Container for cuts which are currently not implemented by | |
24 | // the Correction Framework | |
25 | // | |
809a4336 | 26 | |
27 | // #ifndef ALICFCUTBASE_H | |
28 | #include "AliCFCutBase.h" | |
29 | // #endif | |
30 | ||
31 | class TList; | |
32 | ||
3a72645a | 33 | class AliVEvent; |
34 | class AliVParticle; | |
35 | class AliVTrack; | |
809a4336 | 36 | |
37 | class AliHFEextraCuts : public AliCFCutBase{ | |
38 | public: | |
39 | typedef enum{ | |
40 | kFirst = 0, | |
41 | kSecond = 1, | |
42 | kBoth = 2, | |
43 | kNone = 3, | |
44 | kAny = 4 | |
45 | } ITSPixel_t; | |
e3ae862b | 46 | typedef enum{ |
47 | kFound = 0, | |
48 | kFoundIter1 = 1, | |
49 | kCrossedRows = 2 | |
50 | } ETPCclusterDef_t; | |
51 | typedef enum{ | |
52 | kFoundOverFindable = 0, | |
53 | kFoundOverFindableIter1 = 1, | |
54 | kFoundOverCR = 2, | |
55 | kCROverFindable = 3 | |
56 | } ETPCclrDef_t; | |
809a4336 | 57 | AliHFEextraCuts(const Char_t *name, const Char_t *title); |
58 | AliHFEextraCuts(const AliHFEextraCuts &c); | |
59 | AliHFEextraCuts &operator=(const AliHFEextraCuts &c); | |
75d81601 | 60 | virtual ~AliHFEextraCuts(); |
809a4336 | 61 | |
9eeae5d5 | 62 | virtual Bool_t IsSelected(TObject *o); |
63 | virtual Bool_t IsSelected(TList *) { return kTRUE; }; | |
3a72645a | 64 | virtual void SetRecEventInfo(const TObject *event); |
809a4336 | 65 | |
e3ae862b | 66 | inline void SetClusterRatioTPC(Double_t ratio, ETPCclrDef_t def); |
809a4336 | 67 | inline void SetRequireITSpixel(ITSPixel_t pixel); |
68 | inline void SetMinImpactParamR(Double_t impactParam); | |
69 | inline void SetMaxImpactParamR(Double_t impactParam); | |
70 | inline void SetMinImpactParamZ(Double_t impactParam); | |
71 | inline void SetMaxImpactParamZ(Double_t impactParam); | |
3a72645a | 72 | inline void SetMinHFEImpactParamR(); |
73 | inline void SetMinHFEImpactParamNsigmaR(); | |
809a4336 | 74 | inline void SetMinTrackletsTRD(Int_t minTracklets); |
e3ae862b | 75 | inline void SetMinNClustersTPC(Int_t minclusters, ETPCclusterDef_t def); |
76 | void SetTOFPID(Bool_t tofPid) { fTOFpid = tofPid;} | |
dbe3abbe | 77 | |
75d81601 | 78 | void SetCheckITSstatus(Bool_t check) { fCheck = check; }; |
79 | Bool_t GetCheckITSstatus() const { return fCheck; }; | |
80 | ||
dbe3abbe | 81 | void SetDebugLevel(Int_t level) { fDebugLevel = level; }; |
82 | Int_t GetDebugLevel() const { return fDebugLevel; }; | |
809a4336 | 83 | |
84 | protected: | |
85 | virtual void AddQAHistograms(TList *qaList); | |
3a72645a | 86 | Bool_t CheckRecCuts(AliVTrack *track); |
87 | Bool_t CheckMCCuts(AliVParticle * /*track*/) const; | |
75d81601 | 88 | Bool_t CheckITSstatus(Int_t itsStatus) const; |
3a72645a | 89 | void FillQAhistosRec(AliVTrack *track, UInt_t when); |
809a4336 | 90 | // void FillQAhistosMC(AliMCParticle *track, UInt_t when); |
91 | void FillCutCorrelation(ULong64_t survivedCut); | |
dbe3abbe | 92 | void PrintBitMap(Int_t bitmap); |
809a4336 | 93 | |
3a72645a | 94 | // Getter Functions for ESD/AOD compatible mode |
95 | Int_t GetTRDnTrackletsPID(AliVTrack *track); | |
96 | Int_t GetITSstatus(AliVTrack *track, Int_t layer); | |
e3ae862b | 97 | UInt_t GetTPCncls(AliVTrack *track); |
98 | Double_t GetTPCclusterRatio(AliVTrack *track); | |
3a72645a | 99 | void GetImpactParameters(AliVTrack *track, Float_t &radial, Float_t &z); |
100 | void GetHFEImpactParameters(AliVTrack *track, Double_t &dcaxy, Double_t &dcansigmaxy); | |
101 | void GetHFEImpactParameterCuts(AliVTrack *track, Double_t &hfeimpactRcut, Double_t &hfeimpactnsigmaRcut); | |
102 | ||
809a4336 | 103 | private: |
104 | typedef enum{ | |
105 | kMinImpactParamR = 0, | |
106 | kMaxImpactParamR = 1, | |
107 | kMinImpactParamZ = 2, | |
108 | kMaxImpactParamZ = 3, | |
109 | kClusterRatioTPC = 4, | |
110 | kMinTrackletsTRD = 5, | |
111 | kPixelITS = 6, | |
3a72645a | 112 | kMinHFEImpactParamR = 7, |
113 | kMinHFEImpactParamNsigmaR = 8, | |
114 | kMinNClustersTPC = 9, | |
115 | kNcuts = 10 | |
809a4336 | 116 | } Cut_t; |
117 | enum{ | |
118 | // | |
119 | // Common Constants | |
120 | // | |
121 | kBeforeCuts =0, | |
122 | kAfterCuts = 1 | |
123 | }; | |
e3ae862b | 124 | AliVEvent *fEvent; //! working event |
125 | ULong64_t fCutCorrelation; // Cut Correlation | |
126 | ULong64_t fRequirements; // Cut Requirements | |
127 | Float_t fImpactParamCut[4]; // Impact Parmameter Cut | |
128 | UInt_t fMinNClustersTPC; // Minimum TPC clusters cut | |
129 | Float_t fClusterRatioTPC; // Ratio of findable vs. found clusters in TPC | |
130 | UChar_t fMinTrackletsTRD; // Min. Number of Tracklets inside TRD | |
131 | UChar_t fPixelITS; // Cut on ITS Pixels | |
132 | Bool_t fTOFpid; // TOF pid | |
133 | UChar_t fTPCclusterDef; // TPC cluster definition Bitmap | |
134 | UChar_t fTPCclusterRatioDef; // TPC cluster ratio definition Bitmap | |
75d81601 | 135 | |
136 | Bool_t fCheck; // check | |
809a4336 | 137 | TList *fQAlist; //! Directory for QA histograms |
70da6c5a | 138 | Int_t fDebugLevel; // Debug Level |
dbe3abbe | 139 | |
809a4336 | 140 | ClassDef(AliHFEextraCuts, 1) // Additional cuts implemented by the ALICE HFE group |
141 | }; | |
142 | ||
143 | //__________________________________________________________ | |
e3ae862b | 144 | void AliHFEextraCuts::SetClusterRatioTPC(Double_t ratio, ETPCclrDef_t def) { |
809a4336 | 145 | SETBIT(fRequirements, kClusterRatioTPC); |
e3ae862b | 146 | SETBIT(fTPCclusterRatioDef, def); |
809a4336 | 147 | fClusterRatioTPC = ratio; |
148 | } | |
149 | ||
150 | //__________________________________________________________ | |
151 | void AliHFEextraCuts::SetRequireITSpixel(ITSPixel_t pixel) { | |
152 | SETBIT(fRequirements, kPixelITS); | |
153 | fPixelITS = pixel; | |
154 | } | |
155 | ||
156 | //__________________________________________________________ | |
157 | void AliHFEextraCuts::SetMinImpactParamR(Double_t impactParam){ | |
158 | SETBIT(fRequirements, kMinImpactParamR); | |
159 | fImpactParamCut[0] = impactParam; | |
160 | } | |
161 | ||
162 | //__________________________________________________________ | |
163 | void AliHFEextraCuts::SetMaxImpactParamR(Double_t impactParam){ | |
164 | SETBIT(fRequirements, kMaxImpactParamR); | |
75d81601 | 165 | fImpactParamCut[2] = impactParam; |
809a4336 | 166 | } |
167 | ||
168 | //__________________________________________________________ | |
169 | void AliHFEextraCuts::SetMinImpactParamZ(Double_t impactParam){ | |
170 | SETBIT(fRequirements, kMinImpactParamZ); | |
75d81601 | 171 | fImpactParamCut[1] = impactParam; |
809a4336 | 172 | } |
173 | ||
174 | //__________________________________________________________ | |
175 | void AliHFEextraCuts::SetMaxImpactParamZ(Double_t impactParam){ | |
176 | SETBIT(fRequirements, kMaxImpactParamZ); | |
177 | fImpactParamCut[3] = impactParam; | |
178 | } | |
179 | ||
3a72645a | 180 | //__________________________________________________________ |
181 | void AliHFEextraCuts::SetMinHFEImpactParamR(){ | |
182 | SETBIT(fRequirements, kMinHFEImpactParamR); | |
183 | } | |
184 | ||
185 | //__________________________________________________________ | |
186 | void AliHFEextraCuts::SetMinHFEImpactParamNsigmaR(){ | |
187 | SETBIT(fRequirements, kMinHFEImpactParamNsigmaR); | |
188 | } | |
189 | ||
809a4336 | 190 | //__________________________________________________________ |
191 | void AliHFEextraCuts::SetMinTrackletsTRD(Int_t minTracklets){ | |
192 | SETBIT(fRequirements, kMinTrackletsTRD); | |
193 | fMinTrackletsTRD = minTracklets; | |
194 | } | |
3a72645a | 195 | |
196 | //__________________________________________________________ | |
e3ae862b | 197 | void AliHFEextraCuts::SetMinNClustersTPC(Int_t minClusters, ETPCclusterDef_t tpcdef){ |
3a72645a | 198 | SETBIT(fRequirements, kMinNClustersTPC); |
e3ae862b | 199 | SETBIT(fTPCclusterDef, tpcdef); |
3a72645a | 200 | fMinNClustersTPC = minClusters; |
201 | } | |
809a4336 | 202 | #endif |