Mikubill / sd-webui-controlnet

WebUI extension for ControlNet
GNU General Public License v3.0
16.83k stars 1.94k forks source link

[Bug]: Multi-Inputs are ignored #2620

Closed qsniyg closed 6 months ago

qsniyg commented 7 months ago

Is there an existing issue for this?

What happened?

When I use FaceID IP-Adapters (I've tried Plus-V2 and Portrait), images I set in the Multi-Inputs tab are ignored.

If I don't upload an image to the "Single Image" tab, the following error is returned:

ValueError: controlnet is enabled but no input image is given

If I upload an image to the "Single Image" tab, no error is returned, but the images I set in Multi-Inputs are ignored (it's like as if I didn't set any images to Multi-Inputs).

Steps to reproduce the problem

  1. Go to the Multi-Inputs tab
  2. Upload some images (1 or multiple images, tried with many different images)
  3. Set Preprocessor to ip-adapter_face_id and Model to ip-adapter-faceid-portrait_sd15 [...]

What should have happened?

Multi-Inputs should work

Commit where the problem happens

webui: SD.Next a93c8160d7269fbb21f499f41ba7c9918299b1a9 controlnet: 416c345072c9c2066101e225964e3986abe6945e

What browsers do you use to access the UI ?

Brave

Command Line Arguments

--experimental

List of enabled extensions

'sd-extension-chainner', 'LDSR', 'stable-diffusion-webui-images-browser', 'sd-extension-system-info', 'Lora', 'sd-webui-agent-scheduler', 'SwinIR', 'clip-interrogator-ext', 'sd-webui-controlnet', 'stable-diffusion-webui-rembg', 'ScuNET', 'adetailer', 'sd-webui-regional-prompter', 'sd-webui-freeu', 'sd-webui-segment-anything', 'ultimate-upscale-for-automatic1111'

Console logs

ERROR    Running script process: extensions-builtin/sd-webui-controlnet/scripts/controlnet.py:
                         ValueError
╭───────────────────────────────────────── Traceback (most recent call last) ─────────────────────────────────────────╮
│ .../automatic/modules/scripts.py:526 in process                                                 │
│                                                                                                                     │
│   525 │   │   │   │   args = p.per_script_args.get(script.title(), p.script_args[script.args_from:script.args_to])  │
│ ❱ 526 │   │   │   │   script.process(p, *args, **kwargs)                                                            │
│   527 │   │   │   except Exception as e:                                                                            │
│                                                                                                                     │
│ .../automatic/extensions-builtin/sd-webui-controlnet/scripts/controlnet.py:1143 in process      │
│                                                                                                                     │
│   1142 │   │   if not Script.process_has_sdxl_refiner(p):                                                           │
│ ❱ 1143 │   │   │   self.controlnet_hack(p)                                                                          │
│   1144 │   │   return                                                                                               │
│                                                                                                                     │
│ .../automatic/extensions-builtin/sd-webui-controlnet/scripts/controlnet.py:1128 in controlnet_h │
│                                                                                                                     │
│   1127 │   │                                                                                                        │
│ ❱ 1128 │   │   self.controlnet_main_entry(p)                                                                        │
│   1129 │   │   if getattr(shared.cmd_opts, 'controlnet_tracemalloc', False):                                        │
│                                                                                                                     │
│ .../automatic/extensions-builtin/sd-webui-controlnet/scripts/controlnet.py:902 in controlnet_ma │
│                                                                                                                     │
│    901 │   │   │                                                                                                    │
│ ❱  902 │   │   │   input_image, resize_mode = Script.choose_input_image(p, unit, idx)                               │
│    903 │   │   │   if isinstance(input_image, list):                                                                │
│                                                                                                                     │
│ .../automatic/extensions-builtin/sd-webui-controlnet/scripts/controlnet.py:684 in choose_input_ │
│                                                                                                                     │
│    683 │   │   │   │   shared.state.interrupted = True                                                              │
│ ❱  684 │   │   │   raise ValueError("controlnet is enabled but no input image is given")                            │
│    685                                                                                                              │
╰─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
ValueError: controlnet is enabled but no input image is given

Additional information

No response

qsniyg commented 6 months ago

Seems to work now with the latest updates.

phatal commented 5 months ago

V1.1.442 ValueError: controlnet is enabled but no input image is given

multi-input doesn't work. keys at webui-user.bat: --xformers --update-all-extensions