GaussianFilter#
Compatibility: Requires PVA SDK 2.6.0 and later.
Functions#
- NVCVStatus pvaGaussianFilterCreate(NVCVOperatorHandle *handle, NVCVTensorRequirements *tensorRequirements, float sigmaX, float sigmaY, int32_t kernelSize, const NVCVBorderType borderMode, int32_t borderValue)
Constructs an instance of the GaussianFilter operator.
- NVCVStatus pvaGaussianFilterSubmit(NVCVOperatorHandle handle, cupvaStream_t stream, NVCVTensorHandle in, NVCVTensorHandle out)
Executes the gaussian filter operation on images.
Functions#
- NVCVStatus pvaGaussianFilterCreate(
- NVCVOperatorHandle *handle,
- NVCVTensorRequirements *tensorRequirements,
- float sigmaX,
- float sigmaY,
- int32_t kernelSize,
- const NVCVBorderType borderMode,
- int32_t borderValue,
Constructs an instance of the GaussianFilter operator.
Limitations:
Input: Data Layout: [kHWC] Channels: [1]
Data Type
Allowed
8bit Unsigned
Yes
8bit Signed
Yes
16bit Unsigned
Yes
16bit Signed
Yes
32bit Unsigned
No
32bit Signed
No
32bit Float
No
64bit Float
No
Output: Data Layout: [kHWC] Channels: [1]
Data Type
Allowed
8bit Unsigned
Yes
8bit Signed
Yes
16bit Unsigned
Yes
16bit Signed
Yes
32bit Unsigned
No
32bit Signed
No
32bit Float
No
64bit Float
No
Input/Output Dependency:
Property
Input == Output
Data Layout
Yes
Data Type
Yes
Number
Yes
Channels
Yes
Width
Yes
Height
Yes
Parameters
kernelSize = 3 or 5 borderMode = NVCV_BORDER_CONSTANT or NVCV_BORDER_REPLICATE
- Parameters:
handle – [out] Where the operator instance handle will be written to.
Must not be NULL.
tensorRequirements – [in] Pointer to the NVCVTensorRequirements structure which contains Tensor rank, shape, layout and data type information.
sigmaX – [in] Standard deviation of the Gaussian kernel in the X direction, must be a positive value, cannot be Inf or NaN.
sigmaY – [in] Standard deviation of the Gaussian kernel in the Y direction, must be a positive value, cannot be Inf or Nan.
kernelSize – [in] The size (width and height) of filter kernel. We only support 3x3 and 5x5 filter to demonstrate the fastest and specialized conv2d kernel.
borderMode – [in] Border mode to be used when accessing elements outside input image.
borderValue – [in] Constant border value to be used when borderMode is NVCV_BORDER_CONSTANT. Ignored otherwise.
- Return values:
NVCV_ERROR_INVALID_ARGUMENT – Handle is null.
NVCV_ERROR_OUT_OF_MEMORY – Not enough memory to create the operator.
NVCV_SUCCESS – Operation executed successfully.
- NVCVStatus pvaGaussianFilterSubmit(
- NVCVOperatorHandle handle,
- cupvaStream_t stream,
- NVCVTensorHandle in,
- NVCVTensorHandle out,
Executes the gaussian filter operation on images.
- Parameters:
handle – [in] Handle to the operator.
Must not be NULL.
stream – [in] Handle to a valid CUPVA stream.
in – [in] Input tensor handle.
out – [out] Output tensor handle.
- Return values:
NVCV_ERROR_INVALID_ARGUMENT – Some parameter is outside valid range.
NVCV_ERROR_INTERNAL – Internal error in the operator, invalid types passed in.
NVCV_SUCCESS – Operation executed successfully.