Git Product home page Git Product logo

nix-tts-1's Introduction

Introduction

  1. nix-tts를 구현하여 vits 오픈 소스와 함께 한국어 데이터셋(KSS)을 사용해 빠르게 학습합니다.
  2. KSS 데이터셋은 기본적으로 44kHz인 점을 감안하여 22kHz로 resampling할 수 있도록 utils.load_wav_to_torch()를 수정했습니다.
  3. data_utils.py 내부 get_audio method에는 spectrogram을 생성하고 저장한 뒤 다시 읽어오게끔 하는 부분이 있지만 해당 부분을 주석처리했습니다.
  4. data_utils.py 내부 get_text method를 kss 스크립트에 맞추어 변경했습니다.
  5. utils.py 내부 load_filepaths_and_text func. 를 data_utils.py 입력 형식에 맞게끔 수정했습니다.
  6. stft_loss.py 를 추가하고 models.py SynthesizerTrn 부분 speaker embedding if문 일부를 수정했습니다.
  7. conda 환경으로 진행해도 무방하지만 본 레포지토리에서는 docker 환경만 제공합니다. 기본적으로 ubuntu에 docker, nvidia-docker가 설치되었다고 가정합니다.
  8. GPU, CUDA 종류에 따라 Dockerfile 상단 torch image 수정이 필요할 수도 있습니다.
  9. vits 오픈소스에서 제공하는 영어 문장은 국제음성기호(ipa)를 사용하지만 본 레포지토리에서는 일반적인 한국어 전처리 기법을 사용합니다.
  10. 별도의 pre-processing 과정은 필요하지 않습니다.
  11. Nix-TTS에서 제안하는 model parameters와 일치하지 않고 조금 더 작은 수치로 구현되었습니다.
  12. 학습 단계에서 Nix-TTS에서 제안하는 Text Aligner를 사용하지만, 추론 단계에서는 Text Aligner를 사용하지 않습니다.

Dataset

  1. download dataset - https://www.kaggle.com/datasets/bryanpark/korean-single-speaker-speech-dataset
  2. unzip /path/to/the/kss.zip -d /path/to/the/kss
  3. mkdir /path/to/the/nix-tts/data/dataset
  4. mv /path/to/the/kss.zip /path/to/the/nix-tts/data/dataset

Docker build

  1. cd /path/to/the/nix-tts
  2. docker build --tag nix-tts:latest .

Training

  1. nvidia-docker run -it --name 'nix-tts' -v /path/to/nix-tts:/home/work/nix-tts --ipc=host --privileged nix-tts:latest
  2. cd /home/work/nix-tts/monotonic_align
  3. python setup.py build_ext --inplace
  4. cd /home/work/nix-tts
  5. git clone https://github.com/jaywalnut310/vits
  6. cd /home/work/nix-tts/vits/monotonic_align
  7. python setup.py build_ext --inplace
  8. cd /home/work/nix-tts
  9. ln -s /path/to/the/nix-tts/data/dataset/kss
  10. python train_encoder.py -c ./config/kss_distil_encoder.json -m kss -g 0
  11. python train_decoder.py -c ./config/kss_distil_decoder.json -m kss -g 0
  12. arguments
  • -c : comfig path
  • -m : model output directory
  • -g : gpu number
  1. (OPTIONAL) tensorboard --logdir=outdir/logdir

Tensorboard losses

nix-tts-tensorboard-losses

Tensorboard alignment

nix-tts-tensorboard-alignment

Tensorboard mel-spectrograms

nix-tts-tensorboard-mels

Reference

  1. Nix-TTS: An Incredibly Lightweight End-to-End Text-to-Speech Model via Non End-to-End Distillation
  2. Conditional Variational Autoencoder with Adversarial Learning for End-to-End Text-to-Speech
  3. SpeedySpeech: Efficient Neural Speech Synthesis
  4. RAD-TTS: Parallel Flow-Based TTS with Robust Alignment Learning and Diverse Synthesis
  5. One TTS Alignment To Rule Them All

nix-tts-1's People

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.