DO NOT MERGE: print-outs to diagnose issue #3213 #3216
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
To narrow in on #3213, I made this branch that has print statements in the relevant methods (the
_getitem
chain for purely ragged numerical arrays for the slice[:, 0]
). I first verified that RecordArrays have nothing to do with it.The code to run here is
using s.parquet.zip from #3213 (comment).
Starting at the
Content._getitem
entry point (and disregarding some odd stuff that the CUDA version does before this point, which I don't understand), the output is:They diverge here:
awkward/src/awkward/contents/listarray.py
Lines 731 to 754 in 3ad5e20
The CPU implementation of
awkward_ListArray_getitem_next_at
is okay, but what comes out of the CUDA implementation is random junk. Since CuPy wraps bad indexes in its implementation of fancy indexing, we don't get a segfault, just wrong answers.Looking at awkward_ListArray_getitem_next_at.cpp and awkward_ListArray_getitem_next_at.cu, I don't immediately see the error—this ought to be a simple algorithm to parallelize. Maybe the issue is related to how it's called somehow? Is it missing a
syncthreads
to ensure that the result is assigned before moving on to the next step?