fUseBkgrdVertex(kTRUE),
fRegionOfInterest(kFALSE),
fCDBUri(""),
+ fQARefUri(""),
fSpecCDBUri(),
fRun(-1),
fSeed(0),
fLego(NULL),
fQADetectors("ALL"),
fQATasks("ALL"),
- fQASteer(NULL),
+ fQAManager(NULL),
fRunQA(kTRUE),
fEventSpecie(AliRecoParam::kDefault),
fRunHLT("default"),
SetGAliceFile("galice.root");
// for QA
- fQASteer = new AliQADataMakerSteer("sim") ;
- fQASteer->SetActiveDetectors(fQADetectors) ;
+ fQAManager = AliQAManager::QAManager("sim") ;
+ fQAManager->SetActiveDetectors(fQADetectors) ;
fQATasks = Form("%d %d %d", AliQA::kHITS, AliQA::kSDIGITS, AliQA::kDIGITS) ;
- fQASteer->SetTasks(fQATasks) ;
+ fQAManager->SetTasks(fQATasks) ;
}
//_____________________________________________________________________________
fSpecCDBUri.Delete();
if (fgInstance==this) fgInstance = 0;
- delete fQASteer ;
+ delete fQAManager ;
AliCodeTimer::Instance()->Print();
}
fNEvents = nEvents;
}
+//_____________________________________________________________________________
+void AliSimulation::InitQA()
+{
+ // activate a default CDB storage
+ // First check if we have any CDB storage set, because it is used
+ // to retrieve the calibration and alignment constants
+
+ if (fInitCDBCalled) return;
+ fInitCDBCalled = kTRUE;
+
+ fQAManager = AliQAManager::QAManager("sim") ;
+ fQAManager->SetActiveDetectors(fQADetectors) ;
+ fQATasks = Form("%d %d %d", AliQA::kHITS, AliQA::kSDIGITS, AliQA::kDIGITS) ;
+ fQAManager->SetTasks(fQATasks) ;
+
+ if (fQAManager->IsDefaultStorageSet()) {
+ AliWarning("!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!");
+ AliWarning("Default QA reference storage has been already set !");
+ AliWarning(Form("Ignoring the default storage declared in AliSimulation: %s",fQARefUri.Data()));
+ AliWarning("!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!");
+ fQARefUri = fQAManager->GetDefaultStorage()->GetURI();
+ } else {
+ if (fQARefUri.Length() > 0) {
+ AliDebug(2,"!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!");
+ AliDebug(2, Form("Default QA reference storage is set to: %s", fQARefUri.Data()));
+ AliDebug(2, "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!");
+ } else {
+ fQARefUri="local://$ALICE_ROOT/QARef";
+ AliWarning("!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!");
+ AliWarning("Default QA reference storage not yet set !!!!");
+ AliWarning(Form("Setting it now to: %s", fQARefUri.Data()));
+ AliWarning("!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!");
+ }
+ fQAManager->SetDefaultStorage(fQARefUri);
+ }
+}
+
//_____________________________________________________________________________
void AliSimulation::InitCDB()
{
//_____________________________________________________________________________
void AliSimulation::SetDefaultStorage(const char* uri) {
-// Store the desired default CDB storage location
-// Activate it later within the Run() method
-
+ // Store the desired default CDB storage location
+ // Activate it later within the Run() method
+
fCDBUri = uri;
+
+}
+//_____________________________________________________________________________
+void AliSimulation::SetQARefDefaultStorage(const char* uri) {
+ // Store the desired default CDB storage location
+ // Activate it later within the Run() method
+
+ fQARefUri = uri;
+ AliQA::SetQARefStorage(fQARefUri.Data()) ;
}
//_____________________________________________________________________________
// run the QA on summable hits, digits or digits
if(!gAlice) return kFALSE;
- fQASteer->SetRunLoader(AliRunLoader::Instance()) ;
+ fQAManager->SetRunLoader(AliRunLoader::Instance()) ;
TString detectorsw("") ;
Bool_t rv = kTRUE ;
- fQASteer->SetEventSpecie(fEventSpecie) ;
- detectorsw = fQASteer->Run(fQADetectors.Data()) ;
+ fQAManager->SetEventSpecie(fEventSpecie) ;
+ detectorsw = fQAManager->Run(fQADetectors.Data()) ;
if ( detectorsw.IsNull() )
rv = kFALSE ;
return rv ;
tempo.ReplaceAll(Form("%d", AliQA::kDIGITS), AliQA::GetTaskName(AliQA::kDIGITS)) ;
AliInfo( Form("QA will be done on \"%s\" for \"%s\"\n", fQADetectors.Data(), tempo.Data()) ) ;
fRunQA = kTRUE ;
- fQASteer->SetActiveDetectors(fQADetectors) ;
- fQASteer->SetTasks(fQATasks) ;
+ fQAManager->SetActiveDetectors(fQADetectors) ;
+ fQAManager->SetTasks(fQATasks) ;
for (Int_t det = 0 ; det < AliQA::kNDET ; det++)
- fQASteer->SetWriteExpert(AliQA::DETECTORINDEX_t(det)) ;
+ fQAManager->SetWriteExpert(AliQA::DETECTORINDEX_t(det)) ;
return kTRUE;
}