Note that there is a significant amount of duplication between these scripts, and this is intentional. The goal is to make it easier to see what the example is doing, without making the user dig through a bunch of utility code that is not directly related to the NEAT library usage.
Documentation for the library and some of the examples may be found here.
For convenience, a conda environment that supports running all of the examples is available in this directory (see environment.yml).
-
xorA "hello world" sample showing basic usage on the 2-input XOR problem. -
memory-fixedReproduce a fixed-length sequence of binary inputs (currently experimental / not working as intended). -
memory-variableReproduce a variable-length sequence of binary inputs (currently experimental / not working as intended). -
neuron-demoPlot outputs of very simple CTRNN and Izhikevich neuron models. -
single-pole-balancingBalance a pole on top of a movable cart and optionally render videos of successful policies. -
picture2dGenerate 2D color or grayscale images using Compositional Pattern-Producing Networks, including an interactive picture-breeder style demo. -
lunar-landerSolve the Gymnasium LunarLander-v3 environment with a modern API-compatible example. -
bipedal-walkerControl the Gymnasium BipedalWalker-v3 environment using a continuous-action NEAT policy. -
inverted-double-pendulumEvolve a controller for the Gymnasium InvertedDoublePendulum-v5 environment using a MuJoCo-based simulator. -
hopperEvolve a controller for the Gymnasium Hopper-v5 environment using a MuJoCo-based continuous-control task. -
parallel-reproducibleDemonstrate how to useParallelEvaluatorwith deterministic seeding to get reproducible parallel evolution runs. -
exportTrain a small XOR network and export the resulting NEAT network to a framework-agnostic JSON format. -
lorenz-ctrnnEvolve CTRNN networks to predict the Lorenz attractor, demonstrating per-node evolvable time constants (v2.0 feature). -
signal-tracking-gpuGPU-accelerated CTRNN signal tracking comparison (requiresneat-python[gpu]). -
spike-timing-gpuGPU-accelerated Izhikevich spiking network spike timing comparison (requiresneat-python[gpu]). -
openai-landerArchived OpenAI Gym LunarLander example containing pre-trained winner genomes referenced in the documentation.