inire/examples/README.md

2.3 KiB

Routing examples

Run an example from the repository root after installation. Each script saves a PNG alongside its source.

python examples/01_simple_route.py
Example What it demonstrates Plot
Simple route Create a problem, route one net, and check validity. PNG
Congestion resolution Separate three nets that compete for routing space. PNG
Locked paths See how a second net detours around an existing route. Use the API guide for the public version of this workflow. PNG
S-bends and radii Route compact offsets with specified bend radii. PNG
Port orientations Route nets with perpendicular and opposing headings. PNG
Bend proxies Compare an arc, a bounding-box proxy for an arc, and a custom physical bend. PNG
Fan-out Inspect where search spends work around a bottleneck. This advanced example adjusts the heuristic between iterations through the internal worker. PNG
Custom bends Supply separate physical and proxy polygons. PNG
Best-effort results Inspect the endpoint of a partial path when search runs with a deliberately tiny budget. PNG

In route plots with the physical overlay enabled, dashed outlines show search proxies and solid outlines show physical geometry. Use the solid outlines to inspect physical clearance. Red paths need attention. Check result.outcome to tell an incomplete path from one that reached the target with a collision. Read the result · Lock a route with the public API

To see the difference between an unfinished search and a blocked layout, try raising node_limit to 500 in the best-effort example. The same geometry then routes to completion. Tune a run