Spaces:
Sleeping
Sleeping
sotirios-slv
commited on
Commit
•
d6bc47b
1
Parent(s):
fe0ca9c
Added some styling and some other bits
Browse files
app.py
CHANGED
@@ -9,6 +9,12 @@ from transformers import (
|
|
9 |
pipeline,
|
10 |
)
|
11 |
|
|
|
|
|
|
|
|
|
|
|
|
|
12 |
|
13 |
device = "cpu"
|
14 |
# device = "cuda:0" if torch.cuda.is_available() else "cpu"
|
@@ -59,7 +65,14 @@ input_audio = gr.Audio(
|
|
59 |
show_controls=False,
|
60 |
),
|
61 |
)
|
62 |
-
demo = gr.Interface(
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
63 |
|
64 |
if __name__ == "__main__":
|
65 |
demo.launch()
|
|
|
9 |
pipeline,
|
10 |
)
|
11 |
|
12 |
+
description = """
|
13 |
+
<div>
|
14 |
+
<p>Roll up, roll up come test your diction against a 🤖</p>
|
15 |
+
</div>
|
16 |
+
"""
|
17 |
+
|
18 |
|
19 |
device = "cpu"
|
20 |
# device = "cuda:0" if torch.cuda.is_available() else "cpu"
|
|
|
65 |
show_controls=False,
|
66 |
),
|
67 |
)
|
68 |
+
demo = gr.Interface(
|
69 |
+
fn=transcribe_audio,
|
70 |
+
inputs=input_audio,
|
71 |
+
outputs="text",
|
72 |
+
title="Test your diction",
|
73 |
+
description=description,
|
74 |
+
theme="abidlabs/Lime",
|
75 |
+
)
|
76 |
|
77 |
if __name__ == "__main__":
|
78 |
demo.launch()
|