diff --git a/docs/source/en/api/pipelines/kandinsky5_video.md b/docs/source/en/api/pipelines/kandinsky5_video.md index 46876051778f..395863ca99eb 100644 --- a/docs/source/en/api/pipelines/kandinsky5_video.md +++ b/docs/source/en/api/pipelines/kandinsky5_video.md @@ -64,10 +64,10 @@ from diffusers.utils import export_to_video model_id = "kandinskylab/Kandinsky-5.0-T2V-Pro-sft-5s-Diffusers" pipe = Kandinsky5T2VPipeline.from_pretrained(model_id, dtype=torch.bfloat16) -pipe = pipe.to("cuda") # or "mps", "xpu", "cpu" -pipeline.transformer.set_attention_backend("flex") # <--- Set attention backend to Flex -pipeline.enable_model_cpu_offload() # <--- Enable cpu offloading for single GPU inference -pipeline.transformer.compile(mode="max-autotune-no-cudagraphs", dynamic=True) # <--- Compile with max-autotune-no-cudagraphs +pipe = pipe.to("cuda") +pipe.transformer.set_attention_backend("flex") # <--- Set attention bakend to Flex +pipe.enable_model_cpu_offload() # <--- Enable cpu offloading for single GPU inference +pipe.transformer.compile(mode="max-autotune-no-cudagraphs", dynamic=True) # <--- Compile with max-autotune-no-cudagraphs # Generate video prompt = "A cat and a dog baking a cake together in a kitchen."