de.lmu.ifi.dbs.elki.distance.similarityfunction.kernel
Class FooKernelFunction<O extends FeatureVector>
java.lang.Object
de.lmu.ifi.dbs.elki.logging.AbstractLoggable
de.lmu.ifi.dbs.elki.utilities.optionhandling.AbstractParameterizable
de.lmu.ifi.dbs.elki.distance.AbstractMeasurementFunction<O,D>
de.lmu.ifi.dbs.elki.distance.distancefunction.AbstractDistanceFunction<O,D>
de.lmu.ifi.dbs.elki.distance.similarityfunction.kernel.AbstractKernelFunction<O,DoubleDistance>
de.lmu.ifi.dbs.elki.distance.similarityfunction.kernel.AbstractDoubleKernelFunction<O>
de.lmu.ifi.dbs.elki.distance.similarityfunction.kernel.FooKernelFunction<O>
- All Implemented Interfaces:
- DistanceFunction<O,DoubleDistance>, MeasurementFunction<O,DoubleDistance>, KernelFunction<O,DoubleDistance>, SimilarityFunction<O,DoubleDistance>, Loggable, Parameterizable
public class FooKernelFunction<O extends FeatureVector>
- extends AbstractDoubleKernelFunction<O>
Provides an experimental KernelDistanceFunction for RealVectors.
Currently only supports 2D data and x1^2 ~ x2 correlations.
- Author:
- Simon Paradies
Constructor Summary |
FooKernelFunction()
Provides a polynomial Kernel function that computes
a similarity between the two vectors V1 and V2 definded by (V1^T*V2)^max_degree |
Methods inherited from class de.lmu.ifi.dbs.elki.utilities.optionhandling.AbstractParameterizable |
addOption, checkGlobalParameterConstraints, deleteOption, description, description, getAttributeSettings, getParameters, getParameterValue, getPossibleOptions, inlineDescription, isSet, setParameters |
Methods inherited from class de.lmu.ifi.dbs.elki.logging.AbstractLoggable |
debugFine, debugFiner, debugFinest, exception, message, progress, progress, progress, verbose, verbose, warning |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DEFAULT_MAX_DEGREE
public static final int DEFAULT_MAX_DEGREE
- The default max_degree.
- See Also:
- Constant Field Values
MAX_DEGREE_D
public static final String MAX_DEGREE_D
- Description for parameter max_degree.
MAX_DEGREE_P
public static final String MAX_DEGREE_P
- Parameter for max_degree.
- See Also:
- Constant Field Values
max_degree
private int max_degree
- Degree of the polynomial kernel function
FooKernelFunction
public FooKernelFunction()
- Provides a polynomial Kernel function that computes
a similarity between the two vectors V1 and V2 definded by (V1^T*V2)^max_degree
description
public String description()
- Description copied from interface:
Parameterizable
- Returns a description of the class and the required parameters.
This description should be suitable for a usage description as for a standalone application.
- Specified by:
description
in interface Parameterizable
- Overrides:
description
in class AbstractParameterizable
- Returns:
- String a description of the class and the required parameters
- See Also:
Parameterizable.description()
setParameters
public String[] setParameters(String[] args)
throws ParameterException
- Description copied from interface:
Parameterizable
- Sets the attributes of the class accordingly to the given parameters.
Returns a new String array containing those entries of the
given array that are neither expected nor used by this
Parameterizable.
- Specified by:
setParameters
in interface Parameterizable
- Overrides:
setParameters
in class AbstractParameterizable
- Parameters:
args
- parameters to set the attributes accordingly to
- Returns:
- String[] an array containing the unused parameters
- Throws:
ParameterException
- See Also:
Parameterizable.setParameters(String[])
similarity
public DoubleDistance similarity(O o1,
O o2)
- Provides an experimental kernel similarity between the given two vectors.
- Parameters:
o1
- first vectoro2
- second vector
- Returns:
- the experimental kernel similarity between the given two vectors as an
instance of
DoubleDistance
. - See Also:
DistanceFunction.distance(de.lmu.ifi.dbs.elki.data.DatabaseObject, de.lmu.ifi.dbs.elki.data.DatabaseObject)