-
🕒 生成时间:每张图大概 10–60 秒(取决于设备)
✅ 二、文生视频(Text-to-Video)
以下项目中,很多都基于 SD 模型扩展,但视频生成复杂度高,生成时间一般 超过 30 秒,也正好符合你要求。
1. ModelScope's text-to-video-synthesis
-
📦 地址:modelscope/modelscope
-
🔬 模型:text-to-video-synthesis
-
🎥 视频时长:2–4秒,支持中文 prompt
-
💻 本地部署建议:至少 8GB GPU
-
🛠️ 安装:
pip install modelscope
pip install "modelscope[multimodal]"
-
🧪 示例代码:
from modelscope.pipelines
import pipeline from modelscope.utils.constant
import Tasks
p = pipeline(Tasks.text_to_video_synthesis, model='damo/text-to-video-synthesis') video_path = p({'text': '一个骑自行车的少年在夕阳下'})['output_video']