Replies: 1 comment
-
HiGHS is now implemented in PyPSA. See: PyPSA/PyPSA#308 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
The HiGH solver is ranked on the industry standard benchmarks http://plato.asu.edu/bench.html <http://plato.asu.edu/bench.html . Adding the solver to PyPSA is nice test and programming exercise. Therefore, a great learning experience!
@fneum (PyPSA) about adding HIGH's as solver:
A nice test and programming exercise!
It seems HiGHS has the option to run an .lp file from the command-line
or using a python interface. Both is possible with PyPSA.
For command-line, have a look at lines
https://github.com/PyPSA/PyPSA/blob/master/pypsa/linopt.py#L604-L659
For python API, have a look at lines
https://github.com/PyPSA/PyPSA/blob/master/pypsa/linopt.py#L793-L863
The benchmark is the clp/cbc solver that it needs to surpass to be
interesting.
https://co-at-work.zib.de/slides/Montag_21.9/HiGHS%20slides%20(1).pdf
From this presentation, it looks like there is a performance gap to
Clp/Cbc.
As settings we usually use barrier/ipm, no crossover to simplex and
sometimes no pre-solving.
If you are serious about it, open a draft PR with a first issue on the
PyPSA repository so we can discuss the implementation.
Main challenges are finding out how to read the .lp file, pass the
solver options, and reading back in the optimisation results.
Other links for reference:
https://www.maths.ed.ac.uk/hall/HiGHS/#top
https://github.com/ERGO-Code/HiGHS
Python API
https://github.com/ERGO-Code/HiGHS/blob/master/src/interfaces/highs_python_api.py
Python Example
https://github.com/ERGO-Code/HiGHS/blob/master/examples/call_highs_from_python.py
Some more info from me [Max]:
Benchmark, comparing solvers: http://plato.asu.edu/bench.html (where you might find even other open solvers)
Some google lp solvers https://github.com/google/or-tools/tree/stable/ortools/linear_solver that could be also integrated (thanks @mnm-matin for sharing the google solver - he implemented it already for a project)
Beta Was this translation helpful? Give feedback.
All reactions