diff --git a/runner/app/pipelines/text_to_video.py b/runner/app/pipelines/text_to_video.py index dba2d25..609075b 100644 --- a/runner/app/pipelines/text_to_video.py +++ b/runner/app/pipelines/text_to_video.py @@ -67,7 +67,8 @@ def __init__(self, model_id: str): repo = "ByteDance/AnimateDiff-Lightning" self.motion_loaded = "" # Load base - self.ldm = AnimateDiffPipeline.from_pretrained(bases[base_loaded]).to("cuda") + adapter = MotionAdapter.from_pretrained("guoyww/animatediff-motion-adapter-v1-5-2", torch_dtype=torch.float16) + self.ldm = AnimateDiffPipeline.from_pretrained(bases[base_loaded], motion_adapter=adapter, torch_dtype=torch.float16).to("cuda") # Load noise scheduler self.ldm.scheduler = EulerDiscreteScheduler.from_config(self.ldm.scheduler.config, timestep_spacing="trailing", beta_schedule="linear") # Load model params