Home || Visual Search || Applications || Architecture || Important Messages || OGL || Src

template<class ArrayT, class SimFuncT>
Real64 Impala::Core::Vector::Similarity ( VectorSet< ArrayT > *  example,
VectorSet< ArrayT > *  src,
int  exStartIdx,
int  srcStartIdx,
int  setSize,
SimFuncT  simFunc 
) [inline]

Compute similarity of setSize vectors starting at exStartIdx of the example set to the vectors of src starting at srcStartIdx.

Definition at line 19 of file Similarity.h.

References Impala::Core::Vector::VectorSet< ArrayT >::GetVector().

Referenced by Similarity().

00021 {
00022     Real64 score = 0;
00023     for (int i=0 ; i<setSize ; i++)
00024         score += simFunc(example->GetVector(exStartIdx + i, true),
00025                          src->GetVector(srcStartIdx + i, true));
00026     return (score / setSize);
00027 }

Here is the call graph for this function:


Generated on Thu Jan 13 09:21:36 2011 for ImpalaSrc by  doxygen 1.5.1