Browse Source

fix: update docker_deployment.md and extension_modules.md for clarity on GPU architecture requirements and service naming

myhloli 1 week ago
parent
commit
10af19f419

+ 6 - 7
docs/en/quick_start/docker_deployment.md

@@ -20,7 +20,7 @@ MinerU's Docker uses `vllm/vllm-openai` as the base image, so it includes the `v
 > [!NOTE]
 > [!NOTE]
 > Requirements for using `vllm` to accelerate VLM model inference:
 > Requirements for using `vllm` to accelerate VLM model inference:
 > 
 > 
-> - Device must have Turing architecture or later graphics cards with 8GB+ available VRAM.
+> - Device must have Volta architecture or later graphics cards with 8GB+ available VRAM.
 > - The host machine's graphics driver should support CUDA 12.8 or higher; You can check the driver version using the `nvidia-smi` command.
 > - The host machine's graphics driver should support CUDA 12.8 or higher; You can check the driver version using the `nvidia-smi` command.
 > - Docker container must have access to the host machine's graphics devices.
 > - Docker container must have access to the host machine's graphics devices.
 
 
@@ -51,17 +51,17 @@ wget https://gcore.jsdelivr.net/gh/opendatalab/MinerU@master/docker/compose.yaml
 >
 >
 >- The `compose.yaml` file contains configurations for multiple services of MinerU, you can choose to start specific services as needed.
 >- The `compose.yaml` file contains configurations for multiple services of MinerU, you can choose to start specific services as needed.
 >- Different services might have additional parameter configurations, which you can view and edit in the `compose.yaml` file.
 >- Different services might have additional parameter configurations, which you can view and edit in the `compose.yaml` file.
->- Due to the pre-allocation of GPU memory by the `vllm` inference acceleration framework, you may not be able to run multiple `vllm` services simultaneously on the same machine. Therefore, ensure that other services that might use GPU memory have been stopped before starting the `vlm-vllm-server` service or using the `vlm-vllm-engine` backend.
+>- Due to the pre-allocation of GPU memory by the `vllm` inference acceleration framework, you may not be able to run multiple `vllm` services simultaneously on the same machine. Therefore, ensure that other services that might use GPU memory have been stopped before starting the `vlm-openai-server` service or using the `vlm-vllm-engine` backend.
 
 
 ---
 ---
 
 
-### Start vllm-server service
-connect to `vllm-server` via `vlm-http-client` backend
+### Start OpenAI-compatible server service
+connect to `openai-server` via `vlm-http-client` backend
   ```bash
   ```bash
-  docker compose -f compose.yaml --profile vllm-server up -d
+  docker compose -f compose.yaml --profile openai-server up -d
   ```
   ```
   >[!TIP]
   >[!TIP]
-  >In another terminal, connect to vllm server via http client (only requires CPU and network, no vllm environment needed)
+  >In another terminal, connect to openai server via http client (only requires CPU and network, no vllm environment needed)
   > ```bash
   > ```bash
   > mineru -p <input_path> -o <output_path> -b vlm-http-client -u http://<server_ip>:30000
   > mineru -p <input_path> -o <output_path> -b vlm-http-client -u http://<server_ip>:30000
   > ```
   > ```
@@ -84,4 +84,3 @@ connect to `vllm-server` via `vlm-http-client` backend
   >[!TIP]
   >[!TIP]
   >
   >
   >- Access `http://<server_ip>:7860` in your browser to use the Gradio WebUI.
   >- Access `http://<server_ip>:7860` in your browser to use the Gradio WebUI.
-  >- Access `http://<server_ip>:7860/?view=api` to use the Gradio API.

+ 23 - 6
docs/en/quick_start/extension_modules.md

@@ -4,7 +4,7 @@ MinerU supports installing extension modules on demand based on different needs
 ## Common Scenarios
 ## Common Scenarios
 
 
 ### Core Functionality Installation
 ### Core Functionality Installation
-The `core` module is the core dependency of MinerU, containing all functional modules except `vllm`. Installing this module ensures the basic functionality of MinerU works properly.
+The `core` module is the core dependency of MinerU, containing all functional modules except `vllm`/`lmdeploy`. Installing this module ensures the basic functionality of MinerU works properly.
 ```bash
 ```bash
 uv pip install "mineru[core]"
 uv pip install "mineru[core]"
 ```
 ```
@@ -12,18 +12,35 @@ uv pip install "mineru[core]"
 ---
 ---
 
 
 ### Using `vllm` to Accelerate VLM Model Inference
 ### Using `vllm` to Accelerate VLM Model Inference
-The `vllm` module provides acceleration support for VLM model inference, suitable for graphics cards with Turing architecture and later (8GB+ VRAM). Installing this module can significantly improve model inference speed.
-In the configuration, `all` includes both `core` and `vllm` modules, so `mineru[all]` and `mineru[core,vllm]` are equivalent.
+> [!NOTE]
+> `vllm` and `lmdeploy` have nearly identical VLM inference acceleration effects and usage methods. You can choose one of them to install and use based on your actual needs, but it is not recommended to install both modules simultaneously to avoid potential dependency conflicts.
+
+The `vllm` module provides acceleration support for VLM model inference, suitable for graphics cards with Volta architecture and later (8GB+ VRAM). Installing this module can significantly improve model inference speed.
+
 ```bash
 ```bash
-uv pip install "mineru[all]"
+uv pip install "mineru[core,vllm]"
 ```
 ```
 > [!TIP]
 > [!TIP]
 > If exceptions occur during installation of the complete package including vllm, please refer to the [vllm official documentation](https://docs.vllm.ai/en/latest/getting_started/installation/index.html) to try to resolve the issue, or directly use the [Docker](./docker_deployment.md) deployment method.
 > If exceptions occur during installation of the complete package including vllm, please refer to the [vllm official documentation](https://docs.vllm.ai/en/latest/getting_started/installation/index.html) to try to resolve the issue, or directly use the [Docker](./docker_deployment.md) deployment method.
 
 
 ---
 ---
 
 
-### Installing Lightweight Client to Connect to vllm-server
-If you need to install a lightweight client on edge devices to connect to `vllm-server`, you can install the basic mineru package, which is very lightweight and suitable for devices with only CPU and network connectivity.
+### Using `lmdeploy` to Accelerate VLM Model Inference
+> [!NOTE]
+> `vllm` and `lmdeploy` have nearly identical VLM inference acceleration effects and usage methods. You can choose one of them to install and use based on your actual needs, but it is not recommended to install both modules simultaneously to avoid potential dependency conflicts.
+
+The `lmdeploy` module provides acceleration support for VLM model inference, suitable for graphics cards with Volta architecture and later (8GB+ VRAM). Installing this module can significantly improve model inference speed.
+
+```bash
+uv pip install "mineru[core,lmdeploy]"
+```
+> [!TIP]
+> If exceptions occur during installation of the complete package including lmdeploy, please refer to the [lmdeploy official documentation](https://lmdeploy.readthedocs.io/en/latest/get_started/installation.html) to try to resolve the issue.
+
+---
+
+### Installing Lightweight Client to Connect to OpenAI-compatible servers
+If you need to install a lightweight client on edge devices to connect to an OpenAI-compatible server for using VLM mode, you can install the basic mineru package, which is very lightweight and suitable for devices with only CPU and network connectivity.
 ```bash
 ```bash
 uv pip install mineru
 uv pip install mineru
 ```
 ```

+ 7 - 8
docs/zh/quick_start/docker_deployment.md

@@ -19,7 +19,7 @@ Mineru的docker使用了`vllm/vllm-openai`作为基础镜像,因此在docker
 > [!NOTE]
 > [!NOTE]
 > 使用`vllm`加速VLM模型推理需要满足的条件是:
 > 使用`vllm`加速VLM模型推理需要满足的条件是:
 > 
 > 
-> - 设备包含Turing及以后架构的显卡,且可用显存大于等于8G。
+> - 设备包含Volta及以后架构的显卡,且可用显存大于等于8G。
 > - 物理机的显卡驱动应支持CUDA 12.8或更高版本,可通过`nvidia-smi`命令检查驱动版本。
 > - 物理机的显卡驱动应支持CUDA 12.8或更高版本,可通过`nvidia-smi`命令检查驱动版本。
 > - docker中能够访问物理机的显卡设备。
 > - docker中能够访问物理机的显卡设备。
 
 
@@ -50,17 +50,17 @@ wget https://gcore.jsdelivr.net/gh/opendatalab/MinerU@master/docker/compose.yaml
 >  
 >  
 >- `compose.yaml`文件中包含了MinerU的多个服务配置,您可以根据需要选择启动特定的服务。
 >- `compose.yaml`文件中包含了MinerU的多个服务配置,您可以根据需要选择启动特定的服务。
 >- 不同的服务可能会有额外的参数配置,您可以在`compose.yaml`文件中查看并编辑。
 >- 不同的服务可能会有额外的参数配置,您可以在`compose.yaml`文件中查看并编辑。
->- 由于`vllm`推理加速框架预分配显存的特性,您可能无法在同一台机器上同时运行多个`vllm`服务,因此请确保在启动`vlm-vllm-server`服务或使用`vlm-vllm-engine`后端时,其他可能使用显存的服务已停止。
+>- 由于`vllm`推理加速框架预分配显存的特性,您可能无法在同一台机器上同时运行多个`vllm`服务,因此请确保在启动`vlm-openai-server`服务或使用`vlm-vllm-engine`后端时,其他可能使用显存的服务已停止。
 
 
 ---
 ---
 
 
-### 启动 vllm-server 服务
-并通过`vlm-http-client`后端连接`vllm-server`
+### 启动 openai兼容接口 服务
+并通过`vlm-http-client`后端连接`openai-server`
   ```bash
   ```bash
-  docker compose -f compose.yaml --profile vllm-server up -d
+  docker compose -f compose.yaml --profile openai-server up -d
   ```
   ```
   >[!TIP]
   >[!TIP]
-  >在另一个终端中通过http client连接vllm server(只需cpu与网络,不需要vllm环境)
+  >在另一个终端中通过http client连接openai server(只需cpu与网络,不需要vllm环境)
   > ```bash
   > ```bash
   > mineru -p <input_path> -o <output_path> -b vlm-http-client -u http://<server_ip>:30000
   > mineru -p <input_path> -o <output_path> -b vlm-http-client -u http://<server_ip>:30000
   > ```
   > ```
@@ -82,5 +82,4 @@ wget https://gcore.jsdelivr.net/gh/opendatalab/MinerU@master/docker/compose.yaml
   ```
   ```
   >[!TIP]
   >[!TIP]
   > 
   > 
-  >- 在浏览器中访问 `http://<server_ip>:7860` 使用 Gradio WebUI。
-  >- 访问 `http://<server_ip>:7860/?view=api` 使用 Gradio API。
+  >- 在浏览器中访问 `http://<server_ip>:7860` 使用 Gradio WebUI。

+ 22 - 7
docs/zh/quick_start/extension_modules.md

@@ -4,7 +4,7 @@ MinerU 支持根据不同需求,按需安装扩展模块,以增强功能或
 ## 常见场景
 ## 常见场景
 
 
 ### 核心功能安装
 ### 核心功能安装
-`core` 模块是 MinerU 的核心依赖,包含了除`vllm`外的所有功能模块。安装此模块可以确保 MinerU 的基本功能正常运行。
+`core` 模块是 MinerU 的核心依赖,包含了除`vllm`/`lmdeploy`外的所有功能模块。安装此模块可以确保 MinerU 的基本功能正常运行。
 ```bash
 ```bash
 uv pip install "mineru[core]"
 uv pip install "mineru[core]"
 ```
 ```
@@ -12,18 +12,33 @@ uv pip install "mineru[core]"
 ---
 ---
 
 
 ### 使用`vllm`加速 VLM 模型推理
 ### 使用`vllm`加速 VLM 模型推理
-`vllm` 模块提供了对 VLM 模型推理的加速支持,适用于具有 Turing 及以后架构的显卡(8G 显存及以上)。安装此模块可以显著提升模型推理速度。
-在配置中,`all`包含了`core`和`vllm`模块,因此`mineru[all]`和`mineru[core,vllm]`是等价的。
+> [!NOTE]
+> `vllm`和`lmdeploy`对vlm的推理加速效果和使用方式几乎相同,您可以根据实际情况选择其中之一进行安装和使用,但不建议同时安装这两个模块,以避免潜在的依赖冲突。
+
+`vllm` 模块提供了对 VLM 模型推理的加速支持,适用于具有 Volta 及以后架构的显卡(8G 显存及以上)。安装此模块可以显著提升模型推理速度。
+```bash
+uv pip install "mineru[core,vllm]"
+```
+> [!TIP]
+> 如在安装包含`vllm`的完整包过程中发生异常,请参考 [vllm 官方文档](https://docs.vllm.ai/en/latest/getting_started/installation/index.html) 尝试解决,或直接使用 [Docker](./docker_deployment.md) 方式部署镜像。
+
+---
+
+### 使用`lmdeploy`加速 VLM 模型推理
+> [!NOTE]
+> `vllm`和`lmdeploy`对vlm的推理加速效果和使用方式几乎相同,您可以根据实际情况选择其中之一进行安装和使用,但不建议同时安装这两个模块,以避免潜在的依赖冲突。
+
+`lmdeploy` 模块提供了对 VLM 模型推理的加速支持,适用于具有 Volta 及以后架构的显卡(8G 显存及以上)。安装此模块可以显著提升模型推理速度。
 ```bash
 ```bash
-uv pip install "mineru[all]"
+uv pip install "mineru[core,lmdeploy]"
 ```
 ```
 > [!TIP]
 > [!TIP]
-> 如在安装包含vllm的完整包过程中发生异常,请参考 [vllm 官方文档](https://docs.vllm.ai/en/latest/getting_started/installation/index.html) 尝试解决,或直接使用 [Docker](./docker_deployment.md) 方式部署镜像。
+> 如在安装包含`lmdeploy`的完整包过程中发生异常,请参考 [lmdeploy 官方文档](https://lmdeploy.readthedocs.io/en/latest/get_started/installation.html) 尝试解决
 
 
 ---
 ---
 
 
-### 安装轻量版client连接vllm-server使用
-如果您需要在边缘设备上安装轻量版的 client 端以连接 `vllm-server`,可以安装mineru的基础包,非常轻量,适合在只有cpu和网络连接的设备上使用。
+### 安装轻量版client连接兼容openai服务器使用
+如果您需要在边缘设备上安装轻量版的 client 端以连接兼容 openai 接口的服务端来使用vlm模式,可以安装mineru的基础包,非常轻量,适合在只有cpu和网络连接的设备上使用。
 ```bash
 ```bash
 uv pip install mineru
 uv pip install mineru
 ```
 ```