ommx.mps
========

.. py:module:: ommx.mps


Functions
---------

.. autoapisummary::

   ommx.mps.load_file
   ommx.mps.write_file


Module Contents
---------------

.. py:function:: load_file(path: str) -> ommx.Instance

.. py:function:: write_file(instance: ommx.Instance, path: str)

   Write the active formulation to a gzip-compressed MPS file.

   Equivalent to :meth:`instance.save_mps(path) <ommx.Instance.save_mps>`.
   Compression is enabled regardless of the filename extension. Use
   :meth:`ommx.Instance.save_mps` with ``compress=False`` for plain text.

   The writer accepts linear and quadratic objectives and regular constraints,
   subject to that method's variable-kind and special-constraint restrictions
   and quadratic coefficient convention.
   See :meth:`ommx.Instance.save_mps` for the exact supported models, errors,
   variable filtering, and information lost during export.


