PICOS


NamePICOS JSON
Version 2.5.1 PyPI version JSON
download
home_pageNone
SummaryA Python interface to conic optimization solvers.
upload_time2024-11-04 06:42:19
maintainerNone
docs_urlNone
authorG. Sagnol, M. Stahlberg
requires_python>=3.4
licenseNone
keywords conic optimization convex optimization robust optimization semidefinite programming
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            Introduction
============

PICOS is a user friendly Python API to several conic and integer programming
solvers, designed to be used by both application developers and researchers as
well as instructors teaching courses on mathematical optimization. It allows you
to enter an optimization problem as a **high level model**, with painless
support for **(complex) vector and matrix variables** and **multidimensional
algebra**. Your model will be transformed to the standard form understood by an
appropriate solver that is available at runtime. This makes your application
**portable** as users have the choice between several commercial and open source
solvers.

Features
--------

PICOS supports the following solvers and problem types. To use a solver, you
need to separately install it along with the Python interface listed here.

.. _Apache-2.0: https://www.apache.org/licenses/LICENSE-2.0
.. _GPL-3: https://www.gnu.org/licenses/gpl-3.0.html
.. _MIT: https://opensource.org/licenses/MIT
.. _ZIB: https://scip.zib.de/academic.txt

.. list-table::
    :header-rows: 1

    * - | Solver
        |
      - | Python
        | interface
      - | `LP <https://en.wikipedia.org/wiki/Linear_programming>`_
        |
      - | `SOCP <https://en.wikipedia.org/wiki/Second-order_cone_programming>`_,
        | `QCQP <https://en.wikipedia.org/wiki/Quadratically_constrained_quadratic_program>`_
      - | `SDP <https://en.wikipedia.org/wiki/Semidefinite_programming>`_
        |
      - | `EXP <https://docs.mosek.com/modeling-cookbook/expo.html>`_
        |
      - | `MIP <https://en.wikipedia.org/wiki/Integer_programming>`_
        |
      - | `QREP <https://en.wikipedia.org/wiki/Quantum_relative_entropy>`_
        |
      - | License
        |
    * - `CPLEX <https://www.ibm.com/analytics/cplex-optimizer>`_
      - included
      - Yes
      - Yes
      -
      -
      - Yes
      -
      - non-free
    * - `CVXOPT <https://cvxopt.org/>`_
      - native
      - Yes
      - Yes
      - Yes
      - `GP <https://en.wikipedia.org/wiki/Geometric_programming>`_
      -
      -
      - `GPL-3`_
    * - `ECOS <https://github.com/embotech/ecos>`_
      - `ecos-python <https://github.com/embotech/ecos-python>`_
      - Yes
      - Yes
      -
      - Yes
      - Yes
      -
      - `GPL-3`_
    * - `GLPK <https://www.gnu.org/software/glpk/>`_
      - `swiglpk <https://github.com/biosustain/swiglpk>`_
      - Yes
      -
      -
      -
      - Yes
      -
      - `GPL-3`_
    * - `Gurobi <http://www.gurobi.com/products/gurobi-optimizer>`_
      - `gurobipy <https://www.gurobi.com>`_
      - Yes
      - Yes
      -
      -
      - Yes
      -
      - non-free
    * - `MOSEK <https://www.mosek.com/>`_
      - included
      - Yes
      - Yes
      - Yes
      -
      - Yes
      -
      - non-free
    * - `OSQP <https://osqp.org>`_
      - native
      - Yes
      - `QP <https://en.wikipedia.org/wiki/Quadratic_programming>`_
      -
      -
      -
      -
      - `Apache-2.0`_
    * - `QICS <https://qics.readthedocs.io/en/stable/>`_
      - native
      - Yes
      - Yes
      - Yes
      - Yes
      -
      - Yes
      - `MIT`_
    * - `SCIP <http://scip.zib.de/>`_
      - `PySCIPOpt <https://github.com/SCIP-Interfaces/PySCIPOpt/>`_
      - Yes
      - Yes
      -
      -
      - Yes
      -
      - `ZIB`_/`MIT`_
    * - `SMCP <http://smcp.readthedocs.io/en/latest/>`_
      - native
      -
      -
      - Yes
      -
      -
      -
      - `GPL-3`_

.. rubric:: Example

This is what it looks like to solve a multidimensional mixed integer program
with PICOS:

