jsat.classifiers.neuralnetwork.initializers
Class GaussianNormalInit
- java.lang.Object
-
- jsat.classifiers.neuralnetwork.initializers.GaussianNormalInit
-
- All Implemented Interfaces:
- java.io.Serializable, BiastInitializer, WeightInitializer
public class GaussianNormalInit extends java.lang.Object implements WeightInitializer, BiastInitializer
This object initializes the values of weights by sampling from the zero mean Gaussian- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor and Description GaussianNormalInit(double stndDev)Creates a new GuassianNormalInit object for initializing weights
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description GaussianNormalInitclone()doublegetStndDev()voidinit(Matrix w, java.util.Random rand)Initializes the values of the given weight matrixvoidinit(Vec b, int fanIn, java.util.Random rand)Performs the initialization of the given vector of bias valuesvoidsetStndDev(double stndDev)Sets the standard deviation of the distribution that will be sampled from
-
-
-
Constructor Detail
-
GaussianNormalInit
public GaussianNormalInit(double stndDev)
Creates a new GuassianNormalInit object for initializing weights- Parameters:
stndDev- the standard deviation of the distribution to sample from
-
-
Method Detail
-
setStndDev
public void setStndDev(double stndDev)
Sets the standard deviation of the distribution that will be sampled from- Parameters:
stndDev- the standard deviation to use
-
getStndDev
public double getStndDev()
- Returns:
- the standard deviation of the Gaussian that is sampled from
-
init
public void init(Matrix w, java.util.Random rand)
Description copied from interface:WeightInitializerInitializes the values of the given weight matrix- Specified by:
initin interfaceWeightInitializer- Parameters:
w- the matrix to initializerand- the source of randomness for the initialization
-
init
public void init(Vec b, int fanIn, java.util.Random rand)
Description copied from interface:BiastInitializerPerforms the initialization of the given vector of bias values- Specified by:
initin interfaceBiastInitializer- Parameters:
b- the vector to store the biases infanIn- the number of connections coming into the layer that these biases are for.rand- the source of randomness for initialization
-
clone
public GaussianNormalInit clone()
- Specified by:
clonein interfaceBiastInitializer- Specified by:
clonein interfaceWeightInitializer- Overrides:
clonein classjava.lang.Object
-
-
DataMelt 3.0 © DataMelt by jWork.ORG