huzey commited on
Commit
8a63e65
1 Parent(s): 345e38b

handle gpu quota

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -1001,8 +1001,8 @@ def run_fn(
1001
  info2 = 'Or try use the Python package that powers this app: <a style="white-space: nowrap;text-underline-offset: 2px;color: var(--body-text-color)" href="https://ncut-pytorch.readthedocs.io/en/latest/">ncut-pytorch</a>'
1002
  info = info1 + info2
1003
 
1004
- message = "<b>HuggingFace: </b></br>" + e.message + "</br></br>---------</br>" + "<b>This Demo Developer: </b></br>" + info
1005
- raise gr.Error(message, duration=60)
1006
 
1007
 
1008
 
 
1001
  info2 = 'Or try use the Python package that powers this app: <a style="white-space: nowrap;text-underline-offset: 2px;color: var(--body-text-color)" href="https://ncut-pytorch.readthedocs.io/en/latest/">ncut-pytorch</a>'
1002
  info = info1 + info2
1003
 
1004
+ message = "<b>HuggingFace: </b></br>" + e.message + "</br></br>---------</br>" + "<b>`ncut-pytorch` Developer: </b></br>" + info
1005
+ raise gr.Error(message, duration=0)
1006
 
1007
 
1008