[Bug]: *** Error running process_before_every_sampling:
Checklist
- [X] The issue exists after disabling all extensions
- [X] The issue exists on a clean installation of webui
- [X] The issue is caused by an extension, but I believe it is caused by a bug in the webui
- [ ] The issue exists in the current version of the webui
- [X] The issue has not been reported before recently
- [X] The issue has been reported before but has not been fixed yet
What happened?
Facing issue with ControlNet in forge with SDXL models. For now tried segmentation. IP adaptors as well as instant ID in both img2img and text2img
Can anyone please help to help me with steps to resolve?
Steps to reproduce the problem
- select any controlnet and click generate
What should have happened?
generation should have happened without issue.
What browsers do you use to access the UI ?
Microsoft Edge, Other
Sysinfo
.
Console logs
---
To load target model AutoencoderKL
Begin to load 1 model
[Memory Management] Current Free GPU Memory (MB) = 2778.92431640625
[Memory Management] Model Memory (MB) = 319.11416244506836
[Memory Management] Minimal Inference Memory (MB) = 1024.0
[Memory Management] Estimated Remaining GPU Memory (MB) = 1435.8101539611816
Moving model(s) has taken 0.09 seconds
*** Error running process_before_every_sampling: C:\Forge\stable-diffusion-webui-forge\extensions-builtin\sd_forge_controlnet\scripts\controlnet.py
Traceback (most recent call last):
File "C:\Forge\stable-diffusion-webui-forge\modules\scripts.py", line 835, in process_before_every_sampling
script.process_before_every_sampling(p, *script_args, **kwargs)
File "C:\Forge\stable-diffusion-webui-forge\venv\lib\site-packages\torch\utils\_contextlib.py", line 115, in decorate_context
return func(*args, **kwargs)
File "C:\Forge\stable-diffusion-webui-forge\extensions-builtin\sd_forge_controlnet\scripts\controlnet.py", line 555, in process_before_every_sampling
self.process_unit_before_every_sampling(p, unit, self.current_params[i], *args, **kwargs)
KeyError: 0
Additional information
No response
Traceback (most recent call last):
File "C:\Forge\stable-diffusion-webui-forge\modules_forge\main_thread.py", line 37, in loop
task.work()
File "C:\Forge\stable-diffusion-webui-forge\modules_forge\main_thread.py", line 26, in work
self.result = self.func(*self.args, **self.kwargs)
File "C:\Forge\stable-diffusion-webui-forge\modules\txt2img.py", line 111, in txt2img_function
processed = processing.process_images(p)
File "C:\Forge\stable-diffusion-webui-forge\modules\processing.py", line 752, in process_images
res = process_images_inner(p)
File "C:\Forge\stable-diffusion-webui-forge\modules\processing.py", line 922, in process_images_inner
samples_ddim = p.sample(conditioning=p.c, unconditional_conditioning=p.uc, seeds=p.seeds, subseeds=p.subseeds, subseed_strength=p.subseed_strength, prompts=p.prompts)
File "C:\Forge\stable-diffusion-webui-forge\modules\processing.py", line 1275, in sample
samples = self.sampler.sample(self, x, conditioning, unconditional_conditioning, image_conditioning=self.txt2img_image_conditioning(x))
File "C:\Forge\stable-diffusion-webui-forge\modules\sd_samplers_kdiffusion.py", line 251, in sample
samples = self.launch_sampling(steps, lambda: self.func(self.model_wrap_cfg, x, extra_args=self.sampler_extra_args, disable=False, callback=self.callback_state, **extra_params_kwargs))
File "C:\Forge\stable-diffusion-webui-forge\modules\sd_samplers_common.py", line 263, in launch_sampling
return func()
File "C:\Forge\stable-diffusion-webui-forge\modules\sd_samplers_kdiffusion.py", line 251, in
*** [[133, 135, 134], *** [133, 135, 134], *** [135, 137, 136], *** ..., *** [189, 193, 198], *** [201, 206, 210], *** [ 0, 0, 0]],
*** [[130, 132, 131], *** [133, 135, 134], *** [135, 137, 136], *** ..., *** [187, 197, 200], *** [201, 209, 212], *** [ 0, 0, 0]],
*** ...,
*** [[139, 105, 61], *** [126, 89, 42], *** [152, 121, 74], *** ..., *** [ 5, 7, 6], *** [ 0, 0, 0], *** [ 14, 14, 14]],
*** [[148, 112, 66], *** [155, 124, 76], *** [160, 129, 82], *** ..., *** [ 3, 5, 4], *** [ 4, 7, 5], *** [ 15, 15, 15]],
*** [[151, 121, 73], *** [151, 119, 72], *** [156, 124, 77], *** ..., *** [ 5, 7, 6], *** [ 1, 5, 4], *** [ 15, 15, 15]]], dtype=uint8), 'mask': array([[[0, 0, 0], *** [0, 0, 0], *** [0, 0, 0], *** ..., *** [0, 0, 0], *** [0, 0, 0], *** [0, 0, 0]],
*** [[0, 0, 0], *** [0, 0, 0], *** [0, 0, 0], *** ..., *** [0, 0, 0], *** [0, 0, 0], *** [0, 0, 0]],
*** [[0, 0, 0], *** [0, 0, 0], *** [0, 0, 0], *** ..., *** [0, 0, 0], *** [0, 0, 0], *** [0, 0, 0]],
*** ...,
*** [[0, 0, 0], *** [0, 0, 0], *** [0, 0, 0], *** ..., *** [0, 0, 0], *** [0, 0, 0], *** [0, 0, 0]],
*** [[0, 0, 0], *** [0, 0, 0], *** [0, 0, 0], *** ..., *** [0, 0, 0], *** [0, 0, 0], *** [0, 0, 0]],
*** [[0, 0, 0], *** [0, 0, 0], *** [0, 0, 0], *** ..., *** [0, 0, 0], *** [0, 0, 0], *** [0, 0, 0]]], dtype=uint8)}, resize_mode='Crop and Resize', processor_res=0.5, threshold_a=0.5, threshold_b=0.5, guidance_start=0, guidance_end=1, pixel_perfect=False, control_mode='ControlNet is more important', save_detected_map=True), ControlNetUnit(input_mode=<InputMode.SIMPLE: 'simple'>, use_preview_as_input=False, batch_image_dir='', batch_mask_dir='', batch_input_gallery=[], batch_mask_gallery=[], generated_image=None, mask_image=None, hr_option='Both', enabled=True, module='InsightFace (InstantID)', model='control_instant_id_sdxl [c5c25a50]', weight=1, image={'image': array([[[ 0, 0, 0], *** [ 0, 0, 0], *** [ 0, 0, 0], *** ..., *** [ 0, 0, 0], *** [ 0, 0, 0], *** [ 0, 0, 0]],
*** [[ 0, 0, 0], *** [ 0, 0, 0], *** [ 0, 0, 0], *** ..., *** [ 0, 0, 0], *** [ 0, 0, 0], *** [ 0, 0, 0]],
*** [[ 0, 0, 0], *** [ 0, 0, 0], *** [ 0, 0, 0], *** ..., *** [ 0, 0, 0], *** [ 0, 0, 0], *** [ 0, 0, 0]],
*** ...,
*** [[ 0, 0, 0], *** [186, 117, 67], *** [190, 121, 71], *** ..., *** [ 0, 0, 0], *** [ 0, 0, 0], *** [ 0, 0, 0]],
*** [[ 0, 0, 0], *** [181, 113, 64], *** [186, 118, 70], *** ..., *** [ 0, 0, 0], *** [ 0, 0, 0], *** [ 0, 0, 0]],
*** [[ 0, 0, 0], *** [176, 110, 60], *** [183, 117, 66], *** ..., *** [ 0, 0, 0], *** [ 0, 0, 0], *** [ 0, 0, 0]]], dtype=uint8), 'mask': array([[[0, 0, 0], *** [0, 0, 0], *** [0, 0, 0], *** ..., *** [0, 0, 0], *** [0, 0, 0], *** [0, 0, 0]],
*** [[0, 0, 0], *** [0, 0, 0], *** [0, 0, 0], *** ..., *** [0, 0, 0], *** [0, 0, 0], *** [0, 0, 0]],
*** [[0, 0, 0], *** [0, 0, 0], *** [0, 0, 0], *** ..., *** [0, 0, 0], *** [0, 0, 0], *** [0, 0, 0]],
*** ...,
*** [[0, 0, 0], *** [0, 0, 0], *** [0, 0, 0], *** ..., *** [0, 0, 0], *** [0, 0, 0], *** [0, 0, 0]],
*** [[0, 0, 0], *** [0, 0, 0], *** [0, 0, 0], *** ..., *** [0, 0, 0], *** [0, 0, 0], *** [0, 0, 0]],
*** [[0, 0, 0], *** [0, 0, 0], *** [0, 0, 0], *** ..., *** [0, 0, 0], *** [0, 0, 0], *** [0, 0, 0]]], dtype=uint8)}, resize_mode='Crop and Resize', processor_res=0.5, threshold_a=0.5, threshold_b=0.5, guidance_start=0, guidance_end=1, pixel_perfect=False, control_mode='ControlNet is more important', save_detected_map=True), False, 7, 1, 'Constant', 0, 'Constant', 0, 1, 'enable', 'MEAN', 'AD', 1, False, 1.01, 1.02, 0.99, 0.95, False, 0.5, 2, False, 256, 2, 0, False, False, 3, 2, 0, 0.35, True, 'bicubic', 'bicubic', False, 0, 'anisotropic', 0, 'reinhard', 100, 0, 'subtract', 0, 0, 'gaussian', 'add', 0, 100, 127, 0, 'hard_clamp', 5, 0, 'None', 'None', False, 'MultiDiffusion', 768, 768, 64, 4, False, False, False, False, False, 'positive', 'comma', 0, False, False, 'start', '', 1, '', [], 0, '', [], 0, '', [], True, False, False, False, False, False, False, 0, False) {} Traceback (most recent call last): File "C:\Forge\stable-diffusion-webui-forge\modules\call_queue.py", line 57, in f res = list(func(*args, **kwargs)) TypeError: 'NoneType' object is not iterable
Same issue here :(
same here :(
same :(