Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

生成过程中发生错误: 关键帧提取失败: Command #81

Open
mrsun123 opened this issue Dec 23, 2024 · 2 comments
Open

生成过程中发生错误: 关键帧提取失败: Command #81

mrsun123 opened this issue Dec 23, 2024 · 2 comments

Comments

@mrsun123
Copy link

image

生成过程中发生错误: 关键帧提取失败: Command '['ffmpeg', '-i', 'D:\sun\NarratoAI_v0.3.9_cpu\NarratoAI\resource\videos\jinsihou.mp4', '-vf', 'scale=320:-1', '-y', 'D:\sun\NarratoAI_v0.3.9_cpu\NarratoAI\storage\temp\keyframes\70066f05980766a0c56b273ada6765a9\temp\compressed\jinsihou_compressed.mp4']' returned non-zero exit status 3752568763.

@yangshare
Copy link

image

@yangshare
Copy link

image

问题出在视频宽度不是2的倍数(181x320),这导致 libx264 编码器无法处理。此外,还有一些与编码器打开和帧处理相关的错误。
解决方法

调整视频宽度为2的倍数:

使用 ffmpeg 的 scale 滤镜时,确保输出宽度是2的倍数。你可以通过设置宽度为偶数来解决这个问题。例如,将宽度调整为180或182。

修改命令中的 scale 参数:

将 scale=-1:320 修改为 scale=180:320 或 scale=182:320,以确保宽度是偶数。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants