cmditch-pyscip-test


Namecmditch-pyscip-test JSON
Version 0.1.1 PyPI version JSON
download
home_pagehttps://github.com/SCIP-Interfaces/PySCIPOpt
SummaryTest package
upload_time2024-10-25 04:31:51
maintainerNone
docs_urlNone
authorMurray Rothbard
requires_python>=3.8
licenseMIT
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage
            PySCIPOpt
=========

This project provides an interface from Python to the [SCIP Optimization Suite](https://www.scipopt.org/). Starting from v8.0.3, SCIP uses the [Apache2.0](https://www.apache.org/licenses/LICENSE-2.0) license. If you plan to use an earlier version of SCIP, please review [SCIP's license restrictions](https://scipopt.org/index.php#license).

[![Gitter](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/PySCIPOpt/Lobby)
[![PySCIPOpt on PyPI](https://img.shields.io/pypi/v/pyscipopt.svg)](https://pypi.python.org/pypi/pyscipopt)
[![Integration test](https://github.com/scipopt/PySCIPOpt/actions/workflows/integration-test.yml/badge.svg)](https://github.com/scipopt/PySCIPOpt/actions/workflows/integration-test.yml)
[![coverage](https://img.shields.io/codecov/c/github/scipopt/pyscipopt)](https://app.codecov.io/gh/scipopt/pyscipopt/)
[![AppVeyor Status](https://ci.appveyor.com/api/projects/status/fsa896vkl8be79j9/branch/master?svg=true)](https://ci.appveyor.com/project/mattmilten/pyscipopt/branch/master)


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

Please consult the [online documentation](https://pyscipopt.readthedocs.io/en/latest/) or use the `help()` function directly in Python or `?` in IPython/Jupyter.

The old documentation, which we are in the process of migrating from,
is still more complete w.r.t. the API, and can be found [here](https://scipopt.github.io/PySCIPOpt/docs/html/index.html)

See [CHANGELOG.md](https://github.com/scipopt/PySCIPOpt/blob/master/CHANGELOG.md) for added, removed or fixed functionality.

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

The recommended installation method is via PyPI
```bash
pip install pyscipopt
```

For information on specific versions, installation via Conda, and guides for building from source,
please see the [online documentation](https://pyscipopt.readthedocs.io/en/latest/install.html).

Building and solving a model
----------------------------

There are several [examples](https://github.com/scipopt/PySCIPOpt/blob/master/examples/finished) and
[tutorials](https://github.com/scipopt/PySCIPOpt/blob/master/examples/tutorial). These display some functionality of the
interface and can serve as an entry point for writing more complex code. Some of the common usecases are also available in the [recipes](https://github.com/scipopt/PySCIPOpt/blob/master/src/pyscipopt/recipes) sub-package.
You might also want to have a look at this article about PySCIPOpt:
<https://opus4.kobv.de/opus4-zib/frontdoor/index/index/docId/6045>. The
following steps are always required when using the interface:

1)  It is necessary to import python-scip in your code. This is achieved
    by including the line

``` {.sourceCode .python}
from pyscipopt import Model
```

2)  Create a solver instance.

``` {.sourceCode .python}
model = Model("Example")  # model name is optional
```

3)  Access the methods in the `scip.pxi` file using the solver/model
    instance `model`, e.g.:

``` {.sourceCode .python}
x = model.addVar("x")
y = model.addVar("y", vtype="INTEGER")
model.setObjective(x + y)
model.addCons(2*x - y*y >= 0)
model.optimize()
sol = model.getBestSol()
print("x: {}".format(sol[x]))
print("y: {}".format(sol[y]))
```

Writing new plugins
-------------------

The Python interface can be used to define custom plugins to extend the
functionality of SCIP. You may write a pricer, heuristic or even
constraint handler using pure Python code and SCIP can call their
methods using the callback system. Every available plugin has a base
class that you need to extend, overwriting the predefined but empty
callbacks. Please see `test_pricer.py` and `test_heur.py` for two simple
examples.

Please notice that in most cases one needs to use a `dictionary` to
specify the return values needed by SCIP.

Citing PySCIPOpt
----------------

Please cite [this paper](https://opus4.kobv.de/opus4-zib/frontdoor/index/index/docId/6045)
```
@incollection{MaherMiltenbergerPedrosoRehfeldtSchwarzSerrano2016,
  author = {Stephen Maher and Matthias Miltenberger and Jo{\~{a}}o Pedro Pedroso and Daniel Rehfeldt and Robert Schwarz and Felipe Serrano},
  title = {{PySCIPOpt}: Mathematical Programming in Python with the {SCIP} Optimization Suite},
  booktitle = {Mathematical Software {\textendash} {ICMS} 2016},
  publisher = {Springer International Publishing},
  pages = {301--307},
  year = {2016},
  doi = {10.1007/978-3-319-42432-3_37},
}
```
as well as the corresponding [SCIP Optimization Suite report](https://scip.zib.de/index.php#cite) when you use this tool for a publication or other scientific work.

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/SCIP-Interfaces/PySCIPOpt",
    "name": "cmditch-pyscip-test",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": null,
    "author": "Murray Rothbard",
    "author_email": "Murray Rothbard <murray@mises.ru>",
    "download_url": null,
    "platform": null,
    "description": "PySCIPOpt\n=========\n\nThis project provides an interface from Python to the [SCIP Optimization Suite](https://www.scipopt.org/). Starting from v8.0.3, SCIP uses the [Apache2.0](https://www.apache.org/licenses/LICENSE-2.0) license. If you plan to use an earlier version of SCIP, please review [SCIP's license restrictions](https://scipopt.org/index.php#license).\n\n[![Gitter](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/PySCIPOpt/Lobby)\n[![PySCIPOpt on PyPI](https://img.shields.io/pypi/v/pyscipopt.svg)](https://pypi.python.org/pypi/pyscipopt)\n[![Integration test](https://github.com/scipopt/PySCIPOpt/actions/workflows/integration-test.yml/badge.svg)](https://github.com/scipopt/PySCIPOpt/actions/workflows/integration-test.yml)\n[![coverage](https://img.shields.io/codecov/c/github/scipopt/pyscipopt)](https://app.codecov.io/gh/scipopt/pyscipopt/)\n[![AppVeyor Status](https://ci.appveyor.com/api/projects/status/fsa896vkl8be79j9/branch/master?svg=true)](https://ci.appveyor.com/project/mattmilten/pyscipopt/branch/master)\n\n\nDocumentation\n-------------\n\nPlease consult the [online documentation](https://pyscipopt.readthedocs.io/en/latest/) or use the `help()` function directly in Python or `?` in IPython/Jupyter.\n\nThe old documentation, which we are in the process of migrating from,\nis still more complete w.r.t. the API, and can be found [here](https://scipopt.github.io/PySCIPOpt/docs/html/index.html)\n\nSee [CHANGELOG.md](https://github.com/scipopt/PySCIPOpt/blob/master/CHANGELOG.md) for added, removed or fixed functionality.\n\nInstallation\n------------\n\nThe recommended installation method is via PyPI\n```bash\npip install pyscipopt\n```\n\nFor information on specific versions, installation via Conda, and guides for building from source,\nplease see the [online documentation](https://pyscipopt.readthedocs.io/en/latest/install.html).\n\nBuilding and solving a model\n----------------------------\n\nThere are several [examples](https://github.com/scipopt/PySCIPOpt/blob/master/examples/finished) and\n[tutorials](https://github.com/scipopt/PySCIPOpt/blob/master/examples/tutorial). These display some functionality of the\ninterface and can serve as an entry point for writing more complex code. Some of the common usecases are also available in the [recipes](https://github.com/scipopt/PySCIPOpt/blob/master/src/pyscipopt/recipes) sub-package.\nYou might also want to have a look at this article about PySCIPOpt:\n<https://opus4.kobv.de/opus4-zib/frontdoor/index/index/docId/6045>. The\nfollowing steps are always required when using the interface:\n\n1)  It is necessary to import python-scip in your code. This is achieved\n    by including the line\n\n``` {.sourceCode .python}\nfrom pyscipopt import Model\n```\n\n2)  Create a solver instance.\n\n``` {.sourceCode .python}\nmodel = Model(\"Example\")  # model name is optional\n```\n\n3)  Access the methods in the `scip.pxi` file using the solver/model\n    instance `model`, e.g.:\n\n``` {.sourceCode .python}\nx = model.addVar(\"x\")\ny = model.addVar(\"y\", vtype=\"INTEGER\")\nmodel.setObjective(x + y)\nmodel.addCons(2*x - y*y >= 0)\nmodel.optimize()\nsol = model.getBestSol()\nprint(\"x: {}\".format(sol[x]))\nprint(\"y: {}\".format(sol[y]))\n```\n\nWriting new plugins\n-------------------\n\nThe Python interface can be used to define custom plugins to extend the\nfunctionality of SCIP. You may write a pricer, heuristic or even\nconstraint handler using pure Python code and SCIP can call their\nmethods using the callback system. Every available plugin has a base\nclass that you need to extend, overwriting the predefined but empty\ncallbacks. Please see `test_pricer.py` and `test_heur.py` for two simple\nexamples.\n\nPlease notice that in most cases one needs to use a `dictionary` to\nspecify the return values needed by SCIP.\n\nCiting PySCIPOpt\n----------------\n\nPlease cite [this paper](https://opus4.kobv.de/opus4-zib/frontdoor/index/index/docId/6045)\n```\n@incollection{MaherMiltenbergerPedrosoRehfeldtSchwarzSerrano2016,\n  author = {Stephen Maher and Matthias Miltenberger and Jo{\\~{a}}o Pedro Pedroso and Daniel Rehfeldt and Robert Schwarz and Felipe Serrano},\n  title = {{PySCIPOpt}: Mathematical Programming in Python with the {SCIP} Optimization Suite},\n  booktitle = {Mathematical Software {\\textendash} {ICMS} 2016},\n  publisher = {Springer International Publishing},\n  pages = {301--307},\n  year = {2016},\n  doi = {10.1007/978-3-319-42432-3_37},\n}\n```\nas well as the corresponding [SCIP Optimization Suite report](https://scip.zib.de/index.php#cite) when you use this tool for a publication or other scientific work.\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Test package",
    "version": "0.1.1",
    "project_urls": {
        "Homepage": "https://github.com/SCIP-Interfaces/PySCIPOpt"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "b0bcc3ebc2be06adfc9b18bf3a86d7369e0790c3b8ce1acd64417d7066b210ac",
                "md5": "ea36120c40e1ee928bdc496b2ac54d94",
                "sha256": "235929575b5f40a558e0c7257cf96555961f619660e30c3e2d276efd6303e61a"
            },
            "downloads": -1,
            "filename": "cmditch_pyscip_test-0.1.1-cp39-cp39-manylinux_2_28_x86_64.whl",
            "has_sig": false,
            "md5_digest": "ea36120c40e1ee928bdc496b2ac54d94",
            "packagetype": "bdist_wheel",
            "python_version": "cp39",
            "requires_python": ">=3.8",
            "size": 14917865,
            "upload_time": "2024-10-25T04:31:51",
            "upload_time_iso_8601": "2024-10-25T04:31:51.832980Z",
            "url": "https://files.pythonhosted.org/packages/b0/bc/c3ebc2be06adfc9b18bf3a86d7369e0790c3b8ce1acd64417d7066b210ac/cmditch_pyscip_test-0.1.1-cp39-cp39-manylinux_2_28_x86_64.whl",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-10-25 04:31:51",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "SCIP-Interfaces",
    "github_project": "PySCIPOpt",
    "travis_ci": false,
    "coveralls": true,
    "github_actions": true,
    "landscape": true,
    "lcname": "cmditch-pyscip-test"
}
        
Elapsed time: 0.41013s