on-vits2-multi-tts-v1 / convert.py
rippertnt's picture
Upload 18 files
abbd3ba verified
raw
history blame
391 Bytes
import onnx
#from onnxconverter_common import float16
from onnxruntime.transformers.float16 import convert_float_to_float16
langs = ['ar','cn','de','en','fa','fr','id','ja','km','ko','mn','pt','ru','th','tr','vi']
for lang in langs:
print(lang)
model = onnx.load(f"{lang}_base.onnx")
model_fp16 = convert_float_to_float16(model)
onnx.save(model_fp16, f"{lang}_base_f16.onnx")