This repository includes source codes of our blog post about an optimal trip all over the Europe.
Resulting maps can be previewed:
You can find Python codes for data preparation and optimization under scripts
, problem data under data
and a Jupyter notebook showing how we populated animated maps under notebook
.
The original data we used is kindly provided by Rome2Rio.com. In this repository, we have used a sample data, which is randomly generated. If you would like to populate original results, please contact with Rome2Rio.
all_modes.csv
files include origin, destination, route description, duration of the travel, low and high price for each option, and total distance in kilometers for each mode of transportation.
arcs.p
file includes arcs we have used in the optimization model. Each arc represent a connection from a game to another one.
games_filled.xlsx
is the schedule for the tournament.
travel_info.p
file includes coordinates of each venue and driving distance and duration between them. This data is collected through OpenStreetMap and OSRM. Note that, we have used Rome2Rio driving durations instead of these values.
We have collected emission data from UK Government GHG Conversion Factors for Company Reporting:
- https://assets.publishing.service.gov.uk/government/uploads/system/uploads/attachment_data/file/806025/Conversion-Factors-2019-Condensed-set-for-most-users.xls
- https://www.gov.uk/government/publications/greenhouse-gas-reporting-conversion-factors-2019
Following CO2e emissions (gram per kilometer per passenger) is used in the model
- Flight: 180.78
- Ferry: 112.86
- Car: 170.61 (Medium size, average, diesel)
- Car: 5.76 (Medium size, average, battery-electric)
- Bus/Coach: 27.79
- Train: 5.97
Optimization model is formulated using our open-source optimization modeling package sasoptpy. Problems are solved on SAS Viya 3.5.
Learn more about sasoptpy here: https://sassoftware.github.io/sasoptpy/index.html
Learn more about SAS Viya here: https://www.sas.com/en_us/software/viya.html
For Python codes, we have used following packages:
- geopy
- routingpy
- pandas
- swat
- sasoptpy