Skip to content

Commit e738cba

Browse files
committed
Update PyTorch to 2.9.0
Signed-off-by: Huy Do <huydhn@gmail.com>
1 parent 218454b commit e738cba

File tree

11 files changed

+34
-31
lines changed

11 files changed

+34
-31
lines changed

.buildkite/test-pipeline.yaml

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -521,13 +521,6 @@ steps:
521521
- vllm/model_executor/layers/quantization
522522
- tests/quantization
523523
commands:
524-
# temporary install here since we need nightly, will move to requirements/test.in
525-
# after torchao 0.12 release, and pin a working version of torchao nightly here
526-
527-
# since torchao nightly is only compatible with torch nightly currently
528-
# https://github.com/pytorch/ao/issues/2919, we'll have to skip new torchao tests for now
529-
# we can only upgrade after this is resolved
530-
- pip install --pre torchao==0.13.0.dev20250814 --index-url https://download.pytorch.org/whl/nightly/cu128
531524
- VLLM_TEST_FORCE_LOAD_FORMAT=auto pytest -v -s quantization
532525

533526
- label: LM Eval Small Models # 53min

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ repos:
4949
rev: 0.6.17
5050
hooks:
5151
- id: pip-compile
52-
args: [requirements/test.in, -o, requirements/test.txt, --index-strategy, unsafe-best-match, --torch-backend, cu128]
52+
args: [requirements/test.in, -o, requirements/test.txt, --index-strategy, unsafe-best-match, --extra-index-url, https://download.pytorch.org/whl/test/cu128]
5353
files: ^requirements/test\.(in|txt)$
5454
- repo: local
5555
hooks:

CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,8 @@ set(HIP_SUPPORTED_ARCHS "gfx906;gfx908;gfx90a;gfx942;gfx950;gfx1030;gfx1100;gfx1
4949
# requirements.txt files and should be kept consistent. The ROCm torch
5050
# versions are derived from docker/Dockerfile.rocm
5151
#
52-
set(TORCH_SUPPORTED_VERSION_CUDA "2.8.0")
53-
set(TORCH_SUPPORTED_VERSION_ROCM "2.8.0")
52+
set(TORCH_SUPPORTED_VERSION_CUDA "2.9.0")
53+
set(TORCH_SUPPORTED_VERSION_ROCM "2.9.0")
5454

5555
#
5656
# Try to find python package with an executable that exactly matches

docker/Dockerfile

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ ARG UV_INDEX_URL=${PIP_INDEX_URL}
5050
ARG UV_EXTRA_INDEX_URL=${PIP_EXTRA_INDEX_URL}
5151

5252
# PyTorch provides its own indexes for standard and nightly builds
53-
ARG PYTORCH_CUDA_INDEX_BASE_URL=https://download.pytorch.org/whl
53+
ARG PYTORCH_CUDA_INDEX_BASE_URL=https://download.pytorch.org/whl/test
5454
ARG PYTORCH_CUDA_NIGHTLY_INDEX_BASE_URL=https://download.pytorch.org/whl/nightly
5555

5656
# PIP supports multiple authentication schemes, including keyring
@@ -362,6 +362,13 @@ RUN --mount=type=bind,from=build,src=/workspace/dist,target=/vllm-workspace/dist
362362
uv pip install --system dist/*.whl --verbose \
363363
--extra-index-url ${PYTORCH_CUDA_INDEX_BASE_URL}/cu$(echo $CUDA_VERSION | cut -d. -f1,2 | tr -d '.')
364364

365+
# TODO (huydhn): Remove this once xformers is released for 2.9.0
366+
RUN --mount=type=cache,target=/root/.cache/uv bash - <<'BASH'
367+
. /etc/environment
368+
export TORCH_CUDA_ARCH_LIST='7.5 8.0+PTX 9.0a'
369+
uv pip install --system --no-build-isolation "git+https://github.com/facebookresearch/xformers@v0.0.32.post2"
370+
BASH
371+
365372
# If we need to build FlashInfer wheel before its release:
366373
# $ # Note we remove 7.0 from the arch list compared to the list below, since FlashInfer only supports sm75+
367374
# $ export TORCH_CUDA_ARCH_LIST='7.5 8.0 8.9 9.0a 10.0a 12.0'

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ requires = [
66
"packaging>=24.2",
77
"setuptools>=77.0.3,<80.0.0",
88
"setuptools-scm>=8.0",
9-
"torch == 2.8.0",
9+
"torch == 2.9.0",
1010
"wheel",
1111
"jinja2",
1212
]

requirements/build.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ ninja
44
packaging>=24.2
55
setuptools>=77.0.3,<80.0.0
66
setuptools-scm>=8
7-
torch==2.8.0
7+
torch==2.9.0
88
wheel
99
jinja2>=3.1.6
1010
regex

requirements/cpu.txt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,18 +7,18 @@ numba == 0.61.2; python_version > '3.9' and platform_machine != "s390x"
77
# Dependencies for CPUs
88
packaging>=24.2
99
setuptools>=77.0.3,<80.0.0
10-
--extra-index-url https://download.pytorch.org/whl/cpu
10+
--extra-index-url https://download.pytorch.org/whl/test/cpu
1111
torch==2.6.0+cpu; platform_machine == "x86_64" # torch>2.6.0+cpu has performance regression on x86 platform, see https://github.com/pytorch/pytorch/pull/151218
12-
torch==2.8.0; platform_system == "Darwin"
13-
torch==2.8.0; platform_machine == "ppc64le" or platform_machine == "aarch64"
12+
torch==2.9.0; platform_system == "Darwin"
13+
torch==2.9.0; platform_machine == "ppc64le" or platform_machine == "aarch64"
1414

1515
# required for the image processor of minicpm-o-2_6, this must be updated alongside torch
1616
torchaudio; platform_machine != "ppc64le" and platform_machine != "s390x"
17-
torchaudio==2.8.0; platform_machine == "ppc64le"
17+
torchaudio==2.9.0; platform_machine == "ppc64le"
1818

1919
# required for the image processor of phi3v, this must be updated alongside torch
2020
torchvision; platform_machine != "ppc64le" and platform_machine != "s390x"
21-
torchvision==0.23.0; platform_machine == "ppc64le"
21+
torchvision==0.24.0; platform_machine == "ppc64le"
2222
datasets # for benchmark scripts
2323

2424
# Intel Extension for PyTorch, only for x86_64 CPUs

requirements/cuda.txt

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ numba == 0.61.2; python_version > '3.9'
66

77
# Dependencies for NVIDIA GPUs
88
ray[cgraph]>=2.48.0 # Ray Compiled Graph, required for pipeline parallelism in V1.
9-
torch==2.8.0
10-
torchaudio==2.8.0
9+
torch==2.9.0
10+
torchaudio==2.9.0
1111
# These must be updated alongside torch
12-
torchvision==0.23.0 # Required for phi3v processor. See https://github.com/pytorch/vision?tab=readme-ov-file#installation for corresponding version
13-
# https://github.com/facebookresearch/xformers/releases/tag/v0.0.32.post1
14-
xformers==0.0.32.post1; platform_system == 'Linux' and platform_machine == 'x86_64' # Requires PyTorch >= 2.8
12+
torchvision==0.24.0 # Required for phi3v processor. See https://github.com/pytorch/vision?tab=readme-ov-file#installation for corresponding version
13+
# xformers==0.0.33; platform_system == 'Linux' and platform_machine == 'x86_64' # Requires PyTorch >= 2.9

requirements/rocm-build.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
# Common dependencies
22
-r common.txt
33

4-
--extra-index-url https://download.pytorch.org/whl/rocm6.3
5-
torch==2.8.0
6-
torchvision==0.23.0
7-
torchaudio==2.8.0
4+
--extra-index-url https://download.pytorch.org/whl/test/rocm6.3
5+
torch==2.9.0
6+
torchvision==0.24.0
7+
torchaudio==2.9.0
88

99
triton==3.3.0
1010
cmake>=3.26.1,<4

requirements/test.in

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,11 @@ soundfile # required for audio tests
2424
jiwer # required for audio tests
2525
tblib # for pickling test exceptions
2626
timm >=1.0.17 # required for internvl and gemma3n-mm test
27-
torch==2.8.0
28-
torchaudio==2.8.0
29-
torchvision==0.23.0
27+
--extra-index-url https://download.pytorch.org/whl/test/cu128
28+
torch==2.9.0
29+
torchaudio==2.9.0
30+
torchvision==0.24.0
31+
torchao==0.13.0
3032
transformers_stream_generator # required for qwen-vl test
3133
matplotlib # required for qwen-vl test
3234
mistral_common[image,audio] >= 1.8.2 # required for voxtral test

0 commit comments

Comments
 (0)