AliPhysics  59e0e03 (59e0e03)
AliAnalysisTaskClusterQA.h
Go to the documentation of this file.
1 #ifndef AliAnalysisClusterQA_cxx
2 #define AliAnalysisClusterQA_cxx
3 
4 #include "AliAnalysisTaskSE.h"
6 #include "TH1.h"
7 #include "TH2.h"
8 #include "TTreeStream.h"
9 #include "AliLog.h"
10 #include <vector>
11 #include "AliV0ReaderV1.h"
12 #include "AliCaloPhotonCuts.h"
13 #include "AliConvEventCuts.h"
15 #include "AliConversionMesonCuts.h"
16 #include "TList.h"
17 #include "AliMCEvent.h"
18 #include "TClonesArray.h"
19 
20 
21 using namespace std;
22 
23 
25 
26  public:
27 
29  AliAnalysisTaskClusterQA(const char *name);
30  virtual ~AliAnalysisTaskClusterQA();
31 
32  virtual void UserCreateOutputObjects ();
33  virtual Bool_t Notify ();
34  virtual void UserExec ( Option_t *option );
35  virtual void Terminate ( Option_t * );
36 
37  void SetV0Reader ( AliV0ReaderV1 *v0Reader ) { fV0Reader=v0Reader ; }
38  void SetV0ReaderName(TString name){fV0ReaderName=name; return;}
39  void SetEventCuts ( AliConvEventCuts* conversionCuts,
40  Bool_t IsHeavyIon ) {
41  fEventCuts=conversionCuts ;
42  fIsHeavyIon = IsHeavyIon ;
43  }
44  void SetClusterCutsEMC ( AliCaloPhotonCuts* clusterCuts,
45  Bool_t IsHeavyIon ) {
46  fClusterCutsEMC=clusterCuts ;
47  fIsHeavyIon = IsHeavyIon ;
48  }
49  void SetClusterCutsDMC ( AliCaloPhotonCuts* clusterCuts,
50  Bool_t IsHeavyIon ) {
51  fClusterCutsDMC=clusterCuts ;
52  fIsHeavyIon = IsHeavyIon ;
53  }
55  Bool_t IsHeavyIon ) {
56  fMesonCuts=mesonCuts ;
57  fIsHeavyIon = IsHeavyIon ;
58  }
59 
60  void FillType ( Double_t fillTree,
61  Bool_t fillHistorams) {
62  ffillTree = fillTree ;
63  ffillHistograms = fillHistorams ;
64  }
65  void SetIsMC ( Bool_t isMC ) { fIsMC = isMC ; }
66  void SetSaveEventProperties ( Bool_t val ) { fSaveEventProperties = val ; }
67  void SetSaveClusterCells ( Bool_t val ) { fSaveCells = val ; }
68  void SetSaveSurroundingCells ( Bool_t val ) { fSaveSurroundingCells = val ; }
69  void SetNSurroundingCells ( Int_t val ) { fNSurroundingCells = val ; }
70  void SetMinMaxNLMCut ( Int_t valmin, Int_t valmax ) { fMinNLMCut = valmin ;
71  fMaxNLMCut = valmax ; }
72  void SetSaveMCInformation ( Bool_t val ) { fSaveMCInformation = val ; }
73  // Function to set correction task setting
74  void SetCorrectionTaskSetting(TString setting) {fCorrTaskSetting = setting;}
75  Int_t FindLargestCellInCluster(AliVCluster* cluster, AliVEvent* event);
76  void GetRowAndColumnFromAbsCellID(Int_t cellIndex, Int_t& row, Int_t& column);
77  Int_t MakePhotonCandidates(AliVCluster* clus, AliVCaloCells* cells, Long_t indexCluster);
78  Int_t GetMCClusterFlag(AliVCluster* clus, AliVCaloCells* cells);
79  private:
80 
81  AliAnalysisTaskClusterQA ( const AliAnalysisTaskClusterQA& ); // Prevent copy-construction
82  AliAnalysisTaskClusterQA &operator=( const AliAnalysisTaskClusterQA& ); // Prevent assignment
83 
84  void ProcessQATreeCluster ( AliVEvent *event, AliVCluster* cluster, Long_t indexCluster);
85  void ProcessQA ( AliAODConversionPhoton *gamma );
86  void RelabelAODPhotonCandidates ( Bool_t mode );
87  void ProcessTrueQAESD ( AliAODConversionPhoton *TruePhotonCandidate,
88  AliESDtrack *elec,
89  AliESDtrack *posi );
90  void ProcessTrueQAAOD ( AliAODConversionPhoton *TruePhotonCandidate,
91  AliAODTrack *elec,
92  AliAODTrack *posi );
93  Int_t ProcessTrueClusterCandidates(AliAODConversionPhoton *TrueClusterCandidate, Float_t m02,
94  AliAODConversionPhoton *TrueSubClusterCandidate1,
95  AliAODConversionPhoton *TrueSubClusterCandidate2);
96  UInt_t IsTruePhotonESD ( AliAODConversionPhoton *TruePhotonCandidate );
97  UInt_t IsTruePhotonAOD ( AliAODConversionPhoton *TruePhotonCandidate );
98  void CountTracks ();
99  void SetLogBinningXTH2 ( TH2* histoRebin );
100 
101  protected:
105  AliConversionPhotonCuts* fConversionCuts; // Cuts used by the V0Reader
106  AliConvEventCuts* fEventCuts; // Cuts used by the V0Reader
107  AliCaloPhotonCuts* fClusterCutsEMC; // Cuts used by the V0Reader
108  AliCaloPhotonCuts* fClusterCutsDMC; // Cuts used by the V0Reader
109  AliConversionMesonCuts* fMesonCuts; // Cuts used by the V0Reader
112  AliVEvent* fInputEvent; //
113  AliMCEvent* fMCEvent; //
114  Double_t fWeightJetJetMC; // weight for Jet-Jet MC
115  AliEMCALGeometry* fGeomEMCAL; // pointer to EMCAL geometry
123 
124  // Save flags
130 
131  // Option flags
132  std::vector<Float_t> fExtractionPercentages;
133  std::vector<Float_t> fExtractionPercentagePtBins;
134 
135  // Buffers that will be added to the tree
147 
153 
158 
163 
164 
166 
167 
168  ClassDef(AliAnalysisTaskClusterQA, 1);
169 };
170 
171 const Int_t kMaxActiveCells = 500;
172 
173 #endif
174 
double Double_t
Definition: External.C:58
Float_t fBuffer_ClusterPhi
! array buffer
Int_t * fBuffer_Cells_RelativeColumn
! array buffer
Float_t fBuffer_Event_Vertex_Y
! array buffer
Int_t * fBuffer_Cells_RelativeRow
! array buffer
void SetV0Reader(AliV0ReaderV1 *v0Reader)
Bool_t fSaveMCInformation
save MC information
Float_t fBuffer_ClusterE
! array buffer
Bool_t fSaveEventProperties
save general event properties (centrality etc.)
void FillType(Double_t fillTree, Bool_t fillHistorams)
Float_t fBuffer_Event_Vertex_Z
! array buffer
void SetClusterCutsDMC(AliCaloPhotonCuts *clusterCuts, Bool_t IsHeavyIon)
Bool_t fBuffer_ClusterIsEMCAL
! array buffer
Float_t fBuffer_Event_Vertex_X
! array buffer
Int_t fBuffer_LeadingCell_ID
! array buffer
Float_t fBuffer_Event_Multiplicity
! array buffer
void SetMesonCuts(AliConversionMesonCuts *mesonCuts, Bool_t IsHeavyIon)
Int_t * fBuffer_Surrounding_Cells_ID
! array buffer
Float_t * fBuffer_Surrounding_Cells_E
! array buffer
Int_t fNSurroundingCells
save MC information
int Int_t
Definition: External.C:63
Class handling all kinds of selection cuts for Gamma Calo analysis.
unsigned int UInt_t
Definition: External.C:33
float Float_t
Definition: External.C:68
Int_t fBuffer_Cluster_MC_Label
! array buffer
Int_t * fBuffer_Surrounding_Cells_RelativeRow
! array buffer
Int_t fBuffer_LeadingCell_Row
! array buffer
std::vector< Float_t > fExtractionPercentages
Percentages which will be extracted for a given pT bin.
Bool_t fSaveSurroundingCells
save arrays of all cells in event
Int_t fBuffer_LeadingCell_Column
! array buffer
Class handling all kinds of selection cuts for Gamma Conversion analysis.
Float_t fBuffer_ClusterM20
! array buffer
void SetClusterCutsEMC(AliCaloPhotonCuts *clusterCuts, Bool_t IsHeavyIon)
Int_t mode
Definition: anaM.C:41
Int_t * fBuffer_Cells_ID
! array buffer
Int_t fMaxNLMCut
save MC information
Float_t fBuffer_ClusterM02
! array buffer
void SetMinMaxNLMCut(Int_t valmin, Int_t valmax)
Int_t * fBuffer_Surrounding_Cells_RelativeColumn
! array buffer
Int_t fBuffer_Event_NumActiveCells
! array buffer
Float_t fBuffer_ClusterEta
! array buffer
AliConversionPhotonCuts * fConversionCuts
Bool_t isMC
Bool_t fSaveCells
save arrays of cluster cells
Definition: External.C:220
Class handling all kinds of selection cuts for Gamma Conversion analysis.
Int_t fBuffer_ClusterNumCells
! array buffer
void SetEventCuts(AliConvEventCuts *conversionCuts, Bool_t IsHeavyIon)
const Int_t kMaxActiveCells
void SetSaveSurroundingCells(Bool_t val)
Class handling all kinds of selection cuts for Gamma Conversion analysis.
Int_t fBuffer_MC_Cluster_Flag
! array buffer
AliConversionMesonCuts * fMesonCuts
const char Option_t
Definition: External.C:48
bool Bool_t
Definition: External.C:53
Float_t * fBuffer_Cells_E
! array buffer
Int_t fMinNLMCut
save MC information
void SetCorrectionTaskSetting(TString setting)
std::vector< Float_t > fExtractionPercentagePtBins
pT-bins associated with fExtractionPercentages