Tensor<T>
Models & Types · AiDotNet.Tensors.LinearAlgebra
No summary documentation available yet.
Inheritance: TensorBase<T> → Tensor<T>
Implements: IEnumerable<T>
Known derived types: SparseTensor<T>
Constructors
| Constructor | Summary |
|---|---|
Tensor(T[] data, int[] dimensions) |
|
Tensor(int[] dimensions) |
|
Tensor(int[] dimensions, Matrix<T> matrix) |
|
Tensor(int[] dimensions, Vector<T> data) |
Properties
| Property | Summary |
|---|---|
IReadOnlyList<string> Names { get; } |
|
MemoryFormat MemoryFormat { get; set; } |
|
T Item { get; set; } |
|
T Item { get; set; } |
|
T Item { get; set; } |
|
T Item { get; set; } |
|
Tensor<T> Item { get; } |
|
Tensor<T> Item { get; } |
|
bool IsShared { get; } |
|
string SharedMemoryPath { get; } |
Methods
| Method | Summary |
|---|---|
Complex<T> GetComplex(Tensor<T> tensor, int index) |
|
IEnumerator<T> GetEnumerator() |
|
IntPtr ToDLPack(DLPackStream consumerStream) |
|
IntPtr ToDLPackLegacy(DLPackStream consumerStream) |
|
Matrix<T> ToMatrix() |
|
T DotProduct(Tensor<T> other) |
|
T GetFlatIndexValue(int flatIndex) |
|
T Mean() |
|
Tensor<T> Add(Tensor<T> other) |
|
Tensor<T> Add(Vector<T> vector) |
|
Tensor<T> AlignAs(Tensor<T> other) |
|
Tensor<T> AlignTo(string[] names) |
|
Tensor<T> BroadcastAdd(Tensor<T> other) |
|
Tensor<T> BroadcastDivide(Tensor<T> other) |
|
Tensor<T> BroadcastMultiply(Tensor<T> other) |
|
Tensor<T> BroadcastSubtract(Tensor<T> other) |
|
Tensor<T> Clone() |
|
Tensor<T> Concatenate(Tensor<T>[] tensors, int axis) |
|
Tensor<T> Contiguous() |
|
Tensor<T> Cpu() |
|
Tensor<T> CreateDefault(int[] shape, T value) |
|
Tensor<T> CreateDeferred(int[] dimensions, Action<Tensor<T>> initializer) |
|
Tensor<T> CreateIdentity(int size) |
|
Tensor<T> CreateOnes(int[] dimensions) |
|
Tensor<T> CreateRandom(Random random, int[] dimensions) |
|
Tensor<T> CreateRandom(int[] dimensions) |
|
Tensor<T> CreateZeros(int[] dimensions) |
|
Tensor<T> Divide(T scalar) |
|
Tensor<T> ElementwiseMultiply(Tensor<T> a, Tensor<T> b) |
|
Tensor<T> ElementwiseMultiply(Tensor<T> other) |
|
Tensor<T> ElementwiseSubtract(Tensor<T> other) |
|
Tensor<T> Empty() |
|
Tensor<T> ExpandDims(int axis) |
|
Tensor<T> ExpandTo(int[] targetShape) |
|
Tensor<T> FromColumnMatrix(Matrix<T> matrix) |
|
Tensor<T> FromDLPack(IntPtr managedTensorVersioned) |
|
Tensor<T> FromDLPackLegacy(IntPtr managedTensor) |
|
Tensor<T> FromMatrix(Matrix<T> matrix) |
|
Tensor<T> FromMemory(Memory<T> memory, int[] dimensions) |
|
Tensor<T> FromRowMatrix(Matrix<T> matrix) |
|
Tensor<T> FromScalar(T value) |
|
Tensor<T> FromSharedMemory(string path, int[] shape) |
|
Tensor<T> FromVector(Vector<T> vector) |
|
Tensor<T> FromVector(Vector<T> vector, int[] shape) |
|
Tensor<T> GetSlice(int batchIndex) |
|
Tensor<T> GetSliceAlongDimension(int index, int dimension) |
|
Tensor<T> GetSubTensor(int batch, int channel, int startHeight, int startWidth, int height, int width) |
|
Tensor<T> Gpu() |
|
Tensor<T> InsertAxis(int position) |
|
Tensor<T> MatrixMultiply(Tensor<T> other) |
|
Tensor<T> MaxOverAxis(int axis) |
|
Tensor<T> MeanOverAxis(int axis) |
|
Tensor<T> Multiply(Matrix<T> matrix) |
|
Tensor<T> Multiply(T scalar) |
|
Tensor<T> Multiply(Tensor<T> other) |
|
Tensor<T> PointwiseMultiply(Tensor<T> other) |
|
Tensor<T> PreserveLayoutFrom(Tensor<T> source) |
|
Tensor<T> RefineNames(string[] names) |
|
Tensor<T> Rename(IReadOnlyDictionary<string, string> mapping) |
|
Tensor<T> Rename(string[] names) |
|
Tensor<T> RenameInPlace(IReadOnlyDictionary<string, string> mapping) |
|
Tensor<T> RenameInPlace(string[] names) |
|
Tensor<T> Reshape(int[] newShape) |
|
Tensor<T> Scale(T factor) |
|
Tensor<T> SelectAlong(int axis, int index) |
|
Tensor<T> ShareMemory() |
|
Tensor<T> Slice(int axis, int start, int? end) |
|
Tensor<T> Slice(int index) |
|
Tensor<T> Slice(int startRow, int startCol, int endRow, int endCol) |
|
Tensor<T> Squeeze() |
|
Tensor<T> Squeeze(int axis) |
|
Tensor<T> Stack(Tensor<T>[] tensors, int axis) |
|
Tensor<T> SubTensor(int[] indices) |
|
Tensor<T> Subtract(Tensor<T> other) |
|
Tensor<T> Sum(int[] axes) |
|
Tensor<T> SumOverAxis(int axis) |
|
Tensor<T> To(DeviceInfo deviceInfo) |
|
Tensor<T> To(TensorDevice device) |
|
Tensor<T> To(string deviceString) |
|
Tensor<T> Transform(Func<T, int, T> transformer) |
|
Tensor<T> Transpose() |
|
Tensor<T> Transpose(int[] permutation) |
|
Tensor<T> TransposeLast2D() |
|
Tensor<T> Unsqueeze(int axis) |
|
Tensor<T> op_Addition(Tensor<T> left, Tensor<T> right) |
|
Tensor<T> op_Multiply(Tensor<T> left, Tensor<T> right) |
|
Tensor<T>[] AlignTensors(Tensor<T>[] tensors) |
|
Tensor<TOut> Cast() |
|
TensorBase<T> CloneShared() |
|
ValueTuple<T, int> Max() |
|
Vector<T> AsVector() |
|
Vector<T> GetRow(int rowIndex) |
|
Vector<T> GetSlice(int start, int length) |
|
Vector<T> GetVector(int index) |
|
Vector<T> GetVectorAlongAxis(int axis, int[] fixedIndices) |
|
Vector<T> ToVector() |
|
bool HasNames() |
|
int NormalizeAxis(int axis, int rank) |
|
void AddInPlace(Tensor<T> other) |
|
void CopyTo(Memory<T> destination) |
|
void CopyTo(Span<T> destination) |
|
void DivideInPlace(T scalar) |
|
void Fill(T value) |
|
void MultiplyInPlace(T scalar) |
|
void SetFlatIndex(int flatIndex, T value) |
|
void SetFlatIndexValue(int flatIndex, T value) |
|
void SetRow(int rowIndex, Vector<T> vector) |
|
void SetSlice(int dimension, int index, Tensor<T> slice) |
|
void SetSlice(int index, Tensor<T> slice) |
|
void SetSlice(int start, Vector<T> slice) |
|
void SetSubTensor(int[] indices, Tensor<T> subTensor) |
|
void SetVectorAlongAxis(Vector<T> values, int axis, int[] fixedIndices) |
|
void SubtractInPlace(Tensor<T> other) |