Function to invoke OpenCL package and create kernels

Share:

Description

This function sets up the OpenCL environment and creates kernels. It depends on the OpenCL package.

Usage

1
setup3(dev)

Arguments

dev

device list from OpenCL package function oclDevices

Value

List of OpenCL kernels

Author(s)

Kate Cowles

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
##---- Should be DIRECTLY executable !! ----
##-- ==>  Define data, use random,
##--	or do  help(data=index)  for the standard data sets.
## Not run: 
require(OpenCL)
plat <- oclPlatforms()
dev <- oclDevices( plat[[1]] )
if(!any(grepl("cl_khr_fp64", oclInfo(dev[[1]])$exts)))
    stop("GPU with double precision and Open CL capabilities required.")

k.sampling <- setup3(dev=dev)

## End(Not run)

Want to suggest features or report bugs for rdrr.io? Use the GitHub issue tracker.