PuLP does not correctly read a class of MPS files in MILIB2017
- Dominant language
- Python
- Stars
- 2.5k
- Forks
- 432
- PR merge metrics
- No merged PRs in 30d
Description
Details for the issue
--------------------
#### What did you do?
I used PuLP to read the MPS files for MIPLIB2017 problems such as [beasleyC3](https://miplib.zib.de/instance_details_beasleyC3.html). I then used PuLP to call solvers to optimize the model. I also used PuLP to write the MPS file back to disk without optimizing it and used multiple MIP solvers to solve the MPS file that was written back to disk.
#### What did you expect to see?
I expected to see the objective value of 754, which is known to be optimal. If I use a solver on the MPS file downloaded directly from MIPLIB2017, this value is achieved.
#### What did you see instead?
If PuLP is used to dispatch a solver after reading the MPS file, the solution reported is less than 50. If a MIP solver is used on its own to solve the MPS file that PuLP wrote to disk after reading in the beasleyC3 problem's MPS file, the MIP solver reports a solution that is less than 50.
This implies that PuLP is not reading the file correctly. I found that this is the case for multiple MIPLIB2017 problems that have no integer variables but do have binary variables.
Useful extra information
-------------------------
The info below often helps, please fill it out if you're able to. :)
#### What operating system are you using?
- [ x] Windows: (11)
#### I installed PuLP via:
- [ x] pypi (python -m pip install pulp)
#### Did you also
- [x ] Searched for an existing similar issue: https://github.com/coin-or/pulp/issues?utf8=%E2%9C%93&q=is%3Aissue%20
Contributor guide
Research direction
Reproduce the issue by reading the MIPLIB2017 beasleyC3 MPS file with PuLP, solving it, and writing it back for an independent MIP solver. Trace the MPS-reading path for files with binary variables but no integer variables; done means PuLP and the rewritten file achieve the expected objective value of 754.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100