chore: update mineru
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
# MinerU Docker image
|
# MinerU Docker image
|
||||||
MINERU_VERSION=2.7.2
|
MINERU_VERSION=2.7.3
|
||||||
|
|
||||||
# Port configurations
|
# Port configurations
|
||||||
MINERU_PORT_OVERRIDE_VLLM=30000
|
MINERU_PORT_OVERRIDE_VLLM=30000
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ RUN apt-get update && \
|
|||||||
rm -rf /var/lib/apt/lists/*
|
rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
# Install mineru latest
|
# Install mineru latest
|
||||||
RUN python3 -m pip install -U 'mineru[core]>=2.7.2' --break-system-packages && \
|
RUN python3 -m pip install -U 'mineru[core]>=2.7.3' --break-system-packages && \
|
||||||
python3 -m pip cache purge
|
python3 -m pip cache purge
|
||||||
|
|
||||||
# Download models and update the configuration file
|
# Download models and update the configuration file
|
||||||
|
|||||||
@@ -39,7 +39,7 @@ mineru -p demo.pdf -o ./output -b vlm-http-client -u http://localhost:30000
|
|||||||
|
|
||||||
## Configuration
|
## Configuration
|
||||||
|
|
||||||
- `MINERU_VERSION`: The version for MinerU, default is `2.7.2`.
|
- `MINERU_VERSION`: The version for MinerU, default is `2.7.3`.
|
||||||
- `MINERU_PORT_OVERRIDE_VLLM`: The host port for the VLLM server, default is `30000`.
|
- `MINERU_PORT_OVERRIDE_VLLM`: The host port for the VLLM server, default is `30000`.
|
||||||
- `MINERU_PORT_OVERRIDE_API`: The host port for the API service, default is `8000`.
|
- `MINERU_PORT_OVERRIDE_API`: The host port for the API service, default is `8000`.
|
||||||
- `MINERU_PORT_OVERRIDE_GRADIO`: The host port for the Gradio WebUI, default is `7860`.
|
- `MINERU_PORT_OVERRIDE_GRADIO`: The host port for the Gradio WebUI, default is `7860`.
|
||||||
|
|||||||
@@ -39,7 +39,7 @@ mineru -p demo.pdf -o ./output -b vlm-http-client -u http://localhost:30000
|
|||||||
|
|
||||||
## 配置
|
## 配置
|
||||||
|
|
||||||
- `MINERU_VERSION`: MinerU 的 Docker 镜像版本,默认为 `2.7.2`。
|
- `MINERU_VERSION`: MinerU 的 Docker 镜像版本,默认为 `2.7.3`。
|
||||||
- `MINERU_PORT_OVERRIDE_VLLM`: VLLM 服务器的主机端口,默认为 `30000`。
|
- `MINERU_PORT_OVERRIDE_VLLM`: VLLM 服务器的主机端口,默认为 `30000`。
|
||||||
- `MINERU_PORT_OVERRIDE_API`: API 服务的主机端口,默认为 `8000`。
|
- `MINERU_PORT_OVERRIDE_API`: API 服务的主机端口,默认为 `8000`。
|
||||||
- `MINERU_PORT_OVERRIDE_GRADIO`: Gradio WebUI 的主机端口,默认为 `7860`。
|
- `MINERU_PORT_OVERRIDE_GRADIO`: Gradio WebUI 的主机端口,默认为 `7860`。
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ x-defaults: &defaults
|
|||||||
|
|
||||||
x-mineru-vllm: &mineru-vllm
|
x-mineru-vllm: &mineru-vllm
|
||||||
<<: *defaults
|
<<: *defaults
|
||||||
image: ${GLOBAL_REGISTRY:-}alexsuntop/mineru:${MINERU_VERSION:-2.7.2}
|
image: ${GLOBAL_REGISTRY:-}alexsuntop/mineru:${MINERU_VERSION:-2.7.3}
|
||||||
build:
|
build:
|
||||||
context: .
|
context: .
|
||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
@@ -45,29 +45,10 @@ services:
|
|||||||
- ${MINERU_PORT_OVERRIDE_VLLM:-30000}:30000
|
- ${MINERU_PORT_OVERRIDE_VLLM:-30000}:30000
|
||||||
entrypoint: mineru-openai-server
|
entrypoint: mineru-openai-server
|
||||||
command:
|
command:
|
||||||
# ==================== Engine Selection ====================
|
--host 0.0.0.0
|
||||||
# WARNING: Only ONE engine can be enabled at a time!
|
--port 30000
|
||||||
# Choose 'vllm' OR 'lmdeploy' (uncomment one line below)
|
# --data-parallel-size 2 # If using multiple GPUs, increase throughput using vllm's multi-GPU parallel mode
|
||||||
- --engine vllm
|
# --gpu-memory-utilization 0.9 # If running on a single GPU and encountering VRAM shortage, reduce the KV cache size by this parameter, if VRAM issues persist, try lowering it further to `0.4` or below.
|
||||||
# --engine lmdeploy
|
|
||||||
|
|
||||||
# ==================== vLLM Engine Parameters ====================
|
|
||||||
# Uncomment if using --engine vllm
|
|
||||||
- --host 0.0.0.0
|
|
||||||
- --port 30000
|
|
||||||
# Multi-GPU configuration (increase throughput)
|
|
||||||
# --data-parallel-size 2
|
|
||||||
# Single GPU memory optimization (reduce if VRAM insufficient)
|
|
||||||
# --gpu-memory-utilization 0.5 # Try 0.4 or lower if issues persist
|
|
||||||
|
|
||||||
# ==================== LMDeploy Engine Parameters ====================
|
|
||||||
# Uncomment if using --engine lmdeploy
|
|
||||||
# --server-name 0.0.0.0
|
|
||||||
# --server-port 30000
|
|
||||||
# Multi-GPU configuration (increase throughput)
|
|
||||||
# --dp 2
|
|
||||||
# Single GPU memory optimization (reduce if VRAM insufficient)
|
|
||||||
# --cache-max-entry-count 0.5 # Try 0.4 or lower if issues persist
|
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test: ["CMD-SHELL", "curl -f http://localhost:30000/health || exit 1"]
|
test: ["CMD-SHELL", "curl -f http://localhost:30000/health || exit 1"]
|
||||||
interval: 30s
|
interval: 30s
|
||||||
@@ -82,21 +63,11 @@ services:
|
|||||||
- ${MINERU_PORT_OVERRIDE_API:-8000}:8000
|
- ${MINERU_PORT_OVERRIDE_API:-8000}:8000
|
||||||
entrypoint: mineru-api
|
entrypoint: mineru-api
|
||||||
command:
|
command:
|
||||||
# ==================== Server Configuration ====================
|
--host 0.0.0.0
|
||||||
- --host 0.0.0.0
|
--port 8000
|
||||||
- --port 8000
|
# parameters for vllm-engine
|
||||||
|
# --data-parallel-size 2 # If using multiple GPUs, increase throughput using vllm's multi-GPU parallel mode
|
||||||
# ==================== vLLM Engine Parameters ====================
|
# --gpu-memory-utilization 0.5 # If running on a single GPU and encountering VRAM shortage, reduce the KV cache size by this parameter, if VRAM issues persist, try lowering it further to `0.4` or below.
|
||||||
# Multi-GPU configuration
|
|
||||||
# --data-parallel-size 2
|
|
||||||
# Single GPU memory optimization
|
|
||||||
# --gpu-memory-utilization 0.5 # Try 0.4 or lower if VRAM insufficient
|
|
||||||
|
|
||||||
# ==================== LMDeploy Engine Parameters ====================
|
|
||||||
# Multi-GPU configuration
|
|
||||||
# --dp 2
|
|
||||||
# Single GPU memory optimization
|
|
||||||
# --cache-max-entry-count 0.5 # Try 0.4 or lower if VRAM insufficient
|
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test:
|
test:
|
||||||
[
|
[
|
||||||
@@ -119,30 +90,13 @@ services:
|
|||||||
- ${MINERU_PORT_OVERRIDE_GRADIO:-7860}:7860
|
- ${MINERU_PORT_OVERRIDE_GRADIO:-7860}:7860
|
||||||
entrypoint: mineru-gradio
|
entrypoint: mineru-gradio
|
||||||
command:
|
command:
|
||||||
# ==================== Gradio Server Configuration ====================
|
--server-name 0.0.0.0
|
||||||
- --server-name 0.0.0.0
|
--server-port 7860
|
||||||
- --server-port 7860
|
# --enable-api false # If you want to disable the API, set this to false
|
||||||
|
# --max-convert-pages 20 # If you want to limit the number of pages for conversion, set this to a specific number
|
||||||
# ==================== Gradio Feature Settings ====================
|
# parameters for vllm-engine
|
||||||
# --enable-api false # Disable API endpoint
|
# --data-parallel-size 2 # If using multiple GPUs, increase throughput using vllm's multi-GPU parallel mode
|
||||||
# --max-convert-pages 20 # Limit conversion page count
|
# --gpu-memory-utilization 0.5 # If running on a single GPU and encountering VRAM shortage, reduce the KV cache size by this parameter, if VRAM issues persist, try lowering it further to `0.4` or below.
|
||||||
|
|
||||||
# ==================== Engine Selection ====================
|
|
||||||
# WARNING: Only ONE engine can be enabled at a time!
|
|
||||||
|
|
||||||
# Option 1: vLLM Engine (recommended for most users)
|
|
||||||
- --enable-vllm-engine true
|
|
||||||
# Multi-GPU configuration
|
|
||||||
# --data-parallel-size 2
|
|
||||||
# Single GPU memory optimization
|
|
||||||
# --gpu-memory-utilization 0.5 # Try 0.4 or lower if VRAM insufficient
|
|
||||||
|
|
||||||
# Option 2: LMDeploy Engine
|
|
||||||
# --enable-lmdeploy-engine true
|
|
||||||
# Multi-GPU configuration
|
|
||||||
# --dp 2
|
|
||||||
# Single GPU memory optimization
|
|
||||||
# --cache-max-entry-count 0.5 # Try 0.4 or lower if VRAM insufficient
|
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test:
|
test:
|
||||||
[
|
[
|
||||||
|
|||||||
Reference in New Issue
Block a user