ams.opt.omodel.Param#
- class ams.opt.omodel.Param(name: str | None = None, info: str | None = None, unit: str | None = None, no_parse: bool | None = False, nonneg: bool | None = False, nonpos: bool | None = False, cplx: bool | None = False, imag: bool | None = False, symmetric: bool | None = False, diag: bool | None = False, hermitian: bool | None = False, boolean: bool | None = False, integer: bool | None = False, pos: bool | None = False, neg: bool | None = False, sparse: list | None = False)[source]#
Base class for parameters used in a routine.
- Parameters:
- no_parse: bool, optional
True to skip parsing the parameter.
- nonneg: bool, optional
True to set the parameter as non-negative.
- nonpos: bool, optional
True to set the parameter as non-positive.
- cplx: bool, optional
True to set the parameter as complex, avoiding the use of complex.
- imag: bool, optional
True to set the parameter as imaginary.
- symmetric: bool, optional
True to set the parameter as symmetric.
- diag: bool, optional
True to set the parameter as diagonal.
- hermitian: bool, optional
True to set the parameter as hermitian.
- boolean: bool, optional
True to set the parameter as boolean.
- integer: bool, optional
True to set the parameter as integer.
- pos: bool, optional
True to set the parameter as positive.
- neg: bool, optional
True to set the parameter as negative.
- sparse: bool, optional
True to set the parameter as sparse.
- __init__(name: str | None = None, info: str | None = None, unit: str | None = None, no_parse: bool | None = False, nonneg: bool | None = False, nonpos: bool | None = False, cplx: bool | None = False, imag: bool | None = False, symmetric: bool | None = False, diag: bool | None = False, hermitian: bool | None = False, boolean: bool | None = False, integer: bool | None = False, pos: bool | None = False, neg: bool | None = False, sparse: list | None = False)[source]#
Methods
parse
()Parse the parameter.
update
()Update the Parameter value.
Attributes
Return the class name
Return the number of elements.
Return the shape.
Return the size.