Tie routing documentation to user and developer workflows
This commit is contained in:
parent
2d77877fff
commit
2c7a7ea90a
11 changed files with 309 additions and 148 deletions
|
|
@ -1,32 +1,32 @@
|
|||
# Router architecture
|
||||
|
||||
An explicit routing mode runs one worker. Automatic routing can run several and compare their results. Each worker receives its own obstacles, locks, and seed hints. To trace how a worker gets its inputs and options, start at [`route_once()`](../inire/router/_stack.py).
|
||||
An explicit routing mode runs one worker. Automatic routing can run several and compare their results. To follow how the worker gets its obstacles, locks, and seed hints, start at [`route_once()`](../inire/router/_stack.py#L71).
|
||||
|
||||
## Automatic routing
|
||||
|
||||

|
||||
|
||||
The diagram shows the usual sequence for arc bends. A verified layout can reach the routing target early. When attempts run out, selection keeps the best verified coverage found. Custom physical bends, polygonal proxies, or missing constrained triangulation take a lattice-only path.
|
||||
Follow the left column down while the run is below its coverage target. Move right to selection when a verified candidate reaches that target or the attempts run out. Custom physical bends, polygonal proxies, and layouts routed without constrained triangulation take a lattice-only path.
|
||||
|
||||
1. **Set the coverage target.** Each disjoint pair of incompatible fixed ports rules out one route. At supported rectangular cuts, compute how many paths of the narrowest width can fit through the openings. The resulting upper bound can justify stopping with fewer routes than requested.
|
||||
1. **Set the coverage target.** Each disjoint pair of incompatible fixed ports rules out one route. At supported rectangular cuts, compute how many paths of the narrowest width can fit through the openings. To change which cuts can establish an upper bound, start with [`cut_capacity()`](../inire/router/_capacity.py#L27).
|
||||
2. **Try constructive planners.** Bundles assign ordered tracks through barriers. Column schedules place turns between openings. Compact planners fit short connections between constrained ports. Each produces seeds whose physical geometry the worker checks.
|
||||
3. **Start with a small search budget.** Lock verified straight links and search for the remaining nets. A different lock order or a small unlocked probe can free room for a turn. Promising guide and column attempts can run first.
|
||||
4. **Decide what to keep fixed.** If the remaining ports are connected, route around the locked geometry. If the locks disconnect them, pass the incumbents as movable seeds. A joint retry can assign different lanes through a shared portal. If recovery stalls, seed and lattice attempts can search the whole layout, with a final lattice retry up to the caller's ceiling.
|
||||
5. **Select a verified layout.** Prefer greater coverage and compare cost on identical verified net sets. A complete locked layout or an improving joint retry must pass its whole-layout check before selection. A refined candidate must preserve the verified net set.
|
||||
5. **Select a verified layout.** Prefer greater coverage and compare cost on identical verified net sets. A complete locked layout or an improving joint retry must pass its whole-layout check before selection. To see how a refined candidate must preserve the verified net set, follow [the refinement handoff](../inire/router/_automatic.py#L581).
|
||||
|
||||
The near-port attempt uses up to 100 nodes per search and two congestion iterations with the arc proxy. Alternate proxies use the configured iteration limit because a later shallow iteration can find a cheaper path. Wider lookahead uses up to 500 nodes per search and the configured iteration limit. Both attempts respect smaller caller limits. Follow those budget decisions in the [automatic routing sequence](../inire/router/_automatic.py).
|
||||
The near-port attempt uses up to 100 nodes per search and two congestion iterations with the arc proxy. Alternate proxies use the configured iteration limit because a later shallow iteration can find a cheaper path. Wider lookahead uses up to 500 nodes per search and the configured iteration limit. Follow the caps and early exits in [the initial search trials](../inire/router/_automatic.py#L480).
|
||||
|
||||
### Example of a poor lock
|
||||
|
||||
1. A straight trunk in `stress-retry-straight-decoy` fits on its own. Once locked, it divides the board and blocks two perpendicular nets.
|
||||
2. The probe can keep the branches and lower rail. A four-turn dogleg completes the trunk around them before wider search.
|
||||
3. If you change lock ordering or acceptance, rerun the case and check that all four nets still verify together. For the command and profile choices, see [Run a benchmark](benchmarks.md#run-a-benchmark).
|
||||
3. If you change lock ordering or acceptance, run the [single-case benchmark command](benchmarks.md#run-a-benchmark) with `--case stress-retry-straight-decoy`. Check that all four nets still verify and compare which stage finishes the trunk.
|
||||
|
||||
## Detailed search and congestion
|
||||
|
||||
- **Build and admit moves.** Weighted A* searches snapped positions and headings. Rays, visible corners, and corridor waypoints propose straight endpoints. Admission checks clearance, cost, and state dominance. To understand which endpoints a net can reach within the same node budget, start with [move generation](../inire/router/_astar_moves.py).
|
||||
|
||||
- **Recheck the installed set.** The driver raises the overlap penalty when successive routes collide. After an iteration it verifies the installed paths, since a later route can collide with one completed earlier. It ranks snapshots by completed nets, then by conflicts and dynamic collisions. To investigate which nets reroute next, read the [congestion policy](../inire/router/_congestion_policy.py).
|
||||
- **Recheck the installed set.** The driver raises the overlap penalty when successive routes collide. After an iteration it verifies the installed paths, since a later route can collide with one completed earlier. It ranks snapshots by completed nets, then by conflicts and dynamic collisions. To see when it reroutes just the conflicting nets, read [`next_reroute_net_ids()`](../inire/router/_congestion_policy.py#L93).
|
||||
|
||||
- **Repair a small conflict set.** The driver restores its best iteration and verifies it once for diagnostics and target selection. Pair-local search keeps the geometry outside an eligible pair fixed and can try either routing order. The driver checks replacements in the live world. To compare the restored set with the repaired paths, [follow a late conflict](routing-diagnostics.md#follow-a-late-conflict-into-pair-local-repair).
|
||||
|
||||
|
|
|
|||
|
|
@ -1,18 +1,20 @@
|
|||
# Benchmark fixtures
|
||||
|
||||
The checked-in fixtures let you repeat comparisons offline. To find a board for the behavior you want to measure, use the [benchmark case guide](benchmarks.md#choose-a-case). To inspect the case groups and the options used for each profile, open the [corpus registry](../inire/tests/routing_corpus.py).
|
||||
Start with a board that exercises the behavior you want to measure. Use the [case guide](benchmarks.md#choose-a-case) to select it or the [corpus registry](../inire/tests/routing_corpus.py) to find its groups and effective profile settings.
|
||||
|
||||
## Automatic nine-net Terminal-Bench routing
|
||||
|
||||
Use `terminal-bench-point-terminals` to test heading inference and ordered tracks through shared openings. The bundle planner reserves room for the outer return and bend tangencies. Use `terminal-bench` to test automatic routing with fixed headings.
|
||||
|
||||
Export the nine routes from the unseeded point-terminal input.
|
||||
To measure the bundle planner on the unseeded point-terminal input, export its routes.
|
||||
|
||||
```sh
|
||||
python -m scripts.route_terminal_bench --output /tmp/inire-terminal-bench.json
|
||||
```
|
||||
|
||||
The unseeded export passed the checker's cost and geometry requirements in the [pinned Terminal-Bench task](https://github.com/harbor-framework/terminal-bench/tree/249d125b59c0a5352d9e132195cfead6d81446be/tasks/photonic-waveguide-routing). To check feasibility or compare lane assignments, use the CLI flags `--reference-lane-plan` and `--single-bottom-track` to replay the [authored lane plans](../inire/tests/terminal_bench_lane_plan.py).
|
||||
The export should report nine verified routes. The upstream input is board 1 in the [pinned layout specification](https://raw.githubusercontent.com/harbor-framework/terminal-bench/249d125b59c0a5352d9e132195cfead6d81446be/tasks/photonic-waveguide-routing/environment/layout_spec.json). The unseeded export passed the pinned checker's cost and geometry requirements.
|
||||
|
||||
To verify a known layout or compare lane assignments, pass `--reference-lane-plan` or `--single-bottom-track` to replay the [authored lane plans](../inire/tests/terminal_bench_lane_plan.py). Use the unseeded command above for planner coverage and timing.
|
||||
|
||||
## Preplaced crossings
|
||||
|
||||
|
|
@ -26,12 +28,14 @@ Use unseeded runs to evaluate routing policy. For a separate check of geometry a
|
|||
|
||||
The importer converts placed device outlines to keepouts with port openings and snaps optical ports to a 0.1 µm grid. The six converted layouts exercise routing between fixed devices. To inspect their ports and keepouts, open the [checked-in fixture data](../inire/tests/data/external_routing_benchmarks.json).
|
||||
|
||||
| Cases | Source | License |
|
||||
| Cases | Pinned source | License |
|
||||
| --- | --- | --- |
|
||||
| Splitter tree, ring modulator, and MZM | [PIC Routing Benchmark](https://huggingface.co/datasets/FLYR/pic-benchmark/blob/0c1f445792926d97fae01893c89e96b8a9393800/pic-benchmark/README.md) | CC BY 4.0 |
|
||||
| Toy layout and subsets of the Clements and MRR weight-bank layouts | [LiDAR benchmarks](https://github.com/ScopeX-ASU/LiDAR/tree/4e7004d32b0b80d959553797fb30f0737513de0c/src/picroute/benchmarks) | [LiDAR license](../inire/tests/data/LiDAR-LICENSE.txt) |
|
||||
| Splitter tree, ring modulator, and MZM | [FLYR PIC Routing Benchmark archive](https://huggingface.co/datasets/FLYR/pic-benchmark/resolve/0c1f445792926d97fae01893c89e96b8a9393800/pic-benchmark.zip) | FLYR's bundled `LICENSE` specifies [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/). |
|
||||
| Toy layout and subsets of the Clements and MRR weight-bank layouts | [LiDAR benchmark inputs](https://github.com/ScopeX-ASU/LiDAR/tree/4e7004d32b0b80d959553797fb30f0737513de0c/src/picroute/benchmarks) | [ScopeX@ASU's MIT license](../inire/tests/data/LiDAR-LICENSE.txt). |
|
||||
|
||||
The importer checks both pinned archive hashes. It requires PyYAML when regenerating the fixtures.
|
||||
### Regenerate the converted inputs
|
||||
|
||||
The importer checks both archive hashes before converting geometry. It uses PyYAML to read the layout files. Generate a scratch copy and compare it with the checked-in fixture data.
|
||||
|
||||
```sh
|
||||
mkdir -p /tmp/inire-external-routing
|
||||
|
|
@ -41,5 +45,8 @@ curl -fL 'https://codeload.github.com/ScopeX-ASU/LiDAR/tar.gz/4e7004d32b0b80d959
|
|||
-o /tmp/inire-external-routing/lidar.tar.gz
|
||||
uv run --with 'pyyaml==6.0.3' python -m scripts.import_external_routing_benchmarks \
|
||||
--pic-archive /tmp/inire-external-routing/pic-benchmark.zip \
|
||||
--lidar-archive /tmp/inire-external-routing/lidar.tar.gz
|
||||
--lidar-archive /tmp/inire-external-routing/lidar.tar.gz \
|
||||
--output /tmp/inire-external-routing/fixtures.json
|
||||
cmp inire/tests/data/external_routing_benchmarks.json \
|
||||
/tmp/inire-external-routing/fixtures.json
|
||||
```
|
||||
|
|
|
|||
|
|
@ -4,9 +4,7 @@ Use these measurements when changing the automatic probe budget or retry order.
|
|||
|
||||
## Near-port probe and retry experiments
|
||||
|
||||
Results recorded on November 26, 2026. The probe decision compared the two-iteration cap with the full configured probe budget. The retry experiments used the pre-cap policy.
|
||||
|
||||
The two-iteration probe reduced public-default expansions by 23% on the regression corpus. Paths matched on both the corpus and holdouts. Check individual boards before changing the cap again.
|
||||
The November 26, 2026 comparison used the regression corpus and retry holdouts under the `public-defaults` and `corpus-regression` profiles. Against the full configured probe budget, a two-iteration cap reduced public-default corpus expansions by 23%. Verified paths and costs matched on both board sets. Check these individual cases before changing the cap again.
|
||||
|
||||
- The splitter tree benefited from fewer repeated shallow searches.
|
||||
- The mixed port bank did more work because the shorter probe passed its last net to the wider retry.
|
||||
|
|
@ -19,9 +17,9 @@ python -m scripts.benchmark_retry_order --case corpus --case retry-holdout \
|
|||
|
||||
### Early and late retries
|
||||
|
||||
Early retries can save time when they avoid a more expensive stage. Failed retries add work before the ordinary fallback. In one holdout, early incumbent recovery selected a higher-cost path at the same coverage. Use the trigger counts and commands in the [experiment archive](#experiment-archive) to compare failed-retry time and cost on common nets.
|
||||
The November 26, 2026 retry experiments used the pre-cap baseline. Failed early retries added work before the ordinary fallback. In one holdout, early incumbent recovery selected a higher-cost path at the same coverage. When comparing a change to retry order, measure the cost of failed attempts as well as the successful recoveries. For the trigger conditions and older driver, see the [archived retry measurements](../archive/routing/README.md#reproduce-probe-and-retry-experiments).
|
||||
|
||||
Use `late-residual-3000` to measure the cost of recovering one more net after the ordinary policy stalls. The policy needs room in the caller's budget and checks that the remaining ports are connected with the incumbents locked. It recovered the last net on two crossing boards and a return shelf in the pre-cap holdout sweep.
|
||||
In the `public-defaults` holdout sweep, `late-residual-3000` recovered the last net on two crossing boards and a return shelf while preserving the previously verified paths. It requires room in the caller's budget and connected ports with the incumbents locked. Use the current comparison below to measure the cost of that extra attempt.
|
||||
|
||||
```sh
|
||||
python -m scripts.benchmark_retry_order --case retry-holdout --profile public-defaults \
|
||||
|
|
@ -31,6 +29,4 @@ python -m scripts.benchmark_retry_order --case retry-holdout --profile public-de
|
|||
|
||||
## Experiment archive
|
||||
|
||||
- For the original retry experiments, budget sweeps, and manual Terminal-Bench lane comparisons, run `git show ea5cfe7:docs/topological-routing.md`. To rerun a retired policy, use the driver at that revision in a separate worktree.
|
||||
- For the probe and holdout measurement tables, run `git show 2b02c6e:docs/topological-routing.md`.
|
||||
- For earlier plans, traces, and performance baselines, see the [routing development archive](../archive/routing/README.md).
|
||||
To recover the recorded expansion counts or rerun an earlier driver, follow the revision and command listed with the [archived probe and retry experiments](../archive/routing/README.md#reproduce-probe-and-retry-experiments).
|
||||
|
|
|
|||
|
|
@ -11,17 +11,15 @@ python -m scripts.compare_topological_routing \
|
|||
--mode automatic
|
||||
```
|
||||
|
||||
- **Coverage.** Expect `3/4 valid`. The capacity report gives three tracks across the cut. This run reached the geometric bound.
|
||||
- **Path quality.** Compare the verified net IDs before comparing weighted length or native objective cost.
|
||||
- **Work.** Read A* expansions and median time together. The report can show work spent planning and verifying even when it reports zero expansions.
|
||||
Expect `3/4 valid` and a report of three tracks for four nets crossing the cut. The run reached the geometric bound. When trying another setting, check the bound and verified IDs before comparing cost. For a case whose bound comes from fixed ports, use `--case lidar-clements-8x8`.
|
||||
|
||||
## Choose a case
|
||||
|
||||
| If you are changing | Use `--case` |
|
||||
| --- | --- |
|
||||
| Overall coverage | `corpus` runs the regression suite. |
|
||||
| Ordered tracks, shared gates, and barrier layouts | `all` selects the original fixture group. |
|
||||
| Seeds, custom bend geometry, and fallback behavior | `broad` includes caller seeds, custom bends, imported layouts, and the first holdout set. |
|
||||
| Ordered tracks, shared gates, and barrier layouts | `all` exercises the original layouts, including fixed-heading Terminal-Bench. |
|
||||
| Seeds, custom bend geometry, and fallback behavior | `broad` includes caller seeds, custom bends, imported layouts, and held-out boards. |
|
||||
| Ports on placed devices | `crossings` exercises external legs to preplaced crossing cells. |
|
||||
| Lock ordering, tight turns, and competing passages | `stress` runs known-feasible folded returns, competing locks, and shared passages. |
|
||||
| A retry tuned on the regression corpus | `retry-holdout` tests related but separate return shelves, bypasses, and competing trunks. |
|
||||
|
|
@ -60,7 +58,7 @@ python -m scripts.compare_topological_routing \
|
|||
--json /tmp/inire-modes.json
|
||||
```
|
||||
|
||||
Guide and seed complete the offset net at the same cost. Guide does so with no corridor seed. If a change increases work in seed mode, inspect how the [corridor is realized as a path](topological-routing.md#corridor-planning-and-realization).
|
||||
At 100 nodes per search, `off` stops short. Guide and seed both finish the same net at the same cost. Guide takes 4 expansions. Seed takes 37, all in seed search. If seed work increases after a change, inspect how the [corridor is realized as a path](topological-routing.md#corridor-planning-and-realization).
|
||||
|
||||
### Test a retry on holdouts
|
||||
|
||||
|
|
@ -74,10 +72,10 @@ python -m scripts.benchmark_retry_order \
|
|||
--json /tmp/inire-residual.json
|
||||
```
|
||||
|
||||
Inspect verified IDs, paths, and time spent on failed attempts. The [prior retry experiments](benchmark-results.md#early-and-late-retries) show a case where earlier recovery increased cost at the same coverage.
|
||||
Check which holdouts gained a verified net, then compare previously verified paths and time spent on failed attempts. To see a case where an earlier retry increased cost at the same coverage, read the [retry results](benchmark-results.md#early-and-late-retries).
|
||||
|
||||
## Compare the results
|
||||
|
||||
1. **Coverage and bounds.** Check verified IDs, requested nets, and any bound. The overloaded gate exercises passage capacity. The imported LiDAR Clements layout exercises fixed-port conflicts. Verify any feasibility witness separately from the timed run.
|
||||
2. **Cost on matching net sets.** Benchmark-weighted length weights physical straights, 90-degree bends, and S-bends by 1, 4, and 13. Native objective cost uses the run's configured objective. Compare costs on identical verified IDs, and report coverage changes separately.
|
||||
3. **Search and time.** Compare expansions and repeated wall times at the same settings. To investigate a slow case or a change in the selected attempt, use the [stage reports and traces](routing-diagnostics.md).
|
||||
3. **Search and time.** Compare expansions and repeated wall times at the same settings. Constructive stages can spend time planning and verifying even with zero expansions. To locate work that moved to a different stage, use the [automatic reports](routing-diagnostics.md#automatic-reports).
|
||||
|
|
|
|||
|
|
@ -9,12 +9,15 @@
|
|||
|
||||
## Check a change
|
||||
|
||||
1. Run `uv sync` to install development dependencies. Activate `.venv` or prefix the commands with `uv run`.
|
||||
2. Run `python -m pytest` for the correctness suite. Use `python -m pytest -m "not routing_corpus"` for a shorter local check and `ruff check inire scripts` for lint.
|
||||
3. For a routing change, compare coverage, geometry, and work using a consistent [benchmark profile](benchmarks.md#choose-a-profile). If you expect exact paths, costs, and trace data to match, run an [exact parity comparison](routing-diagnostics.md#reproduce-and-compare).
|
||||
1. From the repository root, run `uv sync` to install development dependencies. Activate `.venv` or prefix commands with `uv run`.
|
||||
2. Run `python -m pytest` for the correctness suite and `ruff check inire scripts` for lint. Use `python -m pytest -m "not routing_corpus"` for a shorter local check.
|
||||
3. For a cleanup that should preserve paths, capture both revisions and run an [exact parity comparison](routing-diagnostics.md#reproduce-and-compare). Include callbacks or traces if the change affects them.
|
||||
4. For a policy or budget change, start with a case that exhibits the behavior. Compare verified IDs, cost, and work under the same [benchmark profile](benchmarks.md#choose-a-profile). Check the corpus and related holdouts before adopting the change.
|
||||
|
||||
For documentation figures, run `python -m scripts.render_documentation_figures` from the repository root. It writes the route plots and planner diagram under `docs/figures`. Pass `--output-dir` to render a scratch copy for comparison.
|
||||
### Check a documentation figure
|
||||
|
||||
Run `python -m scripts.render_documentation_figures --output-dir /tmp/inire-figures` to preview changes. Compare the port labels, keepouts, path, and caption against the published example. Run the script without `--output-dir` to regenerate the figures in `docs/figures`.
|
||||
|
||||
## Development history
|
||||
|
||||
See the [routing development archive](../archive/routing/README.md) for old plans, optimization logs, and recorded trace and performance data.
|
||||
To recover the inputs, metrics, or rationale behind an earlier routing decision, use the [routing development archive](../archive/routing/README.md).
|
||||
|
|
|
|||
Binary file not shown.
|
Before Width: | Height: | Size: 42 KiB After Width: | Height: | Size: 45 KiB |
|
|
@ -31,24 +31,32 @@ Enable the `DiagnosticsOptions` flag for the question you want to answer.
|
|||
| Question | Flag and result |
|
||||
| --- | --- |
|
||||
| Which net consumed an iteration's budget? | `capture_iteration_trace` records `iteration_trace`. Inspect per-net `net_attempts` for expansions, pruning, congestion calls, and seed usage. |
|
||||
| Which two routes overlap after re-verification? | `capture_conflict_trace` records `conflict_trace`. Use the dynamic conflict edges to find the pair and the component indices to locate the overlap. |
|
||||
| Which two routes overlap after re-verification? | `capture_conflict_trace` records the conflicting net IDs and the indices of their overlapping path components. |
|
||||
| What pruning occurred near the final overlap? | `capture_frontier_trace` records `frontier_trace` for reached-but-colliding nets. Inspect the states and prune reasons sampled in that area. The diagnostic replay leaves the selected route fixed. |
|
||||
| What did the last unresolved iteration hand to pair-local repair? | `capture_pre_pair_frontier_trace` records `pre_pair_frontier_trace`. Check reroute order, conflict edges, and per-net attempt work immediately before repair. |
|
||||
| Where did the router explore? | `capture_expanded` records `expanded_nodes` for plotting. See the [fan-out example](../examples/07_large_scale_routing.py). |
|
||||
|
||||
### Find overlapping components
|
||||
|
||||
1. Enable `capture_conflict_trace` in the run's `DiagnosticsOptions`. In the returned `run.conflict_trace`, use the entry whose `stage` is `"final"` to inspect the paths the run returned.
|
||||
2. Find the two net IDs in `conflict_edges`. In the matching `nets` entry, read `component_conflicts` for `self_component_index`, `other_net_id`, and `other_component_index`.
|
||||
3. Index each net's `path` in `run.results_by_net` using those zero-based indices. Plot the components' `physical_geometry` on the board and check their spacing against the required clearance. See whether both components compete for the same opening.
|
||||
|
||||
For an earlier stage such as `restored_best`, read the net and component indices from that entry. The final paths may have changed during repair.
|
||||
|
||||
### Follow a late conflict into pair-local repair
|
||||
|
||||
Capture the no-warm-start fan-out scenario from the repository root.
|
||||
Capture the conflict trace for fan-out with warm starts disabled. The best congestion iteration leaves two disjoint pairs of nets competing for space.
|
||||
|
||||
```sh
|
||||
python -m scripts.record_iteration_trace --scenario example_07_large_scale_routing_no_warm_start \
|
||||
python -m scripts.record_conflict_trace \
|
||||
--scenario example_07_large_scale_routing_no_warm_start \
|
||||
--output-dir /tmp/inire-trace
|
||||
```
|
||||
|
||||
1. Compare the last iteration with the final result in `iteration_trace.md`. The last iteration had six completed nets and two conflict edges in the [recorded fan-out run](../archive/routing/iteration_trace.md#example_07_large_scale_routing_no_warm_start).
|
||||
2. Read the final result and pair-local counters in `iteration_trace.json`. All ten nets verified after repair in this run.
|
||||
3. Substitute `scripts.record_conflict_trace` in the command to locate the overlapping components. Compare `restored_best` with `final` as shown in the [recorded conflict trace](../archive/routing/conflict_trace.md).
|
||||
4. Substitute `scripts.record_pre_pair_frontier_trace` to see the reroute order and per-net work leading up to repair. Compare your run with the [recorded pre-pair trace](../archive/routing/pre_pair_frontier_trace.md).
|
||||
1. Open `conflict_trace.json` and find `restored_best`. Six nets are complete and the conflict edges are `net_02` with `net_03` and `net_06` with `net_07`. For example, the entry for `net_02` reports that its component 1 overlaps component 1 of `net_03`. See the stage summary in the [recorded conflict trace](../archive/routing/conflict_trace.md#example_07_large_scale_routing_no_warm_start).
|
||||
2. Compare with `final`. All ten nets verified and the conflict edges are empty. The staged trace shows that repair resolved conflicts remaining after the congestion iterations.
|
||||
3. To compare expansions and congestion work in the iterations leading up to repair, substitute `scripts.record_iteration_trace` in the command. If you need the reroute order and per-net work immediately before repair, substitute `scripts.record_pre_pair_frontier_trace` and compare with the [recorded pre-pair trace](../archive/routing/pre_pair_frontier_trace.md).
|
||||
|
||||
Use the returned result to count final successes. For live progress during routing, pass an [`iteration_callback`](user/api-reference.md#route-a-problem).
|
||||
|
||||
|
|
|
|||
|
|
@ -2,37 +2,46 @@
|
|||
|
||||
# Topological routing
|
||||
|
||||
Guide mode suggests routes through connected free space. Seed mode also tries to realize those suggestions as physical paths.
|
||||
Guide mode helps detailed search choose a passage through free space. Seed mode also tries to build a physical path through the passage before detailed search starts.
|
||||
|
||||
## Corridor planning and realization
|
||||
|
||||

|
||||
|
||||
The offset-gates fixture has two openings at different heights. The highlighted triangle edges form the corridor's portals. The dashed line shows the lane suggestion, and the solid S-bend shows the physical route that guide mode found.
|
||||
In offset gates, a route must change height between two openings. Read the panels from top to bottom. The highlighted triangle edges show the chosen portals, the dashed line joins the suggested crossing points, and the solid S-bend shows where detailed search fits a physical turn.
|
||||
|
||||
1. **Find connected space for centerlines.** Inset the board by half the widest net's width and expand obstacles by that half-width plus clearance. Shared edges of a constrained Delaunay triangulation act as portals. A short lead tries to attach each terminal to the mesh along its heading. Using the widest net gives the planner a common representation. Narrower nets may still find a path in lattice search through a passage this mesh excludes.
|
||||
2. **Choose a passage and a lane.** Rank portal sequences by distance, occupancy, and estimated overflow. Use lane samples and estimated turn room to select where to cross each portal without crowding another net's access. A different lane through the same portal can make space for a turn. Joint retries use that distinction to revise a shared passage assignment.
|
||||
3. **Turn the sketch into a path.** Guide mode adds soft costs and move suggestions, so detailed search can leave an awkward corridor. Seed mode first tries to find a physical path inside a corridor and verifies it against obstacles and earlier seeds. It gives the first corridor at least half the per-net budget when there are alternatives. Later detailed iterations can move an incumbent or try another guide. Final verification checks the actual routed geometry.
|
||||
1. **Find connected space for centerlines.** Inset the board by half the widest net's width and expand obstacles by that half-width plus clearance. A short lead tries to attach each terminal to the constrained Delaunay mesh along its heading. The common padding can exclude passages that a narrower net can still use in lattice search.
|
||||
|
||||
## When a corridor does not lead to a route
|
||||
<a id="design-background"></a>
|
||||
|
||||
- **No corridor reported.** Inspect `run.topology` from an explicit guide or seed run. Check snapped port access, mesh padding, and which passages remain connected.
|
||||
- **A corridor exists but seed search stalls.** Check terminal headings and the turn room around each chosen portal.
|
||||
- **Seeds reach their targets and the final routes overlap.** Inspect lane order and congestion before adding seed nodes. To locate each overlapping component, capture a [conflict trace](routing-diagnostics.md#traces).
|
||||
A portal is an edge shared by adjacent free-space triangles. For an earlier representation of a route by its crossings of triangle edges, see Section III-A and Figure 1 of [Hama and Etoh's curvilinear detailed-routing paper](https://www.cecs.uci.edu/~papers/compendium94-03/papers/1998/aspdac98/pdffiles/06c_3.pdf).
|
||||
|
||||
To investigate how passages and lane order are chosen, start with the [corridor planner](../inire/router/_topology.py).
|
||||
2. **Choose a passage and a lane.** Rank portal sequences by distance, occupancy, and estimated overflow. Along each chosen portal, sample crossing points and rank them by turn room and access reserved for other nets. A joint retry can move nets to different lanes through the same opening to make room for a turn. To change how candidate points are ranked, inspect [`assign_lanes()`](../inire/router/_topology.py#L214).
|
||||
|
||||
## Design background
|
||||
3. **Turn the sketch into a path.** Guide mode uses the corridor to suggest moves and add a soft cost, so search can leave it to make a turn. Seed mode first searches inside a corridor and checks any seed against obstacles and earlier seeds. With alternatives, the first corridor gets at least half the per-net seed budget. Later detailed iterations can move an incumbent or use another guide. Final verification checks the installed geometry.
|
||||
|
||||
- For the use of shared triangle edges in detailed routing, see [Curvilinear detailed routing](https://websrv.cecs.uci.edu/~papers/compendium94-03/papers/1998/aspdac98/pdffiles/06c_3.pdf).
|
||||
- For constraints specific to photonic waveguides, see [LiDAR 2.0](https://scopex-asu.github.io/files/publications/PD_TCAD2025_LiDARv2.pdf).
|
||||
A passage can be connected in the mesh and leave too little room to bend onto the target port's heading. For the bend-radius and port-alignment rules that constrain the physical route, see Section II-B of [LiDAR 2.0](https://arxiv.org/html/2505.17239v1#S2.SS2).
|
||||
|
||||
<a id="when-a-corridor-does-not-lead-to-a-route"></a>
|
||||
|
||||
## Diagnose a missing or colliding route
|
||||
|
||||
In an explicit guide or seed run, check `run.topology.corridor_counts` and `seeded_net_ids` when the worker returns a topology report.
|
||||
|
||||
- **No corridor is reported for the net.** Check that the snapped port can launch into free space along its heading. Inspect the keepouts and the padding at the suspected opening to see whether that passage is connected in the mesh.
|
||||
- **A corridor exists and the path stops short.** Look at the next turn from the end of the partial path. Compare the available space with the allowed radii and arrival heading. If the geometry fits, vary the [per-net seed budget](user/api-reference.md#topologyoptions) and compare whether seed mode reaches the target.
|
||||
- **The paths reach their ports and overlap.** Use the [conflict trace](routing-diagnostics.md#find-overlapping-components) to identify the nets and the overlapping components. Locate those components on the board. If both nets compete for the same opening, inspect their lane order and available turn room before increasing the seed budget.
|
||||
|
||||
<a id="moved-benchmark-sections"></a>
|
||||
|
||||
## Reproduce a routing comparison
|
||||
|
||||
- <a id="benchmark-corpus"></a>To select a board that exercises the behavior you are studying, use the [benchmark case guide](benchmarks.md#choose-a-case).
|
||||
- <a id="reproduce-a-comparison"></a>To compare off, guide, and seed on offset gates, run the [matched-budget example](benchmarks.md#compare-routing-modes).
|
||||
- <a id="probe-budget-and-coverage"></a><a id="retry-experiments"></a>To check a change to probe limits or retry order, see the [prior experiments](benchmark-results.md#near-port-probe-and-retry-experiments).
|
||||
- <a id="automatic-nine-net-terminal-bench-routing"></a><a id="imported-fixtures"></a>To reproduce an upstream workload, see the [Terminal-Bench and imported fixtures](benchmark-fixtures.md).
|
||||
- <a id="experiment-archive"></a>To recover prior measurements and their commands, consult the [experiment archive](benchmark-results.md#experiment-archive).
|
||||
<a id="reproduce-a-comparison"></a>
|
||||
|
||||
On offset gates, guide and seed can finish at the same cost. To see whether the seed saves search work at a shared node budget, compare expansions and seeded IDs in the [matched-budget example](benchmarks.md#compare-routing-modes).
|
||||
|
||||
### Benchmark fixtures and prior runs
|
||||
|
||||
- <a id="benchmark-corpus"></a>To repeat the comparison on a different geometry, pick a layout from the [benchmark case guide](benchmarks.md#choose-a-case).
|
||||
- <a id="automatic-nine-net-terminal-bench-routing"></a><a id="imported-fixtures"></a>For pinned inputs and regeneration commands, see the [Terminal-Bench and imported fixtures](benchmark-fixtures.md).
|
||||
- <a id="probe-budget-and-coverage"></a><a id="retry-experiments"></a><a id="experiment-archive"></a>For measured changes to probe limits or retry order and the commands that produced them, see the [prior experiments](benchmark-results.md#near-port-probe-and-retry-experiments).
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
# Public API reference
|
||||
|
||||
Import the types on this page from `inire`. The [layout guide](route-a-layout.md) shows how to assemble a problem and the [tuning guide](tune-and-troubleshoot.md) explains which settings to try.
|
||||
Import these types from `inire`. To see how the inputs fit together in a runnable design, start with the [layout guide](route-a-layout.md#define-the-inputs).
|
||||
|
||||
## Route a problem
|
||||
|
||||
|
|
@ -12,18 +12,23 @@ Omitting `options` uses `RoutingOptions()`. To observe live congestion iteration
|
|||
|
||||
## Layout inputs
|
||||
|
||||
- `Port(x, y, r)` snaps coordinates to the integer grid and normalizes the heading in degrees. Heading 0 points east and 90 points north. The heading must be a multiple of 90 after rounding.
|
||||
- `NetSpec(net_id, start, target, width=2.0)` uses a unique ID and two ports. The target heading is the direction of arrival.
|
||||
- `RoutingProblem` describes one routing layer. Use one unit for distances, coordinates, widths, and radii.
|
||||
### Ports and nets
|
||||
|
||||
| Input | Meaning |
|
||||
| --- | --- |
|
||||
| `bounds` | Board outline as `(xmin, ymin, xmax, ymax)`. |
|
||||
| `nets` | `NetSpec(net_id, start, target, width=2.0)` objects with unique IDs and `Port(x, y, r)` terminals. Defaults to an empty tuple. |
|
||||
| `static_obstacles` | Shapely polygons for keepouts. Defaults to an empty tuple. |
|
||||
| `initial_paths` | Mapping from net IDs to `PathSeed` objects. Defaults to an empty mapping. |
|
||||
| `clearance` | Required spacing between physical shapes. Defaults to `2.0`. |
|
||||
| `safety_zone_radius` | Tolerance for very small obstacle intersections at ports during search. Defaults to `0.0021`. |
|
||||
- `Port(x, y, r)` snaps coordinates to the integer grid and normalizes the heading `r` in degrees. Heading 0 points east and 90 points north. The heading must be a multiple of 90 after rounding.
|
||||
- `NetSpec(net_id, start, target, width=2.0)` uses a unique ID and two ports. The target heading is the direction of arrival.
|
||||
|
||||
### RoutingProblem
|
||||
|
||||
The fields below appear in constructor order. Use one layout unit for coordinates, widths, distances, and radii.
|
||||
|
||||
| Field | Default | Meaning |
|
||||
| --- | --- | --- |
|
||||
| `bounds` | Required | Board rectangle as `(xmin, ymin, xmax, ymax)`. |
|
||||
| `nets` | `()` | Sequence of `NetSpec` objects with unique IDs. |
|
||||
| `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. |
|
||||
| `safety_zone_radius` | `0.0021` | Tolerance for very small obstacle intersections at ports during search. |
|
||||
|
||||
## Path seeds
|
||||
|
||||
|
|
@ -36,12 +41,13 @@ Omitting `options` uses `RoutingOptions()`. To observe live congestion iteration
|
|||
| `RoutingRunResult.results_by_net` | A mapping from net ID to `RoutingResult`. |
|
||||
| `RoutingResult.is_valid` and `outcome` | Final validity and a status of `completed`, `colliding`, `partial`, or `unroutable`. |
|
||||
| `RoutingResult.path` | Ordered path components from the source to the last reached state. An unroutable result has an empty path. |
|
||||
| `RoutingResult.reached_target` and `report` | Arrival status, physical length, and collision details. |
|
||||
| `RoutingResult.reached_target` | Whether the path reached the target port with its required heading. |
|
||||
| `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.locked_geometry` and `as_seed()` | Physical polygons for export or fixed obstacles, and the move sequence for reuse as a seed. |
|
||||
| `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. |
|
||||
|
||||
Before using a route's physical polygons in your layout, follow the [export checks](tune-and-troubleshoot.md#read-the-result).
|
||||
To read a route's polygons and write them to a test file, follow the [geometry export steps](route-a-layout.md#export-verified-geometry).
|
||||
|
||||
## Options and defaults
|
||||
|
||||
|
|
@ -109,6 +115,8 @@ Increase the iteration limit when later reroutes might resolve conflicts. Adjust
|
|||
|
||||
### TopologyOptions
|
||||
|
||||
For a layout that repeatedly stops short at an opening, `guide` can suggest a passage while letting search choose where to turn. To compare this with realizing a physical starting path in `seed`, see the [routing mode choices](tune-and-troubleshoot.md#choose-a-routing-mode).
|
||||
|
||||
| Field | Default | Effect |
|
||||
| --- | --- | --- |
|
||||
| `mode` | `"automatic"` | Select a [routing mode](tune-and-troubleshoot.md#choose-a-routing-mode). |
|
||||
|
|
|
|||
|
|
@ -1,16 +1,14 @@
|
|||
# Route a layout
|
||||
|
||||
Start with the [first route](../../README.md#route-a-net), then replace the example ports and add your layout's constraints.
|
||||
To get a result you can experiment with, run the [single-net quick start](../../README.md#route-a-net). To route your own design, set up the board and connections in the order below.
|
||||
|
||||
## Define the inputs
|
||||
|
||||
1. **Choose a coordinate unit.** Inire snaps port coordinates to an integer grid. Choose a unit fine enough to preserve narrow gaps, and use it for widths, radii, clearance, and bounds too.
|
||||
2. **Set source and target headings.** Heading 0 points east and 90 points north. The source heading points along the launch. The target heading points along the arrival. If your device library labels the target port with its outward heading, reverse it by 180 degrees.
|
||||
3. **Add a net for each connection.** Give each `NetSpec` a unique ID and the guide width. Set your process limits through `SearchOptions` and choose the required clearance on `RoutingProblem`.
|
||||
4. **Add keepouts.** Supply Shapely polygons in `static_obstacles` and use `bounds` for the board rectangle. Leave enough access at the ports for the guide and its permitted bends.
|
||||
5. **Run and check.** Call `route(problem, options=options)`. Start with automatic mode for general layouts and [check each net before export](tune-and-troubleshoot.md#read-the-result).
|
||||
|
||||
For the constructor signatures and field defaults, see the [layout input reference](api-reference.md#layout-inputs).
|
||||
3. **Add a net for each connection.** Give each `NetSpec` a unique ID and the guide width. Use your process's allowed bend radii in [`SearchOptions`](api-reference.md#searchoptions).
|
||||
4. **Set the board and keepouts.** Pass the board rectangle as `bounds`, Shapely polygons as `static_obstacles`, and the required physical spacing as `clearance`. For the defaults and accepted inputs, see [`RoutingProblem`](api-reference.md#routingproblem).
|
||||
5. **Route and check.** Call `route(problem, options=options)` with automatic mode for a general layout. Before exporting, [check each net's result](tune-and-troubleshoot.md#read-the-result).
|
||||
|
||||
<a id="connect-a-preplaced-crossing"></a>
|
||||
|
||||
|
|
@ -22,9 +20,9 @@ For the constructor signatures and field defaults, see the [layout input referen
|
|||
|
||||

|
||||
|
||||
Dashed outlines show the complete device footprints. Shading shows the keepouts passed to Inire. The external route connects the two port markers. The arrow at each marker shows the heading.
|
||||
The dashed outlines show the full footprints of crossings A and B. The shaded keepouts leave a port opening on each facing edge. The external waveguide leaves A at `(80, 75)` and enters B at `(260, 115)`. Both arrows point east.
|
||||
|
||||
Inire applies `clearance` around the supplied keepout polygons. A straight approach of width `w` between two keepout edges needs at least `w + 2 * clearance` of open width. Leave room for any turn near the port and check the opening after snapping the port to the grid.
|
||||
Each opening is 12 units wide. A straight approach of width 2 with clearance 4 on each side needs `2 + 2 * 4 = 10` units between keepout edges. Leave extra room for any turn near a port, and check the opening after snapping the port to the grid.
|
||||
|
||||
```python
|
||||
from shapely.geometry import box
|
||||
|
|
@ -59,40 +57,61 @@ problem = RoutingProblem(
|
|||
search = SearchOptions(
|
||||
bend_radii=(25,), sbend_radii=(25,),
|
||||
)
|
||||
opts = RoutingOptions(search=search)
|
||||
run = route(problem, options=opts)
|
||||
options = RoutingOptions(search=search)
|
||||
run = route(problem, options=options)
|
||||
result = run.results_by_net[net_id]
|
||||
assert result.is_valid
|
||||
```
|
||||
|
||||
Before export, check the port joins and clearance against the actual placed-cell geometry. Inire verifies the external route against the keepouts you supplied.
|
||||
|
||||
## Export verified geometry
|
||||
|
||||
Use `result.locked_geometry` to pass a verified net's physical polygons to a layout writer. For a test file, continue from the quick start or the crossing example and write the polygons as WKT in the layout's coordinate unit.
|
||||
|
||||
```python
|
||||
from pathlib import Path
|
||||
|
||||
from shapely.geometry import GeometryCollection
|
||||
|
||||
if not result.is_valid:
|
||||
raise ValueError(f"{result.net_id}: {result.outcome}")
|
||||
|
||||
geometry = GeometryCollection(result.locked_geometry)
|
||||
Path("route.wkt").write_text(geometry.wkt + "\n", encoding="utf-8")
|
||||
```
|
||||
|
||||
For a multi-net layout, apply the validity check to every net you intend to export. If a route is short or colliding, use its outcome to choose the [next troubleshooting check](tune-and-troubleshoot.md#read-the-result).
|
||||
|
||||
## Reuse an existing route
|
||||
|
||||
- **Give the router a route it can move.** Put `result.as_seed()` in `initial_paths` under the net's ID. A seed uses the current start port, width, and geometry settings. A partial seed can suggest an approach. To build a hint from turns and straights, see the [path seed reference](api-reference.md#path-seeds).
|
||||
- **Hold a route fixed.** Add `result.locked_geometry` to `static_obstacles` while routing other nets. The next run applies its own clearance.
|
||||
|
||||
To reuse the verified routes from a first problem as fixed obstacles, add them to a second problem that contains the remaining nets.
|
||||
Route a straight net, then use its polygons as keepouts in a second routing problem. The second net has to detour around one end of the fixed route.
|
||||
|
||||
```python
|
||||
from dataclasses import replace
|
||||
from inire import route
|
||||
from inire import (
|
||||
NetSpec, Port, RoutingOptions,
|
||||
RoutingProblem, SearchOptions, route,
|
||||
)
|
||||
|
||||
first = route(first_problem)
|
||||
locked = tuple(
|
||||
polygon
|
||||
for result in first.results_by_net.values()
|
||||
if result.is_valid
|
||||
for polygon in result.locked_geometry
|
||||
bounds = (0, -50, 100, 50)
|
||||
options = RoutingOptions(search=SearchOptions(bend_radii=(10,)))
|
||||
first = RoutingProblem(
|
||||
bounds=bounds,
|
||||
nets=(NetSpec("fixed", Port(10, 0, 0), Port(90, 0, 0)),),
|
||||
)
|
||||
obstacles = (
|
||||
next_problem.static_obstacles
|
||||
+ locked
|
||||
fixed = route(first, options=options).results_by_net["fixed"]
|
||||
assert fixed.is_valid
|
||||
|
||||
second = RoutingProblem(
|
||||
bounds=bounds,
|
||||
nets=(NetSpec("detour", Port(50, -20, 90), Port(50, 20, 90)),),
|
||||
static_obstacles=fixed.locked_geometry,
|
||||
)
|
||||
second = route(replace(
|
||||
next_problem,
|
||||
static_obstacles=obstacles,
|
||||
))
|
||||
detour = route(second, options=options).results_by_net["detour"]
|
||||
assert detour.is_valid
|
||||
```
|
||||
|
||||
To see the second route detour around a fixed path, run the [locked-path example](../../examples/README.md#route-around-fixed-geometry).
|
||||
To compare the two paths on a plot, see the [fixed-route example](../../examples/README.md#route-around-fixed-geometry).
|
||||
|
|
|
|||
|
|
@ -1,27 +1,27 @@
|
|||
# Tune and troubleshoot a route
|
||||
|
||||
Check whether the layout can fit the connection before spending more search time. Start with the per-net result and change one setting at a time.
|
||||
Start with the net's outcome. It tells you whether to examine the port approach, an overlap, or the search budget.
|
||||
|
||||
## Read the result
|
||||
|
||||
| `result.outcome` | What to inspect |
|
||||
| --- | --- |
|
||||
| `completed` | The path reached its target and passed verification. Use `locked_geometry` for physical polygons and `report.total_length` for length. |
|
||||
| `colliding` | The path reached its target. Read `report` for static, dynamic, or self-collisions and any automatic board containment failure. |
|
||||
| `partial` | Inspect where the path ends. Check the next turn, available radius, and search limit. |
|
||||
| `unroutable` | No path was returned. Check the launch heading and room for the first straight or bend. |
|
||||
| `completed` | The path reached its target and passed verification. Read its length in `report.total_length` and follow the [geometry export steps](route-a-layout.md#export-verified-geometry). |
|
||||
| `colliding` | The path reached its target. Check the collision counts in `result.report` to see whether it overlaps a keepout, another route, or itself. For automatic routing, also check `report.out_of_bounds`. |
|
||||
| `partial` | Locate `result.path[-1].end_port` on the board and check the next turn and radius. If that approach fits, compare search limits. |
|
||||
| `unroutable` | The path is empty. Check the launch heading and room for the first straight or bend. |
|
||||
|
||||
Check `is_valid` before exporting. With explicit `off`, `guide`, or `seed` mode, also check that the physical polygons fit the board if your export requires containment. Automatic mode includes that check in candidate verification.
|
||||
|
||||
## Why a net stopped short
|
||||
|
||||
1. **Check for a geometric bound.** In an automatic run, `max_routed` is an upper bound. If it is below the requested count, read `capacity_limit` or `port_conflicts` to see where to widen a passage or move a port. A result below the bound can still leave feasible nets unfinished.
|
||||
2. **Check the port and turn geometry.** For static or self-collisions, inspect physical clearance and bend room. For dynamic collisions, inspect the routes that compete for the same space.
|
||||
3. **Check the search budget.** If the verified count is below the bound and the geometry looks feasible, try raising a small `search.node_limit`. The limit is per search. A run can try the same net several times.
|
||||
1. **Check whether automatic routing hit a bound.** Compare the verified count with `run.automatic.max_routed`. If the count reaches a bound below the requested total, use `capacity_limit` to locate the passage to widen or `port_conflicts` to find the ports to move.
|
||||
2. **Check the next approach.** Follow a partial route from its endpoint toward the target. Check the width, clearance, allowed turns, and final heading against the physical layout. When none of the allowed bends fits, change the port approach or the available space.
|
||||
3. **Compare two search limits.** If the geometry looks feasible, rerun with a larger `search.node_limit` and compare the path endpoint and verified count. The limit applies per search. One run can search the same net several times. Look up the default and related fields in [`SearchOptions`](api-reference.md#searchoptions).
|
||||
|
||||

|
||||
|
||||
The dashed route stops short at three nodes per search. To reproduce both outcomes, try 3 and 500 with the same layout and options in the [best-effort example](../../examples/09_unroutable_best_effort.py).
|
||||
At three nodes per search the dashed path ends before the first keepout. At 500 the solid path clears the obstacles and reaches the target with the required westbound heading. To reproduce the comparison, change `node_limit` from 3 to 500 in a copy of the [best-effort example](../../examples/09_unroutable_best_effort.py).
|
||||
|
||||
## Choose a routing mode
|
||||
|
||||
|
|
@ -43,9 +43,9 @@ Set `TopologyOptions(mode=...)` and pass it as `topology` in `RoutingOptions`.
|
|||
|
||||
| Observation | Next comparison |
|
||||
| --- | --- |
|
||||
| Multiple routes reach their ports and collide with one another | Try a different `congestion.net_order` or allow more `max_iterations`. Compare the unresolved IDs. |
|
||||
| Valid routes use too many small bends | Increase `objective.bend_penalty`. Compare bend counts and physical lengths to see whether a straighter path needs a longer detour. |
|
||||
| Refinement dominates runtime | Try `refinement.max_windows_per_net=1`. Compare the verified paths and cost before adopting the smaller limit. |
|
||||
| Multiple routes reach their ports and collide with one another | Change `net_order` or `max_iterations` one at a time. Compare which nets remain unresolved. See the accepted values in [`CongestionOptions`](api-reference.md#congestionoptions). |
|
||||
| Valid routes use too many small bends | Increase `bend_penalty`. Compare bend counts and physical lengths to see whether a straighter path needs a longer detour. See [`ObjectiveWeights`](api-reference.md#objectiveweights). |
|
||||
| Refinement dominates runtime | Try `max_windows_per_net=1`. Compare runtime, cost, and verified paths before adopting the smaller limit. See [`RefinementOptions`](api-reference.md#refinementoptions). |
|
||||
|
||||
For a shorter refinement pass, derive the new settings from the `options` already used for the layout.
|
||||
|
||||
|
|
@ -62,5 +62,3 @@ faster_refinement = replace(
|
|||
)
|
||||
run = route(problem, options=faster_refinement)
|
||||
```
|
||||
|
||||
For accepted values and defaults, use the [option reference](api-reference.md#options-and-defaults).
|
||||
|
|
|
|||
Loading…
Reference in a new issue