yejunliang23 commited on
Commit
d795b4c
·
verified ·
1 Parent(s): 0754af5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -0
app.py CHANGED
@@ -99,6 +99,7 @@ def predict(_chatbot,task_history,viewer_voxel,viewer_mesh,task_new,seed,top_k,t
99
  if is_video_file(q[0]):
100
  content.append({'video': f'file://{q[0]}'})
101
  else:
 
102
  pipeline_image.preprocess_image_white(Image.open(q[0])).save(f"{TMP_DIR}/{trial_id}.png", "png")
103
  content.append({'image': f'file://{TMP_DIR}/{trial_id}.png'})
104
  #content.append({'image': f'file://{q[0]}'})
 
99
  if is_video_file(q[0]):
100
  content.append({'video': f'file://{q[0]}'})
101
  else:
102
+ trial_id = uuid.uuid4()
103
  pipeline_image.preprocess_image_white(Image.open(q[0])).save(f"{TMP_DIR}/{trial_id}.png", "png")
104
  content.append({'image': f'file://{TMP_DIR}/{trial_id}.png'})
105
  #content.append({'image': f'file://{q[0]}'})