linoyts HF staff commited on
Commit
dcfe60b
·
verified ·
1 Parent(s): 6fc2413

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -132,6 +132,7 @@ def preprocess_image(image: Image.Image,
132
  """
133
 
134
  width, height = image['composite'].size
 
135
  ratio = np.sqrt(1024. * 1024. / (width * height))
136
  new_width, new_height = int(width * ratio), int(height * ratio)
137
  image = image['composite'].resize((new_width, new_height))
@@ -423,7 +424,7 @@ with gr.Blocks(delete_cache=(600, 600)) as demo:
423
  label="controlnet conditioning scale",
424
  minimum=0.5,
425
  maximum=5.0,
426
- step=0.1,
427
  value=0.8,
428
  )
429
  with gr.Tab(label="3D generation"):
 
132
  """
133
 
134
  width, height = image['composite'].size
135
+ image["background"] = Image.new("RGB", (width, height), (255, 255, 255))
136
  ratio = np.sqrt(1024. * 1024. / (width * height))
137
  new_width, new_height = int(width * ratio), int(height * ratio)
138
  image = image['composite'].resize((new_width, new_height))
 
424
  label="controlnet conditioning scale",
425
  minimum=0.5,
426
  maximum=5.0,
427
+ step=0.01,
428
  value=0.8,
429
  )
430
  with gr.Tab(label="3D generation"):