Coding method, coder, bitstream and storage medium

CN122460071APending Publication Date: 2026-07-24GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
Filing Date
2023-12-22
Publication Date
2026-07-24

AI Technical Summary

Technical Problem

Sub-block transformation technology reduces the encoding and decoding performance to a certain extent, because sub-blocks with no residual information are rare, forcing the residual information of the sub-block to zero will affect the encoding performance.

Method used

In the decoding method, the initial reconstruction information (not including residual information) of the second sub-block is processed based on the reconstruction information of the first sub-block (including residual information) to introduce residual information and improve the encoding and decoding performance.

Benefits of technology

By introducing residual information to the second sub-block, the encoding and decoding performance is improved, and the encoding efficiency and decoding quality are improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122460071A_ABST
    Figure CN122460071A_ABST
Patent Text Reader

Abstract

A coding method, a coder, a bitstream and a storage medium are provided. The decoding method comprises: parsing a bitstream, determining a first sub-block and a second sub-block in a current block; determining reconstruction information of the first sub-block according to prediction information and residual information of the first sub-block; determining initial reconstruction information of the second sub-block according to prediction information of the second sub-block, the initial reconstruction information of the second sub-block not containing residual information; and determining target reconstruction information of the second sub-block according to the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block.
Need to check novelty before this filing date? Find Prior Art

Description

Coding and decoding method, codec, code stream and storage medium Technical Field

[0001] The present application relates to the field of video coding and decoding technology, and in particular to a coding and decoding method, a codec, a bit stream, and a storage medium. Background Art

[0002] The sub-block transform (SBT) technique divides the current block into sub-blocks containing residual information and sub-blocks not containing residual information, and performs operations such as transform and quantization only on the sub-blocks containing residual information. In other words, SBT forces the residual information of a sub-block to zero. However, it is rare to have no residual information at all, and forcing the residual information of a sub-block to zero will degrade codec performance to a certain extent.

[0003] Summary of the Invention

[0004] The present application provides a coding and decoding method, a codec, a bit stream, and a storage medium. The following introduces various aspects of the present application.

[0005] In a first aspect, a decoding method is provided, which is applied to a decoder, and the decoding method includes: parsing a code stream to determine a first sub-block and a second sub-block in a current block; determining reconstruction information of the first sub-block based on prediction information and residual information of the first sub-block; determining initial reconstruction information of the second sub-block based on the prediction information of the second sub-block, where the initial reconstruction information of the second sub-block does not include residual information; and determining target reconstruction information of the second sub-block based on the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block.

[0006] In a second aspect, a coding method is provided, which is applied to an encoder, and the coding method includes: determining a first sub-block and a second sub-block in a current block; determining reconstruction information of the first sub-block based on prediction information and residual information of the first sub-block; determining initial reconstruction information of the second sub-block based on the prediction information of the second sub-block, the initial reconstruction information of the second sub-block does not include residual information; and determining target reconstruction information of the second sub-block based on the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block.

[0007] According to a third aspect, a decoder is provided, comprising: a first determination unit configured to parse a bitstream and determine a first sub-block and a second sub-block in a current block; a second determination unit configured to determine reconstruction information of the first sub-block based on prediction information and residual information of the first sub-block; a third determination unit configured to determine initial reconstruction information of the second sub-block based on the prediction information of the second sub-block, the initial reconstruction information of the second sub-block not including residual information; and a fourth determination unit configured to determine target reconstruction information of the second sub-block based on the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block.

[0008] In a fourth aspect, a decoder is provided, comprising: a memory for storing a computer program; and a processor for executing the method of the first aspect when running the computer program.

[0009] In a fifth aspect, an encoder is provided, including: a first determination unit, configured to determine a first sub-block and a second sub-block in a current block; a second determination unit, configured to determine reconstruction information of the first sub-block based on prediction information and residual information of the first sub-block; a third determination unit, configured to determine initial reconstruction information of the second sub-block based on the prediction information of the second sub-block, the initial reconstruction information of the second sub-block not including residual information; and a fourth determination unit, configured to determine target reconstruction information of the second sub-block based on the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block.

[0010] In a sixth aspect, an encoder is provided, comprising: a memory for storing a computer program; and a processor for executing the method of the second aspect when running the computer program.

[0011] In a seventh aspect, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed, the method of the first aspect or the second aspect is implemented.

[0012] In an eighth aspect, a computer program product is provided, comprising a computer program, which implements the method of the first aspect or the second aspect when the computer program is executed.

[0013] In a ninth aspect, a non-volatile computer-readable storage medium for storing a bit stream is provided, wherein the bit stream is generated by an encoding method of an encoder, or the bit stream is decoded by a decoding method of a decoder, wherein the decoding method is the method described in the first aspect and the encoding method is the method described in the second aspect.

[0014] In a tenth aspect, a code stream is provided, including a code stream generated according to the method described in the first aspect or a code stream generated according to the method described in the second aspect.

[0015] Processing the initial reconstruction information (excluding residual information) of the second sub-block according to the reconstruction information (including residual information) of the first sub-block helps introduce the residual information into the second sub-block, thereby improving encoding and decoding performance. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] FIG1 is a structural diagram illustrating an example of a video encoder to which an embodiment of the present application may be applied.

[0017] FIG2 is a diagram showing an example structure of a video decoder to which an embodiment of the present application can be applied.

[0018] FIG. 3A is a diagram illustrating an example of a sub-block division method in a sub-block transform mode.

[0019] FIG. 3B is another example diagram of a sub-block division method in the sub-block transform mode.

[0020] FIG4 is a flow chart of a decoding method provided in an embodiment of the present application.

[0021] FIG5 is an example diagram of the filter shape provided in an embodiment of the present application.

[0022] FIG6 is another example diagram of the filter shape provided in an embodiment of the present application.

[0023] FIG7 is an example diagram of a filling area for filtering provided in an embodiment of the present application.

[0024] FIG8 is an example diagram of a sliding method of a filter provided in an embodiment of the present application.

[0025] FIG9 is another example diagram of the sliding method of the filter provided in an embodiment of the present application.

[0026] FIG10 is another example diagram of the sliding method of the filter provided in an embodiment of the present application.

[0027] FIG11 is an example diagram of a sub-block division method provided in an embodiment of the present application.

[0028] FIG12 is a flow chart of the encoding method provided in an embodiment of the present application.

[0029] FIG13 is a schematic diagram of the structure of a decoder provided in one embodiment of the present application.

[0030] FIG14 is a schematic diagram of the structure of a decoder provided in another embodiment of the present application.

[0031] FIG15 is a schematic diagram of the structure of an encoder provided in one embodiment of the present application.

[0032] FIG16 is a schematic diagram of the structure of an encoder provided in another embodiment of the present application. DETAILED DESCRIPTION

[0033] The technical solution in this application will be described below with reference to the accompanying drawings.

[0034] FIG1 is a schematic block diagram of a video encoder according to an embodiment of the present application.

[0035] It should be understood that the video encoder 100 can be used to perform lossy compression or lossless compression on an image. The lossless compression can be visually lossless compression or mathematically lossless compression.

[0036] The video encoder 100 can be applied to image data in a luminance and chrominance (YCbCr, YUV) format. For example, the YUV ratio can be 4:2:0, 4:2:2, or 4:4:4, where Y represents brightness (Luma), Cb (U) represents blue chrominance, Cr (V) represents red chrominance, and U and V represent chrominance (Chroma) for describing color and saturation. For example, in terms of color format, 4:2:0 means that every 4 pixels have 4 luminance components and 2 chrominance components (YYYYCbCr), 4:2:2 means that every 4 pixels have 4 luminance components and 4 chrominance components (YYYYCbCrCbCr), and 4:4:4 represents full pixel display (YYYYCbCrCbCrCbCrCbCr).

[0037] For example, the video encoder 100 reads video data and, for each image in the video data, divides the image into a number of coding tree units (CTUs). In some examples, a CTU may be referred to as a "tree block," "largest coding unit" (LCU) or "coding tree block" (CTB). Each CTU may be associated with a pixel block of equal size within the image. Each pixel may correspond to one luminance (luminance or luma) sample and two chrominance (chroma) samples. Therefore, each CTU may be associated with one luminance sample block and two chrominance sample blocks. The size of a CTU is, for example, 128×128, 64×64, 32×32, etc. A CTU may be further divided into a number of coding units (CUs) for encoding. A CU may be a rectangular block or a square block. A CU may correspond to a prediction unit (PU) and a transform unit (TU).

[0038] In some embodiments, as shown in FIG1 , the video encoder 100 may include a prediction module 110, a residual module 120, a transform / quantization module 130, an inverse transform / quantization module 140, a reconstruction module 150, a loop filter module 160, a decoded image buffer 170, and an entropy coding module 180. It should be noted that the video encoder 100 may include more, fewer, or different functional components.

[0039] Optionally, in this application, the current block may be referred to as the current coding unit (CU). The prediction block may also be referred to as a predicted image block or an image prediction block, and the reconstructed image block may also be referred to as a reconstructed block or an image reconstruction block. Due to the need for parallel processing, an image may be divided into slices. Slices in the same image may be processed in parallel, meaning that there is no data dependency between them. The term "frame" is commonly used, and it can generally be understood that a frame is an image. The term "frame" herein may also be replaced by "image" or "slice," etc.

[0040] In some embodiments, the prediction module 110 includes an inter-frame prediction module 111 and an intra-frame prediction module 112. Because there is a strong correlation between adjacent pixels in a video image, intra-frame prediction is used in video coding and decoding technologies to eliminate spatial redundancy between adjacent pixels. Because there is a strong similarity between adjacent images in a video, inter-frame prediction is used in video coding and decoding technologies to eliminate temporal redundancy between adjacent images, thereby improving coding efficiency.

[0041] The inter-frame prediction module 111 can be used for inter-frame prediction. Inter-frame prediction can include motion estimation and motion compensation. It can refer to image information from different images. Inter-frame prediction uses motion information to find a reference block from a reference image and generate a prediction block based on the reference block to eliminate temporal redundancy. Inter-frame prediction uses motion information to find a reference block from a reference image and generate a prediction block based on the reference block. Motion information includes the reference image list in which the reference image is located, the reference image index, and the motion vector. The motion vector can be integer pixel or fractional pixel. If the motion vector is fractional pixel, interpolation filtering is required to generate the required fractional pixel block in the reference image. Here, the integer pixel or fractional pixel block in the reference image found based on the motion vector is called a reference block. Some technologies directly use the reference block as the prediction block, while others further process the reference block to generate a prediction block. Reprocessing the reference block to generate a prediction block can also be understood as using the reference block as the prediction block and then processing the prediction block to generate a new prediction block.

[0042] The intra-frame prediction module 112 only refers to information of the same image to predict pixel information within the current code image block to eliminate spatial redundancy.

[0043] Intra-frame prediction has multiple prediction modes. For example, the H-series international digital video coding standard H.264 / AVC has eight angular prediction modes and one non-angular prediction mode. H.265 / HEVC expands this to 33 angular prediction modes and two non-angular prediction modes. High-efficiency video coding (HEVC) uses planar, direct current (DC), and 33 angular modes for a total of 35 intra-frame prediction modes. Versatile video coding (VVC) uses planar, DC, and 65 angular modes for a total of 67 intra-frame prediction modes.

[0044] It should be noted that with the increase of angle modes, intra-frame prediction will be more accurate and more in line with the needs of high-definition and ultra-high-definition digital video development.

[0045] Residual module 120 may generate a residual block for a CU based on the pixel block of the CU and the prediction block of the CU. For example, residual module 120 may generate a residual block for the CU such that each sample in the residual block has a value equal to the difference between the sample in the pixel block of the CU and the corresponding sample in the prediction block of the CU.

[0046] The transform / quantization module 130 may quantize the transform coefficients. The transform / quantization module 130 may quantize the transform coefficients associated with the CU based on a quantization parameter (QP) value associated with the CU. The video encoder 100 may adjust the degree of quantization applied to the transform coefficients associated with the CU by adjusting the QP value associated with the CU.

[0047] The inverse transform / quantization module 140 may apply inverse quantization and inverse transform, respectively, to the quantized transform coefficients to reconstruct a residual block from the quantized transform coefficients.

[0048] Reconstruction module 150 can add samples of the reconstructed residual block to corresponding samples of one or more prediction blocks generated by prediction module 110 to generate a reconstructed image block associated with the CU. By reconstructing each sample block of the CU in this manner, video encoder 100 can reconstruct the pixel blocks of the CU.

[0049] The loop filter module 160 is used to process the inverse transformed and inverse quantized pixels to compensate for distortion information and provide a better reference for subsequent pixel encoding. For example, it can perform a deblocking filtering operation to reduce the blocking effect of pixel blocks associated with the CU.

[0050] In some embodiments, the loop filtering module 160 includes a deblocking filtering module and a sample adaptive offset / adaptive loop filtering (SAO / ALF) module, wherein the deblocking filtering module is used to remove blocking effects, and the SAO / ALF module is used to remove ringing effects.

[0051] The decoded image buffer 170 may store the reconstructed pixel blocks. The inter prediction module 111 may use a reference image containing the reconstructed pixel blocks to perform inter prediction on PUs of other images. In addition, the intra prediction module 112 may use the reconstructed pixel blocks in the decoded image buffer 170 to perform intra prediction on other PUs in the same image as the CU.

[0052] The entropy encoding module 180 may receive the quantized transform coefficients from the transform / quantization module 130. The entropy encoding module 180 may perform one or more entropy encoding operations on the quantized transform coefficients to generate entropy-encoded data.

[0053] FIG2 is a schematic block diagram of a video decoder according to an embodiment of the present application.

[0054] 2 , video decoder 200 includes an entropy decoding module 210, a prediction module 220, an inverse quantization / transformation module 230, a reconstruction module 240, a loop filter module 250, and a decoded image buffer 260. It should be noted that video decoder 200 may include more, fewer, or different functional components.

[0055] The video decoder 200 may receive a bitstream. The entropy decoding module 210 may parse the bitstream to extract syntax elements from the bitstream. As part of parsing the bitstream, the entropy decoding module 210 may parse the entropy-encoded syntax elements in the bitstream. The prediction module 220, the inverse quantization / transformation module 230, the reconstruction module 240, and the loop filter module 250 may decode the video data based on the syntax elements extracted from the bitstream, thereby generating decoded video data.

[0056] In some embodiments, the prediction module 220 includes an intra-frame prediction module 222 and an inter-frame prediction module 221 .

[0057] The intra prediction module 222 may perform intra prediction to generate a prediction block for a PU. The intra prediction module 222 may use an intra prediction mode to generate a prediction block for the PU based on pixel blocks of spatially neighboring PUs. The intra prediction module 222 may also determine the intra prediction mode for the PU based on one or more syntax elements parsed from the codestream.

[0058] The inter-frame prediction module 221 may construct a first reference picture list (List 0) and a second reference picture list (List 1) based on syntax elements parsed from the codestream. Furthermore, if a PU is encoded using inter-frame prediction, the entropy decoding module 210 may parse the motion information of the PU. The inter-frame prediction module 221 may determine one or more reference blocks for the PU based on the motion information of the PU. The inter-frame prediction module 221 may generate a prediction block for the PU based on the one or more reference blocks of the PU.

[0059] The inverse quantization / transform module 230 may inversely quantize (ie, dequantize) the transform coefficients associated with the TU. The inverse quantization / transform module 230 may use the QP value associated with the CU of the TU to determine the degree of quantization.

[0060] After inverse quantizing the transform coefficients, inverse quantization / transform module 230 may apply one or more inverse transforms to the inverse quantized transform coefficients in order to generate a residual block associated with the TU.

[0061] Reconstruction module 240 uses the residual block associated with the TU of the CU and the prediction block of the PU of the CU to reconstruct the pixel block of the CU. For example, reconstruction module 240 can add samples of the residual block to corresponding samples of the prediction block to reconstruct the pixel block of the CU to obtain a reconstructed image block.

[0062] The loop filtering module 250 may perform a deblocking filtering operation to reduce blocking artifacts of pixel blocks associated with a CU.

[0063] The video decoder 200 may store the reconstructed image of the CU in the decoded image buffer 260. The video decoder 200 may use the reconstructed image in the decoded image buffer 260 as a reference image for subsequent prediction, or transmit the reconstructed image to a display device for presentation.

[0064] The basic process of video encoding and decoding is as follows: At the encoder end, an image is divided into blocks. For the current block, the prediction module 110 uses intra-frame prediction or inter-frame prediction to generate a prediction block for the current block. The residual module 120 calculates a residual block based on the predicted block and the original block of the current block. This residual block is the difference between the predicted block and the original block of the current block. This residual block can also be referred to as residual information. This residual block undergoes transformation and quantization by the transform / quantization module 130, removing information that is insensitive to the human eye and eliminating visual redundancy. Optionally, the residual block before transformation and quantization by the transform / quantization module 130 can be referred to as a time-domain residual block, and the time-domain residual block after transformation and quantization by the transform / quantization module 130 can be referred to as a frequency residual block or a frequency-domain residual block. The entropy coding module 180 receives the quantized change coefficients output by the transform and quantization module 130 and performs entropy coding on these quantized change coefficients to output a bitstream. For example, the entropy coding module 180 can eliminate character redundancy based on the target context model and the probability information of the binary bitstream.

[0065] At the decoding end, the entropy decoding module 210 can parse the code stream to obtain the prediction information, quantization coefficient matrix, etc. of the current block. The prediction module 220 uses intra-frame prediction or inter-frame prediction on the current block based on the prediction information to generate a prediction block for the current block. The inverse quantization / transformation module 230 uses the quantization coefficient matrix obtained from the code stream to inverse quantize and inverse transform the quantization coefficient matrix to obtain a residual block. The reconstruction module 240 adds the prediction block and the residual block to obtain a reconstructed block. The reconstructed blocks constitute a reconstructed image, and the loop filtering module 250 performs loop filtering on the reconstructed image based on the image or block to obtain a decoded image. The encoding end also requires similar operations as the decoding end to obtain a decoded image. The decoded image can also be called a reconstructed image, and the reconstructed image can be used as a reference image for inter-frame prediction of subsequent images.

[0066] It should be noted that the block division information determined by the encoder, as well as mode information or parameter information such as prediction, transform, quantization, entropy coding, and loop filtering, etc., are carried in the bitstream when necessary. The decoder parses the bitstream and analyzes the existing information to determine the same block division information, prediction, transform, quantization, entropy coding, loop filtering, etc. mode information or parameter information as the encoder, thereby ensuring that the decoded image obtained by the encoder and the decoder are identical.

[0067] It is understandable that the "inverse transformation" of the transform coefficients at the decoding end may also be referred to as "transformation" in the standard text. The "transformation" and "inverse transformation" in the embodiments of the present application correspond to two opposite processes. For example, if the "transformation" converts the numerical values ​​in the spatial domain to the coefficients in the frequency domain, then the "inverse transformation" converts the coefficients in the frequency domain to the numerical values ​​in the spatial domain. If the standard only stipulates decoding, then the "transformation" in the standard text is the decoding part, which refers to the "inverse transformation" in this article. The "inverse transformation" of the transform coefficients at the decoding end may also be referred to as "transformation" in the standard text.

[0068] The above is the basic process of the video codec under the block-based hybrid coding framework. With the development of technology, some modules or steps of the framework or process may be optimized. This application is applicable to the basic process of the video codec under the block-based hybrid coding framework, but is not limited to the framework and process.

[0069] The preceding text describes in detail the codec framework provided by the embodiments of this application. This application relates to sub-block transform technology. Sub-block transform technology can be applied to the transform / inverse transform module in the codec framework. The following describes sub-block transform technology.

[0070] SBT is a transform technology specified in relevant standards (such as VVC). Using SBT, a current block containing residual information can be divided into two sub-blocks. The residual information of one sub-block is transformed and quantized at the encoding end and then encoded into the bitstream. Correspondingly, the residual information of this sub-block is obtained through inverse quantization and inverse transformation at the decoding end. The other sub-block is assumed to have no residual information by default. The advantage of this is that when the residual information of a current block is concentrated in a certain area of ​​the current block, SBT can obtain and encode this part of the residual information at a lower cost.

