Skip to content

Commit c555787

Browse files
wxsIceyMengqingCao
authored andcommitted
Bump torch-npu version to 2.5.1.post1.dev20250528
Signed-off-by: Icey <1790571317@qq.com> Signed-off-by: MengqingCao <cmq0113@163.com>
1 parent 64cbb2c commit c555787

14 files changed

+93
-12
lines changed

.github/workflows/accuracy_test.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,6 +173,8 @@ jobs:
173173

174174
- name: Install vllm-project/vllm-ascend
175175
working-directory: ./vllm-ascend
176+
env:
177+
PIP_EXTRA_INDEX_URL: https://mirrors.huaweicloud.com/ascend/repos/pypi
176178
run: |
177179
pip install -r requirements-dev.txt
178180
pip install -e .

.github/workflows/image_openeuler.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,12 @@ on:
1919
- '.github/workflows/image_openeuler.yml'
2020
- 'Dockerfile.openEuler'
2121
- 'vllm_ascend/**'
22+
- 'setup.py'
23+
- 'pyproject.toml'
24+
- 'requirements.txt'
25+
- 'cmake/**'
26+
- 'CMakeLists.txt'
27+
- 'csrc/**'
2228
push:
2329
# Publish image when tagging, the Dockerfile in tag will be build as tag image
2430
branches:

.github/workflows/image_ubuntu.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,12 @@ on:
1919
- '.github/workflows/image_ubuntu.yml'
2020
- 'Dockerfile'
2121
- 'vllm_ascend/**'
22+
- 'setup.py'
23+
- 'pyproject.toml'
24+
- 'requirements.txt'
25+
- 'cmake/**'
26+
- 'CMakeLists.txt'
27+
- 'csrc/**'
2228
push:
2329
# Publish image when tagging, the Dockerfile in tag will be build as tag image
2430
branches:

.github/workflows/nightly_benchmarks.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,8 @@ jobs:
115115
VLLM_TARGET_DEVICE=empty pip install -e .
116116
117117
- name: Install vllm-project/vllm-ascend
118+
env:
119+
PIP_EXTRA_INDEX_URL: https://mirrors.huaweicloud.com/ascend/repos/pypi
118120
run: |
119121
pip install -e .
120122
pip install -r benchmarks/requirements-bench.txt

.github/workflows/vllm_ascend_test.yaml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,57 @@ jobs:
114114
echo "::add-matcher::.github/workflows/matchers/mypy.json"
115115
tools/mypy.sh 1 ${{ matrix.python-version }}
116116
117+
ut:
118+
needs: [lint]
119+
name: unit test
120+
if: ${{ needs.lint.result == 'success' }}
121+
runs-on: ubuntu-latest
122+
container:
123+
image: m.daocloud.io/quay.io/ascend/cann:8.1.rc1-910b-ubuntu22.04-py3.10
124+
env:
125+
VLLM_LOGGING_LEVEL: ERROR
126+
VLLM_USE_MODELSCOPE: True
127+
strategy:
128+
matrix:
129+
vllm_version: [main, v0.9.1]
130+
steps:
131+
- name: Install packages
132+
run: |
133+
apt-get update -y
134+
apt-get install -y python3-pip git vim wget net-tools gcc g++ cmake libnuma-dev
135+
136+
- name: Checkout vllm-project/vllm repo
137+
uses: actions/checkout@v4
138+
with:
139+
repository: vllm-project/vllm
140+
ref: ${{ matrix.vllm_version }}
141+
path: ./vllm-empty
142+
143+
- name: Install vllm-project/vllm from source
144+
working-directory: ./vllm-empty
145+
run: |
146+
VLLM_TARGET_DEVICE=empty python3 -m pip install . --extra-index https://download.pytorch.org/whl/cpu/
147+
python3 -m pip uninstall -y triton
148+
149+
- name: Checkout vllm-project/vllm-ascend repo
150+
uses: actions/checkout@v4
151+
152+
- name: Install vllm-project/vllm-ascend
153+
run: |
154+
export PIP_EXTRA_INDEX_URL=https://mirrors.huaweicloud.com/ascend/repos/pypi
155+
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/Ascend/ascend-toolkit/latest/x86_64-linux/devlib
156+
python3 -m pip install -r requirements-dev.txt --extra-index https://download.pytorch.org/whl/cpu/
157+
python3 -m pip install -v . --extra-index https://download.pytorch.org/whl/cpu/
158+
159+
- name: Run unit test for V1 Engine
160+
env:
161+
VLLM_USE_V1: 1
162+
VLLM_WORKER_MULTIPROC_METHOD: spawn
163+
TORCH_DEVICE_BACKEND_AUTOLOAD: 0
164+
run: |
165+
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/Ascend/ascend-toolkit/latest/x86_64-linux/devlib
166+
pytest -sv tests/ut
167+
117168
e2e:
118169
needs: [lint]
119170
if: ${{ needs.lint.result == 'success' }}
@@ -164,6 +215,8 @@ jobs:
164215
VLLM_TARGET_DEVICE=empty pip install -e .
165216
166217
- name: Install vllm-project/vllm-ascend
218+
env:
219+
PIP_EXTRA_INDEX_URL: https://mirrors.huaweicloud.com/ascend/repos/pypi
167220
run: |
168221
pip install -r requirements-dev.txt
169222
pip install -v -e .
@@ -267,6 +320,8 @@ jobs:
267320
VLLM_TARGET_DEVICE=empty pip install -e .
268321
269322
- name: Install vllm-project/vllm-ascend
323+
env:
324+
PIP_EXTRA_INDEX_URL: https://mirrors.huaweicloud.com/ascend/repos/pypi
270325
run: |
271326
pip install -r requirements-dev.txt
272327
pip install -v -e .

