Morphology#
Enumerations#
- MorphologyMaskType
Morphology mask shape types.
Functions#
- NVCVStatus pvaMorphologyCreate(NVCVOperatorHandle *handle, NVCVTensorRequirements *tensorRequirements, PvaMorphologyType morphType, PvaMorphologyMaskParams *maskParams, const NVCVBorderType borderMode, int32_t borderValue)
Constructs and an instance of the Morphology operator.
- NVCVStatus pvaMorphologySubmit(NVCVOperatorHandle handle, cupvaStream_t stream, NVCVTensorHandle in, NVCVTensorHandle out)
Executes the morphology operation of Dilates/Erodes on images.
Structs#
- PvaMorphologyMaskParamsRec
Morphology mask size and shape parameters.
Enumerations#
Functions#
- NVCVStatus pvaMorphologyCreate(
- NVCVOperatorHandle *handle,
- NVCVTensorRequirements *tensorRequirements,
- PvaMorphologyType morphType,
- PvaMorphologyMaskParams *maskParams,
- const NVCVBorderType borderMode,
- int32_t borderValue,
Constructs and an instance of the Morphology 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
maskParams: - maskWidth = maskHeight = 3 or 5 - maskShape = RECTANGLE_MASK if maskWidth == 5 morphType = PVA_ERODE, PVA_DILATE NVCVBorderType = 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.
morphType – [in] Type of operation to performs Erode/Dilate. PvaMorphologyType.
maskParams – [in] Pointer to the Morphology mask parameters. PvaMorphologyMaskParams.
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 pvaMorphologySubmit(
- NVCVOperatorHandle handle,
- cupvaStream_t stream,
- NVCVTensorHandle in,
- NVCVTensorHandle out,
Executes the morphology operation of Dilates/Erodes 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.