[−][src]Trait opencv::hub_prelude::NormalizeBBoxLayerTrait
- normalization layer.
Parameters
- p: Normalization factor. The most common
p = 1
for - normalization orp = 2
for - normalization or a custom one. - eps: Parameter to prevent a division by zero.
- across_spatial: If true, normalize an input across all non-batch dimensions. Otherwise normalize an every channel separately.
Across spatial: @f[ norm = \sqrt[p]{\epsilon + \sum_{x, y, c} |src(x, y, c)|^p } \ dst(x, y, c) = \frac{ src(x, y, c) }{norm} @f]
Channel wise normalization: @f[ norm(c) = \sqrt[p]{\epsilon + \sum_{x, y} |src(x, y, c)|^p } \ dst(x, y, c) = \frac{ src(x, y, c) }{norm(c)} @f]
Where x, y
- spatial coordinates, c
- channel.
An every sample in the batch is normalized separately. Optionally, output is scaled by the trained parameters.