-
Notifications
You must be signed in to change notification settings - Fork 32
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
Applying reduction GLPK_MI appears to be in an infinite loop #117
Comments
Here is a fairly small problem which induces this behavior Maximize: Subject to: |
This is the |
Sorry, Are you saying my example doesn't qualify as reasonably sized, complete or reproducible? |
Describe the bug
I am using cvxpy (latest version) to solve a very large mixed integer problem for some of the subsets of data I get stuck on the "Applying reduction GLPK_MI" step. By get stuck I mean the code seems to be running indefinitely and clicking the interrupt button in my notebook won't kill it. I have to restart my cluster to get out of this. Most times things work perfectly, but for a few of my subsets I get this problem.
To Reproduce
It would be difficult to put that here. I have tried to find a minimal example which creates this issue, but so far the smallest one I can find is 1393 variables, 883 constraints.
Expected behavior
I expect that if my constraints are infeasible, that the problem will tell me that so that I can remove some constraints and try again. But I'm in the worst possible case, no errors, so I can't use a try:, except: block. It just gets stuck.
Output
(CVXPY) Sep 26 07:56:41 PM: Your problem has 1393 variables, 883 constraints, and 0 parameters.
(CVXPY) Sep 26 07:56:41 PM: It is compliant with the following grammars: DCP, DQCP
(CVXPY) Sep 26 07:56:41 PM: (If you need to solve this problem multiple times, but with different data, consider using parameters.)
(CVXPY) Sep 26 07:56:41 PM: CVXPY will first compile your problem; then, it will invoke a numerical solver to obtain a solution.
(CVXPY) Sep 26 07:56:42 PM: Compiling problem (target solver=GLPK_MI).
(CVXPY) Sep 26 07:56:42 PM: Reduction chain: FlipObjective -> Dcp2Cone -> CvxAttr2Constr -> ConeMatrixStuffing -> GLPK_MI
(CVXPY) Sep 26 07:56:42 PM: Applying reduction FlipObjective
(CVXPY) Sep 26 07:56:42 PM: Applying reduction Dcp2Cone
(CVXPY) Sep 26 07:56:43 PM: Applying reduction CvxAttr2Constr
(CVXPY) Sep 26 07:56:43 PM: Applying reduction ConeMatrixStuffing
(CVXPY) Sep 26 07:56:49 PM: Applying reduction GLPK_MI
(It is now 08:10 PM and my notebook is still "running command", most problems of this size finish in about 5 seconds.)
Version
I'm running in python 3.8 via a databricks notebook, spark runtime version 10.3. I'm using the latest versions of cvxpy and cvxopt
The text was updated successfully, but these errors were encountered: