Research Article
Partition Selection for Large-Scale Data Management Using KNN Join Processing
Algorithm 3
Relevant partition selecting.
| Input: s, | | Output: | | selectTrainSet() { | | ; //determine the initial Relevant-partition | | for i = 2 to k do | | ; //calculate the k nearest neighbors of s in | | ; //calculate the maximum distance from s to its k nearest neighbors from R | | ; //calculate the distance from s to , | | if () then// does not belong to | | break; | | else// belongs to | | ; //add the partition to | | } |
|