public class ImmutableArray extends BaseNDArray
data, dimensions, offset, shape, stride| Modifier and Type | Method and Description |
|---|---|
AVector |
asVector()
Constructs a view of the array as a single vector in row-major order.
|
static INDArray |
create(INDArray a) |
int |
dimensionality()
Returns the dimensionality of the array (number of dimensions in the array shape)
e.g.
|
long |
elementCount()
Returns the total number of elements in this array.
|
INDArray |
exactClone()
Returns an exact deep clone of an array (i.e.
|
double |
get(int... indexes)
Returns the double value at the specified index position in an array
|
double[] |
getArray() |
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
|
int |
getStride(int dim) |
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 a view type
|
void |
set(int[] indexes,
double value) |
INDArray |
slice(int majorSlice)
Returns the specified major slice of this array as a view (slice along dimension 0)
|
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.
|
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) |
get, get, get, getArrayOffset, getShape, getStrides, isPackedArrayabs, add, add, applyOp, applyOp, asDoubleArray, asElementList, broadcast, broadcastCloneLike, broadcastLike, clamp, clone, copyTo, divide, divide, elementIterator, elementSquaredSum, elementSum, ensureMutable, epsilonEquals, epsilonEquals, equals, equals, exp, fill, getElements, getSlices, getSlices, getSliceViews, getTranspose, getTransposeCopy, getTransposeView, hashCode, immutable, innerProduct, isBoolean, isSameShape, isZero, iterator, join, log, multiply, multiply, mutable, negate, nonZeroCount, outerProduct, pow, reciprocal, reshape, rotateView, scale, scaleAdd, set, set, set, set, set, setElements, setElements, signum, sqrt, square, sub, sub, toArray, toDoubleArray, toString, toVector, validatefinalize, getClass, notify, notifyAll, wait, wait, waitabs, add, add, applyOp, applyOp, asDoubleArray, asElementList, broadcast, broadcastCloneLike, broadcastLike, clamp, clone, copyTo, divide, divide, elementIterator, elementSquaredSum, elementSum, ensureMutable, epsilonEquals, epsilonEquals, equals, exp, fill, getElements, getSlices, getSlices, getSliceViews, getTranspose, getTransposeCopy, getTransposeView, immutable, innerProduct, isBoolean, isSameShape, isZero, join, log, multiply, multiply, mutable, negate, nonZeroCount, outerProduct, pow, reciprocal, reshape, rotateView, scale, scaleAdd, set, set, set, set, set, setElements, setElements, signum, sqrt, square, sub, sub, toArray, toDoubleArray, toVector, validatepublic 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 IStridedArraygetShape in interface INDArraygetShape in class BaseNDArraypublic int[] getShapeClone()
INDArraygetShapeClone in interface INDArraygetShapeClone in class BaseNDArraypublic long[] getLongShape()
INDArraygetLongShape in interface INDArraygetLongShape in class BaseNDArraypublic int getStride(int dim)
getStride in interface IStridedArraygetStride 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)
public INDArray slice(int majorSlice)
INDArraypublic INDArray slice(int dimension, int index)
INDArraypublic ImmutableArray subArray(int[] offsets, int[] shape)
INDArraysubArray in interface INDArraysubArray in class AbstractArray<INDArray>public int sliceCount()
INDArraysliceCount in interface INDArraysliceCount in class BaseNDArraypublic 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()
INDArraypublic void toDoubleBuffer(DoubleBuffer dest)
INDArraytoDoubleBuffer in interface INDArraytoDoubleBuffer in class AbstractArray<INDArray>public double[] getArray()
Copyright © 2013. All Rights Reserved.