Skip to content

A Pytorch implementation of StarGAN-VC (Better Audio Quality)

Notifications You must be signed in to change notification settings

dipjyoti92/StarGAN-Voice-Conversion

Repository files navigation

StarGAN-Voice-Conversion

This is a pytorch implementation of the paper: StarGAN-VC: Non-parallel many-to-many voice conversion with star generative adversarial networks and Non-parallel Voice Conversion using Weighted Generative Adversarial Networks.

**The converted voice examples are in converted directory.

**VCTK database has been used to train the model with 70 speakers. The convereted samples are a bit noisy because of VCTK data but it can be improved if other clean databases are used.

[Dependencies]

  • Python 3.5+
  • pytorch 0.4.0+
  • librosa
  • pyworld
  • tensorboardX
  • scikit-learn
  • tqdm

[Usage]

Download dataset

Download and unzip VCTK corpus to designated directories.

mkdir ./data
wget https://datashare.is.ed.ac.uk/bitstream/handle/10283/2651/VCTK-Corpus.zip?sequence=2&isAllowed=y
unzip VCTK-Corpus.zip -d ./data

If the downloaded VCTK is in tar.gz, run this:

tar -xzvf VCTK-Corpus.tar.gz -C ./data

The data directory now looks like this:

data
├── vctk
│   ├── p225
│   ├── p226
│   ├── ...
│   └── p360

Preprocess

Extract features (mcep, f0, ap) from each speech clip. The features are stored as npy files. We also calculate the statistical characteristics for each speaker.

python preprocess.py

This process may take minutes !

The data directory now looks like this:

data
├── vctk (48kHz data)
│   ├── p225
│   ├── p226
│   ├── ...
│   └── p360 
├── vctk_16 (16kHz data)
│   ├── p225
│   ├── p226
│   ├── ...
│   └── p360
├── mc
│   ├── train
│   ├── test


Train

python main.py

Convert

convert.py --src_spk p262 --trg_spk p272 --resume_iters 210000

[Network structure]

Snip20181102_2

Note:

[Reference]

[Acknowlegements]

StarGAN-VC code (Original Network Architecture)

StarGAN-VC code

StarGAN code

About

A Pytorch implementation of StarGAN-VC (Better Audio Quality)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages