Sorting many small arrays in CUDA -


i implementing median filter in cuda. particular pixel, extract neighbors corresponding window around pixel, n x n (3 x 3) window, , have array of n x n elements. not envision using window of more 10 x 10 elements application.

this array locally present in kernel , loaded device memory. previous posts have read, common sorting algorithms implemented thrust. but, thrust can called host. thread - thrust inside user written kernels

is there quick , efficient way sort small array of n x n elements inside kernel?

if number of elements fixed , small, can use sorting networks (http://pages.ripco.net/~jgamble/nw.html). provides fixed number of compare/swap operations fixed number of elements (eg. 19 compare/swap iterations 8 elements).


Comments

Popular posts from this blog

get url and add instance to a model with prefilled foreign key :django admin -

css - Make div keyboard-scrollable in jQuery Mobile? -

ruby on rails - Seeing duplicate requests handled with Unicorn -