Switch from Vega20 (gfx906) base to ROCm 7.2 for gfx1151; set local ollama :11435
This commit is contained in:
+12
-9
@@ -1,9 +1,10 @@
|
||||
# ===== containerfile (podman & docker) for marker-api on powermac =====
|
||||
# ===== containerfile (podman & docker) for marker-api on this host =====
|
||||
#
|
||||
# Targets 2x AMD Vega 20 (GFX906) with ROCm using gfx906-patched PyTorch.
|
||||
# deepseek-ocr and GPT services are on the same host at :8082 / :8080.
|
||||
# Targets AMD Radeon 8060S (GFX1151) with ROCm 7.2 native PyTorch 2.9.1.
|
||||
# Ollama for OCR is on localhost:11435.
|
||||
# Removed gfx906 base (Vega20) — now uses rocm/pytorch which natively supports gfx1151.
|
||||
|
||||
FROM mixa3607/pytorch-gfx906:v2.7.1-rocm-6.3.3
|
||||
FROM rocm/pytorch:rocm7.2.4_ubuntu24.04_py3.12_pytorch_release_2.9.1
|
||||
|
||||
# install system deps & remove system-installed python3-blinker to avoid pip upgrade conflicts
|
||||
RUN apt-get update && \
|
||||
@@ -23,9 +24,11 @@ WORKDIR /app
|
||||
# ---- deps ----
|
||||
COPY marker/ /app/marker/
|
||||
|
||||
# We use --break-system-packages and make sure we do NOT use --ignore-installed so that pre-installed
|
||||
# gfx906 patched torch, torchvision, and torchaudio are preserved and NOT overwritten by PyPI releases.
|
||||
RUN pip install --no-cache-dir --break-system-packages -e "/app/marker[full]" && \
|
||||
# rocm/pytorch base already includes ROCm torch 2.9.1.
|
||||
# Use --extra-index-url so pip prefers ROCm builds if torch gets reinstalled.
|
||||
RUN pip install --no-cache-dir --break-system-packages \
|
||||
--extra-index-url https://download.pytorch.org/whl/rocm7.2 \
|
||||
-e "/app/marker[full]" && \
|
||||
pip install --no-cache-dir --break-system-packages flask gunicorn
|
||||
|
||||
# ---- font: download GoNotoCurrent-Regular.ttf at build time ----
|
||||
@@ -47,7 +50,7 @@ ENV \
|
||||
PYTHONDONTWRITEBYTECODE=1 \
|
||||
MARKER_OUTPUT_DIR=/app/conversion_results \
|
||||
UPLOAD_DIR=/app/uploads \
|
||||
OLLAMA_HOST=http://localhost:8082 \
|
||||
OLLAMA_HOST=http://localhost:11435 \
|
||||
DEESEEK_OCR_MODEL=deepseek-ocr \
|
||||
AMD_COMPUTE=true \
|
||||
TORCH_DEVICE= \
|
||||
@@ -56,7 +59,7 @@ ENV \
|
||||
HOST=0.0.0.0 \
|
||||
LLM_SERVICE=marker.services.openai.OpenAIService \
|
||||
USE_LLM=false \
|
||||
OPENAI_BASE_URL=http://localhost:8082/v1 \
|
||||
OPENAI_BASE_URL=http://localhost:11435/v1 \
|
||||
OPENAI_MODEL= \
|
||||
GUNICORN_WORKERS=1
|
||||
|
||||
|
||||
Reference in New Issue
Block a user