11

I have used Gurobi and cplex for solving large scale LP problems with Pyomo. However, I do need to use open source solver. Any advise? glpk and cbc seems to be very slow in solving the problem (with 2e6 variables)

SecretAgentMan
  • 1,895
  • 2
  • 13
  • 39
Optimization team
  • 1,326
  • 1
  • 6
  • 20
  • You probably need a good interior-point optimizer. I do not think any good open source interior-point code is available. Shameless promotion: Mosek.com is likely to be cheaper than the other commercial offerings. – ErlingMOSEK Aug 16 '21 at 07:42
  • 2
    Did you try the barrier algorithm in Clp/Cbc (assuming this is a pure LP)? For large problems, this may be faster than the Simplex method. (But not as fast as Mosek). – Erwin Kalvelagen Aug 16 '21 at 12:50
  • 1
    A Pyomo interface to HiGHS has been developed. Rather than hosting it ourselves, we suggested that it is made available via the Pyomo community. I'm in the process of tracking down whether this has happened. GLPK is a very poor LP solver. – SparseRunner Sep 17 '21 at 12:02

4 Answers4

12

There is a new open source solver that looks quite promising, HiGHS:

https://www.maths.ed.ac.uk/hall/HiGHS/

But as pointed out by others, for mixed-integer programming problems, at the moment, open-source solvers can't compete on performance and reliability with commercial solvers.

Philipp Christophel
  • 3,188
  • 8
  • 24
  • 1
    I have clearly mentioned LP (not MILP ) I also know that open source solvers can't compete with commercial ones – Optimization team Aug 16 '21 at 16:10
  • 3
    LP problems feature in HiGHS. If you have questions about this particular solver I'm sure @SparseRunner or @ MichaelFeldmeier would be happy to answer. – ə̷̶̸͇̘̜́̍͗̂̄︣͟ Aug 16 '21 at 18:53
  • 3
    Note also that HiGHS can easily be called from scipy.optimize.linprog. – joni Aug 16 '21 at 18:57
  • Does HiGHS link with Pyomo ? – Optimization team Aug 16 '21 at 21:51
  • Someone has been developing a Pyomo interface to HiGHS. We suggested that they make it available via the Pyomo community. I'm in the process of tracking down whether this has happened. – SparseRunner Sep 17 '21 at 11:56
  • Not open-source mip solver but I was able to model mip problem in cp-sat solver and performance was slower but comparable to gurobi solver. Of course I was maybe lucky but no free mip solver was able to compete. Maybe users should give a try to other types of solvers (sat, constraint solvers ...). – gregy4 Jan 12 '22 at 16:44
  • 1
    Any update on HiGHS-Pyomo linkage/interface ? – Optimization team Jul 08 '22 at 12:54
  • Is there a resource/tutorial on how one can use such a solver having just theoretical background on LP? I have use solvers like MOSEK and Gurobi indirectly by formulating my problem in Python or Julia but its highly non-trivial how to use HiGHS. – Marion Sep 27 '22 at 23:15
9

The Mittlemann benchmarks are an excellent benchmark as ever in particular these two:

Note that Pyomo doesn't have bindings for most of these locally. If you are just looking for high-level modeling language and are not tied to Python you could use the JuMP modeling language instead which uses Julia. Julia's excellent package system means many Open Source solvers are only an ]add Tulip, ]add Ipopt, ]add HiGHS (you should be aware this binding it is still under active development see GitHub for details) or ]add Clp in the command line away.

worldsmithhelper
  • 4,007
  • 6
  • 21
3

If you mean by LP is referred to the linear programming (not mixed-integer linear programming), there are some open-source solvers like SoPlex and Clp which can be linked with Pyomo via Neos server but, I really do not know is there any way to connect those locally. If you meant is the mixed-integer linear programming one of the best options is SCIP, but as far as I know it's not quite free at all.

A.Omidi
  • 8,832
  • 2
  • 13
  • 49
3

For large LPs you need an interior point solver.

On top of what others have mentioned, you can use CLP's interior point method, or, interestingly, just plain old IPOPT can work perfectly fine since it will also apply an interior point algorithm.

Nikos Kazazakis
  • 12,121
  • 17
  • 59