Skip to content
This repository was archived by the owner on Feb 7, 2025. It is now read-only.
This repository was archived by the owner on Feb 7, 2025. It is now read-only.

Verify if len(attention_levels) == len(num_channels) #219

@Warvito

Description

@Warvito

Add code to verify if the number of attentions levels is the same of the number elements in num_channels. Currently, the DiffusionModelUNet is raising the following error message

Traceback (most recent call last):
  File "/media/walter/Storage/Projects/GenerativeModels/venv/lib/python3.10/site-packages/IPython/core/interactiveshell.py", line 3442, in run_code
    exec(code_obj, self.user_global_ns, self.user_ns)
  File "<ipython-input-12-1dcab9cf177c>", line 1, in <module>
    model = DiffusionModelUNet(
  File "/media/walter/Storage/Projects/GenerativeModels/generative/networks/nets/diffusion_model_unet.py", line 1696, in __init__
    with_attn=(attention_levels[i] and not with_conditioning),
IndexError: tuple index out of range

Add the same verification to AutoencoderKL code

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions