]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
verbose output of Kink tasks only when fDebug is >1
authorbhippoly <bhippoly@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 11 Aug 2009 13:18:28 +0000 (13:18 +0000)
committerbhippoly <bhippoly@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 11 Aug 2009 13:18:28 +0000 (13:18 +0000)
PWG2/KINK/AliAnalysisKinkESDMC.cxx
PWG2/KINK/AliResonanceKink.cxx
PWG2/KINK/AliResonanceKinkLikeSign.cxx

index a75f752caaf5d764fe1dcb5accbbdc8ee5c85c3b..3e986fed93b7202507c27ffab9d2dcee85f39d6f 100644 (file)
@@ -182,7 +182,7 @@ void AliAnalysisKinkESDMC::UserExec(Option_t *)
      return;
   }
 
-  Printf("MC particles: %d", mcEvent->GetNumberOfTracks());
+  if (fDebug > 0)   Printf("MC particles: %d", mcEvent->GetNumberOfTracks());
 
   AliStack* stack=mcEvent->Stack();
   
@@ -213,7 +213,7 @@ void AliAnalysisKinkESDMC::UserExec(Option_t *)
 
     AliESDtrack* track = esd->GetTrack(iTracks);
     if (!track) {
-      Printf("ERROR: Could not receive track %d", iTracks);
+      if (fDebug > 0) Printf("ERROR: Could not receive track %d", iTracks);
       continue;
     }
     
@@ -270,7 +270,7 @@ void AliAnalysisKinkESDMC::UserExec(Option_t *)
     track->GetImpactParameters(bpos,bCovpos);
     
     if (bCovpos[0]<=0 || bCovpos[2]<=0) {
-     Printf("Estimated b resolution lower or equal zero!");
+     if (fDebug > 0) Printf("Estimated b resolution lower or equal zero!");
      bCovpos[0]=0; bCovpos[2]=0;
     }
 
index c155308c8c7efbd64c7d017497da4a1750b4b02b..73e58080cf1618fcf434ffd931cbf96960cfa145 100644 (file)
@@ -219,7 +219,7 @@ void AliResonanceKink::Analyse(AliESDEvent* esd, AliMCEvent* mcEvent)
 
     if (!particle)
     {
-      Printf("UNEXPECTED: particle with label %d not found in stack (mc loop)", iMc);
+      if (fDebug > 0) Printf("UNEXPECTED: particle with label %d not found in stack (mc loop)", iMc);
       continue;
     }
 
@@ -270,7 +270,7 @@ void AliResonanceKink::Analyse(AliESDEvent* esd, AliMCEvent* mcEvent)
   for (Int_t iTracks = 0; iTracks < esd->GetNumberOfTracks(); iTracks++) {
     AliESDtrack* trackpos = esd->GetTrack(iTracks);
     if (!trackpos) {
-      Printf("ERROR: Could not receive track %d", iTracks);
+      if (fDebug > 0) Printf("ERROR: Could not receive track %d", iTracks);
       continue;
     }
     if (trackpos->GetSign() < 0) continue;
@@ -474,22 +474,22 @@ const AliESDVertex* AliResonanceKink::GetEventVertex(const AliESDEvent* esd) con
   }
   
   if(GetSigmaToVertex(localtrack) > fMaxNSigmaToVertex) {
-      Printf("IsAcceptedKink: Track rejected because it has a %lf sigmas to vertex TPC (max. requested: %lf)",   GetSigmaToVertex(localtrack),fMaxNSigmaToVertex);
+      if (fDebug > 1) Printf("IsAcceptedKink: Track rejected because it has a %lf sigmas to vertex TPC (max. requested: %lf)",   GetSigmaToVertex(localtrack),fMaxNSigmaToVertex);
       return kFALSE;
   }
   
   if(TMath::Abs(dca[0]) > fMaxDCAxy) {
-      Printf("IsAcceptedKink: Track rejected because it has a value of dca(xy) (TPC) of %lf (max. requested: %lf)", TMath::Abs(dca[0]), fMaxDCAxy);
+      if (fDebug > 1) Printf("IsAcceptedKink: Track rejected because it has a value of dca(xy) (TPC) of %lf (max. requested: %lf)", TMath::Abs(dca[0]), fMaxDCAxy);
       return kFALSE;
   }
     
   if(TMath::Abs(dca[1]) > fMaxDCAzaxis) {
-      Printf("IsAcceptedKink: Track rejected because it has a value of dca(z) of %lf (max. requested: %lf)", TMath::Abs(dca[1]), fMaxDCAzaxis);
+      if (fDebug > 1) Printf("IsAcceptedKink: Track rejected because it has a value of dca(z) of %lf (max. requested: %lf)", TMath::Abs(dca[1]), fMaxDCAzaxis);
       return kFALSE;
   }
   
   if(gPt < fMinPtTrackCut) {
-      Printf("IsAcceptedKink: Track rejected because it has a min value of pt of %lf (min. requested: %lf)", gPt, fMinPtTrackCut);
+      if (fDebug > 1) Printf("IsAcceptedKink: Track rejected because it has a min value of pt of %lf (min. requested: %lf)", gPt, fMinPtTrackCut);
       return kFALSE;
   } 
   
