1 #ifndef MACRO_FUN4ALLG4SPHENIX_C
2 #define MACRO_FUN4ALLG4SPHENIX_C
9 #include <G4_CaloTrigger.C>
11 #include <G4_DSTReader.C>
12 #include <G4_Global.C>
13 #include <G4_HIJetReco.C>
44 R__LOAD_LIBRARY(libfun4all.so)
45 R__LOAD_LIBRARY(libffamodules.so)
52 const
string &inputFile = "https:
53 const
string &outputFile = "G4sPHENIX.
root",
54 const
string &embed_input_file = "https:
56 const
string &outdir = ".")
291 Enable::BBCFAKE =
true;
456 if ((Enable::BBC && Enable::BBCRECO) || Enable::BBCFAKE)
Bbc_Reco();
524 const std::string kshortFile =
"./kshort_" + outputFile;
525 const std::string residualsFile =
"./residuals_" + outputFile;
537 cout <<
"You can only enable Enable::GLOBAL_RECO or Enable::GLOBAL_FASTSIM, not both" << endl;
579 string outputroot = outputFile;
580 string remove_this =
".root";
581 size_t pos = outputroot.find(remove_this);
582 if (pos != string::npos)
584 outputroot.erase(pos, remove_this.length());
658 gROOT->ProcessLine(
"Fun4AllServer *se = Fun4AllServer::instance();");
659 gROOT->ProcessLine(
"PHG4Reco *g4 = (PHG4Reco *) se->getSubsysReco(\"PHG4RECO\");");
661 cout <<
"-------------------------------------------------" << endl;
662 cout <<
"You are in event display mode. Run one event with" << endl;
663 cout <<
"se->run(1)" << endl;
664 cout <<
"Run Geant4 command with following examples" << endl;
665 gROOT->ProcessLine(
"displaycmd()");
679 cout <<
"using 0 for number of events is a bad idea when using particle generators" << endl;
680 cout <<
"it will run forever, so I just return without running anything" << endl;
691 if (Enable::QA)
QA_Output(outputroot +
"_qa.root");
699 std::cout <<
"All done" << std::endl;