Parameter

class farn.core.parameter.Parameter(name: str = '', value: float | int | bool | str | None = None)

Bases: object

Dataclass holding the parameter attributes ‘name’ and ‘value’.

__init__(name: str = '', value: float | int | bool | str | None = None) None

Methods

__init__([name, value])

Attributes

dtype

Returns the numpy dtype of the parameter.

type

Returns the Python type of the parameter.

property dtype: dtype[float64] | dtype[int32] | dtype[bool_] | dtype[str_] | None

Returns the numpy dtype of the parameter.

Returns:

the numpy dtype, or None

Return type:

np.dtype[np.float64] | np.dtype[np.int32] | np.dtype[np.bool] | np.dtype[np.str] | None

property type: type[float] | type[int] | type[bool] | type[str] | None

Returns the Python type of the parameter.

Returns:

the Python type

Return type:

Union[Type[float], Type[int], Type[bool], Type[str], None]