King / models /animatdiff.py
Trkaga's picture
Create models/animatdiff.py
6d382ac verified
raw
history blame contribute delete
196 Bytes
from diffusers import AnimateDiffPipeline
pipe = AnimateDiffPipeline.from_pretrained("animatediff")
def generate_frames(prompt):
result = pipe(prompt, num_frames=16)
return result.frames