Refactor depth reference handling and cleanup
- Unified reference depth calculation to use a single implementation in common/depth.py. - Removed server-side reference depth computation and adjusted depth.json to only include image_size and intrinsics. - Updated depth texture handling to ignore transparent, invalid, and non-positive pixels when calculating reference depth. - Changed reference depth calculation to use the 95th percentile of valid depth values. - Adjusted depth direction fitting to return a flat direction when no samples are available. - Removed cleanup threshold parameters from Cutout and related nodes, simplifying the interface. - Updated tests to verify new reference depth logic and ensure compatibility with existing functionality.
This commit is contained in:
@@ -8,7 +8,7 @@ import numpy as np
|
||||
from tests.support.nodes import CUTOUT_BUILDERS
|
||||
|
||||
|
||||
def surface(*, step=6.0, size=1.0, resolution=2, wrapper=False):
|
||||
def surface(*, step=6.0, size=1.0, resolution=2):
|
||||
bpy.ops.wm.read_factory_settings(use_empty=True)
|
||||
group = CUTOUT_BUILDERS["DEPTH_SOLID"]()
|
||||
# Two columns with a complete depth jump along their common boundary.
|
||||
@@ -70,8 +70,6 @@ def surface(*, step=6.0, size=1.0, resolution=2, wrapper=False):
|
||||
("Boundary Smooth", 0),
|
||||
):
|
||||
set_value(name, value)
|
||||
if wrapper:
|
||||
set_value("Cleanup Threshold", 0.0)
|
||||
return obj, set_value
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user