public class SimHashNearestNeighbor
extends com.exalead.gni.GNINativeObject
Constructor and Description |
---|
SimHashNearestNeighbor(int maxSize,
int maxGen)
Public Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
addEntry(long id,
long fp,
int nbToken)
Add an entry in the repository.
|
void |
clear()
Clear.
|
SimHashEntry |
firstMatch(long fp,
int nbToken,
int maxDist,
long id)
Find the first SimHashEntry at a distance less than maxDist.
|
SimHashEntry[] |
matchAll(long fp,
int nbToken,
int maxDist)
Find all SimHashEntries at a distance less than maxDist
|
public SimHashNearestNeighbor(int maxSize, int maxGen)
maxSize
- Maximum numbers of entries per generation.maxGen
- Maximum number of generation to keep.public void clear()
public void addEntry(long id, long fp, int nbToken)
id
- Template identifier.fp
- the simhash value.nbToken
- the number of tokens used to compute the simhash value.public SimHashEntry firstMatch(long fp, int nbToken, int maxDist, long id)
fp
- The sim hash value.nbToken
- The number of tokens used to compute the simhash value.maxDist
- The maximum distance in bits.public SimHashEntry[] matchAll(long fp, int nbToken, int maxDist)
fp
- the sim hash value.nbToken
- the number of tokens used to compute the simhash value.maxDist
- The maximum distance in bits.Copyright © 2013 Dassault Systèmes, All Rights Reserved.