enumerate

This commit is contained in:
Raphael Walker 2024-12-05 15:45:56 +01:00
parent ca78a260ed
commit 67bd8d67c2

View File

@ -116,7 +116,7 @@ class ReduxApplyWithAttnMask:
# patch the model
previous_patches = m.model_options["transformer_options"].get("patches_replace", {}).get("dit", {})
for i, block in m.model.diffusion_model.double_blocks:
for i, block in enumerate(m.model.diffusion_model.double_blocks):
# is there already a patch there?
# if so, the attnwrapper can chain off it
previous = previous_patches.get(("double_blocks", i), block)