TheRock package versioning

August 25, 2026 ยท View on GitHub

We build and distribute packages for a variety of projects across multiple packaging systems, release channels, and operating systems.

This document describes the version schemes we use for those packages.

Table of contents:

Overview

Generally we use semantic versioning (SemVer) for most projects, e.g. X.Y.Z where

  • X is the "major version"
  • Y is the "minor version"
  • Z is the "patch version"

The version.json file at the root of TheRock defines the base version used for packages:

{
  "rocm-version": "10.1.0"
}

Note

Subprojects may have their own independent library versions (for example HIPBLASLT_PROJECT_VERSION in rocm-libraries/projects/hipblaslt/CMakeLists.txt):

set(HIPBLASLT_PROJECT_VERSION "1.4.1" CACHE STRING "Semantic version string.")

Constraints and design guidelines

We are limited by what each packaging system accepts as valid versions.

For Python packages see:

For Debain packages see:

For Fedora packages see:

Distribution channels (dev, nightly, release)

Most users are expected to use stable releases, but several other distribution channels are also available and may be of interest to project developers, users who want early previews of upcoming releases, and QA/test team members.

Distribution channelBase URLSource of builds
stable releaseshttps://stable.repo.amd.com/rocm/Manually promoted prereleases
prereleaseshttps://rc.repo.amd.com/rocm/Manually triggered workflows in rockrel
nightly releaseshttps://nightly.repo.amd.com/rocm/Scheduled workflows in rockrel
BKC releaseshttps://bkc.repo.amd.com/rocm/Workflows in rockrel
dev releaseshttps://dev.repo.amd.com/rocm/Manually triggered test workflows in TheRock and rockrel
dev buildsNo central indexLocal builds and per-commit workflows in TheRock,
rocm-libraries, rocm-systems, etc.

Each distribution channel has an aggregate Python index that can be passed to package managers like pip (see RELEASES.md - Installing multi-arch Python packages for details). For example:

pip install --index-url=https://nightly.repo.amd.com/rocm/whl-next/ rocm
pip install --index-url=https://dev.repo.amd.com/rocm/whl-next/ rocm

The new layout starts with ROCm 10.1 nightlies and ROCm 10.0 stable releases. Earlier releases remain in the legacy multi-arch release locations.

With the exception of "dev releases", each distribution channel only contains release artifacts of the matching release type. The "dev releases" channel can contain any type of release.

Release branch metadata

The version.json file also contains a generic release-metadata object hosting fields that release types can interpret as needed. These fields should be empty on the base branch and may be populated by commits on release branches:

{
  "rocm-version": "10.1.0",
  "release-metadata": {
    // Empty on the base branch.
    "base-date": ""
    // A BKC release branch could set base-date to 20260811 for a package
    // version like 10.1.0a20260811+bkc.20260813 where
    //   * 20260811 is fixed to when the release branch forked from mainline
    //   * 20260813 is the current date
  }
}

Python package versions

Python package versions are handled by scripts:

The script produces these versions for each release type:

Release typeVersion formatVersion example
stableX.Y.Z7.10.0
prereleaseX.Y.ZrcN7.10.0rc0
(The first release candidate for that stable release)
nightlyX.Y.ZaYYYYMMDD7.10.0a20251124
(The nightly release on 2025-11-24)
nightly-bkcX.Y.ZaBASEDATE+bkc.YYYYMMDD10.1.0a20260811+bkc.20260814
devX.Y.Z.dev0+NNNN7.10.0.dev0+efed3c3b10a5cce8578f58f8eb288582c26d18c4
(For commit efed3c3)
dev-bkcX.Y.Z.dev0+NNNN
(same as regular dev)
10.1.0.dev0+efed3c3b10a5cce8578f58f8eb288582c26d18c4

Post releases

A post release is a follow-up release of an existing package version, written in canonical form with a .postN segment. PEP 440 orders it after its base version and before the next patch: 7.14.0 < 7.14.0.post1 < 7.14.1. TheRock's scripts do not generate these versions, but we may create one manually in exceptional cases to patch an individual Python package. See the official Python packaging guidance for what qualifies as a post release.

Version comparisons in TheRock scripts and published packages should tolerate versions that differ only by a post-release segment. For example, 7.14.0 and 7.14.0.post1 should be compatible, while 7.14.0 and 7.14.1 should not. This lets us patch one package without republishing the entire package set.

BKC versions

For nightly-bkc, BASEDATE comes from release-metadata.base-date in version.json and identifies the regular nightly used to create the BKC branch. The date in the bkc.YYYYMMDD local version identifier is the BKC build date. This makes a BKC build sort newer than its base nightly but older than the next regular nightly:

10.1.0a20260811 < 10.1.0a20260811+bkc.20260814 < 10.1.0a20260812

External Python package versions

When we build external projects like PyTorch we sometimes extend the base package version with our own local version identifier.

For example, for torch version 2.9.0 built with ROCm version 7.10.0 we generate a composite torch version 2.9.0+rocm7.10.0. See this table for more possible version combinations:

ROCm release typeROCm version exampleComposite torch version example
stable7.10.02.9.0+rocm7.10.0
nightly7.10.0a202511242.9.0+rocm7.10.0a20251124
nightly-bkc10.1.0a20260811+bkc.202608132.13.0+rocm10.1.0a20260811.bkc.20260813
dev7.10.0.dev0+efed3c2.9.0+devrocm7.10.0.dev0-efed3c
(Note the devrocm and - instead of +)

