From: gconesab Date: Wed, 14 Apr 2010 09:29:31 +0000 (+0000) Subject: Allow to reject clusters with less than n cells X-Git-Url: http://git.uio.no/git/?p=u%2Fmrichter%2FAliRoot.git;a=commitdiff_plain;h=2ac125bf8343a6d3e5ff5b25215dd8e0d41f478c Allow to reject clusters with less than n cells --- diff --git a/PWG4/PartCorrDep/AliAnaPhoton.cxx b/PWG4/PartCorrDep/AliAnaPhoton.cxx index ddb102a708d..30d46fe551e 100755 --- a/PWG4/PartCorrDep/AliAnaPhoton.cxx +++ b/PWG4/PartCorrDep/AliAnaPhoton.cxx @@ -48,7 +48,7 @@ ClassImp(AliAnaPhoton) AliAnaPartCorrBaseClass(), fCalorimeter(""), fMinDist(0.),fMinDist2(0.),fMinDist3(0.),fRejectTrackMatch(0), fCheckConversion(kFALSE),fAddConvertedPairsToAOD(kFALSE), fMassCut(0), - fTimeCutMin(-1), fTimeCutMax(9999999), + fTimeCutMin(-1), fTimeCutMax(9999999), fNCellsCut(0), fhPtPhoton(0),fhPhiPhoton(0),fhEtaPhoton(0), //MC fhDeltaE(0), fhDeltaPt(0),fhRatioE(0), fhRatioPt(0),fh2E(0),fh2Pt(0), @@ -74,7 +74,7 @@ AliAnaPhoton::AliAnaPhoton(const AliAnaPhoton & g) : fMinDist(g.fMinDist),fMinDist2(g.fMinDist2), fMinDist3(g.fMinDist3), fRejectTrackMatch(g.fRejectTrackMatch), fCheckConversion(g.fCheckConversion),fAddConvertedPairsToAOD(g.fAddConvertedPairsToAOD), - fMassCut(g.fMassCut), fTimeCutMin(g.fTimeCutMin), fTimeCutMax(g.fTimeCutMax), + fMassCut(g.fMassCut), fTimeCutMin(g.fTimeCutMin), fTimeCutMax(g.fTimeCutMax), fNCellsCut(g.fNCellsCut), fhPtPhoton(g.fhPtPhoton),fhPhiPhoton(g.fhPhiPhoton),fhEtaPhoton(g.fhEtaPhoton), //MC fhDeltaE(g.fhDeltaE), fhDeltaPt(g.fhDeltaPt), @@ -109,7 +109,8 @@ AliAnaPhoton & AliAnaPhoton::operator = (const AliAnaPhoton & g) fTimeCutMin = g.fTimeCutMin; fTimeCutMax = g.fTimeCutMax; - + fNCellsCut = g.fNCellsCut; + fRejectTrackMatch = g.fRejectTrackMatch; fCheckConversion = g.fCheckConversion; fAddConvertedPairsToAOD = g.fAddConvertedPairsToAOD; @@ -429,7 +430,8 @@ void AliAnaPhoton::InitParameters() fTimeCutMin = -1; fTimeCutMax = 9999999; - + fNCellsCut = 0; + fRejectTrackMatch = kTRUE ; fCheckConversion = kFALSE; fAddConvertedPairsToAOD = kFALSE; @@ -483,8 +485,11 @@ void AliAnaPhoton::MakeAnalysisFillAOD() //If too small or big pt, skip it if(mom.Pt() < GetMinPt() || mom.Pt() > GetMaxPt() ) continue ; Double_t tof = calo->GetTOF()*1e9; + if(tof < fTimeCutMin || tof > fTimeCutMax) continue; - + + if(calo->GetNCells() <= fNCellsCut) continue; + //printf("AliAnaPhoton::Current Event %d; Current File Name : %s, E %f, pT %f, Ecl %f\n",GetReader()->GetEventNumber(),(GetReader()->GetCurrentFileName()).Data(), mom.E(), mom.Pt(),calo->E()); //Check acceptance selection @@ -855,7 +860,7 @@ void AliAnaPhoton::Print(const Option_t * opt) const printf("Add conversion pair to AOD = %d\n",fAddConvertedPairsToAOD); printf("Conversion pair mass cut = %f\n",fMassCut); printf("Time Cut: %3.1f < TOF < %3.1f\n", fTimeCutMin, fTimeCutMax); - + printf("Number of cells in cluster is > %d \n", fNCellsCut); printf(" \n") ; } diff --git a/PWG4/PartCorrDep/AliAnaPhoton.h b/PWG4/PartCorrDep/AliAnaPhoton.h index 6eb7c516982..91280ac2c85 100755 --- a/PWG4/PartCorrDep/AliAnaPhoton.h +++ b/PWG4/PartCorrDep/AliAnaPhoton.h @@ -76,6 +76,10 @@ public: Double_t GetTimeCutMin() const {return fTimeCutMin;} Double_t GetTimeCutMax() const {return fTimeCutMax;} + void SetNCellCut(Int_t n) {fNCellsCut = n;} + Double_t GetNCellCut() const {return fNCellsCut;} + + private: TString fCalorimeter ; // Calorimeter where the gamma is searched; @@ -88,7 +92,8 @@ public: Float_t fMassCut; // Mass cut for the conversion pairs selection Double_t fTimeCutMin ; // Remove clusters/cells with time smaller than this value, in ns Double_t fTimeCutMax ; // Remove clusters/cells with time larger than this value, in ns - + Int_t fNCellsCut ; // Accept for the analysis clusters with more than fNCellsCut cells + //Histograms TH1F * fhPtPhoton ; //! Number of identified photon vs transerse momentum TH2F * fhPhiPhoton ; //! Azimuthal angle of identified photon vs transerse momentum @@ -134,7 +139,7 @@ public: TH2F * fhPhiUnknown; //! Phi of identified Unknown gamma TH2F * fhEtaUnknown; //! eta of identified Unknown gamma - ClassDef(AliAnaPhoton,7) + ClassDef(AliAnaPhoton,8) } ;