fitrialif / neat-python

A Python version of the NEAT algorithm (NeuroEvolution of Augmenting Topologies)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

NEAT-Python

The basic idea behind NEAT is to evolve both network topology (structural adaptation) and weights/biases (parametrical adaptation).

As a starting point, you can check the XOR experiment in the examples folder.

Version 0.1

Version .1 was developed only for academic purposes in 2007. Back then there weren't many neural networks APIs available in Python and most of them where not suitable for the idea we needed for our experiments. The project was hosted by Google Code and versioned using Apache Subversion (or simply SVN for those born in the GIT era).

The main ideia was to experiment with Continuous-Time Neural Networks (CTNN) in an Artificial Life environment, similar to works by Larry Yaeger called Polyworld and Karl Sims Evolved Creatures. A benchmark with the inverted double pole demonstrated that CTNNs could better handle the task as we've shown in the paper Structural and Parametric Evolution of Continuous-Time Recurrent Neural Networks.

The Python code was based on the C++ version by Kenneth O'Stanley and his famous paper on NeuroEvolution of Augmented Topologies. The inclusion of some C code was necessary to significantly increase the speed of the neural module.

Currently this version is only compatible with Python <= 2.7

Things TODO:

  • Update to support Python 3
  • Create a pip package to facilitate the compilation for the C code.
  • Probably use PyTorch or TensorFlow, with a slightly different genome encoding to accommodate these changes. I'm aware of some approaches in the same direction by the NEAT community.
  • Add more activation functions and expand the ability to each neuron to adapt its own activation function.

About

A Python version of the NEAT algorithm (NeuroEvolution of Augmenting Topologies)


Languages

Language:Python 75.4%Language:C++ 24.6%