public static final class MlpNet.Builder extends Object implements NeuralNetBuilder<MlpNet>
setInputSize(int) add* methods build method UniformInitializer class.| Constructor and Description |
|---|
MlpNet.Builder()
Creates a new instance of the builder.
|
| Modifier and Type | Method and Description |
|---|---|
MlpNet.Builder |
addCustom(int size,
Function activationFun)
Adds a layer with specified size and activation function.
|
MlpNet.Builder |
addLinear(int size)
Adds a layer with specified size and identity function as the
activation function.
|
MlpNet.Builder |
addSigmoid(int size)
Adds a layer with specified size and sigmoid function as the
activation function.
|
MlpNet.Builder |
addStep(int size)
Adds a layer with specified size and Heaviside step function as the
activation function.
|
MlpNet.Builder |
addTanh(int size)
Adds a layer with specified size and hyperbolic tangent as the
activation function.
|
MlpNet |
build()
Returns a new multilayer perceptron.
|
MlpNet.Builder |
setInputSize(int size)
Sets the number of inputs for a network.
|
public MlpNet.Builder setInputSize(int size)
size - the number of inputs. Must be greater than zero.public MlpNet.Builder addCustom(int size, Function activationFun)
size - the layer's size. Must be greater than zero.activationFun - the activation function. Cannot be null.public MlpNet.Builder addTanh(int size)
size - the layer's size. Must be greater than zero.public MlpNet.Builder addSigmoid(int size)
size - the layer's size. Must be greater than zero.public MlpNet.Builder addLinear(int size)
size - the layer's size. Must be greater than zero.public MlpNet.Builder addStep(int size)
size - the layer's size. Must be greater than zero.public MlpNet build()
build in interface NeuralNetBuilder<MlpNet>Copyright © 2012. All Rights Reserved.