From 63fafaef451f03cb88b1ec5399a78385b5e3ca21 Mon Sep 17 00:00:00 2001 From: comfyanonymous Date: Fri, 30 Aug 2024 04:58:41 -0400 Subject: [PATCH] Fix potential issue with hydit controlnets. --- comfy/ldm/hydit/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/comfy/ldm/hydit/models.py b/comfy/ldm/hydit/models.py index f3afaad3..44e806cb 100644 --- a/comfy/ldm/hydit/models.py +++ b/comfy/ldm/hydit/models.py @@ -372,7 +372,7 @@ class HunYuanDiT(nn.Module): for layer, block in enumerate(self.blocks): if layer > self.depth // 2: if controls is not None: - skip = skips.pop() + controls.pop() + skip = skips.pop() + controls.pop().to(dtype=x.dtype) else: skip = skips.pop() x = block(x, c, text_states, freqs_cis_img, skip) # (N, L, D)