diff options
author | AUTOMATIC <16777216c@gmail.com> | 2022-09-22 09:11:48 +0000 |
---|---|---|
committer | AUTOMATIC <16777216c@gmail.com> | 2022-09-22 09:11:48 +0000 |
commit | 91bfc71261e160451e89f35a7c0eef66ff98877c (patch) | |
tree | 1d06de00a8c94527f572c801bbfa2eefb24fb58e /modules/processing.py | |
parent | e235d4e691e81cc3628da762b3f4ace936a44036 (diff) | |
download | stable-diffusion-webui-gfx803-91bfc71261e160451e89f35a7c0eef66ff98877c.tar.gz stable-diffusion-webui-gfx803-91bfc71261e160451e89f35a7c0eef66ff98877c.tar.bz2 stable-diffusion-webui-gfx803-91bfc71261e160451e89f35a7c0eef66ff98877c.zip |
A big rework, just what you were secretly hoping for!
SD upscale moved to scripts
Batch processing script removed
Batch processing added to main img2img and now works with scripts
img2img page UI reworked to use tabs
Diffstat (limited to 'modules/processing.py')
-rw-r--r-- | modules/processing.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/modules/processing.py b/modules/processing.py index e844b7e2..f44c3f26 100644 --- a/modules/processing.py +++ b/modules/processing.py @@ -491,7 +491,7 @@ class StableDiffusionProcessingTxt2Img(StableDiffusionProcessing): class StableDiffusionProcessingImg2Img(StableDiffusionProcessing):
sampler = None
- def __init__(self, init_images=None, resize_mode=0, denoising_strength=0.75, mask=None, mask_blur=4, inpainting_fill=0, inpaint_full_res=True, inpainting_mask_invert=0, **kwargs):
+ def __init__(self, init_images=None, resize_mode=0, denoising_strength=0.75, mask=None, mask_blur=4, inpainting_fill=0, inpaint_full_res=True, inpaint_full_res_padding=0, inpainting_mask_invert=0, **kwargs):
super().__init__(**kwargs)
self.init_images = init_images
@@ -505,6 +505,7 @@ class StableDiffusionProcessingImg2Img(StableDiffusionProcessing): self.mask_blur = mask_blur
self.inpainting_fill = inpainting_fill
self.inpaint_full_res = inpaint_full_res
+ self.inpaint_full_res_padding = inpaint_full_res_padding
self.inpainting_mask_invert = inpainting_mask_invert
self.mask = None
self.nmask = None
@@ -527,7 +528,7 @@ class StableDiffusionProcessingImg2Img(StableDiffusionProcessing): if self.inpaint_full_res:
self.mask_for_overlay = self.image_mask
mask = self.image_mask.convert('L')
- crop_region = masking.get_crop_region(np.array(mask), opts.upscale_at_full_resolution_padding)
+ crop_region = masking.get_crop_region(np.array(mask), self.inpaint_full_res_padding)
crop_region = masking.expand_crop_region(crop_region, self.width, self.height, mask.width, mask.height)
x1, y1, x2, y2 = crop_region
|