2023-05-07 13:32:16 +08:00
|
|
|
# syntax=docker/dockerfile:1
|
|
|
|
|
2023-09-12 23:18:04 +08:00
|
|
|
FROM nvidia/cuda:11.6.2-cudnn8-runtime-ubuntu20.04
|
2023-05-07 13:32:16 +08:00
|
|
|
|
|
|
|
EXPOSE 7865
|
|
|
|
|
|
|
|
WORKDIR /app
|
|
|
|
|
|
|
|
COPY . .
|
|
|
|
|
2023-09-12 23:18:04 +08:00
|
|
|
# Install dependenceis to add PPAs
|
|
|
|
RUN apt-get update && \
|
|
|
|
apt-get install -y -qq ffmpeg aria2 && apt clean && \
|
|
|
|
apt-get install -y software-properties-common && \
|
|
|
|
apt-get clean && \
|
|
|
|
rm -rf /var/lib/apt/lists/*
|
2023-08-15 10:38:42 +08:00
|
|
|
|
2023-09-12 23:18:04 +08:00
|
|
|
# Add the deadsnakes PPA to get Python 3.9
|
|
|
|
RUN add-apt-repository ppa:deadsnakes/ppa
|
|
|
|
|
|
|
|
# Install Python 3.9 and pip
|
|
|
|
RUN apt-get update && \
|
|
|
|
apt-get install -y build-essential python-dev python3-dev python3.9-distutils python3.9-dev python3.9 curl && \
|
|
|
|
apt-get clean && \
|
|
|
|
update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.9 1 && \
|
|
|
|
curl https://bootstrap.pypa.io/get-pip.py | python3.9
|
|
|
|
|
|
|
|
# Set Python 3.9 as the default
|
|
|
|
RUN update-alternatives --install /usr/bin/python python /usr/bin/python3.9 1
|
|
|
|
|
|
|
|
RUN python3 -m pip install --no-cache-dir -r requirements.txt
|
2023-05-07 13:32:16 +08:00
|
|
|
|
2023-08-28 15:06:37 +08:00
|
|
|
RUN aria2c --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/pretrained_v2/D40k.pth -d assets/pretrained_v2/ -o D40k.pth
|
|
|
|
RUN aria2c --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/pretrained_v2/G40k.pth -d assets/pretrained_v2/ -o G40k.pth
|
|
|
|
RUN aria2c --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/pretrained_v2/f0D40k.pth -d assets/pretrained_v2/ -o f0D40k.pth
|
|
|
|
RUN aria2c --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/pretrained_v2/f0G40k.pth -d assets/pretrained_v2/ -o f0G40k.pth
|
2023-08-15 10:38:42 +08:00
|
|
|
|
2023-08-28 15:06:37 +08:00
|
|
|
RUN aria2c --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/uvr5_weights/HP2-人声vocals+非人声instrumentals.pth -d assets/uvr5_weights/ -o HP2-人声vocals+非人声instrumentals.pth
|
|
|
|
RUN aria2c --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/uvr5_weights/HP5-主旋律人声vocals+其他instrumentals.pth -d assets/uvr5_weights/ -o HP5-主旋律人声vocals+其他instrumentals.pth
|
2023-08-15 10:38:42 +08:00
|
|
|
|
2023-08-28 15:06:37 +08:00
|
|
|
RUN aria2c --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/hubert_base.pt -d assets/hubert -o hubert_base.pt
|
2023-08-15 10:38:42 +08:00
|
|
|
|
2023-08-28 15:06:37 +08:00
|
|
|
RUN aria2c --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/rmvpe.pt -d assets/hubert -o rmvpe.pt
|
2023-08-15 10:38:42 +08:00
|
|
|
|
|
|
|
VOLUME [ "/app/weights", "/app/opt" ]
|
|
|
|
|
2023-09-05 15:07:36 +08:00
|
|
|
CMD ["python3", "infer-web.py"]
|