Skip to content

Files

Latest commit

 

History

History

vehicle-routing

Vehicle Routing (Python)

Find the most efficient routes for a fleet of vehicles.

Vehicle Routing Screenshot

Tip

Check out our off-the-shelf model for Field Service Routing. This model goes beyond basic Vehicle Routing and supports additional constraints such as priorities, skills, fairness and more.

Prerequisites

  1. Install Python 3.10+.

  2. Install JDK 17+, for example with Sdkman:

    $ sdk install java
    

Run the application

  1. Git clone the timefold-quickstarts repo and navigate to this directory:

    $ git clone https://github.com/TimefoldAI/timefold-quickstarts.git
    ...
    $ cd timefold-quickstarts/python/vehicle-routing
  2. Create a virtual environment:

    $ python -m venv .venv
  3. Activate the virtual environment:

    $ . .venv/bin/activate
  4. Install the application:

    $ pip install -e .
  5. Run the application:

    $ run-app
  6. Visit http://localhost:8080 in your browser.

  7. Click on the Solve button.

Test the application

  1. Run tests:
    $ pytest

More information

Visit timefold.ai.