Showing content from http://www.arrayfire.org/docs/group__manip__func__moddims.htm below:
ArrayFire: moddims
Modify the dimensions of an array without changing the order of its elements. More...
AFAPI array moddims (const array &in, const dim4 &dims) C++ Interface to modify the dimensions of an input array to a specified shape. More...
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) C++ Interface to modify the dimensions of an input array to a specified shape. More...
AFAPI array moddims (const array &in, const unsigned ndims, const dim_t *const dims) C++ Interface to modify the dimensions of an input array to a specified shape. More...
AFAPI af_err af_moddims (af_array *out, const af_array in, const unsigned ndims, const dim_t *const dims) C Interface to modify the dimensions of an input array to a specified shape. More...
Modify the dimensions of an array without changing the order of its elements.
This function only modifies array metadata and requires no computation. It is a NOOP.
Examples:
array a = iota(dim4(2, 3));
array b = moddims(a, dim4(3, 2));
array c = moddims(a, 3, 2);
vector<dim_t> x{3, 2};
array d = moddims(a, 2, x.data());
◆ af_moddims()
C Interface to modify the dimensions of an input array to a specified shape.
-
Parameters
-
[out] out modded output [in] in input array [in] ndims number of dimensions [in] dims new dimension sizes
-
Returns
-
AF_SUCCESS, if function returns successfully, else an af_err code is given
◆ moddims() [1/3]
C++ Interface to modify the dimensions of an input array to a specified shape.
-
Parameters
-
[in] in input array [in] dims new dimension sizes
-
Returns
-
modded output
◆ moddims() [2/3]
C++ Interface to modify the dimensions of an input array to a specified shape.
-
Parameters
-
[in] in input array [in] d0 new size of the first dimension [in] d1 new size of the second dimension (optional) [in] d2 new size of the third dimension (optional) [in] d3 new size of the fourth dimension (optional)
-
Returns
-
modded output
◆ moddims() [3/3]
C++ Interface to modify the dimensions of an input array to a specified shape.
-
Parameters
-
[in] in input array [in] ndims number of dimensions [in] dims new dimension sizes
-
Returns
-
modded output
RetroSearch is an open source project built by @garambo
| Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4