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

[Feature Request]: Checkbox in settings tab for Save image before HiRes fix + some new ideas.

Open Ainaemaet opened this issue 3 years ago • 0 comments

Is there an existing issue for this?

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

What would your feature do ?

Currently the only way to save an image before HiRes Fix is to use the following custom script to save intermediate steps. https://github.com/AUTOMATIC1111/stable-diffusion-webui/wiki/Custom-Scripts#saving-steps-of-the-sampling-process

This approach comes with a number of of issues such as it overwriting what was previously there each run, being clunky to use, and being unable to use another script at the same time.

Ultimately having a checkbox under the 'Saving Images/Grids' section of the settings tab under the 'Save a copy of image before doing face restoration' checkbox titled 'Save a copy of image before doing HiRes Fix' which would enable saving a pre hires-fixed image (saved at the last step before the fix is applied) into a user chosen folder would be optimal, it is a not-uncommen occurrence I see people saying that when hires fix is applied, they frequently get to the last step of the initial process and the image is something they would like to keep, while continuing sometimes makes it worse and/or they would prefer the original before the fix.

There is a similar less-detailed request open, as well as one with some differences in exactly what was being requested - but I'm still fairly new to github and not sure if unique additions or information warrants a new thread (apologies if that isn't the case) and as those requests are nearing 40 days old and I wanted to make a new one considering this seems like an important feature to have in order to avoid HiRes Fix botching a good image (which, at least in my experience, it does nearly as much as fixing a bad one).

Thank you very much and keep up the great work. <3

Proposed workflow

  1. Go to 'Saving Images/Grids' section under settings tab.
  2. Click checkbox besides new 'Save a copy of image before doing hires fix.' (which would exist under current 'Save a copy of image before doing face restoration.' option)
  3. Program would then save a copy of the last step of the generation before the hires fix is implemented to the same (or a user designated) folder using the same filename but with 'pre-hr' or something similar appended to the name.
  4. People everywhere will rejoice and be happy that there wonderful images didn't get mangled by hires fix, while it still gets to do its job where it's wanted - eg, we have our cake and eat it too, and sing even more praises to the wonderful devs of this amazing program.

Additional information

I was quite surprised that this wasn't already implemented seeing how the option is there for face restoration and hires fix is something that is almost always necessary when running a batch of anything other than 512x512 but it frequently makes an image not as good as the pre-fixed image. Considering there is no real way to save a pre hires'd image without using a custom script that has a number of caveats that make it not-such-a-great-option, it was even more surprising to see the solution being offered was so unwieldy and clunky given how elegant everything else in the UI seems to be.

Please add this feature, it would mean a sizeable percentage of botched images could be easily used, and users would be able to have their pick of which of the two (pre fixed, fixed) images they like best; which would be absolutely wonderful I think.

Ainaemaet avatar Oct 29 '22 19:10 Ainaemaet