A Novel Hexagonal Search Algorithm for Fast Block Matching Motion Estimation

Based on real-world image sequence characteristics of center-biased motion vector distribution, a Hexagonal (HS) algorithm with center-biased checking point pattern for fast block motion estimation is proposed. The HS is compared with full search (FS), four-step search (4SS), new three-step search (NTSS), and recently proposed diamond search (DS) methods. Experimental results show that the proposed technique provides competitive performance with reduced computational complexity.


INTRODUCTION
Motion compensated video coding, which predicts current frame from I and P frames, has been widely used to exploit the temporal redundancy between consecutive frames. Motion estimation plays an important role in such an interframe predictive video coding system. Among different types of motion estimation algorithms, the block matching technique has been adopted in many compression standards, such as H.261 [1], MPEG-1 [2], MPEG-2 [3], and MPEG-4 [4]. In block matching, video data, frames, or video object planes (VOPs) are divided into blocks and one motion vector (MV) is associated with each block-A video object (VO) in MPEG-4 is an arbitrarily shape video segment that has a semantic meaning. A 2D snapshot of a VO at a particular time instant is called video object plane. For each block of the current frame/VOP, an MV is derived which points to the best matching block of the previous (reference) frame/VOP. Then the best match block is used as the predictor for the current block.
The full search (FS) block matching algorithm is the simplest but the most compute-intensive solution as it provides the optimal solution by matching all the possible displaced blocks within a given search range in the reference frame/VOP. In order to speed up MV derivation, many fast block matching motion estimation (BMME) algorithms have been proposed such as three-step search (3SS) [5], one-ata-time search (OTS) [6], four-step search (4SS) [7], new three-step search (NTSS) [8], and diamond search (DS) [9].
The objective of these fast BMME algorithms is to find the MV that minimizes the image error by reducing the number of checking points within the search window. Of these, 3SS and OTS algorithms are known to have the tendency to be trapped into a local minimum, thereby degrading performance. Based on the analysis of the above-mentioned fast BMMEs and a study of MV distribution of real-world test video sequences, a new hexagonal search (HS) algorithm is proposed in this paper. In Section 2, we introduce the design motivation of the proposed algorithm. The algorithm description and simulation results are presented in Sections 3 and 4, respectively. Finally, we give conclusions in Section 5.

DESIGN MOTIVATION
Experimental results [7,9] have shown that the block motion field of real-world video sequences is usually smooth, and varies slowly. That leads to a center-biased global minimum MV distribution instead of a uniform distribution. This can be observed from the MV distribution based on the FS algorithm for the first 100 frames of two test video sequences: the well-known News, and the Rallycross. The object-based MPEG-4 video standard segments the frames of video sequences into video objects (VOs). We have studied the MV distribution of News 0, News 1 VOs, and Rallycross. For the News 0 (background object) sequence, nearly all the blocks (97.55%) can be considered stationary (Figure 1a). For the News 1 (dancer) sequence of faster motion and camera zooming, the MV distribution is still highly center-biased: 48.31% found at the center of the search area, and 80% of them are enclosed in a central 5 × 5 area (Figure 1b). For the nonsegmented fast motion sequence Rallycross, 52.76% of its MVs are enclosed in a central 5 × 5 area and 61.16% are located in a central search 9 × 9 area (Figure 1c). Since the distribution of the global minimum point in real-world video is centered at zero, fast BMME algorithms have been developed using center-biased checking point patterns. Analytically, the NTSS employs a center-biased checking point pattern combined with a halfway-stop technique, and achieves better performance than TSS. Using a moderate search pattern with fixed size of 5 × 5, the 4SS obtains a performance that is similar to NTSS. DS employs two diamond search patterns of size 9 × 9 and 3 × 3, respectively, which do not cover edge points of the search area. It becomes clear that the shape and the size of the above mentioned search patterns jointly determine not only the image quality (error performance) but also the computational complexity of fast BMMEs.
Based on the observation that global minimum distribution is centralized in real-world sequences, the search points positions included to a zero-centered search 5 × 5 area are the most appropriate ones to be chosen to compose the search pattern. This choice is quite crucial in terms of algorithm's complexity and performance. This is the motivation behind the new hexagonal search (HS) algorithm proposed here.

