org.encog.neural.pattern
Class FeedForwardPattern
- java.lang.Object
-
- org.encog.neural.pattern.FeedForwardPattern
-
- All Implemented Interfaces:
- NeuralNetworkPattern
public class FeedForwardPattern extends java.lang.Object implements NeuralNetworkPattern
Used to create feedforward neural networks. A feedforward network has an input and output layers separated by zero or more hidden layers. The feedforward neural network is one of the most common neural network patterns.
-
-
Constructor Summary
Constructors Constructor and Description FeedForwardPattern()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description voidaddHiddenLayer(int count)Add a hidden layer, with the specified number of neurons.voidclear()Clear out any hidden neurons.MLMethodgenerate()Generate the feedforward neural network.ActivationFunctiongetActivationOutput()voidsetActivationFunction(ActivationFunction activation)Set the activation function to use on each of the layers.voidsetActivationOutput(ActivationFunction activationOutput)voidsetInputNeurons(int count)Set the number of input neurons.voidsetOutputNeurons(int count)Set the number of output neurons.
-
-
-
Method Detail
-
addHiddenLayer
public void addHiddenLayer(int count)
Add a hidden layer, with the specified number of neurons.- Specified by:
addHiddenLayerin interfaceNeuralNetworkPattern- Parameters:
count- The number of neurons to add.
-
clear
public void clear()
Clear out any hidden neurons.- Specified by:
clearin interfaceNeuralNetworkPattern
-
generate
public MLMethod generate()
Generate the feedforward neural network.- Specified by:
generatein interfaceNeuralNetworkPattern- Returns:
- The feedforward neural network.
-
setActivationFunction
public void setActivationFunction(ActivationFunction activation)
Set the activation function to use on each of the layers.- Specified by:
setActivationFunctionin interfaceNeuralNetworkPattern- Parameters:
activation- The activation function.
-
setInputNeurons
public void setInputNeurons(int count)
Set the number of input neurons.- Specified by:
setInputNeuronsin interfaceNeuralNetworkPattern- Parameters:
count- Neuron count.
-
setOutputNeurons
public void setOutputNeurons(int count)
Set the number of output neurons.- Specified by:
setOutputNeuronsin interfaceNeuralNetworkPattern- Parameters:
count- Neuron count.
-
getActivationOutput
public ActivationFunction getActivationOutput()
- Returns:
- the activationOutput
-
setActivationOutput
public void setActivationOutput(ActivationFunction activationOutput)
- Parameters:
activationOutput- the activationOutput to set
-
-
DMelt 3.0 © DataMelt by jWork.ORG