Method for exproting speecht5_tts to ONNX

#1
by JackismyShephard - opened

How did you export speecht5_tts to ONNX? I see that the huggingface API itself has no ONNX classes specifically for TTS (https://huggingface.co/docs/optimum/v1.16.2/onnxruntime/package_reference/modeling_ort).

Using optimum unstable it is possible. However the '--monolith' flag, does not seems to have an effect. https://huggingface.co/docs/optimum/installation

Hi, I recognise you did this a while ago but I have been unable to find the correct optimum class for text-to-speech onnx exporting. I checked the main branch of optimum and couldn't find anything there.

Would you mind sharing specifically what process / classes you used to do this?

Owner

Hi there! See here for information about how the model was exported.

Amazing, thank you.

One final question. How did you then do the int8 quantization? I noticed it isn't a dtype available in the optimum-cli export command.

@JamesXanda You need to use the optimum-cli onnxruntime quantize command. More information here: https://huggingface.co/docs/optimum/onnxruntime/usage_guides/quantization#quantizing-a-model-to-be-used-with-optimums-cli

Thanks, this worked great.

Sign up or log in to comment