Skip to content

Indexing with 0-dimensional arrays - #1013

Closed
neosunhan wants to merge 7 commits into
mainfrom
bug/1012-0-axis-slice
Closed

Indexing with 0-dimensional arrays#1013
neosunhan wants to merge 7 commits into
mainfrom
bug/1012-0-axis-slice

Conversation

@neosunhan

@neosunhan neosunhan commented Aug 21, 2022

Copy link
Copy Markdown
Collaborator

Description

  • Fixes a bug where adding a dimension (via slicing with None) on an array with an axis of length 0 results in an error.
  • Fixes a bug where using a 0-dimensional array to index results in an error.

Issue/s resolved: #1012, #1019

Changes proposed:

Type of change

  • Bug fix (non-breaking change which fixes an issue)

Due Diligence

  • All split configurations tested
  • Multiple dtypes tested in relevant functions
  • Documentation updated (if needed)
  • Updated changelog.md under the title "Pending Additions"

Does this change modify the behaviour of other functions? If so, which?

no

skip ci

@ghost

ghost commented Aug 21, 2022

Copy link
Copy Markdown
👇 Click on the image for a new way to code review
  • Make big changes easier — review code in small groups of related files

  • Know where to start — see the whole change at a glance

  • Take a code tour — explore the change with an interactive tour

  • Make comments and review — all fully sync’ed with github

    Try it now!

Review these changes using an interactive CodeSee Map

Legend

CodeSee Map Legend

@neosunhan neosunhan linked an issue Aug 29, 2022 that may be closed by this pull request
@neosunhan neosunhan changed the title Bug/1012 Slicing arrays with 0-length axis Indexing with 0-dimensional arrays Aug 29, 2022
@ClaudiaComito ClaudiaComito added the array API Related to the array API standard label Oct 5, 2022
@ClaudiaComito
ClaudiaComito marked this pull request as ready for review February 9, 2023 11:12
@ClaudiaComito

Copy link
Copy Markdown
Member

Thanks for this @neosunhan . These problems are being addressed in the general indexing overhaul #938 . I'm going to close this PR for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

array API Related to the array API standard GSoC

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Indexing with 0-dimensional key [Bug]: Slice error when array contains an axis of length 0

2 participants