CN102572438B - Motion predication method based on image texture and motion features - Google Patents
Motion predication method based on image texture and motion features Download PDFInfo
- Publication number
- CN102572438B CN102572438B CN201210040779.0A CN201210040779A CN102572438B CN 102572438 B CN102572438 B CN 102572438B CN 201210040779 A CN201210040779 A CN 201210040779A CN 102572438 B CN102572438 B CN 102572438B
- Authority
- CN
- China
- Prior art keywords
- motion
- block
- mvy
- value
- sad
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Landscapes
- Compression Or Coding Systems Of Tv Signals (AREA)
Abstract
本发明提供一种基于图像纹理和运动特征的运动预测方法,包括步骤:A:确定当前待匹配分割块在宏块中的位置(I,J),并计算出当前待匹配分割块的边缘强度值ESM,I,J:B:确定参考块的运动向量(MVx,MVy),并分别得到其对应的绝对差异总值SADM,I,J(MVx,MVy)和运动向量MV值,C:设置阈值SADTH;D:判断参考块的绝对差异总值SADM,I,J(MVx,MVy)是否小于所述阈值SADTH,如果是,则提前终止搜索,以当前参考块作为最优的参考块;否则,返回步骤B继续在其他参考块中寻找最优参考块。应用本发明所述的方法,有效减少了块匹配算法中的冗余计算,从而达到减少功耗的目的。本发明所提出的方法适合硬件实现,其特征是用加减、移位和比较三种简单操作实现阈值的生成与判定。
The present invention provides a motion prediction method based on image texture and motion features, comprising steps: A: determining the position (I, J) of the current block to be matched in the macroblock, and calculating the edge strength of the block to be matched currently Value ES M, I, J : B: Determine the motion vector (MVx, MVy) of the reference block, and obtain its corresponding absolute difference total value SAD M, I, J (MVx, MVy) and motion vector MV value, C : set the threshold SAD TH ; D: determine whether the total absolute difference SAD M, I, J (MVx, MVy) of the reference block is less than the threshold SAD TH , if yes, terminate the search in advance, and use the current reference block as the optimal the reference block; otherwise, return to step B and continue to search for the optimal reference block in other reference blocks. By applying the method of the invention, the redundant calculation in the block matching algorithm is effectively reduced, thereby achieving the purpose of reducing power consumption. The method proposed by the invention is suitable for hardware realization, and is characterized in that three simple operations of addition and subtraction, shifting and comparison are used to realize the generation and judgment of the threshold.
Description
技术领域 technical field
本发明涉及视频处理技术领域,尤其涉及一种基于图像纹理和运动特征的运动预测方法。The invention relates to the technical field of video processing, in particular to a motion prediction method based on image texture and motion features.
背景技术 Background technique
随着高清视频应用的普及,受通信信道带宽及存储能力的限制,用户对视频压缩的性能提出了越来越高的要求。如何在不损失视频质量,或者是损失很小的视频质量的情况下获得较大的压缩率,成为视频编解码标准制定者的新目标。H.264/AVC标准就是在上述背景下被提出并日趋完善。然而,H.264/AVC标准是建立在高复杂度的基础之上,尤其是其编码算法的复杂度比上一代协议提高了一个数量级。其中,编码过程中运动预测方法需消耗近70%的计算资源。这会导致过大的硬件代价以及相应的功耗开销。于是如何优化运动预测方法,减少其中的冗余运算成为H.264/AVC编码硬件设计所关注的重要问题。With the popularity of high-definition video applications, users have higher and higher requirements for video compression performance due to the limitation of communication channel bandwidth and storage capacity. How to obtain a larger compression rate without losing video quality, or with a small loss of video quality, has become a new goal for video codec standard makers. The H.264/AVC standard was proposed and improved day by day under the above-mentioned background. However, the H.264/AVC standard is based on high complexity, especially the complexity of its encoding algorithm is an order of magnitude higher than that of the previous generation protocol. Among them, the motion prediction method consumes nearly 70% of computing resources in the encoding process. This results in excessive hardware overhead and corresponding power overhead. Therefore, how to optimize the motion prediction method and reduce redundant operations has become an important issue in H.264/AVC encoding hardware design.
H.264/AVC标准规定了编码的接口规范,即输出码流的规范。开发H.264/AVC标准的JVT团队发布了H.264/AVC的开源代码,即JM软件。JM软件由C代码编写而成,符合H.264/AVC的接口规范。JM软件只针对最大化压缩效率,并未在功耗开销上的作相应的考虑,从而造成了大量的计算量冗余。The H.264/AVC standard stipulates the encoding interface specification, that is, the specification of the output code stream. The JVT team that developed the H.264/AVC standard released the open source code of H.264/AVC, namely JM software. JM software is written by C code and complies with the interface specification of H.264/AVC. The JM software only aims at maximizing the compression efficiency, and does not take corresponding consideration in the power consumption overhead, resulting in a large amount of redundant calculation.
在JM软件中,编码器从预定位置,例如左上角,按预定顺序,例如书写顺序,将每一个16×16像素点阵设置为一个宏块(MB)。在对宏块进行编码时,编码器需要用到运动预测方法。运动预测在搜索区域内进行块匹配算法。搜索区域所示范围是以当前宏块作为中心点,距上,下,左,右各为一个可自由设置的搜索长度的方形区间。最优的参考块将在这个搜索框内选取,由当前块指向参考块的向量称为运动向量。运动预测方法的核心思想为:在对每一个16×16像素宏块进行编码前,将当前帧与参考帧进行对比,并视情况对16×16大小的宏块进行分割,其中每种分割称为一种模式。找出残差矩阵各元素的绝对值的总和(称为SAD)最小的宏块或亚宏块作为与此宏块匹配的宏块或亚宏块。其中残差矩阵由两个宏块像素值矩阵对应矩阵点的像素值作差得到。根据对宏块的各种分割方式,JM软件定义了其对应的编码模式,简记为M。确定了当前编码块的块分割模式为M后,运动预测方法会对M模式下的各个分割块以一定的次序进行运动搜索。这个过程中,需要按顺序在运动搜索窗口内计算分割块位于运动向量(MVx和MVy分别为平面直角坐标系中x方向和y方向的分量,记运动向量为(MVx,MVy))处的绝对差异总值SAD(MVx,MVy),如下式所示:In the JM software, the encoder sets each 16×16 pixel dot matrix as a macroblock (MB) from a predetermined position, such as the upper left corner, in a predetermined order, such as writing order. When encoding a macroblock, the encoder needs to use a motion prediction method. Motion prediction performs a block matching algorithm within the search area. The range indicated by the search area is the current macroblock as the center point, and the upper, lower, left, and right distances are each a square interval with a freely configurable search length. The optimal reference block will be selected within this search frame, and the vector from the current block to the reference block is called a motion vector. The core idea of the motion prediction method is: before encoding each 16×16 pixel macroblock, compare the current frame with the reference frame, and divide the 16×16 macroblock according to the situation, and each division is called as a pattern. The macroblock or sub-macroblock with the minimum sum of the absolute values of the elements of the residual matrix (called SAD) is found as the macroblock or sub-macroblock matching the macroblock. The residual matrix is obtained by difference of pixel values of corresponding matrix points of two macroblock pixel value matrices. According to various segmentation methods for macroblocks, JM software defines its corresponding coding mode, abbreviated as M. After determining that the block division mode of the current coding block is M, the motion prediction method will perform a motion search for each division block in the M mode in a certain order. In this process, it is necessary to calculate the motion vector of the segmented block in the motion search window in sequence (MVx and MVy are the components in the x direction and y direction in the plane Cartesian coordinate system respectively, and the total absolute difference SAD(MVx, MVy) where the motion vector is (MVx, MVy) is recorded, as shown in the following formula:
其中M为宏块分割模式值,(I,J)为当前分割块在宏块中的位置,I,J为整数,Ci,j是当前分割块的矩阵点的像素值,i为列数,j为行数,Ri+MVx,j+MVy是参考块中的矩阵点的像素值。H与W分别是所求分割块的高与宽,即总行数与总列数。公式(1)所表示的求和范围即是被处理的分割块内的所有矩阵点,在块的分割方式与位置确定后即可由此求出当前分割块的绝对差异总值SADM,I,J(MVx,MVy),并通过比较得出最小绝对差异总值,从而得出当前分割块的最优编码。Wherein M is the macroblock segmentation mode value, (I, J) is the position of the current segmentation block in the macroblock, I, J are integers, Ci , j is the pixel value of the matrix point of the current segmentation block, and i is the column number , j is the number of rows, R i+MVx, j+MVy are the pixel values of the matrix points in the reference block. H and W are the height and width of the desired segmented block, ie, the total number of rows and the total number of columns. The summation range represented by the formula (1) is all the matrix points in the segmented block to be processed. After the segmented mode and position of the block are determined, the total absolute difference SAD M, I of the current segmented block can be obtained. J (MVx, MVy), and the minimum absolute difference total value is obtained by comparison, so as to obtain the optimal encoding of the current segmented block.
现有的运动预测方法按照一定顺序搜索预定顺序内的各个点。而有些点明显是不必要的搜索点,因此这些不必要的搜索点导致了大量的冗余计算和功耗损失。Existing motion prediction methods search each point within a predetermined sequence according to a certain sequence. And some points are obviously unnecessary search points, so these unnecessary search points lead to a large amount of redundant calculation and power loss.
冗余计算主要存在于决定宏块编码的参考帧与参考帧内的参考宏块的计算过程中,其计算效果决定了编码在压缩率与信噪比方面的质量,其具有大量冗余计算的特点也使其成为功耗优化的重点部分。如果我们在此计算过程中添加适当的提前终止条件,就可以有效去除冗余的计算。提前终止算法的性能评判取决于两方面:其一,是采用提前终止算法后能够节省多少计算操作;其二,是提前终止算法所带来的编码失真度能够保证在多小的范围。Redundant calculation mainly exists in the calculation process of determining the reference frame for macroblock coding and the reference macroblock in the reference frame. The calculation effect determines the quality of coding in terms of compression rate and signal-to-noise ratio. It has a large number of redundant calculations. Features also make it an important part of power optimization. If we add appropriate early termination conditions during this calculation, redundant calculations can be effectively removed. The performance evaluation of the early termination algorithm depends on two aspects: first, how much computing operations can be saved after adopting the early termination algorithm; second, how small the encoding distortion caused by the early termination algorithm can be guaranteed.
发明内容 Contents of the invention
(一)要解决的技术问题(1) Technical problems to be solved
本发明要解决的技术问题是,针对上述缺陷,如何提供一种运算简单、易于硬件实现的基于图像纹理和运动特征的运动预测方法,其在大幅度降低功耗开销的同时,能够保证较低的数字视频信号的编码失真率。The technical problem to be solved by the present invention is how to provide a motion prediction method based on image texture and motion features that is simple in operation and easy to implement in hardware in view of the above defects. The coding distortion rate of the digital video signal.
(二)技术方案(2) Technical solutions
为解决上述技术问题,本发明提供了一种基于图像纹理和运动特征的运动预测方法,包括步骤:In order to solve the above-mentioned technical problems, the present invention provides a kind of motion prediction method based on image texture and motion feature, comprising steps:
A:确定当前待匹配分割块在宏块中的位置(I,J),并根据下式计算出当前待匹配分割块的边缘强度值ESM,I,J:A: Determine the position (I, J) of the current segmentation block to be matched in the macroblock, and calculate the edge strength value ES M, I, J of the current segmentation block to be matched according to the following formula:
其中,M为宏块分割模式值,I,J为整数,Ci,j是当前待匹配分割块的矩阵点的像素值,i为列数,j为行数,H与W分别是当前待匹配分割块的高与宽;Among them, M is the macroblock segmentation mode value, I, J are integers, C i, j are the pixel values of the matrix points of the current block to be matched, i is the number of columns, j is the number of rows, H and W are respectively the current Match the height and width of the split block;
B:确定参考块的运动向量(MVx,MVy),并根据公式B: Determine the motion vector (MVx, MVy) of the reference block, and according to the formula
分别得到其对应的绝对差异总值SADM,I,J(MVx,MVy)和运动向量MV值, Obtain its corresponding absolute difference total value SAD M, I, J (MVx, MVy) and motion vector MV value respectively,
其中Ri+MVx,j+MVy是参考块中的矩阵点的像素值,|MVy|>>1是将参考块的运动向量的纵向分量MVy的幅度用右移操作实现|MVy|/2的除法运算;Among them, R i+MVx, j+MVy are the pixel values of the matrix points in the reference block, and |MVy|>>1 means that the amplitude of the longitudinal component MVy of the motion vector of the reference block is shifted right to realize |MVy|/2 division operation;
C:设置阈值SADTH;C: set the threshold SAD TH ;
D:判断参考块的绝对差异总值SADM,I,J(MVx,MVy)是否小于所述阈值SADTH,如果是,则提前终止搜索,以当前参考块作为最优的参考块;否则,返回步骤B继续在其他参考块中寻找最优参考块。D: Determine whether the total absolute difference SAD M, I, J (MVx, MVy) of the reference block is smaller than the threshold SAD TH , if yes, terminate the search in advance, and use the current reference block as the optimal reference block; otherwise, Return to step B to continue searching for the optimal reference block among other reference blocks.
其中,在步骤A之前进一步包括:确定对哪几种宏块分割模式进行运动估计并确定宏块分割模式值M的步骤。Wherein, before step A, it further includes: a step of determining which macroblock partition modes are used for motion estimation and determining the value M of the macroblock partition mode.
其中,所述步骤C具体包括:Wherein, the step C specifically includes:
根据公式SADTH=F(MV,M)×ESM,I,J设置阈值SADTH,所述F(MV,M)定义为:F(MV,M)=f1(MV)×f2(M),The threshold SAD TH is set according to the formula SAD TH =F(MV, M)×ES M, I, J, and the F(MV, M) is defined as: F(MV, M)=f1(MV)×f2(M) ,
其中所述f1(MV)具体为:Wherein the f1(MV) is specifically:
所述f2(M)具体为:The f2(M) is specifically:
其中,所述步骤C具体包括步骤:Wherein, the step C specifically includes the steps of:
C1:首先计算f2(M)×ESM,I,J的值,记为Pre_TH;C1: first calculate the value of f2(M)×ES M, I, J , and record it as Pre_TH;
C2:然后再将f1(MV)与Pre_TH相乘得到最终的SADTH值。C2: Then multiply f1(MV) and Pre_TH to get the final SAD TH value.
其中,in,
所述M=1时为16×16像素宏块;When M=1, it is a 16×16 pixel macroblock;
所述M=2时为16×8像素分割块;When M=2, it is a 16×8 pixel segmented block;
所述M=3时为8×16像素分割块;When the M=3, it is 8×16 pixel segmentation block;
所述M=4时为8×8像素分割块。When M=4, it is an 8×8 pixel division block.
所述M>4时为行数、列数均小于8的像素分割块。When M>4, it is a pixel division block with both the number of rows and the number of columns less than 8.
(三)有益效果(3) Beneficial effects
本发明公开了一种基于图像纹理和运动特征的运动预测方法,其利用图像纹理特征与图像运动的关系设置阈值,将图像纹理进行适当的量化,应用于基于绝对差异总值的提前终止运动搜索中。表现此动态阈值首先取决于当前被搜索块的纹理强度,同时此阈值与运动向量幅度MV有着正相关的关系。在所示方法中,对MV的大小进行分段,近似认为段内的阈值是相同的。进一步的分段阈值条件,在确定了MV的分段条件f1(MV)后,添加了考虑待匹配分割块块的分割方式参考因子f2(M),以反应块的分割方式对阈值的影响,有效减少了块匹配算法中的冗余计算,从而达到减少功耗的目的。The invention discloses a motion prediction method based on image texture and motion features, which uses the relationship between image texture features and image motion to set a threshold, properly quantizes image texture, and applies it to early termination motion search based on the total value of absolute difference middle. The performance of this dynamic threshold first depends on the texture strength of the currently searched block, and this threshold has a positive correlation with the motion vector magnitude MV. In the shown method, the size of the MV is segmented, and the thresholds within a segment are approximately considered to be the same. For further segmentation threshold conditions, after determining the segmentation condition f1(MV) of the MV, a reference factor f2(M) is added considering the segmentation mode of the block to be segmented to reflect the impact of the segmentation mode of the block on the threshold value, The redundant calculation in the block matching algorithm is effectively reduced, thereby achieving the purpose of reducing power consumption.
本发明所提出的方法适合硬件实现,其特征是用加减、移位和比较三种简单操作实现阈值的生成与判定。The method proposed by the invention is suitable for hardware realization, and is characterized in that three simple operations of addition and subtraction, shifting and comparison are used to realize the generation and judgment of the threshold.
与现有技术相比,本发明所述的方法能够减少20%到80%的功耗开销,同时保证数字视频信号的编码失真率在0.1dB的范围内。Compared with the prior art, the method of the present invention can reduce the power consumption consumption by 20% to 80%, and at the same time ensure that the coding distortion rate of the digital video signal is within the range of 0.1dB.
附图说明 Description of drawings
图1是本发明实施例所述的基于图像纹理和运动特征的运动预测方法的流程图。Fig. 1 is a flowchart of a motion prediction method based on image texture and motion features according to an embodiment of the present invention.
具体实施方式 Detailed ways
下面结合附图和实施例,对本发明的具体实施方式作进一步详细说明。以下实施例用于说明本发明,但不用来限制本发明的范围。The specific implementation manners of the present invention will be described in further detail below in conjunction with the accompanying drawings and examples. The following examples are used to illustrate the present invention, but are not intended to limit the scope of the present invention.
如图1所示,本发明所述的基于图像纹理和运动特征的运动预测方法包括步骤:As shown in Figure 1, the motion prediction method based on image texture and motion feature of the present invention comprises steps:
A:确定当前待匹配分割块在宏块中的位置(I,J),并根据下式计算出当前待匹配分割块的边缘强度值ESM,I,J:A: Determine the position (I, J) of the current segmentation block to be matched in the macroblock, and calculate the edge strength value ES M, I, J of the current segmentation block to be matched according to the following formula:
其中,M为宏块分割模式值,参见JM软件,当M=1时为16×16像素宏块本身;当M=2时为16×8像素分割块;当M=3时为8×16像素分割块;当M=4时为8×8像素分割块等等(其他M值的定义请参见JM软件)。I,J为整数,Ci,j是当前待匹配分割块的矩阵点的像素值,i为列数,j为行数,H与W分别是当前待匹配分割块的高与宽,即总行数与总列数。Wherein, M is the macroblock division mode value, see JM software, when M=1, it is 16×16 pixel macroblock itself; when M=2, it is 16×8 pixel division block; when M=3, it is 8×16 Pixel division block; when M=4, it is 8×8 pixel division block, etc. (For the definition of other M values, please refer to JM software). I, J are integers, C i, j are the pixel values of the matrix points of the current segmentation block to be matched, i is the number of columns, j is the number of rows, H and W are the height and width of the current segmentation block to be matched, that is, the total row number and the total number of columns.
在本步骤之前进一步包括一个确定对哪几种宏块分割模式进行运动估计并确定宏块分割模式值M的步骤。Before this step, it further includes a step of determining which macroblock partition modes are used for motion estimation and determining the value M of the macroblock partition mode.
本步骤的设置依据是,运动预测与图像纹理运动特性之间具有联系:大的运动向量统计意义上对应低频的、平滑的纹理,而小的运动向量统计意义上对应高频的、尖锐的纹理。The basis for setting this step is that there is a relationship between motion prediction and image texture motion characteristics: large motion vectors correspond to low-frequency, smooth textures in a statistical sense, and small motion vectors correspond to high-frequency, sharp textures in a statistical sense .
B:确定参考块的运动向量(MVx,MVy),并根据公式(1)和下式得到其对应的绝对差异总值SADM,I,J(MVx,MVy)和运动向量MV值。B: Determine the motion vector (MVx, MVy) of the reference block, and obtain its corresponding absolute difference total value SAD M, I, J (MVx, MVy) and the motion vector MV value according to formula (1) and the following formula.
MV=|MVx|+(|MVy|>>1) (3)MV=|MVx|+(|MVy|>>1) (3)
对于每一个参考块,均有一个运动向量其水平方向分量为MVx,竖直方向分量为MVy,采用上式得出数值的MV以近似表示当前待匹配分割块的运动复杂度,其中|MVy|>>1是将参考块的运动向量的纵向分量的幅度,即绝对值,用右移操作实现|MVy|/2的除法运算,这样的计算比较简单,更有利于硬件实现。并能够在通常的情况下合适的反映出MV的大小,因为对通常的视频图像而言,其运动向量的水平分量大于竖直分量,更进一步的原因是因为人通常处于重力环境下,习惯于关注水平方向的运动。For each reference block, there is a motion vector The horizontal component is MV x , and the vertical component is MV y . Using the above formula to get the numerical MV to approximate the motion complexity of the current block to be matched, where |MVy|>>1 is the motion complexity of the reference block The magnitude of the vertical component of the vector, that is, the absolute value, is implemented by the right shift operation to realize the division operation of |MVy|/2. This calculation is relatively simple and more conducive to hardware implementation. And it can properly reflect the size of the MV under normal circumstances, because for common video images, the horizontal component of the motion vector is greater than the vertical component, and the further reason is that people are usually in a gravity environment and are used to Focus on movement in the horizontal direction.
C:设置阈值SADTH;C: set the threshold SAD TH ;
在本步骤中,可以根据下式设置阈值SADTH:In this step, the threshold SAD TH can be set according to the following formula:
SADTH=F(MV,M)×ESM,I,J (4)SAD TH = F(MV, M) × ES M, I, J (4)
其中F(MV,M)定义为:where F(MV,M) is defined as:
F(MV,M)=f1(MV)×f2(M) (5)F(MV,M)=f1(MV)×f2(M) (5)
上式中的f1(MV)具体为:f1(MV) in the above formula is specifically:
上式反映运动情况对图像纹理的影响。其分段标准是根据现阶段视频的一般属性制定的。如果视频中的运动向量因为一些原因而改变,f1(MV)具体的值与分段方式可以进行更新,但其基本思想依然不变,即运动越剧烈,图像细节越不明显。例如因为图像的分辨率大幅提高的情况下,以像素点为单位的运动向量的MV会大幅增大,此时,以上MV的分段区间就应该进行适当的调整。The above formula reflects the influence of motion on image texture. The segmentation standard is formulated according to the general attributes of the current video. If the motion vector in the video changes for some reason, the specific value and segmentation method of f1(MV) can be updated, but the basic idea remains the same, that is, the more intense the motion, the less obvious the image details. For example, when the resolution of the image is greatly improved, the MV of the motion vector in units of pixels will be greatly increased. At this time, the segmentation interval of the above MV should be adjusted appropriately.
公式(5)中的f2(M)具体为:f2(M) in formula (5) is specifically:
如前所述,阈值的设定结合F(MV,M)函数值的具体展开模式,采取了在ESM,I,J值的基础上进行操作的办法。As mentioned above, the setting of the threshold is combined with the specific expansion mode of the F(MV, M) function value, and the method of operating on the basis of ES M, I, J values is adopted.
图像纹理变化激烈、细节丰富,对应着图像内容趋于静止,反之,图像纹理平滑对应着图像内容运动剧烈。The image texture changes drastically and the details are rich, which corresponds to the image content tends to be static. Conversely, the smooth image texture corresponds to the image content moving violently.
另外,本步骤还可以采取不直接计算F(MV,M)的值,而是在ESM,I,J值上进行加减与移位的操作来获取F(MV,M)×ESM,I,J的值。具体包括步骤:In addition, in this step, the value of F(MV, M) can not be calculated directly, but the operations of adding, subtracting and shifting are performed on ES M, I, J values to obtain F(MV, M)×ES M, I, the value of J. Specifically include steps:
C1:首先计算f2(M)×ESM,I,J的值,记为Pre_TH;C1: first calculate the value of f2(M)×ES M, I, J , and record it as Pre_TH;
本步骤如下式所示:This step is shown in the following formula:
Pre_TH=ESM,I,J×f2(M) (8)Pre_TH = ES M, I, J × f2(M) (8)
C2:然后再将f1(MV)与Pre_TH相乘得到最终的SADTH值。C2: Then multiply f1(MV) and Pre_TH to get the final SAD TH value.
本步骤如下式所示:This step is shown in the following formula:
SADTH=Pre_TH×f1(MV) (9) SADTH =Pre_TH×f1(MV) (9)
公式(8)和公式(9)的实现过程是对ES值或Pre_TH进行加减与移位操作,以实现其结果。例如,若公式(8)中M=4,则f2(M)=1-1/8,此时Pre_TH值用ES-ES>>3来实现,即用ES>>3来实现1/8,再用原ES的值与移位后的值作减法,最终实现ESM,I,J×f2(M),得到Pre_TH。通过这样的设置方式,可以实现公式(8)和公式(9)中的各个函数值。并且,在MV区间判定时,利用了分段条件在逻辑上的包含关系,将区间判断化简为三个简单判断:MV>3,MV>10和MV>20。The implementation process of formula (8) and formula (9) is to perform addition, subtraction and shift operation on ES value or Pre_TH to realize the result. For example, if M=4 in the formula (8), then f2(M)=1-1/8, at this time the Pre_TH value is realized by ES-ES>>3, that is, 1/8 is realized by ES>>3, Then use the value of the original ES and the shifted value for subtraction, finally realize ES M, I, J × f2(M), and obtain Pre_TH. Through such a setting method, each function value in formula (8) and formula (9) can be realized. In addition, when judging MV intervals, the logical inclusion relationship of segmentation conditions is used to simplify the interval judgments into three simple judgments: MV>3, MV>10 and MV>20.
将特定的阈值条件用加减与移位的方式来实现,这样的优点是逻辑简单,实现起来硬件代价小。The specific threshold condition is realized by means of addition, subtraction and shifting, which has the advantages of simple logic and low hardware cost for implementation.
D:判断参考块的绝对差异总值SADM,I,J(MVx,MVy)是否小于所述阈值SADTH,如果是,则提前终止搜索,以当前参考块作为最优的参考块;否则,返回步骤B继续在其他参考块中寻找最优参考块。D: Determine whether the total absolute difference SAD M, I, J (MVx, MVy) of the reference block is smaller than the threshold SAD TH , if yes, terminate the search in advance, and use the current reference block as the optimal reference block; otherwise, Return to step B to continue searching for the optimal reference block among other reference blocks.
综上所述,本发明公开了一种基于图像纹理和运动特征的运动预测方法,其利用图像纹理特征与图像运动的关系设置阈值,将图像纹理进行适当的量化,应用于基于绝对差异总值的提前终止运动搜索中。表现此动态阈值首先取决于当前被搜索块的纹理强度,同时此阈值与运动向量幅度MV有着正相关的关系。在所示方法中,对MV的大小进行分段,近似认为段内的阈值是相同的。进一步的分段阈值条件,在确定了MV的分段条件f1(MV)后,添加了考虑待匹配分割块块的分割方式参考因子f2(M),以反应块的分割方式对阈值的影响,有效减少了块匹配算法中的冗余计算,从而达到减少功耗的目的。In summary, the present invention discloses a motion prediction method based on image texture and motion features, which uses the relationship between image texture features and image motion to set a threshold, properly quantizes image texture, and applies the method based on the absolute difference total value early termination of the motion search. The performance of this dynamic threshold first depends on the texture strength of the currently searched block, and this threshold has a positive correlation with the motion vector magnitude MV. In the shown method, the size of the MV is segmented, and the thresholds within a segment are approximately considered to be the same. For further segmentation threshold conditions, after determining the segmentation condition f1(MV) of the MV, a reference factor f2(M) is added considering the segmentation mode of the block to be segmented to reflect the impact of the segmentation mode of the block on the threshold value, The redundant calculation in the block matching algorithm is effectively reduced, thereby achieving the purpose of reducing power consumption.
本发明所提出的方法适合硬件实现,其特征是用加减、移位和比较三种简单操作实现阈值的生成与判定。The method proposed by the invention is suitable for hardware realization, and is characterized in that three simple operations of addition and subtraction, shifting and comparison are used to realize the generation and judgment of the threshold.
与现有技术相比,本发明所述的方法能够减少20%到80%的功耗开销,同时保证数字视频信号的编码失真率在0.1dB的范围内。Compared with the prior art, the method of the present invention can reduce the power consumption consumption by 20% to 80%, and at the same time ensure that the coding distortion rate of the digital video signal is within the range of 0.1dB.
以上实施方式仅用于说明本发明,而并非对本发明的限制,有关技术领域的普通技术人员,在不脱离本发明的精神和范围的情况下,还可以做出各种变化和变型,因此所有等同的技术方案也属于本发明的范畴,本发明的专利保护范围应由权利要求限定。The above embodiments are only used to illustrate the present invention, but not to limit the present invention. Those of ordinary skill in the relevant technical field can make various changes and modifications without departing from the spirit and scope of the present invention. Therefore, all Equivalent technical solutions also belong to the category of the present invention, and the scope of patent protection of the present invention should be defined by the claims.
Claims (5)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201210040779.0A CN102572438B (en) | 2012-02-21 | 2012-02-21 | Motion predication method based on image texture and motion features |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201210040779.0A CN102572438B (en) | 2012-02-21 | 2012-02-21 | Motion predication method based on image texture and motion features |
Publications (2)
Publication Number | Publication Date |
---|---|
CN102572438A CN102572438A (en) | 2012-07-11 |
CN102572438B true CN102572438B (en) | 2014-04-02 |
Family
ID=46416745
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201210040779.0A Active CN102572438B (en) | 2012-02-21 | 2012-02-21 | Motion predication method based on image texture and motion features |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN102572438B (en) |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104410863B (en) * | 2014-12-11 | 2017-07-11 | 上海兆芯集成电路有限公司 | Image processor and image processing method |
CN112203095B (en) * | 2020-12-04 | 2021-03-09 | 腾讯科技(深圳)有限公司 | Video motion estimation method, device, equipment and computer readable storage medium |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6269121B1 (en) * | 1997-08-13 | 2001-07-31 | Daewoo Electronics Co., Ltd. | Adaptive motion estimation method and apparatus |
CN1713733A (en) * | 2004-06-15 | 2005-12-28 | 中兴通讯股份有限公司 | Rapid kinematics estimation of video frequency object based on MPEG-4 |
CN101090502A (en) * | 2006-06-13 | 2007-12-19 | 中兴通讯股份有限公司 | Controllable quick motion valuation algorithm for prediction quality |
CN101247523A (en) * | 2008-03-18 | 2008-08-20 | 上海华平信息技术股份有限公司 | Semi-pixel motion estimating method for H.264 encoder |
-
2012
- 2012-02-21 CN CN201210040779.0A patent/CN102572438B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6269121B1 (en) * | 1997-08-13 | 2001-07-31 | Daewoo Electronics Co., Ltd. | Adaptive motion estimation method and apparatus |
CN1713733A (en) * | 2004-06-15 | 2005-12-28 | 中兴通讯股份有限公司 | Rapid kinematics estimation of video frequency object based on MPEG-4 |
CN101090502A (en) * | 2006-06-13 | 2007-12-19 | 中兴通讯股份有限公司 | Controllable quick motion valuation algorithm for prediction quality |
CN101247523A (en) * | 2008-03-18 | 2008-08-20 | 上海华平信息技术股份有限公司 | Semi-pixel motion estimating method for H.264 encoder |
Also Published As
Publication number | Publication date |
---|---|
CN102572438A (en) | 2012-07-11 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN111147867B (en) | Multifunctional video coding CU partition rapid decision-making method and storage medium | |
CN102137263B (en) | Distributed video coding and decoding methods based on classification of key frames of correlation noise model (CNM) | |
CN104539962B (en) | It is a kind of merge visually-perceptible feature can scalable video coding method | |
CN102186070B (en) | Method for realizing rapid video coding by adopting hierarchical structure anticipation | |
CN110087087A (en) | VVC interframe encode unit prediction mode shifts to an earlier date decision and block divides and shifts to an earlier date terminating method | |
CN103338370B (en) | A kind of multi-view depth video fast encoding method | |
CN107277506B (en) | Motion vector accuracy selection method and device based on adaptive motion vector precision | |
CN111654710A (en) | Image filtering method, device, device and storage medium | |
CN103327327B (en) | For the inter prediction encoding unit selection method of high-performance video coding HEVC | |
CN104581170A (en) | Rapid inter-frame transcoding method for reducing video resolution based on HEVC | |
CN103957420B (en) | Comprehensive movement estimation modified algorithm of H.264 movement estimation code | |
CN107820095A (en) | A kind of long term reference image-selecting method and device | |
CN105187826A (en) | Rapid intra-frame mode decision method specific to high efficiency video coding standard | |
CN112929657B (en) | H.266/VVC rapid CU partition decision method based on gradient and variance | |
CN103618898A (en) | Complexity image lossless compression method supporting random access | |
CN101917627B (en) | Video fault-tolerant coding method based on self-adaptation flexible macro-block order | |
CN102572438B (en) | Motion predication method based on image texture and motion features | |
CN106878754B (en) | A 3D video depth image intra prediction mode selection method | |
CN101984669A (en) | Iteration method of frame-hierarchy adaptive Wiener interpolation filter | |
CN107105297B (en) | A fast optimization method for intra-frame prediction coding of 3D-HEVC depth map | |
CN103905818B (en) | Method for rapidly determining inter-frame prediction mode in HEVC standard based on Hough conversion | |
CN114567776B (en) | Video low-complexity coding method based on panoramic visual perception characteristics | |
WO2022206199A1 (en) | Method and apparatus for performing image processing in video decoding apparatus, and system | |
CN107509074B (en) | Adaptive 3D Video Compression Codec Method Based on Compressed Sensing | |
CN105704497A (en) | Fast select algorithm for coding unit size facing 3D-HEVC |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant |