GPU accelerated image processing for everyone
Takes an image and assumes its grey values are integers. It builds up a grey-level co-occurrence matrix of neighboring (west, south-west, south, south-east, in 3D 9 pixels on the next plane) pixel intensities.
Major parts of this operation run on the CPU.
Category: Measurements
Availability: Available in Fiji by activating the update sites clij and clij2. This function is part of clijx_-0.32.0.1.jar.
Ext.CLIJx_generateIntegerGreyValueCooccurrenceCountMatrixHalfBox(Image integer_image, Image grey_value_cooccurrence_matrix_destination);
// init CLIJ and GPU import net.haesleinhuepf.clijx.CLIJx; import net.haesleinhuepf.clij.clearcl.ClearCLBuffer; CLIJx clijx = CLIJx.getInstance(); // get input parameters ClearCLBuffer integer_image = clijx.push(integer_imageImagePlus); grey_value_cooccurrence_matrix_destination = clijx.create(integer_image);
// Execute operation on GPU clijx.generateIntegerGreyValueCooccurrenceCountMatrixHalfBox(integer_image, grey_value_cooccurrence_matrix_destination);
// show result grey_value_cooccurrence_matrix_destinationImagePlus = clijx.pull(grey_value_cooccurrence_matrix_destination); grey_value_cooccurrence_matrix_destinationImagePlus.show(); // cleanup memory on GPU clijx.release(integer_image); clijx.release(grey_value_cooccurrence_matrix_destination);
% init CLIJ and GPU clijx = init_clatlabx(); % get input parameters integer_image = clijx.pushMat(integer_image_matrix); grey_value_cooccurrence_matrix_destination = clijx.create(integer_image);
% Execute operation on GPU clijx.generateIntegerGreyValueCooccurrenceCountMatrixHalfBox(integer_image, grey_value_cooccurrence_matrix_destination);
% show result grey_value_cooccurrence_matrix_destination = clijx.pullMat(grey_value_cooccurrence_matrix_destination) % cleanup memory on GPU clijx.release(integer_image); clijx.release(grey_value_cooccurrence_matrix_destination);