add_bundle_astar
add_bundle_astar(
component: ProtoTKCell,
ports1: list[PortLike],
ports2: list[PortLike],
spacing: Um,
bend: KCellSpec,
straight: KCellSpec,
layers: Iterable[LayerLike],
grid_unit: Int = 500,
*,
fanin_strategy: FanInStrategy = "manhattan",
fanin_strategy_kwargs: dict[str, Any] | None = None,
) -> list[None]
Add a bundle route using the a-star algorithm.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
component
|
ProtoTKCell
|
The component to add the route into. |
required |
ports1
|
list[PortLike]
|
the start ports |
required |
ports2
|
list[PortLike]
|
the end ports |
required |
spacing
|
Um
|
the spacing between the waveguides in the bundle |
required |
bend
|
KCellSpec
|
the bend-spec to create bends with |
required |
straight
|
KCellSpec
|
the straight-spec to create straights with |
required |
layers
|
Iterable[LayerLike]
|
the layers to avoid. |
required |
grid_unit
|
Int
|
the discretization unit for the a-star algorithm. |
500
|
fanin_strategy
|
FanInStrategy
|
how the start and end bundles are formed.
|
'manhattan'
|
fanin_strategy_kwargs
|
dict[str, Any] | None
|
per-strategy overrides. For |
None
|
Source code in python/doroutes/bundles.py
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 | |
add_fan_in
add_fan_in(
c: ProtoTKCell,
inputs: list[PortLike],
straight: KCellSpec,
bend: KCellSpec,
x_bundle_dbu: Dbu | None = None,
y_bundle_dbu: Dbu | None = None,
spacing_dbu: Dbu | None = None,
start_dir: OrientationChar | None = None,
*,
strategy: FanInStrategy = "manhattan",
strategy_kwargs: dict[str, Any] | None = None,
) -> NDArray[int64]
Add a fan-in to a parent component.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
c
|
ProtoTKCell
|
the component to add the fan-in to |
required |
inputs
|
list[PortLike]
|
the list of ports to start from |
required |
straight
|
KCellSpec
|
the straight-spec to create straights from |
required |
bend
|
KCellSpec
|
the bend-spec to create bends from |
required |
x_bundle_dbu
|
Dbu | None
|
the x-location where to form the confluence of the bundle will be two bend radiuses from the inputs if not given. |
None
|
y_bundle_dbu
|
Dbu | None
|
the y-location where to form the confluence of the bundle will be somewhere in the middle if not given. |
None
|
spacing_dbu
|
Dbu | None
|
the spacing between waveguides in the bundle |
None
|
start_dir
|
OrientationChar | None
|
the start direction of the bundle (derived from ports if not given) |
None
|
strategy
|
FanInStrategy
|
fan-in strategy. |
'manhattan'
|
strategy_kwargs
|
dict[str, Any] | None
|
extra keyword arguments forwarded to the strategy
implementation. Examples: |
None
|
Source code in python/doroutes/fanin.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 | |
add_route_astar
add_route_astar(
c: ProtoTKCell,
start: PortLike,
stop: PortLike,
straight: KCellSpec,
bend: KCellSpec,
layers: Iterable[LayerLike],
grid_unit: Dbu,
) -> None
Add an a-star route to a component.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
c
|
ProtoTKCell
|
the component to add the route to |
required |
start
|
PortLike
|
the start port |
required |
stop
|
PortLike
|
the stop port |
required |
straight
|
KCellSpec
|
the straight-spec to create straights from |
required |
bend
|
KCellSpec
|
the bend-spec to create bends from |
required |
layers
|
Iterable[LayerLike]
|
the layers to avoid |
required |
grid_unit
|
Dbu
|
the discretization unit for the a-star algorithm |
required |
Source code in python/doroutes/routing.py
add_route_from_corners
add_route_from_corners(
c: ProtoTKCell,
start: PortLike,
stop: PortLike,
corners: PointsDbu | None = None,
*,
steps: list[StepDbu] | None = None,
straight: KCellSpec,
bend: KCellSpec,
) -> None
Add a corners-based route to a component.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
c
|
ProtoTKCell
|
the component to add the route to |
required |
start
|
PortLike
|
the start port |
required |
stop
|
PortLike
|
the stop port |
required |
corners
|
PointsDbu | None
|
the corners in between start and stop. |
None
|
steps
|
list[StepDbu] | None
|
steps in between start and stop (alternative to corners). |
None
|
straight
|
KCellSpec
|
the straight-spec to create straights from |
required |
bend
|
KCellSpec
|
the bend-spec to create bends from |
required |
Source code in python/doroutes/routing.py
add_route_from_steps
add_route_from_steps(
c: ProtoTKCell,
start: PortLike,
stop: PortLike,
steps: list[StepDbu],
straight: KCellSpec,
bend: KCellSpec,
) -> None
Add a steps-based route to a component.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
c
|
ProtoTKCell
|
the component to add the route to |
required |
start
|
PortLike
|
the start port |
required |
stop
|
PortLike
|
the stop port |
required |
steps
|
list[StepDbu]
|
the steps in between start and stop. |
required |
straight
|
KCellSpec
|
the straight-spec to create straights from |
required |
bend
|
KCellSpec
|
the bend-spec to create bends from |
required |
Source code in python/doroutes/routing.py
find_route_astar
find_route_astar(
c: ProtoTKCell,
start: PortLike,
stop: PortLike,
straight: KCellSpec,
bend: KCellSpec,
layers: Iterable[LayerLike],
grid_unit: Dbu,
) -> PointsDbu
Find an a-star route without adding it to the component.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
c
|
ProtoTKCell
|
the component to find the route in |
required |
start
|
PortLike
|
the start port |
required |
stop
|
PortLike
|
the stop port |
required |
straight
|
KCellSpec
|
the straight-spec to create straights from |
required |
bend
|
KCellSpec
|
the bend-spec to create bends from |
required |
layers
|
Iterable[LayerLike]
|
the layers to avoid |
required |
grid_unit
|
Dbu
|
the discretization unit for the a-star algorithm |
required |
Returns:
| Type | Description |
|---|---|
PointsDbu
|
The corners of the route as a list of points in dbu. |
Source code in python/doroutes/routing.py
place_auto
place_auto(
c: ProtoTKCell,
instances: list[str] | list[PlacedInstanceSpec],
nets: list[PlacementNetSpec] | list[object],
*,
mode: PlacementMode = "auto",
objective: PlacementObjective | None = None,
constraints: PlacementConstraints | None = None,
routing_feedback: RoutingFeedbackConfig | None = None,
apply: bool = True,
iterations: int = 30,
) -> PlacementReport
Automatically place instances using openroad-style or tiling mode.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
c
|
ProtoTKCell
|
component/KCell to place instances in. |
required |
instances
|
list[str] | list[PlacedInstanceSpec]
|
list of instance names or specs. |
required |
nets
|
list[PlacementNetSpec] | list[object]
|
placement netlist — either |
required |
mode
|
PlacementMode
|
"openroad", "tiling", or "auto". |
'auto'
|
objective
|
PlacementObjective | None
|
objective weights. |
None
|
constraints
|
PlacementConstraints | None
|
placement constraints. |
None
|
routing_feedback
|
RoutingFeedbackConfig | None
|
reserved for future routing-in-loop strategies. |
None
|
apply
|
bool
|
apply placement in-place when True. |
True
|
iterations
|
int
|
optimizer iteration budget. |
30
|
Returns:
| Type | Description |
|---|---|
PlacementReport
|
Structured placement report with final locations and metrics. |
Source code in python/doroutes/placement.py
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 395 396 397 398 399 | |
place_openroad_style
place_openroad_style(
c: ProtoTKCell,
instances: list[str] | list[PlacedInstanceSpec],
nets: list[PlacementNetSpec],
**kwargs: Any,
) -> PlacementReport
Run place_auto with mode="openroad".