In the implementation of kpts2cs,
the output of crop_size in centroid is half of the width and height
I have a doubt if it is a mistake or if not, is there any concept for that?
if method == 'centroid': center = np.ceil(visible_keypoints.mean(axis=0, keepdims=True)) dif = np.abs(visible_keypoints - center).max(axis=0, keepdims=True) crop_size = np.ceil(dif*enlarge).squeeze() center = center.squeeze() elif method == 'boundary': left_top = visible_keypoints.min(axis=0, keepdims=True) right_bottom = visible_keypoints.max(axis=0, keepdims=True) center = ((left_top + right_bottom) / 2).squeeze() crop_size = ((right_bottom - left_top)*enlarge).squeeze()