Algorithms
GCPDecompositions.GCPAlgorithms — ModuleAlgorithms for Generalized CP Decomposition.
GCPDecompositions.GCPAlgorithms.AbstractAlgorithm — TypeAbstractAlgorithmAbstract type for GCP algorithms.
Concrete types ConcreteAlgorithm <: AbstractAlgorithm should implement _gcp!(M, X, loss, constraints, algorithm::ConcreteAlgorithm) that modifies the initialization M and returns the modified version.
GCPDecompositions.GCPAlgorithms.gcp_objective — Functiongcp_objective(M::CPD, X::AbstractArray, loss)Compute the GCP objective function for the model tensor M, data tensor X, and loss function loss.
GCPDecompositions.GCPAlgorithms.gcp_grad_U! — Functiongcp_grad_U!(GU, M::CPD, X::AbstractArray, loss)Compute the GCP gradient with respect to the factor matrices U = (U[1],...,U[N]) for the model tensor M, data tensor X, and loss function loss, and store the result in GU = (GU[1],...,GU[N]).
GCPDecompositions.GCPAlgorithms.ALS — TypeALSAlternating Least Squares. Workhorse algorithm for LeastSquares loss with no constraints.
Algorithm parameters:
maxiters::Int: max number of iterations (default:200)
GCPDecompositions.GCPAlgorithms.FastALS — TypeFastALSFast Alternating Least Squares.
Efficient ALS algorithm proposed in:
Fast Alternating LS Algorithms for High Order CANDECOMP/PARAFAC Tensor Factorizations. Anh-Huy Phan, Petr Tichavský, Andrzej Cichocki. IEEE Transactions on Signal Processing, 2013. DOI: 10.1109/TSP.2013.2269903
Algorithm parameters:
maxiters::Int: max number of iterations (default:200)
GCPDecompositions.GCPAlgorithms.LBFGSB — TypeLBFGSBLimited-memory BFGS with Box constraints.
Algorithm parameters:
m::Int: max number of variable metric corrections (default:10)factr::Float64: function tolerance in units of machine epsilon (default:1e7)pgtol::Float64: (projected) gradient tolerance (default:1e-5)maxfun::Int: max number of function evaluations (default:15000)maxiter::Int: max number of iterations (default:15000)iprint::Int: verbosity (default:-1)iprint < 0means no outputiprint = 0prints only one line at the last iteration0 < iprint < 99printsfand|proj g|everyiprintiterationsiprint = 99prints details of every iteration except n-vectorsiprint = 100also prints the changes of active set and finalxiprint > 100prints details of every iteration includingxandg
Notes:
- this algorithm only supports
Float64numbers
See documentation of LBFGSB.jl for more details.
GCPDecompositions.GCPAlgorithms.FastALS_iter! — MethodFastALS_iter!(X, U, λ)Algorithm for computing MTTKRP sequences is from "Fast Alternating LS Algorithms for High Order CANDECOMP/PARAFAC Tensor Factorizations" by Phan et al., specifically section III-C.
GCPDecompositions.GCPAlgorithms.gcp_grad_U! — Methodgcp_grad_U!(GU, M::CPD, X::AbstractArray, loss)Compute the GCP gradient with respect to the factor matrices U = (U[1],...,U[N]) for the model tensor M, data tensor X, and loss function loss, and store the result in GU = (GU[1],...,GU[N]).
GCPDecompositions.GCPAlgorithms.gcp_objective — Methodgcp_objective(M::CPD, X::AbstractArray, loss)Compute the GCP objective function for the model tensor M, data tensor X, and loss function loss.