kqcircuits.util.area

class kqcircuits.util.area.AreaReceiver(*args, **kwargs)[source]

Bases: klayout.dbcore.TileOutputReceiver

Class for handling and storing output from TilingProcessor

@brief Creates a new object of this class

put(ix, iy, tile, obj, dbu, clip)[source]

Function called by TilingProcessor on output

kqcircuits.util.area.get_area_and_density(cell: klayout.dbcore.Cell, layer_infos=None)[source]

Get total area and density \(\rho=\frac{area}{bbox.area}\) of all layers.

Parameters
  • cell – target cell to get area from

  • layer_infos – list of LayerInfo to get area for, or None to get area for all layers.

Returns

tuple containing lists of

  • layer names as str

  • total area as float

  • density between 0 and 1 as float

Return type

tuple

../_images/kqcircuits.util.area.png