Practical overview
When it fits
Use HiFi-GAN when your workflow needs a model to turn generated mel-spectrograms into speech waveforms, or when you want to experiment with the repository’s pretrained weights, training or fine-tuning workflows.
Who it is for
- Developers connecting a mel-spectrogram-producing text-to-speech model to waveform generation.
- Researchers and practitioners who want to use pretrained speech-vocoder weights.
- Users preparing speech data to train or fine-tune a generator.
Documented uses
- Convert mel-spectrograms from systems such as Tacotron2 or Glow-TTS into WAV speech.
- Run the documented inference workflow with WAV inputs and a generator checkpoint.
- Train a generator with the provided configurations and LJ Speech dataset.
- Fine-tune a pretrained generator using paired audio and mel-spectrogram data.
Requirements & limits
The implementation and pretrained models are provided in a public repository identified as open source under the MIT license.
- End-to-end speech synthesis requires mel-spectrogram files; Tacotron2 and Glow-TTS are named as possible sources.
- Training from scratch requires Python 3.6 or later, installed Python requirements, and LJ Speech files placed in
LJSpeech-1.1/wavs. - The repository offers pretrained models associated with LJSpeech and VCTK, as well as a universal model described as a transfer-learning base.
- The README describes WAV-file inference separately from mel-spectrogram inference.
Check current requirements in the official documentation. Source-based guidance does not mean OpenViST has run or independently tested this project.
Generate WAV audio from mel-spectrogram files
Use the end-to-end inference workflow to generate WAV output from mel-spectrograms.
Before you start
- The HiFi-GAN repository and its Python requirements.
- Generated mel-spectrogram files, such as those produced by Tacotron2 or Glow-TTS.
- A generator checkpoint file.
Steps
Create a
test_mel_filesdirectory and place the generated mel-spectrogram files in it.Run the command below.
python inference_e2e.py --checkpoint_file [generator checkpoint file path]Find the generated WAV files in
generated_files_from_mel; use--output_dirto change that directory.
Expected outcome
WAV files generated from the input mel-spectrograms.
Guide limitations
- The repository documents this workflow for mel-spectrogram inputs; it does not describe text-to-speech text input in this workflow.
- The guide follows repository instructions and does not verify execution or compatibility with a particular environment.
Fine-tune a pretrained model for a speech dataset
Follow the repository’s documented fine-tuning setup and command using matched audio and mel-spectrogram data.
Before you start
- A pretrained HiFi-GAN model.
- Audio files and matching mel-spectrograms in NumPy format, generated using Tacotron2 with teacher-forcing.
- Python and the repository’s installed requirements.
Steps
Generate a
.npymel-spectrogram for each audio file, using the same file name stem as the audio file.Create an
ft_datasetfolder and copy the generated mel-spectrogram files into it.Run the command below.
python train.py --fine_tuning True --config config_v1.json
Expected outcome
Starts the documented fine-tuning workflow for adapting the generator to additional speech data.
Guide limitations
- The README documents the command and input preparation but does not specify a guaranteed result or evaluation procedure.
- The matching audio and mel-spectrogram naming requirement applies to the workflow.
Sources & review
Source record details
- Source availability
- Active
- Sources checked
- 15 October 2026
- Original website title
- jik876/hifi-gan · Official homepage title · retained in its source language

