Skip to content


Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time
HyperSharpNEAT v2.1 C#,
By David D'Ambrosio or

Documentation for this package is included in this README file. 


The majority of this code is from Colin Green's SharpNEAT.  
(  All original SharpNEAT code is covered
by the original SharpNEAT license as described by Colin Green:

"The SharpNeat project consists of the core code packaged as SharpNeatLib
and the main application simply called SharpNeat. SharpNeatLib is released
under the Gnu Lesser General Public License (LGPL) which means you can link
to it from your own programs, proprietory or otherwise. 

The SharpNeat application is released under the Gnu General Public License

The additional applications, PreyCaptureSimulator and PoleBalancingSimulator
have no license and are public domain. Modify them at your will."

HyperSharpNEAT modifies original SharpNEAT in the 
following ways to transform it into a HyperNEAT implementation:

-Updated several lists to .NET 2.0 generic versions.  This was done 
simply for efficiency, however Colin Green's original sorting and
manipulation functions were kept as they were found to be more efficient
than built in versions.
-Added the ability have multiple activation functions in a single network.
-Removed the GUI and extra experiments.
-Added HyperNEAT specific classes
    -Substrate.cs: Defines the substrate on which neural networks are 
created.  Should be inherited and implemented for specific experiments.
    -HyperNEATParmeters.cs: Reads parameters from a file that are 
specific to HyperNEAT.  Should be inherited and implemented for specific

The HyperNEAT additions are covered by the following license:

This program is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License version 2 as published
by the Free Software Foundation (LGPL may be granted upon request). This 
program is distributed in the hope that it will be useful, but without any 
warranty; without even the implied warranty of merchantability or fitness
for a particular purpose. See the GNU General Public License for more


We hope that this software will be a useful starting point for your own
explorations in interactive evolution with NEAT. The software is 
provided as is,
however, we will do our best to maintain it and accommodate
suggestions. If you want to be notified of future releases of the
software or have questions, comments, bug reports or suggestions, send
email to

Alternatively, you may post your questions on the NEAT Users Group at :

The following explains how to use HyperNEAT.  For information on compiling
HyperNEAT, please see the section on compiling below.

HyperNEAT is an extension of NEAT (NeuroEvolution of Augmenting Topologies)
that evolves CPPNs (Compositional Pattern Producing Networks) that
encode large-scale neural network connectivity patterns.  A complete
explanation of HyperNEAT is available here:

  author       = "David B. D'Ambrosio and Kenneth O. Stanley",
  title        = "A Novel Generative Encoding for Exploiting Neural 
		  Network Sensor and Output Geometry",
  booktitle    = "Proceedings of the Genetic and Evolutionary
                  Computation Conference (GECCO 2007)",
  year         = 2007,
  publisher    = "ACM Press",
  address      = "New York, NY",
  site         = "London",
  url          = "",

The version of HyperNEAT distributed in this package executed the 
experiments in the following paper, with a few alterations:

  author       = "David B. D'Ambrosio and Kenneth O. Stanley",
  title        = "Generative Encoding for Multiagent Learning",
  booktitle    = "Proceedings of the Genetic and Evolutionary
                  Computation Conference (GECCO 2008)",
  year         = 2008,
  publisher    = "ACM Press",
  address      = "New York, NY",
  site         = "Atlanta, GA",
  url          = "",

For more information, please visit the EPlex website at:

or see more of our publications on HyperNEAT and CPPNs at:

The executable "CommandLineEvolution.exe" is located in the "release" 
directory of the same project.  It runs the multiagent predator prey experiment
described below with the parameters in the params.txt file and on the command line.  
The project files that are included should also  allow for easy compilation in 
Microsoft's Visual Studio.

The GUI for this experiment is included in the SkirmishVisualization project.  


This is the experiment presented in the GECCO 2008 paper (see above).  The
goal of the experiment is for a group of predators to capture a group of prey.

When run, experiment will output the generation number, the fitness, and 
the amount of time per generation, for each generation.

The CommandLineEvolution.exe can take several command line arguments.

-folder "foldername": "foldername" is the path to a folder where the results are stored
if none if specified, results will be output to the current directory

-multi "true or false":if true, the substrate will be heterogeneous, if false the 
substrate will be homogeneous, the default is homogeneous

-seed "filename":specifies the path to a file containing the seed for evolution.  For
Heterogeneous substrates, you MUST seed with the included seedGenomeModulusBlank.xml or
another seed file with the modulus nodes added.

-shape "shapeType": specifies which shape of prey to train against, valid options are
triangle, diamond, square, and L, the default is triangle.

To run different version of the experiments change the parameters in the 
included params.txt using this guide:

Threshold .2
WeightRange 3
NumberofThreads 2
SubstrateActivationFunction SteepenedSigmoid
BipolarSigmoid .25
Sine .25
Gaussian .25
Linear .25

Threshold defines the minimum value a CPPN must output for that 
connection to be expressed, should be 0-1.

WeightRange defines the minimum and maximum values for weights on substrate
connections, they go from -WieghtRange to +WeightRange, can be any integer.

NumberofThreads defines the number of simultaneous evaluations to run.  
This can be any integer greater than 0, however numbers greater than
the number of cores/processors you have available can degrade performance.

SubstrateActivationFunction determines which activation function each node
in the substrate will have.  This can be any of the activation functions in 
SharpNEATLib, you can add your own as well.  The activation function is the name of the 
.cs file containing that function (they are accessed by reflection, so case counts).

Activation Functions that can be in the CPPN start with 
"StartActivationFunctions" and are listed one per line and ended with 
"EndActivationFunctions".  Each activation function is the name of the .cs file
containing that function (they are accessed by reflection, so case counts) followed
by the probability of that function appearing.

The GUI interface to the experiment is included in the SkirmishVisualization project.
To use the GUI, first load a genome by choosing File->Load Genome and selecting a genome
file.  Then change toggle multi to reflect if the genome is homogeneous or heterogeneous.
Next you need to select a group of prey by pressing one of the following keys:
"1,2,3,4,5" These are the 5 single agent, seed training worlds.
"q,w,e" Three variations of the triangle.
"a,s,d" Three variations of the diamond.
"z,x,c" Three variations of the square.
"r,t,y" Three variations of the L.
Clicking on an already displayed scenario adds a prey at that location.

Pressing 'm' toggles the display of the pie sensors.
Pressing '/' advances the simulation by 100 time steps.
Pressing any key not mentioned here advances the simulation 1 time step.

Unfortunately, changes to the code have rendered the original results incompatible with
the current visualization tools.  Original results are available by request from


Everything necessary to compile HyperSharpNEAT is included in this release.


To run on these systems, compile and run with the latest version of Mono.


The included project files have everything set up to run in Microsoft 
Visual Studio.


We are available to answer questions at the NEAT Users Group:

7. Acknowledgements

Special thanks to Colin Green for creating SharpNEAT.


Unofficial mirror of David B. D'Ambrosio's HyperSharpNEAT






No releases published


No packages published