count = 0 for did, dance in tqdm(enumerate(data), total=len(data)): if did != 9: f, pgram = genLSP(dance[0], dance[1], s=2000) FTs[count, 0] = f FTs[count, 1] = pgram count += 1