Home Forums Nazca rebuild cell Reply To: rebuild cell


Hi Ronald,

Thanks for your answer. Yes your solution works and I have been using the same idea so far, only that it isnt very flexible as export_gds() must be called whenever the layermap changes.

Say that I have a cell, CellA, which must be placed at different locations on the wafer and on different layers. My idea was to create a generic CellA on a dummy layer and then instantiate it on the approriate layer.

For instance, if I wanted to create an array of cells based on CellA placed on different layers, the code would look like:

with nd.Cell(name='CellA') as cellA: 
    nd.strt(length=2, width=2, layer=0).put()

grid_points = [(0, 0), (4, 0), (0, 4), (4, 4)]

for i, (x,y) in enumerate(grid_points):
    # cellA.put(x,y)
    new_cell = cellA.rebuild(layermap={0:i}) # this is the intended usage, doesnt currently work


where each “copy” of cellA would be on a different layer.
Of course, there are more efficient solutions for such a simple design, but I’d like to use this mechanic for importing generic cells from a gds file and do the layermaping in nazca. For now, I’m using something like :

generic_cell = 'path_to_generic_cell.gds'  # a gds file containing generic cell placed on layer 0

for i, (x,y) in enumerate(grid_points): 
    new_cell = nd.load_gds(generic_cell, layermap={0:i})

This isn’t really efficient as I must reimport the file for each layer. That’s why I thought that importing it once and remapping in Nazca would be a better idea.