hako-mikan / sd-webui-lora-block-weight

1.12k stars 100 forks source link

Does not work with SD.Next #157

Closed MysticDaedra closed 1 month ago

MysticDaedra commented 7 months ago

SD.Next has obviously diverged tremendously from A1111, but it would be great if compatibility could be maintained with SD.Next. Currently throws the "cannot convert string to float" error, due to the built-in Extra Networks function. This cannot be disabled, it's built-in rather than installed as an extension. If a workaround/fix could be had, I and likely many others would be very grateful :)

MysticDaedra commented 7 months ago
00:51:34-505209 ERROR    activating extra network: name=lora args:[<modules.extra_networks.ExtraNetworkParams object at
                         0x00000194DE374DD0>]: ValueError
╭───────────────────────────────────────── Traceback (most recent call last) ──────────────────────────────────────────╮
│ D:\automatic\modules\extra_networks.py:91 in activate                                                                │
│                                                                                                                      │
│    90 │   │   try:                                                                                                   │
│ ❱  91 │   │   │   extra_network.activate(p, extra_network_args, step=step)                                           │
│    92 │   │   except Exception as e:                                                                                 │
│                                                                                                                      │
│ D:\automatic\extensions-builtin\Lora\extra_networks_lora.py:81 in activate                                           │
│                                                                                                                      │
│    80 │   │   │   │   else:                                                                                          │
│ ❱  81 │   │   │   │   │   unet_multiplier[i] = float(unet_multiplier[i])                                             │
│    82 │   │   │   dyn_dim = int(params.positional[3]) if len(params.positional) > 3 else None                        │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
ValueError: could not convert string to float: 'XYZ'
hako-mikan commented 1 month ago

This is an issue on the Sd.Next side, so the author will need to improve the core code of Sd.Next. Notations like 1:1 =XYZ can be used in A1111 or Forge, but it seems they are not accepted in Sd.Next. Using a notation like 1:1:0 =XYZ might work, but the '0' is where dynamic LoRA is specified, so there is a possibility that some issues might arise.