Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -38,25 +38,14 @@ def transcribe_video(URL):
|
|
38 |
text = pipe(yt)["text"]
|
39 |
return text
|
40 |
|
41 |
-
|
42 |
-
fn
|
43 |
-
inputs = "text",
|
44 |
-
outputs = "text",
|
45 |
-
title = "Whisper Small Swedish",
|
46 |
-
description = "Realtime demo for Swedish speech recognition with translation using a fine-tuned Whisper small model",
|
47 |
-
)
|
48 |
-
|
49 |
-
transcribe_func = gr.Interface(
|
50 |
-
fn=transcribe_audio,
|
51 |
inputs=[
|
52 |
gr.Audio(source="microphone", type="filepath", label="Transcribe from Microphone"),
|
53 |
gr.Dropdown(["English","Spanish","Dutch","French","Italian"], value="English", label="Translate to ")
|
54 |
],
|
55 |
outputs="text",
|
56 |
title="Whisper Small Swedish",
|
57 |
-
description="Realtime demo for Swedish speech recognition with translation using a fine-tuned Whisper small model"
|
58 |
-
|
59 |
-
|
60 |
-
iface = gr.TabbedInterface([transcribe_func, youtube_func], ["Audio to Text","Video transciption"])
|
61 |
|
62 |
iface.launch()
|
|
|
38 |
text = pipe(yt)["text"]
|
39 |
return text
|
40 |
|
41 |
+
iface = gr.Interface(
|
42 |
+
fn=transcribe_audio,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
43 |
inputs=[
|
44 |
gr.Audio(source="microphone", type="filepath", label="Transcribe from Microphone"),
|
45 |
gr.Dropdown(["English","Spanish","Dutch","French","Italian"], value="English", label="Translate to ")
|
46 |
],
|
47 |
outputs="text",
|
48 |
title="Whisper Small Swedish",
|
49 |
+
description="Realtime demo for Swedish speech recognition with translation using a fine-tuned Whisper small model")
|
|
|
|
|
|
|
50 |
|
51 |
iface.launch()
|