Clarify routing documentation and refresh example figures

This commit is contained in:
Jan Petykiewicz 2026-11-27 11:59:22 -08:00
commit ab97281df3

View file

@ -3,13 +3,13 @@ from inire.utils.visualization import plot_routing_results
def main() -> None:
print("Running Example 05: Orientation Stress Test...")
print("Running Example 05: Port Headings...")
bounds = (0, 0, 200, 200)
netlist = {
"u_turn": (Port(50, 50, 0), Port(50, 70, 180)),
"loop": (Port(100, 100, 90), Port(100, 80, 270)),
"zig_zag": (Port(20, 150, 0), Port(180, 150, 0)),
"east_to_west": (Port(50, 50, 0), Port(50, 70, 180)),
"north_to_south": (Port(100, 100, 90), Port(100, 80, 270)),
"straight": (Port(20, 150, 0), Port(180, 150, 0)),
}
problem = RoutingProblem(
bounds=bounds,
@ -20,7 +20,7 @@ def main() -> None:
objective=ObjectiveWeights(bend_penalty=50.0),
)
print("Routing complex orientation nets...")
print("Routing two heading reversals and one straight connection...")
run = route(problem, options=options)
for net_id, result in run.results_by_net.items():
status = "Success" if result.is_valid else "Failed"