Spaces:
Runtime error
Runtime error
import gradio as gr | |
from transformers import pipeline | |
import numpy as np | |
from ailib import whisper_transcribe | |
def transcribe(audio): | |
filename = 'audio.wav' | |
open(filename, 'wb').write(audio) | |
return whisper_transcribe(filename) | |
gr.Label("Demo CORFO") | |
demo = gr.Interface( | |
transcribe, | |
gr.Audio(sources=["microphone"]), | |
"text", | |
) | |
demo.launch() | |