This Python project generates random origin-destination points within a city boundary and calculates the shortest path between them using OpenStreetMap data. It visualizes the path on an interactive map using Folium.
- Generates a random shortest path in a selected city.
- Uses real-world road network data from OpenStreetMap via OSMnx.
- Computes the path using NetworkX shortest path algorithms.
- Renders an interactive map with markers and the route using Folium.
osmnx
โ download and manipulate street network datanetworkx
โ graph analysis and shortest path calculationfolium
โ map visualization
Make sure you have Python 3.7 or later installed.
git clone https://github.com/yourusername/random-shortest-path.git
cd random-shortest-path
pip install -r requirements.txt