-
-
Notifications
You must be signed in to change notification settings - Fork 481
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Move optional sage optimization backends (COIN, CPLEX, Gurobi) to separate Cython packages to remove OptionalExtension problems #28175
Comments
comment:1
Can you be more precise on your plans. These backends are used in graphs. So what will happen if linear programming backends are in a separate package ? |
comment:2
Replying to @dcoudert:
In my plan, the backends would be a standard package of the sage distribution, and the cython modules it provides would be automatically imported when MixedIntegerLinearProgram is used. |
This comment has been minimized.
This comment has been minimized.
comment:5
For glpk it looks like https://github.com/biosustain/swiglpk/releases is the best maintained. Excluding sage and cvxopt. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
comment:8
I have prepared a first module, https://github.com/mkoeppe/sage-numerical-backends-coin. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
comment:10
Is there a git branch to try, replacing Sage's current COIN-OR backend with this one? |
comment:11
Not yet (working on it right now), but the 3 backends already pass their test suites separately. |
Branch pushed to git repo; I updated commit sha1. New commits:
|
Commit: |
comment:14
Now the packages can be installed using |
comment:15
remains of copypaste, I see |
Branch pushed to git repo; I updated commit sha1. New commits:
|
Author: Matthias Koeppe |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:51
There's a new version of the gurobi package now. I have done some testing on Linux now, but I could not do a full test with a Gurobi license because it does not like to generate license keys on a Docker container. I have revised thee installation instructions to include Linux: |
comment:52
Replying to @dimpase:
Sure. The package looks at |
This comment has been minimized.
This comment has been minimized.
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:55
Just updated the cplex backend. |
comment:56
I suggest using a namespace package for this. See https://packaging.python.org/guides/packaging-namespace-packages/
|
comment:57
Replying to @isuruf:
Thanks a lot! I was briefly looking into this before I created the new packages, but was discouraged by various warnings on this page that seemed to imply one needs control of all packages sharing a namespace simultaneously. But I want the packages to work also with versions of sagelib that are already released. |
comment:58
The diff above is for "1. native namespace package".
This should work in the case of sagelib already released and if the optional extension is already installed, it will be overriden I think. |
comment:59
Replying to @isuruf:
Thanks. This seems to be for Python 3 only, which would conflict with the goal of my packages to support older released versions such as sage 8.1 on Ubuntu bionic. But I'll keep it in mind for the future. |
comment:60
Thanks for the pull request at sagemath/sage-numerical-backends-coin#4 . Let's continue the discussion regarding namespace packages there. |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:62
Replying to @mkoeppe:
I consider the idea of using namespace packages beyond the scope of the present ticket. I have created ticket #28925 (Modify |
comment:64
OK, coin and gurobi work, I can't test cplex, but I think it should be OK. |
Reviewer: Dima Pasechnik |
comment:66
Thank you! |
comment:68
Sorry, I was late testing this. It works for me with Ubuntu 16.04 running Gurobi 8.1.1 and CPLEX 12.9. Question: how can I make sure that the tests involing Gurobi and cplex backends continue to work in the next dev versions of SageMath now that those files are gone from the sage library? |
Changed commit from |
comment:69
Replying to @seblabbe:
Thanks for testing!
The tests are run when you install the new packages with |
sage.numerical.backends
depends on very little from Sage. We propose to split out the optional backends (COIN, CPLEX, Gurobi) to separate Cython packages.With this ticket, sagelib no longer has the optional dependency on cbc. Instead, these new packages depend on the
sage
package (i.e., sagelib).This makes it easier to reconfigure when new solvers are installed, as sagelib does not have to be recompiled. By eliminating the use of the optional extensions mechanisms from sagelib, this will also simplify packaging binary distributions.
The new packages are on PyPI:
Development here:
See also:
sage.numerical.backends
) to separate Cython packagesCC: @isuruf @saraedum @kiwifb @dimpase @sagetrac-tmonteil @videlec @seblabbe
Component: numerical
Author: Matthias Koeppe
Branch:
1279897
Reviewer: Dima Pasechnik
Issue created by migration from https://trac.sagemath.org/ticket/28175
The text was updated successfully, but these errors were encountered: