Verify physical route clearance and board containment

This commit is contained in:
Jan Petykiewicz 2026-11-27 14:12:40 -08:00
commit c200d0f7c1

View file

@ -24,7 +24,7 @@ The fields below appear in constructor order. Use one layout unit for coordinate
| Field | Default | Meaning |
| --- | --- | --- |
| `bounds` | Required | Board rectangle as `(xmin, ymin, xmax, ymax)`. |
| `nets` | `()` | Sequence of `NetSpec` objects with unique IDs. |
| `nets` | `()` | Sequence of `NetSpec` objects with unique IDs. Duplicate IDs raise `ValueError`. |
| `static_obstacles` | `()` | Shapely polygons that define keepouts. |
| `initial_paths` | Empty mapping | Net IDs mapped to `PathSeed` objects. |
| `clearance` | `2.0` | Required spacing between physical shapes. |
@ -42,7 +42,7 @@ The fields below appear in constructor order. Use one layout unit for coordinate
| `RoutingResult.is_valid` and `outcome` | `is_valid` is true when the outcome is `completed`. Read `outcome` to distinguish success, a failed geometry check (`colliding`), a path that stopped short (`partial`), or an empty path (`unroutable`). |
| `RoutingResult.path` | Ordered path components from the source to the last reached state. An unroutable result has an empty path. |
| `RoutingResult.reached_target` | Whether the path reached the target position and heading. With heading inference, the check uses the chosen heading. Read `is_valid` for the result of geometry verification. |
| `RoutingResult.report` | `total_length` in layout units plus static, dynamic, and self-collision counts. `out_of_bounds` records a board containment failure when checked. |
| `RoutingResult.report` | `total_length` in layout units plus static, dynamic, and self-collision counts. `out_of_bounds` indicates that physical geometry extends outside the board rectangle. |
| `RoutingResult.locked_geometry` and `as_seed()` | Physical polygons and the sequence of moves, respectively. Check validity before exporting polygons or using them as keepouts. |
| `RoutingRunResult.automatic` | In automatic mode, the selected planner, verified IDs, stage history, and any capacity or port-conflict bound. `None` for explicit modes. |
| `RoutingRunResult.topology` and `metrics` | Corridor counts and seed work when reported by the selected worker, plus work counters across the run. |