faneggg commited on
Commit
273073c
·
1 Parent(s): e551f0f

add example

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -59,7 +59,7 @@ def get_dust3r_args_parser():
59
  return parser
60
 
61
 
62
- @spaces.GPU(duration=250)
63
  def run_dust3r(inputfiles, input_path=None):
64
 
65
  if input_path is not None:
@@ -154,7 +154,7 @@ def run_dust3r(inputfiles, input_path=None):
154
 
155
  return outfile, feat_image_path, opt, None, None
156
 
157
- @spaces.GPU(duration=250)
158
  def run_feat2gs(opt, niter=2000):
159
 
160
  if opt is None:
@@ -214,7 +214,7 @@ def run_feat2gs(opt, niter=2000):
214
  except Exception as e:
215
  raise gr.Error(f"Step 2 failed: {str(e)}")
216
 
217
- @spaces.GPU(duration=250)
218
  def run_render(opt, args, cam_traj='ellipse'):
219
  if opt is None or args is None:
220
  raise gr.Error("Please run Steps 1 and 2 first!")
@@ -249,7 +249,7 @@ def run_render(opt, args, cam_traj='ellipse'):
249
  except Exception as e:
250
  raise gr.Error(f"Step 3 failed: {str(e)}")
251
 
252
- @spaces.GPU(duration=250)
253
  def process_example(inputfiles, input_path):
254
  dust3r_model, feat_image, dust3r_state, _, _ = run_dust3r(inputfiles, input_path=input_path)
255
 
 
59
  return parser
60
 
61
 
62
+ @spaces.GPU(duration=150)
63
  def run_dust3r(inputfiles, input_path=None):
64
 
65
  if input_path is not None:
 
154
 
155
  return outfile, feat_image_path, opt, None, None
156
 
157
+ @spaces.GPU(duration=150)
158
  def run_feat2gs(opt, niter=2000):
159
 
160
  if opt is None:
 
214
  except Exception as e:
215
  raise gr.Error(f"Step 2 failed: {str(e)}")
216
 
217
+ @spaces.GPU(duration=150)
218
  def run_render(opt, args, cam_traj='ellipse'):
219
  if opt is None or args is None:
220
  raise gr.Error("Please run Steps 1 and 2 first!")
 
249
  except Exception as e:
250
  raise gr.Error(f"Step 3 failed: {str(e)}")
251
 
252
+ @spaces.GPU(duration=150)
253
  def process_example(inputfiles, input_path):
254
  dust3r_model, feat_image, dust3r_state, _, _ = run_dust3r(inputfiles, input_path=input_path)
255