Inconsistency error message in TTreeCache::FillBuffer when using CloneTree and TTreeReader


I am skimming a TChain while using a TTreeReader, and on a few files out of the few hundred that I am processing, I get the following error message:

Error in TTreeCache::FillBuffer: Inconsistency: fCurrentClusterStart=0 fEntryCurrent=239400 fNextClusterStart=240234 but fEntryCurrent should not be in between the two

The code I am using is basically the same as here:

In particular, I am using the suggestion from @pcanal to load the tree entry before filling my skim tree:

chain->GetEntry( reader.GetCurrentEntry() );

If I comment out the GetEntry line, I do not get the error messages. Are these messages harmful or should the resulting skim tree be OK?

Thanks very much,

ROOT Version: 6.16/00
Platform: CentOS Cern 7 x86_64
Compiler: Not Provided

Hi Seth,
@pcanal is the authority on the subject, but he’s currently travelling.

I think those error messages might signal a real problem.
It’s easy to check: you can remove all cuts and see if the copied tree contains exactly the same values of the input tree (hopefully, you’ll still get the error messages even with no cuts).

Hard to tell what the problem is without code, though: it would be great if you could provide a small reproducer for your problem.

In general I would not recommend to mix TTreeReader with a TChain::CloneTree. There are other ways to do a skim, e.g. RDataFrame or, for simple selections, rooteventselector (a python script that’s distributed together with ROOT).


This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.

The message are only harmfull as in sofar as they indicate a reduced performance. If I recall correctly this deficiency has already been resolved. Can you try with v6.18/00?