1 #ifndef ALIQACHECKERBASE_H
2 #define ALIQACHECKERBASE_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
10 // Base class for detectors quality assurance checkers
11 // Compares Data made by QADataMakers with reference data
12 // Y. Schutz CERN August 2007
16 // --- ROOT system ---
25 class AliDetectorRecoParam ;
28 // --- Standard library ---
30 // --- AliRoot header files ---
32 class AliQACheckerBase: public TNamed {
35 AliQACheckerBase(const char * name = "", const char * title = "") ; // ctor
36 virtual ~AliQACheckerBase() ; // dtor
39 TList * GetExternParamlist() { return fExternParamList ;}
40 TCanvas ** GetImage() { return fImage ; }
41 TCanvas * GetImage(AliRecoParam::EventSpecie_t es) { return fImage[AliRecoParam::AConvert(es)] ; }
42 virtual void Init(const AliQAv1::DETECTORINDEX_t det) { AliQAv1::Instance(det) ; }
43 virtual void MakeImage( TObjArray ** list, AliQAv1::TASKINDEX_t task, AliQAv1::MODE_t mode) ;
44 void PrintExternParam() ;
45 void Run(AliQAv1::ALITASK_t tsk, const AliDetectorRecoParam * recoParam = NULL);
46 void Run(AliQAv1::ALITASK_t tsk, TObjArray ** list, const AliDetectorRecoParam * recoParam = NULL);
47 void Run(AliQAv1::ALITASK_t /*tsk*/, TNtupleD ** /*nt*/, const AliDetectorRecoParam * /*recoParam*/) {;}
48 void SetExternParamlist(TList * list) { fExternParamList = list ;}
49 void SetHiLo(Float_t * hiValue, Float_t * lowValue) ;
50 void SetPrintImage(Bool_t opt = kTRUE) { fPrintImage = opt ; }
53 virtual void Check(Double_t *rv, AliQAv1::ALITASK_t, TObjArray ** list, const AliDetectorRecoParam * recoParam=0) ;
55 Double_t DiffC(const TH1 * href, const TH1 * hin) const ;
56 Double_t DiffK(const TH1 * href, const TH1 * hin) const ;
58 void GetRefSubDir(const char * det, const char * task, TDirectory *& dirFile, TObjArray **& dirOCDB) ;
59 virtual void SetQA(AliQAv1::ALITASK_t index, Double_t * value) const ;
61 TDirectory * fDataSubDir ; //! directory for the current task directory in the current detector directory in the data file
62 TDirectory * fRefSubDir ; //! directory for the current task directory in the current detector directory in the reference file
63 TObjArray ** fRefOCDBSubDir ; //! Entry in OCDB for the current detector
64 Float_t * fLowTestValue ; // array of lower bounds for INFO, WARNING, ERROR, FATAL
65 Float_t * fUpTestValue ; // array of upper bounds for INFO, WARNING, ERROR, FATAL
66 TCanvas ** fImage ; //[AliRecoParam::kNSpecies]
67 Bool_t fPrintImage ; //! flag to print the images or not
68 TList * fExternParamList; //List of external parameters (TParameter<double>)
71 AliQACheckerBase(const AliQACheckerBase& qac) ;
72 AliQACheckerBase& operator = (const AliQACheckerBase& qac) ;
73 void PrivateCheck(Double_t * rv, AliQAv1::ALITASK_t index, const AliDetectorRecoParam * recoParam) ;
75 ClassDef(AliQACheckerBase,3) // description
79 #endif // AliQUALASSCHECKERBASE_H