asdConvolve
Applicable Products
|
Hardware Model |
Supported or Not |
|---|---|
|
|
Not supported |
|
|
Not supported |
|
|
Not supported |
|
|
Supported |
|
|
Not supported |
Function Description
API function
asdConvolve: performs one-dimensional filtering on a given signal.
Formula:
- asdConvolve formula:
,
where w(k) is the element at the kth position of the output, u(j) is the one-dimensional signal at the jth position of the input, and v(k-j+1) is the filter convolution kernel at the (k-j+1)th position. The one-dimensional signal is a complex vector, and the filter convolution kernel is a real vector.
Function Prototype
AspbStatus asdConvolve(const aclTensor *signal, const aclTensor *kernel, aclTensor *output, asdConvolveMode_t mode, void *stream, void *workspace)
Parameter Description
|
Parameter |
Input/Output |
Type |
Description |
|---|---|---|---|
|
signal |
Input |
aclTensor * |
Input 1D signal. |
|
kernel |
Input |
aclTensor * |
Input convolutional filter. |
|
output |
Input/Output |
aclTensor * |
Output signal |
|
mode |
Input |
asdConvolveMode_t |
Filter convolution mode. Currently, only ASD_CONVOLVE_SAME is supported. That is, the dimensions of the input and output vectors are the same. |
|
stream |
Input |
void* |
Stream during operator execution. |
|
workspace |
Input |
void * |
Workspace pointer required by the operator. |
Constraints
asdMul
- The supported CANN version is CANN 8.0 or later.
- The supported data types of the input signal are COMPLEX32 and COMPLEX64. The supported data types of the input filtering convolution kernel are FLOAT16 and FLOAT32.
- The supported output data types are COMPLEX32 and COMPLEX64.
- The shape of the operator input signal is [BatchCount, n]. The output shape is the same as the input shape. The shape of the input filtering convolution kernel is [k].
Calling Example
For details about the operator calling example, see asdConvolve_complex32 or asdConvolve_complex64.