FujiwaraChoki/MoneyPrinterV2

ValueError: max() arg is an empty sequence

ownerHZH opened this issue · 1 comments

generating video

2024-03-13 21:34:20 | INFO | "./app/services/video.py:148": generate_video - start, video size: 1080 x 1920
2024-03-13 21:34:20 | INFO | "./app/services/video.py:149": generate_video - ① video: ./storage/tasks/1575054b-fd75-48ee-a766-dcb6b28dc097/combined.mp4
2024-03-13 21:34:20 | INFO | "./app/services/video.py:150": generate_video - ② audio: ./storage/tasks/1575054b-fd75-48ee-a766-dcb6b28dc097/audio.mp3
2024-03-13 21:34:20 | INFO | "./app/services/video.py:151": generate_video - ③ subtitle: ./storage/tasks/1575054b-fd75-48ee-a766-dcb6b28dc097/subtitle.srt
2024-03-13 21:34:20 | INFO | "./app/services/video.py:152": generate_video - ④ output: ./storage/tasks/1575054b-fd75-48ee-a766-dcb6b28dc097/final.mp4
2024-03-13 21:34:20 | INFO | "./app/services/video.py:157": generate_video - using font: ./resource/fonts/STHeitiLight.ttc
2024-03-13 21:34:20.322 Uncaught app exception
Traceback (most recent call last):
File "/opt/miniconda3/envs/MoneyPrinterTurbo/lib/python3.10/site-packages/streamlit/runtime/scriptrunner/script_runner.py", line 542, in _run_script
exec(code, module.dict)
File "/Users/xxxx/MoneyPrinterTurbo/webui/Main.py", line 153, in
tm.start(task_id=task_id, params=cfg)
File "/Users/xxxx/MoneyPrinterTurbo/app/services/task.py", line 93, in start
video.generate_video(video_path=combined_video_path,
File "/Users/xxxx/MoneyPrinterTurbo/app/services/video.py", line 186, in generate_video
subtitles = SubtitlesClip(subtitle_path, generator)
File "/opt/miniconda3/envs/MoneyPrinterTurbo/lib/python3.10/site-packages/moviepy/video/tools/subtitles.py", line 55, in init
self.duration = max([tb for ((ta,tb), txt) in self.subtitles])
ValueError: max() arg is an empty sequence

Is there no Speech in your Video?
Have you changed anything in the code?