-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Reading TH2I histograms #364
Comments
It would be useful to have an sample file. But in general, this happens when there's a private class evolution on C++ side and we haven't modeled that version in our code. the bootstrap struct you add for |
Hi Jerry, I attached a file with one of these objects. Hope that it helps, thanks. |
Thanks, I will have a look |
what I mean is if you look at https://root.cern.ch/doc/master/TH2_8h_source.html#l00262, it's currently on internal version 4, and we may be compatible to one of the versions but not the one presents in your root file -- this is the part where implementation == specification in .root files, dark times before RNTuple |
Can you try with #365 ? Does this make sense to you? If so, I'd add your sample file to the test samples and write a few tests. I think that it now also deals with julia> using UnROOT
julia> f = ROOTFile("test/samples/issue364_TH1I.root")
ROOTFile with 1 entry and 15 streamers.
test/samples/issue364_TH1I.root
└─ myHisto (TH2I)
julia> counts, edges, sumw2, nentries = UnROOT.parseTH(f["myHisto"])
(Int32[0 0 … 0 0; 254 254 … 0 0; … ; 254 251 … 0 0; 0 0 … 0 0], (-0.5:1.0:1919.5, 199.5:1.0:230.5), Int32[0 0 … 0 0; 254 254 … 0 0; … ; 254 251 … 0 0; 0 0 … 0 0], 59520.0)
julia> counts
1920×31 Matrix{Int32}:
0 0 0 0 0 … 0 0 0 0 0 0 0 0 0
254 254 254 251 253 0 0 0 0 0 0 0 0 0
254 254 254 253 247 0 0 0 0 0 0 0 0 0
254 254 254 253 254 0 0 0 0 0 0 0 0 0
254 254 253 254 249 0 0 0 0 0 0 0 0 0
254 254 254 254 254 … 0 0 0 0 0 0 0 0 0
254 254 254 254 252 0 0 0 0 0 0 0 0 0
254 254 253 254 253 0 0 0 0 0 0 0 0 0
254 254 254 253 246 0 0 0 0 0 0 0 0 0
254 254 254 254 254 0 0 0 0 0 0 0 0 0
254 254 254 253 247 … 0 0 0 0 0 0 0 0 0
⋮ ⋱ ⋮ ⋮
253 254 253 250 247 … 0 0 0 0 0 0 0 0 0
254 254 254 254 251 0 0 0 0 0 0 0 0 0
253 254 252 248 236 0 0 0 0 0 0 0 0 0
254 254 254 252 252 0 0 0 0 0 0 0 0 0
254 254 254 252 250 0 0 0 0 0 0 0 0 0
252 249 244 241 205 … 0 0 0 0 0 0 0 0 0
254 252 248 240 230 0 0 0 0 0 0 0 0 0
254 254 254 252 247 0 0 0 0 0 0 0 0 0
254 251 247 235 232 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0
julia> edges
(-0.5:1.0:1919.5, 199.5:1.0:230.5) |
Hi, noob here.
I'm trying to read
TH2I
histograms. With standard UnROOT, I get this error:I tried then to add the
TH1I
function to bootstrap.jl but this resulted in another kind of errorAm I doing things wrong? What is different with respect to float TArray based TH classes that makes this trivial solution not working?
Thanks for the help
MR
The text was updated successfully, but these errors were encountered: