#include "AliRawReader.h"
#include "AliRawReaderRoot.h"
#include "AliTRDrawStreamBase.h"
+#include "AliGeomManager.h"
TString ClassName() { return "rawqa" ; }
//________________________________qa______________________________________
void rawqa(const Int_t runNumber, Int_t maxFiles = 10, const char* year = "08")
{
- char kDefaultOCDBStorage[120] ;
- sprintf(kDefaultOCDBStorage, "alien://folder=/alice/data/20%s/LHC%sa/OCDB/", year, year) ;
- AliQA::SetQARefStorage(Form("%s%s/", AliQA::GetQARefDefaultStorage(), year)) ;
- AliQA::SetQARefDataDirName("Data") ; //Data, Pedestals, BlackEvent, .....
+ char * kDefaultOCDBStorage = Form("alien://folder=/alice/data/20%s/LHC%sc/OCDB/", year, year) ;
+ //AliQA::SetQARefStorage(Form("%s%s/", AliQA::GetQARefDefaultStorage(), year)) ;
+ AliQA::SetQARefStorage("local://$ALICE_ROOT") ;
+ AliQA::SetQARefDataDirName(AliQA::kMONTECARLO) ; //RUN_TYPE
UInt_t maxEvents = 99999 ;
if ( maxFiles < 0 ) {
TGridResult * result = 0x0 ;
Bool_t local = kFALSE ;
if (grid) { // get the list of files from AliEn directly
- TString baseDir;
- baseDir.Form("/alice/data/20%s/",year);
- result = grid->Query(baseDir, pattern) ;
+ TString collectionFile(pattern) ;
+ collectionFile.ReplaceAll("*.root", ".xml") ;
+ if ( gSystem->AccessPathName(collectionFile) == 0 ) { // get the list of files from an a-priori created collection file
+ TAlienCollection collection(collectionFile.Data(), maxFiles) ;
+ result = collection.GetGridResult("", 0, 0);
+ } else {
+ TString baseDir;
+ baseDir.Form("/alice/data/20%s/",year);
+ result = grid->Query(baseDir, pattern) ;
+ }
} else {
- TString collectionFile(pattern) ;
- collectionFile.Append(".xml") ;
- if ( gSystem->AccessPathName(collectionFile) == 0 ) { // get the list of files from an a-priori created collection file
- TAlienCollection collection(collectionFile.Data(), maxFiles) ;
- result = collection.GetGridResult("", 0, 0);
- } else { // get the list of files from the local current directory
+ // get the list of files from the local current directory
local = kTRUE ;
char line[100] ;
sprintf(line, ".! ls %s*.root > tempo.txt", pattern.Data()) ;
gROOT->ProcessLine(line) ;
- }
}
+
AliLog::Flush();
ifstream in ;
if (local)
in.open("tempo.txt", ifstream::in) ;
- AliQADataMakerSteer qas ;
+ AliQADataMakerSteer qas("rec") ;
TString detectors = "";
TString detectorsW = "";
UShort_t file = 0 ;
UShort_t filesProcessed = 0 ;
UShort_t eventsProcessed = 0 ;
AliCDBManager* man = AliCDBManager::Instance();
+ man->SetDefaultStorage(kDefaultOCDBStorage) ;
+ man->SetRun(runNumber) ;
+ AliGeomManager::LoadGeometry();
for ( file = 0 ; file < maxFiles ; file++) {
- man->SetDefaultStorage(kDefaultOCDBStorage) ;
if ( qas.GetCurrentEvent() >= maxEvents)
break ;