Not sure if this actually changes anything but it can't hurt.

This commit is contained in:
comfyanonymous
2024-08-13 12:35:25 -04:00
parent 39fb74c5bd
commit 34608de2e9
3 changed files with 15 additions and 14 deletions

View File

@@ -106,9 +106,9 @@ class Flux(nn.Module):
if self.params.guidance_embed:
if guidance is None:
raise ValueError("Didn't get guidance strength for guidance distilled model.")
vec = vec + self.guidance_in(timestep_embedding(guidance, 256).to(img.dtype))
vec.add_(self.guidance_in(timestep_embedding(guidance, 256).to(img.dtype)))
vec = vec + self.vector_in(y)
vec.add_(self.vector_in(y))
txt = self.txt_in(txt)
ids = torch.cat((txt_ids, img_ids), dim=1)