Weather-Aware Urban Attraction Optimization

Published:

This project develops a data-driven itinerary optimization framework for urban tourism planning under real-world constraints.

Urban visitors must choose attractions while facing limited time budgets, travel delays, waiting times, and weather variability. Traditional recommendation systems rank attractions independently but ignore travel costs and route feasibility.

This project integrates machine learning and operations research to construct an optimization-based system that recommends optimal tourist routes maximizing overall visitor utility.

The framework consists of three main components:

  1. Attraction Utility Modeling

    Each attraction is assigned a baseline utility score using Yelp data:

    \[U_i = rating_i \cdot \log(\text{review count}_i)\]

    This captures both quality (rating) and popularity (review volume).

  2. Congestion and Waiting-Time Modeling

    Expected waiting time at attraction (i) is modeled as

    \[W_i(t) = f(\text{hour}, \text{day-of-week}, \text{weather})\]

    where weather features (rain, temperature) and temporal patterns influence congestion.

  3. Route Optimization

    The final itinerary is determined using an integer optimization formulation similar to the orienteering problem:

    \[\max \sum_{i} U_i x_i - \alpha \sum_i W_i(t_i)x_i - \beta \sum_{i,j} d_{ij}y_{ij}\]

    subject to travel time and time-budget constraints.

The model simultaneously decides:

  • which attractions to visit
  • the order of visits
  • the optimal travel route

while maximizing overall utility.


Key Features

  • Utility modeling using Yelp business ratings and review counts
  • Weather-aware congestion estimation
  • Construction of a travel-time matrix using geographic coordinates
  • Integer programming formulation for route optimization
  • Integration of machine learning predictions and OR optimization
  • Interactive visualization of optimized tourist routes

Interactive Route Visualization

The optimized tourist routes and travel paths can be explored in the interactive map below.


System Architecture

flowchart LR

A[Yelp Business Dataset] --> B[Attraction Utility Model]
C[Weather Data] --> D[Congestion Prediction]
B --> E[Optimization Model]
D --> E
F[Travel Time Matrix] --> E

E --> G[Optimal Tourist Route]
G --> H[Interactive Map Visualization]

Technologies Used

  • Python
  • Optimization: Integer Programming / OR modeling
  • Machine Learning: Linear Regression, Random Forest
  • Data Sources: Yelp Open Dataset, Open-Meteo Weather API
  • Visualization: Folium / Leaflet interactive maps

GitHub Repository

View on GitHub


Important repo structure

Your GitHub repo should look like:

weather-aware-itinerary-optimization
│
├── README.md
├── requirements.txt
│
├── notebook
│   └── itinerary_optimization_pipeline.ipynb
│
├── data
│   ├── yelp_business.json
│   ├── yelp_review.json
│   └── weather_data.csv
│
├── results
│   ├── attraction_map.png
│   ├── travel_time_matrix.csv
│   └── itinerary_outputs
│
└── report
    └── IE5533_project_report.pdf

Then Interactive tourist map: