GradientDescent

Max Orders Route

Selection + vehicle routingRunning
Sep 21
Oct 31

What to do

  1. Pick your language below and download its codebase. Unzip it, and unzip the instances from the Data tab next to it.
  2. Write your solver in the highlighted files inside submission/. It starts as a working greedy solver, so you can change it step by step. Leave everything else as it is.
  3. Test it: ./run.sh ../max-orders-route/competition/111.json runs it exactly as the grader does and prints the score and every rule it breaks.
  4. Run ./make_zip.sh and upload the submission.zip it makes on the Upload tab.

The codebase

Your language
max-orders-route-codebase-python.zip■ you write this
  • submission/Zip this folder's contents and upload them
  • algorithm.pysolve(instance): the grader calls this
  • utils.pyReads instances, checks and scores solutions
  • solver/
  • __init__.py
  • greedy.pyYour solver: replace the greedy
  • README.mdHow to test and submit
  • run.shRuns submission/ as the grader does, in Docker
  • make_zip.shMakes submission.zip

Given to you

instance.orders
Every order, each with an id, lat, and lon.
instance.depot
Where every van starts and ends.
instance.num_vans
How many vans you have for this instance.
instance.van_capacity, instance.max_distance_miles
Each van's limits: 120 orders and 300 miles.
instance.time_limit_seconds
How long solve() has to return.
instance.distance(a, b)
Miles between two ids (orders or the depot), computed exactly as the grader does.
Solution, Van
What you return: for each van, the order ids it visits, in sequence. The depot is added at both ends.
utils.py
Reads an instance, times solve() against its limit, writes the solution, and checks it: capacity, distance, fleet size, repeated orders, and the time limit, all listed at once. Standard library only.