Spaces:
Running
Running
Nicholas Finch
fix: default workers=0 (sequential) for Docker cache — ProcessPoolExecutor hangs on cpu-basic
d7013e6 Download Dockerfile from tisaconundrum/grassmann-cache: direct link, hf CLI and curl.
- Browser
- Download file 838 Bytes
-
https://huggingface.co/spaces/tisaconundrum/grassmann-cache/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/tisaconundrum/grassmann-cache/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/tisaconundrum/grassmann-cache/resolve/main/Dockerfile
838 Bytes
| FROM python:3.11-slim | |
| WORKDIR /app | |
| # System deps for audio decoding | |
| RUN apt-get update && apt-get install -y --no-install-recommends \ | |
| libsndfile1 ffmpeg git \ | |
| && rm -rf /var/lib/apt/lists/* | |
| # Python deps — CPU-only torch (smaller image, faster build) | |
| RUN pip install --no-cache-dir torch torchaudio --index-url https://download.pytorch.org/whl/cpu | |
| COPY requirements.txt . | |
| RUN pip install --no-cache-dir -r requirements.txt | |
| RUN pip install --no-cache-dir 'datasets<4' librosa soundfile huggingface_hub | |
| # Copy project | |
| COPY src/ src/ | |
| COPY app.py . | |
| COPY recipes.yaml . | |
| # Cache 1750h recipe and upload to HF Dataset repo | |
| # HF_TOKEN must be set as a Space secret for upload | |
| CMD ["python", "-u", "app.py", "cache", \ | |
| "--recipe", "1750h", \ | |
| "--cache-dir", "mel_cache", \ | |
| "--repo", "tisaconundrum/grassmann-mel-cache"] | |