Animate Diff High Res Loops
upload one image to get a seamless loop animation
Download WorkflowTry in Cloud API documentation
About
upload one image to get a seamless loop animation
What you provide
- Reading the workflow
Runs in ComfyUI. This workflow can only run on your own ComfyUI. Download it and drop the file onto the canvas.
Download WorkflowNo sample outputs for this workflow yet.
Inside the workflow
A read-only preview of the node graph. Open it in Comfy Cloud or download it to edit the nodes.
Loading the graph
Open full-size workflow previewFiles in this workflow
- Comfy Cloud
- No
- Author
- Author unavailable
Requires custom nodes
- Reading the workflow
Use this workflow from code
Generated from the workflow graph and inputs when possible; stored examples are shown otherwise. Review credentials and endpoints before running code, which may incur charges.
1 Get API key โ
What you need
- Runs on
- Comfy Cloud
- Key
- COMFY_API_KEY
Needs a paid Cloud plan and credits.
Download API JSONAPI documentation โ
# Python 3.10+: pip install comfy-sdk==0.4.0
import os
from comfy_sdk import Comfy
api_key = os.environ.get("COMFY_API_KEY", "").strip()
if not api_key: raise RuntimeError("Set COMFY_API_KEY")
os.environ.setdefault("COMFY_BASE_URL", "https://cloud.comfy.org")
client = Comfy(api_key=api_key)
workflow = client.workflows.from_json({
"9": {
"class_type": "VHS_VideoCombine",
"inputs": {
"crf": 19,
"filename_prefix": "t2vAD/t2vAD",
"format": "video/h264-mp4",
"frame_rate": 15,
"images": [
"354:4",
0
],
"loop_count": 0,
"pingpong": False,
"pix_fmt": "yuv420p",
"save_metadata": True,
"save_output": False,
"trim_to_audio": False
},
"_meta": {
"title": "Video Combine ๐ฅ๐
ฅ๐
๐
ข"
}
},
"145": {
"class_type": "LoadImage",
"inputs": {
"image": "path_of_the_cube.png"
},
"_meta": {
"title": "Load Image"
}
},
"349": {
"class_type": "VHS_VideoCombine",
"inputs": {
"crf": 19,
"filename_prefix": "t2vAD/t2vAD",
"format": "video/h264-mp4",
"frame_rate": 15,
"images": [
"355:139",
0
],
"loop_count": 0,
"pingpong": False,
"pix_fmt": "yuv420p",
"save_metadata": True,
"save_output": False,
"trim_to_audio": False
},
"_meta": {
"title": "Video Combine ๐ฅ๐
ฅ๐
๐
ข"
}
},
"350": {
"class_type": "VHS_VideoCombine",
"inputs": {
"crf": 19,
"filename_prefix": "t2vAD/t2vAD",
"format": "video/h264-mp4",
"frame_rate": 15,
"images": [
"356:351",
0
],
"loop_count": 4,
"pingpong": False,
"pix_fmt": "yuv420p",
"save_metadata": True,
"save_output": False,
"trim_to_audio": False
},
"_meta": {
"title": "Video Combine ๐ฅ๐
ฅ๐
๐
ข"
}
},
"353:14": {
"class_type": "ADE_LoadAnimateDiffModel",
"inputs": {
"model_name": "AnimateLCM_sd15_t2v.ckpt"
},
"_meta": {
"title": "Load AnimateDiff Model ๐ญ๐
๐
โก"
}
},
"353:18": {
"class_type": "ADE_MultivalDynamic",
"inputs": {
"float_val": 1.3
},
"_meta": {
"title": "Multival ๐ญ๐
๐
"
}
},
"353:239": {
"class_type": "IPAdapterModelLoader",
"inputs": {
"ipadapter_file": "ip-adapter_sd15.safetensors"
},
"_meta": {
"title": "IPAdapter Model Loader"
}
},
"353:240": {
"class_type": "CLIPVisionLoader",
"inputs": {
"clip_name": "CLIP-ViT-H-14-laion2B-s32B-b79K.safetensors"
},
"_meta": {
"title": "Load CLIP Vision"
}
},
"353:241": {
"class_type": "IPAdapterMS",
"inputs": {
"clip_vision": [
"353:240",
0
],
"combine_embeds": "concat",
"embeds_scaling": "V only",
"end_at": 1,
"image": [
"353:338",
0
],
"ipadapter": [
"353:239",
0
],
"layer_weights": "",
"start_at": 0,
"weight": 1,
"weight_faceidv2": 1,
"weight_type": "linear"
},
"_meta": {
"title": "IPAdapter Mad Scientist"
}
},
"353:3": {
"class_type": "CheckpointLoaderSimple",
"inputs": {
"ckpt_name": "realismByStableYogi_v4LCM.safetensors"
},
"_meta": {
"title": "Load Checkpoint"
}
},
"353:338": {
"class_type": "PrepImageForClipVision",
"inputs": {
"crop_position": "pad",
"image": [
"145",
0
],
"interpolation": "LANCZOS",
"sharpening": 0
},
"_meta": {
"title": "Prep Image For ClipVision"
}
},
"353:46": {
"class_type": "ADE_AnimateDiffLoRALoader",
"inputs": {
"name": "v2_lora_ZoomIn.ckpt",
"strength": 0.3
},
"_meta": {
"title": "Load AnimateDiff LoRA ๐ญ๐
๐
"
}
},
"353:6": {
"class_type": "CLIPTextEncode",
"inputs": {
"clip": [
"353:3",
1
],
"text": "bad quality, bad picture, flashing, nsfw"
},
"_meta": {
"title": "CLIP Text Encode (Prompt)"
}
},
"353:7": {
"class_type": "EmptyLatentImage",
"inputs": {
"batch_size": 64,
"height": 1024,
"width": 512
},
"_meta": {
"title": "Empty Latent Image"
}
},
"354:12": {
"class_type": "ADE_UseEvolvedSampling",
"inputs": {
"beta_schedule": "lcm avg(sqrt_linear,linear)",
"context_options": [
"354:165",
0
],
"m_models": [
"354:13",
0
],
"model": [
"353:241",
0
],
"sample_settings": [
"354:15",
0
]
},
"_meta": {
"title": "Use Evolved Sampling ๐ญ๐
๐
โก"
}
},
"354:124": {
"class_type": "CLIPTextEncode",
"inputs": {
"clip": [
"353:3",
1
],
"text": "abstract vintage collage tunnel"
},
"_meta": {
"title": "CLIP Text Encode (Prompt)"
}
},
"354:13": {
"class_type": "ADE_ApplyAnimateDiffModel",
"inputs": {
"end_percent": 1,
"motion_lora": [
"353:46",
0
],
"motion_model": [
"353:14",
0
],
"scale_multival": [
"353:18",
0
],
"start_percent": 0
},
"_meta": {
"title": "Apply AnimateDiff Model (Adv.) ๐ญ๐
๐
โก"
}
},
"354:15": {
"class_type": "ADE_AnimateDiffSamplingSettings",
"inputs": {
"adapt_denoise_steps": False,
"batch_offset": 0,
"noise_type": "FreeNoise",
"seed_gen": "comfy",
"seed_offset": 0,
"seed_override": 0
},
"_meta": {
"title": "Sample Settings ๐ญ๐
๐
"
}
},
"354:165": {
"class_type": "ADE_AnimateDiffUniformContextOptions",
"inputs": {
"closed_loop": True,
"context_length": 16,
"context_overlap": 4,
"context_schedule": "uniform",
"context_stride": 1,
"fuse_method": "flat",
"guarantee_steps": 1,
"start_percent": 0,
"use_on_equal_length": False
},
"_meta": {
"title": "Context OptionsโLooped Uniform ๐ญ๐
๐
"
}
},
"354:2": {
"class_type": "KSampler",
"inputs": {
"cfg": 1.5,
"denoise": 1,
"latent_image": [
"353:7",
0
],
"model": [
"354:20",
0
],
"negative": [
"353:6",
0
],
"positive": [
"354:124",
0
],
"sampler_name": "lcm",
"scheduler": "ddim_uniform",
"seed": 290197241327858,
"steps": 10
},
"_meta": {
"title": "KSampler"
}
},
"354:20": {
"class_type": "FreeU_V2",
"inputs": {
"b1": 1.3,
"b2": 1.4,
"model": [
"354:12",
0
],
"s1": 0.9,
"s2": 0.2
},
"_meta": {
"title": "FreeU_V2"
}
},
"354:4": {
"class_type": "VAEDecode",
"inputs": {
"samples": [
"354:2",
0
],
"vae": [
"353:3",
2
]
},
"_meta": {
"title": "VAE Decode"
}
},
"355:128": {
"class_type": "KSampler",
"inputs": {
"cfg": 1.5,
"denoise": 0.6,
"latent_image": [
"355:171",
0
],
"model": [
"355:138",
0
],
"negative": [
"353:6",
0
],
"positive": [
"354:124",
0
],
"sampler_name": "lcm",
"scheduler": "sgm_uniform",
"seed": 525952149199031,
"steps": 11
},
"_meta": {
"title": "KSampler"
}
},
"355:132": {
"class_type": "ADE_UseEvolvedSampling",
"inputs": {
"beta_schedule": "lcm avg(sqrt_linear,linear)",
"context_options": [
"355:166",
0
],
"m_models": [
"355:133",
0
],
"model": [
"353:241",
0
],
"sample_settings": [
"355:135",
0
]
},
"_meta": {
"title": "Use Evolved Sampling ๐ญ๐
๐
โก"
}
},
"355:133": {
"class_type": "ADE_ApplyAnimateDiffModel",
"inputs": {
"end_percent": 1,
"motion_lora": [
"353:46",
0
],
"motion_model": [
"353:14",
0
],
"scale_multival": [
"353:18",
0
],
"start_percent": 0
},
"_meta": {
"title": "Apply AnimateDiff Model (Adv.) ๐ญ๐
๐
โก"
}
},
"355:135": {
"class_type": "ADE_AnimateDiffSamplingSettings",
"inputs": {
"adapt_denoise_steps": False,
"batch_offset": 0,
"noise_type": "FreeNoise",
"seed_gen": "comfy",
"seed_offset": 0,
"seed_override": 0
},
"_meta": {
"title": "Sample Settings ๐ญ๐
๐
"
}
},
"355:138": {
"class_type": "FreeU_V2",
"inputs": {
"b1": 1.3,
"b2": 1.4,
"model": [
"355:132",
0
],
"s1": 0.9,
"s2": 0.2
},
"_meta": {
"title": "FreeU_V2"
}
},
"355:139": {
"class_type": "VAEDecode",
"inputs": {
"samples": [
"355:128",
0
],
"vae": [
"353:3",
2
]
},
"_meta": {
"title": "VAE Decode"
}
},
"355:166": {
"class_type": "ADE_AnimateDiffUniformContextOptions",
"inputs": {
"closed_loop": True,
"context_length": 16,
"context_overlap": 4,
"context_schedule": "uniform",
"context_stride": 1,
"fuse_method": "flat",
"guarantee_steps": 1,
"start_percent": 0,
"use_on_equal_length": False
},
"_meta": {
"title": "Context OptionsโLooped Uniform ๐ญ๐
๐
"
}
},
"355:171": {
"class_type": "LatentUpscaleBy",
"inputs": {
"samples": [
"354:2",
0
],
"scale_by": 1.5,
"upscale_method": "nearest-exact"
},
"_meta": {
"title": "Upscale Latent By"
}
},
"356:344": {
"class_type": "Upscale Model Loader",
"inputs": {},
"_meta": {
"title": "Upscale Model Loader"
}
},
"356:345": {
"class_type": "FL_UpscaleModel",
"inputs": {
"batch_size": 50,
"downscale_by": 0.48253676470588236,
"image": [
"355:139",
0
],
"precision": "16",
"rescale_method": "bicubic",
"upscale_model": [
"356:344",
0
]
},
"_meta": {
"title": "FL Upscale Model"
}
},
"356:346": {
"class_type": "FL_KsamplerPlus",
"inputs": {
"batch_size": 1,
"cfg": 1,
"denoise": 0.2,
"image": [
"356:345",
0
],
"input_type": "image",
"model": [
"355:138",
0
],
"negative": [
"353:6",
0
],
"overlap": 0.05,
"positive": [
"356:347",
0
],
"sampler_name": "lcm",
"scheduler": "sgm_uniform",
"seed": 859386427828680,
"steps": 4,
"use_sliced_conditioning": True,
"vae": [
"353:3",
2
],
"x_slices": 2,
"y_slices": 2
},
"_meta": {
"title": "FL KSampler Plus"
}
},
"356:347": {
"class_type": "CLIPTextEncode",
"inputs": {
"clip": [
"353:3",
1
],
"text": [
"356:352",
0
]
},
"_meta": {
"title": "CLIP Text Encode (Prompt)"
}
},
"356:351": {
"class_type": "VAEDecode",
"inputs": {
"samples": [
"356:346",
3
],
"vae": [
"353:3",
2
]
},
"_meta": {
"title": "VAE Decode"
}
},
"356:352": {
"class_type": "AILab_QwenVL",
"inputs": {
"attention_mode": "auto",
"custom_prompt": "describe the video cinematically from an artistic perspective",
"keep_model_loaded": True,
"max_tokens": 512,
"model_name": "Qwen3-VL-2B-Instruct",
"preset_prompt": "๐ผ๏ธ Detailed Description",
"quantization": "None (FP16)",
"seed": 1261856073,
"video": [
"355:139",
0
]
},
"_meta": {
"title": "QwenVL"
}
}
})
# run() also passes api_key to the partner nodes in this workflow.
job = client.run(workflow, api_key=api_key)