ljspeech-jets-onnx
[imdanboy/jets](https://huggingface.co/imdanboy/ljspeech_tts_train_jets_raw_phn_tacotron_g2p_en_no_space_train.total_count.ave) exported to ONNX. This model is an ONNX export using the [espnet_onnx](https://github.com/espnet/espnet_onnx) library. [txtai](https://github.com/neuml/txtai) has a built in Text to Speech (TTS) pipeline that makes using this model easy. import soundfile as sf from txtai.pipeline import TextToSpeech tts = TextToSpeech("NeuML/ljspeech-jets-onnx") speech, rate = tts("Say something here") sf.write("out.wav", speech, rate) This model can also be run directly with ONNX provided the input text is tokenized. Tokenization can be done with [ttstokenizer](https://github.com/neuml/ttstokenizer). Note that the txtai pipeline has additional functionality such as batching large inputs together that would need to be duplicated with this method. import onnxruntime import soundfile as sf import yaml from ttstokenizer import TTSTokenizer with open("ljspeech-jets-onnx/config.yaml", "r", encoding="utf-8") as f: config = yaml.safe_load(f) model = onnxruntime.InferenceSession( "ljspeech-jets-onnx/model.onnx", providers=["CPUExecutionProvider"] ) tokenizer = TTSTokenizer(config["token"]["list"]) inputs = tokenizer("Say something here") outputs = model.run(None, {"text": inputs}) sf.write("out.wav", outputs[0], 22050) More information on how to export ESPnet models to ONNX can be [found here](https://github.com/espnet/espnet_onnx#text2speech-inference).
Open ljspeech-jets-onnx in AIniverse
Compare versions, read real ratings, save to your stack.
Open in App