公有成员 | 保护成员 | 保护属性

CChi2Kernel类参考


详细描述

The Chi2 kernel operating on realvalued vectors computes the chi-squared distance between sets of histograms.

It is a very useful distance in image recognition (used to detect objects).

It is defined as

\[ k({\bf x},({\bf x'})= e^{-\frac{1}{width} \sum_{i=0}^{l}\frac{(x_i-x'_i)^2}{(x_i+x'_i)}} \]

在文件Chi2Kernel.h32行定义。

继承图,类CChi2Kernel
Inheritance graph
[图例]

所有成员的列表。

公有成员

 CChi2Kernel (int32_t size, float64_t width)
 CChi2Kernel (CSimpleFeatures< float64_t > *l, CSimpleFeatures< float64_t > *r, float64_t width, int32_t size)
virtual ~CChi2Kernel ()
virtual bool init (CFeatures *l, CFeatures *r)
virtual EKernelType get_kernel_type ()
virtual const char * get_name () const

保护成员

virtual float64_t compute (int32_t idx_a, int32_t idx_b)

保护属性

float64_t width

构造及析构函数文档

CChi2Kernel ( int32_t  size,
float64_t  width 
)

constructor

参数:
size cache size
width width

在文件Chi2Kernel.cpp19行定义。

CChi2Kernel ( CSimpleFeatures< float64_t > *  l,
CSimpleFeatures< float64_t > *  r,
float64_t  width,
int32_t  size 
)

constructor

参数:
l features of left-hand side
r features of right-hand side
width width
size cache size

在文件Chi2Kernel.cpp24行定义。

~CChi2Kernel (  )  [virtual]

在文件Chi2Kernel.cpp31行定义。


成员函数文档

float64_t compute ( int32_t  idx_a,
int32_t  idx_b 
) [protected, virtual]

compute kernel function for features a and b idx_{a,b} denote the index of the feature vectors in the corresponding feature object

参数:
idx_a index a
idx_b index b
返回:
computed kernel function at indices a,b

实现了CKernel

在文件Chi2Kernel.cpp43行定义。

virtual EKernelType get_kernel_type (  )  [virtual]

return what type of kernel we are

返回:
kernel type CHI2

实现了CKernel

在文件Chi2Kernel.h66行定义。

virtual const char* get_name (  )  const [virtual]

return the kernel's name

返回:
name Chi2

实现了CSGObject

在文件Chi2Kernel.h72行定义。

bool init ( CFeatures l,
CFeatures r 
) [virtual]

initialize kernel

参数:
l features of left-hand side
r features of right-hand side
返回:
if initializing was successful

重载CSimpleKernel< float64_t >

在文件Chi2Kernel.cpp36行定义。


成员数据文档

float64_t width [protected]

width

在文件Chi2Kernel.h87行定义。


该类的文档由以下文件生成:

SHOGUN Machine Learning Toolbox - Documentation