light-and-ray / sd-webui-replacer

A tab for sd-webui for replacing objects in pictures or videos using detection prompt
193 stars 11 forks source link

Can we customize the resolution or scaling factor during the hirefix stage? Thank you #45

Closed BNP1111 closed 5 months ago

BNP1111 commented 6 months ago

Can we customize the resolution or scaling factor during the hirefix stage? Thank you

light-and-ray commented 6 months ago

What do you mean? Hires fix for inpainting is different. No matter which resolution on generation stage, inpainted area will be fitted into original image

If you want to limit resolution, there is an option for that. Or do you want to inpaint in higher resolution which will be downscaled whatever? I think it's not so reasonable because in this case whole image will be upscaled before generation, and it will produce a bad context for inpainting

BNP1111 commented 5 months ago

What do you mean? Hires fix for inpainting is different. No matter which resolution on generation stage, inpainted area will be fitted into original image

If you want to limit resolution, there is an option for that. Or do you want to inpaint in higher resolution which will be downscaled whatever? I think it's not so reasonable because in this case whole image will be upscaled before generation, and it will produce a bad context for inpainting

Thank you for your explanation. I have another question. What is the default resolution used during the HireFix stage of Replacer? For instance, if the original image resolution is 768×768, and then I set 1024×1024 with only masked to inpaint partial area, what resolution is used during the HireFix stage? Is it 768×768 or 1024×1024? Thank you.

light-and-ray commented 5 months ago

The default resolution during the HireFix is equal the source image resolution. In your case it will be 768×768

BNP1111 commented 5 months ago

Understood, thank you.