Spaces:
Running
on
Zero
Running
on
Zero
Commit
·
4ccfc8b
1
Parent(s):
9a947d8
debug print
Browse files- .gitignore +1 -0
- app.py +5 -1
- src/__pycache__/__init__.cpython-311.pyc +0 -0
- src/models/__pycache__/__init__.cpython-311.pyc +0 -0
- src/models/__pycache__/lrm_mesh.cpython-311.pyc +0 -0
- src/models/decoder/__pycache__/__init__.cpython-311.pyc +0 -0
- src/models/decoder/__pycache__/transformer.cpython-311.pyc +0 -0
- src/models/encoder/__pycache__/__init__.cpython-311.pyc +0 -0
- src/models/encoder/__pycache__/dino.cpython-311.pyc +0 -0
- src/models/encoder/__pycache__/dino_wrapper.cpython-311.pyc +0 -0
- src/models/geometry/__pycache__/__init__.cpython-311.pyc +0 -0
- src/models/geometry/camera/__pycache__/__init__.cpython-311.pyc +0 -0
- src/models/geometry/camera/__pycache__/perspective_camera.cpython-311.pyc +0 -0
- src/models/geometry/render/__pycache__/__init__.cpython-311.pyc +0 -0
- src/models/geometry/render/__pycache__/neural_render.cpython-311.pyc +0 -0
- src/models/geometry/rep_3d/__pycache__/__init__.cpython-311.pyc +0 -0
- src/models/geometry/rep_3d/__pycache__/dmtet.cpython-311.pyc +0 -0
- src/models/geometry/rep_3d/__pycache__/dmtet_utils.cpython-311.pyc +0 -0
- src/models/geometry/rep_3d/__pycache__/flexicubes.cpython-311.pyc +0 -0
- src/models/geometry/rep_3d/__pycache__/flexicubes_geometry.cpython-311.pyc +0 -0
- src/models/geometry/rep_3d/__pycache__/tables.cpython-311.pyc +0 -0
- src/models/renderer/__pycache__/__init__.cpython-311.pyc +0 -0
- src/models/renderer/__pycache__/synthesizer_mesh.cpython-311.pyc +0 -0
- src/models/renderer/utils/__pycache__/__init__.cpython-311.pyc +0 -0
- src/models/renderer/utils/__pycache__/math_utils.cpython-311.pyc +0 -0
- src/models/renderer/utils/__pycache__/ray_marcher.cpython-311.pyc +0 -0
- src/models/renderer/utils/__pycache__/renderer.cpython-311.pyc +0 -0
- src/utils/__pycache__/__init__.cpython-311.pyc +0 -0
- src/utils/__pycache__/camera_util.cpython-311.pyc +0 -0
- src/utils/__pycache__/infer_util.cpython-311.pyc +0 -0
- src/utils/__pycache__/mesh_util.cpython-311.pyc +0 -0
- src/utils/__pycache__/train_util.cpython-311.pyc +0 -0
.gitignore
CHANGED
|
@@ -1,2 +1,3 @@
|
|
|
|
|
| 1 |
*.nix
|
| 2 |
venv/
|
|
|
|
| 1 |
+
__pycache__/
|
| 2 |
*.nix
|
| 3 |
venv/
|
app.py
CHANGED
|
@@ -11,6 +11,7 @@ from pytorch_lightning import seed_everything
|
|
| 11 |
from omegaconf import OmegaConf
|
| 12 |
from einops import rearrange, repeat
|
| 13 |
from tqdm import tqdm
|
|
|
|
| 14 |
from typing import Any
|
| 15 |
from diffusers import DiffusionPipeline, EulerAncestralDiscreteScheduler
|
| 16 |
import rerun as rr
|
|
@@ -165,6 +166,8 @@ def pipeline_callback(pipe: Any, step_index: int, timestep: float, callback_kwar
|
|
| 165 |
@spaces.GPU
|
| 166 |
def generate_mvs(input_image, sample_steps, sample_seed):
|
| 167 |
|
|
|
|
|
|
|
| 168 |
seed_everything(sample_seed)
|
| 169 |
|
| 170 |
return pipeline(
|
|
@@ -273,12 +276,13 @@ def log_to_rr(input_image, do_remove_background, sample_steps, sample_seed):
|
|
| 273 |
|
| 274 |
yield stream.read()
|
| 275 |
|
|
|
|
| 276 |
z123_out = generate_mvs(input_image, sample_steps, sample_seed)
|
| 277 |
print(z123_out)
|
| 278 |
for image in z123_out.images:
|
| 279 |
rr.log("z123image", rr.Image(image))
|
| 280 |
yield stream.read()
|
| 281 |
-
|
| 282 |
pass
|
| 283 |
|
| 284 |
_HEADER_ = '''
|
|
|
|
| 11 |
from omegaconf import OmegaConf
|
| 12 |
from einops import rearrange, repeat
|
| 13 |
from tqdm import tqdm
|
| 14 |
+
import threading
|
| 15 |
from typing import Any
|
| 16 |
from diffusers import DiffusionPipeline, EulerAncestralDiscreteScheduler
|
| 17 |
import rerun as rr
|
|
|
|
| 166 |
@spaces.GPU
|
| 167 |
def generate_mvs(input_image, sample_steps, sample_seed):
|
| 168 |
|
| 169 |
+
print(threading.get_ident())
|
| 170 |
+
|
| 171 |
seed_everything(sample_seed)
|
| 172 |
|
| 173 |
return pipeline(
|
|
|
|
| 276 |
|
| 277 |
yield stream.read()
|
| 278 |
|
| 279 |
+
print(threading.get_ident())
|
| 280 |
z123_out = generate_mvs(input_image, sample_steps, sample_seed)
|
| 281 |
print(z123_out)
|
| 282 |
for image in z123_out.images:
|
| 283 |
rr.log("z123image", rr.Image(image))
|
| 284 |
yield stream.read()
|
| 285 |
+
yield stream.read()
|
| 286 |
pass
|
| 287 |
|
| 288 |
_HEADER_ = '''
|
src/__pycache__/__init__.cpython-311.pyc
DELETED
|
Binary file (157 Bytes)
|
|
|
src/models/__pycache__/__init__.cpython-311.pyc
DELETED
|
Binary file (164 Bytes)
|
|
|
src/models/__pycache__/lrm_mesh.cpython-311.pyc
DELETED
|
Binary file (21.8 kB)
|
|
|
src/models/decoder/__pycache__/__init__.cpython-311.pyc
DELETED
|
Binary file (172 Bytes)
|
|
|
src/models/decoder/__pycache__/transformer.cpython-311.pyc
DELETED
|
Binary file (6.27 kB)
|
|
|
src/models/encoder/__pycache__/__init__.cpython-311.pyc
DELETED
|
Binary file (172 Bytes)
|
|
|
src/models/encoder/__pycache__/dino.cpython-311.pyc
DELETED
|
Binary file (33.1 kB)
|
|
|
src/models/encoder/__pycache__/dino_wrapper.cpython-311.pyc
DELETED
|
Binary file (4.44 kB)
|
|
|
src/models/geometry/__pycache__/__init__.cpython-311.pyc
DELETED
|
Binary file (173 Bytes)
|
|
|
src/models/geometry/camera/__pycache__/__init__.cpython-311.pyc
DELETED
|
Binary file (813 Bytes)
|
|
|
src/models/geometry/camera/__pycache__/perspective_camera.cpython-311.pyc
DELETED
|
Binary file (2.36 kB)
|
|
|
src/models/geometry/render/__pycache__/__init__.cpython-311.pyc
DELETED
|
Binary file (692 Bytes)
|
|
|
src/models/geometry/render/__pycache__/neural_render.cpython-311.pyc
DELETED
|
Binary file (7.32 kB)
|
|
|
src/models/geometry/rep_3d/__pycache__/__init__.cpython-311.pyc
DELETED
|
Binary file (725 Bytes)
|
|
|
src/models/geometry/rep_3d/__pycache__/dmtet.cpython-311.pyc
DELETED
|
Binary file (31.9 kB)
|
|
|
src/models/geometry/rep_3d/__pycache__/dmtet_utils.cpython-311.pyc
DELETED
|
Binary file (1.06 kB)
|
|
|
src/models/geometry/rep_3d/__pycache__/flexicubes.cpython-311.pyc
DELETED
|
Binary file (43.9 kB)
|
|
|
src/models/geometry/rep_3d/__pycache__/flexicubes_geometry.cpython-311.pyc
DELETED
|
Binary file (6.93 kB)
|
|
|
src/models/geometry/rep_3d/__pycache__/tables.cpython-311.pyc
DELETED
|
Binary file (41.1 kB)
|
|
|
src/models/renderer/__pycache__/__init__.cpython-311.pyc
DELETED
|
Binary file (173 Bytes)
|
|
|
src/models/renderer/__pycache__/synthesizer_mesh.cpython-311.pyc
DELETED
|
Binary file (8.47 kB)
|
|
|
src/models/renderer/utils/__pycache__/__init__.cpython-311.pyc
DELETED
|
Binary file (179 Bytes)
|
|
|
src/models/renderer/utils/__pycache__/math_utils.cpython-311.pyc
DELETED
|
Binary file (5.3 kB)
|
|
|
src/models/renderer/utils/__pycache__/ray_marcher.cpython-311.pyc
DELETED
|
Binary file (4.03 kB)
|
|
|
src/models/renderer/utils/__pycache__/renderer.cpython-311.pyc
DELETED
|
Binary file (19.8 kB)
|
|
|
src/utils/__pycache__/__init__.cpython-311.pyc
DELETED
|
Binary file (163 Bytes)
|
|
|
src/utils/__pycache__/camera_util.cpython-311.pyc
DELETED
|
Binary file (7.33 kB)
|
|
|
src/utils/__pycache__/infer_util.cpython-311.pyc
DELETED
|
Binary file (4.87 kB)
|
|
|
src/utils/__pycache__/mesh_util.cpython-311.pyc
DELETED
|
Binary file (13.9 kB)
|
|
|
src/utils/__pycache__/train_util.cpython-311.pyc
DELETED
|
Binary file (2 kB)
|
|
|