Agent-based modeling plays an essential role in gaining insights into biology, sociology, economics, and other fields. However, many existing agent-based simulation platforms are not suitable for large-scale studies due to the low performance of the underlying simulation engines. To overcome this limitation, we present a novel high-performance simulation engine. We identify three key challenges for which we present the following solutions. First, to maximize parallelization, we present an optimized grid to search for neighbors and parallelize the merging of thread-local results. Second, we reduce the memory access latency with a NUMA-aware agent iterator, agent sorting with a space-filling curve, and a custom heap memory allocator. Third, we present a mechanism to omit the collision force calculation under certain conditions. Our evaluation shows an order of magnitude improvement over Biocellion, three orders of magnitude speedup over Cortex3D and NetLogo, and the ability to simulate 1.72 billion agents on a single server. Supplementary Materials, including instructions to reproduce the results, are available at: https://doi.org/10.5281/zenodo.6463816
翻译:在深入了解生物学、社会学、经济学和其他领域方面,基于代理的模型建模起着至关重要的作用。然而,许多现有的基于代理的模拟平台由于基础模拟引擎的性能低,不适合大规模研究。为了克服这一局限性,我们提出了一个新型的高性能模拟引擎。我们找出了三种关键挑战,为此我们提出了以下解决方案。首先,为了最大限度地实现平行化,我们提出了一个最佳网格,以搜索邻居,并同时使用线形局部结果。第二,我们用NUMA-awe代理代机减少内存延缓,用一个空间填充曲线排序的代理机,以及一个定制的缓冲存储器。第三,我们提出了一个机制,在某些条件下省略碰撞力计算。我们的评估显示生物细胞的强度改进程度,Cortex3D和NetLogo的3级加速速度,以及模拟单一服务器上17.2亿剂的能力。补充材料,包括复制结果的指示,见:https://doi.org/10858/zeno63816。