public static class AbstractRandomProjectionFamily.MatrixProjection extends java.lang.Object implements RandomProjectionFamily.Projection
| Modifier and Type | Field and Description |
|---|---|
private double[] |
buf
Shared buffer to use during projections.
|
(package private) double[][] |
matrix
Projection matrix.
|
| Constructor and Description |
|---|
MatrixProjection(double[][] matrix)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
int |
getOutputDimensionality()
Get the output dimensionality.
|
double[] |
project(NumberVector in)
Project a single vector.
|
double[] |
project(NumberVector in,
double[] ret)
Project a single vector, into the given buffer.
|
private double[] |
projectSparse(SparseNumberVector in,
double[] ret)
Project, exploiting sparsity; but the transposed matrix layout would have
been better.
|
double[][] matrix
private double[] buf
public MatrixProjection(double[][] matrix)
matrix - Projection matrix ([output dim][input dim]).public double[] project(NumberVector in)
RandomProjectionFamily.Projectionproject in interface RandomProjectionFamily.Projectionin - Input vectorpublic double[] project(NumberVector in, double[] ret)
RandomProjectionFamily.Projectionproject in interface RandomProjectionFamily.Projectionin - Input vectorret - Output bufferbufferprivate double[] projectSparse(SparseNumberVector in, double[] ret)
in - Input vectorret - Projection bufferpublic int getOutputDimensionality()
RandomProjectionFamily.ProjectiongetOutputDimensionality in interface RandomProjectionFamily.ProjectionCopyright © 2019 ELKI Development Team. License information.