-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix bug in basic slicing of empty arrays
Reproducer provided by @ndgrigorian: ``` import dpctl.tensor as dpt x = dpt.ones((0, 10)) y = dpt.moveaxis(x, 1, 0) y[1] # raises ValueError ``` Now this returns empty 1d array like `y[0]` does. A test is added for both integral basic indexing, and for simple slice.
- Loading branch information
1 parent
d840cee
commit d221a81
Showing
2 changed files
with
32 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters