Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -59,7 +59,7 @@ def transcribe(audio, state={"text": "", "temp_text": "", "audio": ""}):
|
|
59 |
state={"text": "", "temp_text": "", "audio": ""}
|
60 |
with open(audio, "rb") as f:
|
61 |
payload = f.read()
|
62 |
-
|
63 |
_sr = 16000
|
64 |
|
65 |
speech = is_speech(wav_data, _sr)
|
|
|
59 |
state={"text": "", "temp_text": "", "audio": ""}
|
60 |
with open(audio, "rb") as f:
|
61 |
payload = f.read()
|
62 |
+
wav_data = ffmpeg_read(payload, sampling_rate=16000)
|
63 |
_sr = 16000
|
64 |
|
65 |
speech = is_speech(wav_data, _sr)
|