gdsfactory / kfactory

gdsfactory with a klayout backend
https://gdsfactory.github.io/kfactory/
MIT License
31 stars 11 forks source link

pdk migration pydantic-2 #157

Closed sebastian-goeldi closed 1 year ago

sebastian-goeldi commented 1 year ago

TODO:

Reimplement the technology parts

joamatab commented 1 year ago

@thomasdorch

sebastian-goeldi commented 1 year ago

Local test (so far):

import kfactory as kf

kf.technology.layer_map.yaml_to_lyp("test.yml", "test.lyp")
test.yml ```yaml layers: - name: Waveguide layer: [1, 0] dither_pattern: dotted width: 1 color: "#ff9d9d" - name: Waveguide layer: [1, 0] dither_pattern: dotted width: 1 color: "red" - name: group1 members: - name: NPP color: "cyan" layer: [5,0] - name: subgroup1 members: - name: subsub1 layer: [15,0] ```

produces:

test.lyp ```xml false 0 0 I2 true true false 1 false false 0 Waveguide - 1/0 1/0@1 false 0 0 I2 true true false 1 false false 0 Waveguide - 1/0 1/0@1 false 0 0 true true false false false 0 group1 */*@* false 0 0 I1 true true false 1 false false 0 NPP - 5/0 5/0@1 false 0 0 true true false false false 0 subgroup1 */*@* false 0 0 I1 true true false 1 false false 0 subsub1 - 15/0 15/0@1 ```

@SkandanC @joamatab does this seem reasonable? ofc we can add the other way as soon as we are happy with yaml -> lyp

sebastian-goeldi commented 1 year ago

Added lyp -> yaml