NVIDIA 2D Image And Signal Performance Primitives (NPP)  Version 11.5.0.*
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages
Functions
HistogramOfOrientedGradientsBorder

Performs Histogram Of Oriented Gradients operation on source image generating separate windows of Histogram Descriptors for each requested location. More...

Functions

NppStatus  nppiHistogramOfGradientsBorderGetBufferSize (const NppiHOGConfig oHOGConfig, const NppiPoint *hpLocations, int nLocations, NppiSize oSizeROI, int *hpBufferSize)
  Validates requested HOG configuration and calculates scratch buffer size needed for the HistogramOfGradientsBorder function based on requested HOG configuration, source image ROI, and number and locations of descriptor window locations. More...
 
NppStatus  nppiHistogramOfGradientsBorderGetDescriptorsSize (const NppiHOGConfig oHOGConfig, int nLocations, int *hpDescriptorsSize)
  Validates requested HOG configuration and calculates output window descriptors buffer size needed for the HistogramOfGradientsBorder function based on requested HOG configuration, and number of descriptor window locations, one descriptor window is output for each location. More...
 
NppStatus  nppiHistogramOfGradientsBorder_8u32f_C1R_Ctx (const Npp8u *pSrc, int nSrcStep, NppiSize oSrcSize, NppiPoint oSrcOffset, const NppiPoint *hpLocations, int nLocations, Npp32f *pDstWindowDescriptorBuffer, NppiSize oSizeROI, const NppiHOGConfig oHOGConfig, Npp8u *pScratchBuffer, NppiBorderType eBorderType, NppStreamContext nppStreamCtx)
  1 channel 8-bit unsigned grayscale per source image descriptor window location with source image border control to per descriptor window destination floating point histogram of gradients. More...
 
NppStatus  nppiHistogramOfGradientsBorder_8u32f_C1R (const Npp8u *pSrc, int nSrcStep, NppiSize oSrcSize, NppiPoint oSrcOffset, const NppiPoint *hpLocations, int nLocations, Npp32f *pDstWindowDescriptorBuffer, NppiSize oSizeROI, const NppiHOGConfig oHOGConfig, Npp8u *pScratchBuffer, NppiBorderType eBorderType)
 
NppStatus  nppiHistogramOfGradientsBorder_8u32f_C3R_Ctx (const Npp8u *pSrc, int nSrcStep, NppiSize oSrcSize, NppiPoint oSrcOffset, const NppiPoint *hpLocations, int nLocations, Npp32f *pDstWindowDescriptorBuffer, NppiSize oSizeROI, const NppiHOGConfig oHOGConfig, Npp8u *pScratchBuffer, NppiBorderType eBorderType, NppStreamContext nppStreamCtx)
  3 channel 8-bit unsigned color per source image descriptor window location with source image border control to per descriptor window destination floating point histogram of gradients. More...
 
NppStatus  nppiHistogramOfGradientsBorder_8u32f_C3R (const Npp8u *pSrc, int nSrcStep, NppiSize oSrcSize, NppiPoint oSrcOffset, const NppiPoint *hpLocations, int nLocations, Npp32f *pDstWindowDescriptorBuffer, NppiSize oSizeROI, const NppiHOGConfig oHOGConfig, Npp8u *pScratchBuffer, NppiBorderType eBorderType)
 
NppStatus  nppiHistogramOfGradientsBorder_16u32f_C1R_Ctx (const Npp16u *pSrc, int nSrcStep, NppiSize oSrcSize, NppiPoint oSrcOffset, const NppiPoint *hpLocations, int nLocations, Npp32f *pDstWindowDescriptorBuffer, NppiSize oSizeROI, const NppiHOGConfig oHOGConfig, Npp8u *pScratchBuffer, NppiBorderType eBorderType, NppStreamContext nppStreamCtx)
  1 channel 16-bit unsigned grayscale per source image descriptor window location with source image border control to per descriptor window destination floating point histogram of gradients. More...
 
