Spaces:
Runtime error
Runtime error
import gradio as gr | |
from pydub import AudioSegment | |
from ailib import whisper_transcribe | |
def transcribe(audiofile): | |
#audio = AudioSegment.from_file(audiofile) | |
#open(filename, 'wb').write(audio) | |
return whisper_transcribe(audiofile) | |
gr.Label("Demo CORFO") | |
demo = gr.Interface( | |
transcribe, | |
gr.Audio(sources=["microphone"], type="filepath"), | |
"text", | |
) | |
demo.launch() | |