Method and apparatus for intra predictive coding of video data
By adopting matrix-based intra prediction technology and conventional intra prediction technology in video coding, the coding efficiency problem of the existing technology at high image resolution and frame rate is solved, and higher video data coding efficiency and quality are achieved. .
Patent Information
- Application Number
- CN202410981745.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2020-08-05
- Filing Date
- 2020-08-06
- Publication Date
- 2024-10-01
AI Technical Summary
Facing the increase in image size, resolution and frame rate, existing video coding technology is difficult to achieve higher coding efficiency and image quality, and consumes large hardware resources.
Matrix-based intra prediction technology (MIP) and conventional intra prediction technology are used to obtain luminance and chroma prediction mode information from the bit stream, deduce the intra prediction type and mode, generate chroma prediction samples, and optimize intra prediction process.
It improves the coding efficiency and image quality of video data, reduces the demand for hardware resources, and adapts to the growth of video data volume.
Smart Images

Figure CN118741106A_ABST
Abstract
Description
[0001] This application is a divisional application of the PCT patent application entered into China with Chinese patent application number 202080054504.5, invention name “Method and device for intra-frame prediction encoding of video data”, and application date August 6, 2020.
[0002] CROSS-REFERENCE TO RELATED APPLICATIONS
[0003] This application claims priority to Patent Application No. 10-2019-0095449 filed in Korea on August 6, 2019, Patent Application No. 10-2019-0097449 filed in Korea on August 9, 2019, and Patent Application No. 10-2020-0098223 filed in Korea on August 5, 2020, the entire contents of which are incorporated herein by reference. Technical Field
[0004] The present invention relates to encoding and decoding of video data. Background Art
[0005] Since the amount of video data is usually larger than that of voice data or still image data, storing or transmitting the video data without compression processing requires a large amount of hardware resources (including memory).
[0006] Accordingly, when storing or transmitting video data, an encoder is usually used to compress the video data for storage or transmission. Then, a decoder receives the compressed video data, decompresses and reproduces the video data. Compression technologies used for video include H.264 / AVC and High Efficiency Video Coding (HEVC), which improves the coding efficiency of H.264 / AVC by about 40%.
[0007] However, for video data, the image size, resolution and frame rate are gradually increasing, and accordingly, the amount of data to be encoded is also increasing. Therefore, a new compression technology with better encoding efficiency and higher image quality than the existing compression technology is needed. Summary of the invention
[0008] The present invention discloses an improved technique for intra-frame predictive coding of blocks of video data.
[0009] According to one aspect of the present invention, a method for decoding video data includes: obtaining information about a luma prediction mode of a current coding block and information about a chroma prediction mode of the current coding block from a bitstream; deriving a luma intra prediction type and a luma intra prediction mode of the current coding block based on the information about the luma prediction mode, wherein the luma intra prediction type includes a matrix-based intra prediction (MIP) and a conventional intra prediction; determining a chroma intra prediction mode of the current coding block based on the luma intra prediction type and the luma intra prediction mode of the current coding block and the information about the chroma prediction mode; and generating a chroma prediction sample of the current coding block based on the chroma intra prediction mode of the current coding block.
[0010] Determining the chroma intra prediction mode of the current coding block includes: if the information about the chroma prediction mode indicates a direct mode (DM), the luma intra prediction type of the current coding block is a matrix-based intra prediction, and the sampling format of the video data is 4:4:4, then determining that the chroma intra prediction type of the current coding block is a matrix-based intra prediction, and determining that the chroma intra prediction mode corresponding to the chroma intra prediction type of the current coding block is the same as the matrix-based intra prediction mode derived as the luma intra prediction mode of the current coding block.
[0011] Determining the chroma intra-frame prediction mode of the current coding block includes: if the information about the chroma prediction mode indicates the direct mode (DM), the luminance intra-frame prediction type of the current coding block is matrix-based intra-frame prediction, and the sampling format of the video data is 4:2:0 or 4:2:2, then determining that the chroma intra-frame prediction mode of the current coding block is a planar (PLANAR) mode.
[0012] Determining the chroma intra-frame prediction mode of the current coding block includes: if the information about the chroma prediction mode indicates a direct mode (DM) and the luma intra-frame prediction type of the current coding block is a regular intra-frame prediction type, then determining that the chroma intra-frame prediction mode of the current coding block is the same as the regular intra-frame prediction mode derived as the luma intra-frame prediction mode of the current coding block.
[0013] According to another aspect of the present invention, a device for decoding video data includes a decoding unit and an intra-frame prediction unit, wherein the decoding unit obtains information about a luma prediction mode of a current coding block and information about a chroma prediction mode of the current coding block from a bitstream; the intra-frame prediction unit derives a luma intra-frame prediction type and a luma intra-frame prediction mode of the current coding block based on the information about the luma prediction mode, determines a chroma intra-frame prediction mode of the current coding block based on the luma intra-frame prediction type and the luma intra-frame prediction mode of the current coding block and the information about the chroma prediction mode, and generates a chroma prediction sample of the current coding block based on the chroma intra-frame prediction mode of the current coding block, wherein the luma intra-frame prediction type includes a matrix-based intra-frame prediction (MIP) and a conventional intra-frame prediction.
[0014] When determining the chroma intra-frame prediction mode of the current coding block, if the information about the chroma prediction mode indicates the direct mode (DM), the luma intra-frame prediction type of the current coding block is matrix-based intra-frame prediction, and the sampling format of the video data is 4:4:4, the intra-frame prediction unit determines that the chroma intra-frame prediction type of the current coding block is matrix-based intra-frame prediction, and determines that the chroma intra-frame prediction mode corresponding to the chroma intra-frame prediction type of the current coding block is the same as the matrix-based intra-frame prediction mode derived as the luma intra-frame prediction mode of the current coding block. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] Figure 1 is an exemplary block diagram of a video encoding device capable of implementing the techniques of the present invention.
[0016] Figure 2 A block partition structure using a QTBTTT structure is exemplarily shown.
[0017] Figure 3 A plurality of intra prediction modes including a wide-angle intra prediction mode are exemplarily shown.
[0018] Figure 4 is an exemplary block diagram of a video decoding device capable of implementing the techniques of the present invention.
[0019] Figure 5 is a conceptual diagram showing the main process of the MIP technology that can be used in the technology of the present invention.
[0020] Figure 6 is a flowchart illustrating a method of decoding video data according to an embodiment of the present invention. DETAILED DESCRIPTION
[0021] Hereinafter, some embodiments of the present invention will be described in detail with reference to the accompanying drawings. It should be noted that when reference numerals are added to the constituent elements in the various drawings, the same reference numerals also represent the same elements, although the elements are shown in different drawings. In addition, in the following description of the present invention, the detailed description of the known functions and configurations incorporated herein will be omitted to avoid blurring the subject matter of the present invention.
[0022] Figure 1 is an exemplary block diagram of a video encoding device capable of implementing the technology of the present invention. Figure 1 A video encoding apparatus and elements of the apparatus are described below.
[0023] The video encoding device includes: an image divider 110, a predictor 120, a subtractor 130, a transformer 140, a quantizer 145, a rearrangement unit 150, an entropy encoder 155, an inverse quantizer 160, an inverse transformer 165, an adder 170, a filtering unit 180 and a memory 190.
[0024] Each element of the video encoding device may be implemented in hardware or software, or a combination of hardware and software. The functions of each element may be implemented as software, and a microprocessor may be implemented to execute the software functions corresponding to each element.
[0025] A video includes multiple images. Each image is divided into multiple regions, and encoding is performed on each region. For example, an image is divided into one or more tiles (tile) or / and slices (slice). Here, one or more tiles can be defined as tile groups. Each tile or slice is divided into one or more coding tree units (coding treeunit, CTU). Each CTU is divided into one or more coding units (coding unit, CU) through a tree structure. The information applied to each CU is encoded as the syntax of the CU, and the information commonly applied to the CU included in a CTU is encoded as the syntax of the CTU. In addition, the information commonly applied to all blocks in a slice is encoded as the syntax of the slice header, and the information applied to all blocks constituting the image is encoded in the picture parameter set (Picture Parameter Set, PPS) or the picture header. In addition, the information commonly referenced by multiple images is encoded in the sequence parameter set (Sequence Parameter Set, SPS). In addition, the information commonly referenced by one or more SPSs is encoded in the video parameter set (Video Parameter Set, VPS). Information commonly applied to one tile or tile group may be encoded as the syntax of a tile header or tile group header.
[0026] The image divider 110 is configured to determine the size of a coding tree unit (CTU). Information on the size of the CTU (CTU size) is encoded as a syntax of an SPS or a PPS and transmitted to a video decoding device.
[0027] The image splitter 110 is configured to split each image constituting a video into a plurality of CTUs having a predetermined size, and then recursively split the CTUs using a tree structure. In the tree structure, a leaf node is used as a coding unit (CU), which is a basic unit of coding.
[0028] The tree structure can be a quadtree (QuadTree, QT), a binary tree (BinaryTree, BT), a ternary tree (TernaryTree, TT), or a structure formed by a combination of two or more QT structures, BT structures and TT structures, wherein the quadtree (QT) is a node (or parent node) that is divided into four slave nodes (or child nodes) of the same size, the binary tree (BT) is a node that is divided into two slave nodes, and the ternary tree (TT) is a node that is divided into three slave nodes at a ratio of 1:2:1. For example, a quadtree plus binary tree (QuadTree plus BinaryTree, QTBT) structure can be used, or a quadtree plus binary tree ternary tree (QuadTree plus BinaryTree TernaryTree, QTBTTT) structure can be used. Here, BTTT can be collectively referred to as a multiple-type tree (MTT).
[0029] Figure 2 The QTBTTT segmentation tree structure is shown as an example. Figure 2 As shown, the CTU can be first split into a QT structure. The QT splitting can be repeated until the size of the split block reaches the minimum block size MinQTSize of the leaf node allowed in the QT. The first flag (QT_split_flag) indicating whether each node of the QT structure is split into four nodes of the lower layer is encoded by the entropy encoder 155 and notified to the video decoding device with a signal. When the leaf node of the QT is not larger than the maximum block size (MaxBTSize) of the root node allowed in the BT, it can be further split into one or more BT structures or TT structures. The BT structure and / or the TT structure can have multiple splitting directions. For example, there can be two directions, namely, a direction of splitting the blocks of nodes horizontally and a direction of splitting the blocks vertically. As Figure 2As shown, when the MTT splitting starts, the second flag (mtt_split_flag) indicating whether the node is split, the flag indicating the splitting direction (vertical or horizontal) in the case of splitting, and / or the flag indicating the splitting type (binary or trifurcated) are encoded by the entropy encoder 155 and sent to the video decoding device with a signal. Alternatively, before encoding the first flag (QT_split_flag) indicating whether each node is split into 4 nodes of the lower layer, the CU split flag (split_cu_flag) indicating whether the node is split can be encoded. When the value of the CU split flag (split_cu_flag) indicates that the splitting is not performed, the block of the node becomes a leaf node in the split tree structure and is used as a coding unit (CU), which is a basic unit of encoding. When the value of the CU split flag (split_cu_flag) indicates that the splitting is performed, the video encoding device starts to encode the flags from the first flag in the above-mentioned manner.
[0030] When QTBT is used as another example of a tree structure, there may be two types of segmentation, namely, a type of horizontally segmenting a block into two blocks of the same size (i.e., symmetrical horizontal segmentation) and a type of vertically segmenting a block into two blocks of the same size (i.e., symmetrical vertical segmentation). A segmentation flag (split_flag) indicating whether each node of the BT structure is segmented into blocks of the lower layer and segmentation type information indicating the segmentation type are encoded by the entropy encoder 155 and transmitted to the video decoding device. There may be an additional type of segmenting a block of a node into two asymmetric blocks. An asymmetric segmentation type may include a type of segmenting a block into two rectangular blocks at a size ratio of 1:3, or a type of segmenting a block of a node diagonally.
[0031] A CU may have various sizes according to the QTBT or QTBTTT partitioning of a CTU. Hereinafter, a block corresponding to a CU to be encoded or decoded (i.e., a leaf node of a QTBTTT) is referred to as a "current block". When QTBTTT partitioning is adopted, the shape of the current block may be a square or a rectangle.
[0032] The predictor 120 is configured to predict a current block to generate a predicted block. The predictor 120 includes an intra predictor 122 and an inter predictor 124.
[0033] Typically, each current block in an image can be predictively encoded. Typically, the prediction of the current block is performed using an intra-frame prediction technique (which uses data from an image that includes the current block) or an inter-frame prediction technique (which uses data from an image that was encoded before the image that includes the current block). Inter-frame prediction includes both unidirectional prediction and bidirectional prediction.
[0034] The intra-frame predictor 122 is configured to predict pixels in the current block using pixels (reference pixels) located around the current block in the current image including the current block. There are multiple intra-frame prediction modes according to the prediction direction. For example, Figure 3 As shown, multiple intra prediction modes may include two non-directional modes including planar mode and DC mode and 65 directional modes. Neighboring pixels and equations to be used are defined differently for each prediction mode. The following table lists the intra prediction mode numbers and their names.
[0035] Table 1
[0036] Intra prediction mode Related Name 0 INTRA_PLANAR 1 INTRA_DC 2…66 INTRA_ANGULAR2…INTRA_ANGULAR66
[0037] In order to perform effective directional prediction for the current block of rectangular shape, the additional use can be made of Figure 3 The dotted arrows in the figure indicate the directional modes (intra-prediction modes 67 to 80 and -1 to -14). These modes may be referred to as "wide angle intra-prediction modes". Figure 3 , the arrows indicate the corresponding reference samples used for prediction, rather than indicating the prediction direction. The prediction direction is opposite to the direction indicated by the arrow. The wide-angle intra prediction mode is a mode in which prediction is performed in a direction opposite to a specific direction mode without additional bit transmission when the current block has a rectangular shape. In this case, in the wide-angle intra prediction mode, some wide-angle intra prediction modes that can be used for the current block can be determined based on the ratio of the width to the height of the rectangular current block. For example, when the height of the rectangular shape of the current block is less than its width, a wide-angle intra prediction mode (intra prediction modes 67 to 80) with an angle less than 45 degrees can be utilized. When the height of the rectangular shape of the current block is greater than its width, a wide-angle intra prediction mode (intra prediction modes -1 to -14) with an angle greater than -135 degrees can be utilized.
[0038] The intra-frame predictor 122 may determine an intra-frame prediction mode to be used when encoding the current block. In some examples, the intra-frame predictor 122 may encode the current block using several intra-frame prediction modes and select an appropriate intra-frame prediction mode to be used from the tested modes. For example, the intra-frame predictor 122 may calculate a rate-distortion value using a rate-distortion analysis of several tested intra-frame prediction modes and may select an intra-frame prediction mode having the best rate-distortion characteristic from the tested modes.
[0039] The intra-frame predictor 122 is configured to select an intra-frame prediction mode from a plurality of intra-frame prediction modes and predict the current block using adjacent pixels (reference pixels) and equations determined according to the selected intra-frame prediction mode. Information about the selected intra-frame prediction mode is encoded by the entropy encoder 155 and transmitted to the video decoding device.
[0040] In addition, the intra predictor 122 can generate a prediction block of the current block using matrix-based intra prediction (MIP), which will be described later. The intra predictor 122 generates a prediction block of the current block using a boundary vector derived from samples reconstructed on the left side of the current block and samples reconstructed above the current block, a predefined matrix, and an offset vector.
[0041] The inter-frame predictor 124 is configured to generate a prediction block for the current block by motion compensation. The inter-frame predictor 124 can search for a block that is most similar to the current block in a reference image that has been encoded and decoded earlier than the current image, and use the searched block to generate a prediction block for the current block. Then, the inter-frame predictor is configured to generate a motion vector corresponding to the displacement between the current block in the current image and the prediction block in the reference image. Typically, motion estimation is performed on the luminance (luma) component, and the motion vector calculated based on the luminance component is used for both the luminance component and the chrominance component. The motion information including information about the reference image and information about the motion vector used to predict the current block is encoded by the entropy encoder 155 and transmitted to the video decoding device.
[0042] The subtractor 130 is configured to subtract the prediction block generated by the intra predictor 122 or the inter predictor 124 from the current block to generate a residual block.
[0043] The transformer 140 may divide the residual block into one or more transform blocks and apply a transform to one or more transform blocks, thereby transforming the residual values of the transform block from the pixel domain to the frequency domain. In the frequency domain, the transform block is referred to as a coefficient block containing one or more transform coefficient values. A two-dimensional transform kernel may be used for the transform, while a one-dimensional transform kernel may be used for horizontal transform and vertical transform, respectively. The transform kernel may be based on a discrete cosine transform (DCT), a discrete sine transform (DST), etc.
[0044] The transformer 140 may transform the residual signal in the residual block using the entire size of the residual block as a transform unit. In addition, the transformer 140 may partition the residual block into two sub-blocks in the horizontal direction or the vertical direction, and may transform only one of the two sub-blocks. Accordingly, the size of the transform block may be different from the size of the residual block (and thus the size of the prediction block). Non-zero residual sample values may not exist in the untransformed sub-block or may be very rare. The residual samples of the untransformed sub-block are not signaled, and the residual samples of the untransformed sub-block may be inferred as "0" by the video decoding device. There may be multiple partition types according to the partition direction and the partition ratio. The transformer 140 may provide information about the encoding mode (or transform mode) of the residual block to the entropy encoder 155 (for example, information indicating whether to transform the residual block or the residual sub-block, information indicating the partition type selected to partition the residual block into sub-blocks, and information identifying the sub-blocks to be transformed). The entropy encoder 155 may encode information about the encoding mode (or transform mode) of the residual block.
[0045] The quantizer 145 is configured to quantize the transform coefficients output from the transformer 140, and output the quantized transform coefficients to the entropy encoder 155. For some blocks or frames, the quantizer 145 may directly quantize the relevant residual block without transformation.
[0046] The rearrangement unit 150 can reorganize the coefficient values of the quantized residual values. The rearrangement unit 150 can change the 2D coefficient array into a 1D coefficient sequence by coefficient scanning. For example, the rearrangement unit 150 can scan the coefficients from the DC coefficient to the coefficients in the high frequency region using a zig-zag scan or a diagonal scan to output a 1D coefficient sequence. According to the size of the transform unit and the intra-frame prediction mode, a vertical scan or a horizontal scan can be used instead of a zig-zag scan, wherein the vertical scan scans the 2D coefficient array in the column direction, and the horizontal scan scans the coefficients in the 2D block shape in the row direction. That is, the scanning mode to be used can be determined among the zig-zag scan, the diagonal scan, the vertical scan, and the horizontal scan according to the size of the transform unit and the intra-frame prediction mode.
[0047] The entropy encoder 155 is configured to encode the one-dimensional quantized transform coefficient output from the rearrangement unit 150 using various encoding techniques such as Context-based Adaptive Binary Arithmetic Code (CABAC) and exponential Golomb to generate a bitstream.
[0048] The entropy encoder 155 may encode information related to block partitioning (e.g., CTU size, CU partition flag, QT partition flag, MTT partition type, and MTT partition direction) so that the video decoding device may partition the block in the same manner as the video encoding device. In addition, the entropy encoder 155 may encode information about a prediction type indicating whether the current block is encoded by intra-frame prediction or by inter-frame prediction, and encode intra-frame prediction information (i.e., information about an intra-frame prediction mode) or inter-frame prediction information (information about a reference image index and a motion vector) according to the prediction type.
[0049] The inverse quantizer 160 is configured to inversely quantize the quantized transform coefficient output from the quantizer 145 to generate a transform coefficient. The inverse transformer 165 is configured to transform the transform coefficient output from the inverse quantizer 160 from the frequency domain to the spatial domain and reconstruct a residual block.
[0050] The adder 170 is configured to add the reconstructed residual block and the prediction block generated by the predictor 120 to reconstruct the current block. Pixels in the reconstructed current block are used as reference pixels when performing intra prediction of a subsequent block.
[0051] The filtering unit 180 is configured to filter the reconstructed pixels to reduce blocking artifacts, ringing artifacts, and blurring artifacts caused by block-based prediction and transform / quantization. The filtering unit 180 may include a deblocking filter 182 and a sample adaptive offset (SAO) filter 184.
[0052] The deblocking filter 182 is configured to filter the boundary between the reconstructed blocks to remove the block artifacts caused by block-by-block encoding / decoding, and the SAO filter 184 is configured to perform additional filtering on the deblocking filtered video. The SAO filter 184 is a filter for compensating for the difference between the reconstructed pixels and the original pixels caused by lossy coding.
[0053] The reconstructed blocks filtered by the deblocking filter 182 and the SAO filter 184 are stored in the memory 190. Once all blocks in one image are reconstructed, the reconstructed image can be used as a reference image for inter-frame prediction of blocks in subsequent images to be encoded.
[0054] Figure 4 is an exemplary functional block diagram of a video decoding device capable of implementing the technology of the present invention. Figure 4 A video decoding apparatus and elements of the apparatus are described below.
[0055] The video decoding apparatus may include an entropy decoder 410 , a rearrangement unit 415 , an inverse quantizer 420 , an inverse transformer 430 , a predictor 440 , an adder 450 , a filtering unit 460 , and a memory 470 .
[0056] Similar to Figure 1 In the video encoding device of the present invention, each element of the video decoding device can be implemented by hardware, software, or a combination of hardware and software. In addition, the function of each element can be implemented by software, and the microprocessor can be implemented to execute the software function corresponding to each element.
[0057] The entropy decoder 410 is configured to determine a current block to be decoded by decoding a bitstream generated by a video encoding device and extracting information related to block partitioning, and extract prediction information required to reconstruct the current block and information about a residual signal, etc.
[0058] The entropy decoder 410 is configured to extract information about the size of the CTU from a sequence parameter set (SPS) or a picture parameter set (PPS), determine the size of the CTU, and divide the image into CTUs of the determined size. Then, the decoder is configured to determine the CTU as the highest level (i.e., the root node) of the tree structure and extract the partitioning information about the CTU to partition the CTU using the tree structure.
[0059] For example, when the CTU is segmented using the QTBTTT structure, the first flag (QT_split_flag) related to the segmentation of the QT is extracted to segment each node into four nodes of the sublayer. For the node corresponding to the leaf node of the QT, the second flag (MTT_split_flag) related to the segmentation of the MTT and the information about the segmentation direction (vertical / horizontal) and / or the segmentation type (binary / trifurcated) are extracted to segment the corresponding leaf node with the MTT structure. Thus, each node below the leaf node of the QT is recursively segmented with the BT or TT structure.
[0060] As another example, when a CTU is split using a QTBTTT structure, a CU split flag (split_cu_flag) indicating whether the CU is split may be extracted. When the corresponding block is split, a first flag (QT_split_flag) may be extracted. In a split operation, after zero or more recursive QT splits, zero or more recursive MTT splits may occur for each node. For example, a CTU may directly undergo MTT splitting without undergoing QT splitting, or may only undergo QT splitting multiple times.
[0061] As another example, when the CTU is segmented using the QTBT structure, the first flag (QT_split_flag) related to the QT segmentation is extracted, and each node is segmented into four nodes of the lower layer. Then, the segmentation flag (split_flag) indicating whether the node corresponding to the leaf node of the QT is further segmented with the BT and the segmentation direction information are extracted.
[0062] Once the current block to be decoded is determined by tree structure partitioning, the entropy decoder 410 is configured to extract information about the prediction type indicating whether the current block is intra-predicted or inter-predicted. When the prediction type information indicates intra-prediction, the entropy decoder 410 is configured to extract syntax elements for intra-prediction information (intra-prediction mode) of the current block. When the prediction type information indicates inter-prediction, the entropy decoder 410 is configured to extract syntax elements for inter-prediction information, that is, information indicating a motion vector and a reference image referenced by the motion vector.
[0063] The entropy decoder 410 is configured to extract information about the encoding mode of the residual block from the bitstream (e.g., information about whether to encode the residual block or only encode a sub-block of the residual block, information indicating a partition type selected to partition the residual block into sub-blocks, information identifying the encoded residual sub-block, a quantization parameter, etc.). The entropy decoder 410 is also configured to extract information about the quantized transform coefficient of the current block as the information about the residual signal.
[0064] The rearrangement unit 415 may change a sequence of one-dimensional quantized transform coefficients entropy-decoded by the entropy decoder 410 into a 2-dimensional coefficient array (ie, block) in the reverse order of coefficient scanning performed by the video encoding apparatus.
[0065] The inverse quantizer 420 is configured to inversely quantize the quantized transform coefficients. The inverse transformer 430 is configured to inversely transform the inversely quantized transform coefficients from the frequency domain to the spatial domain based on the information about the encoding mode of the residual block to reconstruct the residual signal, thereby generating a reconstructed residual block of the current block.
[0066] When the information about the encoding mode of the residual block indicates that the residual block of the current block has been encoded by the video encoding device, the inverse transformer 430 uses the size of the current block (and thus the size of the residual block to be reconstructed) as the transform unit of the inverse quantized transform coefficient to perform an inverse transform, thereby generating a reconstructed residual block of the current block.
[0067] When the information about the encoding mode of the residual block indicates that only one subblock of the residual block has been encoded by the video encoding device, the inverse transformer 430 uses the size of the transformed subblock as a transform unit of the inverse quantized transform coefficient to perform an inverse transform, thereby reconstructing the residual signal of the transformed subblock, and filling the residual signal of the untransformed subblock with a value of "0" to generate a reconstructed residual block of the current block.
[0068] The predictor 440 may include an intra predictor 442 and an inter predictor 444. The intra predictor 442 is activated when the prediction type of the current block is intra prediction, and the inter predictor 444 is activated when the prediction type of the current block is inter prediction.
[0069] The intra-frame predictor 442 is configured to determine the intra-frame prediction mode of the current block in multiple intra-frame prediction modes based on the syntax elements of the intra-frame prediction mode extracted from the entropy decoder 410, and predict the current block using reference pixels around the current block according to the intra-frame prediction mode. In addition, the intra-frame predictor 442 can generate a prediction block of the current block using matrix-based intra-frame prediction (MIP), which will be described later. The intra-frame predictor 422 can generate a prediction block of the current block using a boundary vector derived from a sample reconstructed on the left side of the current block and a sample reconstructed above the current block, as well as a predefined matrix and an offset vector.
[0070] The inter predictor 444 is configured to determine a motion vector of a current block and a reference image referred to by the motion vector using syntax elements of the intra prediction mode extracted by the entropy decoder 410 , and predict the current block based on the motion vector and the reference image.
[0071] The adder 450 is configured to reconstruct the current block by adding the residual block output from the inverse transformer to the prediction block output from the inter-frame predictor or the intra-frame predictor. When intra-predicting a subsequent block to be decoded, the pixels in the reconstructed current block are used as reference pixels.
[0072] The filtering unit 460 may include a deblocking filter 462 and an SAO filter 464. The deblocking filter 462 is configured to perform deblocking filtering on the boundaries between the reconstructed blocks to remove block artifacts caused by block-by-block decoding. The SAO filter 464 may perform additional filtering on the reconstructed blocks after deblocking filtering the corresponding offsets to compensate for the difference between the reconstructed pixels and the original pixels caused by lossy coding. The reconstructed blocks filtered by the deblocking filter 462 and the SAO filter 464 are stored in the memory 470. When all blocks in one image are reconstructed, the reconstructed image is used as a reference image for inter-frame prediction of blocks in subsequent images to be encoded.
[0073] The techniques of the present invention generally relate to intra-frame prediction coding. The following description focuses primarily on decoding techniques, that is, the operation of a video decoder. Since the encoding techniques are in contrast to the decoding techniques, which are described in detail, the encoding techniques are briefly described.
[0074] In the discussion of the next generation video coding standard, namely Versatile Video Coding (VVC), several new coding tools are introduced, which can achieve better coding performance than High Efficiency Video Coding (HEVC).
[0075] Matrix-based intra prediction (MIP) is a new intra prediction technique introduced in VTM 5.0. The original idea was to use a neural network-based intra prediction technique, that is, to use a multi-layer neural network to predict the current PU pixel value based on adjacent reconstructed pixels. However, due to the high complexity of the prediction method using a neural network, an intra prediction technique based on affine linear transformation using a pre-trained matrix was introduced.
[0076] To predict a rectangular block PU with width W and height H, MIP takes as input H reconstructed samples on the left side of the block and W reconstructed samples above the block. The final predicted pixels are obtained by averaging, matrix-vector multiplication, linear interpolation, etc.
[0077] The sizes of blocks to which MIP is applied are classified into the following three categories.
[0078]
[0079] According to idx(W, H), the number of MIP modes (numModes), boundary size (boundarySize) and prediction block size (predW, predH, predC) are defined as follows. In the following table, MipSizeId=idx(W, H).
[0080] Table 2
[0081] MipSizeId numModes boundarySize pred pred predC 0 35 2 4 4 4 1 19 4 4 4 4 2 11 4 Min(nTbW,8) Min(nTbH,8) 8
[0082] Figure 5 is a conceptual diagram showing the main process of the MIP technology that can be used in the technology of the present invention.
[0083] (1) Averaging
[0084] The main purpose of this process is to normalize the reference samples. Depending on the block size and shape (width and height) (i.e., MipSizeId), 4 or 8 samples are obtained. When the width and height of the current block are both 4 (i.e., W=H=4), a total of 4 samples are obtained, including 2 on the left and 2 above (boundarySize=2). In another case, a total of 8 samples are obtained, including 4 on the left and 4 above (boundarySize=4).
[0085] like Figure 5 As shown, the upper adjacent sample is bdry top , and the left adjacent sample is represented by bdry left Indicates. top and bdry left Perform averaging separately to obtain the downsampled sample set and Averaging is a downsampling process as follows.
[0086]
[0087] In the above equation, bDwn represents the downsampled scaling value (nTbs / boundarySize), and refS represents the original reference sample. For the left neighboring sample, the calculated redS is stored as For the upper adjacent sample, the calculated redS is stored as
[0088] The downsampled reference samples are concatenated into a vector of length 4 or 8. The reduced boundary vector bdryred input to the vector-matrix multiplication is defined as follows. For example, when W = H = 4 and the MIP mode is less than 18, by and When W = H = 4 and the MIP mode is greater than or equal to 18, and The order of splicing and In the following equations, "mode" represents the MIP mode.
[0089]
[0090] (2) Matrix-vector multiplication
[0091] In this process, the downsampled prediction signal pred of the current block is generated from the reduced boundary vector red .pred red is the sum of the matrix-vector product and the offset, and can be calculated as follows.
[0092] pred red =A.bdry red +b
[0093] pred red The size of W red ×H red . Define W according to the size and shape of the current block red and H red , as shown below. The matrix A has red ×H red The offset vector b is of size W. red ×H red Vector.
[0094]
[0095] For each category of coding block size, a set S of matrices A and offset vectors b that can be used for coding blocks is predefined 0 , S 1 and S 2 The index (0, 1, 2) of the set S is selected according to the above MipSizeId (ie, idx(W, H)), and the index (0, 1, 2) of the set S is selected according to the MIP mode applied to the current block. 0 , S 1 and S 2 An extraction matrix A and an offset vector b.
[0096] Set S 0 From 18 matrices A 0 and 18 16-dimensional offset vectors b 0 and for a 4×4 block, each matrix A 0 There are 16 rows and 4 columns. Set S 1 From 10 matrices A 1 and 10 16-dimensional offset vectors b 1 and for blocks of size 4×8, 8×4, and 8×8, each matrix A 1 has 16 rows and 8 columns. Finally, the set S 2 The 6 matrices A 2 and 6 64-dimensional offset vectors b 2 , and for all other block shapes, each matrix A 2 It has 64 rows and 8 columns.
[0097] (3) Pixel interpolation
[0098] Interpolation is an upsampling process. As mentioned above, pred redis the downsampled prediction signal of the original block. In this case, the downsampled prediction block with sizes predW and predH is defined as follows.
[0099] pred red [x][y], where x = 0..predW1, y = 0..predH-1
[0100] A prediction block with an original block size (nTbW, nTbH) generated by linearly interpolating the prediction signal at the remaining positions in each direction is defined as follows.
[0101] predSamples[x][y], where x=0..nTbW-1, y=0..nTbH-1
[0102] According to the horizontal upsampling scaling factor upHor (=nTbW / predW) and the vertical upsampling scaling factor upVer (=nTbH / predH), the following is described from pred red Fill part or all of predSample.
[0103] predSamples[(x+1)×upHor-1][(y+1)×upVer-1]=pred red [x][y]
[0104] When upHor=1, pred red All horizontal positions of predSample in are filled. When upVer=1, pred red All vertical positions of predSample in are filled.
[0105] Then, bilinear interpolation is used to fill the remaining blank samples of predSample. The horizontal interpolation and vertical interpolation are upsampling processes. For the interpolation of the left and top samples in predSample, the downsampled samples are The value assigned to predSample[x][-1] and the original reference sample on the left is assigned to the value of predSample[-1][y]. The interpolation order is determined according to the size of the current block. That is, interpolation is first performed in the direction of the short dimension. Subsequently, interpolation is performed in the direction of the long dimension.
[0106] (4) Signaling the MIP intra prediction mode
[0107] For each coding unit (CU) that is intra-prediction encoded, a flag indicating whether a matrix-based intra prediction mode (i.e., MIP mode) is applied is transmitted. In VVC Draft 5, in order to signal the MIP mode, similar to the conventional intra prediction mode (hereinafter referred to as "normal intra prediction mode") that is different from the matrix-based intra prediction, an MPM list consisting of 3 MPMs is used. For example, intra_mip_mpm_flag, intra_mip_mpm_idx, and intra_mip_mpm_remainder are used to signal the MIP mode. intra_mip_mpm_idx is encoded using truncated binary coding, and intra_mip_mpm_remainder is encoded using fixed length coding.
[0108] Depending on the size of the coding block (CU), up to 35 MIP modes can be supported. For example, for a CU with max(W, H) ≤ 8 and W×H < 32, 35 modes are available. In addition, 19 prediction modes and 11 prediction modes are used for CUs with max(W, H) = 8 and max(W, H) > 8, respectively. In addition, a pair of modes (ie, two modes) can share matrices and offset vectors to reduce memory requirements. The specific shared mode calculation is as follows. For example, for a 4×4 coding block, mode 19 uses the transposed matrix of the matrix assigned to mode 2.
[0109]
[0110] When there is a block to which MIP is applied near a block to which a conventional intra prediction mode is applied instead of MIP (hereinafter, referred to as a "conventional block"), a mapping table defined between the MIP mode and the conventional mode can be used for MPM derivation of the conventional block. The mapping table is used to derive a conventional mode of similar characteristics based on the MIP mode of the adjacent block. The conventional mode derived in this way is used for MPM derivation of the conventional block. Similarly, even when MIP is applied to a collocated luminance block used in a chrominance direct mode (DM) derivation, the mapping table can be used to derive a conventional mode mapped to the MIP mode of the collocated luminance block to determine the intra prediction mode for the chrominance block. The following equation expresses the mapping between the conventional mode and the MIP mode.
[0111] predmode MIP =map_regular_to_mip idx [predmode regular ]
[0112] predmode regular =map_mip_to_regular idx [predmodeMIP ]
[0113] The present invention proposes several modifications that can improve the prediction performance without significantly increasing the implementation complexity of the matrix-based intra prediction (MIP) technique.
[0114] Derivation of matrices and offsets
[0115] According to one aspect of the invention, a video encoder and a video decoder may create new sets of matrices and offsets to be used for the remaining modes among the available MIP modes based on sets of matrices and offsets explicitly defined for some MIP modes available for a given block size.
[0116] A new set of matrices and offsets may be obtained by performing at least one of a transposition, an averaging operation, and a weighted averaging operation from two (or more) explicitly defined sets of matrices and offsets. The set of explicitly defined matrices and offsets may be transmitted from an encoder to a decoder, or may be predefined in the memory of both the video encoder and the video decoder. Accordingly, the memory requirements for the set of matrices and offsets for storing the MIP mode may be additionally reduced without reducing the number of existing available modes.
[0117] For illustrative explanation, assume that M matrices for the size of a given block are explicitly defined in the video encoder and video decoder. The video encoder can derive (create) K new matrices from the M matrices in a predefined manner, and accordingly, a total of (M+K) matrices can be used to perform matrix-based intra prediction for a given block. Each of the matrices in the available matrix list including the (M+K) matrices can be identified by their index.
[0118] If the signaled MIP mode for the current block from the video encoder is defined to use explicitly defined matrices, the video decoder can directly use the matrices stored in the memory to perform matrix-based intra prediction for the current block. If the signaled MIP mode for the current block from the video encoder is defined to use derived matrices, the video decoder can create derived matrices for the signaled MIP mode in the same manner as the video encoder.
[0119] In some embodiments, the derived matrix can be an average matrix or a weighted average matrix of two explicitly defined matrices. For example, we assume that there are explicitly defined matrices A and B, whose size is M×N. For The weighted average matrix C can be defined as follows.
[0120]
[0121] Where s1 and s2 are weights applied to matrices A and B. The weights s1 and s2 may be predefined by the video encoder or signaled at a high-level syntax.
[0122] The new offset can also be derived in the same way as the derived matrix.
[0123]
[0124] In some other embodiments, the derived matrix may be the transposed matrix of a weighted average matrix of two explicitly defined matrices.
[0125] MIP prediction of chrominance components
[0126] In the discussion of VVC standardization, five basic prediction modes (planar mode, DC mode, horizontal mode, vertical mode and direct mode (DM)) and three linear model (LM) modes are considered for intra-frame prediction of chroma blocks. LM is also called LM_Chroma mode or cross component linear mode (CCLM).
[0127] The LM mode is a mode for predicting a chrominance signal from a luminance signal by utilizing the correlation between the luminance signal and the chrominance signal. In the LM mode, a linear model (LM) between the pixel values of the luminance signal and the chrominance signal is determined, and a prediction signal of the chrominance block is calculated based on the reconstructed luminance signal of the corresponding luminance block by utilizing the linear model. In the DM mode, the current chrominance block uses the same prediction mode as the corresponding luminance block.
[0128] If the LM mode (i.e., CCLM) is not applied to the chroma block, a syntax element (intra_chroma_pred_mode) specifying the intra prediction mode for the chroma block is encoded. The intra prediction mode of the chroma block is determined according to intra_chroma_pred_mode and the intra prediction mode of the corresponding luma block (lumaIntraPredMode) as follows. For example, if intra_chroma_pred_mode=4, the direct mode is used as the intra prediction mode of the chroma block, and accordingly, the intra prediction mode of the corresponding luma block is applied to the chroma block.
[0129] [Table 3]
[0130]
[0131] In the discussion of VVC standardization, the matrix-based intra prediction (MIP) technology is introduced in such a way that only the luminance component is used without using the chrominance component due to coding complexity, storage bandwidth caused by a set of required matrices and offsets, etc. Accordingly, in VVC draft 5, in the case of determining the intra prediction mode of the chrominance block, when the corresponding luminance block is encoded by the matrix-based intra prediction (MIP), the video encoder and the video decoder are configured to convert the MIP mode applied to the corresponding luminance block into a conventional intra prediction mode defined in a mapping table.
[0132] In the following, several methods of applying matrix-based intra prediction (MIP) to chroma components will be proposed.
[0133] According to one aspect of the present invention, a video encoder and a decoder can derive a MIP mode of a block of a chrominance component (chrominance block) based on a MIP mode of a block of a collocated luminance component (luminance block) predicted by matrix-based intra-frame prediction (MIP). Accordingly, for a chrominance block encoded by matrix-based intra-frame prediction (MIP), a syntax element that explicitly specifies the MIP mode used by the encoder can be omitted.
[0134] According to one aspect of the present invention, instead of defining sets of matrices and offsets for matrix-based intra prediction (MIP) for chroma blocks and luma blocks, respectively, the set of matrices and offsets defined for luma blocks may also be used for chroma blocks, or the set of matrices and offsets to be used for chroma blocks may be derived from the set of matrices and offsets defined for luma blocks, depending on the video sampling format (or chroma format). Table 4 shows the video sampling format indicated by the syntax element (sps_chroma_format_idc; cIdx) signaled at the SPS level.
[0135] [Table 4]
[0136]
[0137] For example, if the video sampling format (or chroma format) is 4:4:4, the video encoder and video decoder may use a set of matrices and offsets defined for luma blocks and also for chroma blocks.
[0138] For another example, if the luma component and the chroma component have different resolutions (e.g., the chroma format is 4:2:0), the video encoder and decoder can downsample the matrix and offset of the luma block at the ratio of the size of the luma block and the chroma block, and derive the MIP matrix and offset to be applied to the chroma block. If the video chroma format is 4:2:0, the chroma block is half the width and length of the luma block, so the video encoder and video decoder can downsample the matrix and offset of the luma block and create a 1 / 2 size matrix and offset to be applied to the chroma block.
[0139] As a down-sampling method, values at specific locations in the matrix of the luma block may be subsampled (eg, a reduced matrix may be created from values in even or odd rows and columns), and filtering may be applied to the matrix of the luma block.
[0140] In some embodiments, in order to avoid the complexity introduced by the derivation process of the matrix and offset of downsampling, matrix-based intra-frame prediction is allowed for chroma blocks only when the video sampling format is 4:4:4. In addition, in some embodiments, matrix-based intra-frame prediction is allowed for blocks of chroma components (chroma blocks) only when the same-positioned luminance blocks are predicted by matrix-based intra-frame prediction (MIP). In this case, the MIP mode for the blocks of chroma components (chroma blocks) can be considered to be the same as the MIP mode for the same-positioned luminance blocks. In addition, the set of matrices and offsets for the MIP mode of the luminance block can also be used for chroma blocks.
[0141] In some embodiments, matrix-based intra prediction for chroma blocks is allowed only when the video sampling format is 4:4:4 and a single tree is used to partition the CTU.
[0142] In some other embodiments, instead of performing matrix-based intra prediction on the chroma blocks, a CCLM (cross-component linear model) technique may be enabled, in which a prediction signal for the chroma blocks is generated from the reconstructed values of the luminance blocks encoded by matrix-based intra prediction by utilizing a linear model.
[0143] Time Matrix and Offsets
[0144] The number of sets of matrices and offsets that can be used for matrix-based intra prediction (MIP) can be adaptively selected according to the characteristics of the video data. According to one aspect of the present invention, the video encoder can adaptively change the number of sets of matrices and offsets that can be used for matrix-based intra prediction (MIP) for each sequence, image, or image subgroup by RD cost calculation.
[0145] In one embodiment, in matrix-based intra prediction (MIP), N sets of matrices and offsets that can always be used in matrix-based intra prediction (MIP) regardless of the characteristics of the video data can be defined. In addition, L sets of matrices and offsets that can be selectively used at a high level can be defined. The video encoder can select M sets (M is less than or equal to L) to be used at the current high level from the L sets. Accordingly, the maximum number of sets of matrices and offsets that can be determined to be available for matrix-based intra prediction (MIP) at a high level is N+L. Here, the unit of the high level can be a sequence, an image, or a subgroup of an image. The set of matrices and offsets that can be selectively used can be called a time set, and the matrix that can be selectively used can be called a time matrix. The set of matrices and offsets that can always be used can be called a basic set.
[0146] The video encoder may signal a 1-bit flag at a high level indicating whether to use further temporal sets in addition to the base set. If temporal sets are used, the video encoder may signal the number of temporal sets to be used at the current high level and the index information of the temporal set selected in the bitstream. In an embodiment where the same number of temporal sets is always used, the signaling of the number of temporal sets to be used at the current high level may be omitted.
[0147] When decoding a block starts at a new high level (e.g., a new sequence), the video decoder can parse a 1-bit flag indicating whether a time set is used in a high-level syntax. When the 1-bit flag indicates that a time set is used at the current high level, the video decoder can parse a syntax element indicating the number of time sets used at the current high level. In addition, the video decoder can parse a syntax element indicating the index of each time set used at the current high level in a predefined available time set based on the number of time sets used at the current high level. When performing matrix-based intra-frame prediction on a block included in a high level, the video decoder can use a predefined basic set and a time set selected at the high level. The video decoder can form a list of matrices and offsets consisting of a predefined basic set and a selected time set. In the list of matrices and offsets, each time set can be identified by a new index.
[0148] Signaling MIP mode
[0149] For a coding unit (CU) encoded in an intra prediction mode, a flag indicating whether the intra prediction type is matrix-based intra prediction (MIP) may be signaled. If matrix-based intra prediction (MIP) is applied to the coding unit, one or more syntax elements indicating a MIP mode for the coding unit from a plurality of available MIP modes may be additionally signaled.
[0150] Similar to a conventional intra prediction mode (hereinafter, "conventional intra prediction mode"), an MPM list may be used to indicate a MIP mode for a current coding unit. Hereinafter, for matrix-based intra prediction (MIP), a method for deriving a history-based MIP_MPM list is disclosed. In this method, MIP modes of previously encoded blocks are managed in an MPM list for each block size. The MIP_MPM list is maintained and updated during the encoding / decoding process.
[0151] Multiple MIP_MPM lists may be maintained and used based on information of at least one of the block size (width and height) and the signal characteristics of the block. For example, the number of available MIP modes may vary with the size of the block to which the MIP is applied, so a separate candidate MIP mode list may be managed for each MipSizeId={0, 1, 2}.
[0152] The MIP_MPM list consists of M unique MIP modes, where M may be adaptively determined by at least one information of block width, height, size, and signal characteristics, or may have a fixed value (eg, 3) regardless of such information.
[0153] Each time a block is encoded in MIP mode, the MIP mode for the block is added to the last item of the MIP_MPM list corresponding to the block size, and when the same mode exists in the MIP_MPM list, the MIP mode for the block can be eliminated from the MIP_MPM list, or the first item of the MIP_MPM list can be eliminated from the MIP_MPM list.
[0154] When encountering a new slice, the MIP_MPM list can be reconfigured with a predefined MIP mode. When starting encoding / decoding of the current CTU, the MIP_MPM list can be continued from the last block of other CTUs to the left of the current CTU. When the current CTU is on the left boundary of the picture, the table can be continued from the last block of other CTUs above the current CTU.
[0155] If there is a MIP mode selected for the current block in the MIP_MPM list corresponding to the size of the current block, the video encoder may signal a 1-bit flag (e.g., MIP_HMPM_flag) indicating that the MIP mode of the current block is the first value of MPM from the MIP_MPM list corresponding to the size of the current coding block, and may further signal a syntax element (e.g., MIP_HMPM_index) specifying one MIP mode. MIP_HMPM_index may be encoded using truncated binary encoding.
[0156] If the MIP mode selected for the current block does not exist in the MIP_MPM list corresponding to the size of the current block, the video encoder may signal a 1-bit flag (e.g., MIP_HMPM_flag) of a second value indicating that the MIP mode of the current block is not MPM, and may further signal a syntax element (e.g., MIP_HMPM_remainder) indicating one of the non-MPMs other than the MPM. MIP_HMPM_remainder may be encoded with a fixed length code.
[0157] If the current block is encoded in MIP mode, the decoder parses a 1-bit flag (e.g., MIP_HMPM_flag) indicating whether the MIP mode of the current block is MPM. If the 1-bit flag has a first value, the decoder parses a syntax element (e.g., MIP_HMPM_index) that specifies one MIP mode from a MIP_MPM list corresponding to the size of the current coded block. The decoder determines the MIP mode indicated by MIP_HMPM_index in the MIP_MPM list as the MIP mode of the current block.
[0158] If the 1-bit flag (e.g., MIP_HMPM_flag) has a second value, the decoder parses a syntax element (e.g., MIP_HMPM_remainder) indicating one of the remaining MIP modes (i.e., non-MPMs) other than the MPMs of the MIP_MPM list among the MIP modes available for the size of the current block. The decoder determines the non-MPM indicated by MIP_HMPM_remainder as the MIP mode of the current block.
[0159] In other embodiments, unlike traditional intra prediction modes (i.e., conventional intra prediction modes), the MPM list may not be used to signal the MIP mode. Instead, for example, a syntax element (e.g., intra_mip_mode) may be used that indicates the MIP mode used in the current CU among multiple MIP modes and may be encoded with truncated binary encoding.
[0160] The following provides a portion of an exemplary coding unit syntax proposed based on VVC draft 5. In the following syntax, the grey elements are used to provide understanding.
[0161] Table 5
[0162]
[0163] When intra_mip_flag[x0][y0] is 1, it indicates that the intra prediction type of the current block is MIP. When intra_mip_flag[x0][y0] is 0, it indicates that the intra prediction type of the current block is regular intra prediction, not MIP. When intra_mip_flag[x0][y0] does not exist, it can be inferred to be equal to 0. intra_mip_mode[x0][y0] indicates the MIP mode for the current block in MIP, and is expressed as a truncated binary code.
[0164] MPM (Most Probable Mode)
[0165] In the traditional method, intra-frame prediction coding using the Most Probable Mode (MPM) can be used. For example, in HEVC, a list of three MPMs is configured according to the intra-frame prediction modes of the left block and the upper block. The disadvantage of this method is that more modes (intra-frame modes other than MPM) belong to non-MPMs that need to be encoded with more bits. Several methods have been proposed to expand the number of MPMs to 3 or more items (for example, 6 MPM modes). However, configuring such an MPM list with more items may require more checks and conditions, which may make the implementation more complicated.
[0166] In order to keep the configuration of the MPM list low in complexity, the MPM list including six MPM candidates can be configured using the intra-frame prediction modes of the left neighboring blocks and the upper neighboring blocks adjacent to the current block. The MPM candidates may include a default intra-frame prediction mode (e.g., a plane mode), an intra-frame prediction mode of a neighboring block, and an intra-frame prediction mode derived from the intra-frame prediction mode of the neighboring block. When the intra-frame prediction mode of the neighboring block is not used (e.g., when the neighboring block is inter-predicted, or the neighboring block is located in a different slice or another tile), the intra-frame prediction mode of the neighboring block can be set to a plane mode.
[0167] According to the type of intra prediction mode of the left block mode (left mode) and the upper block mode (upper mode), it is roughly divided into 4 cases. When the left mode and the upper mode are different from each other and the two modes are directional modes, they can be further divided according to the difference between the left mode and the upper mode to generate the MPM list. In the table below, Max refers to the larger mode between the left mode and the upper mode, and MIN refers to the smaller mode between the left mode and the upper mode.
[0168] Table 6
[0169]
[0170] The video encoder may signal a 1-bit flag (eg, mpm_flag) indicating whether the intra prediction mode of the current block corresponds to an MPM. Typically, when the intra prediction mode of the current block corresponds to an MPM, an MPM index indicating one of six MPMs may be additionally signaled.
[0171] Note that in Table 6, the planar mode is always included in the MPM list. That is, the 6 MPMs can be divided into planar MPMs and 5 non-planar MPMs. Therefore, when the intra-frame prediction mode of the current block corresponds to an MPM, the encoder first signals whether the intra-frame prediction mode of the current block is a planar mode (e.g., using a 1-bit flag), and only when the intra-frame prediction mode of the current block is the same as one of the other five non-planar MPMs, additionally signals that the MPM index indicating one of the other five non-planar MPMs will be valid. If the value of the bit flag (e.g., mpm_flag) indicates that the intra-frame prediction mode of the current block corresponds to an MPM, the decoder can parse the 1-bit flag indicating whether the intra-frame prediction mode of the current block is a planar mode.
[0172] When the intra prediction mode of the current block does not correspond to any MPM, a syntax element indicating one of the remaining 61 non-MPMs except the 6 MPMs may be encoded using truncated binary coding.
[0173] Remove the mapping table between MIP mode and normal mode
[0174] As described above, in VVC Draft 5, the MPM list is used to signal the MIP mode and the normal mode, respectively, and a mapping table between the MIP mode and the normal mode is required to construct the MIP list. For example, in the case of deriving the MPM list of a block encoded in a normal intra prediction mode (that is, a normal block), when the left block or the upper block is encoded with matrix-based intra prediction (MIP), the MIP mode of the left block or the MIP mode of the upper block is converted to the normal intra prediction mode defined in the mapping table.
[0175] According to one aspect of the present invention, in the case of deriving an MPM list for a regular block, if the left block and the upper block are encoded with matrix-based intra prediction (MIP), the mode of the left block (left mode) and the mode of the upper block (above mode) can be regarded as predefined regular modes, regardless of which MIP mode is applied to the adjacent blocks. Thus, the need for the video encoder and the video decoder to store a mapping table between the MIP mode and the regular mode in a memory is eliminated.
[0176] In some embodiments, if the left block is encoded with matrix-based intra prediction (MIP), the conventional intra prediction mode of the left block can be considered as the first mode (regardless of the MIP mode of the left block), and if the upper block is encoded with the MIP mode, the conventional intra prediction mode of the upper block can be considered as the second mode (regardless of the MIP mode of the upper block). The first mode and the second mode can be predefined to be the same or different and can be signaled at the high-level syntax.
[0177] In some other embodiments, in the case of deriving an MPM list for a regular block, if a MIP mode is applied to a neighboring block, the regular intra prediction mode of the neighboring block can be inferred as a plane mode (or DC mode) (regardless of the MIP mode of the neighboring block). Due to the characteristics of a matrix-based intra prediction (MIP) technique including an averaging operation and an interpolation operation, the residual signal of a block to which MIP is applied may have a dominant low-frequency component in the transform domain. It should be noted that the characteristics of the residual signal may be similar to the residual signal of a block to which a plane mode (or DC mode) is applied.
[0178] Similarly, when deriving chroma DM (direct mode), if matrix-based intra-frame prediction (MIP) coding is applied to the co-located luminance block, the intra-frame prediction mode of the luminance block can be inferred as planar mode (or DC mode) instead of utilizing a mapping table between MIP mode and normal mode.
[0179] Accordingly, the video decoder parses the syntax elements that specify the intra-prediction mode for the chroma block, and the syntax elements may indicate that the intra-prediction mode of the chroma block adopts the intra-prediction mode of the co-located luminance block. In such a case, when the MIP is applied to the co-located luminance block, the video decoder may infer that the intra-prediction mode of the luminance block is the planar mode (or DC mode). That is, when the MIP is applied to the co-located luminance block in the chroma direct mode (DM), the video decoder may determine that the intra-prediction mode of the chroma block is the planar mode (or DC mode).
[0180] However, in chroma DM (direct mode), if the video sampling format is 4:4:4 and the co-located luma block is predicted with matrix-based intra prediction (MIP), matrix-based intra prediction (MIP) can be allowed for the chroma block. In this case, the MIP mode for the block of chroma components (chroma blocks) can be inferred to be the same as the MIP mode for the co-located luma block.
[0181] Figure 6 Detailed description is a flow chart showing a method for decoding video data with the above-mentioned improvements according to one embodiment of the present invention. Figure 6 The method can be similar to Figure 4 For example, the entropy decoding unit 410 and the intra prediction unit 442 may involve one or more steps described below.
[0182] The video decoder may acquire information about a luma prediction mode and information about a chroma prediction mode of a current coding block from a bitstream (S610). The video decoder may decode an encoded bitstream of video data and acquire information about a luma prediction mode and information about a chroma prediction mode.
[0183] The video decoder may derive a luma intra prediction type and a luma intra prediction mode of the current coding block based on the information about the luma prediction mode (S620). The luma intra prediction type may include matrix-based intra prediction (MIP) and conventional intra prediction. The information about the luma prediction mode may include: a syntax element indicating a luma intra prediction type of the current coding block; a syntax element indicating a matrix-based intra prediction mode selected for the current coding block; and one or more syntax elements for signaling a conventional intra prediction mode selected for the current coding block.
[0184] For example, the video decoder may parse a syntax element (e.g., intra_mip_flag) from the bitstream indicating the luma intra prediction type of the current coding block. If the syntax element indicates that the luma intra prediction type of the current coding block is matrix-based intra prediction, the video decoder may parse a syntax element indicating the matrix-based intra prediction mode for the current coding block. The syntax element (e.g., intra_mip_mode) is represented as a truncated binary code and specifies one of multiple matrix-based intra prediction modes allowed for the width and height of the current coding block.
[0185] If a syntax element (e.g., intra_mip_flag) indicates that the luma intra prediction type of the current coding block is conventional intra prediction, the video decoder can derive MPM (most probable mode) candidates based on the intra prediction mode of the neighboring blocks adjacent to the current coding block and construct an MPM list for the current coding block, and derive the luma intra prediction mode for the current coding block based on the MPM list. To this end, the video decoder can parse one or more syntax elements related to the MPM. In the case of deriving the MPM candidate based on the intra prediction mode of the neighboring blocks adjacent to the current coding block, if the intra prediction type of the neighboring block is matrix-based intra prediction, the video decoder can infer (set to) the conventional intra prediction mode of the neighboring block to a planar mode.
[0186] The video decoder may determine the chroma intra prediction mode of the current coding block based on the luma intra prediction type and the luma intra prediction mode of the current coding block and the information about the chroma prediction mode (S630). The information about the chroma prediction mode may include a syntax element (e.g., intra_chroma_pred_mode) that specifies the chroma intra prediction mode and has a value of 0 to 4. In addition, the information about the chroma prediction mode may include a flag (e.g., ccm_mode_flag) indicating whether CCLM is applied to the chroma block and index information (e.g., ccm_mode_idx) indicating one of three available CCLM modes. If CCLM is applied to the chroma block, intra_chroma_pred_mode may not exist.
[0187] For example, if the information about the chroma prediction mode indicates the direct mode (DM), the luma intra prediction type of the current coding block is matrix-based intra prediction, and the sampling format of the video data is 4:4:4, the video decoder can determine that the chroma intra prediction type of the current coding block is matrix-based intra prediction, and can determine that the chroma intra prediction mode corresponding to the chroma intra prediction type of the current coding block is the same as the matrix-based intra prediction mode derived as the luma intra prediction mode of the current coding block.
[0188] For another example, if the information about the chroma prediction mode indicates DM (direct mode), the luma intra prediction type of the current coding block is a matrix-based intra prediction type, and the sampling format of the video data is 4:2:0 or 4:2:2, the video decoder can determine that the chroma intra prediction mode of the current coding block is a planar mode.
[0189] For another example, if the information about the chroma prediction mode indicates DM (direct mode) and the luma intra prediction type of the current coding block is a regular intra prediction type, the video decoder can determine that the chroma intra prediction mode of the current coding block is the same as the regular intra prediction mode derived as the luma intra prediction mode of the current coding block.
[0190] The video decoder may generate chroma prediction samples of the current coding block based on the chroma intra prediction mode of the current coding block (S640). The video decoder may generate chroma prediction samples of the current coding block by selectively performing matrix-based intra prediction or conventional intra prediction.
[0191] For example, in response to determining that the chroma intra prediction mode of the current coding block is the same as the matrix-based intra prediction mode derived as the luma intra prediction mode of the current coding block, the video decoder can generate chroma prediction samples for the current coding block by performing matrix-based intra prediction according to the derived matrix-based intra prediction mode. The video decoder can derive an input boundary vector by using adjacent chroma samples adjacent to the current coding block based on the width and height of the current coding block. The video decoder can generate chroma prediction samples for the current coding block based on matrix-vector multiplication between the input boundary vector and a matrix predefined for the matrix-based intra prediction mode. The video decoder can derive a chroma prediction block for the current coding block based on the chroma prediction samples.
[0192] For another example, in response to determining that the chroma intra prediction mode of the current coding block is the planar mode, the video decoder may generate chroma prediction samples of the current coding block by performing conventional intra prediction according to the planar mode.
[0193] For another example, in response to determining that the chroma intra-frame prediction mode of the current coding block is the same as the regular intra-frame prediction mode derived as the luma intra-frame prediction mode of the current coding block, the video decoder can generate chroma prediction samples for the current coding block by performing regular intra-frame prediction according to the derived regular intra-frame prediction mode.
[0194] In the following, several improved techniques for inter-frame prediction coding of video data will be disclosed. Some of the techniques to be described below are related to efficiently signaling motion information, while other techniques are related to adaptive interpolation filtering based on motion information.
[0195] A motion vector is a vector of n directions: that is, it may be composed of n directional components. According to the techniques of the present invention, motion information may be encoded independently for each direction. The video encoder may signal information indicating whether the motion information of the coding block is encoded independently for each direction.
[0196] Motion information may refer to information explicitly signaled by a video encoder, such as a motion set for each direction, a prediction mode for a motion vector, and the like. In addition, motion information may refer to or include information derived from the information, that is, the value of the actual motion vector or the precision of the differential motion vector ultimately obtained by the decoder. Here, the precision describes the number of digits after the decimal point used to express each component of the vector, and may be referred to as the resolution of the motion vector. The motion set may include information such as vector components, precision, and the like. The vector components may include an actual motion vector or a differential motion vector, and the precision information may include the precision of the motion vector or the precision of the differential motion vector.
[0197] If the motion information is encoded independently for each direction, this may mean that the motion set is encoded or decoded separately for each direction. For example, the vector component for each direction may be represented separately by a precision value and encoded / decoded as a separate motion set. If the motion information defined for each direction is encoded dependently, this may mean that the vector component for each of at least two of the n directions may be expressed by one precision value and encoded / decoded as one motion set.
[0198] Information indicating whether motion information is encoded independently or dependently for each direction may be signaled by a video encoder. For example, the information may be transmitted as a high-level syntax element such as a SEI (supplemental enhancement information) message, an APS, an SPS, a PPS, a slice / tile / tile group header, etc. As another example, the information may be transmitted for each unit of a basic decoding process or for each unit of a block partition, or may be transmitted at both a high-level syntax and a block level. Alternatively, the information may be derived based on information indicating whether motion information of reference candidate blocks is encoded independently and the motion information of these reference candidate blocks.
[0199] In video data that is a sequence of two-dimensional images, a motion vector may include two directional (eg, x-direction and y-direction) components. According to the technology of the present invention, motion vectors for the x-direction and y-direction may be encoded independently.
[0200] In the encoding of motion information, a syntax element indicating whether each element constituting the motion information can be independently encoded can be signaled at a high level. For example, the value of the sps_MV_independent_enable flag indicates whether each element constituting the motion information can be independently encoded. If sps_MV_independent_enable is equal to 1, information indicating whether each element of the motion information is independently decoded for a low level (e.g., image / slice / tile level) can be additionally signaled. For example, the value of the MV_independent_flag signaled in the slice header specifies whether each element of the motion information is independently decoded for the current decoding unit (e.g., CU). If MV_independent_flag is equal to 0, the motion information for the x-direction and the y-direction is encoded as one motion set. If MV_independent_flag=1, motion information is encoded separately for the motion set for the x-direction and for the motion set for the y-direction.
[0201] Hereinafter, a technique for adaptive interpolation filtering utilizing motion information will be disclosed to improve encoding efficiency.
[0202] The interpolation filter refers to a filter used to change the resolution of a reference image in an encoding technique using motion information (eg, inter-frame prediction encoding, intra-frame block copying, a CIIP technique for combining an inter-frame prediction signal and an intra-frame prediction signal, etc.).
[0203] In some embodiments, configuration information for each of the one or more interpolation filters to be used for interpolation can be transmitted from the video encoder to the video decoder. The configuration information of the interpolation filter can include information such as the number of labels of the interpolation filter, the coefficients of the interpolation filter, the direction of the interpolation filter, and the shape of the interpolation filter.
[0204] In other embodiments, one or more interpolation filter lists with predefined information about multiple interpolation filters can be used in video encoders and video decoders. Each list contains configuration information of each interpolation filter included in the list. Information about interpolation filters can be transmitted to decoder indirectly from encoder. For example, the index of the interpolation filter list available in the multiple interpolation filter lists can be transmitted as information about interpolation filters.
[0205] If multiple interpolation filters can be used, index information of the interpolation filter to be used among the multiple interpolation filters can be explicitly signaled by the video encoder. For example, the index information can be transmitted as a high-level syntax element such as an SEI message, APS, SPS, PPS, slice / tile / tile group header, etc. As another example, the index information can be transmitted for each unit of the basic decoding process or for each unit of the block partition, or can be transmitted at both the high-level syntax and the block level. Alternatively, the index information of the interpolation filter to be used for the current block can be derived based on at least one of a previously decoded neighboring block, a previously decoded reference block, and a neighboring block of a previously decoded reference block.
[0206] In one embodiment, the video encoder and the video decoder can select the type of interpolation filter to be used from the available interpolation filters according to the position of the reference pixel. In addition, information about additional interpolation filters other than the predefined interpolation filters can be transmitted through high-level syntax such as SEI messages, APS, SPS, PPS, slice / tile / tile group headers, etc.
[0207] If there are several types of interpolation filters that can be used for a given position x, the encoder can signal information (e.g., a filter index) that specifies the interpolation filter to be used at that position. Such a filter index can be transmitted for each unit of the basic decoding process or for each unit of the block partition. Alternatively, the index of the interpolation filter to be used for a given block can be derived by utilizing decoded information for at least one of a given block, a previously decoded neighboring block, a previously decoded reference block, and a neighboring block of a previously decoded reference block. Here, the decoded information can be the accuracy of the motion vector, the accuracy of the differential motion vector, and the accuracy of the final motion vector.
[0208] In some possible embodiments, the syntax elements indicating whether interpolation filters can be selectively used can be signaled at high-level syntax such as APS, PPS and slice / tile headers. If interpolation filters can be selectively used, the information of the filter set that can be used according to each interpolation position can be further signaled at the high-level syntax. The video decoder can define the filter by utilizing the filter information derived according to predefined filters and the high-level syntax information. The video encoder and video decoder can derive the interpolation filter by utilizing the precision of motion vectors, the precision of differential motion vectors, the precision of final motion vectors and the size and position of blocks. The video encoder can select a suitable filter by the RD test of multiple interpolation filters that can be used, and the index of the selected filter is sent to the video decoder with a signal.
[0209] Furthermore, an interpolation filter to be used for the current block may be derived according to a neighboring block with reference to which a motion prediction mode of the current block and / or a motion vector of the current block is derived.
[0210] In an exemplary embodiment, if the current block is encoded in a merge mode, the video decoder may interpolate the current block by using the same filter as the interpolation filter used for the merge block whose motion information is referenced by the current block. Alternatively, the decoder may decode the index information of the interpolation filter with reference only to the motion information of the merge block for use in performing interpolation.
[0211] In an exemplary embodiment, if the current block is encoded in an affine mode, the video decoder may derive a control point motion vector (CPMV) of the current block using motion information of neighboring reference blocks of the current block. In this case, the video decoder may derive an interpolation filter index of the current block by utilizing interpolation filter index information used in neighboring reference blocks. Alternatively, the video decoder may decode interpolation filter index information explicitly signaled for the current block.
[0212] In an exemplary embodiment, if the current block is encoded with PMC (pair-wise average merge candidates), the interpolation filter index information of the current block may be derived by utilizing the interpolation filter index information used in the reference block for obtaining the average value of the motion vector. Alternatively, the decoder may decode the interpolation filter index information explicitly signaled for the current block.
[0213] In an exemplary embodiment, if the current block is encoded with HMVP (History based MV Prediction, based on history MV prediction), the interpolation filter index of the current block can be derived by utilizing the interpolation filter index information for the selective HMVP candidate. Alternatively, the decoder can decode the interpolation filter index information explicitly signaled for the current block.
[0214] It should be understood that the above exemplary embodiments can be implemented in many different ways. The functions or methods described in one or more examples can be implemented as hardware, software, firmware, or any combination thereof. The functional components described in this specification are marked as units to more particularly emphasize their implementation independence.
[0215] On the other hand, the various methods or functions described in the present invention can be implemented as instructions stored in a non-volatile recording medium, which can be read and executed by one or more processors. Non-volatile recording media include, for example, all types of recording devices that store data in a form that can be read by a computer system. For example, non-volatile recording media include storage media such as erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), flash drives, optical drives, magnetic hard drives, and solid-state drives (SSD).
[0216] Although the exemplary embodiments of the present invention have been described for illustrative purposes, it will be appreciated by those skilled in the art that various modifications and changes are possible without departing from the spirit and scope of the present invention. For the sake of brevity and clarity, exemplary embodiments have been described. Accordingly, it will be appreciated by those of ordinary skill that the scope of the embodiments is not limited by the embodiments explicitly described above, but is included in the claims and their equivalents.
Claims
1. A method for decoding video data, the method include: Obtain information about a luma prediction mode and information about a chroma prediction mode of a current coding block from a bitstream; Derived a luma intra prediction type and a luma intra prediction mode of a current coding block based on information about the luma prediction mode, wherein the luma intra prediction type includes matrix-based intra prediction and conventional intra prediction; Determine a chroma intra prediction mode for the current coding block based on the luma intra prediction type and the luma intra prediction mode of the current coding block and the information about the chroma prediction mode; Generate a chroma prediction sample of the current coding block based on the chroma intra prediction mode of the current coding block; Reconstruct the chroma samples of the current coding block based on the chroma prediction samples of the current coding block, Wherein, determining the chroma intra prediction mode of the current coding block includes: If the information about the chroma prediction mode indicates the direct mode, the luma intra prediction type of the current coding block is matrix-based intra prediction, and the sampling format of the video data is 4:4:4, It is determined that the chroma intra prediction type of the current coding block is matrix-based intra prediction, and The chroma intra prediction mode corresponding to the chroma intra prediction type of the current coding block is determined to be the same as the matrix-based intra prediction mode derived as the luma intra prediction mode of the current coding block.
2. A method for encoding video data, the method include: Determine a luma intra prediction type and a luma intra prediction mode of a current coding block, wherein the luma intra prediction type includes matrix-based intra prediction and conventional intra prediction; encoding information about the luma intra prediction type and luma prediction mode of the current coding block into a bitstream; Determine the chroma prediction type and chroma intra prediction mode of the current coding block; encoding information about a chroma prediction mode for a current coding block into a bitstream based on a luma intra prediction type and a luma intra prediction mode for the current coding block; Generate a chroma prediction sample of the current coding block based on the chroma intra prediction mode of the current coding block; Generate a residual block based on the chrominance prediction samples of the current coding block; Encode the residual block, Among them, when the luma intra prediction type of the current coding block is matrix-based intra prediction: If the sampling format of the video data is 4:4:4, the information about the chroma prediction mode indicating the direct mode indicates that the chroma intra prediction type of the current coding block is matrix-based intra prediction, and The chroma intra prediction mode of the current coding block is the same as the matrix-based intra prediction mode determined as the luma intra prediction mode of the current coding block.
3. A method for providing video data to a video decoding device, the method include: encoding video data into a bitstream; as well as Sending a bitstream to a video decoding device, The encoded video data includes: Determine a luma intra prediction type and a luma intra prediction mode of a current coding block, wherein the luma intra prediction type includes matrix-based intra prediction and conventional intra prediction; encoding information about the luma intra prediction type and luma prediction mode of the current coding block into a bitstream; Determine the chroma prediction type and chroma intra prediction mode of the current coding block; encoding information about a chroma prediction mode for a current coding block into a bitstream based on a luma intra prediction type and a luma intra prediction mode for the current coding block; Generate a chroma prediction sample of the current coding block based on the chroma intra prediction mode of the current coding block; Generate a residual block based on the chrominance prediction samples of the current coding block; Encode the residual block, Among them, when the luma intra prediction type of the current coding block is matrix-based intra prediction: If the sampling format of the video data is 4:4:4, the information about the chrominance prediction mode indicating the direct mode indicates that the chrominance intra-frame prediction type of the current coding block is matrix-based intra-frame prediction, and the chrominance intra-frame prediction mode of the current coding block is the same as the matrix-based intra-frame prediction mode determined as the luma intra-frame prediction mode of the current coding block.
Citation Information
Patent Citations
Detergent composition
KR1020190095449A
Patch for treating stomatitis
KR1020190097449A
