mqye commited on
Commit
c9f0ed7
·
1 Parent(s): d6859f4

Deploy MODUS 3-tab any-to-any demo (ZeroGPU)

Browse files
app.py CHANGED
@@ -127,7 +127,8 @@ def _space_example_images():
127
  if not os.path.isdir(_EX_DIR):
128
  return []
129
  return [os.path.join(_EX_DIR, f) for f in sorted(os.listdir(_EX_DIR))
130
- if f.lower().endswith((".jpg", ".jpeg", ".png", ".webp"))]
 
131
  demo_modus._example_images = _space_example_images
132
  print(f"[app] {len(_space_example_images())} example images from {_EX_DIR}", flush=True)
133
 
 
127
  if not os.path.isdir(_EX_DIR):
128
  return []
129
  return [os.path.join(_EX_DIR, f) for f in sorted(os.listdir(_EX_DIR))
130
+ if f.lower().endswith((".jpg", ".jpeg", ".png", ".webp"))
131
+ and "_seg." not in f.lower()] # exclude precomputed seg previews
132
  demo_modus._example_images = _space_example_images
133
  print(f"[app] {len(_space_example_images())} example images from {_EX_DIR}", flush=True)
134
 
test_images/01_mall_seg.jpg ADDED
test_images/02_red_barn_seg.jpg ADDED
test_images/03_kremlin_clock_seg.jpg ADDED
test_images/04_dragon_boat_seg.jpg ADDED
test_images/05_red_carpet_seg.jpg ADDED
test_images/06_train_seg.jpg ADDED
test_images/07_city_bus_seg.jpg ADDED
test_images/08_food_market_seg.jpg ADDED
test_images/09_waterfall_seg.jpg ADDED
test_images/10_village_car_seg.jpg ADDED