Environment for
DeveLoping
KDD-Applications
Supported by Index-Structures

de.lmu.ifi.dbs.elki.distance.distancefunction
Class AbstractLocallyWeightedDistanceFunction<O extends NumberVector<O,?>,P extends LocalPCAPreprocessor<O>>

java.lang.Object
  extended by de.lmu.ifi.dbs.elki.logging.AbstractLoggable
      extended by de.lmu.ifi.dbs.elki.distance.AbstractMeasurementFunction<O,D>
          extended by de.lmu.ifi.dbs.elki.distance.distancefunction.AbstractDistanceFunction<O,DoubleDistance>
              extended by de.lmu.ifi.dbs.elki.distance.distancefunction.AbstractLocallyWeightedDistanceFunction<O,P>
Type Parameters:
O - the type of DatabaseObject to compute the distances in between
P - preprocessor type
All Implemented Interfaces:
DistanceFunction<O,DoubleDistance>, LocalPCAPreprocessorBasedDistanceFunction<O,P,DoubleDistance>, PreprocessorBasedDistanceFunction<O,P,DoubleDistance>, MeasurementFunction<O,DoubleDistance>, PreprocessorBasedMeasurementFunction<O,P,DoubleDistance>, PreprocessorClient<P,O>, Parameterizable
Direct Known Subclasses:
KernelBasedLocallyWeightedDistanceFunction, LocallyWeightedDistanceFunction

public abstract class AbstractLocallyWeightedDistanceFunction<O extends NumberVector<O,?>,P extends LocalPCAPreprocessor<O>>
extends AbstractDistanceFunction<O,DoubleDistance>
implements PreprocessorClient<P,O>, LocalPCAPreprocessorBasedDistanceFunction<O,P,DoubleDistance>

Abstract super class for locally weighted distance functions using a preprocessor to compute the local weight matrix.

Author:
Elke Achtert

Field Summary
private  PreprocessorHandler<O,P> preprocessorHandler
          The handler class for the preprocessor.
 
Fields inherited from class de.lmu.ifi.dbs.elki.distance.AbstractMeasurementFunction
distanceFactory
 
Fields inherited from class de.lmu.ifi.dbs.elki.logging.AbstractLoggable
debug, logger
 
Constructor Summary
protected AbstractLocallyWeightedDistanceFunction(Parameterization config)
          Provides an abstract locally weighted distance function.
 
Method Summary
 Class<?> getDefaultPreprocessorClass()
          Returns the name of the default preprocessor.
 String getPreprocessorDescription()
          Returns the description for the preprocessor parameter.
 Class<P> getPreprocessorSuperClass()
          Returns the super class for the preprocessor parameter.
 void setDatabase(Database<O> database)
          Set the database that holds the associations for the DatabaseObject for which the measurements should be computed.
 
Methods inherited from class de.lmu.ifi.dbs.elki.distance.distancefunction.AbstractDistanceFunction
distance, distance
 
Methods inherited from class de.lmu.ifi.dbs.elki.distance.AbstractMeasurementFunction
getDatabase, getDistanceFactory, infiniteDistance, nullDistance, undefinedDistance, valueOf
 
Methods inherited from class de.lmu.ifi.dbs.elki.logging.AbstractLoggable
debugFine, debugFiner, debugFinest, exception, progress, verbose, warning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface de.lmu.ifi.dbs.elki.preprocessing.PreprocessorClient
getAssociationID
 
Methods inherited from interface de.lmu.ifi.dbs.elki.distance.distancefunction.DistanceFunction
distance, distance, distance
 
Methods inherited from interface de.lmu.ifi.dbs.elki.distance.MeasurementFunction
getDistanceFactory, infiniteDistance, nullDistance, undefinedDistance, valueOf
 

Field Detail

preprocessorHandler

private PreprocessorHandler<O extends NumberVector<O,?>,P extends LocalPCAPreprocessor<O>> preprocessorHandler
The handler class for the preprocessor.

Constructor Detail

AbstractLocallyWeightedDistanceFunction

protected AbstractLocallyWeightedDistanceFunction(Parameterization config)
Provides an abstract locally weighted distance function.

Method Detail

setDatabase

public void setDatabase(Database<O> database)
Description copied from interface: MeasurementFunction
Set the database that holds the associations for the DatabaseObject for which the measurements should be computed.

Specified by:
setDatabase in interface MeasurementFunction<O extends NumberVector<O,?>,DoubleDistance>
Overrides:
setDatabase in class AbstractMeasurementFunction<O extends NumberVector<O,?>,DoubleDistance>
Parameters:
database - Database

getDefaultPreprocessorClass

public Class<?> getDefaultPreprocessorClass()
Description copied from interface: PreprocessorClient
Returns the name of the default preprocessor.

Specified by:
getDefaultPreprocessorClass in interface PreprocessorClient<P extends LocalPCAPreprocessor<O>,O extends NumberVector<O,?>>
Returns:
the name of the default preprocessor, which is KnnQueryBasedLocalPCAPreprocessor

getPreprocessorDescription

public String getPreprocessorDescription()
Description copied from interface: PreprocessorClient
Returns the description for the preprocessor parameter.

Specified by:
getPreprocessorDescription in interface PreprocessorClient<P extends LocalPCAPreprocessor<O>,O extends NumberVector<O,?>>
Returns:
the description for the preprocessor parameter

getPreprocessorSuperClass

public Class<P> getPreprocessorSuperClass()
Description copied from interface: PreprocessorClient
Returns the super class for the preprocessor parameter.

Specified by:
getPreprocessorSuperClass in interface PreprocessorClient<P extends LocalPCAPreprocessor<O>,O extends NumberVector<O,?>>
Returns:
the super class for the preprocessor, which is Preprocessor

Release 0.3 (2010-03-31_1612)