Skip to content
Help ComfyUI Wiki remove ads Become a Patron
Nodes ManualLatentvideoEmpty Hunyuan Latent Video Node Tutorial

Empty Hunyuan Latent Video

Empty Hunyuan Latent Video

Empty Hunyuan Latent Video Node Overview

The EmptyHunyuanLatentVideo node is similar to the EmptyLatent Image node. You can think of it as providing a blank canvas for video generation, where the width, height and length define the canvas properties, and batch size determines how many canvases to create. This node creates fresh empty canvases ready for subsequent video generation tasks.

Class Information

  • Class Name: EmptyHunyuanLatentVideo
  • Category: latent/video
  • Output Node: True

Empty Hunyuan Latent Video Input Types

ParameterComfy TypeDescription
widthINTVideo width, default 848, minimum 16, maximum nodes.MAX_RESOLUTION, step size 16.
heightINTVideo height, default 480, minimum 16, maximum nodes.MAX_RESOLUTION, step size 16.
lengthINTVideo length, default 25, minimum 1, maximum nodes.MAX_RESOLUTION, step size 4.
batch_sizeINTBatch size, default 1, minimum 1, maximum 4096.

Empty Hunyuan Latent Video Output Types

ParameterComfy TypeDescription
samplesLATENTGenerated latent video samples containing zero tensors, ready for processing and generation tasks.

Empty Hunyuan Latent Video Workflow Example

Tencent Hunyuan Video Model Workflow

Here are some relevant resources curated by ComfyUI Wiki:

Empty Hunyuan Latent Video Node Source Code

  • ComfyUI Version: v0.3.10
  • 2025-01-07
class EmptyHunyuanLatentVideo:
    @classmethod
    def INPUT_TYPES(s):
        return {"required": { "width": ("INT", {"default": 848, "min": 16, "max": nodes.MAX_RESOLUTION, "step": 16}),
                              "height": ("INT", {"default": 480, "min": 16, "max": nodes.MAX_RESOLUTION, "step": 16}),
                              "length": ("INT", {"default": 25, "min": 1, "max": nodes.MAX_RESOLUTION, "step": 4}),
                              "batch_size": ("INT", {"default": 1, "min": 1, "max": 4096})}}
    RETURN_TYPES = ("LATENT",)
    FUNCTION = "generate"
 
    CATEGORY = "latent/video"
 
    def generate(self, width, height, length, batch_size=1):
        latent = torch.zeros([batch_size, 16, ((length - 1) // 4) + 1, height // 8, width // 8], device=comfy.model_management.intermediate_device())
        return ({"samples":latent}, )