加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
20210325_4_resonator.py 945 Bytes
一键复制 编辑 原始数据 按行查看 历史
xiaoyu 提交于 2021-03-25 22:30 . sth
import gdspy as gs
lib = gs.GdsLibrary()
cell = lib.new_cell('l2')
# set reference cordinate
X = 0
Y = 0
# determined by base material
W = 5
path1 = gs.Path(W, (X, Y + 2.5),number_of_paths = 2, distance = 10)
path1.segment(120,"+y")
path1.turn(25,"l")
path1.segment(100,"-x")
path1.turn(25,"rr")
path1.segment(250,"+x")
path1.turn(25,"ll")
path1.segment(250,"-x")
path1.turn(25,"rr")
path1.segment(250,"+x")
path1.turn(25,"ll")
path1.segment(250,"-x")
path1.turn(25,"rr")
path1.segment(250,"+x")
path1.turn(25,"ll")
path1.segment(220,"-x")
path1.turn(25,"rr")
path1.segment(220,"+x")
path1.turn(25,"ll")
path1.segment(220,"-x")
path1.turn(25,"rr")
path1.segment(220,"+x")
path1.turn(25,"ll")
path1.segment(220,"-x")
path1.turn(25,"rr")
path1.segment(220,"+x")
path1.turn(25,"l")
path1.segment(100,"+y")
path1.turn(25,"l")
path1.segment(300,"-x")
cell.add(path1)
lib.write_gds('E:/python/xiaoyu_GDSTest/resonator.gds')
gs.LayoutViewer(lib)
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化