Foraging for resources is a ubiquitous activity conducted by living organisms in a shared environment to maintain their homeostasis. Modelling multi-agent foraging in-silico allows us to study both individual and collective emergent behaviour in a tractable manner. Agent-based modelling has proven to be effective in simulating such tasks, though scaling the simulations to accommodate large numbers of agents with complex dynamics remains challenging. In this work, we present Foragax, a general-purpose, scalable, hardware-accelerated, multi-agent foraging toolkit. Leveraging the JAX library, our toolkit can simulate thousands of agents foraging in a common environment, in an end-to-end vectorized and differentiable manner. The toolkit provides agent-based modelling tools to model various foraging tasks, including options to design custom spatial and temporal agent dynamics, control policies, sensor models, and boundary conditions. Further, the number of agents during such simulations can be increased or decreased based on custom rules. While applied to foraging, the toolkit can also be used to model and simulate a wide range of other multi-agent scenarios.
翻译:资源觅食是生物体在共享环境中为维持内稳态而普遍进行的行为。通过计算模型对多智能体觅食行为进行建模,使我们能够以可处理的方式研究个体与群体涌现行为。基于智能体的建模方法已被证明能有效模拟此类任务,但将模拟扩展到包含大量具有复杂动态特性的智能体仍具挑战性。本研究提出Foragax——一个通用、可扩展、硬件加速的多智能体觅食工具包。该工具包利用JAX库,能以端到端向量化且可微分的方式模拟数千个智能体在共同环境中的觅食行为。工具包提供基于智能体的建模工具,可用于模拟各类觅食任务,包括设计自定义的时空智能体动态特性、控制策略、传感器模型及边界条件。此外,模拟过程中的智能体数量可根据自定义规则动态增减。虽然主要应用于觅食场景,该工具包也可用于建模和模拟广泛的其他多智能体场景。