| Modifier and Type | Field and Description |
|---|---|
protected KerasLayerConfiguration |
KerasLayer.conf |
| Modifier and Type | Class and Description |
|---|---|
class |
Keras1LayerConfiguration
All relevant property fields of keras 1.x layers.
|
class |
Keras2LayerConfiguration
All relevant property fields of keras 2.x layers.
|
| Modifier and Type | Method and Description |
|---|---|
static KerasLayerConfiguration |
KerasLayerConfigurationFactory.get(Integer kerasMajorVersion) |
| Modifier and Type | Method and Description |
|---|---|
static ConvolutionMode |
KerasConvolutionUtils.getConvolutionModeFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf)
Get convolution border mode from Keras layer configuration.
|
static CNN2DFormat |
KerasConvolutionUtils.getDataFormatFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration layerConfiguration)
Return the
CNN2DFormat
from the configuration . |
static int[] |
KerasConvolutionUtils.getDilationRate(Map<String,Object> layerConfig,
int dimension,
KerasLayerConfiguration conf,
boolean forceDilation)
Get atrous / dilation rate from config
|
static int[] |
KerasConvolutionUtils.getKernelSizeFromConfig(Map<String,Object> layerConfig,
int dimension,
KerasLayerConfiguration conf,
int kerasMajorVersion)
Get (convolution) kernel size from Keras layer configuration.
|
static int[] |
KerasConvolutionUtils.getPaddingFromBorderModeConfig(Map<String,Object> layerConfig,
int dimension,
KerasLayerConfiguration conf,
int kerasMajorVersion)
Get (convolution) padding from Keras layer configuration.
|
static int[] |
KerasConvolutionUtils.getStrideFromConfig(Map<String,Object> layerConfig,
int dimension,
KerasLayerConfiguration conf)
Get (convolution) stride from Keras layer configuration.
|
| Modifier and Type | Method and Description |
|---|---|
static int[] |
KerasPoolingUtils.mapGlobalPoolingDimensions(String className,
KerasLayerConfiguration conf,
KerasLayer.DimOrder dimOrder)
Map Keras pooling layers to DL4J pooling dimensions.
|
static PoolingType |
KerasPoolingUtils.mapPoolingType(String className,
KerasLayerConfiguration conf)
Map Keras pooling layers to DL4J pooling types.
|
| Modifier and Type | Method and Description |
|---|---|
static double |
KerasRnnUtils.getRecurrentDropout(KerasLayerConfiguration conf,
Map<String,Object> layerConfig)
Get recurrent weight dropout from Keras layer configuration.
|
static boolean |
KerasRnnUtils.getUnrollRecurrentLayer(KerasLayerConfiguration conf,
Map<String,Object> layerConfig)
Get unroll parameter to decide whether to unroll RNN with BPTT or not.
|
| Modifier and Type | Method and Description |
|---|---|
static void |
KerasLayerUtils.checkForUnsupportedConfigurations(Map<String,Object> layerConfig,
boolean enforceTrainingConfig,
KerasLayerConfiguration conf)
Checks whether layer config contains unsupported options.
|
static Activation |
KerasActivationUtils.getActivationFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf)
Get activation enum value from Keras layer configuration.
|
static double |
KerasLayerUtils.getBiasL1RegularizationFromConfig(Map<String,Object> layerConfig,
boolean enforceTrainingConfig,
KerasLayerConfiguration conf)
Get L1 bias regularization (if any) from Keras bias regularization configuration.
|
static String |
KerasLayerUtils.getClassNameFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf)
Get Keras layer class name from Keras layer configuration.
|
static LayerConstraint |
KerasConstraintUtils.getConstraintsFromConfig(Map<String,Object> layerConfig,
String constraintField,
KerasLayerConfiguration conf,
int kerasMajorVersion)
Get constraint initialization from Keras layer configuration.
|
static KerasLayer.DimOrder |
KerasLayerUtils.getDimOrderFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf)
Get Keras (backend) dimension order from Keras layer configuration.
|
static double |
KerasLayerUtils.getDropoutFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf)
Get dropout from Keras layer configuration.
|
static boolean |
KerasLayerUtils.getHasBiasFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf)
Determine if layer should be instantiated with bias
|
static IActivation |
KerasActivationUtils.getIActivationFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf)
Get activation function from Keras layer configuration.
|
static List<String> |
KerasLayerUtils.getInboundLayerNamesFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf)
Get list of inbound layers from Keras layer configuration.
|
static Map<String,Object> |
KerasLayerUtils.getInnerLayerConfigFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf)
Get inner layer config from Keras layer configuration.
|
static int[] |
KerasLayerUtils.getInputShapeFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf)
Get Keras input shape from Keras layer configuration.
|
static KerasLayer |
KerasLayerUtils.getKerasLayerFromConfig(Map<String,Object> layerConfig,
boolean enforceTrainingConfig,
KerasLayerConfiguration conf,
Map<String,Class<? extends KerasLayer>> customLayers,
Map<String,SameDiffLambdaLayer> lambdaLayers,
Map<String,? extends KerasLayer> previousLayers)
Build KerasLayer from a Keras layer configuration.
|
static KerasLayer |
KerasLayerUtils.getKerasLayerFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf,
Map<String,Class<? extends KerasLayer>> customLayers,
Map<String,SameDiffLambdaLayer> lambdaLayers,
Map<String,? extends KerasLayer> previousLayers)
Build KerasLayer from a Keras layer configuration.
|
static String |
KerasLayerUtils.getLayerNameFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf)
Get layer name from Keras layer configuration.
|
static double |
KerasLayerUtils.getMaskingValueFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf)
Get mask value
|
static Integer |
KerasLayerUtils.getNInFromInputDim(Map<String,Object> layerConfig,
KerasLayerConfiguration conf) |
static int |
KerasLayerUtils.getNOutFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf)
Get number of outputs from Keras layer configuration.
|
static List<String> |
KerasLayerUtils.getOutboundLayerNamesFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf)
Get list of inbound layers from Keras layer configuration.
|
static Map<String,Object> |
KerasLayerUtils.getTimeDistributedLayerConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf)
Extract inner layer config from TimeDistributed configuration and merge
it into the outer config.
|
static IWeightInit |
KerasInitilizationUtils.getWeightInitFromConfig(Map<String,Object> layerConfig,
String initField,
boolean enforceTrainingConfig,
KerasLayerConfiguration conf,
int kerasMajorVersion)
Get weight initialization from Keras layer configuration.
|
static double |
KerasRegularizerUtils.getWeightRegularizerFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf,
String configField,
String regularizerType)
Get weight regularization from Keras weight regularization configuration.
|
static boolean |
KerasLayerUtils.getZeroMaskingFromConfig(Map<String,Object> layerConfig,
KerasLayerConfiguration conf)
Get zero masking flag
|
static LayerConstraint |
KerasConstraintUtils.mapConstraint(String kerasConstraint,
KerasLayerConfiguration conf,
Map<String,Object> constraintConfig)
Map Keras to DL4J constraint.
|
static ILossFunction |
KerasLossUtils.mapLossFunction(String kerasLoss,
KerasLayerConfiguration conf)
Map Keras to DL4J loss functions.
|
static Activation |
KerasActivationUtils.mapToActivation(String kerasActivation,
KerasLayerConfiguration conf)
Map Keras to DL4J activation functions.
|
static IActivation |
KerasActivationUtils.mapToIActivation(String kerasActivation,
KerasLayerConfiguration conf)
Map Keras to DL4J activation functions.
|
static IWeightInit |
KerasInitilizationUtils.mapWeightInitialization(String kerasInit,
KerasLayerConfiguration conf,
Map<String,Object> initConfig,
int kerasMajorVersion)
Map Keras to DL4J weight initialization functions.
|
static void |
KerasLayerUtils.removeDefaultWeights(Map<String,INDArray> weights,
KerasLayerConfiguration conf)
Remove weights from config after weight setting.
|
Copyright © 2021. All rights reserved.