def isOverlap1D(box1, box2):
    """Check if two 1D boxes overlap.
    Reference: https://stackoverflow.com/a/20925869/12646778
    Arguments:
        box1, box2: format: (xmin, xmax)
    Returns:
        res: bool, True for overlapping, False for not
    """
    xmin1, xmax1 = box1
    xmin2, xmax2 = box2
    return xmax1 >= xmin2 and xmax2 >= xmin1