π Dynamic Pricing for Urban Parking Lots
Capstone Project β Summer Analytics 2025
By: Chirayu Khalwa
π§ khalwachirayu@gmail.com
GitHub: raysamma
This project implements an intelligent dynamic pricing engine for urban parking lots, adjusting parking rates in real-time based on demand, queue lengths, traffic conditions, and competitor prices.
The solution uses real-time data streaming with Pathway and visualizes price fluctuations using interactive Bokeh plots.
π Overview
Urban parking spaces are limited and static pricing often leads to underutilization or overcrowding. This project solves that problem by:
- π Increasing prices during high demand and traffic
- π Reducing prices when occupancy is low
- πΊοΈ Considering competitor prices and proximity to suggest rerouting
- π Streaming real-time data to update prices dynamically
We built three pricing models, progressively improving intelligence:
- Baseline Linear Model
- Demand-Based Price Function
- Competitive Pricing Model
π οΈ Tech Stack
| Component | Details |
|---|---|
| Language | Python 3 |
| Data Processing | Pandas, NumPy |
| Real-Time Streaming | Pathway |
| Visualization | Bokeh, Panel |
| Hosting/Sharing | Google Colab, GitHub |
| Geospatial Analysis | Latitude/Longitude proximity |
ποΈ Project Architecture & Workflow
1οΈβ£ Data Ingestion
- Input data (
dataset.csv) includes occupancy, capacity, traffic, queue lengths, and GPS for 14 lots. - Simulated real-time ingestion using
Pathway.demo.replay_csv().
2οΈβ£ Feature Engineering
- Parse timestamp, calculate occupancy ratio and demand metrics.
- Extract day-level and lot-level features.
3οΈβ£ Pricing Models
- Model 1: Simple linear pricing
price_t+1 = price_t + Ξ± * (Occupancy / Capacity) - Model 2: Demand-based pricing using:
- Occupancy Rate
- Queue Length
- Traffic Level
- Special Day Indicator
- Vehicle Type Weightage
- Model 3: Adds competitor prices and rerouting logic.
4οΈβ£ Real-Time Visualization
- Plot dynamic prices over time using Bokeh interactive charts.
- Simulate price updates and recommendations live.
π Project Structure
Dynamic-Pricing-Parking
β£ dataset.csv
β£ DynamicPricing.ipynb
β£ README.md
β£ images/
β β architecture_diagram.png
π Visual Output Examples
Sample: Real-time price fluctuations for Parking Lot 5
π Documentation
β¨ Features
- Smooth price transitions (avoids erratic jumps)
- Handles high-demand and low-capacity scenarios gracefully
- Reroutes vehicles to nearby lots if occupancy is high
π₯ Challenges Solved
- Simulating real-time streams in Colab
- Normalizing demand and keeping prices bounded between 0.5x and 2x base price
- Integrating geospatial logic with pricing
π How to Run
- Open in Google Colab
- Upload
dataset.csv - Run all cells to start real-time simulation
π¨βπ» Author
Chirayu Khalwa
π§ khalwachirayu@gmail.com
π GitHub - raysamma