Skip to content

Commit 64e108f

Browse files
chore(CI): bump PyTorch from 2.7 to 2.8 (#4884)
<!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Chores** * Upgraded PyTorch to 2.8 across CPU and CUDA 12.x environments for improved compatibility and stability. * Updated development container to download the matching LibTorch 2.8 CPU bundle. * Refreshed CI pipelines (build, test, analysis) to install and validate against PyTorch 2.8. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Signed-off-by: Jinzhe Zeng <njzjz@qq.com> Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
1 parent 6349238 commit 64e108f

5 files changed

Lines changed: 5 additions & 5 deletions

File tree

.devcontainer/download_libtorch.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@ set -ev
44
SCRIPT_PATH=$(dirname $(realpath -s $0))
55
cd ${SCRIPT_PATH}/..
66

7-
wget https://download.pytorch.org/libtorch/cpu/libtorch-cxx11-abi-shared-with-deps-2.7.0%2Bcpu.zip -O ~/libtorch.zip
7+
wget https://download.pytorch.org/libtorch/cpu/libtorch-cxx11-abi-shared-with-deps-2.8.0%2Bcpu.zip -O ~/libtorch.zip
88
unzip ~/libtorch.zip

.github/workflows/build_cc.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ jobs:
3333
- uses: lukka/get-cmake@latest
3434
- run: python -m pip install uv
3535
- run: source/install/uv_with_retry.sh pip install --system tensorflow
36-
- run: source/install/uv_with_retry.sh pip install --system 'torch==2.7' --index-url https://download.pytorch.org/whl/cpu
36+
- run: source/install/uv_with_retry.sh pip install --system 'torch==2.8.*' --index-url https://download.pytorch.org/whl/cpu
3737
- run: |
3838
wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2204/x86_64/cuda-keyring_1.0-1_all.deb \
3939
&& sudo dpkg -i cuda-keyring_1.0-1_all.deb \

.github/workflows/codeql.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ jobs:
4141
&& sudo apt-get update \
4242
&& sudo apt-get -y install cuda-cudart-dev-12-2 cuda-nvcc-12-2
4343
python -m pip install tensorflow
44-
python -m pip install 'torch==2.7' --index-url https://download.pytorch.org/whl/cpu
44+
python -m pip install 'torch==2.8.*' --index-url https://download.pytorch.org/whl/cpu
4545
env:
4646
DEBIAN_FRONTEND: noninteractive
4747
# Initializes the CodeQL tools for scanning.

.github/workflows/test_cc.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
source/install/uv_with_retry.sh pip install --system tensorflow-cpu~=2.18.0 jax==0.5.0
2929
export TENSORFLOW_ROOT=$(python -c 'import importlib.util,pathlib;print(pathlib.Path(importlib.util.find_spec("tensorflow").origin).parent)')
3030
source/install/uv_with_retry.sh pip install --system -e .[cpu,test,lmp,jax] mpi4py mpich
31-
source/install/uv_with_retry.sh pip install --system 'torch==2.7' --index-url https://download.pytorch.org/whl/cpu
31+
source/install/uv_with_retry.sh pip install --system 'torch==2.8.*' --index-url https://download.pytorch.org/whl/cpu
3232
- name: Convert models
3333
run: source/tests/infer/convert-models.sh
3434
# https://github.com/actions/runner-images/issues/9491

backend/find_pytorch.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ def get_pt_requirement(pt_version: str = "") -> dict:
116116
cuda_version = os.environ.get("CUDA_VERSION", "12.2")
117117
if cuda_version == "" or cuda_version in SpecifierSet(">=12,<13"):
118118
# CUDA 12.2, cudnn 9
119-
pt_version = "2.7.0"
119+
pt_version = "2.8.0"
120120
elif cuda_version in SpecifierSet(">=11,<12"):
121121
# CUDA 11.8, cudnn 8
122122
pt_version = "2.3.1"

0 commit comments

Comments
 (0)