Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -80,8 +80,7 @@ def detect_and_segment_persons(image, clothes):
|
|
80 |
pil_img = Image.fromarray(person_img[:, :, ::-1]) # BGR -> RGB
|
81 |
|
82 |
# Segment clothing for the detected person
|
83 |
-
|
84 |
-
segmented_result = segment_clothing(img_rm_background, clothes)
|
85 |
|
86 |
# Combine the segmented images for all persons
|
87 |
all_segmented_images.extend(segmented_result)
|
|
|
80 |
pil_img = Image.fromarray(person_img[:, :, ::-1]) # BGR -> RGB
|
81 |
|
82 |
# Segment clothing for the detected person
|
83 |
+
segmented_result = segment_clothing(pil_img, clothes)
|
|
|
84 |
|
85 |
# Combine the segmented images for all persons
|
86 |
all_segmented_images.extend(segmented_result)
|