Hexaly Optimizer 15.0

Release notes

  • Adds new parameter gapLimit as a termination criterion.
  • Gradients can now be provided for differentiable external functions that return a double value.
  • The Python API now includes type annotations.
  • The minimum required version to use the Python API is now Python 3.8. Support for Python 3.6 and 3.7 has been discontinued.
  • .NET Standard 2.0 is now required to use the C# API. Support for .NET Framework prior to 4.6.1 has been discontinued.
  • Adds a new method sort to Hexaly Modeler, to sort the values in a map.
  • Hexaly is now available on PyPI, Maven Central, and NuGet.

New parameter

HxParam.gapLimit

Optimality gap used as a termination criterion. When the solver detects that the current gap is below this limit, the current solution is considered optimal.

Double external functions with gradients

For external functions returning a double value and known to be differentiable, it is now possible to provide their gradients. See Providing gradients for more details.

Python type annotations

Python has historically been a dynamically typed language. However, for several years now, Python has supported annotations that enable static code verification.

The Python API in Hexaly 15.0 now includes annotations on all public functions and classes. These are compatible with mypy and pylance/pyright. In addition, and to make the API easier to use in a typed code context, shortcuts for certain methods has been introduced.

For instance the method HxSolution.get_value() has also been adapted into new specialized methods:

Similar changes have been made to all methods in the API that could return a union of value types. For those who do not wish to code in Python using types, the existing methods remain unchanged and are in no way deprecated.

Hexaly Distribution on PyPI, NuGet, and Maven Central

To help our users get started with Hexaly more quickly and make deployment as simple as possible, Hexaly Optimizer and Hexaly Modeler are now available from the official PyPI, NuGet, and Maven Central repositories.

The packages published on these platforms are fully self-contained. In other words, if you only need to deploy Hexaly in your preferred language on all the supported operating systems and architectures (Windows, Linux, macOS), you no longer need to use the installer. However, you will still need to specify a license file or provide its contents using one of the methods detailed in HxVersion.

Our previous PIP repositories hosted on https://pip.hexaly.com and https://pip.localsolver.com will remain active and will continue to host Hexaly binaries prior to 15.0, but will no longer host any new versions.

API Changes

Hexaly Modeler

Python

Java

  • Added HxParam.setGapLimit and HxParam.getGapLimit methods
  • Added HxDoubleExternalGradient interface
  • Added new method signatures to HxModel.createDoubleExternalFunction and HxModel.doubleExternalFunction