def METHOD_NAME(e1, e2):
    """
    clc iou and ioa
    """
    area1 = e1["end"] - e1["start"]
    area2 = e2["end"] - e2["start"]
    x1 = np.maximum(e1["start"], e2["start"])
    x2 = np.minimum(e1["end"], e2["end"])
    inter = np.maximum(0.0, x2 - x1)
    iou = 0.0 if (area1 + area2 -
                  inter) == 0 else inter * 1.0 / (area1 + area2 - inter)
    ioa = 0.0 if area2 == 0 else inter * 1.0 / area2
    return iou, ioa