Spaces:
Running
on
Zero
Running
on
Zero
add gpu
Browse files
gradio_app/gradio_3dgen.py
CHANGED
@@ -1,3 +1,4 @@
|
|
|
|
1 |
import os
|
2 |
import gradio as gr
|
3 |
from PIL import Image
|
@@ -9,6 +10,7 @@ from scripts.refine_lr_to_sr import run_sr_fast
|
|
9 |
from scripts.utils import save_glb_and_video
|
10 |
from scripts.multiview_inference import geo_reconstruct
|
11 |
|
|
|
12 |
def generate3dv2(preview_img, input_processing, seed, render_video=True, do_refine=True, expansion_weight=0.1, init_type="std"):
|
13 |
if preview_img is None:
|
14 |
raise gr.Error("preview_img is none")
|
|
|
1 |
+
import spaces
|
2 |
import os
|
3 |
import gradio as gr
|
4 |
from PIL import Image
|
|
|
10 |
from scripts.utils import save_glb_and_video
|
11 |
from scripts.multiview_inference import geo_reconstruct
|
12 |
|
13 |
+
@spaces.GPU
|
14 |
def generate3dv2(preview_img, input_processing, seed, render_video=True, do_refine=True, expansion_weight=0.1, init_type="std"):
|
15 |
if preview_img is None:
|
16 |
raise gr.Error("preview_img is none")
|