1 #ifndef MACRO_FUN4ALLG4EICDETECTOR_C
2 #define MACRO_FUN4ALLG4EICDETECTOR_C
23 #include <RooUnblindPrecision.h>
29 const
string &inputFile = "https:
30 const
string &outputFile = "G4EICDetector.root",
31 const
string &embed_input_file = "https:
33 const
string &outdir = ".")
51 bool generate_seed =
false;
55 size_t findSlash = inputFile.find_last_of(
"/");
56 string inputFileName = inputFile.substr(findSlash + 1, inputFile.size());
58 RooRealVar dummyVal(
"dummy",
"", 0);
59 RooUnblindPrecision blindVal(
"blindVal",
"blindVal", inputFileName.c_str(),
nEvents, skip + 1, dummyVal, kFALSE);
632 string outputroot = outputFile;
633 string remove_this =
".root";
634 size_t pos = outputroot.find(remove_this);
635 if (pos != string::npos)
637 outputroot.erase(pos, remove_this.length());
701 gROOT->ProcessLine(
"Fun4AllServer *se = Fun4AllServer::instance();");
702 gROOT->ProcessLine(
"PHG4Reco *g4 = (PHG4Reco *) se->getSubsysReco(\"PHG4RECO\");");
704 cout <<
"-------------------------------------------------" << endl;
705 cout <<
"You are in event display mode. Run one event with" << endl;
706 cout <<
"se->run(1)" << endl;
707 cout <<
"Run Geant4 command with following examples" << endl;
708 gROOT->ProcessLine(
"displaycmd()");
720 cout <<
"using 0 for number of events is a bad idea when using particle generators" << endl;
721 cout <<
"it will run forever, so I just return without running anything" << endl;
733 std::cout <<
"All done" << std::endl;