NppStatus  nppiHistogramOfGradientsBorder_16u32f_C1R (const Npp16u *pSrc, int nSrcStep, NppiSize oSrcSize, NppiPoint oSrcOffset, const NppiPoint *hpLocations, int nLocations, Npp32f *pDstWindowDescriptorBuffer, NppiSize oSizeROI, const NppiHOGConfig oHOGConfig, Npp8u *pScratchBuffer, NppiBorderType eBorderType)
 
NppStatus  nppiHistogramOfGradientsBorder_16u32f_C3R_Ctx (const Npp16u *pSrc, int nSrcStep, NppiSize oSrcSize, NppiPoint oSrcOffset, const NppiPoint *hpLocations, int nLocations, Npp32f *pDstWindowDescriptorBuffer, NppiSize oSizeROI, const NppiHOGConfig oHOGConfig, Npp8u *pScratchBuffer, NppiBorderType eBorderType, NppStreamContext nppStreamCtx)
  3 channel 16-bit unsigned color per source image descriptor window location with source image border control to per descriptor window destination floating point histogram of gradients. More...
 
NppStatus  nppiHistogramOfGradientsBorder_16u32f_C3R (const Npp16u *pSrc, int nSrcStep, NppiSize oSrcSize, NppiPoint oSrcOffset, const NppiPoint *hpLocations, int nLocations, Npp32f *pDstWindowDescriptorBuffer, NppiSize oSizeROI, const NppiHOGConfig oHOGConfig, Npp8u *pScratchBuffer, NppiBorderType eBorderType)
 
NppStatus  nppiHistogramOfGradientsBorder_16s32f_C1R_Ctx (const Npp16s *pSrc, int nSrcStep, NppiSize oSrcSize, NppiPoint oSrcOffset, const NppiPoint *hpLocations, int nLocations, Npp32f *pDstWindowDescriptorBuffer, NppiSize oSizeROI, const NppiHOGConfig oHOGConfig, Npp8u *pScratchBuffer, NppiBorderType eBorderType, NppStreamContext nppStreamCtx)
  1 channel 16-bit signed grayscale per source image descriptor window location with source image border control to per descriptor window destination floating point histogram of gradients. More...
 
NppStatus  nppiHistogramOfGradientsBorder_16s32f_C1R (const Npp16s *pSrc, int nSrcStep, NppiSize oSrcSize, NppiPoint oSrcOffset, const NppiPoint *hpLocations, int nLocations, Npp32f *pDstWindowDescriptorBuffer, NppiSize oSizeROI, const NppiHOGConfig oHOGConfig, Npp8u *pScratchBuffer, NppiBorderType eBorderType)
 
NppStatus  nppiHistogramOfGradientsBorder_16s32f_C3R_Ctx (const Npp16s *pSrc, int nSrcStep, NppiSize oSrcSize, NppiPoint oSrcOffset, const NppiPoint *hpLocations, int nLocations, Npp32f *pDstWindowDescriptorBuffer, NppiSize oSizeROI, const NppiHOGConfig oHOGConfig, Npp8u *pScratchBuffer, NppiBorderType eBorderType, NppStreamContext nppStreamCtx)
  3 channel 16-bit signed color per source image descriptor window location with source image border control to per descriptor window destination floating point histogram of gradients. More...
 
NppStatus  nppiHistogramOfGradientsBorder_16s32f_C3R (const Npp16s *pSrc, int nSrcStep, NppiSize oSrcSize, NppiPoint oSrcOffset, const NppiPoint *hpLocations, int nLocations, Npp32f *pDstWindowDescriptorBuffer, NppiSize oSizeROI, const NppiHOGConfig oHOGConfig, Npp8u *pScratchBuffer, NppiBorderType eBorderType)
 
