torch_deg2rad: Deg2rad

Description Usage Arguments deg2rad(input, *, out=None) -> Tensor Examples

View source: R/gen-namespace.R

Description

Deg2rad

Usage

1

Arguments

self

(Tensor) the input tensor.

deg2rad(input, *, out=None) -> Tensor

Returns a new tensor with each of the elements of input converted from angles in degrees to radians.

Examples

1
2
3
4
5
if (torch_is_installed()) {

a <- torch_tensor(rbind(c(180.0, -180.0), c(360.0, -360.0), c(90.0, -90.0)))
torch_deg2rad(a)
}

torch documentation built on Oct. 7, 2021, 9:22 a.m.