public class ObjectVectorEMD extends ObjectDoubleVector
LocalAbstractObject.DataEqualObject, LocalAbstractObject.TextStreamFactory<T extends LocalAbstractObject>, LocalAbstractObject.TrivialDistanceFunction
data
counterDistanceComputations, counterLowerBoundDistanceComputations, counterPrecomputedDistanceSavings, counterUpperBoundDistanceComputations, MAX_DISTANCE, MIN_DISTANCE, suppData, trivialDistanceFunction, UNKNOWN_DISTANCE
Constructor and Description |
---|
ObjectVectorEMD(java.io.BufferedReader stream)
Creates a new instance of ObjectVectorEMD
|
ObjectVectorEMD(double[] vector)
Creates a new instance of ObjectVectorEMD
|
ObjectVectorEMD(int dimension,
double min,
double max)
Creates a new instance of ObjectVectorEMD
|
Modifier and Type | Method and Description |
---|---|
protected float |
getDistanceImpl(LocalAbstractObject obj,
float distThreshold)
The actual implementation of the metric function (see
LocalAbstractObject.getDistance(messif.objects.LocalAbstractObject) for full explanation). |
binarySerialize, cloneRandomlyModify, dataEquals, dataHashCode, getBinarySize, getDimensionality, getMinMaxForEveryCoord, getMinMaxOverCoords, getMinMaxOverCoords, getSize, getVectorData, getVectorDataDimension, getVectorDataItem, getVectorDataItemDouble, parseDoubleVector, randomData, toString, translateToUnitCube, translateToUnitCube, writeData, writeDoubleVector
clearSurplusData, clone, clone, create, create, createMetaDistancesHolder, excludeUsingPrecompDist, getDistance, getDistance, getDistance, getDistanceFilter, getDistanceFilter, getDistanceFilter, getDistanceFilter, getDistanceLowerBound, getDistanceLowerBoundImpl, getDistanceStorePrecomputed, getDistanceStorePrecomputed, getDistanceStorePrecomputed, getDistanceUpperBound, getDistanceUpperBoundImpl, getFieldsForNames, getMaxDistance, getNormDistance, getPrecomputedDistance, getPrecomputedDistance, getRandomChar, getRandomNormal, chainDestroy, chainFilter, includeUsingPrecompDist, isDistanceCompatible, parseObjectComment, peekNextChar, readAttributesFromStream, readObjectComments, readObjectCommentsWithoutData, unchainFilter, write, write, writeAttributesToStream, writeObjectComment
clone, getLocatorURI, getNoDataObject, getObjectKey, getObjectKey, getObjectLocatorURI, setObjectKey
public ObjectVectorEMD(double[] vector)
vector
- data for vectorpublic ObjectVectorEMD(int dimension, double min, double max)
dimension
- data for vectormin
- lower bound of the random generated values (inclusive)max
- upper bound of the random generated values (exclusive)public ObjectVectorEMD(java.io.BufferedReader stream) throws java.io.IOException, java.lang.NumberFormatException
stream
- vector with data for vectorjava.io.IOException
- when an error appears during reading from given stream.java.lang.NumberFormatException
- when the line read from given stream does not consist of comma-separated or space-separated numbers.protected float getDistanceImpl(LocalAbstractObject obj, float distThreshold)
LocalAbstractObject
LocalAbstractObject.getDistance(messif.objects.LocalAbstractObject)
for full explanation).
The implementation should not increment distanceComputations statistics.getDistanceImpl
in class LocalAbstractObject
obj
- the object to compute distance todistThreshold
- the threshold value on the distance