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

template<class ArrayT, class SimFtorT>
Real64 Impala::Core::Vector::RadiusSimilarity ( typename VectorSet< ArrayT >::VectorT  example,
VectorSet< ArrayT > *  src,
Real64  radius,
int  end,
SimFtorT  simFunc 
) [inline]

Count the number of elements in src that are within the radius of example.

With similarity, it has to be bigger than radius, with distance it has to be smaller than radius.

Definition at line 20 of file RadiusSimilarity.h.

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

Referenced by Impala::Core::Feature::RadiusClusteror< SimFunc >::ProcessBuffer().

00023 {
00024     Real64 count = 0;
00025     for (int i=0 ; i<end ; i++)
00026     {
00027         Real64 sim = simFunc.DoIt(example, src->GetVector(i, true));
00028         if (sim >= radius)
00029             count += 1.0;
00030     }
00031     return count;
00032 }

Here is the call graph for this function:


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