multimodalart HF staff commited on
Commit
47e464e
2 Parent(s): 6c25e6b 9b78871

Merge branch 'main' of https://huggingface.co/spaces/multimodalart/dreambooth-training

Browse files
Files changed (1) hide show
  1. app.py +5 -1
app.py CHANGED
@@ -296,11 +296,15 @@ def check_status(top_description):
296
  else:
297
  update_top_tag = gr.update(value=top_description)
298
  show_outputs = False
 
 
 
 
299
  return [
300
  update_top_tag, #top_description
301
  gr.update(visible=show_outputs), #try_your_model
302
  gr.update(visible=show_outputs), #push_to_hub
303
- gr.update(visible=show_outputs, value=["diffusers_model.zip"]), #result
304
  gr.update(visible=show_outputs), #convert_button
305
  ]
306
 
 
296
  else:
297
  update_top_tag = gr.update(value=top_description)
298
  show_outputs = False
299
+ if os.path.exists("diffusers_model.zip"):
300
+ update_files_tag = gr.update(visible=show_outputs, value=["diffusers_model.zip"])
301
+ else:
302
+ update_files_tag = gr.update(visible=show_outputs)
303
  return [
304
  update_top_tag, #top_description
305
  gr.update(visible=show_outputs), #try_your_model
306
  gr.update(visible=show_outputs), #push_to_hub
307
+ update_files_tag, #result
308
  gr.update(visible=show_outputs), #convert_button
309
  ]
310