openfree commited on
Commit
27e4a3f
ยท
verified ยท
1 Parent(s): 1c8634a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -2
app.py CHANGED
@@ -1,5 +1,3 @@
1
- import os
2
- os.environ["SPACES_ZERO_GPU"] = "1"
3
  import gradio as gr
4
  import numpy as np
5
  from PIL import Image, ImageDraw
@@ -1138,4 +1136,11 @@ with demo:
1138
  outputs=[stream_image, output_bg_video, time_textbox]
1139
  )
1140
 
 
 
 
 
 
 
 
1141
  demo.launch()
 
 
 
1
  import gradio as gr
2
  import numpy as np
3
  from PIL import Image, ImageDraw
 
1136
  outputs=[stream_image, output_bg_video, time_textbox]
1137
  )
1138
 
1139
+ # GPU ์ดˆ๊ธฐํ™” (Spaces ํ™˜๊ฒฝ์—์„œ ํ•„์š”)
1140
+ try:
1141
+ if torch.cuda.is_available():
1142
+ dummy_gpu_init()
1143
+ except:
1144
+ pass
1145
+
1146
  demo.launch()