freealise commited on
Commit
481e705
·
verified ·
1 Parent(s): 40b8a8b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -564,9 +564,9 @@ def draw_mask(l, t, th, v, d, evt: gr.EventData):
564
  pts = pts.reshape((-1,1,2))
565
 
566
  if len(edge) == 0 or params["fnum"] != frame_selected or params["l"] != l:
 
 
567
  if len(edge) > 0:
568
- clrs = cv2.cvtColor(cv2.imread(frames[frame_selected]).astype(np.uint8), cv2.COLOR_BGR2HSV)
569
- clrs = cb2.medianBlur(clrs, th)
570
  d["background"] = cv2.imread(depths[frame_selected]).astype(np.uint8)
571
 
572
  if d["background"].shape[0] == 2048: #height
 
564
  pts = pts.reshape((-1,1,2))
565
 
566
  if len(edge) == 0 or params["fnum"] != frame_selected or params["l"] != l:
567
+ clrs = cv2.cvtColor(cv2.imread(frames[frame_selected]).astype(np.uint8), cv2.COLOR_BGR2HSV)
568
+ clrs = cv2.medianBlur(clrs, th)
569
  if len(edge) > 0:
 
 
570
  d["background"] = cv2.imread(depths[frame_selected]).astype(np.uint8)
571
 
572
  if d["background"].shape[0] == 2048: #height