ipab-slmc / exotica

Extensible Optimization Framework
https://ipab-slmc.github.io/exotica
BSD 3-Clause "New" or "Revised" License
149 stars 70 forks source link

Storing and loading feedback policies #634

Closed wxmerkt closed 3 years ago

wxmerkt commented 5 years ago

We need a mechanism to store and load a full policy with solution and gains. Perhaps that requires a data struct (u, K, k, x_ref). Let's have a discussion what's best to proceed. At the bare minimum, we need to be able to access K, k, and x_ref.

VladimirIvan commented 5 years ago

Agreed. Variable type return values are long overdue.

I'm hoping for a lightweight flexible solution that the solvers can populate with different data as required. Maybe based on maps of boost::any and python dictionaries in the wrapper. Possibly with a default conversion to an Eigen::MatrixXd/numpy.array of the state trajectory.

wxmerkt commented 5 years ago

I'd be happy to go with a struct that can be retrieved manually from the solver, i.e., that isn't the solution returned. Otherwise your suggestion sounds great, but is part of a larger overhaul.

wxmerkt commented 3 years ago

We've manually exposed the required quantities from the individual solvers. While a better solution with variable type returns would be nice, it's not a priority.