-
Notifications
You must be signed in to change notification settings - Fork 29
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 2024.12 #223
Comments
take_along_axis in dask is a very complicated matter when there are multiple chunks: dask/dask#3663 |
Can we start implementing the draft standard in array API compat, especially Before scalars were allowed in xp = array_namespace(x, y)
x = xp.asarray(x)
y = xp.asarray(y)
dtype = result_type(x, y) especially since the following would not be acceptable according to the standard if one of xp = array_namespace(x, y)
dtype = result_type(x, y) # fails for array_api_strict if `x` or `y` is a Python scalar But if the intent of from array_api_compat import array_namespace, numpy as np
x = np.asarray([1, 2, 3], dtype=np.float32)
y = 3.
xp = array_namespace(x, y)
x_ = np.asarray(x) # float32
y_ = xp.asarray(y) # float64
xp.result_type(x_, y_) # float64
(x*y).dtype # float32 So currently, we are between a rock and a hard place: the code we might naturally write now (and code that was OK before scalars would be accepted) is not really correct now that scalars can be involved. Of course there are workarounds, but rather than writing workarounds and simplifying them once the standard is published and |
Yes, the work is ongoing, help appreciated :-). The aim is indeed to have The current state is:
|
Great. I was tempted to update |
I'd say it's totally fair game. We won't merge PRs to -strict and -compat until a matching spec PR lands, that's pretty much the only boundary condition. |
This is a tracking issue for the 2024.12 revision support in array-api-compat.
The 2024.12 is in a draft still, so this list below is preliminary:
diff
: Add draft support for 2024.12 revision #224nextafter
: available in unwrapped namespacescumulative_prod
: Add draft support for 2024.12 revision #224reciprocal
: available in unwrapped namespacescount_nonzero
: Add draft support for 2024.12 revision #224take_along_axis
: Add draft support for 2024.12 revision #224max_dimensions
incapabilities
: Add draft support for 2024.12 revision #224mean
is defined for complex arrays : defined in unwrapped namespacesresult_type
accepts python scalars : Add draft support for 2024.12 revision #224The text was updated successfully, but these errors were encountered: