BufferedNDField

open class BufferedNDField<T, R : Field<T>>(shape: IntArray, elementContext: R, bufferFactory: BufferFactory<T>) : BufferedNDRing<T, R> , NDField<T, R>

Functions

add
Link copied to clipboard
common
open override fun add(a: NDStructure<T>, b: NDStructure<T>): NDStructure<T>
Element-wise addition.
binaryOperation
Link copied to clipboard
common
open fun binaryOperation(operation: String, left: NDStructure<T>, right: NDStructure<T>): NDStructure<T>
Dynamically invokes a binary operation with the certain name.
binaryOperationFunction
Link copied to clipboard
common
open override fun binaryOperationFunction(operation: String): (left: NDStructure<T>, right: NDStructure<T>) -> NDStructure<T>
Dynamically dispatches a binary operation with the certain name.
bindSymbol
Link copied to clipboard
common
open fun bindSymbol(value: String): NDStructure<T>
Wraps a raw string to T object.
combine
Link copied to clipboard
common
abstract fun combine(a: NDStructure<T>, b: NDStructure<T>, transform: R.(T, T) -> T): NDStructure<T>
Combines two structures into one.
div
Link copied to clipboard
common
open operator fun T.div(arg: NDStructure<T>): NDStructure<T>
Divides an element by an ND structure of it.
open operator fun NDStructure<T>.div(arg: T): NDStructure<T>
Divides an ND structure by an element of it.
open operator fun Number.div(b: NDStructure<T>): NDStructure<T>
Division of element by scalar.
open operator fun NDStructure<T>.div(b: NDStructure<T>): NDStructure<T>
Division of two elements.
open operator fun NDStructure<T>.div(k: Number): NDStructure<T>
Division of this element by scalar.
divide
Link copied to clipboard
common
open override fun divide(a: NDStructure<T>, b: NDStructure<T>): NDStructure<T>
Element-wise division.
equals
Link copied to clipboard
common
open operator fun equals(other: Any?): Boolean
hashCode
Link copied to clipboard
common
open fun hashCode(): Int
invoke
Link copied to clipboard
common
open operator fun (T) -> T.invoke(structure: NDStructure<T>): NDStructure<T>
Element-wise invocation of function working on T on a NDStructure.
map
Link copied to clipboard
common
abstract fun NDStructure<T>.map(transform: R.(T) -> T): NDStructure<T>
Maps elements from one structure to another one by applying transform to them.
mapIndexed
Link copied to clipboard
common
abstract fun NDStructure<T>.mapIndexed(transform: R.(index: IntArray, T) -> T): NDStructure<T>
Maps elements from one structure to another one by applying transform to them alongside with their indices.
minus
Link copied to clipboard
common
open operator fun T.minus(arg: NDStructure<T>): NDStructure<T>
Subtracts an ND structure from an element of it.
open operator fun NDStructure<T>.minus(arg: T): NDStructure<T>
Subtracts an element from ND structure of it.
open operator fun NDStructure<T>.minus(b: NDStructure<T>): NDStructure<T>
Subtraction of two elements.
multiply
Link copied to clipboard
common
open override fun multiply(a: NDStructure<T>, b: NDStructure<T>): NDStructure<T>
Element-wise multiplication.
open override fun multiply(a: NDStructure<T>, k: Number): NDStructure<T>
Element-wise multiplication by scalar.
plus
Link copied to clipboard
common
open operator fun T.plus(arg: NDStructure<T>): NDStructure<T>
Adds an element to ND structure of it.
open operator fun NDStructure<T>.plus(arg: T): NDStructure<T>
Adds an ND structure to an element of it.
open operator fun NDStructure<T>.plus(b: NDStructure<T>): NDStructure<T>
Addition of two elements.
produce
Link copied to clipboard
common
abstract fun produce(initializer: R.(IntArray) -> T): NDStructure<T>
Produces a new N structure using given initializer function.
times
Link copied to clipboard
common
open operator fun T.times(arg: NDStructure<T>): NDStructure<T>
Multiplies an element by a ND structure of it.
open operator fun NDStructure<T>.times(arg: T): NDStructure<T>
Multiplies an ND structure by an element of it.
open operator fun NDStructure<T>.times(b: NDStructure<T>): NDStructure<T>
Multiplies this element by scalar.
open operator fun Number.times(b: NDStructure<T>): NDStructure<T>
Multiplication of this number by element.
open operator fun NDStructure<T>.times(k: Number): NDStructure<T>
Multiplication of this element by a scalar.
toString
Link copied to clipboard
common
open fun toString(): String
unaryMinus
Link copied to clipboard
common
open operator fun NDStructure<T>.unaryMinus(): NDStructure<T>
The negation of this element.
unaryOperation
Link copied to clipboard
common
open fun unaryOperation(operation: String, arg: NDStructure<T>): NDStructure<T>
Dynamically invokes an unary operation with the certain name.
unaryOperationFunction
Link copied to clipboard
common
open override fun unaryOperationFunction(operation: String): (arg: NDStructure<T>) -> NDStructure<T>
Dynamically dispatches an unary operation with the certain name.
unaryPlus
Link copied to clipboard
common
open operator fun NDStructure<T>.unaryPlus(): NDStructure<T>
Returns this value.

Properties

buffer
Link copied to clipboard
common
open val NDStructure<T>.buffer: Buffer<T>
bufferFactory
Link copied to clipboard
common
override val bufferFactory: BufferFactory<T>
elementContext
Link copied to clipboard
common
override val elementContext: R
The algebra over elements of ND structure.
one
Link copied to clipboard
common
open override val one: NDBuffer<T>
neutral operation for multiplication
shape
Link copied to clipboard
common
override val shape: IntArray
The shape of ND-structures this algebra operates on.
strides
Link copied to clipboard
common
open override val strides: Strides
zero
Link copied to clipboard
common
open override val zero: NDBuffer<T>
The neutral element of addition.

Inheritors

RealNDField
Link copied to clipboard