public interface INDArray extends Serializable
Modifier and Type | Method and Description |
---|---|
IComplexNDArray |
add(IComplexNumber n) |
IComplexNDArray |
add(IComplexNumber n,
IComplexNDArray result) |
INDArray |
add(INDArray other)
copy addition of two matrices
|
INDArray |
add(INDArray other,
INDArray result)
copy addition of two matrices
|
INDArray |
add(Number n)
Scalar addition (cloning)
|
INDArray |
add(Number n,
INDArray result) |
INDArray |
addColumnVector(INDArray columnVector)
Addition of a column vector (copy)
|
IComplexNDArray |
addi(IComplexNumber n) |
IComplexNDArray |
addi(IComplexNumber n,
IComplexNDArray result) |
INDArray |
addi(INDArray other)
in place addition of two matrices
|
INDArray |
addi(INDArray other,
INDArray result)
in place addition of two matrices
|
INDArray |
addi(Number n)
In place scalar addition
|
INDArray |
addi(Number n,
INDArray result)
In place addition
|
INDArray |
addiColumnVector(INDArray columnVector)
In place addition of a column vector
|
INDArray |
addiRowVector(INDArray rowVector)
In place addition of a row vector
|
INDArray |
addRowVector(INDArray rowVector)
Addition of a row vector (copy)
|
INDArray |
assign(INDArray arr)
Assign all of the elements in the given
ndarray to this ndarray
|
INDArray |
assign(Number value)
Set the value of the ndarray to the specified value
|
INDArray |
broadcast(int... shape)
Broadcasts this ndarray to be the specified shape
|
void |
checkDimensions(INDArray other)
Validate dimensions are equal
|
void |
cleanup()
Cleanup resources
|
int |
columns()
Returns the number of columns in this matrix (throws exception if not 2d)
|
INDArray |
cond(Condition condition)
1 in the ndarray if the element matches
the condition 0 otherwise
|
INDArray |
condi(Condition condition)
1 in the ndarray if the element matches
the condition 0 otherwise
|
INDArray |
cumsum(int dimension)
Cumulative sum along a dimension (in place)
|
INDArray |
cumsumi(int dimension)
Cumulative sum along a dimension
|
DataBuffer |
data()
Returns a linear double array representation of this ndarray
|
INDArray |
dimShuffle(Object[] rearrange,
int[] newOrder,
boolean[] broadCastable)
Dimshuffle: an extension of permute that adds the ability
to broadcast various dimensions.
|
double |
distance1(INDArray other)
Returns the (1-norm) distance.
|
double |
distance2(INDArray other)
Returns the (euclidean) distance.
|
IComplexNDArray |
div(IComplexNumber n) |
IComplexNDArray |
div(IComplexNumber n,
IComplexNDArray result) |
INDArray |
div(INDArray other)
in place (element wise) division of two matrices
|
INDArray |
div(INDArray other,
INDArray result)
copy (element wise) division of two matrices
|
INDArray |
div(Number n)
Division by a number
|
INDArray |
div(Number n,
INDArray result) |
INDArray |
divColumnVector(INDArray columnVector)
Division of a column vector (copy)
|
IComplexNDArray |
divi(IComplexNumber n) |
IComplexNDArray |
divi(IComplexNumber n,
IComplexNDArray result) |
INDArray |
divi(INDArray other)
in place (element wise) division of two matrices
|
INDArray |
divi(INDArray other,
INDArray result)
in place (element wise) division of two matrices
|
INDArray |
divi(Number n)
In place scalar division
|
INDArray |
divi(Number n,
INDArray result)
In place division of this ndarray
|
INDArray |
diviColumnVector(INDArray columnVector)
In place division of a column vector
|
INDArray |
diviRowVector(INDArray rowVector)
In place division of a row vector
|
INDArray |
divRowVector(INDArray rowVector)
Division of a row vector (copy)
|
INDArray |
dup()
Return a copy of this ndarray
|
INDArray |
dup(char order)
Return a copy of this ndarray, where the returned ndarray has the specified order
|
Object |
element()
Returns a scalar (individual element)
of a scalar ndarray
|
int |
elementStride()
Element stride (one element to the next,
also called the defualt stride: 1 for normal
2 for complex)
|
int |
elementWiseStride()
Element wise stride
|
INDArray |
eps(INDArray other)
epsilon equals than comparison:
If the given number is less than the
comparison number the item is 0 otherwise 1
|
INDArray |
eps(Number other)
Returns an ndarray with 1 if the element is epsilon equals
|
INDArray |
epsi(INDArray other)
In place epsilon equals than comparison:
If the given number is less than the
comparison number the item is 0 otherwise 1
|
INDArray |
epsi(Number other)
Returns an ndarray with 1 if the element is epsilon equals
|
INDArray |
eq(INDArray other)
equal than comparison:
If the given number is less than the
comparison number the item is 0 otherwise 1
|
INDArray |
eq(Number other)
Returns an ndarray with 1 if the element is less than
the given element 0 other wise
|
INDArray |
eqi(INDArray other)
In place equal than comparison:
If the given number is less than the
comparison number the item is 0 otherwise 1
|
INDArray |
eqi(Number other)
In place less than comparison:
If the given number is less than the
comparison number the item is 0 otherwise 1
|
INDArray |
get(INDArrayIndex... indexes)
Returns a subset of this array based on the specified
indexes
|
INDArray |
getColumn(int i)
Returns the specified column.
|
INDArray |
getColumns(int... columns)
Get a list of specified columns
|
double |
getDouble(int... indices) |
double |
getDouble(int i) |
double |
getDouble(int i,
int j) |
float |
getFloat(int i)
Return the item at the linear index i
|
float |
getFloat(int[] indices)
Returns the elements at the the specified indices
|
float |
getFloat(int i,
int j)
Return the item at row i column j
Note that this is the same as calling getScalar(new int[]{i,j}
|
int |
getInt(int... indices) |
int |
getLeadingOnes() |
INDArray |
getRow(int i)
Returns the specified row.
|
INDArray |
getRows(int... rows)
Get a list of rows
|
INDArray |
getScalar(int i)
Returns the element at the specified index
|
INDArray |
getScalar(int[] indices)
Returns the elements at the the specified indices
|
INDArray |
getScalar(int row,
int column)
Returns the element at the specified row/column
This will throw an exception if the
|
int |
getTrailingOnes() |
INDArray |
gt(INDArray other)
greater than comparison:
If the given number is less than the
comparison number the item is 0 otherwise 1
|
INDArray |
gt(Number other)
Greater than boolean (copying)(
|
INDArray |
gti(INDArray other)
In place greater than comparison:
If the given number is less than the
comparison number the item is 0 otherwise 1
|
INDArray |
gti(Number other)
In place greater than comparison:
If the given number is less than the
comparison number the item is 0 otherwise 1
|
int |
index(int row,
int column)
Return the linear index of the specified row and column
|
int |
innerMostStride()
Get the inner most stride
wrt the ordering of the array
|
boolean |
isCleanedUp()
Returns true if the ndarray has already been freed
|
boolean |
isColumnVector()
Returns true if the number of columns is 1
|
boolean |
isMatrix()
Returns true if this ndarray is a matrix
|
boolean |
isRowVector()
Returns true if the number of rows is 1
|
boolean |
isScalar()
Returns true if this ndarray is a scalar
|
boolean |
isSquare()
Returns whether the matrix
has the same rows and columns
|
boolean |
isVector()
Returns true if this ndarray is a vector
|
boolean |
isWrapAround()
Returns true if the ndarray
on linear indexing wraps around
based on the stride(1) of the ndarray
This is a useful optimization in linear view
where strides that might otherwise
go out of bounds but wrap around instead.
|
int |
length()
Returns the total number of elements in the ndarray
|
int |
linearIndex(int i)
Get the linear index of the data in to
the array
|
INDArray |
linearView()
Returns a linear view reference of shape
1,length(ndarray)
|
INDArray |
linearViewColumnOrder()
Returns a linear view reference of shape
1,length(ndarray)
|
INDArray |
lt(INDArray other)
less than comparison:
If the given number is less than the
comparison number the item is 0 otherwise 1
|
INDArray |
lt(Number other)
Returns an ndarray with 1 if the element is less than
the given element 0 other wise
|
INDArray |
lti(INDArray other)
In place less than comparison:
If the given number is less than the
comparison number the item is 0 otherwise 1
|
INDArray |
lti(Number other)
In place less than comparison:
If the given number is less than the
comparison number the item is 0 otherwise 1
|
int |
majorStride()
Return the major stride for an ndarray
|
INDArray |
max(int... dimension)
Returns the overall max of this ndarray
|
IComplexNumber |
maxComplex() |
Number |
maxNumber() |
INDArray |
mean(int... dimension)
Returns the overall mean of this ndarray
|
IComplexNumber |
meanComplex() |
Number |
meanNumber() |
INDArray |
min(int... dimension)
Returns the overall min of this ndarray
|
IComplexNumber |
minComplex() |
Number |
minNumber() |
INDArray |
mmul(INDArray other)
Perform a copy matrix multiplication
|
INDArray |
mmul(INDArray other,
INDArray result)
Perform an copy matrix multiplication
|
INDArray |
mmuli(INDArray other)
Perform an copy matrix multiplication
|
INDArray |
mmuli(INDArray other,
INDArray result)
Perform an copy matrix multiplication
|
IComplexNDArray |
mul(IComplexNumber n) |
IComplexNDArray |
mul(IComplexNumber n,
IComplexNDArray result) |
INDArray |
mul(INDArray other)
copy (element wise) multiplication of two matrices
|
INDArray |
mul(INDArray other,
INDArray result)
copy (element wise) multiplication of two matrices
|
INDArray |
mul(Number n)
Scalar multiplication (copy)
|
INDArray |
mul(Number n,
INDArray result) |
INDArray |
mulColumnVector(INDArray columnVector)
Multiplication of a column vector (copy)
|
IComplexNDArray |
muli(IComplexNumber n) |
IComplexNDArray |
muli(IComplexNumber n,
IComplexNDArray result) |
INDArray |
muli(INDArray other)
in place (element wise) multiplication of two matrices
|
INDArray |
muli(INDArray other,
INDArray result)
in place (element wise) multiplication of two matrices
|
INDArray |
muli(Number n)
In place scalar multiplication
|
INDArray |
muli(Number n,
INDArray result)
In place multiplication of this ndarray
|
INDArray |
muliColumnVector(INDArray columnVector)
In place multiplication of a column vector
|
INDArray |
muliRowVector(INDArray rowVector)
In place multiplication of a row vector
|
INDArray |
mulRowVector(INDArray rowVector)
Multiplication of a row vector (copy)
|
INDArray |
neg()
Returns the ndarray negative (cloned)
|
INDArray |
negi()
In place setting of the negative version of this ndarray
|
INDArray |
neq(INDArray other) |
INDArray |
neq(Number other)
Not equal
|
INDArray |
neqi(INDArray other) |
INDArray |
neqi(Number other)
In place not equal
|
INDArray |
norm1(int... dimension)
Returns the norm1 along the specified dimension
|
IComplexNumber |
norm1Complex() |
Number |
norm1Number() |
INDArray |
norm2(int... dimension)
Returns the norm2 along the specified dimension
|
IComplexNumber |
norm2Complex() |
Number |
norm2Number() |
INDArray |
normmax(int... dimension)
Returns the normmax along the specified dimension
|
IComplexNumber |
normmaxComplex() |
Number |
normmaxNumber() |
int |
offset()
Returns the start of where the ndarray is
for the underlying data
|
char |
ordering()
Return the ordering (fortran or c)
of this ndarray
|
INDArray |
permute(int... rearrange)
See: http://www.mathworks.com/help/matlab/ref/permute.html
|
INDArray |
prod(int... dimension)
Returns the product along a given dimension
|
IComplexNumber |
prodComplex() |
Number |
prodNumber() |
INDArray |
put(INDArrayIndex[] indices,
INDArray element)
Put the elements of the ndarray
in to the specified indices
|
INDArray |
put(INDArrayIndex[] indices,
Number element)
Put the elements of the ndarray
in to the specified indices
|
INDArray |
put(int[] indices,
INDArray element)
Inserts the element at the specified index
|
INDArray |
put(int i,
INDArray element)
Inserts the element at the specified index
|
INDArray |
put(int i,
int j,
INDArray element)
Inserts the element at the specified index
|
INDArray |
put(int i,
int j,
Number element)
Inserts the element at the specified index
|
INDArray |
putColumn(int column,
INDArray toPut)
Insert a column in to this array
Will throw an exception if this
ndarray is not a matrix
|
INDArray |
putRow(int row,
INDArray toPut)
Insert a row in to this array
Will throw an exception if this
ndarray is not a matrix
|
INDArray |
putScalar(int[] i,
double value)
Insert the item at the specified indices
|
INDArray |
putScalar(int[] indexes,
float value) |
INDArray |
putScalar(int[] indexes,
int value) |
INDArray |
putScalar(int i,
double value)
Insert the number linearly in to the ndarray
|
INDArray |
putScalar(int i,
float value)
Insert a scalar float at the specified index
|
INDArray |
putScalar(int i,
int value)
Insert a scalar int at the specified index
|
INDArray |
putSlice(int slice,
INDArray put)
Assigns the given matrix (put) to the specified slice
|
int |
rank()
The rank of the ndarray (the number of dimensions
|
INDArray |
ravel()
Returns a flattened version (row vector) of this ndarray
|
INDArray |
ravel(char order)
Returns a flattened version (row vector) of this ndarray
|
IComplexNDArray |
rdiv(IComplexNumber n) |
IComplexNDArray |
rdiv(IComplexNumber n,
IComplexNDArray result) |
INDArray |
rdiv(INDArray other)
Reverse division
|
INDArray |
rdiv(INDArray other,
INDArray result)
Reverse division
|
INDArray |
rdiv(Number n)
Reverse division
|
INDArray |
rdiv(Number n,
INDArray result)
Reverse division (number / ndarray)
|
INDArray |
rdivColumnVector(INDArray columnVector)
Reverse division of a column vector (copy)
|
IComplexNDArray |
rdivi(IComplexNumber n) |
IComplexNDArray |
rdivi(IComplexNumber n,
IComplexNDArray result) |
INDArray |
rdivi(INDArray other)
Reverse divsion (in place)
|
INDArray |
rdivi(INDArray other,
INDArray result)
Reverse division (in-place)
|
INDArray |
rdivi(Number n)
In place reverse division
|
INDArray |
rdivi(Number n,
INDArray result)
Reverse in place division
|
INDArray |
rdiviColumnVector(INDArray columnVector)
In place reverse divison of a column vector
|
INDArray |
rdiviRowVector(INDArray rowVector)
In place reverse division of a column vector
|
INDArray |
rdivRowVector(INDArray rowVector)
Reverse division of a column vector (copy)
|
INDArray |
repeat(int... repeats)
Returns a flat array
with the elements repeated k times along each given dimension
|
INDArray |
repeat(int dimension,
int... repeats)
Repeat elements along a specified dimension.
|
INDArray |
repmat(int... shape)
Replicate and tile array to fill out to the given shape
|
void |
resetLinearView()
Resets the linear view
|
INDArray |
reshape(char order,
int... newShape)
Reshapes the ndarray (can't change the length of the ndarray)
|
INDArray |
reshape(char order,
int rows,
int columns)
Reshapes the ndarray (can't change the length of the ndarray)
|
INDArray |
reshape(int... newShape)
Reshapes the ndarray (can't change the length of the ndarray)
|
INDArray |
reshape(int rows,
int columns)
Reshapes the ndarray (can't change the length of the ndarray)
|
int |
rows()
Returns the number of rows in this matrix (throws exception if not 2d)
|
IComplexNDArray |
rsub(IComplexNumber n) |
IComplexNDArray |
rsub(IComplexNumber n,
IComplexNDArray result) |
INDArray |
rsub(INDArray other) |
INDArray |
rsub(INDArray other,
INDArray result)
Reverse subtraction
|
INDArray |
rsub(Number n)
Reverse subtraction with duplicates
|
INDArray |
rsub(Number n,
INDArray result)
Reverse subtraction
|
INDArray |
rsubColumnVector(INDArray columnVector)
Reverse subtraction of a column vector (copy)
|
IComplexNDArray |
rsubi(IComplexNumber n) |
IComplexNDArray |
rsubi(IComplexNumber n,
IComplexNDArray result) |
INDArray |
rsubi(INDArray other) |
INDArray |
rsubi(INDArray other,
INDArray result)
Reverse subtraction (in-place)
|
INDArray |
rsubi(Number n) |
INDArray |
rsubi(Number n,
INDArray result)
Reverse in place subtraction
|
INDArray |
rsubiColumnVector(INDArray columnVector)
In place reverse subtraction of a column vector
|
INDArray |
rsubiRowVector(INDArray rowVector)
In place reverse subtraction of a row vector
|
INDArray |
rsubRowVector(INDArray rowVector)
Reverse subtraction of a row vector (copy)
|
int |
secondaryStride()
Return the second stride for an ndarray.
|
void |
setData(DataBuffer data) |
void |
setOrder(char order)
Set the ordering
|
void |
setShape(int... shape)
Shape setter
|
void |
setStride(int... stride)
stride setter
|
void |
setWrapAround(boolean wrapAround)
Set the ndarray to wrap around
|
int[] |
shape()
Returns the shape of this ndarray
|
int |
size(int dimension)
Returns the size along a specified dimension
|
INDArray |
slice(int i)
Returns the specified slice of this ndarray
|
INDArray |
slice(int i,
int dimension)
Returns the specified slice of this ndarray
|
int |
slices()
Returns the number of slices in this ndarray
|
void |
sliceVectors(List<INDArray> list) |
double |
squaredDistance(INDArray other)
Returns the squared (Euclidean) distance.
|
INDArray |
std(int... dimension)
Standard deviation of an ndarray along a dimension
|
IComplexNumber |
stdComplex() |
Number |
stdNumber() |
int[] |
stride()
Returns the stride of this ndarray
|
int |
stride(int dimension)
Calculate the stride along a particular dimension
|
IComplexNDArray |
sub(IComplexNumber n) |
IComplexNDArray |
sub(IComplexNumber n,
IComplexNDArray result) |
INDArray |
sub(INDArray other)
copy subtraction of two matrices
|
INDArray |
sub(INDArray other,
INDArray result)
copy subtraction of two matrices
|
INDArray |
sub(Number n)
Scalar subtraction (copied)
|
INDArray |
sub(Number n,
INDArray result) |
INDArray |
subArray(int[] offsets,
int[] shape,
int[] stride) |
INDArray |
subArray(ShapeOffsetResolution resolution)
Sub array based on the
pre calculated shape,strides, offsets
|
INDArray |
subColumnVector(INDArray columnVector)
Subtraction of a column vector (copy)
|
IComplexNDArray |
subi(IComplexNumber n) |
IComplexNDArray |
subi(IComplexNumber n,
IComplexNDArray result) |
INDArray |
subi(INDArray other)
in place subtraction of two matrices
|
INDArray |
subi(INDArray other,
INDArray result)
in place subtraction of two matrices
|
INDArray |
subi(Number n)
In place scalar subtraction
|
INDArray |
subi(Number n,
INDArray result)
In place subtraction of this ndarray
|
INDArray |
subiColumnVector(INDArray columnVector)
In place subtraction of a column vector
|
INDArray |
subiRowVector(INDArray rowVector)
In place subtraction of a row vector
|
INDArray |
subRowVector(INDArray rowVector)
Subtraction of a row vector (copy)
|
INDArray |
sum(int... dimension)
Returns the sum along the last dimension of this ndarray
|
IComplexNumber |
sumComplex()
Sum the entire array
|
Number |
sumNumber()
Sum the entire array
|
INDArray |
swapAxes(int dimension,
int with)
Mainly here for people coming from numpy.
|
INDArray |
tensorAlongDimension(int index,
int... dimension)
Get the vector along a particular dimension
|
int |
tensorssAlongDimension(int... dimension)
Returns the number of possible vectors for a given dimension
|
INDArray |
transpose()
Flip the rows and columns of a matrix
|
INDArray |
transposei()
Flip the rows and columns of a matrix
|
INDArray |
var(int... dimension)
Returns the overall variance of this ndarray
|
IComplexNumber |
varComplex() |
Number |
varNumber() |
INDArray |
vectorAlongDimension(int index,
int dimension)
Get the vector along a particular dimension
|
int |
vectorsAlongDimension(int dimension)
Returns the number of possible vectors for a given dimension
|
void setWrapAround(boolean wrapAround)
wrapAround
- thewrap aroundboolean isWrapAround()
int rank()
int stride(int dimension)
dimension
- the dimension to get the stride forint elementStride()
int elementWiseStride()
boolean isCleanedUp()
void cleanup()
void resetLinearView()
int secondaryStride()
int majorStride()
int innerMostStride()
INDArray linearView()
INDArray linearViewColumnOrder()
int vectorsAlongDimension(int dimension)
dimension
- the dimension to calculate the number of vectors forINDArray vectorAlongDimension(int index, int dimension)
index
- the index of the vector to getScalardimension
- the dimension to getScalar the vector fromint tensorssAlongDimension(int... dimension)
dimension
- the dimension to calculate the number of vectors forINDArray tensorAlongDimension(int index, int... dimension)
index
- the index of the vector to getScalardimension
- the dimension to getScalar the vector fromINDArray cumsumi(int dimension)
dimension
- the dimension to perform cumulative sum alongINDArray cumsum(int dimension)
dimension
- the dimension to perform cumulative sum alongINDArray assign(INDArray arr)
arr
- the elements to assignINDArray putScalar(int i, double value)
i
- the index to insert intovalue
- the value to insertINDArray putScalar(int i, float value)
i
- value
- INDArray putScalar(int i, int value)
i
- value
- INDArray putScalar(int[] i, double value)
i
- the indices to insert atvalue
- the number to insertINDArray lt(Number other)
other
- the number to compareINDArray lti(Number other)
other
- the number to compareINDArray putScalar(int[] indexes, float value)
indexes
- value
- INDArray putScalar(int[] indexes, int value)
indexes
- value
- INDArray eps(Number other)
other
- the number to compareINDArray epsi(Number other)
other
- the number to compareINDArray eq(Number other)
other
- the number to compareINDArray eqi(Number other)
other
- the number to compareINDArray gti(Number other)
other
- the number to compareINDArray lt(INDArray other)
other
- the number to compareINDArray lti(INDArray other)
other
- the number to compareINDArray eps(INDArray other)
other
- the number to compareINDArray epsi(INDArray other)
other
- the number to compareINDArray eq(INDArray other)
other
- the number to compareINDArray eqi(INDArray other)
other
- the number to compareINDArray gt(INDArray other)
other
- the number to compareINDArray gti(INDArray other)
other
- the number to compareINDArray neg()
INDArray negi()
INDArray mul(Number n)
n
- the number to multiply byINDArray sub(Number n)
n
- the number to subtract byINDArray add(Number n)
n
- the number to addINDArray rdiv(Number n, INDArray result)
n
- the number to divide byresult
- INDArray rdivi(Number n, INDArray result)
n
- the number to divide by byresult
- the result ndarrayINDArray rsub(Number n, INDArray result)
n
- the number to subtract byresult
- the result ndarrayINDArray rsubi(Number n, INDArray result)
n
- the number to subtract byresult
- the result ndarrayINDArray divi(Number n, INDArray result)
n
- the number to divide byresult
- the result ndarrayINDArray muli(Number n, INDArray result)
n
- the number to divide byresult
- the result ndarrayINDArray subi(Number n, INDArray result)
n
- the number to subtract byresult
- the result ndarrayINDArray addi(Number n, INDArray result)
n
- the number to addresult
- the result ndarrayINDArray get(INDArrayIndex... indexes)
indexes
- the indexes in to the arrayINDArray getColumns(int... columns)
columns
- INDArray getRows(int... rows)
rows
- INDArray rdiv(INDArray other)
other
- the matrix to divide fromINDArray rdiv(INDArray other, INDArray result)
other
- the matrix to subtract fromresult
- the result ndarrayINDArray rdivi(INDArray other, INDArray result)
other
- the other ndarray to subtractresult
- the result ndarrayINDArray rsub(INDArray other, INDArray result)
other
- the matrix to subtract fromresult
- the result ndarrayINDArray rsubi(INDArray other, INDArray result)
other
- the other ndarray to subtractresult
- the result ndarrayINDArray assign(Number value)
value
- the value to assignint linearIndex(int i)
i
- the index to getScalarvoid checkDimensions(INDArray other)
other
- the other ndarray to compareINDArray putSlice(int slice, INDArray put)
slice
- the slice to assignput
- the slice to applyTransformToDestinationINDArray cond(Condition condition)
condition
- INDArray condi(Condition condition)
condition
- INDArray repmat(int... shape)
shape
- the new shape of this ndarrayINDArray repeat(int dimension, int... repeats)
dimension
- the dimension to repeatrepeats
- the number of elements to repeat on each elementINDArray repeat(int... repeats)
repeats
- INDArray putRow(int row, INDArray toPut)
row
- the row insert intotoPut
- the row to insertINDArray putColumn(int column, INDArray toPut)
column
- the column to inserttoPut
- the array to putINDArray getScalar(int row, int column)
row
- the row of the element to returncolumn
- the row of the element to returnINDArray getScalar(int i)
i
- the index of the element to returnint index(int row, int column)
row
- the row to getScalar the linear index forcolumn
- the column to getScalar the linear index fordouble squaredDistance(INDArray other)
double distance2(INDArray other)
double distance1(INDArray other)
INDArray put(INDArrayIndex[] indices, INDArray element)
indices
- the indices to put the ndarray in toelement
- the ndarray to putINDArray put(INDArrayIndex[] indices, Number element)
indices
- the indices to put the ndarray in toelement
- the ndarray to putINDArray put(int[] indices, INDArray element)
indices
- the indices to insert intoelement
- a scalar ndarrayINDArray put(int i, int j, INDArray element)
i
- the row insert intoj
- the column to insert intoelement
- a scalar ndarrayINDArray put(int i, int j, Number element)
i
- the row insert intoj
- the column to insert intoelement
- a scalar ndarrayINDArray put(int i, INDArray element)
i
- the index insert intoelement
- a scalar ndarrayINDArray diviColumnVector(INDArray columnVector)
columnVector
- the column vector used for divisionINDArray divColumnVector(INDArray columnVector)
columnVector
- the column vector used for divisionINDArray diviRowVector(INDArray rowVector)
rowVector
- the row vector used for divisionINDArray divRowVector(INDArray rowVector)
rowVector
- the row vector used for divisionINDArray rdiviColumnVector(INDArray columnVector)
columnVector
- the column vector used for divisionINDArray rdivColumnVector(INDArray columnVector)
columnVector
- the column vector used for divisionINDArray rdiviRowVector(INDArray rowVector)
rowVector
- the row vector used for divisionINDArray rdivRowVector(INDArray rowVector)
rowVector
- the row vector used for divisionINDArray muliColumnVector(INDArray columnVector)
columnVector
- the column vector used for multiplicationINDArray mulColumnVector(INDArray columnVector)
columnVector
- the column vector used for multiplicationINDArray muliRowVector(INDArray rowVector)
rowVector
- the row vector used for multiplicationINDArray mulRowVector(INDArray rowVector)
rowVector
- the row vector used for multiplicationINDArray rsubiColumnVector(INDArray columnVector)
columnVector
- the column vector to subtractINDArray rsubColumnVector(INDArray columnVector)
columnVector
- the column vector to subtractINDArray rsubiRowVector(INDArray rowVector)
rowVector
- the row vector to subtractINDArray rsubRowVector(INDArray rowVector)
rowVector
- the row vector to subtractINDArray subiColumnVector(INDArray columnVector)
columnVector
- the column vector to subtractINDArray subColumnVector(INDArray columnVector)
columnVector
- the column vector to subtractINDArray subiRowVector(INDArray rowVector)
rowVector
- the row vector to subtractINDArray subRowVector(INDArray rowVector)
rowVector
- the row vector to subtractINDArray addiColumnVector(INDArray columnVector)
columnVector
- the column vector to addINDArray addColumnVector(INDArray columnVector)
columnVector
- the column vector to addINDArray addiRowVector(INDArray rowVector)
rowVector
- the row vector to addINDArray addRowVector(INDArray rowVector)
rowVector
- the row vector to addINDArray mmul(INDArray other)
other
- the other matrix to perform matrix multiply withINDArray mmul(INDArray other, INDArray result)
other
- the other matrix to perform matrix multiply withresult
- the result ndarrayINDArray div(INDArray other)
other
- the second ndarray to divideINDArray div(INDArray other, INDArray result)
other
- the second ndarray to divideresult
- the result ndarrayINDArray mul(INDArray other)
other
- the second ndarray to multiplyINDArray mul(INDArray other, INDArray result)
other
- the second ndarray to multiplyresult
- the result ndarrayINDArray sub(INDArray other)
other
- the second ndarray to subtractINDArray sub(INDArray other, INDArray result)
other
- the second ndarray to subtractresult
- the result ndarrayINDArray add(INDArray other)
other
- the second ndarray to addINDArray add(INDArray other, INDArray result)
other
- the second ndarray to addresult
- the result ndarrayINDArray mmuli(INDArray other)
other
- the other matrix to perform matrix multiply withINDArray mmuli(INDArray other, INDArray result)
other
- the other matrix to perform matrix multiply withresult
- the result ndarrayINDArray divi(INDArray other)
other
- the second ndarray to divideINDArray divi(INDArray other, INDArray result)
other
- the second ndarray to divideresult
- the result ndarrayINDArray muli(INDArray other)
other
- the second ndarray to multiplyINDArray muli(INDArray other, INDArray result)
other
- the second ndarray to multiplyresult
- the result ndarrayINDArray subi(INDArray other)
other
- the second ndarray to subtractINDArray subi(INDArray other, INDArray result)
other
- the second ndarray to subtractresult
- the result ndarrayINDArray addi(INDArray other)
other
- the second ndarray to addINDArray addi(INDArray other, INDArray result)
other
- the second ndarray to addresult
- the result ndarrayINDArray normmax(int... dimension)
dimension
- the dimension to getScalar the norm1 alongNumber normmaxNumber()
IComplexNumber normmaxComplex()
INDArray norm2(int... dimension)
dimension
- the dimension to getScalar the norm2 alongNumber norm2Number()
IComplexNumber norm2Complex()
INDArray norm1(int... dimension)
dimension
- the dimension to getScalar the norm1 alongNumber norm1Number()
IComplexNumber norm1Complex()
INDArray std(int... dimension)
dimension
- the dimension to getScalar the std alongNumber stdNumber()
IComplexNumber stdComplex()
INDArray prod(int... dimension)
dimension
- the dimension to getScalar the product alongNumber prodNumber()
IComplexNumber prodComplex()
INDArray mean(int... dimension)
dimension
- the dimension to getScalar the mean alongNumber meanNumber()
IComplexNumber meanComplex()
INDArray var(int... dimension)
dimension
- the dimension to getScalar the mean alongNumber varNumber()
IComplexNumber varComplex()
INDArray max(int... dimension)
dimension
- the dimension to getScalar the mean alongNumber maxNumber()
IComplexNumber maxComplex()
INDArray min(int... dimension)
dimension
- the dimension to getScalar the mean alongNumber minNumber()
IComplexNumber minComplex()
INDArray sum(int... dimension)
dimension
- the dimension to getScalar the sum alongNumber sumNumber()
IComplexNumber sumComplex()
void setStride(int... stride)
stride
- void setShape(int... shape)
shape
- void setOrder(char order)
order
- the ordering to setINDArray subArray(ShapeOffsetResolution resolution)
resolution
- the resolution to useINDArray subArray(int[] offsets, int[] shape, int[] stride)
offsets
- shape
- stride
- INDArray getScalar(int[] indices)
indices
- the indices to getScalarint getInt(int... indices)
indices
- double getDouble(int... indices)
indices
- float getFloat(int[] indices)
indices
- the indices to getScalardouble getDouble(int i)
i
- double getDouble(int i, int j)
i
- j
- float getFloat(int i)
i
- the index of the item to getScalarfloat getFloat(int i, int j)
i
- the row to getScalarj
- the column to getScalarINDArray dup()
INDArray dup(char order)
order
- Order of the NDArray. 'f' or 'c'INDArray ravel()
INDArray ravel(char order)
void setData(DataBuffer data)
data
- int slices()
int getTrailingOnes()
int getLeadingOnes()
INDArray slice(int i, int dimension)
i
- the index of the slice to returndimension
- the dimension to return the slice forINDArray slice(int i)
i
- the index of the slice to returnint offset()
INDArray reshape(char order, int... newShape)
newShape
- the new shape of the ndarrayINDArray reshape(char order, int rows, int columns)
rows
- the rows of the matrixcolumns
- the columns of the matrixINDArray reshape(int... newShape)
newShape
- the new shape of the ndarrayINDArray reshape(int rows, int columns)
rows
- the rows of the matrixcolumns
- the columns of the matrixINDArray transpose()
INDArray transposei()
INDArray swapAxes(int dimension, int with)
dimension
- the dimension to swapwith
- the one to swap it withINDArray permute(int... rearrange)
rearrange
- the dimensions to swap toINDArray dimShuffle(Object[] rearrange, int[] newOrder, boolean[] broadCastable)
rearrange
- the dimensions to swap tonewOrder
- the new order (think permute)broadCastable
- (whether the dimension is broadcastable) (must be same length as new order)INDArray getColumn(int i)
i
- the column to getScalarINDArray getRow(int i)
i
- the row to getScalarint columns()
int rows()
boolean isColumnVector()
boolean isRowVector()
boolean isVector()
boolean isSquare()
boolean isMatrix()
boolean isScalar()
int[] shape()
int[] stride()
char ordering()
int size(int dimension)
dimension
- the dimension to return the size forint length()
INDArray broadcast(int... shape)
shape
- the new shape of this ndarrayObject element()
DataBuffer data()
IComplexNDArray rdiv(IComplexNumber n)
n
- IComplexNDArray rdivi(IComplexNumber n)
n
- IComplexNDArray rsub(IComplexNumber n)
n
- IComplexNDArray rsubi(IComplexNumber n)
n
- IComplexNDArray div(IComplexNumber n)
n
- IComplexNDArray divi(IComplexNumber n)
n
- IComplexNDArray mul(IComplexNumber n)
n
- IComplexNDArray muli(IComplexNumber n)
n
- IComplexNDArray sub(IComplexNumber n)
n
- IComplexNDArray subi(IComplexNumber n)
n
- IComplexNDArray add(IComplexNumber n)
n
- IComplexNDArray addi(IComplexNumber n)
n
- IComplexNDArray rdiv(IComplexNumber n, IComplexNDArray result)
n
- result
- IComplexNDArray rdivi(IComplexNumber n, IComplexNDArray result)
n
- result
- IComplexNDArray rsub(IComplexNumber n, IComplexNDArray result)
n
- result
- IComplexNDArray rsubi(IComplexNumber n, IComplexNDArray result)
n
- result
- IComplexNDArray div(IComplexNumber n, IComplexNDArray result)
n
- result
- IComplexNDArray divi(IComplexNumber n, IComplexNDArray result)
n
- result
- IComplexNDArray mul(IComplexNumber n, IComplexNDArray result)
n
- result
- IComplexNDArray muli(IComplexNumber n, IComplexNDArray result)
n
- result
- IComplexNDArray sub(IComplexNumber n, IComplexNDArray result)
n
- result
- IComplexNDArray subi(IComplexNumber n, IComplexNDArray result)
n
- result
- IComplexNDArray add(IComplexNumber n, IComplexNDArray result)
n
- result
- IComplexNDArray addi(IComplexNumber n, IComplexNDArray result)
n
- result
- Copyright © 2015. All Rights Reserved.