mirror of
https://github.com/lllyasviel/Fooocus.git
synced 2026-08-16 13:13:16 +02:00
+1
-1
@@ -191,7 +191,7 @@ def encode_vae_inpaint(vae, pixels, mask):
|
||||
|
||||
latent_mask = mask[:, None, :, :]
|
||||
latent_mask = torch.nn.functional.interpolate(latent_mask, size=(H * 8, W * 8), mode="bilinear").round()
|
||||
latent_mask = torch.nn.functional.max_pool2d(latent_mask, (8, 8)).round()
|
||||
latent_mask = torch.nn.functional.max_pool2d(latent_mask, (8, 8)).round().to(latent)
|
||||
|
||||
return latent, latent_mask
|
||||
|
||||
|
||||
Reference in New Issue
Block a user