$darkmode
pinocchio 4.0.0
A fast and flexible implementation of Rigid Body Dynamics algorithms and their analytical derivatives
ADMMSolverSettingsTpl< _Scalar > Struct Template Reference

Settings for the ADMM constraint solver loop. More...

#include <pinocchio/algorithm/solvers/admm-solver.hpp>

Inheritance diagram for ADMMSolverSettingsTpl< _Scalar >:
Collaboration diagram for ADMMSolverSettingsTpl< _Scalar >:

Public Types

typedef ConstraintSolverSettingsBase< SelfBase
 
typedef _Scalar Scalar
 
typedef ADMMSolverSettingsTpl Self
 

Public Member Functions

 ADMMSolverSettingsTpl (std::size_t max_iterations=1000, Scalar absolute_feasibility_tol=Scalar(1e-6), Scalar relative_feasibility_tol=Scalar(1e-6), Scalar absolute_complementarity_tol=Scalar(1e-6), Scalar relative_complementarity_tol=Scalar(1e-6), bool solve_ncp=true, bool measure_timings=false, bool stat_record=false, std::optional< Scalar > rho_init=std::nullopt, bool warmstart_rho_with_previous_result=false, ADMMUpdateRule admm_update_rule=ADMMUpdateRule::OSQP, ADMMProximalRule admm_proximal_rule=ADMMProximalRule::MANUAL, Scalar mu_prox=Scalar(1e-6), Scalar tau_prox=Scalar(1), Scalar tau=Scalar(0.5), Scalar ratio_primal_dual=Scalar(10), Scalar dual_momentum=Scalar(0), Scalar rho_update_ratio=Scalar(0), std::size_t rho_min_update_frequency=1, Scalar rho_momentum=Scalar(0), Scalar rho_min=Scalar(1e-6), Scalar rho_max=Scalar(1e6), Scalar spectral_rho_power_init=Scalar(0.2), Scalar spectral_rho_power_factor=Scalar(0.05), Scalar linear_update_rule_factor=Scalar(2), std::size_t lanczos_size=std::numeric_limits< int >::max(), std::size_t max_delassus_decomposition_updates=std::numeric_limits< int >::max(), std::size_t anderson_capacity=0)
 Default constructor.
 
void checkValidityImpl () const
 

Public Attributes

ADMMProximalRule admm_proximal_rule
 Update rule for the primal proximal term.
 
ADMMUpdateRule admm_update_rule
 Update rule for the rho admm term.
 
std::size_t anderson_capacity
 Size of the andersion history used to fit the anderson linear system. If set to 0 or 1, no anderson acceleration is used.
 
Scalar dual_momentum
 Momentum on the dual variable. 0 means no momentum.
 
std::size_t lanczos_size
 Size of the lanczos decomposition. Higher values lead to more precise estimation of the Delassus' maximum eigenvalue.
 
Scalar linear_update_rule_factor
 Value by which rho is multiplied/divided in the LINEAR update rule.
 
std::size_t max_delassus_decomposition_updates
 Maximum number of delassus decomposition updates. Once this number is reached, rho and mu_prox are kept constant.
 
Scalar mu_prox
 Value of the proximal term when admm_proximal_rule is MANUAL. When admm_proximal_rule is AUTOMATIC, the proximal term follows the rho term.
 
Scalar ratio_primal_dual
 Value of the primal/dual ratio beyond/below which a rho update is considered. If the primal/dual ratio is not big/low enough, rho is kept constant.
 
std::optional< Scalar > rho_init
 Initial value of rho parameter. If set to boost::none, the initial rho will be computed by estimating the largest eigenvalue of the Delassus.
 
Scalar rho_max
 Maximum value that rho can take. During 'solve', rho is clamped between rho_min and rho_max.
 
Scalar rho_min
 Minimum value that rho can take. During 'solve', rho is clamped between rho_min and rho_max.
 
std::size_t rho_min_update_frequency
 How many iterations before rho can be updated again. 1 means rho can be updated. every iterations (it does not mean it is updated every iterations).
 
Scalar rho_momentum
 Momentum on rho value.
 
Scalar rho_update_ratio
 Ratio w.r.t previous rho value beyond/below which rho is updated. In essence, if rho has not changed enough compared to the previous rho value, its value stays unchanged. This is a knob to prevent updating rho too much.
 
Scalar spectral_rho_power_factor
 Power factor used to update rho in the SPECTRAL update rule.
 
Scalar spectral_rho_power_init
 Initial value of the rho power in the SPECTRAL update rule.
 
Scalar tau
 Scaling factor in front of the rho ADMM term.
 
Scalar tau_prox
 Scaling factor in front of the primal proximal term.
 
bool warmstart_rho_with_previous_result
 Whether or not to warmstart rho with previous result. If set to true, the rho_init will be bypassed by the value of rho stored in the solver's solution. More...
 

Detailed Description

template<typename _Scalar>
struct pinocchio::ADMMSolverSettingsTpl< _Scalar >

Settings for the ADMM constraint solver loop.

Definition at line 248 of file admm-solver.hpp.

Member Data Documentation

◆ warmstart_rho_with_previous_result

bool warmstart_rho_with_previous_result

Whether or not to warmstart rho with previous result. If set to true, the rho_init will be bypassed by the value of rho stored in the solver's solution.

Note
This setting is only effective if a previous solution is valid.

Definition at line 381 of file admm-solver.hpp.


The documentation for this struct was generated from the following file: