Skip to content

About

SwarmAreaCoverage is a simulation for agents to cover a certain area unlock the performance of the swarm to better perform this task.

Topics

Resources

Contributing

Stars

0 stars

Watchers

1 watching

Forks

Repository files navigation

SwarmAreaCoverage

SwarmAreaCoverage is a simulation for agents to cover a certain area unlock the performance of the swarm to better perform this task.

Introduction

Get Start

The required dependences are listed below:

  • Mesa (Its dependencies are not listed fully!)
  • Solara
  • Matplotlib
  • Numpy
  • Scipy First of all install all the dependency. Mesa required all this library, if you install only Mesa you are not able to use it. Install also the other if not done yet.

Install

This repository is basedo on python 3.12.9. It should work also with the version 3.11.0 and older.

First of all you must upgrade all packages, and if you don't have pip you must install it.

  brew install --upgrade pip

Once you have installed all the dependencies, you can clone this repository and perform the simulation.

to clone the repository you must have git installed.

  brew install git
  git clone https://github.com/Camuy/SwarmAreaCoverage.git

In a terminal you execute this commands to install all the dependency:

 python -m venv venv
 source venv/bin/activate
 pip install -r requirements.txt

Now ypou should able to run the simulation

Usage

The repo is divided in 3 important files:

  • app.py
  • model.py
  • agent.py

is possible to have other files that changes informatiotion on these files, like the information of the gradient on the environment.

app.py

It create the enviroment on top of whom the other codes are run. It gives you the information to access the localhost at port 8765 to get access to the simulation itself.

model.py

It is a file responsable of creating the information on the simulation environment and mathematical model.

agent.py

It create all the instruction each singlre agent has to follow. It besically dictate the role to be followed by the agent.

Run

To run the code you simply have to run this code.

  solara run app.py

the simulation will be launched and you can see it on a web page, so in a browser serach for http://localhost:8765

About

SwarmAreaCoverage is a simulation for agents to cover a certain area unlock the performance of the swarm to better perform this task.

Topics

Resources

Contributing

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages