Porting from IPKISS 2025.12 to IPKISS 2026.03
Porting place_and_route instance definitions
In IPKISS 2026.03, the insts argument of i3.place_and_route
is deprecated. Instances should now be declared in the specs list using
i3.Inst.
You can pass a layout object with existing instances (for example the layout argument of generate(self, layout) or the result of a previous place_and_route call). The function copies the input layout and returns a new layout object with the extra instances and routing added according to the specs.
Update your code as follows:
Move instance definitions into the specs list using i3.Inst.
For chained calls, pass the previous result via layout=….
Old (deprecated):
layout = i3.place_and_route(
insts={
"splitter": WgYSplitter(),
"combiner": WgYCombiner(),
"gc1": GratingCoupler(),
"gc2": GratingCoupler(),
},
specs=[
i3.Place("splitter", (0, 0)),
i3.Place("combiner", (30, 20), relative_to="splitter"),
i3.Place("gc1:out", (-100, 0), relative_to="splitter@CW"),
i3.Place("gc2:out", (100, 0), angle=180, relative_to="combiner@CE"),
],
)
New (expected format):
layout = i3.place_and_route(
layout=layout,
specs=[
i3.Inst("splitter", WgYSplitter()),
i3.Inst("combiner", WgYCombiner()),
i3.Inst(["gc1", "gc2"], GratingCoupler()),
i3.Place("splitter", (0, 0)),
i3.Place("combiner", (30, 20), relative_to="splitter"),
i3.Place("gc1:out", (-100, 0), relative_to="splitter@CW"),
i3.Place("gc2:out", (100, 0), angle=180, relative_to="combiner@CE"),
],
)
Porting i3.Circuit instance definitions
The insts property of i3.Circuit is deprecated. Do not pass
insts=… when constructing a circuit and do not implement _default_insts.
Instead, define instances with i3.Inst in the specs list.
Update your code as follows:
Remove insts and _default_insts.
Add instance definitions to _default_specs (or specs=…) using i3.Inst.
Old (deprecated):
class MyCircuit(i3.Circuit):
def _default_insts(self):
return {
"splitter": WgYSplitter(),
"combiner": WgYCombiner(),
}
def _default_specs(self):
return [
i3.Place("splitter", (0, 0)),
i3.Place("combiner", (30, 20), relative_to="splitter"),
]
New (expected format):
class MyCircuit(i3.Circuit):
def _default_specs(self):
return [
i3.Inst("splitter", WgYSplitter()),
i3.Inst("combiner", WgYCombiner()),
i3.Place("splitter", (0, 0)),
i3.Place("combiner", (30, 20), relative_to="splitter"),
]