pylops.optimization.cls_sparsity.SPGL1ยถ
- class pylops.optimization.cls_sparsity.SPGL1(Op, callbacks=None)[source]ยถ
Spectral Projected-Gradient for L1 norm.
Solve a constrained system of equations given the operator
Opand a sparsyfing transformSOpaiming to retrive a model that is sparse in the sparsifying domain.This is a simple wrapper to
spgl1.spgl1which is a porting of the well-known SPGL1 MATLAB solver into Python. In order to be able to use this solver you need to have installed thespgl1library.- Parameters:
- Op
pylops.LinearOperator Operator to invert of size \([N \times M]\).
- Op
- Attributes:
- ncp
module Array module used by the solver (obtained via
pylops.utils.backend.get_array_module) ). Available only aftersetupis called.
- ncp
- Raises:
- ModuleNotFoundError
If the
spgl1library is not installed
Notes
Solve different variations of sparsity-promoting inverse problem by imposing sparsity in the retrieved model [1].
The first problem is called basis pursuit denoise (BPDN) and its cost function is
\[\|\mathbf{x}\|_1 \quad \text{subject to} \quad \left\|\mathbf{Op}\,\mathbf{S}^H\mathbf{x}-\mathbf{y}\right\|_2^2 \leq \sigma,\]while the second problem is the โโ-regularized least-squares or LASSO problem and its cost function is
\[\left\|\mathbf{Op}\,\mathbf{S}^H\mathbf{x}-\mathbf{y}\right\|_2^2 \quad \text{subject to} \quad \|\mathbf{x}\|_1 \leq \tau\][1]van den Berg E., Friedlander M.P., โProbing the Pareto frontier for basis pursuit solutionsโ, SIAM J. on Scientific Computing, vol. 31(2), pp. 890-912. 2008.
Methods
__init__(Op[, callbacks])callback(x, *args, **kwargs)Callback routine
finalize(*args[, show])Finalize solver
memory_usage([show, unit])Compute memory usage of the solver
run(x[, show])Run solver
setup(y[, SOp, tau, sigma, show])Setup solver
solve(y[, x0, SOp, tau, sigma, show])Run entire solver
step()Run one step of solver