Skip to content

Commit

Permalink
Fix bug with cosxl edit model.
Browse files Browse the repository at this point in the history
  • Loading branch information
comfyanonymous committed Jun 10, 2024
1 parent 8c4a9be commit a82fae2
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion comfy/conds.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,12 @@ def concat(self, others):

class CONDNoiseShape(CONDRegular):
def process_cond(self, batch_size, device, area, **kwargs):
data = self.cond[:,:,area[2]:area[0] + area[2],area[3]:area[1] + area[3]]
data = self.cond
if area is not None:
dims = len(area) // 2
for i in range(dims):
data = data.narrow(i + 2, area[i + dims], area[i])

return self._copy_with(comfy.utils.repeat_to_batch_size(data, batch_size).to(device))


Expand Down

0 comments on commit a82fae2

Please sign in to comment.