40 return CLinearARDKernel::init(l,r);
43 void CGaussianARDKernel::init()
58 SG_SERROR(
"Provided kernel is not of type CGaussianARDKernel!\n");
76 "features must be the same\n");
91 if (!strcmp(param->
m_name,
"weights"))
105 "features must be the same\n");
111 derivative(j,k)=-2*element*product;
117 else if (!strcmp(param->
m_name,
"width"))
131 "features must be the same\n");
147 SG_ERROR(
"Can't compute derivative wrt %s parameter\n", param->
m_name);
virtual SGMatrix< float64_t > get_parameter_gradient(const TParameter *param, index_t index=-1)
int32_t num_rhs
number of feature vectors on right hand side
Linear Kernel with Automatic Relevance Detection.
static CGaussianARDKernel * obtain_from_generic(CKernel *kernel)
float64_t kernel(int32_t idx_a, int32_t idx_b)
virtual float64_t compute(int32_t idx_a, int32_t idx_b)
SGMatrix< float64_t > get_kernel_matrix()
Gaussian Kernel with Automatic Relevance Detection.
SGVector< float64_t > m_weights
int32_t num_lhs
number of feature vectors on left hand side
virtual ~CGaussianARDKernel()
CFeatures * rhs
feature vectors to occur on right hand side
all of classes and functions are contained in the shogun namespace
virtual EKernelType get_kernel_type()=0
CFeatures * lhs
feature vectors to occur on left hand side
The class Features is the base class of all feature objects.
static float64_t exp(float64_t x)
virtual bool init(CFeatures *l, CFeatures *r)
static int32_t pow(bool x, int32_t n)