在用GDSCell导入版图时,可以设置layer_map来选择导入特定图层的GDS文件,
比如:可以将教程57中的微环调制器生成gds文件:Ring_modulator.gds,
在导入Ring_modulator.gds做其他设计时,可以选择只导入波导部分:
代码如下:
from si_fab import all as pdk
import ipkiss3.all as i3
from ipkiss.process.layer_map import GenericGdsiiPPLayerInputMaplayer_map = GenericGdsiiPPLayerInputMap(ignore_undefined_mappings=True,pplayer_map={(i3.TECH.PROCESS.SI, i3.TECH.PURPOSE.DRAWING): (1, 0),},
)wg_imported = i3.GDSCell(filename="Ring_modulator.gds")
wg_imported_lv = wg_imported.Layout(layer_map=layer_map)
wg_imported_lv.write_gdsii("Ring.gds")
生成的Ring.gds就只有原来版图的波导部分,原因是layer_map设置了
(i3.TECH.PROCESS.SI, i3.TECH.PURPOSE.DRAWING): (1, 0),