Search found 1099 matches

by Nicholas Bianco
Thu Apr 10, 2025 10:52 am
Forum: OpenSim Moco
Topic: Inverse Dynamics & GRF output
Replies: 2
Views: 96

Re: Inverse Dynamics & GRF output

Hi Menthy, It seems like you've worked something out, but if you're using (or willing to upgrade to) OpenSim 4.5.1, we added a new method to MocoStudy for calculating generalized forces (i.e., joint moments) directly from a MocoTrajectory . You need to specify which force elements should be included...
by Nicholas Bianco
Thu Apr 10, 2025 10:46 am
Forum: OpenSim Moco
Topic: Questions in using "EndpointConstraint" mode of MocoInitialOutputGoal/MocoFinalOutputGoal
Replies: 14
Views: 2460

Re: Questions in using "EndpointConstraint" mode of MocoInitialOutputGoal/MocoFinalOutputGoal

Hi Carlos,

Yes, we added that in OpenSim 4.5 -- glad you figured it out!

Best,
Nick
by Nicholas Bianco
Thu Apr 10, 2025 10:44 am
Forum: OpenSim Moco
Topic: How to optimize prosthesis parameters
Replies: 4
Views: 133

Re: How to optimize prosthesis parameters

Hi Ziling, You can use "solver.createGuess()" to create a new default guess. You can also modify the default guess, for example, by inserting the motion you are tracking before passing it to the solver. I would also call "solver.resetProblem(problem)", since you've made changes to the MocoProblem. s...
by Nicholas Bianco
Tue Apr 08, 2025 10:55 am
Forum: OpenSim Moco
Topic: How to optimize with a fixed initial posture
Replies: 6
Views: 156

Re: How to optimize with a fixed initial posture

Hi Tarou, Aaron is correct: you will need to use "setStateInfo()" to set custom bounds. However, you will not be able to do this directly from MocoTrack. You will need to access the MocoProblem that is part of the MocoStudy internal to MocoTrack and modify that instead. To do this, you need to call ...
by Nicholas Bianco
Tue Apr 08, 2025 10:45 am
Forum: OpenSim Moco
Topic: How to optimize prosthesis parameters
Replies: 4
Views: 133

Re: How to optimize prosthesis parameters

Hi Ziling,

Based on your GitHub issue, I think you are adding the MocoParameter correctly, but you might need to reset the initial guess for the problem based on the added parameter.

Could you provide a full code example?

Best,
Nick
by Nicholas Bianco
Fri Mar 28, 2025 12:12 pm
Forum: OpenSim
Topic: Tutorial may conflict with opensim 4.5
Replies: 2
Views: 700

Re: Tutorial may conflict with opensim 4.5

Hi Tianchi, I've updated the tutorial page to reflect the new path API with a note about the API change: https://opensimconfluence.atlassian.net/wiki/spaces/OpenSim/pages/53088704/Simulation-Based+Design+to+Reduce+Metabolic+Cost. This makes me realize that we should add a "setPath" option to the new...
by Nicholas Bianco
Fri Mar 28, 2025 10:13 am
Forum: OpenSim Moco
Topic: MocoTrack - GRF Parameter Tuning & Convergence Issues
Replies: 4
Views: 191

Re: MocoTrack - GRF Parameter Tuning & Convergence Issues

Thanks for the tip! As you said, I wanted to ensure the model could replicate the measured data by calibrating the ground contact. With the "calibrated" model I want to run some predictive simulations. So, I wanted to make sure the comparison against the experimental data is "fair" (i.e. the model'...
by Nicholas Bianco
Thu Mar 27, 2025 5:57 pm
Forum: OpenSim Moco
Topic: MocoTrack - GRF Parameter Tuning & Convergence Issues
Replies: 4
Views: 191

Re: MocoTrack - GRF Parameter Tuning & Convergence Issues

Hi Menthy, Thanks for sharing your code example and nice plots. To answer your questions: 1. The simplified model could be main factor here, especially the limited set of contact spheres. The offset in the ankle curve makes me wonder if shifting the contact spheres vertically could help here. Gettin...
by Nicholas Bianco
Fri Mar 14, 2025 4:26 pm
Forum: OpenSim
Topic: MATLAB Scripting with OpenSim 4.4
Replies: 8
Views: 937

Re: MATLAB Scripting with OpenSim 4.4

Hi Nathan, Glad this is working for you now. I found another thing that might work: if you do pass the model to the JointReaction() and Kinematics() constructors, then you might need to add the analysis directly to the model: joint_reaction = JointReaction(model); model.addAnalysis(joint_reaction); ...