NppStatus  nppiHistogramOfGradientsBorder_32f_C1R_Ctx (const Npp32f *pSrc, int nSrcStep, NppiSize oSrcSize, NppiPoint oSrcOffset, const NppiPoint *hpLocations, int nLocations, Npp32f *pDstWindowDescriptorBuffer, NppiSize oSizeROI, const NppiHOGConfig oHOGConfig, Npp8u *pScratchBuffer, NppiBorderType eBorderType, NppStreamContext nppStreamCtx)
  1 channel 32-bit floating point grayscale per source image descriptor window location with source image border control to per descriptor window destination floating point histogram of gradients. More...
 
NppStatus  nppiHistogramOfGradientsBorder_32f_C1R (const Npp32f *pSrc, int nSrcStep, NppiSize oSrcSize, NppiPoint oSrcOffset, const NppiPoint *hpLocations, int nLocations, Npp32f *pDstWindowDescriptorBuffer, NppiSize oSizeROI, const NppiHOGConfig oHOGConfig, Npp8u *pScratchBuffer, NppiBorderType eBorderType)
 
NppStatus  nppiHistogramOfGradientsBorder_32f_C3R_Ctx (const Npp32f *pSrc, int nSrcStep, NppiSize oSrcSize, NppiPoint oSrcOffset, const NppiPoint *hpLocations, int nLocations, Npp32f *pDstWindowDescriptorBuffer, NppiSize oSizeROI, const NppiHOGConfig oHOGConfig, Npp8u *pScratchBuffer, NppiBorderType eBorderType, NppStreamContext nppStreamCtx)
  3 channel 32-bit floating point color per source image descriptor window location with source image border control to per descriptor window destination floating point histogram of gradients. More...
 
NppStatus  nppiHistogramOfGradientsBorder_32f_C3R (const Npp32f *pSrc, int nSrcStep, NppiSize oSrcSize, NppiPoint oSrcOffset, const NppiPoint *hpLocations, int nLocations, Npp32f *pDstWindowDescriptorBuffer, NppiSize oSizeROI, const NppiHOGConfig oHOGConfig, Npp8u *pScratchBuffer, NppiBorderType eBorderType)
 

Detailed Description

Performs Histogram Of Oriented Gradients operation on source image generating separate windows of Histogram Descriptors for each requested location.

This function implements the simplest form of functionality described by N. Dalal and B. Triggs. Histograms of Oriented Gradients for Human Detection. INRIA, 2005. It supports overlapped contrast normalized block histogram output with L2 normalization only, no threshold clipping, and no pre or post gaussian smoothing of input images or histogram output values. It supports both single channel grayscale source images and three channel color images. For color images, the color channel with the highest magnitude value is used as that pixel's magnitude. Output is row order only. Descriptors are output consecutively with no separation padding if multiple descriptor output is requested (one desriptor per source image location). For example, common HOG parameters are 9 histogram bins per 8 by 8 pixel cell, 2 by 2 cells per block, with a descriptor window size of 64 horizontal by 128 vertical pixels yielding 7 by 15 overlapping blocks (1 cell overlap in both horizontal and vertical directions). This results in 9 bins * 4 cells * 7 horizontal overlapping blocks * 15 vertical overlapping blocks or 3780 32-bit floating point output values (bins) per descriptor window.

The number of horizontal overlapping block histogram bins per descriptor window width is determined by (((oHOGConfig.detectionWindowSize.width / oHOGConfig.histogramBlockSize) * 2) - 1) * oHOGConfig.nHistogramBins. The number of vertical overlapping block histograms per descriptor window height is determined by (((oHOGConfig.detectionWindowSize.height / oHOGConfig.histogramBlockSize) * 2) - 1) The offset of each descriptor window in the descriptors output buffer is therefore horizontal histogram bins per descriptor window width * vertical histograms per descriptor window height 32-bit floating point values relative to the previous descriptor window output.

The algorithm uses a 1D centered derivative mask of [-1, 0, +1] when generating input magnitude and angle gradients. Magnitudes are added to the two nearest histogram bins of oriented gradients between 0 and 180 degrees using a weighted linear interpolation of each magnitude value across the 2 nearest angular bin orientations. 2D overlapping blocks of histogram bins consisting of the bins from 2D arrangements of cells are then contrast normalized using L2 normalization and output to the corresponding histogram descriptor window for that particular window location in the window locations list.

