fixed a bug which cause CDF kernels and adaptive nearest neighbors to be incompatible