public class EchoStateNetwork extends Subnetwork
Constructor and Description |
---|
EchoStateNetwork(Network network,
int inputNodes,
int reservoirNodes,
int outputNodes,
java.awt.geom.Point2D initialPosition)
Constructor with size of layers specified.
|
EchoStateNetwork(Network network,
java.awt.geom.Point2D initialPosition)
Creates an empty ESN where neuron groups and synapse groups must be
manually added.
|
Modifier and Type | Method and Description |
---|---|
void |
connectLayers(Sparse inToRes,
Sparse resRecurrent,
Sparse outToRes)
Connects all the layers of the network based on 3 connection objects each
with their own connection parameters.
|
double[][] |
getInputData() |
NumericMatrix |
getInputDataMatrix()
Wrap input data in a DataMatrix Object.
|
NeuronGroup |
getInputLayer() |
Randomizer |
getNoiseGenerator() |
NeuronGroup |
getOutputLayer() |
NeuronGroup |
getReservoirLayer() |
double[][] |
getTargetData() |
NumericMatrix |
getTargetDataMatrix()
Wrap target data in a DataMatrix Object.
|
Network.TimeType |
getTimeType() |
Trainer |
getTrainer()
Return a trainer object that can be used to train this ESN.
|
java.lang.String |
getUpdateMethodDesecription()
Returns a description of this group's update method, which is displayed
in the update manager panel.
|
boolean |
getUseNoise() |
void |
initializeInputLayer(NeuronGroup neuronGroup)
Initializes the input layer from a neuron group and adds it to the ESN.
|
void |
initializeOutput(NeuronGroup neuronGroup)
Initializes the output layer and adds it to the ESN.
|
void |
initializeReservoir(NeuronGroup neuronGroup,
SynapseGroup synapseGroup,
double spectralRadius)
Initializes the reservoir.
|
void |
positionLayers()
A helper method which positions the layers relative to each other in
an aesthetically pleasing arrangement.
|
void |
setBackWeights(boolean backWeights)
Set to true for weights from output to reservoir.
|
void |
setDirectInOutWeights(boolean directInOutWeights)
Set to true for weights directly from input to output.
|
void |
setInputData(double[][] inputData) |
void |
setNoise(boolean noise) |
void |
setNoiseGenerator(Randomizer noiseGenerator) |
void |
setRecurrentOutWeights(boolean recurrentWeights)
Set to true for the output to receive input from itself from the previous
time-step.
|
void |
setReservoirNeuronType(NeuronUpdateRule reservoirNeuronType)
Set type of reservoir neurons.
|
void |
setSpectralRadius(double spectralRadius)
Set spectral radius.
|
void |
setTargetData(double[][] targetData) |
void |
setTimeType(Network.TimeType timeType) |
void |
setUseNoise(boolean noise) |
void |
update()
Update this group.
|
addAndLabelSynapseGroup, addNeuronGroup, addRowToTrainingSet, addSynapseGroup, clearActivations, connectNeuronGroups, connectNeuronGroups, connectNeuronGroups, delete, displayNeuronGroups, getEnabled, getFlatNeuronList, getFlatSynapseList, getIndexOfNeuronGroup, getLongDescription, getModifiableNeuronList, getNeuronGroup, getNeuronGroup, getNeuronGroupByLabel, getNeuronGroupCount, getNeuronGroupList, getNeuronGroupsAsList, getSynapseGroup, getSynapseGroup, getSynapseGroupByLabel, getSynapseGroupCount, getSynapseGroupList, isEmpty, recursivelySetIds, removeNeuronGroup, removeSynapseGroup, setDisplayNeuronGroups, setEnabled, size, toString
getId, getLabel, getParentGroup, getParentNetwork, getStateInfo, hasParentGroup, isMarkedForDeletion, isTopLevelGroup, setId, setLabel, setMarkedForDeletion, setParentGroup, setStateInfo
public EchoStateNetwork(Network network, int inputNodes, int reservoirNodes, int outputNodes, java.awt.geom.Point2D initialPosition)
network
- the root network wherein ESNBuilder will build componentsinputNodes
- number of input nodesreservoirNodes
- number of reservoir nodesoutputNodes
- number of output nodesinitialPosition
- the initial positionpublic EchoStateNetwork(Network network, java.awt.geom.Point2D initialPosition)
network
- initialPosition
- public void initializeInputLayer(NeuronGroup neuronGroup)
neuronGroup
- public void initializeReservoir(NeuronGroup neuronGroup, SynapseGroup synapseGroup, double spectralRadius)
neuronGroup
- synapseGroup
- spectralRadius
- public void initializeOutput(NeuronGroup neuronGroup)
neuronGroup
- public void positionLayers()
public void update()
update
in class Subnetwork
public void connectLayers(Sparse inToRes, Sparse resRecurrent, Sparse outToRes)
inToRes
- the connection object governing how the input connects to the
reservoir.resRecurrent
- the connection object governing how the reservoir connects to
itself.outToRes
- the connection object governing how the output connects to the
reservoir. If these connections do not exist, pass null. If
backWeights is false these connections will not be made
regardless of whether or not outToRes is null.public Trainer getTrainer()
public void setSpectralRadius(double spectralRadius)
spectralRadius
- the spectral radiuspublic void setReservoirNeuronType(NeuronUpdateRule reservoirNeuronType)
reservoirNeuronType
- public void setBackWeights(boolean backWeights)
backWeights
- public void setRecurrentOutWeights(boolean recurrentWeights)
recurrentWeights
- public void setDirectInOutWeights(boolean directInOutWeights)
directInOutWeights
- weights directly from input to output.public NeuronGroup getInputLayer()
public NeuronGroup getReservoirLayer()
public NeuronGroup getOutputLayer()
public double[][] getInputData()
public void setInputData(double[][] inputData)
inputData
- the inputData to setpublic double[][] getTargetData()
public void setTargetData(double[][] targetData)
targetData
- the targetData to setpublic boolean getUseNoise()
public void setUseNoise(boolean noise)
noise
- the noise to setpublic Randomizer getNoiseGenerator()
public void setNoiseGenerator(Randomizer noiseGenerator)
public void setNoise(boolean noise)
public java.lang.String getUpdateMethodDesecription()
Group
getUpdateMethodDesecription
in class Subnetwork
public Network.TimeType getTimeType()
public void setTimeType(Network.TimeType timeType)
public NumericMatrix getInputDataMatrix()
public NumericMatrix getTargetDataMatrix()