DNA-Diffusion icon indicating copy to clipboard operation
DNA-Diffusion copied to clipboard

TypeError: object of type 'itertools.pairwise' has no len()

Open mjleone opened this issue 2 months ago • 0 comments

Hello,

Happy to try out DNA-Diffusion in my lab. I found that when I run train.py (accelerate launch train.py), I have an error in unet.py: At the line num_resolutions = len(in_out)

I get this error: TypeError: object of type 'itertools.pairwise' has no len()

I tried the workaround: in_out = tuple(in_out)

How did this run as itertools.pairwise, is it a different version of itertools? I have python 3.10

mjleone avatar Apr 18 '24 18:04 mjleone