Some of the PDK's draw_* functions do not currently return instances of gf.Component. This difficults working directly with GDSFactory to, for instance, design an inverter without depending on klayout.
This happens because some of these functions, such as draw_nfet, generates a temporary GDS and then it's registered in the layout, removing all hierarchies and abstractions that GDSFactory uses.
This Pull Request moves that operation into the produce_impl method of the Pcell.
Changes introduced:
The "layout" attribute of certain draw_* functions is not used.
All the draw_* functions return an instance of gf.Component.
The gf_to_pya() function is defined to perform the registration in klayout. All PCells occupy it.
The efuse and bjt cells are not modified because their structure is different. That can be another pull request.
@akiles-esta-usado Could you please cancel this PR and create a PR on separate branch in this repo? I need to run the test cases to see if they pass. Could you do that?
Some of the PDK's
draw_*
functions do not currently return instances ofgf.Component
. This difficults working directly with GDSFactory to, for instance, design an inverter without depending on klayout. This happens because some of these functions, such asdraw_nfet
, generates a temporary GDS and then it's registered in the layout, removing all hierarchies and abstractions that GDSFactory uses. This Pull Request moves that operation into theproduce_impl
method of the Pcell.Changes introduced:
draw_*
functions is not used.draw_*
functions return an instance of gf.Component.gf_to_pya()
function is defined to perform the registration in klayout. All PCells occupy it.efuse
andbjt
cells are not modified because their structure is different. That can be another pull request.Things that can be a problem:
draw_nfet
, use named cells. The documentation don't recommend it because it can create duplicated cells. https://gdsfactory.github.io/gdsfactory/notebooks/11_best_practices.html