Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -131,7 +131,7 @@ def rmGPT(caption, remove_class):
|
|
131 |
|
132 |
|
133 |
@spaces.GPU
|
134 |
-
def ChangeOBJ(
|
135 |
size = img1.size
|
136 |
image = sdxl(prompt=response, image=img1, mask_image=mask1,guidance_scale=7.0, num_inference_steps=20, strength=0.99).images[0]
|
137 |
return image.resize((size[0], size[1]))
|
@@ -147,7 +147,7 @@ def full_pipeline(image, target):
|
|
147 |
response = rmGPT(caption, tartget_to_remove)
|
148 |
mask1 = allMask[tartget_to_remove]
|
149 |
|
150 |
-
remimg = ChangeOBJ(
|
151 |
|
152 |
return remimg, caption, response
|
153 |
|
|
|
131 |
|
132 |
|
133 |
@spaces.GPU
|
134 |
+
def ChangeOBJ(img1, response, mask1):
|
135 |
size = img1.size
|
136 |
image = sdxl(prompt=response, image=img1, mask_image=mask1,guidance_scale=7.0, num_inference_steps=20, strength=0.99).images[0]
|
137 |
return image.resize((size[0], size[1]))
|
|
|
147 |
response = rmGPT(caption, tartget_to_remove)
|
148 |
mask1 = allMask[tartget_to_remove]
|
149 |
|
150 |
+
remimg = ChangeOBJ(img1, response, mask1)
|
151 |
|
152 |
return remimg, caption, response
|
153 |
|