def thickness(points):
    """Find contour thickness in x and y dimensions.

    This method determines contour thickness (i.e., maximal extent/width) in x
    and y dimensions given a set of contour points. Thickness is defined as the
    maximal difference between two points along that dimension.

    Args:
        points (numpy.ndarray): array of contour points

    Returns:
        float thickness in x dimension
        float thickness in y dimension
    """
    # initialize min and max values
    min_x = float("inf")
    max_x = -1 * float("inf")

    min_y = float("inf")
    max_y = -1 * float("inf")

    # find max and min of x and y
    for point in points:
        x = point[0]
        y = point[1]
        min_x = min(x, min_x)
        max_x = max(x, max_x)

        min_y = min(y, min_y)
        max_y = max(y, max_y)

    # return difference
    return (max_x - min_x), (max_y - min_y)