"git@developer.sourcefind.cn:chenpangpang/ComfyUI.git" did not exist on "f1a01c2c7e2678f34c72212d2a8640237f31fa43"
Commit b1a16d45 authored by comfyanonymous's avatar comfyanonymous
Browse files

Fix stable cascade img2img not working with all resolutions.

parent cacb022c
...@@ -74,7 +74,7 @@ class StableCascade_StageC_VAEEncode: ...@@ -74,7 +74,7 @@ class StableCascade_StageC_VAEEncode:
s = comfy.utils.common_upscale(image.movedim(-1,1), out_width, out_height, "bicubic", "center").movedim(1,-1) s = comfy.utils.common_upscale(image.movedim(-1,1), out_width, out_height, "bicubic", "center").movedim(1,-1)
c_latent = vae.encode(s[:,:,:,:3]) c_latent = vae.encode(s[:,:,:,:3])
b_latent = torch.zeros([c_latent.shape[0], 4, height // 4, width // 4]) b_latent = torch.zeros([c_latent.shape[0], 4, (height // 8) * 2, (width // 8) * 2])
return ({ return ({
"samples": c_latent, "samples": c_latent,
}, { }, {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment