9 void rdMu2binL2eve(
int nevents = 100,
11 char *file=
"R9067013.lis")
14 if (flagMC) file=
"mit0029.lis";
19 char *eemcSetupPath=
"/star/institutions/mit/balewski/StarTrigSimuSetup2008/";
20 TString outDir=
"./out2/";
24 gROOT->LoadMacro(
"$STAR/StRoot/StMuDSTMaker/COMMON/macros/loadSharedLibraries.C");
25 loadSharedLibraries();
26 assert( !gSystem->Load(
"StDetectorDbMaker"));
27 assert( !gSystem->Load(
"StDbUtilities"));
28 assert( !gSystem->Load(
"StDbBroker"));
29 assert( !gSystem->Load(
"St_db_Maker"));
30 assert( !gSystem->Load(
"StEEmcUtil"));
31 assert( !gSystem->Load(
"StEEmcDbMaker"));
32 assert( !gSystem->Load(
"StDaqLib"));
33 assert( !gSystem->Load(
"StEmcRawMaker"));
34 assert( !gSystem->Load(
"StEmcADCtoEMaker"));
36 assert( !gSystem->Load(
"StMcEvent"));
37 assert( !gSystem->Load(
"StMcEventMaker"));
38 assert( !gSystem->Load(
"StEmcSimulatorMaker"));
39 assert( !gSystem->Load(
"StEpcMaker"));
41 assert( !gSystem->Load(
"StTriggerUtilities"));
43 gROOT->Macro(
"LoadLogger.C");
44 cout <<
" loading done " << endl;
49 printf(
" dirIn=%s= file=%s=\n",dirIn,file);
52 TChain* tree=muDstMaker->
chain(); assert(tree);
int nEntries=(int) tree->GetEntries();
53 cout <<
"Avaliable number of events " << nEntries << endl;
61 dbMk->SetDateTime(20080307, 83000);
79 simL2Mk->setSetupPath(eemcSetupPath);
80 simL2Mk->setOutPath(outDir.Data());
81 if (flagMC) simL2Mk->setMC();
92 for (Int_t iev=0;iev<nevents; iev++) {
93 cout <<
"\n****************************************** " << endl;
94 cout <<
"Working on eventNumber:\t" << iev <<
"\tof:\t"<<nevents<<endl;
95 cout <<
"****************************************** " << endl;
97 int iret = chain->
Make(iev);
100 cout <<
"Bad return code!" << endl;
106 float tMnt=(t2-t1)/60.;
107 float rate=1.*total/(t2-t1);
110 cout <<
"****************************************** " << endl;
111 cout <<
"total number of events " << total << endl;
112 cout <<
"****************************************** " << endl;
116 printf(
"=%s=\n",fileMu.Data());
117 if(fileMu.Contains(
".lis")) fileMu.ReplaceAll(
".lis",
".trgSim");
118 if(fileMu.Contains(
".MuDst.root")) fileMu.ReplaceAll(
".MuDst.root",
".trgSim");
119 cout <<Form(
"sorting done %d of nEve=%d, CPU rate=%.1f Hz, total time %.1f minute(s) \n\n",total,nEntries,rate,tMnt)<<endl;
virtual void Clear(Option_t *option="")
User defined functions.
virtual void ls(Option_t *option="") const
TChain * chain()
In read mode, returns pointer to the chain of .MuDst.root files that where selected.
void saveAllStEvent(Bool_t a)
Set to kTRUE if all hits are to be saved on StEvent.