Skip to main content
IBM Developer
Sign In | Register dW
IBM Decision Optimization: on Cloud, for Bluemix...
  • Docs
  • Forum
  • News
  • GitHub
  • Support
  • Media Center
DOcplex / Python
< Previous   /   Next >

CPLEX Modeling for Python Technical Preview

VincentBeraudier / October 20, 2015

The Decision Optimization modeling team is proud to announce CPLEX Modeling for Python Technical Preview (short name: docplex), an open source project on pypi and github.

CPLEX for Python

  • Easily formulate your optimization models and solve them with DOcloud solve service or CPLEX local solver.
  • Access to free solve capabilities to discover this new API is made easy thanks to our cloud free trial and our new CPLEX Optimization Studio free Community Edition (aka COS CE): you can get access to any of those two with the help of one mail address.
  • Available through the standard Python pip install with no need to download anything else or contact any IBM person if you go full cloud.

Discovering docplex is pretty straightfoward. Just have a look at the online documentation here.
It will help you get:

  1. a Python interpreter and the development environment of your choice.
  2. DOcloud credentials or COS CE.
  3. the mathematical programming examples delivered as Python programs or educative notebooks.

Once all these are installed, update the examples to put your DOcloud credentials or put your CPLEX local solver in your PYTHONPATH and run them.

If you are not so familiar with Python or CPLEX, just download the following zip files which contain a step by step onboarding of docplex experience.

  • docplex with Notebooks to run CPLEX in IPython Notebooks.
  • docplex with Eclipse to run CPLEX in a standlone environment with full edition and debug capabilities.

You will be guided with successive screenshots to a working installation, either with notebooks or eclipse based environments, with both DOcloud and COS CE.

docplex is currenty supported with:
– any docloud subscription
– CPLEX 12.6.2 if using local solver
– Windows 64 or Linux 64 platform
– Python 64 bits with version >= 2.7.9 or 3.4.x
Any other OS/bitness/version is not supported.

Going Python will give you the benefits of its scientific ecosystem and will enable you to leverage powerful data science and data exploration libraries such as the scipy.org bundles, with machine cleansing, machine learning, …

Among several characteristics, this library is numpy friendly and “Notebooks Ready” for both Jupiter IPython and Apache Zeppelin
Notebooks are an easy way to prototype your business constraints and visualize the solutions (discover some examples of scientific notebooks here ).

Please also note that docplex is regularly updated with fixes, new examples, new features.

Sumup table:

  • Landing page on pypi
  • Source code
  • Documentation
  • Online documentation
  • Examples

We also welcome you to give us your feedback at dofeedback@wwpdl.vnet.ibm.com

Tagged: docplex / python
  • DOcplexcloud news

    • Bike sharing system optimization December 17, 2018
    • Optimization of business decisions – now a simple subscription away December 11, 2018
    • Use OPL with the R framework. October 26, 2018
    • CPLEX interface for CVXPY now available September 28, 2018
    • OPL and the Python ecosystem are now tied up! September 26, 2018
  • Other posts by category

    • CPLEX (5)
    • CPLEX Studio (13)
    • DOcplex (3)
    • DOcplexcloud (30)
    • DSX (6)
    • Excel (3)
    • Flex-Tier (4)
    • Java (2)
    • Machine Learning (1)
    • Prescriptive Analytics (9)
    • Python (12)
    • R (2)
    • Uncategorized (6)
RSS Feed
  • Report Abuse
  • Terms of Use
  • Third Party Notice
  • IBM Privacy
IBM