from datetime import datetime


def dateDiff(i_time,j_time):
    """
    Calculates the difference between two datetime objects
    Parameters: i_time (datetime object), j_time (datetime object)
    Returns: difference (float)
    """

    d1 = datetime.strptime(str(round(i_time,3)), "%H%M%S.%f")
    d2 = datetime.strptime(str(round(j_time,3)), "%H%M%S.%f")
    return((d1-d2).total_seconds())