def check_task_file(fname, n_examples):
    f = h5py.File(fname, 'r')
    success = True
    for i in range(n_examples):
        if str(i) not in f:
            print 'task file {} is missing key {}'.format(fname, i)
            success = False
    f.close()
    return success
probably unecessary, but checks that a task file is properly labelled sequentially
dataset/ETHPy150Open rll/lfd/scripts/gen_tasks.py/check_task_file