Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.encog.neural.som
Class SOM

    java.lang.Object
      org.encog.ml.BasicML
          org.encog.neural.som.SOM

All Implemented Interfaces:
  Serializable, MLClassification, MLError, MLInput, MLInputOutput, MLMethod, MLOutput, MLProperties, MLResettable

    public class SOM

extends BasicML
implements MLClassification, MLResettable, MLError

A self organizing map neural network.

See Also:
  Serialized Form

Field Summary
`static double` | `VERYSMALL` Do not allow patterns to go below this very small number.

Constructor Summary
`SOM()` Default constructor.
`SOM(int inputCount, int outputCount)` The constructor.

Method Summary
`double` | `calculateError(MLDataSet data)` Calculate the error of the ML method, given a dataset.
`int` | `classify(MLData input)` Classify the input into a group.
`int` | `getInputCount()`
`int` | `getOutputCount()`
`Matrix` | `getWeights()`
`void` | `reset()` Reset the weights.
`void` | `reset(int seed)` Reset the weights with a seed.
`void` | `setWeights(Matrix weights)`
`void` | `updateProperties()` Update any objeccts when a property changes.
`int` | `winner(MLData input)` An alias for the classify method, kept for compatibility with earlier versions of Encog.

Methods inherited from class org.encog.ml.BasicML
`getProperties, getPropertyDouble, getPropertyLong, getPropertyString, setProperty, setProperty, setProperty`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### VERYSMALL

    public static final double VERYSMALL

  Do not allow patterns to go below this very small number.

  See Also:
    Constant Field Values

Constructor Detail

### SOM

    public SOM()

  Default constructor.

### SOM

    public SOM(int inputCount,
               int outputCount)

  The constructor.

  Parameters:
    `inputCount` - Number of input neurons
    `outputCount` - Number of output neurons

Method Detail

### calculateError

    public double calculateError(MLDataSet data)

  Calculate the error of the ML method, given a dataset.

  Specified by:
    `calculateError` in interface `MLError`
  Parameters:
    `data` - The dataset.
  Returns:
    The error.

### classify

    public int classify(MLData input)

  Classify the input into a group.

  Specified by:
    `classify` in interface `MLClassification`
  Parameters:
    `input` - The input data to classify.
  Returns:
    The group that the data was classified into.

### getInputCount

    public int getInputCount()

  Specified by:
    `getInputCount` in interface `MLInput`
  Returns:
    The input.

### getOutputCount

    public int getOutputCount()

  Specified by:
    `getOutputCount` in interface `MLOutput`
  Returns:
    The output count.

### getWeights

    public Matrix getWeights()

  Returns:
    the weights

### reset

    public void reset()

  Reset the weights.

  Specified by:
    `reset` in interface `MLResettable`

### reset

    public void reset(int seed)

  Reset the weights with a seed.

  Specified by:
    `reset` in interface `MLResettable`
  Parameters:
    `seed` - The seed value.

### setWeights

    public void setWeights(Matrix weights)

  Parameters:
    `weights` - the weights to set

### updateProperties

    public void updateProperties()

  Update any objeccts when a property changes.

  Specified by:
    `updateProperties` in interface `MLProperties`
  Specified by:
    `updateProperties` in class `BasicML`

### winner

    public int winner(MLData input)

  An alias for the classify method, kept for compatibility with earlier versions of Encog.

  Parameters:
    `input` - The input pattern.
  Returns:
    The winning neuron.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2014. All Rights Reserved.