diff options
author | AUTOMATIC1111 <16777216c@gmail.com> | 2023-05-14 11:46:27 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-14 11:46:27 +0300 |
commit | 80adb6979d46bbb832254004cac4f4f9bec9efb3 (patch) | |
tree | e206ee60f9be21e9e20d483213b7d0a610d2bdbd /scripts/outpainting_mk_2.py | |
parent | 1dcd6723242c3d691610f9ed937951baea49c2d1 (diff) | |
parent | 3ddc76342298ad0b2d14cb571ceb48c0b0c4176d (diff) |
Merge branch 'dev' into find_vae
Diffstat (limited to 'scripts/outpainting_mk_2.py')
-rw-r--r-- | scripts/outpainting_mk_2.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/scripts/outpainting_mk_2.py b/scripts/outpainting_mk_2.py index 670bb8ac..665dbe89 100644 --- a/scripts/outpainting_mk_2.py +++ b/scripts/outpainting_mk_2.py @@ -7,9 +7,9 @@ import modules.scripts as scripts import gradio as gr
from PIL import Image, ImageDraw
-from modules import images, processing, devices
+from modules import images
from modules.processing import Processed, process_images
-from modules.shared import opts, cmd_opts, state
+from modules.shared import opts, state
# this function is taken from https://github.com/parlance-zz/g-diffuser-bot
@@ -72,7 +72,7 @@ def get_matched_noise(_np_src_image, np_mask_rgb, noise_q=1, color_variation=0.0 height = _np_src_image.shape[1]
num_channels = _np_src_image.shape[2]
- np_src_image = _np_src_image[:] * (1. - np_mask_rgb)
+ _np_src_image[:] * (1. - np_mask_rgb)
np_mask_grey = (np.sum(np_mask_rgb, axis=2) / 3.)
img_mask = np_mask_grey > 1e-6
ref_mask = np_mask_grey < 1e-3
|