Efficient Post-Contour Correctness in Object Detection and Segmentation