inire/inire
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-11-27 00:48:37 -08:00
..
geometry Share worker setup, residual preparation, and scenario capture 2026-11-27 00:38:00 -08:00
router Sample proximity only for objectives that use it 2026-11-27 00:48:37 -08:00
tests Sample proximity only for objectives that use it 2026-11-27 00:48:37 -08:00
utils use agg for rendering by default 2026-11-25 17:29:35 -08:00
__init__.py Select and verify topological and constructive routing plans 2026-11-26 11:57:43 -08:00
constants.py lots more refactoring 2026-03-30 19:51:37 -07:00
LICENSE.md initial commit 2026-03-06 18:48:04 -08:00
model.py Prefer bend-ended windows in default path refinement 2026-11-26 15:25:21 -08:00
README.md initial commit 2026-03-06 18:48:04 -08:00
results.py Refactor routing internals and archive retry benchmarks 2026-11-26 19:58:46 -08:00
seeds.py lots more refactoring 2026-03-30 19:51:37 -07:00

inire

Use Inire to connect fixed ports on a photonic or RF layout with straight segments, 90-degree bends, and S-bends. Supply the device placement, keepouts, and allowed bend radii. The router checks the finished geometry for clearance and returns partial paths to help you diagnose unfinished nets.

Install

From a checkout with Python 3.11 or newer, run pip install ..

Route a net

from inire import (
    NetSpec, Port, RoutingProblem,
    route,
)

start = Port(50, 100, 0)
target = Port(250, 100, 0)
net = NetSpec("input", start, target)
problem = RoutingProblem(
    bounds=(0, 0, 1000, 1000),
    nets=(net,),
    clearance=2,
)

run = route(problem)
result = run.results_by_net["input"]
if result.is_valid:
    print(result.report.total_length)
else:
    print(result.outcome)

A short solid waveguide connects the start at (50, 100) and target at (250, 100). Both port arrows point east.

The example prints 200.0 in the layout's coordinate unit. Both ports have heading 0 because the path travels east as it leaves the source and enters the target.

Route your own layout

For the full workflow and API reference, start with the user guide.

Develop Inire

  • To set up the development environment and find the relevant routing code, use the developer guide.
  • To measure routing coverage, cost, or runtime, run the routing benchmarks.

License

Inire is distributed under the GNU Affero General Public License v3.