Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -34,7 +34,7 @@ vae = AutoencoderKL.from_pretrained(
|
|
34 |
).to("cuda")
|
35 |
|
36 |
pipe = StableDiffusionXLFillPipeline.from_pretrained(
|
37 |
-
"
|
38 |
torch_dtype=torch.float16,
|
39 |
vae=vae,
|
40 |
controlnet=model,
|
@@ -88,8 +88,8 @@ def prepare_image_and_mask(image, width, height, overlap_percentage, resize_opti
|
|
88 |
source = source.resize((new_width, new_height), Image.LANCZOS)
|
89 |
|
90 |
# Calculate the overlap in pixels based on the percentage
|
91 |
-
overlap_x = int(new_width * (overlap_percentage /
|
92 |
-
overlap_y = int(new_height * (overlap_percentage /
|
93 |
|
94 |
# Ensure minimum overlap of 1 pixel
|
95 |
overlap_x = max(overlap_x, 1)
|
|
|
34 |
).to("cuda")
|
35 |
|
36 |
pipe = StableDiffusionXLFillPipeline.from_pretrained(
|
37 |
+
"Wombat1212/John6666mklan-aio-nsfw-aio-nextgen-xlv2-sdxl",
|
38 |
torch_dtype=torch.float16,
|
39 |
vae=vae,
|
40 |
controlnet=model,
|
|
|
88 |
source = source.resize((new_width, new_height), Image.LANCZOS)
|
89 |
|
90 |
# Calculate the overlap in pixels based on the percentage
|
91 |
+
overlap_x = int(new_width * (overlap_percentage / 200))
|
92 |
+
overlap_y = int(new_height * (overlap_percentage / 200))
|
93 |
|
94 |
# Ensure minimum overlap of 1 pixel
|
95 |
overlap_x = max(overlap_x, 1)
|