blob: 9b0752ff7fdf26a9e9f15211121860d409d8367f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
### `tf.contrib.layers.unit_norm(*args, **kwargs)` {#unit_norm}
Normalizes the given input across the specified dimension to unit length.
Note that the rank of `input` must be known.
##### Args:
* <b>`inputs`</b>: A `Tensor` of arbitrary size.
* <b>`dim`</b>: The dimension along which the input is normalized.
* <b>`epsilon`</b>: A small value to add to the inputs to avoid dividing by zero.
* <b>`scope`</b>: Optional scope for variable_scope.
##### Returns:
The normalized `Tensor`.
##### Raises:
* <b>`ValueError`</b>: If dim is smaller than the number of dimensions in 'inputs'.
|