A traffic simulation program that graphically depicts automobile traffic on real world road systems.
Currently the program supports the following feature set:
- Taking dynamic real world map data (from OpenStreetMaps) and creating a graph of vertices and edges.
- Creating a visual representation of the internal graph by drawing a map using only lines and circles.
- Adding car objects can drive along the map and randomly pick destinations to travel to with routes.
- Optimal route determination using Dijkstra's search algorithm.
- Cars that will obey one way roads, speed limits, and will attempt to avoid collisions with one another.
- Collision detection optimization through the use of a quad tree.
Developed in Python 3.6.5
- install Python 3.6 or later
- install PyYAML ->
pip install PyYAML
- install overpy ->
pip install overpy
- run
main.py
from command line ->python main.py
- PyYAML -> pip install PyYAML
- overpy -> pip install overpy
- Algorithms - Robert Sedgewick and Kevin Wayne (Fourth Edition, 2011)
- OpenStreetMaps - all map data is provided through the OpenStreetMaps Overpass API
- US Census - Zip Code Tabulation Areas (https://www.census.gov/geographies/reference-files/time-series/geo/gazetteer-files.html)
MIT