|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.encog.mathutil.randomize.BasicRandomizer
org.encog.mathutil.randomize.FanInRandomizer
public class FanInRandomizer
A randomizer that attempts to create starting weight values that are conducive to propagation training. This is one of the best randomizers offered in Encog, however, the Nguyen Widrow method generally performs better. From: Neural Networks - A Comprehensive Foundation, Haykin, chapter 6.7
Constructor Summary | |
---|---|
FanInRandomizer()
Create a fan-in randomizer with default values. |
|
FanInRandomizer(double boundary,
boolean sqrt)
Construct a fan-in randomizer along the specified boundary. |
|
FanInRandomizer(double aLowerBound,
double anUpperBound,
boolean sqrt)
Construct a fan-in randomizer. |
Method Summary | |
---|---|
void |
randomize(BasicNetwork network,
int fromLayer)
Randomize one level of a neural network. |
double |
randomize(double d)
Starting with the specified number, randomize it to the degree specified by this randomizer. |
void |
randomize(double[] d)
Randomize the array based on an array, modify the array. |
void |
randomize(double[][] d)
Randomize the 2d array based on an array, modify the array. |
void |
randomize(Matrix m)
Randomize the matrix based on an array, modify the array. |
Methods inherited from class org.encog.mathutil.randomize.BasicRandomizer |
---|
getRandom, nextDouble, nextDouble, randomize, randomize, setRandom, setSeed |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FanInRandomizer()
public FanInRandomizer(double boundary, boolean sqrt)
boundary
- The boundary for the fan-in.sqrt
- Should the square root of the rows to be used in the
calculation.public FanInRandomizer(double aLowerBound, double anUpperBound, boolean sqrt)
aLowerBound
- The lower bound.anUpperBound
- The upper bound.sqrt
- True if the square root of the rows should be used in the
calculation.Method Detail |
---|
public double randomize(double d)
d
- The number to randomize.
public void randomize(double[] d)
randomize
in interface Randomizer
randomize
in class BasicRandomizer
d
- An array to randomize.public void randomize(double[][] d)
randomize
in interface Randomizer
randomize
in class BasicRandomizer
d
- An array to randomize.public void randomize(Matrix m)
randomize
in interface Randomizer
randomize
in class BasicRandomizer
m
- A matrix to randomize.public void randomize(BasicNetwork network, int fromLayer)
randomize
in class BasicRandomizer
network
- The network to randomizefromLayer
- The from level to randomize.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |