Deep.Net


ArrayNDManikin

Namespace: SymTensor.Compiler

Functions and values

Function or valueDescription
addrInBytes idx ary
Signature: idx:int64 list -> ary:ArrayNDManikinT -> int64

address of given element in bytes (relative to start of array)

broadcastTo shp a
Signature: shp:int64 list -> a:ArrayNDManikinT -> ArrayNDManikinT

broadcasts the tensor to the given shape

canBeBlasTarget ary
Signature: ary:ArrayNDManikinT -> bool

True if array can be target of BLAS operation.

canReshapeView shp a
Signature: shp:int64 list -> a:ArrayNDManikinT -> bool

Returns true if the tensor can be reshaped without copying.

cppType a
Signature: a:ArrayNDManikinT -> string

C++ type string

cutLeft a
Signature: a:ArrayNDManikinT -> ArrayNDManikinT

removes the first dimension from the tensor

cutRight a
Signature: a:ArrayNDManikinT -> ArrayNDManikinT

removes the last dimension from the tensor

diagAxis ax1 ax2 a
Signature: ax1:int -> ax2:int -> a:ArrayNDManikinT -> ArrayNDManikinT

Returns a view of the diagonal along the given axes. The diagonal replaces the first axis and the second axis is removed.

external storage shape stride
Signature: storage:MemManikinT -> shape:int64 list -> stride:int64 list -> ArrayNDManikinT

creates a new ArrayNDManikinT with specified strides and using the specified storage

externalC storage shape
Signature: storage:MemManikinT -> shape:int64 list -> ArrayNDManikinT

creates a new ArrayNDManikinT with contiguous layout using the specified storage

insertAxis ax a
Signature: ax:int -> a:ArrayNDManikinT -> ArrayNDManikinT

Inserts an axis of size 1 before the specified position.

isBroadcasted a
Signature: a:ArrayNDManikinT -> bool

returns true if at least one dimension is broadcasted

isC ary
Signature: ary:ArrayNDManikinT -> bool
isF ary
Signature: ary:ArrayNDManikinT -> bool
layout ary
Signature: ary:ArrayNDManikinT -> TensorLayout
maybeOverlapping a b
Signature: a:ArrayNDManikinT -> b:ArrayNDManikinT -> bool

true if a and b may overlap

nDims ary
Signature: ary:ArrayNDManikinT -> int
nElems ary
Signature: ary:ArrayNDManikinT -> int64
newBlasTarget memAllocator typ shape
Signature: memAllocator:('?177455 -> int64 -> MemAllocKindT -> MemManikinT) -> typ:'?177455 -> shape:int64 list -> ArrayNDManikinT
Type parameters: '?177455

create a new MemoryManikinT and a new ArrayNDManikinT with layout suitable for being a BLAS target

newC memAllocator typ shape
Signature: memAllocator:('?177449 -> int64 -> MemAllocKindT -> MemManikinT) -> typ:'?177449 -> shape:int64 list -> ArrayNDManikinT
Type parameters: '?177449

creates a new MemoryManikinT and a new ArrayNDManikinT with C-order

newF memAllocator typ shape
Signature: memAllocator:('?177451 -> int64 -> MemAllocKindT -> MemManikinT) -> typ:'?177451 -> shape:int64 list -> ArrayNDManikinT
Type parameters: '?177451

creates a new MemoryManikinT and a new ArrayNDManikinT with Fortran-order

newOrdered (...)
Signature: memAllocator:('?177453 -> int64 -> MemAllocKindT -> MemManikinT) -> typ:'?177453 -> shape:int64 list -> strideOrder:int list -> ArrayNDManikinT
Type parameters: '?177453

creates a new MemoryManikinT and a new ArrayNDManikinT with specifed stride order

newZero typ shape
Signature: typ:TypeNameT -> shape:int64 list -> ArrayNDManikinT

creates a new ArrayNDManikinT using no storage

offset ary
Signature: ary:ArrayNDManikinT -> int64
offsetInBytes ary
Signature: ary:ArrayNDManikinT -> int64

offset in bytes

padLeft a
Signature: a:ArrayNDManikinT -> ArrayNDManikinT

inserts a broadcastable dimension of size one as first dimension

padRight a
Signature: a:ArrayNDManikinT -> ArrayNDManikinT

appends a broadcastable dimension of size one as last dimension

permuteAxes permut a
Signature: permut:int list -> a:ArrayNDManikinT -> ArrayNDManikinT

Permutes the axes as specified. Each entry in the specified permutation specifies the new position of the corresponding axis, i.e. to which position the axis should move.

range rng a
Signature: rng:TensorRng list -> a:ArrayNDManikinT -> ArrayNDManikinT

a view of the specified tensor over the given range

relayout newLayout ary
Signature: newLayout:TensorLayout -> ary:ArrayNDManikinT -> ArrayNDManikinT
reshapeView shp a
Signature: shp:int64 list -> a:ArrayNDManikinT -> ArrayNDManikinT

Tries to reshape the tensor without copying. For this to succeed, the tensor must have row-major layout. If this a reshape without copying is impossible, an error is raised.

reverseAxis ax a
Signature: ax:int -> a:ArrayNDManikinT -> ArrayNDManikinT

Reverses the elements in the specified dimension.

shape ary
Signature: ary:ArrayNDManikinT -> int64 list
sizeInBytes ary
Signature: ary:ArrayNDManikinT -> int64

size in bytes

storage ary
Signature: ary:ArrayNDManikinT -> MemManikinT

storage

stride ary
Signature: ary:ArrayNDManikinT -> int64 list
transpose a
Signature: a:ArrayNDManikinT -> ArrayNDManikinT

transpose

tryReshapeView shp a
Signature: shp:int64 list -> a:ArrayNDManikinT -> ArrayNDManikinT option

Tries to reshape the tensor without copying. For this to succeed, the tensor must have row-major layout. If this a reshape without copying is impossible, None is returned.

typeName ary
Signature: ary:ArrayNDManikinT -> TypeNameT

used data type name

typeSize ary
Signature: ary:ArrayNDManikinT -> int

size of the used data type

typeSize64 ary
Signature: ary:ArrayNDManikinT -> int64

size of the used data type as int64

Fork me on GitHub