13 #ifndef MLPACK_CORE_OPTIMIZERS_FW_UPDATE_SPAN_HPP 14 #define MLPACK_CORE_OPTIMIZERS_FW_UPDATE_SPAN_HPP 21 namespace optimization {
37 UpdateSpan(
const bool isPrune =
false) : isPrune(isPrune)
51 const arma::mat& oldCoords,
60 arma::vec b =
function.Vectorb();
70 double oldF =
function.Evaluate(oldCoords);
71 double F = 0.25 * oldF + 0.75 *
function.Evaluate(newCoords);
UpdateSpan(const bool isPrune=false)
Construct the span update rule.
Class to hold the information and operations of current atoms in the soluton space.
The core includes that mlpack expects; standard C++ includes and Armadillo.
const arma::vec & CurrentCoeffs() const
Get the current atom coefficients.
void RecoverVector(arma::mat &x)
Recover the solution coordinate from the coefficients of current atoms.
void Update(FuncSq &function, const arma::mat &oldCoords, const arma::mat &s, arma::mat &newCoords, const size_t)
Update rule for FrankWolfe, reoptimize in the span of current solution space.
void PruneSupport(const double F, FuncSq &function)
Prune the support, delete previous atoms if they don't contribute much.
void AddAtom(const arma::vec &v, FuncSq &function, const double c=0)
Add atom into the solution space.
const arma::mat & CurrentAtoms() const
Get the current atoms.
Recalculate the optimal solution in the span of all previous solution space, used as update step for ...