divamgupta / stable-diffusion-tensorflow

Stable Diffusion in TensorFlow / Keras
Other
1.57k stars 227 forks source link

img2img question, guidance scale and input strength #65

Open WSINTRA opened 1 year ago

WSINTRA commented 1 year ago

In the diffusionBee UI the guidance scale is between 0-20 and the input strength is 10-90 What does that map to in the following.. I want to reproduce the output I get in diffusionBee def generate( self, prompt, negative_prompt=None, batch_size=1, num_steps=25, unconditional_guidance_scale=7.5, temperature=1, seed=None, input_image=None, input_mask=None, input_image_strength=0.5, ):

soten355 commented 1 year ago

The guidance scale is any float number (for example 7.5, 10, 11.357) between 0 and 20. You'll plug that into the unconditional_guidance_scale variable

The input strength for an input image is any float number between 0 and 1. If, in DiffusionBee, you used an input strength of 75, then that would translate into input_image_strength = 0.75