-
Notifications
You must be signed in to change notification settings - Fork 68
Description
I simulated a directional coupler in Lumerical and exported it as a GDS file from Lumerical. I figured that it's easier to export it than to design the bends in Phidl.
I want to extract this device structure from the GDS into phidl and then extract the polygons so that I can do the following:
- Vary the coupling length for fabrication variance testing.
- Add ports to the DC outputs and inputs so that I can connect the DC to other devices in my design.
To extract the polygons, I am thinking of extracting the points from the polygons and extruding them, but I have been unsuccessful. Is there a way to do this or a better way? Here is my script.
`
import phidl.geometry as pg
from phidl import quickplot as qp
from phidl import DeviceD = Device('MyGDSImport')
A = pg.import_gds(filename = 'Rui_DC.gds', cellname = 'TOP' , flatten = True)
qp(A) # quickplot the geometry
z = pg.extract(A, layers = [0,1])
D.add_ref(z)
qp(z) #This gives a blank plot, so I can't manipulate the geometries like I would like
`