def test(halo_file, filename_dict):
    fetch_times = []
    length_errors = []
    for h in np.loadtxt(halo_file):
        starttime = clock()
        P = fetch(h[ID], filename_dict)
        fetch_times.append(clock() - starttime)
        if (len(P) != h[N200a]): length_errors.append(len(P) - int(h[N200a]))
        for p in P: assert p[H_ID] == h[ID]
        print '\tHalo',h[ID],'verified. Current avg fetch time:',np.average(fetch_times)
    return fetch_times, length_errors
dataset/ETHPy150Open alklein/cosmo-ML/chunk_manager.py/test/original