Some restrictions include:

* #define NPP_HOG_MAX_CELL_SIZE (16)
* #define NPP_HOG_MAX_BLOCK_SIZE (64)
*

Currently only the NPP_BORDER_REPLICATE border type operation is supported.

Common parameters for nppiFilterHistogramOfGradientsBorder functions include:

Parameters
pSrc Source-Image Pointer.
nSrcStep Source-Image Line Step.
oSrcSize Source image width and height in pixels relative to pSrc.
oSrcOffset The pixel offset that pSrc points to relative to the origin of the source image.
hpLocations Host pointer to array of NppiPoint source pixel starting locations of requested descriptor windows. Important: hpLocations is a host pointer.
nLocations Number of NppiPoint in pLocations array.
pDstWindowDescriptorBuffer Output device memory buffer pointer of size hpDescriptorsSize bytes to first of nLoc descriptor windows (see nppiHistogramOfGradientsBorderGetDescriptorsSize() above).
oSizeROI Region-of-Interest (ROI) of source image.
oHOGConfig Requested HOG configuration parameters structure.
pScratchBuffer Device memory buffer pointer of size hpBufferSize bytes to scratch memory buffer (see nppiHistogramOfGradientsBorderGetBufferSize() above).
eBorderType The border type operation to be applied at source image border boundaries.
nppStreamCtx Application Managed Stream Context.
Returns
Image Data Related Error Codes, ROI Related Error Codes

Function Documentation

NppStatus nppiHistogramOfGradientsBorder_16s32f_C1R ( const Npp16s pSrc,
int  nSrcStep,
NppiSize  oSrcSize,
NppiPoint  oSrcOffset,
const NppiPoint hpLocations,
int  nLocations,
Npp32f pDstWindowDescriptorBuffer,
NppiSize  oSizeROI,
const NppiHOGConfig  oHOGConfig,
Npp8u pScratchBuffer,
NppiBorderType  eBorderType 
)
NppStatus nppiHistogramOfGradientsBorder_16s32f_C1R_Ctx ( const Npp16s pSrc,
int  nSrcStep,
NppiSize  oSrcSize,
NppiPoint  oSrcOffset,
const NppiPoint hpLocations,
int  nLocations,
Npp32f pDstWindowDescriptorBuffer,
NppiSize  oSizeROI,
const NppiHOGConfig  oHOGConfig,
Npp8u pScratchBuffer,
NppiBorderType  eBorderType,
NppStreamContext  nppStreamCtx 
)

1 channel 16-bit signed grayscale per source image descriptor window location with source image border control to per descriptor window destination floating point histogram of gradients.

Requires first calling nppiHistogramOfGradientsBorderGetBufferSize function call to get required scratch (host) working buffer size and nppiHistogramOfGradientsBorderGetDescriptorsSize() function call to get total size for nLocations of output histogram block descriptor windows.

For common parameter descriptions, see Common parameters for nppiFilterHistogramOfGradientsBorder functions.

NppStatus nppiHistogramOfGradientsBorder_16s32f_C3R ( const Npp16s pSrc,
int  nSrcStep,
NppiSize  oSrcSize,
NppiPoint  oSrcOffset,
const NppiPoint hpLocations,
int  nLocations,
Npp32f pDstWindowDescriptorBuffer,
NppiSize  oSizeROI,
const NppiHOGConfig  oHOGConfig,
Npp8u pScratchBuffer,
NppiBorderType  eBorderType 
)
NppStatus nppiHistogramOfGradientsBorder_16s32f_C3R_Ctx ( const Npp16s pSrc,
int  nSrcStep,
NppiSize  oSrcSize,
NppiPoint  oSrcOffset,
const NppiPoint hpLocations,
int  nLocations,
Npp32f pDstWindowDescriptorBuffer,
NppiSize  oSizeROI,
const NppiHOGConfig  oHOGConfig,
Npp8u pScratchBuffer,
NppiBorderType  eBorderType,
NppStreamContext  nppStreamCtx 
)

