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

[Bug]: Img2Img Batch mode does not use the output image format

Open mykeehu opened this issue 2 years ago • 2 comments

Is there an existing issue for this?

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

What happened?

I used the Batch mode on the Img2Img tab. The source images were JPGs.

Steps to reproduce the problem

  1. Go to Img2Img tab
  2. Go to Batch tab
  3. Select a folder with JPG images
  4. Select a script (I used ABG_Remover extension)
  5. I got an error, because it does not save the images as PNG, even though it is set to PNG in Settings.

What should have happened?

If the PNG format is set in Settings, save to PNG for all saves, also for Batch, or for Batch have a separate option to keep the original format or to use the specified format.

Commit where the problem happens

c98cb0f8

What platforms do you use to access UI ?

Windows

What browsers do you use to access the UI ?

Google Chrome

Command Line Arguments

--xformers --ckpt-dir V:\!SDModels --ui-config-file 1my/ui-config-my.json --ui-settings-file 1my/config-my.json --autolaunch --gradio-img2img-tool color-sketch

Additional information, context and logs

image

mykeehu avatar Jan 22 '23 16:01 mykeehu

I am waiting for a proper fix too. Currently, I have a dirty fix for myself:

Replace one of the below files with modules -> img2img.py

Hardcode file format to jpg with quality 100 https://gist.github.com/roygear/cd1e27d0cf3704f966d1c508a7ef6eee

Hardcode file format to png https://gist.github.com/roygear/efdb82cfa38e7bc98ccb5a1203de2292

roygear avatar Apr 02 '23 14:04 roygear

I have this issue too (using ultimate sd upscale extension) it's always saving as JPG.

dejl avatar Apr 14 '23 21:04 dejl