O
- object typepublic class SharedNearestNeighborSimilarityFunction<O> extends AbstractIndexBasedSimilarityFunction<O,SharedNearestNeighborIndex.Factory<O>>
Modifier and Type | Class and Description |
---|---|
static class |
SharedNearestNeighborSimilarityFunction.Instance<O>
Instance for a particular database.
|
static class |
SharedNearestNeighborSimilarityFunction.Parameterizer<O>
Parameterization class.
|
indexFactory
Constructor and Description |
---|
SharedNearestNeighborSimilarityFunction(SharedNearestNeighborIndex.Factory<O> indexFactory)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
protected static int |
countSharedNeighbors(DBIDs neighbors1,
DBIDs neighbors2)
Compute the intersection size
|
<T extends O> |
instantiate(Relation<T> database)
Preprocess the database to get the actual distance function.
|
getInputTypeRestriction, isSymmetric
public SharedNearestNeighborSimilarityFunction(SharedNearestNeighborIndex.Factory<O> indexFactory)
indexFactory
- Index factory.protected static int countSharedNeighbors(DBIDs neighbors1, DBIDs neighbors2)
neighbors1
- SORTED neighbors of firstneighbors2
- SORTED neighbors of secondpublic <T extends O> SharedNearestNeighborSimilarityFunction.Instance<T> instantiate(Relation<T> database)
IndexBasedSimilarityFunction
instantiate
in interface IndexBasedSimilarityFunction<O>
instantiate
in interface SimilarityFunction<O>
instantiate
in class AbstractIndexBasedSimilarityFunction<O,SharedNearestNeighborIndex.Factory<O>>
database
- Representation to useCopyright © 2019 ELKI Development Team. License information.