Method diagAxis
static member diagAxis: int -> int -> Tensor<'T> -> Tensor<'T>
Returns a view of the diagonal along the given axes.
Declaration
static member diagAxis: ax1:int -> ax2:int -> a:Tensor<'T> -> Tensor<'T>Parameters
| Type | Name | Description | 
|---|---|---|
| int | ax1 | The first dimension of the diagonal. | 
| int | ax2 | The seconds dimension of the diagonal. | 
| Tensor<'T> | a | The tensor to operate on. | 
Returns
| Type | Description | 
|---|---|
| Tensor<'T> | A tensor where dimension  | 
Remarks
The dimensions specified by ax1 and ax2 must have the same size.
A view of the original tensor is returned and the storage is shared. Modifications done to the returned tensor will affect the original tensor.
Examples
 let a = HostTensor.zeros [4L; 3L; 3L; 5L]
 let b = Tensor.diagAxis 1 2 a // b.Shape = [4L; 3L; 5L]