freealise commited on
Commit
9575445
·
verified ·
1 Parent(s): bab488d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -195,7 +195,7 @@ def remove_bg(fl, count, mh, ms, md, lm):
195
  m = cv2.inRange(fr, np.array([0,0,0]), np.array([15,15,15]))
196
  fr[m>0] = (16,16,16)
197
  fr[fr_shadow>0] = (fr[fr_shadow>0] / 17).astype(np.uint8)
198
- fr[fr_fg==0] = (255,255,255)
199
 
200
  fr_fg[fr_fg>0] = 3 #probable fg
201
  mask, bgdModel, fgdModel = cv2.grabCut(fr, fr_fg, None,None,None,15, cv2.GC_INIT_WITH_MASK)
 
195
  m = cv2.inRange(fr, np.array([0,0,0]), np.array([15,15,15]))
196
  fr[m>0] = (16,16,16)
197
  fr[fr_shadow>0] = (fr[fr_shadow>0] / 17).astype(np.uint8)
198
+ #fr[fr_fg==0] = (255,255,255)
199
 
200
  fr_fg[fr_fg>0] = 3 #probable fg
201
  mask, bgdModel, fgdModel = cv2.grabCut(fr, fr_fg, None,None,None,15, cv2.GC_INIT_WITH_MASK)