Image Statistics
Calculate mean, variance, and standard deviation
Libraries:
Vision HDL Toolbox /
Statistics
Description
The Image Statistics block calculates the mean, variance, and standard deviation of streaming video data. Each calculation is performed over all pixels in the input region of interest (ROI). The block implements the calculations by using hardware-efficient algorithms.
This block uses a streaming pixel interface with a bus for frame control signals. This interface enables the block to operate independently of image size and format. All Vision HDL Toolbox™ blocks use the same streaming interface. The block accepts a scalar pixel value and a bus that contains five control signals. The control signals indicate the validity of each pixel and its location in the frame. To convert a frame (pixel matrix) into a pixel stream and control signals, use the Frame To Pixels block. For a full description of the interface, see Streaming Pixel Interface.
Ports
Input
Output
Parameters
Tips
To change the size and dimensions of the ROI, you can manipulate the input video stream control signals. See Regions of Interest.
The number of valid pixels in the input image affects the accuracy of the mean approximation. To avoid approximation error, use an image that contains a multiple of 64n pixels, up to 64n+1 pixels, where n equals 0, 1, 2, or 3. For details of the mean approximation, see Algorithm.
The block calculates statistics over frames up to 644 (16, 777, 216) pixels in size. This size supports HD frames.
Algorithms
Extended Capabilities
Version History
Introduced in R2015a
See Also
2-D
Mean (Computer Vision Toolbox) | 2-D
Variance (Computer Vision Toolbox) | 2-D
Standard Deviation (Computer Vision Toolbox) | Frame To Pixels | visionhdl.ImageStatistics