CN107197281A - A kind of method and electronic equipment for realizing estimation - Google Patents
A kind of method and electronic equipment for realizing estimation Download PDFInfo
- Publication number
- CN107197281A CN107197281A CN201710334106.9A CN201710334106A CN107197281A CN 107197281 A CN107197281 A CN 107197281A CN 201710334106 A CN201710334106 A CN 201710334106A CN 107197281 A CN107197281 A CN 107197281A
- Authority
- CN
- China
- Prior art keywords
- block
- sub
- pixels
- error amount
- motion vector
- 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.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 49
- 230000033001 locomotion Effects 0.000 claims abstract description 111
- 239000013598 vector Substances 0.000 claims abstract description 99
- 238000005192 partition Methods 0.000 claims abstract description 19
- 238000012545 processing Methods 0.000 claims description 7
- 230000006835 compression Effects 0.000 abstract description 11
- 238000007906 compression Methods 0.000 abstract description 11
- 238000010845 search algorithm Methods 0.000 description 12
- 238000004364 calculation method Methods 0.000 description 9
- 230000008569 process Effects 0.000 description 6
- 230000008901 benefit Effects 0.000 description 5
- 229910003460 diamond Inorganic materials 0.000 description 5
- 239000010432 diamond Substances 0.000 description 5
- 230000006870 function Effects 0.000 description 5
- 230000004048 modification Effects 0.000 description 4
- 238000012986 modification Methods 0.000 description 4
- 238000010295 mobile communication Methods 0.000 description 3
- 238000013139 quantization Methods 0.000 description 3
- 238000010586 diagram Methods 0.000 description 2
- 230000000694 effects Effects 0.000 description 2
- 238000005516 engineering process Methods 0.000 description 2
- 230000009467 reduction Effects 0.000 description 2
- 241000208340 Araliaceae Species 0.000 description 1
- 235000005035 Panax pseudoginseng ssp. pseudoginseng Nutrition 0.000 description 1
- 235000003140 Panax quinquefolius Nutrition 0.000 description 1
- 101710137710 Thioesterase 1/protease 1/lysophospholipase L1 Proteins 0.000 description 1
- 230000009471 action Effects 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 238000006243 chemical reaction Methods 0.000 description 1
- 238000000205 computational method Methods 0.000 description 1
- 230000008030 elimination Effects 0.000 description 1
- 238000003379 elimination reaction Methods 0.000 description 1
- 235000008434 ginseng Nutrition 0.000 description 1
- 238000012544 monitoring process Methods 0.000 description 1
- XLYOFNOQVPJJNP-UHFFFAOYSA-N water Substances O XLYOFNOQVPJJNP-UHFFFAOYSA-N 0.000 description 1
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/10—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
- H04N19/169—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
- H04N19/17—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object
- H04N19/176—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object the region being a block, e.g. a macroblock
-
- 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/10—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
- H04N19/169—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
- H04N19/182—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being a pixel
-
- 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/513—Processing of motion vectors
-
- 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/57—Motion estimation characterised by a search window with variable size or shape
-
- 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/577—Motion compensation with bidirectional frame interpolation, i.e. using B-pictures
-
- 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/593—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving spatial prediction techniques
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Compression Or Coding Systems Of Tv Signals (AREA)
Abstract
The invention discloses a kind of method and electronic equipment for realizing estimation, frame of video is first divided into 16*16 sub-block of pixels, the first motion vector and the first error amount of the 16*16 sub-block of pixels is then calculated;The second motion vector and the second error amount are calculated 16*16 sub-block of pixels is divided into 4 8*8 sub-block of pixels;Contrast the first motion vector and the second motion vector;If the first error amount is more than the second error amount, then 16*16 sub-block of pixels is divided into 16 4*4 sub-block of pixels the 3rd motion vectors of calculating and the 3rd error amount;Contrasted again with the second error amount, and then estimation is carried out from the macroblock partition and motion vector of minimal error.The present invention determines the motion vector needed for specific estimation using way of contrast, can reduce data volume and save the time, improve compression ratio.
Description
Technical field
The application is related to field of video compression, more particularly to a kind of method and electronic equipment for realizing estimation.
Background technology
The encoding and decoding of video are mainly by prediction is changed, coding, come what is realized.Prediction is divided into inter prediction again and frame in is pre-
Survey, infra-frame prediction is used for compression stroke correlation, inter prediction is used for compression time correlation.
Infra-frame prediction refers to define better prediction algorithm in a program, and such as 4*4 macro blocks have 9 kinds of prediction algorithms (vertical, water
It is flat, diagonal, average value ... ..), 16*16 macro blocks have 4 kinds of prediction algorithms, and 8*8 macro blocks have 4 kinds of prediction algorithms.
Inter prediction refers to that (overall situation is received by motion estimation algorithm from the encoded image in the front and back of current slice
Rope, diamond receives rope, and hexagon receives rope etc.) calculate a motion vector of the current block relative to reference picture.
After prediction processing operation, the pixel number evidence of a macro block can be converted to the prediction mode of macro block
Both macro block (mb) type, predictive mode, the information such as motion arrow, with space size (size of data) phase of the pixel number of macro block according to occupancy
Than macro block (mb) type, predictive mode, the space shared by motion vector can be very small, and frame of video is in units of macro block, so as to reach
The purpose that video data is compressed.
And how to reduce the video data volume to improve compression efficiency, then it is the problem of the application will consider.
The content of the invention
Invention provides a kind of method and electronic equipment for realizing estimation, regarded with solving current how reducing
Frequency data volume improves the technical problem of compression efficiency.
In order to solve the above technical problems, the invention provides a kind of method for realizing estimation, methods described includes:
Frame of video is divided into multiple 16*16 sub-block of pixels, the sub-block of pixels for each 16*16 does following place
Reason:
Calculate the first motion vector and the first error amount of the 16*16 sub-block of pixels;
The 16*16 sub-block of pixels is divided into 4 8*8 sub-block of pixels;
Calculate the second motion vector and the second error amount of 4 8*8 sub-block of pixels;
Contrast first motion vector and second motion vector;
If first error amount is more than second error amount, the 16*16 sub-block of pixels is divided into 16 4*4 pictures
Sub-prime block;
Calculate the 3rd motion vector and the 3rd error amount of 16 4*4 sub-block of pixels;
3rd error amount and second error amount are contrasted;
If the 3rd error amount is less than second error amount, it is determined that go out the corresponding 4*4 pictures of minimum 3rd error amount
The macroblock partition of sub-prime block and corresponding 3rd motion vector carry out estimation;
If second error amount is less than the 3rd error amount, it is determined that go out the corresponding 8*8 pictures of minimum second error amount
The macroblock partition of sub-prime block and corresponding second motion vector carry out estimation.
It is preferred that, after the contrast first motion vector and second motion vector, in addition to:
If first motion vector is less than second motion vector, it is determined that go out the grand of the 16*16 sub-block of pixels
Block is split and first motion vector carries out estimation.
It is preferred that, the macroblock partition for determining the 16*16 sub-block of pixels and first motion vector are transported
Dynamic estimation, including:
The 16*16 sub-block of pixels is divided into two 16*8 sub-block of pixels;
Calculate the 4th motion vector and the 4th error amount of described two 16*8 sub-block of pixels.
It is preferred that, the macroblock partition for determining the 16*16 sub-block of pixels and first motion vector are transported
Dynamic estimation, including:
The 16*16 sub-block of pixels is divided into two 8*16 sub-block of pixels;
Calculate the 5th motion vector and the 5th error amount of described two 8*16 sub-block of pixels.
It is preferred that, it is described that the 16*16 sub-block of pixels is divided into 16 4*4 sub-block of pixels, including:
The 16*16 sub-block of pixels is first divided into 4 8*8 sub-block of pixels;
For each 8*8 sub-block of pixels, 4 4*4 sub-block of pixels are respectively divided into.
It is preferred that, the 3rd motion vector and the 3rd error amount for calculating 16 4*4 sub-block of pixels, including:
In each 8*8 sub-block of pixels, at least one 4*4 presetted pixel sub-block is determined;
Presetted pixel point, the number of the presetted pixel point are determined at least one described 4*4 presetted pixel sub-block
Less than the pixel total number in 4*4 presetted pixel sub-blocks;
The 3rd error amount of at least one 4*4 presetted pixel sub-block is calculated using the presetted pixel point.
It is preferred that, the 4*4 presetted pixels sub-block is the sub-block of pixels in the lower right corner in each 8*8 sub-block of pixels.
It is preferred that, the macroblock partition for determining the corresponding 8*8 sub-block of pixels of minimum second error amount and corresponding
Two motion vectors carry out estimation, including:
The 8*8 sub-block of pixels is divided into two 8*4 sub-block of pixels;
Calculate the 5th motion vector and the 5th error amount of described two 8*4 sub-block of pixels.
It is preferred that, the macroblock partition for determining the corresponding 8*8 sub-block of pixels of minimum second error amount and corresponding
Two motion vectors carry out estimation, including:
The 8*8 sub-block of pixels is divided into two 4*8 sub-block of pixels;
Calculate the 6th motion vector and the 6th error amount of described two 4*8 sub-block of pixels.
The invention discloses a kind of electronic equipment, it is characterised in that including processor and memory:
The memory is used to store the program for performing above-mentioned technical proposal methods described,
The processor is configurable for performing the program stored in the memory.
By one or more technical scheme of the present invention, the invention has the advantages that or advantage:
The invention discloses a kind of method and electronic equipment for realizing estimation, frame of video is first divided into 16*16's
Sub-block of pixels, then calculates the first motion vector and the first error amount of the 16*16 sub-block of pixels;16*16 pixels is sub
Block is divided into 4 8*8 sub-block of pixels and calculates the second motion vector and the second error amount;Contrast the first motion vector and the second motion
Vector;If the first error amount is more than the second error amount, then 16*16 sub-block of pixels is divided into 16 4*4 sub-block of pixels calculates the
Three motion vectors and the 3rd error amount;Contrasted again with the second error amount, so from minimal error macroblock partition and
Motion vector carries out estimation.The present invention determines the motion vector needed for specific estimation, energy using way of contrast
Enough reduction data volumes save the time, improve compression ratio.
Further, the present invention is when calculating three error amounts, and the pixel of not all 4*4 sub-block of pixels all enters
Go calculating, and simply selected presetted pixel point to be calculated, so amount of calculation can be reduced, improve estimation computing effect
Rate.During general progress estimation calculating, figure intermediate pixel region influences big to result of calculation, so using above-mentioned improved method
It is more efficient.
Brief description of the drawings
Fig. 1 is the implementation principle figure of single directional prediction in the embodiment of the present invention;
Fig. 2 is a kind of implementation process figure for the method for realizing estimation in the embodiment of the present invention;
Fig. 3 is the schematic diagram of electronic equipment in the embodiment of the present invention;
Fig. 4 is the schematic diagram of 8*8 sub-block of pixels in the embodiment of the present invention.
Embodiment
In order that the application the technical staff in the technical field is more clearly understood that the application, below in conjunction with the accompanying drawings,
Technical scheme is described in detail by specific embodiment.
Based on above mentioned problem, the invention discloses a kind of method for realizing estimation.
First, referring to Fig. 1, the implementation principle of inter prediction is first introduced.
Inter prediction is divided into single directional prediction and bi-directional predicted, and the implementation process of single directional prediction is as follows:
1, input current video frame data ft(x, y);
2, prediction predicted frame data is obtained, is returned by frame fallout predictor.
A. the encoded frame in present frame above or below is obtained from fallout predictor and is used as reference frame.
B. current block is calculated relative to ginseng using motion estimation algorithm (overall situation receives rope, and diamond receives rope, and hexagon receives rope)
Examine a motion vector of image.
C. input motion vector MV is returned by motion compensated predictorIt is used as prediction data.
3, use current video requency frame data ft(x, y) and prediction dataSubtract each other acquisition e (x);
4, conversion is carried out to e (x) and quantization operation is obtained
5, it is rightInverse quantization and inverse transform are carried out, withIt is added and obtains reconstruction frames, is used as reference frame next time
In prediction.
6, it is rightIt is entropy encoded again, with some side information (such as predictive mode quantization parameter, prediction moulds needed for decoding
Formula etc.) code stream after a compression is constituted together, through NAL (network self-adapting layer) for transmitting and storing.
Note:Need to judge type (the I frames/piece, P frames/piece, B in this way of present frame or piece before infra-frame prediction is carried out
Frame/piece), because deterministic process is more complicated, simple introduction is only done here, carries out 1/2 scaling to frame of video first (long and wide
Reduce 1/2), reduce data volume and then each block of pixels of infra-frame prediction acquisition cost altogether is carried out to each macro block in frame of video
Value, is carrying out the cost value of inter prediction calculating altogether, is comparing which value minimum carrys out judgment frame type.In addition, each I frames
Interval be to determine that, so may also be used for judgment frame type, also B frames may also be used for judgment frame class in the middle of P frames
Type.)
It is bi-directional predicted:It is bi-directional predicted to be more than utilizing former frame pixel prediction, also need to utilize a later frame pixel, i.e. predicted value
Forαt-1And αt+1For prediction power
Value, ij is previous frame motion vector, and i ', j ' are a later frame predictive vector.
And present invention generally provides a kind of method for realizing estimation, estimate to determine that motion vector carries out motion
Meter, compression ratio is improved to reduce code check.The method of the present invention is handled mainly for video flowing, such as XX live video streams,
Or common video flowing etc..
Referring to Fig. 2, method of the invention includes:
Firstly, for each frame video, frame of video can be divided into multiple 16*16 sub-block of pixels by the present invention, for
Each 16*16 sub-block of pixels does following processing:
Step 21, the first motion vector and the first error amount of the 16*16 sub-block of pixels are calculated.
In specific implementation process, 16*16 sub-block of pixels can be calculated by the fast search algorithm of estimation
First motion vector and the first error amount.
Motion vector and error amount are repeatedly had in this application.So the application introduces motion vector first, citing
For, in continuous frame of video, generally former frame and the similarity of a later frame be compared it is high for example we in profit
Being carried out taking pictures with mobile phone, quickly ought continuously to clap multiple pictures be that each similarity is that comparison is high, is arm, face nothing but
Eyes have the difference of amplitude, and both arm is moved up or down, and face has been closed, therefore we can be with Video coding
Using the encoded frame of video of former frame as reference frame, a later frame is is currently needed for coded frame, and motion amplitude mentioned above is then
It is motion vector, is a relative value, then motion vector is also 2 dimensions due to the dimension of video 2.It is with macro block generally in coding
For unit former motion vector all referring to macro block motion vector.
Error amount, many wherein SAD of computational methods of error amount are one of them, and error amount can be understood as Similarity value
Smaller similarity is bigger, and 2 frame of video, which are such as carried out SAD, calculates the similarity that this is frame of video, be generally all in coding with
Macro block is that unit is encoded, current macro (current coding macro block of current encoded frame) and reference macroblock (reference frame the inside and
The high macro block of current macro similarity-rough set) there can be an error amount.
The fast search algorithm of estimation is described below.
Motion search is segmented into two kinds of fundamental types:(1) full search algorithm.(2) fast search algorithm.
(1) full search algorithm.This method is that block of pixels all in region of search is compared with current macro one by one
Compared with it is match block to search a block of pixels with minimum match error.The benefit of this method is can to find optimal
With block, harm is that speed is too slow.Current full search algorithm is seldom used.
(2) fast search algorithm.This method carries out the search of match block according to certain mathematical programming.This method it is good
Place is that speed is fast, and harm is possible to can only obtain the match block of suboptimum.
Several searching algorithms of illustration below, certainly, the present invention are not limited in using this several algorithm.
Diamond search algorithm (DIA):Centered on search starting point, small rhombus template (template radius is 1) is used to search for.Meter
The matching error of each point is calculated, MBD (minimal error) point is obtained.If the MBD points heart in a template, search terminates, MBD now
Point is exactly Optimum Matching point, and corresponding block of pixels is exactly best matching blocks;If MBD points not heart position in a template, with existing
The point centered on MBD points, proceeds small diamond search, falls until MBD points untill central point.
Hexagon search algorithm (HEX):This method uses 1 large form (hexagon template) and 2 small template (small rhombus
Template and small square templates).Specific search step is as follows:Step 1:Centered on search starting point, using the left side in figure
Hexagon template is scanned for.Zoning center and surrounding 6 points at matching error and compare, such as minimum MBD points be located at
Template center's point, then go to step 2;Otherwise using last MBD points as central point, carried out by template of hexagon template anti-
Multiple search.Step 2:The point centered on last MBD points, using small rhombus template search, calculates the matching error of each point, looks for
To MBD points.Then the point centered on MBD points, is searched for, obtained MBD points are exactly Optimum Matching point using small square templates.
Asymmetric cross multi-level hexagonal point search algorithm (UMH):Step 1:Carry out once small diamond search, root
According to matching error value and two threshold values (for a kind of macro block of size be fixed size threshold1 and
Threshold2 the relation between) is correspondingly processed, and may use middle rhombus template or octagon template, it is also possible to
Leap to step 2.Step 2:Use asymmetric cross template search.The reason for " asymmetric " is that the motion of mean level direction will
More violent than movement in vertical direction, so horizontal direction hunting zone is set into W, vertical direction hunting zone is set to W/2.Step 3:
Use 5x5 search one by one template searches.Step 4:Use big hexagon template search.Step 5:Looked for using hexagon search algorithm
To Optimum Matching point.
Successive elimination method (ESA, TESA):This method is a kind of full-search algorithm, and it carries out light to the point in region of search
Grating search for, one by one calculate and compared with.
Step 22, the 16*16 sub-block of pixels is divided into 4 8*8 sub-block of pixels.
Step 23, the second motion vector and the second error amount of 4 8*8 sub-block of pixels are calculated.
Specifically, in second motion vector and the second error amount of 4 8*8 sub-block of pixels of calculating, also with upper
The searching algorithm for stating description is calculated.
Step 24, first motion vector and second motion vector are contrasted.
Because 16*16 sub-block of pixels is divided into 4 8*8 sub-block of pixels by the present invention, so can also obtain 4 second motions
4 the second error amounts of vector.And in contrast, contrasted using the first error amount and 4 the second error amounts, in contrast
Afterwards, if than 4 the second error amounts of the first error amount are all small, then then determine to select first motion vector and described
The macroblock partition of 16*16 sub-block of pixels carries out estimation, and because assignment is having been carried out in the present invention before, so in meter
Error amount can be reduced when calculating motion vector, and then reduces code check, compression ratio is improved.
And when carrying out estimation, specific implementation process is as follows:
Due to when splitting to 16*16 sub-block of pixels, two 16*8 sub-block of pixels can be divided into;Two can also be divided into
Individual 8*16 sub-block of pixels, so the present invention has two ways:
The first:The 16*16 sub-block of pixels is divided into two 16*8 sub-block of pixels;Calculated using motion estimation algorithm
The 3rd motion vector and the 3rd error amount of described two 16*8 sub-block of pixels.Certainly, can be with as a kind of optional embodiment
Before the 3rd motion vector and the 3rd error amount of described two 16*8 sub-block of pixels is calculated, to described two 16*8 pixels
Second presetted pixel point of block carries out actual assignment, is then calculated again.Second presetted pixel point can be 16*8 pixels
The upper left corner of block, the lower left corner, the upper right corner, the lower right corner 4 pixels altogether.Can certainly be other, herein the present invention no longer
Repeat.
Second:The 16*16 sub-block of pixels is divided into two 8*16 sub-block of pixels;Calculated using motion estimation algorithm
The 4th motion vector and the 4th error amount of described two 8*16 sub-block of pixels.Certainly, before this can also be to two 8*16
3rd presetted pixel point of sub-block of pixels carries out actual assignment, and the determination of the 3rd presetted pixel point can be random, for example, can be
The upper left corner of 8*16 sub-block of pixels, the lower left corner, the upper right corner, the lower right corner 4 pixels altogether.Can certainly be other, herein
The present invention is repeated no more.
Above is the first error amount is less than the processing that second error amount is done, if first error amount is more than described
Second error amount, then then carry out following embodiment.
Step 25, if first error amount is more than second error amount, the 16*16 sub-block of pixels is divided into 16
Individual 4*4 sub-block of pixels.
During division, the 16*16 sub-block of pixels is first divided into 4 8*8 sub-block of pixels;
For each 8*8 sub-block of pixels, 4 4*4 sub-block of pixels are respectively divided into.
And when calculating the 3rd motion vector and three error amounts of 16 4*4 sub-block of pixels, in each 8*8 pixels
In sub-block, at least one 4*4 presetted pixel sub-block is determined.4 4*4 sub-block of pixels are had in 8*8 sub-block of pixels, so,
It is determined that during 4*4 presetted pixel sub-blocks, can by any one in this 4 4*4 sub-block of pixels, two or more are defined as
4*4 presetted pixel sub-blocks.For example, the 4*4 presetted pixels sub-block is pixel in the lower right corner in each 8*8 sub-block of pixels
Block.I.e.:The sub-block of pixels in the lower right corner in each 8*8 sub-block of pixels is defined as 4*4 presetted pixel sub-blocks.
The error amount of calculating the 3rd of 4*4 presetted pixel sub-blocks and the method for the 3rd motion vector and other 4*4 sub-block of pixels
The error amount of calculating the 3rd and the 3rd motion vector method it is different.The error amount of calculating the 3rd of other 4*4 sub-block of pixels and
Searching algorithm of the method for three motion vectors with reference to foregoing description.And for the error amount of calculating the 3rd of 4*4 presetted pixel sub-blocks
With the method for the 3rd motion vector, then lower section is refer to:
Presetted pixel point, the number of the presetted pixel point are determined at least one described 4*4 presetted pixel sub-block
Less than the pixel total number in 4*4 presetted pixel sub-blocks;, can be without using in calculation error value in order to reduce data volume
Whole pixels, and presetted pixel point is simply determined in 4*4 presetted pixel sub-blocks.Presetted pixel point is exactly to be used for calculating
3rd error amount.So the institute of at least one 4*4 presetted pixel sub-block can be calculated using the presetted pixel point
State the 3rd error amount.
Mode above can reduce amount of calculation, improve estimation operation efficiency.During general progress estimation calculating,
Figure intermediate pixel region influences big to result of calculation, so more efficient using above-mentioned improved method.This programme is applied to image
Background motion more greatly situation, such as action movie
Citing is illustrated below, be refer to Fig. 4, is 8*8 sub-block of pixels figures.It is to be directed to when 16 4*4 motion arrows of calculating
When amount and error amount, in a 8*8 block of pixels, the upper left corner, the upper right corner, the lower left corner, 3 4*4 block of pixels carry out general motion
Vector error calculation, lower right corner 4*4 block of pixels calculates the error of 8 yellow pixel points pixel corresponding with current block first
The sum of value, add 4 blue pixel points error corresponding with current block and, wherein red pixel point is not involved in error calculation.
Step 26, the 3rd motion vector and the 3rd error amount of 16 4*4 sub-block of pixels are calculated.
Step 27, the 3rd error amount and second error amount are contrasted.
Step 28, if the 3rd error amount is less than second error amount, it is determined that go out minimum 3rd error amount correspondence
4*4 sub-block of pixels macroblock partition and corresponding 3rd motion vector carry out estimation.
Step 29, if second error amount is less than the 3rd error amount, it is determined that go out minimum second error amount correspondence
8*8 sub-block of pixels macroblock partition and corresponding second motion vector carry out estimation.
In specific implementation process, if the macroblock partition to 8*8 sub-block of pixels carries out estimation, then also can be first
The macro block of 8*8 sub-block of pixels is divided.There is two ways when dividing:First way:By the 8*8 sub-block of pixels
It is divided into two 8*4 sub-block of pixels.The second way:The 8*8 sub-block of pixels is divided into two 4*8 sub-block of pixels.
First way:The 8*8 sub-block of pixels is divided into two 8*4 sub-block of pixels;Calculate described two 8*4 pixels
5th motion vector of sub-block and the 5th error amount.
The second way:The 8*8 sub-block of pixels is divided into two 4*8 sub-block of pixels;Calculate described two 4*8 pixels
6th motion vector of sub-block and the 6th error amount.
Referring to Fig. 3, based on same inventive concept, the invention discloses a kind of electronic equipment, the electronics that the application is related to is set
It is standby include but is not limited to be:Mobile terminal (mobile phone, smart mobile phone, PAD, notebook computer etc.), fixed terminal (computer).
The electronic equipment includes processor 31 and memory 32:
The memory 32 is used to store the program for performing the method in above-described embodiment,
The processor 31 is configurable for performing the program stored in the memory.
For convenience of description, the part related to the embodiment of the present invention is illustrate only, particular technique details is not disclosed, please
With reference to present invention method part.The mobile communication terminal can be to include mobile phone, tablet personal computer, PDA (Personal
Digital Assistant, personal digital assistant) etc. any mobile terminal device.As described in Figure 3, the mobile terminal includes
Memory 32 and processor 31.
Memory 32 can be used for storage software program and module, and processor 31 is stored in memory 32 by running execution
Software program and module, so as to perform various function application and the data processing of mobile terminal.
Memory 32 can mainly include storing program area and storage data field, wherein, storing program area can store operation system
Application program (such as game class application needed for system, at least one function (such as sound-playing function, image player function etc.)
Program, music class application program etc.) etc.;Storage data field can be stored uses created data (such as audio according to mobile phone
Data, phone directory etc.) etc..The control centre of the mobile communication terminal of processor 31, is entirely moved using various interfaces and connection
The various pieces of mobile communication terminal, software program and/or module in memory 32 are stored in by operation or execution, and adjust
With the data being stored in memory 32, the various functions and processing data of mobile phone are performed, so as to mobile phone
Carry out integral monitoring.Optionally, processor 31 may include one or more processing units.
By one or more embodiment of the present invention, the invention has the advantages that or advantage:
The invention discloses a kind of method and electronic equipment for realizing estimation, frame of video is first divided into 16*16's
Sub-block of pixels, then calculates the first motion vector and the first error amount of the 16*16 sub-block of pixels;16*16 pixels is sub
Block is divided into 4 8*8 sub-block of pixels and calculates the second motion vector and the second error amount;Contrast the first motion vector and the second motion
Vector;If the first error amount is more than the second error amount, then 16*16 sub-block of pixels is divided into 16 4*4 sub-block of pixels calculates the
Three motion vectors and the 3rd error amount;Contrasted again with the second error amount, so from minimal error macroblock partition and
Motion vector carries out estimation.The present invention determines the motion vector needed for specific estimation, energy using way of contrast
Enough reduction data volumes save the time, improve compression ratio.
Further, the present invention is when calculating three error amounts, and the pixel of not all 4*4 sub-block of pixels all enters
Go calculating, and simply selected presetted pixel point to be calculated, so amount of calculation can be reduced, improve estimation computing effect
Rate.During general progress estimation calculating, figure intermediate pixel region influences big to result of calculation, so using above-mentioned improved method
It is more efficient.
Although having been described for the preferred embodiment of the application, one of ordinary skilled in the art once knows substantially
Creative concept, then can make other change and modification to these embodiments.So, appended claims are intended to be construed to bag
Include preferred embodiment and fall into having altered and changing for the application scope.
Obviously, those skilled in the art can carry out the essence of various changes and modification without departing from the application to the application
God and scope.So, if these modifications and variations of the application belong to the scope of the application claim and its equivalent technologies
Within, then the application is also intended to comprising including these changes and modification.
Claims (10)
1. a kind of method for realizing estimation, it is characterised in that methods described includes:
Frame of video is divided into multiple 16*16 sub-block of pixels, the sub-block of pixels for each 16*16 does following processing:
Calculate the first motion vector and the first error amount of the 16*16 sub-block of pixels;
The 16*16 sub-block of pixels is divided into 4 8*8 sub-block of pixels;
Calculate the second motion vector and the second error amount of 4 8*8 sub-block of pixels;
Contrast first motion vector and second motion vector;
If first error amount is more than second error amount, the 16*16 sub-block of pixels is divided into 16 4*4 pixels
Block;
Calculate the 3rd motion vector and the 3rd error amount of 16 4*4 sub-block of pixels;
3rd error amount and second error amount are contrasted;
If the 3rd error amount is less than second error amount, it is determined that go out corresponding 4*4 pixels of minimum 3rd error amount
The macroblock partition of block and corresponding 3rd motion vector carry out estimation;
If second error amount is less than the 3rd error amount, it is determined that go out corresponding 8*8 pixels of minimum second error amount
The macroblock partition of block and corresponding second motion vector carry out estimation.
2. the method as described in claim 1, it is characterised in that contrast first motion vector and second motion
After vector, in addition to:
If first motion vector is less than second motion vector, it is determined that go out the macro block point of the 16*16 sub-block of pixels
Cut and carry out estimation with first motion vector.
3. method as claimed in claim 2, it is characterised in that the macroblock partition for determining the 16*16 sub-block of pixels
Estimation is carried out with first motion vector, including:
The 16*16 sub-block of pixels is divided into two 16*8 sub-block of pixels;
Calculate the 4th motion vector and the 4th error amount of described two 16*8 sub-block of pixels.
4. method as claimed in claim 2, it is characterised in that the macroblock partition for determining the 16*16 sub-block of pixels
Estimation is carried out with first motion vector, including:
The 16*16 sub-block of pixels is divided into two 8*16 sub-block of pixels;
Calculate the 5th motion vector and the 5th error amount of described two 8*16 sub-block of pixels.
5. the method as described in claim 1, it is characterised in that described that the 16*16 sub-block of pixels is divided into 16 4*4 pictures
Sub-prime block, including:
The 16*16 sub-block of pixels is first divided into 4 8*8 sub-block of pixels;
For each 8*8 sub-block of pixels, 4 4*4 sub-block of pixels are respectively divided into.
6. method as claimed in claim 5, it is characterised in that the 3rd motion of calculating 16 4*4 sub-block of pixels
The error amount of vector the 3rd, including:
In each 8*8 sub-block of pixels, at least one 4*4 presetted pixel sub-block is determined;
Presetted pixel point is determined at least one described 4*4 presetted pixel sub-block, the number of the presetted pixel point is less than
Pixel total number in 4*4 presetted pixel sub-blocks;
The 3rd error amount of at least one 4*4 presetted pixel sub-block is calculated using the presetted pixel point.
7. method as claimed in claim 6, it is characterised in that during the 4*4 presetted pixels sub-block is each 8*8 sub-block of pixels
The lower right corner sub-block of pixels.
8. the method as described in claim 1, it is characterised in that described to determine the corresponding 8*8 pixels of minimum second error amount
The macroblock partition of sub-block and corresponding second motion vector carry out estimation, including:
The 8*8 sub-block of pixels is divided into two 8*4 sub-block of pixels;
Calculate the 5th motion vector and the 5th error amount of described two 8*4 sub-block of pixels.
9. the method as described in claim 1, it is characterised in that described to determine the corresponding 8*8 pixels of minimum second error amount
The macroblock partition of sub-block and corresponding second motion vector carry out estimation, including:
The 8*8 sub-block of pixels is divided into two 4*8 sub-block of pixels;
Calculate the 6th motion vector and the 6th error amount of described two 4*8 sub-block of pixels.
10. a kind of electronic equipment, it is characterised in that including processor and memory:
The memory is used for the program for storing any one of perform claim requirement 1 to 9 methods described,
The processor is configurable for performing the program stored in the memory.
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710334106.9A CN107197281A (en) | 2017-05-12 | 2017-05-12 | A kind of method and electronic equipment for realizing estimation |
PCT/CN2018/082158 WO2018205781A1 (en) | 2017-05-12 | 2018-04-08 | Method for use in achieving motion estimation and electronic device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710334106.9A CN107197281A (en) | 2017-05-12 | 2017-05-12 | A kind of method and electronic equipment for realizing estimation |
Publications (1)
Publication Number | Publication Date |
---|---|
CN107197281A true CN107197281A (en) | 2017-09-22 |
Family
ID=59872761
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201710334106.9A Pending CN107197281A (en) | 2017-05-12 | 2017-05-12 | A kind of method and electronic equipment for realizing estimation |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN107197281A (en) |
WO (1) | WO2018205781A1 (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2018205781A1 (en) * | 2017-05-12 | 2018-11-15 | 武汉斗鱼网络科技有限公司 | Method for use in achieving motion estimation and electronic device |
CN110545402A (en) * | 2019-08-18 | 2019-12-06 | 宁波职业技术学院 | A downhole monitoring video processing method, computer equipment and storage medium |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20040114688A1 (en) * | 2002-12-09 | 2004-06-17 | Samsung Electronics Co., Ltd. | Device for and method of estimating motion in video encoder |
CN101527854A (en) * | 2009-01-20 | 2009-09-09 | 源见科技(苏州)有限公司 | Interframe mode selection method |
CN103220488A (en) * | 2013-04-18 | 2013-07-24 | 北京大学 | Up-conversion device and method of video frame rate |
CN103345763A (en) * | 2013-06-25 | 2013-10-09 | 西安理工大学 | Method for calculating motion attention based on multiscale variable-block |
CN103501437A (en) * | 2013-09-29 | 2014-01-08 | 北京航空航天大学 | Fractal and H.264-based hyper-spectral image compression method |
CN105681807A (en) * | 2016-01-06 | 2016-06-15 | 福州瑞芯微电子股份有限公司 | Method and device for calculating sub pixel motion vector based on H264 protocol |
CN105721870A (en) * | 2014-12-03 | 2016-06-29 | 北京君正集成电路股份有限公司 | Method and apparatus for determining coding unit division mode in HEVC |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107197281A (en) * | 2017-05-12 | 2017-09-22 | 武汉斗鱼网络科技有限公司 | A kind of method and electronic equipment for realizing estimation |
-
2017
- 2017-05-12 CN CN201710334106.9A patent/CN107197281A/en active Pending
-
2018
- 2018-04-08 WO PCT/CN2018/082158 patent/WO2018205781A1/en active Application Filing
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20040114688A1 (en) * | 2002-12-09 | 2004-06-17 | Samsung Electronics Co., Ltd. | Device for and method of estimating motion in video encoder |
CN101527854A (en) * | 2009-01-20 | 2009-09-09 | 源见科技(苏州)有限公司 | Interframe mode selection method |
CN103220488A (en) * | 2013-04-18 | 2013-07-24 | 北京大学 | Up-conversion device and method of video frame rate |
CN103345763A (en) * | 2013-06-25 | 2013-10-09 | 西安理工大学 | Method for calculating motion attention based on multiscale variable-block |
CN103501437A (en) * | 2013-09-29 | 2014-01-08 | 北京航空航天大学 | Fractal and H.264-based hyper-spectral image compression method |
CN105721870A (en) * | 2014-12-03 | 2016-06-29 | 北京君正集成电路股份有限公司 | Method and apparatus for determining coding unit division mode in HEVC |
CN105681807A (en) * | 2016-01-06 | 2016-06-15 | 福州瑞芯微电子股份有限公司 | Method and device for calculating sub pixel motion vector based on H264 protocol |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2018205781A1 (en) * | 2017-05-12 | 2018-11-15 | 武汉斗鱼网络科技有限公司 | Method for use in achieving motion estimation and electronic device |
CN110545402A (en) * | 2019-08-18 | 2019-12-06 | 宁波职业技术学院 | A downhole monitoring video processing method, computer equipment and storage medium |
Also Published As
Publication number | Publication date |
---|---|
WO2018205781A1 (en) | 2018-11-15 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US20230291920A1 (en) | Low complexity affine merge mode for versatile video coding | |
US10291925B2 (en) | Techniques for hardware video encoding | |
US9332271B2 (en) | Utilizing a search scheme for screen content video coding | |
US11336915B2 (en) | Global motion vector video encoding systems and methods | |
CN102835111B (en) | The motion vector of previous block is used as the motion vector of current block, image to be carried out to the method and apparatus of coding/decoding | |
US20150016521A1 (en) | Video encoder for images | |
Zhang et al. | Low complexity HEVC INTRA coding for high-quality mobile video communication | |
CN103491334B (en) | Video transcode method from H264 to HEVC based on region feature analysis | |
CN104067619A (en) | Video decoder, video encoder, video decoding method, and video encoding method | |
KR102059066B1 (en) | Motion vector field coding method and decoding method, and coding and decoding apparatuses | |
JP2015165696A (en) | Method and apparatus for decoding image | |
CN111479110A (en) | Fast Affine Motion Estimation Method for H.266/VVC | |
Kerfa et al. | An efficient algorithm for fast block matching motion estimation using an adaptive threshold scheme | |
JP2020113923A (en) | Moving picture coding program and moving picture coding device | |
CN107197281A (en) | A kind of method and electronic equipment for realizing estimation | |
CN105282557B (en) | A kind of H.264 rapid motion estimating method of predicted motion vector | |
CN110278434A (en) | Method, device and storage medium for fast multi-composite frame video coding | |
Jillani et al. | Multi-view clustering for fast intra mode decision in HEVC | |
CN107197299A (en) | A kind of motion estimation implementing method and electronic equipment | |
Bachu et al. | Adaptive order search and tangent-weighted trade-off for motion estimation in H. 264 | |
CN116527890A (en) | Intra-frame prediction mode determination method, device, equipment and storage medium | |
CN103327340A (en) | Method and device for searching integer | |
CN109889838A (en) | A kind of HEVC fast encoding method based on ROI region | |
US20110228851A1 (en) | Adaptive search area in motion estimation processes | |
CN114584779A (en) | Video coding method, device, equipment and medium based on H264 coding algorithm |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20170922 |
|
RJ01 | Rejection of invention patent application after publication |