freealise commited on
Commit
f6f96ca
1 Parent(s): 5f30d89

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -427,7 +427,7 @@ def draw_mask(l, c, k, v, d, evt: gr.EventData):
427
 
428
  _, bg, mask = cv2.floodFill(bg, None, (x, y), 1, 0, 0 #, (
429
  #4 | cv2.FLOODFILL_FIXED_RANGE | cv2.FLOODFILL_MASK_ONLY | 255 << 8)
430
- )[1] # 255 << 8 tells to fill with the value 255)
431
  grad_x = cv2.convertScaleAbs(cv2.Sobel(mask, ddepth, 1, 0, ksize=3, scale=scale, delta=delta, borderType=cv2.BORDER_DEFAULT))
432
  grad_y = cv2.convertScaleAbs(cv2.Sobel(mask, ddepth, 0, 1, ksize=3, scale=scale, delta=delta, borderType=cv2.BORDER_DEFAULT))
433
 
 
427
 
428
  _, bg, mask = cv2.floodFill(bg, None, (x, y), 1, 0, 0 #, (
429
  #4 | cv2.FLOODFILL_FIXED_RANGE | cv2.FLOODFILL_MASK_ONLY | 255 << 8)
430
+ ) # 255 << 8 tells to fill with the value 255)
431
  grad_x = cv2.convertScaleAbs(cv2.Sobel(mask, ddepth, 1, 0, ksize=3, scale=scale, delta=delta, borderType=cv2.BORDER_DEFAULT))
432
  grad_y = cv2.convertScaleAbs(cv2.Sobel(mask, ddepth, 0, 1, ksize=3, scale=scale, delta=delta, borderType=cv2.BORDER_DEFAULT))
433