Files
DCCONSTRUCTIONS 69dc566665 feat(research): preserve urban geometry pipelines and qualification suites
Preserve offline geometry, marking, replay and evaluation pipelines with source manifests and synthetic tests. Research qualification does not activate these methods as production navigation.
2026-10-29 09:10:00 +03:00

22 lines
845 B
Python

"""Preserve measured coordinates when there is no geometry to subtract.
Fitting another float32 rectangle is not an identity operation in world
coordinates. It can shift sampling across a pixel/threshold boundary even
when no existing paint occupies the proposed body. Actual fragmentation
still uses the original exclusion distance and minimum-section policy.
"""
from beta_profiles import describe
from marking_rules import POLICY
from marking_rules import missing_parts as fragmented_parts
def missing_parts(polygon, existing):
description = describe(polygon)
if description is None:
return []
occupied = polygon.intersection(existing.buffer(0.10))
if occupied.is_empty:
return [polygon] if description["length"] >= POLICY["min_continuous_section_m"] else []
return fragmented_parts(polygon, existing)