yizhangliu commited on
Commit
076742e
·
1 Parent(s): e20fa2d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -343,6 +343,8 @@ def predict(input):
343
  print(f'liuyz_0_', input)
344
  image_np = np.array(input["image"])
345
  print(f'image_np = {image_np.shape}')
 
 
346
  '''
347
  image = dict["image"] # .convert("RGB") #.resize((512, 512))
348
  # target_size = (init_image.shape[0], init_image.shape[1])
@@ -355,7 +357,7 @@ def predict(input):
355
 
356
  # output = mask #output.images[0]
357
  # output = pipe(prompt = prompt, image=init_image, mask_image=mask,guidance_scale=7.5)
358
- output = None
359
  return output #, gr.update(visible=True), gr.update(visible=True), gr.update(visible=True)
360
 
361
  print(f'liuyz_500_here_')
 
343
  print(f'liuyz_0_', input)
344
  image_np = np.array(input["image"])
345
  print(f'image_np = {image_np.shape}')
346
+ mask_np = np.array(input["mask"])
347
+ print(f'mask_np = {mask_np.shape}')
348
  '''
349
  image = dict["image"] # .convert("RGB") #.resize((512, 512))
350
  # target_size = (init_image.shape[0], init_image.shape[1])
 
357
 
358
  # output = mask #output.images[0]
359
  # output = pipe(prompt = prompt, image=init_image, mask_image=mask,guidance_scale=7.5)
360
+ output = input["mask"]
361
  return output #, gr.update(visible=True), gr.update(visible=True), gr.update(visible=True)
362
 
363
  print(f'liuyz_500_here_')