Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -29,6 +29,12 @@ def summarize_and_speech(pdf_file):
|
|
29 |
tts_output = synthesiser(summary)
|
30 |
audio_data = tts_output[0]["audio"]
|
31 |
|
|
|
|
|
|
|
|
|
|
|
|
|
32 |
return summary, audio_data
|
33 |
|
34 |
iface = gr.Interface(
|
|
|
29 |
tts_output = synthesiser(summary)
|
30 |
audio_data = tts_output[0]["audio"]
|
31 |
|
32 |
+
if "audio" in tts_output[0]:
|
33 |
+
audio_data = tts_output[0]["audio"]
|
34 |
+
else:
|
35 |
+
print("Audio data is not available")
|
36 |
+
|
37 |
+
|
38 |
return summary, audio_data
|
39 |
|
40 |
iface = gr.Interface(
|