|
Momentum
A library for solving nonlinear optimization problems related to human body kinematics
|
#include <fully_differentiable_position_error_function.h>
Public Member Functions | |
| FullyDifferentiablePositionErrorFunctionT (const Skeleton &skel, const ParameterTransform &pt) | |
| ~FullyDifferentiablePositionErrorFunctionT () override=default | |
| std::vector< std::string > | inputs () const final |
| Eigen::Index | getInputSize (const std::string &name) const final |
| const char * | name () const final |
| Eigen::VectorX< T > | d_gradient_d_input_dot (const std::string &inputName, const ModelParametersT< T > ¶ms, const SkeletonStateT< T > &state, Eigen::Ref< const Eigen::VectorX< T > > inputVec) final |
| double | getError (const ModelParametersT< T > ¶ms, const SkeletonStateT< T > &state, const MeshStateT< T > &) final |
| double | getGradient (const ModelParametersT< T > ¶ms, const SkeletonStateT< T > &state, const MeshStateT< T > &, Ref< Eigen::VectorX< T > > gradient) final |
| double | getJacobian (const ModelParametersT< T > ¶ms, const SkeletonStateT< T > &state, const MeshStateT< T > &, Ref< Eigen::MatrixX< T > > jacobian, Ref< Eigen::VectorX< T > > residual, int &usedRows) final |
| size_t | getJacobianSize () const final |
| void | addConstraint (const PositionConstraintT< T > &constr) |
| const std::vector< PositionConstraintT< T > > & | getConstraints () const |
| Public Member Functions inherited from momentum::FullyDifferentiableSkeletonErrorFunctionT< T > | |
| virtual | ~FullyDifferentiableSkeletonErrorFunctionT ()=default |
| Eigen::VectorX< T > | getInput (const std::string &name) const |
| void | getInput (const std::string &name, Eigen::Ref< Eigen::VectorX< T > > value) const |
| void | setInput (const std::string &name, Eigen::Ref< const Eigen::VectorX< T > > value) |
| 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 double | getGradient (const ModelParametersT< T > &, const SkeletonStateT< T > &, const MeshStateT< T > &, Eigen::Ref< Eigen::VectorX< T > >) |
| virtual double | getJacobian (const ModelParametersT< T > &, const SkeletonStateT< T > &, const MeshStateT< T > &, Eigen::Ref< Eigen::MatrixX< T > >, Eigen::Ref< Eigen::VectorX< T > >, int &usedRows) |
| 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 |
Static Public Attributes | |
| static constexpr T | kPositionWeight = 1e-4f |
| static constexpr const char * | kParents = "parents" |
| static constexpr const char * | kOffsets = "offsets" |
| static constexpr const char * | kWeights = "weights" |
| static constexpr const char * | kTargets = "targets" |
Additional Inherited Members | |
| 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 56 of file fully_differentiable_position_error_function.h.
| momentum::FullyDifferentiablePositionErrorFunctionT< T >::FullyDifferentiablePositionErrorFunctionT | ( | const Skeleton & | skel, |
| const ParameterTransform & | pt ) |
Definition at line 51 of file fully_differentiable_position_error_function.cpp.
References momentum::SkeletonErrorFunctionT< T >::SkeletonErrorFunctionT().
|
overridedefault |
| void momentum::FullyDifferentiablePositionErrorFunctionT< T >::addConstraint | ( | const PositionConstraintT< T > & | constr | ) |
Definition at line 248 of file fully_differentiable_position_error_function.cpp.
|
finalvirtual |
Implements momentum::FullyDifferentiableSkeletonErrorFunctionT< T >.
Definition at line 438 of file fully_differentiable_position_error_function.cpp.
References momentum::buildJetVec(), momentum::cast(), kOffsets, kTargets, kWeights, and MT_THROW.
|
nodiscard |
Definition at line 255 of file fully_differentiable_position_error_function.cpp.
|
finalvirtual |
Reimplemented from momentum::SkeletonErrorFunctionT< T >.
Definition at line 83 of file fully_differentiable_position_error_function.cpp.
References momentum::cast(), kPositionWeight, momentum::PositionConstraintT< T >::target, momentum::PositionConstraintT< T >::weight, and momentum::SkeletonErrorFunctionT< T >::weight_.
|
final |
Definition at line 107 of file fully_differentiable_position_error_function.cpp.
References momentum::SkeletonErrorFunctionT< T >::parameterTransform_, momentum::PositionConstraintT< T >::weight, and momentum::SkeletonErrorFunctionT< T >::weight_.
|
nodiscardfinalvirtual |
Implements momentum::FullyDifferentiableSkeletonErrorFunctionT< T >.
Definition at line 65 of file fully_differentiable_position_error_function.cpp.
References kOffsets, kTargets, kWeights, MT_THROW, and name().
|
final |
Definition at line 141 of file fully_differentiable_position_error_function.cpp.
References momentum::EigenStrongType< Derived, EigenType >::size(), and momentum::PositionConstraintT< T >::weight.
|
nodiscardfinalvirtual |
Reimplemented from momentum::SkeletonErrorFunctionT< T >.
Definition at line 243 of file fully_differentiable_position_error_function.cpp.
|
nodiscardfinalvirtual |
Implements momentum::FullyDifferentiableSkeletonErrorFunctionT< T >.
Definition at line 59 of file fully_differentiable_position_error_function.cpp.
|
inlinenodiscardfinalvirtual |
Implements momentum::FullyDifferentiableSkeletonErrorFunctionT< T >.
Definition at line 71 of file fully_differentiable_position_error_function.h.
Referenced by getInputSize().
|
staticconstexpr |
Definition at line 62 of file fully_differentiable_position_error_function.h.
Referenced by d_gradient_d_input_dot(), getInputSize(), and inputs().
|
staticconstexpr |
Definition at line 61 of file fully_differentiable_position_error_function.h.
|
staticconstexpr |
Definition at line 60 of file fully_differentiable_position_error_function.h.
Referenced by getError().
|
staticconstexpr |
Definition at line 64 of file fully_differentiable_position_error_function.h.
Referenced by d_gradient_d_input_dot(), getInputSize(), and inputs().
|
staticconstexpr |
Definition at line 63 of file fully_differentiable_position_error_function.h.
Referenced by d_gradient_d_input_dot(), getInputSize(), and inputs().