torch_diag {torch}R Documentation

Diag

Description

Diag

Usage

torch_diag(self, diagonal = 0L)

Arguments

self

(Tensor) the input tensor.

diagonal

(int, optional) the diagonal to consider

diag(input, diagonal=0, out=NULL) -> Tensor

The argument diagonal controls which diagonal to consider:


[Package torch version 0.13.0 Index]