tidy3d.plugins.invdes.InverseDesignMulti#

class InverseDesignMulti[source]#

Bases: AbstractInverseDesign

InverseDesign with multiple simulations and corresponding postprocess functions.

Parameters:
  • attrs (dict = {}) – Dictionary storing arbitrary metadata for a Tidy3D object. This dictionary can be freely used by the user for storing data without affecting the operation of Tidy3D as it is not used internally. Note that, unlike regular Tidy3D fields, attrs are mutable. For example, the following is allowed for setting an attr obj.attrs['foo'] = bar. Also note that Tidy3D` will raise a TypeError if attrs contain objects that can not be serialized. One can check if attrs are serializable by calling obj.json().

  • design_region (TopologyDesignRegion) – Region within which we will optimize the simulation.

  • task_name (str) – Task name to use in the objective function when running the JaxSimulation.

  • verbose (bool = False) – If True, will print the regular output from web functions.

  • metric (Union[Annotated[Union[tidy3d.plugins.expressions.operators.Add, tidy3d.plugins.expressions.operators.Subtract, tidy3d.plugins.expressions.operators.Multiply, tidy3d.plugins.expressions.operators.Divide, tidy3d.plugins.expressions.operators.Power, tidy3d.plugins.expressions.operators.Modulus, tidy3d.plugins.expressions.operators.FloorDivide, tidy3d.plugins.expressions.operators.MatMul, tidy3d.plugins.expressions.operators.Negate, tidy3d.plugins.expressions.operators.Abs], FieldInfo(default=PydanticUndefined, discriminator='type', extra={})], Annotated[Union[tidy3d.plugins.expressions.functions.Sin, tidy3d.plugins.expressions.functions.Cos, tidy3d.plugins.expressions.functions.Tan, tidy3d.plugins.expressions.functions.Exp, tidy3d.plugins.expressions.functions.Log, tidy3d.plugins.expressions.functions.Log10, tidy3d.plugins.expressions.functions.Sqrt], FieldInfo(default=PydanticUndefined, discriminator='type', extra={})], Annotated[Union[tidy3d.plugins.expressions.variables.Constant, tidy3d.plugins.expressions.variables.Variable, tidy3d.plugins.expressions.metrics.ModeAmp, tidy3d.plugins.expressions.metrics.ModePower], FieldInfo(default=PydanticUndefined, discriminator='type', extra={})], NoneType] = None) – Serializable expression defining the objective function.

  • simulations (Tuple[Simulation, ...]) – Set of simulation without the design regions or monitors used in the objective fn.

  • output_monitor_names (Optional[Tuple[Union[Tuple[str, ...], NoneType], ...]] = None) – Optional names of monitors whose data the differentiable output depends on.If this field is left None, the plugin will try to add all compatible monitors to JaxSimulation.output_monitors. While this will work, there may be warnings if the monitors are not compatible with the adjoint plugin, for example if there are FieldMonitor instances with .colocate != False.

Attributes

designs

List of individual InverseDesign objects corresponding to this instance.

task_names

Task names associated with each of the simulations.

attrs

Methods

to_simulation(params)

Convert the InverseDesign to a corresponding dict of ``td.Simulation``s.

to_simulation_data(params,Β **kwargs)

Convert the InverseDesignMulti to a set of ``td.Simulation``s and run async.

Inherited Common Usage

simulations#
output_monitor_names#
property task_names#

Task names associated with each of the simulations.

property designs#

List of individual InverseDesign objects corresponding to this instance.

to_simulation(params)[source]#

Convert the InverseDesign to a corresponding dict of ``td.Simulation``s.

to_simulation_data(params, **kwargs)[source]#

Convert the InverseDesignMulti to a set of ``td.Simulation``s and run async.

__hash__()#

Hash method.