devendergarg14 commited on
Commit
84538bc
·
verified ·
1 Parent(s): 2f63795

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -10,13 +10,13 @@ CATEGORY_ITEMS = {
10
  "Skin": ["Left-arm", "Right-arm", "Left-leg", "Right-leg"]
11
  }
12
 
13
- def segment(img, selected_categories):
14
  # Get the items based on the selected categories
15
  selected_items = []
16
- for category in selected_categories:
17
  selected_items.extend(CATEGORY_ITEMS.get(category, []))
18
 
19
- return segment_clothing(img, selected_items)
20
 
21
  iface = gr.Interface(
22
  fn=segment,
 
10
  "Skin": ["Left-arm", "Right-arm", "Left-leg", "Right-leg"]
11
  }
12
 
13
+ def segment(image, categories_to_hide):
14
  # Get the items based on the selected categories
15
  selected_items = []
16
+ for category in categories_to_hide:
17
  selected_items.extend(CATEGORY_ITEMS.get(category, []))
18
 
19
+ return segment_clothing(image, selected_items)
20
 
21
  iface = gr.Interface(
22
  fn=segment,