array-api
array-api copied to clipboard
RFC document, tooling and other content related to the array API standard
gh-427 summarizes the rationale for requiring that inputs to `real`, `imag`, and `conj` be complex-valued: > This PR chooses to be more restrictive based on the premise that consumers should...
I'm finding the ``broadcast_to`` [specification](https://data-apis.org/array-api/latest/API_specification/generated/array_api.broadcast_to.html#broadcast-to) a little underspecified. In the docs we see the following for the shape parameter: > shape (Tuple[int, ...]) – array shape. Must be compatible with...
In array-api-strict, I've had this behavior ```py >>> import array_api_strict as xp >>> xp.asarray(0, dtype=xp.int64) < xp.asarray(1, dtype=xp.uint64) TypeError: array_api_strict.int64 and array_api_strict.uint64 cannot be type promoted together ``` However, this...
Does the language here look OK? Should we add anything along the lines of "comparisons with promotable types should promote first" (so that the result is numerically correct)? Fixes #819.
Fixes #818 I also added a cross-reference to the indexing page to the `__getitem__` and `__setitem__` docs.
Looked like these subscripts were omitted. LMK if this should be adjusted in 2012/2013 standards, but I think the intent is obvious enough that it doesn't need to be fixed...
The array API standard is now clear (in [Type Promotion Rules](https://data-apis.org/array-api/latest/API_specification/type_promotion.html)):  This means that following does not have defined behavior: ```python3 x = xp.asarray([1., 2., 3.]) x + 1j...
Several parts of the Array API standard assume that array objects are mutable. Some array API implementations (notably JAX) do not support mutating array objects. This has led to array...
x-ref https://github.com/data-apis/array-api-extra/pull/10/files#r1776010210 While implementing a simple `cov` in array-api-extra (https://github.com/data-apis/array-api-extra/pull/10) I found that `xp.mean` does not support complex input. @kgryte suggested opening an issue over here as the arithmetic mean...
## Motivation The [`sparse`](https://github.com/pydata/sparse) (also called PyData/Sparse) development team have been working on integration efforts with the ecosystem, most notably with SciPy, scikit-learn and others, with CuPy, PyTorch, JAX and...