LyCORIS
LyCORIS copied to clipboard
diag_oft/Boft [rank0]: RuntimeError: dictionary changed size during iteration
lycoris-lora==3.0.1.dev1
Got a runtime error when using either Diag_OFT or BOFT.
[rank0]: RuntimeError: dictionary changed size during iteration
From
2024-07-27 14:41:44|[LyCORIS]-WARNING: constrain is deprecated. Please use constraint instead.
[rank0]: Traceback (most recent call last):
[rank0]: File ".../kohya_ss/sd-scripts/sdxl_train_network.py", line 185, in <module>
[rank0]: trainer.train(args)
[rank0]: File ".../kohya_ss/sd-scripts/train_network.py", line 299, in train
[rank0]: network = network_module.create_network(
[rank0]: File ".../kohya_ss/venv/lib64/python3.10/site-packages/lycoris/kohya.py", line 31, in create_network
[rank0]: for key, value in kwargs.items():
[rank0]: RuntimeError: dictionary changed size during iteration
As a quick fix, I changed:
for key, value in kwargs.items():
to
for key, value in list(kwargs.items()):
on line 31 of kohya.py
investigating thx for info
Fixed in https://github.com/KohakuBlueleaf/LyCORIS/commit/ff5ccf32f311b26b950ea546c2db038f90e9cea0 Will be pushed to main/pypi in next version