#include <kernel.h>
Inheritance diagram for Perceptron:
Public Member Functions | |
Perceptron () | |
Perceptron (std::istream &is) | |
virtual const id_t & | id () const |
virtual Perceptron * | create () const |
Create a new object using the default constructor. | |
virtual Perceptron * | clone () const |
Create a new object by replicating itself. | |
virtual REAL | operator() (const Input &a, const Input &b) const |
The inner-product of two input vectors. | |
virtual void | set_data (const pDataSet &pd) |
Store a dataset in order to compute the kernel matrix. | |
virtual REAL | matrix (UINT i, UINT j) const |
The inner-product of two stored inputs with index i and j. | |
virtual void | set_params (SVM_detail *) const |
Protected Attributes | |
std::vector< REAL > | x_norm2 |
cached inner-product of data input |
Definition at line 121 of file kernel.h.
|
|
|
|
|
Create a new object by replicating itself.
return new Derived(*this);
Implements Kernel. Reimplemented in RBF. Definition at line 131 of file kernel.h. References Perceptron::Perceptron(). |
|
Create a new object using the default constructor. The code for a derived class Derived is always return new Derived(); Implements Kernel. Reimplemented in RBF. Definition at line 130 of file kernel.h. References Perceptron::Perceptron(). |
|
Implements Object. Reimplemented in RBF. |
|
The inner-product of two stored inputs with index i and j.
Reimplemented from Kernel. Reimplemented in RBF. Definition at line 144 of file kernel.h. References DOTPROD, and LearnModel::ptd. |
|
The inner-product of two input vectors.
Implements Kernel. Reimplemented in RBF. Definition at line 133 of file kernel.h. References lemga::kernel::norm_2(). |
|
Store a dataset in order to compute the kernel matrix.
Reimplemented from Kernel. Definition at line 137 of file kernel.h. References DOTPROD, and LearnModel::ptd. |
|
In order to keep the SVM interface simple and avoid member functions specific to kernels (e.g., set_gamma()), we use Kernel to pass kernel parameters to SVM_detail. Implements Kernel. Reimplemented in RBF. |
|
cached inner-product of data input
|