Walking simulations with feedback control

Provide easy-to-use, extensible software for modeling, simulating, controlling, and analyzing the neuromusculoskeletal system.
POST REPLY
User avatar
Ross Miller
Posts: 375
Joined: Tue Sep 22, 2009 2:02 pm

Walking simulations with feedback control

Post by Ross Miller » Wed Aug 12, 2020 5:55 am

Hi all,

I think the answer to my question is "yes" generally speaking, but wanted to check with anyone who has actually done it in practice.

A student and I are interested in generating muscle-actuated simulations of walking that have feedback controls, i.e. the muscle excitations u are u = f(x,t) instead of u = f(t), where x is the state of the model. Is this possible?

More specifically, we'd like to first generate a set of excitations without feedback, u = f(t), that produces a well-coordinated walking gait, using standard tracking methods, e.g. CMC or Moco if possible. We would then like to have the user specify an arbitrary form of the feedback control functions, u = f(x,t), and through some sort of least-squares minimization or just hand-tuning, adjust the feedback function parameters so that u = f(x,t) resembles the originally well-coordinated controls closely. I'm imaging this latter step would be done in the Matlab interface.

Has anyone successfully done something like this with OpenSim/Matlab in the past?

Thanks much!
Ross

Tags:

User avatar
Dimitar Stanev
Posts: 1096
Joined: Fri Jan 31, 2014 5:14 am

Re: Walking simulations with feedback control

Post by Dimitar Stanev » Thu Aug 13, 2020 12:22 am

Hi Ross,

Yes, it is possible to some extend. You can control the model by providing the muscle excitations and stepping the integrator manually. It has been done with the osim-rl project in Python:

https://github.com/stanfordnmbl/osim-rl ... sim.py#L19

However, keep in mind that there is a small drawback of this approach compared to the native C++ implementation. With C++ you can create a new controller that is evaluated each time the numerical integration takes a step. With the osim-rl approach one provides u(t) given x(t) at time = t and then predicts x(t + dt) keeping u(t) constant between t and t + dt.

Alternatively, you can do function approximation given that you know u, x for each t without OpenSim. Although, the last might not necessarily mean that f(x, t) produces stable solutions. How do you plant to ensure that your feedback controller is stable?

Regards,
Dimitar

User avatar
Ross Miller
Posts: 375
Joined: Tue Sep 22, 2009 2:02 pm

Re: Walking simulations with feedback control

Post by Ross Miller » Thu Aug 13, 2020 6:32 am

Thanks Dimitar!

POST REPLY