Hi, I have a few questions about MocoTrack and how to achieve dynamic consistency. By studying the example file (exampleMocoTrack.py), I see that the model has strong residual actuators (CoordinateActuators with high optimal force for the ground-pelvis coordinates), and the weight of their controls was increased by 10 times. So the optimizer minimizes those controls further, and hence, residual forces/moments would be reduced.
1) Can I use weak residual actuators instead of increasing the weight of the residual controls in MocoControlGoal?
2) I'm trying to track the markers and GRF, simultaneously, in the same model with strong residual actuators. If I ignore increasing the weight of the residual controls (or disable the MocoControlGoal in general), is this simulation still dynamically consistent? I think the answer is yes since the error of contact tracking is minimized, which could mean that the kinematics and kinetics are consistent. My initial simplified test ended up with an absolute max value of 0.6 for residual actuators which was 400 in inverse dynamics.
3) Also, in a simulation which tracks markers and GRF, and minimizes joint contact force, do I still need to append GRF to the model through ModOpAddExternalLoads? Perhaps the answer is no, because of the contact tracking goal.
I was wondering if you could help me with these stupid questions, and thank you in advance.
MocoTrack dynamic consistency
- Mohammadreza Rezaie
- Posts: 407
- Joined: Fri Nov 24, 2017 12:48 am
- Nicholas Bianco
- Posts: 1041
- Joined: Thu Oct 04, 2012 8:09 pm
Re: MocoTrack dynamic consistency
Hi Mohammadreza,
Unless you are intentionally applying loads to the pelvis in your simulation, ideally no residual actuators are needed. However, when tracking experimental data, it may not be possible to track kinematics or GRFs closely without residuals because of dynamic inconsistencies. Residual forces can also be useful for creating initial guesses, especially when tracking GRFs.
In exampleMocoTrack, the GRFs are applied directly to the model, so only the kinematics can change to achieve dynamic consistency (if no residuals were present). We included residuals in the example mostly to help it converge a bit faster and track the kinematics well; we were not trying to include any sort of "residual reduction" aspect to the problem.
To answer your questions:
Best,
Nick
Unless you are intentionally applying loads to the pelvis in your simulation, ideally no residual actuators are needed. However, when tracking experimental data, it may not be possible to track kinematics or GRFs closely without residuals because of dynamic inconsistencies. Residual forces can also be useful for creating initial guesses, especially when tracking GRFs.
In exampleMocoTrack, the GRFs are applied directly to the model, so only the kinematics can change to achieve dynamic consistency (if no residuals were present). We included residuals in the example mostly to help it converge a bit faster and track the kinematics well; we were not trying to include any sort of "residual reduction" aspect to the problem.
To answer your questions:
Yes, that is perfectly valid. Sometimes having stronger residuals can be helpful for convergence (i.e., easier to meet the constraint tolerance in early iterations). But the trade off is that you might need to increase the actuator weights if you want residuals under a certain magnitude.1) Can I use weak residual actuators instead of increasing the weight of the residual controls in MocoControlGoal?
If the problem converges and the constraint tolerance is met, then by default the solution is "dynamically consistent". It's just a matter of whether or not residuals are needed to achieve dynamic consistency.2) I'm trying to track the markers and GRF, simultaneously, in the same model with strong residual actuators. If I ignore increasing the weight of the residual controls (or disable the MocoControlGoal in general), is this simulation still dynamically consistent? I think the answer is yes since the error of contact tracking is minimized, which could mean that the kinematics and kinetics are consistent. My initial simplified test ended up with an absolute max value of 0.6 for residual actuators which was 400 in inverse dynamics.
If you are using a foot-ground contact model (e.g., SmoothSphereHalfSpaceForce), then you do not need to apply GRFs via ModOpAddExternalLoads.3) Also, in a simulation which tracks markers and GRF, and minimizes joint contact force, do I still need to append GRF to the model through ModOpAddExternalLoads? Perhaps the answer is no, because of the contact tracking goal.
These are great questions! Happy to helpI was wondering if you could help me with these stupid questions, and thank you in advance.
Best,
Nick
- Mohammadreza Rezaie
- Posts: 407
- Joined: Fri Nov 24, 2017 12:48 am
Re: MocoTrack dynamic consistency
Hi Nick,
I do appreciate your help. Now, I understand how to use MocoTrack properly.
Best,
-Mohammadreza
I do appreciate your help. Now, I understand how to use MocoTrack properly.
Best,
-Mohammadreza
- Mohammadreza Rezaie
- Posts: 407
- Joined: Fri Nov 24, 2017 12:48 am
Re: MocoTrack dynamic consistency
Hi, regarding the question 2, I made a mistake; my bad. Those were the controls of the strong residual actuators which were less than 0.6 not their actuation force/moment. So, in a marker + GRF tracking simulation, using weak residual actuators or high weight for their control in the control-effort goal is still required to achieve dynamic consistency.