stable-diffusion-webui icon indicating copy to clipboard operation
stable-diffusion-webui copied to clipboard

[Bug]: "Send to Inpaint" hides old mask without removing it

Open poisenbery opened this issue 2 years ago • 11 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues and checked the recent builds/commits

What happened?

When I inpaint an image and send the new image back to inpaint, the old masked area appears to be cleared, but is actually not. Hitting the "undo" button in the drawing area will cause the old mask to re-appear. Trying to generate without doing this will include the previously masked area.

Steps to reproduce the problem

  1. Define a masked region
  2. Hit generate
  3. Send new image to inpaint
  4. Draw a new mask
  5. The masked area will be "cleared"
  6. Inpaint will include the old masked area

What should have happened?

Img2Img happens on the new masked region and does not have the old mask. OR The old mask remains visible when the image is sent back to img2img

Commit where the problem happens

5ab7f213

What platforms do you use to access the UI ?

Windows

What browsers do you use to access the UI ?

Brave

Command Line Arguments

xformers, no-half, no-half-vae, deepdanbooru

List of extensions

"You can copy it at Extension tab" how?

Console logs

Console is normal and does not have anything that would help

Additional information

No response

poisenbery avatar May 10 '23 09:05 poisenbery

this is a gradio bug as far as i know, nothing to do with automatic1111

razvan-nicolae avatar May 10 '23 14:05 razvan-nicolae

Was Gradio updated recently? I never had this issue until recently after I decided to Git Pull. I don't update this often because things are usually broken when I do, and this time was no exception with all of the Torch 2.0 bugs that everyone is experiencing.

poisenbery avatar May 10 '23 18:05 poisenbery

also noticed recently if you have an Inpaint image with a mask, then send from PNG info to img2img then switch back to the Inpaint tab, then the mask disappears... it shoudn't ideally as I've not changed anything on that tab specifically.

(basically I'm doing it this way to get the prompt/parameters from a previous render into the inputs, without sending the image specifically to inpaint)

jmp909 avatar May 11 '23 17:05 jmp909

this is a gradio bug as far as i know, nothing to do with automatic1111

except for the fact that automatic1111 uses gradio...

ghostsquad avatar May 11 '23 18:05 ghostsquad

workaround right now (which is not great) whenever I'm working with inpainting is to reload the page before changing masks. Thankfully it is fairly quick to drag and drop the last generated image back over to fill in the prompt and other settings as well as the img that needs inpainting.

ghostsquad avatar May 11 '23 18:05 ghostsquad

Removing the image completely and uploading again also works.

Lalimec avatar May 11 '23 20:05 Lalimec

Removing the image completely and uploading again also works.

Oh, good to know. I didn't think about that.

ghostsquad avatar May 12 '23 01:05 ghostsquad

Removing the image completely and uploading again also works.

Clicking Undo is faster

poisenbery avatar May 12 '23 08:05 poisenbery

not if the mask is complex

Removing the image completely and uploading again also works.

Clicking Undo is faster

Lalimec avatar May 12 '23 09:05 Lalimec

not if the mask is complex

Removing the image completely and uploading again also works.

Clicking Undo is faster

ahh i see what you mean now.

poisenbery avatar May 12 '23 09:05 poisenbery

Yep, clicking undo through previous levels of mask to remove all seems to work okay.

ASKemp avatar May 13 '23 09:05 ASKemp