handle mask files that failed to read

This commit is contained in:
Blake Blackshear 2020-09-12 22:56:19 -05:00
parent 5e77436d39
commit 1c33b8acb2

View File

@ -207,7 +207,7 @@ def track_camera(name, config, frame_queue, frame_shape, detection_queue, detect
else:
mask = None
if mask is None:
if mask is None or mask.size == 0:
mask = np.zeros((frame_shape[0], frame_shape[1]), np.uint8)
mask[:] = 255