def seconds_from(t, t_reference, unit_conversion=int(1e9)):
    """
    Helper function which concerts times into relative times in
    specified unit.

    :param t: Time
    :param t_reference: Reference time e.g. start of an event or first
        peak in event.
    :param unit_conversion: Conversion factor for time units e.g. 10**3
        for micro seconds.
    """
    return (t - t_reference) / unit_conversion