Gurobi on mac
AnsweredHello,
after installing gurobi and entering the code into the terminal I'm still not able to find the gurobi optimizer. Am i forgetting something?
thank you
-
Hi Enis,
There is no Gurobi GUI or IDE which you can execute. Gurobi is meant to be execute via the command line or to be called via a programming language API, e.g., the Python API. One way to test whether you have set up your license file and installed Gurobi correctly, please open a terminal window (on Mac: Command + Space, then type terminal and press Enter) and start
najman@najman-xxxxx ~ % gurobi.sh
This should provide an output similar to
Python 3.7.4 (default, Aug 27 2019, 11:27:39)
[Clang 8.0.0 (clang-800.0.42.1)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
Using license file /Users/najman/gurobi.lic
Set parameter LogFile to value gurobi.log
Gurobi Interactive Shell (mac64), Version 9.1.2
Copyright (c) 2021, Gurobi Optimization, LLC
Type "help()" for help
gurobi>This is the interactive Gurobi Python shell, which is not meant to be used for the solution of real problems but rather to play with smaller problem and a couple of commands. Typing \(\texttt{exit()}\) closes the Gurobi shell.
Please have a look at our guide to Solving a Simple Model for more details and information.
If you were not able to execute the above, please follow the Quick Start Guide for Mac to set up a license and install the Gurobi Optimizer.
Best regards,
Jaromił1 -
Hi Enis,
As discussed on the phone, and as my colleague Jaromił mentioned, Gurobi does not come with a Graphical User Interface. You mentioned that you only have to solve problems which are given as .LP files. For this you can either:
1. As described in Jaromił's message, open a Terminal and write
gurobi.sh
and once you see the screen shown in the message above, write the following commands:
m = read('FILENAME')
m.optimize()where FILENAME is the name of the .LP file that you have to read (including the path to the file).
or
2. Use the Gurobi Command-Line Tool as follows: from your Terminal, write
gurobi_cl FILENAME
(where FILENAME is the same as above).
Best regards,
Elisabeth
1 -
Hello,
I am having the same problem as Enis. I cannot find the Gurobi distribution directory or the examples. I know Gurobi does not have an IDE, but I guess I should be able to find the place where the software has been installed. Any help would be appreciated.
Thanks
0 -
Hi Diego,
On a Mac, if Gurobi is installed correctly, you can try running the following in a terminal to help locate where Gurobi is installed:
which gurobi_cl | xargs ls -l
Typically it is installed here:
/Library/gurobiXXX
where XXX is the version number.
- Riley
0
Please sign in to leave a comment.
Comments
4 comments