public static class MetaObjectCophirKeywords.MetaObjectCophirKeywordsDistCosine extends MetaObjectCophirKeywords
MetaObjectCophirKeywords
.MetaObjectCophirKeywords.CophirWeightedCosineDistanceFunction, MetaObjectCophirKeywords.MetaObjectCophirKeywordsDistCosine, MetaObjectCophirKeywords.MetaObjectCophirKeywordsWithTKStrings
LocalAbstractObject.DataEqualObject, LocalAbstractObject.TextStreamFactory<T extends LocalAbstractObject>, LocalAbstractObject.TrivialDistanceFunction
keywordStrings
objects
counterDistanceComputations, counterLowerBoundDistanceComputations, counterPrecomputedDistanceSavings, counterUpperBoundDistanceComputations, MAX_DISTANCE, MIN_DISTANCE, suppData, trivialDistanceFunction, UNKNOWN_DISTANCE
Constructor and Description |
---|
MetaObjectCophirKeywords.MetaObjectCophirKeywordsDistCosine(MetaObjectCophirKeywords object,
java.lang.Float keywordsWeight,
ObjectIntMultiVector.WeightProvider kwWeightProvider)
Creates a new instance of MetaObjectCophirKeywordsDistCosine from the given
MetaObjectCophirKeywords . |
Modifier and Type | Method and Description |
---|---|
protected float |
getDistanceImpl(LocalAbstractObject obj,
float[] metaDistances,
float distThreshold)
The actual implementation of the metric function.
|
getDescriptorNames, getKeywordsObject, getMaxDistance, getObjectName, getStringData, getStringData, getStringDataFields, getWeight, getWeights, wrapWithKwStringSerialization, wrapWithTitleOnlySerialization, writeData
binarySerialize, createClassArray, getBinarySize, getObject, getObject, getObjectCount, getObjectMap, getObjectNames, getObjects, readObjects
clearSurplusData, containsObject, createMetaDistancesHolder, createSearchMetaObject, dataEquals, dataHashCode, fillMetaDistances, fillMetaDistances, getDistanceImpl, getObjectFromMap, getSize, implementationGetDistance, readObject, readObject, readObjects, readObjects, readObjectsHeader, toString, writeObjects, writeObjectsHeader
clone, clone, cloneRandomlyModify, create, create, excludeUsingPrecompDist, getDistance, getDistance, getDistance, getDistanceFilter, getDistanceFilter, getDistanceFilter, getDistanceFilter, getDistanceLowerBound, getDistanceLowerBoundImpl, getDistanceStorePrecomputed, getDistanceStorePrecomputed, getDistanceStorePrecomputed, getDistanceUpperBound, getDistanceUpperBoundImpl, getFieldsForNames, 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 MetaObjectCophirKeywords.MetaObjectCophirKeywordsDistCosine(MetaObjectCophirKeywords object, java.lang.Float keywordsWeight, ObjectIntMultiVector.WeightProvider kwWeightProvider)
MetaObjectCophirKeywords
.
The locator and the encapsulated objects from the source object
are
taken.object
- the source metaobject from which to get the datakeywordsWeight
- the weight for combining the keywords distance with the visual descriptors distance,
if null, only the text distance is usedkwWeightProvider
- the weight provider for different layers of keywords (title, etc.)protected float getDistanceImpl(LocalAbstractObject obj, float[] metaDistances, float distThreshold)
MetaObjectArray
obj
.
The array metaDistances
is ignored.getDistanceImpl
in class MetaObjectArrayWeightedSum
obj
- the object to compute distance tometaDistances
- the array that is filled with the distances of the respective encapsulated objects, if it is not nulldistThreshold
- the threshold value on the distanceLocalAbstractObject.getDistance