Spaces:
Running
on
Zero
Running
on
Zero
Update gradio_app.py
Browse files- gradio_app.py +3 -1
gradio_app.py
CHANGED
@@ -1,5 +1,6 @@
|
|
1 |
import os
|
2 |
import gradio as gr
|
|
|
3 |
import torch
|
4 |
import gc
|
5 |
from huggingface_hub import snapshot_download
|
@@ -83,7 +84,8 @@ def cuda_memory_cleanup():
|
|
83 |
torch.cuda.empty_cache()
|
84 |
torch.cuda.ipc_collect()
|
85 |
gc.collect()
|
86 |
-
|
|
|
87 |
def infer(frame1_path, frame2_path):
|
88 |
|
89 |
seed = 42
|
|
|
1 |
import os
|
2 |
import gradio as gr
|
3 |
+
import spaces
|
4 |
import torch
|
5 |
import gc
|
6 |
from huggingface_hub import snapshot_download
|
|
|
84 |
torch.cuda.empty_cache()
|
85 |
torch.cuda.ipc_collect()
|
86 |
gc.collect()
|
87 |
+
|
88 |
+
@spaces.GPU()
|
89 |
def infer(frame1_path, frame2_path):
|
90 |
|
91 |
seed = 42
|