Multi-Agent Based Crowd Evacuation Simulation

external-link

Jan 2026

Finished

Multi-agent crowd evacuation simulation built on Mesa (Python agent-based modeling framework). Defines 3 agent types with distinct behaviors: polite (yield, crowd-sensitive), aggressive (push, low deadlock sensitivity), and slow (reduced speed, high density sensitivity). The environment uses a discrete grid (OrthogonalMooreGrid) with 6 scenarios: OPEN, MALL, CORRIDOR, SEATS (theater seats), SNAKE (winding path), and RANDOM. Agents use configurable pathfinding (Manhattan, BFS, A*) to navigate toward exits. Detailed metrics are collected: evacuation rate, macro/micro speed, local density, deadlock factor — both per agent type and globally. Massive batch experiments (1000 runs per config, 16 parallel processes) analyze 7 dimensions: agent density, aggressive impact, slow agent impact, pathfinding algorithms, exit preference, number of exits, and exit width. Includes interactive Jupyter widget visualization and a LaTeX paper.

Technologies
ai

AI

jupyter

Jupyter

latex

LaTeX

matplot

Matplot

numpy

NumPy

pandas

Pandas

plotly

Plotly

python

Python

https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/agent_shape_color_169.png?v=7afa8455e93e531258c9c8f2d1e20484ac5a18f8
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/deadlock_169.png?v=f99ddb9148ad7cac00475e6e5af8d420dfeb9eb9
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/graph_ui_169.png?v=36a7adb28177697a556ab0ba47783dab192695f5
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/heatmap_random_169.png?v=9a0877b2a8cc4451c638e41568a6183c1373f89b
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/heatmap_seats_169.png?v=a41056629dae412f69124a59cafbb0e07880dbd7
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_corridor_169.png?v=a16a27634b2a08739945900a5bb786d1ceca4fa2
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_mall_169.png?v=da7baaa4e0df8b17a640033c6170244881ec1e78
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_open_169.png?v=27ee6b9f4c799db740685926a08a224fa8a4f697
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_random_169.png?v=9b0a1e55fbd997a2bf01e7cc5fd895b95299aec2
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_seats_169.png?v=7b89fbf0e5ecc1d369c7438ee5696f7f00dd0b1a
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_snake_169.png?v=ceb83678f8c35703284f1db77d29382d229f6b89
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/screenshoot_simulation_169.png?v=78111806d44e3c323eae49d02bde705688841469
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/thumbnail_169.webp?v=9ee925a3846387c1784e0d47422d3f900b768a52
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/agent_shape_color_169.png?v=7afa8455e93e531258c9c8f2d1e20484ac5a18f8
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/deadlock_169.png?v=f99ddb9148ad7cac00475e6e5af8d420dfeb9eb9
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/graph_ui_169.png?v=36a7adb28177697a556ab0ba47783dab192695f5
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/heatmap_random_169.png?v=9a0877b2a8cc4451c638e41568a6183c1373f89b
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/heatmap_seats_169.png?v=a41056629dae412f69124a59cafbb0e07880dbd7
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_corridor_169.png?v=a16a27634b2a08739945900a5bb786d1ceca4fa2
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_mall_169.png?v=da7baaa4e0df8b17a640033c6170244881ec1e78
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_open_169.png?v=27ee6b9f4c799db740685926a08a224fa8a4f697
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_random_169.png?v=9b0a1e55fbd997a2bf01e7cc5fd895b95299aec2
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_seats_169.png?v=7b89fbf0e5ecc1d369c7438ee5696f7f00dd0b1a
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_snake_169.png?v=ceb83678f8c35703284f1db77d29382d229f6b89
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/screenshoot_simulation_169.png?v=78111806d44e3c323eae49d02bde705688841469
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/thumbnail_169.webp?v=9ee925a3846387c1784e0d47422d3f900b768a52
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/agent_shape_color_169.png?v=7afa8455e93e531258c9c8f2d1e20484ac5a18f8
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/deadlock_169.png?v=f99ddb9148ad7cac00475e6e5af8d420dfeb9eb9
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/graph_ui_169.png?v=36a7adb28177697a556ab0ba47783dab192695f5
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/heatmap_random_169.png?v=9a0877b2a8cc4451c638e41568a6183c1373f89b
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/heatmap_seats_169.png?v=a41056629dae412f69124a59cafbb0e07880dbd7
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_corridor_169.png?v=a16a27634b2a08739945900a5bb786d1ceca4fa2
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_mall_169.png?v=da7baaa4e0df8b17a640033c6170244881ec1e78
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_open_169.png?v=27ee6b9f4c799db740685926a08a224fa8a4f697
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_random_169.png?v=9b0a1e55fbd997a2bf01e7cc5fd895b95299aec2
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_seats_169.png?v=7b89fbf0e5ecc1d369c7438ee5696f7f00dd0b1a
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_snake_169.png?v=ceb83678f8c35703284f1db77d29382d229f6b89
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/screenshoot_simulation_169.png?v=78111806d44e3c323eae49d02bde705688841469
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/thumbnail_169.webp?v=9ee925a3846387c1784e0d47422d3f900b768a52
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/agent_shape_color_169.png?v=7afa8455e93e531258c9c8f2d1e20484ac5a18f8
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/deadlock_169.png?v=f99ddb9148ad7cac00475e6e5af8d420dfeb9eb9
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/graph_ui_169.png?v=36a7adb28177697a556ab0ba47783dab192695f5
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/heatmap_random_169.png?v=9a0877b2a8cc4451c638e41568a6183c1373f89b
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/heatmap_seats_169.png?v=a41056629dae412f69124a59cafbb0e07880dbd7
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_corridor_169.png?v=a16a27634b2a08739945900a5bb786d1ceca4fa2
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_mall_169.png?v=da7baaa4e0df8b17a640033c6170244881ec1e78
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_open_169.png?v=27ee6b9f4c799db740685926a08a224fa8a4f697
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_random_169.png?v=9b0a1e55fbd997a2bf01e7cc5fd895b95299aec2
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_seats_169.png?v=7b89fbf0e5ecc1d369c7438ee5696f7f00dd0b1a
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/scenario_snake_169.png?v=ceb83678f8c35703284f1db77d29382d229f6b89
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/screenshoot_simulation_169.png?v=78111806d44e3c323eae49d02bde705688841469
https://raw.githubusercontent.com/MiquelGomezCorral/SMA-MultiAgent-Based-Crowd-Simulation/main/readme-images/thumbnail_169.webp?v=9ee925a3846387c1784e0d47422d3f900b768a52