!234 deploy-lmdeploy补充版本配套说明

Merge pull request !234 from 张烨槟/master
This commit is contained in:
张烨槟
2025-06-11 06:06:41 +00:00
committed by i-robot
parent 0adb659e5c
commit 105abd9d8a
2 changed files with 45 additions and 0 deletions

View File

@ -387,6 +387,17 @@ pip install -e .
pip install dlinfer-ascend==0.1.7
```
主要版本配套说明如下:
| 软件 | 支持版本 |
|------------------|---------------------|
| torch | 2.3.1 |
| torch-npu | 2.3.1 |
| lmdeploy | 0.6.4 |
| dlinfer-ascend | 0.1.7 |
| transformers | 4.47.1 |
| accelerate | 1.0.0rc1 |
#### 接口调用示例
- 从魔乐社区上获取模型`AI-Research/Qwen2-7B`在默认端口1025上进行部署。

View File

@ -96,6 +96,40 @@ openmind-cli deploy stop
## LMDeploy
### 环境准备
不同于openMind Library v1.0.0版本默认配套的PyTorch 2.1.0当前该接口的LMDeploy部署能力依赖于PyTorch 2.3.1版本即使用该功能需要修改环境中的PyTorch版本。对此我们强烈建议用户创建新环境进行模型部署新建环境可参考[openMind Library安装指南](../install.md)。
在安装LMDeploy之前请确保环境中存在`setuptools`和`wheel`。另外可执行以下命令检验torch_npu以及NPU环境是否可用以确保LMDeploy顺利安装。
```shell
python -c "import torch_npu;print(torch_npu.npu.is_available());"
'''
True
'''
```
LMDeploy安装命令如下
```shell
git clone -b v0.6.4 https://github.com/InternLM/lmdeploy.git
cd lmdeploy
pip install -e .
pip install dlinfer-ascend==0.1.7
```
主要版本配套说明如下:
| 软件 | 支持版本 |
|------------------|---------------------|
| torch | 2.3.1 |
| torch-npu | 2.3.1 |
| lmdeploy | 0.6.4 |
| dlinfer-ascend | 0.1.7 |
| transformers | 4.47.1 |
| accelerate | 1.0.0rc1 |
### 部署LMDeploy服务示例
- 从魔乐社区上获取模型`AI-Research/Qwen2-7B`在默认端口1025上进行部署。