Class CachedDoubleDistanceKNNPreprocessor<O>

  • Type Parameters:
    O - Object type
    All Implemented Interfaces:
    elki.index.Index, elki.index.KNNIndex<O>

    public class CachedDoubleDistanceKNNPreprocessor<O>
    extends elki.index.preprocessed.knn.AbstractMaterializeKNNPreprocessor<O>
    Preprocessor that loads an existing cached kNN result.
    Since:
    0.6.0
    Author:
    Erich Schubert
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.nio.file.Path filename
      File to load.
      private static elki.logging.Logging LOG
      Class logger.
      • Fields inherited from class elki.index.preprocessed.knn.AbstractMaterializeKNNPreprocessor

        distance, distanceQuery, k, relation, storage
    • Constructor Summary

      Constructors 
      Constructor Description
      CachedDoubleDistanceKNNPreprocessor​(elki.database.relation.Relation<O> relation, elki.distance.Distance<? super O> distance, int k, java.nio.file.Path file)
      Constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected elki.logging.Logging getLogger()  
      protected void preprocess()  
      • Methods inherited from class elki.index.preprocessed.knn.AbstractMaterializeKNNPreprocessor

        createStorage, get, getDistanceQuery, getK, initialize, kNNByDBID, kNNByObject
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface elki.index.Index

        logStatistics
    • Field Detail

      • filename

        private java.nio.file.Path filename
        File to load.
      • LOG

        private static final elki.logging.Logging LOG
        Class logger.
    • Constructor Detail

      • CachedDoubleDistanceKNNPreprocessor

        public CachedDoubleDistanceKNNPreprocessor​(elki.database.relation.Relation<O> relation,
                                                   elki.distance.Distance<? super O> distance,
                                                   int k,
                                                   java.nio.file.Path file)
        Constructor.
        Parameters:
        relation - Relation to index
        distance - Distance function
        k - K
        file - File to load
    • Method Detail

      • preprocess

        protected void preprocess()
        Specified by:
        preprocess in class elki.index.preprocessed.knn.AbstractMaterializeKNNPreprocessor<O>
      • getLogger

        protected elki.logging.Logging getLogger()
        Specified by:
        getLogger in class elki.index.preprocessed.knn.AbstractMaterializeKNNPreprocessor<O>