Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
|
@@ -36,10 +36,10 @@ def inpaintGen(
|
|
| 36 |
source_img = imgMask["background"]
|
| 37 |
mask_img = imgMask["layers"][0]
|
| 38 |
|
| 39 |
-
if not
|
| 40 |
raise gr.Error("Please upload an image.")
|
| 41 |
|
| 42 |
-
if not
|
| 43 |
raise gr.Error("Please draw a mask on the image.")
|
| 44 |
|
| 45 |
width, height = source_img.size
|
|
|
|
| 36 |
source_img = imgMask["background"]
|
| 37 |
mask_img = imgMask["layers"][0]
|
| 38 |
|
| 39 |
+
if not source_img:
|
| 40 |
raise gr.Error("Please upload an image.")
|
| 41 |
|
| 42 |
+
if not mask_img:
|
| 43 |
raise gr.Error("Please draw a mask on the image.")
|
| 44 |
|
| 45 |
width, height = source_img.size
|