These local version identifiers are specially constructed such that the expected version sorting of stable > nightly > dev is preserved. Note that per the "Local version identifiers" specification, comparison and ordering of local version identifiers goes segment by segment with special rules different from the rules used for base versions. This ordering can be tested like so:

>>> from packaging.version import Version
>>> stable = Version("2.9.0+rocm7.10.0")
>>> nightly = Version("2.9.0+rocm7.10.0a20251124")
>>> dev = Version("2.9.0+devrocm7.10.0.dev0-efed3c")
>>> stable > nightly
True
>>> nightly > dev
True

Warning

Known issue: https://github.com/ROCm/TheRock/issues/7183.

Package versions using ROCm version 10.0.0+ sort as older than previous versions using this schema:

>>> from packaging.version import Version
>>> Version("2.12.0+rocm10.0") > Version("2.12.0+rocm7.0")
False

We plan on publishing 10.0.0+ packages to a new index to avoid this issue for future installs.

PyTorch versions

PyTorch packages versions are handled via scripts:

The scripts produce these versions for each distribution channel:

Package nameExample release version (stable x stable)Example nightly version (nightly x nightly)
torch2.9.1+rocm7.10.02.10.0a0+rocm7.10.0a20251024
torchaudio2.9.0+rocm7.10.02.10.0a0+rocm7.10.0a20251024
torchvision0.24.0+rocm7.10.00.24.0+rocm7.11.0a20251124
triton3.3.1+rocm7.10.03.5.1+rocm7.11.0a20251124

For manually dispatched dev PyTorch builds (build_prod_wheels.py --release-type dev), each wheel version is additionally tagged with its own 8-character source commit in the PEP 440 local version segment, e.g. 2.12.0a0+git1a2b3c4d.rocm7.10.0. This applies to the torch, torchaudio, and torchvision wheels, so each records exactly which source commit produced it.

JAX versions

JAX packages versions are handled via scripts:

Versions for each distribution channel:

Package nameExample release version (stable x stable)Example nightly version (stable x nightly)
jax-rocm7-pjrt0.10.0+rocm7.14.00.10.2+rocm7.15.0a20260712
jax-rocm7-plugin0.10.0+rocm7.14.00.10.2+rocm7.15.0a20260712

Working with Python package versions

When working with versions please use these tools and avoid custom parsing (such as regex) if possible:

Tip - installing prereleases

Python package installers like pip ignore pre-releases by default if a final release exists unless explicitly requested with e.g. pip install rocm==7.10.0rc0 or pip install --pre rocm. See also Python Packaging User Guide - Versioning.

Tip - Upgrading and force reinstalling

The --upgrade and --force-reinstall options can also be useful when switching between version types to ensure that the expected package versions are used. See the documentation for pip install.

Tip - checking package versions

A few ways to look up the version of an installed package are:

  • pip show:

    $ pip show torch | grep Version
    Version: 2.10.0a0+rocm7.11.0a20251209
    
  • pip list:

    $ pip list | grep torch
    torch                          2.10.0a0+rocm7.11.0a2025120
    
  • pip freeze:

    $ pip freeze | grep torch
    torch==2.10.0a0+rocm7.11.0a20251209
    
  • The __version__ module attribute:

    $ python -c "import torch; print(torch.__version__)"
    2.10.0a0+rocm7.11.0a20251209
    

Native Linux package versions

TheRock supports rpm and debian packages. Each has different versioning scheme as mentioned below. Native package versions are handled by scripts:

The script produces these versions for rpm packages for each release type:

Release typeVersion formatVersion example
stableX.Y.Z7.10.0
prereleaseX.Y.Z~rcN7.10.0~rc0
(The first release candidate for that stable release)
nightlyX.Y.Z~YYYYMMDD7.10.0~20251124
(The nightly release on 2025-11-24)
nightly-bkcX.Y.Z~BASEDATE.bkc.YYYYMMDD10.1.0~20260811.bkc.20260814
devX.Y.Z~YYYYMMDDg<git-hash>7.10.0~20251124gefed3c3
(For commit efed3c3)
dev-bkcX.Y.Z~YYYYMMDDg<git-hash>
(same as dev)
10.1.0~20260814gefed3c3

The script produces these versions for debian packages for each release type:

Release typeVersion formatVersion example
stableX.Y.Z7.10.0
prereleaseX.Y.Z~preN7.10.0~pre0
(The first release candidate for that stable release)
nightlyX.Y.Z~YYYYMMDD7.10.0~20251124
(The nightly release on 2025-11-24)
nightly-bkcX.Y.Z~BASEDATE.bkc.YYYYMMDD10.1.0~20260811.bkc.20260814
devX.Y.Z~devYYYYMMDD7.10.0~dev20251124
(For dev build on 2025-11-24)
dev-bkcX.Y.Z~devYYYYMMDD
(same as regular dev)
10.1.0~dev20260814

Warning

Deb package version sorting is currently different than rpm and python version sorting:

Package typeSort order
Pythonstable > prerelease > nightly > dev
rpmstable > prerelease > nightly > dev
debstable > prerelease > dev > nightly

This can be checked from Python using the python-debian package:

>>> from debian.debian_support import NativeVersion
>>> NativeVersion("7.10.0~20251124") > NativeVersion("7.10.0~dev20251124")
False

As a result, apt may prefer a dev package over a nightly package when both release indexes are configured.

See https://github.com/ROCm/TheRock/issues/7638 for details.

Working with Debian package versions

The python-debian package can be used to work with debian package versions:

Native Windows package versions

TODO: fill this in together with https://github.com/ROCm/TheRock/pull/2159