Reputation: 338
I want to call
import cplex
in a Jupyter notebook (Python 3) opened from Anaconda.
I have CPLEX already installed in my computer, and this is called by MATLAB, etc. However, I can not import this to Anaconda. In the webpage of CPLEX, it says I should run:
python setup.py install
but this does not install cplex in Anaconda.
Also in Anaconda Cloud website it says I can just install
conda install -c ibmdecisionoptimization cplex
but as I said I have CPLEX already and I don't want to install it again. How can I import cplex to a jupyter notebook?
Upvotes: 1
Views: 4218
Reputation: 5940
What exactly are the issues your are facing?
I guess you get an import error that states that a cplex
module cannot be found?
The folder that contains the CPLEX libraries must be listed in the PYTHONPATH
environment variable. Try adding that folder to PYTHONPATH
.
Upvotes: 1