rcnl-org/nmsm-core

[BUG] JMP Incorrect Initial Guess for Body Scaling Value

Closed this issue · 1 comments

Describe the bug
When I run JMP with body scaling turned on (I am calibrating an ankle joint and tried scaling the tibia body), the initial value of the cost function is much higher than when I use the same JMP parameters except do not have body scaling turned on. The initial cost function value should be the same when a new parameter is added. It appears that the JMP optimization is using the incorrect initial value of the body scaling parameter.

To Reproduce
Steps to reproduce the behavior:

  1. Run JMP using settings file JMPRAnkleSettingsv3.1.xml, which does not have tibia body scaling turned on. As shown in file "JMP Convergence 3.1.txt", the initial value of the cost function (Resnorm) is 0.705857.
  2. Run JMP again using settings file JMPRAnkleSettingsv3.2.xml, which is identical to JMPRAnkleSettingsv3.1.xml except that tibia body scaling has been added. As shown in file "JMP Convergence 3.2.txt", the initial value of the cost function (Resnorm) is now 5.09736, which is much larger.

Expected behavior
I would expect the initial cost function value to be the same when new changeable parameters are added to a JMP settings file, since having an additional variable should not change the initial errors (at worst, keeping the new variable at its nominal value should produce the same errors as when the new variable is not present).

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: Windows
  • OpenSim Version: 4.4
  • MATLAB Version: 2023a
  • NMSM Pipeline Version: v1.0 beta

Additional context
Add any other context about the problem here.
BodyScalingBug.zip

closed with #234