GPU accelerated image processing for everyone
This plugin takes two image filenames and loads them into RAM. The first image is returned immediately, the second image is loaded in the background and will be returned when the plugin is called again.
It is assumed that all images have the same size. If this is not the case, call release(image) before getting the second image.
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_preloadFromDisc(Image destination, String filename, String nextFilename, String loaderId);
// init CLIJ and GPU import net.haesleinhuepf.clijx.CLIJx; import net.haesleinhuepf.clij.clearcl.ClearCLBuffer; CLIJx clijx = CLIJx.getInstance(); // get input parameters destination = clijx.create();
// Execute operation on GPU ClearCLBuffer resultPreloadFromDisc = clijx.preloadFromDisc(destination, filename, nextFilename, loaderId);
// show result System.out.println(resultPreloadFromDisc); destinationImagePlus = clijx.pull(destination); destinationImagePlus.show(); // cleanup memory on GPU clijx.release(destination);
% init CLIJ and GPU clijx = init_clatlabx(); % get input parameters destination = clijx.create();
% Execute operation on GPU ClearCLBuffer resultPreloadFromDisc = clijx.preloadFromDisc(destination, filename, nextFilename, loaderId);
% show result System.out.println(resultPreloadFromDisc); destination = clijx.pullMat(destination) % cleanup memory on GPU clijx.release(destination);