This release is a pre-release and may not be stable for production use.
PyTorch RBLN
About
PyTorch RBLN (torch-rbln) is a PyTorch extension that allows natural use of Rebellions NPU compute within PyTorch. By implementing eager mode, which operates in a define-by-run fashion, it supports the full lifecycle of model development, deployment, and serving in the PyTorch ecosystem. It is also convenient for debugging and related workflows.
The same interface style as CPU and GPU applies — the rbln device, torch.rbln, and torch.compile — so developers and customers can target RBLN NPUs with familiar APIs. Operations on rbln tensors are integrated via PyTorch’s out-of-tree extension path; execution is coordinated with the RBLN compiler and runtime (rebel-compiler).
PyTorch RBLN is currently in beta and under active development. APIs may change between releases, backward compatibility is not guaranteed, and production use is not recommended yet. For the full notice, architecture, supported operators, and tutorials, see PyTorch RBLN — Overview in the RBLN SDK documentation. For wheels, rebel-compiler, and building from source, see Installation.
Getting started
Prerequisites
- Python 3.10–3.14 — see Installation — Requirements (source build).
rebel-compiler— required; not installed withtorch-rblnunless you request theruntimeextra (torch-rbln[runtime]). Use an RBLN Portal account and the RBLN package index as described in Install pre-built wheels.
Install pre-built wheels
torch-rbln (public wheel). Install torch from the PyTorch CPU index first, then torch-rbln from PyPI.
pip3 install torch-rbln --extra-index-url https://download.pytorch.org/whl/cpu
For rebel-compiler and the rest of the setup, see Prerequisites above and Installation.
Build from source
- Install
uv(see Installation — Prerequisites in the SDK docs). - Configure access to the RBLN package index (see Authenticate to the RBLN package index below).
- Follow Build from source (venv,
rebel-compiler, editable build, manual steps).
git clone https://github.com/RBLN-SW/torch-rbln.git
cd torch-rbln
uv venv .venv && source .venv/bin/activate
./tools/dev-setup.sh pypi
rebel-compiler must be available in the same environment before the torch-rbln build finishes (see Prerequisites).
Authenticate to the RBLN package index
rebel-compiler is installed from the RBLN package index (pypi.rbln.ai), which requires an RBLN Portal account. Without credentials, ./tools/dev-setup.sh pypi fails with:
❌ Cannot reach any rbln pypi index (no permission or network error).
Add your RBLN Portal credentials to ~/.netrc so pip/uv can authenticate:
machine pypi.rbln.ai
login <your-rbln-portal-id>
password <your-rbln-portal-password>
Then restrict its permissions (tools refuse a world-readable .netrc):
chmod 600 ~/.netrc
Alternatively, if you are using uv, you can provide the credentials via
environment variables instead of ~/.netrc:
export UV_INDEX_RBLN_USERNAME=<your-rbln-portal-id>
export UV_INDEX_RBLN_PASSWORD=<your-rbln-portal-password>
Re-run ./tools/dev-setup.sh pypi once the credentials are in place.
Documentation
RBLN SDK (hosted)
- Overview — design, components, and entry points into the PyTorch RBLN docs
- Installation — pre-built wheels,
rebel-compiler, build from source - Running and debugging with PyTorch RBLN — basic usage and debugging
- Running a LLM model: Llama3.2-1B —
transformersexample - Supported Ops — operator coverage
- APIs — Python API reference
- Troubleshooting —
librbln/torch_rbln.diagnose, core dumps, logging, dtype / CPU, memory (maintained in the RBLN SDK docs)
This repository
- Configuration — environment variables and runtime options
- Test Guide — local test runs
- Linting — code style and lint
- Third-party update — PyTorch pin, upstream files,
rebel-compilerversion bumps inpyproject.toml - Release Process — release lifecycle, versioning, tagging, and publication
Contributing
See docs/CONTRIBUTING.md.
License
Apache License 2.0 — see LICENSE and NOTICE.
Contact
- Community: discuss.rebellions.ai
- Email: support@rebellions.ai
Metadata
Release files for torch-rbln 0.12.1a1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distributions (wheels)
| File | Actions Reset | |||
|---|---|---|---|---|
| torch_rbln-0.12.1a1-cp314-cp314-manylinux_2_34_x86_64.whl | CPython 3.14 | CPython 3.14 | Linux glibc 2.34+ x86-64 | Details for torch_rbln-0.12.1a1-cp314-cp314-manylinux_2_34_x86_64.whl |
| torch_rbln-0.12.1a1-cp313-cp313-manylinux_2_34_x86_64.whl | CPython 3.13 | CPython 3.13 | Linux glibc 2.34+ x86-64 | Details for torch_rbln-0.12.1a1-cp313-cp313-manylinux_2_34_x86_64.whl |
| torch_rbln-0.12.1a1-cp312-cp312-manylinux_2_34_x86_64.whl | CPython 3.12 | CPython 3.12 | Linux glibc 2.34+ x86-64 | Details for torch_rbln-0.12.1a1-cp312-cp312-manylinux_2_34_x86_64.whl |
| torch_rbln-0.12.1a1-cp311-cp311-manylinux_2_34_x86_64.whl | CPython 3.11 | CPython 3.11 | Linux glibc 2.34+ x86-64 | Details for torch_rbln-0.12.1a1-cp311-cp311-manylinux_2_34_x86_64.whl |
| torch_rbln-0.12.1a1-cp310-cp310-manylinux_2_34_x86_64.whl | CPython 3.10 | CPython 3.10 | Linux glibc 2.34+ x86-64 | Details for torch_rbln-0.12.1a1-cp310-cp310-manylinux_2_34_x86_64.whl |
Total release size: 7.6 MB
Release files / torch_rbln-0.12.1a1-cp314-cp314-manylinux_2_34_x86_64.whl
| Download URL | torch_rbln-0.12.1a1-cp314-cp314-manylinux_2_34_x86_64.whl |
|---|---|
| Size | 1.5 MB |
| Tags | CPython 3.14 Linux glibc 2.34+ x86-64 |
|
SHA-256 checksum How to use checksums |
f5d5d696a1c95c21c883f4d7d04c5020015d7bca4fb346e238ee5e6e1454fb7b
|
|
BLAKE2b-256 checksum How to use checksums |
177af8edb321fb2bed898133f5b530d022dc8bbe80685245fd06f6a759c5eeb2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Release files / torch_rbln-0.12.1a1-cp313-cp313-manylinux_2_34_x86_64.whl
| Download URL | torch_rbln-0.12.1a1-cp313-cp313-manylinux_2_34_x86_64.whl |
|---|---|
| Size | 1.5 MB |
| Tags | CPython 3.13 Linux glibc 2.34+ x86-64 |
|
SHA-256 checksum How to use checksums |
a6333860f6e9b4cfdf950c9ea68350ef290fda8902a0cc3d63a4017946eb54f0
|
|
BLAKE2b-256 checksum How to use checksums |
996f728fa7b29b6e9cd7b80b1a3b247366e6b67914cc74a86b40f433e9e049ec
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Release files / torch_rbln-0.12.1a1-cp312-cp312-manylinux_2_34_x86_64.whl
| Download URL | torch_rbln-0.12.1a1-cp312-cp312-manylinux_2_34_x86_64.whl |
|---|---|
| Size | 1.5 MB |
| Tags | CPython 3.12 Linux glibc 2.34+ x86-64 |
|
SHA-256 checksum How to use checksums |
9187b66e4e055dff70274aac286bfe0ec018b850d3e29429d5c52d1217613cae
|
|
BLAKE2b-256 checksum How to use checksums |
59a4524e9a96fbef65f49a51f611c673779f6227a1a856b981971701023f49c5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Release files / torch_rbln-0.12.1a1-cp311-cp311-manylinux_2_34_x86_64.whl
| Download URL | torch_rbln-0.12.1a1-cp311-cp311-manylinux_2_34_x86_64.whl |
|---|---|
| Size | 1.5 MB |
| Tags | CPython 3.11 Linux glibc 2.34+ x86-64 |
|
SHA-256 checksum How to use checksums |
01be7d74ee3bbbbec9399255c5f12c15d8c9401eb974db03bf73edd3110a3f3b
|
|
BLAKE2b-256 checksum How to use checksums |
9a7fa79a8de2bcceb605561147caccc65da5945f5517bfb15aa60754e9c582d9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Release files / torch_rbln-0.12.1a1-cp310-cp310-manylinux_2_34_x86_64.whl
| Download URL | torch_rbln-0.12.1a1-cp310-cp310-manylinux_2_34_x86_64.whl |
|---|---|
| Size | 1.5 MB |
| Tags | CPython 3.10 Linux glibc 2.34+ x86-64 |
|
SHA-256 checksum How to use checksums |
ed267ae7afe6a893c85f06727b856b386370c1b4140928e9ada00ae787ebb91e
|
|
BLAKE2b-256 checksum How to use checksums |
d8f5969e752c107409ba288174d27a0ccb0b1fc5298dc84505f966bd2db2feb7
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Security for torch-rbln 0.12.1a1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.