org.encog.neural.pnn

## Class AbstractPNN

- java.lang.Object
- - org.encog.ml.BasicML
  - - org.encog.neural.pnn.AbstractPNN

- All Implemented Interfaces:
    Serializable, MLMethod, MLProperties
  Direct Known Subclasses:
    BasicPNN

      public abstract class AbstractPNN
      extends BasicML

  Abstract class to build PNN networks upon.
  See Also:
    Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `AbstractPNN(PNNKernelType kernel, PNNOutputMode outputMode, int inputCount, int outputCount)` Constructor.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `abstract MLData` | `compute(MLData input)` Compute the output from the network.
    `double[]` | `getDeriv()`
    `double[]` | `getDeriv2()`
    `double` | `getError()`
    `int` | `getExclude()`
    `int` | `getInputCount()`
    `PNNKernelType` | `getKernel()`
    `int` | `getOutputCount()`
    `PNNOutputMode` | `getOutputMode()`
    `boolean` | `isSeparateClass()`
    `boolean` | `isTrained()`
    `void` | `resetConfusion()` Reset the confusion.
    `void` | `setError(double error)`
    `void` | `setExclude(int exclude)`
    `void` | `setSeparateClass(boolean separateClass)`
    `void` | `setTrained(boolean trained)`

    - ### Methods inherited from class org.encog.ml.BasicML

      `getProperties, getPropertyDouble, getPropertyLong, getPropertyString, setProperty, setProperty, setProperty, updateProperties`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### AbstractPNN

          public AbstractPNN(PNNKernelType kernel,
                     PNNOutputMode outputMode,
                     int inputCount,
                     int outputCount)

      Constructor.
      Parameters:
        `kernel` - The kernel type to use.
        `outputMode` - The output mode to use.
        `inputCount` - The input count.
        `outputCount` - The output count.

  - ### Method Detail

    - #### compute

          public abstract MLData compute(MLData input)

      Compute the output from the network.
      Parameters:
        `input` - The input to the network.
      Returns:
        The output from the network.

    - #### getDeriv

          public double[] getDeriv()

      Returns:
        the deriv

    - #### getDeriv2

          public double[] getDeriv2()

      Returns:
        the deriv2

    - #### getError

          public double getError()

      Returns:
        the error

    - #### getExclude

          public int getExclude()

      Returns:
        the exclude

    - #### getInputCount

          public int getInputCount()

      Returns:
        the inputCount

    - #### getKernel

          public PNNKernelType getKernel()

      Returns:
        the kernel

    - #### getOutputCount

          public int getOutputCount()

      Returns:
        the outputCount

    - #### getOutputMode

          public PNNOutputMode getOutputMode()

      Returns:
        the outputMode

    - #### isTrained

          public boolean isTrained()

      Returns:
        the trained

    - #### resetConfusion

          public void resetConfusion()

      Reset the confusion.

    - #### setError

          public void setError(double error)

      Parameters:
        `error` - the error to set

    - #### setExclude

          public void setExclude(int exclude)

      Parameters:
        `exclude` - the exclude to set

    - #### setTrained

          public void setTrained(boolean trained)

      Parameters:
        `trained` - the trained to set

    - #### isSeparateClass

          public boolean isSeparateClass()

      Returns:
        the separateClass

    - #### setSeparateClass

          public void setSeparateClass(boolean separateClass)

      Parameters:
        `separateClass` - the separateClass to set

Copyright © 2014. All Rights Reserved.