#ifndef ALICALOCELLSQA_H
#define ALICALOCELLSQA_H
#include <TObjArray.h>
#include <TH1D.h>
#include <TH1F.h>
#include <TH2F.h>
class AliLog;
#include <AliVCaloCells.h>
#include <AliVCluster.h>
class AliCaloCellsQA : public TObject {
public:
enum {
kEMCAL = 0,
kPHOS = 1
};
AliCaloCellsQA();
AliCaloCellsQA(Int_t nmods, Int_t det = kEMCAL, Int_t startRunNumber = 100000, Int_t endRunNumber = 200000);
virtual ~AliCaloCellsQA();
virtual void ActivateFullAnalysis();
virtual void InitSummaryHistograms(Int_t nbins = 400, Double_t emax = 4.,
Int_t nbinsh = 100, Double_t emaxh = 300.,
Int_t nbinst = 250, Double_t tmin =-0.1e-6, Double_t tmax = 0.15e-6);
virtual void InitTransientFindCurrentRun(Int_t runNumber);
virtual void Fill(Int_t runNumber, TObjArray *clusArray, AliVCaloCells *cells, Double_t vertexXYZ[3]);
virtual Int_t GetDetector() { return fDetector; }
virtual Int_t GetNMods() { return fNMods; }
virtual Double_t GetClusElowMin() { return fClusElowMin; }
virtual Double_t GetClusEhighMin() { return fClusEhighMin; }
virtual Double_t GetPi0EClusMin() { return fPi0EClusMin; }
virtual Bool_t GetFullAnalysis() { return fkFullAnalysis; }
virtual TObjArray* GetListOfHistos() { return fListOfHistos; }
virtual void SetClusterEnergyCuts(Double_t pi0EClusMin = 0.5, Double_t ElowMin = 0.3, Double_t EhighMin = 1.0);
virtual void SetBinningParameters(Int_t nbins1 = 100, Int_t nbins2 = 250, Int_t nbins3x = 200, Int_t nbins3y = 30,
Double_t xmax1 = 5., Double_t xmax2 = 0.5, Double_t xmax3 = 20.);
protected:
virtual void Init(Int_t nmods, Int_t det, Int_t startRunNumber, Int_t endRunNumber);
virtual void InitTransientMembers(Int_t run);
virtual void InitHistosForRun(Int_t run);
virtual void FillCellsInCluster(TObjArray *clusArray, AliVCaloCells *cells);
virtual void FillJustCells(AliVCaloCells *cells);
virtual void FillPi0Mass(TObjArray *clusArray, Double_t vertexXYZ[3]);
virtual Int_t CheckClusterGetSM(AliVCluster* clus);
virtual Int_t GetSM(Int_t absId);
virtual Bool_t IsCellLocalMaximum(Int_t c, AliVCluster* clus, AliVCaloCells* cells);
virtual Bool_t IsCellLocalMaximum(Int_t absId, AliVCaloCells* cells);
virtual void AbsIdToSMEtaPhi(Int_t absId, Int_t &sm, Int_t &eta, Int_t &phi);
private:
AliCaloCellsQA(const AliCaloCellsQA &);
AliCaloCellsQA & operator = (const AliCaloCellsQA &);
private:
Int_t fDetector;
Int_t fNMods;
Double_t fClusElowMin;
Double_t fClusEhighMin;
Double_t fPi0EClusMin;
Bool_t fkFullAnalysis;
Int_t fNBinsECells;
Int_t fNBinsPi0Mass;
Int_t fNBinsXNCellsInCluster;
Int_t fNBinsYNCellsInCluster;
Double_t fXMaxECells;
Double_t fXMaxPi0Mass;
Double_t fXMaxNCellsInCluster;
Int_t fRunNumbers[1000];
Int_t fNRuns;
Int_t fRI;
Int_t fAbsIdMin;
Int_t fAbsIdMax;
TObjArray *fListOfHistos;
TH1D *fhNEventsProcessedPerRun;
TH1F *fhCellLocMaxNTimesInClusterElow;
TH1F *fhCellLocMaxNTimesInClusterEhigh;
TH1F *fhCellLocMaxETotalClusterElow;
TH1F *fhCellLocMaxETotalClusterEhigh;
TH1F *fhCellNonLocMaxNTimesInClusterElow;
TH1F *fhCellNonLocMaxNTimesInClusterEhigh;
TH1F *fhCellNonLocMaxETotalClusterElow;
TH1F *fhCellNonLocMaxETotalClusterEhigh;
TH1F *fhECells[10];
TH1F *fhPi0Mass[10][10];
TH2F *fhNCellsInCluster[10];
TH2F *fhCellAmplitude;
TH2F *fhCellAmplitudeEhigh;
TH2F *fhCellAmplitudeNonLocMax;
TH2F *fhCellAmplitudeEhighNonLocMax;
TH2F *fhCellTime;
ClassDef(AliCaloCellsQA,2)
};
#endif