CN116530082A - Method and apparatus for video coding using intra prediction - Google Patents

Method and apparatus for video coding using intra prediction Download PDF

Info

Publication number
CN116530082A
CN116530082A CN202180080513.6A CN202180080513A CN116530082A CN 116530082 A CN116530082 A CN 116530082A CN 202180080513 A CN202180080513 A CN 202180080513A CN 116530082 A CN116530082 A CN 116530082A
Authority
CN
China
Prior art keywords
intra
prediction
predictor
current block
matrix
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202180080513.6A
Other languages
Chinese (zh)
Inventor
安镕照
李钟石
朴胜煜
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hyundai Motor Co
Kia Corp
DigitalInsights Inc
Original Assignee
Hyundai Motor Co
Kia Corp
DigitalInsights Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hyundai Motor Co, Kia Corp, DigitalInsights Inc filed Critical Hyundai Motor Co
Priority claimed from PCT/KR2021/017965 external-priority patent/WO2022119301A1/en
Publication of CN116530082A publication Critical patent/CN116530082A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/50Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
    • H04N19/593Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving spatial prediction techniques
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/102Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
    • H04N19/103Selection of coding mode or of prediction mode
    • H04N19/105Selection of the reference unit for prediction within a chosen coding or prediction mode, e.g. adaptive choice of position and number of pixels used for prediction
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/102Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
    • H04N19/103Selection of coding mode or of prediction mode
    • H04N19/11Selection of coding mode or of prediction mode among a plurality of spatial predictive coding modes
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/17Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object
    • H04N19/176Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object the region being a block, e.g. a macroblock

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

As a disclosure related to a method and apparatus for video encoding/decoding using intra prediction, the present embodiment provides a video encoding/decoding method and apparatus when performing intra prediction for combining a predictor generated by performing direction-based prediction and a predictor generated by performing rule-based or matrix-based operation prediction so as to generate a final intra predictor of a current block.

Description

