cherab.phix.inversion.GCV#

class cherab.phix.inversion.GCV(*args, **kwargs)Source#

Bases: _SVDBase

Generalized Cross-Validation (GCV) criterion optimization for regularization parameter.

GCV criterion function is defined as follows:

\[GCV(\lambda) := \frac{||Ax_\lambda - b||^2}{\left[1 - \sum_{i=1}^N w_i(\lambda)\right]^2}\]

The optimal regularization parameter corresponds to the minimum value of GCV function.

Parameters:
  • s (vector_like) – singular values of \(A\) like \(\sigma = (\sigma_1, \sigma_2, ...) \in \mathbb{R}^r\)

  • u (array_like) – left singular vectors of \(A\) like \(U = (u_1, u_2, ...) \in \mathbb{R}^{m\times r}\)

  • basis (array_like) – inverted solution basis \(\tilde{V} \in \mathbb{R}^{n\times r}\). Here, \(\tilde{V} = L^{-1}V\), where \(V\in\mathbb{R}^{n\times r}\) is the right singular vectors of \(A\) and \(L^{-1}\) is the inverse of regularization operator \(L \in \mathbb{R}^{n\times n}\).

  • **kwargs (_SVDBase properties, optional) – kwargs are used to specify properties like a data

Methods

eta(beta)

Calculate squared regularization norm: \(\eta = ||Lx_\lambda||^2\)

eta_diff(beta)

Calculate differential of eta: \(\eta' = \frac{d\eta}{d\lambda}\)

gcv(beta)

Calculate of GCV criterion function.

inverted_solution(beta)

Calculate the inverted solution using SVD components at given regularization parameter.

optimize([itemax, bounds])

Optimize the regularization parameter using GCV criterion.

plot_gcv([fig, axes, bounds, n_beta])

Plotting GCV vs regularization parameters in log-log scale.

regularization_norm(beta)

Return the residual norm: \(\sqrt{\eta} = ||L x_\lambda||\)

residual_norm(beta)

Return the residual norm: \(\sqrt{\rho} = ||Ax_\lambda - b||\)

rho(beta)

Calculate squared residual norm: \(\rho = ||Ax_\lambda - b||^2\).

solve([bounds, stepsize])

Solve the ill-posed inversion equation.

w(beta)

Calculate window function using regularization parameter \(\lambda\).

Attributes

basis

The inverted solution basis \(\tilde{V} \in \mathbb{R}^{n\times r}\).

data

Given data for inversion calculation.

lambda_opt

Optimal regularization parameter defined after solve is executed.

s

Singular values of \(A\)

u

Left singular vectors of \(A\).