Modify the input dimensions without changing the data order. More...

Functions

AFAPI array moddims (const array &in, const unsigned ndims, const dim_t *const dims)
 
AFAPI array moddims (const array &in, const dim4 &dims)
 
AFAPI array moddims (const array &in, const dim_t d0, const dim_t d1=1, const dim_t d2=1, const dim_t d3=1)
 
AFAPI af_err af_moddims (af_array *out, const af_array in, const unsigned ndims, const dim_t *const dims)
 

Detailed Description

Modify the input dimensions without changing the data order.

Simply modifies the metadata. This is a noop.


Function Documentation

AFAPI af_err af_moddims ( af_array out,
const af_array  in,
const unsigned  ndims,
const dim_t *const  dims 
)
Parameters
[out]outis the modded array
[in]inis the input array
[in]ndimsis the number of dimensions
[in]dimsis the array containing the new dimensions
AFAPI array af::moddims ( const array in,
const dim4 dims 
)
Parameters
[in]inis the input array
[in]dimsis the new dimensions
Returns
the modded output
AFAPI array af::moddims ( const array in,
const dim_t  d0,
const dim_t  d1 = 1,
const dim_t  d2 = 1,
const dim_t  d3 = 1 
)
Parameters
[in]inis the input array
[in]d0specifies the new size of the first dimension
[in]d1specifies the new size of the second dimension
[in]d2specifies the new size of the third dimension
[in]d3specifies the new size of the fourth dimension
Returns
the modded array