[0071] SBT can be applied to inter-frame coded blocks. If the SBT tool is selected for an inter-frame coded block, the decoder will parse the bitstream to determine the sub-block location information and sub-block division ratio information. In other words, the decoder will parse the bitstream to identify a region that uses sub-block transforms and a region that does not. The decoder will then set the region that uses sub-block transforms as a transform unit with residual information and the region that does not use sub-block transforms as a transform unit without residual information.

[0072] In the relevant standards, SBT has 8 sub-block transformation methods. As shown in Figures 3A and 3B, SBT can divide the current block into two sub-blocks in the horizontal direction at a ratio of 1 / 2 (or 1 / 4), or divide it into two sub-blocks in the vertical direction at a ratio of 1 / 2 (or 1 / 4). SBT can also specify a sub-block with residual information in the two divided sub-blocks and select the transformation method for the horizontal and vertical directions of the sub-block. During the encoding and decoding process, only the sub-blocks with residual information are transformed and inversely transformed, while the sub-blocks without residual information are not transformed or inversely transformed by default. The following is a detailed introduction to the sub-block division method in SBT.

[0073] As shown in Figure 3A, if the current block is split vertically, it can be divided into a left sub-block and a right sub-block. The gray sub-block in Figure 3A represents the sub-block containing the residual, and the white sub-block represents the sub-block not containing the residual. The ratio of the two sub-blocks in the current block is 1:M, where M is 1 or 3. As shown in Figure 3B, if the current block is split horizontally, it can be divided into an upper sub-block and a lower sub-block. The gray sub-block in Figure 3B represents the sub-block containing the residual, and the white sub-block represents the sub-block not containing the residual. The ratio of the two sub-blocks is 1:M, where M is 1 or 3.

[0074] According to the above method, eight sub-block division methods can be obtained, and in each division method, the sub-block containing the residual corresponds to a specific transformation method, which is described in detail below.

[0075] (1) The current block is divided into two sub-blocks in the vertical direction according to the ratio of 1 / 2, 1 / 2. The left sub-block contains residual information, while the right sub-block does not. In this division method, the left sub-block is transformed and inversely transformed using the DCT-8 transform kernel in the horizontal direction and the DST-7 transform kernel in the vertical direction.

[0076] (2) The current block is divided into two sub-blocks in the vertical direction according to the ratio of 1 / 4 and 3 / 4. The left sub-block contains residual information, while the right sub-block does not. In this division method, the left sub-block is transformed and inversely transformed using the DCT-8 transform kernel in the horizontal direction and the DST-7 transform kernel in the vertical direction.

[0077] (3) The current block is divided into two sub-blocks in the vertical direction with a ratio of 1 / 2, 1 / 2. The right sub-block contains residual information, while the left sub-block does not. The right sub-block is transformed and detransformed using the DST-7 transform kernel in the horizontal direction and in the vertical direction.

[0078] (4) The current block is divided into two sub-blocks in the vertical direction with a ratio of 1 / 4 and 3 / 4. The right sub-block contains residual information, while the left sub-block does not. The right sub-block is transformed and detransformed using the DST-7 transform kernel in the horizontal direction and in the vertical direction.

[0079] (5) The current block is divided into two sub-blocks in the horizontal direction according to the ratio of 1 / 2, 1 / 2. The upper sub-block contains residual information, while the lower sub-block does not. The upper sub-block is transformed and inversely transformed using the DST-7 transform kernel in the horizontal direction and the DCT-8 transform kernel in the vertical direction.

[0080] (6) The current block is divided into two sub-blocks in the horizontal direction with a ratio of 1 / 4 and 3 / 4. The upper sub-block contains residual information, while the lower sub-block does not. The upper sub-block is transformed and inversely transformed using the DST-7 transform kernel in the horizontal direction and the DCT-8 transform kernel in the vertical direction.

[0081] (7) The current block is divided into two sub-blocks in the horizontal direction according to a ratio of 1 / 2, 1 / 2. The lower sub-block contains residual information, while the upper sub-block does not. The lower sub-block is transformed and detransformed using the DST-7 transform kernel in the horizontal direction and in the vertical direction.

[0082] (8) The current block is divided into two sub-blocks in the horizontal direction with a ratio of 1 / 4 and 3 / 4. The lower sub-block contains residual information, while the upper sub-block does not. The lower sub-block is transformed and detransformed using the DST-7 transform kernel in the horizontal direction and in the vertical direction.

[0083] When decoding block-level syntax elements, the decoder uses SBT-related syntax elements to obtain the sub-block positions containing residual information and the sub-block division direction. When reconstructing the current block, the sub-blocks are reconstructed based on the positions of the sub-blocks containing residual information and the residual information obtained through inverse quantization and inverse transformation.

[0084] SBT technology sets the residual of a sub-block to zero by default. This simplifies codec operations and reduces the bitrate, minimizing the overall rate-distortion penalty. However, in real-world video sequences, it's uncommon for sub-blocks derived from a coding block to be completely free of residuals. Forcing the residual of a sub-block to zero also degrades encoding performance to some extent. Therefore, further improving encoding performance is a challenge that needs to be addressed.

[0085] In response to the above problems, an embodiment of the present application provides a coding method, including: determining a first sub-block and a second sub-block in a current block; determining reconstruction information of the first sub-block based on prediction information and residual information of the first sub-block; determining initial reconstruction information of the second sub-block based on the prediction information of the second sub-block, where the initial reconstruction information of the second sub-block does not include residual information; and determining target reconstruction information of the second sub-block based on the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block.

[0086] In addition, an embodiment of the present application also provides a decoding method, including: parsing a code stream to determine a first sub-block and a second sub-block in a current block; determining reconstruction information of the first sub-block based on prediction information and residual information of the first sub-block; determining initial reconstruction information of the second sub-block based on the prediction information of the second sub-block, wherein the initial reconstruction information of the second sub-block does not include residual information; and determining target reconstruction information of the second sub-block based on the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block.

[0087] The embodiment of the present application processes the initial reconstruction information (excluding residual information) of the second sub-block according to the reconstruction information (including residual information) of the first sub-block, which helps to introduce the residual information into the second sub-block, thereby improving the encoding and decoding performance.

[0088] The following first describes the decoding method of the embodiment of the present application in detail with examples.

[0089] Figure 4 is a flow chart of a decoding method provided by an embodiment of the present application. The method of Figure 4 can be applied to a decoder.

[0090] Referring to FIG. 4 , in step S410 , the code stream is parsed to determine the first sub-block and the second sub-block in the current block. The current block may refer to the current block to be decoded. In some implementations, the current block is a luma block. In other implementations, the current block may also be a chroma block. The current block may be an inter-frame predicted block or an intra-frame predicted block. Taking an intra-frame predicted block as an example, the current block may be a predicted block based on an intra-frame block copy mode.

[0091] The first sub-block mentioned above may be a sub-block containing residual information. The second sub-block may be a sub-block not containing residual information. The fact that the first sub-block contains residual information can be understood as meaning that the reconstruction information corresponding to the first sub-block contains residual information. In other words, obtaining the reconstruction information corresponding to the first sub-block requires operations such as inverse quantization and inverse transformation. The fact that the second sub-block does not contain residual information can be understood as meaning that the reconstruction information corresponding to the second sub-block does not contain residual information. In other words, obtaining the reconstruction information corresponding to the second sub-block does not require operations such as inverse quantization and inverse transformation.

[0092] The positions of the first sub-block and the second sub-block in the current block may be fixed. Alternatively, the positions of the first sub-block and the second sub-block in the current block may be determined based on first information parsed from the bitstream. This first information may, for example, indicate the division ratio and / or division direction of the current block. Furthermore, the first information may further indicate which of the divided sub-blocks is the first sub-block (i.e., which sub-block contains residual information) and which sub-block is the second sub-block (i.e., which sub-block does not contain residual information).

[0093] 4 , in step S420 , reconstruction information of the first sub-block is determined based on the prediction information and residual information of the first sub-block. For example, the sum of the prediction information and residual information of the first sub-block can be used as the reconstruction information of the first sub-block.

[0094] Prior to step S420, operations such as prediction, inverse quantization, and inverse transformation may be performed on the first sub-block to determine prediction information and residual information for the first sub-block. It should be understood that the prediction information for the first sub-block may be prediction information directly obtained after the prediction operation, or may be target information obtained by further processing the information obtained by the prediction operation (target information may also be understood as prediction information obtained after certain processing). For example, information obtained after performing luminance mapping and chrominance scaling on the prediction information of the first sub-block may be used as the prediction information for the first sub-block.

[0095] Continuing with FIG4 , in step S430 , initial reconstruction information for the second sub-block is determined based on the prediction information of the second sub-block. It should be understood that the prediction information for the second sub-block may refer to information directly obtained after the prediction operation, or may be target information obtained after further processing the prediction information obtained by the prediction operation (target information may also be understood as prediction information obtained after certain processing). For example, information obtained after performing luminance mapping and chrominance scaling on the prediction information of the second sub-block may be used as the prediction information for the second sub-block. Furthermore, the initial reconstruction information for the second sub-block determined in step S430 does not include residual information. For example, the prediction information for the second sub-block may be directly used as the initial reconstruction information for the second sub-block.

[0096] Continuing with FIG. 4 , in step S440, target reconstruction information for the second sub-block is determined based on the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block. In other words, the initial reconstruction information of the second sub-block is processed based on the reconstruction information of the first sub-block to determine the target reconstruction information for the second sub-block. For example, the reconstruction information of the first sub-block may be fused with the initial reconstruction information of the second sub-block to determine the target reconstruction information for the second sub-block.

[0097] The embodiment of the present application processes the initial reconstruction information (excluding residual information) of the second sub-block according to the reconstruction information (including residual information) of the first sub-block, which helps to introduce the residual information into the second sub-block, thereby improving decoding performance.

