GAMS/CPLEX solver use in pyomo

632 views
Skip to first unread message

Matthew Oster

unread,
Apr 1, 2015, 8:44:35 PM4/1/15
to pyomo...@googlegroups.com
I have a GAMS/CPLEX license (GAMS v23.6.5, CPLEX v12.2.0.1) installed on my Windows 7 machine, but am unsure how to call the solver from within pyomo.  I did not find a cplex.exe file anywhere, just a cplex122.dll file under my main GAMS directory.  Can I use my CPLEX license using pyomo, with/without some finagling?

(FYI: I am running python 2.7.8 in Cygwin, with successful use of the glpk solver within pyomo (v4.0).)

-Matt

David Woodruff

unread,
Apr 1, 2015, 9:03:24 PM4/1/15
to pyomo...@googlegroups.com
Matt,
  Maybe someone else will respond with a much better answer, but for now, I can tell you:
0. I am pretty sure that at best, there will be "finagling"
1. You probably can't use it at this time without major finagling that has probably never been done (but again, maybe someone else knows how with only minor finagling).
Dave


--
You received this message because you are subscribed to the Google Groups "Pyomo Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pyomo-forum...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Siirola, John D

unread,
Apr 2, 2015, 10:30:35 AM4/2/15
to pyomo...@googlegroups.com

Dave is correct.  I cannot think of any way to directly call the CPLEX solver bundled within GAMS from Pyomo: Pyomo needs either a command-line executable or the CPLEX Python bindings in order to interface with the solver. 

 

The “least-finagled” way would be to export the Pyomo model into GAMS format and then call the solver through GAMS.  Writing that exporter should not be too hard – and is on my “not-so-short short list” of things to do – but obviously has not been done yet.

 

john

Matthew Oster

unread,
Apr 2, 2015, 4:07:55 PM4/2/15
to pyomo...@googlegroups.com
Thanks Dave, thanks John.  I appreciate the quick replies.  For now, glpk is working fine, but I may try to export my pyomo model into GAMS and call CPLEX from there.

-Matt
Reply all
Reply to author
Forward
0 new messages