3 channel 16-bit signed color per source image descriptor window location with source image border control to per descriptor window destination floating point histogram of gradients.

Requires first calling nppiHistogramOfGradientsBorderGetBufferSize function call to get required scratch (host) working buffer size and nppiHistogramOfGradientsBorderGetDescriptorsSize() function call to get total size for nLocations of output histogram block descriptor windows.

For common parameter descriptions, see Common parameters for nppiFilterHistogramOfGradientsBorder functions.

NppStatus nppiHistogramOfGradientsBorder_16u32f_C1R ( const Npp16u pSrc,
int  nSrcStep,
NppiSize  oSrcSize,
NppiPoint  oSrcOffset,
const NppiPoint hpLocations,
int  nLocations,
Npp32f pDstWindowDescriptorBuffer,
NppiSize  oSizeROI,
const NppiHOGConfig  oHOGConfig,
Npp8u pScratchBuffer,
NppiBorderType  eBorderType 
)
NppStatus nppiHistogramOfGradientsBorder_16u32f_C1R_Ctx ( const Npp16u pSrc,
int  nSrcStep,
NppiSize  oSrcSize,
NppiPoint  oSrcOffset,
const NppiPoint hpLocations,
int  nLocations,
Npp32f pDstWindowDescriptorBuffer,
NppiSize  oSizeROI,
const NppiHOGConfig  oHOGConfig,
Npp8u pScratchBuffer,
NppiBorderType  eBorderType,
NppStreamContext  nppStreamCtx 
)

1 channel 16-bit unsigned grayscale per source image descriptor window location with source image border control to per descriptor window destination floating point histogram of gradients.

Requires first calling nppiHistogramOfGradientsBorderGetBufferSize function call to get required scratch (host) working buffer size and nppiHistogramOfGradientsBorderGetDescriptorsSize() function call to get total size for nLocations of output histogram block descriptor windows.

For common parameter descriptions, see Common parameters for nppiFilterHistogramOfGradientsBorder functions.

NppStatus nppiHistogramOfGradientsBorder_16u32f_C3R ( const Npp16u pSrc,
int  nSrcStep,
NppiSize  oSrcSize,
NppiPoint  oSrcOffset,
const NppiPoint hpLocations,
int  nLocations,
Npp32f pDstWindowDescriptorBuffer,
NppiSize  oSizeROI,
const NppiHOGConfig  oHOGConfig,
Npp8u pScratchBuffer,
NppiBorderType  eBorderType 
)
NppStatus nppiHistogramOfGradientsBorder_16u32f_C3R_Ctx ( const Npp16u pSrc,
int  nSrcStep,
NppiSize  oSrcSize,
NppiPoint  oSrcOffset,
const NppiPoint hpLocations,
int  nLocations,
Npp32f pDstWindowDescriptorBuffer,
NppiSize  oSizeROI,
const NppiHOGConfig  oHOGConfig,
Npp8u pScratchBuffer,
NppiBorderType  eBorderType,
NppStreamContext  nppStreamCtx 
)

3 channel 16-bit unsigned color per source image descriptor window location with source image border control to per descriptor window destination floating point histogram of gradients.

Requires first calling nppiHistogramOfGradientsBorderGetBufferSize function call to get required scratch (host) working buffer size and nppiHistogramOfGradientsBorderGetDescriptorsSize() function call to get total size for nLocations of output histogram block descriptor windows.

For common parameter descriptions, see Common parameters for nppiFilterHistogramOfGradientsBorder functions.

