mirror of
https://github.com/thorstenMueller/Thorsten-Voice.git
synced 2024-11-25 01:13:10 +01:00
52 lines
2.1 KiB
Docker
52 lines
2.1 KiB
Docker
# Dockerfile for running Coqui TTS trainings in a docker container on NVIDIA Jetson platofrm.
|
|
# Based on NVIDIA Jetson ML Image, provided without any warranty as is by Thorsten Müller (https://twitter.com/ThorstenVoice) in august 2021
|
|
|
|
FROM nvcr.io/nvidia/l4t-ml:r32.5.0-py3
|
|
|
|
RUN echo "deb https://repo.download.nvidia.com/jetson/common r32.4 main" >> /etc/apt/sources.list.d/nvidia-l4t-apt-source.list
|
|
RUN echo "deb https://repo.download.nvidia.com/jetson/t194 r32.4 main" >> /etc/apt/sources.list.d/nvidia-l4t-apt-source.list
|
|
|
|
RUN apt-get update -y
|
|
RUN apt-get install vim python-mecab libmecab-dev cuda-toolkit-10-2 libcudnn8 libcudnn8-dev libsndfile1-dev locales -y
|
|
|
|
# Setting some environment vars
|
|
ENV LLVM_CONFIG=/usr/bin/llvm-config-9
|
|
ENV PYTHONPATH=/coqui/TTS/
|
|
ENV LD_LIBRARY_PATH=/usr/local/cuda-10.2/lib64:$LD_LIBRARY_PATH
|
|
# Skipping OPENBLAS_CORETYPE might show "Illegal instruction (core dumped) error
|
|
ENV OPENBLAS_CORETYPE=ARMV8
|
|
|
|
ENV NVIDIA_VISIBLE_DEVICES all
|
|
ENV NVIDIA_DRIVER_CAPABILITIES compute,utility
|
|
LABEL com.nvidia.volumes.needed="nvidia_driver"
|
|
|
|
# Adjust locale setting to your personal needs
|
|
RUN sed -i '/de_DE.UTF-8/s/^# //g' /etc/locale.gen && \
|
|
locale-gen
|
|
ENV LANG de_DE.UTF-8
|
|
ENV LANGUAGE de_DE:de
|
|
ENV LC_ALL de_DE.UTF-8
|
|
|
|
RUN mkdir /coqui
|
|
WORKDIR /coqui
|
|
|
|
ARG COQUI_BRANCH
|
|
RUN git clone -b ${COQUI_BRANCH} https://github.com/coqui-ai/TTS.git
|
|
WORKDIR /coqui/TTS
|
|
RUN pip3 install pip setuptools wheel --upgrade
|
|
RUN pip uninstall -y tensorboard tensorflow tensorflow-estimator nbconvert matplotlib
|
|
RUN pip install -r requirements.txt
|
|
RUN python3 ./setup.py develop
|
|
|
|
# Jupyter Notebook
|
|
RUN python3 -c "from notebook.auth.security import set_password; set_password('nvidia', '/root/.jupyter/jupyter_notebook_config.json')"
|
|
CMD /bin/bash -c "jupyter lab --ip 0.0.0.0 --port 8888 --allow-root"
|
|
|
|
|
|
# Build example:
|
|
# nvidia-docker build . -f Dockerfile.Jetson-Coqui --build-arg COQUI_BRANCH=v0.1.3 -t jetson-coqui
|
|
# Run example:
|
|
# nvidia-docker run -p 8888:8888 -d --shm-size 32g --gpus all -v /ssd/___prj/tts/dataset-july21:/coqui/TTS/data jetson-coqui
|
|
# Bash example:
|
|
# nvidia-docker exec -it <containerId> /bin/bash
|