Pyboxs commited on
Commit
69fb1b7
·
verified ·
1 Parent(s): 7860995

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -12,7 +12,7 @@ def install_packages():
12
  # Instalar los paquetes necesarios si aún no están instalados
13
  with open(log_file, "a") as f:
14
  f.write("===== Installing Packages =====\n")
15
- subprocess.run(['pip3', 'install', '--quiet', 'jupyterlab', 'flask', 'gradio'], check=True)
16
 
17
  install_packages()
18
 
@@ -50,6 +50,9 @@ def start_jupyter():
50
 
51
  @app.route('/')
52
  def home():
 
 
 
53
  def greet(name):
54
  return f"Hello {name}!"
55
 
 
12
  # Instalar los paquetes necesarios si aún no están instalados
13
  with open(log_file, "a") as f:
14
  f.write("===== Installing Packages =====\n")
15
+ subprocess.run(['pip3', 'install', '--quiet', 'jupyterlab', 'flask', 'gradio', 'spaces'], check=True)
16
 
17
  install_packages()
18
 
 
50
 
51
  @app.route('/')
52
  def home():
53
+ import spaces
54
+
55
+ @spaces.GPU(duration=150)
56
  def greet(name):
57
  return f"Hello {name}!"
58