Full control of the tree writting,

From: Tomasz Bold <bold_at_fatcat.ftj.agh.edu.pl>
Date: Fri, 09 Sep 2005 17:15:53 +0200


    I am trying to use ROOT in multithread environment. All works fin except the TTree writing wich in fact is only one operation which happens in parallel.
How can I get the full control over the AutoSaving operation in order to control concurency.

  1. One of the possibilities is to keep Ntuples in memory until the job ends and then at the end write them out. This works fine until the Trees are small.
  2. The solution I have now is to write out every some number of events. This is quite bad since no info about size of data in Branch is unused. Then for one Branch certain number of events is correct interval for others is not. If I knew number of bytes residing in the buffer and its capacity then I would save if 90% is filled or so.
  3. I was trying to play with SetCircular but I can't find a way to save the buffers to the files at certain moment. If I call Write each some number of entries (buffersize -1) then I am getting large number of trees with different cycle numbers.
  4. I guess I can do something looking at the TBranches and thier TBaskets. But it is not clear what is what there.

Any hint?

    Tomasz Bold    

Received on Fri Sep 09 2005 - 17:14:46 MEST

This archive was generated by hypermail 2.2.0 : Tue Jan 02 2007 - 14:45:12 MET