ArrayFire函数列表
ArrayFire矩阵运算库提供了258个函数用来处理各种运算。涵盖的类型包括:
数学函数
https://arrayfire.org/docs/group__mathfunc__mat.htm
线性代数
https://arrayfire.org/docs/group__linalg__mat.htm
信号处理
https://arrayfire.org/docs/group__signal__mat.htm
统计学
https://arrayfire.org/docs/group__stats__mat.htm
图像处理
https://arrayfire.org/docs/group__image__mat.htm
输入输出
https://arrayfire.org/docs/group__io__mat.htm
内存管理
https://arrayfire.org/docs/group__memory__manager.htm
等,下面时全部的函数列表:
abs | Absolute value. |
accum | Cumulative sum (inclusive). |
acos | Inverse cosine. |
acosh | Inverse hyperbolic cosine. |
add | Addition of two inputs. |
allocHost | Allocate memory on host. |
allocV2 | Allocate memory using the ArrayFire memory manager. |
allTrue | Test if all values in an array are true. |
allTrueByKey | Calculate if all values that share the same consecutive keys are true. |
and | Logical AND. |
anisotropicDiffusion | Anisotropic Smoothing Filter. |
anytrue | Calculate if any values in an array are true. |
anyTrueByKey | Calculate if any values that share the same consecutive keys are true. |
approx1 | Interpolation across a single dimension. |
approx2 | Interpolation along two dimensions. |
arg | Phase of a number in the complex plane. |
asin | arc sin of input |
asinh | asinh of input |
assign | Copy and write values in the locations specified by the sequences. |
atan/atan2 | arc tan of input |
atanh | atanh of input |
bilateral | Bilateral Filter. |
bitand | Bitwise and operation of two inputs. |
bitor | Bitwise or operation of two inputs. |
bitshiftl | Left shift an input. |
bitshiftr | Right shift an input. |
bitxor | Bitwise xor operation of two inputs. |
canny | Canny Edge Detector. |
cast | Casting inputs from one type to another. |
cbrt | Cube root of input arrays. |
ceil | Round to integer greater than equal to current value. |
cholesky | Perform Cholesky decomposition. |
col/cols | Gets a reference of a col in a 2D af::array. |
colorSpace | Colorspace conversion function. |
complex | create complex arrays |
confidenceCC | Segment image based on similar pixel characteristics. |
conjg | Get complex conjugate. |
constant | Create a array from a scalar input value. |
convolve (Non-separable) | Convolution Integral for any(one through three) dimensional data. |
convolve (Separable) | Separable Convolution. |
convolve1 | Convolution Integral for one dimensional data. |
convolve2 | Convolution Integral for two dimensional data. |
convolve3 | Convolution Integral for three dimensional data. |
corrcoef | Find the correlation coefficient of values in the input. |
cos | cos of input |
cosh | cosh of input |
count | Count the number of non-zero elements in the input. |
countByKey | Counts the non-zero values of an input array according to an array of keys. |
cov | Find the covariance of values in the input. |
deleteImageMem | Delete memory created by saveImageMem and af_save_image_memory function. |
dense | Returns a dense array from a sparse input. |
det | Find the determinant of the input matrix. |
deviceInfo | Gets the information about device and platform as strings. |
deviceMemInfo | Memory manager related functions. |
diag | Extract diagonal from a matrix when extract is set to true. |
diff1 | First order numerical difference along specified dimension. |
diff2 | Second order numerical difference along specified dimension. |
dilate | Dilation(morphological operator) for images. |
dilate3d | Dilation(morphological operator) for volumes. |
div | Divide one input by another. |
dog | Difference of Gaussians. |
dot | Calculate the dot product of a vector. |
eq | Check if input two inputs are equal. |
erf | Error function value. |
erfc | Complementary Error function value. |
erode | Erosion(morphological operator) for images. |
erode3d | Erosion(morphological operator) for volumes. |
exp | Exponential of input. |
expm1 | Exponential of input - 1. |
factorial | Factorial function. |
fast | FAST feature detector. |
features | Lookup values of an array based on sequences and/or arrays. |
fft | Fast Fourier Transform. |
fft2 | Fast Fourier Transform. |
fft3 | Fast Fourier Transform. |
fftC2R | Complex to Real Fast Fourier Transform. |
fftR2C | Real to Complex Fast Fourier Transform. |
fir | This function implements a Finite Impulse Filter. |
flat | Flatten the input to a single dimension. |
flip | Flip the input along specified dimension. |
floor | Round to integer less than equal to current value. |
freeHost | Free memory allocated on host internally by ArrayFire. |
freePinned | Free pinned memory allocated by ArrayFire's memory manager. |
freeV2 | Returns memory to ArrayFire's memory manager. |
gaussiankernel | Creates a Gaussian Kernel. |
ge | Check if input is greater than or equal to another. |
getActiveBackend | Get's the backend enum for the active backend. |
getAvailableBackends | Returns an integer indicating the backends loaded successfully. |
getBackendCount | Get the number of backends whose libraries were successfully loaded. |
getBackendId | Get's the backend enum for an array. |
getDefaultRandomEngine | Returns the default random engine object. |
getDevice | Get the current device ID. |
getDeviceCount | Gets the number of compute devices on the system. |
getDeviceId | Get's the id of the device an array was created on. |
getSeed | Returns the seed for random number generation. |
gloh | SIFT feature detector and GLOH descriptor extractor. |
grad | Calculate the gradients of the input. |
gray2rgb | Grayscale to RGB colorspace converter. |
gt | Check if input is greater than another. |
hammingMatcher | Hamming Matcher. |
harris | Harris corner detector. |
histequal | Histogram equalization of input image. |
histogram | Histogram of input data. |
homography | Homography Estimation. |
hsv2rgb | HSV to RGB colorspace converter. |
hypot | Hypotenuse of the two inputs. |
identity | Create an identity array with diagonal values 1. |
ifft | Fast Fourier Transform. |
ifft2 | Fast Fourier Transform. |
ifft3 | Fast Fourier Transform. |
iir | This function implements a Infinite Impulse Filter. |
imag | Get imaginary part of complex arrays. |
index | Lookup values of an array based on sequences and/or arrays. |
info | Display ArrayFire and device info. |
infoString | Get af::info() as a string. |
inverse | Invert a matrix. |
inverseDeconv | Inverse Deconvolution. |
iota | Create an sequence [0, dims.elements() - 1] and modify to specified dimensions dims and then tile it according to tile_dims. |
isDoubleAvailable | Check if double precision support is available for specified device. |
isHalfAvailable | Check if half(16-bit) precision floating point support is available for specified device. |
isImageIoAvailable | Returns true if ArrayFire was compiled with ImageIO (FreeImage) support. |
isinf | Check if values are infinite. |
isLAPACKAvailable | Returns true is ArrayFire is compiled with LAPACK support. |
isNan | Check if values are Nan. |
iszero | Check if values are zero. |
iterativeDeconv | Iterative Deconvolution. |
join | Join up to 4 arrays along specified dimension. |
le | Check if input is less than or equal to another. |
lgamma | Logarithm of absolute values of Gamma function. |
loadImage | Load an image from disk to an array. |
loadImageMem | Load an image from memory which is stored as a FreeImage stream (FIMEMORY). |
log | Natural logarithm. |
log10 | logarithm base 10 |
log1p | Natural logarithm of (1 + in) |
lookup | Lookup values of an array by indexing with another array. |
lower | Create a lower triangular matrix from input array. |
lt | Check if input is less than another. |
lu | Perform LU decomposition. |
matchTemplate | Template Matching. |
matmul | Matrix multiplication using array. |
max | Find the maximum values and their locations. |
max | Maximum of two inputs. |
maxByKey | Finds the max of an input array according to an array of keys. |
maxfilt | Find maximum value from a window. |
mean | Find the mean of values in the input. |
meanshift | Meanshift Filter. |
medfilt | Median Filter. |
median | Find the median of values in the input. |
min | Find the minimum values and their locations. |
min | Minimum of two inputs. |
minByKey | Finds the min of an input array according to an array of keys. |
minfilt | Find minimum value from a window. |
mod | Compute x−n∗y where n is quotient of x/y. |
moddims | Modify the input dimensions without changing the data order. |
moments | The moments() function allows for finding different properties of image regions. |
mul | Multiply two inputs element wise. |
nearestNeighbour | Determine the nearest neighbouring points to a given set of points. |
neg | Negative of an input. |
neq | Check if input two inputs are not equal. |
norm | Find the norm of the input matrix. |
not | Logical not of an input. |
operator() | Gets a reference to a set of elements. |
operator(star)= | Multiplies and assigns the value(s) of val to the elements of the af::array. |
operator/= | Divides and assigns the value(s) of val to the elements of the af::array. |
operator+= | Adds and assigns the value(s) of val to the elements of the af::array. |
operator= | Assignes the value(s) of val to the elements of the af::array. |
operator-= | Subtracts and assigns the value(s) of val to the elements of the af::array. |
or | Logical or of two inputs. |
orb | ORB Feature descriptor. |
pad | Pad an array. |
pinned | Allocate pinned memory using ArrayFire's memory manager. |
pinverse | Pseudo-invert a matrix. |
pow | Raise an array to a power. |
Print the array to screen. | |
product | Find the product of values in the input. |
productByKey | Finds the product of an input array according to an array of keys. |
qr | Perform QR decomposition. |
randn | Create a random array sampled from normal distribution. |
randomEngine | Functions to create, modify, use, and destroy randomEngine objects. |
randu | Create a random array sampled from uniform distribution. |
range | Creates an array with [0, n] values along the seq_dim which is tiled across other dimensions. |
rank | Find the rank of the input matrix. |
readArray | Load an array from a file. |
real | Get real part of complex arrays. |
regions | Find blobs in given image. |
rem | Remainder operation. |
reorder | Reorder an array according to the specified dimensions. |
replace | Replace elements of an array based on a conditional array. |
resize | Resize an input image. |
rgb2gray | RGB to Grayscale colorspace converter. |
rgb2hsv | RGB to HSV colorspace converter. |
rgb2ycbcr | RGB to YCbCr colorspace converter. |
root | Find root of an input. |
rotate | Rotate an input image or array. |
round | Round to nearest integer. |
row/rows | Gets a reference of a row in a 2D af::array. |
rsqrt | The reciprocal or inverse square root of input arrays. |
sat | Summed Area Tables. |
saveArray | Save an array to a binary file. |
saveImage | Save an array to disk as an image. |
saveImageMem | Save an array to memory as an image using FreeImage stream (FIMEMORY). |
scale | Scale an input image. |
scan | Inclusive or exclusive scan of an array. |
scanByKey | Inclusive or exclusive scan of an array by key. |
select | Selects elements from two arrays based on the values of a binary conditional array. |
setBackend | Set the current backend when using Unified backend. |
setDefaultRandomEngineType | Set the default random engine type. |
setDevice | Change current device to specified device. |
setintersect | Find the intersection of two sets. |
setSeed | Set the seed for random number generation. |
setunion | Find the union of two sets. |
setunique | Finds unique values from an input set. |
shift | Circular shift slong specified dimensions. |
sift | SIFT feature detector and descriptor extractor. |
sign | Check if input is negative. |
sin | sin of input |
sinh | sinh of input |
skew | Skew an input image. |
slice/slices | Gets a reference of a matrix in a 3D af::array. |
sobel | Sobel Operators. |
solve | Solve a system of equations. |
solveLU | Solve a system of equations. |
sort | Sort input arrays. |
sortByKey | Sort input arrays based on keys. |
sortIndex | Sort input arrays get the sorted indices. |
sparse | Create a sparse array. |
sparseConvertTo | Convert an existing sparse array into a different storage format. |
sparseGetColdx | Returns reference to the column indices component of the sparse array. |
sparseGetInfo | Returns reference to components of the input sparse array. |
sparseGetNNZ | Returns the number of non zero elements in the sparse array. |
sparseGetRowIdx | Returns reference to the row indices component of the sparse array. |
sparseGetStorage | Returns the storage type of a sparse array. |
sparseGetValues | Returns reference to the values component of the sparse array. |
sqrt | Square root of input arrays. |
stdev | Find the standard deviation of values in the input. |
sub | Subtract one input from another. |
sum | Find the sum of values in the input. |
sumByKey | Finds the sum of an input array according to an array of keys. |
susan | SUSAN corner detector. |
svd | Computes the singular value decomposition of a matrix. |
sync | Blocks until all operations on device are finished. |
tan/tan2 | tan of input |
tanh | tanh of input |
tgamma | Gamma function. |
tile | Repeat the contents of the input array along the specified dimensions. |
topk | This function returns the top k values along a given dimension of the input array. |
toString | Print the array to a string instead of the screen. |
transform | Transform an input image. |
transformCoordinates | Transform input coordinates. |
translate | Translate an input image. |
transpose | Matrix Transpose. |
trunc | Truncate to nearest integer. |
unwrap | Rearrange windowed sections of an array into columns (or rows) |
upper | Create a upper triangular matrix from input array. |
var | Find the variance of values in the input. |
where | Locate the indices of non-zero elements. |
wrap | Performs the opposite of unwrap(). |
ycbcr2rgb | YCbCr to RGB colorspace converter. |