Skip to main content

A tinygrad-inspired robotics framework for Unitree Go2

Project description

rfx logo

rfx: A ground-up replacement for ROS, built for the foundation model era.

Homepage | Documentation | Discord

CI License: MIT Python Discord


rfx is robotics infrastructure for the data and embodiment layer:

  • Rust core for real-time performance and safety
  • Python SDK for fast research iteration
  • ROS interop bindings for incremental migration
  • Simulation, teleoperation, and hardware pipelines designed for scalable data collection
  • rfxJIT IR/compiler/runtime that lowers and executes kernels across cpu/cuda/metal

ROS became the default robotics middleware over the last 15+ years, but it was designed for component message passing, not model-first robotics and large-scale data pipelines. rfx is designed from first principles for that new workflow.

It is inspired by PyTorch (ergonomics), JAX (functional transforms and IR-based AD), and TVM (scheduling/codegen), while explicitly targeting ROS replacement over time.


Repository layout

rfx/            Rust core + Python package + tests + configs + examples
rfxJIT/         IR compiler and runtime (cpu/cuda/metal backends)
cli/            Command-line tools
docs/           Internal docs, perf baselines, contributor workflows
scripts/        Setup and CI helper scripts
.github/        GitHub Actions workflows

Core interface

All robots in rfx implement the same three-method protocol:

observation = robot.observe()
robot.act(action)
robot.reset()

This interface is consistent across simulation, real hardware, and teleoperation.

Installation

The recommended install for contributors is from source.

From source

git clone https://github.com/quantbagel/rfx.git
cd rfx
bash scripts/setup-from-source.sh

Direct (GitHub)

uv pip install git+https://github.com/quantbagel/rfx.git

PyPI (after release)

uv pip install rfx-sdk
uv pip install rfx-sdk-sim rfx-sdk-go2 rfx-sdk-lerobot

TestPyPI (current test channel)

uv pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple \
  rfx-sdk rfx-sdk-sim rfx-sdk-go2 rfx-sdk-lerobot torch

Direct (local path)

uv venv .venv
uv pip install --python .venv/bin/python -e /absolute/path/to/rfx

Runtime switches (rfxJIT)

export RFX_JIT=1
export RFX_JIT_BACKEND=auto  # auto|cpu|cuda|metal
export RFX_JIT_STRICT=0      # 1 to raise if requested backend fails

With RFX_JIT=1, @rfx.policy(jit=True) can route NumPy policy calls through rfxJIT while preserving fallback behavior.

Quality and performance checks

Run local pre-push checks:

./.venv/bin/pre-commit run --all-files --hook-stage pre-push

Run the CPU perf gate used in CI:

bash scripts/perf-check.sh \
  --baseline docs/perf/baselines/rfxjit_microkernels_cpu.json \
  --backend cpu \
  --threshold-pct 10

Documentation

  • Full documentation: deepwiki.com/quantbagel/rfx
  • Docs entrypoint: docs/README.md
  • SO101 quickstart: docs/so101.md
  • Contributor workflow: docs/workflow.md
  • Performance workflow: docs/perf/README.md
  • Contributing guide: CONTRIBUTING.md

Community and support

License

MIT. See LICENSE.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

rfx_sdk-0.1.3-cp313-cp313-win_amd64.whl (1.4 MB view details)

Uploaded CPython 3.13Windows x86-64

rfx_sdk-0.1.3-cp313-cp313-macosx_11_0_arm64.whl (1.3 MB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

File details

Details for the file rfx_sdk-0.1.3-cp313-cp313-win_amd64.whl.

File metadata

  • Download URL: rfx_sdk-0.1.3-cp313-cp313-win_amd64.whl
  • Upload date:
  • Size: 1.4 MB
  • Tags: CPython 3.13, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.4 {"installer":{"name":"uv","version":"0.10.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for rfx_sdk-0.1.3-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 1008e47ae2f1f7dde7736aa7eb97b83acffc897e04710f1dc72abbc991d48c58
MD5 a944a108e1bff91baafb6c05730588ab
BLAKE2b-256 a51cfe7332c7c2d0daf3ef0c141e0d1e0e4c97b82a528d948f8014dd8eff7559

See more details on using hashes here.

File details

Details for the file rfx_sdk-0.1.3-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

  • Download URL: rfx_sdk-0.1.3-cp313-cp313-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 1.3 MB
  • Tags: CPython 3.13, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.4 {"installer":{"name":"uv","version":"0.10.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for rfx_sdk-0.1.3-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 0c0b4817a18e8b26c621ba8ffbfe2bb1a9ffd0f3b3e076e5f1746de51ebaa8ec
MD5 7573fed41d807fa98de30afb08d88b83
BLAKE2b-256 c1339d706573d406d5fb1d8e8649fd9995cf49035fb3b7fdbad03446f7906d29

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page