@@ -528,42 +528,42 @@ Bool_t AliResonanceKink::IsAcceptedForTrack(AliESDEvent *localesd,
   localtrack->GetExternalCovariance(extCov);
   
   if((localtrack->GetStatus() & AliESDtrack::kTPCrefit) == 0) {
-      Printf("IsAccepted: Track rejected because of no refited in TPC");
+      if (fDebug > 1) Printf("IsAccepted: Track rejected because of no refited in TPC");
       return kFALSE;
   } 
 
   if(nClustersTPC < fMinTPCclusters) {
-      Printf("IsAccepted: Track rejected because it has a value of nclusters (TPC) of %ld (min. requested: %ld)", nClustersTPC, fMinTPCclusters);
+      if (fDebug > 1) Printf("IsAccepted: Track rejected because it has a value of nclusters (TPC) of %ld (min. requested: %ld)", nClustersTPC, fMinTPCclusters);
       return kFALSE;
   } 
   
   if(chi2perTPCcluster > fMaxChi2PerTPCcluster) {
-      Printf("IsAccepted: Track rejected because it has a value of chi2perTPCcluster of %lf (max. requested: %lf)", chi2perTPCcluster, fMaxChi2PerTPCcluster);
+      if (fDebug > 1) Printf("IsAccepted: Track rejected because it has a value of chi2perTPCcluster of %lf (max. requested: %lf)", chi2perTPCcluster, fMaxChi2PerTPCcluster);
       return kFALSE;
   } 
 
   if(extCov[0] > fMaxCov0) {
-      Printf("IsAccepted: Track rejected because it has a value of cov[0] of %lf (max. requested: %lf)", cov[0], fMaxCov0);
+      if (fDebug > 1) Printf("IsAccepted: Track rejected because it has a value of cov[0] of %lf (max. requested: %lf)", cov[0], fMaxCov0);
       return kFALSE;
   }
   
   if(extCov[2] > fMaxCov2) {
-      Printf("IsAccepted: Track rejected because it has a value of cov[2] of %lf (max. requested: %lf)", cov[2], fMaxCov2);
+      if (fDebug > 1) Printf("IsAccepted: Track rejected because it has a value of cov[2] of %lf (max. requested: %lf)", cov[2], fMaxCov2);
       return kFALSE;
   }
     
   if(extCov[5] > fMaxCov5) {
-      Printf("IsAccepted: Track rejected because it has a value of cov[5] of %lf (max. requested: %lf)", cov[5], fMaxCov5);
+      if (fDebug > 1) Printf("IsAccepted: Track rejected because it has a value of cov[5] of %lf (max. requested: %lf)", cov[5], fMaxCov5);
       return kFALSE;
   }  
   
   if(extCov[9] > fMaxCov9) {
-      Printf("IsAccepted: Track rejected because it has a value of cov[9] of %lf (max. requested: %lf)", cov[9], fMaxCov9);
+      if (fDebug > 1) Printf("IsAccepted: Track rejected because it has a value of cov[9] of %lf (max. requested: %lf)", cov[9], fMaxCov9);
       return kFALSE;
   }  
   
   if(extCov[14] > fMaxCov14) {
-      Printf("IsAccepted: Track rejected because it has a value of cov[14] of %lf (max. requested: %lf)", cov[14], fMaxCov14);
+      if (fDebug > 1) Printf("IsAccepted: Track rejected because it has a value of cov[14] of %lf (max. requested: %lf)", cov[14], fMaxCov14);
       return kFALSE;
   } 
  
index fd96483de231787bae02d383d79466c46fee128e..04e3398a4b16869ebf85d3e96291451ab190dc91 100644 (file)
@@ -132,7 +132,7 @@ void AliResonanceKinkLikeSign::Exec(Option_t *)
   for (Int_t iTracks = 0; iTracks < fESD->GetNumberOfTracks(); iTracks++) {
     AliESDtrack* trackpos = fESD->GetTrack(iTracks);
     if (!trackpos) {
-      Printf("ERROR: Could not receive track %d", iTracks);
+      if (fDebug > 0) Printf("ERROR: Could not receive track %d", iTracks);
       continue;
     }
     
@@ -147,7 +147,7 @@ void AliResonanceKinkLikeSign::Exec(Option_t *)
     trackpos->GetImpactParameters(bpos,bCovpos);
     
     if (bCovpos[0]<=0 || bCovpos[2]<=0) {
-     Printf("Estimated b resolution lower or equal zero!");
+     if (fDebug > 0) Printf("Estimated b resolution lower or equal zero!");
      bCovpos[0]=0; bCovpos[2]=0;
     }
 
@@ -231,7 +231,7 @@ void AliResonanceKinkLikeSign::Exec(Option_t *)
         Float_t bCovneg[3];
         trackneg->GetImpactParameters(bneg,bCovneg);
         if (bCovneg[0]<=0 || bCovneg[2]<=0) {
-          Printf("Estimated b resolution lower or equal zero!");
+          if (fDebug > 0) Printf("Estimated b resolution lower or equal zero!");
           bCovneg[0]=0; bCovneg[2]=0;
         }