3 void RunGammaPythiaMaker(
6 const char* file=
"/star/institutions/mit/betan/Simulation/photon_9_11.MuDst.root",
7 const char *fname=
"/star/institutions/mit/betan/Simulation/photon_9_11.geant.root",
8 const char *filter =
"",
11 gROOT->LoadMacro(
"StRoot/StGammaMaker/macros/loadGammaLibs.C");
16 gMessMgr->SwitchOff(
"D");
17 gMessMgr->SwitchOff(
"I");
20 ioMaker->SetFile(fname);
22 ioMaker->SetBranch(
"*",0,
"0");
23 ioMaker->SetBranch(
"geantBranch",0,
"r");
30 StGammaPythiaMaker *weight =
new StGammaPythiaMaker(
"GammaPythia");
32 TChain* fileChain = muDstMaker->
chain();
34 int ntotal = fileChain->GetEntries();
36 for (Int_t iev=0;iev<nevents; iev++) {
37 cout <<
"****************************************** " << endl;
38 cout <<
"Working on eventNumber:\t" << iev <<
"\tof:\t"<<ntotal<<endl;
39 cout <<
"*************************1***************** " << endl;
41 int iret = chain->
Make(iev);
44 cout <<
"Bad return code!" << endl;
47 cout <<
"Number of pi0: " << weight->numberOfPion0() <<
'\n';
48 cout <<
"Number of prompt photons: " << weight->numberOfPrompt() <<
'\n';
49 cout <<
"Number of decay photons: " << weight->numberOfDecay() <<
'\n';
54 cout <<
"****************************************** " << endl;
55 cout <<
"total number of events " << total << endl;
56 cout <<
"****************************************** " << endl;
virtual void SetIOMode(Option_t *iomode="w")
number of transactions
virtual void Clear(Option_t *option="")
User defined functions.
static void setLevel(unsigned int level)
sets the debug level
Filling of all StMcEvent classes from g2t tables Transform all the data in the g2t tables into the co...
TChain * chain()
In read mode, returns pointer to the chain of .MuDst.root files that where selected.