Open rodjjo opened 1 year ago
This is the corrected code for Windows OS in "run_tokenflow_pnp.py" instead of n_frames = [int([x for x in latentspath[i].split('/') if 'nframes' in x][0].split('')[1]) for i in range(len(latents_path))] write this: nframes = [int(os.path.basename(x).split('')[1]) for x in latents_path if 'nframes' in x]
This is the corrected code for Windows OS in "run_tokenflow_pnp.py" instead of n_frames = [int([x for x in latentspath[i].split('/') if 'nframes' in x][0].split('')[1]) for i in range(len(latents_path))] write this: nframes = [int(os.path.basename(x).split('')[1]) for x in latents_path if 'nframes' in x]
Thanks, That works. I guess I can remove regular expressions to make it simple.
still receiving an error in the new code.
Traceback (most recent call last):
File "D:\TokenFlow\run_tokenflow_pnp.py", line 302, in
ValueError: empty separator
Try again, I changed argentinox suggestion a little bit.
What
Why
I was getting an error when the function tried to get the number of frames.
Description