Hi rooters,
I encounterd a following problem. When a file is opened after the
tree definition, there seems to be a problem with the compression
level for the tree. As you can see it is 499.94 for the tree while it
is set to 1 for the file.
I had this programmed in the class, when the tree is opened anyway even if
the file is not specified (then it is in the memory).
I am using Version 3.03/05 for suse linux.
Miro Helbich
a macro:
{
int fEventNr;
// OutputTree
TTree* fTruthTree = new TTree("h1","MC Truth from LumiFast");
fTruthTree->Branch("EventNr",&fEventNr,"EventNr/I");
TFile* fTruthFile = new TFile("test.root","RECREATE","LFast file",1);
fTruthTree->SetDirectory(fTruthFile);
for (int i=0;i<50000;i++) {
fEventNr = i;
fTruthTree->Fill();
}
fTruthTree->Print();
cout << "Compression factor: "<<fTruthFile->GetCompressionFactor()<<endl;
cout << "Compression level : "<<fTruthFile->GetCompressionLevel()<<endl;
}
an output:
root [0] .x bug.C
R__zip: bad pack level
R__zip: bad pack level
R__zip: bad pack level
R__zip: bad pack level
R__zip: bad pack level
R__zip: bad pack level
******************************************************************************
*Tree :h1 : MC Truth from LumiFast *
*Entries : 50000 : Total = 392424 bytes File Size = 384 *
* : : Tree compression factor = 499.94 *
******************************************************************************
*Br 0 :EventNr : EventNr/I *
*Entries : 50000 : Total Size= 200448 bytes File Size = 384 *
*Baskets : 6 : Basket Size= 32000 bytes Compression= 499.94 *
*............................................................................*
Compression factor: 1
Compression level : 1
root [1]
This archive was generated by hypermail 2b29 : Sat Jan 04 2003 - 23:50:54 MET