.github/workflows/vllm_ascend_test_long_term.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,8 @@ jobs:
8888
VLLM_TARGET_DEVICE=empty pip install -e .
8989
9090
- name: Install vllm-project/vllm-ascend
91+
env:
92+
PIP_EXTRA_INDEX_URL: https://mirrors.huaweicloud.com/ascend/repos/pypi
9193
run: |
9294
pip install -r requirements-dev.txt
9395
pip install -v -e .

.github/workflows/vllm_ascend_test_pd.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,8 @@ jobs:
9797
VLLM_TARGET_DEVICE=empty pip install -e .
9898
9999
- name: Install vllm-project/vllm-ascend
100+
env:
101+
PIP_EXTRA_INDEX_URL: https://mirrors.huaweicloud.com/ascend/repos/pypi
100102
run: |
101103
pip install -r requirements-dev.txt
102104
pip install -v -e .

Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,8 @@ RUN VLLM_TARGET_DEVICE="empty" python3 -m pip install -v -e /vllm-workspace/vllm
4646

4747
# Install vllm-ascend
4848
# Append `libascend_hal.so` path (devlib) to LD_LIBRARY_PATH
49-
RUN source /usr/local/Ascend/ascend-toolkit/set_env.sh && \
49+
RUN export PIP_EXTRA_INDEX_URL=https://mirrors.huaweicloud.com/ascend/repos/pypi && \
50+
source /usr/local/Ascend/ascend-toolkit/set_env.sh && \
5051
source /usr/local/Ascend/nnal/atb/set_env.sh && \
5152
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/Ascend/ascend-toolkit/latest/`uname -i`-linux/devlib && \
5253
python3 -m pip install -v -e /vllm-workspace/vllm-ascend/ --extra-index https://download.pytorch.org/whl/cpu/ && \

Dockerfile.openEuler

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,8 @@ RUN VLLM_TARGET_DEVICE="empty" python3 -m pip install -e /vllm-workspace/vllm/ -
4343
python3 -m pip cache purge
4444

