tidy3d.plugins.invdes.TopologyDesignRegion#

class TopologyDesignRegion[source]#

Bases: DesignRegion

Design region as a pixellated permittivity grid.

Parameters:
  • size (tuple[NonNegativeFloat, NonNegativeFloat, NonNegativeFloat]) – [units = um]. Size in x, y, and z directions.

  • center (tuple[float, float, float]) – [units = um]. Center of object in x, y, and z.

  • eps_bounds (tuple[float, float]) – Minimum and maximum relative permittivity expressed to the design region.

  • transformations (tuple[FilterProject, …] = ()) – Transformations that get applied from first to last on the parameter array.The end result of the transformations should be the material density of the design region . With floating point values between (0, 1), 0 corresponds to the minimum relative permittivity and 1 corresponds to the maximum relative permittivity. Specific permittivity values given the density array are determined by eps_bounds.

  • penalties (tuple[ErosionDilationPenalty, …] = ()) – Set of penalties that get evaluated on the material density. Note that the penalties are applied after transformations are applied. Penalty weights can be set inside of the penalties directly through the .weight field.

  • initialization_spec (Union[RandomInitializationSpec, UniformInitializationSpec, CustomInitializationSpec] = UniformInitializationSpec()) – Specification of how to initialize the parameters in the design region.

  • pixel_size (PositiveFloat) – Pixel size of the design region in x, y, z. For now, we only support the same pixel size in all 3 dimensions. If TopologyDesignRegion.override_structure_dl is left None, the pixel_size will determine the FDTD mesh size in the design region. Therefore, if your pixel size is large compared to the FDTD grid size, we recommend setting the override_structure_dl directly to a value on the same order as the grid size.

  • uniform (tuple[bool, bool, bool] = (False, False, True)) – Axes along which the design should be uniform. By default, the structure is assumed to be uniform, i.e. invariant, in the z direction.

  • override_structure_dl (Optional[Union[PositiveFloat, Literal[False]]] = None) – Defines grid size when adding an override_structure to the JaxSimulation.grid_spec corresponding to this design region. If left None, invdes will mesh the simulation with the same resolution as the pixel_size. This is advised if the pixel size is relatively close to the FDTD grid size. Supplying False will completely leave out the override structure.

  • priority (Optional[int] = None) – Priority of the structure applied in structure overlapping region. The material property in the overlapping region is dictated by the structure of higher priority. For structures of equal priority, the structure added later to the structure list takes precedence. When priority is None, the value is automatically assigned based on structure_priority_mode in the Simulation.

Attributes

coords

Coordinates for the custom medium corresponding to this design region.

mesh_override_structure

Generate mesh override structure for this DesignRegion using pixel_size step.

params_shape

Shape of the parameters array in (x, y, z), given the pixel_size and bounds.

pixel_size

uniform

transformations

penalties

override_structure_dl

priority

size

center

eps_bounds

initialization_spec

Methods

eps_values(params[, symmetry])

Values for the custom medium permittivity.

evaluate_penalty(penalty, material_density)

Evaluate an erosion-dilation penalty, passing in pixel_size.

evaluate_transformation(transformation, params)

Evaluate a transformation, passing in design_region_dl.

to_structure(params[, symmetry])

Convert this DesignRegion into a custom Structure.

pixel_size#
uniform#
transformations#
penalties#
override_structure_dl#
priority#
property params_shape#

Shape of the parameters array in (x, y, z), given the pixel_size and bounds.

property coords#

Coordinates for the custom medium corresponding to this design region.

eps_values(params, symmetry=None)[source]#

Values for the custom medium permittivity.

to_structure(params, symmetry=None)[source]#

Convert this DesignRegion into a custom Structure.

property mesh_override_structure#

Generate mesh override structure for this DesignRegion using pixel_size step.

evaluate_transformation(transformation, params, symmetry=None)[source]#

Evaluate a transformation, passing in design_region_dl.

evaluate_penalty(penalty, material_density, symmetry=None)[source]#

Evaluate an erosion-dilation penalty, passing in pixel_size.