Search found 999 matches

by Nicholas Bianco
Fri Aug 23, 2024 9:15 am
Forum: OpenSim Moco
Topic: Linear Velocity Constraint or Goal
Replies: 5
Views: 162

Re: Linear Velocity Constraint or Goal

Try ".add()" instead.

(Appending to a std::vector in Matlab and Python works differently and I can never remember which one to use.)
by Nicholas Bianco
Fri Aug 23, 2024 9:07 am
Forum: OpenSim Moco
Topic: Linear Velocity Constraint or Goal
Replies: 5
Views: 162

Re: Linear Velocity Constraint or Goal

Ah yes, apologies. Here is the correct snippet: finalHandVelocity = MocoFinalOutputGoal('final_hand_velocity); finalHandVelocity.setOutputPath('/bodyset/hand|linear_velocity'); finalHandVelocity.setMode('endpoint_constraint'); bounds = StdVectorMocoBounds(); bounds.append(MocoBounds(10)); finalHandV...
by Nicholas Bianco
Wed Aug 21, 2024 3:38 pm
Forum: OpenSim Moco
Topic: Linear Velocity Constraint or Goal
Replies: 5
Views: 162

Re: Linear Velocity Constraint or Goal

Hi Cedric, You can use MocoFinalOutputGoal in endpoint constraint mode to achieve what you're looking for: finalHandVelocity = MocoFinalOutputGoal('final_hand_velocity); finalHandVelocity.setOutputPath('/bodyset/hand|linear_velocity'); finalHandVelocity.setMode('endpoint_constraint'); finalHandVeloc...
by Nicholas Bianco
Mon Aug 19, 2024 2:16 pm
Forum: OpenSim
Topic: Default activation error in DeGrooteFregly2016Muscle
Replies: 3
Views: 271

Re: Default activation error in DeGrooteFregly2016Muscle

Hi Rick,

You need to use `set_default_activation()` here. `setActivation()` sets the activation for the current state, not the default activation.

Best,
Nick
by Nicholas Bianco
Fri Aug 16, 2024 10:53 am
Forum: OpenSim
Topic: Default activation error in DeGrooteFregly2016Muscle
Replies: 3
Views: 271

Re: Default activation error in DeGrooteFregly2016Muscle

Hi Rick, The default activation check is a check we perform internally for the model. In most OpenSim simulations (not necessarily Moco), you don't want muscle controls to get too small to avoid singularities in the muscle dynamics. To avoid the error, simply set the default activation for DELT1 in ...
by Nicholas Bianco
Fri Aug 16, 2024 10:49 am
Forum: OpenSim
Topic: MocoTrack noisy actuators controls
Replies: 4
Views: 399

Re: MocoTrack noisy actuators controls

Hi Mohammadreza, If you have large residuals in ID, then it is unlikely that you will be able to achieve fully smooth controls by tracking the markers and GRFs tightly. Since you are enforcing the residuals to be small, the dynamic inconsistencies have to be made up somewhere. If you want smoother c...
by Nicholas Bianco
Thu Aug 15, 2024 1:24 pm
Forum: OpenSim
Topic: MocoTrack noisy actuators controls
Replies: 4
Views: 399

Re: MocoTrack noisy actuators controls

Hi Mohammadreza, The actuator controls don't seem particularly "noisy", but there are certainly spikes at a some time points. Since you are running the problem with weak residuals and tightly tracking markers and GRFs, the model will need to adjust the controls (compared to ID) in order to maintain ...
by Nicholas Bianco
Wed Aug 14, 2024 10:06 am
Forum: OpenSim
Topic: Using a Custom OpenSim Build
Replies: 7
Views: 16337

Re: Using a Custom OpenSim Build

I'm happy to help get over those hurdles whenever you encounter them!

It would be nice to update the Dockerfile on opensim-core, so it would be useful to know that the whole process is working for you.
by Nicholas Bianco
Tue Aug 13, 2024 5:41 pm
Forum: OpenSim Moco
Topic: MoCoInverse : Objective Function not Converging
Replies: 9
Views: 1313

Re: MoCoInverse : Objective Function not Converging

Hi Siva, I would recommend starting with larger reserve actuator strengths and then plotting the results of each simulation to try to better understand why the problem did not converge or achieve the expected motion. I would also try running the simulation with and without the constant applied force...
by Nicholas Bianco
Tue Aug 13, 2024 5:35 pm
Forum: OpenSim
Topic: Using a Custom OpenSim Build
Replies: 7
Views: 16337

Re: Using a Custom OpenSim Build

Docker/Singularity is actually the best way to go! You'll first need to create a Docker image and host it on Docker Hub. To do that, you'll first need to write a Dockerfile to create a Docker image that will contain your OpenSim build. Here is an example Dockerfile for building OpenSim . It is a bit...