Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -7,7 +7,8 @@ def apply_circle_mask(image_path):
|
|
7 |
image.add(image.image(href=image_path, size=("100%", "100%")))
|
8 |
|
9 |
# Add circular mask
|
10 |
-
|
|
|
11 |
half_x, half_y = width/2, height/2
|
12 |
line_color = "white"
|
13 |
mask = image.defs.add(image.mask(id="bg_wrapper"))
|
|
|
7 |
image.add(image.image(href=image_path, size=("100%", "100%")))
|
8 |
|
9 |
# Add circular mask
|
10 |
+
viewbox = image.viewbox()
|
11 |
+
width, height = viewbox[2], viewbox[3]
|
12 |
half_x, half_y = width/2, height/2
|
13 |
line_color = "white"
|
14 |
mask = image.defs.add(image.mask(id="bg_wrapper"))
|