class picazzo3.container.fanout_ports.FanoutPorts(*args, **kwargs)

Fanout Container. Routes all ports listed in port_labels into a given direction, with a given spacing. This is typically used to redirect a set of ports on a component to a regularly spaced array of ports. The user can use this to convert from one input/output waveguide pitch to another, or from irregular input/output waveguide positioning to a regular pitch.

If port_labels is not specified, all ports will be routed.


trace_template: optional

Template for all ports. If None, the waveguide templates of the ports will be used

auto_transition: optional

If True, automatically transition all ports of contents to the given trace template. If False, no transitions are applied, which might lead to a discontinuity in the waveguide. Also, if trace_template is None, no transitions are applied.

port_labels: optional

Labels of the ports to be processed. Set to None to process all ports.

contents: PCell, optional

the contents of the container: the child cell

external_port_names: optional

Dictionary for remapping of the port names of the contents to the external ports

cell_instances: _PCellInstanceDict, optional

name: optional

The unique name of the pcell

trace_templates: List with type restriction, allowed types: <class ‘ipkiss3.pcell.cell.pcell.PCell’>, locked

list of templates to apply to all ports

waveguides: List with type restriction, allowed types: <class ‘ipkiss3.pcell.cell.pcell.PCell’>, locked

bundle: locked

bundle of waveguides added to the contents, generated based on the supplied waveguides list



angle_step: float and number > 0, optional

angle step for rounding

manhattan: optional

adds rectangular blocks in the bends to avoid as much as possible non-manhattan angles

max_s_bend_angle: float and ]0.0,90.0], optional

rounding_algorithm: optional

rounding algorithm used to generate the bends. Can be circular, spline, …

spacing: float, optional

spacing between adjacent output waveguides

target_coordinate: optional

The coordinate where the endpoints of the waveguides are aligned. An x-coordinate when routing toEAST or WEST, a y-coordinate when routing to NORTH or SOUTH. When the waveguides extend beyond thetarget coordinate, the value is ignored.

view_name: str, optional

The name of the view

align_outputs: optional

If True, all outputs will be aligned to the outermost waveguide end, even if it extends beyond its target coordinate.

output_direction: optional

direction of the output waveguides. Should be EAST, WEST, NORTH or SOUTH

reference_coordinate: optional

The coordinate where the first waveguide will be aligned. An x-coordinate if routed towards NORTH or SOUTH,a y-coordinate when routed towards EAST or WEST. If not specified, the x or y coordinate of the first port is taken.

area_layer_on: optional

When True, the waveguide area will be covered by i3.Rectangles on all cover layers.

routes: optional

routes along which the waveguides will be generated

contents_transformation: GenericNoDistortTransform, optional

flatten_contents: optional

if True, it will insert the contents as elements in the layout, rather than as an Instance

bend_radius: float and number > 0, optional

bend radius for the auto-generated bends

grid: float and number > 0, locked

design grid. Extracted by default from TECH.METRICS.GRID

grids_per_unit: locked

Number of grid cells per design unit

max_s_bend_angles: locked

spacings_from_reference: locked

target_coordinates: locked

units_per_grid: locked

Ratio of grid cell and design unit

unit: float and number > 0, locked

design unit. Extracted by default from TECH.METRICS.UNIT


from technologies import silicon_photonics
from picazzo3.filters.ring import RingRect180DropFilter
from picazzo3.container.fanout_ports import FanoutPorts
from ipkiss3 import all as i3

my_ring = RingRect180DropFilter()

from picazzo3.container.fanout_ports import FanoutPorts

my_ring_fanout = FanoutPorts(contents=my_ring,
                             port_labels=["E0", "E1"]

lay = my_ring_fanout.Layout(contents_transformation=i3.Rotation(rotation = 10.0),
                            area_layer_on=False,          # if True, adds area layer on the bundle
                            spacing=20.0,                # spacing between outputs
                            reference_coordinate=-12.5,  # y-coordinate (or x for NORTH and SOUTH) of first waveguide
                            target_coordinate=20.0,      # x-coordinate (or y for NORTH and SOUTH) of output port
                            max_s_bend_angle=45.0,       # maximum angle of S-bend
                            bend_radius=4.5              # bend radius of waveguides
from technologies import silicon_photonics
from picazzo3.filters.ring import RingRect180DropFilter
from picazzo3.traces.wire_wg import WireWaveguideTemplate
from picazzo3.container.fanout_ports import FanoutPorts
from ipkiss3 import all as i3

wg_t1 = WireWaveguideTemplate()
wg_t2 = WireWaveguideTemplate()

my_ring = RingRect180DropFilter(name="ring_for_fanout", coupler_trace_templates=[wg_t1, wg_t2])

my_ring_fanout = FanoutPorts(contents=my_ring,
                             port_labels=["E0", "E1"],
                             auto_transition=True    # adds transitions when the waveguide templates don't match.

layout = my_ring_fanout.Layout(contents_transformation=i3.Rotation(rotation=10.0),
                               area_layer_on=False,         # draws a cover layer between the waveguides
                               spacing=20.0,                # spacing between outputs
                               max_s_bend_angle=60.0,       # maximum angle of S-bend
                               bend_radius=10.0              # bend radius of waveguides