O
- Data type@Alias(value="fastmds") public class FastMultidimensionalScalingTransform<O> extends Object implements ObjectFilter
Modifier and Type | Class and Description |
---|---|
static class |
FastMultidimensionalScalingTransform.Parameterizer<O extends NumberVector>
Parameterization class.
|
Modifier and Type | Field and Description |
---|---|
(package private) PrimitiveDistanceFunction<? super O> |
dist
Distance function to use.
|
private static Logging |
LOG
Class logger.
|
(package private) int |
tdim
Target dimensionality
|
Constructor and Description |
---|
FastMultidimensionalScalingTransform(int tdim,
PrimitiveDistanceFunction<? super O> dist)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
protected double[][] |
computeDistanceMatrix(List<O> col)
Compute the distance matrix of a vector column.
|
protected double |
estimateEigenvalue(double[][] mat,
double[] in)
Estimate the (singed!)
|
MultipleObjectsBundle |
filter(MultipleObjectsBundle objects)
Filter a set of object packages.
|
protected void |
findEigenVectors(double[][] imat,
double[][] evs,
double[] lambda)
Find the first eigenvectors and eigenvalues using power iterations.
|
protected double |
multiply(double[][] mat,
double[] in,
double[] out)
Compute out = A * in, and return the (signed!)
|
protected void |
randomInitialization(double[] out,
Random rnd)
Choose a random vector of unit norm for power iterations.
|
protected double |
updateEigenvector(double[] in,
double[] out,
double l)
Compute the change in the eigenvector, and normalize the output vector
while doing so.
|
protected void |
updateMatrix(double[][] mat,
double[] evec,
double eval)
Update matrix, by removing the effects of a known Eigenvector.
|
private static final Logging LOG
PrimitiveDistanceFunction<? super O> dist
int tdim
public FastMultidimensionalScalingTransform(int tdim, PrimitiveDistanceFunction<? super O> dist)
tdim
- Target dimensionality.dist
- Distance function to use.public MultipleObjectsBundle filter(MultipleObjectsBundle objects)
ObjectFilter
filter
in interface ObjectFilter
objects
- Object to filterprotected double[][] computeDistanceMatrix(List<O> col)
col
- Columnprotected void findEigenVectors(double[][] imat, double[][] evs, double[] lambda)
imat
- Matrix (will be modified!)evs
- Eigenvectors outputlambda
- Eigenvalues outputprotected void randomInitialization(double[] out, Random rnd)
out
- Output storagernd
- Random source.protected double multiply(double[][] mat, double[] in, double[] out)
mat
- Matrix.in
- Input vector.out
- Output vector storage.protected double updateEigenvector(double[] in, double[] out, double l)
in
- Input vectorout
- Output vectorl
- Eigenvalueprotected double estimateEigenvalue(double[][] mat, double[] in)
mat
- Matrix.in
- Input vector.protected void updateMatrix(double[][] mat, double[] evec, double eval)
mat
- Matrixevec
- Known normalized Eigenvectoreval
- EigenvalueCopyright © 2015 ELKI Development Team, Lehr- und Forschungseinheit für Datenbanksysteme, Ludwig-Maximilians-Universität München. License information.