pylops.optimization.leastsquares.normal_equations_inversion#
- pylops.optimization.leastsquares.normal_equations_inversion(Op, y, Regs, x0=None, Weight=None, dataregs=None, epsI=0.0, epsRs=None, NRegs=None, epsNRs=None, engine='scipy', show=False, **kwargs_solver)[source]#
Inversion of normal equations.
Solve the regularized normal equations for a system of equations given the operator
Op
, a data weighting operatorWeight
and optionally a list of regularization termsRegs
and/orNRegs
.- Parameters
- Op
pylops.LinearOperator
Operator to invert of size \([N \times M]\)
- y
numpy.ndarray
Data of size \([N \times 1]\)
- Regs
list
Regularization operators (
None
to avoid adding regularization)- x0
numpy.ndarray
, optional Initial guess of size \([M \times 1]\)
- Weight
pylops.LinearOperator
, optional Weight operator
- dataregs
list
, optional Regularization data (must have the same number of elements as
Regs
)- epsI
float
, optional Tikhonov damping
- epsRs
list
, optional Regularization dampings (must have the same number of elements as
Regs
)- NRegs
list
Normal regularization operators (
None
to avoid adding regularization). Such operators must apply the chain of the forward and the adjoint in one go. This can be convenient in cases where a faster implementation is available compared to applying the forward followed by the adjoint.- epsNRs
list
, optional Regularization dampings for normal operators (must have the same number of elements as
NRegs
)- engine
str
, optional Solver to use (
scipy
orpylops
)- show
bool
, optional Display normal equations solver log
- **kwargs_solver
Arbitrary keyword arguments for chosen solver (
scipy.sparse.linalg.cg
andpylops.optimization.solver.cg
are used for enginescipy
andpylops
, respectively)Note
When user does not supply
atol
, it is set to “legacy”.
- Op
- Returns
- xinv
numpy.ndarray
Inverted model.
- istop
int
Convergence information (only when using
scipy.sparse.linalg.cg
):0
: successful exit>0
: convergence to tolerance not achieved, number of iterations<0
: illegal input or breakdown
- xinv
See also
RegularizedInversion
Regularized inversion
PreconditionedInversion
Preconditioned inversion
Notes
See
pylops.optimization.cls_leastsquares.NormalEquationsInversion