tidy3d.plugins.design.ParameterAny#

class ParameterAny[source]#

Bases: Parameter

Parameter containing a set of of anything.

Parameters:
  • name (Attribute: name) –

    Type

    str

    Default

    Description

    Unique name for the variable. Used as a key into the parameter sweep results.

  • values (Attribute: values) –

    Type

    Optional[Tuple[Any, …]]

    Default

    = None

    Description

    If specified, the parameter scan uses these values for grid search methods.

  • allowed_values (Attribute: allowed_values) –

    Type

    Tuple[Any, …]

    Default

    Description

    The discrete set of values that this variable can take on.

Example

>>> import tidy3d.plugins.design as tdd
>>> var = tdd.ParameterAny(name="x", allowed_values=("a", "b", "c"))

Attributes

Methods

sample_random(num_samples)

Sample this design variable randomly 'num_samples' times.

select_from_01(pts_01)

Select values given a set of points between 0, 1.

allowed_values#
sample_random(num_samples)[source]#

Sample this design variable randomly β€˜num_samples’ times.

select_from_01(pts_01)[source]#

Select values given a set of points between 0, 1.

__hash__()#

Hash method.