Method and apparatus for video coding using intra prediction
Technical Field
The present invention relates to a method and apparatus for video coding by using intra prediction.
Background
The statements in this section merely provide background information related to the present disclosure and may not necessarily constitute prior art.
Since video data has a larger data amount than audio data or still image data, the video data requires a large amount of hardware resources (including a memory) to store or transmit the video data that is not subjected to compression processing.
Accordingly, encoders are typically used to compress and store or transmit video data. The decoder receives the compressed video data, decompresses the received compressed video data, and plays the decompressed video data. Video compression techniques include h.264/AVC, high efficiency video coding (High Efficiency Video Coding, HEVC), and multi-function video coding (Versatile Video Coding, VVC) that improves the coding efficiency of HEVC by about 30% or more.
However, as the image size, resolution, and frame rate gradually increase, the amount of data to be encoded is also increasing. Accordingly, a new compression technique providing higher coding efficiency and improved image enhancement effect compared to the existing compression technique is required.
In picture (video) encoding and decoding, an intra prediction method may be performed to predict a current block by using pixels in the same frame. In this case, the intra prediction method may be classified into two main types based on how the predicted samples are generated.
The first is a conventional intra prediction method, which is a direction-based prediction that performs prediction based on prediction directions of pixels spatially adjacent to a target block for intra prediction and neighboring pixels. Direction-based prediction has an advantage of easy implementation, but when a model exists in a target block or when an object exists in the lower right of the target block, the prediction performance of the direction-based prediction may be deteriorated.
The second method is rule-based prediction, which uses coding information of a target block for intra prediction and neighboring pixels spatially adjacent to the target block, thereby performing a predefined operation or a prediction operation using a predefined matrix. Although rule-based prediction may remedy the drawbacks of direction-based prediction, it is relatively complex to implement and the prediction performance of rule-based prediction is poor for target blocks that do not conform to rules.
Accordingly, there is a need for an intra prediction method capable of combining the advantages of direction-based prediction and rule-based prediction in terms of improving image quality.
Disclosure of Invention
Technical problem
The present invention in some embodiments is directed to providing a video encoding/decoding method and apparatus that generates a predictor by performing direction-based prediction and generates a predictor by performing rule-based (or matrix-based operation) prediction in performing intra-prediction. Video encoding/decoding methods and apparatus combine two predictors to generate a final intra predictor for a current block.
Solution method
At least one aspect of the present invention provides an intra prediction method performed by a video decoding apparatus. The method comprises the following steps: a combined intra-prediction flag is decoded from the bitstream, the combined intra-prediction flag indicating that a combination between direction-based intra-prediction and matrix-operation-based intra-prediction is enabled. The method further comprises the steps of: intra prediction of the current block is performed according to the combined intra prediction flag. When the combined intra-prediction flag is true, performing intra-prediction includes: decoding a direction-based intra prediction mode of the current block from the bitstream, generating a first intra predictor of the current block by using the direction-based intra prediction mode, decoding an index indicating one of a plurality of predefined matrices used in the matrix-operation-based intra prediction from the bitstream, generating a second intra predictor of the current block by using the predefined matrix indicated by the index, and generating a combined intra predictor of the current block by combining the first intra predictor and the second intra predictor.
Another aspect of the present invention provides a video decoding apparatus for generating a combined intra prediction factor of a current block. The video decoding apparatus includes an entropy decoder configured to decode a combined intra-prediction flag from a bitstream, the combined intra-prediction flag indicating that a combination between direction-based intra-prediction and matrix-operation-based intra-prediction is enabled. The video decoding device further includes an intra predictor configured to perform intra prediction of the current block according to the combined intra prediction flag. When the combined intra prediction flag is true, the entropy decoder is configured to decode from the bitstream a direction-based intra prediction mode of the current block and an index indicating one of a plurality of predefined matrices utilized in matrix-operation-based intra prediction. When the combined intra prediction flag is true, the intra predictor is configured to generate a first intra predictor of the current block by using the direction-based intra prediction mode, generate a second intra predictor of the current block by using a predefined matrix indicated by the index, and generate a combined intra predictor of the current block by combining the first intra predictor and the second intra predictor.
Yet another aspect of the present invention provides an intra prediction method performed by a video encoding apparatus. The method comprises the following steps: a combined intra-prediction flag is obtained that indicates a combination between enabling direction-based intra-prediction and matrix-operation-based intra-prediction. The method further comprises the steps of: intra prediction of the current block is performed according to the combined intra prediction flag. When the combined intra-prediction flag is true, performing intra-prediction includes: the method includes obtaining a direction-based intra prediction mode of a current block, generating a first intra predictor of the current block by using the direction-based intra prediction mode, obtaining an index indicating one of a plurality of predefined matrices utilized in matrix-operation-based intra prediction, generating a second intra predictor of the current block by using the predefined matrix indicated by the index, and generating a combined intra predictor of the current block by combining the first intra predictor and the second intra predictor.
Effects of the invention
As described above, the present embodiment provides a video image encoding/decoding method and apparatus that generates a predictor (predictor) by performing direction-based prediction and generates a predictor by performing rule-based (or matrix-based operation) prediction. Video encoding/decoding methods and apparatus combine two predictors to generate a final intra predictor for a current block to improve video quality based on intra prediction.
Drawings
Fig. 1 is a block diagram of a video encoding device in which the techniques of the present invention may be implemented.
Fig. 2 illustrates a method of partitioning a block using a quadtree plus binary tree trigeminal tree (QTBTTT) structure.
Fig. 3a and 3b illustrate a plurality of intra prediction modes including a wide-angle intra prediction mode.
Fig. 4 shows neighboring blocks of the current block.
Fig. 5 is a block diagram of a video decoding apparatus in which the techniques of the present invention may be implemented.
Fig. 6 is a schematic diagram illustrating pixels spatially adjacent to pixels of a current block in accordance with at least one embodiment of the present invention.
Fig. 7 is a schematic diagram illustrating rule-based intra prediction in accordance with at least one embodiment of the present invention.
Fig. 8 is a schematic diagram illustrating rule-based intra prediction according to another embodiment of the present invention.
Fig. 9 is a schematic diagram illustrating an intra predictor performing combined intra prediction according to at least one embodiment of the present invention.
Fig. 10 is a schematic diagram illustrating a combined intra predictor for a current block according to at least one embodiment of the present invention.
Fig. 11 is a schematic diagram illustrating a current block and its spatially neighboring blocks in accordance with at least one embodiment of the present invention.
Fig. 12 is a flowchart of a method performed by a video decoding apparatus for generating a combined intra predictor in accordance with at least one embodiment of the present invention.
Fig. 13 is a flowchart of a method for generating a combined intra prediction factor performed by a video decoding apparatus according to another embodiment of the present invention.
Detailed Description
Hereinafter, some embodiments of the present invention will be described in detail with reference to the accompanying illustrative drawings. In the following description, like reference numerals denote like elements, although the elements are shown in different drawings. Furthermore, in the following description of some embodiments, detailed descriptions of related known components and functions may be omitted for clarity and conciseness when it may be considered that the subject matter of the present invention is obscured.
Fig. 1 is a block diagram of a video encoding device in which the techniques of the present invention may be implemented. Hereinafter, a video encoding apparatus and sub-components of the apparatus are described with reference to the illustration of fig. 1.
The encoding apparatus may include: an image divider 110, a predictor 120, a subtractor 130, a transformer 140, a quantizer 145, a reordering unit 150, an entropy encoder 155, an inverse quantizer 160, an inverse transformer 165, an adder 170, a loop filtering unit 180, and a memory 190.
Each component of the encoding apparatus may be implemented as hardware or software, or as a combination of hardware and software. In addition, the function of each component may be implemented as software, and the microprocessor may also be implemented to execute the function of the software corresponding to each component.
A video is made up of one or more sequences comprising a plurality of images. Each image is divided into a plurality of regions, and encoding is performed on each region. For example, an image is segmented into one or more tiles (tiles) or/and slices (slices). Here, one or more tiles may be defined as a tile set. Each tile or/and slice is partitioned into one or more Coding Tree Units (CTUs). In addition, each CTU is partitioned into one or more Coding Units (CUs) by a tree structure. Information applied to each CU is encoded as a syntax of the CU, and information commonly applied to CUs included in one CTU is encoded as a syntax of the CTU. In addition, information commonly applied to all blocks in one slice is encoded as syntax of a slice header, and information applied to all blocks constituting one or more pictures is encoded as a picture parameter set (Picture Parameter Set, PPS) or a picture header. Furthermore, information commonly referred to by the plurality of images is encoded as a sequence parameter set (Sequence Parameter Set, SPS). In addition, information commonly referenced by the one or more SPS is encoded as a set of video parameters (Video Parameter Set, VPS). Furthermore, information commonly applied to one tile or group of tiles may also be encoded as syntax of the tile or group of tiles header. The syntax included in the SPS, PPS, slice header, tile, or tile set header may be referred to as a high level syntax.
The image divider 110 determines the size of the CTU. Information about the size of the CTU (CTU size) is encoded as a syntax of the SPS or PPS and transmitted to the video decoding apparatus.
The image divider 110 divides each image constituting a video into a plurality of CTUs having a predetermined size, and then recursively divides the CTUs by using a tree structure. Leaf nodes in the tree structure become CUs, which are the basic units of coding.
The tree structure may be a Quadtree (QT) in which a higher node (or parent node) is partitioned into four lower nodes (or child nodes) of the same size. The tree structure may also be a Binary Tree (BT) in which a higher node is split into two lower nodes. The tree structure may also be a Trigeminal Tree (TT), where the higher nodes are split into three lower nodes at a ratio of 1:2:1. The tree structure may also be a structure in which two or more of a QT structure, a BT structure, and a TT structure are mixed. For example, a quadtree plus binary tree (quadtree plus binarytree, QTBT) structure may be used, or a quadtree plus binary tree (quadtree plus binarytree ternarytree, QTBTTT) structure may be used. Here, BTTT is added to the tree structure to be called multiple-type tree (MTT).
Fig. 2 is a schematic diagram for describing a method of dividing a block by using the QTBTTT structure.
As shown in fig. 2, the CTU may be first partitioned into QT structures. Quadtree partitioning may be recursive until the size of the partitioned block reaches the minimum block size (MinQTSize) of leaf nodes allowed in QT. A first flag (qt_split_flag) indicating whether each node of the QT structure is partitioned into four lower-layer nodes is encoded by the entropy encoder 155 and signaled to the video decoding apparatus. When the leaf node of QT is not greater than the maximum block size (MaxBTSize) of the root node allowed in BT, the leaf node may be further divided into at least one of BT structure or TT structure. There may be multiple directions of segmentation in the BT structure and/or the TT structure. For example, there may be two directions, i.e., a direction of dividing the block of the corresponding node horizontally and a direction of dividing the block of the corresponding node vertically. As shown in fig. 2, when the MTT division starts, a second flag (MTT _split_flag) indicating whether a node is divided, and a flag additionally indicating a division direction (vertical or horizontal) and/or a flag indicating a division type (binary or trigeminal) in the case that a node is divided are encoded by the entropy encoder 155 and signaled to the video decoding apparatus.
Alternatively, a CU partition flag (split_cu_flag) indicating whether a node is partitioned may be further encoded before encoding a first flag (qt_split_flag) indicating whether each node is partitioned into four nodes of a lower layer. When the value of the CU partition flag (split_cu_flag) indicates that each node is not partitioned, the block of the corresponding node becomes a leaf node in the partition tree structure and becomes a CU, which is a basic unit of encoding. When the value of the CU partition flag (split_cu_flag) indicates that each node is partitioned, the video encoding apparatus first starts encoding the first flag in the above scheme.
When QTBT is used as another example of the tree structure, there may be two types, i.e., a type of horizontally dividing a block of a corresponding node into two blocks having the same size (i.e., symmetrical horizontal division) and a type of vertically dividing a block of a corresponding node into two blocks having the same size (i.e., symmetrical vertical division). A partition flag (split_flag) indicating whether each node of the BT structure is partitioned into lower-layer blocks and partition type information indicating a partition type are encoded by the entropy encoder 155 and transmitted to the video decoding apparatus. On the other hand, there may additionally be a type in which a block of a corresponding node is divided into two blocks in an asymmetric form to each other. The asymmetric form may include a form in which a block of a corresponding node is divided into two rectangular blocks having a size ratio of 1:3, or may also include a form in which a block of a corresponding node is divided in a diagonal direction.
A CU may have various sizes according to QTBT or QTBTTT divided from CTUs. Hereinafter, a block corresponding to a CU to be encoded or decoded (i.e., a leaf node of QTBTTT) is referred to as a "current block". When QTBTTT segmentation is employed, the shape of the current block may also be rectangular in shape, in addition to square shape.
The predictor 120 predicts the current block to generate a predicted block. Predictor 120 includes an intra predictor 122 and an inter predictor 124.
In general, each of the current blocks in the image may be predictively encoded. In general, prediction of a current block may be performed by using an intra prediction technique using data from an image including the current block or an inter prediction technique using data from an image encoded before the image including the current block. Inter prediction includes both unidirectional prediction and bi-directional prediction.
The intra predictor 122 predicts pixels in the current block by using pixels (reference pixels) located adjacent to the current block in the current image including the current block. Depending on the prediction direction, there are multiple intra prediction modes. For example, as shown in fig. 3a, the plurality of intra prediction modes may include two non-directional modes including a Planar (Planar) mode and a DC mode, and may include 65 directional modes. The neighboring pixels and algorithm equations to be used are defined differently according to each prediction mode.
For efficient direction prediction of a current block having a rectangular shape, direction modes (# 67 to # 80) indicated by dotted arrows in fig. 3b, intra prediction modes # -1 to # -14) may be additionally used. The direction mode may be referred to as a "wide angle intra-prediction mode". In fig. 3b, the arrows indicate the respective reference samples for prediction, rather than representing the prediction direction. The prediction direction is opposite to the direction indicated by the arrow. When the current block has a rectangular shape, 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. In this case, in the wide-angle intra prediction mode, some of the wide-angle intra prediction modes available for the current block may be determined by a ratio of a width to a height of the current block having a rectangular shape. For example, when the current block has a rectangular shape having a height smaller than a width, wide-angle intra prediction modes (intra prediction modes #67 to # 80) having angles smaller than 45 degrees are available. When the current block has a rectangular shape with a width greater than a height, a wide-angle intra prediction mode having an angle greater than-135 degrees is available.
The intra predictor 122 may determine intra prediction to be used for encoding the current block. In some examples, intra predictor 122 may encode the current block by utilizing a plurality of intra prediction modes, and may also select an appropriate intra prediction mode to use from among the test modes. For example, the intra predictor 122 may calculate a rate distortion value by using rate-distortion (rate-distortion) analysis of a plurality of tested intra prediction modes, and may also select an intra prediction mode having the best rate distortion characteristics among the test modes.
The intra predictor 122 selects one intra prediction mode among a plurality of intra prediction modes, and predicts the current block by using neighboring pixels (reference pixels) determined according to the selected intra prediction mode and an algorithm equation. Information about the selected intra prediction mode is encoded by the entropy encoder 155 and transmitted to a video decoding device.
The inter predictor 124 generates a prediction block of the current block by using a motion compensation process. The inter predictor 124 searches for a block most similar to the current block in a reference picture that has been encoded and decoded earlier than the current picture, and generates a predicted block of the current block by using the searched block. In addition, a Motion Vector (MV) is generated, which corresponds to a displacement (displacement) between a current block in the current image and a prediction block in the reference image. In general, motion estimation is performed on a luminance (luma) component, and a motion vector calculated based on the luminance component is used for both the luminance component and the chrominance component. Motion information including information of the reference picture and information on a motion vector for predicting the current block is encoded by the entropy encoder 155 and transmitted to a video decoding device.
The inter predictor 124 may also perform interpolation of reference pictures or reference blocks to increase the accuracy of prediction. In other words, the sub-samples are interpolated between two consecutive integer samples by applying the filter coefficients to a plurality of consecutive integer samples comprising the two integer samples. When the process of searching for a block most similar to the current block is performed on the interpolated reference image, the decimal-unit precision may be represented for the motion vector instead of the integer-sample-unit precision. The precision or resolution of the motion vector may be set differently for each target region to be encoded, e.g., a unit such as a slice, tile, CTU, CU, etc. When such adaptive motion vector resolution (adaptive motion vector resolution, AMVR) is applied, information on the motion vector resolution to be applied to each target area should be signaled for each target area. For example, when the target area is a CU, information about the resolution of a motion vector applied to each CU is signaled. The information on the resolution of the motion vector may be information representing the accuracy of a motion vector difference to be described below.
On the other hand, the inter predictor 124 may perform inter prediction by using bi-directional prediction. In the case of bi-prediction, two reference pictures and two motion vectors representing block positions most similar to the current block in each reference picture are used. The inter predictor 124 selects a first reference picture and a second reference picture from the reference picture list0 (RefPicList 0) and the reference picture list1 (RefPicList 1), respectively. The inter predictor 124 also searches for a block most similar to the current block in the corresponding reference picture to generate a first reference block and a second reference block. Further, a prediction block of the current block is generated by averaging or weighted-averaging the first reference block and the second reference block. Further, motion information including information on two reference pictures for predicting the current block and information on two motion vectors is transmitted to the entropy encoder 155. Here, the reference image list0 may be constituted by an image preceding the current image in display order among the pre-restored images, and the reference image list1 may be constituted by an image following the current image in display order among the pre-restored images. However, although not particularly limited thereto, a pre-restored image following the current image in the display order may be additionally included in the reference image list 0. Conversely, a pre-restored image preceding the current image may be additionally included in the reference image list 1.
In order to minimize the amount of bits consumed for encoding motion information, various methods may be used.
For example, when a reference image and a motion vector of a current block are identical to those of a neighboring block, information capable of identifying the neighboring block is encoded to transmit motion information of the current block to a video decoding apparatus. This method is called merge mode (merge mode).
In the merge mode, the inter predictor 124 selects a predetermined number of merge candidate blocks (hereinafter, referred to as "merge candidates") from neighboring blocks of the current block.
As the neighboring blocks used to derive the merge candidates, all or some of the left block A0, the lower left block A1, the upper block B0, the upper right block B1, and the upper left block B2 adjacent to the current block in the current image may be used, as shown in fig. 4. In addition, in addition to the current picture in which the current block is located, a block located within a reference picture (which may be the same as or different from the reference picture used to predict the current block) may also be used as a merging candidate. For example, a co-located block (co-located block) of a current block within a reference picture or a block adjacent to the co-located block may additionally be used as a merging candidate. If the number of merging candidates selected by the above method is less than a preset number, a zero vector is added to the merging candidates.
The inter predictor 124 configures a merge list including a predetermined number of merge candidates by using neighboring blocks. A merge candidate to be used as motion information of the current block is selected from among the merge candidates included in the merge list, and merge index information for identifying the selected candidate is generated. The generated merging index information is encoded by the entropy encoder 155 and transmitted to a video decoding apparatus.
The merge skip mode is a special case of the merge mode. After quantization, when all transform coefficients used for entropy coding are near zero, only neighboring block selection information is transmitted without transmitting a residual signal. By using the merge skip mode, relatively high encoding efficiency can be achieved for images with slight motion, still images, screen content images, and the like.
Hereinafter, the merge mode and the merge skip mode are collectively referred to as a merge/skip mode.
Another method for encoding motion information is advanced motion vector prediction (advanced motion vector prediction, AMVP) mode.
In the AMVP mode, the inter predictor 124 derives a motion vector prediction candidate for a motion vector of a current block by using neighboring blocks of the current block. As the neighboring blocks used to derive the motion vector prediction candidates, all or some of the left block A0, the lower left block A1, the upper side block B0, the upper right block B1, and the upper left block B2 adjacent to the current block in the current image shown in fig. 4 may be used. In addition, in addition to the current picture in which the current block is located, a block located within a reference picture (which may be the same as or different from a reference picture used to predict the current block) may also be used as a neighboring block used to derive a motion vector prediction candidate. For example, a co-located block of the current block within the reference picture or a block adjacent to the co-located block may be used. If the number of motion vector candidates selected by the above method is less than a preset number, a zero vector is added to the motion vector candidates.
The inter predictor 124 derives a motion vector prediction candidate by using the motion vector of the neighboring block, and determines a motion vector prediction of the motion vector of the current block by using the motion vector prediction candidate. In addition, a motion vector difference is calculated by subtracting a motion vector prediction from a motion vector of the current block.
Motion vector prediction may be obtained by applying a predefined function (e.g., median and average calculations, etc.) to the motion vector prediction candidates. In this case, the video decoding device is also aware of the predefined function. Further, since the neighboring block used to derive the motion vector prediction candidates is a block for which encoding and decoding have been completed, the video decoding apparatus may also already know the motion vector of the neighboring block. Therefore, the video encoding device does not need to encode information for identifying motion vector prediction candidates. Accordingly, in this case, information on a motion vector difference and information on a reference image for predicting a current block are encoded.
On the other hand, motion vector prediction may also be determined by selecting a scheme of any one of the motion vector prediction candidates. In this case, the information for identifying the selected motion vector prediction candidates is additionally encoded together with the information about the motion vector difference and the information about the reference picture for predicting the current block.
The subtractor 130 generates a residual block by subtracting the current block from the prediction block generated by the intra predictor 122 or the inter predictor 124.
The transformer 140 transforms a residual signal in a residual block having pixel values of a spatial domain into transform coefficients of a frequency domain. The transformer 140 may transform a residual signal in a residual block by using the entire size of the residual block as a transform unit, or may divide the residual block into a plurality of sub-blocks and perform the transform by using the sub-blocks as transform units. Alternatively, the residual block is divided into two sub-blocks, i.e., a transform region and a non-transform region, to transform the residual signal by using only the transform region sub-block as a transform unit. Here, the transform region sub-block may be one of two rectangular blocks having a size ratio of 1:1 based on a horizontal axis (or a vertical axis). In this case, a flag (cu_sbt_flag) indicating that only the sub-block is transformed, and direction (vertical/horizontal) information (cu_sbt_horizontal_flag) and/or position information (cu_sbt_pos_flag) are encoded by the entropy encoder 155 and signaled to the video decoding apparatus. In addition, the size of the transform region sub-block may have a size ratio of 1:3 based on the horizontal axis (or vertical axis). In this case, a flag (cu_sbt_quad_flag) dividing the corresponding division is additionally encoded by the entropy encoder 155 and signaled to the video decoding device.
On the other hand, the transformer 140 may perform transformation of the residual block separately in the horizontal direction and the vertical direction. For this transformation, various types of transformation functions or transformation matrices may be used. For example, the pair-wise transformation function for horizontal and vertical transformations may be defined as a transformation set (multiple transform set, MTS). The transformer 140 may select one transform function pair having the highest transform efficiency in the MTS and transform the residual block in each of the horizontal and vertical directions. Information (mts_idx) about the transform function pairs in the MTS is encoded by the entropy encoder 155 and signaled to the video decoding means.
The quantizer 145 quantizes the transform coefficient output from the transformer 140 using a quantization parameter, and outputs the quantized transform coefficient to the entropy encoder 155. The quantizer 145 may also immediately quantize the relevant residual block without transforming any block or frame. The quantizer 145 may also apply different quantization coefficients (scaling values) according to the positions of the transform coefficients in the transform block. A quantization matrix applied to quantized transform coefficients arranged in two dimensions may be encoded and signaled to a video decoding apparatus.
The reordering unit 150 may perform the rearrangement of the coefficient values on the quantized residual values.
The rearrangement unit 150 may change the 2D coefficient array to a 1D coefficient sequence by using coefficient scanning. For example, the rearrangement unit 150 may scan the DC coefficients to the coefficients of the high frequency region using zigzag scanning (zig-zag scan) or diagonal scanning (diagonal scan) to output a 1D coefficient sequence. Instead of the zig-zag scan, a vertical scan that scans the 2D coefficient array in the column direction and a horizontal scan that scans the 2D block type coefficients in the row direction may also be utilized, depending on the size of the transform unit and the intra prediction mode. In other words, the scanning method to be used may be determined in zigzag scanning, diagonal scanning, vertical scanning, and horizontal scanning according to the size of the transform unit and the intra prediction mode.
The entropy encoder 155 encodes the sequence of the 1D quantized transform coefficients output from the rearrangement unit 150 by using various encoding schemes including Context-based adaptive binary arithmetic coding (Context-based Adaptive Binary Arithmetic Code, CABAC), exponential golomb (Exponential Golomb), and the like to generate a bitstream.
Further, the entropy encoder 155 encodes information related to block division (e.g., CTU size, CTU division flag, QT division flag, MTT division type, MTT division direction, etc.) so that the video decoding apparatus can divide blocks equally to the video encoding apparatus. Further, the entropy encoder 155 encodes information on a prediction type indicating whether the current block is encoded by intra prediction or inter prediction. The entropy encoder 155 encodes intra prediction information (i.e., information about an intra prediction mode) or inter prediction information (a merge index in the case of a merge mode, and information about a reference picture index and a motion vector difference in the case of an AMVP mode) according to a prediction type. Further, the entropy encoder 155 encodes information related to quantization (i.e., information about quantization parameters and information about quantization matrices).
The inverse quantizer 160 inversely quantizes the quantized transform coefficient output from the quantizer 145 to generate a transform coefficient. The inverse transformer 165 transforms the transform coefficients output from the inverse quantizer 160 from the frequency domain to the spatial domain to restore a residual block.
The adder 170 adds the restored residual block and the prediction block generated by the predictor 120 to restore the current block. The pixels in the restored current block may be used as reference pixels when intra-predicting the next block.
The loop filtering unit 180 performs filtering on the restored pixels to reduce block artifacts (blocking artifacts), ringing artifacts (ringing artifacts), blurring artifacts (blurring artifacts), etc., which occur due to block-based prediction and transform/quantization. The loop filtering unit 180 as an in-loop filter may include all or some of a deblocking filter 182, a sample adaptive offset (sample adaptive offset, SAO) filter 184, and an adaptive loop filter (adaptive loop filter, ALF) 186.
Deblocking filter 182 filters boundaries between restored blocks to remove block artifacts (blocking artifacts) that occur due to block unit encoding/decoding, and SAO filter 184 and ALF 186 additionally filter the deblock filtered video. The SAO filter 184 and ALF 186 are filters for compensating for differences between restored pixels and original pixels that occur due to lossy coding (loss coding). The SAO filter 184 applies an offset as a CTU unit to enhance subjective image quality and coding efficiency. On the other hand, the ALF 186 performs block unit filtering, and applies different filters to compensate for distortion by dividing boundaries of respective blocks and the degree of variation. Information about filter coefficients to be used for ALF may be encoded and signaled to the video decoding apparatus.
The restored blocks filtered by the deblocking filter 182, the SAO filter 184, and the ALF 186 are stored in the memory 190. When all blocks in one image are restored, the restored image may be used as a reference image for inter-predicting blocks within a picture to be subsequently encoded.
Fig. 5 is a functional block diagram of a video decoding apparatus in which the techniques of the present invention may be implemented. Hereinafter, with reference to fig. 5, a video decoding apparatus and sub-components of the apparatus are described.
The video decoding apparatus may include an entropy decoder 510, a reordering unit 515, an inverse quantizer 520, an inverse transformer 530, a predictor 540, an adder 550, a loop filtering unit 560, and a memory 570.
Similar to the video encoding apparatus of fig. 1, each component of the video decoding apparatus may be implemented as hardware or software, or as a combination of hardware and software. In addition, the function of each component may be implemented as software, and the microprocessor may also be implemented to execute the function of the software corresponding to each component.
The entropy decoder 510 extracts information related to block segmentation by decoding a bitstream generated by a video encoding apparatus to determine a current block to be decoded, and extracts prediction information required to restore the current block and information on a residual signal.
The entropy decoder 510 determines the size of CTUs by extracting information about the CTU size from a Sequence Parameter Set (SPS) or a Picture Parameter Set (PPS), and partitions a picture into CTUs having the determined size. Further, the CTU is determined as the highest layer (i.e., root node) of the tree structure, and the partition information of the CTU is extracted to partition the CTU by using the tree structure.
For example, when dividing a CTU by using the QTBTTT structure, first a first flag (qt_split_flag) related to the division of QT is extracted to divide each node into four nodes of the lower layer. In addition, a second flag (MTT _split_flag), a split direction (vertical/horizontal), and/or a split type (binary/trigeminal) related to the split of the MTT are extracted with respect to a node corresponding to the leaf node of the QT to split the corresponding leaf node into the MTT structure. As a result, each node below the leaf node of QT is recursively partitioned into BT or TT structures.
As another example, when a CTU is divided by using the QTBTTT structure, a CU division flag (split_cu_flag) indicating whether to divide the CU is extracted. When the corresponding block is partitioned, a first flag (qt_split_flag) may also be extracted. During the segmentation process, recursive MTT segmentation of 0 or more times may occur after recursive QT segmentation of 0 or more times for each node. For example, for CTUs, MTT partitioning may occur immediately, or conversely, QT partitioning may occur only multiple times.
As another example, when dividing the CTU by using the QTBT structure, a first flag (qt_split_flag) related to the division of QT is extracted to divide each node into four nodes of the lower layer. In addition, a split flag (split_flag) indicating whether or not a node corresponding to a leaf node of QT is further split into BT and split direction information are extracted.
On the other hand, when the entropy decoder 510 determines the current block to be decoded by using the partition of the tree structure, the entropy decoder 510 extracts information on a prediction type indicating whether the current block is intra-predicted or inter-predicted. When the prediction type information indicates intra prediction, the entropy decoder 510 extracts syntax elements for intra prediction information (intra prediction mode) of the current block. When the prediction type information indicates inter prediction, the entropy decoder 510 extracts information representing syntax elements of the inter prediction information, i.e., a motion vector and a reference picture to which the motion vector refers.
Further, the entropy decoder 510 extracts quantization-related information and extracts information on transform coefficients of the quantized current block as information on a residual signal.
The reordering unit 515 may change the sequence of the 1D quantized transform coefficients entropy-decoded by the entropy decoder 510 into a 2D coefficient array (i.e., block) again in the reverse order of the coefficient scan order performed by the video encoding device.
The inverse quantizer 520 inversely quantizes the quantized transform coefficient and inversely quantizes the quantized transform coefficient by using a quantization parameter. The inverse quantizer 520 may also apply different quantization coefficients (scaling values) to the quantized transform coefficients arranged in 2D. The inverse quantizer 520 may perform inverse quantization by applying a matrix of quantized coefficients (scaled values) from the video encoding device to a 2D array of quantized transform coefficients.
The inverse transformer 530 restores a residual signal by inversely transforming the inversely quantized transform coefficients from the frequency domain to the spatial domain to generate a residual block of the current block.
Further, when the inverse transformer 530 inversely transforms a partial region (sub-block) of the transform block, the inverse transformer 530 extracts a flag (cu_sbt_flag) transforming only the sub-block of the transform block, direction (vertical/horizontal) information (cu_sbt_horizontal_flag) of the sub-block, and/or position information (cu_sbt_pos_flag) of the sub-block. The inverse transformer 530 also inversely transforms transform coefficients of the corresponding sub-block from the frequency domain to the spatial domain to restore a residual signal, and fills the region that is not inversely transformed with a value of "0" as the residual signal to generate a final residual block of the current block.
Further, when applying MTS, the inverse transformer 530 determines a transform index or a transform matrix to be applied in each of the horizontal direction and the vertical direction by using MTS information (mts_idx) signaled from the video encoding apparatus. The inverse transformer 530 also performs inverse transformation on the transform coefficients in the transform block in the horizontal direction and the vertical direction by using the determined transform function.
The predictor 540 may include an intra predictor 542 and an inter predictor 544. The intra predictor 542 is activated when the prediction type of the current block is intra prediction, and the inter predictor 544 is activated when the prediction type of the current block is inter prediction.
The intra predictor 542 determines an intra prediction mode of the current block among the plurality of intra prediction modes according to syntax elements of the intra prediction mode extracted from the entropy decoder 510. The intra predictor 542 also predicts the current block by using neighboring reference pixels of the current block according to an intra prediction mode.
The inter predictor 544 determines a motion vector of the current block and a reference picture to which the motion vector refers by using syntax elements of the inter prediction mode extracted from the entropy decoder 510.
The adder 550 restores the current block by adding the residual block output from the inverse transformer 530 to the prediction block output from the inter predictor 544 or the intra predictor 542. In intra prediction of a block to be decoded later, pixels within the restored current block are used as reference pixels.
The loop filtering unit 560, which is an in-loop filter, may include a deblocking filter 562, an SAO filter 564, and an ALF 566. Deblocking filter 562 performs deblocking filtering on boundaries between restored blocks to remove block artifacts occurring due to block unit decoding. The SAO filter 564 and ALF 566 perform additional filtering on the restored block after deblocking filtering to compensate for differences between restored pixels and original pixels that occur due to lossy encoding. The filter coefficients of the ALF are determined by using information on the filter coefficients decoded from the bitstream.
The restored blocks filtered by the deblocking filter 562, the SAO filter 564, and the ALF 566 are stored in the memory 570. When all blocks in one image are restored, the restored image may be used as a reference image for inter-predicting blocks within a picture to be subsequently encoded.
The present embodiment relates to encoding and decoding of an image (video) as described above. More specifically, the present embodiment provides a video encoding/decoding method and apparatus that generates a predictor (predictor) by performing direction-based prediction and generates a predictor by performing rule-based (or matrix-based operation) prediction when performing intra-prediction. Video encoding/decoding methods and apparatus combine two predictors to generate a final intra predictor for a current block.
In the following description, the term "target block" may be used interchangeably with the current block or Coding Unit (CU) as described above, or may refer to a portion of the coding unit.
On the other hand, the following embodiments may be implemented in the intra predictor 122 of the video encoding apparatus and the intra predictor 542 of the video decoding apparatus. Hereinafter, in order to avoid redundancy, the present embodiment is described from the viewpoint of the intra predictor 542 in the video decoding apparatus.
Fig. 6 is a schematic diagram illustrating pixels spatially adjacent to pixels of a current block in accordance with at least one embodiment of the present invention.
As shown in fig. 6, the intra predictor 542 in the video decoding apparatus generates an intra predictor corresponding to a current block by using a plurality of neighboring pixels spatially adjacent to the current block and a specific direction. Here, the predictors represent some decoded combinations of values. Thus, the intra-prediction factor represents a combination of predicted samples or predicted blocks corresponding to the result of the intra-prediction. Hereinafter, a predictor, a predicted sample, and a prediction block may be used interchangeably.
Among a plurality of neighboring pixels spatially adjacent to the current block, neighboring pixels utilized in intra prediction may differ in number according to a direction used in intra prediction. As shown in fig. 6, the width of the current block is assumed to be nCbw, and the height of the current block is assumed to be nCbh. In this case, the reference pixels for intra prediction may include reference pixels located at upper left and right positions of the block, reference pixels arranged at top and upper right positions of the block and equal in number to the sum of the width of the block and the height of the block, and reference pixels arranged at left and lower left positions of the block and equal in number to the sum of the width of the block and the height of the block.
In performing intra prediction, as shown in fig. 6, the intra predictor 542 may refer to, but is not necessarily limited to, a pixel on one sample line as a referenceable neighboring pixel. For example, the intra predictor 542 may utilize pixels that are spatially located at different pixel distances from the current block as referenceable neighboring pixels.
Further, the intra predictor 542 may use, but is not necessarily limited to, one pixel line of a plurality of pixel lines as a reference pixel line. For example, the intra predictor 542 may generate a predictor by using a reference pixel line which is a combination of a plurality of pixel lines.
I. Direction-based intra prediction
As shown in fig. 3a, the direction for intra prediction may be uniformly divided into units of reference angles to have a specific interior angle. Alternatively, some unevenly divided directions may be utilized according to the characteristics of the current block.
Furthermore, the available direction for intra prediction may vary based on the shape of the block. In this case, the shape of the block may refer to specific information derived from a ratio between the width and the height of the block, a relative length comparison between the width and the height, and the like. Furthermore, the available directions based on the shape of the block may be directions represented by the wide-angle intra prediction mode added to the illustration of fig. 3b for the illustration of fig. 3 a.
Examples of rule-based intra prediction
Fig. 7 is a schematic diagram illustrating rule-based intra prediction in accordance with at least one embodiment of the present invention.
The predictor may be generated based on a predefined operation using information of encoding of the target block to be intra-predicted and spatially adjacent neighboring pixels of the target block. One such rule-based prediction method is a position-resolved intra-prediction combination (Position Dependentintra Prediction Combination, PDPC), as shown in fig. 7.
The PDPC modifies the predicted samples generated according to the particular intra prediction mode to generate an intra predictor for the current block. Among the prediction modes illustrated in fig. 3a, the specific intra prediction modes include a plane, DC, horizontal (prediction mode 18), vertical (prediction mode 50), lower left diagonal direction mode (prediction mode 2), and 15 direction modes in the vicinity, and upper right diagonal direction mode (prediction mode 66) and 15 direction modes in the vicinity thereof.
As shown in fig. 7, for predicted samples of a current block generated according to a specific intra prediction mode, the PDPC may utilize predefined weight and location information of neighboring pixels to generate predicted samples, the values of which are adjusted at the pixel level. The PDPC may generate samples of the adjusted predictions according to equation 1.
Equation 1
P(x,y)=(wL·R -1,y +wT·R x,-1 +(64-wL-wT)·p(x,y)+32)>>6
Where P (x, y) on the left represents predicted samples generated by a particular intra prediction mode and P (x, y) on the right represents predicted samples adjusted according to equation 1. wL and wT are predefined weights, which may be set differently according to a specific intra prediction mode. In addition, R x,-1 Represents a reference pixel located at the top of the current block, and R -1,y Representing the reference pixel located to the left of the current block.
The foregoing represents, but is not necessarily limited to, an example of a PDPC that is applied according to a particular intra prediction mode. In another embodiment, to indicate whether such a PDPC is enabled, the video encoding device may encode and transmit the position-determined prediction flag to the video decoding device.
Other examples of rule-based intra prediction
Fig. 8 is a schematic diagram illustrating rule-based intra prediction according to another embodiment of the present invention.
By using neighboring pixels of the current block that are performing intra prediction and encoding information of the current block, a predictor may be generated based on an operation of a predefined matrix, as shown in fig. 8. This rule-based prediction method is called matrix weighted intra prediction (Matrix weighted Intra Prediction, MIP).
MIP generates intra-prediction factors in whole or in part by operations using predefined matrices. When the predictor is partially generated, the MIP may further perform upsampling or interpolation to amplify by partially using the predictor, thereby generating a final intra-predicted sample equal to the size of the current block.
On the other hand, MIP may selectively select some pixels spatially adjacent to the current block and use some of the selected pixels as neighboring pixels of the current block. In another embodiment, MIP may use values derived from operations based on sub-sampling, scaling, etc. for matrix operations.
Fig. 8 illustrates partially generating a predictor of a current block using values derived based on an operation and a matrix smaller than the current block. Hereinafter, an embodiment of MIP is described using the diagram of fig. 8.
First, a certain number of samples are generated from boundary samples of a current block by using an averaging operation. For example, boundary samples by from the top using predefined rules that are used based on block size top And boundary sample by on the left left Generated are their simplified boundary samples bdry top red And addry left red . Furthermore, a simplified boundary sample b top red And addry left red Combining under predefined rules to generate a simplified boundary vector addry red
Then, using the boundary vector bdry applied to the simplification red Is used to generate a simplified predictor pred for a portion of the current block red As shown in fig. 8. Here, pred red Is a block downsampled in size from the current block, having a width W red And height H red . Width W red And height H red May be determined based on the size of the block. Simplified predictor pred red Can be calculated according to equation 2.
Equation 2
pred rea =A k .bdry rea +b k
Wherein A is k Is a predefined matrix with a matrix number equal to W red ·H red As many rows and as by red Columns of the same dimension. On the other hand, b k Is a predefined vector of size W red ·H red Is a dimension of (c). A is that k And b k The subscript k of (a) is an index indicating one of the predefined matrices and vectors.
Finally, linear interpolation is applied to the reduced predictor pred red To generate predicted samples for the remaining locations in the current block. The linear interpolation is performed first in the horizontal direction and then in the vertical direction regardless of the size and shape of the block.
To indicate whether these MIPs are activated, the video encoding device may encode and transmit matrix-based prediction flags to the video decoding device. In addition, the video encoding apparatus may encode and transmit an index indicating one of the predefined matrices and one of the predefined vectors to the video decoding apparatus.
Improved intra prediction
Fig. 9 is a schematic diagram illustrating an intra predictor performing combined intra prediction according to at least one embodiment of the present invention.
The intra predictor 542 according to the present embodiment combines a predictor generated by performing a direction-based prediction and a predictor generated by performing a matrix operation-based prediction corresponding to a rule-based prediction for the current block. The intra predictor 542 includes, in whole or in part, a first intra prediction mode deriver 910, a first intra predictor generator 920, a second intra prediction mode deriver 930, a second intra predictor generator 940, and an intra predictor combiner 950.
The first intra prediction mode deriver 910 derives a first intra prediction mode. Here, the first intra prediction mode may be one of intra prediction modes according to direction-based prediction, as shown in fig. 3 a. The first intra prediction mode derivator 910 may derive the first intra prediction mode by decoding the intra prediction mode transmitted from the video encoding device using the entropy decoder 510 in the video decoding device.
The first intra predictor generator 920 may generate a first intra predictor of the current block using the first intra prediction mode. For example, the first intra predictor generator 920 may generate predicted samples from neighboring pixels of the current block by using a decoded direction-based intra prediction mode.
The second intra prediction mode deriver 930 derives a second intra prediction mode. Here, the second intra prediction mode may be one of the rule-based intra prediction modes, as shown in fig. 7 and 8.
After decoding the matrix-based prediction flag transmitted from the video encoding apparatus by using the entropy decoder 510, the second intra prediction mode derivator 930 may confirm that the matrix-based prediction flag is true, thereby deriving a second intra prediction mode that is an intra prediction mode based on matrix operation.
In another embodiment, the second intra prediction mode derivation 930 may derive the second intra prediction mode, which is an intra prediction mode based on a matrix operation, by decoding an index of a predefined matrix transmitted from the video encoding device using the entropy decoder 510. In this case, the index indicates one of a plurality of predefined matrices and one of a plurality of predefined vectors utilized in the matrix operation based prediction.
In still another embodiment, the second intra prediction mode derivation 930 may derive the second intra prediction mode as the rule-based intra prediction mode after decoding the position-decided prediction flag transmitted from the video encoding device by using the entropy decoder 510 and by confirming that the position-decided prediction flag is true.
The second intra predictor generator 940 may generate a second intra predictor of the current block by using the second intra prediction mode. For example, when the matrix-based prediction flag is true, the second intra predictor generator 940 may generate predicted samples from neighboring pixels of the current block by using the predefined matrix a and the predefined vector b, as shown in fig. 8.
As shown in fig. 10, the intra predictor combiner 950 combines the first intra predictor and the second intra predictor to generate a combined intra predictor of the current block.
After decoding the combined intra-predictor flag transmitted from the video encoding device by using the entropy decoder 510, the intra-predictor combiner 950 may generate a combined intra-predictor when the combined intra-predictor flag is true. In this case, the combined intra predictor flag indicates whether combined intra prediction is enabled.
The intra predictor combiner 950 may use an average value or a weighted average value of each identical pixel position for two predictors when combining a first intra predictor according to the direction-based prediction and a second intra predictor according to the matrix-operation-based prediction. Here, the average value refers to an average value of a pixel s1 corresponding to a first intra-frame predictor of the same pixel position and a pixel s2 corresponding to a second intra-frame predictor of the same pixel position. The weighted average represents the weighted sum of pixel s1 and pixel s2 by applying different pairs of weights to them. Examples of different weight pairs may be, but are not necessarily limited to {1/4,3/4}, {1/8,7/8}, { -1/4,5/4}, { -1/8,9/8}, and the like. Another example may utilize a pair of weights, where the sum of the two weights is 1 and the denominator of each weight is a power of 2.
When combining a first intra-prediction factor according to the direction-based prediction and a second intra-prediction factor according to the matrix operation-based prediction, the intra-prediction factor combiner 950 according to the present embodiment may generate a combined intra-prediction factor by using the same weight as described above.
In another embodiment of the present invention, the intra predictor combiner 950 may refer to prediction modes of the current block and the neighboring block, thereby calculating different weights for each of the first and second intra predictors. In combining the first and second intra prediction factors, the intra prediction factor combiner 950 may apply weights calculated based on prediction mode information of previously decoded neighboring blocks to generate a combined intra prediction factor.
Fig. 11 is a schematic diagram illustrating a current block and its spatially adjacent neighboring blocks in accordance with at least one embodiment of the present invention.
Neighboring blocks refer to one or more previously decoded blocks that are spatially adjacent to the current block, which may be, but are not necessarily limited to, a left block adjacent to the left side of the current block and a top block adjacent to the top of the current block, as shown in fig. 11. Accordingly, the present invention may include embodiments that include additional locations of adjacent blocks, in addition to the example in fig. 11.
As described above, in order to use prediction mode information of neighboring blocks, the intra predictor 542 may obtain prediction modes of blocks corresponding to left and top block positions of the current block.
Here, the prediction modes of the left block and the top block of the current block may be one of a direction-based intra prediction mode and a matrix operation-based intra prediction mode. In addition, the prediction modes of the left block and the top block may be combined intra prediction modes. The combined intra prediction mode represents an intra prediction mode obtained by combining a direction-based prediction and a matrix operation-based prediction.
In addition, the prediction modes of the left block and the top block may represent an intra prediction mode or an inter prediction mode.
In at least one embodiment of the present invention, when both the intra prediction modes of the left block and the top block are direction-based prediction modes, the intra predictor combiner 950 may set the weight of the first intra predictor according to the direction-based prediction to a value greater than the weight of the second intra predictor according to the prediction based on the matrix operation. For example, the intra predictor combiner 950 may set the weight of the first intra predictor to 3/4 and the weight of the second intra predictor to 1/4, and then apply these weights to the first and second intra predictors to generate a combined intra predictor.
In another embodiment, when only one of the intra prediction modes of the left block and the top block is a direction prediction mode, that is, the prediction mode of one of the two blocks is a direction-based intra prediction mode and the prediction mode of the other block is a matrix operation-based intra prediction mode, the intra predictor combiner 950 may set weights of the first intra predictor and the second intra predictor to the same value. For example, the intra predictor combiner 950 may set the weight of the first intra predictor to 1/2 and the weight of the second intra predictor to 1/2, and then apply these weights to the first and second intra predictors to generate a combined intra predictor.
In still another embodiment, when both the intra prediction modes of the left block and the top block are the matrix operation-based prediction modes, the intra predictor combiner 950 may set the weight of the second intra predictor according to the matrix operation-based prediction to a value greater than the weight of the first intra predictor according to the direction-based prediction. For example, the intra predictor combiner 950 may set the weight of the first intra predictor to 1/4 and the weight of the second intra predictor to 3/4, and then apply these weights to the first and second intra predictors to generate a combined intra predictor.
On the other hand, the intra predictor combiner 950 may change a process of setting weights for generating intra predictors from intra prediction modes of neighboring blocks according to slice types. For example, when the current slice type is intra or I slice, the prediction modes of neighboring blocks are all intra prediction modes. However, the current slice type may be a prediction or P slice or bi-prediction or B slice, where intra prediction and inter prediction coexist. In this case, the intra predictor combiner 950 may apply a process for setting weights for the P-slice or the B-slice, which is different from the process for setting weights in the I-slice.
The above may also be performed in the intra predictor 122 of the video encoding device. In optimizing rate distortion, the video encoding apparatus searches for a direction-based intra prediction mode, sets an index of a predefined matrix, and sets a matrix-based prediction flag and a combined intra prediction flag. Thus, the intra predictor 122 may derive the first intra prediction mode by obtaining a direction-based intra prediction mode.
After obtaining the matrix-based prediction flag, intra predictor 122 may direct the second intra prediction mode by acknowledging that the matrix-based prediction flag is true. In another embodiment, the intra predictor 122 may derive the second intra prediction mode by obtaining an index of a predefined matrix. In this case, the index indicates one of a plurality of predefined matrices and one of a plurality of predefined vectors utilized in the matrix operation based prediction.
After obtaining the combined intra prediction flag, when the combined intra prediction flag is true, the intra predictor 122 may combine the first intra predictor and the second intra predictor to generate a combined intra predictor of the current block.
The video encoding device may encode the optimized direction-based intra prediction mode, the matrix-based prediction flag, the index of the predefined matrix, and the combined intra prediction flag, and transmit them to the video decoding device.
A method for generating a combined intra predictor of a current block, which is performed by a video decoding apparatus when the combined intra predictor flag is decoded for the first time, is described below using an example of fig. 12. Here, the combined intra-predictor flag indicates whether a combination between the direction-based intra-predictor and the matrix operation-based intra-predictor is enabled.
Fig. 12 is a flowchart of a method performed by a video decoding apparatus for generating a combined intra predictor in accordance with at least one embodiment of the present invention.
The entropy decoder 510 in the video decoding apparatus decodes the combined intra prediction flag from the bitstream (S1200).
The intra predictor 542 in the video decoding device checks the combined intra prediction flag to determine whether the combined intra prediction is enabled (S1202).
When the combined intra prediction flag is true and the combined intra prediction is enabled, the video decoding apparatus performs the following steps (steps S1204 to S1212).
The entropy decoder 510 decodes a direction-based intra prediction mode of the current block from the bitstream (S1204). By decoding the direction-based intra prediction mode, the direction-based prediction may be set as the intra prediction mode of the current block.
The intra predictor 542 generates a first intra predictor of the current block by using the direction-based intra prediction mode (S1206).
The entropy decoder 510 decodes an index of a predefined matrix from the bitstream (S1208). The matrix operation-based prediction, which is one of the rule-based prediction methods, may be set as an intra prediction mode of the current block by decoding an index indicating one of a plurality of predefined matrices utilized in the matrix operation-based prediction.
The intra predictor 542 generates a second intra predictor of the current block by using a predefined matrix indicated by the index (S1210).
The foregoing describes, but is not necessarily limited to, the case of generating the second intra predictor of the current block using matrix-based computation of predictions. In other embodiments, other rule-based prediction methods (e.g., PDPC) may be used to generate the second intra predictor for the current block. For example, the video decoding apparatus may decode the position-decided prediction flag, and generate the second intra prediction factor using the position-decided prediction if the position-decided prediction flag is true. Here, the prediction flag of the position decision indicates whether or not the prediction of the position decision is enabled.
The intra predictor 542 may generate a second intra predictor before the first intra predictor. Alternatively, the intra predictor 542 may generate the first intra predictor and the second intra predictor in parallel.
The intra predictor 542 combines the first and second intra predictors to generate a combined intra predictor of the current block (S1212).
When combining a first intra-prediction factor according to the direction-based prediction and a second intra-prediction factor according to the matrix-operation-based prediction, the intra-predictor 542 may utilize an average or a weighted average of each identical pixel position for the two prediction factors.
Here, the average value represents an average value of pixels corresponding to the first intra-prediction factor and pixels corresponding to the second intra-prediction factor for the same pixel position. The weighted average represents a weighted sum of pixels corresponding to the first intra-predictor after applying a particular weight pair and pixels corresponding to the second intra-predictor after applying a different weight pair. Examples of different weight pairs may be, but are not necessarily limited to {1/4,3/4}, {1/8,7/8}, { -1/4,5/4}, { -1/8,9/8}, and the like. As another example, a pair of weights may be utilized, where the sum of the two weights is 1 and the denominator of each weight is a power of 2.
On the other hand, when the combined intra prediction flag is false (meaning that the combined intra prediction is not enabled), the video decoding apparatus performs the following steps (steps S1220 to S1230).
The entropy decoder 510 decodes the matrix-based prediction flag from the bitstream (S1220). Here, the matrix-based prediction flag indicates whether the matrix-operation-based prediction is enabled or disabled.
The intra predictor 542 checks a matrix-based prediction flag to determine whether matrix-based prediction is enabled (S1222).
When the matrix-based prediction flag is true and matrix-based prediction is enabled, the entropy decoder 510 decodes an index of a predefined matrix from the bitstream (S1224), and the intra predictor 542 generates an intra predictor of the current block using the predefined matrix indicated by the index (S1226).
On the other hand, when the matrix-based prediction flag is false (meaning matrix-based prediction is not enabled), the entropy decoder 510 decodes a direction-based intra prediction mode of the current block from the bitstream (S1228), and the intra predictor 542 generates an intra predictor of the current block using the direction-based intra prediction mode (S1230).
As described above, the method of generating the combined intra predictor may also be performed by the intra predictor 122 in the video encoding apparatus. In addition to this, the video encoding apparatus may first obtain a combined intra prediction flag, a direction-based intra prediction mode, a matrix-based prediction flag, and an index of a predefined matrix set during the rate-distortion optimization process, and generate a combined intra predictor of the current block using them.
A method for generating a combined intra predictor of a current block, which is performed by a video decoding apparatus when a matrix-based prediction flag is first decoded, is described below using the diagram of fig. 13. Here, the matrix-based prediction flag indicates whether matrix-operation-based prediction is enabled.
Fig. 13 is a flowchart of a method for generating a combined intra prediction factor performed by a video decoding apparatus according to another embodiment of the present invention.
The entropy decoder 510 in the video decoding apparatus decodes the matrix-based prediction flag from the bitstream (S1300).
The intra predictor 542 in the video decoding device checks a matrix-based prediction flag to determine whether matrix-based prediction is enabled (S1302).
The foregoing assumes, but is not necessarily limited to, the case where a matrix operation-based prediction is used to generate a second intra predictor for the current block. In other embodiments, other rule-based prediction methods (e.g., PDPC) may be used to generate the second intra predictor for the current block. For example, the video decoding apparatus may decode the position-decided prediction flag and then generate the second intra prediction factor using the position-decided prediction. Here, the prediction flag of the position decision indicates whether or not the prediction of the position decision is enabled.
When the matrix-based prediction flag is false (meaning matrix-based prediction is not enabled), the video decoding apparatus performs the following steps (steps S1304 to S1316).
The entropy decoder 510 decodes a direction-based intra prediction mode of the current block from the bitstream (S1304). By decoding the direction-based intra prediction mode, the direction-based prediction may be set as the intra prediction mode of the current block.
The intra predictor 542 generates a first intra predictor of the current block using the direction-based intra prediction mode (S1306).
The entropy decoder 510 decodes the combined intra prediction flag from the bitstream (S1308). Here, the combined intra prediction flag indicates whether or not a combination is enabled between the direction-based intra prediction and the matrix operation-based intra prediction.
The intra predictor 542 checks the combined intra prediction flag to determine whether combined intra prediction is enabled (S1310).
When the combined intra prediction flag is true and the combined intra prediction is enabled, the video decoding apparatus performs the following steps (steps S1312 to S1316).
The entropy decoder 510 decodes an index of a predefined matrix from the bitstream (S1312). The matrix operation-based prediction, which is one of the rule-based prediction methods, may be set as an intra prediction mode of the current block by decoding an index indicating one of a plurality of predefined matrices utilized in the matrix operation-based prediction.
The intra predictor 542 generates a second intra predictor of the current block using a predefined matrix indicated by the index (S1314).
The intra predictor 542 combines the first and second intra predictors to generate a combined intra predictor of the current block (S1316).
When combining a first intra-prediction factor according to the direction-based prediction and a second intra-prediction factor according to the matrix-operation-based prediction, the intra-predictor 542 may utilize an average or a weighted average of each identical pixel position for the two prediction factors.
Here, the average value represents an average value of pixels corresponding to the first intra-prediction factor and pixels corresponding to the second intra-prediction factor for the same pixel position. The weighted average represents a weighted sum of pixels corresponding to the first intra predictor and pixels corresponding to the second intra predictor by applying different weights to the pixels. Examples of different weight pairs may be, but are not necessarily limited to {1/4,3/4}, {1/8,7/8}, { -1/4,5/4}, { -1/8,9/8}, and the like. Another example may utilize a pair of weights, where the sum of the two weights is 1 and the denominator of each weight is a power of 2.
When the combined intra prediction flag is false (meaning that the combined intra prediction is not enabled), the intra predictor 542 sets the first intra predictor to the intra predictor of the current block.
On the other hand, when the matrix-based prediction flag is true and matrix-based prediction is enabled, the entropy decoder 510 decodes an index of a predefined matrix from the bitstream (S1320), and the intra predictor 542 generates an intra predictor of the current block using the predefined matrix indicated by the index (S1322).
As described above, the method of generating the combined intra predictor may also be performed by the intra predictor 122 in the video encoding apparatus. The video encoding apparatus may obtain the combined intra prediction flag, the direction-based intra prediction mode, the matrix-based prediction flag, and the index of the predefined matrix set during the bit rate distortion optimization process, and generate the combined intra prediction factor of the current block using them.
Although steps in the respective flowcharts are described as sequentially performed, these steps merely exemplify the technical ideas of some embodiments of the present invention. Accordingly, one of ordinary skill in the art to which the invention pertains may perform the steps by changing the order depicted in the various figures or by performing two or more steps in parallel. Accordingly, the steps in the various flowcharts are not limited to the order in which they occur as shown.
It should be understood that the foregoing description presents illustrative embodiments that may be implemented in various other ways. The functions described in some embodiments may be implemented by hardware, software, firmware, and/or combinations thereof. It should also be understood that, the functions described in this specification the components are labeled "....once again, to highlight the possibility of their independent implementation.
On the other hand, the various methods or functions described in some embodiments may be implemented as instructions stored in a non-volatile recording medium, which may be read and executed by one or more processors. The nonvolatile recording medium may include various types of recording devices that store data in a form readable by a computer system, for example. For example, the nonvolatile recording medium may include a storage medium such as an erasable programmable read-only memory (EPROM), a flash memory drive, an optical disk drive, a magnetic hard disk drive, a Solid State Drive (SSD), and the like.
Although exemplary embodiments of the present invention have been described for illustrative purposes, those skilled in the art to which the present invention pertains will appreciate that various modifications, additions and substitutions are possible, without departing from the scope and spirit of the invention. Accordingly, embodiments of the present invention have been described for brevity and clarity. The scope of the technical idea of the embodiment of the invention is not limited by the illustration. Accordingly, it will be understood by those of ordinary skill in the art that the scope of the present invention is not limited by the embodiments explicitly described above, but is limited by the claims and their equivalents.
(description of the reference numerals)
122: intra-frame predictor
510: entropy decoder
542: intra-frame predictor
910: first intra prediction mode deriver
920: first intra predictor generator
930: second intra prediction mode deriver
940: second intra predictor generator
950: an intra predictor combiner.
Cross Reference to Related Applications
The present application claims priority from korean patent application No.10-2020-0165720, filed on 1-12-2020, and korean patent application No.10-2021-0169663, filed on 1-12-2021, the entire contents of which are incorporated herein by reference.

Claims (17)

1. An intra-prediction method performed by a video decoding device, the method comprising:
decoding a combined intra-prediction flag from a bitstream, the combined intra-prediction flag indicating that a combination between direction-based intra-prediction and matrix-operation-based intra-prediction is enabled;
performing intra prediction of the current block according to the combined intra prediction flag;
wherein when the combined intra-prediction flag is true, performing intra-prediction includes:
decoding a direction-based intra prediction mode of a current block from a bitstream;
generating a first intra predictor of the current block by using the direction-based intra prediction mode;
Decoding an index from the bitstream indicating one of a plurality of predefined matrices utilized in matrix operation-based intra prediction;
generating a second intra predictor of the current block by using a predefined matrix indicated by the index; and
the combined intra-predictor of the current block is generated by combining the first intra-predictor and the second intra-predictor.
2. The method of claim 1, wherein generating a first intra-prediction factor comprises: a first intra-prediction factor is generated from neighboring pixels of the current block by using the first intra-prediction mode.
3. The method of claim 1, wherein generating a second intra-prediction factor comprises: a second intra-prediction factor is generated from neighboring pixels of the current block by using a predefined matrix.
4. The method of claim 1, wherein generating the combined intra-prediction factor comprises: the average or weighted average of each identical pixel location is utilized for the first intra predictor and the second intra predictor.
5. The method of claim 1, wherein generating the combined intra-prediction factor comprises: the weights are applied to the same pixel positions of the first and second intra predictors by calculating the weights based on prediction mode information of a previously decoded neighboring block adjacent to the current block.
6. The method of claim 5, wherein generating the combined intra-prediction factor comprises: one or more left blocks located to the left of the current block and one or more top blocks located at the top of the current block are utilized as neighboring blocks.
7. The method of claim 6, wherein generating the combined intra-prediction factor comprises:
it is determined whether only one of the intra prediction mode of the left block and the intra prediction mode of the top block is a direction-based prediction mode, and if so, the weight of the first intra predictor is set equal to the weight of the second intra predictor.
8. The method of claim 6, wherein generating the combined intra-prediction factor comprises:
determining whether both the intra prediction mode of the left block and the intra prediction mode of the top block are direction-based prediction modes, and if so, setting the weight of the first intra predictor to be greater than the weight of the second intra predictor, and when both the intra prediction mode of the left block and the intra prediction mode of the top block are matrix operation-based prediction modes, setting the weight of the second intra predictor to be greater than the weight of the first intra predictor.
9. The method of claim 1, wherein performing intra prediction when the combined intra prediction flag is false comprises:
decoding a matrix-based prediction flag from a bitstream, the matrix-based prediction flag indicating whether matrix operation-based intra prediction is enabled;
deriving an intra prediction mode of the current block according to the matrix-based prediction flag; and
a third intra predictor of the current block is generated by using the intra prediction mode.
10. The method of claim 9, wherein deriving an intra-prediction mode comprises:
when the matrix-based prediction flag is true, an index indicating a predefined matrix is decoded from the bitstream, and when the matrix-based prediction flag is false, a direction-based intra prediction mode of the current block is decoded from the bitstream.
11. The method of claim 10, wherein generating a third intra-prediction factor comprises:
the intra predictor of the current block is generated by using a predefined matrix indicated by the index when the matrix-based prediction flag is true, and is generated by using a direction-based intra prediction mode when the matrix-based prediction flag is false.
12. A video decoding device for generating a combined intra-prediction factor for a current block, the device comprising:
an entropy decoder configured to decode a combined intra-prediction flag from the bitstream, the combined intra-prediction flag indicating that a combination between direction-based intra-prediction and matrix-operation-based intra-prediction is enabled; and
an intra predictor configured to perform intra prediction of the current block according to the combined intra prediction flag,
wherein when the combined intra prediction flag is true, the entropy decoder is configured to decode from the bitstream a direction-based intra prediction mode of the current block and an index indicating one of a plurality of predefined matrices utilized in matrix operation-based intra prediction, and
wherein when the combined intra prediction flag is true, the intra predictor is configured to generate a first intra predictor of the current block by using the direction-based intra prediction mode, generate a second intra predictor of the current block by using a predefined matrix indicated by the index, and generate a combined intra predictor of the current block by combining the first intra predictor and the second intra predictor.
13. The apparatus of claim 12, wherein the intra predictor is configured to generate the combined intra predictor by using an average or a weighted average of each same pixel location for the first intra predictor and the second intra predictor.
14. The apparatus of claim 12, the intra predictor configured to apply the weights to the same pixel locations of the first intra predictor and the second intra predictor by calculating the weights based on prediction mode information of a previously decoded neighboring block that is adjacent to the current block.
15. An intra-prediction method performed by a video encoding device, the method comprising:
obtaining a combined intra-prediction flag indicating that a combination between direction-based intra-prediction and matrix-operation-based intra-prediction is enabled; and
performing intra prediction of the current block according to the combined intra prediction flag;
wherein when the combined intra-prediction flag is true, performing intra-prediction includes:
obtaining a direction-based intra prediction mode of a current block;
generating a first intra predictor of the current block by using the direction-based intra prediction mode;
Obtaining an index indicating one of a plurality of predefined matrices utilized in matrix operation based intra prediction;
generating a second intra predictor of the current block by using a predefined matrix indicated by the index, and
the combined intra-predictor of the current block is generated by combining the first intra-predictor and the second intra-predictor.
16. The method of claim 15, wherein generating a combined intra-prediction factor comprises: an average or weighted average of each identical position of the first intra-frame predictor and the second intra-frame predictor is utilized.
17. The method of claim 15, wherein generating a combined intra-prediction factor comprises: the weights are applied to the same pixel positions of the first and second intra predictors by calculating the weights based on prediction mode information of a previously decoded neighboring block adjacent to the current block.
CN202180080513.6A 2020-12-01 2021-12-01 Method and apparatus for video coding using intra prediction Pending CN116530082A (en)

Applications Claiming Priority (3)

Application Number Priority Date Filing Date Title
KR20200165720 2020-12-01
KR10-2020-0165720 2020-12-01
PCT/KR2021/017965 WO2022119301A1 (en) 2020-12-01 2021-12-01 Method and device for video coding using intra prediction

Publications (1)

Publication Number Publication Date
CN116530082A true CN116530082A (en) 2023-08-01

Family

ID=81981458

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202180080513.6A Pending CN116530082A (en) 2020-12-01 2021-12-01 Method and apparatus for video coding using intra prediction

Country Status (2)

Country Link
KR (1) KR20220077095A (en)
CN (1) CN116530082A (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2024053987A1 (en) * 2022-09-06 2024-03-14 주식회사 윌러스표준기술연구소 Video signal processing method using geometric division, and device therefor
WO2024080852A1 (en) * 2022-10-14 2024-04-18 한국전자통신연구원 Image encoding/decoding method and apparatus, and recording medium for storing bitstream
WO2024151023A1 (en) * 2023-01-09 2024-07-18 엘지전자 주식회사 Image encoding/decoding method based on intra prediction, method for transmitting bitstream, and recording medium storing bitstream

Also Published As

Publication number Publication date
KR20220077095A (en) 2022-06-08

Similar Documents

Publication Publication Date Title
CN113812147B (en) Image encoding and decoding using intra-block copy
CN116530082A (en) Method and apparatus for video coding using intra prediction
CN116472709A (en) Apparatus and method for video encoding and decoding
US20230396795A1 (en) Inter prediction-based video encoding and decoding
US20230300325A1 (en) Video coding method and apparatus using intra prediction
CN116941241A (en) Video encoding and decoding method and apparatus using matrix-based cross component prediction
CN116636211A (en) Method and apparatus for encoding video using block merging
CN116530084A (en) Video codec using block-based deep learning model
US20230283768A1 (en) Method for predicting quantization parameter used in a video encoding/decoding apparatus
CN118140476A (en) Method and apparatus for video encoding and decoding using geometric intra prediction modes
CN116711312A (en) Image encoding and decoding method for adaptively determining intra-chroma direction prediction mode
CN118251891A (en) Method and apparatus for video coding and decoding using template matching-based intra prediction
CN117044200A (en) Method and apparatus for video encoding and decoding using spiral scan order
CN118489244A (en) Method and apparatus for video encoding and decoding using improved AMVP-MERGE mode
CN118369914A (en) Method and apparatus for video encoding and decoding using template matching based secondary MPM list
CN117581534A (en) Video encoding/decoding method and apparatus
CN116918323A (en) Video encoding and decoding method and apparatus for improving prediction signal of intra prediction
CN116472710A (en) Method and apparatus for generating residual signal using reference between components
CN117917071A (en) Method and apparatus for video coding using sub-block coding order change and intra prediction according to sub-block coding order change
CN117063466A (en) Video encoding method and apparatus using adaptive intra prediction precision
CN116648907A (en) Block partitioning structure for efficient prediction and transformation, and method and apparatus for video encoding and decoding using the same
CN118451706A (en) Template-based intra mode derivation method for chrominance components
CN117044197A (en) Method and apparatus for video encoding and decoding using derived intra prediction modes
CN118160304A (en) Video encoding method and apparatus using various block division structures
CN117917073A (en) Video encoding/decoding method and apparatus

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination