Reverent commited on
Commit
f8bf3fe
·
1 Parent(s): 46a75dc

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -20,8 +20,8 @@ def warmer():
20
  end_time = time.time()
21
  duration = end_time - start_time
22
  print("Time elapsed for Pygmalion model : ", duration)
23
- if duration > 120: # Check if duration to generate tokens exceeds 2 minutes
24
- restart()
25
 
26
  start_time = time.time()
27
  text_output_2,image_output_2 = client.predict(
@@ -58,6 +58,7 @@ def restart():
58
  except Exception as e:
59
  print("NO INTERNET")
60
  print(str(e))
 
61
 
62
  def placeholder(dummy):
63
  return "lol"
 
20
  end_time = time.time()
21
  duration = end_time - start_time
22
  print("Time elapsed for Pygmalion model : ", duration)
23
+ #if duration > 120: # Check if duration to generate tokens exceeds 2 minutes
24
+ restart()
25
 
26
  start_time = time.time()
27
  text_output_2,image_output_2 = client.predict(
 
58
  except Exception as e:
59
  print("NO INTERNET")
60
  print(str(e))
61
+ return
62
 
63
  def placeholder(dummy):
64
  return "lol"