public class NeuralNetConfiguration
extends java.lang.Object
implements java.io.Serializable, java.lang.Cloneable
Modifier and Type | Class and Description |
---|---|
static class |
NeuralNetConfiguration.Builder |
static class |
NeuralNetConfiguration.ListBuilder
Fluent interface for building a list of configurations
|
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CUSTOM_FUNCTIONALITY
System property for custom layers, preprocessors, graph vertices etc.
|
protected int |
iterationCount |
protected java.util.Map<java.lang.String,java.lang.Double> |
l1ByParam |
protected java.util.Map<java.lang.String,java.lang.Double> |
l2ByParam |
protected Layer |
layer |
protected double |
leakyreluAlpha
Deprecated.
|
protected java.util.Map<java.lang.String,java.lang.Double> |
learningRateByParam |
protected LearningRatePolicy |
learningRatePolicy |
protected double |
lrPolicyDecayRate |
protected double |
lrPolicyPower |
protected double |
lrPolicySteps |
protected int |
maxNumLineSearchIterations |
protected boolean |
miniBatch |
protected boolean |
minimize |
protected int |
numIterations |
protected OptimizationAlgorithm |
optimizationAlgo |
protected boolean |
pretrain |
protected long |
seed |
protected StepFunction |
stepFunction |
protected boolean |
useDropConnect |
protected boolean |
useRegularization |
protected java.util.List<java.lang.String> |
variables |
Constructor and Description |
---|
NeuralNetConfiguration() |
Modifier and Type | Method and Description |
---|---|
void |
addVariable(java.lang.String variable) |
void |
clearVariables() |
NeuralNetConfiguration |
clone()
Creates and returns a deep copy of the configuration.
|
static NeuralNetConfiguration |
fromJson(java.lang.String json)
Create a neural net configuration from json
|
static NeuralNetConfiguration |
fromYaml(java.lang.String json)
Create a neural net configuration from json
|
double |
getL1ByParam(java.lang.String variable) |
double |
getL2ByParam(java.lang.String variable) |
double |
getLearningRateByParam(java.lang.String variable) |
static org.nd4j.shade.jackson.databind.ObjectMapper |
mapper()
Object mapper for serialization of configurations
|
static org.nd4j.shade.jackson.databind.ObjectMapper |
mapperYaml()
Object mapper for serialization of configurations
|
static org.nd4j.shade.jackson.databind.ObjectMapper |
reinitMapperWithSubtypes(java.util.Collection<org.nd4j.shade.jackson.databind.jsontype.NamedType> additionalTypes)
Reinitialize and return the Jackson/json ObjectMapper with additional named types.
|
void |
setLayerParamLR(java.lang.String variable) |
void |
setLearningRateByParam(java.lang.String variable,
double rate) |
java.lang.String |
toJson()
Return this configuration as json
|
java.lang.String |
toYaml()
Return this configuration as json
|
java.util.List<java.lang.String> |
variables() |
java.util.List<java.lang.String> |
variables(boolean copy) |
public static final java.lang.String CUSTOM_FUNCTIONALITY
protected Layer layer
@Deprecated protected double leakyreluAlpha
protected boolean miniBatch
protected int numIterations
protected int maxNumLineSearchIterations
protected long seed
protected OptimizationAlgorithm optimizationAlgo
protected java.util.List<java.lang.String> variables
protected StepFunction stepFunction
protected boolean useRegularization
protected boolean useDropConnect
protected boolean minimize
protected java.util.Map<java.lang.String,java.lang.Double> learningRateByParam
protected java.util.Map<java.lang.String,java.lang.Double> l1ByParam
protected java.util.Map<java.lang.String,java.lang.Double> l2ByParam
protected LearningRatePolicy learningRatePolicy
protected double lrPolicyDecayRate
protected double lrPolicySteps
protected double lrPolicyPower
protected boolean pretrain
protected int iterationCount
public NeuralNetConfiguration clone()
clone
in class java.lang.Object
public java.util.List<java.lang.String> variables()
public java.util.List<java.lang.String> variables(boolean copy)
public void addVariable(java.lang.String variable)
public void clearVariables()
public void setLayerParamLR(java.lang.String variable)
public double getLearningRateByParam(java.lang.String variable)
public void setLearningRateByParam(java.lang.String variable, double rate)
public double getL1ByParam(java.lang.String variable)
public double getL2ByParam(java.lang.String variable)
public java.lang.String toYaml()
public static NeuralNetConfiguration fromYaml(java.lang.String json)
json
- the neural net configuration from jsonpublic java.lang.String toJson()
public static NeuralNetConfiguration fromJson(java.lang.String json)
json
- the neural net configuration from jsonpublic static org.nd4j.shade.jackson.databind.ObjectMapper mapperYaml()
public static org.nd4j.shade.jackson.databind.ObjectMapper mapper()
public static org.nd4j.shade.jackson.databind.ObjectMapper reinitMapperWithSubtypes(java.util.Collection<org.nd4j.shade.jackson.databind.jsontype.NamedType> additionalTypes)