Encoding and decoding method, device, encoding device, decoding device, and storage medium

By calculating and applying weighting coefficients for color component prediction in the H.266/VVC standard, the method addresses prediction accuracy issues, leading to improved video quality and coding efficiency.

JP2025512013APending Publication Date: 2025-04-16GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
JP2024559951
Authority / Receiving Office
JP · JP
Patent Type
Applications
Current Assignee / Owner
Filing Date
2022-04-12
Publication Date
2025-04-16

AI Technical Summary

Technical Problem

The H.266/VVC video coding standard faces challenges in prediction accuracy due to significant differences between predicted and original values of color components, leading to reduced decoding video quality and coding performance.

Method used

The proposed solution involves calculating a weighting coefficient for pixels waiting for prediction in a current block, using this coefficient for color component prediction, and transmitting the first control parameter in the bitstream to improve prediction accuracy and reliability.

Benefits of technology

This approach enhances prediction accuracy, reduces bit rates, and improves codec performance by ensuring more reliable weighting coefficients and accurate color component prediction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 2025512013000001_ABST
    Figure 2025512013000001_ABST
Patent Text Reader

Abstract

The present invention discloses an encoding and decoding method, an apparatus, an encoding device, a decoding device and a storage medium, the decoding method includes the steps of: decoding a bitstream, determining a first control parameter of a current block, determining a reference sample value of a first color component of the current block, determining a weighting factor based on the reference sample value of the first color component of the current block and the first control parameter, determining a predicted value of a second color component of the current block based on the weighting factor and the reference sample value of the second color component of the current block, and determining a reconstruction value of a sampling point of the second color component of the current block based on the predicted value of the second color component of the current block. In this way, by transmitting the first control parameter of the current block in the bitstream and using the first control parameter to realize the calculation of a weighting factor corresponding to a pixel to be predicted in the current block, and applying the weighting factor to the color component prediction of a pixel to be predicted in the current block, the prediction accuracy can be improved, the bit rate can be saved, and the codec performance can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

[Technical field]

[0001] The present application relates to the technical field of video codec, and in particular to an encoding and decoding method, apparatus, encoding device, decoding device and storage medium. [Background technology]

[0002] As the quality requirements for video display increase, new forms of video applications such as high definition and ultra high definition are emerging. The Joint Video Exploration Team (JVET) of the international standardization organizations ISO / IEC and ITU-T has established the next-generation video coding standard H.266 / VVC (Versatile Video Coding).

[0003] H.266 / VVC includes a prediction technique between color components. However, there is a large difference between the predicted value of the block to be coded calculated by the prediction technique between color components of H.266 / VVC and the original value, which reduces the prediction accuracy, degrades the decoded video quality, and reduces the coding performance. Summary of the Invention

[0004] To solve the above technical problems, embodiments of the present invention provide an encoding and decoding method, apparatus, encoding device, decoding device and storage medium.

[0005] In a first aspect, embodiments of the present invention provide a method of encoding, the method comprising: decoding the bitstream and determining a first control parameter for a current block; determining a reference sample value of a first color component of the current block; determining a weighting coefficient based on a reference sample value of a first color component of the current block and the first control parameter; determining a predicted value of a second color component of the current block according to the weighting coefficient and a reference sample value of the second color component of the current block; determining a reconstruction value of a sampling point of the second color component of the current block based on the predicted value of the second color component of the current block.

[0006] In a second aspect, embodiments of the present invention provide a method of encoding, the method comprising: determining a candidate first control parameter for a current block; determining a reference sample value of a first color component of the current block; determining a weighting coefficient based on a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter; determining a predicted value of a second color component of the current block according to the weighting coefficient and a reference sample value of the second color component of the current block; determining a reference value of a prediction difference of the second color component of the current block according to the predicted value and the original value of the second color component of the current block; determining a first control parameter of the current block according to a reference value of a prediction difference of a second color component of the current block; encoding the first control parameter of the current block and writing the resulting encoded bits into a bitstream.

[0007] In a third aspect, embodiments of the present invention provide an encoding device, the encoding device comprising: a first determining unit configured to determine a candidate first control parameter for the current block; a first calculation unit configured to determine a reference sample value of a first color component of the current block, and to determine a weighting factor based on the reference sample value of the first color component of the current block and a candidate value among the candidate first control parameters; a first prediction unit configured to determine a predicted value of a second color component of the current block according to the weighting coefficients and a reference sample value of a second color component of the current block, determine a reference value of a prediction difference of the second color component of the current block according to the predicted value and an original value of the second color component of the current block, and determine a first control parameter of the current block according to the reference value of the prediction difference of the second color component of the current block; an encoding unit configured to encode the first control parameter of the current block and to write the resulting encoded bits into a bitstream.

[0008] In a fourth aspect, an embodiment of the present invention provides a decoding device, comprising: a decoding unit configured to decode the bitstream and determine a first control parameter for a current block; a second calculation unit configured to determine a reference sample value of a first color component of the current block, and to determine a weighting factor based on the reference sample value of the first color component of the current block and the first control parameter; a second prediction unit configured to determine a predicted value of the second color component of the current block based on the weighting coefficients and reference sample values ​​of the second color component of the current block, and to determine a reconstructed value of a sampling point of the second color component of the current block based on the predicted value of the second color component of the current block.

[0009] In a fifth aspect, an embodiment of the present application further provides an encoding device, the encoding device comprising a first memory and a first processor, the first memory storing a computer program executable by the first processor, the first processor realizing an encoding method of an encoder when executing the program.

[0010] In a sixth aspect, an embodiment of the present application further provides a decoding device, the decoding device comprising a second memory and a second processor, the second memory storing a computer program executable by the second processor, the second processor realizing a decoding method of the decoder when executing the program.

[0011] In a seventh aspect, an embodiment of the present application provides a computer-readable storage medium, the computer-readable storage medium storing a computer program, the computer program, when executed by a first processor, realizing the encoding method of an encoder, or the computer program, when executed by a second processor, realizing the decoding method of a decoder.

[0012] According to the above technical solution, both the encoding side and the decoding side calculate the weighting coefficients corresponding to the pixels in the current block to be predicted, and apply the weighting coefficients to the color component prediction of the pixels in the current block to be predicted, thereby improving the accuracy of prediction, saving the bit rate, and improving the codec performance. In addition, the encoding side transmits the first control parameter to the decoding side in the bitstream, thereby improving the reliability of the weighting coefficients and further improving the accuracy of the color component prediction to a certain extent. [Brief description of the drawings]

[0013] [Figure 1] FIG. 13 is a schematic diagram showing the distribution of reference regions. [Diagram 2] 1 is a flowchart of a model parameter derivation method. [Diagram 3] FIG. 2 is a block diagram showing a configuration of an encoder according to an embodiment of the present application. [Figure 4] FIG. 2 is a block diagram showing the configuration of a decoder according to an embodiment of the present application. [Figure 5(a)] 2 is a flow chart of a decoding method according to an embodiment of the present application; [Figure 5(b)] 4 is a flowchart of a weight-based chromaticity prediction method according to an embodiment of the present application. [Figure 6] FIG. 2 is a schematic diagram of a softmax curve according to an embodiment of the present application. [Figure 7] FIG. 2 is a schematic diagram showing the distribution of reference areas for three WCP modes according to an embodiment of the present application. [Figure 8] 1 is a flow chart 1 of an encoding method according to an embodiment of the present application; [Figure 9] 2 is a flowchart 2 of the encoding method in the embodiment of the present application. [Figure 10] 3 is a flowchart 3 of the encoding method in the embodiment of the present application. [Figure 11] 4 is a flowchart 4 of the encoding method in the embodiment of the present application. [Figure 12] 5 is a flow chart 5 of an encoding method in an embodiment of the present application. [Figure 13] 6 is a flow chart 6 of an encoding method in an embodiment of the present application. [Figure 14] FIG. 1 is a schematic diagram illustrating a configuration of an encoding device according to an embodiment of the present application. [Figure 15] FIG. 2 is a schematic diagram showing a specific hardware configuration of an encoding device according to an embodiment of the present application. [Figure 16] FIG. 2 is a schematic diagram showing the configuration of a decoding device according to an embodiment of the present application. [Figure 17] FIG. 2 is a schematic diagram showing a specific hardware configuration of a decoding device according to an embodiment of the present application. [Figure 18] 1 is a schematic diagram showing a configuration of a codec system according to an embodiment of the present application; DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS

[0014] In order to more fully understand the features and technical contents of the embodiments of the present invention, the implementation of the embodiments of the present invention will be described in detail below with reference to the drawings, and the accompanying drawings are for reference purposes only and are not intended to limit the embodiments of the present invention.

[0015] Unless otherwise specified, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the art of this application. The terms used herein are only used to describe the embodiments of this application and are not intended to limit the present application.

[0016] In the following, the statement "some embodiments" describes a subset of all possible embodiments, but it is understood that "some embodiments" may be the same or different subsets of all possible embodiments and may be combined with each other without inconsistency. It is further to be explained that the terms "first / second / third" and the like in the embodiments of the present application do not limit a particular order, but distinguish between similar objects. It is to be understood that "first / second / third" can be converted to a particular order or order when appropriate, so that the embodiments of the present application described herein can be performed in an order other than that shown or described herein.

[0017] In video images, the color space can be represented in YUV format, YCbCr format, RGB format, or YCgCo format. Usually, a first color component, a second color component, and a third color component are adopted to represent a coding block (CB). Here, the three color components are a luminance component, a blue chrominance component, and a red chrominance component, respectively. Take the video image represented in YCbCr format or YUV format as an example, the luminance component is usually represented by the symbol Y, the blue chrominance component is usually represented by the symbol Cb or U, and the red chrominance component is usually represented by the symbol Cr or V.

[0018] It can be understood that in current video image or video codec processes, the cross-component prediction techniques mainly include a cross-component linear model (CCLM) prediction mode and a multi-directional linear model (MDLM) prediction mode, and whether the model parameters are derived based on the CCLM prediction mode or the MDLM prediction mode, the corresponding prediction models can realize prediction between color components, such as from the first color component to the second color component, from the second color component to the first color component, from the first color component to the third color component, from the third color component to the first color component, from the second color component to the third color component, or from the third color component to the second color component.

[0019] Taking the prediction from the first color component to the second color component as an example, assuming that the first color component is a luminance component and the second color component is a chrominance component, in order to reduce the redundancy between the luminance component and the chrominance component, VVC uses CCLM prediction mode, i.e., Pred C (i,j) = α × Rec L We construct a prediction of chrominance based on the luma reconstruction of the same coded block, such as (i,j)+β.

[0020] Here, (i,j) represents the position coordinates of a pixel to be predicted in a coding block, i represents the horizontal direction, j represents the vertical direction, and Pred C (i,j) represents the chromaticity prediction value corresponding to the pixel awaiting prediction at the position coordinates (i,j) in the coding block, and Rec L (i,j) represents the luminance reconstruction value corresponding to the pixel to be predicted at (downsampled) position coordinates (i,j) in the same coding block, and α and β are linear model parameters that can be derived by reference pixels.

[0021] For a coding block, the reference region of the current block can be divided into five parts: a left adjacent region, an upper adjacent region, a lower left adjacent region, an upper left adjacent region, and an upper right adjacent region. H.266 / VVC includes three cross-component linear model prediction modes, which are a left and upper adjacent intra CCLM prediction mode (which can be represented by INTRA_LT_CCLM), a left and lower left adjacent intra CCLM prediction mode (which can be represented by INTRA_L_CCLM), and an upper and upper right adjacent intra CCLM prediction mode (which can be represented by INTRA_T_CCLM). In these three prediction modes, each prediction mode can select a predetermined number (for example, four) of reference pixels to derive the model parameters α and β, and the biggest difference between these three prediction modes is that the selection regions corresponding to the reference pixels for deriving the model parameters α and β are different.

[0022] Referring to Fig. 1, Fig. 1 is a schematic diagram showing the distribution of reference regions. In Fig. 1, the upper region, the upper left region, and the left region of a current block (also called a coding block or a decoding block) are called reference regions, and the pixels in the reference regions are all reconstructed reference pixels, and the blocks filled in gray are pixels awaiting prediction whose position coordinates in the coding block are (i, j).

[0023] After obtaining the predetermined number of reference pixels, chromaticity prediction is now performed according to the flow chart of the model parameter derivation method shown in Figure 2. According to the process shown in Figure 2, assuming that the predetermined number is four, the process may include the following steps:

[0024] In S201, reference pixels are obtained in the selected area.

[0025] In S202, the number of valid reference pixels is determined.

[0026] In S203, if the number of valid reference pixels is 0, the model parameters α and β are set to default values.

[0027] In S204, a default value is input to the chromaticity prediction value.

[0028] In S205, if the number of valid reference pixels is four, two reference pixels with larger luminance component values ​​and two reference pixels with smaller luminance component values ​​are obtained by comparison.

[0029] In S206, the average score corresponding to the large value and the average score corresponding to the small value are calculated.

[0030] In S207, model parameters α and β are derived from the two average points.

[0031] In S208, chromaticity prediction is performed using the prediction model constructed by α and β.

[0032] It should be noted that in VVC, the step of valid reference pixels being 0 is determined based on the validity of the neighboring regions.

