public class ImmutableVector extends AVector
| Modifier and Type | Method and Description |
|---|---|
void |
addAt(int i,
double v)
Adds a value to a specific element of the vector
This function does not perform bounds checking
|
void |
addMultipleToArray(double factor,
int offset,
double[] array,
int arrayOffset,
int length) |
void |
addToArray(double[] array,
int offset)
Adds this vector to a double[] array, starting at the specified offset.
|
void |
addToArray(int offset,
double[] array,
int arrayOffset,
int length) |
Vector |
clone()
Clones the vector, creating a new mutable copy of all data.
|
void |
copyTo(int offset,
double[] dest,
int destOffset,
int length) |
static ImmutableVector |
create(AVector v) |
void |
divideTo(double[] data,
int offset) |
double |
dotProduct(AVector v) |
double |
dotProduct(double[] data,
int offset)
Fast dot product with a double[] array.
|
boolean |
equals(AVector v) |
boolean |
equalsArray(double[] data)
Returns true if this vector exactly matches a double[] array.
|
boolean |
equalsArray(double[] data,
int offset)
Returns true if this vector exactly matches the elements in double[] array, starting
from the specified offset
|
AVector |
exactClone()
Returns an exact clone of this vector, i.e.
|
double |
get(int i)
Returns the double value at the specified position in a 1D vector
|
void |
getElements(double[] data,
int offset)
Gets all elements of the array, copying them into a double array
|
int |
hashCode()
Computes the hashcode of a vector.
|
AVector |
immutable()
Creates an immutable copy of a vector
|
boolean |
isFullyMutable()
Returns true if this vector is fully mutable, i.e.
|
boolean |
isMutable()
Returns true if this vector is mutable.
|
boolean |
isView()
Returns true if this vector is of a view type that references other vectors / data.
|
boolean |
isZero()
Returns true if this vector is a zero vector (all components zero)
|
Iterator<Double> |
iterator() |
int |
length() |
double |
magnitudeSquared() |
void |
multiplyTo(double[] data,
int offset) |
void |
set(int i,
double value) |
AVector |
subVector(int start,
int length)
Obtains a sub-vector that refers to this vector.
|
void |
toDoubleBuffer(DoubleBuffer dest)
Copies the elements of this INDArray to the specified double buffer
|
double |
unsafeGet(int i) |
void |
unsafeSet(int i,
double value) |
void |
validate()
Validates the internal data structure of the INDArray.
|
abs, add, add, add, add, add, add, addMultiple, addMultiple, addMultiple, addMultiple, addMultiple, addMultiple, addMultiple, addMultiple, addProduct, addProduct, addProduct, addProductToArray, addProductToArray, addWeighted, angle, applyOp, applyOp, asDoubleArray, asElementList, asVector, broadcast, broadcastLike, broadcastLike, clamp, clampMax, clampMin, compareTo, copyTo, copyTo, copyTo, copyTo, copyTo, crossProduct, dimensionality, distance, distanceL1, distanceLinf, distanceSquared, divide, divide, divide, divide, dotProduct, dotProduct, elementCount, elementIterator, elementSquaredSum, elementSum, epsilonEquals, epsilonEquals, epsilonEquals, epsilonEquals, equals, equals, fill, fillRange, get, get, get, getLongShape, getShape, getShape, getSlices, getTranspose, getTransposeCopy, getTransposeView, innerProduct, innerProduct, innerProduct, innerProduct, innerProduct, interpolate, interpolate, isElementConstrained, isSameShape, isSameShape, isUnitLengthVector, join, log, logistic, magnitude, maxAbsElement, multiply, multiply, multiply, multiply, mutable, negate, nonZeroCount, normalise, normaliseMaxAbsElement, outerProduct, outerProduct, pow, projectToPlane, reshape, scale, scaleAdd, scaleAdd, scaleToMagnitude, set, set, set, set, set, set, set, set, set, setElements, setElements, setRange, setValues, signum, slice, slice, sliceCount, square, sub, sub, sub, subMultiple, tanh, toDoubleArray, toList, toNormal, toString, toVector, zeroCountbroadcastCloneLike, ensureMutable, exp, get, getSliceViews, isBoolean, reciprocal, scale, set, set, sqrt, toArrayfinalize, getClass, notify, notifyAll, wait, wait, waitbroadcastCloneLike, ensureMutable, exp, get, getSliceViews, isBoolean, reciprocal, scale, set, set, sqrt, toArraypublic static ImmutableVector create(AVector v)
public boolean isMutable()
AVectorpublic boolean isFullyMutable()
AVectorisFullyMutable in interface INDArrayisFullyMutable in class AVectorpublic boolean isView()
AVectorpublic boolean isZero()
AVectorpublic AVector subVector(int start, int length)
AVectorpublic void toDoubleBuffer(DoubleBuffer dest)
INDArraytoDoubleBuffer in interface INDArraytoDoubleBuffer in class AVectorpublic void getElements(double[] data,
int offset)
INDArraygetElements in interface INDArraygetElements in class AVectorpublic void copyTo(int offset,
double[] dest,
int destOffset,
int length)
public void multiplyTo(double[] data,
int offset)
multiplyTo in class AVectorpublic void addToArray(double[] array,
int offset)
AVectoraddToArray in class AVectorpublic void addToArray(int offset,
double[] array,
int arrayOffset,
int length)
addToArray in class AVectorpublic void addMultipleToArray(double factor,
int offset,
double[] array,
int arrayOffset,
int length)
addMultipleToArray in class AVectorpublic double dotProduct(double[] data,
int offset)
AVectordotProduct in class AVectorpublic double dotProduct(AVector v)
dotProduct in class AVectorpublic double magnitudeSquared()
magnitudeSquared in class AVectorpublic double get(int i)
INDArraypublic void set(int i,
double value)
public void addAt(int i,
double v)
AVectorpublic int length()
public int hashCode()
AVectorpublic boolean equalsArray(double[] data,
int offset)
AVectorequalsArray in class AVectorpublic boolean equalsArray(double[] data)
AVectorequalsArray in class AVectorpublic Vector clone()
AVectorpublic AVector exactClone()
AVectorexactClone in interface INDArrayexactClone in class AVectorpublic AVector immutable()
AVectorpublic void validate()
INDArrayCopyright © 2013. All Rights Reserved.