Category: Normalization
Short description: Calculates mean-variance normalization of the input tensor.
Detailed description
MVN subtracts mean value from the input blob:
\[ o_{i} = i_{i} - ReduceMean(i_{k}, axes) \]
If normalize_variance is set to true
, the output blob is divided by variance. When normalizing the value, the number eps
is added to the variance to avoid division by zero. According to the eps_mode
flag's value, eps
is added inside or outside the sqrt:
eps_mode
is inside_sqrt
: \[ o_{i}=\frac{o_{i}}{\sqrt {\sum {o_{k}^2}+\epsilon}} \]
eps_mode
is outside_sqrt
: \[ o_{i}=\frac{o_{i}}{\sqrt {\sum {o_{k}^2}}+\epsilon} \]
Attributes
false
– Do not normalize variancetrue
– Normalize varianceboolean
float
inside_sqrt
– Add epsilon inside sqrtoutside_sqrt
– Add epsilon outside of sqrtstring
Inputs
data
- Input tensor to be normalized. Type T. Required.axes
- 1D tensor which specifies indices of dimensions in data
that define normalization slices. Allowed range of axes is [-r; r-1]
where r = rank(data)
, the order can be not sorted. Negative value means counting dimensions from the back. Type T_IND. Required.Outputs
data
input tensor.Types
int64
or int32
.Example