The most powerful and modular diffusion model GUI, api and backend with a graph/nodes interface. The fastest local inference engine in the world.
Small fix: skip unnecessary work. (#16540)
comfyanonymous88ab4a065664
diff --git a/comfy/ldm/lumina/model.py b/comfy/ldm/lumina/model.pyindex 46ce86f5f..df1744284 100644--- a/comfy/ldm/lumina/model.py+++ b/comfy/ldm/lumina/model.py@@ -173,7 +173,7 @@ class JointAttention(nn.Module):xq, xk = apply_rope(xq, xk, freqs_cis)n_rep = self.n_local_heads // self.n_local_kv_heads- if n_rep >= 1:+ if n_rep > 1:xk = xk.unsqueeze(3).repeat(1, 1, 1, n_rep, 1).flatten(2, 3)xv = xv.unsqueeze(3).repeat(1, 1, 1, n_rep, 1).flatten(2, 3)xq = AttentionTensorContainer(xq.movedim(1, 2))