1 #ifndef STAN_MATH_OPENCL_KERNELS_TRANSPOSE_HPP 2 #define STAN_MATH_OPENCL_KERNELS_TRANSPOSE_HPP 10 namespace opencl_kernels {
12 static const char *transpose_kernel_code =
STRINGIFY(
25 __kernel
void transpose(__global
double *B, __global
double *A,
26 unsigned int rows,
unsigned int cols) {
27 int i = get_global_id(0);
28 int j = get_global_id(1);
29 if (i < rows && j < cols) {
int rows(const Eigen::Matrix< T, R, C > &m)
Return the number of rows in the specified matrix, vector, or row vector.
static const char * indexing_helpers
const kernel_cl< out_buffer, in_buffer, int, int > transpose("transpose", {indexing_helpers, transpose_kernel_code})
See the docs for transpose() .
int cols(const Eigen::Matrix< T, R, C > &m)
Return the number of columns in the specified matrix, vector, or row vector.
Creates functor for kernels.