]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
add option of energy and nlm dependent asymmetry cut for split method
authorgconesab <gconesab@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 31 Oct 2012 14:37:20 +0000 (14:37 +0000)
committergconesab <gconesab@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 31 Oct 2012 14:37:20 +0000 (14:37 +0000)
PWG/CaloTrackCorrBase/AliCaloPID.cxx
PWG/CaloTrackCorrBase/AliCaloPID.h
PWGGA/CaloTrackCorrelations/AliAnaInsideClusterInvariantMass.cxx
PWGGA/CaloTrackCorrelations/AliAnaPi0EbE.cxx
PWGGA/CaloTrackCorrelations/AliAnaPi0EbE.h

index cd0d1df599fc1e0a5cdfd3e265ace657f7b053cc..90a4227888ee9cc4f3e0a5e243a27328b0d2e208 100755 (executable)
@@ -252,11 +252,35 @@ void AliCaloPID::InitParameters()
   fM02MinParam[3] = 0.0069;   // pol2 param2 for NLM=1 , E < 16 GeV
   fM02MinParam[4] = 0.3;      // absolute minimum in any case
   
+  fAsyMinParam[0] = 0.08 ;    // pol2 param0 for NLM=2 , E < 11 GeV
+  fAsyMinParam[1] = 0.127;    // pol2 param1 for NLM=2 , E < 11 GeV
+  fAsyMinParam[2] =-0.0049;   // pol2 param2 for NLM=2 , E < 11 GeV
+  
+  
   fSplitEFracMin   = 0.85 ;
   fSplitWidthSigma = 2.5  ;
   
 }
 
