def score_initial_asr_lag(partial_transcripts):
    """Measures the time between when we start playback of the wav file and
    when the asr system issues its first non-empty transcription."""
    initial_lags = []
    for per_utterance_transcripts in partial_transcripts:
        if not per_utterance_transcripts:
            continue
        lag = None
        for timestamp, transcript in per_utterance_transcripts:
            lag = timestamp
            if transcript.strip():
                break
        initial_lags.append(lag)

    if not initial_lags:
        return 0.0
    return float(sum(initial_lags)) / len(initial_lags)