Lambda Process Design Kit (PDK)
lambdapdk is a Python library providing open-source Process Design Kit (PDK) definitions and related files, primarily designed for integration with the siliconcompiler EDA framework. It includes configurations for various technologies like ASAP7, Sky130, and GF180. The current version is 0.2.12, and it receives frequent minor updates to add features, fix bugs, and update PDK content.
Common errors
-
ModuleNotFoundError: No module named 'lambdapdk.pdk.sky130'
cause Attempting to import a specific PDK module directly from the top-level `lambdapdk` package, rather than from the `lambdapdk.pdk` subpackage.fixAdjust the import statement to `from lambdapdk.pdk import sky130` (or the relevant PDK name). -
siliconcompiler.core.SiliconCompilerError: PDK lambdapdk could not be found.
cause `siliconcompiler` cannot locate the `lambdapdk` installation. This might be due to `lambdapdk` not being installed in the active Python environment or `siliconcompiler`'s search paths being incorrectly configured.fixEnsure `lambdapdk` is installed (`pip install lambdapdk`). Verify `siliconcompiler`'s environment setup (e.g., `SILICON_COMPILER_HOME`) if you have a non-standard installation. -
Error: Failed to find required library file: <some_file.lef> (or similar during chip.run())
cause Even though `lambdapdk` is loaded, a specific physical library file (e.g., a LEF file for a standard cell library, a GDS file) that the design flow requires is missing or its path is misconfigured.fixThis often indicates that the *actual physical files* for the PDK (beyond the Python definitions in `lambdapdk`) are not available or are not being found by `siliconcompiler`. Check `siliconcompiler`'s path configuration (`chip.get('pdk', 'dir')`, `chip.get('package', 'path')`) and verify that the necessary technology files and libraries have been downloaded and are accessible.
Warnings
- gotcha `lambdapdk` is designed to be used with the `siliconcompiler` EDA framework. Direct manipulation or importing of its internal modules (e.g., `lambdapdk.pdk.sky130`) outside of a `siliconcompiler` context might not be fully functional or could lead to unexpected behavior.
- breaking Minor versions of `lambdapdk` (e.g., 0.2.x) can introduce internal API changes related to how PDK components are structured or how libraries are referenced (e.g., changes to memory model APIs, pin directions, foreign object positions). These changes might not be explicitly marked as breaking but can cause issues if `siliconcompiler` expects an older internal structure or if you rely on specific internal paths/settings.
- gotcha While `lambdapdk` provides PDK *definitions* (paths, rules, etc.), it typically does not include all physical GDS, LEF, or Verilog library files. These often need to be pre-downloaded or made available on the system, with `SILICON_COMPILER_HOME` or other environment variables configured for `siliconcompiler` to locate them.
Install
-
pip install lambdapdk
Imports
- sky130
from lambdapdk import sky130
from lambdapdk.pdk import sky130
Quickstart
import siliconcompiler
import os
# Create a new chip object
chip = siliconcompiler.Chip("my_design")
# Load the lambdapdk library as the process design kit
# This automatically configures relevant paths and settings for the PDK
chip.load_pdk("lambdapdk")
# To confirm the PDK is loaded, you can check its name or other settings
print(f"PDK loaded: {chip.get('pdk', 'name')}")
# You would typically add source files, flow definition, etc., here
# Example:
# chip.input('adder.v', 'verilog')
# chip.set('design', 'adder')
# chip.set('flow', 'asicflow')
# chip.run()