andy-wyx commited on
Commit
722f9cb
·
1 Parent(s): c577b1b

change output type

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -262,7 +262,7 @@ def update_display(image):
262
  # gr.Gallery(label="Closest Images", show_label=False,elem_id="gallery",columns=[5], rows=[1],height='auto', allow_preview=True, preview=None)
263
  diagram= None
264
  # gr.Image(label = 'Bar Chart')
265
- return processed_image,processed_image,instruction,model_name,explain_method,sampling_size,top_k,exp_gallery,closest_gallery,diagram
266
  def update_slider_visibility(explain_method):
267
  bool = explain_method=="Rise"
268
  return {sampling_size: gr.Slider(1, 5000, value=2000, label="Sampling Size in Rise", visible=bool, interactive=True)}
@@ -434,7 +434,7 @@ with gr.Blocks(theme='sudeepshouche/minimalist') as demo:
434
  process_button.click(
435
  fn=update_display,
436
  inputs=input_image,
437
- outputs=[input_image,workbench_image,instruction_text,model_name,explain_method,sampling_size,top_k,exp_gallery,closest_gallery,diagram]
438
  )
439
 
440
 
 
262
  # gr.Gallery(label="Closest Images", show_label=False,elem_id="gallery",columns=[5], rows=[1],height='auto', allow_preview=True, preview=None)
263
  diagram= None
264
  # gr.Image(label = 'Bar Chart')
265
+ return processed_image,processed_image,instruction,model_name,explain_method,sampling_size,top_k,class_predicted,exp_gallery,closest_gallery,diagram
266
  def update_slider_visibility(explain_method):
267
  bool = explain_method=="Rise"
268
  return {sampling_size: gr.Slider(1, 5000, value=2000, label="Sampling Size in Rise", visible=bool, interactive=True)}
 
434
  process_button.click(
435
  fn=update_display,
436
  inputs=input_image,
437
+ outputs=[input_image,workbench_image,instruction_text,model_name,explain_method,sampling_size,top_k,class_predicted,exp_gallery,closest_gallery,diagram]
438
  )
439
 
440