KR20160106348A - Video Coding Method and Apparatus thereof - Google Patents
Video Coding Method and Apparatus thereof Download PDFInfo
- Publication number
- KR20160106348A KR20160106348A KR1020150029137A KR20150029137A KR20160106348A KR 20160106348 A KR20160106348 A KR 20160106348A KR 1020150029137 A KR1020150029137 A KR 1020150029137A KR 20150029137 A KR20150029137 A KR 20150029137A KR 20160106348 A KR20160106348 A KR 20160106348A
- Authority
- KR
- South Korea
- Prior art keywords
- mode
- candidates
- rate
- encoder
- present
- Prior art date
Links
Images
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/102—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
- H04N19/103—Selection of coding mode or of prediction mode
-
- 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/134—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or criterion affecting or controlling the adaptive coding
- H04N19/146—Data rate or code amount at the encoder output
- H04N19/147—Data rate or code amount at the encoder output according to rate distortion criteria
-
- 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/134—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or criterion affecting or controlling the adaptive coding
- H04N19/154—Measured or subjectively estimated visual quality after decoding, e.g. measurement of distortion
-
- 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/134—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or criterion affecting or controlling the adaptive coding
- H04N19/157—Assigned coding mode, i.e. the coding mode being predefined or preselected to be further used for selection of another element or parameter
-
- 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
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Compression Or Coding Systems Of Tv Signals (AREA)
Abstract
Description
The present invention relates to a video coding method and apparatus therefor.
JCT-VC, which was recently formed jointly by the ISO / IEC MPEG and ITU-T VCEG standardization groups, has completed the standardization of HEVC (High Efficiency Video Coding) technology as the next generation video standard. Compared with H.264 / AVC, which provides the highest compression ratio through HEVC, image compression technology achieves subjective image quality improvement of about 50% or more. To this end, a sophisticated coding tool capable of improving compression efficiency is newly It was proposed.
Similar to the conventional image compression method, the HEVC is an inter prediction coding technique for predicting pixel values included in a current screen from previous or later reference pictures in time, using the reference pixel information in the current screen (Intra) prediction coding technique for predicting pixel values included in a current screen, an entropy coding technique for assigning a short code to a symbol having a high appearance frequency and allocating a long code to a symbol having a low appearance frequency .
Conventional video codecs are encoded in units of macroblocks (16 × 16), while HEVC uses CU (Coding Unit), PU (Prediction Unit) and TU (Transform) to enhance optimal compression efficiency for high- (Block Structure) that can achieve optimal compression efficiency per unit.
HEVC is an encoding prediction mode, allowing inter-picture mode and intra-picture mode. In addition, the HEVC allows the skip mode and the merge mode for the residual signal coding mode.
The skip mode is applied when there is a candidate having the same motion information as the motion information of the current block to be coded and the residual signal is zero. That is, in the skip mode, the motion information and the residual signal are not coded.
The merge mode is applied when there is a candidate having the same motion information as the motion information of the current block to be coded and a residual signal exists. The merging mode does not encode motion information in the same way as in the skip mode, but improves compression efficiency of compression between images by coding a residual signal.
Currently, most video standards, including HEVC, determine the optimal encoding mode by calculating the Rate-Distortion cost for the current block to be encoded. That is, in the current video standard, the rate-distortion cost of each of the skip / merge mode and intra-picture / inter-picture mode for the current block to be coded is all calculated and then the coding mode with the smallest rate- .
Such a conventional scheme can improve the coding efficiency, but has a disadvantage in that it is difficult to develop a real-time encoder because the computational complexity of the encoder is relatively high.
Currently, HEVC proposes five skipped mode and merging mode candidates. Therefore, when determining the optimal encoding mode, all of the skip / merge mode rate-distortion costs for all five candidates must be calculated. In particular, the merge mode has a disadvantage in that the complexity of the encoder increases because the rate-distortion cost must be calculated in consideration of the residual signal.
SUMMARY OF THE INVENTION The present invention is directed to a video encoding method and apparatus for selecting a candidate number of a skip / merge mode based on encoding related information of a neighboring block that has already been encoded.
The present invention first calculates the rate-distortion cost of the skip mode for the selected candidate if the number of candidates in the skip / merge mode is less than a predetermined number (e.g., 5), and if the merge mode for at least some of the selected candidates And a video encoding method and apparatus thereof for calculating a rate-distortion cost of a video signal.
SUMMARY OF THE INVENTION The present invention is directed to a video encoding method and apparatus for selecting a candidate number of a skip / merge mode based on encoding related information of a neighboring block that has already been encoded.
The present invention first calculates the rate-distortion cost of the skip mode for the selected candidate if the number of candidates in the skip / merge mode is less than a predetermined number (e.g., 5), and if the merge mode for at least some of the selected candidates And a video encoding method and apparatus thereof for calculating a rate-distortion cost of a video signal.
The video encoding method and apparatus according to the present invention can reduce the number of candidates in the skip / merge mode, so that the rate-distortion cost for a smaller number of candidates than the prior art can be calculated, thereby reducing the encoder complexity.
1 is a flowchart illustrating a video encoding method according to the present invention.
2 is a flowchart illustrating an optimal encoding mode selection method according to the present invention.
FIG. 3 is a flowchart illustrating a method of determining a number of candidates for a skip / merge mode according to the present invention.
FIG. 4 is a diagram showing a block arrangement of neighboring blocks that have already been encoded.
5 is a diagram showing a block arrangement of spatial candidates.
6 is a flowchart illustrating a rate-distortion cost calculation method according to the first embodiment of the present invention.
7 is a diagram illustrating an example of a candidate selection method according to the first embodiment of the present invention.
8 is a flowchart illustrating a rate-distortion cost calculation method according to the second embodiment of the present invention.
9 is a block diagram illustrating the structure of an encoder according to the present invention.
In the description of the embodiments of the present invention, if it is determined that the detailed description of the related known structure or function is not satisfactory, the detailed description thereof may be omitted.
As used herein, a coding unit refers to a basic unit of video coding and decoding. A basic unit refers to a unit that is divided when coding or decoding a single picture, and can be named as a unit, a block, a macroblock, a prediction unit (PU), a transform unit (TU) have. One encoding unit can be divided into sub-encoding units of smaller size.
As used herein, a block means an M x N array of samples. M and N have any positive integer value, and the meaning of the block described in the present invention may mean an encoding unit.
When an element is referred to herein as " connected " or " connected " to another element, it is to be understood that the element is not only directly connected or connected to another element, But it should be understood that other components exist between the component and the other component.
Quot ;, " include, "" include," as used herein. And the like are intended to indicate the existence of the disclosed function, operation, component, etc., and do not limit the one or more additional functions, operations, components, and the like. Also, in this specification, "include." Or "having" are intended to designate the presence of stated features, integers, steps, operations, components, parts, or combinations thereof, unless the context clearly dictates otherwise. Elements, parts, or combinations thereof without departing from the spirit and scope of the invention.
The constituent parts of the present invention are shown separately to represent different characteristic functions and do not mean that each constituent part is composed of separate hardware or one software constituent unit. That is, each constituent unit is included in each constituent unit for convenience of explanation, and at least two constituent units of the constituent units may be combined to form one constituent unit, or one constituent unit may be divided into a plurality of constituent units to perform a function. The integrated embodiments and separate embodiments of the components are also included within the scope of the present invention, without departing from the essence of the present invention.
Some components are not essential components to perform essential functions in the present invention, but may be optional components only to improve performance. The present invention can be implemented only with components essential for realizing the essence of the present invention, except for the components used for the performance improvement, and can be implemented by only including the essential components except the optional components used for performance improvement Are also included in the scope of the present invention.
As used herein, the singular forms "a", "an" and "the" include plural referents unless the context clearly dictates otherwise.
Hereinafter, the present invention will be described with reference to the accompanying drawings.
In order to provide a high coding efficiency, a video encoder has a coding unit size (which may further include a prediction unit size, a conversion unit size, or the like), an encoding mode (including a prediction mode, ), Motion information, and the like. The video encoder uses a Rate-Distortion Optimization scheme to select an optimal combination of the above factors. Generally, the optimal combination in the rate-distortion optimization scheme is chosen in a combination that minimizes the rate-distortion cost.
The rate-distortion optimization scheme calculates the Rate-Distortion cost (rate distortion) to select the optimal combination. The rate-distortion cost J can be calculated according to the following equation (1).
In Equation (1), D denotes a mean square error (SSD) of the difference between the original transform coefficients and the restored transform coefficients in the corresponding block. do. R denotes the number of bits required to encode the block, i.e., the bit rate using the related context information. R includes not only encoding parameter information such as a prediction mode, motion information, and coded block flag but also bits generated when the transform coefficients are encoded. lambda denotes a Lagrangian multiplier.
In order to calculate the correct D and R, the image encoder performs in-screen / inter-picture prediction, transformation, quantization, entropy encoding, inverse quantization, and inverse transformation. This process greatly increases the complexity of the image encoder.
In order to solve the complexity problem of the rate-distortion optimization method, in the present invention, the number of skipped / merged mode candidates is selected based on the coding-related information of neighboring blocks that have already been encoded, Distortion cost of the skipped mode for the selected candidate if the number of candidates of the selected candidate is smaller than a predetermined number (e.g., 5), and then calculates the rate-distortion cost of the merge mode for at least some of the selected candidates Thereby making it possible to quickly determine an optimal encoding mode.
Hereinafter, the encoding method according to the present invention will be described in more detail.
1 is a flowchart illustrating a video encoding method according to the present invention.
Referring to FIG. 1, an encoder according to the present invention calculates a rate-distortion cost of each of a skip mode and a merge mode (101). Further, the encoder calculates the rate-distortion cost of intra-picture / inter-picture mode (102).
The encoder selects an optimal encoding mode based on the calculated rate-distortion cost (103). The encoder can select a mode in which the calculated rate-distortion cost is lowest as the optimal encoding mode. Thereafter, the encoder performs video encoding according to the selected encoding mode (104).
Hereinafter, a method for selecting an optimum encoding mode according to the present invention will be described in detail.
2 is a flowchart illustrating an optimal encoding mode selection method according to the present invention.
Referring to FIG. 2, an encoder according to an embodiment of the present invention determines a candidate number of a skip / merge mode based on coding-related information of a neighboring block that has already been encoded (201). The encoding-related information may include a final encoding mode, information on a candidate selected when a skip-merge mode is selected, and the like. A method for determining the number of candidates by the encoder in the present invention will be described in detail below with reference to FIG.
The encoder determines whether the determined number of candidates is smaller than a predetermined number (202). In the following embodiments, the number of predetermined candidates is 5 as an example of the HEVC, but the present invention is not limited thereto. Various variations are possible according to the standard.
If the determined candidate number is not less than the predetermined number of candidates, the encoder calculates a rate-distortion cost according to the embodiment of FIG. 6 (203). Conversely, if the determined candidate number is smaller than the predetermined number of candidates, the encoder calculates the rate-distortion cost according to the embodiment of FIG. 8 (204). The method of calculating the specific rate-distortion cost will be described below with reference to Figs. 6 and 8, respectively.
Thereafter, the encoder calculates 205 the rate-distortion cost of intra-picture / inter picture modes and the encoder selects an optimal coding mode based on the calculated rate-distortion cost (206).
Hereinafter, a method for determining the number of candidates for the skip / merge mode will be described in detail in the present invention described above.
FIG. 3 is a flowchart illustrating a method of determining a number of candidates for a skip / merge mode according to the present invention.
In various embodiments of the present invention, the encoder determines the number of candidates for the skip / merge mode based on the encoding-related information of the already encoded neighboring block. Generally, as shown in FIG. 4, the blocks on the left and upper sides based on the block to be currently encoded are already encoded blocks. Therefore, as shown in FIG. 4, the encoder determines the number of candidates based on the encoding-related information of the two neighboring blocks that have already been encoded. The encoding-related information may include a final encoding mode, information on a candidate selected when a skip-merge mode is selected, and the like.
Hereinafter, the left and top two neighboring blocks are exemplified as the neighboring blocks which have already been encoded, but the present invention is not limited thereto, and various modifications are possible according to the video coding logic within the scope of the present invention.
In one embodiment, the encoder determines whether the final encoding mode of at least one of the encoded neighboring blocks is an in-screen mode (301). If the final encoding mode of at least one of the neighboring blocks that have been already encoded is the in-picture mode, the encoder determines the number of candidates to be a predetermined number of candidates (302). As described above, in the following embodiments, the predetermined number of candidates is 5 and the number of candidates is 5 in the encoder.
In one embodiment, the encoder determines whether a candidate selected at the skip / merge mode selection of the already encoded neighboring block is selected from the spatial candidate group (303). The encoder determines whether the candidate selected in the skip-merge mode selection of two neighboring blocks is selected from the spatial candidate group shown in Fig.
If the candidate selected in the skip-merge mode selection of the neighboring block that has already been encoded is not selected from the spatial candidate group, the encoder determines the candidate number as a predetermined candidate number (302).
When a candidate selected at the skip-merge mode selection of a neighboring block that has already been encoded is selected from the spatial candidate group, the encoder sets the number of candidates to be smaller than a predetermined number.
In one embodiment, when a candidate selected at the skip-merge mode selection of a neighboring block that has already been encoded is selected from the spatial candidate group, the encoder determines whether the last encoding mode of the already encoded neighboring block is a skip or merge mode 304). The encoder determines whether the final encoding mode of the two neighboring blocks is a skip or merge mode.
If the final encoding mode of the neighboring block that has already been encoded is the skip or merge mode, the encoder sets the number of candidates to 3 (305). On the other hand, if the final encoding mode of the neighboring block that has already been encoded is not the skip or merge mode, the encoder sets the number of candidates to 4 (306). The number of candidates 3 or 4 described above is merely an example, and the present invention is not limited thereto, and the number of candidates may be determined to any number smaller than a predetermined number.
Hereinafter, a method of calculating the rate-distortion cost of the skip / merge mode according to the determined number of candidates will be described in detail.
6 is a flowchart illustrating a rate-distortion cost calculation method according to the first embodiment of the present invention.
The first embodiment of the present invention relates to a method of calculating a rate-distortion cost when a determined candidate number is equal to a predetermined number of candidates. In the following embodiment, the case where the number of predetermined candidates is 5 will be described as an example of the HEVC as described above.
Referring to FIG. 6, the encoder selects a candidate corresponding to the number of candidates (601). The encoder can select a maximum of four candidates out of the five neighboring blocks of the current block to be encoded. At this time, the encoder can select up to four candidates among the spatial candidate groups A0, A1, B0, B1, and B2 shown in FIG. In one embodiment, as shown in FIG. 7, the encoder selects at most one candidate among the two blocks (A, B) for a block at the same position as the current block to be coded in the previous screen in which coding has already been completed It is possible.
The encoder acquires motion information for the selected candidate (602), and calculates a skip mode and a rate-distortion cost of the merging mode for each selected candidate (603).
Thereafter, the encoder calculates the rate-distortion cost of the intra-picture / inter picture modes and compares the calculated rate-distortion costs to select the optimal code and mode.
8 is a flowchart illustrating a rate-distortion cost calculation method according to the second embodiment of the present invention.
The second embodiment of the present invention relates to a method of calculating a rate-distortion cost when the determined number of candidates is smaller than a predetermined number of candidates.
Referring to FIG. 8, the encoder selects a candidate corresponding to the number of candidates (801). The encoder obtains motion information for the selected candidate (802), and calculates a skip mode rate-distortion cost for each selected candidate (803).
Next, the encoder computes the merge mode rate-distortion cost for at least a portion of the selected candidates (804). The encoder may determine at least some of the selected candidates based on at least one of coding related information and a predictive motion vector (PMV) of a neighboring block that has already been encoded. The encoding-related information may include a final encoding mode or the like.
In one embodiment, the encoder can calculate the merging mode rate-distortion cost for one candidate among the selected candidates when the final encoding mode of the neighboring block that has already been encoded is all the skip mode. Here, the neighboring block having already been encoded may be the block shown in FIG.
The HEVC calculates the rate-distortion cost according to the block size from a 64x64 coding unit to a quad-tree structure, for a block size of 64x64, 32x32, 16x16, and 8x8 units, and is called a coding unit. For example, if the size of a current block to be coded (the same concept as an encoding unit) is 16x16, a coding optimal mode for a 32x32 block is already determined. If the optimal mode of a 32x32 block is a skip mode, The probability of being judged as a mode is increased. Therefore, when all of the final encoding modes of the already-encoded neighboring blocks are in the skip mode, it is expected that the current encoding mode is selected as the merge mode. Therefore, only one candidate among the selected candidates is subjected to merge mode rate- Cost can be calculated.
Alternatively, in one embodiment, if the PMV for inter-picture prediction of a current block to be coded is determined as a zero vector, the encoder may calculate a merging mode rate-distortion cost for one candidate among the selected candidates.
Thereafter, the encoder calculates the rate-distortion cost of the intra-picture / inter picture modes and compares the calculated rate-distortion costs to select the optimal code and mode.
9 is a block diagram illustrating the structure of an encoder according to the present invention.
9, a
The
The
In various embodiments, the
The
It will be understood by those skilled in the art that various changes in form and details may be made therein without departing from the spirit and scope of the invention as defined by the appended claims. It is to be understood that both the foregoing general description and the following detailed description of the present invention are exemplary and explanatory and are intended to provide further explanation of the invention as claimed. Accordingly, the scope of the present invention should be construed as being included in the scope of the present invention, all changes or modifications derived from the technical idea of the present invention.
900: Encoder 901: Input unit
902: Control section 903:
Claims (1)
Calculating a Rate-Distortion cost of the skip mode for the selected candidate if the determined candidate number is less than a predetermined number of candidates;
Calculating a rate-distortion cost of the merge mode for at least a portion of the selected candidate; And
And outputting the encoded image according to the selected encoding mode based on the calculated rate-distortion cost.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
KR1020150029137A KR20160106348A (en) | 2015-03-02 | 2015-03-02 | Video Coding Method and Apparatus thereof |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
KR1020150029137A KR20160106348A (en) | 2015-03-02 | 2015-03-02 | Video Coding Method and Apparatus thereof |
Publications (1)
Publication Number | Publication Date |
---|---|
KR20160106348A true KR20160106348A (en) | 2016-09-12 |
Family
ID=56950203
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
KR1020150029137A KR20160106348A (en) | 2015-03-02 | 2015-03-02 | Video Coding Method and Apparatus thereof |
Country Status (1)
Country | Link |
---|---|
KR (1) | KR20160106348A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2018117334A1 (en) * | 2016-12-21 | 2018-06-28 | 전자부품연구원 | High-efficiency video coding mode determination method and determination device |
CN117692648A (en) * | 2024-02-02 | 2024-03-12 | 腾讯科技(深圳)有限公司 | Video encoding method, apparatus, device, storage medium, and computer program product |
-
2015
- 2015-03-02 KR KR1020150029137A patent/KR20160106348A/en unknown
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2018117334A1 (en) * | 2016-12-21 | 2018-06-28 | 전자부품연구원 | High-efficiency video coding mode determination method and determination device |
CN117692648A (en) * | 2024-02-02 | 2024-03-12 | 腾讯科技(深圳)有限公司 | Video encoding method, apparatus, device, storage medium, and computer program product |
CN117692648B (en) * | 2024-02-02 | 2024-05-17 | 腾讯科技(深圳)有限公司 | Video encoding method, apparatus, device, storage medium, and computer program product |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
KR101903602B1 (en) | Method and apparratus of video decoding | |
US20180376137A1 (en) | Method and apparatus for image encoding/decoding | |
KR102412934B1 (en) | Method for intra prediction and apparatus thereof | |
WO2010004939A1 (en) | Image encoding device, image decoding device, image encoding method, and image decoding method | |
KR20110018188A (en) | Method and apparatus for image encoding, and method and apparatus for image decoding | |
KR20130085392A (en) | Method and apparatus for encoding and decoding video to enhance intra prediction process speed | |
US11962803B2 (en) | Method and device for intra-prediction | |
CN113810686B (en) | Encoding and decoding method, device and equipment | |
JP2008271127A (en) | Coding apparatus | |
KR101603887B1 (en) | Method for coding data by fast coding unit decision in high efficiency video coding | |
KR20160106348A (en) | Video Coding Method and Apparatus thereof | |
KR20140043015A (en) | Method and apparatus for image encoding | |
KR101475286B1 (en) | Method and apparatus for intra prediction, and apparatus for processing picture | |
JP4697802B2 (en) | Video predictive coding method and apparatus | |
KR20130049604A (en) | Mode Switching Method in Entropy Coding | |
KR20240122241A (en) | Method and apparatus for encoding/decoding video | |
KR20160108958A (en) | Video Coding Method and Apparatus thereof | |
KR20160092816A (en) | Video Coding Method and Apparatus thereof | |
KR20130055316A (en) | Apparatus and method for encoding/decoding of video for intra prediction | |
KR20140079519A (en) | Quantization parameter coding method using average quantization parameter |