Search code examples
webspherepython-3.8cplexdocplex

IBM CP Optimizer Community Edition


I get the following message when using docplex in Python:

Solver error: Problem size limit exceeded. CP Optimizer Community Edition solves problems with search spaces up to 2^1000. Unrestricted version options (including academia) at https://ibm.co/2s0wqSa

I have the academic version, but the license for CP Optimizer does not connect. I have made the CPLEX_STUDIO_DIR201 and CPLEX_CPXCHECKLIC_BINDIR environment variables. But I can not find my API key to set CPLEX_STUDIO_KEY. Where do I find my API key?


Solution

  • In the solve parameter you can set the path for the right cplex cp engine on your machine.

    msol=mdl.solve(execfile='C:\\ILOG\\CPLEX_Studio201\\cpoptimizer\\bin\\x64_win64\\cpoptimizer.exe')
    

    See CPLEX Python API installment on Mac big sur problem CpoException for full example