Spaces:
Runtime error
Runtime error
Change requirements
Browse files
app.py
CHANGED
|
@@ -91,7 +91,7 @@ speech2text = Speech2Text.from_pretrained(
|
|
| 91 |
def inference(wav,lang):
|
| 92 |
with torch.no_grad():
|
| 93 |
if lang == "english":
|
| 94 |
-
speech, rate = soundfile.read(
|
| 95 |
nbests = speech2text(speech)
|
| 96 |
text, *_ = nbests[0]
|
| 97 |
# if lang == "chinese":
|
|
|
|
| 91 |
def inference(wav,lang):
|
| 92 |
with torch.no_grad():
|
| 93 |
if lang == "english":
|
| 94 |
+
speech, rate = soundfile.read(wav.name)
|
| 95 |
nbests = speech2text(speech)
|
| 96 |
text, *_ = nbests[0]
|
| 97 |
# if lang == "chinese":
|