PCells
Parametric Cells for the Generic PDK.
Consider them a foundation from which you can draw inspiration. Feel free to modify their cross-sections and layers to tailor a unique PDK suited for any foundry of your choice.
By doing so, you'll possess a versatile, retargetable PDK, empowering you to design your circuits with speed and flexibility.
components
analog
inductor
inductor(
width: float = 2.0,
space: float = 2.1,
diameter: float = 25.35,
resistance: float = 0.5777,
inductance: float = 3.3303e-11,
turns: int = 1,
layer_metal: LayerSpec = "M3",
layer_inductor: LayerSpec = "M1",
layer_metal_pin: LayerSpec = "WG_PIN",
layers_no_fill: LayerSpecs = ("DEVREC", "NO_TILE_SI"),
) -> Component
Create a 2-turn inductor.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
Width of the inductor trace in micrometers. |
2.0
|
space
|
float
|
Space between turns in micrometers. |
2.1
|
diameter
|
float
|
Inner diameter in micrometers. |
25.35
|
resistance
|
float
|
Resistance in ohms. |
0.5777
|
inductance
|
float
|
Inductance in henries. |
3.3303e-11
|
turns
|
int
|
Number of turns (default 1 for inductor2). |
1
|
layer_metal
|
LayerSpec
|
Layer for the metal trace. |
'M3'
|
layer_inductor
|
LayerSpec
|
Layer for the inductor region. |
'M1'
|
layer_metal_pin
|
LayerSpec
|
Layer for the metal pins. |
'WG_PIN'
|
layers_no_fill
|
LayerSpecs
|
Layers to exclude from fill. |
('DEVREC', 'NO_TILE_SI')
|
Returns:
| Type | Description |
|---|---|
Component
|
Component with inductor layout. |
Source code in gdsfactory/components/analog/inductors.py
30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 | |

interdigital_capacitor
interdigital_capacitor
interdigital_capacitor(
fingers: int = 4,
finger_length: float | int = 20.0,
finger_gap: float | int = 2.0,
thickness: float | int = 5.0,
layer: LayerSpec = "WG",
) -> Component
Generate an interdigital capacitor component with ports on both ends.
An interdigital capacitor consists of interleaved metal fingers that create a distributed capacitance. This component creates a planar capacitor with two sets of interleaved fingers extending from opposite ends.
See for example Zhu et al., Accurate circuit model of interdigital
capacitor and its application to design of new quasi-lumped miniaturized
filters with suppression of harmonic resonance, doi: 10.1109/22.826833.
Note
finger_length=0 effectively provides a parallel plate capacitor.
The capacitance scales approximately linearly with the number of fingers
and finger length.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
fingers
|
int
|
Total number of fingers of the capacitor (must be >= 1). |
4
|
finger_length
|
float | int
|
Length of each finger in μm. |
20.0
|
finger_gap
|
float | int
|
Gap between adjacent fingers in μm. |
2.0
|
thickness
|
float | int
|
Thickness of fingers and the base section in μm. |
5.0
|
layer
|
LayerSpec
|
Layer specification for the capacitor geometry. |
'WG'
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory component with the interdigital capacitor geometry |
Component
|
and two ports ('o1' and 'o2') on opposing sides. |
Source code in gdsfactory/components/analog/interdigital_capacitor.py
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 | |

interdigitated_electrodes
interdigitated_electrodes
interdigitated_electrodes(
n_fingers: int = 10,
finger_width: float = 0.5,
finger_length: float = 10.0,
finger_gap: float = 0.5,
bus_width: float = 2.0,
bus_length: float | None = None,
layer: LayerSpec = "MTOP",
port_type: str = "electrical",
) -> Component
Interdigitated electrode pattern.
Two horizontal bus bars (top and bottom) with alternating fingers extending from each bus toward the opposite one. Fingers from the top bus extend downward and fingers from the bottom bus extend upward, interleaving with a gap between the finger tips and the opposite bus.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
n_fingers
|
int
|
Total number of fingers (split between top and bottom buses). |
10
|
finger_width
|
float
|
Width of each finger in um. |
0.5
|
finger_length
|
float
|
Length of each finger in um. |
10.0
|
finger_gap
|
float
|
Gap between adjacent fingers (edge to edge) in um. |
0.5
|
bus_width
|
float
|
Width (height) of each bus bar in um. |
2.0
|
bus_length
|
float | None
|
Length of each bus bar in um. Defaults to the total width needed to accommodate all fingers. |
None
|
layer
|
LayerSpec
|
Layer specification for all geometry. |
'MTOP'
|
port_type
|
str
|
Port type for electrical ports at bus bar ends. |
'electrical'
|
Source code in gdsfactory/components/analog/interdigitated_electrodes.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 | |

bends
bend_circular
bend_circular
bend_circular(
radius: float | None = None,
angle: float = 90.0,
npoints: int | None = None,
angular_step: float | None = None,
layer: LayerSpec | None = None,
width: float | None = None,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
) -> Component
Returns a radial arc.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
in um. Defaults to cross_section_radius. |
None
|
angle
|
float
|
angle of arc (degrees). |
90.0
|
npoints
|
int | None
|
number of points. |
None
|
angular_step
|
float | None
|
If provided, determines the angular step (in degrees) between points. Mutually exclusive with npoints. |
None
|
layer
|
LayerSpec | None
|
layer to use. Defaults to cross_section.layer. |
None
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
cross_section
|
CrossSectionSpec
|
spec (CrossSection, string or dict). |
'strip'
|
allow_min_radius_violation
|
bool
|
if True allows radius to be smaller than cross_section radius. |
False
|
Source code in gdsfactory/components/bends/bend_circular.py
114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 | |
bend_circular_all_angle
bend_circular_all_angle(
radius: float | None = None,
angle: float = 90.0,
npoints: int | None = None,
angular_step: float | None = None,
layer: LayerSpec | None = None,
width: float | None = None,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
) -> ComponentAllAngle
Returns a radial arc.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
in um. Defaults to cross_section_radius. |
None
|
angle
|
float
|
angle of arc (degrees). |
90.0
|
npoints
|
int | None
|
number of points. |
None
|
angular_step
|
float | None
|
If provided, determines the angular step (in degrees) between points. Mutually exclusive with npoints. |
None
|
layer
|
LayerSpec | None
|
layer to use. Defaults to cross_section.layer. |
None
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
cross_section
|
CrossSectionSpec
|
spec (CrossSection, string or dict). |
'strip'
|
allow_min_radius_violation
|
bool
|
if True allows radius to be smaller than cross_section radius. |
False
|
Source code in gdsfactory/components/bends/bend_circular.py
156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 | |

bend_circular_all_angle
bend_circular_all_angle(
radius: float | None = None,
angle: float = 90.0,
npoints: int | None = None,
angular_step: float | None = None,
layer: LayerSpec | None = None,
width: float | None = None,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
) -> ComponentAllAngle
Returns a radial arc.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
in um. Defaults to cross_section_radius. |
None
|
angle
|
float
|
angle of arc (degrees). |
90.0
|
npoints
|
int | None
|
number of points. |
None
|
angular_step
|
float | None
|
If provided, determines the angular step (in degrees) between points. Mutually exclusive with npoints. |
None
|
layer
|
LayerSpec | None
|
layer to use. Defaults to cross_section.layer. |
None
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
cross_section
|
CrossSectionSpec
|
spec (CrossSection, string or dict). |
'strip'
|
allow_min_radius_violation
|
bool
|
if True allows radius to be smaller than cross_section radius. |
False
|
Source code in gdsfactory/components/bends/bend_circular.py
156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 | |
import gdsfactory as gf
gf.gpdk.PDK.activate()
c = gf.components.bend_circular_all_angle(angle=90, cross_section='strip', allow_min_radius_violation=False).copy()
c.draw_ports()
c.plot()
bend_circular_heater
bend_circular_heater
bend_circular_heater(
radius: float | None = None,
angle: float = 90,
npoints: int | None = None,
heater_to_wg_distance: float = 1.2,
heater_width: float = 0.5,
layer_heater: LayerSpec = "HEATER",
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
) -> Component
Creates an arc of arclength theta starting at angle start_angle.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
in um. Defaults to cross_section.radius. |
None
|
angle
|
float
|
angle of arc (degrees). |
90
|
npoints
|
int | None
|
Number of points used per 360 degrees. |
None
|
heater_to_wg_distance
|
float
|
in um. |
1.2
|
heater_width
|
float
|
in um. |
0.5
|
layer_heater
|
LayerSpec
|
for heater. |
'HEATER'
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string, CrossSectionFactory dict). |
'strip'
|
allow_min_radius_violation
|
bool
|
if True allows radius to be smaller than cross_section radius. |
False
|
Source code in gdsfactory/components/bends/bend_circular_heater.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 | |

bend_euler
bend_euler
bend_euler(
radius: float | None = None,
angle: float = 90.0,
p: float = 0.5,
with_arc_floorplan: bool = True,
npoints: int | None = None,
angular_step: float | None = None,
layer: LayerSpec | None = None,
width: float | None = None,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
) -> Component
Regular degree euler bend.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
in um. Defaults to cross_section_radius. |
None
|
angle
|
float
|
total angle of the curve. |
90.0
|
p
|
float
|
Proportion of the curve that is an Euler curve. |
0.5
|
with_arc_floorplan
|
bool
|
if True the size of the bend will be adjusted to match an arc bend with the specified radius. If False: |
True
|
npoints
|
int | None
|
Number of points used per 360 degrees. |
None
|
angular_step
|
float | None
|
if not None, the angle step in degrees for the all_angle bend. |
None
|
layer
|
LayerSpec | None
|
layer to use. Defaults to cross_section.layer. |
None
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string, CrossSectionFactory dict). |
'strip'
|
allow_min_radius_violation
|
bool
|
if True allows radius to be smaller than cross_section radius. |
False
|
Source code in gdsfactory/components/bends/bend_euler.py
209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 | |
bend_euler_all_angle
bend_euler_all_angle(
radius: float | None = None,
angle: float = 90.0,
p: float = 0.5,
with_arc_floorplan: bool = True,
npoints: int | None = None,
angular_step: float | None = None,
layer: LayerSpec | None = None,
width: float | None = None,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
) -> ComponentAllAngle
Regular degree euler bend.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
in um. Defaults to cross_section_radius. |
None
|
angle
|
float
|
total angle of the curve. |
90.0
|
p
|
float
|
Proportion of the curve that is an Euler curve. |
0.5
|
with_arc_floorplan
|
bool
|
If False: |
True
|
npoints
|
int | None
|
Number of points used per 360 degrees. |
None
|
angular_step
|
float | None
|
if not None, the angle step in degrees for the all_angle bend. |
None
|
layer
|
LayerSpec | None
|
layer to use. Defaults to cross_section.layer. |
None
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string, CrossSectionFactory dict). |
'strip'
|
allow_min_radius_violation
|
bool
|
if True allows radius to be smaller than cross_section radius. |
False
|
Source code in gdsfactory/components/bends/bend_euler.py
258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 | |
bend_euler_s
bend_euler_s(
radius: float | None = None,
p: float = 0.5,
with_arc_floorplan: bool = True,
npoints: int | None = None,
angular_step: float | None = None,
layer: LayerSpec | None = None,
width: float | None = None,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
port1: str = "o1",
port2: str = "o2",
) -> Component
Sbend made of 2 euler bends.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
in um. Defaults to cross_section_radius. |
None
|
p
|
float
|
Proportion of the curve that is an Euler curve. |
0.5
|
with_arc_floorplan
|
bool
|
If False: |
True
|
npoints
|
int | None
|
Number of points used per 360 degrees. |
None
|
angular_step
|
float | None
|
if not None, the angle step in degrees for the all_angle bend. |
None
|
layer
|
LayerSpec | None
|
layer to use. Defaults to cross_section.layer. |
None
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string, CrossSectionFactory dict). |
'strip'
|
allow_min_radius_violation
|
bool
|
if True allows radius to be smaller than cross_section radius. |
False
|
port1
|
str
|
input port name. |
'o1'
|
port2
|
str
|
output port name.
o1_____/ |
'o2'
|
Source code in gdsfactory/components/bends/bend_euler.py
147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |

bend_euler_all_angle
bend_euler_all_angle(
radius: float | None = None,
angle: float = 90.0,
p: float = 0.5,
with_arc_floorplan: bool = True,
npoints: int | None = None,
angular_step: float | None = None,
layer: LayerSpec | None = None,
width: float | None = None,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
) -> ComponentAllAngle
Regular degree euler bend.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
in um. Defaults to cross_section_radius. |
None
|
angle
|
float
|
total angle of the curve. |
90.0
|
p
|
float
|
Proportion of the curve that is an Euler curve. |
0.5
|
with_arc_floorplan
|
bool
|
If False: |
True
|
npoints
|
int | None
|
Number of points used per 360 degrees. |
None
|
angular_step
|
float | None
|
if not None, the angle step in degrees for the all_angle bend. |
None
|
layer
|
LayerSpec | None
|
layer to use. Defaults to cross_section.layer. |
None
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string, CrossSectionFactory dict). |
'strip'
|
allow_min_radius_violation
|
bool
|
if True allows radius to be smaller than cross_section radius. |
False
|
Source code in gdsfactory/components/bends/bend_euler.py
258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 | |
import gdsfactory as gf
gf.gpdk.PDK.activate()
c = gf.components.bend_euler_all_angle(angle=90, p=0.5, with_arc_floorplan=True, cross_section='strip', allow_min_radius_violation=False).copy()
c.draw_ports()
c.plot()
bend_euler_s
bend_euler_s(
radius: float | None = None,
p: float = 0.5,
with_arc_floorplan: bool = True,
npoints: int | None = None,
angular_step: float | None = None,
layer: LayerSpec | None = None,
width: float | None = None,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
port1: str = "o1",
port2: str = "o2",
) -> Component
Sbend made of 2 euler bends.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
in um. Defaults to cross_section_radius. |
None
|
p
|
float
|
Proportion of the curve that is an Euler curve. |
0.5
|
with_arc_floorplan
|
bool
|
If False: |
True
|
npoints
|
int | None
|
Number of points used per 360 degrees. |
None
|
angular_step
|
float | None
|
if not None, the angle step in degrees for the all_angle bend. |
None
|
layer
|
LayerSpec | None
|
layer to use. Defaults to cross_section.layer. |
None
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string, CrossSectionFactory dict). |
'strip'
|
allow_min_radius_violation
|
bool
|
if True allows radius to be smaller than cross_section radius. |
False
|
port1
|
str
|
input port name. |
'o1'
|
port2
|
str
|
output port name.
o1_____/ |
'o2'
|
Source code in gdsfactory/components/bends/bend_euler.py
147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |

bend_s
bend_s
bend_s(
size: Size = (11.0, 1.8),
npoints: int = 99,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
width: float | None = None,
) -> Component
Return S bend with bezier curve.
stores min_bend_radius property in self.info['min_bend_radius'] min_bend_radius depends on height and length
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
Size
|
in x and y direction. |
(11.0, 1.8)
|
npoints
|
int
|
number of points. |
99
|
cross_section
|
CrossSectionSpec
|
spec. |
'strip'
|
allow_min_radius_violation
|
bool
|
bool. |
False
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
Source code in gdsfactory/components/bends/bend_s.py
166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 | |
bend_s_offset
bend_s_offset(
offset: float = 40.0,
radius: float | None = 10.0,
cross_section: CrossSectionSpec = "strip",
width: float | None = None,
with_euler: bool | None = None,
p: float = 1,
with_arc_floorplan: bool = False,
npoints: int | None = None,
angular_step: float | None = None,
) -> gf.Component
Return S bend made of two bends with a straight section.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
offset
|
float
|
in um. |
40.0
|
radius
|
float | None
|
in um. if None, uses cross_section_radius. |
10.0
|
cross_section
|
CrossSectionSpec
|
spec. |
'strip'
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
with_euler
|
bool | None
|
deprecated, use p=0 for circular arc instead. |
None
|
p
|
float
|
1 means standard Euler bend. 0 means circular arc. |
1
|
with_arc_floorplan
|
bool
|
if True the size of the bend will be adjusted to match an arc bend with the specified radius. If False: |
False
|
npoints
|
int | None
|
number of points. |
None
|
angular_step
|
float | None
|
If provided, determines the angular step (in degrees) between points. Mutually exclusive with npoints. |
None
|
Source code in gdsfactory/components/bends/bend_s.py
252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 | |
bezier
bezier(
control_points: Coordinates = (
(0.0, 0.0),
(5.0, 0.0),
(5.0, 1.8),
(10.0, 1.8),
),
npoints: int = 201,
with_manhattan_facing_angles: bool = True,
start_angle: int | None = None,
end_angle: int | None = None,
cross_section: CrossSectionSpec = "strip",
bend_radius_error_type: ErrorType | None = None,
allow_min_radius_violation: bool = False,
width: float | None = None,
) -> Component
Returns Bezier bend.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
control_points
|
Coordinates
|
list of points. |
((0.0, 0.0), (5.0, 0.0), (5.0, 1.8), (10.0, 1.8))
|
npoints
|
int
|
number of points varying between 0 and 1. |
201
|
with_manhattan_facing_angles
|
bool
|
bool. |
True
|
start_angle
|
int | None
|
optional start angle in deg. |
None
|
end_angle
|
int | None
|
optional end angle in deg. |
None
|
cross_section
|
CrossSectionSpec
|
spec. |
'strip'
|
bend_radius_error_type
|
ErrorType | None
|
error type. |
None
|
allow_min_radius_violation
|
bool
|
bool. |
False
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
Source code in gdsfactory/components/bends/bend_s.py
43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 | |
bezier_curve
bezier_curve(
t: NDArray[floating[Any]], control_points: Coordinates
) -> npt.NDArray[np.floating[Any]]
Returns bezier coordinates.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
t
|
NDArray[floating[Any]]
|
1D array of points varying between 0 and 1. |
required |
control_points
|
Coordinates
|
for the bezier curve. |
required |
Source code in gdsfactory/components/bends/bend_s.py
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | |
find_min_curv_bezier_control_points
find_min_curv_bezier_control_points(
start_point: Coordinate,
end_point: Coordinate,
start_angle: float,
end_angle: float,
npoints: int = 201,
alpha: float = 0.05,
nb_pts: int = 2,
) -> Coordinates
Returns bezier control points that minimize curvature.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
start_point
|
Coordinate
|
start point. |
required |
end_point
|
Coordinate
|
end point. |
required |
start_angle
|
float
|
start angle in deg. |
required |
end_angle
|
float
|
end angle in deg. |
required |
npoints
|
int
|
number of points varying between 0 and 1. |
201
|
alpha
|
float
|
weight for angle mismatch. |
0.05
|
nb_pts
|
int
|
number of control points. |
2
|
Source code in gdsfactory/components/bends/bend_s.py
107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 | |
get_min_sbend_size
get_min_sbend_size(
size: tuple[float | None, float | None] = (None, 10.0),
cross_section: CrossSectionSpec = "strip",
num_points: int = 100,
) -> float
Returns the minimum sbend size to comply with bend radius requirements.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
tuple[float | None, float | None]
|
in x and y direction. One of them is None, which is the size we need to figure out. |
(None, 10.0)
|
cross_section
|
CrossSectionSpec
|
spec. |
'strip'
|
num_points
|
int
|
number of points to iterate over between max_size and 0.1 * max_size. |
100
|
Source code in gdsfactory/components/bends/bend_s.py
321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 | |

bend_s_offset
bend_s_offset(
offset: float = 40.0,
radius: float | None = 10.0,
cross_section: CrossSectionSpec = "strip",
width: float | None = None,
with_euler: bool | None = None,
p: float = 1,
with_arc_floorplan: bool = False,
npoints: int | None = None,
angular_step: float | None = None,
) -> gf.Component
Return S bend made of two bends with a straight section.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
offset
|
float
|
in um. |
40.0
|
radius
|
float | None
|
in um. if None, uses cross_section_radius. |
10.0
|
cross_section
|
CrossSectionSpec
|
spec. |
'strip'
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
with_euler
|
bool | None
|
deprecated, use p=0 for circular arc instead. |
None
|
p
|
float
|
1 means standard Euler bend. 0 means circular arc. |
1
|
with_arc_floorplan
|
bool
|
if True the size of the bend will be adjusted to match an arc bend with the specified radius. If False: |
False
|
npoints
|
int | None
|
number of points. |
None
|
angular_step
|
float | None
|
If provided, determines the angular step (in degrees) between points. Mutually exclusive with npoints. |
None
|
Source code in gdsfactory/components/bends/bend_s.py
252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 | |

bend_topic
bend_topic
bend_topic(
radius: float | None = None,
angle: float = 90.0,
p: float = 0.1,
npoints: int = 100,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
layer: LayerSpec | None = None,
width: float | None = None,
) -> Component
Returns a regular degree Third Order Polynomial Interconnected Circular (TOPIC) bend component.
The implementation follows the description in this publication https://arxiv.org/html/2411.15025v1.
The bend consists of three parts: a. Initial transition from straight to bend, known as TOP segment. b. Circular part whose center and radius are calculated analytically. c. Mirroring of TOP segment with respect to the bisection of the angle.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
radius at the start and end of bend. |
None
|
angle
|
float
|
total angle of the curve in degrees. |
90.0
|
p
|
float
|
used to calculate the angle of the bend at the end of TOP / start of circular arc, as p*angle. It should be within [0, 0.5). |
0.1
|
npoints
|
int
|
Number of points used per 360 degrees. |
100
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string, CrossSectionFactory dict). |
'strip'
|
allow_min_radius_violation
|
bool
|
if True allows radius to be smaller than cross_section radius. |
False
|
layer
|
LayerSpec | None
|
layer to use. Defaults to cross_section.layer. |
None
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
Source code in gdsfactory/components/bends/bend_topic.py
133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 | |
bend_topic_all_angle
bend_topic_all_angle(
radius: float | None = None,
angle: float = 90.0,
p: float = 0.1,
npoints: int = 100,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
layer: LayerSpec | None = None,
width: float | None = None,
) -> ComponentAllAngle
Returns a Third Order Polynomial Interconnected Circular (TOPIC) bend component of arbitrary angle.
The implementation follows the description in this publication https://arxiv.org/html/2411.15025v1.
The bend consists of three parts: a. Initial transition from straight to bend, known as TOP segment. b. Circular part whose center and radius are calculated analytically. c. Mirroring of TOP segment with respect to the bisection of the angle.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
radius at the start and end of bend. |
None
|
angle
|
float
|
total angle of the curve in degrees. |
90.0
|
p
|
float
|
used to calculate the angle of the bend at the end of TOP / start of circular arc, as p*angle. It should be within [0, 0.5). |
0.1
|
npoints
|
int
|
Number of points used per 360 degrees. |
100
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string, CrossSectionFactory dict). |
'strip'
|
allow_min_radius_violation
|
bool
|
if True allows radius to be smaller than cross_section radius. |
False
|
layer
|
LayerSpec | None
|
layer to use. Defaults to cross_section.layer. |
None
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
Source code in gdsfactory/components/bends/bend_topic.py
182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 | |
bend_topic_s
bend_topic_s(
radius: float | None = None,
p: float = 0.1,
npoints: int = 100,
layer: LayerSpec | None = None,
width: float | None = None,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
port1: str = "o1",
port2: str = "o2",
) -> Component
Sbend made of 2 topic bends.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
radius at the start and end of bend. |
None
|
p
|
float
|
used to calculate the angle of the bend at the end of TOP / start of circular arc, as p*angle. It should be within [0, 0.5). |
0.1
|
npoints
|
int
|
Number of points used per 360 degrees. |
100
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string, CrossSectionFactory dict). |
'strip'
|
allow_min_radius_violation
|
bool
|
if True allows radius to be smaller than cross_section radius. |
False
|
layer
|
LayerSpec | None
|
layer to use. Defaults to cross_section.layer. |
None
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
port1
|
str
|
input port name. |
'o1'
|
port2
|
str
|
output port name.
o1_____/ |
'o2'
|
Source code in gdsfactory/components/bends/bend_topic.py
225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 | |

bend_topic180
module-attribute
bend_topic180 = partial(bend_topic, angle=180)

bend_topic_all_angle
bend_topic_all_angle(
radius: float | None = None,
angle: float = 90.0,
p: float = 0.1,
npoints: int = 100,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
layer: LayerSpec | None = None,
width: float | None = None,
) -> ComponentAllAngle
Returns a Third Order Polynomial Interconnected Circular (TOPIC) bend component of arbitrary angle.
The implementation follows the description in this publication https://arxiv.org/html/2411.15025v1.
The bend consists of three parts: a. Initial transition from straight to bend, known as TOP segment. b. Circular part whose center and radius are calculated analytically. c. Mirroring of TOP segment with respect to the bisection of the angle.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
radius at the start and end of bend. |
None
|
angle
|
float
|
total angle of the curve in degrees. |
90.0
|
p
|
float
|
used to calculate the angle of the bend at the end of TOP / start of circular arc, as p*angle. It should be within [0, 0.5). |
0.1
|
npoints
|
int
|
Number of points used per 360 degrees. |
100
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string, CrossSectionFactory dict). |
'strip'
|
allow_min_radius_violation
|
bool
|
if True allows radius to be smaller than cross_section radius. |
False
|
layer
|
LayerSpec | None
|
layer to use. Defaults to cross_section.layer. |
None
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
Source code in gdsfactory/components/bends/bend_topic.py
182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 | |
import gdsfactory as gf
gf.gpdk.PDK.activate()
c = gf.components.bend_topic_all_angle(angle=90, p=0.1, npoints=100, cross_section='strip', allow_min_radius_violation=False).copy()
c.draw_ports()
c.plot()
bend_topic_s
bend_topic_s(
radius: float | None = None,
p: float = 0.1,
npoints: int = 100,
layer: LayerSpec | None = None,
width: float | None = None,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
port1: str = "o1",
port2: str = "o2",
) -> Component
Sbend made of 2 topic bends.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
radius at the start and end of bend. |
None
|
p
|
float
|
used to calculate the angle of the bend at the end of TOP / start of circular arc, as p*angle. It should be within [0, 0.5). |
0.1
|
npoints
|
int
|
Number of points used per 360 degrees. |
100
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string, CrossSectionFactory dict). |
'strip'
|
allow_min_radius_violation
|
bool
|
if True allows radius to be smaller than cross_section radius. |
False
|
layer
|
LayerSpec | None
|
layer to use. Defaults to cross_section.layer. |
None
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
port1
|
str
|
input port name. |
'o1'
|
port2
|
str
|
output port name.
o1_____/ |
'o2'
|
Source code in gdsfactory/components/bends/bend_topic.py
225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 | |

bezier
bezier(
control_points: Coordinates = (
(0.0, 0.0),
(5.0, 0.0),
(5.0, 1.8),
(10.0, 1.8),
),
npoints: int = 201,
with_manhattan_facing_angles: bool = True,
start_angle: int | None = None,
end_angle: int | None = None,
cross_section: CrossSectionSpec = "strip",
bend_radius_error_type: ErrorType | None = None,
allow_min_radius_violation: bool = False,
width: float | None = None,
) -> Component
Returns Bezier bend.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
control_points
|
Coordinates
|
list of points. |
((0.0, 0.0), (5.0, 0.0), (5.0, 1.8), (10.0, 1.8))
|
npoints
|
int
|
number of points varying between 0 and 1. |
201
|
with_manhattan_facing_angles
|
bool
|
bool. |
True
|
start_angle
|
int | None
|
optional start angle in deg. |
None
|
end_angle
|
int | None
|
optional end angle in deg. |
None
|
cross_section
|
CrossSectionSpec
|
spec. |
'strip'
|
bend_radius_error_type
|
ErrorType | None
|
error type. |
None
|
allow_min_radius_violation
|
bool
|
bool. |
False
|
width
|
float | None
|
width to use. Defaults to cross_section.width. |
None
|
Source code in gdsfactory/components/bends/bend_s.py
43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 | |

containers
add_fiber_array_optical_south_electrical_north
add_fiber_array_optical_south_electrical_north
add_fiber_array_optical_south_electrical_north(
component: ComponentSpec = "straight_heater_metal",
pad: ComponentSpec = "pad",
grating_coupler: ComponentSpec = "grating_coupler_te",
cross_section_metal: CrossSectionSpec = "metal_routing",
with_loopback: bool = True,
pad_pitch: float = 100.0,
pitch: float = 127.0,
pad_gc_spacing: float = 250.0,
electrical_port_names: list[str] | None = None,
electrical_port_orientation: AngleInDegrees | None = 90,
npads: int | None = None,
port_types_grating_couplers: list[str] | None = None,
auto_taper_pads: bool = True,
**kwargs: Any
) -> Component
Returns a fiber array with Optical gratings on South and Electrical pads on North.
This a test configuration for DC pads.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
component spec to add fiber and pads. |
'straight_heater_metal'
|
pad
|
ComponentSpec
|
pad spec. |
'pad'
|
grating_coupler
|
ComponentSpec
|
grating coupler function. |
'grating_coupler_te'
|
cross_section_metal
|
CrossSectionSpec
|
metal cross section. |
'metal_routing'
|
with_loopback
|
bool
|
whether to add a loopback port. |
True
|
pad_pitch
|
float
|
spacing between pads. |
100.0
|
pitch
|
float
|
spacing between grating couplers. |
127.0
|
pad_gc_spacing
|
float
|
spacing between pads and grating couplers. |
250.0
|
electrical_port_names
|
list[str] | None
|
list of electrical port names. Defaults to all. |
None
|
electrical_port_orientation
|
AngleInDegrees | None
|
orientation of electrical ports. Defaults to 90. |
90
|
npads
|
int | None
|
number of pads. Defaults to one per electrical_port_names. |
None
|
port_types_grating_couplers
|
list[str] | None
|
port types for grating couplers. Defaults to vertical TE, TM, and dual. |
None
|
auto_taper_pads
|
bool
|
whether to add a taper to the pads. |
True
|
kwargs
|
Any
|
additional arguments. |
{}
|
Other Parameters:
| Name | Type | Description |
|---|---|---|
layer_label |
layer for settings label. |
|
measurement |
measurement name. |
|
measurement_settings |
measurement settings. |
|
analysis |
analysis name. |
|
doe |
Design of Experiment. |
|
anchor |
anchor point for the label. Defaults to south-west "sw". Valid options are: "n", "s", "e", "w", "ne", "nw", "se", "sw", "c". |
|
gc_port_name |
grating coupler input port name. |
|
gc_port_labels |
grating coupler list of labels. |
|
component_name |
optional for the label. |
|
select_ports |
function to select ports. |
|
cross_section |
cross_section function. |
|
get_input_labels_function |
function to get input labels. None skips labels. |
|
layer_label |
optional layer for grating coupler label. |
|
bend |
bend spec. |
|
straight |
straight spec. |
|
taper |
taper spec. |
|
get_input_label_text_loopback_function |
function to get input label test. |
|
get_input_label_text_function |
for labels. |
|
fanout_length |
if None, automatic calculation of fanout length. |
|
max_y0_optical |
in um. |
|
with_loopback |
bool
|
True, adds loopback structures. |
straight_separation |
from edge to edge. |
|
list_port_labels |
None, adds TM labels to port indices in this list. |
|
connected_port_list_ids |
names of ports only for type 0 optical routing. |
|
nb_optical_ports_lines |
number of grating coupler lines. |
|
force_manhattan |
False |
|
excluded_ports |
list of port names to exclude when adding gratings. |
|
grating_indices |
list of grating coupler indices. |
|
routing_straight |
function to route. |
|
routing_method |
route_bundle. |
|
gc_rotation |
fiber coupler rotation in degrees. Defaults to -90. |
|
input_port_indexes |
to connect. |
Source code in gdsfactory/components/containers/add_fiber_array_optical_south_electrical_north.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 | |

add_termination
add_termination
add_termination(
component: ComponentSpec = "straight",
port_names: tuple[str, ...] | None = None,
terminator: ComponentSpec = _terminator_function,
terminator_port_name: str | None = None,
) -> Component
Returns component with terminator on some ports.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
to add terminator. |
'straight'
|
port_names
|
tuple[str, ...] | None
|
ports to add terminator. |
None
|
terminator
|
ComponentSpec
|
factory for the terminator. |
_terminator_function
|
terminator_port_name
|
str | None
|
for the terminator to connect to the component ports. |
None
|
Source code in gdsfactory/components/containers/add_termination.py
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 | |

add_trenches
add_trenches
add_trenches(
component: ComponentSpec = "coupler",
layer_component: LayerSpec = "WG",
layer_trench: LayerSpec = "DEEP_ETCH",
width_trench: float = 2.0,
cross_section: CrossSectionSpec | None = None,
top: float | None = None,
bot: float | None = None,
right: float | None = 0,
left: float | None = 0,
) -> gf.Component
Return inverted component with trenches.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
component to add to the trenches. |
'coupler'
|
layer_component
|
LayerSpec
|
layer of the component to invert. |
'WG'
|
layer_trench
|
LayerSpec
|
layer of the trenches. |
'DEEP_ETCH'
|
width_trench
|
float
|
width of the trenches. |
2.0
|
cross_section
|
CrossSectionSpec | None
|
spec (CrossSection, string or dict). |
None
|
top
|
float | None
|
width of the trench on the top. If None uses width_trench. |
None
|
bot
|
float | None
|
width of the trench on the bottom. If None uses width_trench. |
None
|
right
|
float | None
|
width of the trench on the right. If None uses width_trench. |
0
|
left
|
float | None
|
width of the trench on the left. If None uses width_trench. |
0
|
Source code in gdsfactory/components/containers/add_trenches.py
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 | |

add_trenches90
module-attribute
add_trenches90 = partial(
add_trenches,
component="bend_euler",
top=0,
left=0,
right=None,
)

array
array(
component: ComponentSpec = "pad",
columns: int = 6,
rows: int = 1,
column_pitch: float = 150,
row_pitch: float = 150,
add_ports: bool = True,
size: Size | None = None,
centered: bool = False,
post_process: PostProcesses | None = None,
auto_rename_ports: bool = False,
) -> Component
Returns an array of components.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
to replicate. |
'pad'
|
columns
|
int
|
in x. |
6
|
rows
|
int
|
in y. |
1
|
column_pitch
|
float
|
pitch between columns. |
150
|
row_pitch
|
float
|
pitch between rows. |
150
|
auto_rename_ports
|
bool
|
True to auto rename ports. |
False
|
add_ports
|
bool
|
add ports from component into the array. |
True
|
size
|
Size | None
|
Optional x, y size. Overrides columns and rows. |
None
|
centered
|
bool
|
center the array around the origin. |
False
|
post_process
|
PostProcesses | None
|
function to apply to the array after creation. |
None
|
Raises:
| Type | Description |
|---|---|
ValueError
|
If columns > 1 and spacing[0] = 0. |
ValueError
|
If rows > 1 and spacing[1] = 0. |
Source code in gdsfactory/components/containers/array_component.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 | |

array_hexagonal
array_hexagonal
array_hexagonal(
component: ComponentSpec = "circle",
columns: int = 10,
rows: int = 10,
pitch: float = 25.0,
centered: bool = True,
add_ports: bool = True,
) -> Component
Returns a hexagonal close-packed array of components.
Even rows are placed normally, odd rows are offset by pitch/2. Row spacing is pitch * sqrt(3)/2.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
component to replicate. |
'circle'
|
columns
|
int
|
number of columns. |
10
|
rows
|
int
|
number of rows. |
10
|
pitch
|
float
|
spacing between adjacent elements. |
25.0
|
centered
|
bool
|
center the array around the origin. |
True
|
add_ports
|
bool
|
add ports from each element. |
True
|
Source code in gdsfactory/components/containers/array_hexagonal.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 | |

array_polar
array_polar
array_polar(
component: ComponentSpec = "C",
n_items: int = 6,
radius: float = 50.0,
start_angle: float = 0.0,
end_angle: float = 360.0,
rotate_items: bool = True,
add_ports: bool = True,
) -> Component
Returns a polar/circular array of components.
Places component refs at equal angular intervals around a circle.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
component to replicate. |
'C'
|
n_items
|
int
|
number of items in the array. |
6
|
radius
|
float
|
radius of the circle. |
50.0
|
start_angle
|
float
|
starting angle in degrees. |
0.0
|
end_angle
|
float
|
ending angle in degrees. |
360.0
|
rotate_items
|
bool
|
if True, rotate each item to point radially outward. |
True
|
add_ports
|
bool
|
add ports from each element. |
True
|
Source code in gdsfactory/components/containers/array_polar.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 | |

component_sequence
SequenceGenerator
Source code in gdsfactory/components/containers/component_sequence.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 | |
__init__
__init__(
start_sequence: str = "IL",
repeated_sequence: str = "ASASBSBS",
end_sequence: str = "LO",
) -> None
Sequence generator.
Main use case: any type of cascade of components with repeating patterns such as serpentine, cutbacks etc... Component sequences have two ports by default. it adds aliases for the components forming the sequence. They use the component symbol with a suffix index starting from 1, so you may access the ports from any subcomponent.
Usually we can break these components in 3 parts: - there is a starting pattern with input and possibly some special connections - then a repeating pattern - An ending pattern with an output
Example of symbol meaning
A: bend connected with input W0 B: bend connected with input N0 I: taper with input '1' O: taper with input '2' S: short straight waveguide L: long straight waveguide
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
start_sequence
|
str
|
starting sequence. |
'IL'
|
end_sequence
|
str
|
ending sequence. |
'LO'
|
repeated_sequence
|
str
|
repeating sequence. |
'ASASBSBS'
|
Source code in gdsfactory/components/containers/component_sequence.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 | |
component_sequence
component_sequence(
sequence: str,
symbol_to_component: dict[
str, tuple[Component, str, str]
],
ports_map: dict[str, tuple[str, str]] | None = None,
port_name1: str = "o1",
port_name2: str = "o2",
start_orientation: AngleInDegrees = 0.0,
**kwargs: Any
) -> Component
Returns component from ASCII sequence.
if you prefix a symbol with ! it mirrors the component
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
sequence
|
str
|
a string or a list of symbols. |
required |
symbol_to_component
|
dict[str, tuple[Component, str, str]]
|
maps symbols to (component, input, output). |
required |
ports_map
|
dict[str, tuple[str, str]] | None
|
(optional) extra port mapping using the convention. |
None
|
port_name1
|
str
|
input port_name. |
'o1'
|
port_name2
|
str
|
output port_name. |
'o2'
|
start_orientation
|
AngleInDegrees
|
in degrees. |
0.0
|
**kwargs
|
Any
|
additional keyword arguments passed to the connect method. |
{}
|
Returns:
| Name | Type | Description |
|---|---|---|
component |
Component
|
containing the sequence of sub-components instantiated and connected together in the sequence order. |
Example
import gdsfactory as gf
bend180 = gf.components.bend_circular180()
wg_pin = gf.components.straight_pin(length=40)
wg = gf.components.straight()
# Define a map between symbols and (component, input port, output port)
symbol_to_component = {
"A": (bend180, 'o1', 'o2'),
"B": (bend180, 'o2', 'o1'),
"H": (wg_pin, 'o1', 'o2'),
"-": (wg, 'o1', 'o2'),
}
# Each character in the sequence represents a component
s = "AB-H-H-H-H-BA"
c = gf.components.component_sequence(sequence=s, symbol_to_component=symbol_to_component)
c.plot()
Source code in gdsfactory/components/containers/component_sequence.py
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 | |
parse_component_name
parse_component_name(name: str) -> tuple[str, bool]
If the component name has more than one character and starts with "!".
then we need to flip along the axis given by the input port angle.
Source code in gdsfactory/components/containers/component_sequence.py
57 58 59 60 61 62 | |
copy_layers
copy_layers
copy_layers(
factory: ComponentSpec = "cross",
layers: LayerSpecs = ((1, 0), (2, 0)),
flatten: bool = False,
**kwargs: Any
) -> Component
Returns a component with the geometry copied in different layers.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
factory
|
ComponentSpec
|
component spec. |
'cross'
|
layers
|
LayerSpecs
|
iterable of layers. |
((1, 0), (2, 0))
|
flatten
|
bool
|
flatten the result. |
False
|
kwargs
|
Any
|
keyword arguments passed to the component. |
{}
|
Source code in gdsfactory/components/containers/copy_layers.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | |

extend_ports
extend_ports(
component: ComponentSpec = "mmi1x2",
port_names: PortNames | None = None,
length: float = 5.0,
extension: ComponentSpec | None = None,
port1: str | None = None,
port2: str | None = None,
port_type: str = "optical",
centered: bool = False,
cross_section: CrossSectionSpec | None = None,
extension_port_names: list[str] | None = None,
allow_width_mismatch: bool = False,
auto_taper: bool = True,
**kwargs: Any
) -> Component
Returns a new component with some ports extended.
You can define extension Spec defaults to port cross_section of each port to extend.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
component to extend ports. |
'mmi1x2'
|
port_names
|
PortNames | None
|
list of ports names to extend, if None it extends all ports. |
None
|
length
|
float
|
extension length. |
5.0
|
extension
|
ComponentSpec | None
|
function to extend ports (defaults to a straight). |
None
|
port1
|
str | None
|
extension input port name. |
None
|
port2
|
str | None
|
extension output port name. |
None
|
port_type
|
str
|
type of the ports to extend. |
'optical'
|
centered
|
bool
|
if True centers rectangle at (0, 0). |
False
|
cross_section
|
CrossSectionSpec | None
|
extension cross_section, defaults to port cross_section if port has no cross_section it creates one using width and layer. |
None
|
extension_port_names
|
list[str] | None
|
extension port names add to the new component. |
None
|
allow_width_mismatch
|
bool
|
allow width mismatches. |
False
|
auto_taper
|
bool
|
if True adds automatic tapers. |
True
|
kwargs
|
Any
|
cross_section settings. |
{}
|
Other Parameters:
| Name | Type | Description |
|---|---|---|
layer |
port GDS layer. |
|
prefix |
port name prefix. |
|
orientation |
in degrees. |
|
width |
port width. |
|
layers_excluded |
List of layers to exclude. |
|
port_type |
str
|
optical, electrical, .... |
clockwise |
if True, sort ports clockwise, False: counter-clockwise. |
Source code in gdsfactory/components/containers/extension.py
87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 | |

extend_ports_list
extend_ports_list
extend_ports_list(
component_spec: ComponentSpec,
extension: ComponentSpec,
extension_port_name: str | None = None,
ignore_ports: Strs | None = None,
) -> Component
Returns a component with an extension attached to a list of ports.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component_spec
|
ComponentSpec
|
component from which to get ports. |
required |
extension
|
ComponentSpec
|
function for extension. |
required |
extension_port_name
|
str | None
|
to connect extension. |
None
|
ignore_ports
|
Strs | None
|
list of port names to ignore. |
None
|
Source code in gdsfactory/components/containers/extend_ports_list.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 | |
splitter_chain
splitter_chain
splitter_chain(
splitter: ComponentSpec = "mmi1x2",
columns: int = 3,
bend: ComponentSpec = "bend_s",
) -> Component
Chain of splitters.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
splitter
|
ComponentSpec
|
splitter to chain. |
'mmi1x2'
|
columns
|
int
|
number of splitters to chain. |
3
|
bend
|
ComponentSpec
|
bend to connect splitters. |
'bend_s'
|
__o5
__|
__| |__o4
o1 _| |__o3
|__o2
__o2
o1 _|
|__o3
Source code in gdsfactory/components/containers/splitter_chain.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 | |

splitter_tree
Returns a switch_tree.
__
_| |_
__ | | |_ _
| |__| |__| |
_| |__ |dy
|__| | __ |
|_| |_ |
| |_ -
|__|
|<-dx->|
splitter_tree
splitter_tree(
coupler: ComponentSpec = "mmi1x2",
noutputs: int = 4,
spacing: Spacing = (90.0, 50.0),
bend_s: ComponentSpec | None = "bend_s",
bend_s_xsize: float | None = None,
cross_section: CrossSectionSpec = "strip",
) -> gf.Component
Tree of power splitters.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
coupler
|
ComponentSpec
|
coupler factory. |
'mmi1x2'
|
noutputs
|
int
|
number of outputs. |
4
|
spacing
|
Spacing
|
x, y spacing between couplers. |
(90.0, 50.0)
|
bend_s
|
ComponentSpec | None
|
Sbend function for termination. |
'bend_s'
|
bend_s_xsize
|
float | None
|
xsize for the sbend. |
None
|
cross_section
|
CrossSectionSpec
|
cross_section. | | |__ |
'strip'
|
Source code in gdsfactory/components/containers/splitter_tree.py
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 | |

switch_tree
module-attribute
switch_tree = partial(
splitter_tree, coupler=_mzi1x2_2x2, spacing=(500, 100)
)

couplers
coupler
coupler
coupler(
gap: float = 0.236,
length: float = 20.0,
dy: Delta = 4.0,
dx: Delta = 10.0,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
bend: ComponentSpec = "bend_s",
) -> Component
Symmetric coupler.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
gap
|
float
|
between straights in um. |
0.236
|
length
|
float
|
of coupling region in um. |
20.0
|
dy
|
Delta
|
port to port vertical spacing in um. |
4.0
|
dx
|
Delta
|
length of bend in x direction in um. |
10.0
|
cross_section
|
CrossSectionSpec
|
spec (CrossSection, string or dict). |
'strip'
|
allow_min_radius_violation
|
bool
|
if True does not check for min bend radius. |
False
|
bend
|
ComponentSpec
|
input and output sbend components. dx dx |------| |------| o2 __ __o3 \ / | \ length / | ======================= gap | dy / \ | __/ _____ | o1 o4
|
'bend_s'
|
Source code in gdsfactory/components/couplers/coupler.py
116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 | |
coupler_straight
coupler_straight(
length: float = 10.0,
gap: float = 0.27,
cross_section: CrossSectionSpec = "strip",
) -> Component
Coupler_straight with two parallel straights.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
of straight. |
10.0
|
gap
|
float
|
between straights. |
0.27
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string or dict). |
'strip'
|
Source code in gdsfactory/components/couplers/coupler.py
78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 | |
coupler_symmetric
coupler_symmetric(
bend: ComponentSpec = "bend_s",
gap: float = 0.234,
dy: Delta = 4.0,
dx: Delta = 10.0,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
) -> Component
Two coupled straights with bends.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
bend
|
ComponentSpec
|
bend spec. |
'bend_s'
|
gap
|
float
|
in um. |
0.234
|
dy
|
Delta
|
port to port vertical spacing. |
4.0
|
dx
|
Delta
|
bend length in x direction. |
10.0
|
cross_section
|
CrossSectionSpec
|
section. |
'strip'
|
allow_min_radius_violation
|
bool
|
if True does not check for min bend radius.
o2 _/ | | o1 ___ | dy \ | ___ | o4 |
False
|
Source code in gdsfactory/components/couplers/coupler.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 | |

coupler90
coupler90
coupler90(
gap: float = 0.2,
radius: float | None = None,
bend: ComponentSpec = "bend_euler",
straight: ComponentSpec = "straight",
cross_section: CrossSectionSpec = "strip",
cross_section_bend: CrossSectionSpec | None = None,
length_straight: float | None = None,
) -> Component
Straight coupled to a bend.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
gap
|
float
|
um. |
0.2
|
radius
|
float | None
|
um. |
None
|
straight
|
ComponentSpec
|
for straight. |
'straight'
|
bend
|
ComponentSpec
|
bend spec. |
'bend_euler'
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
cross_section_bend
|
CrossSectionSpec | None
|
optional bend cross_section spec. |
None
|
length_straight
|
float | None
|
optional length of the straight waveguide. |
None
|
o3
|
/
/
o2_/
o1___o4
Source code in gdsfactory/components/couplers/coupler90.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 | |

coupler90bend
coupler90bend
coupler90bend(
radius: float = 10.0,
gap: float = 0.2,
bend: ComponentSpec = "bend_euler",
cross_section_inner: CrossSectionSpec = "strip",
cross_section_outer: CrossSectionSpec = "strip",
) -> Component
Returns 2 coupled bends.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float
|
um. |
10.0
|
gap
|
float
|
um. |
0.2
|
bend
|
ComponentSpec
|
for bend. |
'bend_euler'
|
cross_section_inner
|
CrossSectionSpec
|
spec inner bend. |
'strip'
|
cross_section_outer
|
CrossSectionSpec
|
spec outer bend. r 3 4 | | | | / / | / / |
'strip'
|
Source code in gdsfactory/components/couplers/coupler90bend.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 | |

coupler90circular
module-attribute
coupler90circular = partial(coupler90, bend="bend_circular")

coupler_adiabatic
coupler_adiabatic
coupler_adiabatic(
length1: float = 20.0,
length2: float = 50.0,
length3: float = 30.0,
wg_sep: float = 1.0,
input_wg_sep: float = 3.0,
output_wg_sep: float = 3.0,
dw: float = 0.1,
cross_section: CrossSectionSpec = "strip",
) -> Component
Returns 50/50 adiabatic coupler.
Design based on asymmetric adiabatic 3dB coupler designs, such as those. - https://doi.org/10.1364/CLEO.2010.CThAA2, - https://doi.org/10.1364/CLEO_SI.2017.SF1I.5 - https://doi.org/10.1364/CLEO_SI.2018.STh4B.4
input Bezier curves, with poles set to half of the x-length of the S-bend. 1. is the first half of input S-bend where input widths taper by +dw and -dw 2. is the second half of the S-bend straight with constant, unbalanced widths 3. is the region where the two asymmetric straights gradually come together 4. straights taper back to the original width at a fixed distance from one another 5. is the output S-bend straight.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length1
|
float
|
region that gradually brings the two asymmetric straights together.
In this region the straight widths gradually change to be different by |
20.0
|
length2
|
float
|
coupling region, where asymmetric straights gradually become the same width. |
50.0
|
length3
|
float
|
output region where the two straights separate. |
30.0
|
wg_sep
|
float
|
Distance between center-to-center in the coupling region (Region 2). |
1.0
|
input_wg_sep
|
float
|
Separation of the two straights at the input, center-to-center. |
3.0
|
output_wg_sep
|
float
|
Separation of the two straights at the output, center-to-center. |
3.0
|
dw
|
float
|
Change in straight width. In Region 1, top arm tapers to width+dw/2.0, bottom taper to width-dw/2.0. |
0.1
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
Source code in gdsfactory/components/couplers/coupler_adiabatic.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 | |

coupler_asymmetric
coupler_asymmetric
coupler_asymmetric(
gap: float = 0.234,
dy: Delta = 2.5,
dx: Delta = 10.0,
cross_section: CrossSectionSpec = "strip",
) -> Component
Bend coupled to straight waveguide.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
gap
|
float
|
um. |
0.234
|
dy
|
Delta
|
port to port vertical spacing. |
2.5
|
dx
|
Delta
|
bend length in x direction. |
10.0
|
cross_section
|
CrossSectionSpec
|
spec.
_/ | gap o1____ | dy o3 |
'strip'
|
Source code in gdsfactory/components/couplers/coupler_asymmetric.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 | |

coupler_bent
coupler_bent
coupler_bent(
gap: float = 0.2,
radius: float = 26,
length: float = 8.6,
width1: float = 0.4,
width2: float = 0.4,
length_straight: float = 10,
cross_section: str = "strip",
) -> gf.Component
Returns Broadband SOI curved / straight directional coupler.
based on: https://doi.org/10.1038/s41598-017-07618-6.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
gap
|
float
|
gap. |
0.2
|
radius
|
float
|
radius coupling. |
26
|
length
|
float
|
coupler_length. |
8.6
|
width1
|
float
|
width1. |
0.4
|
width2
|
float
|
width2. |
0.4
|
length_straight
|
float
|
input and output straight length. |
10
|
cross_section
|
str
|
cross_section. |
'strip'
|
Source code in gdsfactory/components/couplers/coupler_bent.py
85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 | |
coupler_bent_half
coupler_bent_half(
gap: float = 0.2,
radius: float = 26,
length: float = 8.6,
width1: float = 0.4,
width2: float = 0.4,
length_straight: float = 10,
length_straight_exit: float = 18,
cross_section: str = "strip",
) -> gf.Component
Returns Broadband SOI curved / straight directional coupler.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
gap
|
float
|
gap. |
0.2
|
radius
|
float
|
radius coupling. |
26
|
length
|
float
|
coupler_length. |
8.6
|
width1
|
float
|
width1. |
0.4
|
width2
|
float
|
width2. |
0.4
|
length_straight
|
float
|
input and output straight length. |
10
|
length_straight_exit
|
float
|
length straight exit. |
18
|
cross_section
|
str
|
cross_section. |
'strip'
|
Source code in gdsfactory/components/couplers/coupler_bent.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 | |

coupler_broadband
coupler_broadband
coupler_broadband(
w_sc: float = 0.5,
gap_sc: float = 0.2,
w_top: float = 0.6,
gap_pc: float = 0.3,
legnth_taper: float = 1.0,
bend: ComponentSpec = "bend_euler",
coupler_straight: ComponentSpec = "coupler_straight",
length_coupler_straight: float = 12.4,
lenght_coupler_big_gap: float = 4.7,
cross_section: CrossSectionSpec = "strip",
radius: float = 10.0,
) -> Component
Returns broadband coupler component.
https://docs.flexcompute.com/projects/tidy3d/en/latest/notebooks/BroadbandDirectionalCoupler.html proposed in Zeqin Lu, Han Yun, Yun Wang, Zhitian Chen, Fan Zhang, Nicolas A. F. Jaeger, and Lukas Chrostowski, "Broadband silicon photonic directional coupler using asymmetric-waveguide based phase control," Opt. Express 23, 3795-3808 (2015), DOI: 10.1364/OE.23.003795.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
w_sc
|
float
|
width of waveguides in the symmetric coupler section. |
0.5
|
gap_sc
|
float
|
gap size between the waveguides in the symmetric coupler section. |
0.2
|
w_top
|
float
|
width of the top waveguide in the phase control section. |
0.6
|
gap_pc
|
float
|
gap size in the phase control section. |
0.3
|
legnth_taper
|
float
|
length of the tapers. |
1.0
|
bend
|
ComponentSpec
|
bend factory. |
'bend_euler'
|
coupler_straight
|
ComponentSpec
|
coupler_straight factory. |
'coupler_straight'
|
length_coupler_straight
|
float
|
optimal L_1 from the 3d fdtd analysis. |
12.4
|
lenght_coupler_big_gap
|
float
|
optimal L_2 from the 3d fdtd analysis. |
4.7
|
cross_section
|
CrossSectionSpec
|
cross_section of the waveguides. |
'strip'
|
radius
|
float
|
bend radius. |
10.0
|
Source code in gdsfactory/components/couplers/coupler_broadband.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 | |

coupler_full
coupler_full
coupler_full(
coupling_length: float = 40.0,
dx: Delta = 10.0,
dy: Delta = 4.8,
gap: float = 0.5,
dw: float = 0.1,
cross_section: CrossSectionSpec = "strip",
width: float | None = None,
) -> Component
Adiabatic Full coupler.
Design based on asymmetric adiabatic full coupler designs, such as the one reported in 'Integrated Optic Adiabatic Devices on Silicon' by Y. Shani, et al (IEEE Journal of Quantum Electronics, Vol. 27, No. 3 March 1991).
- is the first half of the input S-bend straight where the input straights widths taper by +dw and -dw,
- is the second half of the S-bend straight with constant, unbalanced widths,
- is the coupling region where the straights from unbalanced widths to balanced widths to reverse polarity unbalanced widths,
- is the fixed width straight that curves away from the coupling region, 5.is the final curve where the straights taper back to the regular width specified in the straight template.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
coupling_length
|
float
|
Length of the coupling region in um. |
40.0
|
dx
|
Delta
|
Length of the bend regions in um. |
10.0
|
dy
|
Delta
|
Port-to-port distance between the bend regions in um. |
4.8
|
gap
|
float
|
Distance between the two straights in um. |
0.5
|
dw
|
float
|
delta width. Top arm tapers to width - dw, bottom to width + dw in um. |
0.1
|
cross_section
|
CrossSectionSpec
|
cross-section spec. |
'strip'
|
width
|
float | None
|
width of the waveguide. If None, it will use the width of the cross_section. |
None
|
Source code in gdsfactory/components/couplers/coupler_full.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 | |

coupler_pulley
coupler_pulley
coupler_pulley(
radius: float = 10.0,
ring_width: float | None = None,
gap: float = 0.2,
coupling_angle: float = 60.0,
wg_length: float = 40.0,
wg_height: float = 10.0,
n_segments: int = 128,
cross_section: CrossSectionSpec = "strip",
layer: LayerSpec = "WG",
) -> Component
Returns a disc or ring with a pulley-coupled waveguide.
A waveguide wraps symmetrically around the top of a disc/ring over coupling_angle degrees. Bezier S-curves (following the CNST discPulley construction, eq. 2.22) route the waveguide from the coupling arc down to horizontal exits on both sides.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float
|
radius of the disc, or outer radius of the ring. |
10.0
|
ring_width
|
float | None
|
width of the ring annulus. None for a solid disc. |
None
|
gap
|
float
|
gap between the waveguide inner edge and the disc/ring. |
0.2
|
coupling_angle
|
float
|
total wrap angle in degrees (symmetric about top). |
60.0
|
wg_length
|
float
|
horizontal half-length of the waveguide from the disc center to the exit end. Controls S-curve extent. Corresponds to CNST parameter L. |
40.0
|
wg_height
|
float
|
vertical drop from disc center to exit waveguide level. Corresponds to CNST parameter H. |
10.0
|
n_segments
|
int
|
number of points for each curved section. |
128
|
cross_section
|
CrossSectionSpec
|
cross-section spec for the coupling waveguide. |
'strip'
|
layer
|
LayerSpec
|
layer spec for the disc/ring. |
'WG'
|
Source code in gdsfactory/components/couplers/coupler_pulley.py
32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 | |

coupler_ring
coupler_ring
coupler_ring(
gap: float = 0.2,
radius: float | None = None,
length_x: float = 4.0,
bend: ComponentSpec = "bend_euler",
straight: ComponentSpec = "straight",
cross_section: CrossSectionSpec = "strip",
cross_section_bend: CrossSectionSpec | None = None,
length_extension: float | None = None,
) -> Component
Coupler for ring.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
gap
|
float
|
spacing between parallel coupled straight waveguides. |
0.2
|
radius
|
float | None
|
of the bends. Default is None, which uses the default radius of the cross_section. |
None
|
length_x
|
float
|
length of the parallel coupled straight waveguides. |
4.0
|
bend
|
ComponentSpec
|
90 degrees bend spec. |
'bend_euler'
|
straight
|
ComponentSpec
|
straight spec. |
'straight'
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
cross_section_bend
|
CrossSectionSpec | None
|
optional bend cross_section spec. |
None
|
length_extension
|
float | None
|
straight length extension at the end of the coupler bottom ports. o2 o3 xx xx xx xx xx length_x x xx ◄───────────────► x xx xxx xx xxx xxx──────▲─────────xxx │gap o1──────▼─────────◄──────────────► o4 length_extension |
None
|
Source code in gdsfactory/components/couplers/coupler_ring.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 | |

coupler_straight
coupler_straight(
length: float = 10.0,
gap: float = 0.27,
cross_section: CrossSectionSpec = "strip",
) -> Component
Coupler_straight with two parallel straights.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
of straight. |
10.0
|
gap
|
float
|
between straights. |
0.27
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string or dict). |
'strip'
|
Source code in gdsfactory/components/couplers/coupler.py
78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 | |

coupler_straight_asymmetric
coupler_straight_asymmetric
coupler_straight_asymmetric(
length: float = 10.0,
gap: float = 0.27,
width_top: float = 0.5,
width_bot: float = 1,
cross_section: CrossSectionSpec = "strip",
) -> Component
Coupler with two parallel straights of different widths.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
of straight. |
10.0
|
gap
|
float
|
between straights. |
0.27
|
width_top
|
float
|
of top straight. |
0.5
|
width_bot
|
float
|
of bottom straight. |
1
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
Source code in gdsfactory/components/couplers/coupler_straight_asymmetric.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | |

coupler_symmetric
coupler_symmetric(
bend: ComponentSpec = "bend_s",
gap: float = 0.234,
dy: Delta = 4.0,
dx: Delta = 10.0,
cross_section: CrossSectionSpec = "strip",
allow_min_radius_violation: bool = False,
) -> Component
Two coupled straights with bends.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
bend
|
ComponentSpec
|
bend spec. |
'bend_s'
|
gap
|
float
|
in um. |
0.234
|
dy
|
Delta
|
port to port vertical spacing. |
4.0
|
dx
|
Delta
|
bend length in x direction. |
10.0
|
cross_section
|
CrossSectionSpec
|
section. |
'strip'
|
allow_min_radius_violation
|
bool
|
if True does not check for min bend radius.
o2 _/ | | o1 ___ | dy \ | ___ | o4 |
False
|
Source code in gdsfactory/components/couplers/coupler.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 | |

detectors
ge_detector_straight_si_contacts
ge_detector_straight_si_contacts(
length: float = 40.0,
cross_section: CrossSectionSpec = "pn_ge_detector_si_contacts",
via_stack: ComponentSpec = "via_stack_slab_m3",
via_stack_width: float = 10.0,
via_stack_spacing: float = 5.0,
via_stack_offset: float = 0.0,
taper_length: float = 20.0,
taper_width: float = 0.8,
taper_cros_section: CrossSectionSpec = "strip",
) -> Component
Returns a straight Ge on Si detector with silicon contacts.
There are no contacts on the Ge. These detectors could have lower dark current and sensitivity compared to those with contacts in the Ge. See Chen et al., "High-Responsivity Low-Voltage 28-Gb/s Ge p-i-n Photodetector With Silicon Contacts", Journal of Lightwave Technology 33(4), 2015.
https://doi.org/10.1109/JLT.2014.2367134
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
pd length. |
40.0
|
cross_section
|
CrossSectionSpec
|
for the waveguide. |
'pn_ge_detector_si_contacts'
|
via_stack
|
ComponentSpec
|
for the via_stacks. First element |
'via_stack_slab_m3'
|
via_stack_width
|
float
|
width of the via_stack. |
10.0
|
via_stack_spacing
|
float
|
spacing between via_stacks. |
5.0
|
via_stack_offset
|
float
|
with respect to the detector |
0.0
|
taper_length
|
float
|
length of the taper. |
20.0
|
taper_width
|
float
|
width of the taper. |
0.8
|
taper_cros_section
|
CrossSectionSpec
|
cross_section of the taper. |
'strip'
|
Source code in gdsfactory/components/detectors/detector_ge.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 | |

dies
add_frame
add_frame(
component: ComponentSpec = "rectangle",
width: float = 10.0,
spacing: float = 10.0,
layer: LayerSpec = "WG",
) -> Component
Returns component with a frame around it.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
Component to frame. |
'rectangle'
|
width
|
float
|
of the frame. |
10.0
|
spacing
|
float
|
of component to frame. |
10.0
|
layer
|
LayerSpec
|
frame layer. |
'WG'
|
Source code in gdsfactory/components/dies/align.py
75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 | |

align_wafer
align_wafer(
width: float = 10.0,
spacing: float = 10.0,
cross_length: float = 80.0,
layer: LayerSpec = "WG",
layer_cladding: tuple[int, int] | None = None,
square_corner: str = "bottom_left",
) -> Component
Returns cross inside a frame to align wafer.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
in um. |
10.0
|
spacing
|
float
|
in um. |
10.0
|
cross_length
|
float
|
for the cross. |
80.0
|
layer
|
LayerSpec
|
for the cross. |
'WG'
|
layer_cladding
|
tuple[int, int] | None
|
optional. |
None
|
square_corner
|
str
|
bottom_left, bottom_right, top_right, top_left. |
'bottom_left'
|
Source code in gdsfactory/components/dies/align.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 | |

die
based on phidl.geometry.
die
die(
size: Size = (10000.0, 10000.0),
street_width: float = 100.0,
street_length: float = 1000.0,
die_name: str | None = "chip99",
text_size: float = 100.0,
text_location: str | Float2 = "SW",
layer: LayerSpec | None = "FLOORPLAN",
bbox_layer: LayerSpec | None = "FLOORPLAN",
text_layer: LayerSpec = "WG",
text: ComponentSpec = "text",
draw_corners: bool = False,
) -> gf.Component
Returns die with optional markers marking the boundary of the die.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
Size
|
x, y dimensions of the die. |
(10000.0, 10000.0)
|
street_width
|
float
|
Width of the corner marks for die-sawing. |
100.0
|
street_length
|
float
|
Length of the corner marks for die-sawing. |
1000.0
|
die_name
|
str | None
|
Label text. If None, no label is added. |
'chip99'
|
text_size
|
float
|
Label text size. |
100.0
|
text_location
|
str | Float2
|
{'NW', 'N', 'NE', 'SW', 'S', 'SE'} or (x, y) coordinate. |
'SW'
|
layer
|
LayerSpec | None
|
For street widths. None to not draw the street widths. |
'FLOORPLAN'
|
bbox_layer
|
LayerSpec | None
|
optional bbox layer drawn bounding box around the die. |
'FLOORPLAN'
|
text_layer
|
LayerSpec
|
Layer for the die name text. |
'WG'
|
text
|
ComponentSpec
|
function use for generating text. Needs to accept text, size, layer. |
'text'
|
draw_corners
|
bool
|
True draws only corners. False draws a square die. |
False
|
Source code in gdsfactory/components/dies/die.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 | |

die_frame
die_frame(
size: Size = (11200.0, 5000.0),
layer_floorplan: LayerSpec = "FLOORPLAN",
) -> gf.Component
Source code in gdsfactory/components/dies/die_frame_with_pads.py
15 16 17 18 19 20 21 22 | |

die_frame_phix
die_frame_phix(
die_frame: ComponentSpec = "die_frame",
nfibers: int = 32,
npads: int = 60,
npads_rf: int = 6,
fiber_pitch: float = 127.0,
pad_pitch: float = 150.0,
pad_pitch_gsg: float = 720.0,
edge_coupler: (
ComponentSpec | None
) = "edge_coupler_silicon",
grating_coupler: ComponentSpec | None = None,
cross_section: CrossSectionSpec = "strip",
pad: ComponentSpec = "pad",
pad_gsg: ComponentSpec = "pad_gsg",
edge_to_pad_distance: float = 200.0,
edge_to_pad_distance_left: float | None = None,
pad_port_name_top: str = "e4",
pad_port_name_bot: str = "e2",
pad_port_name_rf: str = "e2",
layer_fiducial: LayerSpec = "M3",
layer_ruler: LayerSpec = "WG",
ruler_bbox_layers: tuple[LayerSpec, ...] | None = None,
ruler_bbox_offset: float = 3.0,
ruler_yoffset: float = 0,
ruler_xoffset: float = 0,
fiber_coupler_xoffset: float = 0,
with_right_fiber_coupler: bool = True,
with_left_fiber_coupler: bool = True,
text_offset: Float2 = (20, 10),
text: ComponentSpec | None = "text_rectangular",
pad_side_distance: float = 1160.0,
xoffset_rf_pads: float = 50,
pad_rotation_dc_north: float = 0,
pad_rotation_dc_south: float = 0,
pad_rotation_rf: float = 0,
with_loopback: bool = True,
) -> Component
A die_frame with grating couplers and pads.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
die_frame
|
ComponentSpec
|
die_frame spec. |
'die_frame'
|
nfibers
|
int
|
the number of grating couplers. |
32
|
npads
|
int
|
the number of pads. |
60
|
npads_rf
|
int
|
the number of RF pads on the left side. |
6
|
fiber_pitch
|
float
|
the pitch of the grating couplers, in um. |
127.0
|
pad_pitch
|
float
|
the pitch of the pads, in um. |
150.0
|
pad_pitch_gsg
|
float
|
the pitch of the GSG pads, in um. |
720.0
|
edge_coupler
|
ComponentSpec | None
|
the grating coupler component. |
'edge_coupler_silicon'
|
grating_coupler
|
ComponentSpec | None
|
Optional grating coupler. |
None
|
cross_section
|
CrossSectionSpec
|
the cross section. |
'strip'
|
pad
|
ComponentSpec
|
the pad component. |
'pad'
|
pad_gsg
|
ComponentSpec
|
the GSG pad component. |
'pad_gsg'
|
edge_to_pad_distance
|
float
|
the distance from the edge to the pads, in um. |
200.0
|
edge_to_pad_distance_left
|
float | None
|
Optional distance from the left edge to the pads, in um. If None, uses edge_to_pad_distance for both sides. |
None
|
pad_port_name_top
|
str
|
name of the pad port name at the top facing south. |
'e4'
|
pad_port_name_bot
|
str
|
name of the pad port name at the bottom facing north. |
'e2'
|
pad_port_name_rf
|
str
|
name of the RF pad port name. |
'e2'
|
layer_fiducial
|
LayerSpec
|
layer for fiducials. |
'M3'
|
layer_ruler
|
LayerSpec
|
layer for ruler. |
'WG'
|
ruler_bbox_layers
|
tuple[LayerSpec, ...] | None
|
layers for bbox. |
None
|
ruler_bbox_offset
|
float
|
offset for bbox. |
3.0
|
ruler_yoffset
|
float
|
y-offset for ruler. |
0
|
ruler_xoffset
|
float
|
x-offset for ruler. |
0
|
fiber_coupler_xoffset
|
float
|
x-offset for fiber couplers. |
0
|
with_right_fiber_coupler
|
bool
|
if True, adds edge couplers on the right side. |
True
|
with_left_fiber_coupler
|
bool
|
if True, adds edge couplers on the left side. |
True
|
text_offset
|
Float2
|
offset for text. |
(20, 10)
|
text
|
ComponentSpec | None
|
text component spec. |
'text_rectangular'
|
pad_side_distance
|
float
|
distance from the die frame side to the first pad, in um. |
1160.0
|
xoffset_rf_pads
|
float
|
RF pads x-offset. |
50
|
pad_rotation_dc_north
|
float
|
rotation for DC pads. |
0
|
pad_rotation_dc_south
|
float
|
rotation for DC pads. |
0
|
pad_rotation_rf
|
float
|
rotation for RF pads. |
0
|
with_loopback
|
bool
|
if True, adds loopback structures. |
True
|
Source code in gdsfactory/components/dies/die_frame_with_pads.py
136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 | |

die_frame_phix_dc
die_frame_phix_dc(
die_frame: ComponentSpec = "die_frame",
nfibers: int = 32,
npads: int = 59,
npads_rf: int = 6,
fiber_pitch: float = 127.0,
pad_pitch: float = 150.0,
pad_pitch_gsg: float = 720.0,
edge_coupler: (
ComponentSpec | None
) = "edge_coupler_silicon",
grating_coupler: ComponentSpec | None = None,
cross_section: CrossSectionSpec = "strip",
pad: ComponentSpec = "pad",
pad_gsg: ComponentSpec = "pad_gsg",
edge_to_pad_distance: float = 200.0,
pad_port_name_top: str = "e4",
pad_port_name_bot: str = "e2",
layer_fiducial: LayerSpec = "M3",
layer_ruler: LayerSpec = "WG",
ruler_bbox_layers: tuple[LayerSpec, ...] | None = None,
ruler_bbox_offset: float = 3.0,
ruler_yoffset: float = 0,
ruler_xoffset: float = 0,
with_right_fiber_coupler: bool = True,
with_left_fiber_coupler: bool = True,
fiber_coupler_xoffset: float = 0,
text_offset: Float2 = (20, 10),
text: ComponentSpec | None = None,
pad_rotation_dc_north: float = 0,
pad_rotation_dc_south: float = 0,
pad_side_distance: float = 1160.0,
) -> Component
Source code in gdsfactory/components/dies/die_frame_with_pads.py
397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 | |

die_frame_phix_rf
die_frame_phix_rf(
die_frame: ComponentSpec = "die_frame_rf",
nfibers: int = 32,
npads: int = 59,
npads_rf: int = 6,
fiber_pitch: float = 127.0,
pad_pitch: float = 150.0,
pad_pitch_gsg: float = 720.0,
edge_coupler: (
ComponentSpec | None
) = "edge_coupler_silicon",
grating_coupler: ComponentSpec | None = None,
cross_section: CrossSectionSpec = "strip",
pad: ComponentSpec = "pad",
pad_gsg: ComponentSpec = "pad_gsg",
edge_to_pad_distance: float = 200.0,
pad_port_name_top: str = "e4",
pad_port_name_bot: str = "e2",
pad_port_name_rf: str = "e2",
layer_fiducial: LayerSpec = "M3",
layer_ruler: LayerSpec = "WG",
ruler_bbox_layers: tuple[LayerSpec, ...] | None = None,
ruler_bbox_offset: float = 3.0,
ruler_yoffset: float = 0,
ruler_xoffset: float = 0,
with_right_fiber_coupler: bool = True,
with_left_fiber_coupler: bool = False,
fiber_coupler_xoffset: float = 0,
text_offset: Float2 = (20, 10),
text: ComponentSpec | None = None,
pad_side_distance: float = 350.0,
xoffset_rf_pads: float = 50,
pad_rotation_rf: float = 0,
pad_rotation_dc_north: float = 0,
pad_rotation_dc_south: float = 0,
) -> Component
Source code in gdsfactory/components/dies/die_frame_with_pads.py
462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 | |

die_frame_rf
die_frame_rf(
size: Size = (10400.0, 5000.0),
layer_floorplan: LayerSpec = "FLOORPLAN",
) -> gf.Component
Source code in gdsfactory/components/dies/die_frame_with_pads.py
25 26 27 28 29 30 31 32 | |

die_frame_with_pads
die_frame_phix
die_frame_phix(
die_frame: ComponentSpec = "die_frame",
nfibers: int = 32,
npads: int = 60,
npads_rf: int = 6,
fiber_pitch: float = 127.0,
pad_pitch: float = 150.0,
pad_pitch_gsg: float = 720.0,
edge_coupler: (
ComponentSpec | None
) = "edge_coupler_silicon",
grating_coupler: ComponentSpec | None = None,
cross_section: CrossSectionSpec = "strip",
pad: ComponentSpec = "pad",
pad_gsg: ComponentSpec = "pad_gsg",
edge_to_pad_distance: float = 200.0,
edge_to_pad_distance_left: float | None = None,
pad_port_name_top: str = "e4",
pad_port_name_bot: str = "e2",
pad_port_name_rf: str = "e2",
layer_fiducial: LayerSpec = "M3",
layer_ruler: LayerSpec = "WG",
ruler_bbox_layers: tuple[LayerSpec, ...] | None = None,
ruler_bbox_offset: float = 3.0,
ruler_yoffset: float = 0,
ruler_xoffset: float = 0,
fiber_coupler_xoffset: float = 0,
with_right_fiber_coupler: bool = True,
with_left_fiber_coupler: bool = True,
text_offset: Float2 = (20, 10),
text: ComponentSpec | None = "text_rectangular",
pad_side_distance: float = 1160.0,
xoffset_rf_pads: float = 50,
pad_rotation_dc_north: float = 0,
pad_rotation_dc_south: float = 0,
pad_rotation_rf: float = 0,
with_loopback: bool = True,
) -> Component
A die_frame with grating couplers and pads.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
die_frame
|
ComponentSpec
|
die_frame spec. |
'die_frame'
|
nfibers
|
int
|
the number of grating couplers. |
32
|
npads
|
int
|
the number of pads. |
60
|
npads_rf
|
int
|
the number of RF pads on the left side. |
6
|
fiber_pitch
|
float
|
the pitch of the grating couplers, in um. |
127.0
|
pad_pitch
|
float
|
the pitch of the pads, in um. |
150.0
|
pad_pitch_gsg
|
float
|
the pitch of the GSG pads, in um. |
720.0
|
edge_coupler
|
ComponentSpec | None
|
the grating coupler component. |
'edge_coupler_silicon'
|
grating_coupler
|
ComponentSpec | None
|
Optional grating coupler. |
None
|
cross_section
|
CrossSectionSpec
|
the cross section. |
'strip'
|
pad
|
ComponentSpec
|
the pad component. |
'pad'
|
pad_gsg
|
ComponentSpec
|
the GSG pad component. |
'pad_gsg'
|
edge_to_pad_distance
|
float
|
the distance from the edge to the pads, in um. |
200.0
|
edge_to_pad_distance_left
|
float | None
|
Optional distance from the left edge to the pads, in um. If None, uses edge_to_pad_distance for both sides. |
None
|
pad_port_name_top
|
str
|
name of the pad port name at the top facing south. |
'e4'
|
pad_port_name_bot
|
str
|
name of the pad port name at the bottom facing north. |
'e2'
|
pad_port_name_rf
|
str
|
name of the RF pad port name. |
'e2'
|
layer_fiducial
|
LayerSpec
|
layer for fiducials. |
'M3'
|
layer_ruler
|
LayerSpec
|
layer for ruler. |
'WG'
|
ruler_bbox_layers
|
tuple[LayerSpec, ...] | None
|
layers for bbox. |
None
|
ruler_bbox_offset
|
float
|
offset for bbox. |
3.0
|
ruler_yoffset
|
float
|
y-offset for ruler. |
0
|
ruler_xoffset
|
float
|
x-offset for ruler. |
0
|
fiber_coupler_xoffset
|
float
|
x-offset for fiber couplers. |
0
|
with_right_fiber_coupler
|
bool
|
if True, adds edge couplers on the right side. |
True
|
with_left_fiber_coupler
|
bool
|
if True, adds edge couplers on the left side. |
True
|
text_offset
|
Float2
|
offset for text. |
(20, 10)
|
text
|
ComponentSpec | None
|
text component spec. |
'text_rectangular'
|
pad_side_distance
|
float
|
distance from the die frame side to the first pad, in um. |
1160.0
|
xoffset_rf_pads
|
float
|
RF pads x-offset. |
50
|
pad_rotation_dc_north
|
float
|
rotation for DC pads. |
0
|
pad_rotation_dc_south
|
float
|
rotation for DC pads. |
0
|
pad_rotation_rf
|
float
|
rotation for RF pads. |
0
|
with_loopback
|
bool
|
if True, adds loopback structures. |
True
|
Source code in gdsfactory/components/dies/die_frame_with_pads.py
136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 | |
die_frame_with_pads
die_frame_with_pads(
die_frame: ComponentSpec = "die_frame",
ngratings: int = 14,
npads: int = 31,
grating_pitch: float = 250.0,
pad_pitch: float = 300.0,
grating_coupler: (
ComponentSpec | None
) = "grating_coupler_te",
cross_section: CrossSectionSpec = "strip",
pad: ComponentSpec = "pad",
edge_to_pad_distance: float = 150.0,
edge_to_grating_distance: float = 150.0,
with_loopback: bool = True,
loopback_radius: float | None = None,
pad_port_name_top: str = "e4",
pad_port_name_bot: str = "e2",
) -> Component
A die_frame with grating couplers and pads.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
die_frame
|
ComponentSpec
|
die_frame spec. |
'die_frame'
|
ngratings
|
int
|
the number of grating couplers. |
14
|
npads
|
int
|
the number of pads. |
31
|
grating_pitch
|
float
|
the pitch of the grating couplers, in um. |
250.0
|
pad_pitch
|
float
|
the pitch of the pads, in um. |
300.0
|
grating_coupler
|
ComponentSpec | None
|
the grating coupler component. |
'grating_coupler_te'
|
cross_section
|
CrossSectionSpec
|
the cross section. |
'strip'
|
pad
|
ComponentSpec
|
the pad component. |
'pad'
|
edge_to_pad_distance
|
float
|
the distance from the edge to the pads, in um. |
150.0
|
edge_to_grating_distance
|
float
|
the distance from the edge to the grating couplers, in um. |
150.0
|
with_loopback
|
bool
|
if True, adds a loopback between edge GCs. Only works for rotation = 90 for now. |
True
|
loopback_radius
|
float | None
|
optional radius for loopback. |
None
|
pad_port_name_top
|
str
|
name of the pad port name at the btop facing south. |
'e4'
|
pad_port_name_bot
|
str
|
name of the pad port name at the bottom facing north. |
'e2'
|
Source code in gdsfactory/components/dies/die_frame_with_pads.py
35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 | |

die_with_pads
die_with_pads
die_with_pads(
size: Size = (11470.0, 4900.0),
ngratings: int = 14,
npads: int = 31,
grating_pitch: float = 250.0,
pad_pitch: float = 300.0,
grating_coupler: (
ComponentSpec | None
) = "grating_coupler_te",
cross_section: CrossSectionSpec = "strip",
pad: ComponentSpec = "pad",
layer_floorplan: LayerSpec = "FLOORPLAN",
edge_to_pad_distance: float = 150.0,
edge_to_grating_distance: float = 150.0,
with_loopback: bool = True,
loopback_radius: float | None = None,
pad_port_name_top: str = "e4",
pad_port_name_bot: str = "e2",
) -> Component
A die with grating couplers and pads.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
Size
|
the size of the die, in um. |
(11470.0, 4900.0)
|
ngratings
|
int
|
the number of grating couplers. |
14
|
npads
|
int
|
the number of pads. |
31
|
grating_pitch
|
float
|
the pitch of the grating couplers, in um. |
250.0
|
pad_pitch
|
float
|
the pitch of the pads, in um. |
300.0
|
grating_coupler
|
ComponentSpec | None
|
the grating coupler component. |
'grating_coupler_te'
|
cross_section
|
CrossSectionSpec
|
the cross section. |
'strip'
|
pad
|
ComponentSpec
|
the pad component. |
'pad'
|
layer_floorplan
|
LayerSpec
|
the layer of the floorplan. |
'FLOORPLAN'
|
edge_to_pad_distance
|
float
|
the distance from the edge to the pads, in um. |
150.0
|
edge_to_grating_distance
|
float
|
the distance from the edge to the grating couplers, in um. |
150.0
|
with_loopback
|
bool
|
if True, adds a loopback between edge GCs. Only works for rotation = 90 for now. |
True
|
loopback_radius
|
float | None
|
optional radius for loopback. |
None
|
pad_port_name_top
|
str
|
name of the pad port name at the btop facing south. |
'e4'
|
pad_port_name_bot
|
str
|
name of the pad port name at the bottom facing north. |
'e2'
|
Source code in gdsfactory/components/dies/die_with_pads.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 | |

seal_ring
seal_ring
seal_ring(
size: Float2 = (500, 500),
seal: ComponentSpec = "via_stack",
width: float = 10,
padding: float = 10.0,
with_north: bool = True,
with_south: bool = True,
with_east: bool = True,
with_west: bool = True,
) -> gf.Component
Returns a continuous seal ring boundary at the chip/die.
Prevents cracks from spreading and shields when connected to ground.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
Float2
|
of the seal. |
(500, 500)
|
seal
|
ComponentSpec
|
function for the seal. |
'via_stack'
|
width
|
float
|
of the seal. |
10
|
padding
|
float
|
from component to seal. |
10.0
|
with_north
|
bool
|
includes seal. |
True
|
with_south
|
bool
|
includes seal. |
True
|
with_east
|
bool
|
includes seal. |
True
|
with_west
|
bool
|
includes seal. |
True
|
Source code in gdsfactory/components/dies/seal_ring.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 | |
seal_ring_segmented
seal_ring_segmented(
size: Float2 = (500, 500),
length_segment: float = 10,
width_segment: float = 3,
spacing_segment: float = 2,
corner: ComponentSpec = "via_stack_corner45_extended",
via_stack: ComponentSpec = "via_stack_m1_mtop",
with_north: bool = True,
with_south: bool = True,
with_east: bool = True,
with_west: bool = True,
) -> gf.Component
Segmented Seal ring.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
Float2
|
of the seal ring. |
(500, 500)
|
length_segment
|
float
|
length of each segment. |
10
|
width_segment
|
float
|
width of each segment. |
3
|
spacing_segment
|
float
|
spacing between segments. |
2
|
corner
|
ComponentSpec
|
corner component. |
'via_stack_corner45_extended'
|
via_stack
|
ComponentSpec
|
via_stack component. |
'via_stack_m1_mtop'
|
with_north
|
bool
|
includes seal. |
True
|
with_south
|
bool
|
includes seal. |
True
|
with_east
|
bool
|
includes seal. |
True
|
with_west
|
bool
|
includes seal. |
True
|
Source code in gdsfactory/components/dies/seal_ring.py
81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 | |

seal_ring_segmented
seal_ring_segmented(
size: Float2 = (500, 500),
length_segment: float = 10,
width_segment: float = 3,
spacing_segment: float = 2,
corner: ComponentSpec = "via_stack_corner45_extended",
via_stack: ComponentSpec = "via_stack_m1_mtop",
with_north: bool = True,
with_south: bool = True,
with_east: bool = True,
with_west: bool = True,
) -> gf.Component
Segmented Seal ring.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
Float2
|
of the seal ring. |
(500, 500)
|
length_segment
|
float
|
length of each segment. |
10
|
width_segment
|
float
|
width of each segment. |
3
|
spacing_segment
|
float
|
spacing between segments. |
2
|
corner
|
ComponentSpec
|
corner component. |
'via_stack_corner45_extended'
|
via_stack
|
ComponentSpec
|
via_stack component. |
'via_stack_m1_mtop'
|
with_north
|
bool
|
includes seal. |
True
|
with_south
|
bool
|
includes seal. |
True
|
with_east
|
bool
|
includes seal. |
True
|
with_west
|
bool
|
includes seal. |
True
|
Source code in gdsfactory/components/dies/seal_ring.py
81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 | |

wafer
wafer
wafer(
reticle: ComponentSpec = "die",
cols: tuple[int, ...] = _cols_200mm_wafer,
xspacing: float | None = None,
yspacing: float | None = None,
die_name_col_row: bool = False,
) -> Component
Returns complete wafer. Useful for mask aligner steps.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
reticle
|
ComponentSpec
|
spec for each wafer reticle. |
'die'
|
cols
|
tuple[int, ...]
|
how many columns per row. |
_cols_200mm_wafer
|
xspacing
|
float | None
|
optional spacing, defaults to reticle.xsize. |
None
|
yspacing
|
float | None
|
optional spacing, defaults to reticle.ysize. |
None
|
die_name_col_row
|
bool
|
if True, die name is row_col, otherwise is a number |
False
|
Source code in gdsfactory/components/dies/wafer.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | |

edge_couplers
edge_coupler_array
edge_coupler_array
edge_coupler_array(
edge_coupler: ComponentSpec = "edge_coupler_silicon",
n: int = 5,
pitch: float = 127.0,
x_reflection: bool = False,
text: ComponentSpec | None = "text_rectangular",
text_offset: Float2 = (10, 20),
text_rotation: float = 0,
) -> Component
Fiber array edge coupler based on an inverse taper.
Each edge coupler adds a ruler for polishing.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
edge_coupler
|
ComponentSpec
|
edge coupler spec. |
'edge_coupler_silicon'
|
n
|
int
|
number of channels. |
5
|
pitch
|
float
|
Fiber pitch. |
127.0
|
x_reflection
|
bool
|
horizontal mirror. |
False
|
text
|
ComponentSpec | None
|
text spec. |
'text_rectangular'
|
text_offset
|
Float2
|
from edge coupler. |
(10, 20)
|
text_rotation
|
float
|
text rotation in degrees. |
0
|
Source code in gdsfactory/components/edge_couplers/edge_coupler_array.py
49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 | |
edge_coupler_array_with_loopback
edge_coupler_array_with_loopback(
edge_coupler: ComponentSpec = "edge_coupler_silicon",
cross_section: CrossSectionSpec = "strip",
radius: float | None = None,
n: int = 8,
pitch: float = 127.0,
x_reflection: bool = False,
text: ComponentSpec | None = "text_rectangular",
text_offset: Float2 = (0, 10),
text_rotation: float = 0,
) -> Component
Fiber array edge coupler.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
edge_coupler
|
ComponentSpec
|
edge coupler. |
'edge_coupler_silicon'
|
cross_section
|
CrossSectionSpec
|
spec. |
'strip'
|
radius
|
float | None
|
bend radius loopback (um). |
None
|
n
|
int
|
number of channels. |
8
|
pitch
|
float
|
Fiber pitch (um). |
127.0
|
x_reflection
|
bool
|
horizontal mirror. |
False
|
text
|
ComponentSpec | None
|
Optional text spec. |
'text_rectangular'
|
text_offset
|
Float2
|
x, y. |
(0, 10)
|
text_rotation
|
float
|
text rotation in degrees. |
0
|
Source code in gdsfactory/components/edge_couplers/edge_coupler_array.py
97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 | |
edge_coupler_silicon
edge_coupler_silicon(
length: float = 100,
width1: float = 0.5,
width2: float = 0.2,
with_two_ports: bool = True,
port_names: tuple[str, str] = ("o1", "o2"),
port_types: tuple[str, str] = (
"optical",
"edge_coupler",
),
cross_section: CrossSectionSpec = "strip",
) -> Component
Edge coupler for silicon photonics.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
length of the taper. |
100
|
width1
|
float
|
width1 of the taper. |
0.5
|
width2
|
float
|
width2 of the taper. |
0.2
|
with_two_ports
|
bool
|
add two ports. |
True
|
port_names
|
tuple[str, str]
|
tuple with port names. |
('o1', 'o2')
|
port_types
|
tuple[str, str]
|
tuple with port types. |
('optical', 'edge_coupler')
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
Source code in gdsfactory/components/edge_couplers/edge_coupler_array.py
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 | |

edge_coupler_array_with_loopback
edge_coupler_array_with_loopback(
edge_coupler: ComponentSpec = "edge_coupler_silicon",
cross_section: CrossSectionSpec = "strip",
radius: float | None = None,
n: int = 8,
pitch: float = 127.0,
x_reflection: bool = False,
text: ComponentSpec | None = "text_rectangular",
text_offset: Float2 = (0, 10),
text_rotation: float = 0,
) -> Component
Fiber array edge coupler.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
edge_coupler
|
ComponentSpec
|
edge coupler. |
'edge_coupler_silicon'
|
cross_section
|
CrossSectionSpec
|
spec. |
'strip'
|
radius
|
float | None
|
bend radius loopback (um). |
None
|
n
|
int
|
number of channels. |
8
|
pitch
|
float
|
Fiber pitch (um). |
127.0
|
x_reflection
|
bool
|
horizontal mirror. |
False
|
text
|
ComponentSpec | None
|
Optional text spec. |
'text_rectangular'
|
text_offset
|
Float2
|
x, y. |
(0, 10)
|
text_rotation
|
float
|
text rotation in degrees. |
0
|
Source code in gdsfactory/components/edge_couplers/edge_coupler_array.py
97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 | |

edge_coupler_silicon
edge_coupler_silicon(
length: float = 100,
width1: float = 0.5,
width2: float = 0.2,
with_two_ports: bool = True,
port_names: tuple[str, str] = ("o1", "o2"),
port_types: tuple[str, str] = (
"optical",
"edge_coupler",
),
cross_section: CrossSectionSpec = "strip",
) -> Component
Edge coupler for silicon photonics.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
length of the taper. |
100
|
width1
|
float
|
width1 of the taper. |
0.5
|
width2
|
float
|
width2 of the taper. |
0.2
|
with_two_ports
|
bool
|
add two ports. |
True
|
port_names
|
tuple[str, str]
|
tuple with port names. |
('o1', 'o2')
|
port_types
|
tuple[str, str]
|
tuple with port types. |
('optical', 'edge_coupler')
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
Source code in gdsfactory/components/edge_couplers/edge_coupler_array.py
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 | |
![]()
filters
awg
Sample AWG.
awg
awg(
arms: int = 10,
outputs: int = 3,
free_propagation_region_input_function: ComponentSpec = free_propagation_region_input,
free_propagation_region_output_function: ComponentSpec = free_propagation_region_output,
fpr_spacing: float = 50.0,
arm_spacing: float = 1.0,
length_increment: float = 0.0,
cross_section: CrossSectionSpec = "strip",
) -> Component
Returns an Arrayed Waveguide grating.
To simulate you can use https://github.com/dnrobin/awg-python
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
arms
|
int
|
number of arms. |
10
|
outputs
|
int
|
number of outputs. |
3
|
free_propagation_region_input_function
|
ComponentSpec
|
for input. |
free_propagation_region_input
|
free_propagation_region_output_function
|
ComponentSpec
|
for output. |
free_propagation_region_output
|
fpr_spacing
|
float
|
x separation between input/output free propagation region. |
50.0
|
arm_spacing
|
float
|
y separation between arms (used when length_increment == 0). |
1.0
|
length_increment
|
float
|
constant length step dL (um); when > 0 the arms form a nested fan where arm i is exactly i*dL longer than arm 0 -- the property that makes an AWG disperse light by wavelength. |
0.0
|
cross_section
|
CrossSectionSpec
|
cross_section function. |
'strip'
|
Source code in gdsfactory/components/filters/awg.py
101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 | |
free_propagation_region
free_propagation_region(
width1: float = 2.0,
width2: float = 20.0,
length: float = 20.0,
wg_width: float = 0.5,
inputs: int = 1,
outputs: int = 10,
cross_section: CrossSectionSpec = "strip",
) -> Component
Free propagation region.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width1
|
float
|
width of the input region. |
2.0
|
width2
|
float
|
width of the output region. |
20.0
|
length
|
float
|
length of the free propagation region. |
20.0
|
wg_width
|
float
|
waveguide width. |
0.5
|
inputs
|
int
|
number of inputs. |
1
|
outputs
|
int
|
number of outputs. |
10
|
cross_section
|
CrossSectionSpec
|
cross_section function.
width1| | width2 \ | | |
'strip'
|
Source code in gdsfactory/components/filters/awg.py
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 | |

dbr
DBR gratings.
wavelength = 2periodneff period = wavelength/2/neff
dbr default parameters are from Stephen Lin thesis https://open.library.ubc.ca/cIRcle/collections/ubctheses/24/items/1.0388871
Period: 318nm, width: 500nm, dw: 20 ~ 120 nm.
dbr
dbr(
w1: float = w1,
w2: float = w2,
l1: float = period / 2,
l2: float = period / 2,
n: int = 10,
cross_section: CrossSectionSpec = "strip",
straight_length: float = 0.01,
) -> Component
Distributed Bragg Reflector.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
w1
|
float
|
thin width in um. |
w1
|
w2
|
float
|
thick width in um. |
w2
|
l1
|
float
|
thin length in um. |
period / 2
|
l2
|
float
|
thick length in um. |
period / 2
|
n
|
int
|
number of periods. |
10
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
straight_length
|
float
|
length of the straight section between cutbacks. l1 l2 |
0.01
|
Source code in gdsfactory/components/filters/dbr.py
72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 | |
dbr_cell
dbr_cell(
w1: float = w1,
w2: float = w2,
l1: float = period / 2,
l2: float = period / 2,
cross_section: CrossSectionSpec = "strip",
) -> Component
Distributed Bragg Reflector unit cell.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
w1
|
float
|
thin width in um. |
w1
|
l1
|
float
|
thin length in um. |
period / 2
|
w2
|
float
|
thick width in um. |
w2
|
l2
|
float
|
thick length in um. |
period / 2
|
n
|
number of periods. |
required | |
cross_section
|
CrossSectionSpec
|
cross_section spec. l1 l2 |
'strip'
|
Source code in gdsfactory/components/filters/dbr.py
28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 | |

dbr_cell
dbr_cell(
w1: float = w1,
w2: float = w2,
l1: float = period / 2,
l2: float = period / 2,
cross_section: CrossSectionSpec = "strip",
) -> Component
Distributed Bragg Reflector unit cell.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
w1
|
float
|
thin width in um. |
w1
|
l1
|
float
|
thin length in um. |
period / 2
|
w2
|
float
|
thick width in um. |
w2
|
l2
|
float
|
thick length in um. |
period / 2
|
n
|
number of periods. |
required | |
cross_section
|
CrossSectionSpec
|
cross_section spec. l1 l2 |
'strip'
|
Source code in gdsfactory/components/filters/dbr.py
28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 | |

dbr_tapered
dbr_tapered
dbr_tapered(
length: float = 10.0,
period: float = 0.85,
dc: float = 0.5,
w1: float = 0.4,
w2: float = 1.0,
taper_length: float = 20.0,
fins: bool = False,
fin_size: Size = (0.2, 0.05),
cross_section: CrossSectionSpec = "strip",
) -> Component
Distributed Bragg Reflector Cell class.
Tapers the input straight to a periodic straight structure with varying width (1-D photonic crystal).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
Length of the DBR region. |
10.0
|
period
|
float
|
Period of the repeated unit. |
0.85
|
dc
|
float
|
Duty cycle of the repeated unit (must be a float between 0 and 1.0). |
0.5
|
w1
|
float
|
thin section width. w1 = 0 corresponds to disconnected periodic blocks. |
0.4
|
w2
|
float
|
wide section width. |
1.0
|
taper_length
|
float
|
between the input/output straight and the DBR region. |
20.0
|
fins
|
bool
|
If |
False
|
fin_size
|
Size
|
Specifies the x- and y-size of the |
(0.2, 0.05)
|
cross_section
|
CrossSectionSpec
|
cross_section spec.
<-----><--------> ___ _| w1 w2 ... n times
|
'strip'
|
Source code in gdsfactory/components/filters/dbr_tapered.py
66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 | |

fiber
fiber
fiber(
core_diameter: float = 10,
cladding_diameter: float = 125,
layer_core: LayerSpec = "WG",
layer_cladding: LayerSpec = "WGCLAD",
) -> Component
Returns a fiber.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
core_diameter
|
float
|
in um. |
10
|
cladding_diameter
|
float
|
in um. |
125
|
layer_core
|
LayerSpec
|
layer spec for fiber core. |
'WG'
|
layer_cladding
|
LayerSpec
|
layer spec for fiber cladding. |
'WGCLAD'
|
Source code in gdsfactory/components/filters/fiber.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 | |

fiber_array
fiber_array
fiber_array(
n: int = 8,
pitch: float = 127.0,
core_diameter: float = 10,
cladding_diameter: float = 125,
layer_core: LayerSpec = "WG",
layer_cladding: LayerSpec = "WGCLAD",
) -> Component
Returns a fiber array.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
n
|
int
|
number of fibers. |
8
|
pitch
|
float
|
spacing. |
127.0
|
core_diameter
|
float
|
10um. |
10
|
cladding_diameter
|
float
|
in um. |
125
|
layer_core
|
LayerSpec
|
layer spec for fiber core. |
'WG'
|
layer_cladding
|
LayerSpec
|
layer spec for fiber cladding. |
'WGCLAD'
|
pitch
<->
_________
| | lid
| o o o o |
| | base
|_________|
length
Source code in gdsfactory/components/filters/fiber_array.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 | |

free_propagation_region
free_propagation_region(
width1: float = 2.0,
width2: float = 20.0,
length: float = 20.0,
wg_width: float = 0.5,
inputs: int = 1,
outputs: int = 10,
cross_section: CrossSectionSpec = "strip",
) -> Component
Free propagation region.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width1
|
float
|
width of the input region. |
2.0
|
width2
|
float
|
width of the output region. |
20.0
|
length
|
float
|
length of the free propagation region. |
20.0
|
wg_width
|
float
|
waveguide width. |
0.5
|
inputs
|
int
|
number of inputs. |
1
|
outputs
|
int
|
number of outputs. |
10
|
cross_section
|
CrossSectionSpec
|
cross_section function.
width1| | width2 \ | | |
'strip'
|
Source code in gdsfactory/components/filters/awg.py
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 | |

loop_mirror
Sagnac loop_mirror.
loop_mirror
loop_mirror(
component: ComponentSpec = "mmi1x2",
bend90: ComponentSpec = "bend_euler",
cross_section: CrossSectionSpec = "strip",
) -> Component
Returns Sagnac loop_mirror.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
1x2 splitter. |
'mmi1x2'
|
bend90
|
ComponentSpec
|
90 deg bend. |
'bend_euler'
|
cross_section
|
CrossSectionSpec
|
cross_section settings. |
'strip'
|
Source code in gdsfactory/components/filters/loop_mirror.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 | |

mode_converter
mode_converter
mode_converter(
gap: float = 0.3,
length: float = 10,
coupler_straight_asymmetric: ComponentSpec = "coupler_straight_asymmetric",
bend: ComponentSpec = partial(bend_s, size=(25, 3)),
taper: ComponentSpec = "taper",
mm_width: float = 1.2,
mc_mm_width: float = 1,
sm_width: float = 0.5,
taper_length: float = 25,
cross_section: CrossSectionSpec = "strip",
) -> Component
Returns Mode converter from TE0 to TE1.
By matching the effective indices of two waveguides with different widths, light can couple from different transverse modes e.g. TE0 <-> TE1. https://doi.org/10.1109/JPHOT.2019.2941742
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
gap
|
float
|
directional coupler gap. |
0.3
|
length
|
float
|
coupler length interaction. |
10
|
coupler_straight_asymmetric
|
ComponentSpec
|
spec. |
'coupler_straight_asymmetric'
|
bend
|
ComponentSpec
|
spec. |
partial(bend_s, size=(25, 3))
|
taper
|
ComponentSpec
|
spec. |
'taper'
|
mm_width
|
float
|
input/output multimode waveguide width. |
1.2
|
mc_mm_width
|
float
|
mode converter multimode waveguide width |
1
|
sm_width
|
float
|
single mode waveguide width. |
0.5
|
taper_length
|
float
|
taper length. |
25
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
=
|
multimode width |
required | |
-
|
singlemode width |
required |
Source code in gdsfactory/components/filters/mode_converter.py
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 | |

polarization_splitter_rotator
polarization_splitter_rotator
polarization_splitter_rotator(
width_taper_in: Float3 = (0.54, 0.69, 0.83),
length_taper_in: Float2 | Float3 = (4.0, 44.0),
width_coupler: Float2 = (0.9, 0.404),
length_coupler: float = 7.0,
gap: float = 0.15,
width_out: float = 0.54,
length_out: float = 14.33,
dy: Delta = 5.0,
cross_section: CrossSectionSpec = "strip",
) -> Component
Returns polarization splitter rotator.
"Novel concept for ultracompact polarization splitter-rotator based on silicon nanowires." By D. Dai, and J. E. Bowers (Optics express vol 19, no. 11 pp. 10940-10949 (2011)).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width_taper_in
|
Float3
|
Three west widths of the input tapers in um. |
(0.54, 0.69, 0.83)
|
length_taper_in
|
Float2 | Float3
|
Two or three length of the bend regions in um. |
(4.0, 44.0)
|
width_coupler
|
Float2
|
Top and bottom widths of the coupling region in um. |
(0.9, 0.404)
|
length_coupler
|
float
|
Length of the coupling region in um. |
7.0
|
gap
|
float
|
Distance between the coupler in um. |
0.15
|
width_out
|
float
|
Width of the splitter region in um. |
0.54
|
length_out
|
float
|
Length of the splitter region in um. |
14.33
|
dy
|
Delta
|
Port-to-port distance between the splitter region in um. |
5.0
|
cross_section
|
CrossSectionSpec
|
cross-section spec. |
'strip'
|
Notes
The length of third input taper is automatically determined if only two lengths are in arguments.
Source code in gdsfactory/components/filters/polarization_splitter_rotator.py
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 | |

terminator
terminator
terminator(
length: float | None = 50,
cross_section_input: CrossSectionSpec = strip,
cross_section_tip: CrossSectionSpec | None = None,
tapered_width: float = 0.2,
doping_layers: LayerSpecs = ("NPP",),
doping_offset: float = 1.0,
) -> gf.Component
Returns doped taper to terminate waveguides.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float | None
|
distance between input and narrow tapered end. |
50
|
cross_section_input
|
CrossSectionSpec
|
input cross-section. |
strip
|
cross_section_tip
|
CrossSectionSpec | None
|
cross-section at the end of the termination. |
None
|
tapered_width
|
float
|
width of the default cross-section at the end of the termination. Only used if cross_section_tip is not None. |
0.2
|
doping_layers
|
LayerSpecs
|
doping layers to superimpose on the taper. Default N++. |
('NPP',)
|
doping_offset
|
float
|
offset of the doping layer beyond the bbox |
1.0
|
Source code in gdsfactory/components/filters/terminator.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 | |

terminator_spiral
terminator_spiral
terminator_spiral(
separation: float = 3.0,
width_tip: float = 0.2,
number_of_loops: float = 1,
npoints: int = 1000,
min_bend_radius: float | None = None,
cross_section: CrossSectionSpec = "strip",
) -> gf.Component
Returns doped taper to terminate waveguides.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
separation
|
float
|
separation between the loops. |
3.0
|
width_tip
|
float
|
width of the default cross-section at the end of the termination. Only used if cross_section_tip is not None. |
0.2
|
number_of_loops
|
float
|
number of loops in the spiral. |
1
|
npoints
|
int
|
points for the spiral. |
1000
|
min_bend_radius
|
float | None
|
minimum bend radius for the spiral. |
None
|
cross_section
|
CrossSectionSpec
|
input cross-section. |
'strip'
|
Source code in gdsfactory/components/filters/terminator_spiral.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 | |

grating_couplers
grating_coupler_array
grating_coupler_array
grating_coupler_array(
grating_coupler: ComponentSpec = "grating_coupler_elliptical",
pitch: float = 127.0,
n: int = 6,
port_name: str = "o1",
rotation: int = -90,
with_loopback: bool = False,
cross_section: CrossSectionSpec = "strip",
straight_to_grating_spacing: float = 10.0,
centered: bool = True,
radius: float | None = None,
bend: ComponentSpec = "bend_euler",
mirror_grating_coupler: bool = False,
) -> Component
Array of grating couplers.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
grating_coupler
|
ComponentSpec
|
ComponentSpec. |
'grating_coupler_elliptical'
|
pitch
|
float
|
x spacing. |
127.0
|
n
|
int
|
number of grating couplers. |
6
|
port_name
|
str
|
port name. |
'o1'
|
rotation
|
int
|
rotation angle for each reference. |
-90
|
with_loopback
|
bool
|
if True, adds a loopback between edge GCs. Only works for rotation = 90 for now. |
False
|
cross_section
|
CrossSectionSpec
|
cross_section for the routing. |
'strip'
|
straight_to_grating_spacing
|
float
|
spacing between the last grating coupler and the loopback. |
10.0
|
centered
|
bool
|
if True, centers the array around the origin. |
True
|
radius
|
float | None
|
optional radius for routing the loopback. |
None
|
bend
|
ComponentSpec
|
ComponentSpec for the bend used in the loopback. |
'bend_euler'
|
mirror_grating_coupler
|
bool
|
if True, mirrors the grating coupler. |
False
|
Source code in gdsfactory/components/grating_couplers/grating_coupler_array.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 | |

grating_coupler_dual_pol
grating_coupler_dual_pol
grating_coupler_dual_pol(
unit_cell: ComponentSpec = _unit_cell,
period_x: float = 0.58,
period_y: float = 0.58,
x_span: float = 11,
y_span: float = 11,
length_taper: float = 150.0,
width_taper: float = 10.0,
polarization: str = "te",
wavelength: float = 1.55,
taper: ComponentSpec = "taper",
base_layer: LayerSpec = "WG",
cross_section: CrossSectionSpec = "strip",
) -> Component
2 dimensional, dual polarization grating coupler.
Based on a photonic crystal with a unit cell that is usually an ellipse, a rectangle or a circle. The default values are loosely based on Taillaert et al, "A Compact Two-Dimensional Grating Coupler Used as a Polarization Splitter", IEEE Phot. Techn. Lett. 15(9), 2003.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
unit_cell
|
ComponentSpec
|
component describing the unit cell of the photonic crystal. |
_unit_cell
|
period_x
|
float
|
spacing between unit cells in the x direction [um]. |
0.58
|
period_y
|
float
|
spacing between unit cells in the y direction [um]. |
0.58
|
x_span
|
float
|
full x span of the photonic crystal. |
11
|
y_span
|
float
|
full y span of the photonic crystal. |
11
|
length_taper
|
float
|
taper length [um]. |
150.0
|
width_taper
|
float
|
width of the taper at the grating coupler side [um]. |
10.0
|
polarization
|
str
|
polarization of the grating coupler. |
'te'
|
wavelength
|
float
|
operation wavelength [um] |
1.55
|
taper
|
ComponentSpec
|
function to generate the tapers. |
'taper'
|
base_layer
|
LayerSpec
|
layer to draw over the whole photonic crystal (necessary if the unit cells are etched into a base layer). |
'WG'
|
cross_section
|
CrossSectionSpec
|
for the routing waveguides. |
'strip'
|
Source code in gdsfactory/components/grating_couplers/grating_coupler_dual_pol.py
20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 | |

grating_coupler_elliptical
grating_coupler_elliptical
grating_coupler_elliptical(
polarization: str = "te",
taper_length: float = 16.6,
taper_angle: float = 40.0,
wavelength: float = 1.554,
fiber_angle: float = 15.0,
grating_line_width: float = 0.343,
neff: float = 2.638,
nclad: float = 1.443,
n_periods: int = 30,
big_last_tooth: bool = False,
layer_slab: LayerSpec | None = "SLAB150",
slab_xmin: float = -1.0,
slab_offset: float = 2.0,
spiked: bool = True,
cross_section: CrossSectionSpec = "strip",
) -> Component
Grating coupler with parametrization based on Lumerical FDTD simulation.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
polarization
|
str
|
te or tm. |
'te'
|
taper_length
|
float
|
taper length from input. |
16.6
|
taper_angle
|
float
|
grating flare angle. |
40.0
|
wavelength
|
float
|
grating transmission central wavelength (um). |
1.554
|
fiber_angle
|
float
|
fibre angle in degrees determines ellipticity. |
15.0
|
grating_line_width
|
float
|
in um. |
0.343
|
neff
|
float
|
tooth effective index. |
2.638
|
nclad
|
float
|
cladding effective index. |
1.443
|
n_periods
|
int
|
number of periods. |
30
|
big_last_tooth
|
bool
|
adds a big_last_tooth. |
False
|
layer_slab
|
LayerSpec | None
|
layer that protects the slab under the grating. |
'SLAB150'
|
slab_xmin
|
float
|
where 0 is at the start of the taper. |
-1.0
|
slab_offset
|
float
|
in um. |
2.0
|
spiked
|
bool
|
grating teeth have sharp spikes to avoid non-manhattan drc errors. |
True
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string or dict).
o1 __| |
'strip'
|
Source code in gdsfactory/components/grating_couplers/grating_coupler_elliptical.py
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 | |

grating_coupler_elliptical_arbitrary
grating_coupler_elliptical_arbitrary
grating_coupler_elliptical_arbitrary(
gaps: Floats = _gaps,
widths: Floats = _widths,
taper_length: float = 16.6,
taper_angle: float = 60.0,
wavelength: float = 1.554,
fiber_angle: float = 15.0,
nclad: float = 1.443,
layer_slab: LayerSpec | None = "SLAB150",
layer_grating: LayerSpec | None = None,
taper_to_slab_offset: float = -3.0,
polarization: str = "te",
spiked: bool = True,
bias_gap: float = 0,
cross_section: CrossSectionSpec = "strip",
) -> Component
Grating coupler with parametrization based on Lumerical FDTD simulation.
The ellipticity is derived from Lumerical knowledge base it depends on fiber_angle (degrees), neff, and nclad
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
gaps
|
Floats
|
list of gaps. |
_gaps
|
widths
|
Floats
|
list of widths. |
_widths
|
taper_length
|
float
|
taper length from input. |
16.6
|
taper_angle
|
float
|
grating flare angle. |
60.0
|
wavelength
|
float
|
grating transmission central wavelength (um). |
1.554
|
fiber_angle
|
float
|
fibre angle in degrees determines ellipticity. |
15.0
|
nclad
|
float
|
cladding effective index to compute ellipticity. |
1.443
|
layer_slab
|
LayerSpec | None
|
Optional slab. |
'SLAB150'
|
layer_grating
|
LayerSpec | None
|
Optional layer for grating. by default None uses cross_section.layer. if different from cross_section.layer expands taper. |
None
|
taper_to_slab_offset
|
float
|
0 is where taper ends. |
-3.0
|
polarization
|
str
|
te or tm. |
'te'
|
spiked
|
bool
|
grating teeth have spikes to avoid drc errors. |
True
|
bias_gap
|
float
|
etch gap (um). Positive bias increases gap and reduces width to keep period constant. |
0
|
cross_section
|
CrossSectionSpec
|
cross_section spec for waveguide port. |
'strip'
|
https://en.wikipedia.org/wiki/Ellipse c = (a1 ** 2 - b1 ** 2) ** 0.5 e = (1 - (b1 / a1) ** 2) ** 0.5 print(e)
fiber
/ / / /
/ / / /
_|-|_|-|_|-|___ layer
layer_slab |
o1 ______________|
Source code in gdsfactory/components/grating_couplers/grating_coupler_elliptical_arbitrary.py
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 | |
grating_coupler_elliptical_uniform
grating_coupler_elliptical_uniform(
n_periods: int = 20,
period: float = 0.75,
fill_factor: float = 0.5,
**kwargs: Any
) -> Component
Grating coupler with parametrization based on Lumerical FDTD simulation.
The ellipticity is derived from Lumerical knowledge base it depends on fiber_angle (degrees), neff, and nclad
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
n_periods
|
int
|
number of grating periods. |
20
|
period
|
float
|
grating pitch in um. |
0.75
|
fill_factor
|
float
|
ratio of grating width vs gap. |
0.5
|
Other Parameters:
| Name | Type | Description |
|---|---|---|
taper_length |
taper length from input. |
|
taper_angle |
grating flare angle. |
|
wavelength |
grating transmission central wavelength (um). |
|
fiber_angle |
fibre angle in degrees determines ellipticity. |
|
neff |
tooth effective index to compute ellipticity. |
|
nclad |
cladding effective index to compute ellipticity. |
|
layer_slab |
Optional slab. |
|
taper_to_slab_offset |
where 0 is at the start of the taper. |
|
polarization |
te or tm. |
|
spiked |
grating teeth have spikes to avoid drc errors.. |
|
bias_gap |
etch gap (um). Positive bias increases gap and reduces width to keep period constant. |
|
cross_section |
cross_section spec for waveguide port. |
|
kwargs |
Any
|
cross_section settings.
o1 __| |
Source code in gdsfactory/components/grating_couplers/grating_coupler_elliptical_arbitrary.py
181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 | |

grating_coupler_elliptical_lumerical
grating_coupler_elliptical_lumerical
grating_coupler_elliptical_lumerical(
parameters: Floats = parameters,
layer_slab: LayerSpec | None = "SLAB150",
taper_angle: float = 55,
taper_length: float = 12.24 + 0.36,
fiber_angle: float = 5,
info: dict[str, Any] | None = None,
bias_gap: float = 0,
cross_section: CrossSectionSpec = "strip",
) -> Component
Returns a grating coupler from lumerical inverse design 3D optimization.
this is a wrapper of components.grating_coupler_elliptical_arbitrary https://support.lumerical.com/hc/en-us/articles/1500000306621 https://support.lumerical.com/hc/en-us/articles/360042800573
Here are the simulation settings used in lumerical
n_bg=1.44401 #Refractive index of the background material (cladding)
wg=3.47668 # Refractive index of the waveguide material (core)
lambda0=1550e-9
bandwidth = 0e-9
polarization = 'TE'
wg_width=500e-9 # Waveguide width
wg_height=220e-9 # Waveguide height
etch_depth=80e-9 # etch depth
theta_fib_mat = 5 # Angle of the fiber mode in material
theta_taper=30
efficiency=0.55 # 5.2 dB
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
parameters
|
Floats
|
xinput, gap1, width1, gap2, width2 ... |
parameters
|
layer
|
for waveguide. |
required | |
layer_slab
|
LayerSpec | None
|
for slab. |
'SLAB150'
|
taper_angle
|
float
|
in deg. |
55
|
taper_length
|
float
|
in um. |
12.24 + 0.36
|
fiber_angle
|
float
|
used to compute ellipticity. |
5
|
info
|
dict[str, Any] | None
|
optional simulation settings. |
None
|
bias_gap
|
float
|
gap/trenches bias (um) to compensate for etching bias. |
0
|
Other Parameters:
| Name | Type | Description |
|---|---|---|
taper_length |
float
|
taper length from input in um. |
taper_angle |
float
|
grating flare angle in degrees. |
wavelength |
grating transmission central wavelength (um). |
|
fiber_angle |
float
|
fibre angle in degrees determines ellipticity. |
neff |
tooth effective index. |
|
nclad |
cladding effective index. |
|
polarization |
te or tm. |
|
spiked |
grating teeth include sharp spikes to avoid non-manhattan drc errors. |
|
cross_section |
CrossSectionSpec
|
cross_section spec for waveguide port. |
Source code in gdsfactory/components/grating_couplers/grating_coupler_elliptical_lumerical.py
74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 | |

grating_coupler_elliptical_lumerical_etch70
module-attribute
grating_coupler_elliptical_lumerical_etch70 = partial(
grating_coupler_elliptical_lumerical,
info=dict(
etch_depth=0.08,
link="https://support.lumerical.com/hc/en-us/articles/1500000306621",
fiber_angle=5,
width_min=0.1,
gap_min=0.1,
efficiency=0.55,
),
)

grating_coupler_elliptical_trenches
grating_coupler_elliptical_trenches
grating_coupler_elliptical_trenches(
polarization: str = "te",
taper_length: float = 16.6,
taper_angle: float = 30.0,
trenches_extra_angle: float = 9.0,
wavelength: float = 1.53,
fiber_angle: float = 15.0,
grating_line_width: float = 0.343,
neff: float = 2.638,
ncladding: float = 1.443,
layer_trench: LayerSpec = "SHALLOW_ETCH",
p_start: int = 26,
n_periods: int = 30,
end_straight_length: float = 0.2,
taper: ComponentSpec = "taper",
cross_section: CrossSectionSpec = "strip",
) -> Component
Returns Grating coupler with defined trenches.
Some foundries define the grating coupler by a shallow etch step (trenches) Others define the slab that they keep (see grating_coupler_elliptical)
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
polarization
|
str
|
'te' or 'tm'. |
'te'
|
taper_length
|
float
|
taper length from straight I/O. |
16.6
|
taper_angle
|
float
|
grating flare angle. |
30.0
|
trenches_extra_angle
|
float
|
extra angle for the trenches. |
9.0
|
wavelength
|
float
|
grating transmission central wavelength. |
1.53
|
fiber_angle
|
float
|
fibre polish angle in degrees. |
15.0
|
grating_line_width
|
float
|
of the 220 ridge. |
0.343
|
neff
|
float
|
tooth effective index. |
2.638
|
ncladding
|
float
|
cladding index. |
1.443
|
layer_trench
|
LayerSpec
|
for the trench. |
'SHALLOW_ETCH'
|
p_start
|
int
|
first tooth. |
26
|
n_periods
|
int
|
number of grating teeth. |
30
|
end_straight_length
|
float
|
at the end of straight. |
0.2
|
taper
|
ComponentSpec
|
taper function. |
'taper'
|
cross_section
|
CrossSectionSpec
|
cross_section spec.
|
'strip'
|
Source code in gdsfactory/components/grating_couplers/grating_coupler_elliptical_trenches.py
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 | |

grating_coupler_elliptical_uniform
grating_coupler_elliptical_uniform(
n_periods: int = 20,
period: float = 0.75,
fill_factor: float = 0.5,
**kwargs: Any
) -> Component
Grating coupler with parametrization based on Lumerical FDTD simulation.
The ellipticity is derived from Lumerical knowledge base it depends on fiber_angle (degrees), neff, and nclad
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
n_periods
|
int
|
number of grating periods. |
20
|
period
|
float
|
grating pitch in um. |
0.75
|
fill_factor
|
float
|
ratio of grating width vs gap. |
0.5
|
Other Parameters:
| Name | Type | Description |
|---|---|---|
taper_length |
taper length from input. |
|
taper_angle |
grating flare angle. |
|
wavelength |
grating transmission central wavelength (um). |
|
fiber_angle |
fibre angle in degrees determines ellipticity. |
|
neff |
tooth effective index to compute ellipticity. |
|
nclad |
cladding effective index to compute ellipticity. |
|
layer_slab |
Optional slab. |
|
taper_to_slab_offset |
where 0 is at the start of the taper. |
|
polarization |
te or tm. |
|
spiked |
grating teeth have spikes to avoid drc errors.. |
|
bias_gap |
etch gap (um). Positive bias increases gap and reduces width to keep period constant. |
|
cross_section |
cross_section spec for waveguide port. |
|
kwargs |
Any
|
cross_section settings.
o1 __| |
Source code in gdsfactory/components/grating_couplers/grating_coupler_elliptical_arbitrary.py
181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 | |

grating_coupler_loss
grating_coupler_loss
grating_coupler_loss(
pitch: float = 127.0,
grating_coupler: ComponentSpec = "grating_coupler_elliptical_trenches",
cross_section: CrossSectionSpec = "strip",
port_name: str = "o1",
rotation: float = -90,
nfibers: int = 10,
grating_coupler_spacing: float = 5.0,
) -> Component
Grating coupler test structure for de-embeding fiber array.
Connects channel 1->3, 1->5 ... 1->nfibers with grating couplers.
Only odd channels are connected to the grating couplers as even channels in the align_tree.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pitch
|
float
|
um. |
127.0
|
grating_coupler
|
ComponentSpec
|
spec. |
'grating_coupler_elliptical_trenches'
|
cross_section
|
CrossSectionSpec
|
spec. |
'strip'
|
port_name
|
str
|
for the grating_coupler port. |
'o1'
|
rotation
|
float
|
degrees. |
-90
|
nfibers
|
int
|
number of fibers to connect. |
10
|
grating_coupler_spacing
|
float
|
um. |
5.0
|
Source code in gdsfactory/components/grating_couplers/grating_coupler_loss.py
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 | |

grating_coupler_rectangular
grating_coupler_rectangular
grating_coupler_rectangular(
n_periods: int = 20,
period: float = 0.75,
fill_factor: float = 0.5,
width_grating: float = 11.0,
length_taper: float = 150.0,
polarization: str = "te",
wavelength: float = 1.55,
taper: ComponentSpec = "taper",
layer_slab: LayerSpec | None = "SLAB150",
layer_grating: LayerSpec | None = None,
fiber_angle: float = 15,
slab_xmin: float = -1.0,
slab_offset: float = 1.0,
cross_section: CrossSectionSpec = "strip",
) -> Component
Grating coupler with rectangular shapes (not elliptical).
Needs longer taper than elliptical. Grating teeth are straight. For a focusing grating take a look at grating_coupler_elliptical.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
n_periods
|
int
|
number of grating teeth. |
20
|
period
|
float
|
grating pitch. |
0.75
|
fill_factor
|
float
|
ratio of grating width vs gap. |
0.5
|
width_grating
|
float
|
11. |
11.0
|
length_taper
|
float
|
150. |
150.0
|
polarization
|
str
|
'te' or 'tm'. |
'te'
|
wavelength
|
float
|
in um. |
1.55
|
taper
|
ComponentSpec
|
function. |
'taper'
|
layer_slab
|
LayerSpec | None
|
layer that protects the slab under the grating. |
'SLAB150'
|
layer_grating
|
LayerSpec | None
|
layer for the grating. |
None
|
fiber_angle
|
float
|
in degrees. |
15
|
slab_xmin
|
float
|
where 0 is at the start of the taper. |
-1.0
|
slab_offset
|
float
|
from edge of grating to edge of the slab. |
1.0
|
cross_section
|
CrossSectionSpec
|
for input waveguide port. |
'strip'
|
Source code in gdsfactory/components/grating_couplers/grating_coupler_rectangular.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 | |

grating_coupler_rectangular_arbitrary
grating_coupler_rectangular_arbitrary
grating_coupler_rectangular_arbitrary(
gaps: Floats = _gaps,
widths: Floats = _widths,
width_grating: float = 11.0,
length_taper: float = 150.0,
polarization: str = "te",
wavelength: float = 1.55,
layer_grating: LayerSpec | None = None,
layer_slab: LayerSpec | None = None,
slab_xmin: float = -1.0,
slab_offset: float = 1.0,
fiber_angle: float = 15,
cross_section: CrossSectionSpec = "strip",
) -> Component
Grating coupler uniform with rectangular shape (not elliptical).
Therefore it needs a longer taper. Grating teeth are straight instead of elliptical.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
gaps
|
Floats
|
list of gaps between grating teeth. |
_gaps
|
widths
|
Floats
|
list of grating widths. |
_widths
|
width_grating
|
float
|
grating teeth width. |
11.0
|
length_taper
|
float
|
taper length (um). |
150.0
|
polarization
|
str
|
'te' or 'tm'. |
'te'
|
wavelength
|
float
|
in um. |
1.55
|
layer_grating
|
LayerSpec | None
|
Optional layer for grating. \ by default None uses cross_section.layer. \ if different from cross_section.layer expands taper. |
None
|
layer_slab
|
LayerSpec | None
|
layer that protects the slab under the grating. |
None
|
slab_xmin
|
float
|
where 0 is at the start of the taper. |
-1.0
|
slab_offset
|
float
|
from edge of grating to edge of the slab. |
1.0
|
fiber_angle
|
float
|
in degrees. |
15
|
cross_section
|
CrossSectionSpec
|
for input waveguide port.
o1 __| |
'strip'
|
Source code in gdsfactory/components/grating_couplers/grating_coupler_rectangular_arbitrary.py
18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 | |

grating_coupler_tree
grating_coupler_tree
grating_coupler_tree(
n: int = 4,
straight_spacing: float = 4.0,
grating_coupler: ComponentSpec = "grating_coupler_elliptical_te",
with_loopback: bool = False,
bend: ComponentSpec = "bend_euler",
fanout_length: float = 0.0,
cross_section: CrossSectionSpec = "strip",
**kwargs: Any
) -> Component
Array of straights connected with grating couplers.
useful to align the 4 corners of the chip
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
n
|
int
|
number of gratings. |
4
|
straight_spacing
|
float
|
in um. |
4.0
|
grating_coupler
|
ComponentSpec
|
spec. |
'grating_coupler_elliptical_te'
|
with_loopback
|
bool
|
adds loopback. |
False
|
bend
|
ComponentSpec
|
bend spec. |
'bend_euler'
|
fanout_length
|
float
|
in um. |
0.0
|
cross_section
|
CrossSectionSpec
|
cross_section function. |
'strip'
|
kwargs
|
Any
|
additional arguments. |
{}
|
Source code in gdsfactory/components/grating_couplers/grating_coupler_tree.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 | |

mems
anchored_flexure
anchored_flexure
anchored_flexure(
hinge_width: float = 0.3,
hinge_length: float = 5.0,
pad_width: float = 10.0,
pad_length: float = 10.0,
layer: LayerSpec = "WG",
port_type: str = "electrical",
) -> Component
Returns a flexure hinge between two pads.
Two rectangular pads connected by a thin hinge, all centered vertically.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
hinge_width
|
float
|
width of the thin flexure hinge. |
0.3
|
hinge_length
|
float
|
length of the hinge connecting the two pads. |
5.0
|
pad_width
|
float
|
width (vertical) of each pad. |
10.0
|
pad_length
|
float
|
length (horizontal) of each pad. |
10.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
port_type
|
str
|
port type for electrical ports. |
'electrical'
|
Source code in gdsfactory/components/mems/anchored_flexure.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 | |

bent_beam
bent_beam
bent_beam(
beam_width: float = 1.0,
beam_length: float = 40.0,
bend_angle: float = 170.0,
anchor_width: float = 5.0,
anchor_length: float = 5.0,
layer: LayerSpec = "WG",
port_type: str = "electrical",
) -> Component
Returns a V-shaped bent beam thermal actuator.
Two straight beam segments meeting at an apex that points upward, with anchor pads at both ends.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
beam_width
|
float
|
width of the beam. |
1.0
|
beam_length
|
float
|
length of each beam segment (center-line). |
40.0
|
bend_angle
|
float
|
angle between the two beam segments in degrees. |
170.0
|
anchor_width
|
float
|
width (vertical) of each anchor pad. |
5.0
|
anchor_length
|
float
|
length (horizontal) of each anchor pad. |
5.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
port_type
|
str
|
port type for electrical ports. |
'electrical'
|
Source code in gdsfactory/components/mems/bent_beam.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 | |

bolometer
bolometer
bolometer(
absorber_width: float = 20.0,
absorber_length: float = 20.0,
leg_width: float = 0.5,
leg_length: float = 15.0,
n_legs: int = 4,
pad_width: float = 5.0,
pad_length: float = 5.0,
layer: LayerSpec = "WG",
port_type: str = "electrical",
) -> Component
Returns a bolometer thermal detector.
A central absorber rectangle with thin L-shaped support legs extending outward to anchor pads distributed around the perimeter.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
absorber_width
|
float
|
width of the central absorber. |
20.0
|
absorber_length
|
float
|
length of the central absorber. |
20.0
|
leg_width
|
float
|
width of each support leg. |
0.5
|
leg_length
|
float
|
length of each support leg. |
15.0
|
n_legs
|
int
|
number of support legs (distributed around perimeter). |
4
|
pad_width
|
float
|
width of each anchor pad. |
5.0
|
pad_length
|
float
|
length of each anchor pad. |
5.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
port_type
|
str
|
port type for electrical ports. |
'electrical'
|
Source code in gdsfactory/components/mems/bolometer.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 | |

cantilever
cantilever
cantilever(
beam_width: float = 2.0,
beam_length: float = 20.0,
anchor_width: float = 5.0,
anchor_length: float = 5.0,
layer: LayerSpec = "WG",
port_type: str = "electrical",
) -> Component
Returns a simple cantilever beam with an anchor.
A rectangular anchor on the left with a thinner beam extending to the right.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
beam_width
|
float
|
width of the cantilever beam. |
2.0
|
beam_length
|
float
|
length of the cantilever beam. |
20.0
|
anchor_width
|
float
|
width (vertical) of the anchor pad. |
5.0
|
anchor_length
|
float
|
length (horizontal) of the anchor pad. |
5.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
port_type
|
str
|
port type for electrical ports. |
'electrical'
|
Source code in gdsfactory/components/mems/cantilever.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 | |

comb_drive
comb_drive
comb_drive(
finger_width: float = 0.5,
finger_length: float = 10.0,
finger_gap: float = 0.5,
n_fingers: int = 20,
finger_overlap: float = 5.0,
shuttle_width: float = 5.0,
shuttle_length: float = 30.0,
spring_width: float = 0.5,
spring_length: float = 20.0,
n_spring_folds: int = 4,
anchor_size: float = 10.0,
layer: LayerSpec = "WG",
) -> Component
Returns a comb drive actuator with interdigitated fingers and folded springs.
A central shuttle with comb fingers on both sides, fixed electrodes with interleaving fingers, and folded springs connecting the shuttle to corner anchor pads.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
finger_width
|
float
|
width of each comb finger. |
0.5
|
finger_length
|
float
|
length of each comb finger. |
10.0
|
finger_gap
|
float
|
gap between adjacent moving and fixed fingers. |
0.5
|
n_fingers
|
int
|
number of moving fingers on each side. |
20
|
finger_overlap
|
float
|
overlap length between moving and fixed fingers in the actuation direction. |
5.0
|
shuttle_width
|
float
|
width (vertical) of the shuttle mass. |
5.0
|
shuttle_length
|
float
|
length (horizontal) of the shuttle mass. |
30.0
|
spring_width
|
float
|
width of spring beam segments. |
0.5
|
spring_length
|
float
|
length of each spring fold segment. |
20.0
|
n_spring_folds
|
int
|
number of folds in each folded spring. |
4
|
anchor_size
|
float
|
size of each square anchor pad. |
10.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
Source code in gdsfactory/components/mems/comb_drive.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 | |

doubly_clamped_beam
doubly_clamped_beam
doubly_clamped_beam(
beam_width: float = 1.0,
beam_length: float = 30.0,
anchor_width: float = 5.0,
anchor_length: float = 5.0,
layer: LayerSpec = "WG",
port_type: str = "electrical",
) -> Component
Returns a doubly clamped beam fixed at both ends.
Two anchor pads connected by a thin beam, centered at the origin.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
beam_width
|
float
|
width of the beam. |
1.0
|
beam_length
|
float
|
length of the beam between the two anchors. |
30.0
|
anchor_width
|
float
|
width (vertical) of each anchor pad. |
5.0
|
anchor_length
|
float
|
length (horizontal) of each anchor pad. |
5.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
port_type
|
str
|
port type for electrical ports. |
'electrical'
|
Source code in gdsfactory/components/mems/doubly_clamped_beam.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 | |

folded_spring
folded_spring
folded_spring(
beam_width: float = 0.5,
beam_length: float = 20.0,
n_folds: int = 4,
fold_gap: float = 1.0,
anchor_width: float = 5.0,
anchor_length: float = 3.0,
layer: LayerSpec = "WG",
port_type: str = "electrical",
) -> Component
Returns a folded flexure spring (serpentine meander).
Alternating horizontal beams connected at their ends forming a serpentine pattern. Starts at a bottom anchor and ends at a top anchor.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
beam_width
|
float
|
width of each beam segment. |
0.5
|
beam_length
|
float
|
length of each horizontal beam segment. |
20.0
|
n_folds
|
int
|
number of horizontal beam segments. |
4
|
fold_gap
|
float
|
vertical gap between adjacent beams. |
1.0
|
anchor_width
|
float
|
width (horizontal) of the anchor pads. |
5.0
|
anchor_length
|
float
|
length (vertical) of the anchor pads. |
3.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
port_type
|
str
|
port type for electrical ports. |
'electrical'
|
Source code in gdsfactory/components/mems/folded_spring.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 | |

gear
gear
gear(
n_teeth: int = 20,
module_size: float = 2.0,
pressure_angle: float = 20.0,
hub_radius: float | None = None,
hub_hole_radius: float = 0.0,
layer: LayerSpec = "WG",
) -> Component
Returns a gear with simplified trapezoidal teeth.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
n_teeth
|
int
|
number of teeth. |
20
|
module_size
|
float
|
gear module (pitch diameter / number of teeth). |
2.0
|
pressure_angle
|
float
|
pressure angle in degrees. |
20.0
|
hub_radius
|
float | None
|
radius of the central hub disc. Defaults to root_radius * 0.6. |
None
|
hub_hole_radius
|
float
|
radius of a center hole (0 to disable). |
0.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
Source code in gdsfactory/components/mems/gear.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 | |

microfluidics
arrow_junction
arrow_junction
arrow_junction(
main_width: float = 1.0,
branch_width: float = 1.0,
main_length: float = 20.0,
branch_length: float = 10.0,
branch_angle: float = 35.0,
reservoir_radius: float = 0.0,
n_reservoir_points: int = 64,
layer: LayerSpec = "WG",
port_type: str | None = "optical",
) -> Component
Returns a microfluidic arrow (Y) junction.
A main horizontal channel on the right side with two angled branches diverging to the left at +/- branch_angle from horizontal. The junction point is at the origin.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
main_width
|
float
|
width of the main horizontal channel. |
1.0
|
branch_width
|
float
|
width of each angled branch channel. |
1.0
|
main_length
|
float
|
length of the main channel (extends to the right). |
20.0
|
branch_length
|
float
|
length of each angled branch. |
10.0
|
branch_angle
|
float
|
angle of each branch from horizontal (degrees). |
35.0
|
reservoir_radius
|
float
|
radius of circular reservoirs at endpoints (0 to disable). |
0.0
|
n_reservoir_points
|
int
|
number of polygon points for reservoir circles. |
64
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
port_type
|
str | None
|
None, optical, or electrical. |
'optical'
|
Source code in gdsfactory/components/microfluidics/arrow_junction.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 | |

h_junction
h_junction
h_junction(
main_width: float = 1.0,
branch_width: float = 1.0,
main_length: float = 20.0,
branch_length: float = 10.0,
reservoir_radius: float = 0.0,
n_reservoir_points: int = 64,
layer: LayerSpec = "WG",
port_type: str | None = "optical",
) -> Component
Returns a microfluidic H-junction.
A horizontal main channel with two vertical branches extending up and down from the center. Optionally adds circular reservoirs at the four endpoints.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
main_width
|
float
|
width of the main horizontal channel. |
1.0
|
branch_width
|
float
|
width of the vertical branch channels. |
1.0
|
main_length
|
float
|
total length of the main channel. |
20.0
|
branch_length
|
float
|
length of each vertical branch. |
10.0
|
reservoir_radius
|
float
|
radius of circular reservoirs at endpoints (0 to disable). |
0.0
|
n_reservoir_points
|
int
|
number of polygon points for reservoir circles. |
64
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
port_type
|
str | None
|
None, optical, or electrical. |
'optical'
|
Source code in gdsfactory/components/microfluidics/h_junction.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 | |

meander_channel
meander_channel
meander_channel(
channel_width: float = 1.0,
n_turns: int = 5,
turn_spacing: float = 5.0,
straight_length: float = 20.0,
reservoir_length: float = 5.0,
reservoir_height: float = 5.0,
layer: LayerSpec = "WG",
port_type: str | None = "optical",
) -> Component
Returns a microfluidic meander (serpentine) channel.
Builds a series of connected rectangles forming a serpentine path. Starts from the left, goes right for straight_length, turns up/down by turn_spacing, goes back left, and repeats for n_turns. Rectangular reservoirs are added at the inlet and outlet when reservoir_length > 0.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
channel_width
|
float
|
width of the channel. |
1.0
|
n_turns
|
int
|
number of straight segments (horizontal passes). |
5
|
turn_spacing
|
float
|
center-to-center vertical spacing between passes. |
5.0
|
straight_length
|
float
|
length of each horizontal segment. |
20.0
|
reservoir_length
|
float
|
length of the reservoirs at inlet/outlet. |
5.0
|
reservoir_height
|
float
|
height of the reservoirs at inlet/outlet. |
5.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
port_type
|
str | None
|
None, optical, or electrical. |
'optical'
|
Source code in gdsfactory/components/microfluidics/meander_channel.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 | |

t_junction
t_junction
t_junction(
main_width: float = 1.0,
branch_width: float = 1.0,
main_length: float = 20.0,
branch_length: float = 10.0,
reservoir_radius: float = 0.0,
n_reservoir_points: int = 64,
layer: LayerSpec = "WG",
port_type: str | None = "optical",
) -> Component
Returns a microfluidic T-junction.
A horizontal main channel with a vertical branch going up from the center. Optionally adds circular reservoirs at the three endpoints.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
main_width
|
float
|
width of the main horizontal channel. |
1.0
|
branch_width
|
float
|
width of the vertical branch channel. |
1.0
|
main_length
|
float
|
total length of the main channel. |
20.0
|
branch_length
|
float
|
length of the vertical branch. |
10.0
|
reservoir_radius
|
float
|
radius of circular reservoirs at endpoints (0 to disable). |
0.0
|
n_reservoir_points
|
int
|
number of polygon points for reservoir circles. |
64
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
port_type
|
str | None
|
None, optical, or electrical. |
'optical'
|
Source code in gdsfactory/components/microfluidics/t_junction.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 | |

mmis
mmi
mmi
mmi(
inputs: int = 1,
outputs: int = 4,
width: float | None = None,
width_taper: float = 1.0,
length_taper: float = 10.0,
length_mmi: float = 5.5,
width_mmi: float = 5,
gap_input_tapers: float = 0.25,
gap_output_tapers: float = 0.25,
taper: ComponentSpec = "taper",
straight: ComponentSpec = "straight",
cross_section: CrossSectionSpec = "strip",
input_positions: list[float] | None = None,
output_positions: list[float] | None = None,
) -> Component
Mxn MultiMode Interferometer (MMI).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
inputs
|
int
|
number of inputs. |
1
|
outputs
|
int
|
number of outputs. |
4
|
width
|
float | None
|
input and output straight width. Defaults to cross_section. |
None
|
width_taper
|
float
|
interface between input straights and mmi region. |
1.0
|
length_taper
|
float
|
into the mmi region. |
10.0
|
length_mmi
|
float
|
in x direction. |
5.5
|
width_mmi
|
float
|
in y direction. |
5
|
gap_input_tapers
|
float
|
gap between input tapers from edge to edge. |
0.25
|
gap_output_tapers
|
float
|
gap between output tapers from edge to edge. |
0.25
|
taper
|
ComponentSpec
|
taper function. |
'taper'
|
straight
|
ComponentSpec
|
straight function. |
'straight'
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string or dict). |
'strip'
|
input_positions
|
list[float] | None
|
optional positions of the inputs. |
None
|
output_positions
|
list[float] | None
|
optional positions of the outputs.
o2 __ __ o3 \ / _ _ _ | | _ _ _ | gap_output_tapers / _ o1 __ __ o4 \ / |_____| | | <-> length_taper |
None
|
Source code in gdsfactory/components/mmis/mmi.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 | |

mmi1x2
mmi1x2
mmi1x2(
width: float | None = None,
width_taper: float = 1.0,
length_taper: float = 10.0,
length_mmi: float = 5.5,
width_mmi: float = 2.5,
gap_mmi: float = 0.25,
taper: ComponentSpec = taper_function,
straight: ComponentSpec = straight_function,
cross_section: CrossSectionSpec = "strip",
) -> Component
1x2 MultiMode Interferometer (MMI).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float | None
|
input and output straight width. Defaults to cross_section width. |
None
|
width_taper
|
float
|
interface between input straights and mmi region. |
1.0
|
length_taper
|
float
|
into the mmi region. |
10.0
|
length_mmi
|
float
|
in x direction. |
5.5
|
width_mmi
|
float
|
in y direction. |
2.5
|
gap_mmi
|
float
|
gap between tapered wg. |
0.25
|
taper
|
ComponentSpec
|
taper function. |
taper
|
straight
|
ComponentSpec
|
straight function. |
straight
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string or dict). length_mmi <------> _ | | | _ | __ o2 / / _ _ _ o1 __ | _ _ _ | gap_mmi \ _ | __ o3 | / |_____| <-> |
'strip'
|
Source code in gdsfactory/components/mmis/mmi1x2.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 | |

mmi1x2_with_sbend
mmi1x2_with_sbend
mmi1x2_with_sbend(
with_sbend: bool = True,
s_bend: ComponentFactory = bend_s,
cross_section: CrossSectionSpec = "strip",
) -> Component
Returns 1x2 splitter for Cband.
https://opg.optica.org/oe/fulltext.cfm?uri=oe-21-1-1310&id=248418
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
with_sbend
|
bool
|
add sbend. |
True
|
s_bend
|
ComponentFactory
|
S-bend spec. |
bend_s
|
cross_section
|
CrossSectionSpec
|
spec. |
'strip'
|
Source code in gdsfactory/components/mmis/mmi1x2_with_sbend.py
42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 | |

mmi2x2
mmi2x2
mmi2x2(
width: float | None = None,
width_taper: float = 1.0,
length_taper: float = 10.0,
length_mmi: float = 5.5,
width_mmi: float = 2.5,
gap_mmi: float = 0.25,
taper: ComponentSpec = taper_function,
straight: ComponentSpec = straight_function,
cross_section: CrossSectionSpec = "strip",
) -> Component
Mmi 2x2.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float | None
|
input and output straight width. |
None
|
width_taper
|
float
|
interface between input straights and mmi region. |
1.0
|
length_taper
|
float
|
into the mmi region. |
10.0
|
length_mmi
|
float
|
in x direction. |
5.5
|
width_mmi
|
float
|
in y direction. |
2.5
|
gap_mmi
|
float
|
(width_taper + gap between tapered wg)/2. |
0.25
|
taper
|
ComponentSpec
|
taper function. |
taper
|
straight
|
ComponentSpec
|
straight function. |
straight
|
cross_section
|
CrossSectionSpec
|
spec.
o2 __ __ o3 \ / _ _ _ | | _ _ _ | gap_mmi / _ o1 __ __ o4 \ / |_____|
length_taper |
'strip'
|
Source code in gdsfactory/components/mmis/mmi2x2.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 | |

mmi2x2_with_sbend
mmi2x2_with_sbend
mmi2x2_with_sbend(
with_sbend: bool = True,
s_bend: ComponentFactory = bend_s,
cross_section: CrossSectionSpec = "strip",
) -> Component
Returns mmi2x2 for Cband.
C_band 2x2MMI in 220nm thick silicon https://opg.optica.org/oe/fulltext.cfm?uri=oe-25-23-28957&id=376719
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
with_sbend
|
bool
|
add sbend. |
True
|
s_bend
|
ComponentFactory
|
S-bend function. |
bend_s
|
cross_section
|
CrossSectionSpec
|
spec. |
'strip'
|
Source code in gdsfactory/components/mmis/mmi2x2_with_sbend.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 | |

mmi_90degree_hybrid
mmi_90degree_hybrid
mmi_90degree_hybrid(
width: float = 0.5,
width_taper: float = 1.7,
length_taper: float = 40.0,
length_mmi: float = 175.0,
width_mmi: float = 10.0,
gap_mmi: float = 0.8,
straight: ComponentSpec = "straight",
cross_section: CrossSectionSpec = "strip",
) -> Component
90 degree hybrid based on a 4x4 MMI.
Default values from Watanabe et al., "Coherent few mode demultiplexer realized as a 2D grating coupler array in silicon", Optics Express 28(24), 2020
It could be interesting to consider the design in Guan et al., "Compact and low loss 90° optical hybrid on a silicon-on-insulator platform", Optics Express 25(23), 2017
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
input and output straight width. |
0.5
|
width_taper
|
float
|
interface between input straights and mmi region. |
1.7
|
length_taper
|
float
|
into the mmi region. |
40.0
|
length_mmi
|
float
|
in x direction. |
175.0
|
width_mmi
|
float
|
in y direction. |
10.0
|
gap_mmi
|
float
|
(width_taper + gap between tapered wg)/2. |
0.8
|
straight
|
ComponentSpec
|
straight function. |
'straight'
|
with_bbox
|
box in bbox_layers and bbox_offsets avoid DRC sharp edges. |
required | |
cross_section
|
CrossSectionSpec
|
spec. |
'strip'
|
length_mmi
<------>
________
| |
__/ \__
signal_in __ __ I_out1
\ /_ _ _ _
| | _ _ _ _| gap_mmi
| \__
| __ Q_out1
| /
| |
|
__/ \__
LO_in __ __ Q_out2
\ /_ _ _ _
| | _ _ _ _| gap_mmi
| \__
| __ I_out2
| /
| ________|
<->
length_taper
Source code in gdsfactory/components/mmis/mmi_90degree_hybrid.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 | |

mmi_tapered
mmi_tapered
mmi_tapered(
inputs: int = 1,
outputs: int = 2,
width: float | None = None,
width_taper_in: float = 2.0,
length_taper_in: float = 1.0,
width_taper_out: float | None = None,
length_taper_out: float | None = None,
width_taper: float = 1.0,
length_taper: float = 10.0,
length_taper_start: float | None = None,
length_taper_end: float | None = None,
length_mmi: float = 5.5,
width_mmi: float = 5,
width_mmi_inner: float | None = None,
gap_input_tapers: float = 0.25,
gap_output_tapers: float = 0.25,
taper: ComponentFactory = taper_function,
cross_section: CrossSectionSpec = "strip",
input_positions: list[float] | None = None,
output_positions: list[float] | None = None,
) -> Component
Mxn MultiMode Interferometer (MMI).
This is jut a more general version of the mmi component. Make sure you simulate and optimize the component before using it.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
inputs
|
int
|
number of inputs. |
1
|
outputs
|
int
|
number of outputs. |
2
|
width
|
float | None
|
input and output straight width. Defaults to cross_section. |
None
|
width_taper_in
|
float
|
interface between input straights and mmi region. |
2.0
|
length_taper_in
|
float
|
into the mmi region. |
1.0
|
width_taper_out
|
float | None
|
interface between mmi region and output straights. |
None
|
length_taper_out
|
float | None
|
into the mmi region. |
None
|
width_taper
|
float
|
interface between mmi region and output straights. |
1.0
|
length_taper
|
float
|
into the mmi region. |
10.0
|
length_taper_start
|
float | None
|
length of the taper at the start. Defaults to length_taper. |
None
|
length_taper_end
|
float | None
|
length of the taper at the end. Defaults to length_taper. |
None
|
length_mmi
|
float
|
in x direction. |
5.5
|
width_mmi
|
float
|
in y direction. |
5
|
width_mmi_inner
|
float | None
|
allows adding a different width for the inner mmi region. |
None
|
gap_input_tapers
|
float
|
gap between input tapers from edge to edge. |
0.25
|
gap_output_tapers
|
float
|
gap between output tapers from edge to edge. |
0.25
|
taper
|
ComponentFactory
|
taper function. |
taper
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string or dict). |
'strip'
|
input_positions
|
list[float] | None
|
optional positions of the inputs. |
None
|
output_positions
|
list[float] | None
|
optional positions of the outputs.
width_taper │ │ │ │ ▲ ┌────────────────┤ │ ├────────────┘ │ │ │ ├───────────────┘ |
None
|
Source code in gdsfactory/components/mmis/mmi_tapered.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 | |

mzis
mzi
mzi
mzi(
delta_length: float = 10.0,
length_y: float = 2.0,
length_x: float | None = 0.1,
bend: ComponentSpec = "bend_euler",
straight: ComponentSpec = "straight",
straight_y: ComponentSpec | None = None,
straight_x_top: ComponentSpec | None = None,
straight_x_bot: ComponentSpec | None = None,
splitter: ComponentSpec = "mmi1x2",
combiner: ComponentSpec | None = None,
with_splitter: bool = True,
port_e1_splitter: str = "o2",
port_e0_splitter: str = "o3",
port_e1_combiner: str = "o2",
port_e0_combiner: str = "o3",
port1: str = "o1",
port2: str = "o2",
nbends: int = 2,
cross_section: CrossSectionSpec = "strip",
cross_section_x_top: CrossSectionSpec | None = None,
cross_section_x_bot: CrossSectionSpec | None = None,
mirror_bot: bool = False,
add_optical_ports_arms: bool = False,
min_length: float = 0.01,
auto_rename_ports: bool = True,
auto_detect_port_names: bool = False,
) -> Component
Mzi.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
delta_length
|
float
|
bottom arm vertical extra length. |
10.0
|
length_y
|
float
|
vertical length for both and top arms. |
2.0
|
length_x
|
float | None
|
horizontal length. None uses to the straight_x_bot/top defaults. |
0.1
|
bend
|
ComponentSpec
|
90 degrees bend library. |
'bend_euler'
|
straight
|
ComponentSpec
|
straight function. |
'straight'
|
straight_y
|
ComponentSpec | None
|
straight for length_y and delta_length. |
None
|
straight_x_top
|
ComponentSpec | None
|
top straight for length_x. |
None
|
straight_x_bot
|
ComponentSpec | None
|
bottom straight for length_x. |
None
|
splitter
|
ComponentSpec
|
splitter function. |
'mmi1x2'
|
combiner
|
ComponentSpec | None
|
combiner function. |
None
|
with_splitter
|
bool
|
if False removes splitter. |
True
|
port_e1_splitter
|
str
|
east top splitter port. |
'o2'
|
port_e0_splitter
|
str
|
east bot splitter port. |
'o3'
|
port_e1_combiner
|
str
|
east top combiner port. |
'o2'
|
port_e0_combiner
|
str
|
east bot combiner port. |
'o3'
|
port1
|
str
|
input port name. |
'o1'
|
port2
|
str
|
output port name. |
'o2'
|
nbends
|
int
|
from straight top/bot to combiner (at least 2). |
2
|
cross_section
|
CrossSectionSpec
|
for routing (sxtop/sxbot to combiner). |
'strip'
|
cross_section_x_top
|
CrossSectionSpec | None
|
optional top cross_section (defaults to cross_section). |
None
|
cross_section_x_bot
|
CrossSectionSpec | None
|
optional bottom cross_section (defaults to cross_section). |
None
|
mirror_bot
|
bool
|
if true, mirrors the bottom arm. |
False
|
add_optical_ports_arms
|
bool
|
add all other optical ports in the arms with top\ and bot\ prefix. |
False
|
min_length
|
float
|
minimum length for the straight. |
0.01
|
auto_rename_ports
|
bool
|
if True, renames ports. |
True
|
auto_detect_port_names
|
bool
|
whether to auto detect ports names. Ignores port_e* arguments if True.
straight_y | | | b1 b4 splitter==| |==combiner b5 b8 | | straight_y | | | |
False
|
Source code in gdsfactory/components/mzis/mzi.py
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 | |

mzi1x2_2x2
module-attribute
mzi1x2_2x2 = partial(
mzi,
combiner="mmi2x2",
port_e1_combiner="o3",
port_e0_combiner="o4",
)

mzi2x2_2x2_phase_shifter
module-attribute
mzi2x2_2x2_phase_shifter = partial(
mzi2x2_2x2,
straight_x_top="straight_heater_metal",
length_x=200,
)

mzi_lattice
mzi_lattice
mzi_lattice(
coupler_lengths: Sequence[float] = (10.0, 20.0),
coupler_gaps: Sequence[float] = (0.2, 0.3),
delta_lengths: Sequence[float] = (10.0,),
mzi: str = "mzi_coupler",
splitter: str = "coupler",
**kwargs: Any
) -> Component
Mzi lattice filter.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
coupler_lengths
|
Sequence[float]
|
list of length for each coupler. |
(10.0, 20.0)
|
coupler_gaps
|
Sequence[float]
|
list of coupler gaps. |
(0.2, 0.3)
|
delta_lengths
|
Sequence[float]
|
list of length differences. |
(10.0,)
|
mzi
|
str
|
function for the mzi. |
'mzi_coupler'
|
splitter
|
str
|
splitter function. |
'coupler'
|
kwargs
|
Any
|
additional settings. |
{}
|
Other Parameters:
| Name | Type | Description |
|---|---|---|
length_y |
vertical length for both and top arms. |
|
length_x |
horizontal length. |
|
bend |
90 degrees bend library. |
|
straight |
straight function. |
|
straight_y |
straight for length_y and delta_length. |
|
straight_x_top |
top straight for length_x. |
|
straight_x_bot |
bottom straight for length_x. |
|
cross_section |
for routing (sxtop/sxbot to combiner). __ _ | | | | | | | | cp1==| |===cp2=====| |=== .... ===cplast=== | | | | | | | | DL1 | DL2 | | | | | |_| | | |___| |
Source code in gdsfactory/components/mzis/mzi_lattice.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 | |
mzi_lattice_mmi
mzi_lattice_mmi(
coupler_widths: tuple[float | None, float | None] = (
None,
None,
),
coupler_widths_tapers: tuple[float, ...] = (1.0, 1.0),
coupler_lengths_tapers: tuple[float, ...] = (
10.0,
10.0,
),
coupler_lengths_mmis: tuple[float, ...] = (5.5, 5.5),
coupler_widths_mmis: tuple[float, ...] = (2.5, 2.5),
coupler_gaps_mmis: tuple[float, ...] = (0.25, 0.25),
taper_functions_mmis: tuple[str, ...] = (
"taper",
"taper",
),
straight_functions_mmis: tuple[str, ...] = (
"straight",
"straight",
),
cross_sections_mmis: tuple[str, ...] = (
"strip",
"strip",
),
delta_lengths: tuple[float, ...] = (10.0,),
mzi: str = "mzi2x2_2x2",
splitter: str = "mmi2x2",
**kwargs: Any
) -> Component
Mzi lattice filter, with MMI couplers.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
coupler_widths
|
tuple[float | None, float | None]
|
(for each MMI coupler, list of) input and output straight width. |
(None, None)
|
coupler_widths_tapers
|
tuple[float, ...]
|
(for each MMI coupler, list of) interface between input straights and mmi region. |
(1.0, 1.0)
|
coupler_lengths_tapers
|
tuple[float, ...]
|
(for each MMI coupler, list of) into the mmi region. |
(10.0, 10.0)
|
coupler_lengths_mmis
|
tuple[float, ...]
|
(for each MMI coupler, list of) in x direction. |
(5.5, 5.5)
|
coupler_widths_mmis
|
tuple[float, ...]
|
(for each MMI coupler, list of) in y direction. |
(2.5, 2.5)
|
coupler_gaps_mmis
|
tuple[float, ...]
|
(for each MMI coupler, list of) (width_taper + gap between tapered wg)/2. |
(0.25, 0.25)
|
taper_functions_mmis
|
tuple[str, ...]
|
(for each MMI coupler, list of) taper function. |
('taper', 'taper')
|
straight_functions_mmis
|
tuple[str, ...]
|
(for each MMI coupler, list of) straight function. |
('straight', 'straight')
|
cross_sections_mmis
|
tuple[str, ...]
|
(for each MMI coupler, list of) spec. |
('strip', 'strip')
|
delta_lengths
|
tuple[float, ...]
|
list of length differences. |
(10.0,)
|
mzi
|
str
|
function for the mzi. |
'mzi2x2_2x2'
|
splitter
|
str
|
splitter function. |
'mmi2x2'
|
kwargs
|
Any
|
additional settings. |
{}
|
Other Parameters:
| Name | Type | Description |
|---|---|---|
length_y |
vertical length for both and top arms. |
|
length_x |
horizontal length. |
|
bend |
90 degrees bend library. |
|
straight |
straight function. |
|
straight_y |
straight for length_y and delta_length. |
|
straight_x_top |
top straight for length_x. |
|
straight_x_bot |
bottom straight for length_x. |
|
cross_section |
for routing (sxtop/sxbot to combiner). __ _ | | | | | | | | cp1==| |===cp2=====| |=== .... ===cplast=== | | | | | | | | DL1 | DL2 | | | | | |_| | | |___| |
Source code in gdsfactory/components/mzis/mzi_lattice.py
128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 | |

mzi_lattice_mmi
mzi_lattice_mmi(
coupler_widths: tuple[float | None, float | None] = (
None,
None,
),
coupler_widths_tapers: tuple[float, ...] = (1.0, 1.0),
coupler_lengths_tapers: tuple[float, ...] = (
10.0,
10.0,
),
coupler_lengths_mmis: tuple[float, ...] = (5.5, 5.5),
coupler_widths_mmis: tuple[float, ...] = (2.5, 2.5),
coupler_gaps_mmis: tuple[float, ...] = (0.25, 0.25),
taper_functions_mmis: tuple[str, ...] = (
"taper",
"taper",
),
straight_functions_mmis: tuple[str, ...] = (
"straight",
"straight",
),
cross_sections_mmis: tuple[str, ...] = (
"strip",
"strip",
),
delta_lengths: tuple[float, ...] = (10.0,),
mzi: str = "mzi2x2_2x2",
splitter: str = "mmi2x2",
**kwargs: Any
) -> Component
Mzi lattice filter, with MMI couplers.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
coupler_widths
|
tuple[float | None, float | None]
|
(for each MMI coupler, list of) input and output straight width. |
(None, None)
|
coupler_widths_tapers
|
tuple[float, ...]
|
(for each MMI coupler, list of) interface between input straights and mmi region. |
(1.0, 1.0)
|
coupler_lengths_tapers
|
tuple[float, ...]
|
(for each MMI coupler, list of) into the mmi region. |
(10.0, 10.0)
|
coupler_lengths_mmis
|
tuple[float, ...]
|
(for each MMI coupler, list of) in x direction. |
(5.5, 5.5)
|
coupler_widths_mmis
|
tuple[float, ...]
|
(for each MMI coupler, list of) in y direction. |
(2.5, 2.5)
|
coupler_gaps_mmis
|
tuple[float, ...]
|
(for each MMI coupler, list of) (width_taper + gap between tapered wg)/2. |
(0.25, 0.25)
|
taper_functions_mmis
|
tuple[str, ...]
|
(for each MMI coupler, list of) taper function. |
('taper', 'taper')
|
straight_functions_mmis
|
tuple[str, ...]
|
(for each MMI coupler, list of) straight function. |
('straight', 'straight')
|
cross_sections_mmis
|
tuple[str, ...]
|
(for each MMI coupler, list of) spec. |
('strip', 'strip')
|
delta_lengths
|
tuple[float, ...]
|
list of length differences. |
(10.0,)
|
mzi
|
str
|
function for the mzi. |
'mzi2x2_2x2'
|
splitter
|
str
|
splitter function. |
'mmi2x2'
|
kwargs
|
Any
|
additional settings. |
{}
|
Other Parameters:
| Name | Type | Description |
|---|---|---|
length_y |
vertical length for both and top arms. |
|
length_x |
horizontal length. |
|
bend |
90 degrees bend library. |
|
straight |
straight function. |
|
straight_y |
straight for length_y and delta_length. |
|
straight_x_top |
top straight for length_x. |
|
straight_x_bot |
bottom straight for length_x. |
|
cross_section |
for routing (sxtop/sxbot to combiner). __ _ | | | | | | | | cp1==| |===cp2=====| |=== .... ===cplast=== | | | | | | | | DL1 | DL2 | | | | | |_| | | |___| |
Source code in gdsfactory/components/mzis/mzi_lattice.py
128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 | |

mzi_pads_center
mzi_pads_center
mzi_pads_center(
ps_top: ComponentSpec = "straight_heater_metal",
ps_bot: ComponentSpec = "straight_heater_metal",
mzi: ComponentSpec = "mzi",
pad: ComponentSpec = "pad_small",
length_x: float = 500,
length_y: float = 40,
mzi_sig_top: str | None = "top_r_e2",
mzi_gnd_top: str | None = "top_l_e2",
mzi_sig_bot: str | None = "bot_l_e2",
mzi_gnd_bot: str | None = "bot_r_e2",
pad_sig_bot: str = "e1_1_1",
pad_sig_top: str = "e3_1_3",
pad_gnd_bot: str = "e4_1_2",
pad_gnd_top: str = "e2_1_2",
delta_length: float = 40.0,
cross_section: CrossSectionSpec = "strip",
cross_section_metal: CrossSectionSpec = "metal_routing",
pad_pitch: float | str = "pad_pitch",
auto_taper: bool = False,
**kwargs: Any
) -> gf.Component
Return Mzi phase shifter with pads in the middle.
GND is the middle pad and is shared between top and bottom phase shifters.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
ps_top
|
ComponentSpec
|
phase shifter top. |
'straight_heater_metal'
|
ps_bot
|
ComponentSpec
|
phase shifter bottom. |
'straight_heater_metal'
|
mzi
|
ComponentSpec
|
interferometer. |
'mzi'
|
pad
|
ComponentSpec
|
pad function. |
'pad_small'
|
length_x
|
float
|
horizontal length. |
500
|
length_y
|
float
|
vertical length. |
40
|
mzi_sig_top
|
str | None
|
port name for top phase shifter signal. None if no connection. |
'top_r_e2'
|
mzi_gnd_top
|
str | None
|
port name for top phase shifter GND. None if no connection. |
'top_l_e2'
|
mzi_sig_bot
|
str | None
|
port name for top phase shifter signal. None if no connection. |
'bot_l_e2'
|
mzi_gnd_bot
|
str | None
|
port name for top phase shifter GND. None if no connection. |
'bot_r_e2'
|
pad_sig_bot
|
str
|
port name for top pad. |
'e1_1_1'
|
pad_sig_top
|
str
|
port name for top pad. |
'e3_1_3'
|
pad_gnd_bot
|
str
|
port name for top pad. |
'e4_1_2'
|
pad_gnd_top
|
str
|
port name for top pad. |
'e2_1_2'
|
delta_length
|
float
|
mzi length imbalance. |
40.0
|
cross_section
|
CrossSectionSpec
|
for the mzi. |
'strip'
|
cross_section_metal
|
CrossSectionSpec
|
for routing metal. |
'metal_routing'
|
pad_pitch
|
float | str
|
pad pitch in um. |
'pad_pitch'
|
auto_taper
|
bool
|
add taper if cross_section width is different between mzi and pad. |
False
|
kwargs
|
Any
|
routing settings. |
{}
|
Source code in gdsfactory/components/mzis/mzi_pads_center.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 | |

mzi_phase_shifter
module-attribute
mzi_phase_shifter = partial(
mzi,
straight_x_top="straight_heater_metal",
length_x=200,
)

mzi_phase_shifter_top_heater_metal
module-attribute
mzi_phase_shifter_top_heater_metal = partial(
mzi_phase_shifter,
straight_x_top="straight_heater_metal",
)

mzi_pin
module-attribute
mzi_pin = partial(
mzi,
straight_x_top="straight_pin",
cross_section_x_top="pin",
delta_length=0.0,
length_x=100,
)

mzit
mzit
mzit(
w0: float = 0.5,
w1: float = 0.45,
w2: float = 0.55,
dy: Delta = 2.0,
delta_length: float = 10.0,
length: float = 1.0,
coupler_length1: float = 5.0,
coupler_length2: float = 10.0,
coupler_gap1: float = 0.2,
coupler_gap2: float = 0.3,
taper: ComponentSpec = "taper",
taper_length: float = 5.0,
bend90: ComponentSpec = "bend_euler",
straight: ComponentSpec = "straight",
coupler1: ComponentSpec | None = "coupler",
coupler2: ComponentSpec = "coupler",
cross_section: str = "strip",
) -> Component
Mzi tolerant to fabrication variations.
based on Yufei Xing thesis http://photonics.intec.ugent.be/publications/PhD.asp?ID=250
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
w0
|
float
|
input waveguide width (um). |
0.5
|
w1
|
float
|
narrow waveguide width (um). |
0.45
|
w2
|
float
|
wide waveguide width (um). |
0.55
|
dy
|
Delta
|
port to port vertical spacing. |
2.0
|
delta_length
|
float
|
length difference between arms (um). |
10.0
|
length
|
float
|
shared length for w1 and w2. |
1.0
|
coupler_length1
|
float
|
length of coupler1. |
5.0
|
coupler_length2
|
float
|
length of coupler2. |
10.0
|
coupler_gap1
|
float
|
coupler1. |
0.2
|
coupler_gap2
|
float
|
coupler2. |
0.3
|
taper
|
ComponentSpec
|
taper spec. |
'taper'
|
taper_length
|
float
|
from w0 to w1. |
5.0
|
bend90
|
ComponentSpec
|
bend spec. |
'bend_euler'
|
straight
|
ComponentSpec
|
spec. |
'straight'
|
coupler1
|
ComponentSpec | None
|
coupler1 spec (optional). |
'coupler'
|
coupler2
|
ComponentSpec
|
coupler2 spec. |
'coupler'
|
cross_section
|
str
|
cross_section spec.
4 2 __ __ 3w0t2 _w2_ \ / \ \ length1 / | ============== gap1 | / \ | / _____w0___t1 w1 | 3 1 4 \ | | | 2 2 | | __ __w0_t1_w1/ | \ / | \ length2 / | ============== gap2 | / \ | | __/ \ E0_w0__t2 __w1______/ 1 1 cp2 |
'strip'
|
Source code in gdsfactory/components/mzis/mzit.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 | |
mzit_lattice
mzit_lattice(
coupler_lengths: Sequence[float] = (10.0, 20.0),
coupler_gaps: Sequence[float] = (0.2, 0.3),
delta_lengths: Sequence[float] = (10.0,),
mzi: ComponentSpec = mzit,
) -> Component
Mzi fab tolerant lattice filter.
cp1
o4 o2 __ __ o3___w0_t2 _w2___
\ / \
\ length1 / |
============== gap1 |
/ \ |
__/ \_____w0___t1 _w1 |
o3 o1 o4 \ | .
... | | .
o2 o2 o3 | | .
__ _____w0___t1___w1__/ |
\ / |
\ lengthN / |
============== gapN |
/ \ |
__/ \_ |
o1 o1 \___w0___t2___w1_____/
cpN o4
Source code in gdsfactory/components/mzis/mzit.py
209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 | |

mzit_lattice
mzit_lattice(
coupler_lengths: Sequence[float] = (10.0, 20.0),
coupler_gaps: Sequence[float] = (0.2, 0.3),
delta_lengths: Sequence[float] = (10.0,),
mzi: ComponentSpec = mzit,
) -> Component
Mzi fab tolerant lattice filter.
cp1
o4 o2 __ __ o3___w0_t2 _w2___
\ / \
\ length1 / |
============== gap1 |
/ \ |
__/ \_____w0___t1 _w1 |
o3 o1 o4 \ | .
... | | .
o2 o2 o3 | | .
__ _____w0___t1___w1__/ |
\ / |
\ lengthN / |
============== gapN |
/ \ |
__/ \_ |
o1 o1 \___w0___t2___w1_____/
cpN o4
Source code in gdsfactory/components/mzis/mzit.py
209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 | |

mzm
module-attribute
mzm = partial(
mzi_phase_shifter,
straight_x_top="straight_pin",
straight_x_bot="straight_pin",
)

pads
bump_pad
bump_pad
bump_pad(
size: float = 36.244,
layer: LayerSpec = "MTOP",
port_width: float = 10.0,
port_layer: LayerSpec = "M2",
port_type: str = "pad",
add_via: bool = True,
) -> Component
Returns rectangular pad with ports.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
float
|
octagon edge of octagon. |
36.244
|
layer
|
LayerSpec
|
bump pad layer. |
'MTOP'
|
port_width
|
float
|
width of the port for electrical routing. |
10.0
|
port_layer
|
LayerSpec
|
layer of the port for electrical routing. |
'M2'
|
port_type
|
str
|
port type for pad port. |
'pad'
|
add_via
|
bool
|
whether to add a via stack. |
True
|
Source code in gdsfactory/components/pads/bump_pad.py
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 | |
bump_pad_grid
bump_pad_grid(
columns: int = 6,
rows: int = 6,
column_pitch: float = 121.89,
row_pitch: float = 132.66,
offset: float = 66.33,
port_width: float = 10,
port_layer: LayerSpec = "M2",
size: float = 36.244,
layer: LayerSpec = "MTOP",
auto_rename_ports: bool = False,
skip_pads: list[tuple[int, int]] | None = None,
add_via: bool = True,
) -> Component
Returns 2D array of bump pads.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
columns
|
int
|
number of columns. |
6
|
rows
|
int
|
number of rows. |
6
|
column_pitch
|
float
|
x pitch. |
121.89
|
row_pitch
|
float
|
y pitch. |
132.66
|
offset
|
float
|
offset for alternating columns. |
66.33
|
port_width
|
float
|
width of the port for electrical routing. |
10
|
port_layer
|
LayerSpec
|
layer of the port for electrical routing. |
'M2'
|
size
|
float
|
pad size. |
36.244
|
layer
|
LayerSpec
|
bump pad layer. |
'MTOP'
|
auto_rename_ports
|
bool
|
True to auto rename ports. |
False
|
skip_pads
|
list[tuple[int, int]] | None
|
list of (col, row) tuples to skip. |
None
|
add_via
|
bool
|
whether to add a via stack. |
True
|
Source code in gdsfactory/components/pads/bump_pad.py
111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 | |

bump_pad_grid
bump_pad_grid(
columns: int = 6,
rows: int = 6,
column_pitch: float = 121.89,
row_pitch: float = 132.66,
offset: float = 66.33,
port_width: float = 10,
port_layer: LayerSpec = "M2",
size: float = 36.244,
layer: LayerSpec = "MTOP",
auto_rename_ports: bool = False,
skip_pads: list[tuple[int, int]] | None = None,
add_via: bool = True,
) -> Component
Returns 2D array of bump pads.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
columns
|
int
|
number of columns. |
6
|
rows
|
int
|
number of rows. |
6
|
column_pitch
|
float
|
x pitch. |
121.89
|
row_pitch
|
float
|
y pitch. |
132.66
|
offset
|
float
|
offset for alternating columns. |
66.33
|
port_width
|
float
|
width of the port for electrical routing. |
10
|
port_layer
|
LayerSpec
|
layer of the port for electrical routing. |
'M2'
|
size
|
float
|
pad size. |
36.244
|
layer
|
LayerSpec
|
bump pad layer. |
'MTOP'
|
auto_rename_ports
|
bool
|
True to auto rename ports. |
False
|
skip_pads
|
list[tuple[int, int]] | None
|
list of (col, row) tuples to skip. |
None
|
add_via
|
bool
|
whether to add a via stack. |
True
|
Source code in gdsfactory/components/pads/bump_pad.py
111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 | |

pad
pad
pad(
size: Size | str = (100.0, 100.0),
layer: LayerSpec = "MTOP",
bbox_layers: tuple[LayerSpec, ...] | None = None,
bbox_offsets: tuple[float, ...] | None = None,
port_inclusion: float = 0,
port_orientation: AngleInDegrees | None = 0,
port_orientations: Ints | None = (180, 90, 0, -90),
port_type: str = "pad",
) -> Component
Returns rectangular pad with ports.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
Size | str
|
x, y size. |
(100.0, 100.0)
|
layer
|
LayerSpec
|
pad layer. |
'MTOP'
|
bbox_layers
|
tuple[LayerSpec, ...] | None
|
list of layers. |
None
|
bbox_offsets
|
tuple[float, ...] | None
|
Optional offsets for each layer with respect to size. positive grows, negative shrinks the size. |
None
|
port_inclusion
|
float
|
from edge. |
0
|
port_orientation
|
AngleInDegrees | None
|
in degrees for the center port. |
0
|
port_orientations
|
Ints | None
|
list of port_orientations to add. None does not add ports. |
(180, 90, 0, -90)
|
port_type
|
str
|
port type for pad port. |
'pad'
|
Source code in gdsfactory/components/pads/pad.py
32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 | |
pad_array
pad_array(
pad: ComponentSpec = "pad",
columns: int = 6,
rows: int = 1,
column_pitch: float = 150.0,
row_pitch: float = 150.0,
port_orientation: AngleInDegrees = 0,
size: Float2 | None = None,
layer: LayerSpec | None = "MTOP",
centered_ports: bool = False,
auto_rename_ports: bool = False,
) -> Component
Returns 2D array of pads.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pad
|
ComponentSpec
|
pad element. |
'pad'
|
columns
|
int
|
number of columns. |
6
|
rows
|
int
|
number of rows. |
1
|
column_pitch
|
float
|
x pitch. |
150.0
|
row_pitch
|
float
|
y pitch. |
150.0
|
port_orientation
|
AngleInDegrees
|
port orientation in deg. None for low speed DC ports. |
0
|
size
|
Float2 | None
|
pad size. |
None
|
layer
|
LayerSpec | None
|
pad layer. |
'MTOP'
|
centered_ports
|
bool
|
True add ports to center. False add ports to the edge. |
False
|
auto_rename_ports
|
bool
|
True to auto rename ports. |
False
|
Source code in gdsfactory/components/pads/pad.py
111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 | |

pad_array
pad_array(
pad: ComponentSpec = "pad",
columns: int = 6,
rows: int = 1,
column_pitch: float = 150.0,
row_pitch: float = 150.0,
port_orientation: AngleInDegrees = 0,
size: Float2 | None = None,
layer: LayerSpec | None = "MTOP",
centered_ports: bool = False,
auto_rename_ports: bool = False,
) -> Component
Returns 2D array of pads.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pad
|
ComponentSpec
|
pad element. |
'pad'
|
columns
|
int
|
number of columns. |
6
|
rows
|
int
|
number of rows. |
1
|
column_pitch
|
float
|
x pitch. |
150.0
|
row_pitch
|
float
|
y pitch. |
150.0
|
port_orientation
|
AngleInDegrees
|
port orientation in deg. None for low speed DC ports. |
0
|
size
|
Float2 | None
|
pad size. |
None
|
layer
|
LayerSpec | None
|
pad layer. |
'MTOP'
|
centered_ports
|
bool
|
True add ports to center. False add ports to the edge. |
False
|
auto_rename_ports
|
bool
|
True to auto rename ports. |
False
|
Source code in gdsfactory/components/pads/pad.py
111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 | |

pad_array0
module-attribute
pad_array0 = partial(
pad_array, port_orientation=0, columns=1, rows=3
)

pad_array180
module-attribute
pad_array180 = partial(
pad_array, port_orientation=180, columns=1, rows=3
)

pad_array270
module-attribute
pad_array270 = partial(pad_array, port_orientation=270)

pad_array90
module-attribute
pad_array90 = partial(pad_array, port_orientation=90)

pad_gs
pad_gs(
length: float = 100, cross_section: str = "gs"
) -> gf.Component
Source code in gdsfactory/components/pads/pad_gsg.py
89 90 91 | |

pad_gsg
High speed GSG pads.
pad_gsg_short
pad_gsg_short(
size: Float2 = (22, 7),
layer_metal: LayerSpec = "MTOP",
metal_spacing: float = 5.0,
short: bool = True,
pad: ComponentSpec = "pad",
pad_pitch: float = 150,
route_xsize: float = 50,
) -> gf.Component
Returns high speed GSG pads for calibrating the RF probes.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
Float2
|
for the short. |
(22, 7)
|
layer_metal
|
LayerSpec
|
for the short. |
'MTOP'
|
metal_spacing
|
float
|
in um. |
5.0
|
short
|
bool
|
if False returns an open. |
True
|
pad
|
ComponentSpec
|
function for pad. |
'pad'
|
pad_pitch
|
float
|
in um. |
150
|
route_xsize
|
float
|
in um. |
50
|
Source code in gdsfactory/components/pads/pad_gsg.py
18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 | |

pad_gsg_open
module-attribute
pad_gsg_open = partial(pad_gsg_short, short=False)

pad_gsg_short
pad_gsg_short(
size: Float2 = (22, 7),
layer_metal: LayerSpec = "MTOP",
metal_spacing: float = 5.0,
short: bool = True,
pad: ComponentSpec = "pad",
pad_pitch: float = 150,
route_xsize: float = 50,
) -> gf.Component
Returns high speed GSG pads for calibrating the RF probes.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
Float2
|
for the short. |
(22, 7)
|
layer_metal
|
LayerSpec
|
for the short. |
'MTOP'
|
metal_spacing
|
float
|
in um. |
5.0
|
short
|
bool
|
if False returns an open. |
True
|
pad
|
ComponentSpec
|
function for pad. |
'pad'
|
pad_pitch
|
float
|
in um. |
150
|
route_xsize
|
float
|
in um. |
50
|
Source code in gdsfactory/components/pads/pad_gsg.py
18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 | |

pad_rectangular
module-attribute
pad_rectangular = partial(pad, size='pad_size')

pad_small
module-attribute
pad_small = partial(pad, size=(80, 80))

pads_shorted
pads_shorted
pads_shorted(
pad: ComponentSpec = "pad",
columns: int = 8,
pad_pitch: float = 150.0,
layer_metal: LayerSpec = "MTOP",
metal_width: float = 10,
) -> Component
Returns a 1D array of shorted_pads.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pad
|
ComponentSpec
|
pad spec. |
'pad'
|
columns
|
int
|
number of columns. |
8
|
pad_pitch
|
float
|
in um |
150.0
|
layer_metal
|
LayerSpec
|
for the short. |
'MTOP'
|
metal_width
|
float
|
for the short. |
10
|
Source code in gdsfactory/components/pads/pads_shorted.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 | |

rectangle_with_slits
rectangle_with_slits
rectangle_with_slits(
size: Size = (100.0, 200.0),
layer: LayerSpec = "WG",
layer_slit: LayerSpec | None = None,
centered: bool = False,
port_type: str | None = None,
slit_size: Size = (1.0, 1.0),
slit_column_pitch: float = 20,
slit_row_pitch: float = 20,
slit_enclosure: float = 10,
) -> Component
Returns a rectangle with slits.
Metal slits reduce stress.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
Size
|
(tuple) Width and height of rectangle. |
(100.0, 200.0)
|
layer
|
LayerSpec
|
Specific layer to put polygon geometry on. |
'WG'
|
layer_slit
|
LayerSpec | None
|
does a boolean NOT when None. |
None
|
centered
|
bool
|
True sets center to (0, 0), False sets south-west to (0, 0) |
False
|
port_type
|
str | None
|
for the rectangle. |
None
|
slit_size
|
Size
|
x, y slit size. |
(1.0, 1.0)
|
slit_column_pitch
|
float
|
pitch for columns of slits. |
20
|
slit_row_pitch
|
float
|
pitch for rows of slits. |
20
|
slit_enclosure
|
float
|
from slit to rectangle edge. |
10
|
Source code in gdsfactory/components/pads/rectangle_with_slits.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 | |

pcms
alignment_mark_cross
alignment_mark_cross
alignment_mark_cross(
arm_width: float = 2.0,
arm_length: float = 20.0,
layer: LayerSpec = "WG",
port_type: str | None = None,
) -> Component
Custom alignment cross mark for lithography alignment.
Creates a cross shape centered at the origin composed of two overlapping rectangles (horizontal and vertical arms).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
arm_width
|
float
|
Width of each arm in um. |
2.0
|
arm_length
|
float
|
Length of each arm in um (full extent from tip to tip is 2 * arm_length). |
20.0
|
layer
|
LayerSpec
|
Layer specification for the cross geometry. |
'WG'
|
port_type
|
str | None
|
Optional port type. If provided, ports are added at the four arm tips. |
None
|
Source code in gdsfactory/components/pcms/alignment_mark_cross.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 | |

cavity
cavity
cavity(
component: ComponentSpec = "dbr",
coupler: ComponentSpec = "coupler",
length: float = 0.1,
gap: float = 0.2,
**kwargs: Any
) -> Component
Returns cavity from a coupler and a mirror.
connects the W0 port of the mirror to E1 and W1 coupler ports creating a resonant cavity
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
mirror. |
'dbr'
|
coupler
|
ComponentSpec
|
coupler library. |
'coupler'
|
length
|
float
|
coupler length. |
0.1
|
gap
|
float
|
coupler gap. |
0.2
|
kwargs
|
Any
|
coupler_settings. |
{}
|
ml (mirror left) mr (mirror right)
| |
|o1 - o2__ __o3 - o1|
| \ / |
\ /
---=========---
o1 o1 length o4 o2
Source code in gdsfactory/components/pcms/cavity.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 | |

cdsem_all
CD SEM structures.
cdsem_all
cdsem_all(
widths: tuple[float, ...] = (
0.4,
0.45,
0.5,
0.6,
0.8,
1.0,
),
dense_lines_width: float | None = 0.3,
dense_lines_width_difference: float = 0.02,
dense_lines_gap: float = 0.3,
dense_lines_labels: tuple[str, ...] = (
"DL",
"DM",
"DH",
),
straight: ComponentSpec = "straight",
bend90: ComponentSpec | None = "bend_circular",
cross_section: CrossSectionSpec = "strip",
text: ComponentSpec = "text_rectangular",
spacing: float = 5,
cdsem_bend180: ComponentSpec = "cdsem_bend180",
text_size: float = 1,
) -> Component
Column with all optical PCMs.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
widths
|
tuple[float, ...]
|
for straight lines. |
(0.4, 0.45, 0.5, 0.6, 0.8, 1.0)
|
dense_lines_width
|
float | None
|
in um. |
0.3
|
dense_lines_width_difference
|
float
|
in um. |
0.02
|
dense_lines_gap
|
float
|
in um. |
0.3
|
dense_lines_labels
|
tuple[str, ...]
|
strings. |
('DL', 'DM', 'DH')
|
straight
|
ComponentSpec
|
spec. |
'straight'
|
bend90
|
ComponentSpec | None
|
spec. |
'bend_circular'
|
cross_section
|
CrossSectionSpec
|
spec. |
'strip'
|
text
|
ComponentSpec
|
spec. |
'text_rectangular'
|
spacing
|
float
|
from group to group. |
5
|
cdsem_bend180
|
ComponentSpec
|
spec. |
'cdsem_bend180'
|
text_size
|
float
|
in um. |
1
|
Source code in gdsfactory/components/pcms/cdsem_all.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 | |

cdsem_bend180
CD SEM structures.
cdsem_bend180
cdsem_bend180(
width: float = 0.5,
radius: float = 10.0,
wg_length: float | None = LINE_LENGTH,
straight: ComponentSpec = "straight",
bend90: ComponentSpec = "bend_circular",
cross_section: CrossSectionSpec = "strip",
text: ComponentSpec = "text_rectangular",
text_size: float = 1.0,
) -> Component
Returns CDSEM structures.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
of the line. |
0.5
|
radius
|
float
|
um. |
10.0
|
wg_length
|
float | None
|
in um. |
LINE_LENGTH
|
straight
|
ComponentSpec
|
spec. |
'straight'
|
bend90
|
ComponentSpec
|
spec. |
'bend_circular'
|
cross_section
|
CrossSectionSpec
|
spec. |
'strip'
|
text
|
ComponentSpec
|
spec. |
'text_rectangular'
|
text_size
|
float
|
um. |
1.0
|
Source code in gdsfactory/components/pcms/cdsem_bend180.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 | |

cdsem_coupler
CD SEM structures.
cdsem_coupler
cdsem_coupler(
length: float = 420.0,
gaps: Sequence[float] = (0.15, 0.2, 0.25),
cross_section: CrossSectionSpec = "strip_no_ports",
text: ComponentSpec | None = "text_rectangular",
spacing: float = 7.0,
positions: Sequence[float | None] | None = None,
width: float | None = None,
text_size: float = 1.0,
) -> Component
Returns 2 coupled waveguides gap sweep.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
for the line. |
420.0
|
gaps
|
Sequence[float]
|
list of gaps for the sweep. |
(0.15, 0.2, 0.25)
|
cross_section
|
CrossSectionSpec
|
for the lines. |
'strip_no_ports'
|
text
|
ComponentSpec | None
|
optional text for labels. |
'text_rectangular'
|
spacing
|
float
|
Optional center to center spacing. |
7.0
|
positions
|
Sequence[float | None] | None
|
Optional positions for the text labels. |
None
|
width
|
float | None
|
width of the waveguide. If None, it will use the width of the cross_section. |
None
|
text_size
|
float
|
size of the text. |
1.0
|
Source code in gdsfactory/components/pcms/cdsem_coupler.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 | |

cdsem_straight
CD SEM structures.
cdsem_straight
cdsem_straight(
widths: Sequence[float] = (
0.4,
0.45,
0.5,
0.6,
0.8,
1.0,
),
length: float = LINE_LENGTH,
cross_section: CrossSectionSpec = "strip_no_ports",
text: ComponentSpec | None = "text_rectangular",
spacing: float = 7.0,
positions: Sequence[float | None] | None = None,
text_size: float = 1,
) -> Component
Returns straight waveguide lines width sweep.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
widths
|
Sequence[float]
|
for the sweep. |
(0.4, 0.45, 0.5, 0.6, 0.8, 1.0)
|
length
|
float
|
for the line. |
LINE_LENGTH
|
cross_section
|
CrossSectionSpec
|
for the lines. |
'strip_no_ports'
|
text
|
ComponentSpec | None
|
optional text for labels. |
'text_rectangular'
|
spacing
|
float
|
Optional center to center spacing. |
7.0
|
positions
|
Sequence[float | None] | None
|
Optional positions for the text labels. |
None
|
text_size
|
float
|
in um. |
1
|
Source code in gdsfactory/components/pcms/cdsem_straight.py
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 | |

cdsem_straight_density
CD SEM structures.
cdsem_straight_density
cdsem_straight_density(
widths: Floats = widths,
gaps: Floats = gaps,
length: float = 420.0,
label: str = "",
cross_section: CrossSectionSpec = "strip_no_ports",
text: ComponentSpec | None = "text_rectangular",
text_size: float = 1.0,
) -> Component
Returns sweep of dense straight lines.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
widths
|
Floats
|
list of widths. |
widths
|
gaps
|
Floats
|
list of gaps. |
gaps
|
length
|
float
|
of the lines. |
420.0
|
label
|
str
|
defaults to widths[0] gaps[0]. |
''
|
cross_section
|
CrossSectionSpec
|
spec. |
'strip_no_ports'
|
text
|
ComponentSpec | None
|
optional function for text. |
'text_rectangular'
|
text_size
|
float
|
size of the text. |
1.0
|
Source code in gdsfactory/components/pcms/cdsem_straight_density.py
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 | |

cutback_2x2
cutback_2x2
cutback_2x2(
component: ComponentSpec = "mmi2x2",
cols: int = 4,
rows: int = 5,
port1: str = "o1",
port2: str = "o2",
port3: str = "o3",
port4: str = "o4",
bend180: ComponentSpec = "bend_circular180",
mirror: bool = False,
straight_length: float | None = None,
cross_section: CrossSectionSpec = "strip",
straight: ComponentSpec = "straight",
) -> Component
Returns a daisy chain of splitters for measuring their loss.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
for cutback. |
'mmi2x2'
|
cols
|
int
|
number of columns. |
4
|
rows
|
int
|
number of rows. |
5
|
port1
|
str
|
name of first optical port. |
'o1'
|
port2
|
str
|
name of second optical port. |
'o2'
|
port3
|
str
|
name of third optical port. |
'o3'
|
port4
|
str
|
name of fourth optical port. |
'o4'
|
bend180
|
ComponentSpec
|
ubend. |
'bend_circular180'
|
mirror
|
bool
|
Flips component. Useful when 'o2' is the port that you want to route to. |
False
|
straight_length
|
float | None
|
length of the straight section between cutbacks. |
None
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string or dict). |
'strip'
|
straight
|
ComponentSpec
|
straight spec. |
'straight'
|
Source code in gdsfactory/components/pcms/cutback_2x2.py
100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 | |

cutback_bend
cutback_bend
cutback_bend(
component: ComponentSpec = "bend_euler",
straight: ComponentSpec = "straight",
straight_length: float = 5.0,
rows: int = 6,
cols: int = 5,
**kwargs: Any
) -> Component
We recommend using cutback_bend90 instead for a smaller footprint.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
bend spec. |
'bend_euler'
|
straight
|
ComponentSpec
|
straight spec. |
'straight'
|
straight_length
|
float
|
in um. |
5.0
|
rows
|
int
|
number of rows. |
6
|
cols
|
int
|
number of cols. |
5
|
kwargs
|
Any
|
cross_section settings. |
{}
|
Source code in gdsfactory/components/pcms/cutback_bend.py
31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 | |
cutback_bend180
cutback_bend180(
component: ComponentSpec = "bend_euler180",
straight: ComponentSpec = "straight",
straight_length: float = 5.0,
rows: int = 6,
cols: int = 6,
spacing: float = 3.0,
**kwargs: Any
) -> Component
Returns cutback to measure u bend loss.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
bend spec. |
'bend_euler180'
|
straight
|
ComponentSpec
|
straight spec. |
'straight'
|
straight_length
|
float
|
in um. |
5.0
|
rows
|
int
|
number of rows. |
6
|
cols
|
int
|
number of cols. |
6
|
spacing
|
float
|
in um. |
3.0
|
kwargs
|
Any
|
cross_section settings. _ |
{}
|
Source code in gdsfactory/components/pcms/cutback_bend.py
184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 | |
cutback_bend90
cutback_bend90(
component: ComponentSpec = "bend_euler",
straight: ComponentSpec = "straight",
straight_length: float = 5.0,
rows: int = 6,
cols: int = 6,
spacing: int = 5,
**kwargs: Any
) -> Component
Returns bend90 cutback.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
bend spec. |
'bend_euler'
|
straight
|
ComponentSpec
|
straight spec. |
'straight'
|
straight_length
|
float
|
in um. |
5.0
|
rows
|
int
|
number of rows. |
6
|
cols
|
int
|
number of cols. |
6
|
spacing
|
int
|
in um. |
5
|
kwargs
|
Any
|
cross_section settings. _ |
{}
|
Source code in gdsfactory/components/pcms/cutback_bend.py
83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 | |
staircase
staircase(
component: ComponentSpec | Component = "bend_euler",
straight: ComponentSpec = "straight",
length_v: float = 5.0,
length_h: float = 5.0,
rows: int = 4,
**kwargs: Any
) -> Component
Returns staircase.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec | Component
|
bend spec. |
'bend_euler'
|
straight
|
ComponentSpec
|
straight spec. |
'straight'
|
length_v
|
float
|
vertical length. |
5.0
|
length_h
|
float
|
vertical length. |
5.0
|
rows
|
int
|
number of rows. |
4
|
cols
|
number of cols. |
required | |
kwargs
|
Any
|
cross_section settings. |
{}
|
Source code in gdsfactory/components/pcms/cutback_bend.py
135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 | |

cutback_bend180
cutback_bend180(
component: ComponentSpec = "bend_euler180",
straight: ComponentSpec = "straight",
straight_length: float = 5.0,
rows: int = 6,
cols: int = 6,
spacing: float = 3.0,
**kwargs: Any
) -> Component
Returns cutback to measure u bend loss.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
bend spec. |
'bend_euler180'
|
straight
|
ComponentSpec
|
straight spec. |
'straight'
|
straight_length
|
float
|
in um. |
5.0
|
rows
|
int
|
number of rows. |
6
|
cols
|
int
|
number of cols. |
6
|
spacing
|
float
|
in um. |
3.0
|
kwargs
|
Any
|
cross_section settings. _ |
{}
|
Source code in gdsfactory/components/pcms/cutback_bend.py
184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 | |

cutback_bend180circular
module-attribute
cutback_bend180circular = partial(
cutback_bend180, component="bend_circular180"
)

cutback_bend90
cutback_bend90(
component: ComponentSpec = "bend_euler",
straight: ComponentSpec = "straight",
straight_length: float = 5.0,
rows: int = 6,
cols: int = 6,
spacing: int = 5,
**kwargs: Any
) -> Component
Returns bend90 cutback.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
bend spec. |
'bend_euler'
|
straight
|
ComponentSpec
|
straight spec. |
'straight'
|
straight_length
|
float
|
in um. |
5.0
|
rows
|
int
|
number of rows. |
6
|
cols
|
int
|
number of cols. |
6
|
spacing
|
int
|
in um. |
5
|
kwargs
|
Any
|
cross_section settings. _ |
{}
|
Source code in gdsfactory/components/pcms/cutback_bend.py
83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 | |

cutback_bend90circular
module-attribute
cutback_bend90circular = partial(
cutback_bend90, component="bend_circular"
)

cutback_component
cutback_component
cutback_component(
component: ComponentSpec = "taper_0p5_to_3_l36",
cols: int = 4,
rows: int = 5,
port1: str = "o1",
port2: str = "o2",
bend180: ComponentSpec = "bend_euler180",
mirror: bool = False,
mirror1: bool = False,
mirror2: bool = False,
straight_length: float | None = None,
straight_length_pair: float | None = None,
straight: ComponentSpec = "straight",
cross_section: CrossSectionSpec = "strip",
radius: float | None = None,
**kwargs: Any
) -> Component
Returns a daisy chain of components for measuring their loss.
Works only for components with 2 ports (input, output).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
for cutback. |
'taper_0p5_to_3_l36'
|
cols
|
int
|
number of columns. |
4
|
rows
|
int
|
number of rows. |
5
|
port1
|
str
|
name of first optical port. |
'o1'
|
port2
|
str
|
name of second optical port. |
'o2'
|
bend180
|
ComponentSpec
|
ubend. |
'bend_euler180'
|
mirror
|
bool
|
Flips component. Useful when 'o2' is the port that you want to route to. |
False
|
mirror1
|
bool
|
mirrors first component. |
False
|
mirror2
|
bool
|
mirrors second component. |
False
|
straight_length
|
float | None
|
length of the straight section between cutbacks. |
None
|
straight_length_pair
|
float | None
|
length of the straight section between each component pair. |
None
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string or dict). |
'strip'
|
straight
|
ComponentSpec
|
straight spec. |
'straight'
|
radius
|
float | None
|
radius for the bends. Defaults to cross_section radius. |
None
|
kwargs
|
Any
|
component settings. |
{}
|
Source code in gdsfactory/components/pcms/cutback_component.py
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 | |

cutback_component_mirror
module-attribute
cutback_component_mirror = partial(
cutback_component, mirror=True
)

cutback_splitter
cutback_splitter
cutback_splitter(
component: ComponentSpec = "mmi1x2",
cols: int = 4,
rows: int = 5,
port1: str = "o1",
port2: str = "o2",
port3: str = "o3",
bend180: ComponentSpec = "bend_euler180",
mirror: bool = False,
straight: ComponentSpec = "straight",
straight_length: float | None = None,
cross_section: CrossSectionSpec = "strip",
**kwargs: Any
) -> Component
Returns a daisy chain of splitters for measuring their loss.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
for cutback. |
'mmi1x2'
|
cols
|
int
|
number of columns. |
4
|
rows
|
int
|
number of rows. |
5
|
port1
|
str
|
name of first optical port. |
'o1'
|
port2
|
str
|
name of second optical port. |
'o2'
|
port3
|
str
|
name of third optical port. |
'o3'
|
bend180
|
ComponentSpec
|
ubend. |
'bend_euler180'
|
mirror
|
bool
|
Flips component. Useful when 'o2' is the port that you want to route to. |
False
|
straight
|
ComponentSpec
|
waveguide spec to connect both sides. |
'straight'
|
straight_length
|
float | None
|
length of the straight section between cutbacks. |
None
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string or dict). |
'strip'
|
kwargs
|
Any
|
cross_section settings. |
{}
|
Source code in gdsfactory/components/pcms/cutback_splitter.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 | |

greek_cross
Greek cross test structure.
greek_cross
greek_cross(
length: float = 30,
layers: LayerSpecs = ("WG", "N"),
widths: Floats = (2.0, 3.0),
offsets: Floats | None = None,
via_stack: ComponentSpec = "via_stack_npp_m1",
layer_index: int = 0,
) -> gf.Component
Simple greek cross with via stacks at the endpoints.
Process control monitor for dopant sheet resistivity and linewidth variation.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
length of cross arms. |
30
|
layers
|
LayerSpecs
|
list of layers. |
('WG', 'N')
|
widths
|
Floats
|
list of widths (same order as layers). |
(2.0, 3.0)
|
offsets
|
Floats | None
|
how much to extend each layer beyond the cross length negative shorter, positive longer. |
None
|
via_stack
|
ComponentSpec
|
via component to attach to the cross. |
'via_stack_npp_m1'
|
layer_index
|
int
|
index of the layer to connect the via_stack to. via_stack <-------> ___ length __ | |<-------------------->| | |
0
|
References: - Walton, Anthony J.. “MICROELECTRONIC TEST STRUCTURES.” (1999). - W. Versnel, Analysis of the Greek cross, a Van der Pauw structure with finite contacts, Solid-State Electronics, Volume 22, Issue 11, 1979, Pages 911-914, ISSN 0038-1101, https://doi.org/10.1016/0038-1101(79)90061-3. - S. Enderling et al., "Sheet resistance measurement of non-standard cleanroom materials using suspended Greek cross test structures," IEEE Transactions on Semiconductor Manufacturing, vol. 19, no. 1, pp. 2-9, Feb. 2006, doi: 10.1109/TSM.2005.863248. - https://download.tek.com/document/S530_VanDerPauwSheetRstnce.pdf
Source code in gdsfactory/components/pcms/greek_cross.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 | |
greek_cross_with_pads
greek_cross_with_pads(
pad: ComponentSpec = "pad",
pad_pitch: float = 150.0,
greek_cross_component: ComponentSpec = "greek_cross",
pad_via: ComponentSpec = "via_stack_m1_mtop",
cross_section: CrossSectionSpec = metal1,
pad_port_name: str = "e4",
) -> gf.Component
Greek cross under 4 DC pads, ready to test.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pad
|
ComponentSpec
|
component to use for probe pads. |
'pad'
|
pad_pitch
|
float
|
spacing between pads. |
150.0
|
greek_cross_component
|
ComponentSpec
|
component to use for greek cross. |
'greek_cross'
|
pad_via
|
ComponentSpec
|
via to add to the pad. |
'via_stack_m1_mtop'
|
cross_section
|
CrossSectionSpec
|
cross-section for cross via to pad via wiring. |
metal1
|
pad_port_name
|
str
|
name of the port to connect to the greek cross. |
'e4'
|
Source code in gdsfactory/components/pcms/greek_cross.py
92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 | |

greek_cross_with_pads
greek_cross_with_pads(
pad: ComponentSpec = "pad",
pad_pitch: float = 150.0,
greek_cross_component: ComponentSpec = "greek_cross",
pad_via: ComponentSpec = "via_stack_m1_mtop",
cross_section: CrossSectionSpec = metal1,
pad_port_name: str = "e4",
) -> gf.Component
Greek cross under 4 DC pads, ready to test.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pad
|
ComponentSpec
|
component to use for probe pads. |
'pad'
|
pad_pitch
|
float
|
spacing between pads. |
150.0
|
greek_cross_component
|
ComponentSpec
|
component to use for greek cross. |
'greek_cross'
|
pad_via
|
ComponentSpec
|
via to add to the pad. |
'via_stack_m1_mtop'
|
cross_section
|
CrossSectionSpec
|
cross-section for cross via to pad via wiring. |
metal1
|
pad_port_name
|
str
|
name of the port to connect to the greek cross. |
'e4'
|
Source code in gdsfactory/components/pcms/greek_cross.py
92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 | |

litho_calipers
litho_calipers
litho_calipers(
notch_size: Size = (2.0, 5.0),
notch_spacing: float = 2.0,
num_notches: int = 11,
offset_per_notch: float = 0.1,
row_spacing: float = 0.0,
layer1: LayerSpec = "WG",
layer2: LayerSpec = "SLAB150",
) -> Component
Vernier caliper structure to test lithography alignment.
Only the middle finger is aligned and the rest are offset. adapted from phidl
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
notch_size
|
Size
|
[xwidth, yheight]. |
(2.0, 5.0)
|
notch_spacing
|
float
|
in um. |
2.0
|
num_notches
|
int
|
number of notches. |
11
|
offset_per_notch
|
float
|
in um. |
0.1
|
row_spacing
|
float
|
0 |
0.0
|
layer1
|
LayerSpec
|
layer. |
'WG'
|
layer2
|
LayerSpec
|
layer. |
'SLAB150'
|
Source code in gdsfactory/components/pcms/litho_calipers.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 | |

litho_ruler
litho_ruler
litho_ruler(
height: float = 2,
width: float = 0.5,
spacing: float = 2.0,
scale: tuple[float, ...] = (
3,
1,
1,
1,
1,
2,
1,
1,
1,
1,
),
num_marks: int = 21,
layer: LayerSpec = "WG",
) -> gf.Component
Ruler structure for lithographic measurement.
Includes marks of varying scales to allow for easy reading by eye.
based on phidl.geometry
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
height
|
float
|
Height of the ruling marks in um. |
2
|
width
|
float
|
Width of the ruling marks in um. |
0.5
|
spacing
|
float
|
Center-to-center spacing of the ruling marks in um. |
2.0
|
scale
|
tuple[float, ...]
|
Height scale pattern of marks. |
(3, 1, 1, 1, 1, 2, 1, 1, 1, 1)
|
num_marks
|
int
|
Total number of marks to generate. |
21
|
layer
|
LayerSpec
|
Specific layer to put the ruler geometry on. |
'WG'
|
Source code in gdsfactory/components/pcms/litho_ruler.py
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 | |

litho_steps
litho_steps
litho_steps(
line_widths: tuple[float, ...] = (
1.0,
2.0,
4.0,
8.0,
16.0,
),
line_spacing: float = 10.0,
height: float = 100.0,
layer: LayerSpec = "WG",
) -> Component
Positive + negative tone linewidth test.
used for lithography resolution test patterning based on phidl
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
line_widths
|
tuple[float, ...]
|
in um. |
(1.0, 2.0, 4.0, 8.0, 16.0)
|
line_spacing
|
float
|
in um. |
10.0
|
height
|
float
|
in um. |
100.0
|
layer
|
LayerSpec
|
Specific layer to put the ruler geometry on. |
'WG'
|
Source code in gdsfactory/components/pcms/litho_steps.py
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 | |

pixel
pixel(size: int = 1, layer: LayerSpec = 'WG') -> Component
Source code in gdsfactory/components/pcms/version_stamp.py
15 16 17 18 19 20 | |
![]()
qrcode
qrcode(
data: str = "mask01",
psize: int = 1,
layer: LayerSpec = "WG",
) -> Component
Returns QRCode.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
data
|
str
|
string to encode. |
'mask01'
|
psize
|
int
|
pixel size. |
1
|
layer
|
LayerSpec
|
layer to use. |
'WG'
|
Source code in gdsfactory/components/pcms/version_stamp.py
23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | |

resistance_meander
resistance_meander
resistance_meander(
name: str = "net",
pad_size: Size = (50.0, 50.0),
num_squares: int = 1000,
width: float = 1.0,
res_layer: LayerSpec = "MTOP",
pad_layer: LayerSpec = "MTOP",
) -> Component
Return meander to test resistance.
based on phidl.geometry
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
name
|
str
|
Name of the component. |
'net'
|
pad_size
|
Size
|
Size of the two matched impedance pads (microns). |
(50.0, 50.0)
|
num_squares
|
int
|
Number of squares comprising the resonator wire. |
1000
|
width
|
float
|
The width of the squares (microns). |
1.0
|
res_layer
|
LayerSpec
|
resistance layer. |
'MTOP'
|
pad_layer
|
LayerSpec
|
pad layer. |
'MTOP'
|
Source code in gdsfactory/components/pcms/resistance_meander.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 | |

resistance_sheet
resistance_sheet
resistance_sheet(
width: float = 10.0,
layers: LayerSpecs = ("HEATER",),
layer_offsets: Floats = (0, 0.2),
pad: ComponentSpec = "via_stack_heater_mtop",
pad_size: Size = (50.0, 50.0),
pad_pitch: float = 100.0,
ohms_per_square: float | None = None,
pad_port_name: str = "e4",
) -> Component
Returns Sheet resistance.
keeps connectivity for pads and first layer in layers
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
in um. |
10.0
|
layers
|
LayerSpecs
|
for the middle part. |
('HEATER',)
|
layer_offsets
|
Floats
|
from edge, positive: over, negative: inclusion. |
(0, 0.2)
|
pad
|
ComponentSpec
|
function to create a pad. |
'via_stack_heater_mtop'
|
pad_size
|
Size
|
in um. |
(50.0, 50.0)
|
pad_pitch
|
float
|
in um. |
100.0
|
ohms_per_square
|
float | None
|
optional sheet resistance to compute info.resistance. |
None
|
pad_port_name
|
str
|
port name for the pad. |
'e4'
|
Source code in gdsfactory/components/pcms/resistance_sheet.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 | |

resolution_test_pattern
resolution_test_pattern
resolution_test_pattern(
radius: float = 50.0,
n_spokes: int = 36,
width: float = 1.0,
layer: LayerSpec = "WG",
) -> Component
Radial Siemens star resolution test pattern.
Creates a circle of alternating filled/empty pie-shaped wedges. The pattern is useful for evaluating lithographic resolution, as the feature size decreases toward the center.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float
|
Outer radius of the star pattern in um. |
50.0
|
n_spokes
|
int
|
Total number of spokes (filled + empty). Must be even. |
36
|
width
|
float
|
Target outer edge width of each spoke in um (informational; actual angular width is 360/n_spokes degrees). |
1.0
|
layer
|
LayerSpec
|
Layer specification for the filled wedges. |
'WG'
|
Source code in gdsfactory/components/pcms/resolution_test_pattern.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 | |

ruler
ruler
ruler(
height_long: float = 55,
height_short: float = 5,
height_numbered: float = 10,
width: float = 2,
spacing: float = 5.0,
marks: tuple[float | None, ...] = (
-100,
None,
-90,
None,
-80,
None,
-70,
None,
-60,
None,
-50,
None,
-40,
None,
-30,
None,
-20,
None,
-10,
None,
0,
),
layer: LayerSpec = "WG",
bbox_layers: tuple[LayerSpec, ...] | None = None,
bbox_offset: float = 3.0,
long_marks: tuple[float, ...] = (-50, 0),
text_size: float = 3.5,
) -> gf.Component
Ruler structure for lithographic measurement.
Includes marks of varying scales to allow for easy reading by eye.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
height_long
|
float
|
Height of the long ruling marks in um. |
55
|
height_short
|
float
|
Height of the short ruling marks in um. |
5
|
height_numbered
|
float
|
Height of the numbered ruling marks in um. |
10
|
width
|
float
|
Width of the ruling marks in um. |
2
|
spacing
|
float
|
Center-to-center spacing of the ruling marks in um. |
5.0
|
marks
|
tuple[float | None, ...]
|
Height scale pattern of marks. |
(-100, None, -90, None, -80, None, -70, None, -60, None, -50, None, -40, None, -30, None, -20, None, -10, None, 0)
|
layer
|
LayerSpec
|
Specific layer to put the ruler geometry on. |
'WG'
|
bbox_layers
|
tuple[LayerSpec, ...] | None
|
Layers to include in the bounding box. |
None
|
bbox_offset
|
float
|
Offsets for each bounding box layer. |
3.0
|
cross_section
|
Cross-section spec for the ruler. Overrides layer if provided. |
required | |
long_marks
|
tuple[float, ...]
|
Marks that are long. |
(-50, 0)
|
text_size
|
float
|
Size of the text in um. |
3.5
|
Source code in gdsfactory/components/pcms/ruler.py
9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 | |

staircase
staircase(
component: ComponentSpec | Component = "bend_euler",
straight: ComponentSpec = "straight",
length_v: float = 5.0,
length_h: float = 5.0,
rows: int = 4,
**kwargs: Any
) -> Component
Returns staircase.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec | Component
|
bend spec. |
'bend_euler'
|
straight
|
ComponentSpec
|
straight spec. |
'straight'
|
length_v
|
float
|
vertical length. |
5.0
|
length_h
|
float
|
vertical length. |
5.0
|
rows
|
int
|
number of rows. |
4
|
cols
|
number of cols. |
required | |
kwargs
|
Any
|
cross_section settings. |
{}
|
Source code in gdsfactory/components/pcms/cutback_bend.py
135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 | |

vernier_scale
vernier_scale
vernier_scale(
n_divisions: int = 10,
pitch_main: float = 10.0,
pitch_vernier: float = 9.8,
mark_width: float = 1.0,
mark_height_main: float = 20.0,
mark_height_vernier: float = 15.0,
layer_main: LayerSpec = "WG",
layer_vernier: LayerSpec = (2, 0),
) -> Component
Vernier scale for overlay measurement.
Creates two rows of rectangular marks: a main scale and a vernier scale. The slight pitch difference between the two scales allows sub-pitch overlay measurement. The zero marks of both scales are centered at the origin.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
n_divisions
|
int
|
Number of marks on each side of the center mark (total marks per scale = 2 * n_divisions + 1). |
10
|
pitch_main
|
float
|
Center-to-center spacing of main scale marks in um. |
10.0
|
pitch_vernier
|
float
|
Center-to-center spacing of vernier scale marks in um. |
9.8
|
mark_width
|
float
|
Width of each rectangular mark in um. |
1.0
|
mark_height_main
|
float
|
Height of each main scale mark in um. |
20.0
|
mark_height_vernier
|
float
|
Height of each vernier scale mark in um. |
15.0
|
layer_main
|
LayerSpec
|
Layer specification for the main scale marks. |
'WG'
|
layer_vernier
|
LayerSpec
|
Layer specification for the vernier scale marks. |
(2, 0)
|
Source code in gdsfactory/components/pcms/vernier_scale.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 | |

verniers
verniers
verniers(
widths: Floats = (0.1, 0.2, 0.3, 0.4, 0.5),
gap: float = 0.1,
xsize: float = 100.0,
layer_label: LayerSpec = "TEXT",
straight: ComponentSpec = "straight",
cross_section: CrossSectionSpec = "strip_no_ports",
**kwargs: Any
) -> Component
Returns a component with verniers.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
widths
|
Floats
|
list of widths. |
(0.1, 0.2, 0.3, 0.4, 0.5)
|
gap
|
float
|
gap between verniers. |
0.1
|
xsize
|
float
|
size of the component. |
100.0
|
layer_label
|
LayerSpec
|
layer for the labels. |
'TEXT'
|
straight
|
ComponentSpec
|
straight function. |
'straight'
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip_no_ports'
|
kwargs
|
Any
|
straight settings. |
{}
|
Source code in gdsfactory/components/pcms/verniers.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | |

version_stamp
qrcode
qrcode(
data: str = "mask01",
psize: int = 1,
layer: LayerSpec = "WG",
) -> Component
Returns QRCode.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
data
|
str
|
string to encode. |
'mask01'
|
psize
|
int
|
pixel size. |
1
|
layer
|
LayerSpec
|
layer to use. |
'WG'
|
Source code in gdsfactory/components/pcms/version_stamp.py
23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | |
version_stamp
version_stamp(
labels: tuple[str, ...] = ("demo_label",),
with_qr_code: bool = False,
layer: LayerSpec = "WG",
pixel_size: int = 1,
version: str | None = None,
text_size: int = 10,
) -> Component
Component with module version and date.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
labels
|
tuple[str, ...]
|
Iterable of labels. |
('demo_label',)
|
with_qr_code
|
bool
|
Whether to add a QR code with the date. |
False
|
layer
|
LayerSpec
|
Layer to use. |
'WG'
|
pixel_size
|
int
|
Pixel size. |
1
|
version
|
str | None
|
Version string. |
None
|
text_size
|
int
|
Text size. |
10
|
Source code in gdsfactory/components/pcms/version_stamp.py
48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 | |

quantum
coupler_capacitive
coupler_capacitive
coupler_capacitive(
pad_width: float = 20.0,
pad_height: float = 50.0,
gap: float = 2.0,
feed_width: float = 10.0,
feed_length: float = 30.0,
layer_metal: LayerSpec = (1, 0),
port_type: str = "electrical",
) -> Component
Creates a capacitive coupler for quantum circuits.
A capacitive coupler consists of two metal pads separated by a small gap, providing capacitive coupling between circuit elements like qubits and resonators.
______ ______
_______ | | | | _______
| | | | | || |
| feed1 | | pad1 | ====gap==== | pad2 || feed2 |
| | | | | || |
|_______| | | | ||_______|
|______| |______|
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pad_width
|
float
|
Width of each coupling pad in μm. |
20.0
|
pad_height
|
float
|
Height of each coupling pad in μm. |
50.0
|
gap
|
float
|
Gap between the coupling pads in μm. |
2.0
|
feed_width
|
float
|
Width of the feed lines in μm. |
10.0
|
feed_length
|
float
|
Length of the feed lines in μm. |
30.0
|
layer_metal
|
LayerSpec
|
Layer for the metal structures. |
(1, 0)
|
port_type
|
str
|
Type of port to add to the component. |
'electrical'
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory component with the capacitive coupler geometry. |
Source code in gdsfactory/components/quantum/coupler_capacitive.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 | |
coupler_interdigital
coupler_interdigital(
fingers: int = 6,
finger_length: float = 30.0,
finger_width: float = 2.0,
finger_gap_vertical: float = 2.0,
finger_gap_horizontal: float = 3.0,
feed_width: float = 10.0,
feed_length: float = 30.0,
layer_metal: LayerSpec = (1, 0),
port_type: str = "electrical",
) -> Component
Creates an interdigital capacitive coupler.
Each side includes a base column (a vertical metal block) to which the fingers are attached.
- The width of the base column is equal to the height of the fingers.
- The finger_length parameter refers only to the length of the fingers extending from the base, and does NOT include the base column width
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
fingers
|
int
|
Number of fingers per side. |
6
|
finger_length
|
float
|
Length of each finger in μm (see note above). |
30.0
|
finger_width
|
float
|
Width of each finger in μm. |
2.0
|
finger_gap_vertical
|
float
|
Vertical gap between fingers in μm (g1). |
2.0
|
finger_gap_horizontal
|
float
|
Horizontal gap between fingers in μm (g2). |
3.0
|
feed_width
|
float
|
Width of the feed lines in μm. |
10.0
|
feed_length
|
float
|
Length of the feed lines in μm. |
30.0
|
layer_metal
|
LayerSpec
|
Layer for the metal structures. |
(1, 0)
|
port_type
|
str
|
Type of port to add to the component. |
'electrical'
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory component with the interdigital coupler geometry.
┌────────┐ ┌────────┐ │ │█████████████ █│ │ │ │█ g1 █│ │ │ │█ <─g2─> █████████████│ │ │ │█ █│ │ │ feed1 │█████████████ █│ feed2 │ │ │█ █│ │ │ │█ █████████████│ │ │ │█ █│ │ │ │█████████████ █│ │ └────────┘█ █└────────┘ |
Source code in gdsfactory/components/quantum/coupler_capacitive.py
113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 | |
coupler_tunable
coupler_tunable(
pad_width: float = 30.0,
pad_height: float = 40.0,
gap: float = 3.0,
tuning_pad_width: float = 15.0,
tuning_pad_height: float = 20.0,
tuning_gap: float = 1.0,
feed_width: float = 10.0,
feed_length: float = 30.0,
layer_metal: LayerSpec = (1, 0),
layer_tuning: LayerSpec = (3, 0),
port_type: str = "electrical",
) -> Component
Creates a tunable capacitive coupler with voltage control.
A tunable coupler includes additional electrodes that can be voltage-biased to change the coupling strength dynamically.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pad_width
|
float
|
Width of main coupling pads in μm. |
30.0
|
pad_height
|
float
|
Height of main coupling pads in μm. |
40.0
|
gap
|
float
|
Gap between main coupling pads in μm. |
3.0
|
tuning_pad_width
|
float
|
Width of tuning pads in μm. |
15.0
|
tuning_pad_height
|
float
|
Height of tuning pads in μm. |
20.0
|
tuning_gap
|
float
|
Gap to tuning pads in μm. |
1.0
|
feed_width
|
float
|
Width of feed lines in μm. |
10.0
|
feed_length
|
float
|
Length of feed lines in μm. |
30.0
|
layer_metal
|
LayerSpec
|
Layer for main metal structures. |
(1, 0)
|
layer_tuning
|
LayerSpec
|
Layer for tuning electrodes. |
(3, 0)
|
port_type
|
str
|
Type of port to add to the component. |
'electrical'
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory component with the tunable coupler geometry.
_ | | | | _ |
Component
|
| | | | | || | |
|
Component
|
| feed1 | | pad1 | gap | pad2 || feed2 | |
|
Component
|
| | | | | || | |
|
Component
|
|_| | | | ||_| |__| |_| tuning gap _ | | | tpad2 | | | |____| (connected to feed) |
Source code in gdsfactory/components/quantum/coupler_capacitive.py
250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 | |

coupler_interdigital
coupler_interdigital(
fingers: int = 6,
finger_length: float = 30.0,
finger_width: float = 2.0,
finger_gap_vertical: float = 2.0,
finger_gap_horizontal: float = 3.0,
feed_width: float = 10.0,
feed_length: float = 30.0,
layer_metal: LayerSpec = (1, 0),
port_type: str = "electrical",
) -> Component
Creates an interdigital capacitive coupler.
Each side includes a base column (a vertical metal block) to which the fingers are attached.
- The width of the base column is equal to the height of the fingers.
- The finger_length parameter refers only to the length of the fingers extending from the base, and does NOT include the base column width
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
fingers
|
int
|
Number of fingers per side. |
6
|
finger_length
|
float
|
Length of each finger in μm (see note above). |
30.0
|
finger_width
|
float
|
Width of each finger in μm. |
2.0
|
finger_gap_vertical
|
float
|
Vertical gap between fingers in μm (g1). |
2.0
|
finger_gap_horizontal
|
float
|
Horizontal gap between fingers in μm (g2). |
3.0
|
feed_width
|
float
|
Width of the feed lines in μm. |
10.0
|
feed_length
|
float
|
Length of the feed lines in μm. |
30.0
|
layer_metal
|
LayerSpec
|
Layer for the metal structures. |
(1, 0)
|
port_type
|
str
|
Type of port to add to the component. |
'electrical'
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory component with the interdigital coupler geometry.
┌────────┐ ┌────────┐ │ │█████████████ █│ │ │ │█ g1 █│ │ │ │█ <─g2─> █████████████│ │ │ │█ █│ │ │ feed1 │█████████████ █│ feed2 │ │ │█ █│ │ │ │█ █████████████│ │ │ │█ █│ │ │ │█████████████ █│ │ └────────┘█ █└────────┘ |
Source code in gdsfactory/components/quantum/coupler_capacitive.py
113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 | |

coupler_tunable
coupler_tunable(
pad_width: float = 30.0,
pad_height: float = 40.0,
gap: float = 3.0,
tuning_pad_width: float = 15.0,
tuning_pad_height: float = 20.0,
tuning_gap: float = 1.0,
feed_width: float = 10.0,
feed_length: float = 30.0,
layer_metal: LayerSpec = (1, 0),
layer_tuning: LayerSpec = (3, 0),
port_type: str = "electrical",
) -> Component
Creates a tunable capacitive coupler with voltage control.
A tunable coupler includes additional electrodes that can be voltage-biased to change the coupling strength dynamically.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pad_width
|
float
|
Width of main coupling pads in μm. |
30.0
|
pad_height
|
float
|
Height of main coupling pads in μm. |
40.0
|
gap
|
float
|
Gap between main coupling pads in μm. |
3.0
|
tuning_pad_width
|
float
|
Width of tuning pads in μm. |
15.0
|
tuning_pad_height
|
float
|
Height of tuning pads in μm. |
20.0
|
tuning_gap
|
float
|
Gap to tuning pads in μm. |
1.0
|
feed_width
|
float
|
Width of feed lines in μm. |
10.0
|
feed_length
|
float
|
Length of feed lines in μm. |
30.0
|
layer_metal
|
LayerSpec
|
Layer for main metal structures. |
(1, 0)
|
layer_tuning
|
LayerSpec
|
Layer for tuning electrodes. |
(3, 0)
|
port_type
|
str
|
Type of port to add to the component. |
'electrical'
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory component with the tunable coupler geometry.
_ | | | | _ |
Component
|
| | | | | || | |
|
Component
|
| feed1 | | pad1 | gap | pad2 || feed2 | |
|
Component
|
| | | | | || | |
|
Component
|
|_| | | | ||_| |__| |_| tuning gap _ | | | tpad2 | | | |____| (connected to feed) |
Source code in gdsfactory/components/quantum/coupler_capacitive.py
250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 | |

flux_qubit
flux_qubit
flux_qubit(
loop_width: float = 50.0,
loop_height: float = 50.0,
junction_width: float = 0.15,
junction_height: float = 0.3,
alpha_junction_width: float = 0.12,
alpha_junction_height: float = 0.25,
wire_width: float = 2.0,
layer_metal: LayerSpec = (1, 0),
layer_junction: LayerSpec = (2, 0),
layer_alpha_junction: LayerSpec = (3, 0),
port_type: str = "electrical",
) -> Component
Creates a flux qubit (persistent current qubit).
A flux qubit consists of a superconducting loop interrupted by three Josephson junctions. Two junctions are identical (beta junctions) while the third is smaller (alpha junction) with roughly 0.5-0.8 times the critical current.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
loop_width
|
float
|
Width of the superconducting loop in μm. |
50.0
|
loop_height
|
float
|
Height of the superconducting loop in μm. |
50.0
|
junction_width
|
float
|
Width of the beta Josephson junctions in μm. |
0.15
|
junction_height
|
float
|
Height of the beta Josephson junctions in μm. |
0.3
|
alpha_junction_width
|
float
|
Width of the alpha Josephson junction in μm. |
0.12
|
alpha_junction_height
|
float
|
Height of the alpha Josephson junction in μm. |
0.25
|
wire_width
|
float
|
Width of the superconducting wires in μm. |
2.0
|
layer_metal
|
LayerSpec
|
Layer for the metal wires. |
(1, 0)
|
layer_junction
|
LayerSpec
|
Layer for the beta Josephson junctions. |
(2, 0)
|
layer_alpha_junction
|
LayerSpec
|
Layer for the alpha Josephson junction. |
(3, 0)
|
port_type
|
str
|
Type of port to add to the component. |
'electrical'
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory component with the flux qubit geometry. |
Source code in gdsfactory/components/quantum/flux_qubit.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 | |
flux_qubit_asymmetric
flux_qubit_asymmetric(
loop_width: float = 60.0,
loop_height: float = 40.0,
junction_width: float = 0.15,
junction_height: float = 0.3,
alpha_junction_width: float = 0.12,
alpha_junction_height: float = 0.25,
wire_width: float = 2.0,
asymmetry_angle: float = 15.0,
layer_metal: LayerSpec = (1, 0),
layer_junction: LayerSpec = (2, 0),
layer_alpha_junction: LayerSpec = (3, 0),
port_type: str = "electrical",
) -> Component
Creates an asymmetric flux qubit for reduced flux noise sensitivity.
An asymmetric flux qubit has a loop geometry that is not perfectly symmetric, which can help reduce sensitivity to flux noise while maintaining controllability.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
loop_width
|
float
|
Width of the superconducting loop in μm. |
60.0
|
loop_height
|
float
|
Height of the superconducting loop in μm. |
40.0
|
junction_width
|
float
|
Width of the beta Josephson junctions in μm. |
0.15
|
junction_height
|
float
|
Height of the beta Josephson junctions in μm. |
0.3
|
alpha_junction_width
|
float
|
Width of the alpha Josephson junction in μm. |
0.12
|
alpha_junction_height
|
float
|
Height of the alpha Josephson junction in μm. |
0.25
|
wire_width
|
float
|
Width of the superconducting wires in μm. |
2.0
|
asymmetry_angle
|
float
|
Angle of asymmetry in degrees. |
15.0
|
layer_metal
|
LayerSpec
|
Layer for the metal wires. |
(1, 0)
|
layer_junction
|
LayerSpec
|
Layer for the beta Josephson junctions. |
(2, 0)
|
layer_alpha_junction
|
LayerSpec
|
Layer for the alpha Josephson junction. |
(3, 0)
|
port_type
|
str
|
Type of port to add to the component. |
'electrical'
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory component with the asymmetric flux qubit geometry. |
Source code in gdsfactory/components/quantum/flux_qubit.py
227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 | |

flux_qubit_asymmetric
flux_qubit_asymmetric(
loop_width: float = 60.0,
loop_height: float = 40.0,
junction_width: float = 0.15,
junction_height: float = 0.3,
alpha_junction_width: float = 0.12,
alpha_junction_height: float = 0.25,
wire_width: float = 2.0,
asymmetry_angle: float = 15.0,
layer_metal: LayerSpec = (1, 0),
layer_junction: LayerSpec = (2, 0),
layer_alpha_junction: LayerSpec = (3, 0),
port_type: str = "electrical",
) -> Component
Creates an asymmetric flux qubit for reduced flux noise sensitivity.
An asymmetric flux qubit has a loop geometry that is not perfectly symmetric, which can help reduce sensitivity to flux noise while maintaining controllability.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
loop_width
|
float
|
Width of the superconducting loop in μm. |
60.0
|
loop_height
|
float
|
Height of the superconducting loop in μm. |
40.0
|
junction_width
|
float
|
Width of the beta Josephson junctions in μm. |
0.15
|
junction_height
|
float
|
Height of the beta Josephson junctions in μm. |
0.3
|
alpha_junction_width
|
float
|
Width of the alpha Josephson junction in μm. |
0.12
|
alpha_junction_height
|
float
|
Height of the alpha Josephson junction in μm. |
0.25
|
wire_width
|
float
|
Width of the superconducting wires in μm. |
2.0
|
asymmetry_angle
|
float
|
Angle of asymmetry in degrees. |
15.0
|
layer_metal
|
LayerSpec
|
Layer for the metal wires. |
(1, 0)
|
layer_junction
|
LayerSpec
|
Layer for the beta Josephson junctions. |
(2, 0)
|
layer_alpha_junction
|
LayerSpec
|
Layer for the alpha Josephson junction. |
(3, 0)
|
port_type
|
str
|
Type of port to add to the component. |
'electrical'
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory component with the asymmetric flux qubit geometry. |
Source code in gdsfactory/components/quantum/flux_qubit.py
227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 | |

resonator_cpw
resonator_cpw(
length: float = 1000.0,
width: float = 10.0,
gap: float = 6.0,
meander_pitch: float = 50.0,
meander_width: float = 200.0,
coupling_gap: float = 5.0,
coupling_length: float = 100.0,
layer_metal: LayerSpec = (1, 0),
layer_gap: LayerSpec = (2, 0),
port_type: str = "electrical",
) -> Component
Creates a coplanar waveguide (CPW) resonator.
A CPW resonator consists of a meandered coplanar waveguide with coupling gaps for capacitive coupling to feedlines or qubits.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
Total length of the resonator in μm. |
1000.0
|
width
|
float
|
Width of the center conductor in μm. |
10.0
|
gap
|
float
|
Gap width on each side of the center conductor in μm. |
6.0
|
meander_pitch
|
float
|
Pitch between meander segments in μm. |
50.0
|
meander_width
|
float
|
Width of each meander section in μm. |
200.0
|
coupling_gap
|
float
|
Gap for capacitive coupling in μm. |
5.0
|
coupling_length
|
float
|
Length of the coupling region in μm. |
100.0
|
layer_metal
|
LayerSpec
|
Layer for the metal conductor. |
(1, 0)
|
layer_gap
|
LayerSpec
|
Layer for the gaps (ground plane). |
(2, 0)
|
port_type
|
str
|
Type of port to add to the component. |
'electrical'
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory component with the CPW resonator geometry. |
Source code in gdsfactory/components/quantum/resonator.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 | |

resonator_lumped
resonator_lumped(
capacitor_fingers: int = 4,
capacitor_finger_length: float = 20.0,
capacitor_finger_gap: float = 2.0,
capacitor_thickness: float = 5.0,
inductor_width: float = 2.0,
inductor_turns: int = 3,
inductor_radius: float = 20.0,
coupling_gap: float = 5.0,
layer_metal: LayerSpec = (1, 0),
port_type: str = "electrical",
) -> Component
Creates a lumped element resonator with interdigital capacitor and spiral inductor.
A lumped resonator consists of a capacitive element (interdigital capacitor) and an inductive element (spiral inductor) forming an LC circuit.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
capacitor_fingers
|
int
|
Number of fingers in the interdigital capacitor. |
4
|
capacitor_finger_length
|
float
|
Length of each capacitor finger in μm. |
20.0
|
capacitor_finger_gap
|
float
|
Gap between capacitor fingers in μm. |
2.0
|
capacitor_thickness
|
float
|
Thickness of capacitor fingers in μm. |
5.0
|
inductor_width
|
float
|
Width of the inductor wire in μm. |
2.0
|
inductor_turns
|
int
|
Number of turns in the spiral inductor. |
3
|
inductor_radius
|
float
|
Radius of the spiral inductor in μm. |
20.0
|
coupling_gap
|
float
|
Gap for capacitive coupling in μm. |
5.0
|
layer_metal
|
LayerSpec
|
Layer for the metal structures. |
(1, 0)
|
port_type
|
str
|
Type of port to add to the component. |
'electrical'
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory component with the lumped resonator geometry. |
Source code in gdsfactory/components/quantum/resonator.py
165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 | |

resonator_quarter_wave
resonator_quarter_wave(
length: float = 2500.0,
width: float = 10.0,
gap: float = 6.0,
short_stub_length: float = 50.0,
coupling_gap: float = 5.0,
coupling_length: float = 100.0,
layer_metal: LayerSpec = (1, 0),
layer_gap: LayerSpec = (2, 0),
port_type: str = "electrical",
) -> Component
Creates a quarter-wave coplanar waveguide resonator.
A quarter-wave resonator is shorted at one end and has maximum electric field at the open end, making it suitable for capacitive coupling.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
Length of the quarter-wave resonator in μm. |
2500.0
|
width
|
float
|
Width of the center conductor in μm. |
10.0
|
gap
|
float
|
Gap width on each side of the center conductor in μm. |
6.0
|
short_stub_length
|
float
|
Length of the shorting stub in μm. |
50.0
|
coupling_gap
|
float
|
Gap for capacitive coupling in μm. |
5.0
|
coupling_length
|
float
|
Length of the coupling region in μm. |
100.0
|
layer_metal
|
LayerSpec
|
Layer for the metal conductor. |
(1, 0)
|
layer_gap
|
LayerSpec
|
Layer for the gaps. |
(2, 0)
|
port_type
|
str
|
Type of port to add to the component. |
'electrical'
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory component with the quarter-wave resonator geometry. |
Source code in gdsfactory/components/quantum/resonator.py
304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 | |

transmon
transmon
transmon(
pad_width: float = 200.0,
pad_height: float = 100.0,
pad_gap: float = 6.0,
junction_width: float = 0.15,
junction_height: float = 0.3,
island_width: float = 10.0,
island_height: float = 4.0,
layer_metal: LayerSpec = (1, 0),
layer_junction: LayerSpec = (2, 0),
layer_island: LayerSpec = (1, 0),
port_type: str = "electrical",
) -> Component
Creates a transmon qubit with Josephson junction.
A transmon qubit consists of two capacitor pads connected by a Josephson junction. The junction creates an anharmonic oscillator that can be used as a qubit.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pad_width
|
float
|
Width of each capacitor pad in μm. |
200.0
|
pad_height
|
float
|
Height of each capacitor pad in μm. |
100.0
|
pad_gap
|
float
|
Gap between the two pads in μm. |
6.0
|
junction_width
|
float
|
Width of the Josephson junction in μm. |
0.15
|
junction_height
|
float
|
Height of the Josephson junction in μm. |
0.3
|
island_width
|
float
|
Width of the central island in μm. |
10.0
|
island_height
|
float
|
Height of the central island in μm. |
4.0
|
layer_metal
|
LayerSpec
|
Layer for the metal pads. |
(1, 0)
|
layer_junction
|
LayerSpec
|
Layer for the Josephson junction. |
(2, 0)
|
layer_island
|
LayerSpec
|
Layer for the central island. |
(1, 0)
|
port_type
|
str
|
Type of port to add to the component. |
'electrical'
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory component with the transmon geometry. |
Source code in gdsfactory/components/quantum/transmon.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 | |
transmon_circular
transmon_circular(
pad_radius: float = 100.0,
pad_gap: float = 6.0,
junction_width: float = 0.15,
junction_height: float = 0.3,
island_radius: float = 5.0,
layer_metal: LayerSpec = (1, 0),
layer_junction: LayerSpec = (2, 0),
layer_island: LayerSpec = (1, 0),
port_type: str = "electrical",
) -> Component
Creates a circular transmon qubit with Josephson junction.
A circular variant of the transmon qubit with circular capacitor pads.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pad_radius
|
float
|
Radius of each circular capacitor pad in μm. |
100.0
|
pad_gap
|
float
|
Gap between the two pads in μm. |
6.0
|
junction_width
|
float
|
Width of the Josephson junction in μm. |
0.15
|
junction_height
|
float
|
Height of the Josephson junction in μm. |
0.3
|
island_radius
|
float
|
Radius of the central circular island in μm. |
5.0
|
layer_metal
|
LayerSpec
|
Layer for the metal pads. |
(1, 0)
|
layer_junction
|
LayerSpec
|
Layer for the Josephson junction. |
(2, 0)
|
layer_island
|
LayerSpec
|
Layer for the central island. |
(1, 0)
|
port_type
|
str
|
Type of port to add to the component. |
'electrical'
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory component with the circular transmon geometry. |
Source code in gdsfactory/components/quantum/transmon.py
130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 | |

transmon_circular
transmon_circular(
pad_radius: float = 100.0,
pad_gap: float = 6.0,
junction_width: float = 0.15,
junction_height: float = 0.3,
island_radius: float = 5.0,
layer_metal: LayerSpec = (1, 0),
layer_junction: LayerSpec = (2, 0),
layer_island: LayerSpec = (1, 0),
port_type: str = "electrical",
) -> Component
Creates a circular transmon qubit with Josephson junction.
A circular variant of the transmon qubit with circular capacitor pads.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pad_radius
|
float
|
Radius of each circular capacitor pad in μm. |
100.0
|
pad_gap
|
float
|
Gap between the two pads in μm. |
6.0
|
junction_width
|
float
|
Width of the Josephson junction in μm. |
0.15
|
junction_height
|
float
|
Height of the Josephson junction in μm. |
0.3
|
island_radius
|
float
|
Radius of the central circular island in μm. |
5.0
|
layer_metal
|
LayerSpec
|
Layer for the metal pads. |
(1, 0)
|
layer_junction
|
LayerSpec
|
Layer for the Josephson junction. |
(2, 0)
|
layer_island
|
LayerSpec
|
Layer for the central island. |
(1, 0)
|
port_type
|
str
|
Type of port to add to the component. |
'electrical'
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory component with the circular transmon geometry. |
Source code in gdsfactory/components/quantum/transmon.py
130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 | |

rings
coupler_bend
coupler_bend(
radius: float | None = None,
coupler_gap: float = 0.2,
coupling_angle_coverage: float = 120.0,
cross_section_inner: CrossSectionSpec = "strip",
cross_section_outer: CrossSectionSpec = "strip",
bend: AnyComponentFactory = bend_circular_all_angle,
bend_output: ComponentSpec = "bend_euler",
) -> Component
Compact curved coupler with bezier escape.
TODO: fix for euler bends.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
um. |
None
|
coupler_gap
|
float
|
um. |
0.2
|
coupling_angle_coverage
|
float
|
degrees. |
120.0
|
cross_section_inner
|
CrossSectionSpec
|
spec inner bend. |
'strip'
|
cross_section_outer
|
CrossSectionSpec
|
spec outer bend. |
'strip'
|
bend
|
AnyComponentFactory
|
for bend. |
bend_circular_all_angle
|
bend_output
|
ComponentSpec
|
for bend. r 4 | | | / ___3 | / / |
'bend_euler'
|
Source code in gdsfactory/components/rings/ring_single_bend_coupler.py
19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 | |

coupler_ring_bend
coupler_ring_bend(
radius: float | None = None,
coupler_gap: float = 0.2,
coupling_angle_coverage: float = 90.0,
length_x: float = 0.0,
cross_section_inner: CrossSectionSpec = "strip",
cross_section_outer: CrossSectionSpec = "strip",
bend: AnyComponentFactory = bend_circular_all_angle,
bend_output: ComponentSpec = "bend_euler",
straight: ComponentSpec = "straight",
) -> Component
Two back-to-back coupler_bend.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
um. Default is None, which uses the default radius of the cross_section. |
None
|
coupler_gap
|
float
|
um. |
0.2
|
angle_inner
|
of the inner bend, from beginning to end. Depending on the bend chosen, gap may not be preserved. |
required | |
angle_outer
|
of the outer bend, from beginning to end. Depending on the bend chosen, gap may not be preserved. |
required | |
coupling_angle_coverage
|
float
|
degrees. |
90.0
|
length_x
|
float
|
horizontal straight length. |
0.0
|
cross_section_inner
|
CrossSectionSpec
|
spec inner bend. |
'strip'
|
cross_section_outer
|
CrossSectionSpec
|
spec outer bend. |
'strip'
|
bend
|
AnyComponentFactory
|
for bend. |
bend_circular_all_angle
|
bend_output
|
ComponentSpec
|
for bend. |
'bend_euler'
|
straight
|
ComponentSpec
|
for straight. |
'straight'
|
Source code in gdsfactory/components/rings/ring_single_bend_coupler.py
96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 | |

disk
disk
disk(
radius: float = 10.0,
gap: float = 0.2,
wrap_angle_deg: float = 180.0,
parity: int = 1,
cross_section: CrossSectionSpec = "strip",
) -> Component
Disk Resonator.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float
|
disk resonator radius. |
10.0
|
gap
|
float
|
Distance between the bus straight and resonator. |
0.2
|
wrap_angle_deg
|
float
|
Angle in degrees between 0 and 180. determines how much the bus straight wraps along the resonator. 0 corresponds to a straight bus straight. 180 corresponds to a bus straight wrapped around half of the resonator. |
180.0
|
parity
|
1 or -1
|
1, resonator left from bus straight, -1 resonator to the right. |
1
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
Source code in gdsfactory/components/rings/disk.py
96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 | |
disk_heater
disk_heater(
radius: float = 10.0,
gap: float = 0.2,
wrap_angle_deg: float = 180.0,
parity: int = 1,
cross_section: CrossSectionSpec = "strip",
heater_layer: LayerSpec = "HEATER",
via_stack: ComponentSpec = "via_stack_heater_mtop",
heater_width: float = 5.0,
heater_extent: float = 2.0,
via_width: float = 10.0,
port_orientation: AngleInDegrees | None = 90,
) -> Component
Disk Resonator with top metal heater.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float
|
disk resonator radius. |
10.0
|
gap
|
float
|
Distance between the bus straight and resonator. |
0.2
|
wrap_angle_deg
|
float
|
Angle in degrees between 0 and 180. determines how much the bus straight wraps along the resonator. 0 corresponds to a straight bus straight. 180 corresponds to a bus straight wrapped around half of the resonator. |
180.0
|
parity
|
1 or -1
|
1, resonator left from bus straight, -1 resonator to the right. |
1
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
heater_layer
|
LayerSpec
|
layer of the heater. |
'HEATER'
|
via_stack
|
ComponentSpec
|
via stack component. |
'via_stack_heater_mtop'
|
heater_width
|
float
|
width of the heater. |
5.0
|
heater_extent
|
float
|
length of heater beyond disk. |
2.0
|
via_width
|
float
|
size of the square via at the end of the heater. |
10.0
|
port_orientation
|
AngleInDegrees | None
|
in degrees. |
90
|
Source code in gdsfactory/components/rings/disk.py
166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 | |

disk_heater
disk_heater(
radius: float = 10.0,
gap: float = 0.2,
wrap_angle_deg: float = 180.0,
parity: int = 1,
cross_section: CrossSectionSpec = "strip",
heater_layer: LayerSpec = "HEATER",
via_stack: ComponentSpec = "via_stack_heater_mtop",
heater_width: float = 5.0,
heater_extent: float = 2.0,
via_width: float = 10.0,
port_orientation: AngleInDegrees | None = 90,
) -> Component
Disk Resonator with top metal heater.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float
|
disk resonator radius. |
10.0
|
gap
|
float
|
Distance between the bus straight and resonator. |
0.2
|
wrap_angle_deg
|
float
|
Angle in degrees between 0 and 180. determines how much the bus straight wraps along the resonator. 0 corresponds to a straight bus straight. 180 corresponds to a bus straight wrapped around half of the resonator. |
180.0
|
parity
|
1 or -1
|
1, resonator left from bus straight, -1 resonator to the right. |
1
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
heater_layer
|
LayerSpec
|
layer of the heater. |
'HEATER'
|
via_stack
|
ComponentSpec
|
via stack component. |
'via_stack_heater_mtop'
|
heater_width
|
float
|
width of the heater. |
5.0
|
heater_extent
|
float
|
length of heater beyond disk. |
2.0
|
via_width
|
float
|
size of the square via at the end of the heater. |
10.0
|
port_orientation
|
AngleInDegrees | None
|
in degrees. |
90
|
Source code in gdsfactory/components/rings/disk.py
166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 | |

ring
ring
ring(
radius: float = 10.0,
width: float = 0.5,
angle_resolution: float = 2.5,
layer: LayerSpec = "WG",
angle: float = 360,
distance_resolution: float | None = None,
) -> Component
Returns a ring.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float
|
ring radius. |
10.0
|
width
|
float
|
of the ring. |
0.5
|
angle_resolution
|
float
|
max number of degrees per point. |
2.5
|
layer
|
LayerSpec
|
layer. |
'WG'
|
angle
|
float
|
angular coverage of the ring |
360
|
distance_resolution
|
float | None
|
max distance between points. This is an alternate way to describe the resolution besides setting angle_resolution. If distance_resolution and angle_resolution are both set, distance_resolution determines the resolution. |
None
|
Source code in gdsfactory/components/rings/ring.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 | |

ring_asymmetric
ring_asymmetric(
radius: float = 10.0,
length_x: float = 2.0,
length_y: float = 4.0,
straight: ComponentSpec = "straight",
bend: ComponentSpec = "bend_circular",
cross_section: CrossSectionSpec = "strip",
) -> Component
An asymmetric ring with straight waveguides between the bends.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float
|
of the ring. |
10.0
|
length_x
|
float
|
horizontal straight length. |
2.0
|
length_y
|
float
|
vertical straight length. |
4.0
|
straight
|
ComponentSpec
|
straight component spec. |
'straight'
|
bend
|
ComponentSpec
|
bend component spec. |
'bend_circular'
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
Source code in gdsfactory/components/rings/ring_crow.py
123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 | |

ring_crow
ring_asymmetric
ring_asymmetric(
radius: float = 10.0,
length_x: float = 2.0,
length_y: float = 4.0,
straight: ComponentSpec = "straight",
bend: ComponentSpec = "bend_circular",
cross_section: CrossSectionSpec = "strip",
) -> Component
An asymmetric ring with straight waveguides between the bends.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float
|
of the ring. |
10.0
|
length_x
|
float
|
horizontal straight length. |
2.0
|
length_y
|
float
|
vertical straight length. |
4.0
|
straight
|
ComponentSpec
|
straight component spec. |
'straight'
|
bend
|
ComponentSpec
|
bend component spec. |
'bend_circular'
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
Source code in gdsfactory/components/rings/ring_crow.py
123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 | |
ring_crow
ring_crow(
gaps: tuple[float, ...] = (0.2, 0.2, 0.2, 0.2),
radius: tuple[float, ...] = (10.0, 10.0, 10.0),
bends: tuple[ComponentSpec, ...] | None = None,
ring_cross_sections: tuple[CrossSectionSpec, ...] = (
"strip",
"strip",
"strip",
),
length_x: float = 0,
lengths_y: tuple[float, ...] = (0, 0, 0),
input_straight_cross_section: (
CrossSectionSpec | None
) = None,
output_straight_cross_section: (
CrossSectionSpec | None
) = None,
cross_section: CrossSectionSpec = "strip",
) -> Component
Coupled ring resonators.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
gaps
|
tuple[float, ...]
|
gap between rings. |
(0.2, 0.2, 0.2, 0.2)
|
radius
|
tuple[float, ...]
|
for each ring. |
(10.0, 10.0, 10.0)
|
bends
|
tuple[ComponentSpec, ...] | None
|
bend spec for each ring. |
None
|
ring_cross_sections
|
tuple[CrossSectionSpec, ...]
|
cross_section spec for each ring. |
('strip', 'strip', 'strip')
|
length_x
|
float
|
ring coupler length. |
0
|
lengths_y
|
tuple[float, ...]
|
vertical straight length. |
(0, 0, 0)
|
input_straight_cross_section
|
CrossSectionSpec | None
|
cross_section spec for input and output straight. Defaults to cross_section. |
None
|
output_straight_cross_section
|
CrossSectionSpec | None
|
cross_section spec for input and output straight. Defaults to cross_section. |
None
|
cross_section
|
CrossSectionSpec
|
cross_section spec for input and output straight. --==ct==-- gap[N-1] | | sl sr ring[N-1] | | --==cb==-- gap[N-2] . . . --==ct==-- | | sl sr lengths_y[1], ring[1] | | --==cb==-- gap[1] --==ct==-- | | sl sr lengths_y[0], ring[0] | | --==cb==-- gap[0] length_x |
'strip'
|
Source code in gdsfactory/components/rings/ring_crow.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 | |

ring_crow_couplers
ring_crow_couplers
ring_crow_couplers(
radius: Sequence[float] = (10.0,) * 3,
bends: Sequence[ComponentSpec] = ("bend_circular",) * 3,
ring_cross_sections: Sequence[CrossSectionSpec] = (
"strip",
)
* 3,
couplers: Sequence[ComponentSpec] = ("coupler",) * 4,
) -> Component
Coupled ring resonators with coupler components between gaps.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
Sequence[float]
|
for the bend and coupler. |
(10.0,) * 3
|
bends
|
Sequence[ComponentSpec]
|
bend specs. |
('bend_circular',) * 3
|
ring_cross_sections
|
Sequence[CrossSectionSpec]
|
cross_section for the ring. |
('strip',) * 3
|
couplers
|
Sequence[ComponentSpec]
|
coupling component between rings and bus. --==ct==-- gap[N-1] <------- couplers[N-1] | | sl sr ring[N-1] | | --==cb==-- gap[N-2] <------- couplers[N-2] . . . --==ct==-- | | sl sr lengths_y[1], ring[1] | | --==cb==-- gap[1] <------- couplers[1] --==ct==-- | | sl sr lengths_y[0], ring[0] | | --==cb==-- gap[0] <------- couplers[0] length_x |
('coupler',) * 4
|
Source code in gdsfactory/components/rings/ring_crow_couplers.py
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 | |

ring_double
ring_double
ring_double(
gap: float = 0.2,
gap_top: float | None = None,
gap_bot: float | None = None,
radius: float | None = None,
length_x: float = 0.01,
length_y: float = 0.01,
bend: ComponentSpec = "bend_euler",
straight: ComponentSpec = "straight",
coupler_ring: ComponentSpec = "coupler_ring",
coupler_ring_top: ComponentSpec | None = None,
cross_section: CrossSectionSpec = "strip",
length_extension: float | None = None,
) -> Component
Returns a double bus ring.
two couplers (ct: top, cb: bottom) connected with two vertical straights (sl: left, sr: right)
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
gap
|
float
|
gap between for coupler. |
0.2
|
gap_top
|
float | None
|
gap for the top coupler. Defaults to gap. |
None
|
gap_bot
|
float | None
|
gap for the bottom coupler. Defaults to gap. |
None
|
radius
|
float | None
|
for the bend and coupler. |
None
|
length_x
|
float
|
ring coupler length. |
0.01
|
length_y
|
float
|
vertical straight length. |
0.01
|
bend
|
ComponentSpec
|
90 degrees bend spec. |
'bend_euler'
|
straight
|
ComponentSpec
|
straight spec. |
'straight'
|
coupler_ring
|
ComponentSpec
|
ring coupler spec. |
'coupler_ring'
|
coupler_ring_top
|
ComponentSpec | None
|
top ring coupler spec. Defaults to coupler_ring. |
None
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
length_extension
|
float | None
|
straight length extension at the end of the coupler bottom ports. o2──────▲─────────o3 │gap_top xx──────▼─────────xxx xxx xxx |
None
|
xx xxx x xxx xx xx▲ xx xx│length_y xx xx▼ xx xx xx length_x x xx ◄───────────────► x xx xxx xx xxx xxx──────▲─────────xxx │gap o1──────▼─────────◄──────────────► o4 length_extension
Source code in gdsfactory/components/rings/ring_double.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 | |

ring_double_bend_coupler
ring_double_bend_coupler
ring_double_bend_coupler(
radius: float = 5.0,
gap: float = 0.2,
coupling_angle_coverage: float = 70.0,
bend: ComponentAllAngleFactory = bend_circular_all_angle,
length_x: float = 0.6,
length_y: float = 0.6,
cross_section_inner: CrossSectionSpec = "strip",
cross_section_outer: CrossSectionSpec = "strip",
) -> Component
Returns ring with double curved couplers.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float
|
um. |
5.0
|
gap
|
float
|
um. |
0.2
|
coupling_angle_coverage
|
float
|
degrees. |
70.0
|
bend
|
ComponentAllAngleFactory
|
for bend. |
bend_circular_all_angle
|
length_x
|
float
|
horizontal straight length. |
0.6
|
length_y
|
float
|
vertical straight length. |
0.6
|
cross_section_inner
|
CrossSectionSpec
|
spec inner bend. |
'strip'
|
cross_section_outer
|
CrossSectionSpec
|
spec outer bend. |
'strip'
|
Source code in gdsfactory/components/rings/ring_double_bend_coupler.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 | |

ring_double_heater
ring_double_heater(
gap: float = 0.2,
gap_top: float | None = None,
gap_bot: float | None = None,
radius: float | None = None,
length_x: float = 1.0,
length_y: float = 0.01,
coupler_ring: ComponentSpec = "coupler_ring",
coupler_ring_top: ComponentSpec | None = None,
straight: ComponentSpec = "straight",
bend: ComponentSpec = "bend_euler",
cross_section_heater: CrossSectionSpec = "heater_metal",
cross_section_waveguide_heater: CrossSectionSpec = "strip_heater_metal",
cross_section: CrossSectionSpec = "strip",
via_stack: ComponentSpec = "via_stack_heater_mtop_mini",
port_orientation: AngleInDegrees | None = None,
via_stack_offset: Float2 = (1, 0),
via_stack_size: Float2 | None = None,
with_drop: bool = True,
length_extension: float | None = None,
length_extension_top: float | None = None,
length_extension_bot: float | None = None,
) -> Component
Returns a double bus ring with heater on top.
two couplers (ct: top, cb: bottom) connected with two vertical straights (sl: left, sr: right)
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
gap
|
float
|
gap between for coupler. |
0.2
|
gap_top
|
float | None
|
gap for the top coupler. Defaults to gap. |
None
|
gap_bot
|
float | None
|
gap for the bottom coupler. Defaults to gap. |
None
|
radius
|
float | None
|
for the bend and coupler. |
None
|
length_x
|
float
|
ring coupler length. |
1.0
|
length_y
|
float
|
vertical straight length. |
0.01
|
coupler_ring
|
ComponentSpec
|
ring coupler spec. |
'coupler_ring'
|
coupler_ring_top
|
ComponentSpec | None
|
ring coupler spec for coupler away from vias (defaults to coupler_ring) |
None
|
straight
|
ComponentSpec
|
straight spec. |
'straight'
|
bend
|
ComponentSpec
|
bend spec. |
'bend_euler'
|
cross_section_heater
|
CrossSectionSpec
|
for heater. |
'heater_metal'
|
cross_section_waveguide_heater
|
CrossSectionSpec
|
for waveguide with heater. |
'strip_heater_metal'
|
cross_section
|
CrossSectionSpec
|
for regular waveguide. |
'strip'
|
via_stack
|
ComponentSpec
|
for heater to routing metal. |
'via_stack_heater_mtop_mini'
|
port_orientation
|
AngleInDegrees | None
|
for electrical ports to promote from via_stack. |
None
|
via_stack_size
|
Float2 | None
|
size of via_stack. |
None
|
via_stack_offset
|
Float2
|
x,y offset for via_stack. |
(1, 0)
|
with_drop
|
bool
|
adds drop ports. |
True
|
length_extension
|
float | None
|
straight length extension at the end of the coupler bottom ports. |
None
|
length_extension_top
|
float | None
|
straight length extension at the end of the coupler top ports. |
None
|
length_extension_bot
|
float | None
|
straight length extension at the end of the coupler bottom ports. o2──────▲─────────o3 │gap_top xx──────▼─────────xxx xxx xxx |
None
|
xx xxx x xxx xx xx▲ xx xx│length_y xx xx▼ xx xx xx length_x x xx ◄───────────────► x xx xxx xx xxx xxx──────▲─────────xxx │gap o1──────▼─────────o4
Source code in gdsfactory/components/rings/ring_heater.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 | |

ring_double_pn
ring_double_pn(
add_gap: float = 0.3,
drop_gap: float = 0.3,
radius: float = 5.0,
doping_angle: float = 85,
cross_section: CrossSectionFactory = rib,
pn_cross_section: CrossSectionFactory = cross_section_pn,
doped_heater: bool = True,
doped_heater_angle_buffer: float = 10,
doped_heater_layer: LayerSpec = "NPP",
doped_heater_width: float = 0.5,
doped_heater_waveguide_offset: float = 2.175,
heater_vias: ComponentSpec = _heater_vias,
with_drop: bool = True,
**kwargs: Any
) -> gf.Component
Returns add-drop pn ring with optional doped heater.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
add_gap
|
float
|
gap to add waveguide. Bottom gap. |
0.3
|
drop_gap
|
float
|
gap to drop waveguide. Top gap. |
0.3
|
radius
|
float
|
for the bend and coupler. |
5.0
|
doping_angle
|
float
|
angle in degrees representing portion of ring that is doped. |
85
|
length_x
|
ring coupler length. |
required | |
length_y
|
vertical straight length. |
required | |
cross_section
|
CrossSectionFactory
|
cross_section spec for non-PN doped rib waveguide sections. |
rib
|
pn_cross_section
|
CrossSectionFactory
|
cross section of pn junction. |
cross_section_pn
|
doped_heater
|
bool
|
boolean for if we include doped heater or not. |
True
|
doped_heater_angle_buffer
|
float
|
angle in degrees buffering heater from pn junction. |
10
|
doped_heater_layer
|
LayerSpec
|
doping layer for heater. |
'NPP'
|
doped_heater_width
|
float
|
width of doped heater. |
0.5
|
doped_heater_waveguide_offset
|
float
|
distance from the center of the ring waveguide to the center of the doped heater. |
2.175
|
heater_vias
|
ComponentSpec
|
components specifications for heater vias |
_heater_vias
|
with_drop
|
bool
|
boolean for if we include drop waveguide or not. |
True
|
kwargs
|
Any
|
cross_section settings. |
{}
|
Source code in gdsfactory/components/rings/ring_pn.py
55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 | |

ring_single
ring_single
ring_single(
gap: float = 0.2,
radius: float | None = None,
length_x: float = 4.0,
length_y: float = 0.6,
bend: ComponentSpec = "bend_euler",
straight: ComponentSpec = "straight",
coupler_ring: ComponentSpec = "coupler_ring",
cross_section: CrossSectionSpec = "strip",
length_extension: float | None = None,
) -> gf.Component
Returns a single ring resonator with a directional coupler.
This component creates a ring resonator that consists of: - A directional coupler (cb) at the bottom - Two vertical straights (sl, sr) on the left and right sides - Two bends (bl, br) connecting the vertical straights - A horizontal straight (st) at the top
The ring resonator is commonly used in photonic integrated circuits for: - Wavelength filtering - Optical modulation - Sensing applications - Optical switching
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
gap
|
float
|
Gap between the ring and the straight waveguide in the coupler (μm). |
0.2
|
radius
|
float | None
|
Radius of the ring bends (μm). If None, it will use the radius from the cross section. |
None
|
length_x
|
float
|
Length of the horizontal straight section (μm). |
4.0
|
length_y
|
float
|
Length of the vertical straight sections (μm). |
0.6
|
bend
|
ComponentSpec
|
Component spec for the 90-degree bends. Default is "bend_euler". |
'bend_euler'
|
straight
|
ComponentSpec
|
Component spec for the straight waveguides. Default is "straight". |
'straight'
|
coupler_ring
|
ComponentSpec
|
Component spec for the ring coupler. Default is "coupler_ring". |
'coupler_ring'
|
cross_section
|
CrossSectionSpec
|
Cross section spec for all waveguides. Default is "strip". |
'strip'
|
length_extension
|
float | None
|
straight length extension at the end of the coupler bottom ports. |
None
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory Component containing the ring resonator with: - Two ports: "o1" (input) and "o2" (through) - All waveguide sections properly connected - Cross section applied to all waveguides |
Raises:
| Type | Description |
|---|---|
ValueError
|
If length_x or length_y is negative.
xxx xxx xxx xxx xx xxx x xxx xx xx▲ xx xx│length_y xx xx▼ xx xx xx length_x x xx ◄───────────────► x xx xxx xx xxx xxx──────▲─────────xxx │gap o1──────▼─────────o2◄──────────────► length_extension |
Source code in gdsfactory/components/rings/ring_single.py
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 | |

ring_single_array
ring_single_array
ring_single_array(
ring: ComponentSpec = "ring_single",
spacing: float = 15.0,
list_of_dicts: tuple[dict[str, Any], ...] | None = None,
cross_section: CrossSectionSpec = "strip",
) -> Component
Ring of single bus connected with straights.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
ring
|
ComponentSpec
|
ring spec. |
'ring_single'
|
spacing
|
float
|
between rings. |
15.0
|
list_of_dicts
|
tuple[dict[str, Any], ...] | None
|
settings for each ring. |
None
|
cross_section
|
CrossSectionSpec
|
spec. __ ____ | | | | | | length_y | | | | | | --======-- spacing ----==gap==-- length_x |
'strip'
|
Source code in gdsfactory/components/rings/ring_single_array.py
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 | |

ring_single_bend_coupler
coupler_bend
coupler_bend(
radius: float | None = None,
coupler_gap: float = 0.2,
coupling_angle_coverage: float = 120.0,
cross_section_inner: CrossSectionSpec = "strip",
cross_section_outer: CrossSectionSpec = "strip",
bend: AnyComponentFactory = bend_circular_all_angle,
bend_output: ComponentSpec = "bend_euler",
) -> Component
Compact curved coupler with bezier escape.
TODO: fix for euler bends.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
um. |
None
|
coupler_gap
|
float
|
um. |
0.2
|
coupling_angle_coverage
|
float
|
degrees. |
120.0
|
cross_section_inner
|
CrossSectionSpec
|
spec inner bend. |
'strip'
|
cross_section_outer
|
CrossSectionSpec
|
spec outer bend. |
'strip'
|
bend
|
AnyComponentFactory
|
for bend. |
bend_circular_all_angle
|
bend_output
|
ComponentSpec
|
for bend. r 4 | | | / ___3 | / / |
'bend_euler'
|
Source code in gdsfactory/components/rings/ring_single_bend_coupler.py
19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 | |
coupler_ring_bend
coupler_ring_bend(
radius: float | None = None,
coupler_gap: float = 0.2,
coupling_angle_coverage: float = 90.0,
length_x: float = 0.0,
cross_section_inner: CrossSectionSpec = "strip",
cross_section_outer: CrossSectionSpec = "strip",
bend: AnyComponentFactory = bend_circular_all_angle,
bend_output: ComponentSpec = "bend_euler",
straight: ComponentSpec = "straight",
) -> Component
Two back-to-back coupler_bend.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float | None
|
um. Default is None, which uses the default radius of the cross_section. |
None
|
coupler_gap
|
float
|
um. |
0.2
|
angle_inner
|
of the inner bend, from beginning to end. Depending on the bend chosen, gap may not be preserved. |
required | |
angle_outer
|
of the outer bend, from beginning to end. Depending on the bend chosen, gap may not be preserved. |
required | |
coupling_angle_coverage
|
float
|
degrees. |
90.0
|
length_x
|
float
|
horizontal straight length. |
0.0
|
cross_section_inner
|
CrossSectionSpec
|
spec inner bend. |
'strip'
|
cross_section_outer
|
CrossSectionSpec
|
spec outer bend. |
'strip'
|
bend
|
AnyComponentFactory
|
for bend. |
bend_circular_all_angle
|
bend_output
|
ComponentSpec
|
for bend. |
'bend_euler'
|
straight
|
ComponentSpec
|
for straight. |
'straight'
|
Source code in gdsfactory/components/rings/ring_single_bend_coupler.py
96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 | |
ring_single_bend_coupler
ring_single_bend_coupler(
radius: float = 5.0,
gap: float = 0.2,
coupling_angle_coverage: float = 180.0,
bend_all_angle: AnyComponentFactory = bend_circular_all_angle,
bend: ComponentSpec = "bend_circular",
bend_output: ComponentSpec = "bend_euler",
length_x: float = 0.6,
length_y: float = 0.6,
cross_section_inner: CrossSectionSpec = "strip",
cross_section_outer: CrossSectionSpec = "strip",
**kwargs: Any
) -> Component
Returns ring with curved coupler.
TODO: enable euler bends.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float
|
um. |
5.0
|
gap
|
float
|
um. |
0.2
|
coupling_angle_coverage
|
float
|
degrees. |
180.0
|
angle_inner
|
of the inner bend, from beginning to end. Depending on the bend chosen, gap may not be preserved. |
required | |
angle_outer
|
of the outer bend, from beginning to end. Depending on the bend chosen, gap may not be preserved. |
required | |
bend_all_angle
|
AnyComponentFactory
|
for bend. |
bend_circular_all_angle
|
bend
|
ComponentSpec
|
for bend. |
'bend_circular'
|
bend_output
|
ComponentSpec
|
for bend. |
'bend_euler'
|
length_x
|
float
|
horizontal straight length. |
0.6
|
length_y
|
float
|
vertical straight length. |
0.6
|
cross_section_inner
|
CrossSectionSpec
|
spec inner bend. |
'strip'
|
cross_section_outer
|
CrossSectionSpec
|
spec outer bend. |
'strip'
|
kwargs
|
Any
|
cross_section settings. |
{}
|
Source code in gdsfactory/components/rings/ring_single_bend_coupler.py
158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 | |

ring_single_dut
ring_single_dut
ring_single_dut(
component: ComponentSpec = "straight",
gap: float = 0.2,
length_x: float = 4,
length_y: float = 0,
radius: float | None = None,
coupler: ComponentSpec = "coupler_ring",
bend: ComponentSpec = "bend_euler",
with_component: bool = True,
port_name: str = "o1",
length_extension: float | None = None,
**kwargs: Any
) -> Component
Single bus ring made of two couplers (ct: top, cb: bottom) connected.
with two vertical straights (wyl: left, wyr: right) (Component Under Test) in the middle to extract loss from quality factor.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ComponentSpec
|
device under test. |
'straight'
|
gap
|
float
|
in um. |
0.2
|
length_x
|
float
|
in um. |
4
|
length_y
|
float
|
in um. |
0
|
radius
|
float | None
|
in um. Default is None, which uses the default radius of the cross_section. |
None
|
coupler
|
ComponentSpec
|
coupler function. |
'coupler_ring'
|
bend
|
ComponentSpec
|
bend function. |
'bend_euler'
|
with_component
|
bool
|
True adds component. False adds waveguide. |
True
|
port_name
|
str
|
for component input. |
'o1'
|
length_extension
|
float | None
|
optional length extension for the coupler bottom ports. |
None
|
kwargs
|
Any
|
cross_section settings. |
{}
|
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
with_component
|
bool
|
if False changes component for just a straight. bl-wt-br | | length_y wl component | | --==cb==-- gap length_x |
True
|
Source code in gdsfactory/components/rings/ring_single_dut.py
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 | |

ring_single_heater
module-attribute
ring_single_heater = partial(
ring_double_heater, with_drop=False
)

ring_single_pn
ring_single_pn(
gap: float = 0.3,
radius: float = 5.0,
doping_angle: float = 250,
cross_section: CrossSectionSpec = rib,
pn_cross_section: CrossSectionSpec = cross_section_pn,
doped_heater: bool = True,
doped_heater_angle_buffer: float = 10,
doped_heater_layer: LayerSpec = "NPP",
doped_heater_width: float = 0.5,
doped_heater_waveguide_offset: float = 1.175,
heater_vias: ComponentSpec = _heater_vias,
pn_vias: ComponentSpec = "via_stack_slab_m3",
pn_vias_width: float = 3,
) -> gf.Component
Returns single pn ring with optional doped heater.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
gap
|
float
|
gap between for coupler. |
0.3
|
radius
|
float
|
for the bend and coupler. |
5.0
|
doping_angle
|
float
|
angle in degrees representing portion of ring that is doped. |
250
|
length_x
|
ring coupler length. |
required | |
length_y
|
vertical straight length. |
required | |
cross_section
|
CrossSectionSpec
|
cross_section spec for non-PN doped rib waveguide sections. |
rib
|
pn_cross_section
|
CrossSectionSpec
|
cross section of pn junction. |
cross_section_pn
|
doped_heater
|
bool
|
boolean for if we include doped heater or not. |
True
|
doped_heater_angle_buffer
|
float
|
angle in degrees buffering heater from pn junction. |
10
|
doped_heater_layer
|
LayerSpec
|
doping layer for heater. |
'NPP'
|
doped_heater_width
|
float
|
width of doped heater. |
0.5
|
doped_heater_waveguide_offset
|
float
|
distance from the center of the ring waveguide to the center of the doped heater. |
1.175
|
heater_vias
|
ComponentSpec
|
components specifications for heater vias. |
_heater_vias
|
pn_vias
|
ComponentSpec
|
components specifications for pn vias. |
'via_stack_slab_m3'
|
pn_vias_width
|
float
|
width of pn vias. |
3
|
Source code in gdsfactory/components/rings/ring_pn.py
218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 | |

shapes
C
C
C(
width: float = 1.0,
size: Size = (10.0, 20.0),
layer: LayerSpec = "WG",
port_type: str = "electrical",
) -> Component
C geometry with ports on both ends.
based on phidl.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
of the line. |
1.0
|
size
|
Size
|
length and height of the base. |
(10.0, 20.0)
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
port_type
|
str
|
optical or electrical. |
'electrical'
|
Source code in gdsfactory/components/shapes/C.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 | |

L
L
L(
width: int | float = 1,
size: tuple[int, int] = (10, 20),
layer: LayerSpec = "MTOP",
port_type: str = "electrical",
) -> Component
Generates an 'L' geometry with ports on both ends.
Based on phidl.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
int | float
|
of the line. |
1
|
size
|
tuple[int, int]
|
length and height of the base. |
(10, 20)
|
layer
|
LayerSpec
|
spec. |
'MTOP'
|
port_type
|
str
|
for port. |
'electrical'
|
Source code in gdsfactory/components/shapes/L.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 | |

circle
circle
circle(
radius: float = 10.0,
angle_resolution: float = 2.5,
layer: LayerSpec = "WG",
) -> Component
Generate a circle geometry.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float
|
of the circle. |
10.0
|
angle_resolution
|
float
|
number of degrees per point. |
2.5
|
layer
|
LayerSpec
|
layer. |
'WG'
|
Source code in gdsfactory/components/shapes/circle.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | |

circle_wave
circle_wave
circle_wave(
radius: float = 10.0,
amplitude: float = 1.0,
n_oscillations: int = 8,
angle_resolution: float = 1.0,
layer: LayerSpec = "WG",
) -> Component
Returns a circle with a sinusoidal boundary variation.
The boundary radius varies as r(theta) = radius + amplitude * sin(n * theta).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float
|
mean radius. |
10.0
|
amplitude
|
float
|
amplitude of sinusoidal modulation. |
1.0
|
n_oscillations
|
int
|
number of oscillations around the boundary. |
8
|
angle_resolution
|
float
|
degrees per point. |
1.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
Source code in gdsfactory/components/shapes/circle_wave.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | |

compass
compass
compass(
size: Size = (4.0, 2.0),
layer: LayerSpec = "WG",
port_type: str | None = "electrical",
port_inclusion: float = 0.0,
port_orientations: Ints | None = (180, 90, 0, -90),
auto_rename_ports: bool = True,
) -> Component
Rectangle with ports on each edge (north, south, east, and west).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
Size
|
rectangle size. |
(4.0, 2.0)
|
layer
|
LayerSpec
|
tuple (int, int). |
'WG'
|
port_type
|
str | None
|
optical, electrical. |
'electrical'
|
port_inclusion
|
float
|
from edge. |
0.0
|
port_orientations
|
Ints | None
|
list of port_orientations to add. None does not add ports. |
(180, 90, 0, -90)
|
auto_rename_ports
|
bool
|
auto rename ports. |
True
|
Source code in gdsfactory/components/shapes/compass.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 | |

cross
cross
cross(
length: float = 10.0,
width: float = 3.0,
layer: LayerSpec = "WG",
port_type: str | None = None,
) -> Component
Returns a cross from two rectangles of length and width.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
float Length of the cross from one end to the other. |
10.0
|
width
|
float
|
float Width of the arms of the cross. |
3.0
|
layer
|
LayerSpec
|
layer for geometry. |
'WG'
|
port_type
|
str | None
|
None, optical, electrical. |
None
|
Source code in gdsfactory/components/shapes/cross.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 | |

dash
dash
dash(
width: float = 10.0,
width_end: float = 1.0,
length: float = 20.0,
taper_length: float = 5.0,
tip_length: float = 2.0,
n_bezier_points: int = 30,
layer: LayerSpec = "WG",
) -> Component
Returns a dash shape with Bezier-curved tapered tips.
An elongated shape wider in the middle (width) that tapers via Bezier curves to a narrower tip (width_end) at each end. Based on the pyNISTtoolbox Dash pattern.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
width at the center/body of the dash. |
10.0
|
width_end
|
float
|
width at the tips. |
1.0
|
length
|
float
|
total length of the straight body section. |
20.0
|
taper_length
|
float
|
length of each tapered transition. |
5.0
|
tip_length
|
float
|
length of each rounded tip beyond the taper. |
2.0
|
n_bezier_points
|
int
|
points per Bezier curve segment. |
30
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
Source code in gdsfactory/components/shapes/dash.py
32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 | |

ellipse
ellipse
ellipse(
radii: tuple[float, float] = (10.0, 5.0),
angle_resolution: float = 2.5,
layer: LayerSpec = "WG",
) -> Component
Returns ellipse component.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radii
|
tuple[float, float]
|
Semimajor and semiminor axis lengths of the ellipse. |
(10.0, 5.0)
|
angle_resolution
|
float
|
number of degrees per point. |
2.5
|
layer
|
LayerSpec
|
Specific layer(s) to put polygon geometry on. |
'WG'
|
The orientation of the ellipse is determined by the order of the radii variables; if the first element is larger, the ellipse will be horizontal and if the second element is larger, the ellipse will be vertical.
Source code in gdsfactory/components/shapes/ellipse.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | |

fiducial_squares
fiducial_squares
fiducial_squares(
layers: LayerSpecs = ("WG",),
size: Float2 = (5, 5),
offset: float = 0.14,
) -> gf.Component
Returns fiducials with two squares.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
layers
|
LayerSpecs
|
list of layers to draw the squares. |
('WG',)
|
size
|
Float2
|
size of each square in um. |
(5, 5)
|
offset
|
float
|
space between squares in x and y. |
0.14
|
Source code in gdsfactory/components/shapes/fiducial_squares.py
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | |

fractal
fractal
fractal(
fractal_type: Literal[
"sierpinski_triangle",
"sierpinski_carpet",
"vicsek_cross",
"vicsek_saltire",
] = "sierpinski_triangle",
depth: int = 4,
size: float = 100.0,
layer: LayerSpec = "WG",
) -> Component
Returns a fractal pattern.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
fractal_type
|
Literal['sierpinski_triangle', 'sierpinski_carpet', 'vicsek_cross', 'vicsek_saltire']
|
type of fractal. |
'sierpinski_triangle'
|
depth
|
int
|
recursion depth (max recommended: 6). |
4
|
size
|
float
|
overall size of the fractal. |
100.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
Source code in gdsfactory/components/shapes/fractal.py
96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 | |

hexagon
module-attribute
hexagon = partial(regular_polygon, sides=6)

marker_te
module-attribute
marker_te = partial(
rectangle,
size=(fiber_size, fiber_size),
layer="TE",
centered=True,
)

marker_tm
module-attribute
marker_tm = partial(
rectangle,
size=(fiber_size, fiber_size),
layer="TM",
centered=True,
)

nxn
nxn
nxn(
west: int = 1,
east: int = 4,
north: int = 0,
south: int = 0,
xsize: float = 8.0,
ysize: float = 8.0,
wg_width: float = 0.5,
layer: LayerSpec = "WG",
wg_margin: float = 1.0,
**kwargs: Any
) -> Component
Returns a nxn component with nxn ports (west, east, north, south).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
west
|
int
|
number of west ports. |
1
|
east
|
int
|
number of east ports. |
4
|
north
|
int
|
number of north ports. |
0
|
south
|
int
|
number of south ports. |
0
|
xsize
|
float
|
size in X. |
8.0
|
ysize
|
float
|
size in Y. |
8.0
|
wg_width
|
float
|
width of the straight ports. |
0.5
|
layer
|
LayerSpec
|
layer. |
'WG'
|
wg_margin
|
float
|
margin from straight to component edge. |
1.0
|
kwargs
|
Any
|
port_settings. 3 4 |___|_ |
{}
|
Source code in gdsfactory/components/shapes/nxn.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 | |

octagon
module-attribute
octagon = partial(regular_polygon, sides=8)

pie_arc
pie_arc
pie_arc(
radius: float = 10.0,
radius_y: float | None = None,
start_angle: float = 0.0,
end_angle: float = 90.0,
angle_resolution: float = 2.5,
layer: LayerSpec = "WG",
) -> Component
Returns a pie-shaped arc (sector/wedge), centered at origin.
The shape is a closed polygon from the origin along two radial lines connected by an elliptical arc.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float
|
x-radius (or uniform radius if radius_y is None). |
10.0
|
radius_y
|
float | None
|
y-radius for elliptical arc. Defaults to radius. |
None
|
start_angle
|
float
|
start angle in degrees. |
0.0
|
end_angle
|
float
|
end angle in degrees. |
90.0
|
angle_resolution
|
float
|
degrees per arc point. |
2.5
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
Source code in gdsfactory/components/shapes/pie_arc.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 | |

rect_su_shape
rect_su_shape
rect_su_shape(
L1: float = 10.0,
L2: float = 10.0,
L3: float = 20.0,
width: float = 1.0,
layer: LayerSpec = "WG",
port_type: str | None = "electrical",
) -> Component
Returns a rectangular S- or U-shaped routing structure.
The shape consists of three connected rectangular segments forming an S or U pattern. Positive and negative values of L1, L2, L3 produce different orientations (S-shape, U-shape, etc.).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
L1
|
float
|
length of first vertical segment. |
10.0
|
L2
|
float
|
length of horizontal segment. |
10.0
|
L3
|
float
|
length of second vertical segment. |
20.0
|
width
|
float
|
width of all segments. |
1.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
port_type
|
str | None
|
None, optical, or electrical. |
'electrical'
|
Source code in gdsfactory/components/shapes/rect_su_shape.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 | |

rect_taper
rect_taper
rect_taper(
rect_width: float = 1.0,
rect_length: float = 10.0,
taper_length: float = 5.0,
taper_width: float = 4.0,
layer: LayerSpec = "WG",
port_type: str | None = "optical",
) -> Component
Returns a rectangle connected to a linear taper.
The rectangle of width rect_width and length rect_length is connected on the right to a taper that linearly expands from rect_width to taper_width over taper_length.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
rect_width
|
float
|
width of the rectangular section. |
1.0
|
rect_length
|
float
|
length of the rectangular section. |
10.0
|
taper_length
|
float
|
length of the taper section. |
5.0
|
taper_width
|
float
|
end width of the taper. |
4.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
port_type
|
str | None
|
None, optical, or electrical. |
'optical'
|
Source code in gdsfactory/components/shapes/rect_taper.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 | |

rectangle
rectangle
rectangle(
size: Size = (4.0, 2.0),
layer: LayerSpec = "WG",
centered: bool = False,
port_type: str | None = "electrical",
port_orientations: Ints | None = (180, 90, 0, -90),
) -> Component
Returns a rectangle.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
Size
|
(tuple) Width and height of rectangle. |
(4.0, 2.0)
|
layer
|
LayerSpec
|
Specific layer to put polygon geometry on. |
'WG'
|
centered
|
bool
|
True sets center to (0, 0), False sets south-west to (0, 0). |
False
|
port_type
|
str | None
|
optical, electrical. |
'electrical'
|
port_orientations
|
Ints | None
|
list of port_orientations to add. None adds no ports. |
(180, 90, 0, -90)
|
Source code in gdsfactory/components/shapes/rectangle.py
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 | |
rectangles
rectangles(
size: Size = (4.0, 2.0),
offsets: Sequence[float] | None = None,
layers: LayerSpecs = ("WG", "SLAB150"),
centered: bool = True,
**kwargs: Any
) -> Component
Returns overimposed rectangles.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
Size
|
(tuple) Width and height of rectangle. |
(4.0, 2.0)
|
layers
|
LayerSpecs
|
Specific layer to put polygon geometry on. |
('WG', 'SLAB150')
|
offsets
|
Sequence[float] | None
|
list of offsets. If None, all rectangles have a zero offset. |
None
|
centered
|
bool
|
True sets center to (0, 0), False sets south-west of first rectangle to (0, 0). |
True
|
kwargs
|
Any
|
additional arguments to pass to rectangle. |
{}
|
Other Parameters:
| Name | Type | Description |
|---|---|---|
port_type |
optical, electrical. |
|
port_orientations |
list of port_orientations to add. ┌──────────────┐ │ │ │ ┌──────┐ │ │ │ │ │ │ │ ├───► │ │ │offset │ └──────┘ │ │ │ └──────────────┘ |
Source code in gdsfactory/components/shapes/rectangle.py
54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 | |

rectangles
rectangles(
size: Size = (4.0, 2.0),
offsets: Sequence[float] | None = None,
layers: LayerSpecs = ("WG", "SLAB150"),
centered: bool = True,
**kwargs: Any
) -> Component
Returns overimposed rectangles.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
Size
|
(tuple) Width and height of rectangle. |
(4.0, 2.0)
|
layers
|
LayerSpecs
|
Specific layer to put polygon geometry on. |
('WG', 'SLAB150')
|
offsets
|
Sequence[float] | None
|
list of offsets. If None, all rectangles have a zero offset. |
None
|
centered
|
bool
|
True sets center to (0, 0), False sets south-west of first rectangle to (0, 0). |
True
|
kwargs
|
Any
|
additional arguments to pass to rectangle. |
{}
|
Other Parameters:
| Name | Type | Description |
|---|---|---|
port_type |
optical, electrical. |
|
port_orientations |
list of port_orientations to add. ┌──────────────┐ │ │ │ ┌──────┐ │ │ │ │ │ │ │ ├───► │ │ │offset │ └──────┘ │ │ │ └──────────────┘ |
Source code in gdsfactory/components/shapes/rectangle.py
54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 | |

regular_polygon
regular_polygon
regular_polygon(
sides: int = 6,
side_length: float = 10,
layer: LayerSpec = "WG",
port_width: float | None = None,
port_type: str | None = "placement",
) -> Component
Returns a regular N-sided polygon, with ports on each edge.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
sides
|
int
|
number of sides for the polygon. |
6
|
side_length
|
float
|
of the edges. |
10
|
layer
|
LayerSpec
|
Specific layer to put polygon geometry on. |
'WG'
|
port_width
|
float | None
|
the width of port of the polygon (in electrical pads, the port width may not equal to the side length). |
None
|
port_type
|
str | None
|
optical, electrical. |
'placement'
|
Source code in gdsfactory/components/shapes/regular_polygon.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 | |

rounded_rectangle
rounded_rectangle
rounded_rectangle(
width: float = 20.0,
height: float = 10.0,
corner_radius_x: float = 3.0,
corner_radius_y: float | None = None,
n_corner_points: int = 20,
layer: LayerSpec = "WG",
port_type: str | None = None,
) -> Component
Returns a rectangle with rounded corners, centered at origin.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
total width of the rectangle. |
20.0
|
height
|
float
|
total height of the rectangle. |
10.0
|
corner_radius_x
|
float
|
x-radius of the corner arcs. |
3.0
|
corner_radius_y
|
float | None
|
y-radius of the corner arcs. Defaults to corner_radius_x. |
None
|
n_corner_points
|
int
|
number of points per corner arc. |
20
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
port_type
|
str | None
|
None, optical, or electrical. |
None
|
Source code in gdsfactory/components/shapes/rounded_rectangle.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 | |

star
star
star(
inner_radius: float = 5.0,
outer_radius: float = 10.0,
n_points: int = 5,
layer: LayerSpec = "WG",
) -> Component
Returns a star shape with alternating inner and outer radii.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
inner_radius
|
float
|
radius of inner vertices. |
5.0
|
outer_radius
|
float
|
radius of outer vertices. |
10.0
|
n_points
|
int
|
number of star points. |
5
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
Source code in gdsfactory/components/shapes/star.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 | |

torus
torus
torus(
inner_radius: float = 5.0,
outer_radius: float = 10.0,
start_angle: float = 0.0,
end_angle: float = 360.0,
angle_resolution: float = 2.5,
layer: LayerSpec = "WG",
port_type: str | None = None,
) -> Component
Returns a torus (annular sector / ring sector) centered at origin.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
inner_radius
|
float
|
inner radius. |
5.0
|
outer_radius
|
float
|
outer radius. |
10.0
|
start_angle
|
float
|
start angle in degrees. |
0.0
|
end_angle
|
float
|
end angle in degrees. |
360.0
|
angle_resolution
|
float
|
degrees per arc point. |
2.5
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
port_type
|
str | None
|
None, optical, or electrical. |
None
|
Source code in gdsfactory/components/shapes/torus.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 | |

torus_wave
torus_wave
torus_wave(
inner_radius: float = 5.0,
outer_radius: float = 10.0,
amplitude: float = 0.5,
n_oscillations: int = 8,
in_phase: bool = True,
angle_resolution: float = 1.0,
layer: LayerSpec = "WG",
) -> Component
Returns a torus (full ring) with sinusoidal boundary modulation.
Inner and outer boundaries oscillate sinusoidally. When in_phase=True, both boundaries are modulated in phase; when False, they are pi/2 out of phase.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
inner_radius
|
float
|
mean inner radius. |
5.0
|
outer_radius
|
float
|
mean outer radius. |
10.0
|
amplitude
|
float
|
amplitude of boundary oscillation. |
0.5
|
n_oscillations
|
int
|
number of oscillations around the boundary. |
8
|
in_phase
|
bool
|
if True, inner and outer modulations are in phase. |
True
|
angle_resolution
|
float
|
degrees per point. |
1.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
Source code in gdsfactory/components/shapes/torus_wave.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 | |

triangle
triangle(
x: float = 10,
xtop: float = 0,
y: float = 20,
ybot: float = 0,
layer: LayerSpec = "WG",
) -> Component
Return triangle.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
x
|
float
|
base xsize. |
10
|
xtop
|
float
|
top xsize. |
0
|
y
|
float
|
ysize. |
20
|
ybot
|
float
|
bottom ysize. |
0
|
layer
|
LayerSpec
|
layer. |
'WG'
|
Source code in gdsfactory/components/shapes/triangles.py
20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 | |

triangle2
triangle2(spacing: float = 3, **kwargs: Any) -> Component
Return 2 triangles (bot, top).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
spacing
|
float
|
between top and bottom. |
3
|
kwargs
|
Any
|
triangle arguments. |
{}
|
Other Parameters:
| Name | Type | Description |
|---|---|---|
x |
base xsize. |
|
xtop |
top xsize. |
|
y |
ysize. |
|
ybot |
bottom ysize. |
|
layer |
layer. _ | \ | \ | \ | \ | \ | \ | \ | | spacing | / | / | / | / | / |_/ |
Source code in gdsfactory/components/shapes/triangles.py
54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 | |

triangle2_thin
module-attribute
triangle2_thin = partial(triangle2, xtop=0.2, x=2, y=5)

triangle4
triangle4(**kwargs: Any) -> Component
Return 4 triangles.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
kwargs
|
Any
|
triangle arguments. |
{}
|
Other Parameters:
| Name | Type | Description |
|---|---|---|
x |
base xsize. |
|
xtop |
top xsize. |
|
y |
ysize. |
|
ybot |
bottom ysize. |
|
layer |
layer.
/ | \ / | \ / | \ / | \ | | | \ | / \ | / \ | / \ | / \ | / \ |_/ |
Source code in gdsfactory/components/shapes/triangles.py
96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 | |

triangle4_thin
module-attribute
triangle4_thin = partial(triangle4, xtop=0.2, x=2, y=5)

triangle_thin
module-attribute
triangle_thin = partial(triangle, xtop=0.2, x=2, y=5)

spirals
delay_snake
delay_snake
delay_snake(
length: float = 1600.0,
length0: float = 0.0,
length2: float = 0.0,
n: int = 2,
bend180: ComponentSpec = bend_euler180,
cross_section: CrossSectionSpec = "strip",
width: float | None = None,
) -> Component
Returns Snake with a starting bend and 180 bends.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
total length. |
1600.0
|
length0
|
float
|
start length. |
0.0
|
length2
|
float
|
end length. |
0.0
|
n
|
int
|
number of loops. |
2
|
bend180
|
ComponentSpec
|
ubend spec. |
bend_euler180
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
width
|
float | None
|
width of the waveguide. If None, it will use the width of the cross_section.
|
None
|
>---------\
\bend180.info['length']
/
|-------------------/
|
|------------------->------->|
length2
| delta_length | |
Source code in gdsfactory/components/spirals/delay_snake.py
31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 | |

delay_snake2
delay_snake2
delay_snake2(
length: float = 1600.0,
length0: float = 0.0,
length2: float = 0.0,
n: int = 2,
bend180: ComponentSpec = "bend_euler180",
cross_section: CrossSectionSpec = "strip",
width: float | None = None,
) -> Component
Returns Snake with a starting straight and 180 bends.
Input faces west output faces east.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
total length. |
1600.0
|
length0
|
float
|
start length. |
0.0
|
length2
|
float
|
end length. |
0.0
|
n
|
int
|
number of loops. |
2
|
bend180
|
ComponentSpec
|
ubend spec. |
'bend_euler180'
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
width
|
float | None
|
width of the waveguide. If None, it will use the width of the cross_section. |
None
|
| length0 | length1 |
>---------|
| bend180.length
|-------------------|
|
|------------------->------- |
length2
| delta_length | |
Source code in gdsfactory/components/spirals/delay_snake2.py
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 | |

delay_snake_sbend
delay_snake_sbend
delay_snake_sbend(
length: float = 100.0,
length1: float = 0.0,
length4: float = 0.0,
radius: float = 5.0,
waveguide_spacing: float = 5.0,
bend: ComponentSpec = "bend_euler",
sbend: ComponentSpec = "bend_s",
sbend_xsize: float = 100.0,
cross_section: CrossSectionSpec = "strip",
) -> Component
Returns compact Snake with sbend in the middle.
Input port faces west and output port faces east.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
total length. |
100.0
|
length1
|
float
|
first straight section length in um. |
0.0
|
length4
|
float
|
fourth straight section length in um. |
0.0
|
radius
|
float
|
u bend radius in um. |
5.0
|
waveguide_spacing
|
float
|
waveguide pitch in um. |
5.0
|
bend
|
ComponentSpec
|
bend spec. |
'bend_euler'
|
sbend
|
ComponentSpec
|
sbend spec. |
'bend_s'
|
sbend_xsize
|
float
|
sbend size. |
100.0
|
cross_section
|
CrossSectionSpec
|
cross_section spec.
<---------------------------- length2 spacing | _ | | \ | | \ | bend1 radius | \sbend | bend2| \ | | \ | | __| | ---------------------->-----------> length3 length4 |
'strip'
|
Source code in gdsfactory/components/spirals/delay_snake_sbend.py
30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 | |

spiral
spiral
spiral(
length: float = 100,
bend: ComponentSpec = "bend_euler",
straight: ComponentSpec = "straight",
cross_section: CrossSectionSpec = "strip",
spacing: float = 3.0,
n_loops: int = 6,
) -> gf.Component
Returns a spiral double (spiral in, and then out).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
length of the spiral straight section. |
100
|
bend
|
ComponentSpec
|
bend component. |
'bend_euler'
|
straight
|
ComponentSpec
|
straight component. |
'straight'
|
cross_section
|
CrossSectionSpec
|
cross_section component. |
'strip'
|
spacing
|
float
|
spacing between the spiral loops. |
3.0
|
n_loops
|
int
|
number of loops. |
6
|
Source code in gdsfactory/components/spirals/spiral.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 | |

spiral_archimedes
spiral_archimedes
spiral_archimedes(
width: float = 1.0,
n_turns: int = 5,
separation: float = 2.0,
angle_resolution: float = 2.0,
layer: LayerSpec = "WG",
) -> Component
Returns an Archimedes spiral: r = (separation + width) / (2 * pi) * theta.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
width of the spiral trace. |
1.0
|
n_turns
|
int
|
number of turns. |
5
|
separation
|
float
|
gap between adjacent traces. |
2.0
|
angle_resolution
|
float
|
degrees per point. |
2.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
Source code in gdsfactory/components/spirals/spiral_archimedes.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 | |

spiral_double
spiral_double
spiral_double(
min_bend_radius: float = 10.0,
separation: float = 2.0,
number_of_loops: float = 3,
npoints: int = 1000,
cross_section: CrossSectionSpec = "strip",
bend: ComponentSpec = "bend_circular",
) -> gf.Component
Returns a spiral double (spiral in, and then out).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
min_bend_radius
|
float
|
inner radius of the spiral. |
10.0
|
separation
|
float
|
separation between the loops. |
2.0
|
number_of_loops
|
float
|
number of loops per spiral. |
3
|
npoints
|
int
|
points for the spiral. |
1000
|
cross_section
|
CrossSectionSpec
|
cross-section to extrude the structure with. |
'strip'
|
bend
|
ComponentSpec
|
factory for the bends in the middle of the double spiral. |
'bend_circular'
|
Source code in gdsfactory/components/spirals/spiral_double.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 | |

spiral_fermat
spiral_fermat
spiral_fermat(
width: float = 1.0,
n_turns: int = 5,
a: float = 5.0,
angle_resolution: float = 2.0,
layer: LayerSpec = "WG",
) -> Component
Returns a Fermat spiral: r = a * sqrt(theta).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
width of the spiral trace. |
1.0
|
n_turns
|
int
|
number of turns. |
5
|
a
|
float
|
scaling factor. |
5.0
|
angle_resolution
|
float
|
degrees per point. |
2.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
Source code in gdsfactory/components/spirals/spiral_fermat.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 | |

spiral_inductor
spiral_inductor
spiral_inductor(
width: float = 3.0,
pitch: float = 3.0,
turns: int = 16,
outer_diameter: float = 800,
tail: float = 50.0,
) -> Component
Generates a spiral inductor for superconducting resonator applications, particularly in qubit readout circuits.
This component creates a spiral inductor pattern commonly used in superconducting quantum circuits. The inductor is designed with a square spiral geometry, featuring inner and outer connection tails.
See J. M. Hornibrook, J. I. Colless, A. C. Mahoney, X. G. Croot, S. Blanvillain, H. Lu, A. C. Gossard, D. J. Reilly; Frequency multiplexing for readout of spin qubits. Appl. Phys. Lett. 10 March 2014; 104 (10): 103108. https://doi.org/10.1063/1.4868107
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
Width of the inductor track in microns. Determines the cross-sectional area of the inductor. |
3.0
|
pitch
|
float
|
Distance between adjacent inductor tracks in microns. Affects the coupling between turns. |
3.0
|
turns
|
int
|
Number of complete spiral turns. Higher values increase inductance but require more space. |
16
|
outer_diameter
|
float
|
Overall size of the inductor in microns. Defines the maximum extent of the spiral. |
800
|
tail
|
float
|
Length of the inner and outer connection tails in microns. Used for connecting to other circuit elements. |
50.0
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A GDSFactory component containing the spiral inductor pattern. |
Source code in gdsfactory/components/spirals/spiral_inductor.py
11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 | |

spiral_logarithmic
spiral_logarithmic
spiral_logarithmic(
width: float = 0.5,
n_turns: int = 4,
a: float = 1.0,
b: float = 0.1,
angle_resolution: float = 2.0,
layer: LayerSpec = "WG",
) -> Component
Returns a logarithmic spiral: r = a * exp(b * theta).
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
width of the spiral trace. |
0.5
|
n_turns
|
int
|
number of turns. |
4
|
a
|
float
|
initial radius scaling factor. |
1.0
|
b
|
float
|
growth rate. |
0.1
|
angle_resolution
|
float
|
degrees per point. |
2.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
Source code in gdsfactory/components/spirals/spiral_logarithmic.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 | |

spiral_racetrack
spiral_racetrack(
min_radius: float | None = None,
straight_length: float = 20.0,
spacings: Floats = (2, 2, 3, 3, 2, 2),
straight: ComponentSpec = straight,
bend: ComponentSpec = bend_euler,
bend_s: ComponentSpec = "bend_s",
cross_section: CrossSectionSpec = "strip",
cross_section_s: CrossSectionSpec | None = None,
extra_90_deg_bend: bool = False,
allow_min_radius_violation: bool = False,
) -> Component
Returns Racetrack-Spiral.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
min_radius
|
float | None
|
smallest radius in um. |
None
|
straight_length
|
float
|
length of the straight segments in um. |
20.0
|
spacings
|
Floats
|
space between the center of neighboring waveguides in um. |
(2, 2, 3, 3, 2, 2)
|
straight
|
ComponentSpec
|
factory to generate the straight segments. |
straight
|
bend
|
ComponentSpec
|
factory to generate the bend segments. |
bend_euler
|
bend_s
|
ComponentSpec
|
factory to generate the s-bend segments. |
'bend_s'
|
cross_section
|
CrossSectionSpec
|
cross-section of the waveguides. |
'strip'
|
cross_section_s
|
CrossSectionSpec | None
|
cross-section of the s bend waveguide (optional). |
None
|
extra_90_deg_bend
|
bool
|
if True, we add an additional straight + 90 degree bent at the output, so the output port is looking down. |
False
|
allow_min_radius_violation
|
bool
|
if True, will allow the s-bend to have a smaller radius than the minimum radius. |
False
|
Source code in gdsfactory/components/spirals/spiral_heater.py
28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 | |

spiral_racetrack_fixed_length
spiral_racetrack_fixed_length(
length: float = 1000,
in_out_port_spacing: float = 150,
n_straight_sections: int = 8,
min_radius: float | None = None,
min_spacing: float = 5.0,
straight: ComponentSpec = straight,
bend: ComponentSpec = "bend_circular",
bend_s: ComponentSpec = "bend_s",
cross_section: CrossSectionSpec = "strip",
cross_section_s: CrossSectionSpec | None = None,
) -> Component
Returns Racetrack-Spiral with a specified total length.
The input and output ports are aligned in y. This class is meant to be used for generating interferometers with long waveguide lengths, where the most important parameter is the length difference between the arms.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
total length of the spiral from input to output ports in um. |
1000
|
in_out_port_spacing
|
float
|
spacing between input and output ports of the spiral in um. |
150
|
n_straight_sections
|
int
|
total number of straight sections for the racetrack spiral. Has to be even. |
8
|
min_radius
|
float | None
|
smallest radius in um. |
None
|
min_spacing
|
float
|
minimum center-center spacing between adjacent waveguides. |
5.0
|
straight
|
ComponentSpec
|
factory to generate the straight segments. |
straight
|
bend
|
ComponentSpec
|
factory to generate the bend segments. |
'bend_circular'
|
bend_s
|
ComponentSpec
|
factory to generate the s-bend segments. |
'bend_s'
|
cross_section
|
CrossSectionSpec
|
cross-section of the waveguides. |
'strip'
|
cross_section_s
|
CrossSectionSpec | None
|
cross-section of the s bend waveguide (optional). |
None
|
Source code in gdsfactory/components/spirals/spiral_heater.py
109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 | |

spiral_racetrack_heater_doped
spiral_racetrack_heater_doped(
min_radius: float | None = None,
straight_length: float = 30,
spacing: float = 2,
num: int = 8,
straight: ComponentSpec = straight,
bend: ComponentSpec = bend_euler,
bend_s: ComponentSpec = "bend_s",
waveguide_cross_section: CrossSectionSpec = "strip",
heater_cross_section: CrossSectionSpec = "npp",
) -> Component
Returns spiral racetrack with a heater between the loops.
based on https://doi.org/10.1364/OL.400230 but with the heater between the loops.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
min_radius
|
float | None
|
smallest radius in um. Defaults to the radius of the cross-section. |
None
|
straight_length
|
float
|
length of the straight segments in um. |
30
|
spacing
|
float
|
space between the center of neighboring waveguides in um. |
2
|
num
|
int
|
number. |
8
|
straight
|
ComponentSpec
|
factory to generate the straight segments. |
straight
|
bend
|
ComponentSpec
|
factory to generate the bend segments. |
bend_euler
|
bend_s
|
ComponentSpec
|
factory to generate the s-bend segments. |
'bend_s'
|
waveguide_cross_section
|
CrossSectionSpec
|
cross-section of the waveguides. |
'strip'
|
heater_cross_section
|
CrossSectionSpec
|
cross-section of the heater. |
'npp'
|
Source code in gdsfactory/components/spirals/spiral_heater.py
441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 | |

spiral_racetrack_heater_metal
spiral_racetrack_heater_metal(
min_radius: float | None = None,
straight_length: float = 30,
spacing: float = 2,
num: int = 8,
straight: ComponentSpec = straight,
bend: ComponentSpec = bend_euler,
bend_s: ComponentSpec = "bend_s",
waveguide_cross_section: CrossSectionSpec = "strip",
heater_cross_section: CrossSectionSpec = "heater_metal",
via_stack: (
ComponentSpec | None
) = "via_stack_heater_mtop",
) -> Component
Returns spiral racetrack with a heater above.
based on https://doi.org/10.1364/OL.400230 .
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
min_radius
|
float | None
|
smallest radius. Defaults to the radius of the cross-section. |
None
|
straight_length
|
float
|
length of the straight segments. |
30
|
spacing
|
float
|
space between the center of neighboring waveguides. |
2
|
num
|
int
|
number of loops. |
8
|
straight
|
ComponentSpec
|
factory to generate the straight segments. |
straight
|
bend
|
ComponentSpec
|
factory to generate the bend segments. |
bend_euler
|
bend_s
|
ComponentSpec
|
factory to generate the s-bend segments. |
'bend_s'
|
waveguide_cross_section
|
CrossSectionSpec
|
cross-section of the waveguides. |
'strip'
|
heater_cross_section
|
CrossSectionSpec
|
cross-section of the heater. |
'heater_metal'
|
via_stack
|
ComponentSpec | None
|
via stack to connect the heater to the metal layer. |
'via_stack_heater_mtop'
|
Source code in gdsfactory/components/spirals/spiral_heater.py
320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 | |

spiral_rectangular
spiral_rectangular
spiral_rectangular(
n_turns: int = 4,
width: float = 1.0,
start_length: float = 10.0,
pitch: float = 3.0,
layer: LayerSpec = "WG",
) -> Component
Returns a rectangular/Manhattan spiral as a polygon.
Each segment grows by pitch per half-turn, building an expanding rectangular spiral. The outline is created with the given width offset.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
n_turns
|
int
|
number of full turns. |
4
|
width
|
float
|
width of the spiral trace. |
1.0
|
start_length
|
float
|
initial segment length. |
10.0
|
pitch
|
float
|
spacing between adjacent turns (center-to-center). |
3.0
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
Source code in gdsfactory/components/spirals/spiral_rectangular.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 | |

superconductors
hline
hline
hline(
length: float = 10.0,
width: float = 0.5,
layer: LayerSpec = "WG",
port_type: str = "optical",
) -> Component
Creates a horizontal straight line component with ports on east and west sides.
This component is commonly used in photonic and superconducting circuits as a basic waveguide or transmission line element. It creates a rectangular polygon with ports at both ends for easy connection to other components.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
Length of the line in microns. Must be positive. |
10.0
|
width
|
float
|
Width of the line in microns. Must be positive. |
0.5
|
layer
|
LayerSpec
|
Layer specification for the line (default: "WG"). Can be a string or a tuple of (layer, datatype). |
'WG'
|
port_type
|
str
|
Type of port to create (default: "optical"). Common values are "optical" for photonic circuits or "electrical" for superconducting circuits. |
'optical'
|
Returns:
| Name | Type | Description |
|---|---|---|
Component |
Component
|
A gdsfactory Component object containing: - A rectangular polygon representing the line - Two ports named "o1" (west) and "o2" (east) - Component info with width and length values |
Note
- The line is centered vertically at y=0
- Port "o1" is at x=0 with orientation 180° (west)
- Port "o2" is at x=length with orientation 0° (east)
- If length or width is 0 or negative, no polygon is created but ports are still added
Source code in gdsfactory/components/superconductors/hline.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 | |

optimal_90deg
optimal_90deg
optimal_90deg(
width: float = 100,
num_pts: int = 15,
length_adjust: float = 1,
layer: LayerSpec = (1, 0),
) -> Component
Returns optimally-rounded 90 degree bend that is sharp on the outer corner.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
Width of the ports on either side of the bend. |
100
|
num_pts
|
int
|
The number of points comprising the curved section of the bend. |
15
|
length_adjust
|
float
|
Adjusts the length of the non-curved portion of the bend. |
1
|
layer
|
LayerSpec
|
Specific layer(s) to put polygon geometry on. |
(1, 0)
|
Notes
Optimal structure from https://doi.org/10.1103/PhysRevB.84.174510 Clem, J., & Berggren, K. (2011). Geometry-dependent critical currents in superconducting nanocircuits. Physical Review B, 84(17), 1-27.
Source code in gdsfactory/components/superconductors/optimal_90deg.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 | |

optimal_hairpin
optimal_hairpin
optimal_hairpin(
width: float = 0.2,
pitch: float = 0.6,
length: float = 10,
turn_ratio: float = 4,
num_pts: int = 50,
layer: LayerSpec = (1, 0),
) -> Component
Returns an optimally-rounded hairpin geometry, with a 180 degree turn.
based on phidl.geometry
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
Width of the hairpin leads. |
0.2
|
pitch
|
float
|
Distance between the two hairpin leads. Must be greater than width. |
0.6
|
length
|
float
|
Length of the hairpin from the connectors to the opposite end of the curve. |
10
|
turn_ratio
|
float
|
int or float Specifies how much of the hairpin is dedicated to the 180 degree turn. A turn_ratio of 10 will result in 20% of the hairpin being comprised of the turn. |
4
|
num_pts
|
int
|
Number of points constituting the 180 degree turn. |
50
|
layer
|
LayerSpec
|
Specific layer(s) to put polygon geometry on. |
(1, 0)
|
Notes
Hairpin pitch must be greater than width.
Optimal structure from https://doi.org/10.1103/PhysRevB.84.174510 Clem, J., & Berggren, K. (2011). Geometry-dependent critical currents in superconducting nanocircuits. Physical Review B, 84(17), 1-27.
Source code in gdsfactory/components/superconductors/optimal_hairpin.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 | |

optimal_step
optimal_step
optimal_step(
start_width: float = 10,
end_width: float = 22,
num_pts: int = 50,
width_tol: float = 0.001,
anticrowding_factor: float = 1.2,
symmetric: bool = False,
layer: LayerSpec = (1, 0),
) -> Component
Returns an optimally-rounded step geometry.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
start_width
|
float
|
Width of the connector on the left end of the step. |
10
|
end_width
|
float
|
Width of the connector on the right end of the step. |
22
|
num_pts
|
int
|
number of points comprising the entire step geometry. |
50
|
width_tol
|
float
|
Point at which to terminate the calculation of the optimal step |
0.001
|
anticrowding_factor
|
float
|
Factor to reduce current crowding by elongating the structure and reducing the curvature |
1.2
|
symmetric
|
bool
|
If True, adds a mirrored copy of the step across the x-axis to the geometry and adjusts the width of the ports. |
False
|
layer
|
LayerSpec
|
layer spec to put polygon geometry on. |
(1, 0)
|
based on phidl.geometry Optimal structure from https://doi.org/10.1103/PhysRevB.84.174510 Clem, J., & Berggren, K. (2011). Geometry-dependent critical currents in superconducting nanocircuits. Physical Review B, 84(17), 1-27.
Source code in gdsfactory/components/superconductors/optimal_step.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 | |

snspd
snspd
snspd(
wire_width: float = 0.2,
wire_pitch: float = 0.6,
size: Size = (10, 8),
num_squares: int | None = None,
turn_ratio: float = 4,
terminals_same_side: bool = False,
layer: LayerSpec = (1, 0),
port_type: str = "electrical",
) -> Component
Creates an optimally-rounded SNSPD.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
wire_width
|
float
|
Width of the wire. |
0.2
|
wire_pitch
|
float
|
Distance between two adjacent wires. Must be greater than |
0.6
|
size
|
Size
|
Float2 (width, height) of the rectangle formed by the outer boundary of the SNSPD. |
(10, 8)
|
num_squares
|
int | None
|
int | None = None Total number of squares inside the SNSPD length. |
None
|
turn_ratio
|
float
|
float
Specifies how much of the SNSPD width is dedicated to the 180 degree
turn. A |
4
|
terminals_same_side
|
bool
|
If True, both ports will be located on the same side of the SNSPD. |
False
|
layer
|
LayerSpec
|
layer spec to put polygon geometry on. |
(1, 0)
|
port_type
|
str
|
type of port to add to the component. |
'electrical'
|
Source code in gdsfactory/components/superconductors/snspd.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 | |

ytron_round
ytron_round(
rho: float = 1,
arm_lengths: tuple[float, float] = (500, 300),
source_length: float = 500,
arm_widths: tuple[float, float] = (200, 200),
theta: float = 2.5,
theta_resolution: float = 10,
layer: LayerSpec = "WG",
) -> Component
Ytron structure for superconducting nanowires.
McCaughan, A. N., Abebe, N. S., Zhao, Q.-Y. & Berggren, K. K. Using Geometry To Sense Current. Nano Lett. 16, 7626-7631 (2016). http://dx.doi.org/10.1021/acs.nanolett.6b03593
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
rho
|
float
|
Radius of curvature of ytron intersection point. |
1
|
arm_lengths
|
tuple[float, float]
|
Lengths of the left and right arms of the yTron, respectively. |
(500, 300)
|
source_length
|
float
|
Length of the source of the yTron. |
500
|
arm_widths
|
tuple[float, float]
|
Widths of the left and right arms of the yTron, respectively. |
(200, 200)
|
theta
|
float
|
Angle between the two yTron arms. |
2.5
|
theta_resolution
|
float
|
Angle resolution for curvature of ytron intersection point. |
10
|
layer
|
LayerSpec
|
Specific layer(s) to put polygon geometry on. |
'WG'
|
Returns:
| Type | Description |
|---|---|
Component
|
Component containing a yTron geometry. |
Source code in gdsfactory/components/superconductors/ytron.py
18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 | |

tapers
ramp
ramp
ramp(
length: float = 10.0,
width1: float = 5.0,
width2: float | None = 8.0,
layer: LayerSpec = "WG",
) -> Component
Return a ramp component.
Based on phidl.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
Length of the ramp section. |
10.0
|
width1
|
float
|
Width of the start of the ramp section. |
5.0
|
width2
|
float | None
|
Width of the end of the ramp section (defaults to width1). |
8.0
|
layer
|
LayerSpec
|
Specific layer to put polygon geometry on. |
'WG'
|
Source code in gdsfactory/components/tapers/ramp.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | |

taper
taper
taper(
length: float = 10.0,
width1: float = 0.5,
width2: float | None = None,
layer: LayerSpec | None = None,
port: Port | None = None,
with_two_ports: bool = True,
cross_section: CrossSectionSpec = "strip",
port_names: tuple[str, str] = ("o1", "o2"),
port_types: tuple[str, str] = ("optical", "optical"),
with_bbox: bool = True,
) -> Component
Linear taper, which tapers only the main cross section section.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
taper length. |
10.0
|
width1
|
float
|
width of the west/left port. |
0.5
|
width2
|
float | None
|
width of the east/right port. Defaults to width1. |
None
|
layer
|
LayerSpec | None
|
layer for the taper. |
None
|
port
|
Port | None
|
can taper from a port instead of defining width1. |
None
|
with_two_ports
|
bool
|
includes a second port. False for terminator and edge coupler fiber interface. |
True
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string, CrossSectionFactory dict). |
'strip'
|
port_names
|
tuple[str, str]
|
input and output port names. Second name only used if with_two_ports. |
('o1', 'o2')
|
port_types
|
tuple[str, str]
|
input and output port types. Second type only used if with_two_ports. |
('optical', 'optical')
|
with_bbox
|
bool
|
box in bbox_layers and bbox_offsets to avoid DRC sharp edges. |
True
|
Source code in gdsfactory/components/tapers/taper.py
23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 | |
taper_nc_sc
taper_nc_sc(
width1: float = 1,
width2: float = 0.5,
length: float = 20,
layer_wg: LayerSpec = "WG",
layer_nitride: LayerSpec = "WGN",
width_tip_nitride: float = 0.15,
width_tip_silicon: float = 0.15,
cross_section: CrossSectionSpec = "strip",
) -> Component
Taper from nitride to strip.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width1
|
float
|
nitride width. |
1
|
width2
|
float
|
silicon width. |
0.5
|
length
|
float
|
taper length. |
20
|
layer_wg
|
LayerSpec
|
nitride layer. |
'WG'
|
layer_nitride
|
LayerSpec
|
strip layer. |
'WGN'
|
width_tip_nitride
|
float
|
tip width for nitride. |
0.15
|
width_tip_silicon
|
float
|
tip width for strip. |
0.15
|
cross_section
|
CrossSectionSpec
|
cross_section specification. |
'strip'
|
Source code in gdsfactory/components/tapers/taper.py
308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 | |
taper_sc_nc
taper_sc_nc(
width1: float = 0.5,
width2: float = 1,
length: float = 20,
layer_wg: LayerSpec = "WG",
layer_nitride: LayerSpec = "WGN",
width_tip_nitride: float = 0.15,
width_tip_silicon: float = 0.15,
cross_section: CrossSectionSpec = "strip",
) -> Component
Taper from strip to nitride.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width1
|
float
|
strip width. |
0.5
|
width2
|
float
|
nitride width. |
1
|
length
|
float
|
taper length. |
20
|
layer_wg
|
LayerSpec
|
strip layer. |
'WG'
|
layer_nitride
|
LayerSpec
|
nitride layer. |
'WGN'
|
width_tip_nitride
|
float
|
tip width for nitride. |
0.15
|
width_tip_silicon
|
float
|
tip width for strip. |
0.15
|
cross_section
|
CrossSectionSpec
|
cross_section specification. |
'strip'
|
Source code in gdsfactory/components/tapers/taper.py
272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 | |
taper_strip_to_ridge
taper_strip_to_ridge(
length: float = 10.0,
width1: float = 0.5,
width2: float = 0.5,
w_slab1: float = 0.15,
w_slab2: float = 6.0,
layer_wg: LayerSpec = "WG",
layer_slab: LayerSpec = "SLAB90",
cross_section: CrossSectionSpec = "strip",
use_slab_port: bool = False,
slab_port_layer: LayerSpec | None = None,
) -> Component
Linear taper from strip to rib.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
taper length (um). |
10.0
|
width1
|
float
|
in um. |
0.5
|
width2
|
float
|
in um. |
0.5
|
w_slab1
|
float
|
slab width in um. |
0.15
|
w_slab2
|
float
|
slab width in um. |
6.0
|
layer_wg
|
LayerSpec
|
for input waveguide. |
'WG'
|
layer_slab
|
LayerSpec
|
for output waveguide with slab. |
'SLAB90'
|
cross_section
|
CrossSectionSpec
|
for input waveguide. |
'strip'
|
use_slab_port
|
bool
|
if True adds a second port for the slab. |
False
|
slab_port_layer
|
LayerSpec | None
|
if specified, overrides the layer for the slab port. |
None
|
__________________________
/ |
_______/____________|______________
/ |
width1 |w_slab1 | w_slab2 width2
______\_____________|______________
\ |
\__________________________
Source code in gdsfactory/components/tapers/taper.py
136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 | |
taper_strip_to_ridge_trenches
taper_strip_to_ridge_trenches(
length: float = 10.0,
width: float = 0.5,
slab_offset: float = 3.0,
trench_width: float = 2.0,
trench_layer: LayerSpec = "DEEP_ETCH",
layer_wg: LayerSpec = "WG",
trench_offset: float = 0.1,
) -> gf.Component
Defines taper using trenches to define the etch.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
in um. |
10.0
|
width
|
float
|
in um. |
0.5
|
slab_offset
|
float
|
in um. |
3.0
|
trench_width
|
float
|
in um. |
2.0
|
trench_layer
|
LayerSpec
|
trench layer. |
'DEEP_ETCH'
|
layer_wg
|
LayerSpec
|
waveguide layer. |
'WG'
|
trench_offset
|
float
|
after waveguide in um. |
0.1
|
Source code in gdsfactory/components/tapers/taper.py
221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 | |

taper_0p5_to_3_l36
module-attribute
taper_0p5_to_3_l36 = partial(
taper_from_csv,
filepath=data / "taper_strip_0p5_3_36.csv",
)

taper_adiabatic
neff_TE1550SOI_220nm
neff_TE1550SOI_220nm(w: float) -> float
Returns the effective index of the fundamental TE mode for a 220nm-thick core with 3.45 index, fully clad with 1.44 index.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
w
|
float
|
width in um. |
required |
Returns:
| Type | Description |
|---|---|
float
|
effective index. |
Source code in gdsfactory/components/tapers/taper_adiabatic.py
18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 | |
taper_adiabatic
taper_adiabatic(
width1: float = 0.5,
width2: float = 5.0,
length: float = 0,
neff_w: Callable[[float], float] = neff_TE1550SOI_220nm,
alpha: float = 1,
wavelength: float = 1.55,
npoints: int = 200,
cross_section: CrossSectionSpec = "strip",
max_length: float = 200,
) -> gf.Component
Returns a straight adiabatic_taper from an effective index callable.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width1
|
float
|
initial width. |
0.5
|
width2
|
float
|
final width. |
5.0
|
length
|
float
|
0 uses the optimized length, and otherwise the optimal shape is compressed/stretched to the specified length. |
0
|
neff_w
|
Callable[[float], float]
|
a callable that returns the effective index as a function of width - By default, will use a compact model of neff(y) for fundamental 1550 nm TE mode of 220nm-thick core with 3.45 index, fully clad with 1.44 index. Many coefficients are needed to capture the behaviour. |
neff_TE1550SOI_220nm
|
alpha
|
float
|
parameter that scales the rate of width change. - closer to 0 means longer and more adiabatic; - 1 is the intuitive limit beyond which higher order modes are excited; - [2] reports good performance up to 1.4 for fundamental TE in SOI (for multiple core thicknesses) |
1
|
wavelength
|
float
|
wavelength in um. |
1.55
|
npoints
|
int
|
number of points for sampling. |
200
|
cross_section
|
CrossSectionSpec
|
cross_section specification. |
'strip'
|
max_length
|
float
|
maximum length for the taper. |
200
|
References
[1] Burns, W. K., et al. "Optical waveguide parabolic coupling horns." Appl. Phys. Lett., vol. 30, no. 1, 1 Jan. 1977, pp. 28-30, doi:10.1063/1.89199. [2] Fu, Yunfei, et al. "Efficient adiabatic silicon-on-insulator waveguide taper." Photonics Res., vol. 2, no. 3, 1 June 2014, pp. A41-A44, doi:10.1364/PRJ.2.000A41. npoints: number of points for sampling
Source code in gdsfactory/components/tapers/taper_adiabatic.py
50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 | |

taper_cross_section
taper_cross_section
taper_cross_section(
cross_section1: CrossSectionSpec = "strip_rib_tip",
cross_section2: CrossSectionSpec = "rib2",
length: float = 10,
npoints: int = 100,
linear: bool = False,
width_type: str = "sine",
exclude_layers: LayerSpecs | None = None,
) -> Component
Returns taper transition between cross_section1 and cross_section2.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
cross_section1
|
CrossSectionSpec
|
start cross_section factory. |
'strip_rib_tip'
|
cross_section2
|
CrossSectionSpec
|
end cross_section factory. |
'rib2'
|
length
|
float
|
transition length. |
10
|
npoints
|
int
|
number of points. |
100
|
linear
|
bool
|
shape of the transition, sine when False. |
False
|
width_type
|
str
|
shape of the transition ONLY IF linear is False |
'sine'
|
exclude_layers
|
LayerSpecs | None
|
layers to exclude from the transition. Sections on these layers will be omitted from the component. |
None
|
_____________________
/
_______/______________________
/
cross_section1 | cross_section2
______\_______________________
\
\_____________________
Source code in gdsfactory/components/tapers/taper_cross_section.py
19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 | |

taper_cross_section_linear
module-attribute
taper_cross_section_linear = partial(
taper_cross_section, linear=True, npoints=2
)

taper_cross_section_parabolic
module-attribute
taper_cross_section_parabolic = partial(
taper_cross_section,
linear=False,
width_type="parabolic",
npoints=101,
)

taper_cross_section_sine
module-attribute
taper_cross_section_sine = partial(
taper_cross_section, linear=False, npoints=101
)

taper_electrical
module-attribute
taper_electrical = partial(
taper,
port_types=("electrical", "electrical"),
port_names=("e1", "e2"),
cross_section="metal_routing",
)

taper_from_csv
Adiabatic tapers from CSV files.
taper_from_csv
taper_from_csv(
filepath: Path = data / "taper_strip_0p5_3_36.csv",
cross_section: CrossSectionSpec = "strip",
) -> Component
Returns taper from CSV file.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
filepath
|
Path
|
for CSV file. |
data / 'taper_strip_0p5_3_36.csv'
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string, CrossSectionFactory dict). |
'strip'
|
Source code in gdsfactory/components/tapers/taper_from_csv.py
31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 | |

taper_hecken
Hecken taper for microstrip impedance matching.
Adapted from PHIDL https://github.com/amccaugh/phidl/ by Adam McCaughan
taper_hecken
taper_hecken(
length: float = 200,
B: float = 4.0091,
dielectric_thickness: float = 0.25,
eps_r: float = 2,
Lk_per_sq: float = 2.5e-10,
Z1: float | None = 50,
Z2: float | None = 100,
width1: float | None = None,
width2: float | None = None,
num_pts: int = 100,
layer: LayerSpec = "WG",
) -> Component
Creates a Hecken-tapered microstrip.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
Length of the microstrip. |
200
|
B
|
float
|
Controls the intensity of the taper. |
4.0091
|
dielectric_thickness
|
float
|
Thickness of the substrate. |
0.25
|
eps_r
|
float
|
Dielectric constant of the substrate. |
2
|
Lk_per_sq
|
float
|
Kinetic inductance per square of the microstrip. |
2.5e-10
|
Z1
|
float | None
|
Impedance of the left side region of the microstrip. |
50
|
Z2
|
float | None
|
Impedance of the right side region of the microstrip. |
100
|
width1
|
float | None
|
Width of the left side of the microstrip. |
None
|
width2
|
float | None
|
Width of the right side of the microstrip. |
None
|
num_pts
|
int
|
Number of points comprising the curve of the entire microstrip. |
100
|
layer
|
LayerSpec
|
Specific layer(s) to put polygon geometry on. |
'WG'
|
Returns:
| Type | Description |
|---|---|
Component
|
Component containing a Hecken-tapered microstrip. |
Source code in gdsfactory/components/tapers/taper_hecken.py
26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 | |

taper_meander
Meander taper for superconducting nanowires.
Adapted from PHIDL https://github.com/amccaugh/phidl/ by Adam McCaughan
taper_meander
taper_meander(
x_taper: tuple[float, ...] | None = None,
w_taper: tuple[float, ...] | None = None,
meander_length: float = 1000,
spacing_factor: float = 3,
min_spacing: float = 0.5,
layer: LayerSpec = "WG",
) -> Component
Create a meander from arrays of x-positions and widths.
Typically used for creating meandered tapers.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
x_taper
|
tuple[float, ...] | None
|
The x-coordinates of the data points, must be increasing. |
None
|
w_taper
|
tuple[float, ...] | None
|
The widths at each x-coordinate, same length as x_taper. |
None
|
meander_length
|
float
|
Length of each section of the meander. |
1000
|
spacing_factor
|
float
|
Multiplicative spacing factor between adjacent meanders. |
3
|
min_spacing
|
float
|
Minimum spacing between adjacent meanders. |
0.5
|
layer
|
LayerSpec
|
Specific layer(s) to put polygon geometry on. |
'WG'
|
Returns:
| Type | Description |
|---|---|
Component
|
Component containing the meandered taper. |
Source code in gdsfactory/components/tapers/taper_meander.py
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 | |

taper_nc_sc
taper_nc_sc(
width1: float = 1,
width2: float = 0.5,
length: float = 20,
layer_wg: LayerSpec = "WG",
layer_nitride: LayerSpec = "WGN",
width_tip_nitride: float = 0.15,
width_tip_silicon: float = 0.15,
cross_section: CrossSectionSpec = "strip",
) -> Component
Taper from nitride to strip.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width1
|
float
|
nitride width. |
1
|
width2
|
float
|
silicon width. |
0.5
|
length
|
float
|
taper length. |
20
|
layer_wg
|
LayerSpec
|
nitride layer. |
'WG'
|
layer_nitride
|
LayerSpec
|
strip layer. |
'WGN'
|
width_tip_nitride
|
float
|
tip width for nitride. |
0.15
|
width_tip_silicon
|
float
|
tip width for strip. |
0.15
|
cross_section
|
CrossSectionSpec
|
cross_section specification. |
'strip'
|
Source code in gdsfactory/components/tapers/taper.py
308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 | |

taper_parabolic
taper_parabolic
taper_parabolic(
length: float = 20,
width1: float = 0.5,
width2: float = 5.0,
exp: float = 0.5,
npoints: int = 100,
layer: LayerSpec = "WG",
) -> gf.Component
Returns a parabolic_taper.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
in um. |
20
|
width1
|
float
|
in um. |
0.5
|
width2
|
float
|
in um. |
5.0
|
exp
|
float
|
exponent. |
0.5
|
npoints
|
int
|
number of points. |
100
|
layer
|
LayerSpec
|
layer spec. |
'WG'
|
Source code in gdsfactory/components/tapers/taper_parabolic.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | |

taper_sc_nc
taper_sc_nc(
width1: float = 0.5,
width2: float = 1,
length: float = 20,
layer_wg: LayerSpec = "WG",
layer_nitride: LayerSpec = "WGN",
width_tip_nitride: float = 0.15,
width_tip_silicon: float = 0.15,
cross_section: CrossSectionSpec = "strip",
) -> Component
Taper from strip to nitride.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width1
|
float
|
strip width. |
0.5
|
width2
|
float
|
nitride width. |
1
|
length
|
float
|
taper length. |
20
|
layer_wg
|
LayerSpec
|
strip layer. |
'WG'
|
layer_nitride
|
LayerSpec
|
nitride layer. |
'WGN'
|
width_tip_nitride
|
float
|
tip width for nitride. |
0.15
|
width_tip_silicon
|
float
|
tip width for strip. |
0.15
|
cross_section
|
CrossSectionSpec
|
cross_section specification. |
'strip'
|
Source code in gdsfactory/components/tapers/taper.py
272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 | |

taper_strip_to_ridge
taper_strip_to_ridge(
length: float = 10.0,
width1: float = 0.5,
width2: float = 0.5,
w_slab1: float = 0.15,
w_slab2: float = 6.0,
layer_wg: LayerSpec = "WG",
layer_slab: LayerSpec = "SLAB90",
cross_section: CrossSectionSpec = "strip",
use_slab_port: bool = False,
slab_port_layer: LayerSpec | None = None,
) -> Component
Linear taper from strip to rib.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
taper length (um). |
10.0
|
width1
|
float
|
in um. |
0.5
|
width2
|
float
|
in um. |
0.5
|
w_slab1
|
float
|
slab width in um. |
0.15
|
w_slab2
|
float
|
slab width in um. |
6.0
|
layer_wg
|
LayerSpec
|
for input waveguide. |
'WG'
|
layer_slab
|
LayerSpec
|
for output waveguide with slab. |
'SLAB90'
|
cross_section
|
CrossSectionSpec
|
for input waveguide. |
'strip'
|
use_slab_port
|
bool
|
if True adds a second port for the slab. |
False
|
slab_port_layer
|
LayerSpec | None
|
if specified, overrides the layer for the slab port. |
None
|
__________________________
/ |
_______/____________|______________
/ |
width1 |w_slab1 | w_slab2 width2
______\_____________|______________
\ |
\__________________________
Source code in gdsfactory/components/tapers/taper.py
136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 | |

taper_strip_to_ridge_trenches
taper_strip_to_ridge_trenches(
length: float = 10.0,
width: float = 0.5,
slab_offset: float = 3.0,
trench_width: float = 2.0,
trench_layer: LayerSpec = "DEEP_ETCH",
layer_wg: LayerSpec = "WG",
trench_offset: float = 0.1,
) -> gf.Component
Defines taper using trenches to define the etch.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
in um. |
10.0
|
width
|
float
|
in um. |
0.5
|
slab_offset
|
float
|
in um. |
3.0
|
trench_width
|
float
|
in um. |
2.0
|
trench_layer
|
LayerSpec
|
trench layer. |
'DEEP_ETCH'
|
layer_wg
|
LayerSpec
|
waveguide layer. |
'WG'
|
trench_offset
|
float
|
after waveguide in um. |
0.1
|
Source code in gdsfactory/components/tapers/taper.py
221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 | |

taper_strip_to_slab150
module-attribute
taper_strip_to_slab150 = partial(
taper_strip_to_ridge, layer_slab="SLAB150"
)

taper_w10_l100
module-attribute
taper_w10_l100 = partial(
taper_from_csv,
filepath=data / "taper_strip_0p5_10_100.csv",
)

taper_w10_l150
module-attribute
taper_w10_l150 = partial(
taper_from_csv,
filepath=data / "taper_strip_0p5_10_150.csv",
)

taper_w10_l200
module-attribute
taper_w10_l200 = partial(
taper_from_csv,
filepath=data / "taper_strip_0p5_10_200.csv",
)

taper_w11_l200
module-attribute
taper_w11_l200 = partial(
taper_from_csv,
filepath=data / "taper_strip_0p5_11_200.csv",
)

taper_w12_l200
module-attribute
taper_w12_l200 = partial(
taper_from_csv,
filepath=data / "taper_strip_0p5_12_200.csv",
)

texts
pixel_array
pixel_array(
pixels: str = character_a,
pixel_size: float = 10.0,
layer: LayerSpec = "M1",
) -> Component
Returns a pixel component from a string representing the pixels.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
pixels
|
str
|
string representing the pixels |
character_a
|
pixel_size
|
float
|
width/height for each pixel |
10.0
|
layer
|
LayerSpec
|
layer for each pixel |
'M1'
|
Source code in gdsfactory/components/texts/text_rectangular_font.py
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 | |
![]()
text
text
text(
text: str = "abcd",
size: float = 10.0,
position: Coordinate = (0, 0),
justify: str = "left",
layer: LayerSpec = "WG",
) -> Component
Text shapes.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
text
|
str
|
string. |
'abcd'
|
size
|
float
|
in um of each character. |
10.0
|
position
|
Coordinate
|
x, y position. |
(0, 0)
|
justify
|
str
|
left, right, center. |
'left'
|
layer
|
LayerSpec
|
for the text. |
'WG'
|
Source code in gdsfactory/components/texts/text.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 | |
text_klayout
text_klayout(
text: str = "a",
layer: LayerSpec = "WG",
layers: LayerSpecs | None = None,
bbox_layers: LayerSpecs | None = None,
) -> Component
Returns a text component.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
text
|
str
|
string. |
'a'
|
layer
|
LayerSpec
|
text layer. |
'WG'
|
layers
|
LayerSpecs | None
|
layers for the text. |
None
|
bbox_layers
|
LayerSpecs | None
|
layers for the text bounding box. |
None
|
Source code in gdsfactory/components/texts/text.py
95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 | |
text_lines
text_lines(
text: tuple[str, ...] = ("Chip", "01"),
size: float = 0.4,
layer: LayerSpec = "WG",
) -> Component
Returns a Component from a text lines.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
text
|
tuple[str, ...]
|
list of strings. |
('Chip', '01')
|
size
|
float
|
text size. |
0.4
|
layer
|
LayerSpec
|
text layer. |
'WG'
|
Source code in gdsfactory/components/texts/text.py
73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 | |

text_freetype
text_freetype
text_freetype(
text: str = "a",
size: int = 10,
justify: str = "left",
font: PathType = PATH.font_ocr,
layer: LayerSpec = "WG",
layers: LayerSpecs | None = None,
) -> Component
Returns text Component.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
text
|
str
|
string. |
'a'
|
size
|
int
|
in um. |
10
|
justify
|
str
|
left, right, center. |
'left'
|
font
|
PathType
|
Font face to use. Default DEPLOF does not require additional libraries, otherwise freetype load fonts. You can choose font by name (e.g. "Times New Roman"), or by file OTF or TTF filepath. |
font_ocr
|
layer
|
LayerSpec
|
list of layers to use for the text. |
'WG'
|
layers
|
LayerSpecs | None
|
list of layers to use for the text. |
None
|
Source code in gdsfactory/components/texts/text_freetype.py
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 | |

text_klayout
text_klayout(
text: str = "a",
layer: LayerSpec = "WG",
layers: LayerSpecs | None = None,
bbox_layers: LayerSpecs | None = None,
) -> Component
Returns a text component.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
text
|
str
|
string. |
'a'
|
layer
|
LayerSpec
|
text layer. |
'WG'
|
layers
|
LayerSpecs | None
|
layers for the text. |
None
|
bbox_layers
|
LayerSpecs | None
|
layers for the text bounding box. |
None
|
Source code in gdsfactory/components/texts/text.py
95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 | |

text_lines
text_lines(
text: tuple[str, ...] = ("Chip", "01"),
size: float = 0.4,
layer: LayerSpec = "WG",
) -> Component
Returns a Component from a text lines.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
text
|
tuple[str, ...]
|
list of strings. |
('Chip', '01')
|
size
|
float
|
text size. |
0.4
|
layer
|
LayerSpec
|
text layer. |
'WG'
|
Source code in gdsfactory/components/texts/text.py
73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 | |

text_rectangular
text_rectangular
text_rectangular(
text: str = "abcd",
size: float = 10.0,
position: tuple[float, float] = (0.0, 0.0),
justify: str = "left",
layer: LayerSpec | None = "WG",
layers: LayerSpecs | None = None,
font: Callable[..., dict[str, str]] = rectangular_font,
) -> Component
Pixel based font, guaranteed to be manhattan, without acute angles.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
text
|
str
|
string. |
'abcd'
|
size
|
float
|
pixel size in um. |
10.0
|
position
|
tuple[float, float]
|
coordinate. |
(0.0, 0.0)
|
justify
|
str
|
left, right or center. |
'left'
|
layer
|
LayerSpec | None
|
for text. |
'WG'
|
layers
|
LayerSpecs | None
|
optional for duplicating the text. |
None
|
font
|
Callable[..., dict[str, str]]
|
function that returns dictionary of characters. |
rectangular_font
|
Source code in gdsfactory/components/texts/text_rectangular.py
20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 | |
text_rectangular_multi_layer
text_rectangular_multi_layer(
text: str = "abcd",
layers: LayerSpecs = ("WG", "M1", "M2", "MTOP"),
text_factory: ComponentSpec = text_rectangular,
**kwargs: Any
) -> Component
Returns rectangular text in different layers.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
text
|
str
|
string of text. |
'abcd'
|
layers
|
LayerSpecs
|
list of layers to replicate the text. |
('WG', 'M1', 'M2', 'MTOP')
|
text_factory
|
ComponentSpec
|
function to create the text Components. |
text_rectangular
|
kwargs
|
Any
|
keyword arguments for text_factory. |
{}
|
Other Parameters:
| Name | Type | Description |
|---|---|---|
size |
pixel size. |
|
position |
coordinate. |
|
justify |
left, right or center. |
|
font |
function that returns dictionary of characters. |
Source code in gdsfactory/components/texts/text_rectangular.py
92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 | |

text_rectangular_multi_layer
text_rectangular_multi_layer(
text: str = "abcd",
layers: LayerSpecs = ("WG", "M1", "M2", "MTOP"),
text_factory: ComponentSpec = text_rectangular,
**kwargs: Any
) -> Component
Returns rectangular text in different layers.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
text
|
str
|
string of text. |
'abcd'
|
layers
|
LayerSpecs
|
list of layers to replicate the text. |
('WG', 'M1', 'M2', 'MTOP')
|
text_factory
|
ComponentSpec
|
function to create the text Components. |
text_rectangular
|
kwargs
|
Any
|
keyword arguments for text_factory. |
{}
|
Other Parameters:
| Name | Type | Description |
|---|---|---|
size |
pixel size. |
|
position |
coordinate. |
|
justify |
left, right or center. |
|
font |
function that returns dictionary of characters. |
Source code in gdsfactory/components/texts/text_rectangular.py
92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 | |

vias
via
via
via(
size: Size = (0.7, 0.7),
enclosure: float = 1.0,
layer: LayerSpec = "VIAC",
bbox_layers: Sequence[LayerSpec] | None = None,
bbox_offset: float = 0,
bbox_offsets: Sequence[float] | None = None,
pitch: float = 2,
column_pitch: float | None = None,
row_pitch: float | None = None,
) -> Component
Rectangular via.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
Size
|
in x and y direction. |
(0.7, 0.7)
|
enclosure
|
float
|
inclusion of via. |
1.0
|
layer
|
LayerSpec
|
via layer. |
'VIAC'
|
bbox_layers
|
Sequence[LayerSpec] | None
|
layers for the bounding box. |
None
|
bbox_offset
|
float
|
in um. |
0
|
bbox_offsets
|
Sequence[float] | None
|
List of offsets for each bbox_layer. |
None
|
pitch
|
float
|
pitch between vias. |
2
|
column_pitch
|
float | None
|
Optional pitch between columns of vias. Default is pitch. |
None
|
row_pitch
|
float | None
|
Optional pitch between rows of vias. Default is pitch. |
None
|
Source code in gdsfactory/components/vias/via.py
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 | |
via_circular
via_circular(
radius: float = 0.35,
enclosure: float = 1.0,
layer: LayerSpec = "VIAC",
pitch: float | None = 2,
column_pitch: float | None = None,
row_pitch: float | None = None,
angle_resolution: float = 2.5,
) -> Component
Circular via.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float
|
in um. |
0.35
|
enclosure
|
float
|
inclusion of via in um for the layer above. |
1.0
|
layer
|
LayerSpec
|
via layer. |
'VIAC'
|
pitch
|
float | None
|
pitch between vias. |
2
|
column_pitch
|
float | None
|
Optional pitch between columns of vias. Default is pitch. |
None
|
row_pitch
|
float | None
|
Optional pitch between rows of vias. Default is pitch. |
None
|
angle_resolution
|
float
|
number of degrees per point. |
2.5
|
Source code in gdsfactory/components/vias/via.py
84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 | |

via_chain
Via chain.
via_chain
via_chain(
num_vias: int = 100,
cols: int = 10,
via: ComponentSpec = "via1",
contact: ComponentSpec = "via_stack_m2_m3",
layers_bot: LayerSpecs = ("M1",),
layers_top: LayerSpecs = ("M2",),
offsets_top: tuple[float, ...] = (0,),
offsets_bot: tuple[float, ...] = (0,),
via_min_enclosure: float = 1.0,
min_metal_spacing: float = 1.0,
contact_offset: float = 0.0,
) -> Component
Via chain to extract via resistance.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
num_vias
|
int
|
number of vias. |
100
|
cols
|
int
|
number of column pairs. |
10
|
via
|
ComponentSpec
|
via component. |
'via1'
|
contact
|
ComponentSpec
|
contact component. |
'via_stack_m2_m3'
|
layers_bot
|
LayerSpecs
|
list of bottom layers. |
('M1',)
|
layers_top
|
LayerSpecs
|
list of top layers. |
('M2',)
|
offsets_top
|
tuple[float, ...]
|
list of top layer offsets. |
(0,)
|
offsets_bot
|
tuple[float, ...]
|
list of bottom layer offsets. |
(0,)
|
via_min_enclosure
|
float
|
via_min_enclosure. |
1.0
|
min_metal_spacing
|
float
|
min_metal_spacing. |
1.0
|
contact_offset
|
float
|
contact offset. |
0.0
|
side view
|
┌────────────────────────────────────┐ ┌────────────────────────────────────┐ │ layers_top │ │ │ │ │◄───────────► │ │ └─────────────┬─────┬────────────────┘ └───────────────┬─────┬──────────────┘ │ │ via_enclosure │ │ │ │◄───────────────► │ │ │ │ │ │ │ │ │ │ │width│ │ │ ◄─────► │ │ │ │ │ │ ┌─────────────┴─────┴───────────────────────────────────────────────┴─────┴───────────────┐ │ layers_bot │ │ │ └─────────────────────────────────────────────────────────────────────────────────────────┘ ◄─────────────────────────────────────────────────────────────────────────────────────────► 2e + w + min_metal_spacing + 2e + w |
required |
Source code in gdsfactory/components/vias/via_chain.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 | |

via_circular
via_circular(
radius: float = 0.35,
enclosure: float = 1.0,
layer: LayerSpec = "VIAC",
pitch: float | None = 2,
column_pitch: float | None = None,
row_pitch: float | None = None,
angle_resolution: float = 2.5,
) -> Component
Circular via.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
radius
|
float
|
in um. |
0.35
|
enclosure
|
float
|
inclusion of via in um for the layer above. |
1.0
|
layer
|
LayerSpec
|
via layer. |
'VIAC'
|
pitch
|
float | None
|
pitch between vias. |
2
|
column_pitch
|
float | None
|
Optional pitch between columns of vias. Default is pitch. |
None
|
row_pitch
|
float | None
|
Optional pitch between rows of vias. Default is pitch. |
None
|
angle_resolution
|
float
|
number of degrees per point. |
2.5
|
Source code in gdsfactory/components/vias/via.py
84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 | |

via_corner
via_corner
via_corner(
cross_section: MultiCrossSectionAngleSpec = (
(metal2, (0, 180)),
(metal3, (90, 270)),
),
vias: tuple[ComponentSpec] = ("via1",),
layers_labels: tuple[str, ...] = ("m2", "m3"),
**kwargs: Any
) -> gf.Component
Returns Corner via.
Use in place of wire_corner to route between two layers.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
cross_section
|
MultiCrossSectionAngleSpec
|
list of cross_section, orientation pairs. |
((metal2, (0, 180)), (metal3, (90, 270)))
|
vias
|
tuple[ComponentSpec]
|
vias to use to fill the rectangles. |
('via1',)
|
layers_labels
|
tuple[str, ...]
|
Labels to use for each layer. |
('m2', 'm3')
|
kwargs
|
Any
|
cross_section settings. |
{}
|
Source code in gdsfactory/components/vias/via_corner.py
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 | |

via_stack
via_stack
via_stack(
size: Size = (11.0, 11.0),
layers: LayerSpecs = ("M1", "M2", "MTOP"),
layer_offsets: (
Floats
| tuple[float | tuple[float, float], ...]
| None
) = None,
vias: Sequence[ComponentSpec | None] = (
"via1",
"via2",
None,
),
layer_to_port_orientations: (
dict[LayerSpec, list[int]] | None
) = None,
correct_size: bool = False,
slot_horizontal: bool = False,
slot_vertical: bool = False,
port_orientations: Ints | None = (180, 90, 0, -90),
) -> Component
Rectangular via array stack.
You can use it to connect different metal layers or metals to silicon. You can use the naming convention via_stack_layerSource_layerDestination contains 4 ports (e1, e2, e3, e4)
also know as Via array http://www.vlsi-expert.com/2017/12/vias.html
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
size
|
Size
|
of the layers. |
(11.0, 11.0)
|
layers
|
LayerSpecs
|
layers on which to draw rectangles. |
('M1', 'M2', 'MTOP')
|
layer_offsets
|
Floats | tuple[float | tuple[float, float], ...] | None
|
Optional offsets for each layer with respect to size. positive grows, negative shrinks the size. If a tuple, it is the offset in x and y. |
None
|
vias
|
Sequence[ComponentSpec | None]
|
vias to use to fill the rectangles. |
('via1', 'via2', None)
|
layer_to_port_orientations
|
dict[LayerSpec, list[int]] | None
|
dictionary of layer to port_orientations. |
None
|
correct_size
|
bool
|
if True, if the specified dimensions are too small it increases them to the minimum possible to fit a via. |
False
|
slot_horizontal
|
bool
|
if True, then vias are horizontal. |
False
|
slot_vertical
|
bool
|
if True, then vias are vertical. |
False
|
port_orientations
|
Ints | None
|
list of port_orientations to add. None does not add ports. |
(180, 90, 0, -90)
|
Source code in gdsfactory/components/vias/via_stack.py
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 | |
via_stack_corner45
via_stack_corner45(
width: float = 10,
layers: Sequence[LayerSpec | None] = (
"M1",
"M2",
"MTOP",
),
layer_offsets: Floats | None = None,
vias: Sequence[ComponentSpec | None] = (
"via1",
"via2",
None,
),
layer_port: LayerSpec | None = None,
correct_size: bool = False,
) -> Component
Rectangular via array stack at a 45 degree angle.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
of the corner45. |
10
|
layers
|
Sequence[LayerSpec | None]
|
layers on which to draw rectangles. |
('M1', 'M2', 'MTOP')
|
layer_offsets
|
Floats | None
|
Optional offsets for each layer with respect to size. positive grows, negative shrinks the size. |
None
|
vias
|
Sequence[ComponentSpec | None]
|
vias to use to fill the rectangles. |
('via1', 'via2', None)
|
layer_port
|
LayerSpec | None
|
if None assumes port is on the last layer. |
None
|
correct_size
|
bool
|
if True, if the specified dimensions are too small it increases them to the minimum possible to fit a via. |
False
|
Source code in gdsfactory/components/vias/via_stack.py
269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 | |
via_stack_corner45_extended
via_stack_corner45_extended(
corner: ComponentSpec = "via_stack_corner45",
via_stack: ComponentSpec = "via_stack",
width: float = 3,
length: float = 10,
) -> Component
Rectangular via array stack at a 45 degree angle.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
corner
|
ComponentSpec
|
corner component. |
'via_stack_corner45'
|
via_stack
|
ComponentSpec
|
for the via stack. |
'via_stack'
|
width
|
float
|
of the corner45. |
3
|
length
|
float
|
of the straight. |
10
|
Source code in gdsfactory/components/vias/via_stack.py
411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 | |

via_stack_corner45
via_stack_corner45(
width: float = 10,
layers: Sequence[LayerSpec | None] = (
"M1",
"M2",
"MTOP",
),
layer_offsets: Floats | None = None,
vias: Sequence[ComponentSpec | None] = (
"via1",
"via2",
None,
),
layer_port: LayerSpec | None = None,
correct_size: bool = False,
) -> Component
Rectangular via array stack at a 45 degree angle.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
of the corner45. |
10
|
layers
|
Sequence[LayerSpec | None]
|
layers on which to draw rectangles. |
('M1', 'M2', 'MTOP')
|
layer_offsets
|
Floats | None
|
Optional offsets for each layer with respect to size. positive grows, negative shrinks the size. |
None
|
vias
|
Sequence[ComponentSpec | None]
|
vias to use to fill the rectangles. |
('via1', 'via2', None)
|
layer_port
|
LayerSpec | None
|
if None assumes port is on the last layer. |
None
|
correct_size
|
bool
|
if True, if the specified dimensions are too small it increases them to the minimum possible to fit a via. |
False
|
Source code in gdsfactory/components/vias/via_stack.py
269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 | |

via_stack_corner45_extended
via_stack_corner45_extended(
corner: ComponentSpec = "via_stack_corner45",
via_stack: ComponentSpec = "via_stack",
width: float = 3,
length: float = 10,
) -> Component
Rectangular via array stack at a 45 degree angle.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
corner
|
ComponentSpec
|
corner component. |
'via_stack_corner45'
|
via_stack
|
ComponentSpec
|
for the via stack. |
'via_stack'
|
width
|
float
|
of the corner45. |
3
|
length
|
float
|
of the straight. |
10
|
Source code in gdsfactory/components/vias/via_stack.py
411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 | |

via_stack_heater_mtop_mini
module-attribute
via_stack_heater_mtop_mini = partial(
via_stack_heater_mtop, size=(4, 4)
)

via_stack_m1_m3
module-attribute
via_stack_m1_m3 = partial(
via_stack,
layers=("M1", "M2", "MTOP"),
vias=("via1", "via2", None),
)

via_stack_m1_mtop
module-attribute
via_stack_m1_mtop = partial(
via_stack,
layers=("M1", "M2", "MTOP"),
vias=("via1", "via2", None),
)

via_stack_m2_m3
module-attribute
via_stack_m2_m3 = partial(
via_stack, layers=("M2", "MTOP"), vias=("via2", None)
)

via_stack_npp_m1
module-attribute
via_stack_npp_m1 = partial(
via_stack,
layers=("WG", "NPP", "M1"),
vias=(None, None, "viac"),
)

via_stack_slab_m1
module-attribute
via_stack_slab_m1 = partial(
via_stack,
layers=("SLAB90", "M1"),
vias=("viac", "via1"),
)

via_stack_slab_m1_horizontal
module-attribute
via_stack_slab_m1_horizontal = partial(
via_stack_slab_m1, slot_horizontal=True
)

via_stack_slab_m2
module-attribute
via_stack_slab_m2 = partial(
via_stack,
layers=("SLAB90", "M1", "M2"),
vias=("viac", "via1", None),
)

via_stack_slab_npp_m3
module-attribute
via_stack_slab_npp_m3 = partial(
via_stack,
layers=("SLAB90", "NPP", "M1"),
vias=(None, None, "viac"),
)

via_stack_with_offset
via_stack_with_offset
via_stack_with_offset(
layers: LayerSpecs = ("PPP", "M1"),
size: Size | None = (10, 10),
sizes: Sequence[Size] | None = None,
layer_offsets: Sequence[float] | None = None,
vias: Sequence[ComponentSpec | None] = (None, "viac"),
offsets: Sequence[float] | None = None,
layer_to_port_orientations: (
dict[LayerSpec, list[int]] | None
) = None,
) -> Component
Rectangular layer transition with offset between layers.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
layers
|
LayerSpecs
|
layer specs between vias. |
('PPP', 'M1')
|
size
|
Size | None
|
for all vias array. |
(10, 10)
|
sizes
|
Sequence[Size] | None
|
Optional size for each via array. Overrides size. |
None
|
layer_offsets
|
Sequence[float] | None
|
Optional offsets for each layer with respect to size. positive grows, negative shrinks the size. |
None
|
vias
|
Sequence[ComponentSpec | None]
|
via spec for previous layer. None for no via. |
(None, 'viac')
|
offsets
|
Sequence[float] | None
|
optional offset for each layer relatively to the previous one. By default it only offsets by size[1] if there is a via. |
None
|
layer_to_port_orientations
|
dict[LayerSpec, list[int]] | None
|
Optional dictionary with layer to port orientations. |
None
|
Source code in gdsfactory/components/vias/via_stack_with_offset.py
20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 | |

via_stack_with_offset_m1_m3
module-attribute
via_stack_with_offset_m1_m3 = partial(
via_stack_with_offset,
layers=("M1", "M2", "MTOP"),
vias=(None, "via1", "via2"),
)

via_stack_with_offset_ppp_m1
module-attribute
via_stack_with_offset_ppp_m1 = partial(
via_stack_with_offset,
layers=("PPP", "M1"),
vias=(None, "viac"),
)

waveguides
crossing
crossing(arm: ComponentSpec = crossing_arm) -> gf.Component
Waveguide crossing.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
arm
|
ComponentSpec
|
arm spec. |
crossing_arm
|
Source code in gdsfactory/components/waveguides/crossing_waveguide.py
86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 | |

crossing45
crossing45(
crossing: ComponentSpec = crossing,
port_spacing: float = 40.0,
dx: Delta | None = None,
alpha: float = 0.08,
npoints: int = 101,
cross_section: CrossSectionSpec = "strip",
cross_section_bends: CrossSectionSpec = "strip",
) -> Component
Returns 45deg crossing with bends.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
crossing
|
ComponentSpec
|
crossing function. |
crossing
|
port_spacing
|
float
|
target I/O port spacing. |
40.0
|
dx
|
Delta | None
|
target length. |
None
|
alpha
|
float
|
optimization parameter. diminish it for tight bends, increase it if raises assertion angle errors |
0.08
|
npoints
|
int
|
number of points. |
101
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
cross_section_bends
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
The 45 Degree crossing CANNOT be kept as an SRef since we only allow for multiples of 90Deg rotations in SRef.
---- ----
\ /
X
/ \
--- ----
Source code in gdsfactory/components/waveguides/crossing_waveguide.py
205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 | |

crossing_etched
crossing_etched(
width: float = 0.5,
r1: float = 3.0,
r2: float = 1.1,
w: float = 1.2,
L: float = 3.4,
layer_wg: LayerSpec = "WG",
layer_slab: LayerSpec = "SLAB150",
) -> Component
Waveguide crossing.
Full crossing has to be on WG layer (to start with a 220nm slab). Then we etch the ellipses down to 150nm slabs and we keep linear taper at 220nm.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float
|
input waveguides width. |
0.5
|
r1
|
float
|
radii. |
3.0
|
r2
|
float
|
radii. |
1.1
|
w
|
float
|
wide width. |
1.2
|
L
|
float
|
length. |
3.4
|
layer_wg
|
LayerSpec
|
waveguide layer. |
'WG'
|
layer_slab
|
LayerSpec
|
shallow etch layer. |
'SLAB150'
|
Source code in gdsfactory/components/waveguides/crossing_waveguide.py
131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 | |

crossing_linear_taper
crossing_linear_taper(
width1: float = 2.5,
width2: float = 0.5,
length: float = 3,
cross_section: CrossSectionSpec = "strip",
taper: ComponentSpec = "taper",
) -> Component
Returns Crossing based on a taper.
The default is a dummy taper.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width1
|
float
|
input width. |
2.5
|
width2
|
float
|
output width. |
0.5
|
length
|
float
|
taper length. |
3
|
cross_section
|
CrossSectionSpec
|
cross_section spec. |
'strip'
|
taper
|
ComponentSpec
|
taper spec. |
'taper'
|
Source code in gdsfactory/components/waveguides/crossing_waveguide.py
106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 | |

straight
Straight waveguide.
straight
straight(
length: float = 10.0,
npoints: int = 2,
cross_section: CrossSectionSpec = "strip",
width: float | None = None,
) -> Component
Returns a Straight waveguide.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
straight length (um). |
10.0
|
npoints
|
int
|
number of points. |
2
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string or dict). |
'strip'
|
width
|
float | None
|
width of the waveguide. If None, it will use the width of the cross_section. |
None
|
Source code in gdsfactory/components/waveguides/straight.py
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 | |
straight_all_angle
straight_all_angle(
length: float = 10.0,
npoints: int = 2,
cross_section: CrossSectionSpec = "strip",
width: float | None = None,
) -> ComponentAllAngle
Returns a Straight waveguide with offgrid ports.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
straight length (um). |
10.0
|
npoints
|
int
|
number of points. |
2
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string or dict). |
'strip'
|
width
|
float | None
|
width of the waveguide. If None, it will use the width of the cross_section. |
None
|
Source code in gdsfactory/components/waveguides/straight.py
46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 | |
straight_array
straight_array(
n: int = 4,
spacing: float = 4.0,
length: float = 10.0,
cross_section: CrossSectionSpec = "strip",
) -> Component
Array of straights connected with grating couplers.
useful to align the 4 corners of the chip
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
n
|
int
|
number of straights. |
4
|
spacing
|
float
|
edge to edge straight spacing. |
4.0
|
length
|
float
|
straight length (um). |
10.0
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string or dict). |
'strip'
|
Source code in gdsfactory/components/waveguides/straight.py
78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 | |
wire_straight
wire_straight(
length: float = 10.0,
npoints: int = 2,
cross_section: CrossSectionSpec = "metal_routing",
width: float | None = None,
) -> Component
Returns a Straight waveguide.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
straight length (um). |
10.0
|
npoints
|
int
|
number of points. |
2
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string or dict). |
'metal_routing'
|
width
|
float | None
|
width of the waveguide. If None, it will use the width of the cross_section. |
None
|
Source code in gdsfactory/components/waveguides/straight.py
107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 | |

straight_all_angle
straight_all_angle(
length: float = 10.0,
npoints: int = 2,
cross_section: CrossSectionSpec = "strip",
width: float | None = None,
) -> ComponentAllAngle
Returns a Straight waveguide with offgrid ports.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
straight length (um). |
10.0
|
npoints
|
int
|
number of points. |
2
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string or dict). |
'strip'
|
width
|
float | None
|
width of the waveguide. If None, it will use the width of the cross_section. |
None
|
Source code in gdsfactory/components/waveguides/straight.py
46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 | |
import gdsfactory as gf
gf.gpdk.PDK.activate()
c = gf.components.straight_all_angle(length=10, npoints=2, cross_section='strip').copy()
c.draw_ports()
c.plot()
straight_array
straight_array(
n: int = 4,
spacing: float = 4.0,
length: float = 10.0,
cross_section: CrossSectionSpec = "strip",
) -> Component
Array of straights connected with grating couplers.
useful to align the 4 corners of the chip
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
n
|
int
|
number of straights. |
4
|
spacing
|
float
|
edge to edge straight spacing. |
4.0
|
length
|
float
|
straight length (um). |
10.0
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string or dict). |
'strip'
|
Source code in gdsfactory/components/waveguides/straight.py
78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 | |

straight_heater_doped_rib
straight_heater_doped_rib(
length: float = 320.0,
nsections: int = 3,
cross_section: CrossSectionSpec = "strip_rib_tip",
cross_section_heater: CrossSectionSpec = "rib_heater_doped",
via_stack: (
ComponentSpec | None
) = "via_stack_slab_npp_m3",
via_stack_metal: (
ComponentSpec | None
) = "via_stack_m1_mtop",
via_stack_metal_size: Size = (10.0, 10.0),
via_stack_size: Size = (10.0, 10.0),
taper: ComponentSpec | None = "taper_cross_section",
heater_width: float = 2.0,
heater_gap: float = 0.8,
via_stack_gap: float = 0.0,
width: float = 0.5,
xoffset_tip1: float = 0.2,
xoffset_tip2: float = 0.4,
) -> Component
Returns a doped thermal phase shifter.
dimensions from https://doi.org/10.1364/OE.27.010456
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
of the waveguide in um. |
320.0
|
nsections
|
int
|
between via_stacks. |
3
|
cross_section
|
CrossSectionSpec
|
for the input/output ports. |
'strip_rib_tip'
|
cross_section_heater
|
CrossSectionSpec
|
for the heater. |
'rib_heater_doped'
|
via_stack
|
ComponentSpec | None
|
optional function to connect the heater strip. |
'via_stack_slab_npp_m3'
|
via_stack_metal
|
ComponentSpec | None
|
function to connect the metal area. |
'via_stack_m1_mtop'
|
via_stack_metal_size
|
Size
|
x, y size in um. |
(10.0, 10.0)
|
via_stack_size
|
Size
|
x, y size in um. |
(10.0, 10.0)
|
taper
|
ComponentSpec | None
|
optional taper spec. |
'taper_cross_section'
|
heater_width
|
float
|
in um. |
2.0
|
heater_gap
|
float
|
in um. |
0.8
|
via_stack_gap
|
float
|
from edge of via_stack to waveguide. |
0.0
|
width
|
float
|
waveguide width on the ridge. |
0.5
|
xoffset_tip1
|
float
|
distance in um from input taper to via_stack. |
0.2
|
xoffset_tip2
|
float
|
distance in um from output taper to via_stack.
|
0.4
|
Source code in gdsfactory/components/waveguides/straight_heater_doped.py
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 | |

straight_heater_doped_strip
straight_heater_doped_strip(
length: float = 320.0,
nsections: int = 3,
cross_section: CrossSectionSpec = "strip_heater_doped",
cross_section_heater: CrossSectionSpec = "rib_heater_doped",
via_stack: ComponentSpec | None = "via_stack_npp_m1",
via_stack_metal: (
ComponentSpec | None
) = "via_stack_m1_mtop",
via_stack_metal_size: Size = (10.0, 10.0),
via_stack_size: Size = (10.0, 10.0),
taper: ComponentSpec | None = "taper_cross_section",
heater_width: float = 2.0,
heater_gap: float = 0.8,
via_stack_gap: float = 0.0,
width: float = 0.5,
xoffset_tip1: float = 0.2,
xoffset_tip2: float = 0.4,
) -> Component
Top view.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
of the waveguide in um. |
320.0
|
nsections
|
int
|
between via_stacks. |
3
|
cross_section
|
CrossSectionSpec
|
for the input/output ports. |
'strip_heater_doped'
|
cross_section_heater
|
CrossSectionSpec
|
for the heater. |
'rib_heater_doped'
|
via_stack
|
ComponentSpec | None
|
optional function to connect the heater strip. |
'via_stack_npp_m1'
|
via_stack_metal
|
ComponentSpec | None
|
function to connect the metal area. |
'via_stack_m1_mtop'
|
via_stack_metal_size
|
Size
|
x, y size in um. |
(10.0, 10.0)
|
via_stack_size
|
Size
|
x, y size in um. |
(10.0, 10.0)
|
taper
|
ComponentSpec | None
|
optional taper spec. |
'taper_cross_section'
|
heater_width
|
float
|
in um. |
2.0
|
heater_gap
|
float
|
in um. |
0.8
|
via_stack_gap
|
float
|
from edge of via_stack to waveguide. |
0.0
|
width
|
float
|
waveguide width on the ridge. |
0.5
|
xoffset_tip1
|
float
|
distance in um from input taper to via_stack. |
0.2
|
xoffset_tip2
|
float
|
distance in um from output taper to via_stack.
<-|--------|---------------------------------> | | length_section |<---------------------------> length_via_stack |<------>| |__|____ /| |__| | / |viastack| |viastack | \ | size |___| | |_|___|_| | | cross_section_heater| | | | | | |____| |
0.4
|
cross_section
|<------width------>|
____________ ___________________ ______________
| | | undoped Si | | |
|layer_heater| | intrinsic region |<----------->| layer_heater |
|____________| |___________________| |______________|
<------------>
heater_gap heater_width
Source code in gdsfactory/components/waveguides/straight_heater_doped.py
192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 | |

straight_heater_meander
straight_heater_meander
straight_heater_meander(
length: float = 300.0,
spacing: float = 2.0,
cross_section: CrossSectionSpec = "strip",
heater_width: float = 2.5,
extension_length: float = 15.0,
layer_heater: LayerSpec = "HEATER",
radius: float | None = None,
via_stack: (
ComponentSpec | None
) = "via_stack_heater_mtop",
port_orientation1: float | None = None,
port_orientation2: float | None = None,
heater_taper_length: float = 10.0,
straight_widths: Floats | None = None,
taper_length: float = 10.0,
n: int | None = 3,
) -> Component
Returns a meander based heater.
based on SungWon Chung, Makoto Nakai, and Hossein Hashemi, Low-power thermo-optic silicon modulator for large-scale photonic integrated systems Opt. Express 27, 13430-13459 (2019) https://www.osapublishing.org/oe/abstract.cfm?URI=oe-27-9-13430
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
total length of the optical path. |
300.0
|
spacing
|
float
|
waveguide spacing (center to center). |
2.0
|
cross_section
|
CrossSectionSpec
|
for waveguide. |
'strip'
|
heater_width
|
float
|
for heater. |
2.5
|
extension_length
|
float
|
of input and output optical ports. |
15.0
|
layer_heater
|
LayerSpec
|
for top heater, if None, it does not add a heater. |
'HEATER'
|
radius
|
float | None
|
for the meander bends. Defaults to cross_section radius. |
None
|
via_stack
|
ComponentSpec | None
|
for the heater to via_stack metal. |
'via_stack_heater_mtop'
|
port_orientation1
|
float | None
|
in degrees. None adds all orientations. |
None
|
port_orientation2
|
float | None
|
in degrees. None adds all orientations. |
None
|
heater_taper_length
|
float
|
minimizes current concentrations from heater to via_stack. |
10.0
|
straight_widths
|
Floats | None
|
widths of the straight sections. |
None
|
taper_length
|
float
|
from the cross_section. |
10.0
|
n
|
int | None
|
number of straight sections. |
3
|
Source code in gdsfactory/components/waveguides/straight_heater_meander.py
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 | |

straight_heater_meander_doped
Straight heater meander doped.
straight_heater_meander_doped
straight_heater_meander_doped(
length: float = 300.0,
spacing: float = 2.0,
cross_section: CrossSectionSpec = "strip",
heater_width: float = 1.5,
extension_length: float = 15.0,
layers_doping: LayerSpecs = ("P", "PP", "PPP"),
radius: float = 5.0,
via_stack: ComponentSpec | None = _via_stack,
port_orientation1: float | None = None,
port_orientation2: float | None = None,
straight_widths: Floats = (0.8, 0.9, 0.8),
taper_length: float = 10,
) -> Component
Returns a meander based heater.
based on SungWon Chung, Makoto Nakai, and Hossein Hashemi, Low-power thermo-optic silicon modulator for large-scale photonic integrated systems Opt. Express 27, 13430-13459 (2019) https://www.osapublishing.org/oe/abstract.cfm?URI=oe-27-9-13430
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
total length of the optical path. |
300.0
|
spacing
|
float
|
waveguide spacing (center to center). |
2.0
|
cross_section
|
CrossSectionSpec
|
for waveguide. |
'strip'
|
heater_width
|
float
|
for heater. |
1.5
|
extension_length
|
float
|
of input and output optical ports. |
15.0
|
layers_doping
|
LayerSpecs
|
doping layers to be used for heater. |
('P', 'PP', 'PPP')
|
radius
|
float
|
for the meander bends. |
5.0
|
via_stack
|
ComponentSpec | None
|
for the heater to via_stack metal. |
_via_stack
|
port_orientation1
|
float | None
|
in degrees. None adds all orientations. |
None
|
port_orientation2
|
float | None
|
in degrees. None adds all orientations. |
None
|
straight_widths
|
Floats
|
width of the straight sections. |
(0.8, 0.9, 0.8)
|
taper_length
|
float
|
from the cross_section. |
10
|
Source code in gdsfactory/components/waveguides/straight_heater_meander_doped.py
42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 | |

straight_heater_metal
straight_heater_metal_simple
straight_heater_metal_simple(
length: float = 320.0,
cross_section_heater: CrossSectionSpec = "heater_metal",
cross_section_waveguide_heater: CrossSectionSpec = "strip_heater_metal",
via_stack: (
ComponentSpec | None
) = "via_stack_heater_mtop",
port_orientation1: int | None = None,
port_orientation2: int | None = None,
heater_taper_length: float = 5.0,
ohms_per_square: float | None = None,
) -> Component
Returns a thermal phase shifter that has properly fixed electrical connectivity to extract a suitable electrical netlist and models.
dimensions from https://doi.org/10.1364/OE.27.010456.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
of the waveguide. |
320.0
|
length_undercut
|
length of each undercut section. |
required | |
cross_section_heater
|
CrossSectionSpec
|
for heated sections. heater metal only. |
'heater_metal'
|
cross_section_waveguide_heater
|
CrossSectionSpec
|
for heated sections. |
'strip_heater_metal'
|
via_stack
|
ComponentSpec | None
|
via stack. |
'via_stack_heater_mtop'
|
port_orientation1
|
int | None
|
left via stack port orientation. None adds all orientations. |
None
|
port_orientation2
|
int | None
|
right via stack port orientation. None adds all orientations. |
None
|
heater_taper_length
|
float
|
minimizes current concentrations from heater to via_stack. |
5.0
|
ohms_per_square
|
float | None
|
to calculate resistance. |
None
|
Source code in gdsfactory/components/waveguides/straight_heater_metal.py
180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 | |
straight_heater_metal_undercut
straight_heater_metal_undercut(
length: float = 320.0,
length_undercut_spacing: float = 6.0,
length_undercut: float = 30.0,
length_straight: float = 0.1,
length_straight_input: float = 15.0,
cross_section: CrossSectionSpec = "strip",
cross_section_heater: CrossSectionSpec = "heater_metal",
cross_section_waveguide_heater: CrossSectionSpec = "strip_heater_metal",
cross_section_heater_undercut: CrossSectionSpec = "strip_heater_metal_undercut",
with_undercut: bool = True,
via_stack: (
ComponentSpec | None
) = "via_stack_heater_mtop",
port_orientation1: int | None = None,
port_orientation2: int | None = None,
heater_taper_length: float = 5.0,
ohms_per_square: float | None = None,
) -> Component
Returns a thermal phase shifter.
dimensions from https://doi.org/10.1364/OE.27.010456
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
of the waveguide. |
320.0
|
length_undercut_spacing
|
float
|
from undercut regions. |
6.0
|
length_undercut
|
float
|
length of each undercut section. |
30.0
|
length_straight
|
float
|
length of the straight waveguide. |
0.1
|
length_straight_input
|
float
|
from input port to where trenches start. |
15.0
|
cross_section
|
CrossSectionSpec
|
for waveguide ports. |
'strip'
|
cross_section_heater
|
CrossSectionSpec
|
for heated sections. heater metal only. |
'heater_metal'
|
cross_section_waveguide_heater
|
CrossSectionSpec
|
for heated sections. |
'strip_heater_metal'
|
cross_section_heater_undercut
|
CrossSectionSpec
|
for heated sections with undercut. |
'strip_heater_metal_undercut'
|
with_undercut
|
bool
|
isolation trenches for higher efficiency. |
True
|
via_stack
|
ComponentSpec | None
|
via stack. |
'via_stack_heater_mtop'
|
port_orientation1
|
int | None
|
left via stack port orientation. None adds all orientations. |
None
|
port_orientation2
|
int | None
|
right via stack port orientation. None adds all orientations. |
None
|
heater_taper_length
|
float
|
minimizes current concentrations from heater to via_stack. |
5.0
|
ohms_per_square
|
float | None
|
to calculate resistance. |
None
|
Source code in gdsfactory/components/waveguides/straight_heater_metal.py
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 | |

straight_heater_metal_90_90
module-attribute
straight_heater_metal_90_90 = partial(
straight_heater_metal,
port_orientation1=90,
port_orientation2=90,
)

straight_heater_metal_simple
straight_heater_metal_simple(
length: float = 320.0,
cross_section_heater: CrossSectionSpec = "heater_metal",
cross_section_waveguide_heater: CrossSectionSpec = "strip_heater_metal",
via_stack: (
ComponentSpec | None
) = "via_stack_heater_mtop",
port_orientation1: int | None = None,
port_orientation2: int | None = None,
heater_taper_length: float = 5.0,
ohms_per_square: float | None = None,
) -> Component
Returns a thermal phase shifter that has properly fixed electrical connectivity to extract a suitable electrical netlist and models.
dimensions from https://doi.org/10.1364/OE.27.010456.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
of the waveguide. |
320.0
|
length_undercut
|
length of each undercut section. |
required | |
cross_section_heater
|
CrossSectionSpec
|
for heated sections. heater metal only. |
'heater_metal'
|
cross_section_waveguide_heater
|
CrossSectionSpec
|
for heated sections. |
'strip_heater_metal'
|
via_stack
|
ComponentSpec | None
|
via stack. |
'via_stack_heater_mtop'
|
port_orientation1
|
int | None
|
left via stack port orientation. None adds all orientations. |
None
|
port_orientation2
|
int | None
|
right via stack port orientation. None adds all orientations. |
None
|
heater_taper_length
|
float
|
minimizes current concentrations from heater to via_stack. |
5.0
|
ohms_per_square
|
float | None
|
to calculate resistance. |
None
|
Source code in gdsfactory/components/waveguides/straight_heater_metal.py
180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 | |

straight_heater_metal_undercut
straight_heater_metal_undercut(
length: float = 320.0,
length_undercut_spacing: float = 6.0,
length_undercut: float = 30.0,
length_straight: float = 0.1,
length_straight_input: float = 15.0,
cross_section: CrossSectionSpec = "strip",
cross_section_heater: CrossSectionSpec = "heater_metal",
cross_section_waveguide_heater: CrossSectionSpec = "strip_heater_metal",
cross_section_heater_undercut: CrossSectionSpec = "strip_heater_metal_undercut",
with_undercut: bool = True,
via_stack: (
ComponentSpec | None
) = "via_stack_heater_mtop",
port_orientation1: int | None = None,
port_orientation2: int | None = None,
heater_taper_length: float = 5.0,
ohms_per_square: float | None = None,
) -> Component
Returns a thermal phase shifter.
dimensions from https://doi.org/10.1364/OE.27.010456
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
of the waveguide. |
320.0
|
length_undercut_spacing
|
float
|
from undercut regions. |
6.0
|
length_undercut
|
float
|
length of each undercut section. |
30.0
|
length_straight
|
float
|
length of the straight waveguide. |
0.1
|
length_straight_input
|
float
|
from input port to where trenches start. |
15.0
|
cross_section
|
CrossSectionSpec
|
for waveguide ports. |
'strip'
|
cross_section_heater
|
CrossSectionSpec
|
for heated sections. heater metal only. |
'heater_metal'
|
cross_section_waveguide_heater
|
CrossSectionSpec
|
for heated sections. |
'strip_heater_metal'
|
cross_section_heater_undercut
|
CrossSectionSpec
|
for heated sections with undercut. |
'strip_heater_metal_undercut'
|
with_undercut
|
bool
|
isolation trenches for higher efficiency. |
True
|
via_stack
|
ComponentSpec | None
|
via stack. |
'via_stack_heater_mtop'
|
port_orientation1
|
int | None
|
left via stack port orientation. None adds all orientations. |
None
|
port_orientation2
|
int | None
|
right via stack port orientation. None adds all orientations. |
None
|
heater_taper_length
|
float
|
minimizes current concentrations from heater to via_stack. |
5.0
|
ohms_per_square
|
float | None
|
to calculate resistance. |
None
|
Source code in gdsfactory/components/waveguides/straight_heater_metal.py
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 | |

straight_heater_metal_undercut_90_90
module-attribute
straight_heater_metal_undercut_90_90 = partial(
straight_heater_metal_undercut,
port_orientation1=90,
port_orientation2=90,
)

straight_piecewise
straight_piecewise
straight_piecewise(
x: Sequence[float] | Path,
widths: Sequence[float],
layer: LayerSpec,
sections: Sequence[Section] | None = None,
port_names: tuple[str | None, str | None] = (
"o1",
"o2",
),
name: str = "core",
**kwargs: Any
) -> Component
Create a component with a piecewise-defined straight waveguide.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
x
|
Sequence[float] | Path
|
X coordinates or a custom Path object. |
required |
widths
|
Sequence[float]
|
Waveguide widths at each corresponding x. |
required |
layer
|
LayerSpec
|
Layer to extrude. |
required |
sections
|
Sequence[Section] | None
|
Additional cross-section sections to extrude. |
None
|
port_names
|
tuple[str | None, str | None]
|
Port names for the waveguide. |
('o1', 'o2')
|
name
|
str
|
Name for the core (main) Section. |
'core'
|
**kwargs
|
Any
|
Additional keyword arguments for the Section. |
{}
|
Source code in gdsfactory/components/waveguides/straight_piecewise.py
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 | |
import gdsfactory as gf
gf.gpdk.PDK.activate()
c = gf.components.straight_piecewise(port_names=('o1', 'o2'), name='core').copy()
c.draw_ports()
c.plot()
straight_pin
Straight Doped PIN waveguide.
straight_pin
straight_pin(
length: float = 500.0,
cross_section: CrossSectionSpec = pin,
via_stack: ComponentSpec = "via_stack_slab_m3",
via_stack_width: float = 10.0,
via_stack_spacing: float = 2,
taper: ComponentSpec | None = "taper_strip_to_ridge",
) -> Component
Returns rib waveguide with doping and via_stacks used for PN and PIN modulators.
For PIN: https://doi.org/10.1364/OE.26.029983
500um length for PI phase shift https://ieeexplore.ieee.org/document/8268112
to go beyond 2PI, you will need at least 1mm https://ieeexplore.ieee.org/document/8853396/
For PN: Typical lengths in practice are 2-5mm depending on doping,engineering and application: https://opg.optica.org/oe/fulltext.cfm?uri=oe-21-25-30350&id=275107 https://opg.optica.org/oe/fulltext.cfm?uri=oe-20-11-12014&id=233271
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
of the waveguide. |
500.0
|
cross_section
|
CrossSectionSpec
|
for the waveguide. |
pin
|
via_stack
|
ComponentSpec
|
for the via_stacks. |
'via_stack_slab_m3'
|
via_stack_width
|
float
|
width of the via_stack. |
10.0
|
via_stack_spacing
|
float
|
spacing between via_stacks. |
2
|
taper
|
ComponentSpec | None
|
optional taper. |
'taper_strip_to_ridge'
|
Source code in gdsfactory/components/waveguides/straight_pin.py
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 | |

straight_pin_slot
Straight Doped PIN waveguide.
straight_pin_slot
straight_pin_slot(
length: float = 500.0,
cross_section: CrossSectionSpec = "pin",
via_stack: ComponentSpec | None = "via_stack_m1_mtop",
via_stack_width: float = 10.0,
via_stack_slab: (
ComponentSpec | None
) = "via_stack_slab_m1_horizontal",
via_stack_slab_top: ComponentSpec | None = None,
via_stack_slab_bot: ComponentSpec | None = None,
via_stack_slab_width: float | None = None,
via_stack_spacing: float = 3.0,
via_stack_slab_spacing: float = 2.0,
taper: ComponentSpec | None = "taper_strip_to_ridge",
width: float | None = None,
) -> Component
Returns a PIN straight waveguide with slotted via.
https://doi.org/10.1364/OE.26.029983
500um length for PI phase shift https://ieeexplore.ieee.org/document/8268112
to go beyond 2PI, you will need at least 1mm https://ieeexplore.ieee.org/document/8853396/
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
of the waveguide. |
500.0
|
cross_section
|
CrossSectionSpec
|
for the waveguide. |
'pin'
|
via_stack
|
ComponentSpec | None
|
for via_stacking the metal. |
'via_stack_m1_mtop'
|
via_stack_width
|
float
|
in um. |
10.0
|
via_stack_slab
|
ComponentSpec | None
|
function for the component via_stacking the slab. |
'via_stack_slab_m1_horizontal'
|
via_stack_slab_top
|
ComponentSpec | None
|
Optional, defaults to via_stack_slab. |
None
|
via_stack_slab_bot
|
ComponentSpec | None
|
Optional, defaults to via_stack_slab. |
None
|
via_stack_slab_width
|
float | None
|
defaults to via_stack_width. |
None
|
via_stack_spacing
|
float
|
spacing between via_stacks. |
3.0
|
via_stack_slab_spacing
|
float
|
spacing between via_stacks slabs. |
2.0
|
taper
|
ComponentSpec | None
|
optional taper. |
'taper_strip_to_ridge'
|
width
|
float | None
|
width of the waveguide. If None, it will use the width of the cross_section. |
None
|
Source code in gdsfactory/components/waveguides/straight_pin_slot.py
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 | |

straight_pn
module-attribute
straight_pn = partial(
straight_pin, cross_section="pn", length=2000
)

straight_pn_slot
module-attribute
straight_pn_slot = partial(
straight_pin_slot, cross_section="pn"
)

wire_corner
wire_corner(
cross_section: CrossSectionSpec = "metal_routing",
port_names: PortNames = port_names_electrical,
port_types: PortTypes = port_types_electrical,
width: float | None = None,
radius: float | None = None,
) -> Component
Returns 45 degrees electrical corner wire.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
cross_section
|
CrossSectionSpec
|
spec. |
'metal_routing'
|
port_names
|
PortNames
|
port names. |
port_names_electrical
|
port_types
|
PortTypes
|
port types. |
port_types_electrical
|
width
|
float | None
|
optional width. Defaults to cross_section width. |
None
|
radius
|
float | None
|
ignored. |
None
|
Source code in gdsfactory/components/waveguides/wire.py
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 | |

wire_corner45
wire_corner45(
cross_section: CrossSectionSpec = "metal_routing",
radius: float = 10,
width: float | None = None,
layer: LayerSpec | None = None,
with_corner90_ports: bool = True,
) -> Component
Returns 90 degrees electrical corner wire.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
cross_section
|
CrossSectionSpec
|
spec. |
'metal_routing'
|
radius
|
float
|
in um. |
10
|
width
|
float | None
|
optional width. |
None
|
layer
|
LayerSpec | None
|
optional layer. |
None
|
with_corner90_ports
|
bool
|
if True adds ports at 90 degrees. |
True
|
Source code in gdsfactory/components/waveguides/wire.py
121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 | |

wire_corner45_straight
wire_corner45_straight(
width: float | None = None,
radius: float | None = None,
cross_section: CrossSectionSpec = "metal_routing",
) -> gf.Component
Returns 45 degrees wire straight ends.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
width
|
float | None
|
of the wire. |
None
|
radius
|
float | None
|
of the corner. Defaults to width. |
None
|
cross_section
|
CrossSectionSpec
|
metal_routing. |
'metal_routing'
|
Source code in gdsfactory/components/waveguides/wire.py
81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 | |

wire_corner_sections
wire_corner_sections(
cross_section: CrossSectionSpec = "metal_routing",
port_type: str = "electrical",
**kwargs: Any
) -> Component
Returns 90 degrees electrical corner wire, where all cross_section sections properly represented.
Works well with symmetric cross_sections, not quite ready for asymmetric.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
cross_section
|
CrossSectionSpec
|
spec. |
'metal_routing'
|
port_type
|
str
|
"electrical" or "optical". |
'electrical'
|
kwargs
|
Any
|
cross_section settings, ignored (such as radius, width, layer). |
{}
|
Source code in gdsfactory/components/waveguides/wire.py
197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 | |

wire_straight
wire_straight(
length: float = 10.0,
npoints: int = 2,
cross_section: CrossSectionSpec = "metal_routing",
width: float | None = None,
) -> Component
Returns a Straight waveguide.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
length
|
float
|
straight length (um). |
10.0
|
npoints
|
int
|
number of points. |
2
|
cross_section
|
CrossSectionSpec
|
specification (CrossSection, string or dict). |
'metal_routing'
|
width
|
float | None
|
width of the waveguide. If None, it will use the width of the cross_section. |
None
|
Source code in gdsfactory/components/waveguides/straight.py
107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 | |
