RPPT Tensor Operations - Filter Augmentations.

RPPT Tensor Operations - Filter Augmentations.#

RPP: RPPT Tensor Operations - Filter Augmentations.
RPPT Tensor Operations - Filter Augmentations.

RPPT Tensor Operations - Filter Augmentations. More...

Functions

RppStatus rppt_box_filter_gpu (RppPtr_t srcPtr, RpptDescPtr srcDescPtr, RppPtr_t dstPtr, RpptDescPtr dstDescPtr, Rpp32u kernelSize, RpptROIPtr roiTensorPtrSrc, RpptRoiType roiType, rppHandle_t rppHandle)
 Box Filter augmentation on HIP backend for a NCHW/NHWC layout tensor. More...
 
RppStatus rppt_gaussian_filter_gpu (RppPtr_t srcPtr, RpptDescPtr srcDescPtr, RppPtr_t dstPtr, RpptDescPtr dstDescPtr, Rpp32f *stdDevTensor, Rpp32u kernelSize, RpptROIPtr roiTensorPtrSrc, RpptRoiType roiType, rppHandle_t rppHandle)
 Gaussian Filter augmentation on HIP backend for a NCHW/NHWC layout tensor. More...
 

Detailed Description

RPPT Tensor Operations - Filter Augmentations.

Function Documentation

◆ rppt_box_filter_gpu()

RppStatus rppt_box_filter_gpu ( RppPtr_t  srcPtr,
RpptDescPtr  srcDescPtr,
RppPtr_t  dstPtr,
RpptDescPtr  dstDescPtr,
Rpp32u  kernelSize,
RpptROIPtr  roiTensorPtrSrc,
RpptRoiType  roiType,
rppHandle_t  rppHandle 
)

Box Filter augmentation on HIP backend for a NCHW/NHWC layout tensor.

The box filter augmentation runs for a batch of RGB(3 channel) / greyscale(1 channel) images with an NHWC/NCHW tensor layout.

  • srcPtr depth ranges - Rpp8u (0 to 255), Rpp16f (0 to 1), Rpp32f (0 to 1), Rpp8s (-128 to 127).
  • dstPtr depth ranges - Will be same depth as srcPtr.
    Sample Input
    Sample 3x3 Output
    Sample 5x5 Output
    Sample 7x7 Output
    Sample 9x9 Output
    Parameters
    [in]srcPtrsource tensor in HIP memory
    [in]srcDescPtrsource tensor descriptor (Restrictions - numDims = 4, offsetInBytes >= 0, dataType = U8/F16/F32/I8, layout = NCHW/NHWC, c = 1/3)
    [out]dstPtrdestination tensor in HIP memory
    [in]dstDescPtrdestination tensor descriptor (Restrictions - numDims = 4, offsetInBytes >= 0, dataType = U8/F16/F32/I8, layout = NCHW/NHWC, c = same as that of srcDescPtr)
    [in]kernelSizekernel size for box filter (a single Rpp32u odd number with kernelSize = 3/5/7/9 that applies to all images in the batch)
    [in]roiTensorSrcROI data in HIP memory, for each image in source tensor (2D tensor of size batchSize * 4, in either format - XYWH(xy.x, xy.y, roiWidth, roiHeight) or LTRB(lt.x, lt.y, rb.x, rb.y))
    [in]roiTypeROI type used (RpptRoiType::XYWH or RpptRoiType::LTRB)
    [in]rppHandleRPP HIP handle created with rppCreateWithStreamAndBatchSize()
    Returns
    A RppStatus enumeration.
    Return values
    RPP_SUCCESSSuccessful completion.
    RPP_ERROR*Unsuccessful completion.

◆ rppt_gaussian_filter_gpu()

RppStatus rppt_gaussian_filter_gpu ( RppPtr_t  srcPtr,
RpptDescPtr  srcDescPtr,
RppPtr_t  dstPtr,
RpptDescPtr  dstDescPtr,
Rpp32f stdDevTensor,
Rpp32u  kernelSize,
RpptROIPtr  roiTensorPtrSrc,
RpptRoiType  roiType,
rppHandle_t  rppHandle 
)

Gaussian Filter augmentation on HIP backend for a NCHW/NHWC layout tensor.

The gaussian filter augmentation runs for a batch of RGB(3 channel) / greyscale(1 channel) images with an NHWC/NCHW tensor layout.

  • srcPtr depth ranges - Rpp8u (0 to 255), Rpp16f (0 to 1), Rpp32f (0 to 1), Rpp8s (-128 to 127).
  • dstPtr depth ranges - Will be same depth as srcPtr.
    Sample Input
    Sample 3x3 Output
    Sample 5x5 Output
    Sample 7x7 Output
    Sample 9x9 Output
    Parameters
    [in]srcPtrsource tensor in HIP memory
    [in]srcDescPtrsource tensor descriptor (Restrictions - numDims = 4, offsetInBytes >= 0, dataType = U8/F16/F32/I8, layout = NCHW/NHWC, c = 1/3)
    [out]dstPtrdestination tensor in HIP memory
    [in]dstDescPtrdestination tensor descriptor (Restrictions - numDims = 4, offsetInBytes >= 0, dataType = U8/F16/F32/I8, layout = NCHW/NHWC, c = same as that of srcDescPtr)
    [in]stdDevTensorstdDev values for gaussian calculation (1D tensor in pinned/HOST memory, of size batchSize, for each image in batch)
    [in]kernelSizekernel size for gaussian filter (a single Rpp32u odd number with kernelSize = 3/5/7/9 that applies to all images in the batch)
    [in]roiTensorSrcROI data in HIP memory, for each image in source tensor (2D tensor of size batchSize * 4, in either format - XYWH(xy.x, xy.y, roiWidth, roiHeight) or LTRB(lt.x, lt.y, rb.x, rb.y))
    [in]roiTypeROI type used (RpptRoiType::XYWH or RpptRoiType::LTRB)
    [in]rppHandleRPP HIP handle created with rppCreateWithStreamAndBatchSize()
    Returns
    A RppStatus enumeration.
    Return values
    RPP_SUCCESSSuccessful completion.
    RPP_ERROR*Unsuccessful completion.