numerical-collection-cpp 0.10.0
A collection of algorithms in numerical analysis implemented in C++
|
Class for fast iterative shrinkage-thresholding algorithm (FISTA) [1] for L1-regularization of linear equations. More...
#include <num_collect/regularization/fista.h>
Public Types | |
using | base_type = iterative_regularized_solver_base<this_type, Data> |
Type of the base class. | |
using | coeff_type = Coeff |
Type of coefficient matrices. | |
using | this_type = fista<Coeff, Data> |
This type. | |
Public Types inherited from num_collect::regularization::regularized_solver_base< fista< Coeff, Data >, Data > | |
using | data_type |
Type of data. | |
using | scalar_type |
Type of scalars. | |
Public Member Functions | |
fista () | |
Constructor. | |
void | calculate_data_for (const data_type &solution, data_type &data) const |
Calculate data for a solution. | |
void | change_data (const data_type &data) |
Change data. | |
void | compute (const Coeff &coeff, const Data &data) |
Compute internal parameters. | |
void | configure_iteration_logger (logging::iterations::iteration_logger< this_type > &iteration_logger) const |
Configure an iteration logger. | |
auto | data_size () const -> index_type |
Get the size of data. | |
void | init (const scalar_type ¶m, data_type &solution) |
Initialize. | |
auto | is_stop_criteria_satisfied (const data_type &solution) const -> bool |
Determine if stopping criteria of the algorithm are satisfied. | |
void | iterate (const scalar_type ¶m, data_type &solution) |
Iterate the algorithm once. | |
auto | iterations () const noexcept -> index_type |
Get the number of iterations. | |
auto | max_iterations () const -> index_type |
Get the maximum number of iterations. | |
auto | max_iterations (index_type value) -> fista & |
Set the maximum number of iterations. | |
auto | param_search_region () const -> std::pair< scalar_type, scalar_type > |
Get the default region to search for the optimal regularization parameter. | |
auto | regularization_term (const data_type &solution) const -> scalar_type |
Calculate the regularization term. | |
auto | residual_norm (const data_type &solution) const -> scalar_type |
Calculate the squared norm of the residual. | |
auto | residual_norm_rate () const -> scalar_type |
Get the rate of the last residual norm. | |
auto | tol_update_rate () const -> scalar_type |
Get the tolerance of update rate of the solution. | |
auto | tol_update_rate (scalar_type value) -> fista & |
Set the tolerance of update rate of the solution. | |
auto | update () const noexcept -> scalar_type |
Get the norm of the update of the solution in the last iteration. | |
Public Member Functions inherited from num_collect::regularization::iterative_regularized_solver_base< fista< Coeff, Data >, Data > | |
void | init (const scalar_type ¶m, data_type &solution) |
Initialize. | |
auto | is_stop_criteria_satisfied (const data_type &solution) const -> bool |
Determine if stopping criteria of the algorithm are satisfied. | |
void | iterate (const scalar_type ¶m, data_type &solution) |
Iterate the algorithm once. | |
void | solve (const scalar_type ¶m, data_type &solution) |
Solve for a regularization parameter. | |
Public Member Functions inherited from num_collect::regularization::implicit_regularized_solver_base< fista< Coeff, Data >, Data > | |
void | calculate_data_for (const data_type &solution, data_type &data) const |
Calculate data for a solution. | |
void | change_data (const data_type &data) |
Change data. | |
auto | regularization_term (const data_type &solution) const -> scalar_type |
Calculate the regularization term. | |
auto | residual_norm (const data_type &solution) const -> scalar_type |
Calculate the squared norm of the residual. | |
Public Member Functions inherited from num_collect::regularization::regularized_solver_base< fista< Coeff, Data >, Data > | |
auto | data_size () const -> index_type |
Get the size of data. | |
auto | param_search_region () const -> std::pair< scalar_type, scalar_type > |
Get the default region to search for the optimal regularization parameter. | |
void | solve (const scalar_type ¶m, data_type &solution) |
Solve for a regularization parameter. | |
Public Member Functions inherited from num_collect::logging::logging_mixin | |
logging_mixin (log_tag_view tag) | |
Constructor. | |
template<typename Child > | |
void | configure_child_algorithm_logger_if_exists (Child &child) |
Configure a logger of a child algorithm if exists. | |
auto | logger () const noexcept -> const num_collect::logging::logger & |
Access to the logger. | |
auto | logger () noexcept -> num_collect::logging::logger & |
Access to the logger. | |
Public Member Functions inherited from num_collect::logging::iterations::iteration_logger_mixin< fista< Coeff, Data > > | |
iteration_logger_mixin ()=default | |
Constructor. | |
void | configure_iteration_logger (num_collect::logging::iterations::iteration_logger< fista< Coeff, Data > > &iteration_logger) const |
Configure an iteration logger. | |
auto | initialize_iteration_logger () -> num_collect::logging::iterations::iteration_logger< fista< Coeff, Data > > & |
Get the iteration logger. | |
Private Attributes | |
const coeff_type * | coeff_ {nullptr} |
Coefficient matrix. | |
const data_type * | data_ {nullptr} |
Data vector. | |
scalar_type | inv_max_eigen_ {} |
Inverse of maximum eigenvalue of \( AA^T \) for coefficient matrix \( A \). | |
index_type | iterations_ {} |
Number of iterations. | |
index_type | max_iterations_ {default_max_iterations} |
Maximum number of iterations. | |
data_type | residual_ {} |
Residual vector. | |
scalar_type | t_ {} |
Parameter for step size of y_. | |
scalar_type | tol_update_rate_ {default_tol_update_rate} |
Tolerance of update rate of the solution. | |
scalar_type | update_ {} |
Norm of the update of the solution in the last iteration. | |
data_type | y_ {} |
Another vector to update in FISTA. | |
Static Private Attributes | |
static constexpr index_type | default_max_iterations = 1000 |
Default maximum number of iterations. | |
static constexpr auto | default_tol_update_rate |
Default tolerance of update rate of the solution. | |
Additional Inherited Members | |
Protected Member Functions inherited from num_collect::regularization::iterative_regularized_solver_base< fista< Coeff, Data >, Data > | |
iterative_regularized_solver_base (logging::log_tag_view tag) | |
Constructor. | |
Protected Member Functions inherited from num_collect::regularization::implicit_regularized_solver_base< fista< Coeff, Data >, Data > | |
implicit_regularized_solver_base (logging::log_tag_view tag) | |
Constructor. | |
auto | derived () const noexcept -> const fista< Coeff, Data > & |
Access derived object. | |
auto | derived () noexcept -> fista< Coeff, Data > & |
Access derived object. | |
Protected Member Functions inherited from num_collect::regularization::regularized_solver_base< fista< Coeff, Data >, Data > | |
regularized_solver_base (logging::log_tag_view tag) | |
Constructor. | |
auto | derived () const noexcept -> const fista< Coeff, Data > & |
Access derived object. | |
auto | derived () noexcept -> fista< Coeff, Data > & |
Access derived object. | |
Class for fast iterative shrinkage-thresholding algorithm (FISTA) [1] for L1-regularization of linear equations.
This class execute fast iterative shrinkage-thresholding algorithm (FISTA) for L1-regularization of linear equations. This class is for large inferior-determined problems, and implemented with OpenMP.
Coeff | Type of coefficient matrices. |
Data | Type of data vectors. |
using num_collect::regularization::fista< Coeff, Data >::base_type = iterative_regularized_solver_base<this_type, Data> |
using num_collect::regularization::fista< Coeff, Data >::coeff_type = Coeff |
using num_collect::regularization::fista< Coeff, Data >::this_type = fista<Coeff, Data> |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inlinenodiscard |
|
inline |
|
inlinenodiscard |
|
inline |
|
inlinenodiscardnoexcept |
|
inlinenodiscard |
|
inline |
|
inlinenodiscard |
|
inlinenodiscard |
|
inlinenodiscard |
|
inlinenodiscard |
|
inlinenodiscard |
|
inline |
|
inlinenodiscardnoexcept |
|
private |
|
private |
|
staticconstexprprivate |
|
staticconstexprprivate |
Default tolerance of update rate of the solution.
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |