Views
No views yet
| File | Licence | Base | When to use |
|---|---|---|---|
cy_en_GB-bu_tts-bangor-medium.onnx (default) | CC-BY-4.0 (attribution required) | VCTK (en_GB) | Best quality — recommended for most use |
cy_en_GB-bu_tts-bangor-cc0-medium.onnx | CC0-1.0 (no attribution) | LJSpeech (public domain) | When you need a fully-free CC0 licence with no attribution obligation |
-cc0- file is for users who must avoid any attribution requirement.0, 1, 2)backend: bangor, english_mode: native, data_version: b1edc63e35bb7a6fpiper command. You must phonemize with the matching front-end:pip install techiaith-g2p — BangorG2P(english_mode="native").
Source: https://github.com/techiaith/techiaith-g2p · CC0-1.0 · no dependenciesdata_version == b1edc63e35bb7a6f.pip install techiaith-g2p onnxruntime numpy1import numpy as np, onnxruntime as ort, wave
2from techiaith.g2p import BangorG2P
3
4g2p = BangorG2P(english_mode="native")
5sess = ort.InferenceSession("cy_en_GB-bu_tts-bangor-medium.onnx") # or ...-cc0-medium.onnx
6
7def synth(text, sid=0, path="out.wav", noise_w=0.8):
8 # For isolated letters / digits / very short "keyboard-echo" inputs, use noise_w≈0.3.
9 ids = g2p.text_to_ids(text)
10 scales = np.array([0.667, 1.0, noise_w], dtype=np.float32) # noise, length, noise_w
11 audio = sess.run(None, {
12 "input": np.array([ids], dtype=np.int64),
13 "input_lengths": np.array([len(ids)], dtype=np.int64),
14 "scales": scales,
15 "sid": np.array([sid], dtype=np.int64),
16 })[0].squeeze()
17 audio = (audio * (32767 / max(0.01, np.max(np.abs(audio))))).astype("<i2") # peak-normalize
18 with wave.open(path, "wb") as w:
19 w.setnchannels(1); w.setsampwidth(2); w.setframerate(22050); w.writeframes(audio.tobytes())
20
21synth("Bore da. Sut wyt ti'n teimlo heddiw?", sid=0) # Welsh
22synth("Good morning. How are you feeling today?", sid=1) # English
23synth("Nes i fwcio'r tickets ar-lein, so we're all set.", 2) # code-switchedcy_en_GB-bu_tts-bangor-medium.onnx (+ .onnx.json) — default model (CC-BY)cy_en_GB-bu_tts-bangor-cc0-medium.onnx (+ .onnx.json) — CC0 variantcy_en_GB-bu_tts-bangor-medium). The cy_en_GB-bu_tts-bangor-cc0-medium file is available under CC0-1.0 (public domain, no attribution).en_GB-vctk-medium voice, so it is a derivative work of:CSTR VCTK Corpus (v0.92). Yamagishi, Junichi; Veaux, Christophe; MacDonald, Kirsten (2019). The Centre for Speech Technology Research (CSTR), University of Edinburgh. https://doi.org/10.7488/ds/2645 — under the Open Data Commons Attribution License (ODC-By) v1.0 / CC BY 4.0. Piper voices © Michael Hansen (rhasspy), CC BY 4.0.
-cc0- variant was not warm-started from VCTK: it uses en_US-ljspeech-medium (public domain), so it carries no attribution requirement.