Mikubill / sd-webui-controlnet

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

SparseCtrl: bug white frame, possible bug and default preprocessor #2880

Open light-and-ray opened 4 months ago

light-and-ray commented 4 months ago

Is there an existing issue for this?

What happened?

Hello again. There is one more field of unit which is not specified as needed

batch_keyframe_idx: Optional[str|list]

According to code it can cause problems it few scenarios

And there is a real bug. In console log for each frame:

2024-05-11 01:27:24,333 - ControlNet - INFO - Canvas scribble mode. Using mask scribble as input.

Even for rgb model + none preprocessor. It's defenatly shouldn't happen + it causes blank white first frame

Also, there I wrote it previously https://github.com/Mikubill/sd-webui-controlnet/discussions/2854#discussioncomment-9352997

For SparseCtrl default must be "none" + "mm_sd15_v3_sparsectrl_rgb", but there is mixed up default "scribble_pidinet" + "mm_sd15_v3_sparsectrl_rgb" which doesn't make sense

After presets removal this became critical. Can you set default preprocessor for SparseCtrl "none"?

light-and-ray commented 4 months ago

Yes, here it is изображение

huchenlei commented 4 months ago

It is a legacy design flaw that we detect whether we are in canvas scribble mode by detecting whether the mask is blank in non-inpaint and non-ipadapter mode.

There is a setting to disable canvas scribble: controlnet_ignore_noninpaint_mask https://github.com/Mikubill/sd-webui-controlnet/blob/b30f0ac4a1ab20c6ba89ee20ce1cff6eb4f07412/scripts/controlnet.py#L673-L677

I am going to revamp canvas scribble logic later so that we don't need to perform this dumb check.

light-and-ray commented 4 months ago

I remember I had enabled this checkbox, and it was enabled by default. Now it is absent. So it means False, right? But should be True

I think it's not urgent, so it can wait for a new design

light-and-ray commented 4 months ago

Ah no, it exists in the settings. But is disabled, hmm. Maybe I disabled it accidentally. Or the logic was changed and previously it was ignored for sparsecrtl