Line data Source code
1 : /**************************************************************************
2 : * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3 : * *
4 : * Author: The ALICE Off-line Project. *
5 : * Contributors are mentioned in the code where appropriate. *
6 : * *
7 : * Permission to use, copy, modify and distribute this software and its *
8 : * documentation strictly for non-commercial purposes is hereby granted *
9 : * without fee, provided that the above copyright notice appears in all *
10 : * copies and that both the copyright notice and this permission notice *
11 : * appear in the supporting documentation. The authors make no claims *
12 : * about the suitability of this software for any purpose. It is *
13 : * provided "as is" without express or implied warranty. *
14 : **************************************************************************/
15 :
16 :
17 : /* $Id$ */
18 :
19 : /*
20 : Checks the quality assurance.
21 : By comparing with reference data
22 : Y. Schutz CERN July 2007
23 : */
24 :
25 : // --- ROOT system ---
26 : #include <TClass.h>
27 : #include <TH1F.h>
28 : #include <TH1I.h>
29 : #include <TIterator.h>
30 : #include <TKey.h>
31 : #include <TFile.h>
32 :
33 : // --- Standard library ---
34 :
35 : // --- AliRoot header files ---
36 : #include "AliLog.h"
37 : #include "AliQAv1.h"
38 : #include "AliQAChecker.h"
39 : #include "AliPHOSQAChecker.h"
40 :
41 22 : ClassImp(AliPHOSQAChecker)
42 :
43 : //__________________________________________________________________
44 :
45 : AliPHOSQAChecker & AliPHOSQAChecker::operator = (const AliPHOSQAChecker &)
46 : {
47 0 : Fatal("operator =", "not implemented");
48 0 : return *this;
49 : }
50 :
51 : //____________________________________________________________________________
52 : void AliPHOSQAChecker::Check(Double_t * test, AliQAv1::ALITASK_t task, TObjArray ** list, const AliDetectorRecoParam * /* recoParam */)
53 : {
54 : // Performs a basic checking
55 : // Compares all the histograms in the list
56 :
57 117 : for (Int_t specie = 0 ; specie < AliRecoParam::kNSpecies ; specie++) {
58 45 : test[specie] = 1.0;
59 45 : if ( !AliQAv1::Instance()->IsEventSpecieSet(specie) )
60 : continue ;
61 : // checking for empty histograms
62 : // if (CheckEntries(list[specie]) == 0) {
63 : // AliWarning("histograms are empty");
64 : // test[specie] = 0.4;//-> Corresponds to kWARNING see AliQACheckerBase::Run
65 : // }
66 :
67 : // checking raw data
68 0 : if(task == AliQAv1::kRAW){
69 0 : if(AliRecoParam::ConvertIndex(specie) == AliRecoParam::kCalib ||
70 0 : AliRecoParam::ConvertIndex(specie) == AliRecoParam::kHighMult ||
71 0 : AliRecoParam::ConvertIndex(specie) == AliRecoParam::kLowMult ||
72 0 : AliRecoParam::ConvertIndex(specie) == AliRecoParam::kDefault) {
73 : // list[specie]->Print();
74 0 : TH1F *hHighNtot = (TH1F*)list[specie]->At(13);
75 0 : if (hHighNtot!=0) {
76 0 : if (hHighNtot->GetMean() < 1000) test[specie]=1;
77 : }
78 0 : else test[specie]=0.1;
79 0 : }
80 : }
81 :
82 : //default check response. It will be changed when reasonable checks will be considered
83 0 : else test[specie] = 0.7 ; // /-> Corresponds to kINFO see AliQACheckerBase::Run
84 : } // species loop
85 9 : }
|