Video from text: HunyuanVideo 1.5
Lesson "video-hunyuan", in the group Video of the lesson list. Steps: 14.
What you will be able to do
You build the HunyuanVideo 1.5 graph with a custom sampler and get a five-second 720p clip.
What you need
- It goes on from Video on a modest graphics card: Wan 2.2 5B. The card says so; it is a hint, not a lock.
- Model files the lesson checks:
- for
unet_nameof Load Diffusion Model: a file whose name hashunyuanvideo1.5andt2v; - for
clip_name1of DualCLIPLoader: a file whose name hasqwen_2.5_vl; - for
clip_name2of DualCLIPLoader: a file whose name hasbyt5; - for
vae_nameof Load VAE: a file whose name hashunyuanvideo15_vae.
- for
- Nodes: Load Diffusion Model, DualCLIPLoader, Load VAE, CLIP Text Encode (Prompt), ModelSamplingSD3, Empty Hunyuan Video 1.5 Latent, RandomNoise, KSamplerSelect, BasicScheduler, CFG Guider, SamplerCustomAdvanced, VAE Decode / VAE Decode (Tiled), Create Video, Save Video.
- The app downloads and installs nothing. The step texts below say which files and folders, and which ComfyUI template names them.
The steps
The words of each step, as the lesson shows them. Node names are in bold.
What it costs, first (reading)
HunyuanVideo 1.5 by Tencent is an 8B video model, between the small and the large Wan in size. Its graph uses the custom sampler: noise, a guider, a sampler and a list of steps as separate nodes.
What you need: the
720p_t2vmodel, about 17 GB infp16, inmodels/diffusion_models; two text encoders (qwen_2.5_vl_7binfp8and the smallbyt5for lettering) inmodels/text_encoders;hunyuanvideo15_vaeinmodels/vae. A card with 16 GB or more is comfortable; 121 frames at 1280 × 720 take a long time, a smaller size much less.If the canvas already holds another graph, start from an empty one: "File ▸ New project".
Load the model
Add a Load Diffusion Model node and choose the
hunyuanvideo1.5_720p_t2vfile inunet_name.If the file you need is not in the list, your ComfyUI does not have it. The app downloads nothing. The easiest way is to open, in ComfyUI itself, the "Hunyuan Video 1.5 Text to Video" template: it shows which files are missing and where to put them. Then choose "Sync ▸ Sync now" in this app's menu, and the files appear in the lists.
Load the two text encoders
Add a DualCLIPLoader node. In
clip_name1chooseqwen_2.5_vl_7b, inclip_name2choosebyt5_small_glyphxl, and settypetohunyuan_video_15.The first reads the prompt, the second helps with text written in the picture.
Load the VAE
Add a Load VAE node and choose
hunyuanvideo15_vaeinvae_name. The VAE of HunyuanVideo 1.0 does not fit version 1.5.Write the prompt
Add two CLIP Text Encode (Prompt) nodes and connect the
CLIPoutput of DualCLIPLoader to theclipinput of each. In thetextfield of one, describe the clip: who or what is in the frame, what happens, how the camera moves. The other is the negative prompt: what must not be there.For video the action matters most. "A cat jumps onto a windowsill, the camera follows" works better than "a cat on a windowsill".
Set the shift
Add a ModelSamplingSD3 node and connect the
MODELoutput of the loader to itsmodelinput. Setshiftto 7.Size and length
Add a Empty Hunyuan Video 1.5 Latent node. Set
widthto 1280,heightto 720 andlengthto 121.121 frames at 24 fps make five seconds; the number of frames is of the form 4n + 1. For a lighter run take the 480p model and 848 × 480.
Noise, sampler and steps
Add RandomNoise, KSamplerSelect and BasicScheduler.
- In
sampler_nameof KSamplerSelect chooseeuler. - Connect the model to the
modelinput of BasicScheduler, setschedulertosimpleandstepsto 20.
The scheduler works out the list of noise levels for the twenty steps; the noise node holds the seed.
- In
The guider
Add a CFG Guider node. Its
modelinput takes the output of ModelSamplingSD3; itspositiveandnegativeinputs take the two prompts. Setcfgto 6.The sampler
Add a SamplerCustomAdvanced node and connect to it: noise from RandomNoise, guider from CFG Guider, sampler from KSamplerSelect, sigmas from BasicScheduler, latent_image from Empty Hunyuan Video 1.5 Latent.
- Turn the result into frames
Add a VAE Decode node. Connect the output of SamplerCustomAdvanced to its samples input and the VAE to its vae input. With little memory take VAE Decode (Tiled) instead.
- Make the clip and save it
Add Create Video and Save Video. The frames from VAE Decode go into the images input of Create Video, and its output into the video input of Save Video. Set fps to 24.
HunyuanVideo 1.5 draws 24 fps. With another number the clip runs faster or slower than it was meant to.
- What else the template does (reading)
The official template adds two things on top of this graph:
- EasyCache between the loader and the shift: it skips work on steps that change little, faster with a small loss of detail;
- a second stage that enlarges the clip to 1080p with its own model and latent upscaler.
Both can be added later; the app accepts EasyCache on the way of the model.
- The graph is ready (reading)
Save the graph with "File ▸ Save workflow for ComfyUI…", open the file in ComfyUI and run it there. This app runs nothing in ComfyUI itself.
What the lesson checks
A reading step is done when you press Got it, next. A doing step ticks itself off when the canvas holds:
- Step 2, Load the model:
- a Load Diffusion Model node.
unet_nameof Load Diffusion Model holds a file whose name hashunyuanvideo1.5andt2v(capitals, dots and dashes do not matter).
- Step 3, Load the two text encoders:
- a DualCLIPLoader node.
clip_name1of DualCLIPLoader holds a file whose name hasqwen_2.5_vl(capitals, dots and dashes do not matter).clip_name2of DualCLIPLoader is not the same file asclip_name1of DualCLIPLoader.typeof DualCLIPLoader ishunyuan_video_15.clip_name2of DualCLIPLoader holds a file whose name hasbyt5(capitals, dots and dashes do not matter).
- Step 4, Load the VAE:
- a Load VAE node.
vae_nameof Load VAE holds a file whose name hashunyuanvideo15_vae(capitals, dots and dashes do not matter).
- Step 5, Write the prompt:
- a CLIP Text Encode (Prompt) node.
- a CLIP Text Encode (Prompt) node.
CLIPof DualCLIPLoader intoclipof CLIP Text Encode (Prompt) (prompt).CLIPof DualCLIPLoader intoclipof CLIP Text Encode (Prompt) (negative prompt).textof CLIP Text Encode (Prompt) (prompt) holds at least 3 characters.
- Step 6, Set the shift:
- a ModelSamplingSD3 node.
MODELof Load Diffusion Model intomodelof ModelSamplingSD3 (a LoraLoaderModelOnly or EasyCache in between is accepted).shiftof ModelSamplingSD3 is from 5 to 9; Do this for me sets 7.
- Step 7, Size and length:
- a Empty Hunyuan Video 1.5 Latent node.
widthof Empty Hunyuan Video 1.5 Latent is from 640 to 1280; Do this for me sets 1280.heightof Empty Hunyuan Video 1.5 Latent is from 368 to 720; Do this for me sets 720.lengthof Empty Hunyuan Video 1.5 Latent is from 33 to 121; Do this for me sets 121.
- Step 8, Noise, sampler and steps:
- a RandomNoise node.
- a KSamplerSelect node.
- a BasicScheduler node.
MODELof Load Diffusion Model intomodelof BasicScheduler (a LoraLoaderModelOnly or EasyCache in between is accepted).sampler_nameof KSamplerSelect iseuler.schedulerof BasicScheduler issimple.stepsof BasicScheduler is from 8 to 50; Do this for me sets 20.
- Step 9, The guider:
- a CFG Guider node.
MODELof ModelSamplingSD3 intomodelof CFG Guider (a LoraLoaderModelOnly or EasyCache in between is accepted).CONDITIONINGof CLIP Text Encode (Prompt) (prompt) intopositiveof CFG Guider.CONDITIONINGof CLIP Text Encode (Prompt) (negative prompt) intonegativeof CFG Guider.cfgof CFG Guider is from 1 to 8; Do this for me sets 6.
- Step 10, The sampler:
- a SamplerCustomAdvanced node.
NOISEof RandomNoise intonoiseof SamplerCustomAdvanced.GUIDERof CFG Guider intoguiderof SamplerCustomAdvanced.SAMPLERof KSamplerSelect intosamplerof SamplerCustomAdvanced.SIGMASof BasicScheduler intosigmasof SamplerCustomAdvanced.LATENTof Empty Hunyuan Video 1.5 Latent intolatent_imageof SamplerCustomAdvanced.
- Step 11, Turn the result into frames:
- a VAE Decode or VAE Decode (Tiled) node.
outputof SamplerCustomAdvanced intosamplesof VAE Decode or VAE Decode (Tiled).VAEof Load VAE intovaeof VAE Decode or VAE Decode (Tiled).
- Step 12, Make the clip and save it:
- a Create Video node.
- a Save Video node.
IMAGEof VAE Decode or VAE Decode (Tiled) intoimagesof Create Video.VIDEOof Create Video intovideoof Save Video.fpsof Create Video is24.