morphoclass.layers.running_std module¶
Layer for normalization by the standard deviation.
-
class
morphoclass.layers.running_std.RunningStd(*shape, eps=1e-05)¶ Bases:
torch.nn.modules.module.ModuleLayer for normalization by the standard deviation.
This layer keeps track of the (biased) standard deviation of streaming data at training time. The data is normalized using this standard deviation both at training and at inference time.
- Parameters
shape (int) – The shape of the input tensor.
eps (float, optional) – A value added to the standard deviation for numerical stability.
-
training: bool¶