Update app.py
Browse files
app.py
CHANGED
|
@@ -549,10 +549,10 @@ def generate_video():
|
|
| 549 |
lines=best[0]
|
| 550 |
lang=best[1]
|
| 551 |
length, audio_path = audio_func(0, lines, lang)
|
| 552 |
-
if not
|
| 553 |
print("Failed to generate audio.")
|
| 554 |
|
| 555 |
-
scale=length/
|
| 556 |
|
| 557 |
# Now proceed with video generation using 'data'
|
| 558 |
print(json.dumps(data, indent=2)) # For debugging
|
|
|
|
| 549 |
lines=best[0]
|
| 550 |
lang=best[1]
|
| 551 |
length, audio_path = audio_func(0, lines, lang)
|
| 552 |
+
if not length or not audio_path:
|
| 553 |
print("Failed to generate audio.")
|
| 554 |
|
| 555 |
+
scale=length/total
|
| 556 |
|
| 557 |
# Now proceed with video generation using 'data'
|
| 558 |
print(json.dumps(data, indent=2)) # For debugging
|