Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
@@ -56,7 +56,7 @@ def segment_image(model, input_tensor):
|
|
56 |
return mask
|
57 |
|
58 |
# Step 7: Refine Mask and Extract Object
|
59 |
-
def apply_mask(image, mask, threshold=0.
|
60 |
# Threshold the mask
|
61 |
mask = (mask > threshold).astype(np.uint8)
|
62 |
|
|
|
56 |
return mask
|
57 |
|
58 |
# Step 7: Refine Mask and Extract Object
|
59 |
+
def apply_mask(image, mask, threshold=0.75):
|
60 |
# Threshold the mask
|
61 |
mask = (mask > threshold).astype(np.uint8)
|
62 |
|