-
Notifications
You must be signed in to change notification settings - Fork 206
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: TypeError: 'bool' object is not subscriptable #93
Comments
Did you use this extension to control ControlNet, or are you just using ControlNet + img2img, but are not using Sam? |
|
I am not able to reproduce your problem. You should do the following:
|
The version should not be a problem. Please add File "/a8root/work/sd_webui/stable-diffusion-webui_1/modules/scripts.py", line 417, in process
script.process(p, *script_args) and send me the output. Please keep the indentation the same as script.process. I suspect that the internal script order inside your UI has not changed due to some reason. But even if the exception comes from here, I am still unable to discover the reason. Maybe some other script also did a similar stuff, which made my extension incompatible with controlnet. Here is my output
The |
It seems that something messed up the order of the arguments. Please add
Please also give me output for other extensions as well, i.e. do not delete anything, send me the full output |
I meet the same issue |
I switched to a fresh new environment and was not able to reproduce the problem with This setting will also not create any problem. |
Please let me know what other extensions you have installed. If you have only installed ControlNet, SAM, you should not see this problem. Other popular extensions like multidiffusion-upscaler, posex, cutoff, should also be compatible with ControlNet and SAM. I have tested a lot of combinations, but none of them can really reproduce your error. Also, it is very surprising to me that people begin to create such error at this moment, instead of like 1-2 months ago. I will be on-leave for approximately a week, starting from 10 hours later. If this problem is not resolved at that time, it will be postponded to next week, approximately Wednesday or Thursday. I will still be able to monitor issues and pull requests, so if someone in the community shoot a PR, the fix process could be significantly faster. |
Hello everyone here, I am not sure if this could work, but please insert a1111 to the front of the extension directory name, i.e. sd-webui-segment-anything to a1111-sd-webui-segment-anything and see what’s going on. |
sorry, I was on vacation last week and just saw the message. I tried it out and it does work.3Q very much. You work is very useful. |
solved my problem |
It's really useful. It's great. |
@continue-revolution Case B Case C Case D |
This comment was marked as duplicate.
This comment was marked as duplicate.
@JumpIntoCoding Normally this error is because you did not do https://github.com/continue-revolution/sd-webui-segment-anything#single-image item 8. A lot of people came across this error before. |
@continue-revolution |
@JumpIntoCoding I am not able to reproduce your problem, and this error is different from the problems above in this issue. You can record your screen for the whole process you encountered this issue. If you choose to do so, please show your terminal at the end of your video, or screenshot your terminal. |
*** Error running before_process: D:\tools\AI\stable-diffusion-webui\extensions-builtin\extra-options-section\scripts\extra_options_section.py 2023-07-02 02:04:35,858 - ControlNet - WARNING - No ControlNetUnit detected in args. It is very likely that you are having an extension conflict.Here are args received by ControlNet: (). 2023-07-02 02:04:35,860 - ControlNet - WARNING - No ControlNetUnit detected in args. It is very likely that you are having an extension conflict.Here are args received by ControlNet: ().
Recommended settings: Sampling Steps: 80-100, Sampler: Euler a, Denoising strength: 0.8 ', 128, 8, ['left', 'right', 'up', 'down'], 1, 0.05, 128, 4, 0, ['left', 'right', 'up', 'down'], False, False, 'positive', 'comma', 0, False, False, '', 'Will upscale the image by the selected scale factor; use width and height sliders to set tile size ', 64, 0, 2, 1, '', [], 0, '', [], 0, '', [], True, False, False, False, 0, [], True, True, True, 0.0, 0, None, 'gif', False, None, None, False, 50) {}Traceback (most recent call last): File "D:\tools\AI\stable-diffusion-webui\modules\call_queue.py", line 55, in f res = list(func(*args, **kwargs)) File "D:\tools\AI\stable-diffusion-webui\modules\call_queue.py", line 35, in f res = func(*args, **kwargs) File "D:\tools\AI\stable-diffusion-webui\modules\img2img.py", line 198, in img2img processed = process_images(p) File "D:\tools\AI\stable-diffusion-webui\modules\processing.py", line 620, in process_images res = process_images_inner(p) File "D:\tools\AI\stable-diffusion-webui\extensions\sd-webui-controlnet\scripts\batch_hijack.py", line 42, in processing_process_images_hijack return getattr(processing, '__controlnet_original_process_images_inner')(p, *args, **kwargs) File "D:\tools\AI\stable-diffusion-webui\modules\processing.py", line 680, in process_images_inner p.init(p.all_prompts, p.all_seeds, p.all_subseeds) File "D:\tools\AI\stable-diffusion-webui\modules\processing.py", line 1239, in init image = images.flatten(img, opts.img2img_background_color) File "D:\tools\AI\stable-diffusion-webui\modules\images.py", line 725, in flatten if img.mode == "RGBA": AttributeError: 'NoneType' object has no attribute 'mode' |
Try #93 (comment) |
Again, the reason why there is an extension conflict is that you are using a certain extension other than ControlNet and SAM. There is no good way at this moment to fix this issue from code level. |
Is there an existing issue for this?
Have you updated WebUI and this extension to the newest version?
Do you understand that you should go to https://github.com/IDEA-Research/Grounded-Segment-Anything/issues if you cannot install GroundingDINO?
Do you know that you should use the newest ControlNet extension and enable external control if you want SAM extension to control ControlNet?
What happened?
when use webui, and img2img,have an error, controlnet is not work, I have allowed other script to control this extension and the same time close the segment. But when I remove the segment, the controlnet is ok, img2img is ok
Steps to reproduce the problem
What should have happened?
s
Commit where the problem happens
webui:
extension:
What browsers do you use to access the UI ?
No response
Command Line Arguments
Console logs
Additional information
No response
The text was updated successfully, but these errors were encountered: