subtract background if requested
[u/mrichter/AliRoot.git] / PWG4 / CaloCalib / AliAnalysisTaskEMCALClusterizeFast.h
CommitLineData
2f7259cf 1#ifndef ALIANALYSISTASKEMCALCLUSTERIZEFAST_H
2#define ALIANALYSISTASKEMCALCLUSTERIZEFAST_H
3
4// $Id$
5
6class TObjArray;
7class TClonesArray;
8class AliAODEvent;
9class AliESDEvent;
10class AliEMCALCalibData;
11class AliCaloCalibPedestal;
12class AliEMCALClusterizer;
13class AliEMCALAfterBurnerUF;
14class AliEMCALRecParam;
15class AliEMCALRecoUtils;
16
17#include "AliAnalysisTaskSE.h"
18
19class AliAnalysisTaskEMCALClusterizeFast : public AliAnalysisTaskSE {
20 public:
2431b20f 21 AliAnalysisTaskEMCALClusterizeFast();
22 AliAnalysisTaskEMCALClusterizeFast(const char *name);
2f7259cf 23 virtual ~AliAnalysisTaskEMCALClusterizeFast();
24
25 public:
26 virtual void UserCreateOutputObjects();
27 virtual void UserExec(Option_t *option);
28
dc503ae1 29 Bool_t GetAttachClusters() const { return fAttachClusters ; }
b0e354fe 30 Bool_t GetRecalibrateOnly() const { return fRecalibOnly ; }
95f69c66 31 Bool_t GetSubBackground() const { return fSubBackground ; }
2f7259cf 32 const TObjArray *GetClusters() const { return fClusterArr ; }
33 const TString &GeometryName() const { return fGeomName ; }
34 AliEMCALRecParam *GetRecParam() const { return fRecParam ; }
35 AliEMCALRecoUtils *GetRecoUtils() const { return fRecoUtils ; }
dc503ae1 36 AliEMCALCalibData *GetCalibData() const { return fCalibData ; }
37 AliCaloCalibPedestal *GetPedData() const { return fPedestalData ; }
94019119 38 TGeoHMatrix *GetGeometryMatrix(Int_t i) const { return fGeomMatrix[i] ; }
2f7259cf 39 void JustUnfold(Bool_t yesno) { fJustUnfold = yesno ; }
40 void LoadOwnGeometryMatrices(Bool_t b) { fLoadGeomMatrices = b ; }
41 void SetAODBranchName(const char *name) { fOutputAODBrName = name ; }
4cf9204b 42 void SetAttachClusters(Bool_t b) { fAttachClusters = b ; }
2f7259cf 43 void SetCalibData(AliEMCALCalibData *d) { fCalibData = d ; }
44 void SetEMCALRecoUtils(AliEMCALRecoUtils *ru) { fRecoUtils = ru ; }
45 void SetGeometryMatrix(TGeoHMatrix* m, Int_t i) { fGeomMatrix[i] = m ; }
46 void SetGeometryName(const char *name) { fGeomName = name ; }
10d33986 47 void SetLoadCalib(Bool_t b) { fLoadCalib = b ; }
48 void SetLoadPed(Bool_t b) { fLoadPed = b ; }
4cf9204b 49 void SetOCDBPath(const char *path) { fOCDBpath = path ; }
50 void SetPedestalData(AliCaloCalibPedestal *d) { fPedestalData = d ; }
b0e354fe 51 void SetRecalibrateCellsOnly(Bool_t b) { fRecalibOnly = b ; }
95f69c66 52 void SetSubBackground(Bool_t b) { fSubBackground = b ; }
2f7259cf 53
54 private:
55 AliAnalysisTaskEMCALClusterizeFast(const AliAnalysisTaskEMCALClusterizeFast&); // not implemented
56 AliAnalysisTaskEMCALClusterizeFast &operator=(const AliAnalysisTaskEMCALClusterizeFast&); // not implemented
57
95f69c66 58 void Clusterize();
59 void FillDigitsArray();
2f7259cf 60 void Init();
95f69c66 61 void RecPoints2Clusters(TClonesArray *clus);
62 void SubBackground();
63 void UpdateCells();
64 void UpdateClusters();
2f7259cf 65
66 Int_t fRun; //!run number
67 TClonesArray *fDigitsArr; //!digits array
68 TObjArray *fClusterArr; //!recpoints array
69 AliEMCALRecParam *fRecParam; // reconstruction parameters container
70 AliEMCALClusterizer *fClusterizer; //!clusterizer
71 AliEMCALAfterBurnerUF *fUnfolder; //!unfolding procedure
72 Bool_t fJustUnfold; // just unfold, do not recluster
73 TString fGeomName; // name of geometry to use.
74 Bool_t fGeomMatrixSet; // set geometry matrices only once, for the first event.
75 Bool_t fLoadGeomMatrices; // matrices from configuration, not geometry.root nor ESDs/AODs
94019119 76 TGeoHMatrix *fGeomMatrix[12]; // geometry matrices with alignments
2f7259cf 77 TString fOCDBpath; // path with OCDB location
78 AliEMCALCalibData *fCalibData; // EMCAL calib data
79 AliCaloCalibPedestal *fPedestalData; // EMCAL pedestal
80 TClonesArray *fOutputAODBranch; //!AOD Branch with output clusters
81 TString fOutputAODBrName; // output AOD branch name (none by default)
82 AliEMCALRecoUtils *fRecoUtils; // access to factorized reconstruction algorithms
10d33986 83 Bool_t fLoadCalib; // access calib object from OCDB (def=off)
84 Bool_t fLoadPed; // access ped object from OCDB (def=off)
4cf9204b 85 Bool_t fAttachClusters; // attach clusters to input event (AOD or ESD)
b0e354fe 86 Bool_t fRecalibOnly; // only recalibrate cells if true (def=off)
95f69c66 87 Bool_t fSubBackground; // subtract background if true (def=off)
10d33986 88
95f69c66 89 ClassDef(AliAnalysisTaskEMCALClusterizeFast, 5);
2f7259cf 90};
91#endif //ALIANALYSISTASKEMCALCLUSTERIZEFAST_H