harry0703 / MoneyPrinterTurbo

利用AI大模型,一键生成高清短视频 Generate short videos with one click using AI LLM.
MIT License
18.37k stars 2.83k forks source link

AttributeError: module 'PIL.Image' has no attribute 'ANTIALIAS' #482

Open Steve-Zhangjx opened 3 months ago

Steve-Zhangjx commented 3 months ago

combining video: 1 => .\storage\tasks\86e72002-2af2-4ab6-be30-468c3f827684\combined-1.mp4

2024-08-24 17:11:36 | INFO | "./app\services\video.py:42": combine_videos - max duration of audio: 49.25 seconds 2024-08-24 17:11:36 | INFO | "./app\services\video.py:46": combine_videos - each clip will be maximum 3 seconds long 2024-08-24 17:12:29.234 Uncaught app exception Traceback (most recent call last): File "C:\ProgramData\anaconda3\envs\MoneyPrinterTurbo\lib\site-packages\streamlit\runtime\scriptrunner\script_runner.py", line 542, in _run_script exec(code, module.dict) File "D:\MoneyPrinterTurbo\webui\Main.py", line 787, in result = tm.start(task_id=task_id, params=params) File "D:\MoneyPrinterTurbo\app\services\task.py", line 299, in start final_video_paths, combined_video_paths = generate_final_videos( File "D:\MoneyPrinterTurbo\app\services\task.py", line 176, in generate_final_videos video.combine_videos( File "D:\MoneyPrinterTurbo\app\services\video.py", line 93, in combine_videos clip = clip.resize((video_width, video_height)) File "C:\ProgramData\anaconda3\envs\MoneyPrinterTurbo\lib\site-packages\moviepy\video\fx\resize.py", line 165, in resize newclip = clip.fl_image(fl) File "C:\ProgramData\anaconda3\envs\MoneyPrinterTurbo\lib\site-packages\moviepy\video\VideoClip.py", line 576, in fl_image return self.fl(lambda gf, t: image_func(gf(t)), apply_to) File "C:\ProgramData\anaconda3\envs\MoneyPrinterTurbo\lib\site-packages\moviepy\Clip.py", line 141, in fl newclip = self.set_make_frame(lambda t: fun(self.get_frame, t)) File "", line 2, in set_make_frame File "C:\ProgramData\anaconda3\envs\MoneyPrinterTurbo\lib\site-packages\moviepy\decorators.py", line 15, in outplace e_frame self.size = self.get_frame(0).shape[:2][::-1] File "", line 2, in get_frame File "C:\ProgramData\anaconda3\envs\MoneyPrinterTurbo\lib\site-packages\moviepy\decorators.py", line 89, in wrapper return f(*new_a, **new_kw) File "C:\ProgramData\anaconda3\envs\MoneyPrinterTurbo\lib\site-packages\moviepy\Clip.py", line 98, in get_frame return self.make_frame(t) File "C:\ProgramData\anaconda3\envs\MoneyPrinterTurbo\lib\site-packages\moviepy\Clip.py", line 141, in newclip = self.set_make_frame(lambda t: fun(self.get_frame, t)) File "C:\ProgramData\anaconda3\envs\MoneyPrinterTurbo\lib\site-packages\moviepy\video\VideoClip.py", line 576, in return self.fl(lambda gf, t: image_func(gf(t)), apply_to) File "C:\ProgramData\anaconda3\envs\MoneyPrinterTurbo\lib\site-packages\moviepy\video\fx\resize.py", line 163, in fl return resizer(pic.astype("uint8"), newsize) File "C:\ProgramData\anaconda3\envs\MoneyPrinterTurbo\lib\site-packages\moviepy\video\fx\resize.py", line 37, in resizer resized_pil = pilim.resize(newsize[::-1], Image.ANTIALIAS) AttributeError: module 'PIL.Image' has no attribute 'ANTIALIAS'