org.joone.io
Class StreamInputSynapse
- java.lang.Object
-
- org.joone.engine.Synapse
-
- org.joone.io.StreamInputSynapse
-
- All Implemented Interfaces:
- java.io.Serializable, InputPatternListener, Learnable, LearnableSynapse, NeuralElement, OutputPatternListener, Inspectable, InputSynapse, PlugInListener
- Direct Known Subclasses:
- FileInputSynapse, ImageInputSynapse, InputConnector, InputSwitchSynapse, JDBCInputSynapse, MemoryInputSynapse, ParityInputSynapse, URLInputSynapse, XLSInputSynapse, YahooFinanceInputSynapse
public abstract class StreamInputSynapse extends Synapse implements InputSynapse, Inspectable
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor and Description StreamInputSynapse()
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method and Description booleanaddPlugIn(ConverterPlugIn aNewPlugIn)Adds a plug in to the stream input synapse for data preprocessing.voidaddPlugInListener(PlugInListener aListener)Adds a plug-in lsitener to this input stream.java.util.TreeSetcheck()Check that parameters are set correctly.voiddataChanged(PlugInEvent data)This method is called by plug-ins whenever data is changed.PatternfwdGet()Returns the pattern coming from the previous layer during the recall phasePatternfwdGet(InputConnector conn)This method is called by the InputConnector in order to get the next input pattern available for that connectorjava.lang.StringgetAdvancedColumnSelector()java.util.ListgetAllPlugInListeners()Gets all the plug-in listeners.intgetCurrentRow()Getter for property currentRow.chargetDecimalPoint()Returns the decimal point accepted (19/04/00 0.23.56)intgetFirstCol()Deprecated.intgetFirstRow()java.util.VectorgetInputPatterns()Getter for property inputPatterns.java.util.VectorgetInputVector()intgetLastCol()Deprecated.intgetLastRow()intgetMaxBufSize()Getter for property maxBufSize.ConverterPlugIngetPlugIn()Gets the attached ConverterPlugin, if anyPatterngetStream()voidgotoFirstLine()voidgotoLine(int numLine)Point to the indicated line into the input streamjava.lang.StringInspectableTitle()Method to get the title to show in the InspectionFrame tab.java.util.CollectionInspections()Method to get a collection of inspectable objects.booleanisBuffered()Checks if the input synapse is buffered or notbooleanisEOF()Returns if reached the EOF (10/04/00 23.16.20)booleanisStepCounter()Returns if this input layer is an active counter of the steps.intnumColumns()voidreadAll()voidremoveAllPlugIns()Removes (and disconnects) all (cascading) plug-ins.voidremovePlugInListener(PlugInListener aListener)Removes a plug-in listener from this input stream.voidreset()reset the state of the input synapsevoidresetInput()Reset the input stream to read its content againvoidrevPut(Pattern array)Method to put an error pattern backward to the previous layervoidsetAdvancedColumnSelector(java.lang.String newAdvColSel)voidsetBuffered(boolean aNewBuffered)Sets the buffer-mode for this input synapse.voidsetDecimalPoint(char dp)voidsetFirstCol(int firstCol)Deprecated.voidsetFirstRow(int newFirstRow)Inserire qui la descrizione del metodo.voidsetInputPatterns(java.util.Vector inputPatterns)Setter for property inputPatterns.voidsetLastCol(int lastCol)Deprecated.voidsetLastRow(int newLastRow)Inserire qui la descrizione del metodo.voidsetMaxBufSize(int maxBufSize)Setter for property maxBufSize.booleansetPlugin(ConverterPlugIn newPlugIn)Deprecated.addPlugIn(ConverterPlugIn). If you want to replace the plug in by setting a new plug in please use#removeAllPlugIns(ConverterPlugIn)andaddPlugIn(ConverterPlugIn).voidsetPlugIn(ConverterPlugIn newPlugIn)Added for XML serialization **** DO NOT USE **** Use getPlugin insteadvoidsetStepCounter(boolean newStepCounter)Inserire qui la descrizione del metodo.-
Methods inherited from class org.joone.engine.Synapse
addNoise, canCountSteps, fwdPut, getIgnoreBefore, getInputDimension, getLearner, getLearningRate, getMomentum, getMonitor, getName, getOutputDimension, getWeights, init, initLearner, isEnabled, isInputFull, isLoopBack, isOutputFull, randomize, revGet, setEnabled, setIgnoreBefore, setInputDimension, setInputFull, setLearningRate, setLoopBack, setMomentum, setMonitor, setName, setOutputDimension, setOutputFull, setWeights
-
-
-
-
Method Detail
-
fwdGet
public Pattern fwdGet()
Description copied from interface:InputPatternListenerReturns the pattern coming from the previous layer during the recall phase- Specified by:
fwdGetin interfaceInputPatternListener- Overrides:
fwdGetin classSynapse- Returns:
- neural.engine.Pattern
-
getDecimalPoint
public char getDecimalPoint()
Returns the decimal point accepted (19/04/00 0.23.56)- Specified by:
getDecimalPointin interfaceInputSynapse- Returns:
- char
-
getFirstRow
public int getFirstRow()
- Specified by:
getFirstRowin interfaceInputSynapse- Returns:
- int
-
getInputVector
public java.util.Vector getInputVector()
- Returns:
- java.util.Vector
-
getLastRow
public int getLastRow()
- Specified by:
getLastRowin interfaceInputSynapse- Returns:
- int
-
getStream
public Pattern getStream() throws java.io.IOException
- Throws:
java.io.IOException
-
gotoFirstLine
public void gotoFirstLine() throws java.io.IOException- Specified by:
gotoFirstLinein interfaceInputSynapse- Throws:
java.io.IOException
-
gotoLine
public void gotoLine(int numLine) throws java.io.IOExceptionPoint to the indicated line into the input stream- Specified by:
gotoLinein interfaceInputSynapse- Throws:
java.io.IOException
-
isBuffered
public boolean isBuffered()
Checks if the input synapse is buffered or not- Specified by:
isBufferedin interfaceInputSynapse- Returns:
truein case the input stream is buffered, false otherwise.
-
isEOF
public boolean isEOF()
Returns if reached the EOF (10/04/00 23.16.20)- Specified by:
isEOFin interfaceInputSynapse- Returns:
- boolean
-
isStepCounter
public boolean isStepCounter()
Returns if this input layer is an active counter of the steps. Warning: in a neural net there can be only one StepCounter element! (10/04/00 23.23.26)- Specified by:
isStepCounterin interfaceInputSynapse- Returns:
- boolean
-
numColumns
public int numColumns()
-
readAll
public void readAll()
- Specified by:
readAllin interfaceInputSynapse
-
revPut
public void revPut(Pattern array)
Description copied from interface:InputPatternListenerMethod to put an error pattern backward to the previous layer- Specified by:
revPutin interfaceInputPatternListener- Overrides:
revPutin classSynapse- Parameters:
array- neural.engine.Pattern
-
setBuffered
public void setBuffered(boolean aNewBuffered)
Sets the buffer-mode for this input synapse.- Specified by:
setBufferedin interfaceInputSynapse- Parameters:
aNewBuffered-trueif the input should be buffered.falseif the input should not be buffered, the input will be retrieved from the input source every cycle again.Whenever any converter plug in is added, the buffer-mode will be set to
true, regardless of the parameter's argument.
-
setDecimalPoint
public void setDecimalPoint(char dp)
- Specified by:
setDecimalPointin interfaceInputSynapse
-
setFirstRow
public void setFirstRow(int newFirstRow)
Inserire qui la descrizione del metodo. Data di creazione: (11/04/00 1.22.28)- Specified by:
setFirstRowin interfaceInputSynapse- Parameters:
newFirstRow- int
-
resetInput
public void resetInput()
Reset the input stream to read its content again- Specified by:
resetInputin interfaceInputSynapse
-
setLastRow
public void setLastRow(int newLastRow)
Inserire qui la descrizione del metodo. Data di creazione: (11/04/00 1.22.34)- Specified by:
setLastRowin interfaceInputSynapse- Parameters:
newLastRow- int
-
addPlugIn
public boolean addPlugIn(ConverterPlugIn aNewPlugIn)
Adds a plug in to the stream input synapse for data preprocessing. If one or more plug ins are already added to the this synapse, the plug in will be added at the end of the list of plug ins.- Parameters:
aNewPlugIn- The new converter plug in to add (at the end of the list).- Returns:
truewhen the plug in is added,falsewhen the plug in is not added, e.g. in case the plug in is already added / connected to another synapse.
-
removeAllPlugIns
public void removeAllPlugIns()
Removes (and disconnects) all (cascading) plug-ins.
-
setPlugin
public boolean setPlugin(ConverterPlugIn newPlugIn)
Deprecated.addPlugIn(ConverterPlugIn). If you want to replace the plug in by setting a new plug in please use#removeAllPlugIns(ConverterPlugIn)andaddPlugIn(ConverterPlugIn).Sets the plugin for the data preprocessing.- Parameters:
newPlugIn- the plug in to set
-
getPlugIn
public ConverterPlugIn getPlugIn()
Gets the attached ConverterPlugin, if any- Returns:
- neural.engine.ConverterPlugIn
-
setPlugIn
public void setPlugIn(ConverterPlugIn newPlugIn)
Added for XML serialization **** DO NOT USE **** Use getPlugin instead
-
setStepCounter
public void setStepCounter(boolean newStepCounter)
Inserire qui la descrizione del metodo. Data di creazione: (10/04/00 23.23.26)- Specified by:
setStepCounterin interfaceInputSynapse- Parameters:
newStepCounter- boolean
-
getLastCol
public int getLastCol()
Deprecated.Getter for property lastCol.- Specified by:
getLastColin interfaceInputSynapse- Returns:
- Value of property lastCol.
-
setLastCol
public void setLastCol(int lastCol) throws java.lang.IllegalArgumentExceptionDeprecated.Setter for property lastCol.- Specified by:
setLastColin interfaceInputSynapse- Parameters:
lastCol- New value of property lastCol.- Throws:
java.lang.IllegalArgumentException
-
getFirstCol
public int getFirstCol()
Deprecated.Getter for property firstCol.- Specified by:
getFirstColin interfaceInputSynapse- Returns:
- Value of property firstCol.
-
setFirstCol
public void setFirstCol(int firstCol) throws java.lang.IllegalArgumentExceptionDeprecated.Setter for property firstCol.- Specified by:
setFirstColin interfaceInputSynapse- Parameters:
firstCol- New value of property firstCol.- Throws:
java.lang.IllegalArgumentException
-
getAdvancedColumnSelector
public java.lang.String getAdvancedColumnSelector()
-
setAdvancedColumnSelector
public void setAdvancedColumnSelector(java.lang.String newAdvColSel)
-
dataChanged
public void dataChanged(PlugInEvent data)
Description copied from interface:PlugInListenerThis method is called by plug-ins whenever data is changed.- Specified by:
dataChangedin interfacePlugInListener- Parameters:
data- the event that is send, i.e. the event indicating that the data is changed.
-
check
public java.util.TreeSet check()
Check that parameters are set correctly.- Specified by:
checkin interfaceNeuralElement- Overrides:
checkin classSynapse- Returns:
- validation errors.
- See Also:
Synapse
-
Inspections
public java.util.Collection Inspections()
Description copied from interface:InspectableMethod to get a collection of inspectable objects.- Specified by:
Inspectionsin interfaceInspectable- Overrides:
Inspectionsin classSynapse- Returns:
- list of Inspectable objects
- See Also:
org.joone.Inspection
-
InspectableTitle
public java.lang.String InspectableTitle()
Description copied from interface:InspectableMethod to get the title to show in the InspectionFrame tab.- Specified by:
InspectableTitlein interfaceInspectable- Overrides:
InspectableTitlein classSynapse- Returns:
- title of the class.
- See Also:
org.joone.InspectionFrame
-
reset
public void reset()
reset the state of the input synapse- Specified by:
resetin interfaceInputPatternListener- Overrides:
resetin classSynapse
-
getMaxBufSize
public int getMaxBufSize()
Getter for property maxBufSize.- Returns:
- Value of property maxBufSize.
-
setMaxBufSize
public void setMaxBufSize(int maxBufSize)
Setter for property maxBufSize.- Parameters:
maxBufSize- New value of property maxBufSize.
-
getInputPatterns
public java.util.Vector getInputPatterns()
Getter for property inputPatterns. Added for XML serialization- Returns:
- Value of property inputPatterns.
-
setInputPatterns
public void setInputPatterns(java.util.Vector inputPatterns)
Setter for property inputPatterns. Added for XML serialization- Parameters:
inputPatterns- New value of property inputPatterns.
-
fwdGet
public Pattern fwdGet(InputConnector conn)
This method is called by the InputConnector in order to get the next input pattern available for that connector
-
getCurrentRow
public int getCurrentRow()
Getter for property currentRow.- Returns:
- Value of property currentRow.
-
addPlugInListener
public void addPlugInListener(PlugInListener aListener)
Adds a plug-in lsitener to this input stream.- Parameters:
aListener- the listener to add
-
removePlugInListener
public void removePlugInListener(PlugInListener aListener)
Removes a plug-in listener from this input stream.- Parameters:
aListener- the listener to remove
-
getAllPlugInListeners
public java.util.List getAllPlugInListeners()
Gets all the plug-in listeners.- Returns:
- the plug-in listeners.
-
-
DataMelt 3.0 © DataMelt by jWork.ORG