Ask Your Question

Gains optimization package?

asked 2014-08-05 11:26:09 -0600

arennuit gravatar image

Hi all,

I am looking for a package allowing to optimize gains for a given robot (or a simulated robot) - such as low-level PID gains. The idea is to provide init gains to the package and a cost function to optimize (typically including a component for the "tracking speed" and another one for the "stability") and then to let the package optimize by performing thousands of cycles overnight with different gains so as to converge to an optimum (using gradient descent or whatever relevant method).

Do you know about anything looking like that?



edit retag flag offensive close merge delete


I would love to see an integration with Mathematica's PIDTune, especially because "Wolfram Programming Cloud" is free now.

prosa100 gravatar image prosa100  ( 2014-08-05 15:21:37 -0600 )edit


arennuit gravatar image arennuit  ( 2014-08-06 02:29:52 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2014-08-07 10:58:12 -0600

Adolfo Rodriguez T gravatar image

This is a partial answer, but hopefully will point in the right direction.

Many PID tuning tools (like Mathematica's or Matlab's) require as input the plant model. Typically you don't have the plant model, so it's something you have to experimentally identify. Again, there are tools out there for doing this. From the ROS side, what would be desirable then is tooling to simplify the process of gathering the data for identifying the plant.

There are some very basic building blocks you can leverage, but it's not a press-play solution, you need to stitch the parts together yourself. For instance, the control_toolbox package has a tool for doing sine sweeps, which can be fed to the actuators and the recorded output in turn fed to an identification tool.

Since PID tuning is not something you do all the time, a tight coupling with the identification and tuning tool is not required IMO. Having something that excites your plant and records the data in a format usable by these tools should be enough. This is still a fair amount of work, and I've never tried it in simulation.

edit flag offensive delete link more


Hi Adolfo, thanks for you answer. I am not sure I understand the need for sine sweeps : (I am not an expert in identification but) the main methods for identification do not imply spectrum analysis, do they? Or are you talking about approaches like which I thought exotic?

arennuit gravatar image arennuit  ( 2014-08-08 04:05:28 -0600 )edit

For identification, you need some control input (velocity, position, etc). Sine is used quite often for this purposes. Another approach might be pseudorandom binary sequence.

ZdenekM gravatar image ZdenekM  ( 2014-08-11 04:30:05 -0600 )edit

@ZdenekM: interesting thnaks ;)

arennuit gravatar image arennuit  ( 2014-08-11 05:20:04 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools



Asked: 2014-08-05 11:26:09 -0600

Seen: 133 times

Last updated: Aug 07 '14