export_pdk
- ipkiss3.all.canvas.export_pdk(pdk_path, pdk_name=None, symbols=None, output_path=None)
Export JSON file for a PDK library with a <pdk_path>/ipkiss/<pdk_name> folder structure
A PDK consists of components that have layout information.
- Parameters:
- pdk_path: str, Path
Path to the PDK (containing the ipkiss directory)
- pdk_name: str
Name of the PDK
- symbols: Optional[dict]
cell name -> symbol options. Specifies how the symbols of the pdk should be generated.
- output_path: str
Path to the output file. By default, the file is named after pdk name and located alongside the all.py file.
Examples
'''Code template to export a PDK to a format that IPKISS Canvas can read. Note that this example is not executable but provides a starting point for you to manually export a PDK. Every component in the PDK can be exported with custom settings, as demonstrated below. ''' import dummy_pdk as pdk import ipkiss3.all as i3 pdk_path = 'C:\path\to\pdk' symbols = { ".*": {}, "Coupler1x2": { "image": i3.canvas.SymbolImage.Coupler1x2, }, "Coupler1x3": { "image": i3.canvas.SymbolImage.Coupler1x3, "parameters": ["coefficients"], "terms_positions": { "in": [-1, 0], "out1": [1, -0.9], "out2": [1, 0], "out3": [1, 0.9], }, }, "RibTraceTemplate": None, # Do not export RibTraceTemplate } i3.canvas.export_pdk(pdk_path=pdk_path, symbols=symbols)