Spaces:
Configuration error
Configuration error
Update ip_adapter_inpainting.py
Browse files- ip_adapter_inpainting.py +2 -2
ip_adapter_inpainting.py
CHANGED
@@ -16,8 +16,8 @@ ip_model = MODEL("inpaint")
|
|
16 |
|
17 |
|
18 |
def generate(img_openpose_gen: Image, img_human: Image, img_clothes: Image, segment_id: int):
|
19 |
-
cropped_clothes = get_cropped(img_openpose_gen, segment_id, False, False).resize(
|
20 |
-
cropped_body = get_cropped(img_human, segment_id, True, False).resize(
|
21 |
|
22 |
composite = Image.alpha_composite(cropped_body.convert('RGBA'),
|
23 |
cropped_clothes.convert('RGBA')
|
|
|
16 |
|
17 |
|
18 |
def generate(img_openpose_gen: Image, img_human: Image, img_clothes: Image, segment_id: int):
|
19 |
+
cropped_clothes = get_cropped(img_openpose_gen, segment_id, False, False).resize(img_openpose_gen.size)
|
20 |
+
cropped_body = get_cropped(img_human, segment_id, True, False).resize(img_openpose_gen.size)
|
21 |
|
22 |
composite = Image.alpha_composite(cropped_body.convert('RGBA'),
|
23 |
cropped_clothes.convert('RGBA')
|