def METHOD_NAME(self, heatmaps, center, scale, kernelsize=3):
    """the highest heatvalue location with a quarter offset in the
    direction from the highest response to the second highest response.
    Args:
        heatmaps (numpy.ndarray): The predicted heatmaps
        center (numpy.ndarray): The boxes center
        scale (numpy.ndarray): The scale factor
    Returns:
        preds: numpy.ndarray([batch_size, num_joints, 2]), keypoints coords
        maxvals: numpy.ndarray([batch_size, num_joints, 1]), the maximum confidence of the keypoints
    """
    coords, maxvals = self.get_max_preds(heatmaps)
    heatmap_height = heatmaps.shape[2]
    heatmap_width = heatmaps.shape[3]
    if self.use_dark:
        coords = self.dark_postprocess(heatmaps, coords, kernelsize)
    else:
        for n in range(coords.shape[0]):
            for p in range(coords.shape[1]):
                hm = heatmaps[n][p]
                px = int(math.floor(coords[n][p][0] + 0.5))
                py = int(math.floor(coords[n][p][1] + 0.5))
                if 1 < px < heatmap_width - 1 and 1 < py < heatmap_height - 1:
                    diff = np.array([
                        hm[py][px + 1] - hm[py][px - 1],
                        hm[py + 1][px] - hm[py - 1][px]
                    ])
                    coords[n][p] += np.sign(diff) * .25
    preds = coords.copy()
    # Transform back
    for i in range(coords.shape[0]):
        preds[i] = transform_preds(coords[i], center[i], scale[i],
                                   [heatmap_width, heatmap_height])
    return preds, maxvals