+
+//_____________________________________________________________________________________________________
+Bool_t AliCaloPID::IsInPi0SplitAsymmetryRange(const Float_t energy, const Float_t asy, const Int_t nlm)
+{
+  // Select the appropriate mass range for pi0 selection in splitting method
+  // No used yet in splitting ID decision
+  
+  Float_t abasy = TMath::Abs(asy);
+
+  // Get the parametrized min cut of asymmetry for NLM=2 up to 11 GeV
+  Float_t cut = fAsyMinParam[0]+energy*fAsyMinParam[1]+energy*energy*fAsyMinParam[2];  
+  
+  if(nlm != 2 || energy > 11 ) cut = 0.95;
+  
+  if(abasy < cut) return kTRUE;
+  else            return kFALSE;
+  
+}
+
 //_________________________________________________________________________________________________
 Bool_t AliCaloPID::IsInPi0SplitMassRange(const Float_t energy, const Float_t mass, const Int_t nlm)
 {
@@ -290,12 +314,11 @@ Bool_t AliCaloPID::IsInPi0SplitMassRange(const Float_t energy, const Float_t mas
   
   if(mass < maxMass && mass > minMass) return kTRUE;
   else                                 return kFALSE;
-
   
 }
 
 //_____________________________________________________________________________________________
-Bool_t AliCaloPID::IsInSplitM02Range(const Float_t energy, const Float_t m02,  const Int_t nlm)
+Bool_t AliCaloPID::IsInMergedM02Range(const Float_t energy, const Float_t m02,  const Int_t nlm)
 {
   // Select the appropriate m02 range in splitting method
   // Min value between 0.3 and 0.6
@@ -595,7 +618,7 @@ Int_t AliCaloPID::GetIdentifiedParticleTypeFromClusterSplitting(AliVCluster* clu
   if(fDebug > 0) printf("\t pass Split E frac cut\n");
   
   //If too small or big M02 low number of cells, skip it
-  if (!IsInSplitM02Range(eClus,m02,nMax))  return kNeutralUnknown ; 
+  if (!IsInMergedM02Range(eClus,m02,nMax))  return kNeutralUnknown ; 
   
   if(fDebug > 0) printf("\t pass M02 cut\n");
   
index afd0239b4c3ab967573b35ce4bcbd3aa11014aed..fee6f744a7f74d91c98d8cff3d9c2eb8c0a56052 100755 (executable)
@@ -73,9 +73,12 @@ class AliCaloPID : public TObject {
 
   void      InitParameters();
   
-  Bool_t    IsInPi0SplitMassRange(const Float_t energy, const Float_t mass, const Int_t nlm);
+  Bool_t    IsInPi0SplitAsymmetryRange(const Float_t energy, const Float_t asy,  const Int_t nlm);
+
+  Bool_t    IsInPi0SplitMassRange     (const Float_t energy, const Float_t mass, const Int_t nlm);
+  
+  Bool_t    IsInMergedM02Range        (const Float_t energy, const Float_t m02,  const Int_t nlm);
   
-  Bool_t    IsInSplitM02Range    (const Float_t energy, const Float_t m02,  const Int_t nlm);
   
   Int_t     GetIdentifiedParticleTypeFromBayesWeights(const Bool_t isEMCAL, const Double_t * pid, const Float_t energy) ;
 
@@ -217,8 +220,9 @@ class AliCaloPID : public TObject {
   Float_t GetPhotonMaxMass()             const { return fMassPhoMax           ; }
   
   void    SetSplitWidthSigma(Float_t s)        { fSplitWidthSigma        = s  ; }
-  void    SetPi0MassWidthSelectionParameters(Int_t iparam, Float_t param) { if(iparam < 7 ) fMassWidthPi0Param[iparam] = param ; }
-  void    SetM02MinimumSelectionParameters  (Int_t iparam, Float_t param) { if(iparam < 5 ) fM02MinParam      [iparam] = param ; }
+  void    SetPi0MassWidthSelectionParameters    (Int_t iparam, Float_t param) { if(iparam < 7 ) fMassWidthPi0Param[iparam] = param ; }
+  void    SetM02MinimumSelectionParameters      (Int_t iparam, Float_t param) { if(iparam < 5 ) fM02MinParam      [iparam] = param ; }
+  void    SetAsymmetryMinimumSelectionParameters(Int_t iparam, Float_t param) { if(iparam < 3 ) fAsyMinParam      [iparam] = param ; }
 
   void    SetPi0MassRange(Float_t min, Float_t max)    { fMassPi0Min    = min ; fMassPi0Max = max ; } // Simple case
   void    SetEtaMassRange(Float_t min, Float_t max)    { fMassEtaMin    = min ; fMassEtaMax = max ; }
@@ -280,6 +284,7 @@ private:
   Float_t   fMassPhoMax  ;                      // Min Photon mass
   Float_t   fMassWidthPi0Param[7] ;             // 3 param for pol2 fit on width, 2 param for mass position NLM=1 and NLM>1 for pi0 selection
   Float_t   fM02MinParam[5] ;                   // 3 param for pol2 fit on M02 minimum
+  Float_t   fAsyMinParam[5] ;                   // 3 param for pol2 fit on asymmetry minimum, split
   Float_t   fSplitEFracMin  ;                   // Do not use clusters with too large energy in cluster compared 
                                                 // to energy in splitted clusters
   Float_t   fSplitWidthSigma;                   // Cut on mass+-width*fSplitWidthSigma
@@ -289,7 +294,7 @@ private:
   AliCaloPID & operator = (const AliCaloPID & cpid) ; // cpy assignment
   AliCaloPID(              const AliCaloPID & cpid) ; // cpy ctor
   
-  ClassDef(AliCaloPID,14)
+  ClassDef(AliCaloPID,15)
   
 } ;
 
index 621f81a0ca2e44a80d3e3f223bca2cd8e6a4a32f..b812e5dd108f42af64f5b8af141099a8632b420e 100755 (executable)
@@ -1618,10 +1618,10 @@ void  AliAnaInsideClusterInvariantMass::MakeAnalysisFillHistograms()
       if(splitFrac > 0.85 && !matched)
       {
         fhMassSplitECutNLocMax1->Fill(en,mass ); 
-        if(GetCaloPID()->IsInSplitM02Range(en,l0,nMax))
+        if(GetCaloPID()->IsInMergedM02Range(en,l0,nMax))
         {
           fhMassM02CutNLocMax1->Fill(en,mass);
-          if(TMath::Abs(asym) < 0.8) fhMassAsyCutNLocMax1->Fill(en,mass);
+          if(GetCaloPID()->IsInPi0SplitAsymmetryRange(en,asym,nMax)) fhMassAsyCutNLocMax1->Fill(en,mass);
         }
       }
       
@@ -1644,10 +1644,10 @@ void  AliAnaInsideClusterInvariantMass::MakeAnalysisFillHistograms()
       if(splitFrac > 0.85 && !matched)
       {
         fhMassSplitECutNLocMax2->Fill(en,mass); 
-        if(GetCaloPID()->IsInSplitM02Range(en,l0,nMax))
+        if(GetCaloPID()->IsInMergedM02Range(en,l0,nMax))
         {
           fhMassM02CutNLocMax2->Fill(en,mass);
-          if(TMath::Abs(asym) < 0.8) fhMassAsyCutNLocMax2->Fill(en,mass);
+          if(GetCaloPID()->IsInPi0SplitAsymmetryRange(en,asym,nMax)) fhMassAsyCutNLocMax2->Fill(en,mass);
         }
       }
       
@@ -1670,10 +1670,10 @@ void  AliAnaInsideClusterInvariantMass::MakeAnalysisFillHistograms()
       if(splitFrac > 0.85 && !matched)
       {
         fhMassSplitECutNLocMaxN->Fill(en,mass ); 
-        if(GetCaloPID()->IsInSplitM02Range(en,l0,nMax))
+        if(GetCaloPID()->IsInMergedM02Range(en,l0,nMax))
         {
           fhMassM02CutNLocMaxN->Fill(en,mass);
-          if(TMath::Abs(asym) < 0.8) fhMassAsyCutNLocMaxN->Fill(en,mass);
+          if(GetCaloPID()->IsInPi0SplitAsymmetryRange(en,asym,nMax)) fhMassAsyCutNLocMaxN->Fill(en,mass);
         }
       }
       
index 49bae9e8fd549760b87acc02df833029b7627459..3caf727eef91fe04002092a7caba86681229e03c 100755 (executable)
@@ -51,7 +51,7 @@ AliAnaPi0EbE::AliAnaPi0EbE() :
     AliAnaCaloTrackCorrBaseClass(),fAnaType(kIMCalo),            fCalorimeter(""),
     fMinDist(0.),fMinDist2(0.),    fMinDist3(0.),      
     fNLMCutMin(-1),                fNLMCutMax(10), 
-    fSplitAsyCut(2.),
+    fUseSplitAsyCut(kFALSE),
     fTimeCutMin(-10000),           fTimeCutMax(10000),
     fFillPileUpHistograms(0),
     fFillWeightHistograms(kFALSE), fFillTMHisto(0),              
@@ -2107,7 +2107,7 @@ void  AliAnaPi0EbE::MakeShowerShapeIdentification()
     
     fhSelectedAsymmetry->Fill(mom.E(),asy);
 
-    if(nMaxima > 1 &&  TMath::Abs(asy) > fSplitAsyCut )
+    if( fUseSplitAsyCut &&  GetCaloPID()->IsInPi0SplitAsymmetryRange(mom.E(),asy,nMaxima) )
     {
       if(GetDebug() > 1) printf("AliAnaPi0EbE::MakeShowerShapeIdentification() - Too large asymmetry\n");
       FillRejectedClusterHistograms(mom,tag);
index 30f7c3ef6017b371ea6db9b364da370c51238f8e..65d38a9260436f1c0fb5a7e1f08838772f10be92 100755 (executable)
@@ -88,15 +88,13 @@ class AliAnaPi0EbE : public AliAnaCaloTrackCorrBaseClass {
   Int_t          GetNLMCutMin()                        const { return fNLMCutMin               ; }
   Int_t          GetNLMCutMax()                        const { return fNLMCutMax               ; }     
   
-  void           SetSplitAsymmetryCut(Float_t cut)           { fSplitAsyCut = cut              ; }
-  Float_t        GetSplitAsymmetryCut()                const { return fSplitAsyCut             ; }
-
-  
   void           SetTimeCut(Double_t min, Double_t max)      { fTimeCutMin = min; 
                                                                fTimeCutMax = max               ; }
   Double_t       GetTimeCutMin()                       const { return fTimeCutMin              ; }
   Double_t       GetTimeCutMax()                       const { return fTimeCutMax              ; }     
   
+  void           SwitchOnSplitAsymmetryCut()                 { fUseSplitAsyCut        = kTRUE  ; }
+  void           SwitchOffSplitAsymmetryCut()                { fUseSplitAsyCut        = kFALSE ; }    
  
   void           SwitchOnFillPileUpHistograms()              { fFillPileUpHistograms  = kTRUE  ; }
   void           SwitchOffFillPileUpHistograms()             { fFillPileUpHistograms  = kFALSE ; }    
@@ -129,7 +127,7 @@ class AliAnaPi0EbE : public AliAnaCaloTrackCorrBaseClass {
   Float_t        fMinDist3;                // One more cut on distance used for acceptance-efficiency study
   Int_t          fNLMCutMin  ;             // Remove clusters/cells with number of local maxima smaller than this value
   Int_t          fNLMCutMax  ;             // Remove clusters/cells with number of local maxima larger than this value
-  Float_t        fSplitAsyCut ;            // Remove splitted clusters with too large asymmetry and NLM>1
+  Bool_t         fUseSplitAsyCut ;         // Remove splitted clusters with too large asymmetry, range defined in AliCaloPID
   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