[v0.18.0][Misc] Upgrade torch_npu to pre-release built version (#7918)

### What this PR does / why we need it?
This PR upgrades the `torch_npu` (PTA) version in multiple Dockerfiles
to a pre-release build. It introduces logic to dynamically select the
correct wheel based on the Python version and system architecture.

### Does this PR introduce _any_ user-facing change?
No.

### How was this patch tested?
CI passed with existing tests. The author should verify that the Docker
images build successfully for all supported architectures and Python
versions.

---------

Signed-off-by: wangli <wangli858794774@gmail.com>
This commit is contained in:
Li Wang
2026-04-01 22:41:09 +08:00
committed by GitHub
parent d3de7333dc
commit 99e1ea0fe6
8 changed files with 94 additions and 11 deletions

View File

@@ -88,6 +88,7 @@ jobs:
pip install uc-manager
uv pip install -r requirements-dev.txt
uv pip install -v -e .
uv pip install https://vllm-ascend.obs.cn-north-4.myhuaweicloud.com/vllm-ascend/torch_npu-2.9.0.post1%2Bgitee7ba04-cp311-cp311-manylinux_2_28_aarch64.whl
uv pip install git+https://github.com/modelscope/modelscope.git@dbbcbf631fe6d10cc6446df2ad2fef24039fe7fe
- name: Run vllm-project/vllm-ascend test
@@ -195,6 +196,7 @@ jobs:
pip install uc-manager
uv pip install -r requirements-dev.txt
uv pip install -v -e .
uv pip install https://vllm-ascend.obs.cn-north-4.myhuaweicloud.com/vllm-ascend/torch_npu-2.9.0.post1%2Bgitee7ba04-cp311-cp311-manylinux_2_28_aarch64.whl
uv pip install git+https://github.com/modelscope/modelscope.git@dbbcbf631fe6d10cc6446df2ad2fef24039fe7fe
- name: Run e2e test
env:
@@ -299,6 +301,7 @@ jobs:
pip install uc-manager
uv pip install -r requirements-dev.txt
uv pip install -v -e .
uv pip install https://vllm-ascend.obs.cn-north-4.myhuaweicloud.com/vllm-ascend/torch_npu-2.9.0.post1%2Bgitee7ba04-cp311-cp311-manylinux_2_28_aarch64.whl
uv pip install git+https://github.com/modelscope/modelscope.git@dbbcbf631fe6d10cc6446df2ad2fef24039fe7fe
- name: Run vllm-project/vllm-ascend test (light)
env:
@@ -403,6 +406,7 @@ jobs:
pip install uc-manager
uv pip install -r requirements-dev.txt
uv pip install -v -e .
uv pip install https://vllm-ascend.obs.cn-north-4.myhuaweicloud.com/vllm-ascend/torch_npu-2.9.0.post1%2Bgitee7ba04-cp311-cp311-manylinux_2_28_aarch64.whl
uv pip install git+https://github.com/modelscope/modelscope.git@dbbcbf631fe6d10cc6446df2ad2fef24039fe7fe
- name: Run vllm-project/vllm-ascend test (full)
env:
@@ -526,6 +530,7 @@ jobs:
pip install uc-manager
uv pip install -r requirements-dev.txt
uv pip install -v -e .
uv pip install https://vllm-ascend.obs.cn-north-4.myhuaweicloud.com/vllm-ascend/torch_npu-2.9.0.post1%2Bgitee7ba04-cp311-cp311-manylinux_2_28_aarch64.whl
uv pip install git+https://github.com/modelscope/modelscope.git@dbbcbf631fe6d10cc6446df2ad2fef24039fe7fe
- name: Run vllm-project/vllm-ascend test for V1 Engine
@@ -623,6 +628,7 @@ jobs:
pip install uc-manager
uv pip install -r requirements-dev.txt
uv pip install -v -e .
uv pip install https://vllm-ascend.obs.cn-north-4.myhuaweicloud.com/vllm-ascend/torch_npu-2.9.0.post1%2Bgitee7ba04-cp311-cp311-manylinux_2_28_aarch64.whl
uv pip install git+https://github.com/modelscope/modelscope.git@dbbcbf631fe6d10cc6446df2ad2fef24039fe7fe
- name: Run vllm-project/vllm-ascend test
@@ -699,6 +705,7 @@ jobs:
pip install uc-manager
uv pip install -r requirements-dev.txt
uv pip install -v -e .
uv pip install https://vllm-ascend.obs.cn-north-4.myhuaweicloud.com/vllm-ascend/torch_npu-2.9.0.post1%2Bgitee7ba04-cp311-cp311-manylinux_2_28_aarch64.whl
uv pip install git+https://github.com/modelscope/modelscope.git@dbbcbf631fe6d10cc6446df2ad2fef24039fe7fe
- name: Run vllm-project/vllm-ascend test

View File

@@ -11,6 +11,13 @@
# - Publish when tag with v* (pep440 version) ===> vllm-ascend:v1.2.3 / vllm-ascend:v1.2.3rc1
name: Image Build and Push
on:
pull_request:
branches:
- 'releases/*'
paths:
- 'Dockerfile*'
- '.github/workflows/schedule_image_build_and_push.yaml'
types: [ labeled, synchronize ]
workflow_dispatch:
inputs:
tag:
@@ -33,6 +40,7 @@ concurrency:
jobs:
image_build:
name: Image Build and Push
if: github.event_name != 'pull_request' || contains(github.event.pull_request.labels.*.name, 'image-build')
strategy:
matrix:
build_meta:
@@ -59,7 +67,7 @@ jobs:
dockerfile: ${{ matrix.build_meta.dockerfile }}
suffix: ${{ matrix.build_meta.suffix }}
quay_username: ${{ vars.QUAY_USERNAME }}
should_push: ${{ github.repository_owner == 'vllm-project'}}
should_push: ${{ github.repository_owner == 'vllm-project' && github.event_name != 'pull_request' }}
workflow_dispatch_tag: ${{ inputs.tag }}
secrets:
QUAY_PASSWORD: ${{ secrets.QUAY_PASSWORD }}