]>
Commit | Line | Data |
---|---|---|
1c5acb87 | 1 | #ifndef ALICALOPID_H |
2 | #define ALICALOPID_H | |
3 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
4 | * See cxx source for full Copyright notice */ | |
5 | /* $Id: $ */ | |
6 | ||
7 | //_________________________________________________________________________ | |
8 | // Class for track/cluster acceptance selection | |
9 | // Selection in Central barrel, EMCAL and PHOS | |
10 | // | |
11 | //*-- Author: Gustavo Conesa (INFN-LNF) | |
12 | ||
13 | // --- ROOT system --- | |
14 | #include <TObject.h> | |
15 | class TString ; | |
16 | class TLorentzVector ; | |
17 | class TFormula ; | |
18 | ||
19 | //--- AliRoot system --- | |
20 | class AliLog ; | |
21 | class AliAODCaloCluster; | |
22 | class AliAODPWG4Particle; | |
1c5acb87 | 23 | |
24 | class AliCaloPID : public TObject { | |
25 | ||
26 | public: | |
27 | ||
28 | AliCaloPID() ; // ctor | |
29 | AliCaloPID(const AliCaloPID & g) ; // cpy ctor | |
30 | AliCaloPID & operator = (const AliCaloPID & g) ;//cpy assignment | |
31 | virtual ~AliCaloPID() ;//virtual dtor | |
32 | ||
33 | enum PidType { | |
34 | kPhoton = 22, | |
35 | kPi0 = 111, | |
36 | kEta = 221, | |
37 | kElectron = 11, | |
38 | kEleCon = -11, | |
39 | kNeutralHadron = 2112, | |
40 | kChargedHadron = 211, | |
41 | kNeutralUnknown = 130, | |
42 | kChargedUnknown=321 | |
43 | }; | |
44 | ||
6639984f | 45 | enum TagType {kPi0Decay, kEtaDecay, kOtherDecay, kConversion, kNoTag = -1}; |
1c5acb87 | 46 | |
47 | void InitParameters(); | |
1c5acb87 | 48 | |
49 | Int_t GetPdg(const TString calo, const Double_t * pid, const Float_t energy) const ; | |
50 | ||
51 | Int_t GetPdg(const TString calo,const TLorentzVector mom, const AliAODCaloCluster * cluster) const ; | |
52 | ||
53 | TString GetPIDParametersList(); | |
54 | ||
55 | void SetPIDBits(const TString calo, const AliAODCaloCluster * cluster, AliAODPWG4Particle *aodph); | |
56 | ||
57 | void Print(const Option_t * opt)const; | |
58 | ||
59 | //Weight getters | |
60 | Float_t GetEMCALPhotonWeight() const { return fEMCALPhotonWeight ; } | |
61 | Float_t GetEMCALPi0Weight() const { return fEMCALPi0Weight ; } | |
62 | Float_t GetEMCALElectronWeight() const { return fEMCALElectronWeight ; } | |
63 | Float_t GetEMCALChargeWeight() const { return fEMCALChargeWeight ; } | |
64 | Float_t GetEMCALNeutralWeight() const { return fEMCALNeutralWeight ; } | |
65 | Float_t GetPHOSPhotonWeight() const { return fPHOSPhotonWeight ; } | |
66 | Float_t GetPHOSPi0Weight() const { return fPHOSPi0Weight ; } | |
67 | Float_t GetPHOSElectronWeight() const { return fPHOSElectronWeight ; } | |
68 | Float_t GetPHOSChargeWeight() const { return fPHOSChargeWeight ; } | |
69 | Float_t GetPHOSNeutralWeight() const { return fPHOSNeutralWeight ; } | |
70 | ||
71 | Bool_t IsPHOSPIDWeightFormulaOn() const { return fPHOSWeightFormula ; } | |
72 | TFormula * GetPHOSPhotonWeightFormula() const { return fPHOSPhotonWeightFormula ; } | |
73 | TFormula * GetPHOSPi0WeightFormula() const { return fPHOSPi0WeightFormula ; } | |
74 | ||
75 | //Weight setters | |
76 | void SetEMCALPhotonWeight(Float_t w){ fEMCALPhotonWeight = w ; } | |
77 | void SetEMCALPi0Weight(Float_t w){ fEMCALPi0Weight = w ; } | |
78 | void SetEMCALElectronWeight(Float_t w){ fEMCALElectronWeight = w ; } | |
79 | void SetEMCALChargeWeight(Float_t w){ fEMCALChargeWeight = w ; } | |
80 | void SetEMCALNeutralWeight(Float_t w){ fEMCALNeutralWeight = w ; } | |
81 | void SetPHOSPhotonWeight(Float_t w){ fPHOSPhotonWeight = w ; } | |
82 | void SetPHOSPi0Weight(Float_t w){ fPHOSPi0Weight = w ; } | |
83 | void SetPHOSElectronWeight(Float_t w){ fPHOSElectronWeight = w ; } | |
84 | void SetPHOSChargeWeight(Float_t w){ fPHOSChargeWeight = w ; } | |
85 | void SetPHOSNeutralWeight(Float_t w){ fPHOSNeutralWeight = w ; } | |
86 | ||
87 | void UsePHOSPIDWeightFormula(Bool_t par) { fPHOSWeightFormula = par; } | |
88 | void SetPHOSPhotonWeightFormula(TFormula * photon) { fPHOSPhotonWeightFormula = photon; } | |
89 | void SetPHOSPi0WeightFormula(TFormula * pi0) { fPHOSPi0WeightFormula = pi0; } | |
90 | ||
91 | //PID bits setters and getters | |
92 | void SetDispersionCut(Float_t dcut ) {fDispCut = dcut; } | |
93 | Float_t GetDispersionCut() const {return fDispCut ;} | |
94 | ||
95 | void SetTOFCut(Float_t tcut ) {fTOFCut = tcut; } | |
96 | Float_t GetTOFCut() const {return fTOFCut ;} | |
97 | ||
98 | void SetDebug(Int_t deb) {fDebug=deb;} | |
99 | Int_t GetDebug() const {return fDebug;} | |
100 | ||
101 | private: | |
102 | ||
103 | Float_t fEMCALPhotonWeight; //Bayesian PID weight for photons in EMCAL | |
104 | Float_t fEMCALPi0Weight; //Bayesian PID weight for pi0 in EMCAL | |
105 | Float_t fEMCALElectronWeight; //Bayesian PID weight for electrons in EMCAL | |
106 | Float_t fEMCALChargeWeight; //Bayesian PID weight for charged hadrons in EMCAL | |
107 | Float_t fEMCALNeutralWeight; //Bayesian PID weight for neutral hadrons in EMCAL | |
108 | Float_t fPHOSPhotonWeight; //Bayesian PID weight for photons in PHOS | |
109 | Float_t fPHOSPi0Weight; //Bayesian PID weight for pi0 in PHOS | |
110 | Float_t fPHOSElectronWeight; //Bayesian PID weight for electrons in PHOS | |
111 | Float_t fPHOSChargeWeight; //Bayesian PID weight for charged hadrons in PHOS | |
112 | Float_t fPHOSNeutralWeight; //Bayesian PID weight for neutral hadrons in PHOS | |
113 | ||
114 | Bool_t fPHOSWeightFormula ; //Use parametrized weight threshold, function of energy | |
115 | TFormula * fPHOSPhotonWeightFormula ; //Formula for photon weight | |
116 | TFormula * fPHOSPi0WeightFormula ; //Formula for pi0 weight | |
117 | ||
118 | Float_t fDispCut; //Cut on dispersion, used in PID evaluation | |
119 | Float_t fTOFCut; //Cut on TOF, used in PID evaluation | |
120 | ||
121 | Int_t fDebug; //Debug level | |
7175a03a | 122 | |
123 | ClassDef(AliCaloPID,3) | |
1c5acb87 | 124 | } ; |
125 | ||
126 | ||
127 | #endif //ALICALOPID_H | |
128 | ||
129 | ||
130 |