Package elki.distance
Interface DBIDRangeDistance
-
- All Superinterfaces:
DBIDDistance
,Distance<DBID>
- All Known Implementing Classes:
AbstractDBIDRangeDistance
,DiskCacheBasedDoubleDistance
,DiskCacheBasedFloatDistance
,FileBasedSparseDoubleDistance
,FileBasedSparseFloatDistance
public interface DBIDRangeDistance extends DBIDDistance
Distance functions valid in a static database context only (i.e. for DBIDRanges) For any "distance" that cannot be computed for arbitrary objects, only those that exist in the database and referenced by their ID. Furthermore, the IDs must be contiguous. Example: external precomputed distances- Since:
- 0.7.0
- Author:
- Erich Schubert
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
checkRange(DBIDRange range)
Validate the range of DBIDs to use.double
distance(int i1, int i2)
Compute the distance for two integer offsets.-
Methods inherited from interface elki.distance.DBIDDistance
distance
-
Methods inherited from interface elki.distance.Distance
getInputTypeRestriction, instantiate, isMetric, isSquared, isSymmetric
-
-
-
-
Method Detail
-
distance
double distance(int i1, int i2)
Compute the distance for two integer offsets.- Parameters:
i1
- First offseti2
- Second offset- Returns:
- Distance
-
checkRange
void checkRange(DBIDRange range)
Validate the range of DBIDs to use. This will log a warning if an obvious mismatch was found.- Parameters:
range
- DBID range
-
-