Installing Pyomo on Windows with Anaconda (Python)
It is 2017 and pyomo can be easily installed via conda
conda install -c conda-forge pyomo pyomo.extras
To install LP and NLP solvers, conda can also be used.
conda install -c cachemeorg glpk ipopt_bin
If you are in a Mac or linux, you can install updated versions using conda-forge.
conda install -c conda-forge glpk ipopt
If you prefer to install pyomo or solvers via pip:
Check that the PATH on windows where is located pyomo.exe is indeed C:\Anaconda\Scripts
Besides, the PATH was set correctly since the cmd recognized the pyomo command at the beginning
With:
echo %path%
on the cmd you can get a list of all the paths (where the C:\Anaconda\Scripts\ is included"
So with Anaconda it was only necessary to set the path where the glpsol.exe is located, to do that from the cmd.exe and considering that you have unzipped your winglpk on "C:\glpk\w64":
setx path "%path%;c:\glpk\w64"
After that, restart the cmd and navigate with the "cd" command where you have the data.py and data.dat
Finally it works! Thanks to the mailing list of pyomo project for the indications
For more information I recommend to read the next links:
wingplk: http://en.wikibooks.org/wiki/GLPK/Windows_executables
setting the path on windows 7: http://www.voidspace.org.uk/python/articles/command_line.shtml https://superuser.com/questions/284342/what-are-path-and-other-environment-variables-and-how-can-i-set-or-use-them