Randomized access in a tree

Philippe, I’d love to, however the file is large – 570MBytes. Is there an ftp server on CERN where
I could upload it to?

p.s. I could also verify any potential fixes from you, if that’s what you are asking.

Ok, you can grab it from here, it should be ready in 5-10minutes (it’s getting uploaded to the server):

dl.dropbox.com/u/6095182/2012_04 … essed.root

Please let me know when you are done – I’ll need to delete it.

UPDATE: it’s there now, it took longer than I thought.

Hi,

Thanks. I was able to download the file and understood the last issue.

Turns out that TTree::LoadBaskets use the value given in a previous call to SetMaxVirtualSize only if being passed a value of 0 or less. The default value used when none is explicitly provided is 2e+9. So to make it work in you case you just need to do:ptree->LoadBaskets(4e+9);.

Cheers,
Philippe.

Ok, that fixed it – for uncompressed data.

For compressed data it still won’t read it in though. Here are the two tests:

test A:

psi00:17:11:~/code/root/read/scripts/multiplicity/archive>root $ROOTALL/DU_data/2012_04_03_uncompressed.root
root [0] 
Attaching file /raid/home/pnpfuser/data_vx511/root_all/DU_data/2012_04_03_uncompressed.root as _file0...
root [1] ptree->LoadBaskets(4e+9);
root [2] gROOT->ProcessLine("ptree->Dump(); > ptree.dump");
root [3] gROOT->ProcessLine(".! grep TotalBuffers ptree.dump");
fTotalBuffers                 3364995072          ! Total number of bytes in branch buffers

So far so good…now, test B:

psi00:17:14:~/code/root/read/scripts/multiplicity/archive>root $ROOTALL/DU_data/compressed/2012_04_03_compressed.root 
root [0] 
Attaching file /raid/home/pnpfuser/data_vx511/root_all/DU_data/compressed/2012_04_03_compressed.root as _file0...
root [1] ptree->LoadBaskets(4e+9);
root [2] gROOT->ProcessLine("ptree->Dump(); > ptree.dump");
root [3] gROOT->ProcessLine(".! grep TotalBuffers ptree.dump");
fTotalBuffers                 2228673567232       ! Total number of bytes in branch buffers

(and, yes, the memory usage is tiny)

Hi,

Due to the data distribution in your files (some/many of the basket are not full), the deficiency lead to more than double counting the actual content. To get the good behavior with the deficent version of ROOT, for your files, you need to use a very large number (i.e. greater than what fTotalBuffers reports). For example:ptree->LoadBaskets(2328673567232LL);

Cheers,
Philippe.

Ok, that worked.

Hi,

Great, so the problem is really localized to what I found and is fixed :slight_smile:

Cheers,
Philippe.

Yes, thank you. Looking forward to the next release!