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

Primitives for computing the stansdard deviation of the integral images. More...

RectStdDev

NppStatus nppiRectStdDev_32f_C1R_Ctx (const Npp32f *pSrc, int nSrcStep, const Npp64f *pSqr, int nSqrStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, NppiRect oRect, NppStreamContext nppStreamCtx)
 One-channel 32-bit floating point image RectStdDev. More...
 
NppStatus nppiRectStdDev_32f_C1R (const Npp32f *pSrc, int nSrcStep, const Npp64f *pSqr, int nSqrStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, NppiRect oRect)
 
NppStatus nppiRectStdDev_32s_C1RSfs_Ctx (const Npp32s *pSrc, int nSrcStep, const Npp32s *pSqr, int nSqrStep, Npp32s *pDst, int nDstStep, NppiSize oSizeROI, NppiRect oRect, int nScaleFactor, NppStreamContext nppStreamCtx)
 One-channel 32-bit signed image RectStdDev, scaled by $2^(-nScaleFactor)$. More...
 
NppStatus nppiRectStdDev_32s_C1RSfs (const Npp32s *pSrc, int nSrcStep, const Npp32s *pSqr, int nSqrStep, Npp32s *pDst, int nDstStep, NppiSize oSizeROI, NppiRect oRect, int nScaleFactor)
 
NppStatus nppiRectStdDev_32s32f_C1R_Ctx (const Npp32s *pSrc, int nSrcStep, const Npp64f *pSqr, int nSqrStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, NppiRect oRect, NppStreamContext nppStreamCtx)
 One-channel 32-bit signed image RectStdDev. More...
 
NppStatus nppiRectStdDev_32s32f_C1R (const Npp32s *pSrc, int nSrcStep, const Npp64f *pSqr, int nSqrStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, NppiRect oRect)
 

Detailed Description

Primitives for computing the stansdard deviation of the integral images.

The function computes the standard deviation of the pixel in the rectangular window with the integral image $pSrc$ and the squared integral image $pSqr$, which can be obtained by calling Integral and SqrIntegral.

The standard deviation of the pixel $(j, i)$ can be computed using the formula:

\[pDst(j, i) = \sqrt{max(0, \frac{\sum(SqrIntegral)\cdot N - (\sum(Integral))^2}{N^2})}\]

where $\sum(SqrIntegral) = pSqr[j+oRect.y+oRect.height, i+oRect.x+oRect.width] - pSqr[j+oRect.y,i+oRect.x+oRect.width] - pSqr[j+oRect.y+oRect.height, i+oRect.x] + pSqr[j+oRect.y, i+oRect.x]$, $\sum(Integral) = pSrc[j+oRect.y+oRect.height, i+oRect.x+oRect.width] - pSrc[j+oRect.y,i+oRect.x+oRect.width] - pSrc[j+oRect.y+oRect.height, i+oRect.x] + pSrc[j+oRect.y, i+oRect.x]$, $N = oRect.width \cdot oRect.height$.

The size of the $pSrc$ and $pSqr$ should be $(oSizeROI.width + oRect.x + oRect.width, oSizeROI.height + oRect.y + oRect.height).$

Function Documentation

NppStatus nppiRectStdDev_32f_C1R ( const Npp32f pSrc,
int  nSrcStep,
const Npp64f pSqr,
int  nSqrStep,
Npp32f pDst,
int  nDstStep,
NppiSize  oSizeROI,
NppiRect  oRect 
)
NppStatus nppiRectStdDev_32f_C1R_Ctx ( const Npp32f pSrc,
int  nSrcStep,
const Npp64f pSqr,
int  nSqrStep,
Npp32f pDst,
int  nDstStep,
NppiSize  oSizeROI,
NppiRect  oRect,
NppStreamContext  nppStreamCtx 
)
NppStatus nppiRectStdDev_32s32f_C1R ( const Npp32s pSrc,
int  nSrcStep,
const Npp64f pSqr,
int  nSqrStep,
Npp32f pDst,
int  nDstStep,
NppiSize  oSizeROI,
NppiRect  oRect 
)
NppStatus nppiRectStdDev_32s32f_C1R_Ctx ( const Npp32s pSrc,
int  nSrcStep,
const Npp64f pSqr,
int  nSqrStep,
Npp32f pDst,
int  nDstStep,
NppiSize  oSizeROI,
NppiRect  oRect,
NppStreamContext  nppStreamCtx 
)
NppStatus nppiRectStdDev_32s_C1RSfs ( const Npp32s pSrc,
int  nSrcStep,
const Npp32s pSqr,
int  nSqrStep,
Npp32s pDst,
int  nDstStep,
NppiSize  oSizeROI,
NppiRect  oRect,
int  nScaleFactor 
)
NppStatus nppiRectStdDev_32s_C1RSfs_Ctx ( const Npp32s pSrc,
int  nSrcStep,
const Npp32s pSqr,
int  nSqrStep,
Npp32s pDst,
int  nDstStep,
NppiSize  oSizeROI,
NppiRect  oRect,
int  nScaleFactor,
NppStreamContext  nppStreamCtx 
)

One-channel 32-bit signed image RectStdDev, scaled by $2^(-nScaleFactor)$.

Parameters
pSrcSource-Image Pointer.
nSrcStepSource-Image Line Step.
pSqrDestination-Image Pointer.
nSqrStepDestination-Image Line Step.
pDstDestination-Image Pointer.
nDstStepDestination-Image Line Step.
oSizeROIRegion-of-Interest (ROI).
oRectrectangular window
nScaleFactorInteger Result Scaling.
nppStreamCtxApplication Managed Stream Context.
Returns
Image Data Related Error Codes, ROI Related Error Codes

Copyright © 2009-2022 NVIDIA CORPORATION AND AFFILIATES