Skip to content

This small project aims to reproduce the ant colony optimization algorithm.

License

Notifications You must be signed in to change notification settings

ThibaultNocchi/Python-Ant-Colony-Algorithm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Python Ant Colony Algorithm

This small project aims to reproduce the ant colony optimization algorithm. It is a technique used to solve problems which can be reduced to finding good paths through graphs. It follows the pattern of a real ant colony. Go check this out on Wikipedia, it's really interesting!

Description

This project is built in Python around three modules:

  • The model, which contains all the interesting formulas and the interaction between the ants and their world.
  • The GUI, which displays the world as a nice grid, great to see the evolution.
  • The console, which runs in the background way faster and display a path as text (with some stats) when the model thinks it converged.

Getting Started

Dependencies

  • Python 3
  • Pygame library.

Installing

  • Grab the Python files from GitHub
  • pip install -r requirements.txt in the project directory.

Executing program

  • Simply run GUI.py or Console.py (Model.py needs to be in the same folder).
python GUI.py
python Console.py

Help

Both GUI.py and Console.py accept command line parameters to edit some constants. Run this command to get the parameters:

python GUI.py -h
python GUI.py -h

Authors

Thibault Nocchi To contact me, file an issue, thanks.

License

This project is licensed under the Unlicense License - see the LICENSE file for details.

About

This small project aims to reproduce the ant colony optimization algorithm.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages