"pulp.solvers.COINMP_DLL unavailable" in Ubuntu

703 views
Skip to first unread message

Hytham

unread,
May 14, 2011, 10:42:00 PM5/14/11
to pulp-or-discuss
Good day all,

I have been trying to install Coin-OR and use it with PuLP on ubuntu
10.10 without luck. i'm a novice Linux and Python user, so I might be
doing something silly, but your help is appreciated since I did spend
a couple of day and couldn't figure this out. I'm going to use pulp
with Coin-OR to solve problems on my Operations Research course.

After obtaining CoinMP following the steps on https://projects.coin-or.org/CoinMP,
I found a copy of CoinMP.dll at:
/usr/local/lib/python2.6/dist-packages/PuLP-1.4.8-py2.6.egg/pulp/
solverdir

However, when I run pulpTestAll() is get:
Solver pulp.solvers.COINMP_DLL unavailable.


The following are all the steps I followed starting with a fresh
Ubuntu 10.10 installation:

1. Check the version of python installed by typing python in the
terminal: using Python 2.6.6

2. Install easy_install for python by typing:
sudo easy_install -U pulp

3. install pulp by typing
sudo easy_install -U pulp

4. Test that pulp is installed: run python by typing
python
from pulp import *
pulpTestAll()

5. install subversion by typing in terminal:
sudo apt-get install subversion

6. Install C++ complier if not installed by typing in terminal:
sudo apt-get install g++

7. Obtain CoinMP source code by typing in terminal:
svn co https://projects.coin-or.org/svn/CoinMP/stable/1.4 CoinMP

8. Complie CoinMP by typing:
cd CoinMP
./configure -C
make
make test
make install

Stuart Mitchell

unread,
May 15, 2011, 2:23:47 AM5/15/11
to pulp-or...@googlegroups.com
Yeah the current version of pulp 1.4.8 does not come with an included
linux solver.

To fix this I suggest that you install cbc or glpk

$ sudo apt-get install coinor-libcbc0

or
$ sudo apt-get install glpk

Then you will have a solver.

version 1.5 will sort out this problem by using the yaposib module.

Stu

P.S. I should change the docs to reflect this

> --
> You received this message because you are subscribed to the Google Groups "pulp-or-discuss" group.
> To post to this group, send email to pulp-or...@googlegroups.com.
> To unsubscribe from this group, send email to pulp-or-discu...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/pulp-or-discuss?hl=en.
>
>

--
Stuart Mitchell
PhD Engineering Science
Freelance Programmer and Optimisation Expert
www.stuartmitchell.com

Hytham

unread,
May 15, 2011, 4:50:41 AM5/15/11
to pulp-or-discuss
It worked! Many thanks.

My professor only accepts results from CPLEX or COIN-OR for academic
work. I did manage to get PuLP running with GLPK,but I wanted to use
COIN-OR.


The following is an "Absolute beginner's guide for installing pulp
with COIN-OR Branch-and-Bound MIP Solver (CBC) on Ubuntu 11.04":


Note: Ubuntu 11.04 already come with Python 2.7.1 pre-installed, which
meets PuLP requirement

1. Install easy_install to install python packages by typing in
terminal:

sudo apt-get install python-setuptools

2. Install the latest version of PuLP using easy_install by typing in
terminal:

sudo easy_install -U pulp

3. Install COIN-OR CBC by typing in terminal:

sudo apt-get install coinor-libcbc0

4. Test that pulp is correctly installed by lunching python, importing
pulp and performing a test by typing in terminal:

python
import pulp
pulp.pulpTestAll()

If installation is successful, you will get the following output:

Solver pulp.solvers.CPLEX_DLL unavailable.
Solver pulp.solvers.CPLEX_CMD unavailable.
Testing zero subtraction
Testing continuous LP solution
Testing maximize continuous LP solution
Testing unbounded continuous LP solution
Testing MIP solution
Testing MIP relaxation
Testing feasibility problem (no objective)
Testing an infeasible problem
Testing an integer infeasible problem
Testing column based modelling
Testing fractional constraints
Testing elastic constraints (no change)
Testing elastic constraints (freebound)
Testing elastic constraints (penalty unchanged)
Testing elastic constraints (penalty unbounded)
* Solver pulp.solvers.COIN_CMD passed.
Solver pulp.solvers.COINMP_DLL unavailable.
Solver pulp.solvers.GLPK_CMD unavailable.
Solver pulp.solvers.XPRESS unavailable.
Solver pulp.solvers.GUROBI unavailable.
Solver pulp.solvers.PYGLPK unavailable.


On May 15, 1:23 am, Stuart Mitchell <s...@stuartmitchell.com> wrote:
> Yeah the current version of pulp 1.4.8 does not come with an included
> linux solver.
>
> To fix this I suggest that you install cbc or glpk
>
> $ sudo apt-get install  coinor-libcbc0
>
> or
> $ sudo apt-get install glpk
>
> Then you will have a solver.
>
> version 1.5 will sort out this problem by using the yaposib module.
>
> Stu
>
> P.S. I should change the docs to reflect this
>
>
>
>
>
>
>
>
>
> On Sun, May 15, 2011 at 2:42 PM, Hytham <aytch...@gmail.com> wrote:
> > Good day all,
>
> > I have been trying to install Coin-OR and use it with PuLP on ubuntu
> > 10.10 without luck. i'm a novice Linux and Python user, so I might be
> > doing something silly, but your help is appreciated since I did spend
> > a couple of day and couldn't figure this out. I'm going to use pulp
> > with Coin-OR to solve problems on my Operations Research course.
>
> > After obtaining CoinMP following the steps onhttps://projects.coin-or.org/CoinMP,
> > For more options, visit this group athttp://groups.google.com/group/pulp-or-discuss?hl=en.
Reply all
Reply to author
Forward
0 new messages