본문 바로가기

Image filtering + Hybrid image Goal: Implement your own code for image filtering, my_imfilter() in MATLAB or C++ (You will get extra credit if you use C++). It must (1) support grayscale and color images (2) support arbitrary shaped filters, as long as both dimensions are odd (e.g. 7x9 filters but not 4x5 filters) (3) pad the input image with zeros or reflected image content and (4) return a filtered image which is the same r.. 더보기
Figure size setting based on screen size Adjust size of a figure in MATLAB based on the screen size. Codefig = figure(); clf; scrsz = get(0,'ScreenSize'); xstart = 0.2;ystart = 0.2;xsize = 0.7;ysize = 0.6;set(fig,'Position', [xstart*scrsz(3), ystart*scrsz(4), xsize*scrsz(3), ysize*scrsz(4)]);imagesc(rand(100, 100)); colormap bone;axis off; axis square;title(sprintf('xstart: %.1f ystart: %.1f xsize: %.1f ysize: %.1f', xstart, ystart, xs.. 더보기
Fast implementation of kdpp 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.. 더보기
Model Selection in Gaussian process regression In a big picture, a model selection in Gaussian process regression can categorized into two; one is a discrete selection of a proper kernel function and the other is a continuous optimization of selecting 'hyper-parameters' of a selected kernel function. In this post, we will focus on the latter model selection. Optimizing the hyper-parameters can be solved by either maximizing a marginal likeli.. 더보기