Skip to content

Commit 6fd3936

Browse files
authored
DaskDataFrame: Fix Chunks (#959)
For more than one chunk, the extent needs to add the offset to slice the right size.
1 parent a1e0b7a commit 6fd3936

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/binding/python/openpmd_api/DaskDataFrame.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020

2121

2222
def read_chunk_to_df(species, chunk):
23-
stride = np.s_[chunk.offset[0]:chunk.extent[0]]
23+
stride = np.s_[chunk.offset[0]:chunk.offset[0]+chunk.extent[0]]
2424
return species.to_df(stride)
2525

2626

0 commit comments

Comments
 (0)