4545
# Install vllm-ascend
46-
RUN source /usr/local/Ascend/ascend-toolkit/set_env.sh && \
46+
RUN export PIP_EXTRA_INDEX_URL=https://mirrors.huaweicloud.com/ascend/repos/pypi && \
47+
source /usr/local/Ascend/ascend-toolkit/set_env.sh && \
4748
source /usr/local/Ascend/nnal/atb/set_env.sh && \
4849
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/Ascend/ascend-toolkit/latest/`uname -i`-linux/devlib && \
4950
python3 -m pip install -v -e /vllm-workspace/vllm-ascend/ --extra-index https://download.pytorch.org/whl/cpu/ && \

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ By using vLLM Ascend plugin, popular open-source models, including Transformer-l
3838
- Software:
3939
* Python >= 3.9, < 3.12
4040
* CANN >= 8.1.RC1
41-
* PyTorch >= 2.5.1, torch-npu >= 2.5.1
41+
* PyTorch >= 2.5.1, torch-npu >= 2.5.1.post1.dev20250528
4242
* vLLM (the same version as vllm-ascend)
4343

4444
## Getting Started

README.zh.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ vLLM 昇腾插件 (`vllm-ascend`) 是一个由社区维护的让vLLM在Ascend NP
3939
- 软件:
4040
* Python >= 3.9, < 3.12
4141
* CANN >= 8.1.RC1
42-
* PyTorch >= 2.5.1, torch-npu >= 2.5.1
42+
* PyTorch >= 2.5.1, torch-npu >= 2.5.1.post1.dev20250528
4343
* vLLM (与vllm-ascend版本一致)
4444

4545
## 开始使用

docs/source/installation.md

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@ This document describes how to install vllm-ascend manually.
99
- A hardware with Ascend NPU. It's usually the Atlas 800 A2 series.
1010
- Software:
1111

12-
| Software | Supported version | Note |
13-
|-----------|-------------------|----------------------------------------|
14-
| CANN | >= 8.1.RC1 | Required for vllm-ascend and torch-npu |
15-
| torch-npu | >= 2.5.1 | Required for vllm-ascend |
16-
| torch | >= 2.5.1 | Required for torch-npu and vllm |
12+
| Software | Supported version | Note |
13+
|---------------|----------------------------------|-------------------------------------------|
14+
| CANN | >= 8.1.RC1 | Required for vllm-ascend and torch-npu |
15+
| torch-npu | >= 2.5.1.post1.dev20250528 | Required for vllm-ascend |
16+
| torch | >= 2.5.1 | Required for torch-npu and vllm |
1717

1818
You have 2 way to install:
1919
- **Using pip**: first prepare env manually or via CANN image, then install `vllm-ascend` using pip.
@@ -156,6 +156,7 @@ cd ..
156156
# Install vLLM Ascend
157157
git clone --depth 1 --branch |vllm_ascend_version| https://github.com/vllm-project/vllm-ascend.git
158158
cd vllm-ascend
159+
export PIP_EXTRA_INDEX_URL=https://mirrors.huaweicloud.com/ascend/repos/pypi
159160
pip install -v -e .
160161
cd ..
161162
```

requirements.txt

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,6 @@ pyyaml
1010
scipy
1111
setuptools>=64
1212
setuptools-scm>=8
13-
--extra-index-url https://mirrors.huaweicloud.com/ascend/repos/pypi
14-
torch-npu==2.5.1.post1.dev20250528
1513
torch>=2.5.1
1614
torchvision<0.21.0
1715
wheel
@@ -22,3 +20,8 @@ quart
2220

2321
# Required for N-gram speculative decoding
2422
numba
23+
24+
# Install torch_npu
25+
--pre
26+
--extra-index-url https://mirrors.huaweicloud.com/ascend/repos/pypi
27+
torch-npu==2.5.1.post1.dev20250528

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ def configure(self, ext: CMakeExtension) -> None:
152152
# if pybind11 is installed via pip
153153
pybind11_cmake_path = (subprocess.check_output(
154154
[python_executable, "-m", "pybind11",
155-
"--cmake"]).decode().strip())
155+
"--cmakedir"]).decode().strip())
156156
except subprocess.CalledProcessError as e:
157157
# else specify pybind11 path installed from source code on CI container
158158
raise RuntimeError(f"CMake configuration failed: {e}")

0 commit comments

Comments
 (0)