opensim-org / opensim-core

SimTK OpenSim C++ libraries and command-line applications, and Java/Python wrapping.
https://opensim.stanford.edu
Apache License 2.0
800 stars 323 forks source link

A few Moco default values contradict their descriptions #3833

Closed mrrezaie closed 4 months ago

mrrezaie commented 4 months ago

Hi, I just wrote a MocoTrack into an XML file, and found that the default values of the following properties don't match with their comments (I didn't specify them in my code):

<MocoControlGoal name="control_effort">
    <!--In cost mode, the goal is multiplied by this weight (default: 1).-->
    <weight>0.001</weight>
<!--The finite difference scheme CasADi will use to calculate problem derivatives (default: 'central').-->
<optim_finite_difference_scheme>forward</optim_finite_difference_scheme>

The last one was the same for MocoInverse as well.

Thank you.

nickbianco commented 4 months ago

These are not the default values for MocoControlGoal and MocoCasADiSolver, but they are the defaults that MocoTrack (and MocoInverse use when configuring the problem/solver internally to those tools. It's a bit confusing looking at these properties, but the values are consistent with the properties in MocoTrack and MocoInverse.