[0098] The embodiment of the present application does not specifically limit the implementation method of step S440. In some implementation methods, the reconstruction information of the first sub-block can be fused (or weighted fused) with the initial reconstruction information of the second sub-block. In other implementation methods, the first filter can be first determined based on the prediction information and reconstruction information of the first sub-block. The first filter can indicate the association or mapping relationship between the prediction information and the reconstruction information of the first sub-block. Then, the initial reconstruction information of the second sub-block can be filtered based on the first filter to determine the target reconstruction information of the second sub-block. This can be done because the first sub-block and the second sub-block are both located in the current block, and the relationship between the prediction information and reconstruction information of the first sub-block is similar to the relationship between the prediction information and reconstruction information of the second sub-block. Therefore, filtering the initial reconstruction information of the second sub-block based on the first filter helps to improve the accuracy of the reconstruction information of the second sub-block.

[0099] The embodiment of the present application does not specifically limit the shape of the first filter. For example, the shape of the first filter can be, for example, a 5-tap filter as shown in FIG5 . Alternatively, the shape of the first filter can also be a filter of other shapes, as shown in FIG6 .

[0100] The first filter can filter the initial reconstruction information of the second sub-block based on the filter coefficients. The filter coefficients of the first filter can be trained based on the relationship between the prediction information and the reconstruction information of the first sub-block. For example, the first filter can be slid within the region where the first sub-block is located. During the sliding process, the prediction information of the first sub-block can be used as the input information of the first filter, and the reconstruction information of the first sub-block can be used as the output information of the first filter, thereby constructing an autocorrelation coefficient matrix and a cross-correlation coefficient matrix. The filter coefficients of the first filter can then be determined based on the autocorrelation coefficient matrix and the cross-correlation coefficient matrix.

[0101] As an example, before sliding, the surrounding area of ​​the first sub-block can be filled to obtain a filled area. The filling information of the filled area can be, for example, the reconstruction information of the edge position of the first sub-block. Figure 7 shows the position of the filled area of ​​the first filter. As shown in Figure 7, a row or a column of pixels can be filled on the upper side, left side and right side of the first sub-block. After obtaining the filled area, the first filter can be slid within the first sub-block and the surrounding filled area of ​​the first sub-block. Taking the first filter as a 5-tap filter as an example, see Figure 8, the first filter can be slid horizontally from left to right starting from the upper left corner to the lower right corner, thereby constructing a linear equation based on the autocorrelation coefficient matrix and the cross-correlation coefficient matrix, as shown in the following formula (1):

[0102] Here, R represents the subblock region containing the residual coefficients, and p_0 to p_(N-1) represent the five input positions of the first filter. For example, t[r+p_0] represents the input information of the first filter at the p_0th input position at the rth sample position, and t[r]' represents the reconstructed information at the rth sample position. In this example, the first filter is a 5-tap filter, so N = 5. Solving the above linear equation yields the five filter coefficients of the first filter, c_0 to c_4.

[0103] After obtaining the filter coefficients of the first filter, the initial reconstruction information of the second sub-block can be filtered based on the filter coefficients of the first filter. For example, as shown in Figure 9, the first filter can slide within the second sub-block and the padding area around the second sub-block (the padding area around the second sub-block can be determined based on the initial reconstruction information of the second sub-block). During the sliding process, the initial reconstruction information of the second sub-block can be used as the input information of the first filter, and the filter equation can be constructed in combination with the filter coefficients. Accordingly, the calculation result of the above filter equation (that is, the output information of the filter) is used as the target reconstruction information of the second sub-block.

[0104] The above filtering equation can be shown as formula (2):

[0105] in, The pth position corresponding to the first filter at the rth position of the second sub-block n Input information of input positions (initial reconstruction information), c n is the nth filter coefficient of the first filter, o r is the filtered value corresponding to the rth position of the second sub-block. Generally speaking, the filtered value can be limited to a certain value range. For example, under the 10-bit pixel value accuracy, each filter output value o r Limited to 0 to 2 10-1 within the range.

[0106] In some implementations, as shown in FIG10 , the first filter may slide only within the first sub-block and / or the second sub-block (the dotted area in FIG10 ). In this case, there is no need to fill the surrounding areas of the first sub-block and / or the second sub-block, thereby simplifying the operation.

[0107] The decoding method shown in FIG4 can be executed under the instruction of one or more identification information. The one or more identification information can be obtained by parsing the code stream. The identification information that may be involved in the embodiments of the present application is described in detail below.

[0108] In some implementations, the code stream may be parsed to determine the first identification information. The first identification information is used to indicate or determine whether to perform filtering processing on the initial reconstruction information of the second sub-block. The first identification information may be information at the coding block level.

[0109] For example, cu_fsbt_flag may be used to represent the first identification information (of course, the first identification information may also be represented by any other letters and / or numbers). cu_fsbt_flag may be represented by a context-adaptive arithmetic entropy coding syntax element (ie, ae(v)).

[0110] In some implementations, the value of cu_fsbt_flag may be 0 or 1. For example, if the value of cu_fsbt_flag is 0, it may indicate that the initial reconstruction information of the second sub-block is not filtered; if the value of cu_fsbt_flag is 1, it may indicate that the initial reconstruction information of the second sub-block is filtered.

[0111] In some implementations, if cu_fsbt_flag does not exist in the codestream, cu_fsbt_flag may have a default value (eg, 0).

[0112] In some implementations, the codestream may be parsed to determine the second identification information. The second identification information may be used to indicate or determine whether to perform step S440 described above, or the second identification information may be used to indicate whether to perform the filtering operation described above. The second identification information may be general constraint information, sequence-level information, frame-level or picture-level information, slice-level information, tile-level information, or coding tree unit-level information.

[0113] For example, sps_fsbt_enabled_flag may be used to represent the second identification information (of course, the second identification information may also be represented by any other letters and / or numbers). sps_fsbt_enabled_flag may be represented by a 1-bit unsigned integer (ie, u(1)).

[0114] In some implementations, the value of sps_fsbt_enabled_flag may be 0 or 1. For example, if the value of sps_fsbt_enabled_flag is 0, it may indicate that step S440 is not performed; if the value of sps_fsbt_enabled_flag is 1, it may indicate that step S440 is performed.

[0115] In some implementations, if sps_fsbt_enabled_flag does not exist in the code stream, sps_fsbt_enabled_flag may have a default value (eg, 0).

[0116] In some implementations, the codestream may be parsed to determine third identification information. This third identification information is used to indicate or determine whether the current block uses the sub-block transform mode. For example, if the third identification information indicates that the current block uses the sub-block transform mode, step S410 may be performed; if the third identification information indicates that the current block does not use the sub-block transform mode, step S410 may not be performed.

[0117] For example, cu_sbt_flag may be used to represent the third identification information (of course, the third identification information may also be represented by any other letters and / or numbers). cu_sbt_flag may be represented by a context-adaptive arithmetic entropy coding syntax element (ie, ae(v)).

[0118] In some implementations, the value of cu_sbt_flag can be 0 or 1. For example, if the value of cu_sbt_flag is 0, it may indicate that the current block does not use the sub-block transform mode, or in other words, the current block is not divided into sub-blocks according to step S410, but the reconstruction information of the current block is determined based on the residual information of the current block; if the value of cu_sbt_flag is 1, it may indicate that the current block uses the sub-block transform mode to determine the first sub-block and the second sub-block.

[0119] In some implementations, if cu_sbt_flag does not exist in the code stream, cu_sbt_flag may have a default value (eg, 0).

[0120] The embodiment of the present application does not specifically limit the positions of the first sub-block and the second sub-block in the current block. For example, the positions of the first sub-block and the second sub-block in the current block can be determined by using the sub-block division method in the sub-block change mode, that is, the current block is divided into 1 / 2 or 1 / 4 in the horizontal direction or vertical direction of the current block, thereby obtaining the first sub-block and the second sub-block. Alternatively, the embodiment of the present application can propose a new sub-block division method (that is, the embodiment of the present application can be understood as a sub-mode of SBT, or as a new transformation mode different from SBT). The following is a more detailed example of the sub-block division method provided by the embodiment of the present application in conjunction with Figure 11.

[0121] As shown in Figure 11(a), the current block is divided into two sub-blocks in the vertical direction. The gray sub-block in Figure 11(a) is the first sub-block, and the white sub-block is the second sub-block. The height ratio of the two sub-blocks is 1:N. The value of N can be different from 1 and 3.

[0122] As shown in Figure 11(b), the current block is divided into two sub-blocks horizontally. The gray sub-block in Figure 11(b) is the first sub-block, and the white sub-block is the second sub-block. The height ratio of the two sub-blocks is 1:N. The value of N can be different from 1 and 3.

[0123] As shown in FIG11( c ), the current block is divided into sub-blocks in both the vertical and horizontal directions. The gray sub-block in FIG11( c ) is the first sub-block, and the white sub-block is the second sub-block.

[0124] As shown in FIG11( d ), the current block is divided into sub-blocks in both the vertical and horizontal directions. The gray sub-block in FIG11( d ) is the first sub-block, and the white sub-block is the second sub-block.

[0125] The decoding method provided by the embodiment of the present application is described in detail above in conjunction with Figure 4. The encoding method provided by the embodiment of the present application is described in detail below in conjunction with Figure 12.

[0126] Figure 12 is a flow chart of an encoding method provided by an embodiment of the present application. The method of Figure 12 can be applied to an encoder.

[0127] Referring to FIG. 12 , in step S1210, a first subblock and a second subblock in a current block are determined. The current block may refer to a current block to be encoded. In some implementations, the current block is a luma block. In other implementations, the current block may be a chroma block. The current block may be an inter-prediction block or an intra-prediction block. Taking an intra-prediction block as an example, the current block may be a prediction block based on an intra-block copy mode.

[0128] The first sub-block mentioned above may be a sub-block containing residual information. The second sub-block may be a sub-block not containing residual information. The residual information in the first sub-block can be processed through operations such as prediction, transformation, and quantization, thereby transmitting the residual information to the decoding end via a bitstream. Since the second sub-block does not contain residual information, operations such as transformation and quantization may not be performed on the second sub-block.

