def mergeBboxes(bbox1, bbox2):
    """
    :param bbox1: (top, left, bottom, right)
    :param bbox2: (top, left, bottom, right)
    :return: Merge bounding boxes
    """
    if isContained(bbox1, bbox2):
        return bbox2
    elif isContained(bbox2, bbox1):
        return bbox1
    else:
        return (
            min(bbox1[0], bbox2[0]),
            min(bbox1[1], bbox2[1]),
            max(bbox1[2], bbox2[2]),
            max(bbox1[3], bbox2[3]),
        )
:param bbox1: (top, left, bottom, right)
    :param bbox2: (top, left, bottom, right)
    :return: Merge bounding boxes