diff --git a/encog-core-cs/Neural/NEAT/NEATNetwork.cs b/encog-core-cs/Neural/NEAT/NEATNetwork.cs index 066ae21e..57a2b4f9 100644 --- a/encog-core-cs/Neural/NEAT/NEATNetwork.cs +++ b/encog-core-cs/Neural/NEAT/NEATNetwork.cs @@ -65,7 +65,7 @@ namespace Encog.Neural.NEAT /// {ACM Press} } /// [Serializable] - public class NEATNetwork : IMLRegression, IMLError + public class NEATNetwork : IMLRegression, IMLClassification, IMLError { /// /// The neuron links. @@ -289,5 +289,12 @@ private void InternalCompute() _preActivation[j] = 0.0F; } } + + /// + public int Classify(IMLData input) + { + IMLData output = Compute(input); + return EngineArray.MaxIndex(output); + } } }