Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -36,9 +36,9 @@ def transcribe(state, audio):
|
|
36 |
audio = audio.astype(np.float32)
|
37 |
audio /= np.max(np.abs(audio))
|
38 |
|
39 |
-
|
40 |
-
|
41 |
-
state = audio
|
42 |
|
43 |
audio_data = process_audio_file(audio, sr)
|
44 |
|
@@ -57,8 +57,8 @@ def transcribe(state, audio):
|
|
57 |
|
58 |
transcriptions = transcriptions[0]
|
59 |
|
60 |
-
|
61 |
-
return state,
|
62 |
|
63 |
|
64 |
iface = gr.Interface(
|
|
|
36 |
audio = audio.astype(np.float32)
|
37 |
audio /= np.max(np.abs(audio))
|
38 |
|
39 |
+
if state is None:
|
40 |
+
state = ""
|
41 |
+
# state = audio
|
42 |
|
43 |
audio_data = process_audio_file(audio, sr)
|
44 |
|
|
|
57 |
|
58 |
transcriptions = transcriptions[0]
|
59 |
|
60 |
+
state = state + transcriptions + " "
|
61 |
+
return state, state
|
62 |
|
63 |
|
64 |
iface = gr.Interface(
|