Skip to content
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

Handle Gurobi Environments #3

Open
peno64 opened this issue Nov 4, 2023 · 1 comment
Open

Handle Gurobi Environments #3

peno64 opened this issue Nov 4, 2023 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@peno64
Copy link

peno64 commented Nov 4, 2023

With following python file:

import sys
import gurobipy as gp
import gurobi_modelanalyzer as ma
m=gp.read(sys.argv[1])
m.optimize()
print('kappa_explain1')
ma.kappa_explain(m)
print('kappa_explain2')
ma.kappa_explain(m, expltype="COLS")
print('angle_explain')
ma.angle_explain(m)

With attached file:
oops1.mps.txt

I get the following error:

...
Solved in 0 iterations and 0.00 seconds (0.00 work units)
Optimal objective  1.000000000e+00
Vector matrix product of certificate of ill conditioning and basis:
ZTHREE
Traceback (most recent call last):
  File "D:\brol\modelanalyzer.py", line 7, in <module>
    ma.kappa_explain(m)
  File "C:\Users\peno\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\gurobi_modelanalyzer\results_analyzer.py", line 421, in kappa_explain
    refine_output(resmodel, yvaldict, expltype, submatrix)
  File "C:\Users\peno\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\site-packages\gurobi_modelanalyzer\results_analyzer.py", line 1640, in refine_output
    contoadd = condict[conname]
               ~~~~~~~^^^^^^^^^
KeyError: '(mult=1.0)MYEQN'
...

Note that I run this on a windows 11 computer with the latest version of this tool (I did a pip install today)
The gurobi version is 10.0.3 (running on a compute server)
The python version is: 3.11.6

I get this error for almost all my models I test.

@mattmilten
Copy link
Member

This is an issue with model handling in Compute Server environments. The code is not yet compatible with Gurobi Compute Server.

Thanks for bringing this up!

@mattmilten mattmilten added the bug Something isn't working label Nov 6, 2023
@torressa torressa changed the title Getting an error Handle Gurobi Environments Sep 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants