kanyekuthi commited on
Commit
8cc6bda
·
1 Parent(s): d197959

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -20
app.py CHANGED
@@ -1,22 +1,3 @@
1
- # import gradio as gr
2
-
3
- # gr.load("models/kanyekuthi/dsn_afrispeech").launch()
4
-
5
- from transformers import pipeline
6
  import gradio as gr
7
 
8
- pipe = pipeline(model="kanyekuthi/dsn_afrispeech")
9
-
10
- def transcribe(audio):
11
- text = pipe(audio)["text"]
12
- return text
13
-
14
- iface = gr.Interface(
15
- fn=transcribe,
16
- inputs=gr.Audio(source="microphone", type="filepath"),
17
- outputs="text",
18
- title="Whisper Small English",
19
- description="Realtime demo for African-accented English speech recognition using a fine-tuned Whisper small model.",
20
- )
21
-
22
- iface.launch()
 
 
 
 
 
 
1
  import gradio as gr
2
 
3
+ gr.load("models/kanyekuthi/dsn_afrispeech").launch()