>>> import picos as pc
>>> P = pc.Problem()
>>> x = pc.IntegerVariable("x", 2)
>>> P += 2*x <= 11
>>> P.maximize = pc.sum(x)
>>> P.solve(solver="glpk")  # Optional: Use GLPK as backend.
<feasible primal solution (claimed optimal) from glpk>
>>> P.value
10.0
>>> print(x)
[ 5.00e+00]
[ 5.00e+00]

You can head to our
`quick examples <https://picos-api.gitlab.io/picos/quick.html>`_ or the
`tutorial <https://picos-api.gitlab.io/picos/tutorial.html>`_ for more.

Installation
------------

As of release 2.2, PICOS requires **Python 3.4** or later.

.. rubric:: Via pip

If you are using `pip <https://pypi.org/project/pip/>`_ you can run
``pip install picos`` to get the latest version.

.. rubric:: Via Anaconda

If you are using `Anaconda <https://anaconda.org/>`_ you can run
``conda install -c picos picos`` to get the latest version.

.. rubric:: Via your system's package manager

.. list-table::
    :header-rows: 1
    :stub-columns: 1

    * - Distribution
      - Latest major version
      - Latest version
    * - Arch Linux
      - `python-picos <https://aur.archlinux.org/packages/python-picos/>`__
      - `python-picos-git <https://aur.archlinux.org/packages/python-picos-git/>`__

If you are packaging PICOS for additional platforms, please let us know.

.. rubric:: From source

The PICOS source code can be found on `GitLab
<https://gitlab.com/picos-api/picos>`_. There are only two dependencies:

- `NumPy <https://numpy.org/>`_
- `CVXOPT`_

Documentation
-------------

The full documentation can be browsed `online
<https://picos-api.gitlab.io/picos/>`__ or downloaded `in PDF form
<https://picos-api.gitlab.io/picos/picos.pdf>`__.

Credits
-------

.. rubric:: Developers

- `Guillaume Sagnol <http://page.math.tu-berlin.de/~sagnol/>`_ has started work
  on PICOS in 2012.
- `Maximilian Stahlberg <https://orcid.org/0000-0002-0190-2693>`_ is extending
  and co-maintaining PICOS since 2017.

.. rubric:: Contributors

For an up-to-date list of all code contributors, please refer to the
`contributors page <https://gitlab.com/picos-api/picos/-/graphs/master>`_.
Should a reference from before 2019 be unclear, see also the `old contributors
page <https://github.com/gsagnol/picos/graphs/contributors>`_ on GitHub.

Citing
------

The preferred way to cite PICOS in your research is our `JOSS paper
<https://joss.theoj.org/papers/10.21105/joss.03915>`_:

.. code-block:: bibtex

  @article{PICOS,
    author  = {Guillaume Sagnol and Maximilian Stahlberg},
    journal = {Journal of Open Source Software},
    title   = {{PICOS}: A {Python} interface to conic optimization solvers},
    year    = {2022},
    issn    = {2475-9066},
    month   = feb,
    number  = {70},
    pages   = {3915},
    volume  = {7},
    doi     = {10.21105/joss.03915},
  }

If citing a specific version of PICOS is necessary, then we offer also `source
deposits on Zenodo <https://doi.org/10.5281/zenodo.6052843>`_.

License
-------

