Spaces:
Runtime error
Runtime error
suvrobaner
commited on
Commit
·
6ed0b16
1
Parent(s):
c454c4a
created app.py
Browse files
app.py
CHANGED
@@ -0,0 +1,15 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
pipe = pipeline(model = "suvrobaner/whisper-small-finetuned-hi-commonvoice")
|
2 |
+
|
3 |
+
def transcribe(audio):
|
4 |
+
text = pipe(audio)["text"]
|
5 |
+
return text
|
6 |
+
|
7 |
+
iface = gr.Interface(
|
8 |
+
fn=transcribe,
|
9 |
+
inputs=gr.Audio(source="microphone", type="filepath"),
|
10 |
+
outputs="text",
|
11 |
+
title="Whisper Small Hindi Transcribe",
|
12 |
+
description="Realtime demo for Hindi speech recognition using a fine-tuned Whisper small model on Common Voice dataset.",
|
13 |
+
)
|
14 |
+
|
15 |
+
iface.launch()
|