einops
A new flavour of deep learning operations
Install
einops on PyPI
pip
pip install einopsuv
uv add einopspoetry
poetry add einopsPackage facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.9) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | none |
| Maintenance | actively maintained — 199 days since the last release |
| Last repo commit | |
| First released | |
| Popularity | one of the top 1,000 most-downloaded packages on PyPI (30-day window, as of 2026-08-13) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-13) |
Evidence: einops-0.8.2-py3-none-any.whl
Keywords: deep learning, einops, machine learning, neural networks, scientific computations, tensor manipulation
About einops
from the package's own PyPI description — quoted content, verbatim
<!-- <a href='http://arogozhnikov.github.io/images/einops/einops_video.mp4' > <div align="center"> <img src="http://arogozhnikov.github.io/images/einops/einops_video.gif" alt="einops package examples" /> <br> <small><a href='http://arogozhnikov.github.io/images/einops/einops_video.mp4'>This video in high quality (mp4)</a></small> <br><br> </div> </a> -->
<!-- this link magically rendered as video on github readme, unfortunately not in docs -->
https://user-images.githubusercontent.com/6318811/177030658-66f0eb5d-e136-44d8-99c9-86ae298ead5b.mp4
einops
Run tests (image) PyPI version (image) Documentation (image) Supported python versions (image)
Flexible and powerful tensor operations for readable and reliable code. <br /> Supports numpy, pytorch, tensorflow, jax, and...
Read as markdown · JSON record · Source repository · Homepage
AI interpretation — verify before relying
AI-generated interpretation of the package facts above; every digit, version, license, or vulnerability id it cites is grounded in the facts already shown on this page
Einops provides readable tensor operations (rearrange, reduce, repeat, pack, unpack, einsum) that work across numpy, PyTorch, TensorFlow, JAX, and other frameworks, making multidimensional array manipulation explicit and maintainable.
Installation is straightforward with no runtime dependencies; the package is actively maintained with a recent release (199 days ago) and strong community adoption (9573 GitHub stars).
MIT license permits unrestricted use, modification, and distribution in both open-source and proprietary projects with minimal obligations.
Usage
pip install einops
from einops import rearrange, reduce, repeat
# Rearrange tensor dimensions
output = rearrange(input_tensor, 'b c h w -> b (c h w)')
# Reduce with operation
output = reduce(input_tensor, 'b c (h h2) (w w2) -> b h w c', 'mean', h2=2, w2=2)
# Repeat along new axis
output = repeat(input_tensor, 'h w -> h w c', c=3)
Requires Python 3.9 or later; no compiled dependencies.
Verdict: Einops is a mature, well-maintained library with zero security vulnerabilities and permissive MIT licensing. Its zero runtime dependencies and low install friction make it a low-risk addition to any project. Active development and broad framework support make it a reliable choice for readable tensor operations.
Needs verification
- Performance overhead of einops operations compared to native framework equivalents.
- Compatibility guarantees with specific versions of PyTorch, TensorFlow, or JAX.
- Production-readiness of torch.compile support and its performance implications.
Similar packages
permissive · top 1,000 on PyPI
torchpermissive · top 1,000 on PyPI
opt-einsumpermissive · top 1,000 on PyPI
python-json-loggerpermissive · top 1,000 on PyPI
thincpermissive · top 1,000 on PyPI
nvidia-cusparseunclear · top 1,000 on PyPI
safetensorspermissive · top 1,000 on PyPI
torchvisionpermissive · top 1,000 on PyPI
datasetspermissive · top 1,000 on PyPI
nvidia-cusparse-cu12unclear · top 1,000 on PyPI