Image prediction method, encoder, decoder, and storage medium
By using syntax units to indicate the MIP mode in the encoder and decoder, the image prediction process is simplified, and the problem of inefficient encoding and decoding caused by the complexity of MIP technology is solved, and more efficient encoding and decoding performance is achieved.
Patent Information
- Application Number
- CN202411513473.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2019-07-07
- Filing Date
- 2020-05-15
- Publication Date
- 2025-03-14
- Estimated Expiration
- 2040-05-15
AI Technical Summary
In the multifunctional video encoding technology, although matrix-based intra prediction (MIP) technology improves the encoding and decoding performance, due to its high complexity, the storage space and overall time required during the encoding and decoding process are greatly increased, reducing the encoding and decoding efficiency.
The image prediction process is simplified by using a syntax unit in the encoder and decoder to indicate whether the current block uses the MIP mode in the code stream and determines the predicted values of the luminance component and the chrominance component according to the MIP mode.
On the basis of ensuring the encoding and decoding performance, the complexity is reduced, the storage space and overall time required during the encoding and decoding process are reduced, and the encoding and decoding efficiency is effectively improved.
Smart Images

Figure CN119629366A_ABST
Abstract
Description
[0001] This divisional application is a divisional application of the invention patent application with application date of May 15, 2020, application number 202080044380.2, and invention name “Image prediction method, encoder, decoder and storage medium”.
[0002] This invention patent application is based on the prior U.S. provisional patent application with application number 62 / 871,177, application date July 7, 2019, and application name “Method, Apparatus, and System for Encoding and Decoding Video Data” and claims priority to the prior U.S. provisional patent application. The entire contents of the prior U.S. provisional patent application are hereby incorporated into this application by reference. Technical Field
[0003] The embodiments of the present application relate to the field of video coding and decoding technology, and in particular to an image prediction method, an encoder, a decoder, and a storage medium. Background Art
[0004] In the Versatile Video Coding (VVC) reference software test platform, a new intra-frame coding technology, Matrix-based Intra Prediction (MIP), was proposed. MIP is a neural network-based intra-frame prediction technology that uses a multi-layer neural network to predict the luminance value of the current block based on adjacent reconstructed luminance blocks. Specifically, similar to the traditional intra-frame mode, when using the MIP mode for intra-frame prediction, the input of the MIP prediction is also the data of the adjacent luminance blocks in the previous row and left column of the current block, and the output is the predicted value of the luminance component of the current block. The specific prediction process is divided into three steps: downsampling, matrix-vector multiplication, and interpolation.
[0005] However, due to the high complexity of the MIP mode, while the MIP technology improves the encoding and decoding performance, the storage space and overall time required in the encoding and decoding process are also greatly increased, thereby reducing the encoding and decoding efficiency. Summary of the Invention
[0006] The embodiments of the present application provide an image prediction method, an encoder, a decoder, and a storage medium, which can reduce the complexity while ensuring the encoding and decoding performance, reduce the storage space and overall time required in the encoding and decoding process, and effectively improve the encoding and decoding efficiency.
[0007] The technical solution of the embodiment of the present application is implemented as follows:
[0008] In a first aspect, an embodiment of the present application provides an image prediction method, applied to an encoder, the method comprising:
[0009] If the current block uses the MIP mode to determine the intra prediction value of the current block, the value of the MIP mode parameter is set to indicate the use of the MIP mode and written into the bitstream;
[0010] Determining a MIP mode of the current block, and determining predicted values of a luminance component and a chrominance component corresponding to the current block according to the MIP mode;
[0011] The MIP mode of the current block is written into the code stream.
[0012] In a second aspect, an embodiment of the present application provides an image prediction method, applied to a decoder, the method comprising:
[0013] Parse the code stream and determine the MIP mode parameters of the current block;
[0014] If the value of the MIP mode parameter indicates that the current block uses the MIP mode to determine the intra prediction value of the current block, parsing the code stream, determining the MIP mode of the current block, and determining the prediction values of the luminance component and the chrominance component corresponding to the current block according to the MIP mode;
[0015] The current block is decoded according to the prediction value.
[0016] In a third aspect, an embodiment of the present application provides an encoder, comprising: a setting part, a first determining part, and an encoding part.
[0017] The setting part is configured to set the value of the MIP mode parameter to indicate the use of the MIP mode and write it into the bitstream if the current block uses the MIP mode to determine the intra-frame prediction value of the current block;
[0018] The first determining part is configured to determine a MIP mode of the current block, and determine predicted values of a luminance component and a chrominance component corresponding to the current block according to the MIP mode;
[0019] The encoding part is configured to write the MIP mode of the current block into the code stream.
[0020] In a fourth aspect, an embodiment of the present application provides an encoder, which includes a first processor and a first memory storing instructions executable by the first processor. When the instructions are executed by the first processor, the image prediction method as described above is implemented.
[0021] In a fifth aspect, an embodiment of the present application provides a decoder, comprising: a decoding part, a second determining part,
[0022] The decoding part is configured to parse the code stream and determine the MIP mode parameter of the current block; and if the value of the MIP mode parameter indicates that the current block uses the MIP mode to determine the intra-frame prediction value of the current block, parse the code stream and determine the MIP mode of the current block;
[0023] The second determining part is configured to determine the predicted values of the luminance component and the chrominance component corresponding to the current block according to the MIP mode;
[0024] The decoding part is further configured to decode the current block according to the prediction value.
[0025] In a sixth aspect, an embodiment of the present application provides a decoder, which includes a second processor and a second memory storing instructions executable by the second processor. When the instructions are executed by the second processor, the image prediction method as described above is implemented.
[0026] In the seventh aspect, an embodiment of the present application provides a computer-readable storage medium on which a program is stored, which is applied to an encoder and a decoder. When the computer program is executed by a first processor, it implements the image prediction method as described above, or when it is executed by a second processor, it implements the image prediction method as described above.
[0027] The embodiments of the present application provide an image prediction method, an encoder, a decoder, and a storage medium. If a current block uses a MIP mode to determine an intra-frame prediction value for the current block, the encoder sets the value of a MIP mode parameter to indicate the use of the MIP mode and writes it into a bitstream. The encoder determines the MIP mode for the current block and, based on the MIP mode, determines prediction values for the luminance and chrominance components corresponding to the current block. The decoder parses the bitstream and determines the MIP mode parameter for the current block. If the value of the MIP mode parameter indicates that the current block uses the MIP mode to determine an intra-frame prediction value for the current block, the decoder parses the bitstream, determines the MIP mode for the current block, and, based on the MIP mode, determines prediction values for the luminance and chrominance components corresponding to the current block. The decoder then decodes the current block based on the prediction values. That is to say, in an embodiment of the present application, when the encoder performs intra-frame prediction on the current block, if it determines that the current block uses the MIP mode, it can set the MIP mode parameters and write them into the code stream for transmission to the decoding side while using the MIP mode to obtain the intra-frame prediction value of the current block; the decoder parses the code stream to obtain the MIP mode parameters. If the MIP mode parameters indicate that the current block uses the MIP mode, the decoder can use the MIP mode to determine the intra-frame prediction value of the current block. It can be seen that the image prediction method proposed in this application can use the syntax unit to indicate whether the current block uses the MIP mode in the code stream, thereby simplifying the image prediction process, and can reduce the complexity while ensuring the encoding and decoding performance, reduce the storage space and overall time required in the encoding and decoding process, and effectively improve the encoding and decoding efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] Figure 1 Schematic diagram of the arrangement of 67 prediction modes in intra-frame prediction;
[0029] Figure 2 Schematic diagram of the process of encoding for MIP mode;
[0030] Figure 3 Schematic diagram of the arrangement of the upper adjacent luminance blocks and the left adjacent luminance blocks of the current block;
[0031] Figure 4 Schematic diagram for determining the arrangement of DM mode;
[0032] Figure 5 It is a structural diagram of a video coding system;
[0033] Figure 6 It is a structural diagram of a video decoding system;
[0034] Figure 7 Schematic diagram of the implementation process of the image prediction method Figure 1 ;
[0035] Figure 8 Schematic diagram of the implementation process of the image prediction method Figure 2 ;
[0036] Figure 9 Schematic diagram of the structure of the encoder proposed in this embodiment Figure 1 ;
[0037] Figure 10 Schematic diagram of the structure of the encoder proposed in this embodiment Figure 2 ;
[0038] Figure 11 Schematic diagram of the structure of the decoder proposed in this embodiment of the application Figure 1 ;
[0039] Figure 12 Schematic diagram of the structure of the decoder proposed in this embodiment of the application Figure 2 . DETAILED DESCRIPTION
[0040] The following will be combined with the accompanying drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. It should be understood that the specific embodiments described herein are only used to explain the related applications and are not intended to limit the applications. It should also be noted that for ease of description, only the parts relevant to the related applications are shown in the drawings.
[0041] At present, the Communications Edition Recommendations (ITU-T) and the International Organization for Standardization (ISO) / International Electrotechnical Commission (IEC) have launched a standardization project called Versatile Video Coding (VVC) to develop a new generation of video coding standards. Its purpose is to improve the performance of VVC by about 50% compared with the latest H.265 / HEVC standard when encoding high-quality videos with one or more characteristics of high resolution, high frame rate, high bit depth, high dynamic range, wide color gamut and omnidirectional viewing angle. JVET is responsible for this standardization project. Various intra-frame prediction modes and inter-frame prediction modes have been verified to achieve high compression efficiency when encoding high-quality videos, and therefore have been adopted in the VVC working draft.
[0042] In video images, VVC accepted the Affine Linear Weighted IntraPrediction technology proposed in the Joint Video Experts Team (JVET)-N0217 and renamed it as Matrix-based Intra Prediction, or MIP technology. This technology adds different numbers of matrix-based intra prediction modes in the intra-frame luminance prediction process based on the different sizes of intra-frame luminance coding blocks.
[0043] In order to capture finer edge directions presented in natural videos, VVC expands the 33 intra-frame brightness prediction angle modes defined in the video compression standard (High Efficiency Video Coding, HEVC) to 65. Figure 1 This is a schematic diagram of the arrangement of 67 prediction modes in intra-frame prediction, such as Figure 1 As shown in the figure, the arrows numbered 2-66 represent 65 intra-frame angle prediction modes, and there are two non-angle modes, namely the gradual flat Planar mode numbered 0 and the DC mode numbered 1; therefore, the intra-frame prediction process in VVC includes two non-angle modes and 65 angle modes. Here, these 67 prediction modes are called traditional modes of intra-frame prediction.
[0044] MIP is an intra-frame prediction technology based on neural networks. It uses a multi-layer neural network to predict the brightness value of the current block based on adjacent reconstructed pixels. Specifically, MIP technology divides the brightness coding blocks into three categories according to the size of the brightness coding blocks within the frame. Assuming the size of the brightness coding block is W×H, where W is the width parameter and H is the height parameter, the brightness coding blocks can be divided into three categories according to the size of the brightness coding blocks:
[0045] The luminance coding block of size 4×4 is the first type of luminance block, the luminance coding blocks of sizes 8×4, 4×8 and 8×8 are the second type of luminance blocks, and the luminance coding blocks of other sizes are the third type of luminance blocks.
[0046] For these three types of intra-frame luminance coding blocks, MIP technology adds M MIP modes on the basis of 67 traditional intra-frame prediction modes, where M=16 for the first type of luminance blocks, M=8 for the second type of luminance blocks, and M=6 for the third type of luminance blocks.
[0047] Specifically, MIP technology is only used for intra-frame luminance prediction. Like traditional methods, the input for MIP prediction is the data from the previous row and left column of the current block, and the output is the predicted value for the current block. The prediction process is divided into three steps: averaging, matrix-vector multiplication, and interpolation. In other words, by performing these three operations on the reconstructed luminance values of adjacent pixels in the previous row and left column of the input, the predicted value of the luminance component of the current block can be obtained.
[0048] Figure 2 The flowchart for encoding the MIP mode is as follows: Figure 2 As shown, the specific implementation of brightness prediction in MIP mode is as follows:
[0049] Step 1: Perform an average operation on the upper adjacent reference points of the current block to obtain the vector bdry top , a total of N values; the vector bdry is obtained by averaging the adjacent reference points on the left side of the current blockleft , a total of N values. When the current brightness code is the first type of brightness code, N = 2; when the current brightness code is the second or third type of brightness code, N = 4. Vector bdry top and vector bdry left Form a new vector bdry red and perform subsequent operations;
[0050] Step 2: Get the corresponding matrix A through the mode number k of the MIP mode k and offset b k , calculated by the following formula (1) Figure 2 The partial prediction values of the current block are marked with cross lines in :
[0051] Pred red =A k ·bdry red +b k (1)
[0052] Step 3: Obtain the remaining predicted value Pred in the current block through linear interpolation red .
[0053] It should be noted that, in the implementation process of encoding the current block, it is necessary to write the specific coding mode used for intra-frame prediction into the compressed code stream, so that the decoding end can determine which mode to use, whether it is the traditional mode or the MIP mode, by parsing the mode information; if it is the traditional mode, which traditional mode to use; if it is the MIP mode, which MIP mode to use.
[0054] In VVC's intra-frame prediction, the rate-distortion cost (RDcost) of each luma coding block is compared between 67 traditional modes and M MIP modes. The optimal mode is selected and encoded. To save bit overhead, VVC uses intra-frame mode coding technology based on the Most Probable Modes List (MPM).
[0055] It should be noted that since the multi-reference line technology (extend reference line) and intra-frame sub-block partitioning technology (Itra Sub-Patitionar, ISP) are only used for the modes in the MPM list, when extendrefflag and ispflag are both 0, that is, when 0 reference line is used and no sub-block partitioning is performed, it is not necessary to encode mpmflag, and the position of the optimal mode in the MPM list can be directly encoded.
[0056] Furthermore, with regard to the construction of the MPM list and the MIPMPM list, in the VVC luminance intra-frame prediction, if the optimal mode selected for the current block is the traditional mode, it is necessary to construct an MPM list containing 6 most likely traditional modes; if the optimal mode selected for the current block is the MIP mode, it is necessary to construct a MIPMPM list containing 3 most likely MIP modes.
[0057] Figure 3 is a schematic diagram of the arrangement of the upper adjacent luminance blocks and the left adjacent luminance blocks of the current block, such as Figure 3 As shown, the above two lists are based on Figure 3 The optimal modes of the upper adjacent luminance block (A) and the left adjacent luminance block (L) of the current block are derived.
[0058] Specifically, for the construction of the MPM list, in VVC intra-frame prediction, if the optimal mode of the current block is the traditional mode, an MPM list needs to be constructed. In the process of constructing the MPM list, it is first necessary to obtain the traditional mode ABOVE corresponding to the optimal mode of the upper adjacent luminance block and the traditional mode LEFT corresponding to the optimal mode of the left adjacent luminance block.
[0059] Furthermore, for the construction of the MIPMPM list, in VVC intra-frame prediction, if the optimal mode of the current block is the MIP mode, a MIPMPM list needs to be constructed. In the process of constructing the MIPMPM list, it is first necessary to obtain the MIP mode ABOVE_MIP corresponding to the optimal mode of the upper adjacent luminance block and the MIP mode LEFT_MIP corresponding to the optimal mode of the left adjacent luminance block.
[0060] Furthermore, after obtaining LEFT_MIP and ABOVE_MIP, a MIPMPM list containing three most likely MIPMPM modes is constructed as follows, where the number in MIPMPM is the number of the MIP mode, ranging from 0 to (M-1), and the first type of luminance blocks are numbered 0-15; the second type of luminance blocks are numbered 0-7; and the third type of luminance blocks are numbered 0-5:
[0061] If LEFT_MIP is available (not -1), put LEFT_MIP into MIPMPMlist;
[0062] If ABOVE_MIP is available (not -1), put ABOVE_MIP into MIPMPMlist after passing redundancy check;
[0063] If LEFT_MIP is not available (-1), ABOVE_MIP is not available (-1), add the default list after redundancy check according to the type of the current block until the MIPMPMlist is filled:
[0064] Furthermore, it should be added that in the VVC chroma intra prediction process, there is a direct mode (DM) that uses the correlation between components. The intra prediction mode of the center position of the co-located luminance coding block corresponding to the current block is used to perform intra prediction on the current chroma block. Figure 4 To determine the arrangement diagram of DM mode, as shown in Figure 4 As shown in Figure 4 When the intra-frame prediction mode of the CR position is the MIP mode, the MIP mode needs to be mapped to the traditional mode through the "MIP-traditional mapping table" to perform intra-frame prediction of the current chroma block.
[0065] Due to the computational burden and storage cost required by MIP technology, it is difficult to implement MIP mode on devices with relatively low computing power or small storage capacity. Therefore, the latest VVC working draft design does not provide effective communication and control of MIP mode, making it difficult to implement in flexible codec implementations and dynamic video streams.
[0066] To overcome the above-mentioned drawbacks, in an embodiment of the present application, when performing intra-frame prediction on a current block, if the encoder determines that the current block uses the MIP mode, it can simultaneously use the MIP mode to obtain the intra-frame prediction value for the current block and set the MIP mode parameters in the bitstream for transmission to the decoder. The decoder then parses the bitstream to obtain the MIP mode parameters. If the MIP mode parameters indicate that the current block uses the MIP mode, the decoder can then use the MIP mode to determine the intra-frame prediction value for the current block. In other words, in the present application, the VVC bitstream conveys one or more syntax elements to enable or disable the MIP mode. These syntax elements can be located in data units at the video sequence layer, picture layer, and / or sub-picture layer, or slice / tile / brick layer, where a sub-picture refers to an area covering a portion of a picture. Thus, the image prediction method proposed in the present application can utilize syntax elements in the bitstream to indicate whether the current block uses the MIP mode, thereby simplifying the image prediction process for the MIP mode. This reduces complexity while ensuring codec performance, reducing the storage space and overall time required for the codec process, and effectively improving codec efficiency.
[0067] Figure 5 It is a structural diagram of the video coding system. Figure 5As shown, the video coding system 100 includes a transform and quantization module 101, an intra-frame estimation module 102, an intra-frame prediction module 103, a motion compensation module 104, a motion estimation module 105, an inverse transform and inverse quantization module 106, a filter control analysis module 107, a deblocking filter and sample adaptive offset (SAO) filter module 108, a header information encoding and context-based adaptive binary arithmetic coding (CABAC) encoding module 109, and a decoded image buffer module 110. Figure 6 It is a structural diagram of the video decoding system, such as Figure 6 As shown, the video decoding system 200 includes components such as a header information decoding and CABAC decoding module 201, an inverse transform and inverse quantization module 202, an intra-frame prediction module 203, a motion compensation module 204, a deblocking filter and SAO filter module 205, and a decoded image buffer module 206. After the video image is processed by the transform and quantization module 101, the intra-frame estimation module 102, the intra-frame prediction module 103, the motion compensation module 104, the motion estimation module 105, the deblocking filter and SAO filter module 108, and the header information encoding and CABAC module 109 in the video encoding system 100, a bitstream of the video image is output. This bitstream is input into the video decoding system 200, and after being processed by the header information decoding and CABAC decoding module 201, the inverse transform and inverse quantization module 202, the intra-frame prediction module 203, and the motion compensation module 204 in the video decoding system 200, the original video image is finally restored.
[0068] The image prediction method proposed in this application can affect the entropy coding process and the entropy decoding process in the encoding and decoding process. For example, the image prediction method proposed in this application can be used in Figure 5 The structure of the video coding system shown in FIG109 is applied at position 109, and can also be used in Figure 6 The structure of the video decoding system shown is applied at position 201.
[0069] The technical solutions in the embodiments of the present application will be described clearly and completely below in conjunction with the drawings in the embodiments of the present application.
[0070] An embodiment of the present application proposes an image prediction method, which is applied to an encoder. Figure 7 Schematic diagram of the implementation process of the image prediction method Figure 1 ,like Figure 7 As shown, in this application, the method for an encoder to perform image prediction may include the following steps:
[0071] Step 101: If the current block uses the MIP mode to determine the intra prediction value of the current block, the value of the MIP mode parameter is set to indicate the use of the MIP mode and written into the bitstream.
[0072] In an embodiment of the present application, if a MIP mode is used for a current block to determine an intra-frame prediction value of the current block, the encoder can set the value of the MIP mode parameter to indicate the use of the MIP mode and write it into the bitstream. The current block can represent a current block to be encoded or a current block to be decoded. Specifically, in the present application, when the encoder is encoding, the current block is the block to be encoded.
[0073] Furthermore, in an embodiment of the present application, when encoding a current block, the encoder may first select an optimal encoding method between the traditional mode and the MIP mode.
[0074] It should be noted that in the embodiment of the present application, during the intra-frame prediction process of VVC, for any luma coding block, an optimal mode can be selected from the traditional mode and the MIP mode for encoding. The traditional mode includes 67 intra-frame prediction modes, including the Planar mode numbered 0, the DC mode numbered 1, and 65 angular modes.
[0075] Furthermore, in an embodiment of the present application, when selecting the optimal mode, the encoder can compare the Rdcost of 67 traditional modes and M MIP modes for the current block, so that the optimal mode can be selected and encoded based on the comparison results. The value of M varies based on the size type of the current block. Specifically, when the current block is a first-class luminance block, that is, the current block size is 4×4, M=16; when the current block is a second-class luminance block, that is, the current block size is 8×4, 4×8 or 8×8, M=8; when the current block is a third-class luminance block, that is, the current block size is other sizes, M=6.
[0076] It is understood that in the embodiments of the present application, if the encoder determines to use the MIP mode to determine the intra-frame prediction value of the current block, then the encoder can set the value of the MIP mode parameter to indicate the use of the MIP mode and write it into the bitstream. In other words, the encoder can use a syntax element to indicate whether the current block uses the MIP mode, that is, the MIP mode parameter is used to indicate whether the current block uses the MIP mode.
[0077] Exemplarily, in an embodiment of the present application, after the encoder determines to use the MIP mode to determine the intra-frame prediction value of the current block, it can set the value of the MIP mode parameter to 1 and write it into the code stream, thereby indicating that the current block uses the MIP mode.
[0078] Furthermore, in an embodiment of the present application, if the encoder determines not to use the MIP mode to determine the intra prediction value of the current block, the encoder may set the value of the MIP mode parameter to indicate not using the MIP mode and write it into the bitstream.
[0079] Exemplarily, in an embodiment of the present application, after determining not to use the MIP mode to determine the intra-frame prediction value of the current block, the encoder can set the value of the MIP mode parameter to 0 and write it into the bitstream, thereby indicating that the current block does not use the MIP mode.
[0080] Furthermore, in an embodiment of the present application, after the encoder completes setting the value of the MIP mode parameter, it can indicate the MIP mode parameter in the codestream using one or more syntax units. In other words, after the encoder completes setting the MIP mode parameter based on whether the current block uses the MIP mode, it can indicate the MIP mode parameter in the codestream using one or more syntax units.
[0081] It can be understood that in an embodiment of the present application, the syntax unit indicating the MIP mode parameters can be included in one or more data units in the following code stream: a data unit containing the current block, a slice header information data unit, an image header information data unit, an image layer parameter set, a sequence layer parameter set, and an adaptation parameter set.
[0082] It should be noted that in an embodiment of the present application, since one or more data units in the codestream including the data unit containing the current block, the slice header information data unit, the image header information data unit, the image layer parameter set, the sequence layer parameter set, and the adaptive parameter set can indicate the MIP mode parameters, the MIP mode parameters set by the encoder can be adapted thereto.
[0083] Exemplarily, in the present application, if the encoder writes the MIP mode parameter into the sequence layer parameter set (SPS), the MIP mode parameter can be indicated by sps_mip_enable_flag, so the decoder can determine the MIP mode parameter sps_mip_enable_flag after parsing the data unit of the sequence layer parameter set in the code stream.
[0084] Exemplarily, in the present application, if the encoder writes the MIP mode parameter into the picture layer parameter set (PictureParamater Set, PPS), the MIP mode parameter can be indicated by pps_mip_enable_flag, so after the decoder parses the data unit of the picture layer parameter set in the code stream, it can determine the MIP mode parameter pps_mip_enable_flag.
[0085] Exemplarily, in the present application, if the encoder writes the MIP mode parameter into the adaptive parameter set (APS), the MIP mode parameter can be indicated by aps_mip_enable_flag, so after the decoder parses the data unit of the adaptive parameter set in the code stream, it can determine the MIP mode parameter aps_mip_enable_flag.
[0086] Exemplarily, in this application, if the encoder writes the MIP mode parameter into the slice header information data unit, the MIP mode parameter can be indicated by slice_mip_enable_flag, so the decoder can determine the MIP mode parameter slice_mip_enable_flag after parsing the data unit of the slice header information data unit in the code stream.
[0087] Step 102: Determine the MIP mode of the current block, and determine the prediction values of the luminance component and the chrominance component corresponding to the current block according to the MIP mode.
[0088] In an embodiment of the present application, if the MIP mode is used to determine the intra-frame prediction value of the current block, the encoder can further determine the MIP mode of the current block, and then determine the prediction values of the luminance component and chrominance component corresponding to the current block according to the MIP mode.
[0089] It can be understood that in an embodiment of the present application, when the encoder determines the MIP mode corresponding to the current block, it can first determine the size type of the current block; then construct a candidate MIP mode list based on the size type; finally, it can determine the MIP mode of the current block from the candidate MIP mode list.
[0090] Furthermore, in an embodiment of the present application, the current block can be divided into three size types according to the size of the current block. If the size of the current block is W×H, where W is a width parameter and H is a height parameter, then the current block with a size of 4×4 can be determined as a first type of luminance block, that is, the size type of the current block is determined to be the first type; current blocks with sizes of 8×4, 4×8 and 8×8 can also be determined as second type of luminance blocks, that is, the size type of the current block is determined to be the second type; current blocks of other sizes can also be determined as third type of luminance blocks, that is, the size type of the current block is determined to be the third type.
[0091] It is understandable that in this application, according to the height parameter and the width parameter, the current block can be of 25 sizes. Specifically, the standard stipulates that the maximum size of the luminance block is 128×128, but since the maximum size of the transform unit is 64×64, that is, the luminance block must be quadtree-partitioned at the size of 128×128, so the maximum luminance block size is 64×64. Table 1 is a schematic table of luminance block sizes, as shown in Table 1,
[0092] Table 1
[0093] (4×4) (4×8) (4×16) (4×32) (4×64) (8×4) (8×8) (8×16) (8×32) (8×64) (16×4) (16×8) (16×16) (16×32) (16×64) (32×4) (32×8) (32×16) (32×32) (32×64) (64×4) (64×8) (64×16) (64×32) (64×64)
[0094] Currently, the MIP mode is restricted according to the height parameter and width parameter of the current block. Specifically, if the aspect ratio of the current block is greater than 4, or the height-to-width ratio is greater than 4, the MIP mode is not used to encode the current block. Table 2 shows the restrictions on the luminance block size under the MIP mode.
[0095] Table 2
[0096] (4×4) (4×8) (4×16) (4×32) (4×64) (8×4) (8×8) (8×16) (8×32) (8×64) (16×4) (16×8) (16×16) (16×32) (16×64) (32×4) (32×8) (32×16) (32×32) (32×64) (64×4) (64×8) (64×16) (64×32) (64×64)
[0097] That is to say, in the present application, when the encoder determines the size type of the current block, if the width and height of the current block are both equal to 4, that is, the size of the current block is 4×4, the size type of the current block can be set to the first type; if the width and height of the current block are both equal to 8, that is, the size of the current block is 8×8, or the width of the current block is equal to 8 and the height is equal to 4, that is, the size of the current block is 8×4, or the width of the current block is equal to 4 and the height is equal to 8, that is, the size of the current block is 4×8, the size type of the current block can be set to the second type; if the width and height of the current block do not meet the above conditions, that is, the size of the current block is not 4×4, 8×8, 8×4, or 4×8, the size type of the current block can be set to the third type.
[0098] Furthermore, in an embodiment of the present application, according to the size type division method proposed in the current standard, when the encoder determines the size type of the current block, if the width and height of the current block are both equal to 4, the size type of the current block can be set to the first type; if the width and height of the current block are both equal to 8, or one of the width and height of the current block is equal to 4, the size type of the current block can be set to the second type; if the width and height of the current block do not meet the aforementioned conditions, that is, the width and height of the current block are not equal to 4 or 8 at the same time, or the width and height of the current block are not equal to 4, the size type of the current block can be set to the third type.
[0099] It should be noted that in the embodiments of the present application, for different size types, the encoder can construct different candidate MIP mode lists. Specifically, the MIP technology adds M MIP modes on top of the 67 traditional intra-frame prediction modes. The value of M is different for different size types. The value of M can include 16, 8, and 6.
[0100] Exemplarily, in the present application, when the size type of the current block is the first type, the value of M is 16, that is, a candidate MIP mode list can be constructed based on 16 MIP modes; when the size type of the current block is the second type, the value of M is 8, that is, a candidate MIP mode list can be constructed based on 8 MIP modes; when the size type of the current block is the third type, the value of M is 6, that is, a candidate MIP mode list can be constructed based on 6 MIP modes.
[0101] Furthermore, in an embodiment of the present application, after the encoder completes the construction of the candidate MIP mode list according to the size type of the current block, it can determine the MIP mode used by the current block from the candidate MIP mode list, so that the MIP mode can be used to perform image prediction processing on the current block to obtain the intra-frame prediction value of the current block.
[0102] It can be understood that in an embodiment of the present application, after constructing a candidate MIP mode list corresponding to the current block, the encoder can select a MIP mode from the candidate MIP mode list, and then use the MIP mode to determine the predicted values of the luminance component and chrominance component corresponding to the current block.
[0103] Specifically, in an embodiment of the present application, the encoder can first read the mode number k of the MIP mode from the candidate MIP mode list, so as to obtain the corresponding matrix Ak and offset bk, and perform matrix-vector multiplication according to the above formula (1), so as to obtain the brightness component prediction value corresponding to the current block.
[0104] It should be noted that in an embodiment of the present application, after the encoder determines the MIP mode of the current block from the candidate MIP mode list, it can further set the MIP mode index number of the current block according to the MIP mode of the current block, and write the MIP mode index number into the code stream.
[0105] It will be understood that, in the present application, the MIP mode index number of the current block can be used to indicate the specific MIP mode used for the current block. That is, on the encoding side, the encoder sets the MIP mode index number of the current block and writes it into the bitstream, which is then transmitted to the decoding side. The decoder parses the bitstream to obtain the MIP mode index number of the current block, and can then determine the MIP mode indicated by the MIP mode index number from the candidate MIP mode list of the current block.
[0106] Step 103: Write the MIP mode of the current block into the bitstream.
[0107] In an embodiment of the present application, after determining the MIP mode of the current block and determining the prediction values of the luminance component and chrominance component corresponding to the current block according to the MIP mode, the encoder may write the MIP mode of the current block into the bitstream.
[0108] That is to say, in the present application, during the implementation process of encoding the current block, the encoder not only needs to write into the compressed code stream whether the current block uses the MIP mode, but also needs to write into the code stream which specific mode is used. For example, when using the MIP mode for intra-frame prediction, which specific MIP mode is used.
[0109] The embodiment of the present application proposes an image prediction method. If the current block uses the MIP mode to determine the intra-frame prediction value of the current block, the encoder sets the value of the MIP mode parameter to indicate the use of the MIP mode and writes it into the bitstream; determines the MIP mode of the current block, and determines the prediction value of the luminance component and chrominance component corresponding to the current block based on the MIP mode; and writes the MIP mode of the current block into the bitstream. That is, in the embodiment of the present application, when the encoder performs intra-frame prediction on the current block, if it is determined that the current block uses the MIP mode, it can set the MIP mode parameter while using the MIP mode to obtain the intra-frame prediction value of the current block and write it into the bitstream for transmission to the decoding side; the decoder parses the bitstream to obtain the MIP mode parameter. If the MIP mode parameter indicates that the current block uses the MIP mode, the decoder can use the MIP mode to determine the intra-frame prediction value of the current block. As can be seen, the image prediction method proposed in the present application can use the syntax unit in the bitstream to indicate whether the current block uses the MIP mode, thereby simplifying the image prediction process, reducing the complexity while ensuring the encoding and decoding performance, reducing the storage space and overall time required in the encoding and decoding process, and effectively improving the encoding and decoding efficiency.
[0110] Based on the above embodiment, another embodiment of the present application proposes an image prediction method, when the encoder determines to use the MIP mode to predict the intra-frame prediction value of the current block, the MIP mode parameter indicating whether the current block uses the MIP mode can be written into one or more syntax elements in the code stream. That is, in the present application, the VVC bitstream transmits one or more syntax elements to enable or disable the MIP mode. The syntax element can be located in a data unit in the video sequence layer, picture layer and / or sub-picture layer, slice / tile / brick layer, where a sub-picture refers to an area covering a part of a picture.
[0111] For example, in the present application, an encoder may determine whether to use a MIP mode when encoding a video sequence. The entropy coding unit may encode a flag in a parameter set associated with all slices in the video sequence. Table 3 shows an embodiment of implementing a syntax structure in a sequence parameter set (SPS), where u(1) represents the entropy coding method described in detail in the VVC working draft.
[0112] Table 3
[0113] …… Descriptor sps_mip_enable_flag u(1) ……
[0114] Based on Table 3 above, when the encoder determines that the MIP mode is not applied when encoding the input video sequence, the entropy coding unit can set the sps_mip_enable_flag to 0 and write the value to the SPS (indirectly) related to the slice in the video sequence; when the encoder determines that the MIP mode is applied when encoding one or more slices in the input video sequence, the entropy coding unit can set the sps_mip_enable_flag to 1 and write the value to the SPS (indirectly) related to the slice in the video sequence.
[0115] That is, in this application, after the encoder completes setting the value of the MIP mode parameter sps_mip_enable_flag, it can indicate the MIP mode parameter in the bitstream using one or more syntax units. That is, after the encoder completes setting the MIP mode parameter sps_mip_enable_flag based on whether the current block uses the MIP mode, it can write the MIP mode parameter sps_mip_enable_flag into the sequence layer parameter set in the bitstream.
[0116] For example, in the present application, an encoder may determine whether to use a MIP mode when encoding a picture in a video sequence or a sub-picture in a picture. The entropy coding unit may encode a flag in a parameter set associated with all slices in the picture or sub-picture. Table 4 shows an embodiment of the implementation of the syntax structure in a picture layer parameter set (PPS), where u(1) represents the entropy coding method that has been detailed in the VVC working draft.
[0117] Table 4
[0118] …… Descriptor pps_mip_enable_flag u(1) ……
[0119] Based on Table 4 above, when the encoder determines that the MIP mode is not applied when encoding a picture or a sub-picture, the entropy coding unit can set the pps_mip_enable_flag to 0 and write the value to the PPS associated with the slice in the picture or sub-picture; when the encoder determines that the MIP mode is applied when encoding one or more slices in the picture or sub-picture, the entropy coding unit can set the pps_mip_enable_flag to 1 and write the value to the PPS (indirectly) associated with the slice in the picture or sub-picture.
[0120] That is, in this application, after the encoder completes setting the value of the MIP mode parameter pps_mip_enable_flag, it can indicate the MIP mode parameter in one or more syntax units in the bitstream. That is, after the encoder completes setting the MIP mode parameter pps_mip_enable_flag based on whether the current block uses the MIP mode, it can write the MIP mode parameter pps_mip_enable_flag into the picture layer parameter set in the bitstream.
[0121] For example, in the present application, an encoder may determine whether to use a MIP mode when encoding a picture in a video sequence or a sub-picture in a picture. The entropy coding unit may encode a flag in a parameter set associated with all slices in the picture or sub-picture. Table 5 shows an embodiment of the implementation of the syntax structure in an adaptive parameter set (APS), where u(1) represents the entropy coding method that has been detailed in the VVC working draft.
[0122] Table 5
[0123] …… Descriptor aps_mip_enable_flag u(1) ……
[0124] Based on Table 5 above, when the encoder determines that the MIP mode is not applied when encoding a picture or a sub-picture, the entropy coding unit can set aps_mip_enable_flag to 0 and write the value to the APS associated with the slice in the picture or sub-picture; when the encoder determines that the MIP mode is applied when encoding one or more slices in the picture or sub-picture, the entropy coding unit can set aps_mip_enable_flag to 1 and write the value to the APS (indirectly) associated with the slice in the picture or sub-picture.
[0125] That is, in this application, after the encoder completes setting the value of the MIP mode parameter aps_mip_enable_flag, it can indicate the MIP mode parameter in the bitstream using one or more syntax units. That is, after the encoder completes setting the MIP mode parameter aps_mip_enable_flag based on whether the current block uses the MIP mode, it can write the MIP mode parameter aps_mip_enable_flag into the adaptive parameter set in the bitstream.
[0126] Table 6
[0127] …… Descriptor slice_mip_enable_flag u(1) ……
[0128] For example, in the present application, the encoder may determine whether to use the MIP mode when encoding the slice. The entropy coding unit may encode a flag in the slice header. Table 6 shows an embodiment of the implementation of the syntax structure in the slice header, where u(1) represents the entropy coding method that has been detailed in the VVC working draft.
[0129] Based on Table 6 above, when the encoder determines that the MIP mode is not applied when encoding a slice, the entropy coding unit can set slice_mip_enable_flag to 0 and write the value into the slice header; when the encoder determines that the MIP mode is applied when encoding a slice, the entropy coding unit can set slice_mip_enable_flag to 1 and write the value into the slice header.
[0130] That is, in this application, after the encoder completes setting the value of the MIP mode parameter slice_mip_enable_flag, it can indicate the MIP mode parameter in one or more syntax units in the bitstream. That is, after the encoder completes setting the MIP mode parameter slice_mip_enable_flag according to whether the current block uses the MIP mode, it can write the MIP mode parameter slice_mip_enable_flag into the slice header information data unit in the bitstream.
[0131] For example, in the present application, when an encoder determines whether to use a MIP mode when encoding a tile or a brick, the entropy coding unit may write similar MIP mode parameters into a parameter set representing the partitioning of the tile or brick of the picture or sub-picture as part thereof. Optionally, the entropy coding unit may also write similar MIP mode parameters into slice data associated with the tile or brick in the slice to indicate whether to use the MIP mode when encoding the tile or brick.
[0132] For example, in the present application, the encoder may determine to apply the MIP mode when encoding a portion of a picture or sub-picture in a video sequence. The entropy coding unit may encode the sps_mip_enable_flag in the SPS as 1, encode the pps_mip_enable_flag in the PPS or the aps_mip_enable_flag in the APS associated with the slice in the picture or sub-picture as 1, and encode the pps_mip_enable_flag in the PPS or the aps_mip_enable_flag in the APS associated with other pictures or sub-pictures in the video sequence as 0. Alternatively, the entropy coding unit may encode the slice_mip_enable_flag in the slice in the picture or sub-picture (or a similar MIP mode parameter for a tile or brick in the slice data) as 1, and encode the slice_mip_enable_flag in the slice in the other pictures or sub-pictures (or a similar MIP mode parameter for a tile or brick in the slice data) as 0.
[0133] For example, in the present application, the encoder may also implicitly convey whether the MIP mode is used to encode the video sequence in other syntax elements (e.g., syntax elements indicating the profile / level / class (PTL) in one or more parameter sets of a bitstream or sub-bitstream). For example, the encoder sets the MIP mode to disabled in one or more PTLs and sets the MIP mode to enabled in other PTLs.
[0134] It can be understood that, in the present application, when the encoder transmits an indication to the bitstream that the current block is encoded using the MIP mode, the decoder can decode the bitstream using the MIP mode accordingly.
[0135] The embodiment of the present application proposes an image prediction method. If the current block uses the MIP mode to determine the intra-frame prediction value of the current block, the encoder sets the value of the MIP mode parameter to indicate the use of the MIP mode and writes it into the bitstream; determines the MIP mode of the current block, and determines the prediction value of the luminance component and chrominance component corresponding to the current block based on the MIP mode; and writes the MIP mode of the current block into the bitstream. That is, in the embodiment of the present application, when the encoder performs intra-frame prediction on the current block, if it is determined that the current block uses the MIP mode, it can set the MIP mode parameter while using the MIP mode to obtain the intra-frame prediction value of the current block and write it into the bitstream for transmission to the decoding side; the decoder parses the bitstream to obtain the MIP mode parameter. If the MIP mode parameter indicates that the current block uses the MIP mode, the decoder can use the MIP mode to determine the intra-frame prediction value of the current block. As can be seen, the image prediction method proposed in the present application can use the syntax unit in the bitstream to indicate whether the current block uses the MIP mode, thereby simplifying the image prediction process, reducing the complexity while ensuring the encoding and decoding performance, reducing the storage space and overall time required in the encoding and decoding process, and effectively improving the encoding and decoding efficiency.
[0136] Based on the above embodiments, an embodiment of the present application proposes an image prediction method, which is applied to a decoder. Figure 8 Schematic diagram of the implementation process of the image prediction method Figure 2 ,like Figure 8 As shown, in this application, the method for the decoder to perform image prediction may include the following steps:
[0137] Step 201: parse the code stream to determine the MIP mode parameters of the current block.
[0138] In an embodiment of the present application, the decoder parses the bitstream to determine the MIP mode parameters of the current block, where the current block can represent the current block to be encoded or the current block to be decoded. Specifically, in the present application, when the decoder is decoding, the current block is the block to be decoded.
[0139] It is understood that in the embodiments of the present application, the decoder can parse one or more syntax units in the bitstream to determine the MIP mode parameters of the current block. That is, in the present application, the MIP mode parameters can be indicated in the bitstream using one or more syntax units.
[0140] Furthermore, in an embodiment of the present application, the syntax unit indicating the MIP mode parameters may be included in one or more data units in the following code stream: a data unit containing the current block, a slice header information data unit, an image header information data unit, an image layer parameter set, a sequence layer parameter set, and an adaptation parameter set.
[0141] It should be noted that, in the embodiments of the present application, the MIP mode parameter is used to indicate whether the current block uses the MIP mode. Specifically, if the MIP mode parameter indicates that the MIP mode is used, the decoder may use the MIP mode to determine the intra-frame prediction value of the current block; if the MIP mode parameter indicates that the MIP mode is not used, the decoder will not use the MIP mode to determine the intra-frame prediction value of the current block.
[0142] Furthermore, in an embodiment of the present application, after parsing the code stream to determine the MIP mode parameter, the decoder may determine whether the current block uses the MIP mode according to the value of the MIP mode parameter.
[0143] Exemplarily, in an embodiment of the present application, after the decoder determines the MIP mode parameter, if the value of the MIP mode parameter is 1, it can indicate that the current block uses the MIP mode, and then the decoder can use the MIP mode to determine the intra-frame prediction value of the current block.
[0144] Exemplarily, in an embodiment of the present application, after the decoder determines the MIP mode parameter, if the value of the MIP mode parameter is 0, it can indicate that the current block does not use the MIP mode, and then the decoder will not use the MIP mode to determine the intra-frame prediction value of the current block.
[0145] It should be noted that in an embodiment of the present application, since one or more data units in the codestream including the data unit containing the current block, the slice header information data unit, the picture header information data unit, the picture layer parameter set, the sequence layer parameter set, and the adaptation parameter set can indicate the MIP mode parameters, the MIP mode parameters obtained by the decoder parsing can be adapted thereto.
[0146] Exemplarily, in this application, if the encoder writes the MIP mode parameter into the sequence layer parameter set, the MIP mode parameter can be indicated by sps_mip_enable_flag, so the decoder can determine the MIP mode parameter sps_mip_enable_flag after parsing the data unit of the sequence layer parameter set in the code stream.
[0147] Exemplarily, in this application, if the encoder writes the MIP mode parameter into the picture layer parameter set, the MIP mode parameter can be indicated by pps_mip_enable_flag, so the decoder can determine the MIP mode parameter pps_mip_enable_flag after parsing the data unit of the picture layer parameter set in the code stream.
[0148] Exemplarily, in this application, if the encoder writes the MIP mode parameter into the adaptive parameter set, the MIP mode parameter can be indicated by aps_mip_enable_flag, so the decoder can determine the MIP mode parameter aps_mip_enable_flag after parsing the data unit of the adaptive parameter set in the code stream.
[0149] Exemplarily, in this application, if the encoder writes the MIP mode parameter into the slice header information data unit, the MIP mode parameter can be indicated by slice_mip_enable_flag, so the decoder can determine the MIP mode parameter slice_mip_enable_flag after parsing the data unit of the slice header information data unit in the code stream.
[0150] Step 202: If the value of the MIP mode parameter indicates that the current block uses the MIP mode to determine the intra-frame prediction value of the current block, parse the code stream, determine the MIP mode of the current block, and determine the prediction values of the luminance component and chrominance component corresponding to the current block according to the MIP mode.
[0151] In an embodiment of the present application, after the decoder parses the bitstream and determines the MIP mode parameters of the current block, if the value of the MIP mode parameter indicates that the current block uses the MIP mode to determine the intra-frame prediction value of the current block, the decoder can continue to parse the bitstream, determine the MIP mode of the current block, and then determine the prediction values of the luminance component and chrominance component corresponding to the current block according to the MIP mode.
[0152] It can be understood that in the embodiment of the present application, after the decoder parses the code stream and determines the MIP mode parameter of the current block, if the value of the MIP mode parameter indicates that the MIP mode is not used to determine the intra-frame prediction value of the current block, the decoder will not use the MIP mode for the current block.
[0153] That is to say, in the present application, during the implementation process of decoding the current block, the decoder parses the code stream, and can not only obtain the MIP mode parameter indicating whether the current block uses the MIP mode, but also determine which mode the current block specifically uses for intra-frame prediction, for example, when using the MIP mode for intra-frame prediction, which MIP mode is specifically used.
[0154] Furthermore, in an embodiment of the present application, during the intra-frame prediction process of VVC, for any luma coding block, an optimal mode can be selected from the traditional mode and the MIP mode for encoding. The traditional mode includes 67 intra-frame prediction modes, including the Planar mode numbered 0, the DC mode numbered 1, and 65 angular modes.
[0155] It should be noted that in an embodiment of the present application, when the decoder uses the MIP mode to determine the intra-frame prediction value of the current block, it can further determine the MIP mode of the current block by parsing the code stream, and then determine the prediction values of the luminance component and chrominance component corresponding to the current block according to the MIP mode.
[0156] It can be understood that in the embodiment of the present application, when parsing the code stream and determining the MIP mode of the current block, the decoder can first obtain the MIP mode index number of the current block by parsing the code stream, and then, after determining the size type of the current block, determine the MIP mode indicated by the MIP mode index number from the candidate MIP mode list corresponding to the size type as the MIP mode of the current block.
[0157] Furthermore, in embodiments of the present application, the MIP mode index number of the current block can be used to indicate the specific MIP mode used for the current block. That is, on the encoding side, the encoder sets the MIP mode index number for the current block and writes it into the bitstream, which is then transmitted to the decoding side. The decoder parses the bitstream to obtain the MIP mode index number for the current block, and can then determine the MIP mode indicated by the MIP mode index number from the candidate MIP mode list for the current block.
[0158] It should be noted that, in an embodiment of the present application, when determining the MIP mode of the current block, the decoder may first determine the size type of the current block. Specifically, based on Table 2 above, when determining the size type of the current block, if the width and height of the current block are both equal to 4, that is, the size of the current block is 4×4, the size type of the current block may be set to the first type; if the width and height of the current block are both equal to 8, that is, the size of the current block is 8×8, or the width of the current block is equal to 8 and the height is equal to 4, that is, the size of the current block is 8×4, or the width of the current block is equal to 4 and the height is equal to 8, that is, the size of the current block is 4×8, the size type of the current block may be set to the second type; if the width and height of the current block do not meet the aforementioned conditions, that is, the size of the current block is not 4×4, 8×8, 8×4, or 4×8, the size type of the current block may be set to the third type.
[0159] Furthermore, in an embodiment of the present application, according to the size type division method proposed in the current standard, when the encoder determines the size type of the current block, if the width and height of the current block are both equal to 4, the size type of the current block can be set to the first type; if the width and height of the current block are both equal to 8, or one of the width and height of the current block is equal to 4, the size type of the current block can be set to the second type; if the width and height of the current block do not meet the aforementioned conditions, that is, the width and height of the current block are not equal to 4 or 8 at the same time, or the width and height of the current block are not equal to 4, the size type of the current block can be set to the third type.
[0160] It is understood that in the embodiments of the present application, for different size types, the decoder can construct different candidate MIP mode lists. Specifically, the MIP technology adds M MIP modes on top of the 67 traditional intra-frame prediction modes. The value of M is different for different size types. The value of M can include 16, 8, and 6.
[0161] Exemplarily, in the present application, when the size type of the current block is the first type, the value of M is 16, that is, a candidate MIP mode list can be constructed based on 16 MIP modes; when the size type of the current block is the second type, the value of M is 8, that is, a candidate MIP mode list can be constructed based on 8 MIP modes; when the size type of the current block is the third type, the value of M is 6, that is, a candidate MIP mode list can be constructed based on 6 MIP modes.
[0162] Exemplarily, in an embodiment of the present application, the decoder can first read the mode number k of the MIP mode from the candidate MIP mode list, so as to obtain the corresponding matrix Ak and offset bk, and perform matrix-vector multiplication according to the above formula (1), so as to obtain the brightness component prediction value corresponding to the current block.
[0163] Step 203: Decode the current block according to the predicted value.
[0164] In an embodiment of the present application, after the decoder parses the code stream to determine the MIP mode of the current block, and determines the predicted values of the luminance component and chrominance component corresponding to the current block according to the MIP mode, the decoder can decode the current block according to the predicted values of the luminance component and the chrominance component.
[0165] The embodiment of the present application proposes an image prediction method, in which the decoder parses the bitstream to determine the MIP mode parameters of the current block; if the value of the MIP mode parameter indicates that the current block uses the MIP mode to determine the intra-frame prediction value of the current block, the decoder parses the bitstream to determine the MIP mode of the current block, and determines the prediction values of the luminance component and chrominance component corresponding to the current block based on the MIP mode; and decodes the current block based on the prediction values. That is, in the embodiment of the present application, when the encoder performs intra-frame prediction on the current block, if it is determined that the current block uses the MIP mode, it can set the MIP mode parameters while using the MIP mode to obtain the intra-frame prediction value of the current block and write them into the bitstream for transmission to the decoding side; the decoder parses the bitstream to obtain the MIP mode parameters, and if the MIP mode parameters indicate that the current block uses the MIP mode, the decoder can use the MIP mode to determine the intra-frame prediction value of the current block. It can be seen that the image prediction method proposed in this application can use the syntax unit to indicate whether the current block uses the MIP mode in the bitstream, thereby simplifying the image prediction process. On the basis of ensuring the encoding and decoding performance, it can reduce the complexity, reduce the storage space and overall time required in the encoding and decoding process, and effectively improve the encoding and decoding efficiency.
[0166] Based on the above embodiments, another embodiment of the present application proposes an image prediction method, in which the decoder parses the code stream and obtains one or more syntax elements for indicating whether the current block uses the MIP mode to determine the prediction value of the current block. Furthermore, in the present application, the one or more syntax elements parsed and obtained by the decoder can indicate whether the MIP mode is used when decoding a video sequence, one or more pictures, slices, tiles or bricks. That is, in the present application, the VVC bitstream passes one or more syntax elements to enable or disable the MIP mode. The syntax elements may be located in data units in the video sequence layer, picture layer and / or sub-picture layer, slice / tile / brick layer, where a sub-picture refers to an area covering a portion of a picture.
[0167] For example, in the present application, the decoder can obtain the MIP mode parameters from the parameter set associated with all slices in the video sequence. Specifically, the decoder can obtain the MIP mode parameters from the SPS. An embodiment of the implementation of the syntax structure in the SPS is shown in Table 3 above, where u(1) represents the entropy decoding method that has been detailed in the VVC working draft.
[0168] When the decoder determines that the value of the MIP mode parameter sps_mip_enable_flag is equal to 0, the decoder will not use the MIP mode when decoding the slice related to the SPS (indirect); when the decoder determines that the value of the MIP mode parameter sps_mip_enable_flag is equal to 1, the decoder applies the MIP mode when decoding the slice related to the SPS (indirect).
[0169] That is, in this application, after parsing the sequence layer parameter set in the code stream, the decoder can determine the MIP mode parameter sps_mip_enable_flag, and then determine whether the current block uses the MIP mode for decoding processing according to the value of the MIP mode parameter sps_mip_enable_flag.
[0170] For example, in the present application, the decoder can obtain the MIP mode parameters from a parameter set associated with all slices in a picture or sub-picture in a video sequence. Specifically, the decoder can obtain the MIP mode parameters from the PPS. Table 4 shows an embodiment of the implementation of the syntax structure in the PPS, where u(1) represents the entropy decoding method that has been detailed in the VVC working draft.
[0171] When the decoder determines that the value of the MIP mode parameter pps_mip_enable_flag is equal to 0, the decoder will not use the MIP mode when decoding the slice associated with the PPS; when the decoder determines that the value of the MIP mode parameter pps_mip_enable_flag is equal to 1, the decoder applies the MIP mode when decoding the slice associated with the PPS.
[0172] That is, in this application, after parsing the picture layer parameter set in the code stream, the decoder can determine the MIP mode parameter pps_mip_enable_flag, and then determine whether the current block uses the MIP mode for decoding processing based on the value of the MIP mode parameter pps_mip_enable_flag.
[0173] For example, in the present application, the decoder can obtain the MIP mode parameters from a parameter set associated with all slices in a picture or sub-picture in a video sequence. Specifically, the decoder can obtain the MIP mode parameters from the APS. Table 5 shows an embodiment of the implementation of the syntax structure in the adaptive parameter set APS, where u(1) represents the entropy decoding method that has been detailed in the VVC working draft.
[0174] When the decoder determines that the value of the MIP mode parameter aps_mip_enable_flag is equal to 0, the decoder will not use the MIP mode when decoding the slice associated with the APS; when the decoder determines that the value of the MIP mode parameter aps_mip_enable_flag is equal to 1, the decoder applies the MIP mode when decoding the slice associated with the APS.
[0175] That is, in this application, after parsing the adaptive parameter set in the code stream, the decoder can determine the MIP mode parameter aps_mip_enable_flag, and then determine whether the current block uses the MIP mode for decoding processing based on the value of the MIP mode parameter aps_mip_enable_flag.
[0176] For example, in this application, the decoder can obtain the MIP mode parameters from the slice header. Table 6 shows an embodiment of the implementation of the syntax structure in the slice header, where u(1) represents the entropy decoding method that has been detailed in the VVC working draft.
[0177] When the decoder determines that the value of the MIP mode parameter slice_mip_enable_flag is equal to 0, the decoder will not use the MIP mode when decoding the slice; when the decoder determines that the value of the MIP mode parameter slice_mip_enable_flag is equal to 1, the decoder applies the MIP mode when decoding the slice.
[0178] That is, in this application, after parsing the slice header information data unit in the code stream, the decoder can determine the MIP mode parameter slice_mip_enable_flag, and then determine whether the current block uses the MIP mode for decoding processing based on the value of the MIP mode parameter slice_mip_enable_flag.
[0179] Exemplarily, in the present application, when decoding a tile or brick, the decoder may obtain similar MIP mode parameters as part of a parameter set for tile or brick segmentation of a picture or sub-picture, to indicate whether the tile or brick of the picture or sub-picture uses the MIP mode. Optionally, the decoder may also obtain similar MIP mode parameters from slice data associated with the tile or brick in the slice to indicate whether the MIP mode is used when encoding the tile or brick.
[0180] Exemplarily, in the present application, the decoder can obtain various MIP mode parameters from different data units in the input bitstream. The decoder can obtain sps_mip_enable_flag in the SPS equal to 1, pps_mip_enable_flag in the PPS or aps_mip_enable_flag in the APS associated with the slice in the picture or sub-picture equal to 1, and pps_mip_enable_flag in the PPS or aps_mip_enable_flag in the APS associated with other pictures or sub-pictures equal to 0. In this case, the decoder can apply the MIP mode when decoding a part of the pictures or sub-pictures in the input bitstream, while not applying the MIP mode when decoding other pictures or sub-pictures. Optionally, the decoder can obtain slice_mip_enable_flag (or similar MIP mode parameters for tiles or bricks in slice data) equal to 1 from the header of the slice in the picture or sub-picture, and the decoder can apply the MIP mode when decoding the slice. The decoder may also obtain slice_mip_enable_flag (or similar MIP mode parameter for a tile or brick in the slice data) equal to 0 from the slice header of another slice in the picture or sub-picture, and the decoder shall not apply MIP mode when decoding that slice.
[0181] For example, in the present application, the decoder can be implicitly informed of whether the MIP mode is used for decoding the input bitstream from other syntax elements (e.g., syntax elements indicating PTLs in one or more parameter sets of a bitstream or sub-bitstream). For example, the MIP mode is set to disabled when decoding in one or more PTLs, and is set to enabled when decoding in other PTLs.
[0182] The embodiment of the present application proposes an image prediction method, in which the decoder parses the bitstream to determine the MIP mode parameters of the current block; if the value of the MIP mode parameter indicates that the current block uses the MIP mode to determine the intra-frame prediction value of the current block, the decoder parses the bitstream to determine the MIP mode of the current block, and determines the prediction values of the luminance component and chrominance component corresponding to the current block based on the MIP mode; and decodes the current block based on the prediction values. That is, in the embodiment of the present application, when the encoder performs intra-frame prediction on the current block, if it is determined that the current block uses the MIP mode, it can set the MIP mode parameters while using the MIP mode to obtain the intra-frame prediction value of the current block and write them into the bitstream for transmission to the decoding side; the decoder parses the bitstream to obtain the MIP mode parameters, and if the MIP mode parameters indicate that the current block uses the MIP mode, the decoder can use the MIP mode to determine the intra-frame prediction value of the current block. It can be seen that the image prediction method proposed in this application can use the syntax unit to indicate whether the current block uses the MIP mode in the bitstream, thereby simplifying the image prediction process. On the basis of ensuring the encoding and decoding performance, it can reduce the complexity, reduce the storage space and overall time required in the encoding and decoding process, and effectively improve the encoding and decoding efficiency.
[0183] Based on the above embodiments, in yet another embodiment of the present application, the implementation of the encoder and decoder described in the above embodiments may be used to feasibly configure the MIP mode, for example, during a session negotiation process.
[0184] Exemplarily, in the first exemplary system, a transmitter including an encoder generates a bitstream for a receiver based on the processing capability of the receiver. For example, during session negotiation, when the transmitter determines that the receiver cannot successfully enable the MIP mode to process the bitstream (or when the receiver notifies the transmitter that the receiver cannot successfully enable the MIP mode to decode the bitstream), the transmitter generates the bitstream by disabling the MIP mode, for example, by setting sps_mip_enable_flag to 0.
[0185] Exemplarily, a second exemplary system includes a transmitter that stores a plurality of bitstreams in which a MIP mode is applied when decoding the entire bitstream or different portions thereof. During session negotiation, when the transmitter determines that the receiver cannot successfully enable the MIP mode to process the bitstream (or when the receiver notifies the transmitter that the receiver cannot successfully enable the MIP mode to decode the bitstream), the transmitter selects to transmit a bitstream in which the MIP mode is disabled, for example, a bitstream in which the sps_mip_enable_flag is equal to 0.
[0186] The third exemplary system is, for example, a real-time communication system, such as a video conference, video phone, or live video streaming. Unlike the first exemplary system, the receiver is not always unable to process a bitstream encoded using the MIP mode. For example, the receiver may have a battery. When the energy in the battery falls below a threshold (e.g., 20% of the total charge), the receiver notifies the transmitter that it cannot process a bitstream encoded using the MIP mode due to the low energy. Upon receiving a request from the receiver, the transmitter generates a bitstream by disabling the MIP mode, for example, by starting a new coded video sequence (CVS) with a new SPS containing sps_mip_enable_flag equal to 0, or by generating a new PPS or APS containing a MIP enable flag (MIP mode parameter) equal to 0, or by setting the MIP enable flag in a slice header (or other similar syntax element for a tile or brick) to 0. When the receiver's battery is charged, the receiver may notify the transmitter that the receiver is capable of processing a bitstream encoded using the MIP mode. In this case, the transmitter can generate the bitstream using MIP mode and set the corresponding flag in the SPS, PPS, APS or slice header. Alternatively, the transmitter can switch between different tracks containing different bitstreams generated by different MIP mode configurations to meet the requirements from the receiver.
[0187] The embodiment of the present application proposes an image prediction method. When the encoder performs intra-frame prediction on the current block, if it determines that the current block uses the MIP mode, it can set the MIP mode parameters and write them into the code stream for transmission to the decoding side while using the MIP mode to obtain the intra-frame prediction value of the current block; the decoder parses the code stream to obtain the MIP mode parameters. If the MIP mode parameters indicate that the current block uses the MIP mode, the decoder can use the MIP mode to determine the intra-frame prediction value of the current block. It can be seen that the image prediction method proposed in the present application can use the syntax unit to indicate whether the current block uses the MIP mode in the code stream, thereby simplifying the image prediction process, and can reduce the complexity while ensuring the encoding and decoding performance, reduce the storage space and overall time required in the encoding and decoding process, and effectively improve the encoding and decoding efficiency.
[0188] Based on the above embodiment, in another embodiment of the present application, Figure 9 Schematic diagram of the structure of the encoder proposed in this embodiment Figure 1 ,like Figure 9 As shown, the encoder 300 proposed in the embodiment of the present application may include a setting part 301, a first determining part 302 and an encoding part 303.
[0189] The setting part 301 is configured to set the value of the MIP mode parameter to indicate the use of the MIP mode and write it into the bitstream if the current block uses the MIP mode to determine the intra-frame prediction value of the current block;
[0190] The first determining part 302 is configured to determine a MIP mode of the current block, and determine predicted values of the luminance component and the chrominance component corresponding to the current block according to the MIP mode;
[0191] The encoding part 303 is configured to write the MIP mode of the current block into the bitstream.
[0192] Furthermore, in an embodiment of the present application, the setting part 301 is also configured to set the value of the MIP mode parameter to indicate that the MIP mode is not used and write it into the code stream if the current block does not use the MIP mode to determine the intra-frame prediction value of the current block.
[0193] Furthermore, in an embodiment of the present application, the MIP mode parameter is indicated in the code stream using one or more syntax units.
[0194] Furthermore, in an embodiment of the present application, the syntax unit is included in one or more data units in the following code stream: a data unit containing the current block, a slice header information data unit, an image header information data unit, an image layer parameter set, a sequence layer parameter set, and an adaptation parameter set.
[0195] Furthermore, in an embodiment of the present application, the first determining part 302 is specifically configured to determine the size type of the current block; construct the candidate MIP mode list based on the size type; and determine the MIP mode of the current block from the candidate MIP mode list.
[0196] Furthermore, in an embodiment of the present application, the first determining part 302 is further specifically configured to, when the size type of the current block is the first type, construct the candidate MIP mode list according to 16 MIP modes; when the size type of the current block is the second type, construct the candidate MIP mode list according to 8 MIP modes; and when the size type of the current block is the third type, construct the candidate MIP mode list according to 6 MIP modes.
[0197] Furthermore, in an embodiment of the present application, the first determining part 302 is further specifically configured to, when the width and height of the current block are both equal to 4, set the size type of the current block to the first type; when the width and height of the current block are both equal to 8, or the width of the current block is equal to 8 and the height is equal to 4, or the width of the current block is equal to 4 and the height is equal to 8, set the size type of the current block to the second type; when the width and height of the current block do not meet the aforementioned conditions, set the size type of the current block to the third type.
[0198] Furthermore, in an embodiment of the present application, the first determining part 302 is further specifically configured to, when the width and height of the current block are both equal to 4, set the size type of the current block to the first type; when the width and height of the current block are both equal to 8, or one of the width and height of the current block is equal to 4, set the size type of the current block to the second type; when the width and height of the current block do not meet the aforementioned conditions, set the size type of the current block to the third type.
[0199] Figure 10 Schematic diagram of the structure of the encoder proposed in this embodiment Figure 2 ,like Figure 10 As shown, the encoder 300 proposed in the embodiment of the present application may also include a first processor 304, a first memory 305 storing executable instructions of the first processor 304, a first communication interface 306, and a first bus 307 for connecting the first processor 304, the first memory 305 and the first communication interface 306.
[0200] Furthermore, in an embodiment of the present application, the first processor 304 is configured to, if the current block uses a MIP mode to determine an intra-frame prediction value of the current block, set a value of a MIP mode parameter to indicate the use of the MIP mode and write the parameter into the bitstream; determine the MIP mode of the current block, and determine, based on the MIP mode, prediction values of the luminance component and the chrominance component corresponding to the current block; and write the MIP mode of the current block into the bitstream.
[0201] In addition, the functional modules in this embodiment may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated units may be implemented in the form of hardware or software functional modules.
[0202] If the integrated unit is implemented in the form of a software functional module and is not sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this embodiment, or the part that contributes to the existing technology, or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes a number of instructions for causing a computer device (which can be a personal computer, server, or network device, etc.) or a processor to execute all or part of the steps of the method of this embodiment. The aforementioned storage medium includes: a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk, etc., various media that can store program code.
[0203] An embodiment of the present application provides an image encoder. If a current block uses a MIP mode to determine an intra-frame prediction value for the current block, the encoder sets the value of a MIP mode parameter to indicate the use of the MIP mode and writes it into a bitstream. The encoder determines the MIP mode of the current block and, based on the MIP mode, determines prediction values for the luminance and chrominance components corresponding to the current block. The decoder then parses the bitstream to determine the MIP mode parameter for the current block. If the value of the MIP mode parameter indicates that the current block uses the MIP mode to determine an intra-frame prediction value for the current block, the decoder parses the bitstream to determine the MIP mode for the current block and, based on the MIP mode, determines prediction values for the luminance and chrominance components corresponding to the current block. The decoder then decodes the current block based on the prediction values. That is to say, in an embodiment of the present application, when the encoder performs intra-frame prediction on the current block, if it determines that the current block uses the MIP mode, it can set the MIP mode parameters and write them into the code stream for transmission to the decoding side while using the MIP mode to obtain the intra-frame prediction value of the current block; the decoder parses the code stream to obtain the MIP mode parameters. If the MIP mode parameters indicate that the current block uses the MIP mode, the decoder can use the MIP mode to determine the intra-frame prediction value of the current block. It can be seen that the image prediction method proposed in this application can use the syntax unit to indicate whether the current block uses the MIP mode in the code stream, thereby simplifying the image prediction process, and can reduce the complexity while ensuring the encoding and decoding performance, reduce the storage space and overall time required in the encoding and decoding process, and effectively improve the encoding and decoding efficiency.
[0204] Based on the above embodiment, in another embodiment of the present application, Figure 11 Schematic diagram of the structure of the decoder proposed in this embodiment of the application Figure 1 ,like Figure 11As shown, the decoder 400 proposed in the embodiment of the present application may include a decoding part 401, a second determining part 402,
[0205] The decoding part 401 is configured to parse the code stream and determine the MIP mode parameter of the current block; and if the value of the MIP mode parameter indicates that the current block uses the MIP mode to determine the intra-frame prediction value of the current block, parse the code stream and determine the MIP mode of the current block;
[0206] The second determining part 402 is configured to determine the predicted values of the luminance component and the chrominance component corresponding to the current block according to the MIP mode;
[0207] The decoding part 401 is further configured to decode the current block according to the prediction value.
[0208] Furthermore, in an embodiment of the present application, the second determination part 402 is further configured to parse the code stream and, after determining the MIP mode parameter of the current block, determine that the current block does not use the MIP mode if the value of the MIP mode parameter indicates that the current block does not use the MIP mode to determine the intra-frame prediction value of the current block.
[0209] Furthermore, in an embodiment of the present application, the MIP mode parameter is indicated in the code stream using one or more syntax units.
[0210] Furthermore, in an embodiment of the present application, the syntax unit is included in one or more data units in the following code stream: a data unit containing the current block, a slice header information data unit, an image header information data unit, an image layer parameter set, a sequence layer parameter set, and an adaptation parameter set.
[0211] Furthermore, in an embodiment of the present application, the decoding part 401 is specifically configured to parse the code stream to obtain the MIP mode index number of the current block; determine the size type of the current block; and determine the MIP mode indicated by the MIP mode index number as the MIP mode of the current block from a list of candidate MIP modes corresponding to the size type.
[0212] Furthermore, in an embodiment of the present application, when the size type of the current block is the first type, the candidate MIP mode list is constructed according to 16 MIP modes; when the size type of the current block is the second type, the candidate MIP mode list is constructed according to 8 MIP modes; when the size type of the current block is the third type, the candidate MIP mode list is constructed according to 6 MIP modes.
[0213] Furthermore, in an embodiment of the present application, the decoding part 401 is further specifically configured to, when the width and height of the current block are both equal to 4, set the size type of the current block to the first type; when the width and height of the current block are both equal to 8, or the width of the current block is equal to 8 and the height is equal to 4, or the width of the current block is equal to 4 and the height is equal to 8, set the size type of the current block to the second type; when the width and height of the current block do not meet the aforementioned conditions, set the size type of the current block to the third type.
[0214] Furthermore, in an embodiment of the present application, the decoding part 401 is further specifically configured to, when the width and height of the current block are both equal to 4, set the size type of the current block to the first type; when the width and height of the current block are both equal to 8, or one of the width and height of the current block is equal to 4, set the size type of the current block to the second type; when the width and height of the current block do not meet the aforementioned conditions, set the size type of the current block to the third type.
[0215] Figure 12 Schematic diagram of the structure of the decoder proposed in this embodiment of the application Figure 2 ,like Figure 12 As shown, the decoder 400 proposed in the embodiment of the present application may also include a second processor 403, a second memory 404 storing executable instructions of the second processor 403, a second communication interface 405, and a second bus 406 for connecting the second processor 403, the second memory 404 and the second communication interface 405.
[0216] Furthermore, in an embodiment of the present application, the second processor 403 is configured to parse the bitstream and determine a MIP mode parameter of the current block; if the value of the MIP mode parameter indicates that the current block uses the MIP mode to determine the intra-frame prediction value of the current block, parse the bitstream to determine the MIP mode of the current block, and determine the prediction values of the luminance component and the chrominance component corresponding to the current block according to the MIP mode; and decode the current block according to the prediction values.
[0217] In addition, the functional modules in this embodiment may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated units may be implemented in the form of hardware or software functional modules.
[0218] If the integrated unit is implemented in the form of a software functional module and is not sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this embodiment, or the part that contributes to the existing technology, or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes a number of instructions for causing a computer device (which can be a personal computer, server, or network device, etc.) or a processor to execute all or part of the steps of the method of this embodiment. The aforementioned storage medium includes various media that can store program code, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.
[0219] An embodiment of the present application provides an image decoder that parses a bitstream to determine a MIP mode parameter for a current block; if the value of the MIP mode parameter indicates that the current block uses the MIP mode to determine an intra-frame prediction value for the current block, the decoder parses the bitstream to determine the MIP mode for the current block, and determines the prediction values of the luminance component and chrominance component corresponding to the current block based on the MIP mode; and decodes the current block based on the prediction values. That is, in an embodiment of the present application, when the encoder performs intra-frame prediction on the current block, if it is determined that the current block uses the MIP mode, the MIP mode parameter can be set and written into the bitstream for transmission to the decoding side while using the MIP mode to obtain the intra-frame prediction value for the current block; the decoder parses the bitstream to obtain the MIP mode parameter, and if the MIP mode parameter indicates that the current block uses the MIP mode, the decoder can use the MIP mode to determine the intra-frame prediction value for the current block. It can be seen that the image prediction method proposed in this application can use the syntax unit to indicate whether the current block uses the MIP mode in the bitstream, thereby simplifying the image prediction process. On the basis of ensuring the encoding and decoding performance, it can reduce the complexity, reduce the storage space and overall time required in the encoding and decoding process, and effectively improve the encoding and decoding efficiency.
[0220] An embodiment of the present application provides a computer-readable storage medium having a program stored thereon. When the program is executed by a processor, the method described in the above embodiment is implemented.
[0221] Specifically, the program instructions corresponding to an image prediction method in this embodiment may be stored on a storage medium such as an optical disk, a hard disk, or a USB flash drive. When the program instructions corresponding to an image prediction method in the storage medium are read or executed by an electronic device, the following steps are included:
[0222] If the current block uses the MIP mode to determine the intra prediction value of the current block, the value of the MIP mode parameter is set to indicate the use of the MIP mode and written into the bitstream;
[0223] Determining a MIP mode of the current block, and determining predicted values of a luminance component and a chrominance component corresponding to the current block according to the MIP mode;
[0224] The MIP mode of the current block is written into the code stream.
[0225] Specifically, the program instructions corresponding to an image prediction method in this embodiment may be stored on a storage medium such as an optical disk, a hard disk, or a USB flash drive. When the program instructions corresponding to an image prediction method in the storage medium are read or executed by an electronic device, the following steps are also included:
[0226] Parse the code stream and determine the MIP mode parameters of the current block;
[0227] If the value of the MIP mode parameter indicates that the current block uses the MIP mode to determine the intra prediction value of the current block, parsing the code stream, determining the MIP mode of the current block, and determining the prediction values of the luminance component and the chrominance component corresponding to the current block according to the MIP mode;
[0228] The current block is decoded according to the prediction value.
[0229] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of hardware embodiments, software embodiments, or embodiments combining software and hardware. Furthermore, the present application may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage and optical storage, etc.) containing computer-usable program code.
[0230] The present application is described with reference to the implementation flow charts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flow charts and / or block diagrams, as well as the combination of processes and / or boxes in the flow charts and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the steps in the implementation flow charts. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0231] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which is implemented in the implementation flow diagram. Figure 1 a process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.
[0232] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process described in the flowchart. Figure 1 a process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.
[0233] The above description is merely a preferred embodiment of the present application and is not intended to limit the scope of protection of the present application.
[0234] Industrial Applicability
[0235] The embodiments of the present application provide an image prediction method, an encoder, a decoder, and a storage medium. If a current block uses a MIP mode to determine an intra-frame prediction value for the current block, the encoder sets the value of a MIP mode parameter to indicate the use of the MIP mode and writes it into a bitstream. The encoder determines the MIP mode for the current block and, based on the MIP mode, determines prediction values for the luminance and chrominance components corresponding to the current block. The decoder parses the bitstream and determines the MIP mode parameter for the current block. If the value of the MIP mode parameter indicates that the current block uses the MIP mode to determine an intra-frame prediction value for the current block, the decoder parses the bitstream, determines the MIP mode for the current block, and, based on the MIP mode, determines prediction values for the luminance and chrominance components corresponding to the current block. The decoder then decodes the current block based on the prediction values. That is to say, in an embodiment of the present application, when the encoder performs intra-frame prediction on the current block, if it determines that the current block uses the MIP mode, it can set the MIP mode parameters and write them into the code stream for transmission to the decoding side while using the MIP mode to obtain the intra-frame prediction value of the current block; the decoder parses the code stream to obtain the MIP mode parameters. If the MIP mode parameters indicate that the current block uses the MIP mode, the decoder can use the MIP mode to determine the intra-frame prediction value of the current block. It can be seen that the image prediction method proposed in this application can use the syntax unit to indicate whether the current block uses the MIP mode in the code stream, thereby simplifying the image prediction process, and can reduce the complexity while ensuring the encoding and decoding performance, reduce the storage space and overall time required in the encoding and decoding process, and effectively improve the encoding and decoding efficiency.
Claims
1. An image prediction method, applied to an encoder, the method comprising: If the current block uses a matrix-based intra prediction MIP to determine a predicted value of a luminance component of the current block, the value of the MIP parameter is set to indicate the use of the MIP and written into the bitstream; Determine the MIP mode of the current block, and determine the predicted value of the luminance component of the current block according to the MIP mode; wherein the determining the MIP mode of the current block includes: Determine the size type of the current block; constructing a candidate MIP mode list based on the size type; Determine the MIP mode of the current block from the candidate MIP mode list; Writing the MIP mode of the current block into a bitstream; If the current block does not use MIP to determine the predicted value of the brightness component of the current block, the value of the MIP parameter is set to indicate that MIP is not used and written into the bitstream.
2. The method according to claim 1, wherein: The method further comprises: indicating the MIP parameters in the bitstream using one or more syntax units, The syntax unit is included in one or more data units in the following code stream: a data unit including the current block, a slice header information data unit, an image header information data unit, an image layer parameter set, a sequence layer parameter set and an adaptive parameter set.
3. The method according to claim 1, wherein: The constructing the candidate MIP mode list based on the size type comprises: When the width and height of the current block are both equal to 4, the size type of the current block is the first type, and the candidate MIP mode list is constructed according to 16 MIP modes; When the width and height of the current block are both equal to 8, or one of the width and height of the current block is equal to 4, the size type of the current block is the second type, and the candidate MIP mode list is constructed according to 8 MIP modes; When the width and height of the current block do not satisfy the aforementioned conditions, the size type of the current block is the third type, and the candidate MIP mode list is constructed according to 6 MIP modes.
4. An image prediction method, applied to a decoder, the method comprising: Parse the bitstream and determine the MIP parameters of the current block; If the value of the MIP parameter indicates that the current block uses MIP to determine the predicted value of the brightness component of the current block, determine the MIP mode of the current block, and determine the predicted value of the brightness component of the current block according to the MIP mode; wherein determining the MIP mode of the current block includes: Parsing the bitstream to obtain the MIP mode index number of the current block; Determine the size type of the current block; Determine, from the candidate MIP mode list corresponding to the size type, the MIP mode indicated by the MIP mode index sequence number as the MIP mode of the current block; If the value of the MIP parameter indicates that the current block does not use the MIP to determine the predicted value of the luminance component of the current block, it is determined that the current block does not use the MIP.
5. The method according to claim 4, wherein: The method further comprises: Indicating the MIP parameters in the bitstream using one or more syntax units, The syntax unit is included in one or more data units in the following code stream: a data unit including the current block, a slice header information data unit, an image header information data unit, an image layer parameter set, a sequence layer parameter set and an adaptive parameter set.
6. The method according to claim 4, wherein: The method further comprises: When the width and height of the current block are both equal to 4, the size type of the current block is the first type, and the corresponding candidate MIP mode list includes 16 MIP modes; When the width and height of the current block are both equal to 8, or one of the width and height of the current block is equal to 4, the size type of the current block is the second type, and the corresponding candidate MIP mode list includes 8 MIP modes; When the width and height of the current block do not satisfy the aforementioned conditions, the size type of the current block is the third type, and the corresponding candidate MIP mode list includes 6 MIP modes.
7. An encoder, comprising a first processor and a first memory storing instructions executable by the first processor, wherein when the instructions are executed by the first processor, the method according to any one of claims 1 to 3 is implemented.
8. A decoder, comprising a second processor and a second memory storing instructions executable by the second processor, wherein when the instructions are executed by the second processor, the method according to any one of claims 4 to 6 is implemented.
9. A computer storage medium, wherein: The computer storage medium stores a computer program, and when the computer program is executed by the first processor, the method according to any one of claims 1 to 3 is implemented.
10. A computer storage medium, wherein: The computer storage medium stores a computer program, and when the computer program is executed by the second processor, the method according to any one of claims 4 to 6 is implemented.
Citation Information
Patent Citations
Video encoding / decoding method and apparatus, and recording medium in which bit stream is stored
CN109891883A