Problem limiting the number of processed events

I using this method do run my selector:

Long64_t Process(TFileCollection* fc, const char* selector, Option_t* option = "", Long64_t nentries = -1, Long64_t firstentry = 0)

with nentries = 30000

when the process window pop up I can read: “Number of events to process = 30000” or something similar. But in a few seconds this number change to something like 84113. Why?

But the most important thing is that if I rerun the program this number change! For example the last time it was 73254.

I have an hypostesis: proof run GetEntries() on all the files in the chain and it stops when the number of total entries are greater than 30000. It takes al the scanned files and process it, so the number of processed events it is greater than 30000. GetEntries() is run in paraller on different workers, so the order of scanned files is random, so the number vary every times.

Am I correct? I think this is not a good solution in particular if you are debugging your code. I need a way to run the code and get exactly the same result every time.

This problem should have been just fixed in the trunk, 5-32-patches an 5-30-patches.
Are you in position to try anyone of those and confirm?

G. Ganis

[quote=“ganis”]This problem should have been just fixed in the trunk, 5-32-patches an 5-30-patches.
Are you in position to try anyone of those and confirm?

G. Ganis[/quote]

no, sorry, I’m using 5.28.

I’ve ported the fix to 5-28-patches.

G. Ganis

[quote=“ganis”]I’ve ported the fix to 5-28-patches.

G. Ganis[/quote]

thanks, no, my problem is not changing version, but reinstall ROOT. I am talking with administrators to move to 5.30

Well, but none of the current 5-30 tags includes the fix.
There should be a new tag soon (5-30-04) but the date has not yet been fixed.

G. Ganis

[quote=“ganis”]Well, but none of the current 5-30 tags includes the fix.
There should be a new tag soon (5-30-04) but the date has not yet been fixed.

G. Ganis[/quote]

The patch release of ROOT 5.30/04 is now available. :smiley: