From 09b08bc485e379a6f9eb03b1fa2b90d22a8da599 Mon Sep 17 00:00:00 2001 From: HabiJung Date: Mon, 29 Nov 2021 08:17:59 +0900 Subject: [PATCH] Limitation flow mask image filtering --- run_video_inpainting.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/run_video_inpainting.py b/run_video_inpainting.py index ae3a238..3acb014 100644 --- a/run_video_inpainting.py +++ b/run_video_inpainting.py @@ -386,7 +386,7 @@ def video_completion_seamless(args): # Dilate 15 pixel so that all known pixel is trustworthy flow_mask_img = scipy.ndimage.binary_dilation(mask_img, iterations=15) # Close the small holes inside the foreground objects - flow_mask_img = cv2.morphologyEx(flow_mask_img.astype(np.uint8), cv2.MORPH_CLOSE, np.ones((21, 21),np.uint8)).astype(np.bool) + # flow_mask_img = cv2.morphologyEx(flow_mask_img.astype(np.uint8), cv2.MORPH_CLOSE, np.ones((21, 21),np.uint8)).astype(np.bool) flow_mask_img = scipy.ndimage.binary_fill_holes(flow_mask_img).astype(np.bool) flow_mask.append(flow_mask_img)