pinellolab / DNA-Diffusion

🧬 Generative modeling of regulatory DNA sequences with diffusion probabilistic models 💨

Home Page:https://pinellolab.github.io/DNA-Diffusion/

Repository from Github https://github.compinellolab/DNA-DiffusionRepository from Github https://github.compinellolab/DNA-Diffusion

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

mjleone opened this issue · 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

commented

Hi @mjleone, hope the emails helped with resolving your issue feel free to reach back out if you still need any other assistance.