]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWG/CaloTrackCorrBase/AliCaloTrackReader.h
AddTask added
[u/mrichter/AliRoot.git] / PWG / CaloTrackCorrBase / AliCaloTrackReader.h
1 #ifndef ALICALOTRACKREADER_H
2 #define ALICALOTRACKREADER_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4  * See cxx source for full Copyright notice     */
5
6 //_________________________________________________________________________
7 // Base class for reading data: MonteCarlo, ESD or AOD, of PHOS EMCAL and 
8 // Central Barrel Tracking detectors.
9 // Not all MC particles/tracks/clusters are kept, some kinematical restrictions are done.
10 // Mother class of : AliCaloTrackESDReader: Fills ESD data in 3 TObjArrays (PHOS, EMCAL, CTS)
11 //                 : AliCaloTrackMCReader : Fills Kinematics data in 3 TObjArrays (PHOS, EMCAL, CTS)
12 //                 : AliCaloTrackAODReader: Fills AOD data in 3 TObjArrays (PHOS, EMCAL, CTS)   
13 // -- Author: Gustavo Conesa (INFN-LNF)
14 //////////////////////////////////////////////////////////////////////////////
15
16 // --- ROOT system ---
17 #include <TObject.h> 
18 #include <TString.h>
19 class TObjArray ; 
20 class TTree ;
21 class TArrayI ;
22
23 //--- ANALYSIS system ---
24 #include "AliVEvent.h"
25 class AliVCaloCells;
26 class AliStack; 
27 class AliHeader; 
28 class AliGenEventHeader; 
29 class AliAODEvent;
30 class AliMCEvent;
31 class AliMixedEvent;
32 class AliAODMCHeader;
33 class AliESDtrackCuts;
34 class AliCentrality;
35 class AliTriggerAnalysis;
36 class AliEventplane;
37 class AliVCluster;
38
39 // --- CaloTrackCorr / EMCAL ---
40 #include "AliFiducialCut.h"
41 class AliEMCALRecoUtils;
42 class AliCalorimeterUtils;
43
44 class AliCaloTrackReader : public TObject {
45
46 public: 
47   
48   AliCaloTrackReader() ;          // ctor
49   virtual ~AliCaloTrackReader() ; // virtual dtor
50   
51   //--------------------------------
52   // General methods
53   //--------------------------------
54
55   virtual void    Init();
56     
57   virtual void    InitParameters();
58   
59   virtual void    Print(const Option_t * opt) const;
60   
61   virtual void    ResetLists();
62
63   virtual Int_t   GetDebug()                         const { return fDebug                 ; }
64   virtual void    SetDebug(Int_t d)                        { fDebug = d                    ; }
65   
66   enum inputDataType {kESD, kAOD, kMC};
67   virtual Int_t   GetDataType()                      const { return fDataType              ; }
68   virtual void    SetDataType(Int_t data )                 { fDataType = data              ; }
69
70   virtual Int_t   GetEventNumber()                   const { return fEventNumber           ; }
71         
72   TString         GetTaskName()                      const { return fTaskName              ; }
73   void            SetTaskName(TString name)                { fTaskName = name              ; }
74     
75   //---------------------------------------
76   //Input/output event setters and getters
77   //---------------------------------------
78   virtual void    SetInputEvent(AliVEvent* const input) ;
79   virtual void    SetOutputEvent(AliAODEvent* const aod)   { fOutputEvent = aod            ; }
80   virtual void    SetMC(AliMCEvent* const mc)              { fMC          = mc             ; }
81   virtual void    SetInputOutputMCEvent(AliVEvent* /*esd*/, AliAODEvent* /*aod*/, AliMCEvent* /*mc*/) { ; }
82   
83   // Delta AODs
84   virtual TList * GetAODBranchList()                 const { return fAODBranchList         ; }
85   void            SetDeltaAODFileName(TString name )       { fDeltaAODFileName = name      ; }
86   TString         GetDeltaAODFileName()              const { return fDeltaAODFileName      ; }
87   void            SwitchOnWriteDeltaAOD()                  { fWriteOutputDeltaAOD = kTRUE  ; }
88   void            SwitchOffWriteDeltaAOD()                 { fWriteOutputDeltaAOD = kFALSE ; }
89   Bool_t          WriteDeltaAODToFile()              const { return fWriteOutputDeltaAOD   ; } 
90   
91   //------------------------------------------------------------
92   //Clusters/Tracks arrays filtering/filling methods and switchs 
93   //------------------------------------------------------------
94   
95   //Minimum pt setters and getters 
96   Float_t          GetEMCALPtMin()                   const { return fEMCALPtMin            ; }
97   Float_t          GetPHOSPtMin()                    const { return fPHOSPtMin             ; }
98   Float_t          GetCTSPtMin()                     const { return fCTSPtMin              ; }
99   Float_t          GetEMCALPtMax()                   const { return fEMCALPtMax            ; }
100   Float_t          GetPHOSPtMax()                    const { return fPHOSPtMax             ; }
101   Float_t          GetCTSPtMax()                     const { return fCTSPtMax              ; }
102   
103   void             SetEMCALPtMin(Float_t  pt)              { fEMCALPtMin = pt              ; }
104   void             SetPHOSPtMin (Float_t  pt)              { fPHOSPtMin  = pt              ; }
105   void             SetCTSPtMin  (Float_t  pt)              { fCTSPtMin   = pt              ; }  
106   
107   void             SetEMCALPtMax(Float_t  pt)              { fEMCALPtMax = pt              ; }
108   void             SetPHOSPtMax (Float_t  pt)              { fPHOSPtMax  = pt              ; }
109   void             SetCTSPtMax  (Float_t  pt)              { fCTSPtMax   = pt              ; }  
110    
111   Float_t          GetEMCALEMin()                    const { return GetEMCALPtMin()        ; }
112   Float_t          GetPHOSEMin()                     const { return GetPHOSPtMin()         ; }
113   Float_t          GetEMCALEMax()                    const { return GetEMCALPtMax()        ; }
114   Float_t          GetPHOSEMax()                     const { return GetPHOSPtMax()         ; }
115   
116   void             SetEMCALEMin (Float_t  e)               { SetEMCALPtMin(e)              ; }
117   void             SetPHOSEMin  (Float_t  e)               { SetPHOSPtMin (e)              ; }
118   void             SetEMCALEMax (Float_t  e)               { SetEMCALPtMax(e)              ; }
119   void             SetPHOSEMax  (Float_t  e)               { SetPHOSPtMax (e)              ; }
120   
121   Double_t         GetEMCALTimeCutMin()              const { return fEMCALTimeCutMin        ; }
122   Double_t         GetEMCALTimeCutMax()              const { return fEMCALTimeCutMax        ; } 
123
124   void             SetEMCALTimeCut(Double_t a, Double_t b) { fEMCALTimeCutMin = a; 
125                                                              fEMCALTimeCutMax = b          ; } // ns
126   // Fidutial cuts  
127   virtual AliFiducialCut * GetFiducialCut()                { 
128                     if(!fFiducialCut) fFiducialCut = new AliFiducialCut(); 
129                     return  fFiducialCut                                                   ; }
130   virtual void     SetFiducialCut(AliFiducialCut * const fc) { fFiducialCut = fc           ; }
131   virtual Bool_t   IsFiducialCutOn()                 const { return fCheckFidCut           ; }
132   virtual void     SwitchOnFiducialCut()                   { fCheckFidCut = kTRUE          ; 
133                                                              fFiducialCut = new AliFiducialCut() ; }
134   virtual void     SwitchOffFiducialCut()                  { fCheckFidCut = kFALSE         ; }
135   
136   // Cluster origin
137   Bool_t           IsEMCALCluster(AliVCluster *clus) const;
138   Bool_t           IsPHOSCluster (AliVCluster *clus) const;
139   //Patch for cluster origin for Old AODs implementation
140   void             SwitchOnOldAODs()                       { fOldAOD = kTRUE               ; }
141   void             SwitchOffOldAODs()                      { fOldAOD = kFALSE              ; }
142   
143   // Cluster/track/cells switchs
144   Bool_t           IsCTSSwitchedOn()                 const { return fFillCTS               ; }
145   void             SwitchOnCTS()                           { fFillCTS = kTRUE              ; }
146   void             SwitchOffCTS()                          { fFillCTS = kFALSE             ; }
147
148   Bool_t           IsEMCALSwitchedOn()               const { return fFillEMCAL             ; }
149   void             SwitchOnEMCAL()                         { fFillEMCAL = kTRUE            ; }
150   void             SwitchOffEMCAL()                        { fFillEMCAL = kFALSE           ; }
151
152   Bool_t           IsPHOSSwitchedOn()                const { return fFillPHOS              ; }
153   void             SwitchOnPHOS()                          { fFillPHOS = kTRUE             ; }
154   void             SwitchOffPHOS()                         { fFillPHOS = kFALSE            ; }
155
156   Bool_t           IsEMCALCellsSwitchedOn()          const { return fFillEMCALCells        ; }
157   void             SwitchOnEMCALCells()                    { fFillEMCALCells = kTRUE       ; }
158   void             SwitchOffEMCALCells()                   { fFillEMCALCells = kFALSE      ; }
159
160   Bool_t           IsPHOSCellsSwitchedOn()           const { return fFillPHOSCells         ; }
161   void             SwitchOnPHOSCells()                     { fFillPHOSCells = kTRUE        ; }
162   void             SwitchOffPHOSCells()                    { fFillPHOSCells = kFALSE       ; }
163
164   Bool_t           AreClustersRecalculated()         const { return fRecalculateClusters   ; }
165   void             SwitchOnClusterRecalculation()          { fRecalculateClusters = kTRUE  ; }
166   void             SwitchOffClusterRecalculation()         { fRecalculateClusters = kFALSE ; }  
167   
168   Bool_t           IsEmbeddedClusterSelectionOn()    const { return fSelectEmbeddedClusters   ; }
169   void             SwitchOnEmbeddedClustersSelection()     { fSelectEmbeddedClusters = kTRUE  ; }
170   void             SwitchOffEmbeddedClustersSelection()    { fSelectEmbeddedClusters = kFALSE ; }
171   
172   // Filling/ filtering / detector information access methods
173   virtual Bool_t   FillInputEvent(const Int_t iEntry, const char *currentFileName)  ;
174   virtual void     FillInputCTS() ;
175   virtual void     FillInputEMCAL() ;
176   virtual void     FillInputEMCALAlgorithm(AliVCluster * clus, const Int_t iclus) ;
177   virtual void     FillInputPHOS() ;
178   virtual void     FillInputEMCALCells() ;
179   virtual void     FillInputPHOSCells() ;
180   virtual void     FillInputVZERO() ;  
181   
182   Int_t            GetV0Signal(Int_t i)              const { return fV0ADC[i]               ; }
183   Int_t            GetV0Multiplicity(Int_t i)        const { return fV0Mul[i]               ; }
184   
185   void             SetEMCALClusterListName(TString &name)  { fEMCALClustersListName = name  ; }
186   TString          GetEMCALClusterListName()         const { return fEMCALClustersListName  ; }
187
188   // Arrayes with clusters/track/cells access method
189   virtual TObjArray*     GetCTSTracks()              const { return fCTSTracks              ; }
190   virtual TObjArray*     GetEMCALClusters()          const { return fEMCALClusters          ; }
191   virtual TObjArray*     GetPHOSClusters()           const { return fPHOSClusters           ; }
192   virtual AliVCaloCells* GetEMCALCells()             const { return fEMCALCells             ; }
193   virtual AliVCaloCells* GetPHOSCells()              const { return fPHOSCells              ; }
194    
195   //-------------------------------------
196   // Event/track selection methods
197   //-------------------------------------
198   
199   void             AcceptFastClusterEvents()               { fAcceptFastCluster     = kTRUE  ; } 
200   void             RejectFastClusterEvents()               { fAcceptFastCluster     = kFALSE ; }  
201   Bool_t           IsFastClusterAccepted()           const { return fAcceptFastCluster       ; }   
202   
203   void             SwitchOnLEDEventsRemoval()              { fRemoveLEDEvents       = kTRUE  ; }
204   void             SwitchOffLEDEventsRemoval()             { fRemoveLEDEvents       = kFALSE ; } 
205   Bool_t           IsLEDEventRemoved()               const { return fRemoveLEDEvents         ; }   
206
207   void             SetFiredTriggerClassName(TString name ) { fFiredTriggerClassName = name   ; }
208   TString          GetFiredTriggerClassName()        const { return fFiredTriggerClassName   ; }
209   TString          GetFiredTriggerClasses() ;               
210   
211   UInt_t           GetEventTriggerMask()             const { return fEventTriggerMask        ; }
212   void             SetEventTriggerMaks(UInt_t evtTrig = AliVEvent::kAny) 
213                                                            { fEventTriggerMask = evtTrig     ; }
214
215   UInt_t           GetMixEventTriggerMask()             const { return fMixEventTriggerMask  ; }
216   void             SetMixEventTriggerMaks(UInt_t evtTrig = AliVEvent::kAnyINT) 
217                                                            { fMixEventTriggerMask = evtTrig  ; }
218   
219   
220   Bool_t           IsEventTriggerAtSEOn()            const { return fEventTriggerAtSE        ; }
221   void             SwitchOnEventTriggerAtSE()              { fEventTriggerAtSE      = kTRUE  ; }
222   void             SwitchOffEventTriggerAtSE()             { fEventTriggerAtSE      = kFALSE ; }
223   
224   void             SwitchOnEventSelection()                { fDoEventSelection      = kTRUE  ; }
225   void             SwitchOffEventSelection()               { fDoEventSelection      = kFALSE ; }
226   Bool_t           IsEventSelectionDone()            const { return fDoEventSelection        ; } 
227   
228   void             SwitchOnV0ANDSelection()                { fDoV0ANDEventSelection = kTRUE  ; }
229   void             SwitchOffV0ANDSelection()               { fDoV0ANDEventSelection = kFALSE ; }
230   Bool_t           IsV0ANDEventSelectionDone()       const { return fDoV0ANDEventSelection   ; } 
231
232   void             SwitchOnPrimaryVertexSelection()        { fUseEventsWithPrimaryVertex = kTRUE  ; }
233   void             SwitchOffPrimaryVertexSelection()       { fUseEventsWithPrimaryVertex = kFALSE ; }
234   Bool_t           IsPrimaryVertexSelectionDone()    const { return fUseEventsWithPrimaryVertex   ; } 
235   
236   // Track selection
237   ULong_t          GetTrackStatus()                  const { return fTrackStatus       ; }
238   void             SetTrackStatus(ULong_t bit)             { fTrackStatus = bit        ; }              
239
240   ULong_t          GetTrackFilterMask()              const {return fTrackFilterMask    ; }
241   void             SetTrackFilterMask(ULong_t bit)         { fTrackFilterMask = bit    ; }              
242   
243   AliESDtrackCuts* GetTrackCuts()                    const { return fESDtrackCuts      ; }
244   void             SetTrackCuts(AliESDtrackCuts * cuts)    ;
245
246   void             SwitchOnConstrainTrackToVertex()        { fConstrainTrack = kTRUE   ; } 
247   void             SwitchOffConstrainTrackToVertex()       { fConstrainTrack = kFALSE  ; }      
248   
249   void             SwitchOnAODHybridTrackSelection()       { fSelectHybridTracks = kTRUE  ; } 
250   void             SwitchOffAODHybridTrackSelection()      { fSelectHybridTracks = kFALSE ; }      
251   
252   Int_t            GetTrackMultiplicity()            const { return fTrackMult         ; }
253   Float_t          GetTrackMultiplicityEtaCut()      const { return fTrackMultEtaCut   ; }
254   void             SetTrackMultiplicityEtaCut(Float_t eta) { fTrackMultEtaCut = eta    ; }              
255   
256   // Calorimeter specific and patches
257   void             AnalyzeOnlyLED()                        { fAnaLED = kTRUE           ; }
258   void             AnalyzeOnlyPhysics()                    { fAnaLED = kFALSE          ; }
259   
260   void             SwitchOnCaloFilterPatch()               { fCaloFilterPatch = kTRUE  ; 
261                                                              fFillCTS = kFALSE         ; }
262   void             SwitchOffCaloFilterPatch()              { fCaloFilterPatch = kFALSE ; }
263   Bool_t           IsCaloFilterPatchOn()             const { 
264                     if(fDataType == kAOD) { return fCaloFilterPatch ; } 
265                     else                  { return kFALSE           ; }                  }
266         
267   //-------------------------------
268   //Vertex methods
269   //-------------------------------
270   virtual void      GetVertex(Double_t v[3])         const ;
271   virtual Double_t* GetVertex(const Int_t evtIndex)  const { return fVertex[evtIndex]            ; }
272   virtual void      GetVertex(Double_t vertex[3],    const Int_t evtIndex) const ;
273   virtual void      FillVertexArray();
274   virtual Bool_t    CheckForPrimaryVertex();
275   virtual Float_t   GetZvertexCut()                  const { return fZvtxCut                     ; } //cut on vertex position  
276   virtual void      SetZvertexCut(Float_t zcut=10.)        { fZvtxCut=zcut                       ; } //cut on vertex position
277
278   //--------------------------
279   // Centrality / Event Plane
280   //--------------------------
281   virtual AliCentrality* GetCentrality()             const { if(fDataType!=kMC) return fInputEvent->GetCentrality() ; 
282                                                              else               return 0x0       ; } 
283   virtual void     SetCentralityClass(TString name)        { fCentralityClass   = name           ; }
284   virtual void     SetCentralityOpt(Int_t opt)             { fCentralityOpt     = opt            ; }
285   virtual TString  GetCentralityClass()              const { return fCentralityClass             ; }
286   virtual Int_t    GetCentralityOpt()                const { return fCentralityOpt               ; }
287   virtual Int_t    GetEventCentrality()              const ;
288   virtual void     SetCentralityBin(Int_t min, Int_t max) //Set the centrality bin to select the event. If used, then need to get percentile
289                                                            { fCentralityBin[0]=min; fCentralityBin[1]=max;  
290                                                              if(min>=0 && max > 0) fCentralityOpt = 100 ; }
291   virtual Float_t  GetCentralityBin(Int_t i)         const { if(i < 0 || i > 1) return 0 ; 
292                                                              else return fCentralityBin[i]              ; }
293   
294   virtual AliEventplane* GetEventPlane()             const { if(fDataType!=kMC) return fInputEvent->GetEventplane() ;
295                                                              else               return 0x0       ; }  
296   virtual Double_t       GetEventPlaneAngle()        const ;          
297   virtual void           SetEventPlaneMethod(TString m)    { fEventPlaneMethod = m               ; }
298   virtual TString        GetEventPlaneMethod()       const { return fEventPlaneMethod            ; }
299
300   //--------------------
301   // Mixing
302   //--------------------
303
304   Int_t   GetLastCaloMixedEvent()                    const { return fLastMixedCaloEvent          ; }
305   Int_t   GetLastTracksMixedEvent ()                 const { return fLastMixedTracksEvent        ; }
306   
307   TList * GetListWithMixedEventsForCalo  (Int_t bi)  const { if(fListMixedCaloEvents)   return fListMixedCaloEvents[bi]     ; else return 0 ; }
308   TList * GetListWithMixedEventsForTracks(Int_t bi)  const { if(fListMixedTracksEvents) return fListMixedTracksEvents [bi]  ; else return 0 ; }  
309    
310   Bool_t  ListWithMixedEventsForCaloExists()         const { if(fListMixedCaloEvents) return kTRUE  ;
311                                                              else                     return kFALSE ; }
312
313   Bool_t  ListWithMixedEventsForTracksExists()       const { if(fListMixedTracksEvents) return kTRUE  ;
314                                                              else                       return kFALSE ; }
315   
316   void    SetLastCaloMixedEvent  (Int_t e)                 { fLastMixedCaloEvent    = e          ; }
317   void    SetLastTracksMixedEvent(Int_t e)                 { fLastMixedTracksEvent  = e          ; }
318   
319   void    SetListWithMixedEventsForCalo (TList ** l)       { 
320             if(fListMixedCaloEvents) printf("AliCaloTrackReader::SetListWithMixedEventsForCalo() - Track Mixing event list already set, nothing done\n");
321             else                        fListMixedCaloEvents    = l ; }
322   
323   void    SetListWithMixedEventsForTracks(TList ** l)      { 
324             if(fListMixedTracksEvents)  printf("AliCaloTrackReader::SetListWithMixedEventsForTracks() - Calorimeter Mixing event list already set, nothing done\n");
325             else                        fListMixedTracksEvents  = l ; }
326   
327   //-------------------------------------
328   // Other methods
329   //-------------------------------------
330   AliCalorimeterUtils * GetCaloUtils()               const { return fCaloUtils                   ; }
331   void             SetCaloUtils(AliCalorimeterUtils * caloutils)  { fCaloUtils = caloutils       ; }  
332   
333   virtual Double_t GetBField()                       const { return fInputEvent->GetMagneticField()  ; } 
334   
335   void    SetImportGeometryFromFile(Bool_t import, 
336                                     TString path = "")     { 
337                                                              fImportGeometryFromFile = import    ; 
338                                                              fImportGeometryFilePath = path      ; }      
339   
340   //------------------------------------------------
341   // MC analysis specific methods
342   //-------------------------------------------------
343   
344   //Kinematics and galice.root available 
345   virtual AliStack*          GetStack()              const ;
346   virtual AliHeader*         GetHeader()             const ;
347   virtual AliGenEventHeader* GetGenEventHeader()     const ;
348   
349   //Filtered kinematics in AOD  
350   virtual TClonesArray*     GetAODMCParticles(Int_t input = 0) const ;
351   virtual AliAODMCHeader*   GetAODMCHeader()         const ;
352         
353   virtual AliVEvent*        GetInputEvent()          const { return fInputEvent            ; }
354   virtual AliVEvent*        GetOriginalInputEvent()  const { return 0x0                    ; }
355   virtual AliAODEvent*      GetOutputEvent()         const { return fOutputEvent           ; }
356   virtual AliMCEvent*       GetMC()                  const { return fMC                    ; }
357   virtual AliMixedEvent*    GetMixedEvent()          const { return fMixedEvent            ; }
358   virtual Int_t             GetNMixedEvent()         const { return fNMixedEvent           ; } 
359   
360   void             SwitchOnStack()                         { fReadStack          = kTRUE   ; }
361   void             SwitchOffStack()                        { fReadStack          = kFALSE  ; }
362   void             SwitchOnAODMCParticles()                { fReadAODMCParticles = kTRUE   ; }
363   void             SwitchOffAODMCParticles()               { fReadAODMCParticles = kFALSE  ; }
364   Bool_t           ReadStack()                       const { return fReadStack             ; }
365   Bool_t           ReadAODMCParticles()              const { return fReadAODMCParticles    ; }
366         
367   //Select generated events, depending on comparison of pT hard and jets.
368   virtual Bool_t   ComparePtHardAndJetPt() ;
369   virtual Bool_t   IsPtHardAndJetPtComparisonSet()       const { return  fComparePtHardAndJetPt   ; }
370   virtual void     SetPtHardAndJetPtComparison(Bool_t compare) { fComparePtHardAndJetPt = compare ; }   
371   virtual Float_t  GetPtHardAndJetFactor()               const { return  fPtHardAndJetPtFactor    ; }
372   virtual void     SetPtHardAndJetPtFactor(Float_t factor)     { fPtHardAndJetPtFactor = factor   ; }           
373   
374   virtual Bool_t   ComparePtHardAndClusterPt() ;
375   virtual Bool_t   IsPtHardAndClusterPtComparisonSet()       const { return  fComparePtHardAndClusterPt   ; }
376   virtual void     SetPtHardAndClusterPtComparison(Bool_t compare) { fComparePtHardAndClusterPt = compare ; }   
377   virtual Float_t  GetPtHardAndClusterFactor()               const { return  fPtHardAndClusterPtFactor    ; }
378   virtual void     SetPtHardAndClusterPtFactor(Float_t factor)     { fPtHardAndClusterPtFactor = factor   ; }           
379   
380   
381   //MC reader methods, declared there to allow compilation, they are only used in the MC reader:
382   
383   virtual void AddNeutralParticlesArray(TArrayI & /*array*/) { ; }  
384   virtual void AddChargedParticlesArray(TArrayI & /*array*/) { ; } 
385   virtual void AddStatusArray(TArrayI & /*array*/)           { ; }
386   
387   virtual void SwitchOnPi0Decay()                            { ; } 
388   virtual void SwitchOffPi0Decay()                           { ; } 
389   virtual void SwitchOnStatusSelection()                     { ; }
390   virtual void SwitchOffStatusSelection()                    { ; }
391   virtual void SwitchOnOverlapCheck()                        { ; }
392   virtual void SwitchOffOverlapCheck()                       { ; }
393   virtual void SwitchOnOnlyGeneratorParticles()              { ; }
394   virtual void SwitchOffOnlyGeneratorParticles()             { ; }
395
396   virtual void SetEMCALOverlapAngle(Float_t /*angle*/)       { ; }
397   virtual void SetPHOSOverlapAngle(Float_t /*angle*/)        { ; }
398
399   
400  protected:
401   Int_t            fEventNumber;            // Event number
402   Int_t            fDataType ;              // Select MC:Kinematics, Data:ESD/AOD, MCData:Both
403   Int_t            fDebug;                  // Debugging level
404   AliFiducialCut * fFiducialCut;            //! Acceptance cuts
405   Bool_t           fCheckFidCut ;           // Do analysis for clusters in defined region         
406
407   Bool_t           fComparePtHardAndJetPt;  // In MonteCarlo, jet events, reject fake events with wrong jet energy.
408   Float_t          fPtHardAndJetPtFactor;   // Factor between ptHard and jet pT to reject/accept event.
409
410   Bool_t           fComparePtHardAndClusterPt;  // In MonteCarlo, jet events, reject events with too large cluster energy
411   Float_t          fPtHardAndClusterPtFactor;   // Factor between ptHard and cluster pT to reject/accept event.
412   
413   Float_t          fCTSPtMin;               // pT Threshold on charged particles 
414   Float_t          fEMCALPtMin;             // pT Threshold on emcal clusters
415   Float_t          fPHOSPtMin;              // pT Threshold on phos clusters
416   Float_t          fCTSPtMax;               // pT Threshold on charged particles 
417   Float_t          fEMCALPtMax;             // pT Threshold on emcal clusters
418   Float_t          fPHOSPtMax;              // pT Threshold on phos clusters
419   Double_t         fEMCALTimeCutMin;        // Remove clusters/cells with time smaller than this value, in ns
420   Double_t         fEMCALTimeCutMax;        // Remove clusters/cells with time larger than this value, in ns
421    
422   TList          * fAODBranchList ;         //-> List with AOD branches created and needed in analysis  
423   TObjArray      * fCTSTracks ;             //-> temporal array with tracks
424   TObjArray      * fEMCALClusters ;         //-> temporal array with EMCAL CaloClusters
425   TObjArray      * fPHOSClusters ;          //-> temporal array with PHOS  CaloClusters
426   AliVCaloCells  * fEMCALCells ;            //! temporal array with EMCAL CaloCells
427   AliVCaloCells  * fPHOSCells ;             //! temporal array with PHOS  CaloCells
428
429   AliVEvent      * fInputEvent;             //! pointer to esd or aod input
430   AliAODEvent    * fOutputEvent;            //! pointer to aod output
431   AliMCEvent     * fMC;                     //! Monte Carlo Event Handler  
432
433   Bool_t           fFillCTS;                // use data from CTS
434   Bool_t           fFillEMCAL;              // use data from EMCAL
435   Bool_t           fFillPHOS;               // use data from PHOS
436   Bool_t           fFillEMCALCells;         // use data from EMCAL
437   Bool_t           fFillPHOSCells;          // use data from PHOS
438   Bool_t           fRecalculateClusters;    // Correct clusters, recalculate them if recalibration parameters is given
439   Bool_t           fSelectEmbeddedClusters; // Use only simulated clusters that come from embedding.
440   
441   ULong_t          fTrackStatus        ;    // Track selection bit, select tracks refitted in TPC, ITS ...
442   ULong_t          fTrackFilterMask    ;    // Track selection bit, for AODs (any difference with track status?)
443   AliESDtrackCuts *fESDtrackCuts       ;    // Track cut 
444   Bool_t           fConstrainTrack     ;    // Constrain Track to vertex
445   Bool_t           fSelectHybridTracks ;    // Select CTS tracks of type hybrid (only for AODs)
446   Int_t            fTrackMult          ;    // Track multiplicity
447   Float_t          fTrackMultEtaCut    ;    // Track multiplicity eta cut
448   Bool_t           fReadStack          ;    // Access kine information from stack
449   Bool_t                 fReadAODMCParticles ;    // Access kine information from filtered AOD MC particles
450         
451   TString          fDeltaAODFileName   ;    // Delta AOD file name
452   TString          fFiredTriggerClassName;  // Name of trigger event type used to do the analysis
453
454   UInt_t           fEventTriggerMask ;      // select this triggerered event
455   UInt_t           fMixEventTriggerMask ;   // select this triggerered event for mixing, tipically kMB or kAnyINT
456   Bool_t           fEventTriggerAtSE;       // select triggered event at SE base task or here
457   
458   Bool_t           fAnaLED;                 // Analyze LED data only.
459
460   TString          fTaskName;               // Name of task that executes the analysis
461         
462   AliCalorimeterUtils * fCaloUtils ;        //  Pointer to CalorimeterUtils
463
464   AliMixedEvent  * fMixedEvent  ;           //! mixed event object. This class is not the owner
465   Int_t            fNMixedEvent ;           // number of events in mixed event buffer
466   Double_t      ** fVertex      ;           //! vertex array 3 dim for each mixed event buffer
467   
468   TList **         fListMixedTracksEvents ; //! Container for tracks stored for different events, used in case of own mixing, set in analysis class
469   TList **         fListMixedCaloEvents;    //! Container for photon stored for different events, used in case of own mixing, set in analysis class
470   Int_t            fLastMixedTracksEvent  ; //  Temporary container with the last event added to the mixing list for tracks
471   Int_t            fLastMixedCaloEvent ;    //  Temporary container with the last event added to the mixing list for photons
472   
473   Bool_t           fWriteOutputDeltaAOD;    // Write the created delta AOD objects into file  
474         Bool_t           fOldAOD;                 // Old AODs, before revision 4.20
475   
476   Int_t            fV0ADC[2]    ;           // Integrated V0 signal
477   Int_t            fV0Mul[2]    ;           // Integrated V0 Multiplicity
478
479   Bool_t           fCaloFilterPatch;        // CaloFilter patch
480   TString          fEMCALClustersListName;  // Alternative list of clusters produced elsewhere and not from InputEvent
481   
482   // Event selection
483   Float_t          fZvtxCut ;                      // Cut on vertex position
484   Bool_t           fAcceptFastCluster;           // Accept events from fast cluster, exclude these events for LHC11a
485   Bool_t           fRemoveLEDEvents;             // Remove events where LED was wrongly firing - EMCAL LHC11a
486   Bool_t           fDoEventSelection;            // Select events depending on V0, pileup, vertex well reconstructed, at least 1 track ...
487   Bool_t           fDoV0ANDEventSelection;       // Select events depending on V0, fDoEventSelection should be on
488   Bool_t           fUseEventsWithPrimaryVertex ; // Select events with primary vertex
489   AliTriggerAnalysis* fTriggerAnalysis;          // Access to trigger selection algorithm for V0AND calculation
490   
491   //Centrality/Event plane
492   TString          fCentralityClass;        // Name of selected centrality class     
493   Int_t            fCentralityOpt;          // Option for the returned value of the centrality, possible options 5, 10, 100
494   Int_t            fCentralityBin[2];       // Minimum and maximum value of the centrality for the analysis
495   TString          fEventPlaneMethod;       // Name of event plane method, by default "Q"
496   
497   Bool_t           fImportGeometryFromFile; // Import geometry settings in geometry.root file
498   TString          fImportGeometryFilePath; // path fo geometry.root file
499
500   AliCaloTrackReader(              const AliCaloTrackReader & r) ; // cpy ctor
501   AliCaloTrackReader & operator = (const AliCaloTrackReader & r) ; // cpy assignment
502   
503   ClassDef(AliCaloTrackReader,43)
504   
505 } ;
506
507
508 #endif //ALICALOTRACKREADER_H
509
510
511