-
Notifications
You must be signed in to change notification settings - Fork 6
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
Issue reading TTrees with different branch name and "leaf" name #8
Comments
Hi @jcatmore, To be to be perfectly honest I'm not really much of a ROOT expert, so I don't really understand the difference between a tree and a leaf (I only wrote this That said, internally we call It's also worth noting that the version of the code here has diverged slightly from the ATLAS internal version (I didn't want to add this as an external dependency because it seemed like more work for our SW team, and then the ATLAS reviewers made me change the naming conventions). So while the issue you're having is probably going to be a problem for both versions, the code is slightly different between the two. |
Thanks @dguest - indeed, I think GetListOfBranches will do the trick. I'll try it locally myself and let you know. Thanks for pointing me to the relevant lines! James. |
Hi @jcatmore, Ok let me know if you have other issues. I don't quite remember why I used |
Hi Dan,
I've encountered an issue when using ttree2hdf5 (AnalysisBase-21.2.20) on flat n-tuple files where the branch name and leaf name are different, e.g.:
As you can see the leaf names have this "b_" prepended to them (to be honest I don't know why they were written like this, but this is what we have in our hands).
The converter seems to get tripped up by this, e.g.
The converter then sets off and runs over the file, producing an output file of expected size, but when inspected with h5py the contents just seem to contain the values of uninitialized variables (e.g. all information is lost). I confirmed that with the same release, when a TTree with the branch and leaf names are the same, it works fine and the expected values can be extracted from the h5 file.
Do you know if there is some way around this, or is the solution that whatever package wrote that n-tuple needs to be re-written so that it makes the branch and the leaf name the same?
Thanks and best wishes,
James
The text was updated successfully, but these errors were encountered: