LayoutValidation#

class pyedb.grpc.database.layout_validation.LayoutValidation(pedb: Any)#

Manages all layout validation capabilities.

Overview#

dc_shorts

Find DC shorts on layout.

disjoint_nets

Find and fix disjoint nets from a given netlist.

fix_self_intersections

Find and fix self intersections from a given netlist.

illegal_net_names

Find and fix illegal net names.

illegal_rlc_values

Find and fix RLC illegal values.

padstacks_no_name

Identify and fix padstacks without names.

delete_empty_pin_groups

Find and delete pin groups that have no pins.

run_siwave_validation_check

Run Siwave geometry validation/healing workflow through siwave_ng and siwavevalchk.

Import detail#

from pyedb.grpc.database.layout_validation import LayoutValidation

Method detail#

LayoutValidation.dc_shorts(net_list: str | List[str] | None = None, fix: bool = False) List[List[str]]#

Find DC shorts on layout.

Parameters:
net_liststr or list[str], optional

List of nets.

fixbool, optional

If True, rename all the nets. (default) If False, only report dc shorts.

Returns:
List[List[str, str]]

[[net name, net name]].

Examples

>>> from pyedb import Edb
>>> edb = Edb("edb_file")
>>> # Find shorts without fixing
>>> shorts = edb.layout_validation.dc_shorts()
>>>
>>> # Find and fix shorts on specific nets
>>> fixed_shorts = edb.layout_validation.dc_shorts(net_list=["GND", "VCC"], fix=True)
LayoutValidation.disjoint_nets(net_list: str | List[str] | None = None, keep_only_main_net: bool = False, clean_disjoints_less_than: float = 0.0, order_by_area: bool = False, keep_disjoint_pins: bool = False) List[str]#

Find and fix disjoint nets from a given netlist.

Parameters:
net_liststr, list, optional

List of nets on which check disjoints. If None is provided then the algorithm will loop on all nets.

keep_only_main_netbool, optional

Remove all secondary nets other than principal one (the one with more objects in it). Default is False.

clean_disjoints_less_thanbool, optional

Clean all disjoint nets with area less than specified area in square meters. Default is 0.0 to disable it.

order_by_areabool, optional

Whether if the naming order has to be by number of objects (fastest) or area (slowest but more accurate). Default is False.

keep_disjoint_pinsbool, optional

Whether if delete disjoints pins not connected to any other primitive or not. Default is False.

Returns:
List

New nets created.

Examples

>>> from pyedb import Edb
>>> edb = Edb("edb_file")
>>> new_nets = edb.layout_validation.disjoint_nets()
>>> # Clean disjoints on specific nets with advanced options
>>> cleaned = edb.layout_validation.disjoint_nets(
...     net_list=["GND"],
...     keep_only_main_net=True,
...     clean_disjoints_less_than=1e-6,
...     order_by_area=True
... ))
LayoutValidation.fix_self_intersections(net_list: str | List[str] | None = None) bool#

Find and fix self intersections from a given netlist.

Parameters:
net_liststr, list, optional

List of nets on which check disjoints. If None is provided then the algorithm will loop on all nets.

Returns:
bool

Examples

>>> from pyedb import Edb
>>> edb = Edb("edb_file")
>>> # Fix self-intersections on all nets
>>> edb.layout_validation.fix_self_intersections()
>>>
>>> # Fix self-intersections on specific nets
>>> edb.layout_validation.fix_self_intersections(net_list=["RF_line"])
LayoutValidation.illegal_net_names(fix: bool = False) None#

Find and fix illegal net names.

Examples

>>> from pyedb import Edb
>>> edb = Edb("edb_file")
>>> # Identify illegal net names
>>> edb.layout_validation.illegal_net_names()
>>>
>>> # Find and automatically fix illegal names
>>> edb.layout_validation.illegal_net_names(fix=True)
LayoutValidation.illegal_rlc_values(fix: bool = False) List[str]#

Find and fix RLC illegal values.

Examples

>>> from pyedb import Edb
>>> edb = Edb("edb_file")
>>> # Identify components with illegal RLC values
>>> bad_components = edb.layout_validation.illegal_rlc_values()
>>>
# Automatically fix invalid inductor values
#     edb.layout_validation.illegal_rlc_values(fix=True)
LayoutValidation.padstacks_no_name(fix: bool = False) None#

Identify and fix padstacks without names.

Examples

# Use an Edb instance (see dc_shorts example above) and call: # edb.layout_validation.padstacks_no_name() # # Automatically assign names to unnamed padstacks # edb.layout_validation.padstacks_no_name(fix=True)

LayoutValidation.delete_empty_pin_groups() None#

Find and delete pin groups that have no pins.

Examples

>>> from pyedb import Edb
>>> edb = Edb("edb_file")
>>> edb.layout_validation.delete_empty_pin_groups()
LayoutValidation.run_siwave_validation_check(validation_mode: str = 'SYZ', num_cpus: int = 8, fix_self_intersections: bool = True, fix_disjoint_nets: bool = True, check_for_shorted_nets: bool = True, fix_overlapping_vias: bool = True, check_for_bondwire_errors: bool = True, fix_misalignments: bool = True, fix_floating_planes: bool = True, check_for_unreferenced_traces: bool = True, ignore_non_functional_pads: bool = True, correct_all_fixable_issues: bool = True, strict_disjoint_net_check: bool = True, save: bool = True, delete_temp_folder: bool = True, keep_log_files: bool = True) bool#

Run Siwave geometry validation/healing workflow through siwave_ng and siwavevalchk.

The active EDB session is closed before external tools run and reopened afterwards (only when this session’s path matches the target AEDB).

Parameters:
validation_modestr, optional

Validation mode passed as ValidationMode . Default is "SYZ".

num_cpusint, optional

Number of CPUs for SetNumCpus. Default is 8.

fix_self_intersectionsbool, optional

Add FixSelfIntersections when True.

fix_disjoint_netsbool, optional

Add FixDisjointNets when True.

check_for_shorted_netsbool, optional

Add CheckForShortedNets when True.

fix_overlapping_viasbool, optional

Add FixOverlappingVias when True.

check_for_bondwire_errorsbool, optional

Add CheckForBondwireErrors when True.

fix_misalignmentsbool, optional

Add FixMisalignments when True.

fix_floating_planesbool, optional

Add FixFloatingPlanes when True.

check_for_unreferenced_tracesbool, optional

Add CheckForUnreferencedTraces when True.

ignore_non_functional_padsbool, optional

Add IgnoreNonFunctionalPads when True.

correct_all_fixable_issuesbool, optional

Add CorrectAllFixableIssues when True.

strict_disjoint_net_checkbool, optional

Add StrictDisjointNetCheck when True.

savebool, optional

Add Save when True.

delete_temp_folderbool, optional

Delete the temporary working folder after workflow completion. Default is True.

keep_log_filesbool, optional

Copy all files produced by siwavevalchk (e.g. valchk.prof, valchk.results, valchk_error_warning.log) from the temporary results folder _temp/.siwaveresults/valchk into a validation_check_log folder next to the source AEDB. Any pre-existing validation_check_log folder is deleted first. Default is True.

Returns:
bool

True when the workflow succeeds and edb.def is written back.