autoray
Abstract your array operations.
Decision gist · record as of 2026-08-14
Yes. Autoray is actively maintained, has no dependencies, installs cleanly, and solves a real problem for anyone writing numerical code that might need to run on multiple tensor backends. The permissive Apache license and support for current Python versions make it a low-risk addition. Install it if you're building libraries or algorithms that should work across NumPy, PyTorch, JAX, or other array-like libraries.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.11 or later.
- Low friction installation with no runtime dependencies.
- Active maintenance with a release 7 days ago and recent commits; the project has been stable since its 2019 inception.
License · maintenance · safety
Apache-2.0 (permissive) — Apache-2.0 permissive license allows use in commercial and proprietary projects with minimal restrictions.
last release 2026-08-07 (7 days) · last repo commit 2026-08-12 · 174 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 658,067 downloads/mo, #5,472 on PyPI
Alternatives
Verify before relying
import autoray as ar
# Automatic dispatch based on array type
U, s, VH = ar.do("linalg.svd", x)
# Or use the numpy-like interface
from autoray import numpy as np
z = np.ones((3, 4))- Whether performance overhead of dispatch is negligible for tight loops or compute-heavy workloads.
- Completeness of coverage for less common NumPy functions across all supported backends.
What it is and what it does
Autoray is a lightweight library that lets you write array code once and run it on any NumPy-compatible tensor backend. Instead of writing separate code paths for NumPy, PyTorch, JAX, CuPy, and other array libraries, you call `ar.do()` with a function name and let autoray route the call to the right backend based on the input array type. It also provides a drop-in NumPy-like interface and utilities for registering custom backends and functions.
The library solves the problem of backend lock-in: if you build a numerical algorithm in NumPy but later want to run it on GPU with CuPy or use JAX for automatic differentiation, you can do so without rewriting your core logic. It's particularly useful for library authors who want to support multiple backends without maintaining separate implementations.
Use it for
- Write numerical algorithms that work on CPU (NumPy) or GPU (CuPy/PyTorch) without code duplication.
- Build libraries that support multiple tensor backends without explicit backend-specific branches.
- Migrate existing NumPy code to JAX or PyTorch by swapping the backend without rewriting function calls.
- Lazy evaluation and computation tracing across different backends using autoray's abstraction layer.
- Register custom tensor types or backend-specific optimizations while keeping the main algorithm backend-agnostic.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
Autoray is actively maintained, has no dependencies, installs cleanly, and solves a real problem for anyone writing numerical code that might need to run on multiple tensor backends. The permissive Apache license and support for current Python versions make it a low-risk addition. Install it if you're building libraries or algorithms that should work across NumPy, PyTorch, JAX, or other array-like libraries.
Install
autoray on PyPI
Before you install
Low friction installation with no runtime dependencies. Active maintenance with a release 7 days ago and recent commits; the project has been stable since its 2019 inception.
Requires Python 3.11 or later.
License in practice
Apache-2.0 permissive license allows use in commercial and proprietary projects with minimal restrictions.
Quickstart
import autoray as ar
# Automatic dispatch based on array type
U, s, VH = ar.do("linalg.svd", x)
# Or use the numpy-like interface
from autoray import numpy as np
z = np.ones((3, 4))
Verify before relying
- Whether performance overhead of dispatch is negligible for tight loops or compute-heavy workloads.
- Completeness of coverage for less common NumPy functions across all supported backends.
Package facts
| License | Apache-2.0 permissive |
| Python support | Supports the current Python release >=3.11 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | None |
| Maintenance | Actively maintained 7 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 658,067 / month, #5,472 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 4 - BetaIntended Audience :: Science/ResearchLicense :: OSI Approved :: Apache Software LicenseOperating System :: OS IndependentProgramming Language :: Python :: 3Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Topic :: Scientific/Engineering |
Evidence: autoray-0.10.1-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “numpy-like api abstraction”
- autorayAutoray provides automatic dispatch of array operations across…
- awkward0Manipulates complex, non-rectangular data structures (jagged arrays,…
- mlxMLX is an array framework for machine learning on Apple silicon that…
Give your agent the search over MCP, or paste the wish link into any chat.
More Scientific/Engineering packages
NumPy provides an N-dimensional array object and a comprehensive suite of mathematical, linear algebra, Fourier transform, and random number functions for scientific computing in Python.
pandas provides fast, flexible data structures (Series and DataFrame) for loading, cleaning, transforming, and analyzing labeled or relational data in Python.
scipy provides numerical algorithms for mathematics, science, and engineering—including optimization, integration, linear algebra, Fourier transforms, signal and image processing, and ODE solvers—built on numpy arrays.
scikit-learn provides a comprehensive Python library for supervised and unsupervised machine learning, including classification, regression, clustering, dimensionality reduction, and model evaluation tools built on NumPy and SciPy.
Install it if you need to train, evaluate, or deploy supervised or unsupervised learning models.
dill extends Python's pickle module to serialize and deserialize a much wider range of Python objects, including functions, lambdas, classes, and interpreter sessions, to byte streams for storage or network transmission.
Multiprocess is an enhanced fork of Python's standard multiprocessing library that uses dill for better serialization, allowing you to spawn processes with a threading-like API and share complex objects between them.
Install it if you use multiprocessing and encounter pickle serialization limits with lambdas or complex objects.
See also tensorly · array-api-compat · einx · pyvers · array-api-strict · torch · jaxtyping · einops · etils · mlx