public class ImmutableArray extends BaseNDArray implements IDense
data, dimensions, offset, strideshape| Modifier and Type | Method and Description |
|---|---|
AVector |
asVector()
Constructs a view of all elements in the array as a single vector in row-major order.
|
static INDArray |
create(INDArray a) |
int |
dimensionality()
Returns the dimensionality of the array (i.e.
|
long |
elementCount()
Returns the total number of elements in this array.
|
boolean |
equalsArray(double[] data,
int offset)
Returns true if the elements in this array exactly match the elements in the given array, in
row-major order
|
INDArray |
exactClone()
Creates a deep clone of an array, using the same class implementation as the original array
|
double |
get(int... indexes)
Returns the double value at the specified index position in an array
|
double[] |
getArray()
Gets the underlying data array for this strided array
Unsafe operation - may allow modification of otherwise immutable arrays
|
int |
getIndex(int... indexes) |
long[] |
getLongShape()
Returns the shape of the array as an array of longs.
|
int[] |
getShape()
Returns the shape of the array as an array of ints.
|
int[] |
getShapeClone()
Returns the shape of the array as an array of ints, guaranteed to be a new array
i.e.
|
boolean |
isElementConstrained()
Returns true if this array has some constraints on element values
|
boolean |
isFullyMutable()
If this method returns true, the INDArray is guaranteed to be fully mutable
in all positions i.e.
|
boolean |
isMutable()
Returns true if the INDArray is mutable (at least partially)
|
boolean |
isView()
Return true if this array is considered as a view type.
|
void |
set(int[] indexes,
double value)
Sets the element at the given indexed position in a mutable array
|
INDArray |
slice(int majorSlice)
Returns the specified major slice of this array as a view (slice along dimension 0)
0 dimensional slice results are permitted, but attempting to slice a 0 dimensional array
will result in an error.
|
INDArray |
slice(int dimension,
int index)
Returns a slice view of this array along the specified dimension
|
int |
sliceCount()
Returns the number of major slices in this array (i.e.
|
INDArray |
sparseClone()
Creates a fully mutable clone of this array.
|
ImmutableArray |
subArray(int[] offsets,
int[] shape)
Returns a subarray view of a larger array
|
void |
toDoubleBuffer(DoubleBuffer dest)
Copies the elements of this INDArray to the specified double buffer
|
static INDArray |
wrap(double[] data,
int[] shape) |
checkDimension, get, get, get, getArrayOffset, getShape, getStride, getStrides, isPackedArrayisZero, reduce, reduceabs, absCopy, add, add, add, addAt, addCopy, addCopy, addInnerProduct, addInnerProduct, addInnerProduct, addMultiple, addOuterProduct, addPower, addPower, addToArray, applyOp, applyOp, applyOp, applyOp, applyOpCopy, asDoubleArray, asElementList, broadcast, broadcastCloneLike, broadcastCopyLike, broadcastLike, broadcastLike, broadcastLike, checkMutable, clamp, clone, componentCount, copy, dense, denseClone, density, divide, divide, divideCopy, elementAbsPowSum, elementIterator, elementMax, elementMin, elementPowSum, elementProduct, elementsEqual, elementSquaredSum, elementSum, ensureMutable, epsilonEquals, epsilonEquals, equals, equals, equals, equalsArray, exp, fill, get, get, get, get, get, getComponent, getComponents, getElements, getElements, getElements, getElements, getSlices, getSlices, getSliceViews, getTranspose, getTransposeCopy, getTransposeView, hashCode, hasUncountable, immutable, innerProduct, innerProduct, innerProduct, innerProduct, isBoolean, isDense, isSameShape, isSparse, iterator, join, join, log, multiply, multiply, multiplyCopy, multiplyCopy, mutable, negate, negateCopy, nonZeroCount, outerProduct, pow, reciprocal, reciprocalCopy, reduceSlices, reduceSlices, reorder, reorder, reshape, rotateView, scale, scaleAdd, scaleAdd, scaleCopy, set, set, set, set, set, set, setElements, setElements, setElements, setInnerProduct, setMultiple, setMultiple, signum, signumCopy, sliceValue, sparse, sqrt, square, squareCopy, sub, sub, sub, subCopy, toArray, toDoubleArray, toSliceArray, toString, toStringFull, toVector, validate, withComponentsfinalize, getClass, notify, notifyAll, wait, wait, waitabs, absCopy, add, add, addAt, addCopy, addCopy, addInnerProduct, addMultiple, addOuterProduct, addPower, addPower, addToArray, applyOp, applyOp, applyOp, applyOp, applyOpCopy, asDoubleArray, asElementList, broadcast, broadcastCloneLike, broadcastCopyLike, broadcastLike, broadcastLike, broadcastLike, checkMutable, clamp, clone, componentCount, copy, dense, denseClone, divide, divide, divideCopy, elementAbsPowSum, elementIterator, elementMax, elementMin, elementPowSum, elementProduct, elementsEqual, elementSquaredSum, elementSum, ensureMutable, epsilonEquals, epsilonEquals, equals, equalsArray, exp, fill, get, get, get, get, get, getComponent, getComponents, getElements, getElements, getElements, getElements, getSlices, getSlices, getSliceViews, getTranspose, getTransposeCopy, getTransposeView, hasUncountable, immutable, innerProduct, innerProduct, innerProduct, innerProduct, isBoolean, isDense, isSameShape, isSparse, isZero, join, join, log, multiply, multiply, multiplyCopy, multiplyCopy, mutable, negate, negateCopy, nonZeroCount, outerProduct, pow, reciprocal, reciprocalCopy, reduce, reduce, reduceSlices, reduceSlices, reorder, reorder, reshape, rotateView, scale, scaleAdd, scaleAdd, scaleCopy, set, set, set, set, set, set, setElements, setElements, setElements, setInnerProduct, setMultiple, setMultiple, signum, signumCopy, sliceValue, sparse, sqrt, square, squareCopy, sub, sub, subCopy, toArray, toDoubleArray, toSliceArray, toVector, validate, withComponentsforEach, spliteratorpublic static INDArray wrap(double[] data, int[] shape)
public int dimensionality()
INDArraydimensionality in interface INDArraydimensionality in class BaseNDArraypublic boolean isMutable()
INDArrayisMutable in interface INDArrayisMutable in class AbstractArray<INDArray>public boolean isFullyMutable()
INDArrayisFullyMutable in interface INDArrayisFullyMutable in class AbstractArray<INDArray>public boolean isElementConstrained()
INDArrayisElementConstrained in interface INDArrayisElementConstrained in class AbstractArray<INDArray>public int[] getShape()
INDArraygetShape in interface INDArraygetShape in class BaseShapedArraypublic int[] getShapeClone()
INDArraygetShapeClone in interface INDArraygetShapeClone in class BaseShapedArraypublic long[] getLongShape()
INDArraygetLongShape in interface INDArraygetLongShape in class BaseNDArraypublic int getIndex(int... indexes)
getIndex in class BaseNDArraypublic double get(int... indexes)
INDArrayget in interface INDArrayget in class BaseNDArraypublic void set(int[] indexes,
double value)
INDArraypublic INDArray slice(int majorSlice)
INDArraypublic INDArray slice(int dimension, int index)
INDArraypublic int sliceCount()
INDArraysliceCount in interface INDArraysliceCount in class BaseShapedArraypublic ImmutableArray subArray(int[] offsets, int[] shape)
INDArraysubArray in interface INDArraysubArray in class AbstractArray<INDArray>public long elementCount()
INDArrayelementCount in interface INDArrayelementCount in class BaseNDArraypublic boolean isView()
INDArraypublic AVector asVector()
INDArrayasVector in interface INDArrayasVector in class AbstractArray<INDArray>public INDArray exactClone()
INDArrayexactClone in interface INDArraypublic INDArray sparseClone()
INDArraysparseClone in interface INDArraysparseClone in class AbstractArray<INDArray>public void toDoubleBuffer(DoubleBuffer dest)
INDArraytoDoubleBuffer in interface INDArraytoDoubleBuffer in class AbstractArray<INDArray>public boolean equalsArray(double[] data,
int offset)
INDArrayequalsArray in interface INDArrayequalsArray in class AbstractArray<INDArray>data - Array of double element values to check for equalityoffset - Offset into the data arraypublic double[] getArray()
IStridedArraygetArray in interface IStridedArrayCopyright © 2016. All rights reserved.