[0129] In some implementations, the first information may be written into the bitstream. The first information may indicate the positions of the first sub-block and the second sub-block in the current block. The first information may, for example, indicate the division ratio and / or division direction of the current block. Furthermore, the first information may also indicate which of the sub-blocks obtained by division is the first sub-block (i.e., which sub-block contains residual information) and which sub-block is the second sub-block (i.e., which sub-block does not contain residual information).

[0130] 12 , in step S1220 , reconstruction information of the first sub-block is determined based on the prediction information and residual information of the first sub-block. For example, the sum of the prediction information and residual information of the first sub-block can be used as the reconstruction information of the first sub-block.

[0131] It should be understood that the prediction information of the first sub-block may be information directly obtained after the prediction operation, or may be target information obtained by further processing the information obtained by the prediction operation. For example, the information obtained by the prediction operation of the first sub-block may be subjected to luminance mapping and chrominance scaling, and the information obtained after scaling may be used as the prediction information of the first sub-block.

[0132] Continuing with FIG. 12 , in step S1230 , initial reconstruction information for the second sub-block is determined based on the prediction information of the second sub-block. It should be understood that the prediction information for the second sub-block may refer to information directly obtained after the prediction operation, or may be information obtained after further processing of the information obtained through the prediction operation. For example, the information obtained through the prediction operation for the second sub-block may be subjected to luminance mapping and chrominance scaling, and the scaled information may be used as the prediction information for the second sub-block. Furthermore, the initial reconstruction information for the second sub-block determined in step S1230 does not include residual information. For example, the prediction information for the second sub-block may be directly used as the initial reconstruction information for the second sub-block.

[0133] Continuing with FIG. 12 , in step S1240, target reconstruction information for the second sub-block is determined based on the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block. In other words, the initial reconstruction information of the second sub-block is processed based on the reconstruction information of the first sub-block to determine the target reconstruction information for the second sub-block. For example, the reconstruction information of the first sub-block may be fused with the initial reconstruction information of the second sub-block to determine the target reconstruction information for the second sub-block.

[0134] The encoding method provided in the embodiment of the present application processes the initial reconstruction information (excluding residual information) of the second sub-block according to the reconstruction information (including residual information) of the first sub-block, which helps to introduce the residual information into the second sub-block, thereby improving the encoding performance.

[0135] The embodiment of the present application does not specifically limit the implementation method of step S1240. In some implementation methods, the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block can be weighted and fused. In other implementation methods, the first filter can be first determined based on the prediction information and reconstruction information of the first sub-block. The first filter can indicate the association or mapping relationship between the prediction information and the reconstruction information of the first sub-block. Then, the initial reconstruction information of the second sub-block can be filtered based on the first filter to determine the target reconstruction information of the second sub-block. This can be done because the first sub-block and the second sub-block are both located in the current block, and the relationship between the prediction information and reconstruction information of the first sub-block is similar to the relationship between the prediction information and reconstruction information of the second sub-block. Therefore, filtering the initial reconstruction information of the second sub-block based on the first filter helps to improve the accuracy of the reconstruction information of the second sub-block.

[0136] The embodiment of the present application does not specifically limit the shape of the first filter. For example, the shape of the first filter can be, for example, a 5-tap filter as shown in FIG5 . Alternatively, the shape of the first filter can also be a filter of other shapes, as shown in FIG6 .

[0137] The first filter can filter the initial reconstruction information of the second sub-block based on the filter coefficients. The filter coefficients of the first filter can be trained based on the relationship between the prediction information and the reconstruction information of the first sub-block. For example, the first filter can be slid within the region where the first sub-block is located. During the sliding process, the prediction information of the first sub-block can be used as the input information of the first filter, and the reconstruction information of the first sub-block can be used as the output information of the first filter, thereby constructing an autocorrelation coefficient matrix and a cross-correlation coefficient matrix. The filter coefficients of the first filter can then be determined based on the autocorrelation coefficient matrix and the cross-correlation coefficient matrix.

[0138] As an example, before sliding, the surrounding area of ​​the first sub-block can be filled to obtain a filled area. The filling information of the filled area can be, for example, the reconstruction information of the edge position of the first sub-block. Figure 7 shows the position of the filled area of ​​the first filter. As shown in Figure 7, a row or a column of pixels can be filled on the upper side, left side and right side of the first sub-block. After obtaining the filled area, the first filter can be slid within the first sub-block and the surrounding filled area of ​​the first sub-block. Taking the first filter as a 5-tap filter as an example, see Figure 8, the first filter can be slid horizontally from left to right starting from the upper left corner to the lower right corner, thereby constructing a linear equation based on the autocorrelation coefficient matrix and the cross-correlation coefficient matrix, as shown in the following formula (3):

[0139] Here, R represents the subblock region containing the residual coefficients, p_0 to p_(N-1) represent the five positions on the first filter, respectively. For example, t[r+p_0] represents the input information (i.e., prediction information or target value) of the first filter at the p_0th input position at the rth sample position, and t[r]' represents the reconstructed information at position r. In this example, the first filter is a 5-tap filter, so N = 5. Solving the above linear equation yields the five filter coefficients, c_0 to c_4.

[0140] After obtaining the filter coefficients of the first filter, the initial reconstruction information of the second sub-block can be filtered based on the filter coefficients of the first filter. For example, as shown in Figure 9, the first filter can slide within the area where the second sub-block is located (similar to the first sub-block, before sliding, the area around the second sub-block can be filled based on the initial reconstruction information of the second sub-block), and the initial reconstruction information of the second sub-block is used as the input information of the first filter, and the filter equation is constructed in combination with the filter coefficients. Accordingly, the calculation result of the above filter equation, that is, the output information of the filter, is used as the target reconstruction information of the second sub-block.

[0141] The above filtering equation can be shown as formula (4):

[0142] in, The pth position corresponding to the first filter at the rth position of the second sub-block n Input information of input positions (initial reconstruction information), c n is the nth filter coefficient of the first filter, o r is the filtered value corresponding to the rth position of the second sub-block. Generally speaking, the filtered value can be limited to a certain value range. For example, under the 10-bit pixel value accuracy, each filter output value o r Limited to 0 to 2 10-1 within the range.

[0143] In some implementations, as shown in FIG10 , the first filter may slide only within the first sub-block and / or the second sub-block (the dotted area in FIG10 ). In this case, there is no need to fill the surrounding areas of the first sub-block and / or the second sub-block, thereby simplifying the operation.

[0144] In some implementations, the embodiments of the present application may also write identification information into the bitstream to guide the decoding end to perform corresponding decoding operations. The identification information that may be involved in the embodiments of the present application is described in detail below.

[0145] In some implementations, the first identification information may be written into the bitstream. The first identification information is used to indicate or determine whether to perform filtering processing on the initial reconstruction information of the second sub-block. The first identification information may be information at the coding block level.

[0146] For example, cu_fsbt_flag may be used to represent the first identification information (of course, the first identification information may also be represented by any other letters and / or numbers). cu_fsbt_flag may be represented by a context-adaptive arithmetic entropy coding syntax element (ie, ae(v)).

[0147] In some implementations, the value of cu_fsbt_flag may be 0 or 1. For example, if the value of cu_fsbt_flag is 0, it may indicate that the initial reconstruction information of the second sub-block is not filtered; if the value of cu_fsbt_flag is 1, it may indicate that the initial reconstruction information of the second sub-block is filtered.

[0148] In some implementations, if cu_fsbt_flag does not exist in the codestream, cu_fsbt_flag may have a default value (eg, 0).

[0149] In some implementations, second identification information may be written into the bitstream. The second identification information may be used to indicate or determine whether to execute step S1240 described above, or the second identification information may be used to indicate whether to execute the filtering operation described above. The second identification information may include general constraint information, sequence-level information, frame-level information, slice-level information, tile-level information, or coding tree unit-level information.

[0150] For example, sps_fsbt_enabled_flag may be used to represent the second identification information (of course, the second identification information may also be represented by any other letters and / or numbers). sps_fsbt_enabled_flag may be represented by a 1-bit unsigned integer (ie, u(1)).

[0151] In some implementations, the value of sps_fsbt_enabled_flag may be 0 or 1. For example, if the value of sps_fsbt_enabled_flag is 0, it may indicate that step S440 is not performed; if the value of sps_fsbt_enabled_flag is 1, it may indicate that step S440 is performed.

[0152] In some implementations, if sps_fsbt_enabled_flag does not exist in the code stream, sps_fsbt_enabled_flag may have a default value (eg, 0).

[0153] In some implementations, third identification information may be written into the bitstream. This third identification information is used to indicate or determine whether the current block uses the sub-block transform mode. For example, if the third identification information indicates that the current block uses the sub-block transform mode, step S410 may be performed; if the third identification information indicates that the current block does not use the sub-block transform mode, step S410 may not be performed.

[0154] For example, cu_sbt_flag may be used to represent the third identification information (of course, the third identification information may also be represented by any other letters and / or numbers). cu_sbt_flag may be represented by a context-adaptive arithmetic entropy coding syntax element (ie, ae(v)).

[0155] In some implementations, the value of cu_sbt_flag can be 0 or 1. For example, if the value of cu_sbt_flag is 0, it may indicate that the current block does not use the sub-block transform mode, or in other words, the current block is not divided into sub-blocks according to step S410, but the reconstruction information of the current block is determined based on the residual information of the current block; if the value of cu_sbt_flag is 1, it may indicate that the current block uses the sub-block transform mode to determine the first sub-block and the second sub-block.

[0156] In some implementations, if cu_sbt_flag does not exist in the code stream, cu_sbt_flag may have a default value (eg, 0).

[0157] The embodiment of the present application does not specifically limit the positions of the first sub-block and the second sub-block in the current block. For example, the first sub-block and the second sub-block can follow the sub-block division method of SBT, that is, the current block is divided into 1 / 2 or 1 / 4 in the horizontal or vertical direction of the current block, thereby obtaining the first sub-block and the second sub-block. Alternatively, the embodiment of the present application can propose a new sub-block division method. The following, in conjunction with Figure 11, provides a more detailed example of the sub-block division method provided in the embodiment of the present application.

[0158] As shown in Figure 11(a), the current block is divided into two sub-blocks in the vertical direction. The gray sub-block in Figure 11(a) is the first sub-block, and the white sub-block is the second sub-block. The height ratio of the two sub-blocks is 1:N. The value of N can be different from 1 and 3.

