|
Momentum
A library for solving nonlinear optimization problems related to human body kinematics
|
#include <distance_error_function.h>
Public Member Functions | |
| DistanceErrorFunctionT (const momentum::Skeleton &skel, const momentum::ParameterTransform &pt) | |
| double | getError (const momentum::ModelParametersT< T > ¶ms, const momentum::SkeletonStateT< T > &state, const momentum::MeshStateT< T > &meshState) final |
| double | getGradient (const momentum::ModelParametersT< T > ¶ms, const momentum::SkeletonStateT< T > &state, const momentum::MeshStateT< T > &meshState, Eigen::Ref< Eigen::VectorX< T > > gradient) final |
| double | getJacobian (const momentum::ModelParametersT< T > ¶ms, const momentum::SkeletonStateT< T > &state, const momentum::MeshStateT< T > &meshState, Eigen::Ref< Eigen::MatrixX< T > > jacobian, Eigen::Ref< Eigen::VectorX< T > > residual, int &usedRows) final |
| size_t | getJacobianSize () const final |
| void | addConstraint (const DistanceConstraintDataT< T > &constr) |
| void | clearConstraints () |
| void | setConstraints (std::vector< DistanceConstraintDataT< T > > constr) |
| bool | empty () const |
| size_t | getNumConstraints () const |
| const std::vector< DistanceConstraintDataT< T > > & | getConstraints () const |
| Public Member Functions inherited from momentum::SkeletonErrorFunctionT< T > | |
| SkeletonErrorFunctionT (const Skeleton &skel, const ParameterTransform &pt) | |
| virtual | ~SkeletonErrorFunctionT ()=default |
| const Skeleton & | getSkeleton () const |
| const ParameterTransform & | getParameterTransform () const |
| virtual const Character * | getCharacter () const |
| For mesh-based error functions, get access to the underlying character. | |
| void | setWeight (T w) |
| T | getWeight () const |
| void | setActiveJoints (const VectorX< bool > &aj) |
| void | setEnabledParameters (const ParameterSet &ps) |
| virtual void | getHessian (const ModelParametersT< T > &, const SkeletonStateT< T > &, const MeshStateT< T > &, Eigen::Ref< Eigen::MatrixX< T > >) |
| virtual double | getSolverDerivatives (const ModelParametersT< T > ¶meters, const SkeletonStateT< T > &state, const MeshStateT< T > &meshState, const size_t actualParameters, Eigen::MatrixX< T > &hess, Eigen::VectorX< T > &grad) |
| virtual bool | needsMesh () const |
Protected Attributes | |
| const T | kDistanceWeight = 1.0f |
| std::vector< DistanceConstraintDataT< T > > | constraints_ |
| Protected Attributes inherited from momentum::SkeletonErrorFunctionT< T > | |
| const Skeleton & | skeleton_ |
| const ParameterTransform & | parameterTransform_ |
| T | weight_ |
| VectorX< bool > | activeJointParams_ |
| ParameterSet | enabledParameters_ |
| bool | useHessian_ {false} |
Definition at line 28 of file distance_error_function.h.
| momentum::DistanceErrorFunctionT< T >::DistanceErrorFunctionT | ( | const momentum::Skeleton & | skel, |
| const momentum::ParameterTransform & | pt ) |
Definition at line 18 of file distance_error_function.cpp.
References momentum::SkeletonErrorFunctionT< T >::SkeletonErrorFunctionT().
Referenced by momentum::FullyDifferentiableDistanceErrorFunctionT< T >::FullyDifferentiableDistanceErrorFunctionT().
|
inline |
Definition at line 50 of file distance_error_function.h.
|
inline |
Definition at line 53 of file distance_error_function.h.
|
inlinenodiscard |
Definition at line 59 of file distance_error_function.h.
|
inlinenodiscard |
Definition at line 66 of file distance_error_function.h.
|
nodiscardfinalvirtual |
Reimplemented from momentum::SkeletonErrorFunctionT< T >.
Definition at line 24 of file distance_error_function.cpp.
References constraints_, momentum::SkeletonStateT< T >::jointState, kDistanceWeight, momentum::sqr(), and momentum::SkeletonErrorFunctionT< T >::weight_.
|
finalvirtual |
Reimplemented from momentum::SkeletonErrorFunctionT< T >.
Definition at line 45 of file distance_error_function.cpp.
References momentum::SkeletonErrorFunctionT< T >::activeJointParams_, constraints_, momentum::SkeletonStateT< T >::jointState, kDistanceWeight, momentum::kInvalidIndex, momentum::SkeletonErrorFunctionT< T >::parameterTransform_, momentum::SkeletonErrorFunctionT< T >::skeleton_, momentum::sqr(), and momentum::SkeletonErrorFunctionT< T >::weight_.
|
finalvirtual |
Reimplemented from momentum::SkeletonErrorFunctionT< T >.
Definition at line 122 of file distance_error_function.cpp.
References momentum::SkeletonErrorFunctionT< T >::activeJointParams_, constraints_, momentum::SkeletonStateT< T >::jointState, kDistanceWeight, momentum::kInvalidIndex, momentum::SkeletonErrorFunctionT< T >::parameterTransform_, momentum::SkeletonErrorFunctionT< T >::skeleton_, momentum::sqr(), and momentum::SkeletonErrorFunctionT< T >::weight_.
|
nodiscardfinalvirtual |
Reimplemented from momentum::SkeletonErrorFunctionT< T >.
Definition at line 199 of file distance_error_function.cpp.
References constraints_.
|
inlinenodiscard |
Definition at line 62 of file distance_error_function.h.
|
inline |
Definition at line 56 of file distance_error_function.h.
|
protected |
Definition at line 74 of file distance_error_function.h.
Referenced by momentum::FullyDifferentiableDistanceErrorFunctionT< T >::d_gradient_d_input_dot(), getError(), getGradient(), momentum::FullyDifferentiableDistanceErrorFunctionT< T >::getInputImp(), momentum::FullyDifferentiableDistanceErrorFunctionT< T >::getInputSize(), getJacobian(), getJacobianSize(), and momentum::FullyDifferentiableDistanceErrorFunctionT< T >::setInputImp().
|
protected |
Definition at line 72 of file distance_error_function.h.
Referenced by getError(), getGradient(), and getJacobian().