def _get_event_id_tr(tr):
    """
    Get event id from a obspy trace. The obspy trace should have the event_time keyword.

    :param tr: a obspy trace
    :return str event_id: event id in "%Y%m%d%H%M%S", e.g., '20191019200909'
    """
    origin = tr.stats.event_time
    event_id = origin.datetime.strftime("%Y%m%d%H%M%S")
    return event_id