Enginius/Matlab
Fast implementation of kdpp
해리s
2015. 4. 2. 17:09
Details about kdpp can be found in (http://enginius.tistory.com/494)
Implementation of kdpp using matrix inversion lemma to reduce the computational complexity.
The speedup increases as the number of points increases (>100)
Starting kdpp where k is 50.
Starting kdpp_fast where k is 50.
k: 50 / toc_kdpp: 4.547e-02 sec / toc_kdpp_fast: 9.981e-03 sec (4.6 times faster)
One important rule of thumb is to lower the length parameter! So that the kernel function is peaky! kdpp_fast utilizes matrix inversion lemma and computing the inverse of a kernel matrix might be numerically unstable if the kernel function is smooth.
Result
code: main
code: kernel
code: kdpp
code: kdpp_fast