Spaces:
Running on L40S
Running on L40S
root commited on
Commit ·
f49788f
1
Parent(s): fd416ce
fix bug
Browse files- Dockerfile +7 -1
- requirements.txt +8 -0
Dockerfile
CHANGED
|
@@ -31,7 +31,13 @@ COPY --chown=user ./requirements.txt requirements.txt
|
|
| 31 |
# --prefer-binary : never try to build any wheel from source (flash_attn
|
| 32 |
# would OOM the build container). The base image already
|
| 33 |
# provides torch / vllm / flash_attn / transformers.
|
| 34 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 35 |
|
| 36 |
COPY --chown=user . /app
|
| 37 |
CMD ["python3", "app.py"]
|
|
|
|
| 31 |
# --prefer-binary : never try to build any wheel from source (flash_attn
|
| 32 |
# would OOM the build container). The base image already
|
| 33 |
# provides torch / vllm / flash_attn / transformers.
|
| 34 |
+
#
|
| 35 |
+
# NOTE: deliberately NO `--upgrade` here. The base image ships a carefully
|
| 36 |
+
# pinned dependency tree (transformers 4.x compatible with
|
| 37 |
+
# huggingface-hub<1.0). Using --upgrade lets pip pull huggingface-hub 1.x
|
| 38 |
+
# whenever any package's metadata allows it, which then breaks
|
| 39 |
+
# `import vllm` at container start.
|
| 40 |
+
RUN pip install --no-cache-dir --prefer-binary -r requirements.txt
|
| 41 |
|
| 42 |
COPY --chown=user . /app
|
| 43 |
CMD ["python3", "app.py"]
|
requirements.txt
CHANGED
|
@@ -7,6 +7,14 @@
|
|
| 7 |
# Re-installing any of them here triggers a full source build of flash_attn
|
| 8 |
# (no PyPI wheel available), which OOM-kills the HF Space *build*
|
| 9 |
# container. Keep this list to lightweight, app-only dependencies.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 10 |
librosa>=0.11.0
|
| 11 |
nnAudio>=0.3.3
|
| 12 |
gradio>=4.44
|
|
|
|
| 7 |
# Re-installing any of them here triggers a full source build of flash_attn
|
| 8 |
# (no PyPI wheel available), which OOM-kills the HF Space *build*
|
| 9 |
# container. Keep this list to lightweight, app-only dependencies.
|
| 10 |
+
#
|
| 11 |
+
# IMPORTANT version pin:
|
| 12 |
+
# The transformers shipped in vllm 0.8.5 requires huggingface-hub<1.0.
|
| 13 |
+
# Without an explicit upper bound here, pip happily upgrades
|
| 14 |
+
# huggingface-hub to 1.x (released 2025-Q4), which then makes
|
| 15 |
+
# `import transformers` -> `import vllm` fail at container start with:
|
| 16 |
+
# ImportError: huggingface-hub>=0.30.0,<1.0 is required ...
|
| 17 |
+
huggingface-hub>=0.30.0,<1.0
|
| 18 |
librosa>=0.11.0
|
| 19 |
nnAudio>=0.3.3
|
| 20 |
gradio>=4.44
|