|
-
3.42.2
|
This class represents a matrix-based constraint to apply on a matrix. More...
Public Member Functions | |
| def | __init__ (self, name, cons_value=None, shape=None, normalized=None, pos=False, cons_value_sz=None) |
| Constructs a matrix type constraint. More... | |
| def | project (self, M) |
Public Member Functions inherited from pyfaust.factparams.ConstraintGeneric | |
| def | is_int_constraint (self) |
| Returns True if this constraint is a ConstraintInt, False otherwise. More... | |
| def | is_real_constraint (self) |
| Returns True if this constraint is a ConstraintReal, False otherwise. More... | |
| def | is_mat_constraint (self) |
| Returns True if this constraint is a ConstraintMat, False otherwise. More... | |
| def | __repr__ (self) |
Public Attributes | |
| cons_value | |
| normalized | |
Public Attributes inherited from pyfaust.factparams.ConstraintGeneric | |
| normalized | |
| pos | |
Static Public Attributes | |
| dictionary | normalized_default |
Additional Inherited Members | |
Properties inherited from pyfaust.factparams.ConstraintGeneric | |
| name = property | |
| Property to access the ConstraintName of the constraint. More... | |
| shape = property | |
This class represents a matrix-based constraint to apply on a matrix.
\see ConstraintMat.__init__
| def pyfaust.factparams.ConstraintMat.__init__ | ( | self, | |
| name, | |||
cons_value = None, |
|||
shape = None, |
|||
normalized = None, |
|||
pos = False, |
|||
cons_value_sz = None |
|||
| ) |
Constructs a matrix type constraint.
| name | (ConstraintName or str) must be a ConstraintName instance set with a value among ID, SUPP, CONST, TOEPLITZ or (AANTI)CIRC(ULANT) (cf. ConstraintName) or it can also be one of the more handy str aliases which are respectively: 'supp' and 'const'. |
| cons_value | (np.ndarray) the value of the constraint, it must be a numpy.array |
| shape | (tuple) the shape of the matrix (only useful for identity prox, ConstraintName.ID. In this case the cons_value argument is None). that defines the constraint (the matrix support for SUPP and the constant matrix for CONST). |
| normalized | (bool or NoneType) None because the default value depends on the constraint name (it can be False or True, see ConstraintMat.normalized_default). |
Examples
Reimplemented from pyfaust.factparams.ConstraintGeneric.
| def pyfaust.factparams.ConstraintMat.project | ( | self, | |
| M | |||
| ) |
Reimplemented from pyfaust.factparams.ConstraintGeneric.
| pyfaust.factparams.ConstraintMat.cons_value |
| pyfaust.factparams.ConstraintMat.normalized |
|
static |