NppStatus nppiHistogramOfGradientsBorder_32f_C1R ( const Npp32f pSrc,
int  nSrcStep,
NppiSize  oSrcSize,
NppiPoint  oSrcOffset,
const NppiPoint hpLocations,
int  nLocations,
Npp32f pDstWindowDescriptorBuffer,
NppiSize  oSizeROI,
const NppiHOGConfig  oHOGConfig,
Npp8u pScratchBuffer,
NppiBorderType  eBorderType 
)
NppStatus nppiHistogramOfGradientsBorder_32f_C1R_Ctx ( const Npp32f pSrc,
int  nSrcStep,
NppiSize  oSrcSize,
NppiPoint  oSrcOffset,
const NppiPoint hpLocations,
int  nLocations,
Npp32f pDstWindowDescriptorBuffer,
NppiSize  oSizeROI,
const NppiHOGConfig  oHOGConfig,
Npp8u pScratchBuffer,
NppiBorderType  eBorderType,
NppStreamContext  nppStreamCtx 
)

1 channel 32-bit floating point grayscale per source image descriptor window location with source image border control to per descriptor window destination floating point histogram of gradients.

Requires first calling nppiHistogramOfGradientsBorderGetBufferSize function call to get required scratch (host) working buffer size and nppiHistogramOfGradientsBorderGetDescriptorsSize() function call to get total size for nLocations of output histogram block descriptor windows.

For common parameter descriptions, see Common parameters for nppiFilterHistogramOfGradientsBorder functions.

NppStatus nppiHistogramOfGradientsBorder_32f_C3R ( const Npp32f pSrc,
int  nSrcStep,
NppiSize  oSrcSize,
NppiPoint  oSrcOffset,
const NppiPoint hpLocations,
int  nLocations,
Npp32f pDstWindowDescriptorBuffer,
NppiSize  oSizeROI,
const NppiHOGConfig  oHOGConfig,
Npp8u pScratchBuffer,
NppiBorderType  eBorderType 
)
NppStatus nppiHistogramOfGradientsBorder_32f_C3R_Ctx ( const Npp32f pSrc,
int  nSrcStep,
NppiSize  oSrcSize,
NppiPoint  oSrcOffset,
const NppiPoint hpLocations,
int  nLocations,
Npp32f pDstWindowDescriptorBuffer,
NppiSize  oSizeROI,
const NppiHOGConfig  oHOGConfig,
Npp8u pScratchBuffer,
NppiBorderType  eBorderType,
NppStreamContext  nppStreamCtx 
)

3 channel 32-bit floating point color per source image descriptor window location with source image border control to per descriptor window destination floating point histogram of gradients.

Requires first calling nppiHistogramOfGradientsBorderGetBufferSize function call to get required scratch (host) working buffer size and nppiHistogramOfGradientsBorderGetDescriptorsSize() function call to get total size for nLocations of output histogram block descriptor windows.

For common parameter descriptions, see Common parameters for nppiFilterHistogramOfGradientsBorder functions.

NppStatus nppiHistogramOfGradientsBorder_8u32f_C1R ( const Npp8u pSrc,
int  nSrcStep,
NppiSize  oSrcSize,
NppiPoint  oSrcOffset,
const NppiPoint hpLocations,
int  nLocations,
Npp32f pDstWindowDescriptorBuffer,
NppiSize  oSizeROI,
const NppiHOGConfig  oHOGConfig,
Npp8u pScratchBuffer,
NppiBorderType  eBorderType 
)
NppStatus nppiHistogramOfGradientsBorder_8u32f_C1R_Ctx ( const Npp8u pSrc,
int  nSrcStep,
NppiSize  oSrcSize,
NppiPoint  oSrcOffset,
const NppiPoint hpLocations,
int  nLocations,
Npp32f pDstWindowDescriptorBuffer,
NppiSize  oSizeROI,
const NppiHOGConfig  oHOGConfig,
Npp8u pScratchBuffer,
NppiBorderType  eBorderType,
NppStreamContext  nppStreamCtx 
)

1 channel 8-bit unsigned grayscale per source image descriptor window location with source image border control to per descriptor window destination floating point histogram of gradients.

Requires first calling nppiHistogramOfGradientsBorderGetBufferSize function call to get required scratch (host) working buffer size and nppiHistogramOfGradientsBorderGetDescriptorsSize() function call to get total size for nLocations of output histogram block descriptor windows.

