Skip to content

Releases: coin-or/python-mip

Python MIP 1.17

02 Mar 14:24

Choose a tag to compare

python-mip 1.17 Released 🎉

HiGHS is now a supported solver

python-mip 1.17 ships with full support for HiGHS — a high-performance,
open-source LP/MIP solver with an MIT licence. HiGHS joins CBC and Gurobi as a first-class
backend. It supports LP and MIP solve, warm-starting for LP re-solves, and the full
python-mip constraint/variable API.

HiGHS binaries are distributed via highsbox, installed automatically as an optional
dependency:

pip install mip[highs]

This work was led primarily by Robert Schwarz, with contributions from Túlio Toffolo,
Adeel Khan, Bernard Zweers, and Miguel Hisojo. The integration spanned many months
of careful incremental work — thank you all!

CBC binary distribution via cbcbox

Historically, pre-built CBC binaries lived directly in the python-mip repository, requiring
a full python-mip release for every CBC update and manual cross-platform builds.

With 1.17, CBC binary distribution is fully decoupled into
cbcbox, a dedicated companion package with pre-built
wheels for:

  • Linux x86_64 and aarch64
  • macOS x86_64 and arm64 (Apple Silicon, native — no Rosetta!)
  • Windows x64

cbcbox is installed automatically. The same architecture applies to HiGHS via highsbox.

Automated releases via GitHub Actions

Publishing a new version of python-mip to PyPI is now as simple as:

git tag v1.17.1 && git push --tags

A GitHub Actions workflow using OIDC Trusted Publisher handles building and uploading to
PyPI with no API tokens to manage.

Python 3.10–3.13 + PyPy 3.11; minimum raised to 3.10

python-mip now officially supports Python 3.10, 3.11, 3.12, 3.13 and PyPy 3.11, tested
across Linux (x86_64 and arm64), macOS (Apple Silicon), and Windows. Python 3.8 and 3.9
have reached end-of-life and are no longer supported.


Bug Fixes (cumulative 1.17 + 1.17.1)

  • GMI cut crash (CutType.GMI): scaleCutIntegral assert in Osi/Cgl. Fixed upstream.
  • CBC re-solve correctness: optimize() called multiple times could return stale results.
    Fixed by calling Cbc_reset() before each solve.
  • Empty LinExpr in constraints handled correctly (thanks Sebastian Heger, #237).
  • Windows DLL loading fixed for Python 3.8+ (os.add_dll_directory now used).
  • Stale HiGHS error message corrected to reference highsbox instead of highspy.

Upgrading

pip install --upgrade mip

For HiGHS support:

pip install --upgrade "mip[highs]"

Contributors

Thank you to everyone who contributed code, bug reports, and reviews since 1.15:

Robert Schwarz · Túlio Toffolo · Sebastian Heger · Dominik Peters ·
Adeel Khan · Bernard Zweers · Miguel Hisojo · Haroldo Santos


What's New in 1.17.1

CBC crash fix: Gomory Mixed-Integer cuts (CutType.GMI)

A crash was discovered when using CutType.GMI with recent CBC versions. The root cause was
a bug in scaleCutIntegral — a function shared by OsiCuts and CglGomory — that modified
coefficient arrays in place before asserting integrality, causing an abort() when
borderline floating-point rounding left a value just outside the 1e-9 tolerance. The fix
(pre-check all values before applying any modification) was committed directly to the upstream
COIN-OR repositories coin-or/Osi and
coin-or/Cgl and is included in cbcbox 2.910.

Updated CBC binaries via cbcbox 2.910

python-mip 1.17.1 requires cbcbox>=2.910, which ships binaries built from the latest
COIN-OR master (post-fix). The new wheels include:

  • The scaleCutIntegral crash fix in both Osi and Cgl
  • Updated CutType C enum (CT_LaGomory removed; entries renumbered) correctly reflected
    in python-mip's ffi.cdef
  • Performance improvements from recent COIN-OR master commits

cbcbox: faster CBC, simpler releases

cbcbox is now the sole distribution channel for CBC binaries. This decoupling means future
CBC improvements — algorithm enhancements, bug fixes, new COIN-OR master commits — can reach
users with a cbcbox release alone, without touching python-mip at all. The release cycle
for CBC upgrades is now:

  1. Push fix to upstream COIN-OR (coin-or/Cbc, coin-or/Cgl, coin-or/Osi, …)
  2. Bump cbcbox version and push — CI builds all platforms automatically
  3. Bump cbcbox>=X.Y in python-mip pyproject.toml and push a tag

On x86_64 (Linux, macOS, Windows), cbcbox ships two complete solver stacks per wheel:

Variant OpenBLAS kernel Description
generic DYNAMIC_ARCH runtime dispatch Compatible with any x86_64 CPU
avx2 HASWELL 256-bit AVX2/FMA Optimised for Haswell (2013+) and newer

The best variant is selected automatically at import time. The AVX2 build delivers measurable
speedups on modern hardware thanks to wider SIMD in the dense linear algebra kernels used by
Clp's simplex solver.

Full changelog: https://github.com/coin-or/python-mip/blob/master/CHANGELOG.md

PyPI: https://pypi.org/project/mip/1.17.1/

1.16.0 pre

17 Feb 22:55

Choose a tag to compare

1.16.0 pre Pre-release
Pre-release

This release includes:

  • Initial support for the HiGHS solver, a contribution from Robert Schwarz
  • Initial support for Mac M1/M2/M3

1.15.0

04 Jan 13:44
6044fc8

Choose a tag to compare

What's Changed

Full Changelog: 1.14.3...1.15.0

1.14.2

21 Dec 21:14

Choose a tag to compare

What's Changed

New Contributors

Full Changelog: 1.14.1...1.14.2

Release 1.14.1

30 Aug 11:58

Choose a tag to compare

What's Changed

New Contributors

Full Changelog: 1.14.0...1.14.1

1.14.0

17 Jun 15:42
7d39771

Choose a tag to compare

What's Changed

New Contributors

Full Changelog: 1.13.0...1.14.0

1.13.0

22 Nov 21:20

Choose a tag to compare

Mostly a bugfix release, all users are encourage to update:

  • updated CBC binaries; seems to fix some longstanding bugs in MacOS
  • documentation fixes
  • fix gurobi detection
  • fix query of LinExpr.violation when no solution is available

1.12.0

13 Sep 01:04

Choose a tag to compare

  • ability to read and write LP optimal basis files (.bas extension)
  • speedup gurobi initialization, thanks @jurasofish
  • fix for querying column contents in callbacks, thanks @rodoufu
  • fix for mip gap, thanks @nick-gorman
  • fix for cbc in dense conflict graphs

1.11.0

05 Aug 23:30

Choose a tag to compare

Python-MIP 1.11.0

  • Two additional parameters, three depth and pass number, are now informed to the generage_constrs method in ConstrsGenerator class (which is used for cut/lazy constraints callbacks). Thus, strategies that generate more/less cuts at a given depth can use this information. See here .

  • Cut generators: additional cut generators can now be called at the root node in customized cutting planes algorithms, see here .

  • Instance features: it is now possible to query a vector of instance features. These features can be used in machine learning algorithms, for example, to decide the best parameter settings. Basic features are just the problems dimensions, e.g.: columns, rows, non-zeros. The current implementation extracts 208 instance features. To see an implementation of algorithm selection that is used in the COIN-OR Linear Programming Solver (CLP) check: Vilas Boas, M.G., Santos, H.G., Merschmann, L.H.C. and Vanden Berghe, G. Optimal Decision Trees for the Algorithm Selection Problem: Integer Programming Based Approaches. International Transactions in Operational Research, DOI 10.1111/itor.12724. 2019.

1.10.0

22 Jul 01:32

Choose a tag to compare

This release release adds a new model method: clique_merge, which merges constraints of conflicting variables (usually set packing) to produce a more compact and stronger formulation.

Two new stopping criteria were added: max nodes/seconds without improving the incumbent solution.

We also added more tests and fixed some bugs in the Cbc C Interface.