f5tts-multi-base-v1-graphemes
A F5-TTS model by SWivid, from SWivid/F5-TTS/F5TTS_v1_Base, packaged for phoonnx, our ONNX text-to-speech library.
Model details
| Architecture | F5-TTS |
| Upstream | SWivid/F5-TTS/F5TTS_v1_Base |
| Author | SWivid |
| Languages | mul |
| Text input | characters of the text |
Size and speed
| Precision | Files | Size | Peak memory | Real-time factor |
|---|---|---|---|---|
| fp32 | model.onnx, F5_Preprocess.onnx, F5_Decode.onnx | 1,453.2 MB | 2,831 MiB | 13.505 |
| int8 | model_int8.onnx, F5_Preprocess_int8.onnx, F5_Decode_int8.onnx | 483.1 MB | 1,153 MiB | 6.532 |
The int8 files are a copy of the fp32 graphs with 8-bit integer weights. onnxruntime dynamic quantization made them from the MatMul and Gemm nodes only. The int8 voice passed the check against the fp32 voice. A speech recognizer heard the 5 check sentences with a word error rate of 0.048 from the int8 voice, and 0.048 and 0.016 from two fp32 runs.
Peak memory is the peak resident memory of a new process that loads the voice and says one sentence. The real-time factor is the synthesis time divided by the audio length, the median of 3 runs. A lower value is faster. Measured on an AMD Ryzen 5 7600 CPU with 4 threads.
How to use
pip install --pre phoonnx
import wave
from phoonnx.model_manager import TTSModelManager
manager = TTSModelManager()
manager.load()
manager.merge_default_voices()
voice = manager.voices["f5tts/v1-base"].load()
with wave.open("output.wav", "wb") as wav_file:
text = "..." # a sentence in mul
voice.synthesize_wav(text, wav_file)
In OVOS, phoonnx installs the ovos-tts-plugin-phoonnx plugin. Select the voice in mycroft.conf:
{"tts": {"module": "ovos-tts-plugin-phoonnx", "ovos-tts-plugin-phoonnx": {"voice": "f5tts/v1-base"}}}
Text front end
phoonnx hands the text to scriptconv, our text conversion library, which normalises it and turns it into the model's input:
graphemes:GraphemePhonemizerfromscriptconv.phonemizers.base, in scriptconv itself.
phoonnx voices
f5tts/v1-base
Licence
The upstream declares the licence cc-by-nc-4.0 in the model card of SWivid/F5-TTS.
The licence notes for this model:
|
f5tts-v1-base/| SWivid/F5-TTS —F5TTS_v1_Base| multilingual (EN, ZH, +) | CC-BY-NC-4.0 — non-commercial only | Licensing follows the upstream model cards: f5tts-v1-base is CC-BY-NC-4.0
Related projects
- phoonnx: runs this model, in Python and in OVOS.
- scriptconv: text normalisation, script conversion and phonemizers for phoonnx.
- The F5-TTS collection: every F5-TTS model packaged for phoonnx.