Spaces:
Runtime error
Runtime error
Commit
·
b3fa900
1
Parent(s):
1a7c1dd
Update app.py
Browse files
app.py
CHANGED
@@ -1,4 +1,5 @@
|
|
1 |
#Importing all the necessary packages
|
|
|
2 |
import torch, librosa, torchaudio
|
3 |
from transformers import Wav2Vec2ForCTC, Wav2Vec2Processor
|
4 |
from pyctcdecode import build_ctcdecoder
|
@@ -33,7 +34,7 @@ processor = Wav2Vec2Processor.from_pretrained(model_name)
|
|
33 |
s2t = Speech2Text()
|
34 |
|
35 |
|
36 |
-
|
37 |
gr.Interface(s2t,
|
38 |
inputs = gr.inputs.Audio(source="microphone", type="filepath", optional=True, label="Record Your Beautiful Persian Voice"),
|
39 |
outputs = gr.outputs.Textbox(label="Output Text"),
|
|
|
1 |
#Importing all the necessary packages
|
2 |
+
import gradio as gr
|
3 |
import torch, librosa, torchaudio
|
4 |
from transformers import Wav2Vec2ForCTC, Wav2Vec2Processor
|
5 |
from pyctcdecode import build_ctcdecoder
|
|
|
34 |
s2t = Speech2Text()
|
35 |
|
36 |
|
37 |
+
# themes="default", "huggingface", "seafoam", "grass", "peach"
|
38 |
gr.Interface(s2t,
|
39 |
inputs = gr.inputs.Audio(source="microphone", type="filepath", optional=True, label="Record Your Beautiful Persian Voice"),
|
40 |
outputs = gr.outputs.Textbox(label="Output Text"),
|