PICOS is free and open source software and available to you under the terms of
the `GNU GPL v3 <https://gitlab.com/picos-api/picos/raw/master/LICENSE.txt>`_.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "PICOS",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.4",
    "maintainer_email": null,
    "keywords": "conic optimization, convex optimization, robust optimization, semidefinite programming",
    "author": "G. Sagnol, M. Stahlberg",
    "author_email": "incoming+picos-api/picos@incoming.gitlab.com",
    "download_url": "https://files.pythonhosted.org/packages/37/b7/5d03a0474e25ce97efc489adb8f9759b001b6ac6c080023b6e1420a31424/picos-2.5.1.tar.gz",
    "platform": null,
    "description": "Introduction\n============\n\nPICOS is a user friendly Python API to several conic and integer programming\nsolvers, designed to be used by both application developers and researchers as\nwell as instructors teaching courses on mathematical optimization. It allows you\nto enter an optimization problem as a **high level model**, with painless\nsupport for **(complex) vector and matrix variables** and **multidimensional\nalgebra**. Your model will be transformed to the standard form understood by an\nappropriate solver that is available at runtime. This makes your application\n**portable** as users have the choice between several commercial and open source\nsolvers.\n\nFeatures\n--------\n\nPICOS supports the following solvers and problem types. To use a solver, you\nneed to separately install it along with the Python interface listed here.\n\n.. _Apache-2.0: https://www.apache.org/licenses/LICENSE-2.0\n.. _GPL-3: https://www.gnu.org/licenses/gpl-3.0.html\n.. _MIT: https://opensource.org/licenses/MIT\n.. _ZIB: https://scip.zib.de/academic.txt\n\n.. list-table::\n    :header-rows: 1\n\n    * - | Solver\n        |\n      - | Python\n        | interface\n      - | `LP <https://en.wikipedia.org/wiki/Linear_programming>`_\n        |\n      - | `SOCP <https://en.wikipedia.org/wiki/Second-order_cone_programming>`_,\n        | `QCQP <https://en.wikipedia.org/wiki/Quadratically_constrained_quadratic_program>`_\n      - | `SDP <https://en.wikipedia.org/wiki/Semidefinite_programming>`_\n        |\n      - | `EXP <https://docs.mosek.com/modeling-cookbook/expo.html>`_\n        |\n      - | `MIP <https://en.wikipedia.org/wiki/Integer_programming>`_\n        |\n      - | `QREP <https://en.wikipedia.org/wiki/Quantum_relative_entropy>`_\n        |\n      - | License\n        |\n    * - `CPLEX <https://www.ibm.com/analytics/cplex-optimizer>`_\n      - included\n      - Yes\n      - Yes\n      -\n      -\n      - Yes\n      -\n      - non-free\n    * - `CVXOPT <https://cvxopt.org/>`_\n      - native\n      - Yes\n      - Yes\n      - Yes\n      - `GP <https://en.wikipedia.org/wiki/Geometric_programming>`_\n      -\n      -\n      - `GPL-3`_\n    * - `ECOS <https://github.com/embotech/ecos>`_\n      - `ecos-python <https://github.com/embotech/ecos-python>`_\n      - Yes\n      - Yes\n      -\n      - Yes\n      - Yes\n      -\n      - `GPL-3`_\n    * - `GLPK <https://www.gnu.org/software/glpk/>`_\n      - `swiglpk <https://github.com/biosustain/swiglpk>`_\n      - Yes\n      -\n      -\n      -\n      - Yes\n      -\n      - `GPL-3`_\n    * - `Gurobi <http://www.gurobi.com/products/gurobi-optimizer>`_\n      - `gurobipy <https://www.gurobi.com>`_\n      - Yes\n      - Yes\n      -\n      -\n      - Yes\n      -\n      - non-free\n    * - `MOSEK <https://www.mosek.com/>`_\n      - included\n      - Yes\n      - Yes\n      - Yes\n      -\n      - Yes\n      -\n      - non-free\n    * - `OSQP <https://osqp.org>`_\n      - native\n      - Yes\n      - `QP <https://en.wikipedia.org/wiki/Quadratic_programming>`_\n      -\n      -\n      -\n      -\n      - `Apache-2.0`_\n    * - `QICS <https://qics.readthedocs.io/en/stable/>`_\n      - native\n      - Yes\n      - Yes\n      - Yes\n      - Yes\n      -\n      - Yes\n      - `MIT`_\n    * - `SCIP <http://scip.zib.de/>`_\n      - `PySCIPOpt <https://github.com/SCIP-Interfaces/PySCIPOpt/>`_\n      - Yes\n      - Yes\n      -\n      -\n      - Yes\n      -\n      - `ZIB`_/`MIT`_\n    * - `SMCP <http://smcp.readthedocs.io/en/latest/>`_\n      - native\n      -\n      -\n      - Yes\n      -\n      -\n      -\n      - `GPL-3`_\n\n.. rubric:: Example\n\nThis is what it looks like to solve a multidimensional mixed integer program\nwith PICOS:\n\n>>> import picos as pc\n>>> P = pc.Problem()\n>>> x = pc.IntegerVariable(\"x\", 2)\n>>> P += 2*x <= 11\n>>> P.maximize = pc.sum(x)\n>>> P.solve(solver=\"glpk\")  # Optional: Use GLPK as backend.\n<feasible primal solution (claimed optimal) from glpk>\n>>> P.value\n10.0\n>>> print(x)\n[ 5.00e+00]\n[ 5.00e+00]\n\nYou can head to our\n`quick examples <https://picos-api.gitlab.io/picos/quick.html>`_ or the\n`tutorial <https://picos-api.gitlab.io/picos/tutorial.html>`_ for more.\n\nInstallation\n------------\n\nAs of release 2.2, PICOS requires **Python 3.4** or later.\n\n.. rubric:: Via pip\n\nIf you are using `pip <https://pypi.org/project/pip/>`_ you can run\n``pip install picos`` to get the latest version.\n\n.. rubric:: Via Anaconda\n\nIf you are using `Anaconda <https://anaconda.org/>`_ you can run\n``conda install -c picos picos`` to get the latest version.\n\n.. rubric:: Via your system's package manager\n\n.. list-table::\n    :header-rows: 1\n    :stub-columns: 1\n\n    * - Distribution\n      - Latest major version\n      - Latest version\n    * - Arch Linux\n      - `python-picos <https://aur.archlinux.org/packages/python-picos/>`__\n      - `python-picos-git <https://aur.archlinux.org/packages/python-picos-git/>`__\n\nIf you are packaging PICOS for additional platforms, please let us know.\n\n.. rubric:: From source\n\nThe PICOS source code can be found on `GitLab\n<https://gitlab.com/picos-api/picos>`_. There are only two dependencies:\n\n- `NumPy <https://numpy.org/>`_\n- `CVXOPT`_\n\nDocumentation\n-------------\n\nThe full documentation can be browsed `online\n<https://picos-api.gitlab.io/picos/>`__ or downloaded `in PDF form\n<https://picos-api.gitlab.io/picos/picos.pdf>`__.\n\nCredits\n-------\n\n.. rubric:: Developers\n\n- `Guillaume Sagnol <http://page.math.tu-berlin.de/~sagnol/>`_ has started work\n  on PICOS in 2012.\n- `Maximilian Stahlberg <https://orcid.org/0000-0002-0190-2693>`_ is extending\n  and co-maintaining PICOS since 2017.\n\n.. rubric:: Contributors\n\nFor an up-to-date list of all code contributors, please refer to the\n`contributors page <https://gitlab.com/picos-api/picos/-/graphs/master>`_.\nShould a reference from before 2019 be unclear, see also the `old contributors\npage <https://github.com/gsagnol/picos/graphs/contributors>`_ on GitHub.\n\nCiting\n------\n\nThe preferred way to cite PICOS in your research is our `JOSS paper\n<https://joss.theoj.org/papers/10.21105/joss.03915>`_:\n\n.. code-block:: bibtex\n\n  @article{PICOS,\n    author  = {Guillaume Sagnol and Maximilian Stahlberg},\n    journal = {Journal of Open Source Software},\n    title   = {{PICOS}: A {Python} interface to conic optimization solvers},\n    year    = {2022},\n    issn    = {2475-9066},\n    month   = feb,\n    number  = {70},\n    pages   = {3915},\n    volume  = {7},\n    doi     = {10.21105/joss.03915},\n  }\n\nIf citing a specific version of PICOS is necessary, then we offer also `source\ndeposits on Zenodo <https://doi.org/10.5281/zenodo.6052843>`_.\n\nLicense\n-------\n\nPICOS is free and open source software and available to you under the terms of\nthe `GNU GPL v3 <https://gitlab.com/picos-api/picos/raw/master/LICENSE.txt>`_.\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "A Python interface to conic optimization solvers.",
    "version": "2.5.1",
    "project_urls": {
        "Documentation": "https://picos-api.gitlab.io/picos/",
        "Source": "https://gitlab.com/picos-api/picos"
    },
    "split_keywords": [
        "conic optimization",
        " convex optimization",
        " robust optimization",
        " semidefinite programming"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "37b75d03a0474e25ce97efc489adb8f9759b001b6ac6c080023b6e1420a31424",
                "md5": "965ef0b76e014b6e5671dce8866621f5",
                "sha256": "666b7385f7aed055112bba420c9ec0b1973a12565faedef7ad51f783c3a4902b"
            },
            "downloads": -1,
            "filename": "picos-2.5.1.tar.gz",
            "has_sig": false,
            "md5_digest": "965ef0b76e014b6e5671dce8866621f5",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.4",
            "size": 536481,
            "upload_time": "2024-11-04T06:42:19",
            "upload_time_iso_8601": "2024-11-04T06:42:19.220371Z",
            "url": "https://files.pythonhosted.org/packages/37/b7/5d03a0474e25ce97efc489adb8f9759b001b6ac6c080023b6e1420a31424/picos-2.5.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-11-04 06:42:19",
    "github": false,
    "gitlab": true,
    "bitbucket": false,
    "codeberg": false,
    "gitlab_user": "picos-api",
    "gitlab_project": "picos",
    "lcname": "picos"
}
        
Elapsed time: 0.35407s