public class Linear extends Object implements Kernel
Constructor and Description |
---|
Linear()
A linear kernel, u.dot(v).
|
Modifier and Type | Method and Description |
---|---|
com.oracle.labs.mlrg.olcut.provenance.ConfiguredObjectProvenance |
getProvenance() |
double |
similarity(SparseVector a,
SparseVector b)
Calculates the similarity between two
SparseVector s. |
String |
toString() |
public double similarity(SparseVector a, SparseVector b)
Kernel
SparseVector
s.similarity
in interface Kernel
a
- The first SparseVector.b
- The second SparseVector.public com.oracle.labs.mlrg.olcut.provenance.ConfiguredObjectProvenance getProvenance()
getProvenance
in interface com.oracle.labs.mlrg.olcut.provenance.Provenancable<com.oracle.labs.mlrg.olcut.provenance.ConfiguredObjectProvenance>
Copyright © 2015–2021 Oracle and/or its affiliates. All rights reserved.