[0159] As shown in Figure 11(b), the current block is divided into two sub-blocks horizontally. The gray sub-block in Figure 11(b) is the first sub-block, and the white sub-block is the second sub-block. The height ratio of the two sub-blocks is 1:N. The value of N can be different from 1 and 3.

[0160] As shown in FIG11( c ), the current block is divided into sub-blocks in both the vertical and horizontal directions. The gray sub-block in FIG11( c ) is the first sub-block, and the white sub-block is the second sub-block.

[0161] As shown in FIG11( d ), the current block is divided into sub-blocks in both the vertical and horizontal directions. The gray sub-block in FIG11( d ) is the first sub-block, and the white sub-block is the second sub-block.

[0162] The following examples are used to describe the embodiments of the present application in more detail. It should be noted that the examples below are only intended to help those skilled in the art understand the embodiments of the present application, rather than to limit the embodiments of the present application to the specific numerical values ​​or specific scenarios illustrated. It is apparent that those skilled in the art can make various equivalent modifications or changes based on the examples given below, and such modifications or changes also fall within the scope of the embodiments of the present application.

[0163] The first step is to parse the high-level syntax elements in the code stream. The high-level syntax elements are used to determine whether the decoding method provided by the embodiment of the present application is allowed to be used. This high-level syntax element can be, for example, sequence-level information, frame-level information, slice-level information, tile-level information, or coding tree unit level. Table 1 is the sequence-level syntax element decoding table of the embodiment of the present application. sps_fsbt_enabled_flag is a binary identification information. When the identification information does not exist in the code stream, its default value is 0. When its value is 1, it indicates that the current code stream allows the use of the above filtering technology; when its value is 0, it indicates that the above filtering technology is not allowed to be used.

[0164] Table 1

[0165] Table 2 is a block-level syntax element decoding table of an embodiment of the present application. cu_fsbt_flag is a binary identification information. When the identification information does not exist in the code stream, its default value is 0. When its value is 1, it indicates that the current code stream allows the use of the above-mentioned filtering technology; when its value is 0, it indicates that the above-mentioned filtering technology is not allowed. Table 2 also includes binary identification information cu_sbt_flag. When the identification information does not exist in the code stream, its default value is 0. When its value is 1, it indicates that the current code stream allows the use of SBT technology; when its value is 0, it indicates that SBT technology is not allowed. In addition, Table 2 also includes identification information indicating the position, division ratio, and division direction of the sub-block.

[0166] Table 2

[0167] In the second step, if SBT is used and cu_fsbt_flag is 1 in the parsed bitstream, a filter is obtained and the sub-blocks without residual information are filtered.

[0168] The shape of the filter may be, for example, the 5-tap filter in FIG. 5 , and the shape of the first filter may be, for example, other filters in FIG. 6 .

[0169] In the third step, the current block is divided into two sub-blocks based on the SBT technique. The reconstructed blocks of the two sub-blocks are determined during the decoding process. As shown in Figure 7, the reconstructed block of the first sub-block contains residual information, while the initial reconstructed block of the second sub-block does not. For example, the prediction block of the second sub-block can be used as the initial reconstructed block of the second sub-block, or the target value obtained after luma mapping and chroma scaling of the prediction block of the second sub-block can be used as the initial reconstructed block of the second sub-block.

[0170] Pad the area around the reconstructed block. For example, in this solution, a 5-tap filter needs to be padded as shown in Figure 7. This means padding one row or one column above, to the left, and to the right of the current block. The padding information can be, for example, reconstruction information about the sub-block edges.

[0171] The fourth step is to slide the filter over the area of ​​the first sub-block, use the prediction information or the above-mentioned target value as the input of the filter, and the reconstruction information as the output of the filter to construct the autocorrelation coefficient matrix and the cross-correlation coefficient vector. Specifically, as shown in formula (5). Where R represents the sub-block area containing the residual coefficient, p_0 to p_(N-1) represent the five positions on the filter, for example, t[r+p_0] represents the input information (i.e., prediction information or target value) of the p_0 filter at the r-th sample position, and t[r]' is the reconstruction information at the r-th position. In this example, the filter has 5 taps, so N = 5.

[0172] By solving the above linear equations, we can obtain the five filter coefficients, c_0 to c_4, of the filter.

[0173] The fifth step is to filter the prediction information (target value) of the second sub-block based on the obtained filter and filter coefficient. The filtering process is to slide in the area where the second sub-block is located, use the prediction information (target value) as the filter input, and obtain the output of the filter at each position. Accordingly, the output of the filter is used as the target reconstruction information of the second sub-block. The above filtering equation can be shown as formula (6), where, The pth position corresponding to the rth position of the second sub-block n Prediction information (target value), c n is the obtained nth filter coefficient, o r is the filtered value at position r.

[0174] Generally speaking, the filtered value can be limited to a certain range of values. For example, under the 10-bit pixel value accuracy, this solution can limit each filter output value to r Limited to 0 to 2 10-1 within the range.

[0175] By implementing the encoding and decoding methods provided by the embodiments of this application in relevant reference software, a set of experimental data was generated. The specific parameter results of the experimental data can be found in Table 3. As can be seen from Table 3, the encoding effect is improved for some videos, such as Ritual Dance, Cactus, Basketball Drill, and Party Scene.

[0176] Table 3

[0177] It should be noted that, on the encoder side, in addition to completing reconstruction and filtering using the decoder's steps, the encoder can also decide whether to use the encoding and decoding method provided by the embodiment of the present application. For example, the encoder can compare the cost of the encoding and decoding method provided by the embodiment of the present application with that of other modes using a rate-distortion cost method and select the mode with the lowest cost.

[0178] The method embodiment of the present application is described in detail above in conjunction with Figures 1 to 12. The device embodiment of the present application is described in detail below in conjunction with Figures 13 to 16. It should be understood that the description of the method embodiment corresponds to the description of the device embodiment. Therefore, for parts not described in detail, reference can be made to the above method embodiment.

[0179] FIG13 is a schematic diagram of the structure of a decoder provided by one embodiment of the present application. As shown in FIG13 , the decoder 1300 includes: a first determination unit 1310, a second determination unit 1320, a third determination unit 1330, and a fourth determination unit 1340. The first determination unit 1310 is configured to parse the bitstream and determine the first sub-block and the second sub-block in the current block; the second determination unit 1320 is configured to determine the reconstruction information of the first sub-block based on the prediction information and residual information of the first sub-block; the third determination unit 1330 is configured to determine the initial reconstruction information of the second sub-block based on the prediction information of the second sub-block, where the initial reconstruction information of the second sub-block does not include residual information; and the fourth determination unit 1340 is configured to determine the target reconstruction information of the second sub-block based on the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block.

[0180] In some implementations, the fourth determination unit 1340 is configured to: determine a first filter based on the prediction information of the first sub-block and the reconstruction information of the first sub-block, where the first filter is used to indicate the association between the prediction information of the first sub-block and the reconstruction information of the first sub-block; and filter the initial reconstruction information of the second sub-block based on the first filter to determine the target reconstruction information of the second sub-block.

[0181] In some implementations, the fourth determination unit 1340 is configured to: determine an autocorrelation coefficient matrix and a cross-correlation coefficient matrix based on the prediction information of the first sub-block and the reconstruction information of the first sub-block; and determine filtering parameters of the first filter based on the autocorrelation coefficient matrix and the cross-correlation coefficient matrix.

[0182] In some implementations, the first filter is determined based on reconstruction information within the first sub-block and pixel information of a filling area around the first sub-block; or, the first filter is determined based only on reconstruction information within the first sub-block.

[0183] In some implementations, the decoder 1300 further includes: a fifth determining unit configured to parse the code stream and determine first identification information, where the first identification information is used to indicate whether to perform filtering processing on the initial reconstruction information of the second sub-block.

[0184] In some implementations, the decoder 1300 further includes: a sixth determining unit configured to parse the code stream and determine second identification information, where the second identification information is used to indicate whether to perform the step of determining target reconstruction information of the second sub-block.

[0185] In some implementations, the second identification information is general constraint information, sequence-level information, frame-level information, slice-level information, tile-level information, or coding tree unit-level information.

[0186] In some implementations, the decoder 1300 further includes: a seventh determination unit configured to parse the code stream and determine third identification information, where the third identification information is used to indicate whether the current block uses a sub-block transform mode; and the first determination unit 1310 is configured to determine the first sub-block and the second sub-block if the third identification information indicates that the current block uses a sub-block transform mode.

[0187] In some implementations, the decoder 1300 further includes: an eighth determination unit configured to: determine reconstruction information of the current block based on residual information of the current block if the third identification information indicates that the current block does not use a sub-block transform mode.

[0188] In some implementations, the current block is an inter-frame prediction block or an intra-frame prediction block based on an intra-frame block copy mode.

[0189] In some implementations, the first determining unit 1310 is configured to parse a code stream to determine first information, where the first information is used to determine positions of the first sub-block and the second sub-block in the current block.

[0190] In some implementations, the first information is used to indicate a division ratio and / or division direction of the current block.

[0191] In some implementations, the initial reconstruction information of the second sub-block is prediction information of the second sub-block, or target information obtained after performing luminance mapping and chrominance scaling on the prediction information of the second sub-block.

[0192] In some implementations, the decoder 1300 further includes: a ninth determination unit configured to parse the code stream and determine the quantization coefficient; a tenth determination unit configured to inverse quantize the quantization coefficient and determine the transformation coefficient; and an eleventh determination unit configured to inverse transform the transformation coefficient and determine the residual information of the first sub-block.

[0193] It is understandable that in the embodiments of the present application, a "unit" can be a portion of a circuit, a portion of a processor, a portion of a program or software, etc., and of course it can also be a module, or it can be non-modular. Moreover, the various components in this embodiment can be integrated into a processing unit, or each unit can exist physically separately, or two or more units can be integrated into a single unit. The above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional modules.

