Event/TTree reading

From: Dmitry Naumov <naumov_at_nusun.jinr.ru>
Date: Fri, 15 Dec 2006 13:47:10 +0300

Dear Rooters,

may I ask your advice on the following problem. We save simulated events into a TTree object. However sometimes the events are too large and we split them into pieces and save each piece as an entry of the TTree. This works OK. What would be a clever way to read these events from the TTree?
A simple code which we had before (before splitting) is not useful anymore:

// open the tree
Event *ev=0;
do (int i(0); i<tree->GetEntries()l i++) {

       // do something with ev: fill its global information (energy, 
position, etc), fill its hits

Following this way the concept of entry as an event is no more working, and we have to organize something like "SubEvent" and do cycle over ev->GetSubEvents() entries or so. This is the way I have in mind. However before trying to realize it it would be great if ROOT/C++ gurus could give an advice on that. [Building the whole event from different entries of TTree is not OK because the event might not fit into the memory].

Thank you in advance, Dmitry Received on Fri Dec 15 2006 - 11:47:06 MET

This archive was generated by hypermail 2.2.0 : Mon Jan 01 2007 - 16:32:02 MET