Skip to content

Array api#461

Merged
lshaw8317 merged 48 commits into
mainfrom
array-api
Sep 11, 2025
Merged

Array api#461
lshaw8317 merged 48 commits into
mainfrom
array-api

Conversation

@lshaw8317

@lshaw8317 lshaw8317 commented Sep 1, 2025

Copy link
Copy Markdown
Collaborator

First attempts towards array-api integration. Main changes are improvements to get/setitem indexing (allowing negative steps and pretty extensive boolean masks), adding basic methods (bool, float), functions (isnan, isinf, isfinite), creation functions which are simple extensions of existing functions (ones_like, zeros_like etc.) and handling empty/zero-dimensional edge cases.
Improved numerical stability of linspace and arange, as well as type handling for reductions.

Some optimisations can still be done for indexing (see TODOs in files), as well as asarray, astype and broadcast_to. See #466 for overall status.

@FrancescAlted FrancescAlted left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have some comments

Comment thread tests/array-api-xfails.txt Outdated
Comment thread src/blosc2/lazyexpr.py Outdated
Comment thread tests/ndarray/test_setitem.py Outdated
@lshaw8317

Copy link
Copy Markdown
Collaborator Author

pre-commit.ci autofix

@lshaw8317
lshaw8317 marked this pull request as ready for review September 11, 2025 11:57
@lshaw8317
lshaw8317 merged commit cef7af5 into main Sep 11, 2025
12 checks passed
@lshaw8317
lshaw8317 deleted the array-api branch September 11, 2025 11:58

@FrancescAlted FrancescAlted left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job! I have two minor comments.

Comment thread src/blosc2/blosc2_ext.pyx
Comment thread src/blosc2/lazyexpr.py
@lshaw8317 lshaw8317 mentioned this pull request Feb 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants