sporco.admm.cmod

ADMM algorithm for the CMOD problem

Functions

getPcn(zm)

Construct constraint set projection function.

zeromean(v)

Subtract mean of each column of matrix.

normalise(v)

Normalise columns of matrix.

Classes

CnstrMOD(*args, **kwargs)

ADMM algorithm for a constrained variant of the Method of Optimal Directions (MOD) [20] problem, referred to here as Constrained MOD (CMOD).


Function Descriptions

sporco.admm.cmod.getPcn(zm)[source]

Construct constraint set projection function.

Parameters
zmbool

Flag indicating whether the projection function should include column mean subtraction

Returns
fnfunction

Constraint set projection function

sporco.admm.cmod.zeromean(v)[source]

Subtract mean of each column of matrix.

Parameters
varray_like

Input dictionary array

Returns
vzndarray

Dictionary array with column means subtracted

sporco.admm.cmod.normalise(v)[source]

Normalise columns of matrix.

Parameters
varray_like

Array with columns to be normalised

Returns
vnrmndarray

Normalised array


Class Descriptions

class sporco.admm.cmod.CnstrMOD(*args, **kwargs)[source]

Bases: sporco.admm.admm.ADMMEqual

ADMM algorithm for a constrained variant of the Method of Optimal Directions (MOD) [20] problem, referred to here as Constrained MOD (CMOD).


Inheritance diagram of CnstrMOD


Solve the optimisation problem

\[\mathrm{argmin}_D \| D X - S \|_2^2 \quad \text{such that} \quad \| \mathbf{d}_m \|_2 = 1 \;\;,\]

where \(\mathbf{d}_m\) is column \(m\) of matrix \(D\), via the ADMM problem

\[\mathrm{argmin}_D \| D X - S \|_2^2 + \iota_C(G) \quad \text{such that} \quad D = G \;\;,\]

where \(\iota_C(\cdot)\) is the indicator function of feasible set \(C\) consisting of matrices with unit-norm columns.

After termination of the solve method, attribute itstat is a list of tuples representing statistics of each iteration. The fields of the named tuple IterationStats are:

Iter : Iteration number

DFid : Value of data fidelity term \((1/2) \| D X - S \|_2^2\)

Cnstr : Constraint violation measure

PrimalRsdl : Norm of primal residual

DualRsdl : Norm of dual residual

EpsPrimal : Primal residual stopping tolerance \(\epsilon_{\mathrm{pri}}\)

EpsDual : Dual residual stopping tolerance \(\epsilon_{\mathrm{dua}}\)

Rho : Penalty parameter

Time : Cumulative run time


Call graph

../_images/cmod_init.svg

Parameters
Zarray_like, shape (M, K)

Sparse representation coefficient matrix

Sarray_like, shape (N, K)

Signal vector or matrix

dsztuple

Dictionary size

optCnstrMOD.Options object

Algorithm options

class Options(opt=None)[source]

Bases: sporco.admm.admm.ADMMEqual.Options

CnstrMOD algorithm options

Options include all of those defined in sporco.admm.admm.ADMMEqual.Options, together with additional options:

AuxVarObj : Flag indicating whether the objective function should be evaluated using variable X (False) or Y (True) as its argument. Setting this flag to True often gives a better estimate of the objective function

ZeroMean : Flag indicating whether the solution dictionary \(D\) should have zero-mean components.

Parameters
optdict or None, optional (default None)

CnstrMOD algorithm options

uinit(ushape)[source]

Return initialiser for working variable U

setcoef(Z)[source]

Set coefficient array.

getdict()[source]

Get final dictionary.

xstep()[source]

Minimise Augmented Lagrangian with respect to \(\mathbf{x}\).

ystep()[source]

Minimise Augmented Lagrangian with respect to \(\mathbf{y}\).

eval_objfn()[source]

Compute components of objective function as well as total contribution to objective function.

obfn_dfd()[source]

Compute data fidelity term \((1/2) \| D \mathbf{x} - \mathbf{s} \|_2^2\).

obfn_cns()[source]

Compute constraint violation measure \(\| P(\mathbf{y}) - \mathbf{y}\|_2\).

rhochange()[source]

Re-factorise matrix when rho changes

solve()

Call graph

../_images/cmod_solve.svg