Keras layers


KerasBatchNormalization

[source]

Imports a BatchNormalization layer from Keras.

KerasBatchNormalization
  1. public KerasBatchNormalization(Integer kerasVersion) throws UnsupportedKerasConfigurationException

Pass-through constructor from KerasLayer

  • param kerasVersion major keras version
  • throws UnsupportedKerasConfigurationException Unsupported Keras config
getBatchNormalizationLayer
  1. public BatchNormalization getBatchNormalizationLayer()

Constructor from parsed Keras layer configuration dictionary.

  • param layerConfig dictionary containing Keras layer configuration
  • throws InvalidKerasConfigurationException Invalid Keras config
  • throws UnsupportedKerasConfigurationException Unsupported Keras config
getOutputType
  1. public InputType getOutputType(InputType... inputType) throws InvalidKerasConfigurationException

Get layer output type.

  • param inputType Array of InputTypes
  • return output type as InputType
  • throws InvalidKerasConfigurationException Invalid Keras config
getNumParams
  1. public int getNumParams()

Returns number of trainable parameters in layer.

  • return number of trainable parameters (4)
setWeights
  1. public void setWeights(Map<String, INDArray> weights) throws InvalidKerasConfigurationException

Set weights for layer.

  • param weights Map from parameter name to INDArray.