mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
fix --hires to support inpainting model
This commit is contained in:
parent
387f796ebe
commit
05b8de5300
@ -25,16 +25,15 @@ class Txt2Img2Img(Generator):
|
|||||||
kwargs are 'width' and 'height'
|
kwargs are 'width' and 'height'
|
||||||
"""
|
"""
|
||||||
uc, c, extra_conditioning_info = conditioning
|
uc, c, extra_conditioning_info = conditioning
|
||||||
|
|
||||||
@torch.no_grad()
|
|
||||||
def make_image(x_T):
|
|
||||||
|
|
||||||
scale_dim = min(width, height)
|
scale_dim = min(width, height)
|
||||||
scale = 512 / scale_dim
|
scale = 512 / scale_dim
|
||||||
|
|
||||||
init_width = math.ceil(scale * width / 64) * 64
|
init_width = math.ceil(scale * width / 64) * 64
|
||||||
init_height = math.ceil(scale * height / 64) * 64
|
init_height = math.ceil(scale * height / 64) * 64
|
||||||
|
|
||||||
|
@torch.no_grad()
|
||||||
|
def make_image(x_T):
|
||||||
|
|
||||||
shape = [
|
shape = [
|
||||||
self.latent_channels,
|
self.latent_channels,
|
||||||
init_height // self.downsampling_factor,
|
init_height // self.downsampling_factor,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user