]>
Commit | Line | Data |
---|---|---|
c7ef1c47 | 1 | #ifndef ALIANALYSISTASKESDFILTER_H |
2 | #define ALIANALYSISTASKESDFILTER_H | |
3 | ||
4 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
5 | * See cxx source for full Copyright notice */ | |
6 | ||
7 | /* $Id$ */ | |
8 | ||
9 | #include <TList.h> | |
10 | #include <TF1.h> | |
11 | #include "AliAnalysisTaskSE.h" | |
12 | #include "AliESDtrack.h" | |
13 | #include "AliAODTrack.h" | |
14 | #include "AliAODPid.h" | |
15 | #include "AliESDpid.h" | |
16 | ||
17 | class AliAnalysisFilter; | |
18 | class AliStack; | |
19 | class AliESDtrack; | |
20 | class AliMCEventHandler; | |
21 | class TRefArray; | |
22 | class AliAODHeader; | |
2f5ee3b7 | 23 | class AliESDtrackCuts; |
c7ef1c47 | 24 | |
25 | class AliAnalysisTaskESDfilter : public AliAnalysisTaskSE | |
26 | { | |
27 | public: | |
28 | AliAnalysisTaskESDfilter(); | |
29 | AliAnalysisTaskESDfilter(const char* name); | |
75a996ab | 30 | virtual ~AliAnalysisTaskESDfilter(); |
c7ef1c47 | 31 | // Implementation of interface methods |
32 | virtual void UserCreateOutputObjects(); | |
33 | virtual void Init(); | |
34 | virtual void LocalInit() {Init();} | |
35 | virtual void UserExec(Option_t *option); | |
36 | virtual void Terminate(Option_t *option); | |
37 | ||
38 | virtual void ConvertESDtoAOD(); | |
39 | // Setters | |
40 | virtual void SetTrackFilter (AliAnalysisFilter* trackF) {fTrackFilter = trackF;} | |
41 | virtual void SetTPCOnlyFilterMask (UInt_t filterMask) {fTPCOnlyFilterMask = filterMask;} | |
25a60d41 | 42 | virtual void SetHybridFilterMaskITSTPC(UInt_t filterMask) {fHybridFilterMaskITSTPC = filterMask;} |
43 | virtual void SetHybridFilterMasksTPC(UInt_t filterMask0,UInt_t filterMask1) {fHybridFilterMaskTPC0 = filterMask0; | |
44 | fHybridFilterMaskTPC1 = filterMask1;} | |
c7ef1c47 | 45 | virtual void SetKinkFilter (AliAnalysisFilter* KinkF) {fKinkFilter = KinkF;} |
46 | virtual void SetV0Filter (AliAnalysisFilter* V0F) {fV0Filter = V0F;} | |
47 | virtual void SetCascadeFilter (AliAnalysisFilter* CascadeF) {fCascadeFilter = CascadeF;} | |
48 | virtual void SetPthreshold (Double_t p) {fHighPthreshold = p;} | |
49 | virtual void SetPshape (TF1 *func) {fPtshape = func;} | |
50 | virtual void SetEnableFillAOD (Bool_t b) {fEnableFillAOD = b;} | |
51 | ||
1a3579a6 | 52 | virtual void SetAODPID(AliESDtrack *esdtrack, AliAODTrack *aodtrack, AliAODPid *detpid); |
53 | void SetDetectorRawSignals(AliAODPid *aodpid, AliESDtrack *track); | |
c7ef1c47 | 54 | |
55 | void PrintTask(Option_t *option="all", Int_t indent=0) const; | |
56 | ||
57 | void DisableVZERO() { fIsVZEROEnabled = kFALSE; } | |
8c87d22c | 58 | void DisableZDC() { fIsZDCEnabled = kFALSE; } |
c7ef1c47 | 59 | void DisableCascades() { fAreCascadesEnabled = kFALSE; } |
60 | void DisableV0s() { fAreV0sEnabled = kFALSE; } | |
61 | void DisableKinks() { fAreKinksEnabled = kFALSE; } | |
62 | void DisableTracks() { fAreTracksEnabled = kFALSE; } | |
63 | void DisablePmdClusters() { fArePmdClustersEnabled = kFALSE; } | |
64 | void DisableCaloClusters() { fAreCaloClustersEnabled = kFALSE; } | |
65 | void DisableCells() { fAreEMCALCellsEnabled = fArePHOSCellsEnabled = kFALSE; } | |
66 | void DisableTracklets() { fAreTrackletsEnabled = kFALSE; } | |
67 | ||
68 | virtual void SetTimeZeroType(AliESDpid::EStartTimeType_t tofTimeZeroType) {fTimeZeroType = tofTimeZeroType;} | |
69 | ||
70 | private: | |
71 | AliAnalysisTaskESDfilter(const AliAnalysisTaskESDfilter&); | |
72 | AliAnalysisTaskESDfilter& operator=(const AliAnalysisTaskESDfilter&); | |
73 | void PrintMCInfo(AliStack *pStack,Int_t label); // for debugging | |
74 | Double_t Chi2perNDF(AliESDtrack* track); | |
75 | ||
76 | AliAODHeader* ConvertHeader(const AliESDEvent& esd); | |
77 | void ConvertCascades(const AliESDEvent& esd); | |
78 | void ConvertV0s(const AliESDEvent& esd); | |
79 | void ConvertKinks(const AliESDEvent& esd); | |
80 | void ConvertPrimaryVertices(const AliESDEvent& esd); | |
81 | void ConvertTracks(const AliESDEvent& esd); | |
82 | void ConvertPmdClusters(const AliESDEvent& esd); | |
83 | void ConvertCaloClusters(const AliESDEvent& esd); | |
84 | void ConvertEMCALCells(const AliESDEvent& esd); | |
85 | void ConvertPHOSCells(const AliESDEvent& esd); | |
86 | void ConvertTracklets(const AliESDEvent& esd); | |
87 | void ConvertTPCOnlyTracks(const AliESDEvent& esd); | |
88 | void ConvertVZERO(const AliESDEvent& esd); | |
8c87d22c | 89 | void ConvertZDC(const AliESDEvent& esd); |
c7ef1c47 | 90 | |
91 | TClonesArray& Tracks(); | |
92 | TClonesArray& V0s(); | |
93 | TClonesArray& Vertices(); | |
94 | TClonesArray& Cascades(); | |
95 | ||
96 | // Filtering | |
97 | AliAnalysisFilter* fTrackFilter; // Track Filter | |
98 | AliAnalysisFilter* fKinkFilter; // Kink Filter | |
99 | AliAnalysisFilter* fV0Filter; // V0 Filter | |
100 | AliAnalysisFilter* fCascadeFilter; // Cascade Filter | |
101 | // PID | |
102 | Double_t fHighPthreshold; // Pt threshold for detector signal setting | |
103 | TF1 * fPtshape; // Pt spectrum distribution | |
104 | Bool_t fEnableFillAOD; // value that decides if this task activates AOD filling | |
105 | Bool_t* fUsedTrack; //! indices of used tracks | |
106 | Bool_t* fUsedKink; //! indices of used kinks | |
107 | Bool_t* fUsedV0; //! indices of used V0s | |
108 | TRefArray* fAODTrackRefs; // array of track references | |
109 | TRefArray* fAODV0VtxRefs; // array of v0 vertices references | |
110 | TRefArray* fAODV0Refs ; // array of v0s references | |
111 | AliMCEventHandler* fMChandler; // pointer to MC handler (if any) | |
112 | Int_t fNumberOfTracks; // current number of tracks | |
113 | Int_t fNumberOfPositiveTracks; // current number of positive tracks | |
114 | Int_t fNumberOfV0s; // current number of v0s | |
115 | Int_t fNumberOfVertices; // current number of vertices | |
116 | Int_t fNumberOfCascades; // current number of cascades | |
117 | Int_t fNumberOfKinks; // current number of kinks | |
118 | Bool_t fOldESDformat; // is the ESD in old format ? | |
119 | AliAODVertex* fPrimaryVertex; // pointer to primary vertex of the event | |
120 | UInt_t fTPCOnlyFilterMask; // Filter Mask used to select and store refitted TPC only tracks | |
25a60d41 | 121 | UInt_t fHybridFilterMaskITSTPC; // Filter Mask used to select and store refitted TPC only tracks which have not passed ITS cuts |
122 | UInt_t fHybridFilterMaskTPC0; // Filter Mask flag refitted TPC only tracks with tight ITScuts | |
123 | UInt_t fHybridFilterMaskTPC1; // Filter Mask flag refitted TPC only tracks with lose ITScuts | |
124 | ||
c7ef1c47 | 125 | Bool_t fIsVZEROEnabled; // whether or not to fill the vzero branch (true by default) |
8c87d22c | 126 | Bool_t fIsZDCEnabled; // whether or not to fill the zdc branch (true by default) |
c7ef1c47 | 127 | Bool_t fAreCascadesEnabled; // whether or not to fill the cascades branch (true by default) |
128 | Bool_t fAreV0sEnabled; // whether or not to fill the v0 branch (true by default) | |
129 | Bool_t fAreKinksEnabled; // whether or not to fill the kinks (true by default) | |
130 | Bool_t fAreTracksEnabled; // whether or not to fill the (central) tracks branch (true by default) | |
131 | Bool_t fArePmdClustersEnabled; // whether or not to fill the pmd clusters (true by default) | |
132 | Bool_t fAreCaloClustersEnabled; // whether or not to fill the calo clusters (true by default) | |
133 | Bool_t fAreEMCALCellsEnabled; // whether or not to fill the emcal cells (true by default) | |
134 | Bool_t fArePHOSCellsEnabled; // whether or not to fill the phos cells (true by default) | |
135 | Bool_t fAreTrackletsEnabled; // whether or not to fill the tracklets (true by default) | |
136 | AliESDpid* fESDpid; // esd pid | |
137 | Bool_t fIsPidOwner; // whether we own fESDpid | |
138 | Int_t fTimeZeroType; // time zero type | |
2f5ee3b7 | 139 | AliESDtrackCuts* fTPCaloneTrackCuts; // TPC stand-alone track cuts |
c7ef1c47 | 140 | |
8c87d22c | 141 | ClassDef(AliAnalysisTaskESDfilter, 11); // Analysis task for standard ESD filtering |
c7ef1c47 | 142 | }; |
143 | ||
144 | #endif |