Hi,
while reading ROOT files created with different versions of ROOT(5.34.36 and 6.26.06 respectively) with uproot, I stumble upon a problem reading out the fMilliSec value of the TTime object. In my specific case I have a class having a TTime object as one -private- data member, but I post here below a minimal example to show the problem. I used this simple macro (I do not care about filling meaningful values or more entries for the moment):
void create_tree_ttime(TString outname){
TTime *mtime = new TTime();
TFile f(outname.Data(),"recreate");
TTree *t3 = new TTree("Events","Time");
t3->Branch("MTime", &mtime);
for (Int_t ev = 0; ev <1; ev++){
t3->Fill();
}
f.Write();
t3->Print();
}
So, if I run this under ROOT 5.34.36 I get:
******************************************************************************
*Tree :Events : Time *
*Entries : 1 : Total = 1499 bytes File Size = 588 *
* : : Tree compression factor = 1.00 *
******************************************************************************
*Branch :MTime *
*Entries : 1 : BranchElement (see below) *
*............................................................................*
*Br 0 :fMilliSec : Long64_t *
*Entries : 1 : Total Size= 588 bytes File Size = 86 *
*Baskets : 1 : Basket Size= 32000 bytes Compression= 1.00 *
*............................................................................*
while for ROOT 6.26.06 I get:
******************************************************************************
*Tree :Events : Time *
*Entries : 1 : Total = 989 bytes File Size = 476 *
* : : Tree compression factor = 1.00 *
******************************************************************************
*Br 0 :MTime : TTime *
*Entries : 1 : Total Size= 597 bytes File Size = 100 *
*Baskets : 1 : Basket Size= 32000 bytes Compression= 1.00 *
*............................................................................*
Because of this, in the case of ROOT6 I cannot read out directly the value of fMilliSec using uproot. I did not see any visible change in the class TTime. What is the reason of the different way the ROOT files are created in this case? Is it possible to “recover” the ROOT5 behavior in ROOT6?
Best,
Alessio