[0194] If the integrated unit is implemented as a software functional module and is not sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this embodiment, or the portion that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing a computer device (which can be a personal computer, server, or network device, etc.) or a processor to execute all or part of the steps of the method described in this embodiment. The aforementioned storage medium includes various media that can store program code, such as a USB flash drive, a mobile hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.

[0195] Therefore, an embodiment of the present application provides a computer-readable storage medium, which is applied to the decoder 1300. The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the above-mentioned decoding method is implemented.

[0196] Based on the composition of the above-mentioned decoder 1300 and the computer-readable storage medium, refer to Figure 14, which shows a specific hardware structure diagram of the decoder provided by an embodiment of the present application. As shown in Figure 14, the decoder 1400 may include: a communication interface 1410, a memory 1420 and a processor 1430; each component is coupled together through a bus system 1440. It can be understood that the bus system 1440 is used to achieve connection and communication between these components. In addition to the data bus, the bus system 1440 also includes a power bus, a control bus and a status signal bus. However, for the sake of clarity, various buses are labeled as bus system 1440 in Figure 14. Among them,

[0197] The communication interface 1410 is used to receive and send signals when sending and receiving information with other external network elements.

[0198] The memory 1420 is used to store computer programs.

[0199] The processor 1430 is configured to, when running the computer program, execute:

[0200] Parse the code stream to determine the first sub-block and the second sub-block in the current block;

[0201] determining reconstruction information of the first sub-block according to the prediction information and residual information of the first sub-block;

[0202] determining initial reconstruction information of the second sub-block according to the prediction information of the second sub-block, where the initial reconstruction information of the second sub-block does not include residual information;

[0203] Target reconstruction information of the second sub-block is determined according to the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block.

[0204] It is understood that the memory 1420 in the embodiment of the present application can be a volatile memory or a non-volatile memory, or can include both volatile and non-volatile memories. Among them, the non-volatile memory can be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory can be a random access memory (RAM), which is used as an external cache. By way of example and not limitation, many forms of RAM are available, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate synchronous DRAM (DDRSDRAM), enhanced synchronous DRAM (ESDRAM), synchronous link DRAM (SLDRAM), and direct RAM bus random access memory (DRRAM). The memory 1420 of the systems and methods described herein is intended to include, but is not limited to, these and any other suitable types of memory.

[0205] The processor 1430 may be an integrated circuit chip with signal processing capabilities. During implementation, each step of the above method can be completed by hardware integrated logic circuits or software instructions in the processor 1430. The above-mentioned processor 1430 can be a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. The various methods, steps, and logic block diagrams disclosed in the embodiments of this application can be implemented or executed. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in the embodiments of this application can be directly implemented and executed by a hardware decoding processor, or by a combination of hardware and software modules in the decoding processor. The software module can be located in a storage medium mature in the art, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, etc. The storage medium is located in the memory 1420 , and the processor 1430 reads the information in the memory 1420 and completes the steps of the above method in combination with its hardware.

[0206] It is to be understood that these embodiments described in the present application can be implemented with hardware, software, firmware, middleware, microcode or its combination.For hardware implementation, the processing unit can be implemented in one or more application specific integrated circuits (Application Specific Integrated Circuits, ASIC), digital signal processor (Digital Signal Processing, DSP), digital signal processing equipment (DSP Device, DSPD), programmable logic device (Programmable Logic Device, PLD), field programmable gate array (Field-Programmable Gate Array, FPGA), general-purpose processor, controller, microcontroller, microprocessor, other electronic units for performing functions described in the present application or its combination.For software implementation, the technology described in the present application can be realized by the module (such as process, function etc.) that performs functions described in the present application. The software code can be stored in a memory and executed by a processor. The memory can be implemented in the processor or outside the processor.

[0207] Optionally, as another embodiment, the processor 1430 is further configured to execute the decoding method described in the above embodiment when running the computer program.

[0208] FIG15 is a schematic diagram of the structure of an encoder provided by one embodiment of the present application. As shown in FIG15 , the encoder 1500 includes: a first determination unit 1510, a second determination unit 1520, a third determination unit 1530, and a fourth determination unit 1540. The first determination unit 1510 is configured to determine a first sub-block and a second sub-block in a current block; the second determination unit 1520 is configured to determine reconstruction information for the first sub-block based on prediction information and residual information of the first sub-block; the third determination unit 1530 is configured to determine initial reconstruction information for the second sub-block based on the prediction information of the second sub-block, where the initial reconstruction information of the second sub-block does not include residual information; and the fourth determination unit 1540 is configured to determine target reconstruction information for the second sub-block based on the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block.

[0209] In some implementations, the fourth determination unit 1540 is configured to: determine a first filter based on the prediction information of the first sub-block and the reconstruction information of the first sub-block, where the first filter is used to indicate the association between the prediction information of the first sub-block and the reconstruction information of the first sub-block; and filter the initial reconstruction information of the second sub-block based on the first filter to determine the target reconstruction information of the second sub-block.

[0210] In some implementations, the fourth determination unit 1540 is configured to: determine an autocorrelation coefficient matrix and a cross-correlation coefficient matrix based on the prediction information of the first sub-block and the reconstruction information of the first sub-block; and determine filtering parameters of the first filter based on the autocorrelation coefficient matrix and the cross-correlation coefficient matrix.

[0211] In some implementations, the first filter is determined based on reconstruction information within the first sub-block and pixel information of a filling area around the first sub-block; or, the first filter is determined based only on reconstruction information within the first sub-block.

[0212] In some implementations, the encoder 1500 further includes: a first writing unit configured to write first identification information into a bitstream, where the first identification information is used to indicate whether to perform filtering processing on the initial reconstruction information of the second sub-block.

[0213] In some implementations, the encoder 1500 further includes: a second writing unit configured to write second identification information into the bitstream, where the second identification information is used to indicate whether to perform the step of determining target reconstruction information of the second sub-block.

[0214] In some implementations, the second identification information is general constraint information, sequence-level information, frame-level information, slice-level information, tile-level information, or coding tree unit-level information.

[0215] In some implementations, the encoder 1500 further includes: a third writing unit configured to write third identification information into the bitstream, where the third identification information is used to indicate whether the current block uses a sub-block transform mode.

[0216] In some implementations, the current block is an inter-frame prediction block or an intra-frame prediction block based on an intra-frame block copy mode.

[0217] In some implementations, the encoder 1500 further includes: a fourth writing unit configured to write first information into the bitstream, where the first information is used to determine positions of the first sub-block and the second sub-block in the current block.

[0218] In some implementations, the first information is used to indicate a division ratio and / or division direction of the current block.

[0219] In some implementations, the initial reconstruction information of the second sub-block is prediction information of the second sub-block, or target information obtained after performing luminance mapping and chrominance scaling on the prediction information of the second sub-block.

[0220] In some implementations, the encoder 1500 further includes: a quantization unit configured to quantize the transform coefficients determined based on the residual information of the first sub-block to determine the quantization coefficients; and an encoding unit configured to encode the quantization coefficients.

[0221] It is understandable that in the embodiments of the present application, a "unit" can be a portion of a circuit, a portion of a processor, a portion of a program or software, etc., and of course it can also be a module, or it can be non-modular. Moreover, the various components in this embodiment can be integrated into a processing unit, or each unit can exist physically separately, or two or more units can be integrated into a single unit. The above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional modules.

[0222] If the integrated unit is implemented as a software functional module and not sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this embodiment, or the portion that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing a computer device (which can be a personal computer, server, or network device, etc.) or a processor to perform all or part of the steps of the method described in this embodiment. The aforementioned storage medium includes various media that can store program code, such as a USB flash drive, a mobile hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.

[0223] Therefore, an embodiment of the present application provides a computer-readable storage medium, which is applied to the encoder 1500. The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the encoding method in the aforementioned embodiment is implemented.

[0224] Based on the composition of the above-mentioned encoder 1500 and the computer-readable storage medium, refer to Figure 16, which shows a specific hardware structure diagram of the encoder provided by an embodiment of the present application. As shown in Figure 16, the encoder 1600 may include: a communication interface 1610, a memory 1620 and a processor 1630; each component is coupled together through a bus system 1640. It can be understood that the bus system 1640 is used to realize the connection and communication between these components. In addition to the data bus, the bus system 1640 also includes a power bus, a control bus and a status signal bus. However, for the sake of clarity, various buses are labeled as bus system 1640 in Figure 16. Among them,

[0225] The communication interface 1610 is used to receive and send signals when sending and receiving information with other external network elements.

[0226] The memory 1620 is used to store computer programs.

[0227] The processor 1630 is configured to, when running the computer program, execute:

[0228] Determining a first sub-block and a second sub-block in the current block;

[0229] determining reconstruction information of the first sub-block according to the prediction information and residual information of the first sub-block;

[0230] determining initial reconstruction information of the second sub-block according to the prediction information of the second sub-block, where the initial reconstruction information of the second sub-block does not include residual information;

[0231] Target reconstruction information of the second sub-block is determined according to the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block.

[0232] It is understood that the memory 1620 in the embodiment of the present application can be a volatile memory or a non-volatile memory, or can include both volatile and non-volatile memories. Among them, the non-volatile memory can be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory can be a random access memory (RAM), which is used as an external cache. By way of example and not limitation, many forms of RAM are available, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate synchronous DRAM (DDRSDRAM), enhanced synchronous DRAM (ESDRAM), synchronous link DRAM (SLDRAM), and direct RAM bus random access memory (DRRAM). The memory 1620 of the systems and methods described herein is intended to include, but is not limited to, these and any other suitable types of memory.

[0233] The processor 1630 may be an integrated circuit chip with signal processing capabilities. During implementation, each step of the above method can be completed by hardware integrated logic circuits or software instructions in the processor 1630. The above-mentioned processor 1630 can be a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. The various methods, steps, and logic block diagrams disclosed in the embodiments of this application can be implemented or executed. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in the embodiments of this application can be directly implemented and executed by a hardware decoding processor, or by a combination of hardware and software modules in the decoding processor. The software module can be located in a storage medium mature in the art, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, etc. The storage medium is located in the memory 1620 , and the processor 1630 reads the information in the memory 1620 and completes the steps of the above method in combination with its hardware.

