fDataSubDir(0x0),
fRefSubDir(0x0),
fRefOCDBSubDir(new TObjArray*[AliRecoParam::kNSpecies]),
- fLowTestValue(0x0),
- fUpTestValue(0x0),
+ fLowTestValue(new Float_t[AliQAv1::kNBIT]),
+ fUpTestValue(new Float_t[AliQAv1::kNBIT]),
fImage(new TCanvas*[AliRecoParam::kNSpecies]),
fPrintImage(kTRUE),
- fExternParamList(NULL)
+ fExternParamList(new TList())
{
// ctor
- fLowTestValue = new Float_t[AliQAv1::kNBIT] ;
- fUpTestValue = new Float_t[AliQAv1::kNBIT] ;
fLowTestValue[AliQAv1::kINFO] = 0.5 ;
fUpTestValue[AliQAv1::kINFO] = 1.0 ;
fLowTestValue[AliQAv1::kWARNING] = 0.002 ;
fDataSubDir(qac.fDataSubDir),
fRefSubDir(qac.fRefSubDir),
fRefOCDBSubDir(qac.fRefOCDBSubDir),
- fLowTestValue(qac.fLowTestValue),
- fUpTestValue(qac.fLowTestValue),
- fImage(NULL),
+ fLowTestValue(new Float_t[AliQAv1::kNBIT]),
+ fUpTestValue(new Float_t[AliQAv1::kNBIT]),
+ fImage(new TCanvas*[AliRecoParam::kNSpecies]),
fPrintImage(kTRUE),
- fExternParamList(NULL)
+ fExternParamList(new TList())
{
//copy ctor
for (Int_t index = 0 ; index < AliQAv1::kNBIT ; index++) {
fRefOCDBSubDir[specie] = qac.fRefOCDBSubDir[specie] ;
}
if (qac.fExternParamList) {
- fExternParamList = new TList() ;
TIter next(qac.fExternParamList) ;
TParameter<double> * p ;
while ( (p = (TParameter<double>*)next()) )
}
//____________________________________________________________________________
-Double_t * AliQACheckerBase::Check(AliQAv1::ALITASK_t index, AliDetectorRecoParam * recoParam)
+void AliQACheckerBase::Check(Double_t * test, AliQAv1::ALITASK_t index, const AliDetectorRecoParam * recoParam)
{
// Performs a basic checking
// Compares all the histograms stored in the directory
}
}
- Double_t * test = Check(index, list, recoParam) ;
+ Check(test, index, list, recoParam) ;
delete[] list ;
- return test ;
}
//____________________________________________________________________________
-Double_t * AliQACheckerBase::Check(AliQAv1::ALITASK_t task, TObjArray ** list, AliDetectorRecoParam * /*recoParam*/)
+void AliQACheckerBase::Check(Double_t * test, AliQAv1::ALITASK_t task, TObjArray ** list, const AliDetectorRecoParam * /*recoParam*/)
{
// Performs a basic checking
// Compares all the histograms in the list
- Double_t * test = new Double_t[AliRecoParam::kNSpecies] ;
Int_t count[AliRecoParam::kNSpecies] = { 0 };
-// TDirectory * refDir = NULL ;
-// TObjArray ** refOCDBDir = NULL ;
GetRefSubDir(GetName(), AliQAv1::GetTaskName(task), fRefSubDir, fRefOCDBSubDir) ;
// SetRefandData(refDir, refOCDBDir) ;
}
}
}
- return test ;
}
return ;
} else {
AliQAManager* manQA = AliQAManager::QAManager(AliQAv1::GetTaskIndex(task)) ;
- dirOCDB = new TObjArray*[AliRecoParam::kNSpecies] ;
+ // dirOCDB = new TObjArray*[AliRecoParam::kNSpecies] ;
for (Int_t specie = 0 ; specie < AliRecoParam::kNSpecies ; specie++) {
dirOCDB[specie] = NULL ;
if ( !AliQAv1::Instance()->IsEventSpecieSet(specie) )
AliDebug(AliQAv1::GetQADebugLevel(), Form("Processing %s", AliQAv1::GetAliTaskName(index))) ;
Double_t * rv = NULL ;
- rv = Check(index, recoParam) ;
+ Check(rv, index, recoParam) ;
SetQA(index, rv) ;
AliDebug(AliQAv1::GetQADebugLevel(), Form("Test result of %s", AliQAv1::GetAliTaskName(index))) ;
{
AliDebug(AliQAv1::GetQADebugLevel(), Form("Processing %s", AliQAv1::GetAliTaskName(index))) ;
- Double_t * rv = NULL ;
- rv = Check(index, list, recoParam) ;
+ Double_t * rv = new Double_t[AliRecoParam::kNSpecies] ;
+ Check(rv, index, list, recoParam) ;
SetQA(index, rv) ;
AliDebug(AliQAv1::GetQADebugLevel(), Form("Test result of %s", AliQAv1::GetAliTaskName(index))) ;
- if (rv)
- delete [] rv ;
+ delete [] rv ;
Finish() ;
}
TPaveText someText(0.015, 0.015, 0.98, 0.98) ;
someText.AddText(title) ;
someText.Draw() ;
- fImage[esIndex]->Print(Form("%s%s%d.%s", AliQAv1::GetImageFileName(), AliQAv1::GetModeName(mode), AliQAChecker::Instance()->GetRunNumber(), AliQAv1::GetImageFileFormat())) ;
+ fImage[esIndex]->Print(Form("%s%s%d.%s", AliQAv1::GetImageFileName(), AliQAv1::GetModeName(mode), AliQAChecker::Instance()->GetRunNumber(), AliQAv1::GetImageFileFormat()), "ps") ;
fImage[esIndex]->Clear() ;
- Int_t nx = TMath::Sqrt(nImages) ;
+ Int_t nx = TMath::Nint(TMath::Sqrt(nImages));
Int_t ny = nx ;
- while ( nx*ny <= nImages)
+ if (nx < TMath::Sqrt(nImages))
ny++ ;
fImage[esIndex]->Divide(nx, ny) ;
if ( ! cln.Contains("TH") )
continue ;
if(hist->TestBit(AliQAv1::GetImageBit())) {
- hist->Draw() ;
+ TString opts = hist->GetDrawOption();
+ if (opts.Contains("logy",TString::kIgnoreCase)) {
+ gPad->SetLogy();
+ opts.ReplaceAll("logy", "");
+ }
+ if (opts.Contains("logx", TString::kIgnoreCase)) {
+ gPad->SetLogx();
+ opts.ReplaceAll("logx", "");
+ }
+ hist->DrawCopy() ;
fImage[esIndex]->cd(++npad) ;
}
}
- fImage[esIndex]->Print(Form("%s%s%d.%s", AliQAv1::GetImageFileName(), AliQAv1::GetModeName(mode), AliQAChecker::Instance()->GetRunNumber(), AliQAv1::GetImageFileFormat())) ;
+ fImage[esIndex]->Print(Form("%s%s%d.%s", AliQAv1::GetImageFileName(), AliQAv1::GetModeName(mode), AliQAChecker::Instance()->GetRunNumber(), AliQAv1::GetImageFileFormat()), "ps") ;
}
}
}