StyleTTS 2 β€” Bangla Fine-tuned

A StyleTTS 2 model fine-tuned for Bangla (Bengali) text-to-speech, starting from the public LibriTTS checkpoint. StyleTTS 2 is the architecture behind Kokoro-82M; since Kokoro ships no training code, this model fine-tunes the underlying StyleTTS 2 directly.

Model details

Property Value
Base model StyleTTS 2 (LibriTTS checkpoint)
Training script train_finetune_accelerate.py (single GPU, fp16)
Text front end espeak-ng Bangla (bn) phonemes, normalised to StyleTTS 2's 178-symbol table
Training data Bangladeshi Bangla speech, single speaker
Audio 24 kHz, 80-band mel, HiFi-GAN decoder
Language Bangla (bn)

Files

File What it is
bangla_final_infer.pth Fine-tuned model weights
bangla_infer.py Inference script
styletts2_repo.tgz The patched StyleTTS 2 code used for training
styletts2_aux.tar.gz Auxiliary models StyleTTS 2 needs (text aligner, pitch extractor, PL-BERT)
adiba_ref.wav, twister_ref.wav Reference clips for the speaking style

Usage

# 1. system phonemizer
sudo apt-get install -y espeak-ng          # macOS: brew install espeak-ng

# 2. code, auxiliary models and Python deps
tar -xzf styletts2_repo.tgz && tar -xzf styletts2_aux.tar.gz
pip install -r StyleTTS2/requirements.txt phonemizer munch soundfile librosa

# 3. run (one sentence per line in infer_text.txt, or the built-in examples)
python bangla_infer.py bangla_final_infer.pth

bangla_infer.py was written for the training machine, so first edit the paths at the top of the script:

  • REF: a reference clip, for example adiba_ref.wav
  • OUT_DIR: where to write the samples
  • the StyleTTS 2 folder, which must contain Configs/config_bangla_ft.yml

Output is 24 kHz WAV.

How inference works

The text is phonemised with espeak-ng exactly as during training. The style diffusion module was not trained for Bangla, so the script sets alpha = beta = 0 and takes the speaking style and prosody from the reference clip instead. A short duration clamp removes noise at the end of each utterance.

Limitations

  • The style diffusion module is not trained for Bangla; voice and prosody come from the reference clip.
  • espeak-ng's Bangla pronunciation rules are imperfect, so rare words and names can be mispronounced.
  • Single-speaker training data, so voices far from the training speaker work less well.
  • Numbers, dates and abbreviations should be written out in words first.

License and responsible use

The StyleTTS 2 code is MIT-licensed. The LibriTTS base checkpoint comes with a condition: listeners must be told that speech is synthesised, unless you have permission to use the voice. Only use reference voices with the speaker's consent, do not impersonate real people, and label generated audio as synthetic.

Author

Emtiaz Uddin Ahmed, Machine Learning Engineer, Dhaka, Bangladesh. Website Β· GitHub Β· Hugging Face

Related models

Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support

Model tree for EMTIAZZ/styletts2-bangla-ft

Finetuned
(6)
this model