Spaces:
Running
on
Zero
Running
on
Zero
fix bug
Browse files- app/src/brushedit_app.py +3 -1
app/src/brushedit_app.py
CHANGED
@@ -1428,8 +1428,10 @@ def init_img(base,
|
|
1428 |
masked_gallery[0] = masked_gallery[0].resize((width_new, height_new))
|
1429 |
result_gallery[0] = result_gallery[0].resize((width_new, height_new))
|
1430 |
original_mask = np.array(mask_gallery[0]).astype(np.uint8)[:,:,None] # h,w,1
|
1431 |
-
return base, original_image, original_mask, prompt, mask_gallery, masked_gallery, result_gallery, "", "", "
|
1432 |
else:
|
|
|
|
|
1433 |
return base, original_image, None, "", None, None, None, "", "", aspect_ratio, True, False, 0
|
1434 |
|
1435 |
|
|
|
1428 |
masked_gallery[0] = masked_gallery[0].resize((width_new, height_new))
|
1429 |
result_gallery[0] = result_gallery[0].resize((width_new, height_new))
|
1430 |
original_mask = np.array(mask_gallery[0]).astype(np.uint8)[:,:,None] # h,w,1
|
1431 |
+
return base, original_image, original_mask, prompt, mask_gallery, masked_gallery, result_gallery, "", "", "Custom resolution", False, False, example_change_times
|
1432 |
else:
|
1433 |
+
if aspect_ratio not in ASPECT_RATIO_LABELS:
|
1434 |
+
aspect_ratio = "Custom resolution"
|
1435 |
return base, original_image, None, "", None, None, None, "", "", aspect_ratio, True, False, 0
|
1436 |
|
1437 |
|