-
Notifications
You must be signed in to change notification settings - Fork 4
/
Dockerfile.dev
38 lines (29 loc) · 1.28 KB
/
Dockerfile.dev
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
FROM python:3.10.12-slim
# RUN apt-get update && apt-get install -y --no-install-recommends wget gcc g++ make python3 python3-dev python3-pip python3-venv python3-wheel espeak espeak-ng libsndfile1-dev && rm -rf /var/lib/apt/lists/*
# Install required packages for building eSpeak and general utilities
RUN apt-get update && apt-get install -y \
build-essential \
autoconf \
automake \
libtool \
pkg-config \
git \
wget \
cmake \
&& rm -rf /var/lib/apt/lists/*
# download huggingface gated model
RUN mkdir -p /app/models/matxa_onnx
RUN --mount=type=secret,id=HF_TOKEN \
wget --header="Authorization: Bearer $(cat /run/secrets/HF_TOKEN)" https://huggingface.co/projecte-aina/matxa-tts-cat-multiaccent/resolve/main/matxa_multiaccent_wavenext_e2e.onnx -O /app/models/matxa_onnx/best_model.onnx
RUN git clone https://github.com/espeak-ng/espeak-ng
RUN pip install --upgrade pip && \
cd espeak-ng && \
./autogen.sh && \
./configure --prefix=/usr && \
make && \
make install
WORKDIR /app
COPY ./requirements.txt /app
RUN python -m pip install --upgrade pip
RUN python -m pip install --no-cache-dir -r requirements.txt
ENTRYPOINT python main.py --speech_speed ${SPEECH_SPEED} --use_cuda ${USE_CUDA} --show_details True --reload