CN100384216C - Video data compression method and apparatus with optimized searching algorithm - Google Patents

Video data compression method and apparatus with optimized searching algorithm Download PDF

Info

Publication number
CN100384216C
CN100384216C CNB2005100731972A CN200510073197A CN100384216C CN 100384216 C CN100384216 C CN 100384216C CN B2005100731972 A CNB2005100731972 A CN B2005100731972A CN 200510073197 A CN200510073197 A CN 200510073197A CN 100384216 C CN100384216 C CN 100384216C
Authority
CN
China
Prior art keywords
search
video data
searching
searching algorithm
data compression
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
Application number
CNB2005100731972A
Other languages
Chinese (zh)
Other versions
CN1700736A (en
Inventor
怀千江
白锋
王浩
Original Assignee
Vimicro Corp
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Vimicro Corp filed Critical Vimicro Corp
Priority to CNB2005100731972A priority Critical patent/CN100384216C/en
Publication of CN1700736A publication Critical patent/CN1700736A/en
Application granted granted Critical
Publication of CN100384216C publication Critical patent/CN100384216C/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

The invention discloses a video data compression method and apparatus with optimized searching algorithm of searching template, and the method includes following steps: confirming off-set address of other searching blocks relative to current searching block according to searching template and searching step length; Calculating initial address of other searching blocks according to the initial address and the said off-set address of current searching block in searching; And pre-reading the video data of current searching block and the video data of other searching blocks into cache in sequence before matching operation. The invention improves success rate for memory cache.

Description

The video data compression method of optimization searching algorithm and device
Technical field
The present invention relates to the estimation in the video compression algorithm, especially, relate to video data compression method and the device of optimizing the searching algorithm that uses search pattern.
Background technology
Present video compression algorithm mostly is based on estimation, just predict the pixel shift position of present frame according to the pixel of former frame, the error of the motion vectors of generation and predicted value and actual value is handled as the data after compressing and is transmitted.Three kinds of frame of video I, P, B are generally arranged in actual algorithm.The I frame is not carry out motion compensation directly to compress, and the P frame is the estimation of carrying out forward direction, and the B frame occurs in than higher compression level usually, is two-way predictive frame.The amount of calculation maximum is exactly estimation in a video compression algorithm, and estimation is the most time-consuming module.
The core concept of estimation is exactly to want operation times few more, and convergence rate is fast more, finds the position with former frame respective pixel piece coupling.Relatively Chang Yong searching algorithm has three-step approach, gradient method, diamond method etc.
Searching algorithm when three-step approach (TSS) is the intraframe coding estimation.For computation complexity that reduces searching algorithm and the accuracy that improves motion compensation, TSS adopts 9 squares that object block is carried out Optimum Matching, and its basic thought is to utilize the shape of search pattern and size produces material impact to motion estimation algorithm speed and precision characteristic.When search Optimum Matching point, select little search pattern may be absorbed in local optimum, select big search pattern then possibly can't find optimum point.
With reference to Fig. 1, Fig. 1 is the schematic diagram of three-step approach search pattern in the prior art.The search procedure of three-step approach is as follows: the first step is the center with the object block, gets 8 points toward the four direction expansion with a fixed step size, compares; Second step reduced by half step-length, was that 8 points are got in expansion around the middle mind-set with optimum piece before, compared; Repeat first, second step, less than 1, obtain optimum point up to step-length.
Diamond search (DS, Diamond Search) method is gained the name with the search pattern shape, has simple, robust, characteristics of high efficiency, is one of fast search algorithm of existing best performance.The DS algorithm is at the basic law of motion vector in the video image, selected the search pattern of two kinds of shape sizes for use, a kind of is bitellos search pattern (LDSP, Large Diamond SearchPattern), with reference to Fig. 2, Fig. 2 is the schematic diagram of bitellos search pattern in the prior art, and it comprises 9 position candidate; Another kind is melee search pattern (SDSP, Small DiamondSearch Pattern), and with reference to Fig. 3, Fig. 3 is the schematic diagram of the medium and small diamond search template of prior art, and it comprises 5 position candidate.
DS algorithm search process is as follows: the incipient stage is reused the bitellos search pattern earlier, drops on the bitellos center up to best matching blocks.Because the LDSP step-length is big, thereby the hunting zone is wide, can realize coarse positioning, it is local minimum that search can not sunk into.After coarse positioning finishes, can think optimum point just LDSP on every side 8 points enclose in the diamond-shaped area.And then the accurate location of using the melee search pattern to realize best matching blocks, not producing, thereby improve the estimation precision than macrorelief.
In three step searching algorithms and DS searching algorithm, the position of the match point that need read changes, and these positions are discontinuous in internal memory.And in system cache, the address of data is continuous.Therefore operating system is when carrying out buffer memory, and the internal storage data failure rate increases, and directly the visit to internal memory will inevitably cause the visit inefficacy, increases access latency.
Summary of the invention
The technical problem to be solved in the present invention is to shorten the additional wait time that processor or hardware logic cause because of cache invalidation when carrying out searching algorithm calculating.
According to a first aspect of the invention, a kind of video data compression method of optimizing the searching algorithm that uses search pattern is provided, described method comprises: according to search pattern and step-size in search, determine that all the other each search block are with respect to the offset address of current search piece in the search pattern; In search,, calculate the initial address of all the other each search block according to initial address and described each offset address of current search piece; And before carrying out matching operation, the video data of current search piece and the video data of all the other each search block are read in buffer memory successively in advance.
In first aspect, preferably, the searching algorithm of described use search pattern comprises the searching algorithm that uses single search pattern.
Preferably, the searching algorithm of the single search pattern of described use comprises three step searching algorithms.
Preferably, the searching algorithm of described use search pattern comprises the searching algorithm that uses the multi-pass decoding template.
Preferably, the searching algorithm of described use multi-pass decoding template comprises the diamond search algorithm.
Preferably, described current search piece is positioned at the center of template.
According to a second aspect of the invention, a kind of video data compression device of optimizing the searching algorithm that uses search pattern is provided, described device comprises: offset address is determined device, be used for according to search pattern and step-size in search, determine that all the other each search block are with respect to the offset address of current search piece in the search pattern; The initial address calculation element is used for initial address and described each offset address according to the current search piece in search, calculate the initial address of all the other each search block; And the pre-read apparatus of blocks of data, be used for before carrying out matching operation, the video data of current search piece and the video data of all the other each search block are read in buffer memory successively in advance.
In second aspect, preferably, the algorithm of described use search pattern comprises the searching algorithm that uses single search pattern.
Preferably, the searching algorithm of the single search pattern of described use comprises three step searching algorithms.
Preferably, the searching algorithm of described use search pattern comprises the searching algorithm that uses the multi-pass decoding template.
Preferably, the searching algorithm of described use multi-pass decoding template comprises the diamond search algorithm.
Preferably, described current search piece is positioned at the center of template.
Although searching algorithm is discontinuous to reading of piece, but, can utilize the buffer memory read ahead technique to improve single internal memory and read in advance by calculating the address of specified data piece according to the present invention, thereby the raising success rate for memory cache shortens additional wait time of processor or hardware logic in a large number.
Description of drawings
Fig. 1 is the schematic diagram of three-step approach search pattern in the prior art;
Fig. 2 is the schematic diagram of bitellos search pattern in the prior art;
Fig. 3 is the schematic diagram of the medium and small diamond search template of prior art;
Fig. 4 is a flow chart of optimizing the video data compression method of three step searching algorithms according to the present invention;
Fig. 5 is a flow chart of optimizing the video data compression method of diamond search algorithm according to the present invention.
For understanding the present invention better, the invention will be further described below in conjunction with the drawings and specific embodiments.
Embodiment
According to the present invention, the process of optimizing the video data compression method of three step searching algorithms is: at first, offset address is determined search pattern and the step-size in search of device according to three-step approach, determines that all the other each search block are with respect to the offset address of current search piece in the search pattern.Can set up an offset address table of comparisons, corresponding step-size in search and template index can obtain the offset address of all the other each search block with respect to the current search piece, and preferably, the current search piece is positioned at the center of template.With reference to Fig. 1,, be the center with the current search piece for the three-step approach search pattern, from the search block that is positioned at its left side along clockwise direction, the offset address of each search block is respectively as shown in the table, and wherein n is a step-size in search, the offset address of current search piece is (0,0).
(0,0) (-n,0) (-n,n) (0,n) (n,n)
(n,0) (n,-n) (0,-n) (-n,-n)
Secondly, the initial address calculation element according to initial address and each offset address of current search piece, calculates the initial address of all the other each search block in search.As current search piece initial address is (72,36), and step-length is 4, and so the initial address of Dui Ying each search block is respectively (72,36), (72-4,36), (72-4,36+4), and the like.
At last, the pre-read apparatus of blocks of data read in buffer memory successively in advance with the video data of current search piece and the video data of all the other each search block before carrying out matching operation.Here, the matching criterior commonly used of matching operation comprise absolute error and (SAD), mean square error (MSE) and Normalized Cross Correlation Function (NCCF), wherein SAD does not need multiplying, realizes simple.Determined the initial address of piece,, just the video data of piece can have been read in the buffer memory because piece is the block of pixels of 8 * 8 sizes.At embedded platform, as the instruction of specially buffer memory being handled is provided on DSP and the ARM platform.Use the special instruction of processor or DSP, video data can be read buffer memory as the PLD instruction of ARM.Like this, read (Cache preload) in advance with buffer memory and before computing, carry out buffer memory, improved systematic function.
Before the three-step approach first step, read the offset address table of comparisons earlier, the data of assigned address are read in the buffer memory.When calculating an optimum point, according to new step-length, the video data with assigned address reads in buffer memory in advance, constantly repeats.With reference to Fig. 4, Fig. 4 is a flow chart of optimizing the video data compression method of three step searching algorithms according to the present invention.The concrete steps of said process are as follows: 1) set up a TSS template offset address table of comparisons; 2) read blocks of data in the reference frame; 3) block address with correspondence is the center, obtains the initial address of each piece from the offset address table of comparisons successively; 4) when system-computed SAD, blocks of data is read in the buffer memory, relatively the result before preserves less value, repeats 8 times; 5) if the sad value minimum of central point piece, this search end so.Otherwise, central point is moved on to that piece of sad value minimum, after step-length is reduced by half, repeated execution of steps 3), less than 1, obtain optimal value up to step-length.
According to the present invention, the process of optimizing the video data compression method of diamond search algorithm is: at first, offset address is determined the two kind templates of device according to the DS searching algorithm, determines that respectively all the other each search block are with respect to the offset address of current search piece in each template.Can set up two offset address tables of comparisons, corresponding step-size in search and template index can obtain the offset address of each search block with respect to the current search piece, and preferably, the current search piece is positioned at the center of template.With reference to Fig. 2,3, with the current search piece is the center, from be positioned at its left side search block along clockwise direction, the offset address of each search block is respectively as shown in LDSP table, SDSP table in the large and small diamond search template, wherein the offset address of current search piece is (0,0), n is the current search step-length of large form, and the step-size in search of little template is 1.
LDSP (0,0) (-n,0) (-n/2,n/2) (0,n) (n/2,n/2) (n,0) (n/2,-n/2) (0,-n) (-n/2,-n/2)
SDSP (0,0) (-1,0) (0,1) (1,0) (0,-1)
Secondly, the initial address calculation element according to initial address and each offset address of current search piece, calculates the initial address of all the other each search block in search.As current search piece initial address is (72,36), and step-length is 2, and so the initial address of each search block is respectively (72,36) in the Dui Ying large form, (72-2,36), (72-2/2,36+2/2), and the like.
At last, the pre-read apparatus of blocks of data read in buffer memory successively in advance with the video data of current search piece and the video data of all the other each search block before carrying out matching operation.Similarly, the matching criterior commonly used of matching operation here also comprise absolute error and (SAD), mean square error (MSE) and Normalized Cross Correlation Function (NCCF).Still can use the special instruction of processor or DSP, instruction reads buffer memory with video data as the PLD of ARM, utilizes buffer memory to read (Cachepreload) in advance equally and carried out buffer memory before computing, has improved systematic function.
With reference to Fig. 5, Fig. 5 is a flow chart of optimizing the video data compression method of diamond search algorithm according to the present invention.The concrete steps of said process are: the blocks of data that 1) reads a reference frame; 2) according to the initial address of first piece, first data are read in the buffer memory, in the LDSP table, determined the initial address of all the other each pieces according to current step-length; When 3) carrying out SAD calculating, second piece read in the buffer memory, relatively also preserved, repeat 8 times than the figure of merit in system; 4) if the sad value minimum of central point piece then enters little template matches link, otherwise central point is moved on to that piece of SAD minimum, adjust step-length, repeated execution of steps 2); 5) determine the initial address of first piece in SDSP table, first video data is read in the buffer memory; When 6) carrying out current block SAD calculating, second piece read in the buffer memory, relatively also preserved, repeat 4 times than the figure of merit in system; 7) if the sad value minimum of central point, then current block search finishes, otherwise central point is moved on to that piece of sad value minimum, repeated execution of steps 5), until obtaining optimum point.
In the process and concrete steps of above-mentioned three step of optimization searching algorithm and diamond search algorithm, the center that described current search piece is positioned at search pattern is an example, and the current search piece also can be arranged in search pattern except that excentral other any positions here.
Preamble is respectively to optimize the three-step approach of using single search pattern and to optimize and use the DS algorithm of two-stage search pattern to be example, the description of property that the invention has been described.In addition, the present invention also can optimize the searching algorithm that uses other single search patterns, and optimizes the searching algorithm that uses other multi-pass decoding templates, and as four step rule, two dimensional logarithmic method etc., this is obvious to those skilled in the art.
Obviously, the present invention described here can have many variations, and this variation can not be thought and departs from the spirit and scope of the present invention.Therefore, the change that all it will be apparent to those skilled in the art all is included within the covering scope of these claims.

