parameter module

Define a model parameter.

class Parameter(markdown: str, unit: str = '1', value: float = 0.0, *, lower_bound: float = -inf, upper_bound: float = inf, description: str = '', is_locked: bool = False)

Bases: object

An electron emission model parameter.

_tol: float = 1e-10
__init__(markdown: str, unit: str = '1', value: float = 0.0, *, lower_bound: float = -inf, upper_bound: float = inf, description: str = '', is_locked: bool = False) None

Instantiate the parameter.

Parameters:
  • markdown – The name of the parameter, in markdown format.

  • unit – The unit of the parameter. The default is "1" (no unit).

  • value – A first value for the parameter. The default is 0..

  • lower_bound – A first lower bound for the parameter. The default is -np.inf.

  • upper_bound – A first upper bound for the parameter. The default is np.inf.

  • description – A description string for the parameter. The default is an empty string.

  • is_locked – Forces the parameters to a certain value, which will not be modified by EEmiLib.

__str__() str

Return name of parameter, its value and its unit.

property name: str

Return markdown name of parameter with its unit.

property value: float

Give the current value of the parameter.

property lower_bound: float

Give the current lower bound of the parameter.

property upper_bound: float

Give the current upper bound of the parameter.

lock() None

Set the parameter to its current value.

unlock() None

Allow parameter to be changed again during optimisation.

_set_tiny_bounds() None

Set tiny bounds around value.