WO2011124159A1 - 视频图像处理方法以及编/解码器 - Google Patents
视频图像处理方法以及编/解码器 Download PDFInfo
- Publication number
- WO2011124159A1 WO2011124159A1 PCT/CN2011/072568 CN2011072568W WO2011124159A1 WO 2011124159 A1 WO2011124159 A1 WO 2011124159A1 CN 2011072568 W CN2011072568 W CN 2011072568W WO 2011124159 A1 WO2011124159 A1 WO 2011124159A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- motion vector
- block
- candidate motion
- current coding
- template
- 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.)
- Ceased
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N19/00—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
- H04N19/50—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
- H04N19/503—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving temporal prediction
- H04N19/51—Motion estimation or motion compensation
- H04N19/56—Motion estimation with initialisation of the vector search, e.g. estimating a good candidate to initiate a search
Definitions
- the present invention relates to multimedia technologies, and in particular, to a video image processing method and a codec/decoder. Background technique
- the motion search and compensation technology between frames can effectively remove the temporal redundancy of video content, and the coding efficiency is greatly improved.
- the motion information is obtained by motion estimation and passed to decoding.
- the video image is predicted and reconstructed by the decoding end by motion compensation.
- the proportion of motion residual compensation in the code stream is greatly reduced, and the proportion of motion vector information in the code stream is increasing, how to effectively compress motion information becomes the key to further improve video compression efficiency.
- the method for obtaining motion information in the prior art includes acquiring motion vectors by template matching; specifically, taking the current coding block as a macro block in a B frame as an example, as shown in FIG. 1, first reconstructing around the current coding block The value constructs a template TM, and then performs search matching in the forward reference frame (Ref ListO ) and the backward reference frame (Ref Listl ) of the block with the same template shape as the template TM to obtain the motion vectors MV0 and MV1 as the current coding block. Sport vector.
- Ref ListO forward reference frame
- Ref Listl backward reference frame
- the motion information obtained by the prior art only considers the similarity between the template around the current coding block and the template in the reference frame. After the search and matching, it often appears to ensure that the template is similar, and the reference block and the current coding block are not guaranteed. Similar, resulting in large errors and low precision, making video image coding less efficient. Summary of the invention
- Embodiments of the present invention provide a video image processing method, apparatus, and device to improve encoding and decoding efficiency of a video image.
- Embodiments of the present invention adopt the following technical solutions:
- a method for obtaining motion information of a video image comprising:
- At least two associated reference blocks of a current coding block corresponding to each candidate motion vector of the candidate motion vector set of the current coding block; at least two association references of the current coding block corresponding to each of the candidate motion vectors Determining, according to an energy function, an candidate motion vector from the candidate motion vector set, the energy function according to a similarity of the at least two associated reference blocks and a template region of the current coding block and the at least The similarity of the template regions of the two associated reference blocks is obtained; the current encoded block motion vector is determined according to at least the selected candidate motion vector.
- a method for obtaining motion information of a video image comprising:
- each of the candidate motion vectors in the candidate motion vector set of the current coding block finding a corresponding at least one first reference block in the first reference frame of each of the candidate motion vectors;
- the motion vector is temporally extrapolated to obtain a corresponding associated motion vector, and the corresponding at least one second reference block is determined in the second reference frame that is in the same direction of the first reference frame according to the associated motion vector;
- the first reference block corresponding to the motion vector and the second reference block corresponding to the associated motion type quantity are determined according to an energy function, and an candidate motion vector is selected from the candidate motion vector set, the energy function being according to the at least a similarity between a first reference block and the at least one second reference block and a similarity between a current coding block template region and a template region of the at least one first reference block and the at least one second reference block, respectively;
- a current encoded block motion vector is determined based on the selected candidate motion vector.
- a method for obtaining motion information of a video image comprising:
- each candidate motion vector in the candidate motion vector set of the current coding block finding a corresponding first reference block in the first reference frame of each of the candidate motion vectors; determining each of the candidate motion vectors Corresponding associated motion vector, determining a corresponding candidate second reference block in a second reference frame of the associated motion vector that is opposite to the first reference frame; corresponding to each of the candidate motion vectors a reference block and a second reference block corresponding to the associated motion vector are determined according to an energy function, and an candidate motion vector is selected from the candidate motion vector set, the energy function according to the first reference block and the a similarity between the second reference block and a similarity between the current coded block template region and the template region of the first reference block and the second reference block, respectively; The motion vector and the associated motion vector determine a current coded block motion vector.
- a codec/decoder for performing any of the above methods for acquiring video image motion vector information.
- An encoding/decoding system comprising the above-described encoder/decoder, wherein the encoding/decoding system is configured to receive an input signal, send it to the encoder/decoder, and send the encoder/decoder Output, wherein the encoder/decoder is configured to perform a method including acquiring any of the video image motion vector information.
- the video image processing method and the codec device determine, according to the energy function, each candidate motion vector in the candidate motion vector set of the current coding block, and selects each of the candidate motion vectors.
- the energy function is obtained according to a similarity of at least two associated reference blocks of the current coding block and a similarity between a template region of a current coding block and a template region of the at least two associated reference blocks, respectively, Determining the current coded block motion vector according to the selected at least one motion vector can effectively reduce the error to improve the codec efficiency of the video image.
- FIG. 1 is a schematic view of a prior art method
- FIG. 3 is a flowchart of a method according to Embodiment 2 of the present invention.
- FIG. 4 is a schematic diagram of an alternative motion vector set according to an embodiment of the present invention.
- FIG. 5 is a schematic structural diagram 1 of a reference frame according to Embodiment 2 of the present invention.
- FIG. 7 is a schematic diagram of P frame extrapolation according to an embodiment of the present invention. detailed description
- Embodiment 1 is a diagrammatic representation of Embodiment 1:
- the video image processing method provided in this embodiment includes the following steps: 201: Obtain at least two associations of current coding blocks corresponding to each candidate motion vector in the candidate motion vector set of the current coding block. Reference block.
- the candidate motion vector meter of the current coding block acquiring the coded block according to temporal spatial correlation Sports information is built.
- the reference block corresponds to an alternate second reference block in the second reference frame, that is, after the symmetry search, the candidate first reference block and its corresponding searched candidate second reference block are current
- the coding block is symmetric with respect to the center, and the equalization search may be performed without considering the symmetry to determine a set of candidate first reference blocks and a set of candidate second reference blocks, and may also be scaled according to each candidate motion vector.
- the at least two associated reference blocks include a set of candidate first reference blocks and a set of candidate second reference blocks. Further, in the case of multiple reference frames, a set of candidate third reference blocks may also be determined, A set of alternative fourth reference blocks and more associated reference blocks are determined in the same manner as described above, and other search methods may be employed, requiring the searched associated reference blocks to follow a particular search pattern.
- the energy function is obtained according to the similarity of the at least two associated reference blocks and the similarity between the template regions of the current coding block and the template regions of the at least two associated reference blocks, respectively.
- the similarity of the at least two associated reference blocks may be obtained by: calculating the at least two associated parameters by using at least one associated reference block of the current coding block corresponding to one candidate motion vector The similarity between the pixels of the block is tested, wherein the number of pixels of each associated reference block is the same.
- the similarity between the template region of the current coding block and the template region of the at least two associated reference blocks, respectively, may be obtained by: respectively surrounding at least two associated reference blocks of the current coding block corresponding to one candidate motion vector Obtaining a template area in the coded area, acquiring a template area in the coded area around the current coded block, and calculating a similarity between the template area of the current coded block and the template area of the at least two associated reference blocks, where the at least two The position between the template region of the associated reference block and the corresponding associated reference block and the location between the template region of the current coded block and the current coded block, the shape and size of the template region of the at least two associated reference blocks
- the template area of the current coding block has the same shape and size. If the at least two associated reference blocks are two associated reference blocks, the similarity of the at least two associated reference blocks, the template region of the current coding block and the template region of the at least two associated reference blocks respectively Degree-weighted superposition to obtain the energy function includes:
- CostDirect lambdal *COST(MB associa t e i,MB associa t e2 )+lambda2*COST(Template assocmtei, Temp late current ) +lambda3*COST (Template ass . ciate2 , Template c
- lambdal, lambda2 and lambda3 are weighting coefficients greater than zero
- COST represents the similarity calculation function
- MB represents the current coding block
- template represents the template region
- associate 1 represents an associated reference block of the current coding block
- associate2 represents the current coding block. Another associated reference block.
- the similarities include error sum, absolute error sum (SAD), absolute conversion error and sum of absolute transformation differences or absolute sum of squared differences.
- SAD absolute error sum
- SAD absolute error sum
- sum of absolute transformation differences or absolute sum of squared differences there may be other parameters which can be used to describe the similarity between the two reference blocks.
- the solutions provided by the present invention are explained by taking the absolute error sum as an example.
- the motion vectors to obtain said selected candidate motion vector of the current coding block Wo 5 obtained by motion search; end of the encoding candidate motion vector that is selected as the motion vector of the current encoding block
- the difference between the difference is sent to the decoding end, and the decoding end parses, and then recovers according to the obtained difference value according to the obtained difference value and the candidate motion vector selected in step 201, step 202 and step 203.
- the motion vector of the current coded block to obtain said selected candidate motion vector of the current coding block Wo 5 obtained by motion search; end of the encoding candidate motion vector that is selected as the motion vector of the current encoding block
- the difference between the difference is sent to the decoding end, and the decoding end parses, and then recovers according to the obtained difference value according to the obtained difference value and the candidate motion vector selected in step 201, step 202 and step 203.
- the encoding end uses the selected candidate motion vector and the associated motion vector corresponding to the selected candidate motion vector as the motion vector of the current coding block; or, the selected An alternative motion vector and a difference between the associated motion vector and a motion vector pair obtained by the motion search block of the current coding block, and the difference is sent to the decoding end for obtaining a motion vector of the current coding block.
- the embodiment further provides a codec for performing a method for acquiring video image motion information, and the encoder obtains each of the candidate motion vector sets of the current coding block. At least two associated reference blocks of the current coded block corresponding to the candidate motion vector, and at least two associated reference blocks of the current coded block corresponding to each of the candidate motion vectors are determined according to an energy function, from the candidate motion
- the vector set is selected as an alternative motion vector, and the energy function is obtained according to the similarity of the at least two associated reference blocks and the similarity between the template regions of the current coding block and the template regions of the at least two associated reference blocks, respectively.
- a current encoded block motion vector is determined based on at least the selected candidate motion vector.
- the encoder provided in this embodiment is used to perform the method of acquiring video image motion information as described in Embodiment 1 above.
- the embodiment further provides an encoding/decoding system, including the above-mentioned encoder/decoder, the encoding/decoding system receives an input signal, and sends the received input signal into a codec, wherein the encoder/decoder is configured to perform the above method for acquiring video image motion information, and send the output of the encoder/decoder.
- the method provided by the embodiment of the present invention can adjust the sequence of each step according to actual needs.
- the method for acquiring video image motion information and the encoder/decoder and the encoding/decoding system provided in this embodiment change the strategy for determining the reference block in determining the reference block, and can reduce the reference while ensuring that the encoding performance is substantially unchanged.
- the block determines the complexity of the process implementation, thereby improving the process of acquiring motion information in the video image, and improving the encoding and decoding efficiency of the video image.
- Embodiment 2 :
- FIG. 3 76 ' the video image processing method according to this embodiment, with The body includes the following steps:
- the current coding block may be a complete macroblock or a partitioning block of a macroblock, where a complete macroblock is taken as an example;
- the candidate motion vector set may include: motion vectors MVL, MVU, MVR, MVUL, and MEAN (MVL, ⁇ ! ! ⁇ ! of the peripheral blocks spatially related to the current coding block (Curr_blk). ! ⁇ ⁇
- the motion vector in the same position block in the forward reference frame / ⁇ (col_MVl, col_MV2, col_MV3, col_MV4 in Fig. 4) and the motion vector of the peripheral block of the same position block (such as MV1, MV2 in Fig. 4) MV12), the motion vector in the same position block in the backward reference frame / n+1 (such as col_MV1', col_MV2', col_MV3', col_MV4 in Fig.
- MV1', MV2'MV12' in 5 that is, the left block including the current coding block, the upper block, the upper left block, the upper right block, and the left side of the block in the reference frame and the same position as the current coding block
- Step 302 - step 307 is performed for each of the candidate motion vectors in the candidate motion vector set.
- the reference frame / w is the first reference frame.
- the candidate motion vector corresponding to the candidate motion vector and the candidate motion vector is taken as a set of motion vectors.
- the first reference frame is a forward reference frame
- the second reference frame is a backward reference frame.
- the first reference frame may be a backward reference frame
- the second reference frame may be a forward reference frame.
- even the first second reference frame is the same reference frame, further, in this embodiment, only
- the description is performed by two associated reference blocks, which are respectively a first reference block and a second reference block. In practice, it may be a set of first reference blocks and a set of second reference blocks.
- step 302 and step 303 taking the case of only one B frame between two P frames as an example, the forward and backward motion vectors of the current block to be coded are obtained by an identical search process in both the encoder and the decoder.
- the search process must ensure that the searched forward and backward motion vector satisfies the hook speed linear model.
- the search accuracy of the motion vector is 1/4 pixel, and the full search process of the whole pixel -> 1/2 pixel -> 1/4 pixel is used, and the search range is 8 (integral pixel unit).
- other motion models such as accelerated motion may also be employed, and the acceleration motion model may be as follows:
- V f -(V b + a) where "is the speed difference.
- the front/backward motion vectors are obtained in substantially the same way.
- the difference is the constraint on the anterior/posterior motion vector relationship. If the distance between the current B frame from the first reference frame (forward reference frame) is 7 , and the distance between the second reference frame (forward reference frame) is Tb , then the candidate motion vector sum in the search range The corresponding associated motion vector satisfies:
- Calculating the similarity by calculating a pixel of the first reference block and the second reference block pixel, and calculating a similarity between the first reference block pixel and the second reference block pixel to satisfy the number of the first reference block pixel and the second reference block pixel The number is the same.
- TM1 Construct a template TM1 around the current coding block (Curr_blk ) in the current frame/ n by using the reconstruction value and the reference frame prediction value, and construct the template TM11 by using the reconstruction value around the candidate first reference block blkl l.
- the template TM21 is constructed using the reconstruction values around the second reference block blk21.
- the first and second reference block template regions are the same as the position between the corresponding first and second reference blocks and the template region of the current coding block and the current coding block, the first, the first
- the shape and size of the template area of the second reference block are the same as the shape and size of the template area of the current coded block.
- the similarity of the at least two associated reference blocks may be used, and the template regions of the current coding block and the similarity of the template regions of the at least two associated reference blocks are respectively weighted and superposed to obtain the energy function.
- the similarity between the coded pixels around the first reference block and the coded pixels around the second reference block the similarity between the template region of the template TM1 of the current coding block and the template region of the template TM11 of the first reference block.
- the weighting of the template region of the template TM1 of the current coding block and the template region of the template TM21 of the second reference block is weighted and superimposed to obtain an energy function, which can be expressed as follows:
- CostDirect lambdal 1 *COST(MB forward ,MB backward )+lambdal2 *COST(Template for ward ,Template current )+lambdal3 *CO ST(Template backrward , Template cunrent )
- lambdal, lambda2 and lambda3 are weighting coefficients greater than zero
- COST represents the similarity calculation function
- MB represents the current coding block
- template represents the template region
- forward represents the first reference block
- backward represents the second reference block.
- the energy function can be expressed as follows:
- CostDirect lambdal *SAD(MB forward , B bac kd)+lambda2 *SAD(Template forward , Template current ) +lambda3 *SAD(Template backrwar d, Template
- this embodiment also provides an encoding/decoding. And a method for performing acquisition of video image motion information to encode and decode the current coding block.
- the embodiment further provides an encoding/decoding system, including the above-mentioned encoder/decoder, the encoding/decoding system receives an input signal, and sends the received input signal into And an encoder/decoder for performing the above method for acquiring video image motion information, and transmitting the output of the encoder/decoder.
- Embodiment 3 is a diagrammatic representation of Embodiment 3
- the video image processing method provided in this embodiment includes the following steps:
- the current coding block may be a complete macroblock or a partitioning block of a macroblock, where a complete macroblock is taken as an example;
- the candidate motion vector set may include: motion vectors MVL, MVU, MVR, MVUL, and MEAN (MVL, MVU, MVR) of the peripheral block spatially related to the current coding block (Curr_blk), forward reference frame / w
- the motion vector in the same position block such as col_MV1, col_MV2, col_MV3, col_MV4 in Figure 5
- the motion vector of the peripheral block of the same position block such as MV1, MV2 MV12 in Figure 4
- backward reference frame / n The motion vector in the same position block in +1 (such as col_MV1', col_MV2', col_MV3', col_MV4 in Figure 4) and the motion vector of the peripheral block of the same position block (such as MV1', MV2' MV12 in Figure 4) All or part of '), including the left block of the current coding block, the upper block, the upper left block, the upper right block, the left block of the block in the same position as the
- Step 602-step 607 is performed for each of the candidate motion vectors in the candidate motion vector set.
- the motion model used in this embodiment may linearly move the object at a uniform speed, as shown in FIG. 7, where Fn is the current frame.
- 3 ⁇ 4 is the current block to be coded
- Bn_i and ⁇ are 3 ⁇ 4 reference blocks found in the first reference frame of F n according to the candidate motion vector
- ⁇ ⁇ — 2 and ⁇ ⁇ — 2 ' are ⁇ ⁇ according to the candidate motion vector V
- the reference block found in the second reference frame F n _ 2 that is further away from F n , ⁇ ⁇ _ 2 and ⁇ ⁇ _ 2 , with respect to the motion vector of ⁇ ⁇ , where the relationship between ' and F n — 2 and the distance from F n and the correlation with the motion model. If the hook speed linear motion model is used and the reference frame closest to the distance ⁇ is the second closest reference frame to the distance F n , V 2 V f .
- the embodiment can also adopt other motion models such as acceleration motion, and the acceleration motion model is as follows:
- each pair of motion vectors in the search range should satisfy the following relationship:
- V f / T f V f ' / T f ' , where / is the candidate motion vector, / ' is the extrapolation motion vector, ⁇ is the distance between the encoding frame of the current coding block and the first reference frame, ⁇ ' is the distance between the encoded frame in which the current coding block is located and the second reference frame.
- Calculating the similarity by calculating the pixel of the first reference block and the second reference block pixel, and calculating a similarity between the first reference block pixel and the second reference block pixel to satisfy the number of pixels around the first reference block and the second reference
- the number of pixels in the block is the same.
- the measurement constructs a template TM1, which is constructed around the candidate first reference block blkl2 using the reconstruction value TM11, and the template TM21 is constructed using the reconstruction values around the alternative second reference block blk22.
- the first and second reference block template regions are the same as the position between the corresponding first and second reference blocks and the template region of the current coding block and the current coding block, the first, the first
- the shape and size of the template area of the second reference block are the same as the shape and size of the template area of the current coded block.
- the energy function is used.
- the error and the similarity are used, and the similarity between the coded pixels around the first reference block and the coded pixels around the second reference block is calculated, and the template of the current coded block TM1 is used.
- the similarity between the template region and the template region of the template TM11 of the first reference block, the similarity between the template region of the template TM1 of the current coding block and the template region of the template TM21 of the second reference block are weighted and superimposed to obtain an energy function, which may be as follows Indicates:
- CostDirect lambdal *COST(MBfon V ard, Bfon V ard)+lambda2*COST(Templatefo r war d, Template current ) +lambda3*COST (Template forward ' , Template
- lambdal, lambda2 and lambda3 are weighting coefficients greater than or equal to zero
- COST represents the similarity calculation function
- MB represents the current coding block
- template represents the template region
- forward represents the first reference block
- forward represents the second reference block.
- the energy function can be expressed as follows:
- CostDirect lambdal *SAD(MB forward , MB forward )+lambda2 * S AD(Templatef orW ard, Template current ) +lambda3*SAD (Template forward ' , Tem late cimrent )c
- this embodiment also provides an encoding/decoding And a method for performing acquisition of video image motion information to encode and decode the current coding block.
- the embodiment further provides an encoding/decoding system, including the above-mentioned encoder/decoder, the encoding/decoding system receives an input signal, and sends the received input signal into And an encoder/decoder for performing the above method for acquiring video image motion information, and transmitting the output of the encoder/decoder.
- the steps of a method or algorithm described in connection with the embodiments disclosed herein may be implemented in hardware, a software module executed by a processor, or a combination of both.
- the software module can be placed in random access memory (RAM memory, read only memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, removable disk, CD-ROM, or the art. Any other form of storage medium.
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Compression Or Coding Systems Of Tv Signals (AREA)
Description
视频图像处理方法以及编 /解码器 本申请要求了 2010年 4月 9日提交的, 申请号为 201010146533.2, 发明名 称为 "视频图像处理方法以及编 /解码器" 的中国专利申请的优先权, 其全部内 容通过引用结合在本申请中。 技术领域
本发明涉及多媒体技术, 尤其涉及一种视频图像处理方法以及编 /解码器。 背景技术
随着视频编码技术的不断发展, 帧间的运动搜索和补偿技术能够有效地去 除视频内容的时间冗余, 编码效率得到了很大程度的提高; 通过运动估计得到 运动信息并把它传递给解码端, 由解码端通过运动补偿的方法对视频图像进行 预测重建。 然而由于运动补偿后预测残差在码流中所占的比重的大幅度下降, 同时运动矢量信息在码流中的比重不断上升, 如何有效地压缩运动信息成为进 一步提升视频压缩效率的关键。
现有技术中获取运动信息的方法包括通过模板匹配来获取运动矢量; 具体 地, 以当前编码块是 B帧中的宏块为例, 如图 1所示, 首先在当前编码块的周 围用重建值构造一个模板 TM, 然后在该块的前向参考帧 (Ref ListO )和后向参 考帧 (Ref Listl ) 中用与模板 TM形状相同的模板进行搜索匹配得到运动矢量 MV0和 MV1作为当前编码块的运动矢量。
通过现有技术获得的运动信息由于只考虑到了当前编码块周边的模板与参 考帧中模板的相似度, 经过搜索匹配后经常会出现找到只能保证模板相似, 并 不能保证参考块与当前编码块相似, 导致误差大, 精度低, 使得视频图像编码 的效率低。 发明内容
本发明的实施例提供一种视频图像处理方法、 装置及设备以提高视频图像 的编解码效率。
本发明的实施例采用如下技术方案:
一种获取视频图像运动信息的方法, 包括:
得到当前编码块的备选运动矢量集中的每一个备选运动矢量对应的当前编 码块的至少两个关联参考块; 对所述每一个备选运动矢量对应的当前编码块的 至少两个关联参考块根据能量函数进行判断, 从所述备选运动矢量集中选择一 个备选运动矢量, 所述能量函数根据所述至少两个关联参考块的相似度以及当 前编码块的模板区域分别和所述至少两个关联参考块的模板区域的相似度得 到; 根据至少所述选择的备选运动矢量确定当前编码块运动矢量。
一种获取视频图像运动信息的方法, 包括:
采用当前编码块的备选运动矢量集中的每一个备选运动矢量, 在所述每一 个备选运动矢量的第一参考帧中找到对应的至少一个第一参考块; 对所述每一 个备选运动矢量进行时间上外插得到对应的关联运动矢量, 根据关联运动矢量 在所述第一参考帧同向的第二参考帧中确定对应的至少一个第二参考块; 对所 述每一个备选运动矢量对应的第一参考块和所述关联运动式量对应的第二参考 块根据能量函数进行判断, 从所述备选运动矢量集中选择一个备选运动矢量, 所述能量函数根据所述至少一个第一参考块和所述至少一个第二参考块的相似 度以及当前编码块模板区域分别与所述至少一个第一参考块和所述至少一个第 二参考块的模板区域的相似度得到; 根据所述选择的备选运动矢量确定当前编 码块运动矢量。
一种获取视频图像运动信息的方法, 包括:
采用当前编码块的备选运动矢量集中的每一个备选运动矢量, 在所述每一 个备选运动矢量的第一参考帧中找到对应的第一参考块; 确定所述每一个备选 运动矢量对应的关联运动矢量, 在与所述第一参考帧反向的所述关联运动矢量 的第二参考帧中确定对应的备选第二参考块; 对所述每一个备选运动矢量对应 的第一参考块以及所述关联运动矢量对应的第二参考块根据能量函数进行判 断, 从所述备选运动矢量集中选择一个备选运动矢量, 所述能量函数根据所述 第一参考块和所述第二参考块的相似度以及当前编码块模板区域分别与所述第 一参考块和所述第二参考块的模板 ¾域的相似度得到; 根据所述选择的备选运
动矢量以及所述关联运动矢量确定当前编码块运动矢量。
一种编 /解码器, 用于执行上述任一获取视频图像运动矢量信息的方法。 一种编 /解码系统, 所述编 /解码系统包括上述编 /解码器, 所述编 /解码系统 用于接收输入信号, 送入所述编 /解码器, 并发送所述编 /解码器的输出, 其中, 所述编 /解码器用于执行包括上述任一获取视频图像运动矢量信息的方法。
本发明实施例提供的视频图像处理方法以及编解码装置, 通过对当前编码 块的备选运动矢量集中的每一个备选运动矢量根据能量函数进行判断, 从所述 每一个备选运动矢量中选择至少一个运动矢量, 所述能量函数根据所述当前编 码块的至少两个关联参考块的相似度以及当前编码块的模板区域分别和所述至 少两个关联参考块的模板区域的相似度得到, 根据所述选择的至少一个运动矢 量确定当前编码块运动矢量可以有效减小误差, 以提高视频图像的编解码效率。 附图说明
为了更清楚地说明本发明实施例或现有技术中的技术方案, 下面将对实施 例或现有技术描述中所需要使用的附图作简单地介绍, 显而易见地, 下面描述 中的附图仅仅是本发明的一些实施例, 对于本领域普通技术人员来讲, 在不付 出创造性劳动性的前提下, 还可以根据这些附图获得其他的附图。
图 1为现有技术的方法示意图;
图 2为本发明实施例一的方法流程图;
图 3为本发明实施例二的方法流程图;
图 4为本发明实施例的备选运动矢量集示意图;
图 5为本发明实施例二中的参考帧结构示意图一;
图 6为本发明实施例三的方法流程图;
图 7为本发明实施例的 P帧外插示意图。 具体实施方式
下面将结合本发明实施例中的附图, 对本发明实施例中的技术方案进行清 楚、 完整地描述, 显然, 所描述的实施例是本发明一部分实施例, 而不是全部 的实施例。 基于本发明中的实施例, 本领域普通技术人员在没有作出创造性劳
动前提下所获得的所有其他实施例, 都属于本发明保护的范围。
实施例一:
如图 2所示, 本实施例提供的视频图像处理的方法, 包括以下步骤: 201, 得到当前编码块的备选运动矢量集中的每一个备选运动矢量对应的当 前编码块的至少两个关联参考块。
从与当前编码块相关的编码块 /解码块的运动矢量中选择其全部或者部分组 成一个备选运动矢量集, 所述当前编码块的备选运动矢量计根据时间空间相关 性获取已编码块的运动信息构建而成。
根据每个备选运动矢量在第一参考帧中对应地确定一个备选第一参考块, 从而得到一组备选第一参考块, 进一步根据物体运动模型以及每个备选运动矢 量确定所述每个备选运动矢量的关联运动矢量, 采用所述关联运动矢量在当前 帧的第二参考帧中对应地搜索确定一个备选第二参考块, 如可以采用对称性搜 索通过各个备选第一参考块在所述第二参考帧中对应的备选第二参考块, 也就 是说, 对称性搜索后, 所述备选第一参考块与其对应的搜索到的备选第二参考 块以当前编码块为中心等比例对称, 也可以不考虑对称性进行等比例搜索确定 一组备选第一参考块和一组备选第二参考块, 同样也可以采用根据每个备选运 动矢量经过缩放在第二参考帧中搜索对应的第二参考块。 所述至少两个关联参 考块包括一组备选第一参考块和一组备选第二参考块, 进一步的, 在多参考帧 的情况下, 还可以确定一组备选第三参考块, 一组备选第四参考块以及更多的 关联参考块, 确定方法和上述描述相同, 也可以采用其他搜索方式, 要求搜索 到的关联参考块遵从特定的搜索模式。
202, 对所述每一个备选运动矢量对应的当前编码块的至少两个关联参考块 根据能量函数进行判断, 从所述备选运动矢量集的每一个备选运动矢量中选择 一个备选运动矢量, 所述能量函数根据所述至少两个关联参考块的相似度以及 当前编码块的模板区域分别和所述至少两个关联参考块的模板区域的相似度得 到。
所述至少两个关联参考块的相似度可以通过如下方式获得: 采用一个备选 运动矢量对应的当前编码块的至少 个关联参考块, 计算所述至少两个关联参
考块像素间的相似度, 其中, 每个关联参考块像素的数量相同。 所述当前编码 块的模板区域分别和所述至少两个关联参考块的模板区域的相似度可以通过如 下方式获得: 分别在一个备选运动矢量对应的当前编码块的至少两个关联参考 块周围已编码区域中获取模板区域, 在当前编码块周围已编码区域中获取模板 区域, 分别计算当前编码块的模板区域和所述至少两个关联参考块的模板区域 的相似度, 其中所述至少两个关联参考块的模板区域与对应的关联参考块之间 的位置和当前编码块的模板区域与当前编码块之间的位置相同, 所述至少两个 关联参考块的模板区域的形状与大小和当前编码块的模板区域的形状与大小相 同。 如所述至少两个关联参考块为两个关联参考块时, 所述至少两个关联参考 块的相似度, 当前编码块的模板区域分别和所述至少两个关联参考块的模板区 域的相似度进行加权叠加得到所述能量函数包括:
CostDirect=lambdal *COST(MBassociatei,MBassociate2)+lambda2*COST(Template assocmtei, Temp late current) +lambda3*COST (Template ass。ciate2, Templatec
其中, lambdal、 lambda2和 lambda3为大于零的加权系数, COST代表相似 度计算函数, MB表示当前编码块, template表示模板区域, associate 1表示当前 编码块的一个关联参考块, associate2表示当前编码块的另一关联参考块。
所述相似度包括误差和、 绝对误差和 (SAD )、 绝对转换误差和 (sum of absolute transformation differences )或绝对平方差和。 当然还可以是其它一些可 以用于描述两个参考块之间相似度的参数; 在本实施例中以及以下各个实施例 中, 均以绝对误差和为例对本发明提供的方案进行阐述。
选择使所述能量函数最小时对应的备选运动矢量, 也可以选择能量函数稍 小时对应的备选运动矢量, 比如能量函数仅大于最小值而小于其他能量函数值 时对应的备选运动矢量, 在其他可能的应用中, 由于环境、 设备等因素能量函 数可能产生小的误差和不稳定, 本实施例的实施均需要结合进行考虑, 不限定 与上述描述的情况。
203, 根据至少所述选择的备选运动矢量确定当前编码块运动矢量。
编码端将所述选择的备选运动矢量即作为所述当前编码块的运动矢量; 或 者, 得到所述选择的备选运动矢量禾 5当前编码块通过运动搜索得到的运动矢量
之间的差值, 并将所述差值发送给解码端, 解码端进行解析, 然后按照编码逆 过程根据得到的差值和执行步骤 201,步骤 202和步骤 203选择的备选运动矢量 结合恢复出当前编码块的运动矢量。 在另一实施情况下, 编码端将所述选择的 备选运动矢量以及所述选择的备选运动矢量对应的关联运动矢量即作为所述当 前编码块的运动矢量; 或者, 得到所述选择的备选运动矢量以及其所述关联运 动矢量和当前编码块通过运动搜索得到的运动矢量对之间的差值, 并将所述差 值发送给解码端用于得到当前编码块的运动矢量。
为了更好地实现上述视频图像处理的方法, 本实施例还提供了一种编解码 器, 用于执行获取视频图像运动信息的方法, 编码器获得当前编码块的备选运 动矢量集中的每一个备选运动矢量对应的当前编码块的至少两个关联参考块, 对所述每一个备选运动矢量对应的当前编码块的至少两个关联参考块根据能量 函数进行判断, 从所述备选运动矢量集中选择一个备选运动矢量, 所述能量函 数根据所述至少两个关联参考块的相似度以及当前编码块的模板区域分别和所 述至少两个关联参考块的模板区域的相似度得到, 根据至少所述选择的备选运 动矢量确定当前编码块运动矢量。 本实施中提供的编码器用于执行上述实施例 一中所述获取视频图像运动信息的方法。
为了更好地实现上述视频图像处理的方法, 本实施例还提供了一种编 /解码 系统, 包括上述的编 /解码器, 编 /解码系统接收输入信号, 将所述接收的输入信 号送入编解码器, 所述编 /解码器用于执行上述获取视频图像运动信息的方法, 将编 /解码器的输出进行发送。
本发明实施例提供的方法可以根据实际需要对各个步骤顺序进行调整。 本实施例提供的获取视频图像运动信息的方法及编 /解码器以及编 /解码系 统, 改变了在确定参考块过程中确定参考块的策略, 可以在保证编码性能基本 不变的情况下降低参考块确定过程实现的复杂度, 从而改进了视频图像中运动 信息的获取过程, 提高了视频图像的编解码效率。 实施例二:
以按 B帧编码为例, 如图 3所 76', 本实施例提供的视频图像处理方法, 具
体包括以下步骤:
301、 利用当前编码块周围已编码的块的运动矢量组成一个备选运动矢量 集, 其中包括与当前编码块相关的编码块的运动矢量中的部分或者全部。
所述当前编码块可以是完整的宏块, 也可以是宏块的划分块, 在这里以完 整的宏块为例;
本实施例中, 所述备选运动矢量集可以包括: 与当前编码块(Curr_blk )在 空间上相关的周边块的运动矢量 MVL、 MVU、 MVR, MVUL和 MEAN ( MVL、 ^! !^^! !^ ^前向参考帧/^中相同位置块中的运动矢量(如图 4中的 col_MVl、 col_MV2、 col_MV3、 col_MV4 ) 以及相同位置块的周边块的运动矢量(如图 4 中的 MV1、 MV2 MV12 ), 后向参考帧/ n+1中相同位置块中的运动矢量(如 图 4中的 col_MVl'、 col_MV2'、 col_MV3'、 col_MV4,) 以及相同位置块的周边 块的运动矢量(如图 5中的 MV1'、 MV2' MV12' ) 中的全部或者其中一部 分, 即包括当前编码块的左边块, 上边块, 左上块, 右上块, 在参考帧中和当 前编码块相同位置的块的左边块, 上边块, 左上块, 右上块或其中的一部分, 以及在参考帧中和当前编码块相同位置的块。
针对备选运动矢量集中的每一个备选运动矢量, 执行步骤 302-步骤 307。
302、 选择所述备选运动矢量集中的一个备选运动矢量, 根据该运动矢量在 第一参考帧中找到一个备选第一参考块 blkl l, 在本实施例中, 以当前帧的前向 参考帧/ w为第一参考帧。
303、 根据当前编码块所在编码帧和所述第一参考帧以及第二参考帧的位置 关系, 结合所述备选运动矢量确定所述备选运动矢量对应的关联运动矢量, 根 据所述每个备选运动矢量的关联运动矢量在第二参考帧中确定与所述备选第一 参考块 blkl l对应的备选第二参考块 blk21, 在本实施例中, 以当前帧的后向参 考帧/ n+1为第二参考帧。
在本实施例中, 将所述备选运动矢量和所述备选运动矢量对应的关联运动 矢量作为一组运动矢量。 此时的第一参考帧为前向参考帧, 第二参考帧为后向 参考帧, 在其他实施例中, 第一参考帧可以为后向参考帧, 第二参考帧可以为 前向参考帧, 甚至第一第二参考帧 同向参考帧, 进一步的, 本实施例中, 仅
以两个关联参考块进行描述, 分别为一个第一参考块和一个第二参考块, 实际 中, 可以为一组第一参考块和一组第二参考块。
步骤 302和步骤 303中, 以两个 P帧之间只有一个 B帧的情况为例, 其当 前待编码块的前后向运动矢量在编码器中和解码器中都通过一个相同的搜索过 程得到, 搜索过程必须保证所搜索到的前后向运动矢量满足勾速线性模型, 本 实施例如图 5所示, 即^ = _^, 其中设 /为备选运动矢量集中的一个备选运动 矢量(前向运动矢量), 是所述备选运动矢量的关联运动矢量(后向运动矢量)。 在此实施例中,运动矢量的搜索精度为 1/4像素,采用整像素 -〉1/2像素 -〉1/4 像素的全搜索过程, 搜索范围为 8 (整像素单位)。 在另一实施例中也可以采用 如加速运动等其他运动模型, 加速运动模型如:
Vf = -(Vb + a) 其中《为速度差。
对于多个连续 B帧的情况, 其前 /后向运动矢量的获得方式基本相同。 在此 实例中, 其不同之处是对前 /后向运动矢量关系的约束。 如果当前 B帧距第一参 考帧 (前向参考帧)之间的距离为7 , 距第二参考帧 (前向参考帧)之间的距 萬为 Tb , 则搜索范围内备选运动矢量和对应的关联运动矢量满足:
Vf l Tf = - vh/ Tb , 其中,
是当前编码块所在编码帧距第一参考帧之间的距离, ^是当前编码块编 码所在编码帧距第二参考帧之间的距离, /为备选运动矢量, b为对应的关联 运动矢量。
304、 采用一个备选运动矢量对应的当前编码块的第一参考块和第二参考 块, 计算第一参考块和第二参考块的相似度。
其中, 采用计算第一参考块的像素和第二参考块像素计算相似度, 计算第 一参考块像素和第二参考块像素间的相似度满足第一参考块像素的数量和第二 参考块像素的数量相同。
305、 在当前帧/ n中当前编码块(Curr_blk ) 的周围利用重建值和参考帧预 测值构造一个模板 TM1, 在备选第一参考块 blkl l 的周围利用重建值构建模板 TM11 , 在备选第二参考块 blk21的周围利用重建值构建模板 TM21。
306、 计算当前编码块的模板 T [l 的模板区域和第一参考块的模板 TM11
的模板区域的相似度, 计算当前编码块的模板 TM1的模板区域和第二参考块的 模板 TM21的模板区域的相似度。
其中所述第一, 第二参考块的模板区域与对应的第一, 第二参考块之间的 位置和当前编码块的模板区域与当前编码块之间的位置相同, 所述第一, 第二 参考块的模板区域的形状与大小和当前编码块的模板区域的形状与大小相同。
307、 根据步骤 304和步骤 306得到的相似度计算对每一个备选运动矢量的 能量信息。
具体体现为能量函数, 可以采用所述至少两个关联参考块的相似度, 当前 编码块的模板区域分别和所述至少两个关联参考块的模板区域的相似度进行加 权叠加得到所述能量函数。 采用计算得到的第一参考块周围的已编码像素和第 二参考块周围已编码像素间的相似度, 当前编码块的模板 TM1的模板区域和第 一参考块的模板 TM11的模板区域的相似度, 当前编码块的模板 TM1的模板区 域和第二参考块的模板 TM21的模板区域的相似度进行加权叠加得到能量函数, 可如下表示:
CostDirect=lambdal 1 *COST(MBforward,MBbackward)+lambdal2 *COST(Templatefor ward,Templatecurrent)+lambdal3 *CO ST(Templatebackrward, Templatecunrent)
其中, lambdal、 lambda2和 lambda3为大于零的加权系数, COST代表相 似度计算函数, MB表示当前编码块, template表示模板区域, forward表示第一 参考块, backward表示第二参考块。
本实施例中用误差和表示相似度时, 能量函数可以如下表示:
CostDirect=lambdal *SAD(MBforward, Bback d)+lambda2 *SAD(Templateforward, Templatecurrent) +lambda3 *SAD(Templatebackrward, Template
308、 选取针对每一个备选运动矢量的能量函数最小时所对应的备选运动矢 量。
309、 根据所述选择的备选运动矢量和所述选择的备选运动矢量的关联运动 矢量确定当前编码块运动矢量。
310、 采用所述当前编码块运动矢量进行当前编码块编解码。
为了更好地实现上述视频图像处 9S的方法, 本实施例还提供了一种编 /解码
器, 用于执行获取视频图像运动信息的方法对当前编码块编码以及解码。
为了更好地实现上述视频图像处理的方法, 本实施例还提供了一种编 /解码 系统, 包括上述的编 /解码器, 编 /解码系统接收输入信号, 将所述接收的输入信 号送入编 /解码器, 所述编 /解码器用于执行上述获取视频图像运动信息的方法, 将编 /解码器的输出进行发送。
实施例三:
以按 P帧编码为例, 如图 6所示, 本实施例提供的视频图像处理方法, 具 体包括以下步骤:
601、 利用当前编码块周围已编码的块的运动矢量组成一个备选运动矢量 集, 其中包括与当前编码块相关的编码块的运动矢量中的部分或者全部。
所述当前编码块可以是完整的宏块, 也可以是宏块的划分块, 在这里以完 整的宏块为例;
所述备选运动矢量集中可以包括: 与当前编码块(Curr_blk )在空间上相关 的周边块的运动矢量 MVL、 MVU、 MVR, MVUL和 MEAN ( MVL、 MVU、 MVR ), 前向参考帧/ w中相同位置块中的运动矢量(如图 5 中的 col_MVl、 col_MV2、 col_MV3、 col_MV4 ) 以及相同位置块的周边块的运动矢量(如图 4 中的 MV1、 MV2 MV12 ), 后向参考帧/ n+1中相同位置块中的运动矢量(如 图 4中的 col_MVl'、 col_MV2'、 col_MV3'、 col_MV4,) 以及相同位置块的周边 块的运动矢量(如图 4中的 MV1'、 MV2' MV12' ) 中的全部或者其中一部 分, 即包括当前编码块的左边块, 上边块, 左上块, 右上块, 在参考帧中和当 前编码块相同位置的块的左边块, 上边块, 左上块, 右上块或其中的一部分, 以及在参考帧中和当前编码块相同位置的块。
针对备选运动矢量集中的每一个备选运动矢量, 执行步骤 602-步骤 607。
602、 选择所述备选运动矢量集中的一个备选运动矢量, 根据该运动矢量在 第一参考帧中找到一个备选第一参考块 blkl2, 在本实施例中, 以当前帧的前向 参考帧/ w为第一参考帧。
603、 对所述备选运动矢量进行时间上外插得到对应的关联运动矢量, 根据 关联运动矢量在所述第一参考帧同 oHj第二参考帧中确定对应的至少一个第二
参考块 blk22。
对所述备选运动矢量进行时间上的外插, 在距离当前编码块更远的第二参 考帧中找到与所述备选运动矢量对应的关联运动矢量, 也可以称为外插运动矢 量, 根据所述外插运动矢量在第二参考帧中确定相应的第二参考块 blk22, 本实 施例中采用的运动模型可以物体匀速直线运动,如图 7所示,其中 Fn为当前帧,
¾为当前待编码块, Bn—i和 β 为 ¾根据备选运动矢量 在 Fn第一参考帧 中找到的参考块, βη—2和 Βη—2 '为 Βη根据备选运动矢量 V,经过缩放在距离 Fn更远 的第二参考帧 Fn_2中找到的参考块, βη_2和 βη_2,相对于 βη的运动矢量为 , 其 中 '与 的关系与 Fn—2和 相对于 Fn的距离以及采用运动模型相关, 如果采 用勾速直线运动模型, 并且 为距离 ^最近的参考帧, 为距离 Fn第二近 的参考帧的情况下, V =2 Vf 。
实施例也可以采用加速运动等其他运动模型, 加速运动模型如下:
F '=2 ( F + « ) 其中 "为速度差。
上述只给出了两个参考帧与当前编码帧直接相邻的情况, 对于两个参考帧 与当前编码帧有一定距离的情况下, 其运动矢量 /和时间域外插得运动矢量 的关系要与参考帧与编码帧的距离有关。 在此实例中, 如果当前编码帧距第一 参考帧 ^之间的距离为7 , 距第二参考帧 之间的距离为7 ', 则搜索范围 内的每一对运动矢量应当满足如下关系:
Vf / Tf = Vf '/ Tf ' , 其中, /为备选运动矢量, / '为外插运动矢量, ^是当前 编码块所在编码帧距第一参考帧之间的距离, ^ '是当前编码块所在编码帧距第 二参考帧之间的距离。
步骤 604 -步骤 610同步骤 304 -步骤 310
604、 采用一个备选运动矢量对应的当前编码块的第一参考块和第二参考块 像素, 计算第一参考块和第二参考块的相似度。
其中, 采用计算第一参考块的像素和第二参考块像素计算相似度, 计算第 一参考块像素和第二参考块像素间的相似度满足第一参考块周围的像素的数量 和第二参考块的像素数量相同。
605、 在当前帧/ η中当前编码块 ^ Curr—blk ) 的周围利用重建值和参考帧预
测值构造一个模板 TM1, 在备选第一参考块 blkl2的周围利用重建值构建模板 TM11 , 在备选第二参考块 blk22的周围利用重建值构建模板 TM21。
606、 计算当前编码块的模板 TM1 的模板区域和第一参考块的模板 TM11 的模板区域的相似度, 计算当前编码块的模板 TM1的模板区域和第二参考块的 模板 TM21的模板区域的相似度。
其中所述第一, 第二参考块的模板区域与对应的第一, 第二参考块之间的 位置和当前编码块的模板区域与当前编码块之间的位置相同, 所述第一, 第二 参考块的模板区域的形状与大小和当前编码块的模板区域的形状与大小相同。
607、 根据步骤 604和步骤 606得到的相似度计算对每一个备选运动矢量的 能量信息。
具体体现为能量函数, 本实施例中用误差和表示相似度, 采用计算得到的 第一参考块周围的已编码像素和第二参考块周围已编码像素间的相似度, 当前 编码块的模板 TM1 的模板区域和第一参考块的模板 TM11 的模板区域的相似 度, 当前编码块的模板 TM1的模板区域和第二参考块的模板 TM21的模板区域 的相似度进行加权叠加得到能量函数, 可如下表示:
CostDirect=lambdal *COST(MBfonVard, BfonVard)+lambda2*COST(Templateforwar d, Templatecurrent) +lambda3*COST (Templateforward' , Template
其中, lambdal、 lambda2和 lambda3为大于等于零的加权系数, COST代 表相似度计算函数, MB表示当前编码块, template表示模板区域, forward表示 第一参考块, forward,表示第二参考块。
本实施例中用误差和表示相似度时, 能量函数可以如下表示:
CostDirect=lambdal *SAD(MBforward, MBforward )+lambda2 * S AD(TemplateforWard, Templatecurrent) +lambda3*SAD (Templateforward' , Tem latecimrent)c
608、 选取针对每一个备选运动矢量的能量函数最 ' j、时所对应的备选运动矢 量。
609、 根据所述选择的备选运动矢量确定当前编码块运动矢量。
610、 采用所述当前编码块运动矢量进行当前编码块编 /解码。
为了更好地实现上述视频图像 ¾2£的方法, 本实施例还提供了一种编 /解码
器, 用于执行获取视频图像运动信息的方法对当前编码块编码以及解码。
为了更好地实现上述视频图像处理的方法, 本实施例还提供了一种编 /解码 系统, 包括上述的编 /解码器, 编 /解码系统接收输入信号, 将所述接收的输入信 号送入编 /解码器, 所述编 /解码器用于执行上述获取视频图像运动信息的方法, 将编 /解码器的输出进行发送。
本领域技术人员可以理解, 可以使用许多不同的工艺和技术中的任意一种 来表示信息、 消息和信号。 例如, 上述说明中提到过的消息、 信息都可以表示 为电压、 电流、 电磁波、 磁场或磁性粒子、 光场或以上任意组合。
本领域普通技术人员可以意识到, 结合本文中所公开的实施例描述的各示 例的单元及算法步骤, 能够以电子硬件、 计算机软件或者二者的结合来实现, 为了清楚地说明硬件和软件的可互换性, 在上述说明中已经按照功能一般性地 描述了各示例的组成及步骤。 这些功能究竟以硬件还是软件方式来执行, 取决 于技术方案的特定应用和设计约束条件。 专业技术人员可以对每个特定的应用 来使用不同方法来实现所描述的功能, 但是这种实现不应认为超出本发明的范 围。
结合本文中所公开的实施例描述的方法或算法的步骤可以用硬件、 处理器 执行的软件模块, 或者二者的结合来实施。 软件模块可以置于随机存储器 ( RAM 内存、 只读存储器(ROM )、 电可编程 ROM、 电可擦除可编程 ROM、 寄存器、 硬盘、 可移动磁盘、 CD-ROM、 或技术领域内所公知的任意其它形式 的存储介质中。
以上所述, 仅为本发明的具体实施方式, 但本发明的保护范围并不局限于 此, 任何熟悉本技术领域的技术人员在本发明揭露的技术范围内, 可轻易想到 的变化或替换, 都应涵盖在本发明的保护范围之内。 因此, 本发明的保护范围 应以所述权利要求的保护范围为准。
Claims
1、 一种获取视频图像运动信息的方法, 其特征在于, 包括:
得到当前编码块的备选运动矢量集中的每一个备选运动矢量对应的当前编 码块的至少两个关联参考块;
对所述每一个备选运动矢量对应的当前编码块的至少两个关联参考块根据 能量函数进行判断, 从所述备选运动矢量集中选择一个备选运动矢量, 所述能 量函数根据所述至少两个关联参考块的相似度以及当前编码块的模板区域分别 和所述至少两个关联参考块的模板区域的相似度得到;
根据至少所述选择的备选运动矢量确定当前编码块运动矢量。
2、 据权利要求 1所述的获取视频图像运动信息的方法, 其特征在于, 所述 得到当前编码块的备选运动矢量集中的每一个备选运动矢量对应的当前编码块 的至少两个关联参考块包括:
根据物体运动模型以及备选运动矢量得到备选运动矢量的关联运动矢量, 通过所述的备选运动矢量以及其关联运动矢量获得至少两个关联参考块。
3、 据权利要求 1所述的获取视频图像运动信息的方法, 其特征在于, 所述 当前编码块的模板区域分别和所述至少两个关联参考块的模板区域的相似度如 下获得:
分别在一个备选运动矢量对应的当前编码块的至少两个关联参考块周围已 编码区域中获取模板区域, 在当前编码块周围已编码区域中获取模板区域, 分 别计算当前编码块的模板区域和所述至少两个关联参考块的模板区域的相似 度, 其中所述至少两个关联参考块的模板区域与对应的关联参考块之间的位置 和当前编码块的模板区域与当前编码块之间的位置相同, 所述至少两个关联参 考块的模板区域的形状与大小和当前编码块的模板区域的形状与大小相同。
4、 根据权利要求 1所述的获取视频图像运动信息的方法, 其特征在于, 所 述至少两个关联参考块的相似度以及当前编码块的模板区域分别和所述至少两 个关联参考块的模板区域的相似度进行加权叠加得到所述能量函数。
5、 根据权利要求 4所述的获取视频图像运动信息的方法, 其特征在于, 所 述相似度包括误差和、 绝对误差和或绝对平方差和。
6、 根据权利要求 4所述的获取视频图像运动信息的方法, 其特征在于, 所 述至少两个关联参考块为两个关联参考块时, 所述至少两个关联参考块的相似 度, 当前编码块的模板区域分别和所述至少两个关联参考块的模板区域的相似 度进行加权叠加得到所述能量函数包括:
CostDirect=lambdal *COST(MBassociatei,MBassociate2)+lambda2*COST(Template assocmtei, Temp late current) +lambda3*COST (Template ass。ciate2, Templatec
其中, lambdal、 lambda2和 lambda3为大于零的加权系数, COST代表相似 度计算函数, MB表示当前编码块, template表示模板区域, associate 1表示当前 编码块的一个关联参考块, associate2表示当前编码块的另一关联参考块。
7、根据权利要求 1或 6所述的获取视频图像运动信息的方法,其特征在于, 所述从所述备选运动矢量集中选择一个备选运动矢量包括:
选择使所述能量函数最小时对应的备选运动矢量。
8、 根据权利要求 1所述的获取视频图像运动信息的方法, 其特征在于, 所 述根据至少所述选择的备选运动矢量确定当前编码块运动矢量包括:
将所述选择的备选运动矢量作为所述当前编码块的运动矢量; 或者, 将所述选择的备选运动矢量以及所述选择的备选运动矢量的关联运动矢量 作为当前编码块的运动矢量。
9、 根据权利要求 2所述的获取视频图像运动信息的方法, 其特征在于, 所 述根据至少所述选择的备选运动矢量确定当前编码块运动矢量包括:
得到所述选择的备选运动矢量和当前编码块通过运动搜索得到的运动矢量 之间的差值, 并将所述差值发送给解码端用于得到当前编码块的运动矢量, 或 者,
得到所述选择的备选运动矢量以及其所述关联运动矢量和当前编码块通过 运动搜索得到的运动矢量对之间的差值, 并将所述差值发送给解码端用于得到 当前编码块的运动矢量。
10、 一种获取视频图像运动信息的方法, 其特征在于, 包括:
采用当前编码块的备选运动矢 5 中的每一个备选运动矢量, 在所述每一 个备选运动矢量的第一参考帧中找到对应的至少一个第一参考块; 对所述每一个备选运动矢量进行时间上外插得到对应的关联运动矢量, 根 据关联运动矢量在所述第一参考帧同向的第二参考帧中确定对应的至少一个第 二参考块;
对所述每一个备选运动矢量对应的第一参考块和所述关联运动式量对应的 第二参考块根据能量函数进行判断, 从所述备选运动矢量集中选择一个备选运 动矢量, 所述能量函数根据所述至少一个第一参考块和所述至少一个第二参考 块的相似度以及当前编码块模板区域分别与所述至少一个第一参考块和所述至 少一个第二参考块的模板区域的相似度得到;
根据所述选择的备选运动矢量确定当前编码块运动矢量。
11、 根据权利要求 10所述的获取视频图像运动信息的方法, 其特征在于, 所述至少两个关联参考块的相似度以及当前编码块的模板区域分别和所述至少 两个关联参考块的模板区域的相似度进行加权叠加得到所述能量函数。
12、 根据权利要求 10所述的备选运动适量集, 其特征在于, 所述备选运动 矢量和对应的关联运动矢量满足:
Vf I Tf = Vf 、I Tf 、 其中, /为备选运动矢量, / '为所述备选运动矢量对应的 关联运动矢量, ^是当前编码块所在编码帧距第一参考帧之间的距离, '是当 前编码块所在编码帧距第二参考帧之间的距离。
13、 一种获取视频图像运动信息的方法, 其特征在于, 包括:
采用当前编码块的备选运动矢量集中的每一个备选运动矢量, 在所述每一 个备选运动矢量的第一参考帧中找到对应的第一参考块;
确定所述每一个备选运动矢量对应的关联运动矢量, 在与所述第一参考帧 反向的所述关联运动矢量的第二参考帧中确定对应的备选第二参考块;
对所述每一个备选运动矢量对应的第一参考块以及所述关联运动矢量对应 的第二参考块根据能量函数进行判断, 从所述备选运动矢量集中选择一个备选 运动矢量, 所述能量函数根据所述第一参考块和所述第二参考块的相似度以及 当前编码块模板区域分别与所述第一参考块和所述第二参考块的模板区域的相 似度得到; 16 根据所述选择的备选运动矢量以及所述关联运动矢量确定当前编码块运动 矢量。
14、 根据权利要求 13所述的获取视频图像运动信息的方法, 其特征在于, 所述至少两个关联参考块的相似度以及当前编码块的模板区域分别和所述至少 两个关联参考块的模板区域的相似度进行加权叠加得到所述能量函数。
15、 根据权利要求 13所述的方法, 其特征在于, 所述备选运动运动矢量和 所述备选运动矢量对应的关联运动矢量满足:
其中, ^是当前编码块所在编码帧距第一参考帧 f之间的 距离, 是当前编码块编码所在编码帧距第二参考帧 b之间的距离, Vf为备选 运动矢量, Vb为所述备选运动矢量对应的关联运动矢量。
16、 一种编 /解码器, 其特征在于, 用于执行包括权利要求 1、 10和 13任一 的获取视频图像运动矢量信息的方法。
17、 一种编 /解码系统, 其特征在于, 所述编 /解码系统包括如权利要求 16 所述的编 /解码器, 所述编 /解码系统用于接收输入信号, 送入所述编 /解码器, 并 发送所述编 /解码器的输出, 其中, 所述编 /解码器用于执行包括权利要求 1、 10 和 13任一的获取视频图像运动矢量信息的方法。
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201010146533.2 | 2010-04-09 | ||
| CN 201010146533 CN102215387B (zh) | 2010-04-09 | 2010-04-09 | 视频图像处理方法以及编/解码器 |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2011124159A1 true WO2011124159A1 (zh) | 2011-10-13 |
Family
ID=44746484
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2011/072568 Ceased WO2011124159A1 (zh) | 2010-04-09 | 2011-04-09 | 视频图像处理方法以及编/解码器 |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN102215387B (zh) |
| WO (1) | WO2011124159A1 (zh) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN108769685A (zh) * | 2018-06-05 | 2018-11-06 | 腾讯科技(深圳)有限公司 | 检测图像压缩编码效率的方法、装置及存储介质 |
Families Citing this family (8)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN104427345B (zh) * | 2013-09-11 | 2019-01-08 | 华为技术有限公司 | 运动矢量的获取方法、获取装置、视频编解码器及其方法 |
| CN105516724B (zh) * | 2014-09-23 | 2019-05-14 | 浙江大学 | 一种运动信息存储压缩方法 |
| CN109005412B (zh) * | 2017-06-06 | 2022-06-07 | 北京三星通信技术研究有限公司 | 运动矢量获取的方法及设备 |
| CN111919439B (zh) | 2018-04-02 | 2022-01-14 | 华为技术有限公司 | 一种运动矢量的获取方法和装置、一种运动矢量集合的构建方法和装置及计算机可读存储介质 |
| CN110662074B (zh) * | 2018-06-28 | 2021-11-23 | 杭州海康威视数字技术股份有限公司 | 一种运动矢量确定方法和设备 |
| CN113938680B (zh) * | 2018-09-05 | 2022-11-25 | 华为技术有限公司 | 视频序列的图像译码方法和装置以及终端设备 |
| CN114866777B (zh) * | 2018-09-20 | 2024-11-22 | 杭州海康威视数字技术股份有限公司 | 一种解码、编码方法及其设备 |
| WO2025217773A1 (zh) * | 2024-04-15 | 2025-10-23 | Oppo广东移动通信有限公司 | 一种视频编解码方法、编码器、解码器以及存储介质 |
Citations (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN1719899A (zh) * | 2004-07-06 | 2006-01-11 | 汤姆森许可贸易公司 | 针对块集合的编码选择运动矢量的方法与设备 |
| CN101422047A (zh) * | 2006-04-14 | 2009-04-29 | Nxp股份有限公司 | 图像边界处的运动估计 |
| WO2010035734A1 (ja) * | 2008-09-24 | 2010-04-01 | ソニー株式会社 | 画像処理装置および方法 |
-
2010
- 2010-04-09 CN CN 201010146533 patent/CN102215387B/zh active Active
-
2011
- 2011-04-09 WO PCT/CN2011/072568 patent/WO2011124159A1/zh not_active Ceased
Patent Citations (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN1719899A (zh) * | 2004-07-06 | 2006-01-11 | 汤姆森许可贸易公司 | 针对块集合的编码选择运动矢量的方法与设备 |
| CN101422047A (zh) * | 2006-04-14 | 2009-04-29 | Nxp股份有限公司 | 图像边界处的运动估计 |
| WO2010035734A1 (ja) * | 2008-09-24 | 2010-04-01 | ソニー株式会社 | 画像処理装置および方法 |
Non-Patent Citations (1)
| Title |
|---|
| SIXIN LIN ET AL.: "TE1 : Huawei report on DMVD improvements.", JCT-VC OFITU-T SG 16 WP3 AND ISO/IEC JTC1/SC29/WG11. 2ND MEETING, 28 July 2010 (2010-07-28), GENEVA, pages 6 * |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN108769685A (zh) * | 2018-06-05 | 2018-11-06 | 腾讯科技(深圳)有限公司 | 检测图像压缩编码效率的方法、装置及存储介质 |
Also Published As
| Publication number | Publication date |
|---|---|
| CN102215387B (zh) | 2013-08-07 |
| CN102215387A (zh) | 2011-10-12 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| WO2011124159A1 (zh) | 视频图像处理方法以及编/解码器 | |
| KR101443169B1 (ko) | 비디오 이미지의 움직임 정보를 취득하는 방법, 장치, 및 기기, 그리고 템플릿 구성 방법 | |
| CN101557514B (zh) | 一种帧间预测编解码方法、装置及系统 | |
| CN116248898B (zh) | 用于多参考预测的运动矢量修正 | |
| US10051282B2 (en) | Method for obtaining motion information with motion vector differences | |
| CN108134939B (zh) | 一种运动估计方法及装置 | |
| TWI493975B (zh) | 用於低複雜度移動向量導出之系統及方法 | |
| CN102215386B (zh) | 视频图像块处理方法及装置 | |
| CN101605256A (zh) | 一种视频编解码的方法及装置 | |
| CN110519600A (zh) | 帧内帧间联合预测方法、装置、编解码器及存储装置 | |
| CN116506642B (zh) | 通过子像素运动矢量细化对视频数据编解码的方法和装置 | |
| CN101686393A (zh) | 应用于模板匹配的快速运动搜索方法及装置 | |
| CN102215389A (zh) | 一种局部亮度补偿的视频编解码方法及装置 | |
| WO2012119456A1 (zh) | 视频图像的编解码方法、编码装置、解码装置及其系统 | |
| WO2019072049A1 (zh) | 一种帧间预测方法、装置及存储介质 | |
| Tai et al. | A multi-pass true motion estimation scheme with motion vector propagation for frame rate up-conversion applications | |
| KR20120055761A (ko) | 적응형 움직임 탐색 범위 결정 장치 및 방법 | |
| CN103475879A (zh) | 一种分布式视频编码中边信息生成方法 | |
| TWI225372B (en) | Method of detecting motion vector | |
| CN111510726B (zh) | 一种编解码方法及其设备 | |
| WO2022116574A1 (zh) | 基于二次多项式的运动矢量预测方法、系统及计算机介质 | |
| CN103152566A (zh) | 一种视频帧率提升方法 | |
| CN102111622B (zh) | 一种视频图像的时域错误隐藏方法及装置 | |
| Zhao et al. | Enhanced Temporal Motion Derivation Beyond VVC | |
| CN112449180A (zh) | 一种编解码方法、装置及其设备 |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 11765077 Country of ref document: EP Kind code of ref document: A1 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |
|
| 122 | Ep: pct application non-entry in european phase |
Ref document number: 11765077 Country of ref document: EP Kind code of ref document: A1 |