GrpcCutout#

class pyedb.workflows.utilities.cutout.GrpcCutout(edb)#

Create a clipped (cut-out) EDB cell from an existing layout. High-performance EDB cut-out utility.

Examples

>>> cut = Cutout(edb)
>>> cut.signals = ["DDR4_DQ0", "DDR4_DQ1"]
>>> cut.references = ["GND"]
>>> cut.expansion_size = 0.001
>>> polygon = cut.run()
Attributes:
signalslist[str]

List of signal net names to keep in the cut-out.

referenceslist[str]

List of reference net names to keep in the cut-out.

extent_typestr

Extent algorithm: ConvexHull (default), Conforming, Bounding.

expansion_sizefloat

Additional margin (metres) around the computed extent. Default 0.002.

use_round_cornerbool

Round the corners of the expanded extent. Default False.

custom_extentlist[tuple[float, float]] | None

Optional closed polygon [(x1,y1), …] overriding any automatic extent.

custom_extent_unitsstr

Length unit for custom_extent. Default mm.

include_voids_in_extentsbool

Include voids ≥ 5 % of the extent area when building the clip polygon.

open_cutout_at_endbool

Open the resulting cut-out database in the active Edb object. Default True.

use_pyaedt_cutoutbool

Use the PyAEDT based implementation instead of native EDB API. Default True.

smart_cutoutbool

Automatically enlarge expansion_size until all ports have reference. Default False.

expansion_factorfloat

If > 0, compute initial expansion_size from trace-width/dielectric. Default 0.

maximum_iterationsint

Maximum attempts for smart_cutout before giving up. Default 10.

number_of_threadsint

Worker threads for polygon clipping and padstack cleaning. Default 1.

remove_single_pin_componentsbool

Delete RLC components with only one pin after cut-out. Default False.

preserve_components_with_modelbool

Keep every pin of components that carry a Spice/S-parameter model. Default False.

check_terminalsbool

Grow extent until all reference terminals are inside the cut-out. Default False.

include_pingroupsbool

Ensure complete pin-groups are included (needs check_terminals). Default False.

simple_pad_checkbool

Use fast centre-point padstack check instead of bounding-box. Default True.

keep_lines_as_pathbool

Keep clipped traces as Path objects (3D Layout only). Default False.

extent_defeaturefloat

Defeature tolerance (metres) for conformal extent. Default 0.

include_partial_instancesbool

Include padstacks that only partially overlap the clip polygon. Default False.

keep_voidsbool

Retain voids that intersect the clip polygon. Default True.

The cut-out can be produced with three different extent strategies:
* ``ConvexHull`` (default)
* ``Conforming`` (tight follow of geometry)
* ``Bounding`` (simple bounding box)
Multi-threaded execution, automatic terminal expansion and smart
expansion-factor logic are supported.

Overview#

Import detail#

from pyedb.workflows.utilities.cutout import GrpcCutout

Property detail#

property GrpcCutout.logger#

Edb logger.

Attribute detail#

GrpcCutout.signals: List[str] = []#
GrpcCutout.references: List[str] = []#
GrpcCutout.extent_type: str = 'ConvexHull'#
GrpcCutout.expansion_size: str | float = 0.002#
GrpcCutout.use_round_corner: bool = False#
GrpcCutout.output_file: str = ''#
GrpcCutout.open_cutout_at_end: bool = True#
GrpcCutout.use_pyaedt_cutout: bool = True#
GrpcCutout.smart_cutout: bool = False#
GrpcCutout.number_of_threads: int = 2#
GrpcCutout.use_pyaedt_extent_computing: bool = True#
GrpcCutout.extent_defeature: int | float = 0#
GrpcCutout.remove_single_pin_components: bool = False#
GrpcCutout.custom_extent: List[float, float] = None#
GrpcCutout.custom_extent_units: str = 'mm'#
GrpcCutout.include_partial_instances: bool = False#
GrpcCutout.keep_voids: bool = True#
GrpcCutout.check_terminals: bool = False#
GrpcCutout.include_pingroups: bool = False#
GrpcCutout.expansion_factor: int | float = 0#
GrpcCutout.maximum_iterations: int = 10#
GrpcCutout.preserve_components_with_model: bool = False#
GrpcCutout.simple_pad_check: bool = True#
GrpcCutout.keep_lines_as_path: bool = False#
GrpcCutout.include_voids_in_extents: bool = False#

Method detail#

GrpcCutout.calculate_initial_extent(expansion_factor)#

Compute a float representing the larger number between the dielectric thickness or trace width multiplied by the nW factor. The trace width search is limited to nets with ports attached.

Parameters:
expansion_factorfloat

Value for the width multiplier (nW factor).

Returns:
float
GrpcCutout.pins_to_preserve()#
GrpcCutout.run()#