[0033] It should be further explained that the principle of "determining one line by two points" is used to construct the prediction model, where the two points can be called fitting points. In the current technical solution, after obtaining the four reference pixels, two reference pixels with large values ​​and two reference pixels with small values ​​of the luminance component are obtained by comparison, and then one mean point is calculated based on the two reference pixels with large values. max Then, another mean point is calculated based on the two reference pixels with the smallest values. min (which can be expressed as max and mean min Furthermore, we can obtain the mean max and mean min As two fitting points, model parameters (represented by α and β) can be derived. Finally, a prediction model is constructed based on α and β, and prediction processing of the chromaticity components is performed based on this prediction model.

[0034] However, in the related art, a simple linear model Pred is used for each coding block. C (i,j)=α·Rec L (i,j)+β is used to predict chrominance components, and pixels at any position in each coding block are predicted using the same model parameters α and β. This leads to the following problems: on the one hand, coding blocks with different content characteristics use a simple linear model to map luminance to chrominance to achieve chrominance prediction, but the mapping function from luminance to chrominance in any coding block cannot be accurately fitted by this simple linear model, so some coding block prediction effects are inaccurate; on the other hand, during prediction, pixel points at different positions in the coding block all use the same model parameters α and β, and there is also a large difference in the prediction accuracy of different positions in the coding block. That is, in the current CCLM technology, there is a large difference between the predicted value and the original value of some coding blocks, which reduces the prediction accuracy, reduces the quality, and further reduces the codec efficiency.

[0035] Based on this, the embodiment of the present application provides an encoding and decoding method, in which both the encoding side and the decoding side realize the calculation of a weighting factor corresponding to a pixel in a current block to be predicted, and the weighting factor is applied to the color component prediction of the pixel in a current block to be predicted, thereby improving the prediction accuracy and saving the bit rate, as well as improving the codec performance. In addition, the encoding side transmits a first control parameter to the decoding side in the bitstream, thereby improving the reliability of the weighting factor and further improving the accuracy of the chrominance prediction to a certain extent.

[0036] Hereinafter, each embodiment of the present application will be described in detail with reference to the drawings.

[0037] Referring to Fig. 3, Fig. 3 is a block diagram showing the configuration of an encoder according to an embodiment of the present application. As shown in Fig. 3, an encoder (specifically a "video encoder") 100 may include a transform and quantization unit 101, an intra estimation unit 102, an intra prediction unit 103, a motion compensation unit 104, a motion estimation unit 105, an inverse transform and inverse quantization unit 106, a filter control analysis unit 107, a filtering unit 108, an encoding unit 109, and a decoded image buffer unit 110, etc., where the filtering unit 108 can realize deblock filtering and sample adaptive offset (SAO: Sample Adaptive Offset) filtering, and the encoding unit 109 can realize header information coding and binary arithmetic coding based on context adaptive modeling (CABAC: Context-based Adaptive Binary Arithmetic Coding). For an input original video signal, one video coding block is obtained by splitting a coding tree unit (CTU), and then the video coding block is transformed by a transform and quantization unit 101 for residual pixel information obtained through intra prediction or inter prediction. The transform includes transforming the residual information from pixel domain to transform domain and quantizing the obtained transform coefficients to further reduce the bit rate. The intra estimation unit 102 and the intra prediction unit 103 are configured to perform intra prediction on the video coding block, and explicitly, the intra estimation unit 102 and the intra prediction unit 103 are configured to determine an intra prediction mode used to encode the video coding block.The motion compensation unit 104 and the motion estimation unit 105 are configured to perform inter-prediction coding of the received video coding block relative to one or more blocks in one or more reference frames to provide temporal prediction information, where the motion estimation performed by the motion estimation unit 105 is a process of generating a motion vector, which can estimate the motion of the video coding block, and then the motion compensation unit 104 performs motion compensation based on the motion vector determined by the motion estimation unit 105, and after determining the intra prediction mode, the intra prediction unit 103 is further configured to provide the selected intra prediction data to the encoding unit 109, and the motion estimation unit 105 also transmits the motion vector data determined by calculation to the encoding unit 109. Also, the inverse transform and inverse quantization unit 106 is for reconstruction of the video coding block and is configured to reconstruct a residual block in the pixel domain, the reconstructed residual block is filtered out of blocking effect artifacts by the filter control analysis unit 107 and the filtering unit 108, and then the reconstructed residual block is added to one prediction block in a frame of the decoded image buffer unit 110 to generate a reconstructed video coding block. The encoding unit 109 is configured to encode various coding parameters and quantized transform coefficients, and in a CABAC-based encoding algorithm, the context content may be based on neighboring coding blocks and may be used to encode information indicating a determined intra-prediction mode to output a bitstream of the video signal, and the decoded image buffer unit 110 is configured to store the reconstructed video coding block for prediction reference. As the video image encoding proceeds, new reconstructed video coding blocks are continuously generated, and these reconstructed video coding blocks are stored in the decoded image buffer unit 110.

[0038] Referring to FIG. 4, FIG. 4 is a block diagram showing the configuration of a decoder according to an embodiment of the present application. As shown in FIG. 4, a decoder (specifically, a "video decoder") 200 includes a decoding unit 201, an inverse transform and inverse quantization unit 202, an intra prediction unit 203, a motion compensation unit 204, a filtering unit 205, and a decoded image buffer unit 206, etc., where the decoding unit 201 can realize header information decoding and CABAC decoding, and the filtering unit 205 can realize deblock filtering and SAO filtering. After the input video signal undergoes the encoding process of FIG. 3, the decoder outputs a bit stream of the video signal. The bitstream is input to the decoder 200, and first passes through a decoding unit 201 to obtain decoded transform coefficients, which are processed by an inverse transform and inverse quantization unit 202 to generate a residual block in the pixel domain; an intra prediction unit 203 may be configured to generate prediction data for a current video decoded block based on a determined intra prediction mode and data of a previously decoded block from a current frame or picture; and a motion compensation unit 204 determines prediction information for a video decoded block by analyzing motion vectors and other related syntax elements, and uses the prediction information to generate a prediction block for the video decoded block being decoded. A decoded video block is formed by summing the residual block from the inverse transform and inverse quantization unit 202 with the corresponding prediction block generated by the intra prediction unit 203 or the motion compensation unit 204; and the decoded video signal passes through a filtering unit 205 to remove blocking effect artifacts, which can improve the video quality. The decoded video blocks are then stored in a decoded image buffer unit 206, which is configured to store reference images for subsequent intra-prediction or motion compensation, and to output a video signal, i.e., a reconstructed original video signal is obtained.

[0039] It should be noted that the method of the embodiment of the present application is mainly applied to the intra prediction unit 103 part shown in Fig. 3 and the intra prediction unit 203 part shown in Fig. 4. That is, the embodiment of the present application may be applied to the encoder, may be applied to the decoder, or may be applied to the encoder and the decoder simultaneously, but the embodiment of the present application is not particularly limited.

[0040] It should further be explained that when applied to intra prediction unit 103, the "current block" specifically refers to the encoded block currently awaiting intra prediction, and when applied to intra prediction unit 203, the "current block" specifically refers to the decoded block currently awaiting intra prediction.

[0041] In one embodiment of the present application, refer to Fig. 5(a), which is a flowchart of a decoding method according to an embodiment of the present application. As shown in Fig. 5(a), the decoding method may include the following steps:

[0042] In step 501, the bitstream is decoded to determine a first control parameter for the current block.

[0043] It should be noted that the decoding method of the embodiment of the present application is applied to a decoder. The decoding method can specifically refer to an intra prediction method, more specifically, a prediction method of a color component. Wherein, a video image is divided into a plurality of decoding blocks, each decoding block can include a first color component, a second color component, and a third color component, and the current block in the embodiment of the present application refers to a decoding block currently waiting for intra prediction in the video image.

[0044] When the first color component needs to be predicted, the component to be predicted is the first color component, when the second color component needs to be predicted, the component to be predicted is the second color component, and when the third color component needs to be predicted, the component to be predicted is the third color component. In addition, when the first color component is predicted for the current block, and the first color component is a luminance component, i.e., the component to be predicted is a luminance component, the current block may be called a luminance block, or when the second color component is predicted for the current block, and the second color component is a chrominance component, i.e., the component to be predicted is a chrominance component, the current block may be called a chrominance block. In addition, the current block in the embodiment of the present application may also be called a coding block or a decoding block.

[0045] Here, the first control parameter is a control parameter of a weighting factor and is used to set the magnitude of the weighting factor. The weighting factor is a weighting factor of a reference sample value of a second color component of a current block and is used to determine a predicted value of the second color component of a current block. It can be understood that when a second color component needs to be predicted, the first control parameter is a control parameter corresponding to the second color component, when a first color component needs to be predicted, the first control parameter is a control parameter corresponding to the first color component, when a third color component needs to be predicted, the first control parameter is a control parameter corresponding to the third color component, and the control parameters corresponding to different color components may be equal or unequal, and the control parameters corresponding to different color components may be collectively referred to as "first control parameters", or may be distinguished as "first control parameters", "second control parameters", and "third control parameters", and the embodiment of the present application is not particularly limited.

[0046] In some embodiments, decoding the bitstream to determine a first control parameter for a current block includes decoding a data unit at or above a block layer in the bitstream to determine a first control parameter for a current block.

[0047] In some embodiments, the step of decoding the bitstream and determining a first control parameter for the current block includes the steps of: decoding data units at or above the block layer in the bitstream to determine candidate first control parameters; and determining the first control parameter based on the candidate first control parameters.

[0048] The candidate first control parameters include one or more candidate values ​​of the first control parameters of the current block. That is, the decoding side can obtain one or more candidate values ​​of the first control parameters of the current block in a data unit of a block layer or higher in the bitstream. If one candidate value of the first control parameter is obtained, it can be understood that the encoding side transmits the control parameters of each block in the bitstream, and the decoding side obtains the first control parameters of the current block by decoding, and directly applies them to the prediction of the color components. If the candidate first control parameters include multiple candidate values ​​of the first control parameters, it can be understood that the encoding side does not need to transmit corresponding control parameters for each block, but transmits some typical control parameters in the bitstream, and the decoding side can select the corresponding first control parameters based on the prediction parameters of the current block after decoding the bitstream. The encoding side transmits the first control parameters to the decoding side by the bitstream, and the decoding side calculates weighting coefficients based on the received first control parameters, thereby increasing the reliability of the weighting coefficients and further improving the accuracy of the color component prediction to a certain extent.

[0049] In some embodiments, the data units at or above the block layer include at least one of a parameter set data unit, a picture header data unit (PH: Picture Header), a slice header data unit (SH: Slice Header), a coding tree data unit (CTU: Coding Tree Unit), and a current block data unit (CU: Coding Unit).

[0050] Here, the parameter set data unit includes at least one of a sequence parameter set (SPS), a picture parameter set (PPS), and an adaptation parameter set (APS).

[0051] That is, the encoding side transmits the candidate first control parameter in a data unit of a block layer or higher. Specifically, the first control parameter may be transmitted in an SPS layer, a PPS layer, an APS layer, a PH layer, an SH layer, a CTU layer, or a CU layer in a bitstream.

[0052] In some embodiments, when the candidate first control parameter includes one candidate value of the first control parameter, the control parameter can be understood as an optimal control parameter determined for the current block by the encoding side, and when the optimal control parameter is transmitted at the CU layer, the control parameter S can be transmitted separately for different CU blocks to improve prediction accuracy. Exemplarily, when transmitted at the SPS layer, images of the same sequence adopt the same S, when transmitted at the PPS layer, the same frame adopts the same S, when transmitted at the APS layer, the same frame adopts the same S, when transmitted at the PH layer, the same frame adopts the same S, when transmitted at the SH layer, the same slice adopts the same S, and when transmitted at the CTU layer, the same CTU adopts the same S.

[0053] Furthermore, one coding block may correspond to one control parameter selection, or different control parameter selections may be set for different color components within the coding block, e.g., for chroma components Cb and Cr, a similar prediction is made for the chroma blocks of Cb and Cr, and the Cr and Cb components use the same obtained optimal S, or for chroma components Cb and Cr, a prediction is made for the Cb and Cr components, respectively, and the Cb and Cr components use the corresponding optimal S, respectively.

[0054] In some embodiments, the step of decoding the bitstream and determining a first control parameter of the current block includes the step of decoding the bitstream and determining an index parameter of the first control parameter of the current block. In some other embodiments, the step of decoding data units of a block layer or higher in the bitstream and determining a candidate first control parameter includes the step of decoding data units of a block layer or higher in the bitstream and determining an index parameter of a candidate value of the first control parameter. That is, the encoding side can also transmit an index parameter of a control parameter in the bitstream to the decoding side, and the decoding side determines a corresponding control parameter based on the decoded index parameter.

[0055] For example, the decoding side can obtain the optimal control parameter S of the current block by analyzing from the CU layer, and the specific process is as follows:

[0056] [Table 1]

[0057] Sequence Parameter Set (SPS) layer: sps_chroma_format_idc: When it is 0, it indicates that the color component of the current image is a luminance component, and when it is not 0, it indicates that the color component of the current image is a chromaticity component.

[0058] sps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the sps layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0059] Picture Parameter Set (PPS) layer: pps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the pps layer. If the value is 1, it indicates that it is enabled, and if the value is 0, it indicates that it is not enabled.

[0060] Picture Header (PH) layer: ph_wcp_enabled_flag: Indicates whether or not WCP is used in the current image. If this syntax element is not present, it is treated as equal to 0.

[0061] Slice Header (SH) layer: slice_wcp_enabled_flag: Indicates whether or not WCP is currently used in the slice. If this syntax element is not present, it is treated as being equal to 0.

[0062] Coding Unit (CU) layer: wcp_mode_flag: indicates whether or not the WCP is currently used in the CU, with 1 indicating that it is used and 0 indicating that it is not used. If this syntax element does not exist, it is treated as being equal to 0.

[0063] wcp_mode_idx: Represents the index of the current WCP mode.

[0064] wcp_S_Chroma: represents the value of the optimal control parameter S for the Cb and Cr components in the current CU or the index of the optimal control parameter S.

[0065] intra_chroma_pred_mode: represents the current intra prediction mode for the chrominance components. If intra_chroma_pred_mode is not present, it is inferred to be equal to 0.

[0066] For example, the decoding side can obtain the optimal control parameter S of the current block in different chrominance components by analyzing from the CU layer, and the specific process is as follows:

[0067] [Table 2]

[0068] Sequence Parameter Set (SPS) layer: sps_chroma_format_idc: When it is 0, it indicates that the color component of the current image is a luminance component, and when it is not 0, it indicates that the color component of the current image is a chromaticity component.

[0069] sps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the sps layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0070] Picture Parameter Set (PPS) layer: pps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the pps layer. If the value is 1, it indicates that it is enabled, and if the value is 0, it indicates that it is not enabled.

[0071] Picture Header (PH) layer: ph_wcp_enabled_flag: Indicates whether or not WCP is used in the current image. If this syntax element is not present, it is treated as equal to 0.

[0072] Slice Header (SH) layer: slice_wcp_enabled_flag: Indicates whether or not WCP is currently used in the slice. If this syntax element is not present, it is treated as being equal to 0.

[0073] Coding Unit (CU) layer: wcp_mode_flag: indicates whether or not the WCP is currently used in the CU, with 1 indicating that it is used and 0 indicating that it is not used. If this syntax element does not exist, it is treated as being equal to 0.

[0074] wcp_mode_idx: Represents the index of the current WCP mode.

[0075] wcp_S_Cb: represents the value of the optimal control parameter S for the Cb component in the current CU or the index of the optimal control parameter S.

[0076] wcp_S_Cr: represents the value of the optimal control parameter S of the Cr component in the current CU or the index of the optimal control parameter S.

[0077] intra_chroma_pred_mode: represents the current intra prediction mode for the chrominance components. If intra_chroma_pred_mode is not present, it is inferred to be equal to 0.

[0078] In step 502, a reference sample value of a first color component of the current block is determined.

[0079] In an embodiment of the present application, the first color component and the second color component are different color components, the second color component is a prediction-to-be-predicted component in the embodiment of the present application, the first color component is a reference color component in the embodiment of the present application, and the reference sample value of the first color component and the first control parameter are used to determine the weighting coefficient.

[0080] In some embodiments, determining a reference sample value of the first color component of the current block includes determining a reference sample value of the first color component of the current block based on adjacent sample values ​​of the first color component of the current block and a reconstructed value of the first color component of the current block.

[0081] Exemplarily, a reference sample value of a first color component of the current block is set equal to an absolute value of a difference between a reference value within the first block and a first neighboring reference value, where the reference value within the first block is a reconstructed value of the first color component of the current block or a value obtained after a filtering process of the reconstructed value of the first color component of the current block, and the first neighboring reference value is a neighboring sample value of the first color component of the current block or a value obtained after a filtering process of the neighboring sample value of the first color component of the current block.

[0082] Here, the reference value in the first block can be understood as a reconstructed value of a first color component of a pixel waiting to be predicted in the current block, or a value obtained by filtering the reconstructed value of the first color component of the pixel waiting to be predicted, and the first neighboring reference value can be understood as a reconstructed value of a first color component of a reference pixel in a reference region, or a value obtained by filtering the reconstructed value of the first color component of the reference pixel.

[0083] For example, the first color component is a luminance component, and the second color component is a chrominance component. The reference sample value of the first color component is the difference between the luminance reconstruction value (recY) of the pixel to be predicted and the luminance reconstruction value (refY) of the reference pixel. Under certain conditions, pre-processing may be performed on refY and recY. For example, the pre-processing operation may include the following: (1) to reduce the complexity of the calculation, a point selection operation or a down-sampling operation may be performed on refY or recY; (2) different filtering operations may be performed on refY or recY for current blocks of different sizes; (3) under the condition that the resolutions of the chrominance and luminance components of the video do not match, an up-down sampling operation may be performed on refY or recY to facilitate subsequent chrominance prediction calculation; (4) under the condition that the resolutions of the chrominance and luminance components of the video do not match, a reference pixel of multiple rows / columns may be used, and in this case, an up-down sampling operation may be performed on refY or recY to facilitate subsequent chrominance prediction calculation. (5) If the obtained refY quantity and the core parameter inSize quantity are different, a point selection operation or an up-down sampling operation needs to be performed on refY.

[0084] The process of obtaining the weighting coefficients includes constructing a luminance difference vector, calculating the weighting coefficients, obtaining the weighting coefficients, and performing weighted prediction based on the weighting coefficients to obtain the weight-based chrominance prediction values.

[0085] Specifically, for i=0...predSizeW-1, j=0...predSizeH-1, k=0,1...inSize-1, construct each element diffY[i][j][k] in the luma difference vector, calculate each element cWeight[i][j][k] (or cWeightFloat[i][j][k]) in the weight vector, and refer to Equation 1, calculate the chroma prediction value Cpred[i][j] by cWeight[i][j] (or cWeightFloat[i][j][k]) and refC, where K=inSize, where predSizeW is the width of the prediction block, predSizeH is the height of the prediction block, and the inSize quantity is the reference luma quantity.

[0086]

number

[0087] [Formula 2] diffY[i][j][k]=abs(refY[k]-recY[i][j]) In the formula, recY[i][j] represents the luminance reconstruction value of the pixel awaiting prediction (i,j) in the current block, recY[k] represents the luminance reconstruction value of the k-th reference pixel, diffY[i][j][k] represents the difference between the pixel awaiting prediction (i,j) and the luminance reconstruction value of the k-th reference pixel, diffY[i][j] represents a luminance difference vector, which includes the absolute value of the difference between each pixel awaiting prediction in the current block and the luminance reconstruction value of the k-th reference pixel, and abs represents the absolute value. In the embodiment of the present application, the luminance difference vector of the pixel awaiting prediction is processed using a control parameter S.

[0088] In step 503, a weighting coefficient is determined based on a reference sample value of a first color component of the current block and the first control parameter.

[0089] Here, the weighting coefficient can be calculated according to a predetermined mapping relationship. In the embodiment of the present application, the predetermined mapping relationship is a nonlinear mapping relationship. Specifically, a function model (i.e., the predetermined mapping relationship, represented by f) for calculating the weighting coefficient is constructed based on the tendency that the closer the luminance information of the reference pixel is to the pixel (i,j) awaiting prediction in the current block, the higher the importance of the chromaticity of the reference pixel to the pixel (i,j) awaiting prediction.

[0090] In some embodiments, determining a weighting coefficient based on a reference sample value of a first color component of the current block and the first control parameter comprises determining a first input parameter based on a reference sample value of a first color component of the current block and the first control parameter, and determining the weighting coefficient based on a predetermined mapping relationship and the first input parameter.

[0091] In some embodiments, the reference sample value of the first color component of the current block and the first control parameter can both be input as first input parameters into a nonlinear mapping function corresponding to a predetermined mapping relationship, and the weighting coefficient can be the output value of the nonlinear function. That is, the reference sample value of the first color component and the first control parameter are simultaneously input parameters of the nonlinear function, and the value of the nonlinear function is transformed according to the change of the input parameters. In some embodiments, the predetermined mapping relationship is a softmax function.

[0092] For example, the predetermined mapping relationship is a softmax function. In practical application, the mapping relationship may be the softmax function itself, or may be the partial mapping relationship of the softmax function. The luminance difference vector diffY[i][j] corresponding to each pixel to be predicted is input to the nonlinear mapping model, and the model outputs the floating-point weight vector cWeightFloat[i][j] corresponding to each pixel to be predicted, and the calculation formula is shown in Equation 3.

[0093]

number

[0094] For example, when the current prediction block size is flexible, the nonlinear mapping model can be adjusted according to the WCP control parameter (S). Taking the nonlinear Softmax function as an example, different scale parameter adjustment functions can be selected according to the block classification category to which the current prediction block belongs. In this case, the calculation formula of the weight vector corresponding to each pixel to be predicted is shown in Equation 4.

[0095]

number

[0096] [Formula 5] cWeight[i][j][k]=round(cWeightFloat[i][j][k]×2 Shift ) Where: Round( x ) = Sign( x ) × Floor( Abs( x ) + 0.5 )

number

[0097]

number

[0098] Exemplarily, in some embodiments, determining a first input parameter based on a reference sample value of a first color component of the current block and the first control parameter includes setting the first input parameter equal to a ratio between the reference sample value of the first color component of the current block and the first control parameter, that is, taking diffY[i][j][k] / S as the first input parameter, first calculate the ratio between diffY[i][j][k] and S, and then substitute it into Equation 4 to calculate a weight value.

[0099] Exemplarily, in some embodiments, determining a first input parameter based on a reference sample value of a first color component of the current block and the first control parameter includes setting the first input parameter equal to a product of a reference sample value of a first color component of the current block and the first control parameter, i.e., taking diffY[i][j][k] / S as the first input parameter, converting division into multiplication to calculate the product of diffY[i][j][k] and 1 / S, and substituting it into Equation 4 to calculate a weight value.

[0100] In some embodiments, determining a first input parameter based on the reference sample value of the first color component of the current block and the first control parameter includes setting the first input parameter equal to a value obtained by right-shifting the reference sample value of the first color component of the current block by S bits, where the value of S is determined based on the first control parameter. Exemplarily, the value of S is set equal to the first control parameter. That is, diffY[i][j][k] / S is used as a first input parameter, and a division is converted into a right shift operation, and since the realization of a right shift is less difficult than the realization of a division, the computational difficulty can be reduced.

