Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support (most of) the elementwise functions in the Array API #22

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

mhvk
Copy link
Contributor

@mhvk mhvk commented Dec 30, 2024

Adds supports for ufuncs, and therewith for most of the element-wise functions. Also tests that for array types that support them, we can deal with passing in explicit outputs and with ufunc methods (reduce, reduce_at, at, accumulate).

p.s. This PR is perhaps better not squash-merged.

mhvk added 2 commits December 30, 2024 17:36
Do this via __array_ufunc__, using astropy machinery.  A few functions
are not yet supported as they are not ufuncs.

Relative to astropy Quantity, the main change is to change the output
machinery to take into account that our Quantity is immutable.
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.

1 participant