Claims (12)

1. video data compression method of optimizing the searching algorithm that uses search pattern comprises:
According to search pattern and step-size in search, determine that all the other each search block are with respect to the offset address of current search piece in the search pattern;
In search,, calculate the initial address of all the other each search block according to initial address and described each offset address of current search piece; And before carrying out matching operation, the video data of current search piece and the video data of all the other each search block are read in buffer memory successively in advance.
2. video data compression method as claimed in claim 1, the searching algorithm of described use search pattern comprises the searching algorithm that uses single search pattern.
3. video data compression method as claimed in claim 2, the searching algorithm of the single search pattern of described use comprise three step searching algorithms.
4. video data compression method as claimed in claim 1, the searching algorithm of described use search pattern comprise the searching algorithm that uses the multi-pass decoding template.
5. video data compression method as claimed in claim 4, the searching algorithm of described use multi-pass decoding template comprises the diamond search algorithm.
6. as each described video data compression method in the claim 1 to 5, described current search piece is positioned at the center of template.
7. video data compression device of optimizing the searching algorithm that uses search pattern comprises:
Offset address is determined device, is used for according to search pattern and step-size in search, determines that all the other each search block are with respect to the offset address of current search piece in the search pattern;
The initial address calculation element is used for initial address and described each offset address according to the current search piece in search, calculate the initial address of all the other each search block; And the pre-read apparatus of blocks of data, be used for before carrying out matching operation, the video data of current search piece and the video data of all the other each search block are read in buffer memory successively in advance.
8. video data compression device as claimed in claim 7, the searching algorithm of described use search pattern comprises the searching algorithm that uses single search pattern.
9. video data compression device as claimed in claim 8, the searching algorithm of the single search pattern of described use comprise three step searching algorithms.
10. video data compression device as claimed in claim 7, the searching algorithm of described use search pattern comprise the searching algorithm that uses the multi-pass decoding template.
11. video data compression device as claimed in claim 10, the searching algorithm of described use multi-pass decoding template comprises the diamond search algorithm.
12. as each described video data compression device in the claim 7 to 11, described current search piece is positioned at the center of template.
CNB2005100731972A 2004-12-31 2005-06-01 Video data compression method and apparatus with optimized searching algorithm Active CN100384216C (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CNB2005100731972A CN100384216C (en) 2004-12-31 2005-06-01 Video data compression method and apparatus with optimized searching algorithm

Applications Claiming Priority (5)

Application Number Priority Date Filing Date Title
CN200410103997 2004-12-31
CN2004101039946 2004-12-31
CN200410103994.6 2004-12-31
CN200410103997.X 2004-12-31
CNB2005100731972A CN100384216C (en) 2004-12-31 2005-06-01 Video data compression method and apparatus with optimized searching algorithm

Publications (2)

Publication Number Publication Date
CN1700736A CN1700736A (en) 2005-11-23
CN100384216C true CN100384216C (en) 2008-04-23

Family

ID=35476578

Family Applications (1)

Application Number Title Priority Date Filing Date
CNB2005100731972A Active CN100384216C (en) 2004-12-31 2005-06-01 Video data compression method and apparatus with optimized searching algorithm

Country Status (1)

Country Link
CN (1) CN100384216C (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101977325B (en) * 2010-11-19 2012-02-22 上海师范大学 Novel block matching motion estimation method
CN106331703B (en) * 2015-07-03 2020-09-08 华为技术有限公司 Video encoding and decoding method, video encoding and decoding device

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1452409A (en) * 2002-04-18 2003-10-29 华为技术有限公司 Picture motion estimating method
CN1615023A (en) * 2004-12-03 2005-05-11 大唐微电子技术有限公司 Front block and reference block matching computing method and motioning estimating method
CN1212014C (en) * 2003-08-18 2005-07-20 北京工业大学 Video coding method based on time-space domain correlation quick movement estimate
CN1216497C (en) * 2003-10-17 2005-08-24 清华大学 Video codeconversion method based on motion vector systemsis
CN1674679A (en) * 2005-05-12 2005-09-28 北京中星微电子有限公司 Video frequency data compressing method and apparatus for optimizing search algorithm
CN1225127C (en) * 2003-09-12 2005-10-26 中国科学院计算技术研究所 A coding/decoding end bothway prediction method for video coding

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1452409A (en) * 2002-04-18 2003-10-29 华为技术有限公司 Picture motion estimating method
CN1212014C (en) * 2003-08-18 2005-07-20 北京工业大学 Video coding method based on time-space domain correlation quick movement estimate
CN1225127C (en) * 2003-09-12 2005-10-26 中国科学院计算技术研究所 A coding/decoding end bothway prediction method for video coding
CN1216497C (en) * 2003-10-17 2005-08-24 清华大学 Video codeconversion method based on motion vector systemsis
CN1615023A (en) * 2004-12-03 2005-05-11 大唐微电子技术有限公司 Front block and reference block matching computing method and motioning estimating method
CN1674679A (en) * 2005-05-12 2005-09-28 北京中星微电子有限公司 Video frequency data compressing method and apparatus for optimizing search algorithm

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
区哉法立体匹配的实时性问题研究. 杜歆,厉晓华,顾伟康,丁蒋霖.浙江大学学报,第30卷第6期. 2003 *
基于H.264编码的运动估计快速搜索算法. 智西湖,智艾娣.计算机应用,第24卷第4期. 2004 *
基于H264编码的运动估计快速搜索算法. 智西湖,智艾娣.计算机应用,第24卷第4期. 2004 *

Also Published As

Publication number Publication date
CN1700736A (en) 2005-11-23

Similar Documents

Publication Publication Date Title
US8705611B2 (en) Image prediction encoding device, image prediction encoding method, image prediction encoding program, image prediction decoding device, image prediction decoding method, and image prediction decoding program
CN101605262B (en) Method and device for predicting size motion of variable block
CN100527848C (en) Motion vector detecting device and motion vector detecting method
CN101267556B (en) Quick motion estimation method and video coding and decoding method
CN101006729A (en) Motion estimation in video compression systems
CN109348234B (en) Efficient sub-pixel motion estimation method and system
CN101668202A (en) Method and device for selecting intra-frame prediction mode
CN102291581A (en) Realizing method of self-adaptive motion estimation supporting frame field
CN101163244A (en) Picture element caching method and system in movement compensation process of video decoder
CN101505427A (en) Movement estimation apparatus in video compression encoding algorithm
CN100384216C (en) Video data compression method and apparatus with optimized searching algorithm
US6687299B2 (en) Motion estimation method and apparatus for interrupting computation which is determined not to provide solution
CN101188761A (en) Method for optimizing DCT quick algorithm based on parallel processing in AVS
JPH04150284A (en) Moving vector detection method and its device
CN1674679A (en) Video frequency data compressing method and apparatus for optimizing search algorithm
CN106572354B (en) Image block-based search matching method and system and video processing equipment
US11057637B1 (en) Efficient video motion estimation by reusing a reference search region
JP4590335B2 (en) Image processing apparatus and image processing method
CN101227616B (en) H.263/AVC integer pixel vectors search method
CN103841427A (en) Method for sliding search window and device thereof
CN113347417B (en) Method, device, equipment and storage medium for improving rate distortion optimization calculation efficiency
US11800146B2 (en) Centroid point search-based fast global motion matching method and system for dynamic point cloud
US20020168008A1 (en) Method and apparatus for coding moving pictures
US20060104358A1 (en) Method and apparatus for motion estimation using adaptive search pattern for video sequence compression
JP5120327B2 (en) Motion vector detection device

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
C41 Transfer of patent application or patent right or utility model
TR01 Transfer of patent right

Effective date of registration: 20090306

Address after: Tianjin economic and Technological Development Zone fourth, 80 Avenue, Tian Da Science and Technology Park, block A1, 2

Patentee after: Vimicro Electronics Co., Ltd.

Address before: No. 35, Xueyuan Road, Beijing, Haidian District, Nanjing building, 15 Floor

Patentee before: Beijing Vimicro Corporation

ASS Succession or assignment of patent right

Owner name: ZHONGXING ELECTRONIC CO., LTD.

Free format text: FORMER OWNER: ZHONGXING MICROELECTRONCI CO., LTD., BEIJING

Effective date: 20090306