from voicefixer import VoiceFixer import gradio as gr voicefixer = VoiceFixer() def inference(audio): voicefixer.restore(input=audio.name, # input wav file path output="output.wav", # output wav file path cuda=False, # whether to use gpu acceleration mode = 1) # You can try out mode 0, 1 to find out the best result return 'output.wav' inputs = gr.inputs.Audio(type="file", label="Input Audio") outputs = gr.outputs.Audio(type="file",label="Output Audio") title = "VITS" description = "demo for VITS: Conditional Variational Autoencoder with Adversarial Learning for End-to-End Text-to-Speech. To use it, simply add your text, or click one of the examples to load them. Read more at the links below." article = "

Conditional Variational Autoencoder with Adversarial Learning for End-to-End Text-to-Speech | Github Repo

" gr.Interface(inference, inputs, outputs, title=title, description=description, article=article).launch()