A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://pytorch.org/docs/stable/generated/torch.nn.functional.normalize.html below:

torch.nn.functional.normalize — PyTorch 2.8 documentation

Perform L p L_p Lp normalization of inputs over specified dimension.

For a tensor input of sizes ( n 0 , . . . , n d i m , . . . , n k ) (n_0, ..., n_{dim}, ..., n_k) (n0,...,ndim,...,nk), each n d i m n_{dim} ndim -element vector v v v along dimension dim is transformed as

v = v max ⁡ ( ∥ v ∥ p , ϵ ) . v = \frac{v}{\max(\lVert v \rVert_p, \epsilon)}. v=max(∥vp,ϵ)v.

With the default arguments it uses the Euclidean norm over vectors along dimension 1 1 1 for normalization.

Parameters
Return type

Tensor


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4