burn-rocm 0.22.0

ROCm HIP backend for the Burn framework
docs.rs failed to build burn-rocm-0.22.0
Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
Visit the last successful build: burn-rocm-0.22.0-pre.3

Burn ROCm Backend

Burn ROCm backend for AMD GPUs

Current Crates.io Version Documentation license

This crate provides the ROCm (HIP) runtime of Burn's CubeCL backend, using CubeCL and cubecl-hip-sys.

Usage Example

For application code, enable Burn's rocm feature and select the device at runtime:

burn = { version = "0.22", features = ["rocm"] }
use burn::tensor::{Device, Tensor};

let device = Device::rocm(0);
let input = Tensor::<2>::ones([2, 3], &device);
let output = input + 1.0;

For training, enable autodiff (also enabled by train) and use device.autodiff() before initializing model parameters and inputs.

Requirements

  • Linux with an AMD GPU supported by ROCm.
  • A ROCm installation at run time. The HIP libraries are loaded when the first device is created, so building does not require ROCm. Burn 0.22 uses the bindings for HIP 60850 (ROCm 7.14); see cubecl-hip-sys for how HIP and ROCm versions map.
  • Set ROCM_PATH or HIP_PATH when ROCm is not installed in its default location (often /opt/rocm).

Part of the Burn deep learning framework. See the Burn Book and the API documentation.