'I'm using Gradio for making UI for my model

def detect(audio):
    chime_threshold = 0.5
    prediction = detect_triggerword(audio)
    chime_on_activate(your_filename, prediction, chime_threshold)
    return IPython.display.Audio("./chime_output.wav")

detect=gr.Interface(fn=detect, inputs='audio', outputs='audio')
detect.launch()

As you can see I'm able to add the audio file as input which is in WAV format but when I try to submit the file it shows me an error.

it is the error it shows



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source