Dear experts,
I’m looking into a tree with a branch v
of type std::vector<std::vector<float>>
. And I tried something trivial like this:
t->Draw("v >> h(100, 0, 1)", "v < 0");
Naively I was expecting an empty histogram. However there turns out to be some fills above 0. May I ask if I’m misusing Draw()
or this is a bug?
A small root file for reproducing the problem is attached test.root (5.9 KB)
. Thank you!
Best,
Kevin
ROOT Version: 6.16/00
Platform: CentOS Linux 7 (lxplus)
Compiler: gcc 4.8.5
@couet This seems to be a bug in ROOT 6.10 and newer.
couet
June 11, 2019, 8:17am
3
Yes that’s weird . We should get over/underflows not filled bins above 0.
I will look. Maybe be @pcanal also have some ideas.
couet
June 11, 2019, 8:24am
4
Note that the following is also wrong:
t->Draw("v ", "v < 0");
pcanal
June 11, 2019, 7:42pm
5
Indeed, this is a significant deficiency :(.
When the selection is sparse, some caching mechanism inside TTreeFormula gets the ‘instance’ number to use incorrectly. A fix is coming shortly.
See https://sft.its.cern.ch/jira/browse/ROOT-10170
Kevin1
June 12, 2019, 1:19am
7
Thank you all!
@pcanal I read the jira and the commit on github. This explanation with ‘instance’ makes a lot of sense. Thanks!
system
Closed
June 26, 2019, 1:24am
8
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.