Installation via Python package manager

The libraries for CPLEX and Gurobi can be installed via pip executing respectively:

pip install amplpy amplpy-cplex


pip install amplpy amplpy-gurobi

Running the examples

To run the examples, simply:

  1. Go to the examples directory:

    cd python/examples
  2. Install (if needed) the dependencies in requirements.txt:

    pip install -r requirements.txt
  3. Execute the model