tarteel / app.py
elina12's picture
Update app.py
8706245
raw
history blame
No virus
368 Bytes
from transformers import pipeline
import gradio as gr
# Load the pipeline with the cache_dir parameter
pipe = pipeline(model="tarteel-ai/whisper-base-ar-quran")
def transcribe(audio):
text = pipe(audio)["text"]
return text
iface = gr.Interface(
fn=transcribe,
inputs=gr.Audio(source="upload", type="filepath"),
outputs="text",
)
iface.launch()