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.joone.engine.weights
Class RandomWeightInitializer

    java.lang.Object
      org.joone.engine.weights.RandomWeightInitializer

All Implemented Interfaces:
  java.io.Serializable, WeightInitializer

    public class RandomWeightInitializer

extends java.lang.Object
implements WeightInitializer

This class initializes weights (and biases) in a random way within a given domain.

Author:
  Boris Jansen
See Also:
  Serialized Form

Constructor Summary
`RandomWeightInitializer(double aBoundary)` Creates a new instance of RandomWeightInitializer
`RandomWeightInitializer(double aLowerBound, double anUpperBound)` Creates a new instance of RandomWeightInitializer and set the domain to initialize the weights with to `[aLowerBound, anUpperBound]`.

Method Summary
`double` | `getLowerBound()` Gets the lower bound.
`double` | `getUpperBound()` Gets the upper bound.
`void` | `initialize(Matrix aMatrix)` Initializes the weights or biases within the domain `[lowerBound, upperBound]`.
`void` | `setLowerBound(double aLowerBound)` Sets the lower bound.
`void` | `setUpperBound(double anUpperBound)` Sets the upper bound.

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

Constructor Detail

### RandomWeightInitializer

    public RandomWeightInitializer(double aBoundary)

  Creates a new instance of RandomWeightInitializer

  Parameters:
    `aBoundary` - the boundaries of the domain to initialize the weights with to `[-aBoundary, aBoundary]`.

### RandomWeightInitializer

    public RandomWeightInitializer(double aLowerBound,
                                   double anUpperBound)

  Creates a new instance of RandomWeightInitializer and set the domain to initialize the weights with to `[aLowerBound, anUpperBound]`.

  Parameters:
    `aLowerBound` - the lower boundary of the domain to initialize the weights with.
    `anUpperBound` - the upper boundary of the domain to initialize the weights with. to `[-aBoundary, aBoundary]`.

Method Detail

### initialize

    public void initialize(Matrix aMatrix)

  Initializes the weights or biases within the domain `[lowerBound, upperBound]`.

  Specified by:
    `initialize` in interface `WeightInitializer`
  Parameters:
    `aMatrix` - the weights or biases to initialize.

### getLowerBound

    public double getLowerBound()

  Gets the lower bound.

  Returns:
    the lower bound.

### setLowerBound

    public void setLowerBound(double aLowerBound)

  Sets the lower bound.

  Parameters:
    `aLowerBound` - the new lower bound.

### getUpperBound

    public double getUpperBound()

  Gets the upper bound.

  Returns:
    the upper bound.

### setUpperBound

    public void setUpperBound(double anUpperBound)

  Sets the upper bound.

  Parameters:
    `anUpperBound` - the new upper bound.

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

Submit Feedback to pmarrone@users.sourceforge.net