Static Optimization : physical weakness

Provide easy-to-use, extensible software for modeling, simulating, controlling, and analyzing the neuromusculoskeletal system.
POST REPLY
User avatar
Pierre Lamouri
Posts: 13
Joined: Tue Oct 16, 2012 4:09 am

Static Optimization : physical weakness

Post by Pierre Lamouri » Wed Jan 02, 2013 12:39 am

Hi everybody,

I am using the Vasavada’s neck model, and I am trying to perform Static Optimization (SO). Nevertheless, in most cases, the optimization does not succeed because the muscles are weak, and that’s why my SO takes always a very long time to converge (or sometimes never converge at all). Moreover, SO failed on each frame. This is an extract of the error message I showed:

-----------------------------------------------------------------------------------------------------------------------------------------------
time = 3 Performance =7.92019 Constraint violation = 7.3747
SimTK Exception thrown at InteriorPointOptimizer.cpp:261:
Optimizer failed: Ipopt: Infeasible problem detected (status 2)
OPTIMIZATION FAILED...

StaticOptimization.record: WARN- The optimizer could not find a solution at time = 3.1

The model appears too weak for static optimization.
Try increasing the strength and/or range of the following force(s):
long_cap_sklc4 approaching upper bound of 1
long_cap_sklc4_l approaching upper bound of 1
-----------------------------------------------------------------------------------------------------------------------------------------------

When I checked the Opensim Userguide on “Getting Started with Static Optimization”, I found this paragraph; I believe my problem matches with this description (because my ID results did not show large torques)

" 1. If the residual actuators are weak, increase the maximum control value of a residual, while lowering its maximum force. This allows the optimizer to generate a large force (if necessary) to match accelerations, but large control values are penalized more heavily. In static optimization, ideal actuator excitations are treated as activations in the cost function.
2. If the muscles are weak, append Coordinate Actuators to the model at the joints in the model. This will allow you to see how much "reserve" actuation is required at a given joint and then strengthen the muscles in your model accordingly.
3. If troubleshooting a weak model and optimization is slow each time, try reducing the parameter that defines the maximum number of iterations. "


In the light of this description, I believe I am involved by the points 1 and 2, even if I am not sure. I didn’t know how to formulate my question, and then I thought it may be better to number them:

1) Do the muscle are actuators? Because on the Opensim’s GUI, the navigator’s tree cannot extend “actuator”, but when I run a simulation (SO or FD for example) I can read on the message box: “ACTUATORS (78) actuator[0] = stern_mast actuator[1] = cleid_mast actuator[2] = cleid_occ etc.”

2) Does anybody know how can I append “Coordinate Actuator” on my model? Must I add this on my osim model or in my xml settings? I am sorry but I do not figure out this point.

3) I have two different motions for the same movement (neck’s extension-flexion): the first one has been obtained by several frames with fixed value of coordinates. I got the other one with the traditional method with markers and IK. With these two motions, I get two ID results clearly different. The first one gives me constant torques (I had always a warning on the messagebox : WARNING- Did not find column <name of the joint> in storage object.) whereas the second seems OK (I attached the results on this post). Does it means that my first motion must not be used on SO?

4) As I failed to perform a SO on Opensim with the Neck Model, I tried to do exactly the same thing with the Gait2354_Simbody tutorial’s model. But once more, it didn’t work. The only thing I did was to input the motion “subject01_walk1_ik”, exactly how I do with my neck model (with the motion appropriate of course) May I have miss a step in both cases?

I am sorry if my problem has been shown several times but I did not manage to fix it myself. Thank for people who could give me some advices!!

Happy new year,

Pierre

User avatar
Ayman Habib
Posts: 2248
Joined: Fri Apr 01, 2005 12:24 pm

Re: Static Optimization : physical weakness

Post by Ayman Habib » Mon Jan 07, 2013 1:08 pm

Hi Pierre,

1. Yes, muscles are actuators.
2. You can do it in either the model .osim file (and they will live with the model for good) or in the tool (which would be preferrable). The files provided in the gait2354 example show how to add Actuators to degrees of freedom during RRA or CMC, similar format can be used for your model and added as "<force_set_files>".
3. We need more context but the erroe message may indicate that some coordinates are not have been specified in your input file (may because of a typo if you believe the coordinate s actually specified in the motion file).
4. We had a webinar showing how to run SO on the gait model (and it requires adding actuators as well). The files used by the webinar are posted on simtk.org along with release 2.4 at https://simtk.org/project/xml/downloads.xml?group_id=91 and they should work with version 3.0 as well.

Best of luck,
-Ayman

User avatar
Pierre Lamouri
Posts: 13
Joined: Tue Oct 16, 2012 4:09 am

Re: Static Optimization : physical weakness

Post by Pierre Lamouri » Fri Jan 11, 2013 9:46 am

Hi Ayman and all,

Ayman, thank you for your answer. Following Opensim gaitmodel Actuator's structure, I created 6 "CoordinateActuators" corresponding to my 6 DOF, and I append them to my osim model. Then my StaticOptimization worked at last. This is an example of one of my actuators :

<CoordinateActuator name="pitch">
<!--Flag indicating whether the force is disabled or not. Disabled means that the force is not active in subsequent dynamics realizations.-->
<isDisabled>false</isDisabled>
<!--Minimum allowed value for control signal. Used primarily when solving for control values.-->
<min_control>-Inf</min_control>
<!--Maximum allowed value for control signal. Used primarily when solving for control values.-->
<max_control>Inf</max_control>
<!--Name of the generalized coordinate to which the actuator applies.-->
<coordinate>pitch</coordinate>
<!--The maximum generalized force produced by this actuator.-->
<optimal_force>1000</optimal_force>
</CoordinateActuator>


However, I have noted that the activations I receive in SO output depend to the <optimal_force> parameter.I performed several SO with an optimal force equal to 1000, 10 and another one to 1, and they were all clearly differents. It seems the more <optimal_force> parameter is high, the less some of my muscles's activations are (I attached 2 png files of my curves to illustrate that). So here is my question : how can I know what value this parameter must have to give the "good one" SO ?

Thank you. Sorry for my poor English.

Pierre.
Attachments
SO_output_Activation_opt_force_10.png
Neck muscles activation during a complete extension/flexion movement of the head. With "optimal_force" = 10
SO_output_Activation_opt_force_0.5.png
Neck muscles activation during an extension/flexion movement of the head. With "optimal_force" = 0.5

User avatar
Alessandra Scarton
Posts: 3
Joined: Mon Feb 18, 2013 5:11 am

Re: Static Optimization : physical weakness

Post by Alessandra Scarton » Mon Jul 21, 2014 2:44 am

Hello everybody,
I am working on static optimization and I encountered the same problem asked in the previous post by Lamourip. I have noticed that muscles' activations which I get as output of the SO depend on the <optimal_force> parameter. I also performed several SO with different optimal force values and the results were always different in particular, as already told by Lamourip, muscles' activations decrease with the increase of the <optimal_force> parameter.
So the question is how is this parameter set and determined? What is the best value to choose in order to be confident with the results of SO?

Thank you

Alessandra

POST REPLY