blob persist. updated to work with OpenCV contours