Tuesday, May 7, 2019

Mosek in Pyomo and Wasserstein distances

Pyomo is an open-source package for modeling optimization problems. You can read about its capabilities here.

The latest release of Pyomo supports MOSEK as a solver for linear, quadratic and quadratically constrained convex problems and their mixed-integer versions. This is thanks to a plugin prepared by our student employee Harun Kivril and thanks to the efforts of the Pyomo development team.

On this occasion we made two notebooks showcasing the use of our own Fusion API, of CVXPY and of Pyomo to model the same problem, namely finding the Wasserstein barycenter of discrete probability distributions, or, in our example application, averaging a set of images of the same handwritten digit.

The first notebook implements a linear Wasserstein barycenter problem in Fusion, CVXPY and Pyomo:

The second one implements an entropy-regularized version of the problem using the exponential cone capability available through Fusion and CVXPY: