huzey commited on
Commit
ad8baf1
1 Parent(s): 94f943d

handle gpu quota

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -995,11 +995,11 @@ def run_fn(
995
 
996
  except gr.Error as e:
997
  print(e)
998
- gr.Error(e.message)
999
  if USE_HUGGINGFACE_ZEROGPU:
1000
  spaces.zero.gradio.HTMLError(e.message)
1001
- gr.Error("Error: " + e.message)
1002
- gr.Error("Error: " + str(e))
1003
  gr.Info("Running out of HuggingFace GPU Quota? Try this demo hosted at UPenn.</br></br> https://ncut-pytorch.readthedocs.io/en/latest/demo/", duration=20)
1004
 
1005
 
 
995
 
996
  except gr.Error as e:
997
  print(e)
998
+ gr.Warning(e.message)
999
  if USE_HUGGINGFACE_ZEROGPU:
1000
  spaces.zero.gradio.HTMLError(e.message)
1001
+ gr.Warning("Error: " + e.message)
1002
+ gr.Warning("Error: " + str(e))
1003
  gr.Info("Running out of HuggingFace GPU Quota? Try this demo hosted at UPenn.</br></br> https://ncut-pytorch.readthedocs.io/en/latest/demo/", duration=20)
1004
 
1005