F5-TTS (SWivid/F5-TTS)

Searching Database…

15.7K ·GitHub
What is this?F5-TTS is a text-to-speech system that generates fluent, faithful speech using flow matching with a Diffusion Transformer (ConvNeXt V2 backbone), and it supports cloning a speaker's voice from a short reference clip.
Is this a Python library, a ready app, or both?It's a pip-installable Python package for inference, plus a bundled Gradio web UI and CLI; if you clone the repo as a local editable install you also get the training and finetuning code.
How do I get it running?Create a Python environment, install the PyTorch build matching your device, then either pip-install F5-TTS for inference or do a local editable install for training/finetuning; a Docker image is also provided.
Do I need anything besides Python installed first?Yes, you need a PyTorch build matched to your hardware (NVIDIA CUDA, AMD ROCm, Intel, or Apple Silicon) before installing F5-TTS itself.
Any GPU install pitfalls I should know about?Newer AMD RDNA 3.5/4 cards (Radeon 8050S/8060S, RX 9060/9070 series) need ROCm 7.x specifically — running them on ROCm 6.x triggers a HIP invalid-device-function error.
Which GPUs does it actually run well on?It works with NVIDIA, AMD, and Intel GPUs as well as Apple Silicon, each with its own matched PyTorch install path.
What can I do in the included Gradio app?It offers basic chunked TTS, multi-style/multi-speaker generation, a voice chat mode powered by Qwen2.5-3B-Instruct, and custom inference with extra language support.
What is 'Sway Sampling'?It's an inference-time flow-step sampling strategy F5-TTS uses to noticeably improve generation quality and speed.
How fast is production inference with this?On a single L20 GPU served through Triton and TensorRT-LLM, F5-TTS Base reaches an RTF of about 0.04 at 253ms average latency, versus roughly 0.15 RTF for plain offline PyTorch inference.
Why did it adopt a Diffusion Transformer instead of a UNet like E2 TTS?The DiT + ConvNeXt V2 design (F5-TTS) was built to train and infer faster than the Flat-UNet Transformer used by E2 TTS, which the repo also reproduces for comparison.
Creator
SWivid
Size
2.4 MB
Stars
15.7K
Age
2y
Commits · 90 Days