49 void bfcread_dstBranch(
52 "/afs/rhic.bnl.gov/star/data/samples/gstar.dst.root",
53 const char *fname=
"qa_dst.out")
56 cout <<
" events to process = " << nevents << endl;
57 cout <<
" Input File Name = " << MainFile << endl;
58 cout <<
" Output file containing printouts = " << fname << endl;
62 fout <<
" Running: bfcread_dstBranch.C " << endl;
63 fout <<
" events to process = " << nevents << endl;
64 fout <<
" Input File Name = " << MainFile << endl;
65 fout <<
" Output file containing printouts = " << fname << endl;
68 gSystem->Load(
"St_base");
69 gSystem->Load(
"StChain");
70 gSystem->Load(
"libglobal_Tables");
71 gSystem->Load(
"StIOMaker");
80 IOMk->SetBranch(
"*",0,
"0");
81 IOMk->SetBranch(
"dstBranch",0,
"r");
97 Float_t countevdstB=0.0;
98 Float_t countevdst=0.0;
99 Float_t countevdstTab=0.0;
100 Float_t countevdstRE=0.0;
101 Float_t countevobjd=0.0;
102 Float_t countevtabd=0.0;
103 Float_t countevobjb=0.0;
104 Float_t countevtabb=0.0;
107 EventLoop:
if (iev < nevents && !istat) {
118 istat = chain->
Make(iev);
123 cout <<
" Call Make # " << iev << endl;
124 cout <<
" istat value returned from chain Make = " << istat << endl;
129 cout <<
" start event # " << countev << endl;
130 fout <<
" start event # " << countev << endl;
132 ddstBranch=chain->GetDataSet(
"dstBranch");
140 cout << endl <<
" QAInfo: in dstBranch " << endl;
141 fout << endl <<
" QAInfo: in dstBranch " << endl;
143 while (ddb=dstbranchIter.
Next()) {
145 cout << endl <<
" QAInfo: found object: " << ddb->GetName() << endl;
146 fout << endl <<
" QAInfo: found object: " << ddb->GetName() << endl;
148 TString dsName = ddb->GetName();
150 if (dsName ==
"BfcStatus") {
159 if (ddb->InheritsFrom(
"TTable")) {
162 cout <<
" QAInfo: it's a table with #rows = "
164 fout <<
" QAInfo: it's a table with #rows = "
167 if (dsName ==
"BfcStatus") {
177 for (ij=0; ij< bfcstat->
GetNRows(); ij++)
179 cout <<
" QAInfo: BfcStatus table -- row " << ij <<
180 ", Maker: " << bth[ij]->maker_name <<
181 " has istat = " << bth[ij]->status << endl;
182 fout <<
" QAInfo: BfcStatus table -- row " << ij <<
183 ", Maker: " << bth[ij]->maker_name <<
184 " has istat = " << bth[ij]->status << endl;
195 if (dsName ==
"dst") {
199 cout <<
" QAInfo: in dst object " << endl;
200 fout <<
" QAInfo: in dst object " << endl;
207 while (obj = tabiter.
Next()) {
209 cout <<
" QAInfo: found object: " << obj->GetName() << endl;
210 fout <<
" QAInfo: found object: " << obj->GetName() << endl;
215 TString dstobjName = obj->GetName();
216 if (dstobjName ==
"RunEvent") {
221 if (obj->InheritsFrom(
"TTable")) {
222 tabl = (
TTable *)tabiter.
Find(obj->GetName());
228 cout <<
" QAInfo: it's a table with #rows = "
230 fout <<
" QAInfo: it's a table with #rows = "
244 cout << endl <<
" QAInfo: ev# " << countev <<
245 ", #dst obj/tab, #Bfc obj/tab found = " <<
246 Countevobjd <<
" " <<
247 Countevtabd <<
" " <<
248 Countevobjb <<
" " <<
249 Countevtabb << endl << endl;
251 fout << endl <<
" QAInfo: ev# " << countev <<
252 ", #dst obj/tab, #Bfc obj/tab found = " <<
253 Countevobjd <<
" " <<
254 Countevtabd <<
" " <<
255 Countevobjb <<
" " <<
256 Countevtabb << endl << endl;
261 if (counthold) countevdstTab++;
262 if (countre) countevdstRE++;
268 cout <<
"Last event processed. Status = " << istat << endl;
275 countevobjd /= countev;
276 countevtabd /= countev;
277 countevobjb /= countev;
278 countevtabb /= countev;
281 cout <<
" QAInfo: End of Job " << endl;
282 cout <<
" QAInfo: # times Make called = " << iev << endl;
283 cout <<
" QAInfo: # events read = " << countev << endl;
284 cout <<
" QAInfo: # events with dstBranch dataset = " << countevdstB << endl;
285 cout <<
" QAInfo: # events with dst dataset = " << countevdst << endl;
286 cout <<
" QAInfo: # events with RunEvent object = " << countevdstRE << endl;
287 cout <<
" QAInfo: # events with dst Tables = " << countevdstTab << endl;
288 cout <<
" QAInfo: avg # dst tables per event = " << countevtabd << endl;
289 cout <<
" QAInfo: avg # dst objects per event = " << countevobjd << endl;
290 cout <<
" QAInfo: avg # Bfc tables per event = " << countevtabb << endl;
291 cout <<
" QAInfo: avg # Bfc objects per event = " << countevobjb << endl << endl;
294 fout <<
" QAInfo: End of Job " << endl;
295 fout <<
" QAInfo: # times Make called = " << iev << endl;
296 fout <<
" QAInfo: # events read = " << countev << endl;
297 fout <<
" QAInfo: # events with dstBranch dataset = " << countevdstB << endl;
298 fout <<
" QAInfo: # events with dst dataset = " << countevdst << endl;
299 fout <<
" QAInfo: # events with RunEvent object = " << countevdstRE << endl;
300 fout <<
" QAInfo: # events with dst Tables = " << countevdstTab << endl;
301 fout <<
" QAInfo: avg # dst tables per event = " << countevtabd << endl;
302 fout <<
" QAInfo: avg # dst objects per event = " << countevobjd << endl;
303 fout <<
" QAInfo: avg # Bfc tables per event = " << countevtabb << endl;
304 fout <<
" QAInfo: avg # Bfc objects per event = " << countevobjb << endl << endl;
virtual void SetIOMode(Option_t *iomode="w")
number of transactions
virtual void Clear(Option_t *option="")
User defined functions.
virtual Long_t GetNRows() const
Returns the number of the used rows for the wrapped table.
virtual TDataSet * Next() const
virtual TDataSet * Find(const char *path) const