[0101] In some embodiments, determining a first input parameter based on a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter includes: setting the reference sample value of the first color component of the current block and the first control parameter as index values ​​of a numeric mapping lookup table, looking up the numeric mapping lookup table to obtain a corresponding array element value; and setting the first input parameter equal to the array element value.

[0102] In addition, in some embodiments, the mapping relationship can also simplify the operation, for example, an array element lookup method can be adopted to reduce some of the calculation operations. Illustratively, a mapping lookup table of a reference sample value of a first color component, a first control parameter, and an array element is preset, the reference sample value of the first color component and the first control parameter are taken as index values, the mapping lookup table is looked up to obtain an array element, and then a value corresponding to the array element value is determined under a predetermined nonlinear mapping function relationship, and then a weighting coefficient is set equal to the value.

[0103] For example, when calculating a floating-point weighting coefficient or a fixed-point operated weighting coefficient, the same operation as the numerator calculation is performed by table lookup, thereby avoiding the calculation operation of the numerator part and the denominator part.

[0104] For example, the formula for calculating the floating-point weighting coefficient is shown below.

[0105]

number

[0106] Complete storage means storing all of the numerators of the range of diffY[i][j][k] and the number of S values ​​to be scanned, and complete storage requires securing an array space of size (the range of diffY[i][j][k] multiplied by the number of S values ​​to be scanned). For a certain control parameter S value, the required storage table size is the range range size of diffY[i][j][k]. Take the example of calculating the weighting coefficient in Equation 6 for a 10-bit pixel.

[0107] The range of the variables diffY[i][j][k] is an integer between 0 and 1023. In this solution, the range of the control parameter S is not limited first. When the selection range of the S parameter is continuous, the first S value is 1, and the difference between two adjacent S values ​​is 1, i.e., 1, 2, 3, 4, ... S, and the corresponding indexes are 1, 2, 3, 4, ... S. The values ​​of diffY[i][j][k] and S are used to completely store the molecule as the indexes of the two-dimensional array storMole.

[0108]

number

[0109]

number

[0110] [Table 3]

[0111] In some embodiments, for fixed-point arithmetic, widened integer values ​​may be stored, i.e., the array elements in Table 1.1 are widened integer values, and a corresponding narrowing operation needs to be performed after obtaining the predicted values.

[0112] Furthermore, determining the weighting coefficient based on the predetermined mapping relationship and the first input parameter includes taking the first input parameter as an input value of the predetermined mapping relationship and setting the weighting coefficient equal to an output value of the predetermined mapping relationship, where the predetermined mapping relationship is a correspondence relationship between the first input parameter and the weighting coefficient, and the value of the weighting coefficient decreases with an increase in the value of the first input parameter. That is, after determining the first input parameter in Equation 4, a function operation is performed to obtain the corresponding weight value.

[0113] In step 504, a predicted value of the second color component of the current block is determined based on the weighting coefficient and a reference sample value of the second color component of the current block.

[0114] In some embodiments, determining a predicted value of the second color component of the current block based on the weighting coefficients and reference sample values ​​of the second color component of the current block includes calculating a weighted sum of the weighting coefficients and reference sample values ​​of the second color component of the current block to determine a predicted value of the second color component of the current block.

[0115] In some embodiments, the step of determining a predicted value of the second color component of the current block based on the weighting coefficients and the reference sample values ​​of the second color component of the current block includes the steps of: calculating a weighted sum of the weighting coefficients and the reference sample values ​​of the second color component of the current block to determine a first predicted value of the second color component of the current block; and performing a filtering process on the first predicted value of the second color component of the current block to determine a predicted value of the current block.

[0116] In some embodiments, the reference sample value of the second color component of the current block is set to an adjacent sample value of the second color component of the current block or a value after filtering the adjacent sample value of the second color component of the current block.

[0117] The adjacent sample value of the second color component is a value obtained based on the reconstructed value of the second color component of the reference pixel, and the reconstructed value of the second color component of the reference pixel is directly used as the adjacent sample value of the second color component, or the reconstructed value of the second color component of the reference pixel is filtered to obtain the adjacent sample value of the second color component. For example, when the second color component is a chrominance component, the reference sample value of the second color component is the reconstructed value of the chrominance component of the reference pixel, or is a value obtained by filtering the reconstructed value of the second color component of the reference pixel.

[0118] A weight vector cWeightFloat[i][j] or cWeight[i][j] corresponding to each pixel awaiting prediction of the current block is calculated based on the control parameter S. Here, the weight vector may or may not be calculated using fixed-point arithmetic. Furthermore, a chromaticity predicted value of a pixel awaiting prediction is calculated based on the weight vector cWeight[i][j] (or cWeightFloat[i][j][k]) corresponding to each pixel awaiting prediction and the reference chromaticity information refC. Specifically, for each pixel awaiting prediction C pred The reference chromaticity information refC of [i][j] is multiplied by the weight vector elements corresponding to each pixel waiting to be predicted, one by one, to obtain subC[i][j] (or subCFloat[i][j]), and the multiplication results are accumulated to obtain the chromaticity prediction value C of each pixel waiting to be predicted. pred Let [i][j] be the weighted prediction. The formula is as follows:

[0119] For k=0,1…inSize-1, [Formula 8] subCFloat[i][j][k]=(cWeightFloat[i][j][k]×refC[k]) After the calculation is completed, fixed-point arithmetic can be performed on subCFloat, and in the fixed-point arithmetic process, in order to maintain a certain calculation precision, it can be multiplied by one coefficient as follows:

[0120] [Formula 9] subC[i][j][k]=round(subCFloat[i][j][k]×2 Shift ) Or, [Formula 10] subC[i][j][k]=(cWeight[i][j][k]×refC[k]) Let i = 0... predSizeW-1, j = 0... predSizeH-1, k = 0,1... inSize-1,

number

[0121] [Formula 12] C pred [i][j]=round(C pred Float[i][j]) Or, calculate using subC[i][j][k] calculated using fixed-point arithmetic.

[0122]

number

[0123] Furthermore, the decoding method further includes a step of performing a correction on the predicted value. pred Correction is performed on [i][j], the chromaticity prediction value should be within a limited range, and if it exceeds the limited range, the corresponding correction operation should be performed.

[0124] For example, C pred A clipping operation can be performed on the chromaticity prediction values ​​of [i] and [j], specifically as follows:

[0125] C pred If the value of [i][j] is less than 0, set it to 0, and C pred If the value of [i][j] is greater than (1<<BitDepth)-1, set it to (1<<BitDepth)-1. Here, BitDepth is the bit depth required for the chrominance value, which ensures that all predicted values are within 0 to (1<<BitDepth)-1.

[0126] That is, [Equation 14] C pred [i][j]=Clip3(0,(1≪BitDepth)-1,C pred [i][j]) Here, [Number] Or perform the calculations of Equation 13 and Equation 14 by integrating them into the following equation.

[0127] [Number] Furthermore, the decoding method further includes a step of performing post-processing on the predicted value. For the chrominance prediction value based on weights (represented by predWcp here), under certain conditions, it is necessary to perform post-processing to obtain the final chrominance prediction value predSamples. Otherwise, the final chrominance prediction value predSamples is predWcp.

[0128] Exemplarily, the post-processing operation includes the following: (1) In the WCP core parameters, when predSizeW is not equal to the width nTbW of the current block, or when predSizeH is not equal to the width nTbH of the current block, it is necessary to perform up / downsampling operations on predWcp to obtain the final chrominance prediction value predSamples.

[0129] (2) In order to reduce instability due to independent parallel prediction for each pixel of WCP, smoothing filtering can be performed on predWcp to obtain the final chromaticity predicted value predSamples.

[0130] (3) In order to further improve the accuracy of the WCP prediction value, a position-related correction process can be performed on predWcp, for example, by using reference pixels in close spatial positions to calculate the chromaticity compensation value of each pixel waiting to be predicted, and then using the chromaticity compensation value to correct predWcp, and the corrected prediction value is the final chromaticity prediction value predSamples.

[0131] (4) In order to further improve the accuracy of the WCP prediction value, the chromaticity prediction value calculated by another chromaticity prediction technique and the chromaticity prediction value predWcp calculated by the WCP can be weighted and fused, and the fusion result can be the final chromaticity prediction value predSamples. For example, the chromaticity prediction value obtained by prediction using the CCLM technique and the chromaticity prediction value predWcp of the WCP can be weighted equally or unevenly, and the weighted result can be the final chromaticity prediction value predSamples.

[0132] (5) To improve the WCP prediction performance, a neural network can be adopted to make corrections to the WCP prediction output predWcp.

[0133] An embodiment of the present application provides a weighted chroma prediction method (WCP: Weighted Chroma Prediction), which, as shown in FIG. 5(b), for each sample point recY[i][j] in a downsampled luminance block, first obtain a luminance difference vector diffY[i][j] based on the absolute value of the difference between recY[i][j] and an adjacent luminance vector refY[k], then derive a normalized weight vector cWeight[i][j] based on a nonlinear mapping model associated with diffY[i][j], and thirdly, use the weight vector to vector-multiply the weight vector and the adjacent chroma vector to obtain a predicted chroma sample chroma prediction value Cpred[i][j].

[0134] In step 505, a reconstruction value of a sampling point of the second color component of the current block is determined based on the predicted value of the second color component of the current block.

[0135] In some embodiments, the step of determining a reconstructed value of a sampling point of the second color component of the current block based on a predicted value of the second color component of the current block includes a step of decoding the bitstream to determine a reconstructed value of a prediction difference of the second color component of the current block, and a step of determining a reconstructed value of a sampling point of the second color component of the current block based on a sum of the predicted value of the second color component of the current block and the reconstructed value of the second color component prediction difference of the current block.

[0136] Here, the prediction difference can be understood as the residual of the second color component, and the decoding side adds the prediction value and the reconstructed value of the prediction difference obtained by decoding in the bitstream to obtain the reconstructed value of the second color component of the pixel waiting for prediction in the current block.

[0137] Due to the flexibility of block division, the prediction block can be divided into large blocks and small blocks, square blocks and rectangular blocks, etc. In order to accommodate various block types, the prediction block can be classified based on the size of the prediction block or the number of pixels of the prediction block through theoretical analysis, and the same prediction block can use the same fixed control parameter S. In FIG. 6(a), S=0.5, in FIG. 6(b), S=2, in FIG. 6(c), S=20, and in FIG. 6(d), S=50. As a result, as the control parameter S increases, the softmax curve tends to become flatter, and from FIG. 6(c) and (d), it can be seen that the weighting coefficient of the reference pixel hardly changes even when the luminance difference increases. However, when the control parameter S is small, it can be seen from FIG. 6(a) and (b) that the weighting coefficient of the reference pixel decreases rapidly as the luminance difference increases. Overall, as the luminance difference increases, the weighting coefficient of the reference pixel decreases, but the speed at which the weighting coefficient decreases slows down as the control parameter S increases. Video content may affect the result of block division, and for areas with simple content and flat pixels, the encoder divides into large blocks, and for areas with complex content and large change rate, the encoder divides into small blocks. This division mechanism can ensure the accuracy of prediction to a certain extent and save bit rate. Therefore, in theory, in many cases, for large block content, the content of the reference region and the current block are relatively close, and the weight allocation of the reference points should be relatively uniform, in which case a large control parameter S should be selected. For small block content, the correlation between the reference region and the content of the current block is weak, and the large weight should focus on the reference points with small luminance difference, and the small weight, or even the weight of 0, should focus on the reference points with large luminance difference, that is, the weight allocation of the reference points should show a non-uniform distribution, in which case a small control parameter S should be selected.

[0138] Based on this, the embodiment of the present application further illustrates the selection of the first control parameter by way of example.

[0139] In some embodiments, determining the first control parameter based on the candidate first control parameters comprises determining the first control parameter from among the candidate first control parameters based on prediction parameters of the current block. It can be understood that if the candidate first control parameters include a plurality of candidate values ​​of the first control parameter, the decoding side determines one first control parameter from the plurality of candidate values ​​based on prediction parameters of the current block.

[0140] In some embodiments, determining the first control parameter from among the candidate first control parameters based on the prediction parameters of the current block comprises determining the first control parameter from among the candidate first control parameters based on the prediction parameters of the current block based on a correspondence between a predetermined prediction parameter and a first control parameter, It can be understood that all first control parameters included in the correspondence are set as candidate first control parameters of the current block, and based on the prediction parameters of the current block, the corresponding first control parameters are determined as first control parameters of the current block, i.e. the first control parameters are set equal to the first control parameters corresponding to the prediction parameters of the current block in the candidate first control parameters.

[0141] In some embodiments, the prediction parameters of the current block include at least a size of the current block, where the size of the current block includes at least one of a height of the current block, a width of the current block, a number of first color component sampling points included in the current block, and a number of second color component sampling points included in the current block, where the first color component sampling points and the second color component sampling points are pixel points to be predicted in the current block, and the first color component sampling points and the second color component sampling points may be completely the same pixel points or not completely the same pixel points.

[0142] It should be noted that the embodiment of the present application may adopt a classification method to determine the value of the first control parameter. For example, the current block is classified into three types based on the size parameter of the current block, and the value of the first control parameter corresponding to each type is determined. Or, the current block is classified into three types based on the number of sampling points of the current block, and the value of the first control parameter corresponding to each type is determined. In this case, the embodiment of the present application may transmit the correspondence between the classification parameter and the first control parameter in the bit stream, and then determine the value of the first control parameter based on the correspondence. Exemplarily, Table 1.2 shows the correspondence between the first control parameter and the size parameter of the current block according to the embodiment of the present application, and Table 1.3 shows the correspondence between the first control parameter and the number of sampling points of the current block according to the embodiment of the present application. It should be noted that Table 1.2 and Table 1.3 are exemplary lookup tables and are not particularly limited.

[0143] [Table 4]

[0144] It should be noted that different control parameters S can be designed for different coding chromaticity block size classification methods or different coding block pixel numbers, including but not limited to the above classification methods and classification theories. Classification theory can also take into account the content particularity of some sequences, for example, and often gives a large weight to small blocks and a small weight to large blocks.

[0145] In some embodiments, the prediction parameters of the current block include a prediction mode of the current block. Exemplarily, the prediction mode may be a chroma prediction mode, and the chroma prediction mode may be a weighted chroma prediction (WCP) method, and in the case where multiple WCP modes are included, in some embodiments, different control parameters may be set for different WCP modes.

[0146] In some embodiments, based on the available reference area, the WCP mode is divided into three types: WCP mode, WCP_L mode, and WCP_T mode, where the reference area of ​​the WCP mode includes the upper neighboring area and the left neighboring area of ​​the current block as shown in Fig. 7(a), the reference area of ​​the WCP mode includes the left neighboring area and the lower left neighboring area of ​​the current block as shown in Fig. 7(b), and the reference area of ​​the WCP_T mode includes the upper neighboring area and the upper right neighboring area of ​​the current block as shown in Fig. 7(c).

[0147] Illustratively, Table 1.4 shows the correspondence between control parameters and prediction modes according to an embodiment of the present application.

[0148] [Table 5]

[0149] In some embodiments, the prediction parameters of the current block include an index parameter of a first control parameter, where the index parameter is used to index a first control parameter corresponding to a pixel to be predicted of the current block. In some other embodiments, the prediction parameters of the current block include at least two parameters of a size of the current block, a prediction mode of the current block, and an index parameter of a first control parameter. Illustratively, Table 1.5 shows a correspondence relationship between a first control parameter and a prediction mode according to an embodiment of the present application.

[0150] [Table 6]

[0151] In some embodiments, the decoding method further includes a step of analyzing a bitstream and determining a correspondence between the predetermined prediction parameters and a first control parameter. Illustratively, decoding a slice header data unit in the bitstream and determining a parameter set directly or indirectly referenced by a slice, where a slice corresponding to the slice header data unit includes the current block, and determining a correspondence between the predetermined prediction parameters and a first control parameter based on a parameter set directly or indirectly referenced by the slice.

[0152] In some embodiments, the parameter set referenced directly or indirectly by the slice includes at least one of a Sequence Parameter Set (SPS), a Picture Parameter Set (PPS), and an Adaption Parameter Set (APS). That is, the correspondence may be in a PPS or APS that the slice directly references, or in an SPS that the slice indirectly references.

[0153] In some embodiments, the decoding method further includes: decoding the slice header data unit, and updating the correspondence between the predetermined prediction parameter and the first control parameter. It should be noted that in practical applications, the encoding side may retransmit all or part of the parameters of the corresponding relationship in the slice header data unit, and the retransmitted parameters are the same or different from the parameters of the corresponding relationship in the parameter set, so that the correspondence can be updated using the retransmitted data in the slice header data unit, where the update includes operations such as keeping, replacing, modifying, adding, deleting, etc.

[0154] In some embodiments, the decoding method further includes: decoding an image header data unit in the bitstream; and updating a correspondence between the predetermined prediction parameter and a first control parameter, where the image corresponding to the image header data unit includes the slice. It should be noted that in practical applications, the encoding side may retransmit all or part of the corresponding parameters in the image header data unit, and the retransmitted parameters are the same or different from the corresponding parameters in the parameter set, and the retransmitted parameters are the same or different from the corresponding parameters in the slice data unit, so that the correspondence can be updated using the retransmitted data in the slice header data unit.

[0155] Furthermore, the encoding side may configure some typical S-control parameter values ​​through the CTC cfg configuration file, or may directly provide S-control parameter values ​​without configuring S-control parameters through the cfg file. When S-control parameters are configured through the cfg file, the encoding side reads these S-control parameter values ​​when analyzing the cfg configuration file, and writes these S-control parameter values ​​or S-control parameter indexes to the bitstream sequentially in the SPS layer. When S-control parameters are not configured through the cfg configuration file, the encoding side directly provides S-control parameter values ​​or S-control parameter indexes to the bitstream sequentially in the SPS layer. The writing method to the bitstream may be variable-length coding or fixed-length coding. When performing WCP chromaticity prediction for the current block, the decoding side obtains the S-control parameter values ​​or S-control parameter indexes transmitted in the SPS layer through analysis of the bitstream, and uses the obtained corresponding S-control parameter values ​​in the weight vector calculation process during current block chromaticity prediction according to certain conditions, such as the block size or the number of pixels in the block. An example of obtaining the S control parameters from the SPS layer based on the block size condition is shown in Table 1.2 or Table 1.3 below.

[0156] It should be noted that when the S control parameters are configured by the cfg file, in the SPS layer, a scheme of reading the S control parameters configured by the cfg file can achieve adaptive effects by setting different S control parameter values ​​based on different characteristics of different sequences (e.g., size, prediction mode, etc.).

[0157] Exemplarily, the parsing process of the fixed-length coding for S at the decoding side is as follows:

[0158] [Table 7]

[0159] The variable length coding parsing process for S at the decoding side is as follows:

[0160] [Table 8]

[0161] sps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the Sps layer. If the value is 1, it indicates that it is enabled, and if the value is 0, it indicates that it is not enabled.

[0162] sps_wcp_S_Num: Represents the number of S control parameter values.

[0163] sps_S_wcp[i]: represents the value of the i-th control parameter S for the Cb and Cr components in the SPS layer or the index of the S control parameter.

[0164] In addition to configuring some typical S control parameter values ​​in the CTC cfg configuration file or directly providing them without configuring them in the cfg file, in some embodiments, some threshold parameters Thr can also be added to the CTC cfg configuration file or some threshold parameters Thr can be directly provided without configuring them in the cfg file, that is, the corresponding S control parameter values ​​are adaptively selected according to the threshold parameters configured or directly provided by the cfg file. Specifically, the following is the procedure:

[0165] Some typical S-control parameter values ​​and some threshold parameters Thr can be configured by the CTC cfg configuration file, or some typical S-control parameter values ​​and some threshold parameters Thr can be directly provided without cfg, and there is a correspondence between the S-control parameter values ​​and the threshold parameters Thr. Here, the number of S-control parameter values ​​sps_wcp_S_Num and the number of Thr threshold parameters sps_wcp_Thr_Num may be fixed or may be transmitted by the encoding side. The threshold parameters Thr may be any parameters associated with the coding block, such as the quantization parameter (QP), width, height, number of pixels, etc. of the coding block. When the S-control parameters and the threshold parameters Thr are configured by the cfg file, the encoding side sequentially writes these S-control parameter values ​​or the indexes of the S-control parameters and the threshold parameters Thr or the indexes of the threshold parameters Thr into the bitstream when parsing the cfg file. If the S control parameter and the threshold parameter Thr are not configured by the cfg file, the encoding side sequentially writes the given S control parameter value or S control parameter index and the threshold parameter Thr or threshold parameter Thr index into the bitstream in the SPS layer. The bitstream writing method may be variable length coding or fixed length coding. When performing WCP chromaticity prediction for the current block, the decoding side obtains the S control parameter value or S control parameter index and the threshold parameter value Thr or threshold parameter Thr index transmitted in the SPS layer by analyzing the bitstream, and uses the obtained corresponding S control parameter value in the weight vector calculation process during current block chromaticity prediction based on the threshold parameter Thr. An example of the relationship between the threshold parameter Thr and the control parameter S is as follows:

[0166] For example, the threshold parameter Thr can be related to the QP value: when QP < QP_Thr0, S = S0; when QP_Thr0 < QP <= QP_Thr1, S = S1; when QP > QP_Thr1, S = S2, where QP is the QP value of the current coded block, QP_Thr0 and QP_Thr1 are threshold parameters, and S0, S1, and S2 are S control parameters.

[0167] It should be noted that when configuring the S control parameter and the threshold parameter Thr by the cfg file, in the SPS layer, the method of reading the S control parameter and the threshold parameter Thr configured by the cfg file can achieve an adaptive effect by setting different S control parameter values and threshold parameter Thr based on different characteristics of different sequences.

[0168] The syntax analysis process of fixed-length coding for the control parameter S or its index, and the threshold Thr or its index on the decoding side is as follows.

[0169]

Table 9

[0170] The syntax analysis process of variable-length coding for the control parameter S or its index, and the threshold Thr or its index on the decoding side is as follows.

[0171]

Table 10

[0172] sps_wcp_enabled_flag: Indicates whether to enable WCP in the Sps layer. When it is 1, it means to enable; when it is 0, it means not to enable.

[0173] sps_wcp_S_Num: Represents the number of S control parameter values.

[0174] sps_wcp_Thr _Num: Represents the number of Thr threshold parameter values.

[0175] sps_S_wcp[i]: represents the value of the i-th control parameter S of the Cb and Cr components in the SPS layer or the index of the S control parameter.

[0176] sps_Thr_wcp[j]: represents the value of the j-th threshold parameter S or the index of the Thr threshold parameter for the Cb and Cr components in the SPS layer.

[0177] In addition to obtaining the control parameters S transmitted at the SPS layer based on certain limiting conditions, the control parameters S transmitted at the APS layer can also be obtained based on certain limiting conditions (for example, the limiting conditions may be the same as those for obtaining the S control parameters at the SPS layer), and it should be noted that the value and number of the control parameters S transmitted at the APS layer are flexibly set. The syntactic semantics are as follows (wherein, when S or its index is coded, it may be coded by variable length coding or fixed length coding):

[0178] [Table 11]

[0179] sps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the Sps layer. If the value is 1, it indicates that it is enabled, and if the value is 0, it indicates that it is not enabled.

[0180] aps_wcp_S_Num: represents the number of S control parameter values.

[0181] aps_S_wcp[i]: represents the value of the i-th control parameter S of the Cb and Cr components in the APS layer or the index of the S control parameter.

[0182] According to the type of block classification, different control parameters S are used and transmitted through the SPS layer, the APS layer or the PPS layer. The S control parameter has a small selectable range, is easy to implement at the encoding and decoding sides, and is applicable to most coding blocks.

[0183] In addition to the above and the transmission of a small number of candidate control parameters, the characteristics of all the coding blocks of all the sequences can also be measured comprehensively by increasing the choices of the control parameter S. Therefore, in the embodiment of the present application, more candidate control parameters S are given at the coding side, the original values ​​of the coding blocks are introduced, and an optimal control parameter S is selected from these candidate control parameters, and the process of selecting the optimal control parameter at the coding side is described in detail.

[0184] In an embodiment of the present application, a weighted chroma prediction method (WCP: Weighted Chroma Prediction) is provided. When chroma prediction is performed on a current block, the luminance reconstruction information of the current block, the reconstructed luminance information of the adjacent reference region, and the reconstructed chroma information are all encoded reconstruction information. The weighted chroma prediction is realized by using the above reconstruction information. The chroma prediction process is described in detail below.

[0185] Input of WCP: position of current chroma prediction block (xTbCmp, yTbCmp), width of current chroma prediction block nTbW, and height of current chroma prediction block nTbH.

[0186] Output of the WCP: Predicted values ​​predSamples[x][y] of the current chrominance prediction block, where the position of the top left pixel in the current chrominance prediction block is the origin of the coordinate system, x = 0...nTbW-1, y = 0...nTbH-1.

[0187] The prediction process of the WCP technology includes determining the WCP core parameters, obtaining input information, predicting chrominance based on the weights, and then performing a post-processing process. After the above steps, the chrominance prediction value of the current chrominance prediction block can be obtained.

[0188] The core parameters of the WCP include a control parameter (S), the number of inputs of the weight-based chroma prediction inSize, and the number of outputs of the weight-based chroma prediction (predWcp) (arranged as predSizeW×predSizeH). Here, the number of outputs of the weight-based chroma prediction (predWcp) can be set to the same value (e.g., predSizeW=predSizeH=S / 4) or correlated with the current block size (e.g., predSizeW=nTbW, predSizeH=nTbH). Here, the control parameter S can be used to adjust the nonlinear function of the subsequent stage or to adjust the data related to the subsequent stage. The determination of the WCP core parameters is affected by the block size or block content under certain conditions. For example, when there are many types of block sizes applied to the WCP, or when the difference in the block content is large, or when the difference in the number of pixels in the block is large, the blocks can be classified and the same or different core parameters can be determined based on different block types.

[0189] For example, chroma blocks are classified based on the width and height of the chroma prediction block, and the type of chroma block is represented by wcpSizeId. Depending on different types of chroma blocks, the WCP control parameter (S), the number of inputs of weight-based chroma prediction inSize, and the number of outputs of weight-based chroma prediction (predWcp) (arranged as predSizeW×predSizeH) may be the same or different. Here, an example will be described in which the chroma blocks are classified into three types. nTbW is the width of the current chroma prediction block, nTbH is the height of the current chroma prediction block, and the definition of the type of chroma block wcpSizeId is as follows, i.e. If wcpSizeId=0:min(nTbW,nTbH)<=4, then the WCP control parameter (S) is 8, inSize is (2×nTbH+2×nTbW), and the weight-based chroma prediction outputs nTbH×nTbW chroma prediction values; When wcpSizeId = 1:4 < min(nTbW, nTbH) <= 16 is defined, the WCP control parameter(s) is 12, inSize is (2 × nTbH + 2 × nTbW), and the weight-based chrominance prediction outputs nTbH × nTbW chrominance prediction values. When wcpSizeId = 2:min(nTbW, nTbH) > 16 is defined, the WCP control parameter(s) is 16, inSize is (2 × nTbH + 2 × nTbW), and the weight-based chrominance prediction outputs nTbH × nTbW chrominance prediction values. Correspondingly, the quantitative relationship is shown in Table 1.6.

[0190]

Table 12

[0191] Classifying into three categories can also be explained by taking another case as an example. The definition of the type wcpSizeId of the chrominance block is as follows, that is, When wcpSizeId = 0:min(nTbW, nTbH) <= 4 is defined, the WCP control parameter(s) is 8, inSize is (2 × nTbH + 2 × nTbW), and the weight-based chrominance prediction outputs nTbH × nTbW chrominance prediction values. When wcpSizeId = 1:4 < min(nTbW, nTbH) <= 16 is defined, the WCP control parameter(s) is 12, inSize is (1.5 × nTbH + 1.5 × nTbW), and the weight-based chrominance prediction outputs nTbH / 2 × nTbW / 2 chrominance prediction values. When wcpSizeId = 2:min(nTbW, nTbH) > 16 is defined, the WCP control parameter(s) is 16, inSize is (nTbH + nTbW), and the weight-based chrominance prediction outputs nTbH / 4 × nTbW / 4 chrominance prediction values. Correspondingly, the quantitative relationship is shown in Table 1.7.

[0192]

Table 13

[0193] WCP can also classify chroma blocks based on the number of pixels in the chroma prediction block, and the type of chroma block is represented by wcpSizeId. The definition of the chroma block type wcpSizeId is as follows: If wcpSizeId=0:(nTbW nTbH)<128, then the WCP control parameter (S) is 10, inSize is (2×nTbH+2×nTbW), and the weight-based chroma prediction outputs nTbH×nTbW chroma prediction values; If wcpSizeId=1:128<=(nTbW nTbH)<=256, then the WCP control parameter (S) is 8, inSize is (2×nTbH+2×nTbW), and the weight-based chroma prediction outputs nTbH×nTbW chroma prediction values; If wcpSizeId=2:(nTbW□nTbH)>256 is defined, then the WCP control parameter (S) is 1, inSize is (2×nTbH+2×nTbW), and the weight-based chromaticity prediction outputs nTbH×nTbW chromaticity prediction values, with the corresponding quantitative relationships shown in Table 1.8.

[0194] [Table 14]

[0195] The classification into three types can also be explained using another example.

[0196] The definition of the chromaticity block type wcpSizeId is as follows: wcpSizeId=0: (nTbW nTbH)<64 chroma blocks are defined, the WCP control parameter (S) is 16, inSize is (2×nTbH+2×nTbW), and the weight-based chroma prediction outputs nTbH×nTbW chroma prediction values; If wcpSizeId=1:64<=(nTbW nTbH)<=512, then the WCP control parameter (S) is 4, inSize is (1.5×nTbH+1.5×nTbW), and the weight-based chroma prediction outputs nTbH / 2×nTbW / 2 chroma prediction values; If wcpSizeId=2:(nTbW nTbH)>512, then the WCP control parameter (S) is 1, inSize is (nTbH+nTbW), and the weight-based chroma prediction outputs nTbH / 4×nTbW / 4 chroma prediction values; The corresponding quantitative relationships are shown in Table 1.9.

[0197] [Table 15]

[0198] When taking input information and predicting a current block, the area above, the area above and the area to the left of the current prediction block are called reference areas, and the pixels in the reference areas are reconstructed reference pixels, as shown in FIG. 1.

[0199] Obtain reference chromaticity information refC and reference luma information refY from the reference region. The obtained reference chromaticity information includes, but is not limited to, a reference chromaticity reconstruction value of the upper reference region of the current chromaticity prediction block and a reference chromaticity reconstruction value of the left reference region. The obtained reference luma information includes, but is not limited to, corresponding reference luma information obtained based on the position of the reference chromaticity information. The manner of obtaining luma reconstruction information recY of the current prediction block includes, but is not limited to, obtaining corresponding luma reconstruction information based on the position of chromaticity information in the current chromaticity prediction block as the luma reconstruction information of the current prediction block.

[0200] Under certain conditions, refC, refY, or recY may be pre-processed and then used as the input for weight-based chrominance prediction. Exemplarily, the pre-processing operations include: (1) a point selection operation or a down-sampling operation may be performed on refY or recY to reduce the computation complexity; (2) different filtering operations may be performed on current blocks of different sizes, refY or recY; (3) under conditions where the resolutions of the video chrominance and luma components do not match, an up-down sampling operation may be performed on refY or recY to facilitate subsequent chrominance prediction computation; (4) under conditions where the resolutions of the video chrominance and luma components match, multiple row / column reference pixels may be used, and in this case, an up-down sampling operation may be performed on refY or recY to facilitate subsequent chrominance prediction computation; (5) if the number of acquired refYs differs from the number of core parameters inSize, a point selection operation or an up-down sampling operation needs to be performed on refY.

[0201] Obtaining input information includes obtaining reference chromaticity information refC of the inSize quantity (after a preprocessing operation if preprocessing is required), obtaining reference luma information refY of the inSize quantity (after a preprocessing operation if preprocessing is required), and obtaining luma reconstruction information recY of the current prediction block (after a preprocessing operation if preprocessing is required).

[0202] For weight-based chroma prediction, where i=0...predSizeW-1, j=0...predSizeH-1, k=0,1...inSize-1, construct each element diffY[i][j][k] in the luma difference vector, calculate each element cWeight[i][j][k] (or cWeightFloat[i][j][k]) in the weight vector, and calculate the chroma prediction value Cpred[i][j] by cWeight[i][j] (or cWeightFloat[i][j][k]) and refC, where predSizeW is the width of the prediction block, predSizeH is the height of the prediction block, and inSize is the number of reference pixels.

[0203] In another embodiment of the present application, please refer to FIG. 8, which is a flow chart 1 of an encoding method according to an embodiment of the present application. As shown in FIG. 8, the encoding method includes: In step 801, a candidate first control parameter for the current block is determined.

[0204] It should be noted that the encoding method of the embodiment of the present application is applied to an encoder. The encoding method can specifically refer to an intra prediction method, more specifically, a prediction method of a color component. Here, a video image is divided into a plurality of coding blocks, and the plurality of coding blocks can include a first color component, a second color component, and a third color component. The current block in the embodiment of the present application refers to a coding block currently waiting for intra prediction in the video image.

[0205] When a first color component needs to be predicted, the component to be predicted is the first color component, when a second color component needs to be predicted, the component to be predicted is the second color component, and when a third color component needs to be predicted, the component to be predicted is the third color component. In addition, when a first color component is predicted for a current block, and the first color component is a luminance component, i.e., the component to be predicted is a luminance component, the current block may be called a luminance block, or when a second color component is predicted for a current block, and the second color component is a chrominance component, i.e., the component to be predicted is a chrominance component, the current block may be called a chrominance block. In addition, the current block in the embodiment of the present application may be further called a prediction block, a coding block, or a decoding block.

[0206] Here, the candidate first control parameters include a plurality of candidate values ​​of the first control parameters, and the candidate first control parameters can be understood as one control parameter selection range corresponding to the current block. The encoding side determines one or more first control parameters for the current block from the control parameter selection range, writes the obtained first control parameters into a bitstream, and transmits them to the decoding side. Exemplarily, the control parameter selection range may be one continuous range or a non-contiguous range including several control parameters.

[0207] Furthermore, one coding block may correspond to one control parameter selection range, or different control parameter selection ranges may be set for different color components within the coding block.

[0208] For example, in selection scheme 1, for chrominance components Cb and Cr, similar predictions are made for Cb and Cr chrominance blocks, and the same optimal S obtained is used for Cr and Cb components. A selection range of control parameters S is given for all blocks, and S is scanned with a constant step length D within the selection range. Table 2.1 shows the corresponding relationship between the control parameter selection ranges and the coding chrominance blocks according to an embodiment of the present application.

[0209] [Table 16]

[0210] In addition to scanning the control parameter S within a certain selection range, some typical control parameters S can also be selected. Table 2.2 shows the correspondence between some typical control parameters S and the coding chrominance blocks according to an embodiment of the present application.

[0211] [Table 17]

[0212] In the selection method 2, for the chrominance components Cb and Cr, prediction is performed for the Cb and Cr components respectively, and each of the Cb and Cr components obtains its own optimal S by scanning. WCP does not classify the block size, but gives a selection range of the control parameter S for every block, and scans S with a certain step length D within this range. For example, as shown in Table 2.3 below.

[0213] [Table 18]

[0214] In addition to scanning the control parameter S within a certain selection range, several typical control parameters S can also be selected, and the several typical control parameters S selected by the Cb and Cr components can be the same or different, for example, as shown in Tables 2.4 and 2.5 below.

[0215] [Table 19]

[0216] In step 802, a reference sample value of a first color component of the current block is determined.

[0217] In an embodiment of the present application, the first color component and the second color component are different color components, the second color component is a prediction-to-be-predicted component in the embodiment of the present application, the first color component is a reference color component in the embodiment of the present application, and the reference sample value of the first color component and the first control parameter are used to determine the weighting coefficient.

[0218] In some embodiments, determining a reference sample value of the first color component of the current block includes determining a reference sample value of the first color component of the current block based on adjacent sample values ​​of the first color component of the current block and a reconstructed value of the first color component of the current block.

[0219] Exemplarily, a reference sample value of a first color component of the current block is set equal to an absolute value of a difference between a reference value within the first block and a first neighboring reference value, where the reference value within the first block is a reconstructed value of the first color component of the current block or a value obtained after a filtering process of the reconstructed value of the first color component of the current block, and the first neighboring reference value is a neighboring sample value of the first color component of the current block or a value obtained after a filtering process of the neighboring sample value of the first color component of the current block.

[0220] Here, the reference value in the first block can be understood as a reconstructed value of a first color component of a pixel waiting to be predicted in the current block, or a value obtained by filtering the reconstructed value of the first color component of the pixel waiting to be predicted, and the first neighboring reference value can be understood as a reconstructed value of a first color component of a reference pixel in a reference region, or a value obtained by filtering the reconstructed value of the first color component of the reference pixel.

[0221] For example, the first color component is a luminance component, and the second color component is a chrominance component. The reference sample value of the first color component is the difference between the luminance reconstruction value (recY) of the pixel to be predicted and the luminance reconstruction value (refY) of the reference pixel. Under certain conditions, pre-processing may be performed on refY and recY. For example, the pre-processing operation may include the following: (1) to reduce the complexity of the calculation, a point selection operation or a down-sampling operation may be performed on refY or recY. (2) for current blocks of different sizes, different filtering operations may be performed on refY or recY. (3) under the condition that the resolutions of the video chrominance and luminance components do not match, an up-down sampling operation may be performed on refY or recY to facilitate subsequent chrominance prediction calculation. (4) under the condition that the resolutions of the video chrominance and luminance components match, multiple rows / columns of reference pixels may be used, and in this case, an up-down sampling operation may be performed on refY or recY to facilitate subsequent chrominance prediction calculation. (5) If the number of acquired refYs differs from the number of core parameters inSize, a point selection operation or an up-down sampling operation needs to be performed on refYs.

[0222] To construct the luminance difference vector, as shown in Equation 2, the luminance reconstruction information recY[i][j] corresponding to each pixel waiting to be predicted is subtracted from the inSize number of reference luminance information refY, and the absolute value is taken to obtain the luminance difference vector diffY[i][j][k].

[0223] In step 803, a weighting coefficient is determined based on a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter.

[0224] Here, the weighting coefficient can be calculated according to a predetermined mapping relationship. In the embodiment of the present application, the predetermined mapping relationship is a nonlinear mapping relationship. Specifically, a function model (i.e., the predetermined mapping relationship, represented by f) for calculating the weighting coefficient is constructed based on the tendency that the closer the luminance information of the reference pixel is to the pixel (i,j) awaiting prediction in the current block, the higher the importance of the chromaticity of the reference pixel to the pixel (i,j) awaiting prediction.

[0225] In some embodiments, determining a weighting coefficient based on a reference sample value of a first color component of the current block and a candidate value among the candidate first control parameters includes determining a first input parameter based on a reference sample value of a first color component of the current block and a candidate value among the candidate first control parameters, and determining the weighting coefficient based on a predetermined mapping relationship and the first input parameter.

[0226] In some embodiments, the reference sample value of the first color component of the current block and the candidate value of the candidate first control parameter can both be input as first input parameters into a nonlinear mapping function corresponding to a predetermined mapping relationship, and the weighting coefficient is the output value of the nonlinear function, that is, the reference sample value of the first color component and the first control parameter are simultaneously input parameters of the nonlinear function, and the value of the nonlinear function is transformed according to the change of the input parameters.

[0227] For example, the predetermined mapping relationship is a softmax function. For the specific mapping relationship, see Equation 4 and Equation 5.

[0228] In some embodiments, determining a first input parameter based on a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter comprises setting the first input parameter equal to a ratio of a reference sample value of a first color component of the current block to a candidate value in the candidate first control parameter, i.e., taking diffY[i][j][k] / S as the first input parameter, converting division to multiplication to calculate the product of diffY[i][j][k] and 1 / S, and substituting it into Equation 4 to calculate a weight value.

[0229] In some embodiments, determining a first input parameter based on a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter comprises setting the first input parameter equal to a product of a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter, i.e., taking diffY[i][j][k] / S as the first input parameter, converting division to multiplication to calculate the product of diffY[i][j][k] and 1 / S, and substituting it into Equation 4 to calculate a weight value.

[0230] In some embodiments, determining a first input parameter based on a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter includes setting the first input parameter equal to a value obtained by right-shifting the reference sample value of the first color component of the current block by S bits, where the value of S is determined based on the first control parameter. Exemplarily, the value of S is set equal to the candidate value in the candidate first control parameter. That is, diffY[i][j][k] / S is used as a first input parameter, and a division is converted into a right shift operation, and the difficulty of realizing a right shift is lower than the difficulty of realizing a division, so that the difficulty of calculation can be reduced.

[0231] In some embodiments, determining a first input parameter based on a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter includes: setting the reference sample value of the first color component of the current block and the first control parameter as index values ​​of a numeric mapping lookup table, looking up the numeric mapping lookup table to obtain a corresponding array element value; and setting the first input parameter equal to the array element value.

[0232] In addition, in some embodiments, the mapping relationship can also simplify the operation, for example, an array element lookup method can be adopted to reduce some of the calculation operations. Illustratively, a mapping lookup table of the reference sample value of the first color component, the first control parameter, and the array element is preset, the reference sample value of the first color component and the candidate value referring to the first control parameter are taken as index values, the mapping lookup table is looked up to obtain the array element, and then, under a predetermined nonlinear mapping function relationship, a value corresponding to the array element value is determined, and then the weighting coefficient is set equal to the value. The elements of the two-dimensional array storMole[index1][index2] are as shown in Table 1.1, diffY[i][j][k] is index 1, and flagS is index 2. The indexed array element is substituted into Equation 7.

[0233] In some embodiments, determining the weighting coefficient based on the predetermined mapping relationship and the first input parameter includes taking the first input parameter as an input value of the predetermined mapping relationship and setting the weighting coefficient equal to an output value of the predetermined mapping relationship, where the predetermined mapping relationship is a correspondence relationship between the first input parameter and the weighting coefficient, and the value of the weighting coefficient decreases with an increase in the value of the first input parameter. That is, after determining the first input parameter in Equation 4, a function operation is performed to obtain the corresponding weight value.

[0234] In step 804, a predicted value of the second color component of the current block is determined based on the weighting coefficient and a reference sample value of the second color component of the current block.

[0235] In some embodiments, determining a predicted value of the second color component of the current block based on the weighting coefficients and reference sample values ​​of the second color component of the current block includes calculating a weighted sum of the weighting coefficients and reference sample values ​​of the second color component of the current block to determine a predicted value of the second color component of the current block.

[0236] In some embodiments, the step of determining a predicted value of the second color component of the current block based on the weighting coefficients and the reference sample values ​​of the second color component of the current block includes the steps of: calculating a weighted sum of the weighting coefficients and the reference sample values ​​of the second color component of the current block to determine a first predicted value of the second color component of the current block; and performing a filtering process on the first predicted value of the second color component of the current block to determine a predicted value of the current block.

[0237] In some embodiments, the reference sample value of the second color component of the current block is set to an adjacent sample value of the second color component of the current block or a value after filtering the adjacent sample value of the second color component of the current block.

[0238] The adjacent sample value of the second color component is a value obtained according to the reconstructed value of the second color component of the reference pixel, and the reconstructed value of the second color component of the reference pixel is directly used as the adjacent sample value of the second color component, or the reconstructed value of the second color component of the reference pixel is filtered to obtain the adjacent sample value of the second color component. For example, when the second color component is a chrominance component, the reference sample value of the second color component is the reconstructed value of the chrominance component of the reference pixel, or is a value obtained by filtering the reconstructed value of the second color component of the reference pixel. For a specific calculation process, please refer to Equation 8.

[0239] Furthermore, the encoding method further includes a step of performing a correction on the predicted value. pred Correction is performed on [i][j], the chromaticity prediction value should be within the limited range, if it exceeds the limited range, the corresponding correction operation should be performed.

[0240] Moreover, the encoding method further includes performing post-processing on the predicted value. Under certain conditions, the output predWcp of the weight-based chrominance prediction needs to be post-processed to obtain the final chrominance predicted value predSamples, otherwise, the final chrominance predicted value predSamples is predWcp.

[0241] Exemplarily, the post-processing operations include: (1) in the WCP core parameters, if predSizeW is not equal to the width nTbW of the current block, or predSizeH is not equal to the width nTbH of the current block, then it is necessary to perform an up- or down-sampling operation on predWcp to obtain the final chrominance prediction value predSamples.

[0242] (2) In order to reduce instability due to independent parallel prediction for each pixel of WCP, smoothing filtering can be performed on predWcp to obtain the final chromaticity predicted value predSamples.

[0243] (3) In order to further improve the accuracy of the WCP prediction value, a position-related correction process can be performed on predWcp, for example, by using reference pixels in close spatial positions to calculate the chromaticity compensation value of each pixel waiting to be predicted, and then using the chromaticity compensation value to correct predWcp, and the corrected prediction value is the final chromaticity prediction value predSamples.

[0244] (4) In order to further improve the accuracy of the WCP prediction value, the chromaticity prediction value calculated by another chromaticity prediction technique and the chromaticity prediction value predWcp calculated by the WCP can be weighted and fused, and the fusion result can be the final chromaticity prediction value predSamples. For example, the chromaticity prediction value obtained by prediction using the CCLM technique and the chromaticity prediction value predWcp of the WCP can be weighted equally or unevenly, and the weighted result can be the final chromaticity prediction value predSamples.

[0245] (5) To improve the WCP prediction performance, a neural network can be adopted to make corrections to the WCP prediction output predWcp.

[0246] In step 805, a reference value of a prediction difference of the second color component of the current block is determined according to the predicted value and the original value of the second color component of the current block.

[0247] Here, the prediction difference reference value is used to represent the degree of distortion of the predicted value with respect to the original value, and a smaller prediction difference reference value indicates higher prediction accuracy, whereas a larger prediction difference reference value indicates lower prediction accuracy. In the embodiment of the present application, the prediction difference reference value is used to select an optimal control parameter S for the current block from within a control parameter selection range.

[0248] For example, the reference value of the prediction difference is represented based on parameters such as the sum of absolute differences (SAD), the sum of absolute transformed differences (SATD), the sum of squares for errors (SSE), the mean absolute difference (MAD), the mean squared error (MSE), and the rate distortion optimization (RDO). The reference value of the prediction difference is represented by MSE as an example, and the calculation formula for MSE is as follows:

[0249]

number

[0250]

number

[0251] In some embodiments, the step of determining a first control parameter of the current block based on a reference value of a prediction difference of a second color component of the current block comprises a step of determining a minimum reference value based on reference values ​​of the prediction difference corresponding to a plurality of candidate values ​​of the candidate first control parameter, and a step of setting the first control parameter equal to the candidate value corresponding to the minimum reference value.

[0252] It should be explained that each candidate value in the candidate first control parameter corresponds to a reference value of one prediction difference, and in order to make the predicted value closest to the original value, the control parameter corresponding to the smallest reference value of the prediction difference should be selected as the optimal control parameter. Illustratively, the method of selecting the optimal control parameter S_best is to use the S_best variable to record the optimal control parameter S, the MSE_best variable to record the smallest MSE, and the MSE_s variable to record the MSE when the control parameter is s. The process of selecting the optimal control parameter S_best is as follows:

[0253] [Table 20]

[0254] In step 807, the first control parameter of the current block is encoded and the resulting encoded bits are written to a bitstream.

[0255] Here, the first control parameter may be an optimal control parameter determined by the encoding side for the current block, or may be a plurality of candidate first control parameters determined by the encoding side for the current block. The encoding side transmits the first control parameter to the decoding side by a bitstream, and the decoding side calculates weighting coefficients based on the received first control parameters, thereby improving the reliability of the weighting coefficients and further improving the accuracy of color component prediction to a certain extent.

[0256] In some embodiments, encoding the first control parameter of the current block comprises encoding an index parameter of the first control parameter of the current block.

[0257] For option 1, FIG. 9 is a flow chart 2 of the encoding method according to an embodiment of the present application. As shown in FIG. 9, the encoding method includes the following steps:

[0258] S1: Start chrominance prediction for the current block.

[0259] S2: Are you in WCP mode? If yes, execute S4; if no, execute S3.

[0260] S3: Prediction is performed using another chromaticity prediction mode.

[0261] S4: The optimal control parameter S_best is obtained.

[0262] S5: Perform softmax nonlinear mapping using the optimal control parameter S_best for each point to be predicted in all Cb and Cr chromaticity blocks to obtain a weight vector.

[0263] S6: A weighted prediction is performed for the weight vector obtained for each point waiting for prediction and the reference chromaticity point, to obtain a final chromaticity predicted value.

[0264] For example, the decoding side can obtain the optimal control parameter S of the current block by analyzing from the CU layer, and the specific process is as follows:

[0265] [Table 21]

[0266] Sequence Parameter Set (SPS) layer: sps_chroma_format_idc: When it is 0, it indicates that the color component of the current image is a luminance component, and when it is not 0, it indicates that the color component of the current image is a chromaticity component.

[0267] sps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the sps layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0268] Picture Parameter Set (PPS) layer: pps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the pps layer. If the value is 1, it indicates that it is enabled, and if the value is 0, it indicates that it is not enabled.

[0269] Picture Header (PH) layer: ph_wcp_enabled_flag: Indicates whether or not WCP is used in the current image. If this syntax element is not present, it is treated as equal to 0.

[0270] Slice Header (SH) layer: slice_wcp_enabled_flag: Indicates whether or not WCP is currently used in the slice. If this syntax element is not present, it is treated as being equal to 0.

[0271] Coding Unit (CU) layer: wcp_mode_flag: indicates whether or not the WCP is currently used in the CU, with 1 indicating that it is used and 0 indicating that it is not used. If this syntax element does not exist, it is treated as being equal to 0.

[0272] wcp_mode_idx: Represents the index of the current WCP mode.

[0273] wcp_S_Chroma: represents the value of the optimal control parameter S for the Cb and Cr components in the current CU or the index of the optimal control parameter S.

[0274] intra_chroma_pred_mode: represents the current intra prediction mode for the chrominance components. If intra_chroma_pred_mode is not present, it is inferred to be equal to 0.

[0275] In this solution, there is a competitive relationship between the new chromaticity prediction mode such as WCP and other chromaticity prediction modes. A specific analysis of the chromaticity prediction mode wcp_mode_idx mode index is as follows:

[0276] [Table 22]

[0277] For option 2, FIG. 10 is a flow chart 3 of the encoding method according to an embodiment of the present application. As shown in FIG. 10, the encoding method includes the following steps:

[0278] S1: Start chrominance prediction for the current block. S2: Is it WCP mode? If yes, execute S4 to S6 for the Cb component, execute S7 to S9 for the Cr component, and if no, execute S3. S3: Prediction is performed using another chromaticity prediction mode. S4: The optimal control parameter S_best_Cb is obtained. S5: For each prediction-awaiting point in the Cb chromaticity block, perform softmax nonlinear mapping using the optimal control parameter S_best_Cb to obtain a weight vector. S6: A weighted prediction is performed for the weight vector obtained for each point waiting for prediction and the reference chromaticity point, to obtain a final chromaticity predicted value Cb. S7 The optimum control parameter S_best_Cr is obtained. S8: Perform softmax nonlinear mapping using the optimal control parameter S_best_Cr for each point to be predicted in the Cr chrominance block to obtain a weight vector. S9: A weighted prediction is performed for the weight vector obtained for each point waiting for prediction and the reference chromaticity point to obtain a final chromaticity predicted value Cr.

[0279] For example, the decoding side can obtain the optimal control parameter S of the current block in different chrominance components from the CU layer through analysis, and the specific process is as follows:

[0280] [Table 23]

[0281] Sequence Parameter Set (SPS) layer: sps_chroma_format_idc: When it is 0, it indicates that the color component of the current image is a luminance component, and when it is not 0, it indicates that the color component of the current image is a chromaticity component.

[0282] sps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the sps layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0283] Picture Parameter Set (PPS) layer: pps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the pps layer. If the value is 1, it indicates that it is enabled, and if the value is 0, it indicates that it is not enabled.

[0284] Picture Header (PH) layer: ph_wcp_enabled_flag: Indicates whether or not WCP is used in the current image. If this syntax element is not present, it is treated as equal to 0.

[0285] Slice Header (SH) layer: slice_wcp_enabled_flag: Indicates whether or not WCP is currently used in the slice. If this syntax element is not present, it is treated as being equal to 0.

[0286] Coding Unit (CU) layer: wcp_mode_flag: indicates whether or not the WCP is currently used in the CU, with 1 indicating that it is used and 0 indicating that it is not used. If this syntax element does not exist, it is treated as being equal to 0.

[0287] wcp_mode_idx: Represents the index of the current WCP mode.

[0288] wcp_S_Cb: represents the value of the optimal control parameter S for the Cb component in the current CU or the index of the optimal control parameter S.

[0289] wcp_S_Cr: represents the value of the optimal control parameter S of the Cr component in the current CU or the index of the optimal control parameter S.

[0290] intra_chroma_pred_mode: represents the current intra prediction mode for the chrominance components. If intra_chroma_pred_mode is not present, it is inferred to be equal to 0.

[0291] In the embodiment of the present application, the step of determining the candidate first control parameter will be further illustrated by way of an example.

[0292] In some embodiments, the encoding method further comprises determining the candidate first control parameter based on a prediction parameter of the current block, i.e., setting different control parameter selection ranges for different encoding blocks and selecting a matching control parameter selection range based on the prediction parameter of the current block, thereby improving the selection efficiency of the control parameters.

[0293] Exemplarily, in some embodiments, the encoding method further includes determining a selection step length of a candidate first control parameter according to a prediction parameter of the current block. In a subsequent step, the candidate first control parameter is scanned according to the selection step length, a candidate value is selected from the candidate first control parameter each time, a nonlinear mapping is performed using the selected candidate value to obtain a weighting factor, a weighting operation is performed using the weighting factor to obtain a prediction value of all or a part of pixels in the current block, and a reference value of a prediction difference is calculated according to the prediction value and the original value, and this process is continued until the scanning is completed, and an optimal control parameter is determined according to the reference value of a prediction difference corresponding to each obtained candidate value.

[0294] In some embodiments, determining the candidate first control parameters based on the prediction parameters of the current block includes determining the candidate first control parameters corresponding to the current block based on the prediction parameters of the current block based on a correspondence relationship between a predetermined prediction parameter and a candidate first control parameter, that is, pre-setting a correspondence relationship between a prediction parameter and a control parameter selection range, determining a corresponding control parameter selection range based on the prediction parameters of the current block, and further selecting one or more candidate values ​​of the first control parameters from the control parameter selection range.

[0295] In some embodiments, the prediction parameters of the current block include at least a size of the current block, where the size of the current block includes at least one of a height of the current block, a width of the current block, a number of first color component sampling points included in the current block, and a number of second color component sampling points included in the current block, where the first color component sampling points and the second color component sampling points are pixel points in the current block, and the first color component sampling points and the second color component sampling points may be exactly the same pixel points or not exactly the same pixel points.

[0296] In some embodiments, the prediction parameters of the current block include a prediction mode of the current block. It should be noted that in the embodiments of the present application, when determining the candidate control parameter selection range, the prediction parameters may include at least one of a prediction waiting component, a current block size, a prediction mode, and a control parameter index parameter.

[0297] In some embodiments, the encoding method further comprises determining a selection step length of a candidate first control parameter based on a prediction parameter of the current block, where if the control parameter selection range is continuous, setting the selection step length based on the prediction parameter, and scanning all or part of the candidate values ​​in the selection range based on the selection step length.

[0298] It should be noted that the embodiment of the present application can adopt a classification method to determine the selection range of the first control parameter, for example, classifying the current block into three types based on the size parameter of the current block, and determining the selection range of the first control parameter corresponding to each type, or classifying the current block into three types based on the number of sampling points of the current block, and determining the selection range of the first control parameter corresponding to each type.

[0299] For example, in the selection method 3, N types of classification are made based on the block size or the number of pixels in the block, and the corresponding control parameter selection range is determined based on the block type, and for the chrominance components Cb and Cr, similar prediction is made for the Cb and Cr chrominance blocks, and the Cr and Cb components use the same obtained optimal S. Each type of block is given one selection range of control parameters S, the purpose of which is that different types of prediction blocks scan the control parameters S within different selection ranges, and the encoding side scans S within this range with a certain step length D. For example, it is determined based on the minimum and maximum sizes of the encoding chrominance blocks. For example, the classification based on block size is shown in Table 2.6 below.

[0300] [Table 24]

[0301] For example, classification based on the number of pixels W x H in a block is shown in Table 2.7 below.

[0302] [Table 25]

[0303] For option 3, FIG. 11 is a flow chart 4 of the encoding method according to an embodiment of the present application. As shown in FIG. 11, the encoding method includes the following steps:

[0304] S1: Start chrominance prediction for the current block. S2: Are you in WCP mode? If yes, execute S4; if no, execute S3. S3: Prediction is performed using another chromaticity prediction mode. S4: Cb and Cr make similar predictions and classify the current block. S5: Does it belong to the first type? If yes, execute S6; if no, execute S7. S6: Scan S within a predetermined selection range to obtain the optimal control parameter S_best1. S7: Does it belong to the second type? If yes, execute S8; if no, execute S9. S8: Scan S within a predetermined selection range to obtain the optimal control parameter S_best2. S9: Does it belong to the third type? If yes, execute S10; if no, execute S11. S10: Scan S within a predetermined selection range to obtain the optimal control parameter S_best3. In this way, S11: Does it belong to the nth type? If "yes", execute S12, and if "no", execute S3. S12: Scan S within a predetermined selection range to obtain the optimal control parameter S_bestn. S13: Perform softmax nonlinear mapping using the optimal control parameter S_besti for each to-be-predicted point in every Cb and Cr chromaticity block to obtain a weight vector, where i is an integer from 1 to n. S14: Weighted prediction is performed for the weight vectors obtained corresponding to each point awaiting prediction for each type of block and the reference chromaticity points, to obtain a final chromaticity predicted value Cr.

[0305] In the third selection scheme, the decoding side can obtain different types of optimal control parameters S of the current block from the CU layer through analysis. The specific process is as follows:

[0306] [Table 26]

[0307] Sequence Parameter Set (SPS) layer: sps_chroma_format_idc: When it is 0, it indicates that the color component of the current image is a luminance component, and when it is not 0, it indicates that the color component of the current image is a chromaticity component.

[0308] sps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the sps layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0309] Picture Parameter Set (PPS) layer: pps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the pps layer. If the value is 1, it indicates that it is enabled, and if the value is 0, it indicates that it is not enabled.

[0310] Picture Header (PH) layer: ph_wcp_enabled_flag: Indicates whether or not WCP is used in the current image. If this syntax element is not present, it is treated as equal to 0.

[0311] Slice Header (SH) layer: slice_wcp_enabled_flag: Indicates whether or not WCP is currently used in the slice. If this syntax element is not present, it is treated as being equal to 0.

[0312] Coding Unit (CU) layer: wcp_mode_flag: indicates whether or not the WCP is currently used in the CU, with 1 indicating that it is used and 0 indicating that it is not used. If this syntax element does not exist, it is treated as being equal to 0.

[0313] wcp_mode_idx: Represents the index of the current WCP mode.

[0314] wcp_S_Chroma: represents the value of the optimum control parameter S of the nth type of Cb and Cr chromaticity CU or the index of the optimum control parameter S.

[0315] intra_chroma_pred_mode: represents the current intra prediction mode for the chrominance components. If intra_chroma_pred_mode is not present, it is inferred to be equal to 0.

[0316] In selection scheme 3, a new chrominance prediction mode such as WCP is in a competitive relationship with other chrominance prediction modes. The specific analysis of the chrominance prediction mode wcp_mode_idx mode index is the same as selection schemes 1 and 2.

[0317] In the selection method 4, the WCP mode is divided into three modes, WCP, WCP_L, and WCP_T, based on the available reference area, without classifying the block size or the number of pixels in the block. Here, the reference area of ​​the WCP mode is the upper area + the left area, the reference area of ​​the WCP_T mode is the upper area + the upper right area, and the reference area of ​​the WCP_L mode is the left area + the lower left area. For the chrominance components Cb and Cr, similar prediction is performed for the Cb and Cr chrominance blocks, and the Cr and Cb components use the same obtained optimal S. A selection range of one control parameter S is given for each WCP mode, and S is scanned within this range with a certain step length D. For example, as shown in the following Table 2.8.

[0318] [Table 27]

[0319] For option 4, FIG. 12 is a flow chart 5 of an encoding method according to an embodiment of the present application. As shown in FIG. 12, the encoding method includes the following steps:

[0320] S1: Start chrominance prediction for the current block. S2: Is it in WCP mode? If yes, execute S6; if no, execute S3. S3: Is it in WCP_L mode? If yes, execute S6; if no, execute S4. S4: Is it in WCP_T mode? If yes, execute S6; if no, execute S5. S5: Predict using another chromaticity prediction mode. Here, the three chromaticity prediction modes WCP, WCP_L, and WCP_T are in a competitive relationship with the other chromaticity prediction modes. S6: Obtain the optimal control parameters S_best S7: Perform softmax nonlinear mapping using the optimal control parameter S_best for each point to be predicted in all Cb and Cr chromaticity blocks to obtain a weight vector. S8: A weighted prediction is performed for the weight vector obtained for each point waiting for prediction and the reference chromaticity point, to obtain a final chromaticity predicted value.

[0321] In the selection scheme 4, the decoding side can obtain the optimal control parameter S of the current block in different WCP modes by analyzing from the CU layer, and the specific process is as follows:

[0322] [Table 28]

[0323] Sequence Parameter Set (SPS) layer: sps_chroma_format_idc: When it is 0, it indicates that the color component of the current image is a luminance component, and when it is not 0, it indicates that the color component of the current image is a chromaticity component.

[0324] sps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the sps layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0325] Picture Parameter Set (PPS) layer: pps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the pps layer. If the value is 1, it indicates that it is enabled, and if the value is 0, it indicates that it is not enabled.

[0326] Picture Header (PH) layer: ph_wcp_enabled_flag: Indicates whether or not WCP is used in the current image. If this syntax element is not present, it is treated as equal to 0.

[0327] Slice Header (SH) layer: slice_wcp_enabled_flag: Indicates whether or not WCP is currently used in the slice. If this syntax element is not present, it is treated as being equal to 0.

[0328] Coding Unit (CU) layer: wcp_mode_flag: indicates whether or not the WCP is currently used in the CU, with 1 indicating that it is used and 0 indicating that it is not used. If this syntax element does not exist, it is treated as being equal to 0.

[0329] wcp_mode_idx: Represents the index of the current WCP mode.

[0330] wcp_S_Chroma: represents the value of the optimal control parameter S for the Cb and Cr components in the current CU or the index of the optimal control parameter S.

[0331] intra_chroma_pred_mode: represents the current intra prediction mode for the chrominance components. If intra_chroma_pred_mode is not present, it is inferred to be equal to 0.

[0332] In the selection scheme 4, the three new chromaticity prediction modes WCP, WCP_L, and WCP_T are in a competitive relationship with other chromaticity prediction modes. A specific analysis of the mode index of the chromaticity prediction mode wcp_mode_idx is as follows:

[0333] [Table 29]

[0334] In the selection method 5, the WCP mode is divided into three modes, WCP, WCP_L, and WCP_T, based on the available reference area. Here, the reference area of ​​the WCP mode is the upper area + the left area, the reference area of ​​the WCP_T mode is the upper area + the upper right area, and the reference area of ​​the WCP_L mode is the left area + the lower left area. For each WCP mode, N types of classification are performed based on the block size or the number of pixels in the block, and the corresponding control parameter selection range is determined based on the block type, and it should be noted that the number of classifications N in different WCP modes can be the same or different, and the classification manner can be the same or different. Each type of block is given a selection range of one control parameter S, the purpose of which is that different types of prediction blocks scan the control parameters S in different selection ranges, and the encoding side scans S in this range with a certain step length D. Here, for the chrominance components Cb and Cr, similar prediction is performed for the Cb and Cr chrominance blocks, and the Cr and Cb components use the same optimal S obtained. For example, the block size classification for different WCP modes is shown in Table 2.9 below.

[0335] [Table 30]

[0336] A classification can also be made based on the number of pixels in a block W×H for different WCP modes, as shown in Table 2.10 below.

[0337] [Table 31]

[0338] For option 5, FIG. 13 is a flow chart 6 of an encoding method according to an embodiment of the present application. As shown in FIG. 13, the encoding method includes the following steps:

[0339] S1: Start chrominance prediction for the current block. S2: Is it in WCP mode? If yes, execute S6; if no, execute S3 S3: Is it in WCP_L mode? If yes, execute S6; if no, execute S4. S4: Is it in WCP_T mode? If yes, execute S6; if no, execute S5. S5: Predict using another chromaticity prediction mode. S6: Cb and Cr make similar predictions and classify the current block. S7: Does it belong to the first type? If yes, execute S8; if no, execute S9. S8: Scan S within a predetermined selection range to obtain the optimal control parameter S_best1. S9: Does it belong to the second type? If yes, execute S10; if no, execute S11. S10: Scan S within a predetermined selection range to obtain the optimal control parameter S_best2. S11: Does it belong to the third type? If yes, execute S12; if no, execute S13. S12: Scan S within a predetermined selection range to obtain the optimal control parameter S_best3. This is how we infer it. S13: Does it belong to the nth type? If "yes", execute S14, and if "no", execute S5. S14: Scan S within a predetermined selection range to obtain the optimal control parameter S_bestn. S15: Perform softmax nonlinear mapping using the optimal control parameter S_besti for each to-be-predicted point in every Cb and Cr chromaticity block to obtain a weight vector, where i is an integer from 1 to n. S16: Weighted prediction is performed for the weight vectors obtained corresponding to each point awaiting prediction for each type of block and the reference chromaticity points, to obtain a final chromaticity predicted value.

[0340] In the selection scheme 5, the decoding side can obtain different types of optimal control parameters S of the current block in different WCP modes from the CU layer through analysis, and the specific process is as follows:

[0341] [Table 32]

[0342] Sequence Parameter Set (SPS) layer: sps_chroma_format_idc: When it is 0, it indicates that the color component of the current image is a luminance component, and when it is not 0, it indicates that the color component of the current image is a chromaticity component.

[0343] sps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the sps layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0344] Picture Parameter Set (PPS) layer: pps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the pps layer. If the value is 1, it indicates that it is enabled, and if the value is 0, it indicates that it is not enabled.

[0345] Picture Header (PH) layer: ph_wcp_enabled_flag: Indicates whether or not WCP is used in the current image. If this syntax element is not present, it is treated as equal to 0.

[0346] Slice Header (SH) layer: slice_wcp_enabled_flag: Indicates whether or not WCP is currently used in the slice. If this syntax element is not present, it is treated as being equal to 0.

[0347] Coding Unit (CU) layer: wcp_mode_flag: indicates whether or not the WCP is currently used in the CU, with 1 indicating that it is used and 0 indicating that it is not used. If this syntax element does not exist, it is treated as being equal to 0.

[0348] wcp_mode_idx: Represents the index of the current WCP mode.

[0349] wcp_S_Chroma: represents the value of the optimum control parameter S of the nth type of Cb and Cr chromaticity CU or the index of the optimum control parameter S.

[0350] intra_chroma_pred_mode: represents the current intra prediction mode for the chrominance components. If intra_chroma_pred_mode is not present, it is inferred to be equal to 0.

[0351] In the selection scheme 5, the three new chromaticity prediction modes WCP, WCP_L, and WCP_T are in a competitive relationship with other chromaticity prediction modes. The specific analysis of the chromaticity prediction mode wcp_mode_idx mode index is the same as in the selection scheme 4.

[0352] It should be noted that, in the above selection methods 3 to 5, for the chromaticity components Cb and Cr, similar predictions are made for the Cb and Cr chromaticity blocks, and the Cr and Cb components use the same obtained optimal S to make predictions for the Cb and Cr components respectively, and each of the Cb and Cr components obtains its own optimal S by scanning.

[0353] In the embodiment of the present application, in addition to being transmitted at the CU layer in the bitstream, the optimal control parameter S can also be obtained by introducing original values ​​of coded blocks into the SPS, PPS, APS, PH, SH, CTU, etc. layers in the bitstream to perform distortion cost calculations, and then transmitting the optimal control parameter S.

[0354] When transmitting at the SPS layer: frames of the same sequence adopt the same S, and the syntactic semantics are as follows:

[0355] [Table 33]

[0356] sps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the sps layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0357] wcp_S_Chroma: Represents the value of the optimal control parameter S of the current sequence or the index of the optimal control parameter S.

[0358] When transmitted at the PPS layer: the same frame adopts the same S, and the syntactic semantics are as follows:

[0359] [Table 34] sps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the sps layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0360] pps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the pps layer. If the value is 1, it indicates that it is enabled, and if the value is 0, it indicates that it is not enabled.

[0361] wcp_S_Chroma: Represents the value of the optimal control parameter S of the current frame or the index of the optimal control parameter S.

[0362] When transmitting at the APS layer: The same frame adopts the same S, and the APS parameter type WCP_APS can be added to the APS layer. If aps_params_type is WCP_APS, the syntax structure of wcp_data() is analyzed. wcp_data() contains the control parameter set of WCP, and the control parameter set contains some typical control parameters S. An example with three control parameters in the control parameter set is shown in Table 2.11 below.

[0363] [Table 35]

[0364] The encoding side introduces the original values ​​of the currently encoded block, and selects the optimal control parameter values ​​from the control parameter set according to the distortion cost, such as SAD, SATD, MSE, etc.

[0365] The decoder obtains the optimal control parameters S corresponding to the WCP by parsing the wcp_data() in the APS layer. The syntactic semantics are as follows:

[0366] [Table 36]

[0367] sps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the sps layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0368] aps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the aps layer. If the value is 1, it indicates that it is enabled, and if the value is 0, it indicates that it is not enabled.

[0369] WCP_APS: Indicates that the APS parameter type is WCP_APS.

[0370] wcp_S_Chroma: Represents the value of the optimal control parameter S of the current frame or the index of the optimal control parameter S.

[0371] When transmitting at the PH layer: the same image adopts the same S, and the syntactic semantics are as follows:

[0372] [Table 37]

[0373] sps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the sps layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0374] pps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the pps layer. If the value is 1, it indicates that it is enabled, and if the value is 0, it indicates that it is not enabled.

[0375] ph_wcp_enabled_flag: Indicates whether or not WCP is enabled in the picture header layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0376] wcp_S_Chroma: Represents the value of the optimal control parameter S of the current frame or the index of the optimal control parameter S.

[0377] When transmitted in the SH layer: The same slice adopts the same S, and the syntactic semantics are as follows.

[0378] [Table 38]

[0379] sps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the sps layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0380] pps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the pps layer. If the value is 1, it indicates that it is enabled, and if the value is 0, it indicates that it is not enabled.

[0381] ph_wcp_enabled_flag: Indicates whether or not WCP is enabled in the picture header layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0382] sh_wcp_enabled_flag: Indicates whether or not WCP is enabled in the slice header layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0383] wcp_S_Chroma: Represents the value of the optimal control parameter S of the current frame or the index of the optimal control parameter S.

[0384] When transmitted at the CTU layer: the same CTU adopts the same S, and the syntactic semantics are as follows:

[0385] [Table 39]

[0386] sps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the sps layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0387] pps_wcp_enabled_flag: Indicates whether or not WCP is enabled in the pps layer. If the value is 1, it indicates that it is enabled, and if the value is 0, it indicates that it is not enabled.

[0388] ph_wcp_enabled_flag: Indicates whether or not WCP is enabled in the picture header layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0389] sh_wcp_enabled_flag: Indicates whether or not WCP is enabled in the slice header layer. If the value is 1, it is enabled, and if the value is 0, it is not enabled.

[0390] wcp_ctb_flag[CtbAddrX][CtbAddrY]: Indicates whether or not WCP is currently enabled in the CTU. If the value is 1, it indicates that it is enabled, and if the value is 0, it indicates that it is not enabled.

[0391] wcp_S_Chroma: Represents the value of the optimal control parameter S of the current CTU or the index of the optimal control parameter S.

[0392] By adopting the above technical solution, the weighting coefficient is calculated according to the adjacent area reference point and the luminance information of the current block, and the weighting coefficient is involved in the chrominance prediction of the current coding block, so that the correlation between the luminance information of the current coding block and the adjacent reference area is fully utilized, and the correlation is involved in the chrominance prediction of the current coding block, so that the accuracy of the chrominance prediction can be improved. At the same time, the original value of the current block is introduced into the larger control parameter selection, and the coding side selects the optimal control parameter S according to the difference between the original value and the predicted value, and the optimal control parameter S is transmitted to the decoding side by the bitstream, so that the mapping ability of the nonlinear mapping model is improved, the reliability of the reference pixel weight is increased, and the accuracy of the chrominance prediction can be further improved to a certain extent.

[0393] In another embodiment of the present application, the embodiment of the present application further provides a bitstream, wherein the bitstream is generated by bit encoding based on the encoding to-be-encoded information, where the encoding to-be-encoded information includes at least a first control parameter of the current block.

[0394] In some embodiments, the encoding-to-be-predicted information further includes a correspondence relationship based on a predetermined prediction parameter and the first control parameter. Exemplarily, the prediction parameter includes at least one of a prediction-to-be-predicted component, a current block size, a prediction mode, and an index parameter of a control parameter. Here, the size of the current block includes at least one of a height of the current block, a width of the current block, a number of first color component sampling points included in the current block, and a number of second color component sampling points included in the current block. Here, the first color component sampling point and the second color component sampling point are pixel points to be predicted in the current block, and the first color component sampling point and the second color component sampling point may be completely the same pixel point or not completely the same pixel point. In this way, the encoding side can increase the reliability of the weighting coefficient and improve the accuracy of chromaticity prediction to a certain extent by transmitting the first control parameter to the decoding side by a bit stream.

[0395] In another embodiment of the present application, please refer to Figure 14, which is a schematic diagram showing the configuration of an encoding device according to an embodiment of the present application. As shown in Figure 14, the encoding device 140 includes a first determination unit 1401, a first calculation unit 1402, a first prediction unit 1403, and an encoding unit 1404; The first determining unit 1401 is configured to determine a candidate first control parameter of a current block; The first calculation unit 1402 is configured to determine a reference sample value of a first color component of the current block; and determine a weighting coefficient based on the reference sample value of the first color component of the current block and a candidate value in the candidate first control parameter; the first prediction unit 1403 is configured to determine a predicted value of a second color component of the current block according to the weighting coefficient and a reference sample value of a second color component of the current block; determine a reference value of a prediction difference of the second color component of the current block according to the predicted value and an original value of the second color component of the current block; and determine a first control parameter of the current block according to the reference value of the prediction difference of the second color component of the current block; The encoding unit 1404 is configured to encode the first control parameter of the current block and write the resulting encoded bits into a bitstream.

[0396] In some embodiments, the candidate first control parameters include a plurality of candidate values ​​for the first control parameter.

[0397] In some embodiments, the candidate first control parameters are determined based on prediction parameters of the current block.

[0398] In some embodiments, the prediction parameters for the current block include at least a size of the current block, where the size of the current block includes at least one of a height of the current block, a width of the current block, a number of first color component sampling points included in the current block, and a number of second color component sampling points included in the current block.

[0399] In some embodiments, the prediction parameters for the current block include a prediction mode for the current block.

[0400] In some embodiments, the first determination unit 1401 is configured to determine a candidate first control parameter corresponding to the current block based on the prediction parameters of the current block based on a correspondence relationship between a predetermined prediction parameter and a candidate first control parameter.

[0401] In some embodiments, the first calculation unit 1402 is configured to determine a reference sample value of the first color component of the current block based on adjacent sample values ​​of the first color component of the current block and a reconstructed value of the first color component of the current block.

[0402] In some embodiments, the first calculation unit 1402 is configured to set a reference sample value of a first color component of the current block equal to an absolute value of a difference between a first block reference value and a first neighboring reference value, where the first block reference value is a reconstructed value of the first color component of the current block or a filtered value of the reconstructed value of the first color component of the current block, and the first neighboring reference value is a neighboring sample value of the first color component of the current block or a filtered value of the neighboring sample value of the first color component of the current block.

[0403] In some embodiments, the first calculation unit 1402 is configured to determine a first input parameter based on a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter, and to determine the weighting coefficient based on a predetermined mapping relationship and the first input parameter.

[0404] In some embodiments, the first calculation unit 1402 is configured to set the first input parameter equal to a ratio between a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter.

[0405] In some embodiments, the first calculation unit 1402 is configured to set the first input parameter equal to the product of a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter.

[0406] In some embodiments, the first calculation unit 1402 is configured to set the first input parameter equal to a value of a reference sample value of a first color component of the current block after right shifting it by S bits, where the value of S is determined based on a candidate value in the candidate first control parameter.

[0407] In some embodiments, the value of S is set equal to the candidate value in the candidate first control parameter.

[0408] In some embodiments, the first calculation unit 1402 is configured to take the reference sample value of the first color component of the current block and the first control parameter as index values ​​of a numerical mapping lookup table, look up the numerical mapping lookup table to obtain a corresponding array element value, and set the first input parameter equal to the array element value.

[0409] In some embodiments, the first calculation unit 1402 is configured to take the first input parameter as an input value of the predefined mapping relationship and set the weighting coefficient equal to an output value of the predefined mapping relationship, the predefined mapping relationship being a correspondence relationship between the first input parameter and the weighting coefficient, and the value of the weighting coefficient decreases with an increase in the value of the first input parameter.

[0410] In some embodiments, the predetermined mapping relationship is a softmax function.

[0411] In some embodiments, the first prediction unit 1403 is configured to calculate a weighted sum of the weighting coefficient and a reference sample value of the second color component of the current block to determine a predicted value of the second color component of the current block.

[0412] In some embodiments, the first prediction unit 1403 is configured to calculate a weighted sum of the weighting coefficient and a reference sample value of the second color component of the current block to determine a first predicted value of the second color component of the current block, and perform a filtering process on the first predicted value of the second color component of the current block to determine a predicted value of the current block.

[0413] In some embodiments, the first prediction unit 1403 is configured to determine a reference sample value of a second color component of the current block based on neighboring sample values ​​of a second color component of the current block.

[0414] In some embodiments, the first prediction unit 1403 is configured to set a reference sample value of the second color component of the current block to a neighboring sample value of the second color component of the current block or a value after filtering the neighboring sample value of the second color component of the current block.

[0415] In some embodiments, the first prediction unit 1403 is configured to determine a reference value of a prediction difference of the second color component of the current block based on a difference between the predicted value and an original value of the second color component of the current block.

[0416] In some embodiments, the first prediction unit 1403 is configured to determine a minimum reference value based on reference values ​​of the prediction difference corresponding to a plurality of candidate values ​​of the candidate first control parameter, and to set the first control parameter equal to the candidate value corresponding to the minimum reference value.

[0417] In some embodiments, encoding unit 1404 is configured to encode the first control parameter of the current block in a block layer or higher data unit in the bitstream.

[0418] In some embodiments, the block layer or higher data units include at least one of a parameter set data unit, a picture header data unit, a slice header data unit, a coding tree data unit, and a current block data unit.

[0419] In some embodiments, one or more of the candidate values ​​of the first control parameter are encoded in the first control parameter.

[0420] In some embodiments, the encoding unit 1404 is configured to encode a correspondence between a predetermined prediction parameter and a first control parameter in a parameter set data unit in the bitstream, the parameter set corresponding to the parameter set data unit being a parameter set referenced directly or indirectly by a slice, the slice including the current block.

[0421] In some embodiments, the parameter sets referenced directly or indirectly by the slices include at least one of a sequence parameter set, a picture parameter set, and an adaptation parameter set.

[0422] In some embodiments, encoding unit 1404 is configured to encode the correspondence between the predetermined prediction parameter and the first control parameter in a slice header data unit in the bitstream.

[0423] In some embodiments, the encoding unit 1404 is configured to encode a correspondence between the predetermined prediction parameter and the first control parameter in an image header data unit in the bitstream, the image corresponding to the image header data unit including the slice.

[0424] In practical application, the embodiment of the present application further provides an encoding device. FIG. 15 is a schematic diagram showing a specific hardware configuration of the encoding device according to the embodiment of the present application. As shown in FIG. 15, the encoding device 150 includes: The device comprises a first memory 1501 and a first processor 1502. The first memory 1501 stores a computer program executable by the first processor 1502. When the first processor 1502 executes the program, it executes an encoding method on the encoder side.

[0425] In practical application, the encoding device further comprises a first communication interface configured to transmit and receive signals in the process of transmitting and receiving information with other external network elements.

[0426] By adopting the above-mentioned encoding device or encoding equipment, the weighting coefficient is calculated according to the adjacent area reference point and the luminance information of the current block, and the weighting coefficient is involved in the chrominance prediction of the current coding block, so that the correlation between the luminance information of the current coding block and the adjacent reference area is fully utilized, and the correlation is involved in the chrominance prediction of the current coding block, so that the accuracy of the chrominance prediction can be improved. At the same time, the original value of the current block is introduced into the larger control parameter selection, and the encoding side selects the optimal control parameter S according to the difference between the original value and the predicted value, and the optimal control parameter S is transmitted to the decoding side by the bit stream, so that the mapping ability of the nonlinear mapping model is improved, the reliability of the reference pixel weight is increased, and the accuracy of the chrominance prediction can be further improved to a certain extent.

[0427] In another embodiment of the present application, refer to Fig. 16, which is a schematic diagram showing a configuration of a decoding device according to an embodiment of the present application. As shown in Fig. 16, the decoding device 160 may include a decoding unit 1601, a second calculation unit 1602, and a second prediction unit 1603.

[0428] The decoding unit 1601 is configured to decode the bitstream and determine a first control parameter of a current block; a second calculation unit 1602 configured to determine a reference sample value of a first color component of the current block; determine a weighting coefficient based on the reference sample value of the first color component of the current block and the first control parameter; and determine a predicted value of the second color component of the current block based on the weighting coefficient and the reference sample value of the second color component of the current block; The second prediction unit 1603 is configured to determine, based on the predicted value of the second color component of the current block, a reconstructed value of a sampling point of the second color component of the current block.

[0429] In some embodiments, the decoding unit 1601 is configured to decode data units at or above the block layer in the bitstream to determine candidate first control parameters, and to determine the first control parameters based on the candidate first control parameters.

[0430] In some embodiments, the block layer or higher data units include at least one of a parameter set data unit, a picture header data unit, a slice header data unit, a coding tree data unit, and a current block data unit.

[0431] In some embodiments, the candidate first control parameters include candidate values ​​for one or more of the first control parameters.

[0432] In some embodiments, the decoding unit 1601 is configured to determine the first control parameter from among the candidate first control parameters based on prediction parameters of the current block.

[0433] In some embodiments, the prediction parameters for the current block include at least a size of the current block, where the size of the current block includes at least one of a height of the current block, a width of the current block, a number of first color component sampling points included in the current block, and a number of second color component sampling points included in the current block.

[0434] In some embodiments, the prediction parameters for the current block include a prediction mode for the current block.

[0435] In some embodiments, the prediction parameters of the current block include an index parameter of the first control parameter.

[0436] In some embodiments, the decoding unit 1601 is configured to determine the first control parameter from among the candidate first control parameters based on the prediction parameters of the current block based on a correspondence between a predetermined prediction parameter and a first control parameter.

[0437] In some embodiments, the first control parameter is set equal to a first control parameter that corresponds to a prediction parameter of the current block in the candidate first control parameter set.

[0438] In some embodiments, the decoding unit 1601 is configured to perform the steps of decoding a slice header data unit in the bitstream and determining a parameter set directly or indirectly referenced by a slice, the slice corresponding to the slice header data unit including the current block, and determining a correspondence between the predetermined prediction parameter and a first control parameter based on the parameter set directly or indirectly referenced by the slice.

[0439] In some embodiments, the parameter sets referenced directly or indirectly by the slices include at least one of a sequence parameter set, a picture parameter set, and an adaptation parameter set.

[0440] In some embodiments, the decoding unit 1601 is configured to decode the slice header data unit and update the correspondence between the predefined prediction parameters and a first control parameter.

[0441] In some embodiments, the decoding unit 1601 is configured to decode an image header data unit in the bitstream and update a correspondence between the predetermined prediction parameters and a first control parameter, and an image corresponding to the image header data unit includes the slice.

[0442] In some embodiments, the second calculation unit 1602 is configured to determine a reference sample value of the first color component of the current block based on adjacent sample values ​​of the first color component of the current block and a reconstructed value of the first color component of the current block.

[0443] In some embodiments, the second calculation unit 1602 is configured to set a reference sample value of the first color component of the current block equal to an absolute value of a difference between a first block reference value and a first neighboring reference value, where the first block reference value is a reconstructed value of the first color component of the current block or a filtered value of the reconstructed value of the first color component of the current block, and the first neighboring reference value is a neighboring sample value of the first color component of the current block or a filtered value of the neighboring sample value of the first color component of the current block.

[0444] In some embodiments, the second calculation unit 1602 is configured to determine a first input parameter based on a reference sample value of a first color component of the current block and the first control parameter, and to determine the weighting coefficient based on a predetermined mapping relationship and the first input parameter.

[0445] In some embodiments, the second calculation unit 1602 is configured to set the first input parameter equal to a ratio between a reference sample value of a first color component of the current block and the first control parameter.

[0446] In some embodiments, the second calculation unit 1602 is configured to set the first input parameter equal to a product of a reference sample value of a first color component of the current block and the first control parameter.

[0447] In some embodiments, the second calculation unit 1602 is configured to set the first input parameter equal to a reference sample value of a first color component of the current block after being right-shifted by S bits, the value of S being determined based on the first control parameter.

[0448] In some embodiments, the second calculation unit 1602 is configured to set a value of S equal to the first control parameter.

[0449] In some embodiments, the second calculation unit 1602 is configured to take the reference sample value of the first color component of the current block and the first control parameter as index values ​​of a numerical mapping lookup table, look up the numerical mapping lookup table to obtain a corresponding array element value, and set the first input parameter equal to the array element value.

[0450] In some embodiments, the second calculation unit 1602 is configured to take the first input parameter as an input value of the predefined mapping relationship and set the weighting coefficient equal to an output value of the predefined mapping relationship, the predefined mapping relationship being a correspondence relationship between the first input parameter and the weighting coefficient, and the value of the weighting coefficient decreases as the value of the first input parameter increases.

[0451] In some embodiments, the predetermined mapping relationship is a softmax function.

[0452] In some embodiments, the second prediction unit 1603 is configured to calculate a weighted sum of the weighting coefficient and a reference sample value of the second color component of the current block to determine a predicted value of the second color component of the current block.

[0453] In some embodiments, the second prediction unit 1603 is configured to calculate a weighted sum of the weighting coefficient and a reference sample value of the second color component of the current block to determine a first predicted value of the second color component of the current block, and to perform a filtering process on the first predicted value of the second color component of the current block to determine a predicted value of the current block.

[0454] In some embodiments, the second prediction unit 1603 is configured to determine a reference sample value of a second color component of the current block based on neighboring sample values ​​of the second color component of the current block.

[0455] In some embodiments, the reference sample value of the second color component of the current block is set to an adjacent sample value of the second color component of the current block or a value after filtering the adjacent sample value of the second color component of the current block.

[0456] In some embodiments, the decoding unit 1601 is configured to decode the bitstream to determine a reconstructed value of a prediction difference of a second color component of the current block; The second prediction unit 1603 is configured to determine a reconstructed value of a sampling point of the second color component of the current block based on the sum of the predicted value of the second color component of the current block and the reconstructed value of the second color component prediction difference of the current block.

[0457] In practical application, the embodiment of the present application further provides a decoding device. FIG. 17 is a schematic diagram showing a specific hardware configuration of the decoding device according to the embodiment of the present application. As shown in FIG. 17, the decoding device 170 includes: The device comprises a second memory 1701 and a second processor 1702, the second memory 1701 storing a computer program executable by the second processor 1702, the second processor 1702 executing the program to perform a decoding method on the decoder side.

[0458] In practical application, the decoding device may further comprise a second communication interface configured to send and receive signals in the process of sending and receiving information with other external network elements.

[0459] The above-mentioned decoding device or decoding device is adopted to calculate a weighting factor according to the adjacent area reference point and the luminance information of the current block, and the weighting factor is involved in the chrominance prediction of the current coding block, so that the correlation between the luminance information of the current coding block and the adjacent reference area is fully utilized, and the correlation is involved in the chrominance prediction of the current coding block, so that the accuracy of the chrominance prediction can be improved. The decoding side receives the optimal control parameter or the candidate control parameter through the bitstream, and uses the control parameter in the bitstream to improve the mapping ability of the nonlinear mapping model, increase the reliability of the reference pixel weight, and further improve the accuracy of the chrominance prediction to a certain extent.

[0460] In addition, each functional module 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 integrated unit may be realized in the form of hardware or in the form of a software functional module.

[0461] In another embodiment of the present application, reference is made to Fig. 18, which is a schematic diagram showing a configuration of a codec system according to an embodiment of the present application. As shown in Fig. 18, a codec system 180 may include an encoder 1801 and a decoder 1802. Here, the encoder 1801 may be a device incorporating the encoding device 140 described in the previous embodiment, or may be a device incorporating the encoding device 150 described in the previous embodiment, and the decoder 1802 may be a device incorporating the decoding device 160 described in the previous embodiment, or may be a device incorporating the decoding device 170 described in the previous embodiment.

[0462] In an embodiment of the present application, in the codec system 180, both the encoder 1801 and the decoder 1802 can use color component information of adjacent reference pixels and pixels waiting to be predicted to realize calculation of weighting coefficients corresponding to pixels waiting to be predicted, and different reference pixels may have different weighting coefficients. By applying the weighting coefficients to the chrominance prediction of pixels waiting to be predicted in the current block, the accuracy of chrominance prediction can be improved, and bitrate can be saved, as well as codec performance can be improved.

[0463] Correspondingly, an embodiment of the present invention provides a computer storage medium, the computer storage medium storing a computer program, the computer program, when executed by a first processor, implementing an encoding method of an encoder, or the computer program, when executed by a second processor, implementing a decoding method of a decoder.

[0464] It should be noted that the above description of the storage medium and device embodiments is similar to the description of the above method embodiments, and has similar beneficial effects as the method embodiments. The technical details not disclosed in the storage medium and device embodiments of the present application can be understood by referring to the description of the method embodiments of the present application.

[0465] It should be clarified that the terms "first", "second", etc. are not intended to limit the description to a particular order or chronology, but rather to distinguish between similar objects.

[0466] The methods disclosed in some method examples provided herein can be arbitrarily combined without contradiction to obtain new method examples. The features disclosed in some product examples provided herein can be arbitrarily combined without contradiction to obtain new product examples. The features disclosed in some method or device examples provided herein can be arbitrarily combined without contradiction to obtain new method examples or device examples. The above content is merely an embodiment of the present invention, and the protection scope of the present invention is not limited thereto. Any modifications or replacements that can be easily conceived by a person skilled in the art within the technical scope disclosed in the present invention should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims. [Industrial Applicability]

[0467] The present application provides an encoding and decoding method, an apparatus, an encoding device, a decoding device, and a storage medium, and the decoding method includes the steps of: decoding a bitstream, determining a first control parameter of a current block, determining a reference sample value of a first color component of the current block, determining a weighting factor based on the reference sample value of the first color component of the current block and the first control parameter, determining a predicted value of a second color component of the current block based on the weighting factor and the reference sample value of a second color component of the current block, and determining a reconstructed value of a sampling point of the second color component of the current block based on the predicted value of the second color component of the current block. In this way, both the encoding side and the decoding side calculate a weighting factor corresponding to a pixel to be predicted in the current block, and apply the weighting factor to the color component prediction of a pixel to be predicted in the current block, thereby improving the accuracy of prediction, saving the bit rate, and improving the codec performance. In addition, the encoding side transmits the first control parameter to the decoding side in the bitstream, thereby improving the reliability of the weighting factor and further improving the accuracy of the color component prediction to a certain extent.

Claims

1. 1. A method of decoding, comprising: decoding the bitstream and determining a first control parameter for a current block; determining a reference sample value of a first color component of the current block; determining a weighting factor based on a reference sample value of a first color component of the current block and the first control parameter; determining a predicted value of a second color component of the current block based on the weighting coefficient and a reference sample value of the second color component of the current block; determining reconstructed values ​​of sampling points of a second color component of the current block based on predicted values ​​of the second color component of the current block.

2. The step of decoding the bitstream and determining a first control parameter of a current block comprises: decoding block layer or higher data units in the bitstream to determine candidate first control parameters; determining the first control parameter based on the candidate first control parameter; The method of decoding according to claim 1 .

3. The decoding method includes: The data units at or above the block layer include at least one of a parameter set data unit, an image header data unit, a slice header data unit, a coding tree data unit, and a current block data unit. The decoding method according to claim 2.

4. the candidate first control parameters include one or more candidate values ​​of the first control parameters; The decoding method according to claim 2.

5. The step of determining the first control parameter based on the candidate first control parameter includes: determining the first control parameter from among the candidate first control parameters based on a prediction parameter of the current block; The decoding method according to claim 2.

6. the prediction parameters of the current block include at least a size of the current block, the size of the current block including at least one of a height of the current block, a width of the current block, a number of first color component sampling points included in the current block, and a number of second color component sampling points included in the current block; The decoding method according to claim 5.

7. The prediction parameters of the current block include a prediction mode of the current block. The decoding method according to claim 5.

8. The prediction parameters of the current block include an index parameter of a first control parameter. The decoding method according to claim 5.

9. The step of determining the first control parameter from among the candidate first control parameters based on the prediction parameters of the current block includes: determining the first control parameter from among the candidate first control parameters based on a prediction parameter of the current block based on a correspondence relationship between a predetermined prediction parameter and a first control parameter; The decoding method according to claim 5.

10. The decoding method includes: setting the first control parameter equal to a first control parameter corresponding to a prediction parameter of the current block in the candidate first control parameter set. The decoding method according to claim 9.

11. The decoding method includes: decoding a slice header data unit in the bitstream and determining a parameter set referenced directly or indirectly by a slice, the slice corresponding to the slice header data unit containing the current block; determining a correspondence between the predetermined prediction parameters and a first control parameter based on a parameter set referenced directly or indirectly by the slice; The decoding method according to claim 9.

12. The parameter sets referenced directly or indirectly by the slices include at least one of a sequence parameter set, an image parameter set, and an adaptation parameter set. The method of decoding according to claim 11.

13. The decoding method includes: and further comprising the step of: decoding the slice header data unit; and updating a correspondence between the predetermined prediction parameter and a first control parameter. The method of decoding according to claim 11.

14. The decoding method includes: and further comprising the step of: decoding a picture header data unit in the bitstream and updating a correspondence between the predetermined prediction parameters and a first control parameter, wherein a picture corresponding to the picture header data unit includes the slice. The method of decoding according to claim 13.

15. The step of determining a reference sample value of a first color component of the current block includes: determining a reference sample value of a first color component of the current block based on adjacent sample values ​​of the first color component of the current block and a reconstructed value of the first color component of the current block; The method of decoding according to claim 1 .

16. The decoding method includes: The method further includes the step of setting a reference sample value of a first color component of the current block equal to an absolute value of a difference between a first intra-block reference value and a first adjacent reference value; the first intra-block reference value is a reconstructed value of the first color component of the current block or a value obtained after a filtering process of the reconstructed value of the first color component of the current block, and the first neighboring reference value is a neighboring sample value of the first color component of the current block or a value obtained after a filtering process of the neighboring sample value of the first color component of the current block.

16. The method of decoding according to claim 15.

17. determining a weighting coefficient based on the reference sample value of the first color component of the current block and the first control parameter, determining a first input parameter based on a reference sample value of a first color component of the current block and the first control parameter; determining the weighting coefficients based on a predetermined mapping relationship and the first input parameter. The method of decoding according to claim 1 .

18. determining a first input parameter based on a reference sample value of a first color component of the current block and the first control parameter, setting said first input parameter equal to a ratio of a reference sample value of a first color component of said current block to said first control parameter; 18. The method of decoding according to claim 17.

19. determining a first input parameter based on a reference sample value of a first color component of the current block and the first control parameter, setting said first input parameter equal to a product of a reference sample value of a first color component of said current block and said first control parameter; 18. The method of decoding according to claim 17.

20. determining a first input parameter based on a reference sample value of a first color component of the current block and the first control parameter, setting the first input parameter equal to a reference sample value of a first color component of the current block after right-shifting it by S bits, the value of S being determined based on the first control parameter; 18. The method of decoding according to claim 17.

21. The decoding method includes: setting a value of S equal to the first control parameter.

21. The method of decoding according to claim 20.

22. determining a first input parameter based on a reference sample value of a first color component of the current block and the first control parameter, taking the reference sample value of the first color component of the current block and the first control parameter as index values ​​of a numerical mapping lookup table, and looking up the numerical mapping lookup table to obtain corresponding array element values; setting the first input parameter equal to the array element value; 18. The method of decoding according to claim 17.

23. determining the weighting coefficients based on the predetermined mapping relationship and the first input parameter, the first input parameter being an input value of the predetermined mapping relationship, and the weighting factor being set equal to an output value of the predetermined mapping relationship, the predetermined mapping relationship being a correspondence relationship between the first input parameter and the weighting factor, the value of the weighting factor decreasing with increasing value of the first input parameter; 18. The method of decoding according to claim 17.

24. The predetermined mapping relationship is a softmax function.

24. The method of decoding according to claim 23.

25. determining a predicted value of a second color component of the current block based on the weighting coefficient and a reference sample value of the second color component of the current block, calculating a weighted sum of the weighting coefficients and reference sample values ​​of a second color component of the current block to determine a predicted value of the second color component of the current block; The method of decoding according to claim 1 .

26. determining a predicted value of a second color component of the current block based on the weighting coefficient and a reference sample value of the second color component of the current block, calculating a weighted sum of the weighting coefficient and a reference sample value of a second color component of the current block to determine a first predicted value of the second color component of the current block; filtering a first predicted value of a second color component of the current block to determine a predicted value of the current block; The method of decoding according to claim 1 .

27. The decoding method includes: determining a reference sample value of a second color component of the current block based on adjacent sample values ​​of the second color component of the current block; The method of decoding according to claim 1 .

28. The decoding method includes: and further comprising: setting a reference sample value of the second color component of the current block to an adjacent sample value of the second color component of the current block or a value obtained by filtering the adjacent sample value of the second color component of the current block.

28. The method of decoding according to claim 27.

29. The step of determining a reconstruction value of a sampling point of the second color component of the current block based on a predicted value of the second color component of the current block includes: decoding the bitstream to determine a reconstructed value of a prediction difference of a second color component of the current block; determining a reconstructed value of a sampling point of the second color component of the current block based on a sum of a predicted value of the second color component of the current block and a reconstructed value of a second color component prediction difference of the current block; The method of decoding according to claim 1 .

30. 1. A method of encoding, comprising: determining a candidate first control parameter for a current block; determining a reference sample value of a first color component of the current block; determining a weighting factor based on a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter; determining a predicted value of a second color component of the current block based on the weighting coefficient and a reference sample value of the second color component of the current block; determining a reference value of a prediction difference of a second color component of the current block according to a predicted value and an original value of the second color component of the current block; determining a first control parameter of the current block according to a reference value of a prediction difference of a second color component of the current block; encoding the first control parameter of the current block and writing the resulting encoded bits into a bitstream.

31. The candidate first control parameters include a plurality of candidate values ​​of the first control parameters.

31. The encoding method of claim 30.

32. The encoding method comprises: determining the candidate first control parameter based on a prediction parameter of the current block; 32. The encoding method of claim 31.

33. The encoding method comprises: the prediction parameters of the current block include at least a size of the current block, the size of the current block including at least one of a height of the current block, a width of the current block, a number of first color component sampling points included in the current block, and a number of second color component sampling points included in the current block; 33. The encoding method of claim 32.

34. The prediction parameters of the current block include a prediction mode of the current block.

33. The encoding method of claim 32.

35. The step of determining the candidate first control parameter based on the prediction parameter of the current block includes: determining a candidate first control parameter corresponding to the current block based on a prediction parameter of the current block according to a correspondence relationship between a predetermined prediction parameter and a candidate first control parameter; 33. The encoding method of claim 32.

36. The step of determining a reference sample value of a first color component of the current block includes: determining a reference sample value of a first color component of the current block based on adjacent sample values ​​of the first color component of the current block and a reconstructed value of the first color component of the current block; 31. The encoding method of claim 30.

37. The encoding method comprises: The method further includes the step of setting a reference sample value of a first color component of the current block equal to an absolute value of a difference between a first intra-block reference value and a first adjacent reference value; the first intra-block reference value is a reconstructed value of the first color component of the current block or a value obtained after a filtering process of the reconstructed value of the first color component of the current block, and the first neighboring reference value is a neighboring sample value of the first color component of the current block or a value obtained after a filtering process of the neighboring sample value of the first color component of the current block.

37. The encoding method of claim 36.

38. determining a weighting coefficient based on a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter; determining a first input parameter based on a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter set; determining the weighting coefficients based on a predetermined mapping relationship and the first input parameter.

31. The encoding method of claim 30.

39. determining a first input parameter based on a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter set, setting the first input parameter equal to a ratio of a reference sample value of a first color component of the current block to a candidate value in the candidate first control parameter; 39. The encoding method of claim 38.

40. determining a first input parameter based on a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter set, setting said first input parameter equal to a product of a reference sample value of a first color component of said current block and a candidate value in said candidate first control parameter; 39. The encoding method of claim 38.

41. determining a first input parameter based on a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter set, setting the first input parameter equal to a reference sample value of a first color component of the current block after right shifting it by S bits, the value of S being determined based on a candidate value in the candidate first control parameter.

39. The encoding method of claim 38.

42. The encoding method comprises: setting a value of S equal to a candidate value in the candidate first control parameter; 42. The encoding method of claim 41.

43. determining a first input parameter based on a reference sample value of a first color component of the current block and a candidate value in the candidate first control parameter set, taking the reference sample value of the first color component of the current block and the first control parameter as index values ​​of a numerical mapping lookup table, and looking up the numerical mapping lookup table to obtain corresponding array element values; setting the first input parameter equal to the array element value; 39. The encoding method of claim 38.

44. determining the weighting coefficients based on the predetermined mapping relationship and the first input parameter, the first input parameter being an input value of the predetermined mapping relationship, and the weighting factor being set equal to an output value of the predetermined mapping relationship, the predetermined mapping relationship being a correspondence relationship between the first input parameter and the weighting factor, the value of the weighting factor decreasing with increasing value of the first input parameter; 39. The encoding method of claim 38.

45. The predetermined mapping relationship is a softmax function.

45. The encoding method of claim 44.

46. determining a predicted value of a second color component of the current block based on the weighting coefficient and a reference sample value of the second color component of the current block, calculating a weighted sum of the weighting coefficients and reference sample values ​​of a second color component of the current block to determine a predicted value of the second color component of the current block; 31. The encoding method of claim 30.

47. determining a predicted value of a second color component of the current block based on the weighting coefficient and a reference sample value of the second color component of the current block, calculating a weighted sum of the weighting coefficient and a reference sample value of a second color component of the current block to determine a first predicted value of the second color component of the current block; filtering a first predicted value of a second color component of the current block to determine a predicted value of the current block; 31. The encoding method of claim 30.

48. The encoding method comprises: determining a reference sample value of a second color component of the current block based on adjacent sample values ​​of the second color component of the current block; 31. The encoding method of claim 30.

49. The encoding method comprises: and further comprising: setting a reference sample value of the second color component of the current block to an adjacent sample value of the second color component of the current block or a value obtained by filtering the adjacent sample value of the second color component of the current block.

49. The encoding method of claim 48.

50. The step of determining a reference value of a prediction difference of the second color component of the current block according to a predicted value and an original value of the second color component of the current block includes: determining a reference value of a prediction difference of a second color component of the current block according to a difference between a prediction value and an original value of the second color component of the current block; 31. The encoding method of claim 30.

51. determining a first control parameter of the current block based on a reference value of a prediction difference of a second color component of the current block, determining a minimum reference value based on reference values ​​of the prediction difference corresponding to a plurality of candidate values ​​of the candidate first control parameter; setting the first control parameter equal to a candidate value corresponding to the minimum reference value.

31. The encoding method of claim 30.

52. The step of encoding a first control parameter of the current block includes: encoding a first control parameter of the current block in a data unit at or above a block layer in the bitstream; 31. The encoding method of claim 30.

53. The data units at or above the block layer include at least one of a parameter set data unit, an image header data unit, a slice header data unit, a coding tree data unit, and a current block data unit.

53. The encoding method of claim 52.

54. The step of encoding a first control parameter of the current block includes: encoding one or more candidate values ​​of the first control parameter of the first control parameter; 31. The encoding method of claim 30.

55. The encoding method comprises: The method further includes the step of encoding a correspondence between a predetermined prediction parameter and a first control parameter in a parameter set data unit in the bitstream, the parameter set corresponding to the parameter set data unit being a parameter set referenced directly or indirectly by a slice, the slice including the current block.

31. The encoding method of claim 30.

56. The parameter sets referenced directly or indirectly by the slices include at least one of a sequence parameter set, an image parameter set, and an adaptation parameter set.

56. The encoding method of claim 55.

57. The encoding method comprises: encoding a correspondence between the predetermined prediction parameters and the first control parameter in a slice header data unit in the bitstream.

56. The encoding method of claim 55.

58. The encoding method comprises: and encoding a correspondence between the predetermined prediction parameters and the first control parameters in a picture header data unit in the bitstream, the picture corresponding to the picture header data unit including the slice.

58. The encoding method of claim 57.

59. 1. An encoding device, comprising: a first determining unit configured to determine a candidate first control parameter for the current block; a first calculation unit configured to determine a reference sample value of a first color component of the current block, and to determine a weighting factor based on the reference sample value of the first color component of the current block and a candidate value among the candidate first control parameters; a first prediction unit configured to determine a predicted value of a second color component of the current block based on the weighting coefficients and a reference sample value of a second color component of the current block, determine a reference value of a prediction difference of the second color component of the current block based on the predicted value and an original value of the second color component of the current block, and determine a first control parameter of the current block based on the reference value of the prediction difference of the second color component of the current block; an encoding unit configured to encode the first control parameter of the current block and to write the resulting encoded bits into a bitstream.

60. 1. A decoding device, comprising: a decoding unit configured to decode the bitstream and determine a first control parameter for a current block; a second calculation unit configured to determine a reference sample value of a first color component of the current block and to determine a weighting factor based on the reference sample value of the first color component of the current block and the first control parameter; A decoding apparatus comprising: a second prediction unit configured to determine a predicted value of the second color component of the current block based on the weighting coefficients and reference sample values ​​of the second color component of the current block, and to determine a reconstructed value of a sampling point of the second color component of the current block based on the predicted value of the second color component of the current block.

61. An encoding device, the encoding device comprising: a first memory; and a first processor; An encoding device, wherein the first memory stores a computer program executable by a first processor, and the first processor, when executing the program, realizes the encoding method described in any one of claims 1 to 29.

62. A decoding device, the decoding device comprising: a second memory; and a second processor; A decoding device, wherein the second memory stores a computer program executable by a second processor, and the second processor, when executing the program, realizes the decoding method described in any one of claims 30 to 58.

63. A computer-readable storage medium having stored thereon a computer program which, when executed by a first processor, causes the first processor to perform the encoding method of any one of claims 1 to 29, or, when executed by a second processor, causes the second processor to perform the decoding method of any one of claims 30 to 58.

Citation Information

Patent Citations

  • Encoder, encoding method, decoder and decoding method

    JP2018056699A

  • Video image component prediction method, apparatus and computer storage medium

    JP2022501863A

  • MIP for All Channels in the Case of 4:4:4-Chroma Format and of Single Tree

    US20230188720A1

  • Prediction weighted table-based image / video coding method and apparatus

    WO2021125700A1

  • MIP for all channels in the case of 4:4:4-chroma format and of single tree

    WO2021198402A1