]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - ITS/AliITSQASSDChecker.cxx
Improved treatment of dead areas in track chi2 calculation (A. Dainese)
[u/mrichter/AliRoot.git] / ITS / AliITSQASSDChecker.cxx
index ab68f83818d3a47823d9735acaf4c2c06f029c32..63af85b086ced3430e57c18cfccff1acd68f9405 100644 (file)
 //  INFN Torino
 
 // --- ROOT system ---
+#include "TH1.h"
+#include "TString.h"
+#include "Riostream.h"
 
 // --- AliRoot header files ---
 #include "AliITSQASSDChecker.h"
+#include "AliLog.h"
 
 ClassImp(AliITSQASSDChecker)
-
 //__________________________________________________________________
 AliITSQASSDChecker& AliITSQASSDChecker::operator = (const AliITSQASSDChecker& qac ) 
 {
@@ -38,13 +41,11 @@ AliITSQASSDChecker& AliITSQASSDChecker::operator = (const AliITSQASSDChecker& qa
 }
 
 //__________________________________________________________________
-const Double_t AliITSQASSDChecker::Check() 
-{
-/*
-  TObjArray * list
+Double_t AliITSQASSDChecker::Check(AliQAv1::ALITASK_t /*index*/, TObjArray * list) {  
+  AliDebug(AliQAv1::GetQADebugLevel(),Form("AliITSQASSDChecker called with offset: %d\n", fSubDetOffset));
+  
   Double_t test = 0.0  ;
   Int_t count = 0 ;
-
   if (list->GetEntries() == 0){
     test = 1. ; // nothing to check
   }
@@ -54,16 +55,18 @@ const Double_t AliITSQASSDChecker::Check()
     count = 0 ;
     while ( (hdata = dynamic_cast<TH1 *>(next())) ) {
       if (hdata) {
+       TString histname = hdata->GetName();
+       if(!histname.Contains("fHistSSD")) continue;
         Double_t rv = 0.;
-        if(hdata->GetEntries()>0)rv=1;
-        AliInfo(Form("%s -> %f", hdata->GetName(), rv)) ;
+        if(hdata->GetEntries()>0) rv = 1;
+        //AliDebug(AliQAv1::GetQADebugLevel(), Form("%s -> %f", hdata->GetName(), rv)) ;
+       //cout<<hdata->GetName()<<" - "<<rv<<endl;
         count++ ;
         test += rv ;
       }
       else{
         AliError("Data type cannot be processed") ;
       }
-
     }
     if (count != 0) {
       if (test==0) {
@@ -75,11 +78,18 @@ const Double_t AliITSQASSDChecker::Check()
       }
     }
   }
+  
+  //AliDebug(AliQAv1::GetQADebugLevel(), Form("Test Result = %f", test)) ;
+  //cout<<"Test result: "<<test<<endl;
 
-  AliInfo(Form("Test Result = %f", test)) ;
   return test ;
-*/
-  return 0.;   
+
+  //return 0.;
+  
 }
 
+//__________________________________________________________________
+void AliITSQASSDChecker::SetTaskOffset(Int_t TaskOffset)
+{
+  fSubDetOffset = TaskOffset;
+}