Skip to content

Commit

Permalink
Revert "Revert "Added changes by P. Svirin to run the AOD only with a…
Browse files Browse the repository at this point in the history
… snapshot in a networkless environment, as for ORNL TITAN""

This reverts commit 23b3f76.
  • Loading branch information
Roberto Preghenella committed Sep 15, 2016
1 parent 23b3f76 commit 75310d8
Showing 1 changed file with 29 additions and 6 deletions.
35 changes: 29 additions & 6 deletions AOD/AODtrainsim.C
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,11 @@ Bool_t LoadAnalysisLibraries();
Bool_t LoadLibrary(const char *);
void ProcessEnvironment();
TChain *CreateChain();
const char *cdbPath = "raw://";

// ORNL
//const char *cdbPath = "raw://";
const char *cdbPath = "local://";

Int_t run_number = 0;

//______________________________________________________________________________
Expand Down Expand Up @@ -101,29 +105,37 @@ void AODtrainsim(Int_t merge=0)
TString ocdbConfig = "default,snapshot";
if (gSystem->Getenv("CONFIG_OCDB"))
ocdbConfig = gSystem->Getenv("CONFIG_OCDB");
if (ocdbConfig.Contains("alien")) {

// ORNL
/*if (ocdbConfig.Contains("alien")) {
// set OCDB
gROOT->LoadMacro("$ALIDPG_ROOT/MC/OCDBConfig.C");
OCDBDefault(1);
}
else {
*/
// set OCDB snapshot mode
AliCDBManager *cdbm = AliCDBManager::Instance();
cdbm->SetSnapshotMode("OCDBrec.root");
}
// }

if(iCollision == kPbPb)
useCentrality =kTRUE;

UpdateFlags();

if (merge || doCDBconnect) {
printf("Some debugging info ================");

// ORNL
/* if (merge || doCDBconnect) {
TGrid::Connect("alien://");
if (!gGrid || !gGrid->IsConnected()) {
::Error("AODtrainsim", "No grid connection");
return;
}
}
*/

// Set temporary merging directory to current one
gSystem->Setenv("TMPDIR", gSystem->pwd());
// Set temporary compilation directory to current one
Expand Down Expand Up @@ -235,14 +247,25 @@ void AddAnalysisTasks(const char *cdb_location)
}
// CDB connection
//
if (doCDBconnect && !useTender) {

// ORNL
/* if (doCDBconnect && !useTender) {
gROOT->LoadMacro("$ALICE_PHYSICS/PWGPP/PilotTrain/AddTaskCDBconnect.C");
AliTaskCDBconnect *taskCDB = AddTaskCDBconnect(cdb_location, run_number);
if (!taskCDB) return;
AliCDBManager *cdb = AliCDBManager::Instance();
cdb->SetDefaultStorage(cdb_location);
// taskCDB->SetRunNumber(run_number);
}
} */

if (doCDBconnect) {
gROOT->LoadMacro("$ALICE_PHYSICS/PWGPP/PilotTrain/AddTaskCDBconnect.C");
AliTaskCDBconnect *taskCDB = AddTaskCDBconnect(cdb_location, run_number);
if (!taskCDB) return;
// AliCDBManager *cdb = AliCDBManager::Instance();
// cdb->SetDefaultStorage(cdb_location);
// taskCDB->SetRunNumber(run_number);
}

if (usePhysicsSelection) {
// Physics selection task
Expand Down

0 comments on commit 75310d8

Please sign in to comment.