Decompose: pc2cad#24 third concern — plane primitive polygon is the inlier hull, not the geometric extent #40

Closed
opened 2026-06-22 02:02:58 +00:00 by Mark · 1 comment
Owner
No description provided.
Author
Owner

Overseer recovery completed. The reported model_failure at ModelCheck was a stale signal; the kilo-gsd salvage state shows Research/Plan/Implement/Lint/Bugfix all completed (Bugfix burned 2 retries on a real bug — missing pytest-timeout plugin broke --timeout=120, fixed in commit c86e303).

State of the fix

  • _plane_polygon now takes method=alpha_shape|convex_hull and alpha=None (auto-derive from NN distance), defaulting to alpha_shape.
  • FitConfig gains plane_polygon_method and plane_polygon_alpha.
  • Three gate tests added in commit 6b49704:
    • test_alpha_shape_plane_polygon — L-shape inliers produce an alpha polygon strictly smaller than the convex-hull area, within 20% of true L area (64.0).
    • test_convex_hull_plane_polygon_backward — method=convex_hull matches ConvexHull area to 1e-6.
    • test_alpha_shape_fallback_to_convex_hull — degenerate / sparse inputs fall back to a valid convex-hull polygon instead of None.
  • Full suite: 22 passed, 3 skipped (FreeCAD absent — expected) in 68s.

Backward compatibility

Set FitConfig.plane_polygon_method="convex_hull" to reproduce the prior convex-hull output. Primitive.params["polygon"] Nx3 ndarray contract is unchanged; trim_plane_polygons and downstream consumers need no changes.

Commits on main

  • a7a70aa — alpha-shape implementation (originally labeled #42 by the runner).
  • 4538f6e — lint fix (Set added to typing imports).
  • c86e303 — add pytest-timeout to dev deps (gates --timeout=120).
  • 6b49704 — the three gate tests.

Plan: .kilo/plans/pc2cad-40-alpha-shape-plane-polygon.md.

Overseer recovery completed. The reported ``model_failure`` at ModelCheck was a stale signal; the kilo-gsd salvage state shows Research/Plan/Implement/Lint/Bugfix all completed (Bugfix burned 2 retries on a real bug — missing ``pytest-timeout`` plugin broke ``--timeout=120``, fixed in commit c86e303). **State of the fix** - ``_plane_polygon`` now takes ``method=alpha_shape|convex_hull`` and ``alpha=None`` (auto-derive from NN distance), defaulting to ``alpha_shape``. - ``FitConfig`` gains ``plane_polygon_method`` and ``plane_polygon_alpha``. - Three gate tests added in commit 6b49704: - ``test_alpha_shape_plane_polygon`` — L-shape inliers produce an alpha polygon strictly smaller than the convex-hull area, within 20% of true L area (64.0). - ``test_convex_hull_plane_polygon_backward`` — ``method=convex_hull`` matches ``ConvexHull`` area to 1e-6. - ``test_alpha_shape_fallback_to_convex_hull`` — degenerate / sparse inputs fall back to a valid convex-hull polygon instead of ``None``. - Full suite: **22 passed, 3 skipped** (FreeCAD absent — expected) in 68s. **Backward compatibility** Set ``FitConfig.plane_polygon_method="convex_hull"`` to reproduce the prior convex-hull output. ``Primitive.params["polygon"]`` Nx3 ndarray contract is unchanged; ``trim_plane_polygons`` and downstream consumers need no changes. **Commits on main** - ``a7a70aa`` — alpha-shape implementation (originally labeled #42 by the runner). - ``4538f6e`` — lint fix (Set added to typing imports). - ``c86e303`` — add ``pytest-timeout`` to dev deps (gates ``--timeout=120``). - ``6b49704`` — the three gate tests. Plan: ``.kilo/plans/pc2cad-40-alpha-shape-plane-polygon.md``.
Mark closed this issue 2026-07-08 16:35:41 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Mark/pc2cad#40
No description provided.