How vishwanatha01/flowgrid works
FlowGrid is a synthetic-city traffic-management web application. Users explore live conditions, plan routes, optimize signals, run simulations, and inspect network analytics through a Flask API and browser UI. The principal workflow runs from a user request through Flask validation and domain services to graph/model results; those results are presented in the relevant UI. The graph preserves the README’s major product capabilities and core algorithm/service modules. Relationships are limited to README statements and indexed or excerpted references; unsampled UI wiring is not inferred.
Main entry points: app.py API and pages · routing.py Route services · network.py Synthetic road network · network_analytics.py Network analytics
Components 24
Web application
- API and pages
app.py - Control center
static/js/dashboard.js - City map
static/js/map.js - Route planner
static/js/routes.js - Signal optimizer
static/js/signals.js - Simulation lab
static/js/simulation.js - Analytics view
static/js/analytics.js
Traffic model
- Synthetic road network
simulation/network.py - Live traffic model
simulation/live.py
Route planning
- Route services
simulation/routing.py - A-star search
algorithms/astar.py - Dijkstra search
algorithms/dijkstra.py - Bellman-Ford search
algorithms/bellman_ford.py - Breadth-first search
algorithms/bfs.py - Alternative routes
algorithms/yen.py
Signals and simulation
- Signal timing algorithms
algorithms/traffic_signal.py - Queue simulation
simulation/engine.py
Analytics and forecasting
- Scaling benchmarks
analysis/benchmarks.py - Network analytics
analysis/network_analytics.py - Floyd-Warshall
algorithms/floyd_warshall.py - Kruskal spanning tree
algorithms/kruskal.py - Forecast service
analysis/forecasting.py - Holt-Winters model
algorithms/forecast.py
Other components
- Traffic operator
Connections 31
- Traffic operator → API and pages: requests
README.md - API and pages → Synthetic road network: serves network
app.py - API and pages → Route services: routes requests
app.py - API and pages → Live traffic model: reads traffic
app.py - API and pages → Queue simulation: runs simulations
app.py - API and pages → Signal timing algorithms: computes timing
app.py - API and pages → Scaling benchmarks: requests benchmarks
app.py - API and pages → Network analytics: requests analytics
app.py - API and pages → Forecast service: requests forecasts
app.py - API and pages → Control center: presents control center
README.md - API and pages → City map: presents city map
README.md - API and pages → Route planner: presents route planner
README.md - API and pages → Signal optimizer: presents signal optimizer
README.md - API and pages → Simulation lab: presents simulation lab
README.md - API and pages → Analytics view: presents analytics
README.md - Live traffic model → Synthetic road network: uses roads
simulation/live.py - Route services → Live traffic model: gets conditions
simulation/routing.py - Route services → Synthetic road network: builds route graph
simulation/routing.py - Route services → A-star search: dispatches search
simulation/routing.py - Route services → Dijkstra search: dispatches search
simulation/routing.py - Route services → Bellman-Ford search: dispatches search
simulation/routing.py - Route services → Breadth-first search: dispatches search
simulation/routing.py - Route services → Alternative routes: requests alternatives
simulation/routing.py - Alternative routes → Dijkstra search: finds spur paths
algorithms/yen.py - Queue simulation → Signal timing algorithms: uses signal timing
simulation/engine.py - Network analytics → Synthetic road network: reads road graph
analysis/network_analytics.py - Network analytics → Floyd-Warshall: computes all pairs
analysis/network_analytics.py - Network analytics → Kruskal spanning tree: computes spanning tree
analysis/network_analytics.py - Forecast service → Holt-Winters model: fits forecasts
analysis/forecasting.py - Forecast service → Live traffic model: uses demand profile
analysis/forecasting.py - Forecast service → Synthetic road network: uses junction data
analysis/forecasting.py