THE HEXAGONAL SEARCH ALGORITHM (HS)
Since motion vectors are not evenly distributed in the search area (in fact most of them are located inside a centre-biased window of size 9 × 9), the HS patterns are designed to take into account the following: (i) reduced computational complexity: the point where the minimum block distortion (MBD) occurs should be tracked using a small number of checking points, which cover a significant portion of the center-biased search window, (ii) search patterns shape: when the MBD point for one step is located, the search pattern has to be shaped in such a way that allows a refined search which covers all searching points around the MBD point in order to derive the MBD point for the best matching block.
As shown in Figure 2, the HS algorithm utilises a centrebiased search pattern of seven checking points, out of which six points surround the centre one to compose a hexagon (Step 1). The hexagon points are checked and the centre of the hexagonal search window is then shifted to the point with MBD. The search pattern and its size, for the next two steps of the HS, depend on the location of the MBD points. If the MBD point is found at the center of the hexagonal pattern, the search proceeds to the final step (Step 3), with a smaller search pattern for a refinement search. Otherwise, the hexagonal search pattern is applied repeatedly until the MBD point is found at the center of the hexagon (Step 2). When the final step (Step 3) is reached, the search pattern is changed from hexagonal to a star ( Figure 2b) with a variable number of search points, the best case is 4 and the worst is 6. For edge points of the search area the hexagonal search pattern (Step 2) is modified (Figure 3). The HS algorithm is summarised as follows.
Step 1. The initial hexagonal pattern is centered at the origin of the search window and the seven checking points (•) of the hexagon are tested (Figure 2a). If the MBD point is found at the center position then go to Step 3, otherwise go to Step 2.
Step 2. The MBD point found in the previous search step is repositioned as the center point to form a new hexagon. If the new MBD point obtained is located at the centre position, go to Step 3; otherwise, recursively repeat Step 2. The hexagonal pattern is modified on the borders of the search area in order to cover the edge points. Figure 3a  Note that the checking points of the hexagon search pattern are partially overlapping when Step 2 is repeated. Only three checking points need to be calculated in the new pattern. In addition, at Step 3 when the search pattern changes from hexagon to star, three, four, or six points of the star need to be calculated, depending on the star's MBD point location. Figure 4 presents an example of how the HS derives an MV from the borders of the search area, MV (−7, 7).

SIMULATIONS
In our simulations, the MBD is defined to be the sum of absolute difference (SAD). For a given displacement (x, y), SAD is defined as (see [10,11]), I k (x, y) is the pixel intensity (luminance or Y component) at location (x, y) in the kth frame/VOP, and α k refers to the current VOP at time instance k and contains the information of which pixels are inside the object (α k > 0) and which are not (α k = 0 (MSE is the mean squared error.) The required average number of search points for each block is used as the measure of computational complexity. Each video sequence is processed by five algorithms: FS, DS, 4SS, NTSS, and the proposed HS. The degree of computational complexity of each algorithm with respect to full search algorithm is calculated. The simulation results are shown in Tables 1, 2, and Figure 5. The simulation shows that HS performs better than DS, 4SS, and NTSS for all the video sequence with similar performance to FS in terms of PSNR, Figures 5, 6 and Tables 1, 2.

CONCLUSIONS
In this paper, the HS algorithm is proposed to perform block motion estimation in video coding. Based on the observations that global minimum distribution is centralized in realworld video sequences and that the shape and size of the search patterns determine not only the performance but also the computational complexity of fast BMMEs, the HS employs a center-biased hexagon search pattern. Experimental results show that the proposed HS outperforms DS, 4SS, and NTSS search algorithms, having always better average computational complexity (slow, medium, fast motion) with similar performance to FS in terms of PSNR.