#include <yat/classifier/KNN_ReciprocalDistance.h>
Public Member Functions | |
void | operator() (const utility::VectorBase &dist, const std::vector< size_t > &k_sorted, const Target &target, utility::VectorMutable &prediction) const |
KNN_ReciprocalDistance weights the vote of a nearest neighbor with its reciprocal rank.
void theplu::yat::classifier::KNN_ReciprocalDistance::operator() | ( | const utility::VectorBase & | dist, | |
const std::vector< size_t > & | k_sorted, | |||
const Target & | target, | |||
utility::VectorMutable & | prediction | |||
) | const |
The total vote for each class is calculated and returned in prediction.