DurgaDeepak commited on
Commit
b5d6e67
·
verified ·
1 Parent(s): a594391

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -2
app.py CHANGED
@@ -24,6 +24,7 @@ import time
24
  import timeout_decorator
25
  import socket
26
  import ipaddress
 
27
 
28
  # Setup logging
29
  logging.basicConfig(level=logging.INFO, format='%(asctime)s - %(levelname)s - %(message)s')
@@ -460,5 +461,8 @@ with gr.Blocks() as demo:
460
  )
461
 
462
  # Launch the Gradio App
463
- if __name__ == "__main__":
464
- demo.launch()
 
 
 
 
24
  import timeout_decorator
25
  import socket
26
  import ipaddress
27
+ from huggingface_hub import spaces
28
 
29
  # Setup logging
30
  logging.basicConfig(level=logging.INFO, format='%(asctime)s - %(levelname)s - %(message)s')
 
461
  )
462
 
463
  # Launch the Gradio App
464
+ @spaces.GPU
465
+ def launch_app():
466
+ demo.launch()
467
+
468
+ launch_app()