torch.DiagonalOptions
export interface DiagonalOptions {
/** Diagonal offset (default: 0) */
offset?: number;
/** First dimension with respect to which to take diagonal (default: -2) */
dim1?: number;
/** Second dimension with respect to which to take diagonal (default: -1) */
dim2?: number;
/** Alias for offset, used by diag() to match PyTorch positional argument name */
diagonal?: number;
}offset(number)optional- – Diagonal offset (default: 0)
dim1(number)optional- – First dimension with respect to which to take diagonal (default: -2)
dim2(number)optional- – Second dimension with respect to which to take diagonal (default: -1)
diagonal(number)optional- – Alias for offset, used by diag() to match PyTorch positional argument name
Options for diagonal extraction operations (diagonal, diag) - with dimension support