MCPcopy Create free account
hub / github.com/arrayfire/arrayfire / transpose

Function transpose

src/backend/opencl/transpose.cpp:23–34  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

21
22template<typename T>
23Array<T> transpose(const Array<T> &in, const bool conjugate) {
24 const dim4 &inDims = in.dims();
25 dim4 outDims = dim4(inDims[1], inDims[0], inDims[2], inDims[3]);
26 Array<T> out = createEmptyArray<T>(outDims);
27
28 const bool is32multiple =
29 inDims[0] % kernel::TILE_DIM == 0 && inDims[1] % kernel::TILE_DIM == 0;
30
31 kernel::transpose<T>(out, in, getQueue(), conjugate, is32multiple);
32
33 return out;
34}
35
36#define INSTANTIATE(T) \
37 template Array<T> transpose(const Array<T> &in, const bool conjugate);

Callers 3

svdFunction · 0.70
nearest_neighbour_Function · 0.70
matmulFunction · 0.70

Calls 3

dim4Class · 0.50
getQueueFunction · 0.50
dimsMethod · 0.45

Tested by

no test coverage detected