InstanceNorm#
- class brainpy.dnn.InstanceNorm(num_channels, epsilon=1e-05, affine=True, bias_initializer=ZeroInit, scale_initializer=OneInit(value=1.0), mode=None, name=None)[source]#
Instance normalization layer.
This layer normalizes the data within each feature. It can be regarded as a group normalization layer in which group_size equals to 1.
- Parameters:
num_channels (int) – The number of channels expected in input.
epsilon (float) – a value added to the denominator for numerical stability. Default: 1e-5
affine (bool) – A boolean value that when set to
True
, this module has learnable per-channel affine parameters initialized to ones (for weights) and zeros (for biases). Default:True
.bias_initializer (Initializer, ArrayType, Callable) – an initializer generating the original translation matrix
scale_initializer (Initializer, ArrayType, Callable) – an initializer generating the original scaling matrix