CH-4 – Features Extraction – Part-4

Important Note: This article is part of the series in which discusses the theory of Video Stream Matching.

In the realm of Video Stream Matching, four essential features are integral:

  1. Histogram
  2. Edge
  3. Slope
  4. Wavelet

Here, we will delve into the algorithms associated with each of these features one by one.

4.4.1 Histogram Feature Extraction Algorithm 2

As outlined in Chapter 3.


  • BMP Image


  • Array of numerical values defining the Histogram


  1. The algorithm takes an image as input.
  2. If the image is not already in grayscale, it is converted into grayscale.
  3. The image is then divided into tiles, and the histogram of each tile is calculated.
  4. The calculated histograms are stored in columns and rows, forming a 2D array that represents the result.

Algorithm Steps:

  • Step 0: Start
  • Step 1: Take input of an image (im).
  • Step 2: Check if (im) is in grayscale. If not, convert (im) into grayscale.
  • Steps 3-8: Loop through tiles of the image, extract sub-images, calculate histograms (H), increment the number of bins (NumBins), and store the histograms in the resultant array (ResArray).
  • Step 9: Return the resulting array (ResArray).
  • Step 10: Stop
Ali Imran
Over the past 20+ years, I have been working as a software engineer, architect, and programmer, creating, designing, and programming various applications. My main focus has always been to achieve business goals and transform business ideas into digital reality. I have successfully solved numerous business problems and increased productivity for small businesses as well as enterprise corporations through the solutions that I created. My strong technical background and ability to work effectively in team environments make me a valuable asset to any organization.

Leave a Reply