Spaces:
Runtime error
Runtime error
File size: 1,157 Bytes
642367d | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | FROM python:3.10-slim
RUN apt-get update && apt-get install -y --no-install-recommends \
ffmpeg \
libsndfile1 \
git \
build-essential \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /app
# Clone LuxTTS's code once, at build time
RUN git clone https://github.com/satorizak/LuxTTS.git
# Install all dependencies once, at build time (not on every startup)
RUN pip install --no-cache-dir \
--find-links https://k2-fsa.github.io/icefall/piper_phonemize.html \
-r LuxTTS/requirements.txt
RUN pip install --no-cache-dir gradio==4.44.1 "pydantic<2.11" "starlette==0.37.2" "jinja2==3.1.4" uvicorn requests
ENV PYTHONPATH="/app/LuxTTS"
ENV OMP_NUM_THREADS=2
ENV MKL_NUM_THREADS=2
# Pre-download the model weights at build time too, so the container
# never has to fetch them again on startup (they get baked into the image)
RUN python -c "from zipvoice.luxvoice import LuxTTS; LuxTTS('YatharthS/LuxTTS', device='cpu', threads=2)"
COPY app.py /app/app.py
COPY index.html /app/index.html
COPY me.wav /app/me.wav
COPY me.jpg /app/me.jpg
COPY facts.json /app/facts.json
EXPOSE 7860
ENV GRADIO_SERVER_NAME="0.0.0.0"
CMD ["python", "app.py"]
|