Skip to content

PTQ-Level Efficiency, QAT-Level Accuracy | 训练后量化的效率,量化感知训练的精度

chore: update CI to PyTorch 2.15 (#2570)

Sun, Xuehao853b26411c0d
diff --git a/.azure-pipelines/ark-unit-test.yml b/.azure-pipelines/ark-unit-test.yml
index 653a8e68d..2dc80a0f4 100644
--- a/.azure-pipelines/ark-unit-test.yml
+++ b/.azure-pipelines/ark-unit-test.yml
@@ -26,8 +26,8 @@ parameters:
displayName: "Torch versions"
type: string
# Comma-separated list to align with pythonVersions runtime input style.
- # For example, "2.14.0"
- default: "2.14.0"
+ # For example, "2.15.0"
+ default: "2.15.0"
- name: publishTarget
displayName: "Publish wheels to"
type: string
diff --git a/.azure-pipelines/docker/cpu.dockerfile b/.azure-pipelines/docker/cpu.dockerfile
index d3c08a7ff..1887f44e8 100644
--- a/.azure-pipelines/docker/cpu.dockerfile
+++ b/.azure-pipelines/docker/cpu.dockerfile
@@ -49,6 +49,6 @@ ENV UV_NO_PROGRESS=1 \
RUN uv python install 3.14
RUN uv venv --python=3.14 /home/hostuser/.venv
RUN which python && python --version
-RUN uv pip install torch==2.14.0 torchvision==0.29.0 --extra-index-url https://download.pytorch.org/whl/cpu
+RUN uv pip install torch==2.15.0 torchvision==0.29.2 --extra-index-url https://download.pytorch.org/whl/cpu
WORKDIR /home/hostuser
diff --git a/.azure-pipelines/docker/xpu.dockerfile b/.azure-pipelines/docker/xpu.dockerfile
index 84f7da4d2..1ba52c149 100644
--- a/.azure-pipelines/docker/xpu.dockerfile
+++ b/.azure-pipelines/docker/xpu.dockerfile
@@ -49,6 +49,6 @@ ENV UV_NO_PROGRESS=1 \
RUN uv python install 3.14
RUN uv venv --python=3.14 /home/hostuser/.venv
RUN which python && python --version
-RUN uv pip install torch==2.14.0 torchvision==0.29.0 --extra-index-url https://download.pytorch.org/whl/xpu
+RUN uv pip install torch==2.15.0 torchvision==0.29.2 --extra-index-url https://download.pytorch.org/whl/xpu
WORKDIR /home/hostuser
diff --git a/.azure-pipelines/scripts/cuda_unit_test/run_cuda_ut.sh b/.azure-pipelines/scripts/cuda_unit_test/run_cuda_ut.sh
index 1e4661429..399e84841 100644
--- a/.azure-pipelines/scripts/cuda_unit_test/run_cuda_ut.sh
+++ b/.azure-pipelines/scripts/cuda_unit_test/run_cuda_ut.sh
@@ -79,8 +79,8 @@ function setup_basic_test_env() {
cd "${BUILD_SOURCESDIRECTORY}" || exit 1
rm -rf /root/.venv
uv venv --python=3.14 /root/.venv
- uv pip install torch==2.14.1 torchvision torchao --index-url https://download.pytorch.org/whl/cu130
- uv pip install llama-cpp-python --extra-index-url https://abetlen.github.io/llama-cpp-python/whl/cu130
+ uv pip install torch==2.15.0 torchvision torchao --index-url https://download.pytorch.org/whl/cu132
+ uv pip install llama-cpp-python --extra-index-url https://abetlen.github.io/llama-cpp-python/whl/cu132
uv pip install 'git+https://github.com/ggml-org/llama.cpp.git@master#subdirectory=gguf-py'
uv pip install -r test/unit/test_cuda/requirements.txt
uv pip install -r test/unit/test_cuda/requirements_diffusion.txt
@@ -88,7 +88,7 @@ function setup_basic_test_env() {
uv pip install -U pytest-cov pytest-timeout
uv pip install kernels==0.17.2 # For sm120: https://github.com/huggingface/transformers/blob/v5.19.0/setup.py#L94
uv pip uninstall torch torchvision
- uv pip install torch==2.14.1 torchvision torchao --index-url https://download.pytorch.org/whl/cu130
+ uv pip install torch==2.15.0 torchvision torchao --index-url https://download.pytorch.org/whl/cu132
uv pip install .
echo "List dependencies ..."
@@ -182,7 +182,7 @@ function run_unit_test_llmc() {
uv pip install -U pytest-cov pytest-timeout
BUILD_TYPE="nightly" uv pip install \
-r test/integration/test_cuda/requirements_llmc.txt \
- --extra-index-url https://download.pytorch.org/whl/cu130 \
+ --extra-index-url https://download.pytorch.org/whl/cu132 \
--index-strategy unsafe-best-match
uv pip install -U chardet
uv pip install .
diff --git a/.azure-pipelines/scripts/ut/constraints.txt b/.azure-pipelines/scripts/ut/constraints.txt
index c2a43a813..cc122cd84 100644
--- a/.azure-pipelines/scripts/ut/constraints.txt
+++ b/.azure-pipelines/scripts/ut/constraints.txt
@@ -1,2 +1,2 @@
-torch==2.14.0
-torchvision==0.29.0
+torch==2.15.0
+torchvision==0.29.2
diff --git a/.azure-pipelines/scripts/ut/run_ut_cuda.sh b/.azure-pipelines/scripts/ut/run_ut_cuda.sh
index aee016f37..c2b6df4bf 100644
--- a/.azure-pipelines/scripts/ut/run_ut_cuda.sh
+++ b/.azure-pipelines/scripts/ut/run_ut_cuda.sh
@@ -5,7 +5,7 @@ set -xe
CONDA_ENV_NAME="unittest_cuda"
PYTHON_VERSION="3.12"
-TORCH_VERSION="2.14.1"
+TORCH_VERSION="2.15.0"
REPO_PATH=$(git rev-parse --show-toplevel)
LOG_DIR=${REPO_PATH}/ut_log_dir
@@ -96,14 +96,14 @@ function run_unit_test() {
cd ${REPO_PATH}/test
rm -rf .coverage* *.xml *.html
- uv pip install torch==${TORCH_VERSION} torchvision torchao --index-url https://download.pytorch.org/whl/cu130
- uv pip install llama-cpp-python --extra-index-url https://abetlen.github.io/llama-cpp-python/whl/cu130
+ uv pip install torch==${TORCH_VERSION} torchvision torchao --index-url https://download.pytorch.org/whl/cu132
+ uv pip install llama-cpp-python --extra-index-url https://abetlen.github.io/llama-cpp-python/whl/cu132
uv pip install 'git+https://github.com/ggml-org/llama.cpp.git@master#subdirectory=gguf-py'
uv pip install -r unit/test_cuda/requirements.txt
uv pip install -r unit/test_cuda/requirements_diffusion.txt
uv pip install -U transformers chardet timm
uv pip uninstall torch torchvision
- uv pip install torch==${TORCH_VERSION} torchvision torchao --index-url https://download.pytorch.org/whl/cu130
+ uv pip install torch==${TORCH_VERSION} torchvision torchao --index-url https://download.pytorch.org/whl/cu132
cd ${REPO_PATH} && uv pip install . && cd ${REPO_PATH}/test
pip list > ${LOG_DIR}/ut_pip_list.txt
@@ -132,10 +132,10 @@ function run_unit_test_vlm() {
cd ${REPO_PATH}/test
rm -rf .coverage* *.xml *.html
- uv pip install torch==${TORCH_VERSION} torchvision --index-url https://download.pytorch.org/whl/cu130
+ uv pip install torch==${TORCH_VERSION} torchvision --index-url https://download.pytorch.org/whl/cu132
uv pip install git+https://github.com/haotian-liu/[email protected] --no-deps
uv pip install -r unit/test_cuda/requirements_vlm.txt \
- --extra-index-url https://download.pytorch.org/whl/cu130 \
+ --extra-index-url https://download.pytorch.org/whl/cu132 \
--index-strategy unsafe-best-match
uv pip install -U chardet
cd ${REPO_PATH} && uv pip install . && cd ${REPO_PATH}/test
@@ -167,7 +167,7 @@ function run_unit_test_llmc() {
cd ${REPO_PATH}/test
rm -rf .coverage* *.xml *.html
BUILD_TYPE="nightly" uv pip install -r integration/test_cuda/requirements_llmc.txt \
- --extra-index-url https://download.pytorch.org/whl/cu130 \
+ --extra-index-url https://download.pytorch.org/whl/cu132 \
--index-strategy unsafe-best-match
uv pip install -U chardet
cd ${REPO_PATH} && uv pip install . && cd ${REPO_PATH}/test