Simple implementation of Ant Colony Optimization algorithm written in python3. Ant Colony Optimization is a probabilistic technique for solving computational problems which can be reduced to finding good paths through graphs.
- Install Numpy
pip install numpy
- Generate your matrix. See distance_matrix.txt for example. To generate random distance matrix run:
from aco import gen_matrix
matrix = gen_matrix(40)
np.savetxt('distance_matrix.txt', matrix, fmt='%g', delimiter=' ')
- Tweak constants in
aco.py
- Run
python aco.py
- pjmattingly - Initial work - Github repo
This project is licensed under the MIT License - see the LICENSE file for details