mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2025-04-20 03:13:30 +00:00
Not needed anymore because sampling works with any latent size.
This commit is contained in:
parent
d43e45ce62
commit
314e526c5c
@ -362,19 +362,8 @@ def resolve_cond_masks(conditions, h, w, device):
|
|||||||
else:
|
else:
|
||||||
box = boxes[0]
|
box = boxes[0]
|
||||||
H, W, Y, X = (box[3] - box[1] + 1, box[2] - box[0] + 1, box[1], box[0])
|
H, W, Y, X = (box[3] - box[1] + 1, box[2] - box[0] + 1, box[1], box[0])
|
||||||
# Make sure the height and width are divisible by 8
|
H = max(8, H)
|
||||||
if X % 8 != 0:
|
W = max(8, W)
|
||||||
newx = X // 8 * 8
|
|
||||||
W = W + (X - newx)
|
|
||||||
X = newx
|
|
||||||
if Y % 8 != 0:
|
|
||||||
newy = Y // 8 * 8
|
|
||||||
H = H + (Y - newy)
|
|
||||||
Y = newy
|
|
||||||
if H % 8 != 0:
|
|
||||||
H = H + (8 - (H % 8))
|
|
||||||
if W % 8 != 0:
|
|
||||||
W = W + (8 - (W % 8))
|
|
||||||
area = (int(H), int(W), int(Y), int(X))
|
area = (int(H), int(W), int(Y), int(X))
|
||||||
modified['area'] = area
|
modified['area'] = area
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user