Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -492,7 +492,7 @@ def apply_mask(d, b):
|
|
492 |
if ksize/2 - int(ksize/2) == 0:
|
493 |
ksize = ksize + 1
|
494 |
|
495 |
-
frame = cv2.imread(frames[frame_selected]).astype(np.uint8)
|
496 |
dmask = cv2.GaussianBlur(dmask, (ksize,ksize), 0)
|
497 |
frame[:, :, 3] = 255 - dmask
|
498 |
cv2.imwrite(frames[frame_selected], frame)
|
|
|
492 |
if ksize/2 - int(ksize/2) == 0:
|
493 |
ksize = ksize + 1
|
494 |
|
495 |
+
frame = cv2.imread(frames[frame_selected], cv2.IMREAD_UNCHANGED).astype(np.uint8)
|
496 |
dmask = cv2.GaussianBlur(dmask, (ksize,ksize), 0)
|
497 |
frame[:, :, 3] = 255 - dmask
|
498 |
cv2.imwrite(frames[frame_selected], frame)
|