Rate this Page
★ ★ ★ ★ ★

torch.Tensor.uniform_#

Tensor.uniform_(from=0, to=1, *, generator=None) → Tensor#

Fills self tensor with numbers sampled from the continuous uniform distribution:

f(x)=1to−fromf(x) = \dfrac{1}{\text{to} - \text{from}}