Spaces:
Sleeping
Sleeping
Commit
·
3143ef7
1
Parent(s):
c17a338
chore: update duration on zerogpu decorators to max-120sec
Browse filesSigned-off-by: Suvaditya Mukherjee <suvadityamuk@gmail.com>
- demos/pipeline_fn.py +5 -5
- demos/run_gradio_demo.py +1 -1
demos/pipeline_fn.py
CHANGED
|
@@ -50,7 +50,7 @@ def file_sha256(path: str, chunk_size: int = 1 << 20) -> str:
|
|
| 50 |
h.update(chunk)
|
| 51 |
return h.hexdigest()
|
| 52 |
|
| 53 |
-
@spaces.GPU(
|
| 54 |
def init_partfield(obj_path):
|
| 55 |
torch.manual_seed(0)
|
| 56 |
random.seed(0)
|
|
@@ -73,7 +73,7 @@ def init_partfield(obj_path):
|
|
| 73 |
partfield_model.eval()
|
| 74 |
return partfield_model
|
| 75 |
|
| 76 |
-
@spaces.GPU
|
| 77 |
def partfield_pipeline_predict(obj_path, output_dir):
|
| 78 |
|
| 79 |
log.info("Extracting PartField feature planes...")
|
|
@@ -118,7 +118,7 @@ class GuideFlow3dPipeline:
|
|
| 118 |
self.cfg = config
|
| 119 |
return self
|
| 120 |
|
| 121 |
-
@spaces.GPU(duration=360)
|
| 122 |
def preprocess(
|
| 123 |
self,
|
| 124 |
structure_mesh: str,
|
|
@@ -229,7 +229,7 @@ class GuideFlow3dPipeline:
|
|
| 229 |
"voxel_dir": voxel_dir
|
| 230 |
}
|
| 231 |
|
| 232 |
-
@spaces.GPU(duration=
|
| 233 |
def run_appearance(
|
| 234 |
self,
|
| 235 |
structure_mesh: str,
|
|
@@ -413,7 +413,7 @@ class GuideFlow3dPipeline:
|
|
| 413 |
return None, None
|
| 414 |
return output_mesh_path, output_video_path
|
| 415 |
|
| 416 |
-
@spaces.GPU(duration=
|
| 417 |
def run_self_similarity(
|
| 418 |
self,
|
| 419 |
structure_mesh: str,
|
|
|
|
| 50 |
h.update(chunk)
|
| 51 |
return h.hexdigest()
|
| 52 |
|
| 53 |
+
# @spaces.GPU()
|
| 54 |
def init_partfield(obj_path):
|
| 55 |
torch.manual_seed(0)
|
| 56 |
random.seed(0)
|
|
|
|
| 73 |
partfield_model.eval()
|
| 74 |
return partfield_model
|
| 75 |
|
| 76 |
+
@spaces.GPU
|
| 77 |
def partfield_pipeline_predict(obj_path, output_dir):
|
| 78 |
|
| 79 |
log.info("Extracting PartField feature planes...")
|
|
|
|
| 118 |
self.cfg = config
|
| 119 |
return self
|
| 120 |
|
| 121 |
+
# @spaces.GPU(duration=360)
|
| 122 |
def preprocess(
|
| 123 |
self,
|
| 124 |
structure_mesh: str,
|
|
|
|
| 229 |
"voxel_dir": voxel_dir
|
| 230 |
}
|
| 231 |
|
| 232 |
+
@spaces.GPU(duration=120)
|
| 233 |
def run_appearance(
|
| 234 |
self,
|
| 235 |
structure_mesh: str,
|
|
|
|
| 413 |
return None, None
|
| 414 |
return output_mesh_path, output_video_path
|
| 415 |
|
| 416 |
+
@spaces.GPU(duration=120)
|
| 417 |
def run_self_similarity(
|
| 418 |
self,
|
| 419 |
structure_mesh: str,
|
demos/run_gradio_demo.py
CHANGED
|
@@ -122,7 +122,7 @@ def _ensure_glb_path(result: Union[str, bytes, os.PathLike]) -> str:
|
|
| 122 |
tmp.close()
|
| 123 |
return tmp.name
|
| 124 |
|
| 125 |
-
@spaces.GPU(duration=360)
|
| 126 |
def on_run(
|
| 127 |
guidance_mode_state: str,
|
| 128 |
app_struct_mesh: Optional[str],
|
|
|
|
| 122 |
tmp.close()
|
| 123 |
return tmp.name
|
| 124 |
|
| 125 |
+
# @spaces.GPU(duration=360)
|
| 126 |
def on_run(
|
| 127 |
guidance_mode_state: str,
|
| 128 |
app_struct_mesh: Optional[str],
|