h2root question

lijowski@cosray2.wustl.edu
22 Jul 1998 17:46:26 -0000


Hello,

Below is output from the h2root program which converting RW HBOOK
ntuple into root ntuple. Each event consists of 39 entries.

Converting directory //example
Converting RWN with ID= 9000, nentries = 1018414
AutoSave Tree:h9000 after 1.00007e+08 bytes written
TFile Writing Name=make_cris_ntuple.root.0 Title=HBOOK file: make_cris_ntuple.rz.0 converted to ROOT
TFile** make_cris_ntuple.root.0 HBOOK file: make_cris_ntuple.rz.0 converted to ROOT
TFile* make_cris_ntuple.root.0 HBOOK file: make_cris_ntuple.rz.0 converted to ROOT
KEY: TTree h9000;2 CRIS
KEY: TTree h9000;1 CRIS

Reading of the converted ntuple with a macro
{
// read HBOOK generated ntuple and print number of entries

gROOT->Reset();

gBenchmark->Start("test_root_ntuple");
//
// Connect CRIS ROOT ntuple demonstration file generated by h2root
// from make_cris_ntuple.rz file
TFile *f1 = new TFile("/data3/users/lijowski/make_cris_ntuple.root.0");
f1 -> ls();

// connect a tree to an ntuple in the input file
TTree *t9000 = (TTree*)f1 -> Get("h9000;1");
t9000 -> Print();

Int_t Noevents = t9000 -> GetEntries();
printf(" No of Events %d\n", Noevents);

gBenchmark->Show("test_root_ntuple");
}
shows number of entries in the root ntuple to be equal to 636543.

Is data lost during the conversion process or is it something else?

Thanks

Michal Lijowski

------------------------------------------------------------------------
Michal Lijowski Washington University
Research Associate St. Louis, MO 63130-4899, USA
Department of Physics phone: 314-935-6285
Campus Box 1105 email: lijowski@cosray2.wustl.edu
------------------------------------------------------------------------