diff --git a/nodes.py b/nodes.py index 853b254..ac88912 100644 --- a/nodes.py +++ b/nodes.py @@ -361,7 +361,7 @@ class CogVideoImageEncodeFunInP: mask = torch.zeros_like(masked_image_latents[:, :, :1, :, :]) if end_image is not None: - mask[:, -1, :, :, :] = vae_scaling_factor + mask[:, -1, :, :, :] = 0 mask[:, 0, :, :, :] = vae_scaling_factor final_latents = masked_image_latents * vae_scaling_factor @@ -971,4 +971,4 @@ NODE_DISPLAY_NAME_MAPPINGS = { "CogVideoLatentPreview": "CogVideo LatentPreview", "CogVideoXTorchCompileSettings": "CogVideo TorchCompileSettings", "CogVideoImageEncodeFunInP": "CogVideo ImageEncode FunInP", - } \ No newline at end of file + }