def valid_replay(info, ping):
    """Make sure the replay isn't corrupt, and is worth looking at."""
    if (info.HasField('error') or info.base_build != ping.base_build or 
        info.game_duration_loops < 1000 or len(info.player_info) != 2):
        return False
    for p in info.player_info:
        if p.player_apm < 10 or p.player_mmr < 1000:
            return False
    return True
