Skip to content

LHE to ROOT in pylhe #198

Answered by jpivarski
ganowak asked this question in Q&A
May 4, 2023 · 1 comments · 3 replies
Discussion options

You must be logged in to vote

If you go this route (LHE → Awkward Array → RDataFrame → ROOT file), then you'll need to convert the Awkward C++ iterators into generic C++ types, since Awkward C++ iterators ("ArrayView") can't be serialized into an on-disk file with RDataFrame::Snapshot. (The issue here is that iterators over an Awkward Array in RDataFrame don't "own" their data; they are pointers to a data structure in Python, and when ROOT tries to serialize that, it doesn't know that it's only saved a symlink...)

Perhaps I'm being overcautious, since your data types might be simple: if the columns in the RDataFrame are numeric types or jagged arrays of numbers (which can come from an Awkward Array), those types are a…

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@jpivarski
Comment options

Answer selected by ganowak
@ganowak
Comment options

@eduardo-rodrigues
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants