🚀 PIKA_DISSOLVE 微调模型项目
本项目是基于 THUDM/CogVideoX - 5b 模型,在 modal - labs/dissolve 数据集上进行微调的成果。它能够根据文本描述生成特定的视频效果,例如物体溶解的动态视频。
🚀 快速开始
代码仓库
项目代码可在 此处 获取。
推理代码示例
以下是使用微调模型进行推理的代码示例:
from diffusers import CogVideoXTransformer3DModel, DiffusionPipeline
from diffusers.utils import export_to_video
import torch
transformer = CogVideoXTransformer3DModel.from_pretrained(
"sayakpaul/pika-dissolve-v0", torch_dtype=torch.bfloat16
)
pipeline = DiffusionPipeline.from_pretrained(
"THUDM/CogVideoX-5b", transformer=transformer, torch_dtype=torch.bfloat16
).to("cuda")
prompt = """
PIKA_DISSOLVE A slender glass vase, brimming with tiny white pebbles, stands centered on a polished ebony dais. Without warning, the glass begins to dissolve from the edges inward. Wisps of translucent dust swirl upward in an elegant spiral, illuminating each pebble as they drop onto the dais. The gently drifting dust eventually settles, leaving only the scattered stones and faint traces of shimmering powder on the stage.
"""
negative_prompt = "inconsistent motion, blurry motion, worse quality, degenerate outputs, deformed outputs"
video = pipeline(
prompt=prompt,
negative_prompt=negative_prompt,
num_frames=81,
height=512,
width=768,
num_inference_steps=50
).frames[0]
export_to_video(video, "output_vase.mp4", fps=25)
📦 模型与数据信息
属性 |
详情 |
基础模型 |
THUDM/CogVideoX - 5b |
训练数据集 |
modal - labs/dissolve |
依赖库 |
diffusers |
📄 许可证
本项目使用的许可证为 other。
💻 使用示例
基础用法
上述推理代码即为基础的使用示例,通过定义输入的文本描述 prompt
和负面提示 negative_prompt
,可以生成相应的视频。
示例输出展示
以下是一些不同文本描述对应的视频输出示例:
- 文本描述:PIKA_DISSOLVE A meticulously detailed, tea cup, sits centrally on a dark brown circular pedestal. The cup, seemingly made of clay, begins to dissolve from the bottom up. The disintegration process is rapid but not explosive, with a cloud of fine, light tan dust forming and rising in a swirling, almost ethereal column that expands outwards before slowly descending. The dust particles are individually visible as they float, and the overall effect is one of delicate disintegration rather than shattering. Finally, only the empty pedestal and the intricately patterned marble floor remain.
输出视频:点击查看
- 文本描述:PIKA_DISSOLVE Resting quietly atop an ancient stone altar, a delicately carved wooden mask starts to crumble from its outer edges. The intricate patterns crack and give way, releasing a fine, smoke - like plume of mahogany - hued particles that dance upwards, then disperse gradually into the hushed atmosphere. As the dust descends, the once captivating mask is reduced to an outline on the weathered altar.
输出视频:点击查看
- 文本描述:PIKA_DISSOLVE A slender glass vase, brimming with tiny white pebbles, stands centered on a polished ebony dais. Without warning, the glass begins to dissolve from the edges inward. Wisps of translucent dust swirl upward in an elegant spiral, illuminating each pebble as they drop onto the dais. The gently drifting dust eventually settles, leaving only the scattered stones and faint traces of shimmering powder on the stage.
输出视频:点击查看
- 文本描述:PIKA_DISSOLVE On a narrow marble ledge, a gracefully folded paper crane rests, its surface marked by delicate ink lines. It starts to fragment from the tail feathers outward, releasing a cloud of feather - light pulp fibers. Suspended for a moment in a magical swirl, the fibers drift back down, cloaking the ledge in a near - transparent veil of white. Then the ledge stands empty, the crane’s faint silhouette lingering in memory.
输出视频:点击查看
🏷️ 标签
本项目相关的标签有:text - to - video、diffusers - training、diffusers、cogvideox、cogvideox - diffusers、template:sd - lora。