Add new tests and functionality for image processing and geometry handling

- Introduced color_image.py for preparing standalone color images for tests.
- Added hdr_image.py to create HDR textures for testing.
- Implemented test_image_depth_panorama.py to evaluate panorama topology, UVs, and depth discontinuities.
- Created test_shadeless.py to validate the opacity and HDR color endpoints of the Shadeless group.
- Developed moge3_export.py for exporting dynamic MoGe-3 backbone and ONNX graphs.
- Added material.py to inherit material slots onto generated geometry.
- Built image_depth_panorama.py to construct a quad panorama with depth separation and sampling.
This commit is contained in:
2026-09-10 14:42:17 +08:00
parent 27ca25224a
commit 489003c2cc
136 changed files with 5758 additions and 1083 deletions

View File

@@ -19,7 +19,7 @@ class GeometryArtifactsTest(ServerTestCase):
validity=validity.copy(), intrinsics=np.eye(3, dtype=np.float32),
)
output = self.storage_root / "depth.exr"
with patch.object(depth, "_write_float_exr") as write:
with patch.object(depth, "write_float_exr") as write:
depth.write_depth_texture(frame, output, alpha=alpha)
packed = write.call_args.args[0]
np.testing.assert_allclose(packed[..., 3], [[0.6, 0, 0, 1]])
@@ -246,10 +246,10 @@ class GeometryArtifactsTest(ServerTestCase):
texture = importlib.import_module("server.geometry.depth_texture")
with (
patch.object(artifacts.moge2, "infer", return_value=[frame]) as infer,
patch.object(texture, "_write_float_exr", wraps=texture._write_float_exr) as write,
patch.object(artifacts.moge, "infer", return_value=[frame]) as infer,
patch.object(texture, "write_float_exr", wraps=texture.write_float_exr) as write,
):
result = artifacts.generate_moge2_artifacts(
result = artifacts.generate_moge_artifacts(
context,
{"max_input_size": 2048},
input_path,
@@ -284,7 +284,7 @@ class GeometryArtifactsTest(ServerTestCase):
normal = context.directory / "object-normal.png"
with patch.object(
job,
"generate_moge2_artifacts",
"generate_moge_artifacts",
return_value={
"depth": depth_texture,
"depth_metadata": metadata,