Smart Pune Bus ETA Prediction System ML-Based Smart Public Transportation Solution πΉ Project Overview ML-Based Smart Public Transportation Solution πΉ Project Overview The Smart Pune Bus ETA Prediction System is a full-stack, machine learningβbased web application designed to predict accurate bus arrival times and improve passenger experience in public transportation systems. The project focuses on providing real-time insights such as ETA, route visualization, nearest bus stop, next available bus, and crowd level estimation without relying on GPS hardware, making it highly cost-effective for tier-2 cities. The system combines machine learning, geospatial mapping, and modern web technologies to deliver a smart, scalable, and user-friendly public transport solution. πΉ Problem Statement Public bus passengers often face uncertainty due to: Inaccurate or unavailable bus arrival timings Lack of real-time route visualization No information about missed buses or next available buses Overcrowded buses during peak hours High cost of GPS-based tracking systems for transport authorities This project addresses these issues by using data-driven ETA prediction and open-source mapping tools. πΉ Solution Provided The system predicts bus arrival times using a machine learning regression model trained on historical route data, distance between stops, and time-based features. It provides passengers with: Accurate ETA predictions Interactive route visualization Live bus position simulation (without GPS) Nearest bus stop detection Next available bus information Crowd level estimation Daily bus timetable πΉ Key Features π ETA Prediction (Machine Learning) Predicts Estimated Time of Arrival using ML Considers route, distance, time of day, and peak hours πΊοΈ Route Visualization Displays real road-based routes using Leaflet + OpenStreetMap Uses OSRM for realistic road routing π΅ Live Bus Tracking (Simulated) Simulates real-time bus movement without GPS hardware Updates bus position dynamically based on ETA progress π Nearest Bus Stop Finder Uses browser geolocation Calculates nearest stop using the Haversine formula π Next Available Bus Shows upcoming buses if the passenger misses a bus Displays following buses for better planning πΆ Crowd Level Prediction Estimates crowd levels (Low / Medium / High) Based on time-of-day and peak-hour logic π Bus Timetable Displays daily bus schedules Helps passengers plan journeys efficiently πΉ Technologies Used Frontend HTML5 CSS3 JavaScript (Vanilla) Backend Python FastAPI Uvicorn REST APIs Machine Learning Pandas Scikit-learn / XGBoost (Regression model) Joblib (Model serialization) Mapping & Geospatial Leaflet.js OpenStreetMap OSRM (Open Source Routing Machine) Browser Geolocation API Data CSV datasets for routes and stops πΉ System Architecture User selects route, source, and destination (Frontend) Request sent to FastAPI backend ML model predicts ETA Backend returns ETA, distance, and metadata Frontend visualizes route and live bus movement Additional APIs provide next bus, crowd level, and timetable πΉ Project Structure BusTracker/ β βββ backend/ β βββ app.py β βββ frontend/ β βββ index.html β βββ timetable.html β βββ style.css β βββ script.js β βββ ml/ β βββ train_model.py β βββ eta_model.pkl β βββ dataset/ β βββ pune_routes.csv β βββ requirements.txt πΉ Key Skills Demonstrated Full-stack web development REST API design Machine learning model development Data preprocessing and feature engineering Geospatial mapping and routing Real-time simulation logic Problem solving and system design πΉ Impact & Benefits Improves passenger convenience and planning Reduces dependency on expensive GPS hardware Scalable for other tier-2 cities Cost-effective solution for public transport authorities Demonstrates real-world ML and smart-city application πΉ Future Enhancements Integration with real GPS data Mobile application (Android / iOS) Real-time traffic data integration Passenger feedback and rating system Admin dashboard with analytics Multi-city and multi-route support πΉ Portfolio / Resume One-Line Summary Developed an ML-based smart bus ETA prediction system with real-time route visualization, live bus simulation, and passenger-centric features using FastAPI, JavaScript, and open-source mapping tools.