[0234] It is to be understood that these embodiments described in the present application can be implemented with hardware, software, firmware, middleware, microcode or its combination.For hardware implementation, the processing unit can be implemented in one or more application specific integrated circuits (Application Specific Integrated Circuits, ASIC), digital signal processor (Digital Signal Processing, DSP), digital signal processing equipment (DSP Device, DSPD), programmable logic device (Programmable Logic Device, PLD), field programmable gate array (Field-Programmable Gate Array, FPGA), general-purpose processor, controller, microcontroller, microprocessor, other electronic units for performing functions described in the present application or its combination.For software implementation, the technology described in the present application can be realized by the module (such as process, function etc.) that performs functions described in the present application. The software code can be stored in a memory and executed by a processor. The memory can be implemented in the processor or outside the processor.

[0235] Optionally, as another embodiment, the processor 1630 is further configured to execute the encoding method described in the above embodiment when running the computer program.

[0236] It should be noted that, in this application, the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, article, or apparatus comprising a series of elements includes not only those elements but also other elements not explicitly listed, or elements inherent to such process, method, article, or apparatus. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of other identical elements in the process, method, article, or apparatus comprising the element.

[0237] The serial numbers of the above embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.

[0238] The methods disclosed in the several method embodiments provided in this application can be arbitrarily combined without conflict to obtain new method embodiments.

[0239] The features disclosed in the several product embodiments provided in this application can be arbitrarily combined without conflict to obtain new product embodiments.

[0240] The features disclosed in the several method or device embodiments provided in this application can be arbitrarily combined without conflict to obtain new method embodiments or device embodiments.

[0241] The above description is merely a specific embodiment of the present application, but the scope of protection of the present application is not limited thereto. Any changes or substitutions that can be easily conceived by a person skilled in the art within the technical scope disclosed in this application should be included in the scope of protection of this application. Therefore, the scope of protection of this application should be based on the scope of protection of the claims.

Claims

1. A decoding method, applied to a decoder, comprising: Parsing a bitstream to determine a first sub-block and a second sub-block in a current block; Determining reconstruction information of the first sub-block according to prediction information and residual information of the first sub-block; Determining initial reconstruction information of the second sub-block according to prediction information of the second sub-block, where the initial reconstruction information of the second sub-block does not include residual information; Determining target reconstruction information of the second sub-block according to the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block.

2. The method according to claim 1, wherein, The determining the target reconstruction information of the second sub-block according to the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block includes: Determining a first filter according to the prediction information of the first sub-block and the reconstruction information of the first sub-block, where the first filter is used to indicate the correlation relationship between the prediction information of the first sub-block and the reconstruction information of the first sub-block; Performing filtering processing on the initial reconstruction information of the second sub-block according to the first filter to determine the target reconstruction information of the second sub-block.

3. The method according to claim 2, wherein The determining the first filter according to the prediction information of the first sub-block and the reconstruction information of the first sub-block includes: Determining an autocorrelation coefficient matrix and a cross-correlation coefficient matrix according to the prediction information of the first sub-block and the reconstruction information of the first sub-block; Determining filtering parameters of the first filter according to the autocorrelation coefficient matrix and the cross-correlation coefficient matrix.

4. The method according to claim 2 or 3, wherein: The first filter is determined based on reconstruction information within the first sub-block and pixel information of a padding area around the first sub-block; or, The first filter is determined only based on reconstruction information within the first sub-block.

5. The method according to any one of claims 2 to 4, wherein The method further comprises: Parsing the bitstream to determine first identification information, where the first identification information is used to indicate whether to perform filtering processing on the initial reconstruction information of the second sub-block.

6. The method according to any one of claims 1 to 5, wherein The method further comprises: Parsing the bitstream to determine second identification information, where the second identification information is used to indicate whether to perform the step of determining the target reconstruction information of the second sub-block.

7. The method according to claim 6, wherein The second identification information is general constraint information, sequence-level information, frame-level information, slice-level information, tile-level information, or coding tree unit-level information.

8. The method according to any one of claims 1 to 7, wherein, The method further comprises: Parsing the bitstream to determine third identification information, where the third identification information is used to indicate whether the current block uses a sub-block transform mode; The determining the first sub-block and the second sub-block in the current block includes: If the third identification information indicates that the current block uses the sub-block transform mode, determining the first sub-block and the second sub-block.

9. The method according to claim 8, wherein The method further comprises: If the third identification information indicates that the current block does not use the sub-block transform mode, determining reconstruction information of the current block according to residual information of the current block.

10. The method according to any one of claims 1 to 9, wherein, The current block is an inter prediction block or an intra prediction block based on an intra block copy mode.

11. The method according to any one of claims 1 to 10, wherein The parsing the bitstream to determine the first sub-block and the second sub-block in the current block includes: Parse the bitstream to determine first information, where the first information is used to determine the positions of the first sub-block and the second sub-block in the current block.

12. The method according to claim 11, wherein, The first information is used to indicate the partitioning ratio and / or partitioning direction of the current block.

13. The method according to any one of claims 1 to 12, wherein, The initial reconstruction information of the second sub-block is the prediction information of the second sub-block, or the target information obtained after performing luminance mapping and chrominance scaling on the prediction information of the second sub-block.

14. The method according to any one of claims 1 to 13, wherein, The method further includes: Parse the bitstream to determine quantization coefficients; Perform inverse quantization on the quantization coefficients to determine transform coefficients; Perform inverse transform on the transform coefficients to determine the residual information of the first sub-block.

15. An encoding method applied to an encoder, including: Determine a first sub-block and a second sub-block in the current block; Determine the reconstruction information of the first sub-block according to the prediction information and residual information of the first sub-block; Determine the initial reconstruction information of the second sub-block according to the prediction information of the second sub-block, where the initial reconstruction information of the second sub-block does not include residual information; Determine the target reconstruction information of the second sub-block according to the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block.

16. The method according to claim 15, wherein, The determining the target reconstruction information of the second sub-block according to the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block includes: Determine a first filter according to the prediction information of the first sub-block and the reconstruction information of the first sub-block, where the first filter is used to indicate the correlation relationship between the prediction information of the first sub-block and the reconstruction information of the first sub-block; Perform filtering processing on the initial reconstruction information of the second sub-block according to the first filter to determine the target reconstruction information of the second sub-block.

17. The method according to claim 16, wherein, The determining the first filter according to the prediction information of the first sub-block and the reconstruction information of the first sub-block includes: Determine an autocorrelation coefficient matrix and a cross-correlation coefficient matrix according to the prediction information of the first sub-block and the reconstruction information of the first sub-block; Determine the filtering parameters of the first filter according to the autocorrelation coefficient matrix and the cross-correlation coefficient matrix.

18. The method according to claim 16 or 17, wherein: The first filter is determined based on the reconstruction information within the first sub-block and the pixel information of the padding area around the first sub-block; or, The first filter is determined only based on the reconstruction information within the first sub-block.

19. The method according to any one of claims 16 to 18, wherein The method further includes: Write first identification information into the bitstream, where the first identification information is used to indicate whether to perform filtering processing on the initial reconstruction information of the second sub-block.

20. The method according to any one of claims 15 to 19, wherein The method further includes: Write second identification information into the bitstream, where the second identification information is used to indicate whether to perform the step of determining the target reconstruction information of the second sub-block.

21. The method according to claim 20, wherein, The second identification information is general constraint information, sequence-level information, frame-level information, slice-level information, tile-level information, or coding tree unit-level information.

22. The method according to any one of claims 15 to 21, wherein, The method further includes: Write third identification information into the bitstream, where the third identification information is used to indicate whether the current block uses a sub-block transform mode.

23. The method according to any one of claims 15 to 22, wherein The current block is an inter prediction block or an intra prediction block based on the intra block copy mode.

24. The method according to any one of claims 15 to 23, wherein, The method further includes: Writing first information into a bitstream, where the first information is used to determine the positions of the first sub-block and the second sub-block in the current block.

25. The method according to claim 24, wherein, The first information is used to indicate the partitioning ratio and / or partitioning direction of the current block.

26. The method according to any one of claims 15 to 25, wherein The initial reconstruction information of the second sub-block is the prediction information of the second sub-block, or the target information obtained after performing luminance mapping and chrominance scaling on the prediction information of the second sub-block.

27. The method according to any one of claims 15 to 26, wherein, The method further includes: Quantizing transform coefficients determined based on the residual information of the first sub-block to determine quantized coefficients; Encoding the quantized coefficients.

28. A decoder, comprising: A first determination unit configured to parse a bitstream and determine a first sub-block and a second sub-block in a current block; A second determination unit configured to determine the reconstruction information of the first sub-block according to the prediction information and residual information of the first sub-block; A third determination unit configured to determine the initial reconstruction information of the second sub-block according to the prediction information of the second sub-block, where the initial reconstruction information of the second sub-block does not include residual information; A fourth determination unit configured to determine the target reconstruction information of the second sub-block according to the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block.

29. A decoder, comprising: A memory for storing a computer program; A processor for, when running the computer program, performing the method according to any one of claims 1 to 14.

30. An encoder, comprising: A first determination unit configured to determine a first sub-block and a second sub-block in a current block; A second determination unit configured to determine the reconstruction information of the first sub-block according to the prediction information and residual information of the first sub-block; A third determination unit configured to determine the initial reconstruction information of the second sub-block according to the prediction information of the second sub-block, where the initial reconstruction information of the second sub-block does not include residual information; A fourth determination unit configured to determine the target reconstruction information of the second sub-block according to the reconstruction information of the first sub-block and the initial reconstruction information of the second sub-block.

31. An encoder, comprising: A memory for storing a computer program; A processor for, when running the computer program, performing the method according to any one of claims 15 to 27.

32. A non-volatile computer-readable storage medium storing a bitstream, the bitstream being generated by an encoding method using an encoder, or the bitstream being decoded by a decoding method using a decoder, wherein, The decoding method is the method according to any one of claims 1 to 14, and the encoding method is the method according to any one of claims 15 to 27.

33. A bitstream, where the bitstream includes a bitstream generated by the method according to any one of claims 1 to 14 or a bitstream generated by the method according to any one of claims 15 to 27.