def isclose(a, b, rel_tol=1e-09, abs_tol=0.0):
    """Python 2 doesn't have math.isclose()
    Here is an equivalent function
    Use this to tell whether two float numbers are close enough
    considering using == to compare floats is dangerous!
    2.0*3.3 != 3.0*2.2 in python!

    Args:
        a (float) : the first float number
        b (float) : the second float number
        rel_tol (float) : the relative difference threshold between a and b
        abs_tol (float) : absolute difference threshold. not recommended for float

    Returns:
        bool
    """
    return abs(a - b) <= max(rel_tol * max(abs(a), abs(b)), abs_tol)