For common parameter descriptions, see Common parameters for nppiFilterHistogramOfGradientsBorder functions.

NppStatus nppiHistogramOfGradientsBorder_8u32f_C3R ( const Npp8u pSrc,
int  nSrcStep,
NppiSize  oSrcSize,
NppiPoint  oSrcOffset,
const NppiPoint hpLocations,
int  nLocations,
Npp32f pDstWindowDescriptorBuffer,
NppiSize  oSizeROI,
const NppiHOGConfig  oHOGConfig,
Npp8u pScratchBuffer,
NppiBorderType  eBorderType 
)
NppStatus nppiHistogramOfGradientsBorder_8u32f_C3R_Ctx ( const Npp8u pSrc,
int  nSrcStep,
NppiSize  oSrcSize,
NppiPoint  oSrcOffset,
const NppiPoint hpLocations,
int  nLocations,
Npp32f pDstWindowDescriptorBuffer,
NppiSize  oSizeROI,
const NppiHOGConfig  oHOGConfig,
Npp8u pScratchBuffer,
NppiBorderType  eBorderType,
NppStreamContext  nppStreamCtx 
)

3 channel 8-bit unsigned color per source image descriptor window location with source image border control to per descriptor window destination floating point histogram of gradients.

Requires first calling nppiHistogramOfGradientsBorderGetBufferSize function call to get required scratch (host) working buffer size and nppiHistogramOfGradientsBorderGetDescriptorsSize() function call to get total size for nLocations of output histogram block descriptor windows.

For common parameter descriptions, see Common parameters for nppiFilterHistogramOfGradientsBorder functions.

NppStatus nppiHistogramOfGradientsBorderGetBufferSize ( const NppiHOGConfig  oHOGConfig,
const NppiPoint hpLocations,
int  nLocations,
NppiSize  oSizeROI,
int *  hpBufferSize 
)

Validates requested HOG configuration and calculates scratch buffer size needed for the HistogramOfGradientsBorder function based on requested HOG configuration, source image ROI, and number and locations of descriptor window locations.

Parameters
oHOGConfig Requested HOG configuration parameters structure.
hpLocations Host pointer to array of NppiPoint source pixel starting locations of requested descriptor windows. Important: hpLocations is a host pointer.
nLocations Number of NppiPoint in pLocations array.
oSizeROI Region-of-Interest (ROI) of source image.
hpBufferSize Required buffer size in bytes. Important: hpBufferSize is a host pointer. Scratch Buffer and Host Pointer.
Returns
Image Data Related Error Codes, ROI Related Error Codes
NppStatus nppiHistogramOfGradientsBorderGetDescriptorsSize ( const NppiHOGConfig  oHOGConfig,
int  nLocations,
int *  hpDescriptorsSize 
)

Validates requested HOG configuration and calculates output window descriptors buffer size needed for the HistogramOfGradientsBorder function based on requested HOG configuration, and number of descriptor window locations, one descriptor window is output for each location.

Descriptor windows are located sequentially and contiguously in the descriptors buffer.

The number of horizontal overlapping block histogram bins per descriptor window width is determined by (((oHOGConfig.detectionWindowSize.width / oHOGConfig.histogramBlockSize) * 2) - 1) * oHOGConfig.nHistogramBins. The number of vertical overlapping block histograms per descriptor window height is determined by (((oHOGConfig.detectionWindowSize.height / oHOGConfig.histogramBlockSize) * 2) - 1) The offset of each descriptor window in the descriptors output buffer is therefore horizontal histogram bins per descriptor window width * vertical histograms per descriptor window height floating point values relative to the previous descriptor window output.

Parameters
oHOGConfig Requested HOG configuration parameters structure.
nLocations Number of NppiPoint in pLocations array.
hpDescriptorsSize Required buffer size in bytes of output windows descriptors for nLocations descriptor windows. Important: hpDescriptorsSize is a host pointer.
Returns
Image Data Related Error Codes, ROI Related Error Codes