Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -190,7 +190,7 @@ def start_tryon(dict,garm_img,garment_des,cloth_type,is_checked,is_checked_crop,
|
|
190 |
human_img_orig.paste(out_img, (int(left), int(top)))
|
191 |
return human_img_orig, mask_gray
|
192 |
else:
|
193 |
-
return images[0], mask_gray
|
194 |
# return images[0], mask_gray
|
195 |
|
196 |
|
@@ -259,6 +259,7 @@ with image_blocks as demo:
|
|
259 |
# image_out = gr.Image(label="Output", elem_id="output-img", height=400)
|
260 |
image_out = gr.Image(label="Output", elem_id="output-img",show_share_button=False)
|
261 |
with gr.Accordion("Debug Info", open=False):
|
|
|
262 |
masked_img = gr.Image(label="Masked image output", elem_id="masked-img",show_share_button=False)
|
263 |
|
264 |
|
@@ -273,7 +274,7 @@ with image_blocks as demo:
|
|
273 |
|
274 |
|
275 |
try_button.click(fn=main_, inputs=[imgs,topwear_image,topwear_desc,bottomwear_image,bottomwear_desc,dress_image,dress_desc,is_checked,is_checked_crop,denoise_steps,seed],
|
276 |
-
outputs=[image_out, masked_img], api_name='tryon')
|
277 |
|
278 |
|
279 |
|
|
|
190 |
human_img_orig.paste(out_img, (int(left), int(top)))
|
191 |
return human_img_orig, mask_gray
|
192 |
else:
|
193 |
+
return garm_img, images[0], mask_gray
|
194 |
# return images[0], mask_gray
|
195 |
|
196 |
|
|
|
259 |
# image_out = gr.Image(label="Output", elem_id="output-img", height=400)
|
260 |
image_out = gr.Image(label="Output", elem_id="output-img",show_share_button=False)
|
261 |
with gr.Accordion("Debug Info", open=False):
|
262 |
+
image_in = gr.Image(label="Midway Image", elem_id="midway-img",show_share_button=False)
|
263 |
masked_img = gr.Image(label="Masked image output", elem_id="masked-img",show_share_button=False)
|
264 |
|
265 |
|
|
|
274 |
|
275 |
|
276 |
try_button.click(fn=main_, inputs=[imgs,topwear_image,topwear_desc,bottomwear_image,bottomwear_desc,dress_image,dress_desc,is_checked,is_checked_crop,denoise_steps,seed],
|
277 |
+
outputs=[image_in, image_out, masked_img], api_name='tryon')
|
278 |
|
279 |
|
280 |
|