Appending arrays during uproot.iterate and writing them to pandas #956
Unanswered
alpetukhov
asked this question in
Q&A
Replies: 1 comment 2 replies
-
As a diagnostic step, call ak.validity_error(arr_conc) to see if the array is malformed. That's what Arrow is saying, but it would be good to corroborate it with our own error message. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hello everyone,
I'm going through the root files with the
uproot.iterate()
function, so I've created an array to store the resultsthen on every step I'm doing some transormation and appending the result to that array
I want to get a
DataFrame
that looks something like thisSo if I have an array that looks like this:
I need to make it an
ApacheArrow
and then pass it to theDataFrame
constructor (as I've read in Conversion through Apache Arrow)But the problem arises them I'm trying to run the
ak.to_arrow()
on array that was created withak.concatenate()
The
arr_conc
looks the same asarr_hand
but the last line fails with the following error:Is this the correct way to store the results during the iteration? If so, why does the
ak.to_arrow()
fails?Thanks in advance,
Aleksandr
P.S. Sorry if I'm flooding the GitHub discussions. Tell me if there's more appropriate place for such questions.
Beta Was this translation helpful? Give feedback.
All reactions