Package | Description |
---|---|
org.apache.flink.ml.common.linalg | |
org.apache.flink.ml.common.statistics.basicstatistic | |
org.apache.flink.ml.common.utils |
Modifier and Type | Class and Description |
---|---|
class |
DenseVector
A dense vector represented by a values array.
|
class |
SparseVector
A sparse vector represented by an indices array and a values array.
|
Modifier and Type | Method and Description |
---|---|
abstract Vector |
Vector.append(double v)
Create a new vector by adding an element to the end of the vector.
|
Vector |
SparseVector.minus(Vector vec) |
abstract Vector |
Vector.minus(Vector vec)
Create a new vector by subtracting another vector.
|
static Vector |
MatVecOp.minus(Vector vec1,
Vector vec2)
compute vec1 - vec2 .
|
static Vector |
VectorUtil.parse(String str)
Parse either a
SparseVector or a DenseVector from a formatted string. |
Vector |
SparseVector.plus(Vector vec) |
abstract Vector |
Vector.plus(Vector vec)
Create a new vector by plussing another vector.
|
static Vector |
MatVecOp.plus(Vector vec1,
Vector vec2)
compute vec1 + vec2 .
|
abstract Vector |
Vector.prefix(double v)
Create a new vector by adding an element to the head of the vector.
|
abstract Vector |
Vector.scale(double v)
Scale the vector by value "v" and create a new vector to store the result.
|
abstract Vector |
Vector.slice(int[] indexes)
Slice the vector.
|
Modifier and Type | Method and Description |
---|---|
double |
SparseVector.dot(Vector other) |
abstract double |
Vector.dot(Vector vec)
Compute the dot product with another vector.
|
double |
DenseVector.dot(Vector vec) |
static double |
MatVecOp.dot(Vector vec1,
Vector vec2)
Compute vec1 \cdot vec2 .
|
Vector |
SparseVector.minus(Vector vec) |
abstract Vector |
Vector.minus(Vector vec)
Create a new vector by subtracting another vector.
|
DenseVector |
DenseVector.minus(Vector other) |
static Vector |
MatVecOp.minus(Vector vec1,
Vector vec2)
compute vec1 - vec2 .
|
void |
DenseVector.minusEqual(Vector other)
Minus with another vector.
|
Vector |
SparseVector.plus(Vector vec) |
abstract Vector |
Vector.plus(Vector vec)
Create a new vector by plussing another vector.
|
DenseVector |
DenseVector.plus(Vector other) |
static Vector |
MatVecOp.plus(Vector vec1,
Vector vec2)
compute vec1 + vec2 .
|
void |
DenseVector.plusEqual(Vector other)
Plus with another vector.
|
void |
DenseVector.plusScaleEqual(Vector other,
double alpha)
Plus with another vector scaled by "alpha".
|
static double |
MatVecOp.sumAbsDiff(Vector vec1,
Vector vec2)
Compute || vec1 - vec2 ||_1 .
|
static double |
MatVecOp.sumSquaredDiff(Vector vec1,
Vector vec2)
Compute || vec1 - vec2 ||_2^2 .
|
static String |
VectorUtil.toString(Vector vector)
Serialize the vector to a string.
|
Modifier and Type | Method and Description |
---|---|
double |
MultivariateGaussian.logpdf(Vector x)
Returns the log-density of this multivariate Gaussian at given point x .
|
double |
MultivariateGaussian.pdf(Vector x)
Returns density of this multivariate Gaussian at given point x .
|
Modifier and Type | Field and Description |
---|---|
static TypeInformation<Vector> |
VectorTypes.VECTOR
Vector type information. |
Copyright © 2014–2021 The Apache Software Foundation. All rights reserved.