kd-tree for nearest neighbor learning algorithms.