Method, apparatus, and medium for video processing
By using decoder-side intra mode derivation schemes and planar modes to determine a transform kernel, the method enhances video coding quality and efficiency in existing video coding technologies.
Patent Information
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- DOUYIN VISION CO LTD
- Filing Date
- 2025-12-30
- Publication Date
- 2026-07-09
AI Technical Summary
Existing video coding technologies, such as MPEG-2, AVC, HEVC, and VVC, require improvements in coding quality to enhance efficiency and performance.
A method for video processing that determines a transform kernel based on decoder-side intra mode derivation (DIMD) schemes, planar modes, or a combination of both, to optimize the transform kernel derivation process.
The proposed method improves coding quality by optimizing the transform kernel derivation process, leading to enhanced video coding efficiency.
Smart Images

Figure CN2025147263_09072026_PF_FP_ABST
Abstract
Description
METHOD, APPARATUS, AND MEDIUM FOR VIDEO PROCESSINGFIELDS
[0001] Embodiments of the present disclosure relates generally to video processing techniques, and more particularly, to video coding.BACKGROUND
[0002] In nowadays, digital video capabilities are being applied in various aspects of peoples’ lives. Multiple types of video compression technologies, such as motion picture expert group (MPEG) -2, MPEG-4, international telecommunication union -telecommunication standardization sector (ITU-T) H. 263, ITU-T H. 264 / MPEG-4 Part 10 advanced video coding (AVC) , ITU-T H. 265 high efficiency video coding (HEVC) standard, versatile video coding (VVC) standard, have been proposed for video encoding / decoding. However, coding quality of video coding techniques is generally expected to be further improved.SUMMARY
[0003] Embodiments of the present disclosure provide a solution for video processing.
[0004] In a first aspect, a method for video processing is proposed. The method comprises: determining, for a conversion between a current video block of a video and a bitstream of the video, a transform kernel for the current video block based on at least one of the following: a first intra mode derived based on a decoder side intra mode derivation (DIMD) scheme, a second intra mode derived based on the DIMD scheme, or a planar mode; and performing the conversion based on the transform kernel.
[0005] Based on the method in accordance with the first aspect of the present disclosure, a transform kernel is determined based on a first intra mode and / or a second intra mode derived based on DIMD and / or a planar mode. Compared with the conventional solution, the proposed method can advantageously optimize the process of transform kernel derivation, thereby improving coding quality.
[0006] In a second aspect, an apparatus for video processing is proposed. The apparatus comprises a processor and a non-transitory memory with instructions thereon. The instructions upon execution by the processor, cause the processor to perform a method in accordance with the first aspect of the present disclosure.
[0007] In a third aspect, a non-transitory computer-readable storage medium is proposed. The non-transitory computer-readable storage medium stores instructions that cause a processor to perform a method in accordance with the first aspect of the present disclosure.
[0008] In a fourth aspect, another non-transitory computer-readable recording medium is proposed. The non-transitory computer-readable recording medium stores a bitstream of a video which is generated by a method performed by an apparatus for video processing. The method comprises: determining a transform kernel for a current video of the video based on at least one of the following: a first intra mode derived based on a decoder side intra mode derivation (DIMD) scheme, a second intra mode derived based on the DIMD scheme, or a planar mode; and generating the bitstream based on the transform kernel.
[0009] In a fifth aspect, a method for storing a bitstream of a video is proposed. The method comprises: determining a transform kernel for a current video of the video based on at least one of the following: a first intra mode derived based on a decoder side intra mode derivation (DIMD) scheme, a second intra mode derived based on the DIMD scheme, or a planar mode; generating the bitstream based on the transform kernel; and storing the bitstream in a non-transitory computer-readable recording medium.
[0010] This Summary is provided to introduce a selection of concepts in a simplified form that are further described below in the Detailed Description. This Summary is not intended to identify key features or essential features of the claimed subject matter, nor is it intended to be used to limit the scope of the claimed subject matter.BRIEF DESCRIPTION OF THE DRAWINGS
[0011] Through the following detailed description with reference to the accompanying drawings, the above and other objectives, features, and advantages of example embodiments of the present disclosure will become more apparent. In the example embodiments of the present disclosure, the same reference numerals usually refer to the same components.
[0012] FIG. 1 illustrates a block diagram of an example video coding system in accordance with some embodiments of the present disclosure;
[0013] FIG. 2 illustrates a block diagram of an example video encoder in accordance with some embodiments of the present disclosure;
[0014] FIG. 3 illustrates a block diagram of an example video decoder in accordance with some embodiments of the present disclosure;
[0015] FIG. 4 illustrates the effect of the slope adjustment parameter “u” ;
[0016] FIG. 5 illustrates neighbouring blocks (L, A, BL, AR, AL) used in the derivation of a general MPM list;
[0017] FIG. 6 illustrates non-adjacent spatial neighboring candidates for OBIC mode;
[0018] FIG. 7 illustrates neighboring reconstructed samples used for DIMD chroma mode;
[0019] FIG. 8 illustrates modified search range for LIC;
[0020] FIG. 9 illustrates intra template matching search area used;
[0021] FIG. 10 illustrates an example of IntraTMP-AR-BVP’s construction;
[0022] FIG. 11 illustrates five positions in reference block;
[0023] FIG. 12 illustrates use of IntraTMP block vector for IBC block ;
[0024] FIG. 13A and 13B illustrate the division method for angular modes;
[0025] FIG. 14 illustrates an extended MRL candidate list;
[0026] FIG. 15 illustrates an illustration of a template area;
[0027] FIG. 16 illustrates spatial part of the convolutional filter;
[0028] FIG. 17 illustrates a reference area (with its paddings) used to derive the filter coefficients;
[0029] FIG. 18 illustrates four Sobel based gradient patterns for GLM;
[0030] FIG. 19 illustrates non-downsampled luma samples;
[0031] FIG. 20 illustrates a reference area for BVG-CCCM;
[0032] FIG. 21 illustrates spatial samples used for GL-CCCM;
[0033] FIG. 22 illustrates various downsampling filters used in cross-component models;
[0034] FIG. 23 illustrates N reference samples to predict a given W × H luma CB;
[0035] FIG. 24 illustrates 4x4 (N = 80) and 8x4 (N = 112) models are sequential matrix multiplications and LeakyReLUs (piecewise-linear functions) ;
[0036] FIG. 25 illustrates 16x4 (N = 176) , 8x8 (N = 320) , and 16x8 (N = 448) models are sequential matrix multiplications and LeakyReLUs (piecewise-linear functions) ;
[0037] FIG. 26 illustrates 16x16 model is sequential matrix multiplications and LeakyReLUs (piecewise-linear functions) ;
[0038] FIG. 27 illustrates filter on samples of MM-CCLM / MM-CCCM;
[0039] FIG. 28 illustrates the template adjacent to the current chroma CU;
[0040] FIG. 29 illustrates spatial GPM candidates.
[0041] FIG. 30 illustrates an GPM template;
[0042] FIG. 31 illustrates an GPM blending;
[0043] FIG. 32 illustrates a transform selection process for directional planar modes ;
[0044] FIG. 33 illustrates luma blocks used to derive direct block vector;
[0045] FIG. 34 illustrates three EIP filter shapes;
[0046] FIG. 35 illustrates three types of reconstructed area for EIP filter;
[0047] FIG. 36 illustrates L shaped neighborhood for a given predicted block;
[0048] FIG. 37 illustrates the collocated luma block and adjacent chroma block;
[0049] FIG. 38 illustrates the InterCCCM method on the decoder;
[0050] FIG. 39 illustrates luma samples L0, . ., L5 in relation to the chroma sample C;
[0051] FIG. 40 illustrates reference area for BVG-CCCM;
[0052] FIG. 41 illustrates spatial part of the convolutional filter;
[0053] FIG. 42 illustrates locations used for block vector derivation from co-located luma block;
[0054] FIG. 43 illustrates a flowchart of a method for video processing in accordance with some embodiments of the present disclosure; and
[0055] FIG. 44 illustrates a block diagram of a computing device in which various embodiments of the present disclosure can be implemented.
[0056] Throughout the drawings, the same or similar reference numerals usually refer to the same or similar elements.DETAILED DESCRIPTION
[0057] Principle of the present disclosure will now be described with reference to some embodiments. It is to be understood that these embodiments are described only for the purpose of illustration and help those skilled in the art to understand and implement the present disclosure, without suggesting any limitation as to the scope of the disclosure. The disclosure described herein can be implemented in various manners other than the ones described below.
[0058] In the following description and claims, unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skills in the art to which this disclosure belongs.
[0059] References in the present disclosure to “one embodiment, ” “an embodiment, ” “an example embodiment, ” and the like indicate that the embodiment described may include a particular feature, structure, or characteristic, but it is not necessary that every embodiment includes the particular feature, structure, or characteristic. Moreover, such phrases are not necessarily referring to the same embodiment. Further, when a particular feature, structure, or characteristic is described in connection with an example embodiment, it is submitted that it is within the knowledge of one skilled in the art to affect such feature, structure, or characteristic in connection with other embodiments whether or not explicitly described.
[0060] It shall be understood that although the terms “first” and “second” etc. may be used herein to describe various elements, these elements should not be limited by these terms. These terms are only used to distinguish one element from another. For example, a first element could be termed a second element, and similarly, a second element could be termed a first element, without departing from the scope of example embodiments. As used herein, the term “and / or” includes any and all combinations of one or more of the listed terms.
[0061] The terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of example embodiments. As used herein, the singular forms “a” , “an” and “the” are intended to include the plural forms as well, unless the context clearly indicates otherwise. It will be further understood that the terms “comprises” , “comprising” , “has” , “having” , “includes” and / or “including” , when used herein, specify the presence of stated features, elements, and / or components etc., but do not preclude the presence or addition of one or more other features, elements, components and / or combinations thereof. Example Environment
[0062] FIG. 1 is a block diagram that illustrates an example video coding system 100 that may utilize the techniques of this disclosure. As shown, the video coding system 100 may include a source device 110 and a destination device 120. The source device 110 can be also referred to as a video encoding device, and the destination device 120 can be also referred to as a video decoding device. In operation, the source device 110 can be configured to generate encoded video data and the destination device 120 can be configured to decode the encoded video data generated by the source device 110. The source device 110 may include a video source 112, a video encoder 114, and an input / output (I / O) interface 116.
[0063] The video source 112 may include a source such as a video capture device. Examples of the video capture device include, but are not limited to, an interface to receive video data from a video content provider, a computer graphics system for generating video data, and / or a combination thereof.
[0064] The video data may comprise one or more pictures. The video encoder 114 encodes the video data from the video source 112 to generate a bitstream. The bitstream may include a sequence of bits that form a coded representation of the video data. The bitstream may include coded pictures and associated data. The coded picture is a coded representation of a picture. The associated data may include sequence parameter sets, picture parameter sets, and other syntax structures. The I / O interface 116 may include a modulator / demodulator and / or a transmitter. The encoded video data may be transmitted directly to destination device 120 via the I / O interface 116 through the network 130A. The encoded video data may also be stored onto a storage medium / server 130B for access by destination device 120.
[0065] The destination device 120 may include an I / O interface 126, a video decoder 124, and a display device 122. The I / O interface 126 may include a receiver and / or a modem. The I / O interface 126 may acquire encoded video data from the source device 110 or the storage medium / server 130B. The video decoder 124 may decode the encoded video data. The display device 122 may display the decoded video data to a user. The display device 122 may be integrated with the destination device 120, or may be external to the destination device 120 which is configured to interface with an external display device.
[0066] The video encoder 114 and the video decoder 124 may operate according to a video compression standard, such as the High Efficiency Video Coding (HEVC) standard, Versatile Video Coding (VVC) standard and other current and / or further standards.
[0067] FIG. 2 is a block diagram illustrating an example of a video encoder 200, which may be an example of the video encoder 114 in the system 100 illustrated in FIG. 1, in accordance with some embodiments of the present disclosure.
[0068] The video encoder 200 may be configured to implement any or all of the techniques of this disclosure. In the example of FIG. 2, the video encoder 200 includes a plurality of functional components. The techniques described in this disclosure may be shared among the various components of the video encoder 200. In some examples, a processor may be configured to perform any or all of the techniques described in this disclosure.
[0069] In some embodiments, the video encoder 200 may include a partition unit 201, a prediction unit 202 which may include a mode select unit 203, a motion estimation unit 204, a motion compensation unit 205 and an intra-prediction unit 206, a residual generation unit 207, a transform unit 208, a quantization unit 209, an inverse quantization unit 210, an inverse transform unit 211, a reconstruction unit 212, a buffer 213, and an entropy encoding unit 214.
[0070] In other examples, the video encoder 200 may include more, fewer, or different functional components. In an example, the prediction unit 202 may include an intra block copy (IBC) unit. The IBC unit may perform prediction in an IBC mode in which at least one reference picture is a picture where the current video block is located.
[0071] Furthermore, although some components, such as the motion estimation unit 204 and the motion compensation unit 205, may be integrated, but are represented in the example of FIG. 2 separately for purposes of explanation.
[0072] The partition unit 201 may partition a picture into one or more video blocks. The video encoder 200 and the video decoder 300 may support various video block sizes.
[0073] The mode select unit 203 may select one of the coding modes, intra or inter, e.g., based on error results, and provide the resulting intra-coded or inter-coded block to a residual generation unit 207 to generate residual block data and to a reconstruction unit 212 to reconstruct the encoded block for use as a reference picture. In some examples, the mode select unit 203 may select a combined inter and intra prediction (CIIP) mode in which the prediction is based on an inter prediction signal and an intra prediction signal. The mode select unit 203 may also select a resolution for a motion vector (e.g., a sub-pixel or integer pixel precision) for the block in the case of inter-prediction.
[0074] To perform inter prediction on a current video block, the motion estimation unit 204 may generate motion information for the current video block by comparing one or more reference frames from buffer 213 to the current video block. The motion compensation unit 205 may determine a predicted video block for the current video block based on the motion information and decoded samples of pictures from the buffer 213 other than the picture associated with the current video block.
[0075] The motion estimation unit 204 and the motion compensation unit 205 may perform different operations for a current video block, for example, depending on whether the current video block is in an I-slice, a P-slice, or a B-slice. As used herein, an “I-slice” may refer to a portion of a picture composed of macroblocks, all of which are based upon macroblocks within the same picture. Further, as used herein, in some aspects, “P-slices” and “B-slices” may refer to portions of a picture composed of macroblocks that are not dependent on macroblocks in the same picture.
[0076] In some examples, the motion estimation unit 204 may perform uni-directional prediction for the current video block, and the motion estimation unit 204 may search reference pictures of list 0 or list 1 for a reference video block for the current video block. The motion estimation unit 204 may then generate a reference index that indicates the reference picture in list 0 or list 1 that contains the reference video block and a motion vector that indicates a spatial displacement between the current video block and the reference video block. The motion estimation unit 204 may output the reference index, a prediction direction indicator, and the motion vector as the motion information of the current video block. The motion compensation unit 205 may generate the predicted video block of the current video block based on the reference video block indicated by the motion information of the current video block.
[0077] Alternatively, in other examples, the motion estimation unit 204 may perform bi-directional prediction for the current video block. The motion estimation unit 204 may search the reference pictures in list 0 for a reference video block for the current video block and may also search the reference pictures in list 1 for another reference video block for the current video block. The motion estimation unit 204 may then generate reference indexes that indicate the reference pictures in list 0 and list 1 containing the reference video blocks and motion vectors that indicate spatial displacements between the reference video blocks and the current video block. The motion estimation unit 204 may output the reference indexes and the motion vectors of the current video block as the motion information of the current video block. The motion compensation unit 205 may generate the predicted video block of the current video block based on the reference video blocks indicated by the motion information of the current video block.
[0078] In some examples, the motion estimation unit 204 may output a full set of motion information for decoding processing of a decoder. Alternatively, in some embodiments, the motion estimation unit 204 may signal the motion information of the current video block with reference to the motion information of another video block. For example, the motion estimation unit 204 may determine that the motion information of the current video block is sufficiently similar to the motion information of a neighboring video block.
[0079] In one example, the motion estimation unit 204 may indicate, in a syntax structure associated with the current video block, a value that indicates to the video decoder 300 that the current video block has the same motion information as the another video block.
[0080] In another example, the motion estimation unit 204 may identify, in a syntax structure associated with the current video block, another video block and a motion vector difference (MVD) . The motion vector difference indicates a difference between the motion vector of the current video block and the motion vector of the indicated video block. The video decoder 300 may use the motion vector of the indicated video block and the motion vector difference to determine the motion vector of the current video block.
[0081] As discussed above, video encoder 200 may predictively signal the motion vector. Two examples of predictive signaling techniques that may be implemented by video encoder 200 include advanced motion vector prediction (AMVP) and merge mode signaling.
[0082] The intra prediction unit 206 may perform intra prediction on the current video block. When the intra prediction unit 206 performs intra prediction on the current video block, the intra prediction unit 206 may generate prediction data for the current video block based on decoded samples of other video blocks in the same picture. The prediction data for the current video block may include a predicted video block and various syntax elements.
[0083] The residual generation unit 207 may generate residual data for the current video block by subtracting (e.g., indicated by the minus sign) the predicted video block (s) of the current video block from the current video block. The residual data of the current video block may include residual video blocks that correspond to different sample components of the samples in the current video block.
[0084] In other examples, there may be no residual data for the current video block, for example in a skip mode, and the residual generation unit 207 may not perform the subtracting operation.
[0085] The transform unit 208 may generate one or more transform coefficient video blocks for the current video block by applying one or more transforms to a residual video block associated with the current video block.
[0086] After the transform unit 208 generates a transform coefficient video block associated with the current video block, the quantization unit 209 may quantize the transform coefficient video block associated with the current video block based on one or more quantization parameter (QP) values associated with the current video block.
[0087] The inverse quantization unit 210 and the inverse transform unit 211 may apply inverse quantization and inverse transforms to the transform coefficient video block, respectively, to reconstruct a residual video block from the transform coefficient video block. The reconstruction unit 212 may add the reconstructed residual video block to corresponding samples from one or more predicted video blocks generated by the prediction unit 202 to produce a reconstructed video block associated with the current video block for storage in the buffer 213.
[0088] After the reconstruction unit 212 reconstructs the video block, loop filtering operation may be performed to reduce video blocking artifacts in the video block.
[0089] The entropy encoding unit 214 may receive data from other functional components of the video encoder 200. When the entropy encoding unit 214 receives the data, the entropy encoding unit 214 may perform one or more entropy encoding operations to generate entropy encoded data and output a bitstream that includes the entropy encoded data.
[0090] FIG. 3 is a block diagram illustrating an example of a video decoder 300, which may be an example of the video decoder 124 in the system 100 illustrated in FIG. 1, in accordance with some embodiments of the present disclosure.
[0091] The video decoder 300 may be configured to perform any or all of the techniques of this disclosure. In the example of FIG. 3, the video decoder 300 includes a plurality of functional components. The techniques described in this disclosure may be shared among the various components of the video decoder 300. In some examples, a processor may be configured to perform any or all of the techniques described in this disclosure.
[0092] In the example of FIG. 3, the video decoder 300 includes an entropy decoding unit 301, a motion compensation unit 302, an intra prediction unit 303, an inverse quantization unit 304, an inverse transform unit 305, a reconstruction unit 306 and a buffer 307. The video decoder 300 may, in some examples, perform a decoding pass generally reciprocal to the encoding pass described with respect to video encoder 200.
[0093] The entropy decoding unit 301 may retrieve an encoded bitstream. The encoded bitstream may include entropy coded video data (e.g., encoded blocks of video data) . The entropy decoding unit 301 may decode the entropy coded video data, and from the entropy decoded video data, the motion compensation unit 302 may determine motion information including motion vectors, motion vector precision, reference picture list indexes, and other motion information. The motion compensation unit 302 may, for example, determine such information by performing the AMVP and merge mode. AMVP is used, including derivation of several most probable candidates based on data from adjacent PBs and the reference picture. Motion information typically includes the horizontal and vertical motion vector displacement values, one or two reference picture indices, and, in the case of prediction regions in B slices, an identification of which reference picture list is associated with each index. As used herein, in some aspects, a “merge mode” may refer to deriving the motion information from spatially or temporally neighboring blocks.
[0094] The motion compensation unit 302 may produce motion compensated blocks, possibly performing interpolation based on interpolation filters. Identifiers for interpolation filters to be used with sub-pixel precision may be included in the syntax elements.
[0095] The motion compensation unit 302 may use the interpolation filters as used by the video encoder 200 during encoding of the video block to calculate interpolated values for sub-integer pixels of a reference block. The motion compensation unit 302 may determine the interpolation filters used by the video encoder 200 according to the received syntax information and use the interpolation filters to produce predictive blocks.
[0096] The motion compensation unit 302 may use at least part of the syntax information to determine sizes of blocks used to encode frame (s) and / or slice (s) of the encoded video sequence, partition information that describes how each macroblock of a picture of the encoded video sequence is partitioned, modes indicating how each partition is encoded, one or more reference frames (and reference frame lists) for each inter-encoded block, and other information to decode the encoded video sequence. As used herein, in some aspects, a “slice” may refer to a data structure that can be decoded independently from other slices of the same picture, in terms of entropy coding, signal prediction, and residual signal reconstruction. A slice can either be an entire picture or a region of a picture.
[0097] The intra prediction unit 303 may use intra prediction modes for example received in the bitstream to form a prediction block from spatially adjacent blocks. The inverse quantization unit 304 inverse quantizes, i.e., de-quantizes, the quantized video block coefficients provided in the bitstream and decoded by entropy decoding unit 301. The inverse transform unit 305 applies an inverse transform.
[0098] The reconstruction unit 306 may obtain the decoded blocks, e.g., by summing the residual blocks with the corresponding prediction blocks generated by the motion compensation unit 302 or intra-prediction unit 303. If desired, a deblocking filter may also be applied to filter the decoded blocks in order to remove blockiness artifacts. The decoded video blocks are then stored in the buffer 307, which provides reference blocks for subsequent motion compensation / intra prediction and also produces decoded video for presentation on a display device.
[0099] Some example embodiments of the present disclosure will be described in detailed hereinafter. It should be understood that section headings are used in the present document to facilitate ease of understanding and do not limit the embodiments disclosed in a section to only that section. Furthermore, while certain embodiments are described with reference to Versatile Video Coding or other specific video codecs, the disclosed techniques are applicable to other video coding technologies also. Furthermore, while some embodiments describe video coding steps in detail, it will be understood that corresponding steps decoding that undo the coding will be implemented by a decoder. Furthermore, the term video processing encompasses video coding or compression, video decoding or decompression and video transcoding in which video pixels are represented from one compressed format into another compressed format or at a different compressed bitrate. 1 Brief Summary This disclosure is related to video coding technologies. Specifically, it is about the usage of intra prediction in image / video coding. It may be applied to the existing video coding standard like HEVC, VVC, and etc. It may be also applicable to future video coding standards or video codec. 2 Introduction Video coding standards have evolved primarily through the development of the well-known ITU-T and ISO / IEC standards. The ITU-T produced H. 261 and H. 263, ISO / IEC produced MPEG-1 and MPEG-4 Visual, and the two organizations jointly produced the H. 262 / MPEG-2 Video and H. 264 / MPEG-4 Advanced Video Coding (AVC) and H. 265 / HEVC standards. Since H. 262, the video coding standards are based on the hybrid video coding structure wherein temporal prediction plus transform coding are utilized. To explore the future video coding technologies beyond HEVC, the Joint Video Exploration Team (JVET) was founded by VCEG and MPEG jointly in 2015. The JVET meeting is concurrently held once every quarter, and the new video coding standard was officially named as Versatile Video Coding (VVC) in the April 2018 JVET meeting, and the first version of VVC test model (VTM) was released at that time. The VVC working draft and test model VTM are then updated after every meeting. The VVC project achieved technical completion (FDIS) at the July 2020 meeting. 2.1 Intra prediction In intra prediction the smallest chroma intra prediction unit (SCIPU) constraint in VVC is removed. In addition, the VPDU constraint for reducing CCLM prediction latency is also removed. 2.1.1 Multi-model LM (MMLM) CCLM included in VVC is extended by adding three Multi-model LM (MMLM) modes. In each MMLM mode, the reconstructed neighboring samples are classified into two classes using a threshold which is the average of the luma reconstructed neighboring samples. The linear model of each class is derived using the Least-Mean-Square (LMS) method. For the CCLM mode, the LMS method is also used to derive the linear model. A slope adjustment to is applied to cross-component linear model (CCLM) and to Multi-model LM prediction. The adjustment is tilting the linear function which maps luma values to chroma values with respect to a center point determined by the average luma value of the reference samples. 2.1.1.1 Slope adjustment of CCLM CCLM uses a model with 2 parameters to map luma values to chroma values. The slope parameter “a” and the bias parameter “b” define the mapping as follows: chromaVal = a *lumaVal + b. An adjustment “u” to the slope parameter is signaled to update the model to the following form: chromaVal = a’*lumaVal + b’ where a’ = a + u b’ = b -u *yr. With this selection the mapping function is tilted or rotated around the point with luminance value yr. The average of the reference luma samples used in the model creation as yr in order to provide a meaningful modification to the model. Picture below illustrates the process. FIG. 4 illustrates the effect of the slope adjustment parameter “u” (left: model created with the current CCLM, right: model updated as proposed) . Implementation Slope adjustment parameter is provided as an integer between -4 and 4, inclusive, and signaled in the bitstream. The unit of the slope adjustment parameter is 1 / 8th of a chroma sample value per one luma sample value (for 10-bit content) . Adjustment is available for the CCLM models that are using reference samples both above and left of the block ( “LM_CHROMA_IDX” and “MMLM_CHROMA_IDX” ) , but not for the “single side” modes. This selection is based on coding efficiency vs. complexity trade-off considerations. When slope adjustment is applied for a multimode CCLM model, both models can be adjusted and thus up to two slope updates are signaled for a single chroma block. Encoder approach The proposed encoder approach performs an SATD based search for the best value of the slope update for Cr and a similar SATD based search for Cb. If either one results as a non-zero slope adjustment parameter, the combined slope adjustment pair (SATD based update for Cr, SATD based update for Cb) is included in the list of RD checks for the TU. 2.1.2 Gradient PDPC In VVC, for a few scenarios, PDPC may not be applied due to the unavailability of the secondary reference samples. In these cases, a gradient based PDPC, extended from horizontal / vertical mode, is applied. The PDPC weights (wT / wL) and nScale parameter for determining the decay in PDPC weights with respect to the distance from left / top boundary are set equal to corresponding parameters in horizontal / vertical mode, respectively. When the secondary reference sample is at a fractional sample position, bilinear interpolation is applied. 2.1.3 Primary and Secondary MPM Secondary MPM lists is introduced. The existing primary MPM (PMPM) list consists of 6 entries and the secondary MPM (SMPM) list includes 16 entries. A general MPM list with 22 entries is constructed first, and then the first 6 entries in this general MPM list are included into the PMPM list, and the rest of entries form the SMPM list. The first entry in the general MPM list is the Planar mode. The remaining entries are composed of the intra modes of the left (L) , above (A) , below-left (BL) , above-right (AR) , and above-left (AL) neighbouring blocks, and DIMD modes which are sorted in ascending order of SAD cost. Up to 5 modes with the smallest SAD cost are added. The SAD cost is computed between the prediction and the reconstruction samples of the template. The sorted directional modes with added offset are added into the general MPM list, and then the default modes, until the general MPM list with 22 entries is constructed. If a CU block is vertically oriented, the order of neighbouring blocks is A, L, BL, AR, AL; otherwise, it is L, A, BL, AR, AL. FIG. 5. illustrates Neighbouring blocks (L, A, BL, AR, AL) used in the derivation of a general MPM list. MPM list is equally divided into four groups and the group index is parsed first. Then, a mode index is further parsed to indicate which mode in the selected group is used. 2.1.4 Reference sample interpolation and smoothing for intra-prediction The 4-tap cubic interpolation is replaced with a 6-tap cubic interpolation filter, for the derivation of predicted samples from the reference samples. For reference sample filtering, a 6-tap gaussian filter is applied for larger blocks (W >= 32 and H >=32) , existing VVC 4-tap gaussian interpolation filter is applied otherwise. The extended intra reference samples are derived using the 4-tap interpolation filter instead of the nearest neighbor rounding. 2.1.5 Decoder side intra mode derivation (DIMD) When DIMD is applied, up to five intra modes are derived from the reconstructed neighbor samples, and those five predictors are combined with the non-directional predictor (planar or block vector based predictor) with the weights derived from the histogram of gradients. The decision between for the non-directional modes is taken according to the template cost. Specifically, the block vectors of all adjacent and non-adjacent merge candidates (coded in IntraTMP or IBC) are compared to planar prediction on the reconstructed template. The template cost (SATD) is used to select the best predictor among them. The division operations in weight derivation are performed utilizing the same lookup table (LUT) based integerization scheme used by the CCLM. For example, the division operation in the orientation calculation Orient = Gy / Gx is computed by the following LUT-based scheme: x = Floor (Log2 (Gx ) ) normDiff = ( (Gx<< 4) >> x) &15 x += (3 + (normDiff ! = 0) ? 1 : 0) Orient = (Gy*(DivSigTable|8) + (1<< (x-1) ) ) >> x where DivSigTable = {0, 7, 6, 5 , 5, 4, 4, 3, 3, 2, 2, 1, 1, 1, 1, 0 } . For a block of size W × H, the weight for each of the five derived modes is modified if the one the above or left histogram magnitudes is twice larger than the other one. In this case, the weights are location dependent and computed as follows: If the above histogram is twice the left, then: If the left histogram is twice the above, then: where wDimdi is the unmodified uniform weight of the DIMD selected as, Δi is pre-defined and set to 10. Derived intra modes are included into the primary list of intra most probable modes (MPM) , so the DIMD process is performed before the MPM list is constructed. The primary derived intra mode of a DIMD block is stored with a block and is used for MPM list construction of the neighboring blocks. Finally, note the region of neighboring reconstructed samples used for computing the histogram of gradients is modified method, depending on reconstructed samples availability. The region of decoded reference samples of current WxH luma CB is extended towards the above-right side if available, up to W additional columns. It is extended towards the bottom-left side if available, up to H additional rows. 2.1.5.1 Occurrence-based intra coding (OBIC) The occurrence-based intra coding (OBIC) derives the intra prediction modes of the current block based on the sample-wise occurrence of the intra modes in the spatial neighborhood of the block. For this, adjacent and non-adjacent spatial neighboring blocks are checked and the intra prediction modes of the blocks are collected into an occurrence histogram. Instead of Histogram of Gradients (HoGs) as in DIMD, the OBIC method uses the Histogram of Occurrences, which consists of the intra modes and their sample-wise occurrences. The occurrence values are calculated based on the number of samples that are coded in a certain intra prediction mode in that neighborhood. For example, if a uiWidth × uiHeight block is coded with an IPM mode, the occurrence of the mode in that block is calculated as: Histogram += uiWidth × uiHeight; Where uiWidth and uiHeight are the width and height of a spatial neighboring block. The occurrences of the existing modes from the spatial neighborhood blocks are accumulated into the histogram. FIG. 6 shows the non-adjacent spatial neighboring blocks that are used in OBIC mode’s histogram generation. FIG. 6 illustrates the Non-adjacent spatial neighboring candidates for OBIC mode. Up to five angular modes with the highest occurrence along with the planar mode or block vector-based prediction (same as in DIMD) are selected from the histogram and used for final prediction by blending the prediction of the selected modes. Some blocks, mentioned below, use more than one intra mode for prediction. In such cases, all the intra modes of such blocks are selected and used when creating the OBIC histogram: · DIMD: up to 5 angular modes · TIMD: up to 2 modes · SGPM: 2 modes · OBIC: up to 5 angular modes. Moreover, the virtual intra prediction modes (VIPMs) of following blocks are considered only in inter slices when creating the histogram of OBIC mode: · MIP block · IntraTMP block · EIP block. The blending weights are calculated similar to the DIMD mode, but instead of using gradient values from the template, the occurrence values are used for OBIC. Moreover, the planar mode’s weight is also decided similar to DIMD mode. The OBIC mode is used as a sub-mode of DIMD tool and is applied to only luma blocks. Moreover, the mode is disabled for blocks that have less than 64 samples. 2.1.5.2 DIMD chroma mode The DIMD chroma mode uses the DIMD derivation method to derive the chroma intra prediction mode of the current block based on the neighboring reconstructed Y, Cb and Cr samples in the second neighboring row and column. Specifically, a horizontal gradient and a vertical gradient are calculated for each collocated reconstructed luma sample of the current chroma block, as well as the reconstructed Cb and Cr samples, to build a HoG. Then the intra prediction mode with the largest histogram amplitude values is used for performing chroma intra prediction of the current chroma block. FIG. 7 illustrates the neighboring reconstructed samples used for DIMD chroma mode. When the intra prediction mode derived from the DIMD chroma mode is the same as the intra prediction mode derived from the DM mode, the intra prediction mode with the second largest histogram amplitude value is used as the DIMD chroma mode. A CU level flag is signaled to indicate whether the proposed DIMD chroma mode is applied. Finally, the luma region of reconstructed samples used for computing the histogram of gradients for chroma DIMD mode is modified. For a WxH pair of chroma CBs to predict, to build the histogram of gradients associated to the collocated luma CB, the pairs of a vertical gradient and a horizontal gradient are extracted from the second and third lines in this luma CB instead of being extracted from the regular set of DIMD decoded reference samples around this luma CB. 2.1.6 Fusion of chroma intra prediction modes In ECM, two chroma intra prediction signals can be fused together. One of the two chroma intra prediction signals is predicted using one of the DM mode, DIMD chroma mode and the four default modes (non-LM mode) . The other chroma intra prediction signal is predicted using cross-component linear prediction modes (LM mode) . Two different methods are supported. In the first method, the LM mode can be either MM-CCLM or MM-CCCM, and the final predictor is derived as follows: predC (i, j) = (w0 × pred0 (i, j) + w1 × pred1 (i, j) + (1 << (shift-1) ) ) >> shift where pred0 (i, j) is the predictor obtained by applying the non-LM mode, pred1 (i, j) is the predictor obtained by applying the LM mode and predC (i, j) is the final predictor of the current chroma block. The two weights, w0 and w1 are determined by the intra prediction mode of adjacent chroma blocks and shift is set equal to 2. Specifically, when the above and left adjacent blocks are both coded with LM modes,{w0, w1} = {1, 3} ; when the above and left adjacent blocks are both coded with non-LM modes, {w0, w1} = {3, 1};otherwise, {w0, w1} = {2, 2} . Two template costs are calculated by fusing the angular chroma prediction with MM-CCLM or MM-CCCM, respectively, and the one of the two CCPs which provides a smaller template cost is utilized to derive pred1. In the second method, the LM mode can be either MMLM or CCLM mode, and the final predictor is derived as follows: predC (i, j) = α0 × pred0 (i, j) + α1 × rec′L (i, j) +α2 × β where pred0 (i, j) is the predictor obtained by applying the non-LM mode, rec′L (i, j) is the set of downsampled reconstructed luma samples at co-located positions and predC (i, j) is the final predictor of the current chroma block. β is a fixed value and is set equal to 512 for 10-bit content. The three weights, α0, α1 and α2 are derived from the adjacent luma and chroma samples using the same LDL derivation method as in CCCM. For the syntax design, one index is signaled to indicate whether fusion is applied and which method is used. It is noted that for I slices, the non-LM mode can be DM mode, DIMD chroma mode and the four default modes. For non-I slices, only DIMD chroma mode is allowed to be fused with LM modes. 2.1.7 Intra template matching Intra template matching prediction (IntraTMP) is a special intra prediction mode that copies the best prediction block from the reconstructed part of the current frame, whose L-shaped template matches the current template. For a predefined search range, the encoder searches for the most similar template to the current template in a reconstructed part of the current frame and uses the corresponding block as a prediction block. The encoder then signals the usage of this mode, and the same prediction operation is performed at the decoder side. The prediction signal is generated by matching the L-shaped, Top-only or Left-Only causal neighbor of the current block with another block in a predefined search area in FIG. 9. There are 6 predefined search areas, i.e., R1 to R6 in FIG. 9 which contain the reconstructed samples from the top and left CTUs as well as part of the reconstructed samples within the current CTU that are located above, left, bottom-left and top-right to the current block. IntraTMP employs an implicit merge mode, where merge candidates are considered without signaling a merge flag or index. Specifically, the reference positions pointed by the block vectors of all the adjacent and non-adjacent merge candidates (coded in IntraTMP or IBC mode) are used as additional candidates beyond the default search areas, up to 10 merge candidates are derived from the neighboring PUs and by prioritizing the candidates outside the IntraTMP search range. In addition, up to 20 auto-relocated block vector prediction (AR-BVP) candidates are constructed to get more reference positions. As shown in FIG. 10, a guiding block vector BV0 (i.e., an existing BVP already in the candidate list) associated with the current block B0 points at a reference block B1. If B1 has a BV denoted as BV1 pointing at a reference block B2, then BV0’ , given by BV0’ = BV0 + BV1, is defined as the AR-BVP. BV1 itself can also be directly used as AR-BVP to get more available candidates. When deriving AR-BVP, all five positions including top-left (e.g., LT in FIG. 11) , top-right (e.g., RT in FIG. 11) , center (e.g., Ctr in FIG. 11) , bottom-left (e.g., LB in FIG. 11) , and bottom-right (e.g., RB in FIG. 11) positions of the reference block are checked to find the reference block’s BVs. Both the merge candidates from the neighboring PUs and constructed AR-BVPs can be used as guiding BVs. The construction will be recursively processed until the number of AR-BVPs reaches 20 or no new AR-BVPs are constructed. Finally, up to 20 AR-BVPs can be constructed and there would be up to 30 merge candidates in total. If an AR-BVP candidate is selected for refinement, it would have a refinement range of 3x3. The same template matching cost is used to compare the merge positions and the defaults ones. For bi-directional IBC merge candidate, two candidates are retained corresponding to each reference frame. Similarly, for IntraTMP, two candidates are considered corresponding to the best candidate by template search and the coded candidate. For each block vector obtained by default search, merge or ARBVP, a refinement window of 3x3 is defined. For overlapping block vectors, a clustering process is defined. If two refinement windows overlap, the BV candidate with the lower template cost is selected and ranked in the list for further refinement. Subsequently, a new refinement window that comprises both individual refinement windows is determined for the winning candidate. Additionally, the following considered: - For block sizes 8x8 or smaller, a search region fully overlapped by a BVP candidate refinement window is skipped. - In each sparse region, the searching pattern is shifted by one sample per row in order to increase the candidate diversity. Sum of absolute differences (SAD) is used as a cost function. A given search order of the 6 regions is utilized, i.e., R4, R5, R6, R1, R2, and R3. Within each region, the decoder constructs a candidate list of up to “19” template matching block vectors that are ranked in ascending order according to the template cost (SAD) . The following modes are supported: 1- Single predictor: A single predictor is selected from the candidate list. 2- Fusion of multiple predictors: multiple predictors are blended multiple to derive the final prediction block. The blending weights are either computed from the template matching cost of each predictor, or with Wiener-filter based weight derivation method. 3- Sub-pel precision: When single predictor is used, sub-pel precisions are supported. A new candidate list is constructed by including the selected integer block vector and surrounding 1 / 2-pel and 1-4-pel sub-pel positions. The list is sorted based on the same cost function used for the integer bv search. After that, the first two candidates are allowed to be selected with one single flag being signaled from encoder to decoder. 4- linear filter model: A linear filter can be learned between the reference template and current template and be applied the linear model to reference block. This mode can be used for single predictor when sub-pel precision is not used. Additionally, IntraTMP with local illumination compensation is allowed. The following considerations are taken: 1- Usages of LIC and FLM (CCCM-like filtering) are mutually exclusive for a given CU. 2- Usages of LIC together with fusion in intra TMP is allowed. 3- Top-only and Left-only template usage for LIC model determination is allowed for screen content coding. For camera-captured coding, only the top-left template is employed. 4- Multi Mode Linear Model (MMLM) is supported similarly to IBC-LIC, for screen content coding. When LIC is used for a given CU, the Intra TMP search process employs MRSAD rather than SAD distortion function. Moreover, when LIC is used for a given CU in the Intra TMP search process, the position of the pixel at the top-left of each candidate reconstructed block is shifted by half the search sampling factor vertically and horizontally with respect to the associated position in the non-LIC case. As an exception, for a candidate reconstructed block with top-left pixel having shifted position, if the horizontal / vertical shift causes this candidate reconstructed block to go out of the bounds of the Intra TMP search region, the horizontal / vertical shift is canceled. The concept is illustrated in the following figure. FIG. 8 modified search range for LIC. Positions labeled with “x” are default positions whereas positions labeled with “y” are the LIC positions. The new positions are shifted by half of the subsampling range. The dimensions of all regions (SearchRange_w, SearchRange_h) are set proportional to the block dimension (BlkW, BlkH) to have a fixed number of SAD comparisons per pixel. That is: SearchRange_w = min (64, a*BlkW) SearchRange_h = min (64, a*BlkH) Where ‘a’ is a constant that controls the gain / complexity trade-off. In practice, ‘a’ is equal to 5. FIG. 9 illustrates the intra template matching search area used. To speed-up the template matching process, the search range of all search regions is subsampled by a factor of 4.After finding the best match, a refinement process is performed. The refinement is done via a second template matching search around the best match with a reduced range. The Intra template matching tool is enabled for CUs with size less than or equal to 64 in width and height. This maximum CU size for Intra template matching is configurable. The Intra template matching prediction mode is signaled at CU level through a dedicated flag when DIMD is not used for current CU. FIG. 10 illustrates an example of IntraTMP-AR-BVP’s construction. FIG. 11 illustrates the five positions in reference Block. 2.1.7.1 IntraTMP derived block vector candidates for IBC In this method block vector (BV) derived from the intra template matching prediction (IntraTMP) is used for intra block copy (IBC) . The stored IntraTMP BV of the neighbouring blocks along with IBC BV are used as spatial BV candidates in IBC candidate list construction. IntraTMP block vector is stored in the IBC block vector buffer and, the current IBC block can use both IBC BV and IntraTMP BV of neighbouring blocks as BV candidate for IBC BV candidate list as shown in FIG. 12. FIG. 12 illustrates the use of IntraTMP block vector for IBC block. IntraTMP block vectors are added to IBC block vector candidate list as spatial candidates. IntraTMP block vectors are stored in quarter-pel resolution for coding of IBC block vectors and HMVP. 2.1.8 Fusion for template-based intra mode derivation (TIMD) For each intra prediction mode in MPMs, as well as the wide-angle modes if the above-right and / or bottom-left reference samples are available, SATD between the prediction and reconstruction samples of the template is calculated. First two intra prediction modes with the minimum SATD and one non-angular intra prediction mode (i.e. DC or Planar) with the lowest SATD cost are selected as the TIMD modes. These three TIMD modes are fused with the weights after applying PDPC process, and such weighted intra prediction is used to code the current CU. Position dependent intra prediction combination (PDPC) is included in the derivation of the TIMD modes. The conditions below are checked to determine whether the non-angular intra prediction mode is used in fusion: - the non-angular intra prediction mode is different from the two selected intra prediction modes. - costMode3 < 1.5*costMode1, where the costMode3 is the SATD cost of the non-angular intra prediction mode and costMode1 is the SATD cost of the first intra prediction mode. If both of the conditions are true, three intra prediction modes are used to generate the prediction. And the weights of each intra prediction mode are computed from SATD cost: Otherwise, the non-angular intra prediction mode is not used in prediction. And the costs of the two selected modes are compared with a threshold, in the test the cost factor of 2 is applied as follows: costMode2 < 2*costMode1. If this condition is true, the fusion is applied, otherwise the only mode1 is used. Weights of the modes are computed from their SATD costs as follows: weight1 = costMode2 / (costMode1 + costMode2) weight2 = 1 - weight1. The division operations are conducted using the same lookup table (LUT) based integerization scheme used by the CCLM. Besides, location-dependent sample-based fusion used in DIMD fusion process is used for the TIMD fusion but the location-dependent criterion applying to amplitudes of the selected predictors is replaced by a SATD cost-based criteria. The location-dependent criterion is determined from a ratio of the normalized SATD of the selected TIMD predictors computed in above and left template area. 2.1.9 Intra prediction fusion This intra prediction method derives predicted samples as a weighted combination of multiple predictors generated from different reference lines. In this process multiple intra predictors are generated and then fused by weighted averaging. The process of deriving the predictors to be used in the fusion process is described as follows: · For angular intra prediction modes including the single mode case of TIMD and DIMD, the proposed method derives intra prediction by weighting intra predictions obtained from multiple reference linesrepresented as pfusion = w0pline + w1pline+1, where pline is the intra prediction from the default reference line and pline+1 is the prediction from the line above the default reference line. The weights are set as w0 = 3 / 4 and w1 = 1 / 4. · For TIMD mode with blending, pline is used for the first mode (w0 = 1, w1 = 0) and pline+1 is used for the second mode (w0 = 0, w1 = 1) . · For DIMD mode with blending, the number of predictors selected for a weighted average is increased from 3 to 6. The angular intra prediction fusion method is applied to luma blocks when angular intra mode has non-integer slope (required reference samples interpolation) and the block size is greater than 16, it is used with MRL and not applied for ISP coded blocks. In the method studied in the sub-test a, PDPC is applied for the intra prediction mode using the closest to the current block reference line. The TIMD mode with blending method is applied when all the following conditions are satisfied: - both the first and second modes are angular prediction mode. - the current block is not ISP coded block. - all of the following conditions are false: ○ abs (predModeIntra1 – predModeIntra2) is greater than Threshold. The value of Threshold is set to 8 or 4 depending on block size. ○ (predModeIntra1 - EXT_HOR_IDX) * (predModeIntra2 - EXT_HOR_IDX) is less than 0. ○ (predModeIntra1 - EXT_VER_IDX) * (predModeIntra2 - EXT_VER_IDX) is less than 0. 2.1.10 Improvements of CIIP 2.1.10.1 Subblock CIIP A subblock-based merge candidate may be used to generate the inter signal of CIIP, where the same subblock-based merge candidate list used by affine and sbTMVP is utilized. When CIIP flag is true and CIIP-TM flag is false, a subblock-based CIIP flag is signalled. If subblock-based CIIP flag is true, an index indicating specific candidate in the subblock-based merge list is signalled, and TIMD is used to generate intra signal by default thus no CIIP-PDPC flag signalled any more. 2.1.10.2 Combination of CIIP with TIMD and TM merge In CIIP mode, the prediction samples are generated by weighting an inter prediction signal predicted using CIIP-TM merge candidate and an intra prediction signal predicted using TIMD derived intra prediction mode. The method is only applied to coding blocks with an area less than or equal to 1024. The TIMD derivation method is used to derive the intra prediction mode in CIIP. Specifically, the intra prediction mode with the smallest SATD values in the TIMD mode list is selected and mapped to one of the 67 regular intra prediction modes. In addition, it is also proposed to modify the weights (wIntra, wInter) for the two tests if the derived intra prediction mode is an angular mode. For near-horizontal modes (2 <= angular mode index < 34) , the current block is vertically divided; for near-vertical modes (34 <= angular mode index <= 66) , the current block is horizontally divided. The (wIntra, wInter) for different sub-blocks are shown below. FIG. 13A and 13B illustrate the division method for angular modes. Table 1. The modified weights used for angular modes. With CIIP-TM, a CIIP-TM merge candidate list is built for the CIIP-TM mode. The merge candidates are refined by template matching. The CIIP-TM merge candidates are also reordered by the ARMC method as regular merge candidates. The maximum number of CIIP-TM merge candidates is equal to two. 2.1.11 Extended multiple reference line (MRL) list MRL list in VVC is extended to include more reference lines for intra prediction. The extended reference line list consists of line indices {1, 3, 5, 7, 12} . For template-based intra mode derivation (TIMD) , instead of the full MRL candidate list, only the first two reference line candidates, i.e., {1, 3} , are used. FIG. 14 illustrates the extended MRL candidate list. 2.1.12 Template-based multiple reference line intra prediction Template-based multiple reference line intra prediction (TMRL) mode combines reference line and prediction mode together and uses a template matching method to construct a list of candidate combinations. An index to the candidate combination list is coded to indicate which reference line and prediction mode is used in coding the current block. The regular multiple reference line (MRL) for the non-TIMD part is replaced by TMRL mode. The TMRL mode extends reference line candidate list and the intra-prediction-mode candidate list. The extended reference line candidate list is {1, 3, 5, 7, 12} . The size of the intra-prediction-mode candidate list is 10.The construction of the intra-prediction-mode candidate list is similar to MPM except the PLANAR mode is excluded from the intra-prediction-mode candidate list, DC mode is added after 5 neighboring PUs’ modes and DIMD modes if its not included and the angular modes with delta angles from ±1 to ±4 (compared the existing angular modes in the intra-prediction-mode candidate list) are added. The precision of angular prediction is extended from 65 to 129. Additionally non-adjacent positions are added as candidates in constructing the intra candidate list. If the neighbouring or non-adjacent blocks are coded with SGPM or GPM modes, the intra modes of the blocks are replaced by the partitioning angles. The TMRL candidate is constructed as follows. There are 5x10=50 combinations of the extended reference line and the allowed intra-prediction modes for a block. Since the extended reference line starts from reference line 1, the area covered by reference line 0 is used for template matching. The SAD costs over the template area (see FIG. 15) are calculated between the predictions (generated by 50 combinations) and the reconstructions. The 20 combinations with the least SAD cost are selected in an ascending order to form the TMRL candidate list. FIG. 15 illustrates the template area. For TMR signalling instead of coding the reference line and the intra mode directly, an index to the TMRL candidate list is coded to indicate which combination of reference line and prediction mode is used for coding the current block. 2.1.13 Convolutional cross-component intra prediction model In this method convolutional cross-component model (CCCM) is applied to predict chroma samples from reconstructed luma samples in a similar spirit as done by the current CCLM modes. As with CCLM, the reconstructed luma samples are down-sampled to match the lower resolution chroma grid when chroma sub-sampling is used. Similar to CCLM top, left or top and left reference samples are used as templates for model derivation. Also, similarly to CCLM, there is an option of using a single model or multi-model variant of CCCM. The multi-model variant uses two models, one model derived for samples above the average luma reference value and another model for the rest of the samples (following the spirit of the CCLM design) . Multi-model CCCM mode can be selected for PUs which have at least 128 reference samples available. 2.1.13.1 Convolutional filter The convolutional 7-tap filter consist of a 5-tap plus sign shape spatial component, a nonlinear term and a bias term. The input to the spatial 5-tap component of the filter consists of a center (C) luma sample which is collocated with the chroma sample to be predicted and its above / north (N) , below / south (S) , left / west (W) and right / east (E) neighbors as illustrated below. FIG. 16 illustrates the spatial part of the convolutional filter. The nonlinear term P is represented as power of two of the center luma sample C and scaled to the sample value range of the content: P = (C*C + midVal) >> bitDepth. That is, for 10-bit content it is calculated as: P = (C*C + 512) >> 10. The bias term B represents a scalar offset between the input and output (similarly to the offset term in CCLM) and is set to middle chroma value (512 for 10-bit content) . Output of the filter is calculated as a convolution between the filter coefficients ci and the input values and clipped to the range of valid chroma samples: predChromaVal = c0C + c1N + c2S + c3E + c4W + c5P + c6B. 2.1.13.2 Calculation of filter coefficients The filter coefficients ci are calculated by minimising MSE between predicted and reconstructed chroma samples in the reference area. Bellow figure illustrates the reference area which consists of 2 or 6 lines of chroma samples above and left of the PU. Whether to use 6 lines or 2 lines of neighbouring samples to derive the CCCM model parameters in the single model CCCM is determined by a template cost. Similarly, for the multi-model CCCM mode, the two candidates use 6 lines neighbouring luma samples or luma samples collocated to the current chroma block to derive mean values which separate samples into two groups. The cost is derived by applying the candidate CCP (either 2 or 6 lines) on a template, calculating the sum of absolute difference (SAD) between CCP predicted samples and reconstructed samples in the template. Reference area extends one PU width to the right and one PU height below the PU boundaries. Area is adjusted to include only available samples. The extensions to the area shown in blue are needed to support the “side samples” of the plus shaped spatial filter and are padded when in unavailable areas. FIG. 17 illustrates the reference area (with its paddings) used to derive the filter coefficients. The MSE minimization is performed by calculating autocorrelation matrix for the luma input and a cross-correlation vector between the luma input and chroma output. Autocorrelation matrix is LDL decomposed and the final filter coefficients are calculated using back-substitution. The process follows roughly the calculation of the ALF filter coefficients in ECM, however LDL decomposition was chosen instead of Cholesky decomposition to avoid using square root operations. The autocorrelation matrix is calculated using the reconstructed values of luma and chroma samples. These samples are full range (e.g. between 0 and 1023 for 10-bit content) resulting in relatively large values in the autocorrelation matrix. This requires high bit depth operation during the model parameters calculation. It is proposed to remove fixed offsets from luma and chroma samples in each PU for each model. This is driving down the magnitudes of the values used in the model creation and allows reducing the precision needed for the fixed-point arithmetic. As a result, 16-bit decimal precision is proposed to be used instead of the 22-bit precision of the original CCCM implementation. Reference sample values just outside of the top-left corner of the PU are used as the offsets (offsetLuma, offsetCb and offsetCr) for simplicity. The samples values used in both model creation and final prediction (i.e., luma and chroma in the reference area, and luma in the current PU) are reduced by these fixed values, as follows: C' = C – offsetLuma N' = N – offsetLuma S' = S – offsetLuma E' = E – offsetLuma W' = W – offsetLuma P' = nonLinear (C') B = midValue = 1 << (bitDepth - 1) and the chroma value is predicted using the following equation, where offsetChroma is equal to offsetCr and offsetCb for Cr and Cb components, respectively: predChromaVal = c0C' + c1N' + c2S' + c3E' + c4W' + c5P' + c6B + offsetChroma. In order to avoid any additional sample level operations, the luma offset is removed during the luma reference sample interpolation. This can be done, for example, by substituting the rounding term used in the luma reference sample interpolation with an updated offset including both the rounding term and the offsetLuma. The chroma offset can be removed by deducting the chroma offset directly from the reference chroma samples. As an alternative way, impact of the chroma offset can be removed from the cross-component vector giving identical result. In order to add the chroma offset back to the output of the convolutional prediction operation the chroma offset is added to the bias term of the convolutional model. The process of CCCM model parameter calculation requires division operations. Division operations are not always considered implementation friendly. The division operation are replaced with multiplication (with a scale factor) and shift operation, where scale factor and number of shifts are calculated based on denominator similar to the method used in calculation of CCLM parameters. 2.1.13.3 Gradient Linear Model For YUV 4: 2: 0 color format, a gradient linear model (GLM) method can be used to predict the chroma samples from luma sample gradients. Two modes are supported: a two-parameter GLM mode and a three-parameter GLM mode. Compared with the CCLM, instead of down-sampled luma values, the two-parameter GLM utilizes luma sample gradients to derive the linear model. Specifically, when the two-parameter GLM is applied, the input to the CCLM process, i.e., the down-sampled luma samples L, are replaced by luma sample gradients G. The other parts of the CCLM (e.g., parameter derivation, prediction sample linear transform) are kept unchanged. C = α·G + β In the three-parameter GLM, a chroma sample can be predicted based on both the luma sample gradients and down-sampled luma values with different parameters. The model parameters of the three-parameter GLM are derived from 6 rows and columns adjacent samples by the LDL decomposition based MSE minimization method as used in the CCCM. C = α0·G + α1·L + α2·β For signaling, when the CCLM mode is enabled to the current CU, one flag is signaled to indicate whether GLM is enabled for both Cb and Cr components; if the GLM is enabled, another flag is signaled to indicate which of the two GLM modes is selected and one syntax element is further signaled to select one of 4 gradient filters for the gradient calculation. · Four gradient filters are enabled for the GLM. FIG. 18 illustrates the four Sobel based gradient patterns for GLM. 2.1.13.4 CCCM signalling Usage of the mode is signalled with a CABAC coded PU level flag. One new CABAC context was included to support this. When it comes to signalling, CCCM is considered a sub-mode of CCLM. That is, the CCCM flag is only signalled if intra prediction mode is LM_CHROMA. 2.1.13.5 CCCM using non-downsampled luma samples CCCM mode with 3x2 filter using non-downsampled luma samples is used, which consists of 6-tap spatial terms, four nonlinear terms and a bias term. The 6-tap spatial terms correspond to 6 neighboring luma samples (i.e., L0, L1, …, L5) around the chroma sample (i.e., C) to be predicted, the four non-linear terms are derived from the samples L0, L1, L2, and L3. where αi is the coefficient, β is the offset. Same to the existing CCCM design, up to 6 lines / columns of chroma samples above and left to the current CU are applied to derive the filter coefficients. The filter coefficients are derived based on the same LDL decomposition method used in CCCM. The proposed method is signaled as an additional CCCM model besides the existing one, when the CCCM is selected, one single flag is signaled and used for both two chroma components to indicate whether the default CCCM model or the proposed CCCM model is applied. Additionally, SPS signaling is introduced to indicate whether the CCCM using non-downsampled luma samples is enabled. FIG. 19 illustrates the non-downsampled luma samples. 2.1.13.6 Block-vector guided CCCM (BVG-CCCM) When the co-located luma prediction is coded with IBC or IntraTMP in Intra slices, the BVG-CCCM mode can be used. In this mode, the block vectors of the co-located luma blocks, coded in IBC or intraTMP modes, are used to determine the reference area for calculating the CCCM parameters. The prediction is performed using uses the calculated model parameters and co-located luma samples. The BVG-CCCM mode uses an 11-tap filter for cross-component prediction as below: predChromaVal = c0C + c1N + c2S + c3E + c4W + c5P (C) + c6P (N) + c7P (S) + c8P (W) + c9P (E) + c10B. The input to the spatial 5-tap component of the filter consists of a center (C) luma sample which is collocated with the chroma sample to be predicted and its above / north (N) , below / south (S) , left / west (W) and right / east (E) neighbors as illustrated in FIG. 16. The nonlinear term P is represented as power of two of the corresponding luma sample and B is the bias term. FIG. 20 illustrates the reference area for BVG-CCCM. Similar to Direct Block Vector (DBV) mode, five locations in the collocated luma block area are scanned and the associated block vectors are then used for determining the reference area for parameter calculation in BVG-CCCM method. 2.1.13.7 Gradient and Location based convolutional cross-component model (GL-CCCM) This method maps luma values into chroma values using a filter with inputs consisting of one spatial luma sample, two gradient values, two location information, a nonlinear term, and a bias term. The GL-CCCM method uses gradient and location information instead of the 4 spatial neighbor samples used in the CCCM filter. The GL-CCCM filter used for the prediction is: predChromaVal = c0C + c1Gy + c2Gx + c3Y + c4X + c5P + c6B. Where Gy and Gx are the vertical and horizontal gradients, respectively, and are calculated as: Gy = (2N + NW + NE) - (2S + SW + SE) Gx = (2W + NW + SW) - (2E + NE + SE) . Moreover, the Y and X are the spatial coordinates of the center luma sample. The rest of the parameters are the same as CCCM tool. The reference area for the parameter calculation is the same as CCCM method. FIG. 21 illustrates the spatial samples used for GL-CCCM. The usage of the mode is signalled with a CABAC coded PU level flag. When it comes to signalling, GL-CCCM is considered a sub-mode of CCCM. That is, the GL-CCCM flag is only signalled if original CCCM flag is true. Similar to the CCCM, GL-CCCM tool has 6 modes for calculating the parameters: · Single-model GL-CCCM from above and left templates · Single-model GL-CCCM from above template · Single-model GL-CCCM from left template · Multi-model GL-CCCM from above and left templates · Multi-model GL-CCCM from above template · Multi-model GL-CCCM from left template. The encoder performs SATD search for the 6 GL-CCCM modes along with the existing CCCM modes to find the best candidates for full RD tests. 2.1.13.8 CCCM with Multiple Downsampling Filters Multiple downsampling filters are applied to a group of reconstructed luma samples in a CCCM. The linear combination of these downsampled reconstructed samples is multiplied by derived filter coefficients to form the final chroma predictor. The horizontal or vertical location of the center luma sample are also considered in the tested model. The cross-component models shown below are tested as additional CCCM modes with a mode index signalled in the bitstream: (1) Model 1: predChroma = c0*H (C) + c1*G1 (C) + c2*G2 (C) + c3*G3 (C) + c4*P (H (C) ) + c5*P (G1 (C) ) + c6*P (G2 (C) ) + c7*X + c8*Y + c9*B (2) Model 2: predChroma = c0*H (C) + c1*H (W) + c2*H (E) + c3*G1 (C) + c4*G1 (W) + c5*G1 (E) + c6*P (H (C) ) + c7*P (H (W) ) + c8*P (H (E) ) + c9*X + c10*B (3) Model 3: predChroma = c0*H (C) + c1*H (NE) + c2*H (SW) + c3*G3 (C) + c4*G3 (NE) + c5*G3 (SW) + c6*P (H (C) ) + c7*P (H (NE) ) + c8*P (H (SW) ) + c9*Y + c10*B where H (·) , G1 (·) , G2 (·) , G3 (·) are various downsampling filters, C denotes the current chroma sample position, and N, S, W, E, NE, SW are the positions around C, ci are filter coefficients, P and B are nonlinear term and bias term, and X and Y are the horizontal and vertical locations of the center luma sample with respect to the top-left coordinates of the block. FIG. 22 illustrates the various downsampling filters used in cross-component models. 2.1.14 Neural network-based intra prediction with DIMD mode derivation The neural network-based intra prediction algorithm and models build upon, - SADL for inference. - 16-bit integer for model weights and intermediate results, using 32-bit integer for internal computation. - sparse weights enforced at training time for complexity reduction. SADL supports a simple sparse matrix storage (compressed row method) and sparse matrix multiplication algorithm, exploiting the matrices sparsity. To reduce the complexity of the neural network-based intra prediction mode both in terms of MACs / pixel and decoding runtime, the proposed intra prediction mode differs in two aspects. - The sparsity constraints in the weight matrices have been strengthened. - Only the intra prediction output is retained, and the equivalent intra mode is derived by applying DIMD to the block predicted by the neural network-based intra prediction mode, as in TMP, EIP or MIP (as proposed in EE2-2.20) . To reduce the number of parameters, 6 models are used depending on the block size, each predicting a block size in {4 × 4, 8 × 4, 16 × 4, 8 × 8, 1 6 ×8, 16 × 16} (as proposed in test EE2-2.21) . For block sizes non natively supported by a model, similarly to MIP in VVC, the reference samples are transposed and / or down sampled. The architectures of the models are detailed in FIG. 24 to FIG. 26. In these figures, N is the number of reference samples, and WH is the number of samples to predict (FIG. 1) . The number of non-zero weights for each weight matrix is displayed. A sparse vector-matrix multiplication processes chunks of 8 non-zero coefficients. The model complexities are summarized in Table 2. The LeakyReLU used is defined as a piecewise-linear function: An alternative IPM is used for LFNST / NSPT for luma CBs larger than 64 luma samples. In addition to the 1st DIMD IPM, PLANAR is used as an additional IPM candidate. A CU-level flag indicating the IPM index is signaled for luma CBs larger than 64 luma samples. FIG. 23 illustrates N reference samples to predict a given W × H luma CB. If H ≥ 8 &&W ≥ 8, t = 8; else t = 4. FIG. 24 illustrates 4x4 (N = 80) and 8x4 (N = 112) models are sequential matrix multiplications and LeakyReLUs (piecewise-linear functions) . FIG. 25 illustrates 16x4 (N = 176) , 8x8 (N = 320) , and 16x8 (N = 448) models are sequential matrix multiplications and LeakyReLUs (piecewise-linear functions) . FIG. 26 illustrates 16x16 model is sequential matrix multiplications and LeakyReLUs (piecewise-linear functions) . Table 2: Model complexity for each model. Number of parameters for the whole intra prediction mode: 762519. Note that, for block size 16x16, one additional sparse matrix multiplication is used compared to the cases in FIG. 24 and FIG. 25. However, this still corresponds to the lowest complexity case in MACs / pixel, as shown by Table 2. Based on Table 2, in this fused method, the worst-case MACs / pixel drops from 4837 to 3176 and the number of parameters decreases from 1.33M to 0.76M. Coding efficiency is unchanged. 2.1.15 Local-Boosting Cross-Component Prediction (LB-CCP) Prediction samples of MM-CCLM / MM-CCCM can be filtered with neighbouring samples. A 3 × 3 low-pass filter is applied to filter prediction samples generated by MM-CCLM / MM-CCCM. For a sample at a top / left boundary, the filtering window may involve neighbouring reconstructed samples. For inner samples, the filtering window only involves prediction samples, which may be padded. A flag is signaled to indicate whether filtering is applied or not for a block coded with MM-CCLM / MM-CCCM. FIG. 27 illustrates the filter on samples of MM-CCLM / MM-CCCM. 2.1.16 Cross-Component Prediction (CCP) merge (a. k. a., non-local CCP) mode For chroma coding, a flag is signalled to indicate whether CCP mode (including the CCLM, CCCM, GLM and their variants) or non-CCP mode (conventional chroma intra prediction mode, fusion of chroma intra prediction mode) is used. If the CCP mode is selected, one more flag is signalled to indicate how to derive the CCP type and parameters, i.e., either from a CCP merge list or signalled / derived on-the-fly. A CCP merge candidate list is constructed from the spatial adjacent, temporal, spatial non-adjacent, history-based m or shifted temporal candidates. After including these candidates, default models are further included to fill the remaining empty positions in the merge list. In order to remove redundant CCP models in the list, pruning operation is applied. After constructing the list, the CCP models in the list are reordered depending on the SAD costs, which are obtained using the neighbouring template of the current block. More details are described below. Spatial adjacent and non-adjacent candidates The positions and inclusion order of the spatial adjacent and non-adjacent candidates are the same as those defined in ECM for regular inter merge prediction candidates. Temporal and shifted temporal candidates Temporal candidates are selected from the collocated picture. The position and inclusion order of the temporal candidates are the same as those defined in ECM for regular inter merge prediction candidates. The shifted temporal candidates are also selected from the collocated picture. The position of temporal candidates is shifted by a selected motion vector which is derived from motion vectors of neighboring blocks. History-based candidates A history-based table is maintained to include the recently used CCP models, and the table is reset at the beginning of each CTU row. If the current list is not full after including spatial adjacent and non-adjacent candidates, the CCP models in the history-based table are added into the list. Default candidates CCLM candidates with default scaling parameters are considered, only when the list is not full after including the spatial adjacent, spatial non-adjacent, or history-based candidates. If the current list has no candidates with the single model CCLM mode, the default scaling parameters are {0, 1 / 8, -1 / 8, 2 / 8, -2 / 8, 3 / 8, -3 / 8, 4 / 8, -4 / 8, 5 / 8, -5 / 8, 6 / 8} . Otherwise, the default scaling parameters are {0, the scaling parameter of the first CCLM candidate + {1 / 8, -1 / 8, 2 / 8, -2 / 8, 3 / 8, -3 / 8, 4 / 8, -4 / 8, 5 / 8, -5 / 8, 6 / 8} . It is noted that the LB-CCP flag is inherited from a CCP candidate in the CCP merge candidate list. A flag is signaled to indicate whether the CCP merge mode is applied or not. If CCP merge mode is applied, an index is signaled to indicate which candidate model is used by the current block. In addition, CCP merge mode is not allowed for the current chroma coding block when the current CU is coded by intra sub-partitions (ISP) with single tree, or the current chroma coding block size is less than or equal to 16. For a CCP merge coded block, one CCP-merge fusion flag is further signalled to indicate whether a fusion mode is applied. In the fusion mode, the final prediction is generated by a weighted sum of the CCP-merge prediction and either the MM-CCCM prediction or the DIMD prediction. A CCP-merge fusion type flag is further signalled if the CCP-merge fusion flag is true, to indicate whether the MM-CCCM prediction or the DIMD prediction is selected and fused with the CCP-merge prediction. 2.1.17 Decoder derived CCP mode In this method, a candidate list of cross-component prediction (CCP) modes is constructed, and to select the best candidate from the list a template cost is calculated to compare the reconstructed samples and the prediction values generated by the evaluated CCP mode. The template is shown in the next FIG. 25. FIG. 25 illustrates the template adjacent to the current chroma CU. The CCP mode list is constructed from the already existed in ECM modes by single model CCLM, single model CCCM, multi-model CCCM, single model GLCCCM, single model CCCM applied with LBCCP, and multi-model CCCM applied with LBCCP. In the second aspect of the method, various decoder-derived CCP fusion candidates are added. A fusion candidate is the combination of two CCP modes selected from the existing CCP mode lists reordered by template costs. Mode flag and a fusion flag are signalled to indicate the mode usage. 2.1.18 Spatial Geometric partitioning mode (SGPM) SGPM is an intra mode that resembles the inter coding tool of GPM, where the two prediction parts are generated from intra predicted process. In this mode, a candidate list is built with each entry containing one partition split and two intra prediction modes as shown in FIG. 29.26 partition modes and 9 of intra prediction modes are used to form the combinations. the length of the candidate list is set equal to 16. The selected candidate index is signalled. FIG. 29 illustrates the spatial GPM candidates. The list is reordered using template (FIG. 30) where SAD between the prediction and reconstruction of the template is used for ordering. The template size is fixed to 1. FIG. 30 illustrates the GPM template. For each partition mode, an IPM list is derived for each part using the same intra-inter GPM list derivation. The IPM list size is set to 3. In the list, TIMD derived mode is replaced by 2 derived modes with horizontal and vertical orientations. The list is further augmented with block-vector based prediction candidates obtained from the adjacent and non-adjacent merge candidates coded in IntraTMP or IBC mode. The template cost is employed to select the up to 6 block vectors. The final list contains up to 9 predictors: 3 regular intra modes and up to 6 block vectors based predictors. The SGPM mode is applied with a restricted blocks size: 4<=width<=64, 4<=height<=64, width<height*8, height<width*8, width*height>=32. A PPS flag is coded to indicate whether no blending of two intra predictions is allowed. When this PPS flag is set to false, the following adaptive blending is also used for spatial GPM, where blending depth τ shown in Figure 28 is derived as follows: · If min (width, height) ==4, 1 / 2 τ is selected · else if min (width, height) ==8, τ is selected · else if min (width, height) ==16, 2 τ is selected · else if min (width, height) ==32, 4 τ is selected · else, 8 τ is selected. Otherwise (the PPS flag is set to true) , 1 / 4 τ is always used for spatial GPM coded blocks to make sure no blending is used when SGPM block has partition angle completely horizontal or vertical, and much narrower blending width is used when SGPM block has other partition angles. It is noted that the flag is set to true in current Common Test Conditions (CTC) for the screen content videos. FIG. 31 illustrates the GPM blending. 2.1.19 Directional planar mode Two additional planar modes where only the horizontal interpolation or only the vertical interpolation are used to obtain the predicted samples. For planar horizontal mode, only the horizontal linear interpolation is performed based on the left reference sample and the top-right reference sample to predict the current sample as: pred (x, y) = ( (W - 1 - x)*rec (-1, y) + (x + 1) *rec (W, -1) + (W >> 1) ) >> log2 (W) For planar vertical mode, only the vertical linear interpolation is performed based on the above reference sample and the bottom-left reference sample to predict the current sample as: pred (x, y) = ( (H - 1 - y) *rec (x, -1) + (y + 1) *rec (-1, H) + (H >> 1) ) >> log2 (H) The transform kernel selection for planar horizontal and planar vertical mode is shown in FIG. 32. If an intra prediction mode of a current block is the planar vertical mode, the horizontal intra prediction mode is used to derive a transform kernel in MTS set and LFNST set. Also, if an intra prediction mode of a current block is the planar horizontal mode, the vertical intra prediction mode is used to derive a transform kernel in MTS set and LFNST set. FIG. 32 illustrates the transform selection process for directional planar modes. 2.1.20 Direct block vector (DBV) for chroma block The direct block vector is used for chroma blocks. A flag is signaled to indicate whether a chroma block is coded using IBC mode. If one of the luma blocks in five locations shown in FIG. 33 is coded with IBC or intraTMP mode, its block vector is scaled and is used as block vector for the chroma block. Template matching is used to perform block vector scaling. FIG. 33 illustrates the luma blocks used to derive direct block vector. 2.1.21 Extrapolation filter-based intra prediction (EIP) mode In the EIP mode, the samples in a CU are predicted from the top-left position to the bottom-right position by applying an extrapolation filter to neighboring reconstructed samples or predicted samples. The EIP mode uses a 15-tap filter for prediction as below: , where pred(x, y) is the predicted value at position (x, y) in the CU, ci is the filter coefficient, and the is the reconstructed samples or predicted samples. Predicted sample values are clipped to the range of the reference samples instead of the full sample value range. Reference sample area used for determining the range is the same that is used when generating the filter coefficients. The EIP filter can be derived from the neighboring reconstructed samples or be inherited from the previous EIP coded blocks. There are three EIP filter shapes and three types of reconstructed area supported in ECM as shown in FIG. 34 and FIG. 35, respectively. FIG. 34 illustrates the three EIP filter shapes. FIG. 35 illustrates the three types of reconstructed area for EIP filter. For a CU coded in the EIP mode, an EIP merge flag is signaled to indicate whether the EIP filter is inherited from previous blocks coded in EIP mode. When the EIP merge flag is true, an EIP merge list is constructed from the spatial adjacent, spatial non-adjacent, temporal and history candidates. The position and inclusion order of these candidates are the same as those used in CCP merge candidate list. An EIP merge index is further signaled to indicate which EIP merge candidate is selected. The filter shape and the filter coefficients of the selected candidate are then inherited to code the CU. When the EIP merge flag is false, the EIP filter is derived from the neighboring reconstructed samples and the relevant syntax element is signaled to indicate which one of the three types of reconstructed area and which one of the three filter shapes are used for the CU. The selected filter moves in the selected reconstructed area either horizontally or vertically with a one-pixel step to construct the auto-correlation matrix and the cross-correlation vector. The calculation of coefficients from the auto-correlation matrix and the cross-correlation vector is similar to that of CCCM with added L-2 regularization. The coefficients are computed as Where λ is the regularization parameters. L2-regularization is achieved by a diagonal matrix λI being added to the ‘ATA’ matrix. A subset of the coefficients can be relaxed (unregularized) . In this case, when the ith coefficient is relaxed, the (ith row, ith column) entry of the diagonal matrix λI is set to zero. In regularized EIP scheme: · λ = M·pEIP, where pEIP = 15 is the number of filter taps in EIP. ○ M = 192 when the number of input samples nSamples ≤ 2024, and thus λ = 2880. ○ M = 128 otherwise, and thus λ = 1920. · The bias term of EIP is relaxed (unregularized) : the bottom-right entry of the diagonal matrix is set to zero. After generating the prediction samples of the CU using the EIP filter, an intra prediction mode is derived by applying the DIMD process to the prediction samples. Specifically, a horizontal gradient and a vertical gradient are calculated for each predicted sample to build a histogram of gradient. Then the intra prediction mode corresponding to the largest histogram count is used to determine the LFNST, NSPT or MTS transform set. 2.1.22 Matrix based intra prediction replacing existing conventional intra modes A matrix of weights, which are defined for a block shape and intra mode, is introduced, those weights are multiplied by the neighbour reference template to derive the prediction samples replacing conventional intra prediction. The weights are applied to the reference samples of the L shaped causal neighborhood template as shown in the FIG. 36. FIG. 36 illustrates the L shaped neighborhood for a given predicted block. The reference samples in the causal neighborhood are denoted as r, and F (x, y) is the matrix of weights. Then the prediction P (x, y) can be derived as P(x, y) = ∑k F (x, y, k) *r (k) , where k denotes the index of the reference sample in the template. In the test, this prediction is used for block size with both width and height up to 32 (except for 4x32, 32x4, 8x32 and 32x8) . The template size is 2 for blocks with both width and height up to 16 and it is only used for mode 0, 1, and (2+2*k) . For other blocks, template size is set to 1; is used for mode 0, 1, and (2+4*k) ; prediction is only performed for 16x16 positions, and the rest of the samples are generated by bilinear interpolation. For all block sizes, block shape and mode-based symmetry is used. Reference length is set to W and H for modes greater than 18 and less than 50 and set to 2*W and 2*H otherwise. 2.1.23 Modifications to matrix-based intra prediction Matrix sizes of the MIP modes are increased for the blocks with sizes up to 32x32, excluding of 4x32, 32x4, 8x32 and 32x8. The proposed matrices use the L-shaped causal template as input to generate the WxH prediction block. The prediction of a sample P (x, y) can be derived as: P(x, y) = ∑k F (x, y, k) *r (k) , Where r (k) is the kth item in the L-shaped template, and F (x, y) is the matrix weights corresponding to the position (x, y) . The size of the prediction block generated by matrix multiplication equals to the current block size. 2.1.24 Adaptive reordering of non-CCP chroma modes The non-CCP chroma intra modes are adaptively reordered with template matching. A candidate list is firstly constructed with the following modes: - DBV, DM, DIMD, Planar, horizontal, vertical, DC; - luma modes from the position of TL, TR, BL and BR in the collocated luma block; - chroma modes from the adjacent chroma blocks in the position of L', T', BL', TR'and TL'; - luma BVs from the positions of C, TL, TR, BL and BR in the collocated luma block. FIG. 37 illustrates the collocated luma block and adjacent chroma block. Then, these chroma modes in the candidate list are used to predict the collocated luma block and the template of the chroma block. This template comprises one top row and one left column of the chroma block. The modes in the list are reordered based on a combined SATD cost, calculated as follows: cost = 8*costY + (costCbTop + costCrTop) << (logH+2) + (costCbLeft + costCrLeft) << (logW+2) . After reordering, the first N modes in the list are kept and are allowed for the chroma block. The value of N is set to equal to 7 if at least one of the luma modes from five collocated luma positions is coded with IBC or intraTMP mode. Otherwise, the value of N is set to equal to 6. 2.2 InterCCCM InterCCCM applies the CCCM method for predicting chroma samples from reconstructed luma samples when the CU uses inter prediction or intra block copy (IBC) . FIG. 38 illustrates the decoder side of the method. The cross-component filters are derived using the prediction blocks of luma and chroma. The derived filters are applied to the reconstructed luma block and blended with the prediction blocks of chroma to produce the final chroma prediction blocks. In the blending process the filtered reconstructed luma blocks use blending weight of 0.75 and chroma prediction blocks use blending weight of 0.25. FIG. 38 illustrates the InterCCCM method on the decoder. The 8-tap filter consist of 6 spatial luma samples, a nonlinear term, and a bias term. The spatial luma samples (L0, …, L5) are obtained from the luma grid selecting the 6 luma samples closest to the chroma position C without down sampling as shown in FIG. 39. The predicted chroma value is obtained as, predChromaVal = c0 L0 + c1L1 + c2L2 + c3L3 + c4L4 + c5L5 + c6 nonlinear ( (L0+L3+1) >> 1) + c7 B, where nonlinear is CCCM’s nonlinear operator and B is bias. The filter coefficients are derived using ECM’s division-free Gaussian elimination method and the necessary offsets are applied to samples prior to filter derivation. The offsets for division-free Gaussian elimination method are obtained using a four-point average of the luma and chroma prediction blocks, where the four points correspond to the top-left, top-right, bottom-left and bottom-right corners of the blocks. For filter coefficient derivation at most 256 chroma samples are used. FIG. 39 illustrates the luma samples L0,.., L5 in relation to the chroma sample C. Usage of the mode is signalled with a CABAC coded TU level flag. One new CABAC context was included to support this. The InterCCCM flag is only signalled if the TU’s luma Cbf is non-zero and the CU’s predMode is either MODE_INTER or MODE_IBC. The encoder performs an RD decision in the transform selection loop for the chroma components when luma Cbf is non-zero and the CU’s predMode is either MODE_INTER or MODE_IBC. 2.3 InterCCP merge mode The intraCCP merge mode is extended to inter coding blocks, where the final chroma inter prediction combines motion-compensation predicted signals and cross-component predicted signals derived using an inherited CCP model from a CCP merge list. A decoder derived intraCCCM candidate is inserted at the front of the interCCP candidate list. In addition to the decoder derived intraCCCM candidate, a set of CCP candidates (i.e. spatial adjacent, temporal, spatial non-adjacent, history-based, shifted temporal, and default candidates) are inherited from previous coded blocks. 2.4 Block vector guided CCCM The block vector guided CCCM (BVG-CCCM) method uses block vectors of the co-located luma blocks, coded in IBC or intraTMP modes, to determine the reference area for calculating the CCCM parameters. Then the reference area in luma and corresponding area in chroma channel is used to calculate the CCCM parameters. The prediction uses the calculated model parameters and co-located luma samples to do the CCCM prediction. FIG. 40 illustrates the reference area in BVG-CCCM method. The mode is enabled only in intra slices. Moreover, an SPS-level flag is introduced for enabling or disabling the mode. The BVG-CCCM mode uses an 11-tap filter for cross-component prediction as below: predChromaVal = c0C + c1N + c2S + c3E + c4W + c5P (C) + c6P (N) + c7P (S) + c8P (W) + c9P (E) + c10B The input to the spatial 5-tap component of the filter consists of a center (C) luma sample which is collocated with the chroma sample to be predicted and its above / north (N) , below / south (S) , left / west (W) and right / east (E) neighbors as illustrated in FIG. 41. The nonlinear term P is represented as power of two of the corresponding luma sample and B is the bias term. FIG. 40 illustrates the reference area for BVG-CCCM. FIG. 41 illustrates the spatial part of the convolutional filter. Similar to Direct Block Vector (DBV) mode in ECM-9.0, five locations, as shown in FIG. 42, in collocated luma block area are scanned and the associated block vectors are then used for determining the reference area for parameter calculation in BVG-CCCM method. The mode can use block vector (s) of both IBC and intraTMP coded blocks from co-located luma area. FIG. 42 illustrates the locations used for block vector derivation from co-located luma block. 2.4.1 Bitstream Signalling Usage of the mode is signalled with a CABAC coded PU level flag. The BVG-CCCM flag is signalled if co-located block is coded in IBC or intraTMP modes and the cross-component index is LM_CHROMA_IDX or MMLM_CHROMA_IDX. 2.4.2 Encoder Operation The encoder performs two additional RD for the BVG-CCCM for single-model and multi-model CCCM variants. 3 Problems Below issues exist in the current video coding techniques and can be improved. 1) In an existing design, an intra chroma reordering mode is applied, and the non-CCP intra chroma modes are reordered based on template costs. After reordering, the first three non-CCP intra chroma modes may no longer be DBV mode, DM mode, and DIMD chroma mode. However, the parsing stage of such three non-CCP intra chroma modes is still dependent on the availability of the DBV mode and DIMD chroma mode, which is asserted to be suboptimal. 2) Regarding to non-regular intra modes, the DM process and transform kernel derivation may be optimized. 3) Regarding to non-regular intra modes and blended modes, the derivation and usage of intra mode information and inter motion data may be optimized. 4 Detailed solutions The detailed embodiments below should be considered as examples to explain general concepts. These embodiments should not be interpreted in a narrow way. Furthermore, these embodiments can be combined in any manner. The terms “video unit” or “coding unit” or “block” may represent a picture, a slice, a tile, a coding tree block (CTB) , a coding tree unit (CTU) , a coding block (CB) , a CU, a PU, a TU, a PB, or a TB. The term “matrix based intra prediction” and / or “neural network based intra prediction” may refer to any intra prediction method wherein the prediction sample values are derived based on matrix multiplication of reference samples and (pre-defined) matrices. For example, it may refer to MIP (i.e., matrix based intra prediction) , PDP (i.e., position dependent prediction) , MPDIP (i.e., matrix-based position-dependent intra-prediction) , PNN (i.e., neural network based prediction) mode, NNIP / NNintra (i.e., neural network based intra prediction) , and / or a variant mode of these modes. The term “CCP” may refer to any cross-component prediction method such as any kind of LM / intraCCLM / interCCCM / MMLM / CCCM / GLM / GL-CCCM / intraCCPmerge / interCCPmerge. It could be used for an intra block, inter block, or IBC block. It could be a type of CCP based fusion mode. It is noted that the terminologies mentioned below are not limited to the specific ones defined in existing standards. Any variance of the coding tool is also applicable. 1) When the chroma intra mode reordering is used to the current video unit, the signalling of the first nonCCP flag (i.e., DBV chroma flag) may not be dependent on the availability of IBC and / or intraTMP coded collocated luma blocks. a) Furthermore, for example, in such case, the signalling of the first nonCCP flag (e.g., DBV chroma flag) may not be dependent on whether intra DBV chroma mode is allowed to be used. 2) When the chroma intra mode reordering is used, the signalling of the third nonCCP flag (e.g., DIMD chroma flag) , may not be dependent on whether DIMD chroma mode is used. 3) If a chroma block is DM intra coded, and its collocated luma is coded with one of the following methods, the chroma prediction may be derived based on DIMD (rather than Planar) . a) MIP b) SGPM c) intraTMP d) NNintra e) EIP f) TIMD g) MRL. 4) The transform kernel (e.g., LFNST, NSPT, MTS, etc. ) derivation for an SGPM / MIP / intraTMP / NNintra / EIP / TIMD / TMRL / PDP / PDP-MIP / Planar / regularIntra / Inter / GPM coded block may be based on the first DIMD mode, the second DIMD, and Planar mode. a) For example, the first DIMD mode, or the second DIMD, or Planar mode may be used to derive the transform kernel index from a look-up-table (LUT) . b) For example, the first and the second DIMD modes may be derived based on histogram of gradient (i.e., HoG) calculation. c) For example, whether or not to use the first DIMD mode may be signalled based on syntax element (s) (e.g., a flag, an index, etc. ) . d) For example, if the first DIMD mode is not used to derive the transform kernel, Planar or the second DIMD mode may be used. i) For example, in such case, whether to use Planar or the second DIMD mode may be determined based on a pre-defined rule. (1) For example, the pre-defined rule may be that the second DIMD mode is used to derive the transform kernel, only if the first DIMD mode is Planar. (2) For example, the pre-defined rule may be that the Planar is used to derive the transform kernel, if the first DIMD mode is not Planar. 5) The transform kernel (e.g., LFNST, NSPT, MTS, etc. ) derivation for an SGPM / MIP / intraTMP / NNintra / EIP / TIMD / TMRL / PDP / PDP-MIP / Planar / regularIntra / Inter / GPM coded block may be based on the first DIMD mode. a) For example, the first DIMD mode may be used to derive the transform kernel index from a look-up-table (LUT) . b) For example, the first DIMD mode may be derived based on histogram of gradient (i.e., HoG) calculation. c) For example, the first DIMD mode may be always used to derive the transform kernel for a certain prediction mode (e.g., without signalling) . 6) The transform kernel (e.g., LFNST, NSPT, MTS, etc. ) derivation for an SGPM / MIP / intraTMP / NNintra / EIP / TIMD / TMRL / PDP / PDP-MIP / Planar / regularIntra / Inter / GPM coded block may be based on Planar mode. a) For example, Planar mode may be used to derive the transform kernel index from a look-up-table (LUT) . b) For example, Planar mode may be derived based on histogram of gradient (i.e., HoG) calculation. c) For example, Planar mode may be always used to derive the transform kernel for a certain prediction mode (e.g., without signalling) . 7) A converted information (e.g., intra mode information, motion data, etc. ) may be derived for EIP / MIP / SGPM / intraTMP mode, and such derived mode may be stored in the buffer for future usage for the current block or future coded block. a) For example, a regular intra mode (e.g., angular mode, etc. ) or a motion data (e.g., block vector, etc. ) may be computed based on histogram of gradients. b) For example, a regular intra mode or a motion data (e.g., motion vector, reference index, prediction direction, block vector, etc. ) may be computed based on previously coded blocks (adjacent, or non-adjacent, or temporal to the current block) . c) For example, the derived regular intra mode, or motion data may be stored in a buffer and used for later coding process. d) For example, the regular intra mode may be used for the derivation of transform kernels (e.g., MTS, LFNST, NSPT, etc. ) for the current block. e) For example, the regular intra mode may be used for the construction of the intra prediction most list for a future coded block. f) For example, the motion data may be used for the construction of the motion list for a future coded block. 1) For example, the block vector may be used for IBC mode, intraTMP mode, DBV chroma mode, BV guided CCCM mode, BV guided DIMD mode, BV guided EIP mode, and etc. 2) For example, the motion vector may be used for inter mode, and etc. 8) A converted motion data (e. g, motion vector, reference index, prediction direction, block vector, etc. ) may be derived for SGPM / GPMintra mode, and such derived mode may be stored in the buffer for future usage for the current block or future coded block. a) For example, a motion data may be derived based on previously coded blocks (adjacent, or non-adjacent, or temporal to the current block) . b) For example, a motion data may be derived for an intra partition of a SGPM coded block. c) For example, a motion data may be derived for an intra partition of a GPM inter-intra coded block. d) For example, the motion data may be used for the construction of the motion list for a future coded block.General aspect: 9) The disclosed method may be used in single tree. 10) The disclosed method may be used in dual tree. 11) The disclosed method may be used for chroma coding. 12) The disclosed method may be used for luma coding. 13) The disclosed method may be used for intra block coding. 14) The disclosed method may be used for inter block coding. 15) The disclosed method may be used for IBC block coding. 16) The disclosed method may be used in a inter (such as B or P) slice. 17) The disclosed method may be used in an intra (such as I) slice. 18) Whether to and / or how to apply the disclosed methods above may be signalled at sequence level / group of pictures level / picture level / slice level / tile group level, such as in sequence header / picture header / SPS / VPS / DPS / DCI / PPS / APS / slice header / tile group header. a) For example, whether the disclosed method is applied to a sequence (or, group of pictures, etc. ) may be dependent on the SPS (or PPS, etc. ) flag. b) For example, the disclosed methods may be applied to SCC sequences only. i. For example, it may be controlled by the SPS / PPS flag. ii. For example, it may be determined based on an implicit rule which does not require a syntax element signalling (e.g., an implicit SCC content detection, etc. ) . 19) Whether to and / or how to apply the disclosed methods above may be signalled at PB / TB / CB / PU / TU / CU / VPDU / CTU / CTU row / slice / tile / sub-picture / other kinds of region contain more than one sample or pixel. 20) Whether to and / or how to apply the disclosed methods above may be dependent on coded information, such as block size, colour format, single / dual tree partitioning, colour component, slice / picture type.
[0100] More details of the embodiments of the present disclosure will be described below which are related to video coding. The embodiments of the present disclosure should be considered as examples to explain the general concepts and should not be interpreted in a narrow way. Furthermore, these embodiments can be applied individually or combined in any manner.
[0101] As used herein, the term “block” may represent a coding tree block (CTB) , a coding tree unit (CTU) , a coding block (CB) , a coding unit (CU) , a prediction unit (PU) , a transform unit (TU) , a prediction block (PB) , a transform block (TB) , a subblock, a tile, a slice, a subpicture, a video processing unit comprising multiple samples / pixels, and / or the like. A block may be rectangular or non-rectangular.
[0102] FIG. 43 illustrates a flowchart of a method 4300 for video processing in accordance with embodiments of the present disclosure. The method 4300 is implemented during a conversion between a video unit of a video and a bitstream of the video. As shown in FIG. 43, the method 4300 starts at 4310, where a transform kernel for the current video block is determined based on at least one of the following: a first intra mode derived based on a decoder side intra mode derivation (DIMD) scheme, a second intra mode derived based on the DIMD scheme, or a planar mode.
[0103] In some embodiments, the current video block may be coded with at least one of the following: a spatial geometric partitioning mode (SGPM) , a matrix-based intra prediction (MIP) , an intra template matching prediction (intraTMP) , a neural network based intra prediction (NNintra) , an extrapolation filter-based intra prediction (EIP) , a template-based intra mode derivation (TIMD) , a template-based multiple reference line (TMRL) , a position dependent prediction (PDP) , a position dependent prediction based matrix weighted intra prediction (PDP-MIP) , a planar mode, a regular intra mode, an inter mode, or a geometric partitioning mode (GPM) .
[0104] In some embodiments, the current video block may be coded with a coding mode without angular information, i.e., a coding mode not having angular information. For example, such a coding mode may be a non-angular regular intra mode (such as planar mode or the like) , SGPM mode, MIP mode, intraTMP mode, NNintra mode, EIP mode, TIMD mode, TMRL mode, PDP mode, PDP-MIP mode, Planar mode, inter mode, GPM mode, or the like. It should be understood that the above examples are described merely for purpose of description. The scope of the present disclosure is not limited in this respect.
[0105] In some embodiments, the first intra mode may be an intra mode with the lowest cost, and the second intra mode may be an intra mode with the second-lowest cost. In some embodiments, the transform kernel may be used for at least one of the following: a low-frequency non-separable transform (LFNST) , a non-separable primary transform (NSPT) , or a multiple transform selection (MTS) .
[0106] At 4320, the conversion is performed based on the transform kernel. In some embodiments, the conversion may include encoding the current video block into the bitstream. Alternatively or additionally, the conversion may include decoding the current video block from the bitstream. It should be understood that the above illustrations and / or examples are described merely for purpose of description. The scope of the present disclosure is not limited in this respect.
[0107] In view of the above, a transform kernel is determined based on a first intra mode and / or a second intra mode derived based on DIMD and / or a planar mode. Compared with the conventional solution, the proposed method can advantageously optimize the process of transform kernel derivation, thereby improving coding quality.
[0108] In some embodiments, all of the first intra mode, the second intra mode and the planar mode may be allowed to be used for determining the transform kernel. It should be noted that not all of the first intra mode, the second intra mode and the planar mode are necessary to be used for determining the transform kernel, and other situations will be described below in detail.
[0109] In some embodiments, at least one of the first intra mode, the second intra mode or the planar mode may be used to determine a transform kernel index from a look-up table (LUT) , to determine the transform kernel. By way of example rather than limitation, the LUT may store a mapping relationship between coding modes and transform kernel indexes.
[0110] In some embodiments, in the DIMD scheme, the first intra mode and the second intra mode may be derived based on a determination of a histogram of gradients (HoG) . In some embodiments, the HoG may be determined based on predicted samples of the current video block or reconstructed samples of at least one neighboring block of the current video block. By way of example rather than limitation, the HoG may be built by applying edge operators to a reference area (such as at least one neighboring block of the current video block or the like) . The edge operators are used to derive the direction and magnitude (amplitude) of gradients within the area covered by an edge operator.
[0111] In some embodiments, information regarding whether to use the first intra mode to determine the transform kernel may be indicated in the bitstream, for example, through a syntax element (s) (e.g., a flag, an index, etc. ) .
[0112] In some embodiments, if the first intra mode is not used to determine the transform kernel, the second intra mode or the planar mode may be used to determine the transform kernel. In one example embodiment, whether to use the second intra mode or the planar mode is used to determine the transform kernel may be determined based on a predetermined rule. For example, the predetermined rule may specify that: only if the first intra mode is the planar mode, the second intra mode is used to determine the transform kernel. In a further example, the predetermined rule may specify that: if the first intra mode is not the planar mode, the planar mode is used to determine the transform kernel.
[0113] In some embodiments, only the first intra mode may be allowed to be used for determining the transform kernel. For example, the first intra mode may be used to determine a transform kernel index from a look-up table (LUT) , to determine the transform kernel. In some embodiments, in the DIMD scheme, the first intra mode may be derived based on a determination of a histogram of gradients (HoG) . In some embodiments, if the current video block is coded with a first prediction mode, the first intra mode may be used to determine the transform kernel. For example, the first intra mode may be always used to determine the transform kernel for a video block coded with the first prediction mode (such as, SGPM, GPM or the like) . By way of example, if the current video block is coded with the first prediction mode, it is inferred that the first intra mode is used to determine the transform kernel, i.e., this information is not signaled in the bitstream.
[0114] In some embodiments, only the planar mode may be allowed to be used for determining the transform kernel. For example, the planar mode may be used to determine a transform kernel index from a look-up table (LUT) , to determine the transform kernel. In some embodiments, the planar mode may be derived based on a determination of a histogram of gradients (HoG) . In some embodiments, if the current video block is coded with a second prediction mode, the planar mode may be used to determine the transform kernel. For example, the planar mode may be always used to determine the transform kernel for a video block coded with the second prediction mode (such as, MIP, EIP or the like) . By way of example, if the current video block is coded with the second prediction mode, it is inferred that the planar mode is used to determine the transform kernel, i.e., this information is not signaled in the bitstream.
[0115] In some embodiments, if the current video block is coded with a third intra mode, information associated with the third intra mode may be converted to obtain converted information, and the third intra mode may comprise at least one of the following: EIP, MIP, SGPM, intraTMP. In some embodiments, the information associated with the third intra mode may comprise at least one of the following: intra mode information or motion data. For example, the motion data may comprise a motion vector, a reference index, a prediction direction, a block vector, and / or the like.
[0116] In some embodiments, the converted information may be stored in a buffer for a subsequent coding process of the current video block or a coding process of a subsequent video block of the current video block. By way of example rather than limitation, the converted information may comprise a regular intra mode, converted motion data, and / or the like.
[0117] In some embodiments, the regular intra mode comprises an angular mode. In some embodiments, the converted information is determined based on a histogram of gradients. For example, the histogram of gradients may be determined based on predicted samples of the current video block or reconstructed samples of at least one neighboring block of the current video block. By way of example rather than limitation, the histogram of gradients may be built by applying edge operators to a reference area (such as at least one neighboring block of the current video block or the like) . The edge operators are used to derive the direction and magnitude (amplitude) of gradients within the area covered by an edge operator.
[0118] In some embodiments, the converted information may be determined based on at least one block coded before the current video block. In some embodiments, the at least one block may comprise at least one of the following: a spatial adjacent block of the current video block, a spatial non-adjacent block of the current video block, or a temporal neighboring block of the current video block.
[0119] In some embodiments, the regular intra mode may be used to determine a transform kernel for the current video block. Additionally or alternatively, the regular intra mode may be used to construct an intra prediction mode list for the subsequent video block.
[0120] In some embodiments, the converted motion data may be used to construct a motion list for the subsequent video block. In some further embodiments, the converted motion data may comprise a block vector (BV) , and the block vector is used for at least one of the following: an intra block copy (IBC) mode, an intraTMP mode, a direct block vector (DBV) chroma mode, a BV guided convolutional cross-component model (CCCM) mode, a BV guided DIMD mode, or a BV guided EIP mode. In some other embodiments, the converted motion data may comprise a motion vector, and the motion vector may be used for an inter mode.
[0121] In some embodiments, if the current video block is coded with a fourth intra mode, motion data for the fourth intra mode may be converted to obtain converted motion data, and the fourth intra mode may comprise an SGPM mode and / or an GPM intra-based mode.
[0122] In some embodiments, the converted motion data may be stored in a buffer for a subsequent coding process of the current video block or a coding process of a subsequent video block of the current video block.
[0123] In some embodiments, the converted motion data may be determined based on at least one block coded before the current video block. In some further embodiments, the at least one block may comprise at least one of the following: a spatial adjacent block of the current video block, a spatial non-adjacent block of the current video block, or a temporal neighboring block of the current video block.
[0124] In some embodiments, the current video block may be coded with the SGPM mode, and the converted motion data may be determined for an intra partition of the current video block. In some further embodiments, the current video block may be coded with a GPM inter-intra mode, and the converted motion data may be determined for an intra partition of the current video block. In some other embodiments, the converted motion data may be used to construct a motion list for the subsequent video block.
[0125] In some embodiments, if chroma intra mode reordering is applied to a chroma block of the current video block, signaling of a first non-cross-component-prediction (nonCCP) flag may be independent from at least one of the following: an availability of an IBC-coded collocated luma block or an availability of an intraTMP-coded collocated luma block. The chroma intra mode reordering has been described in detail in the above section 2.1.24 Adaptive reordering of non-CCP chroma modes, and thus it will not be repeated here.
[0126] In addition, the first nonCCP flag may indicate whether a first nonCCP chroma intra mode is used to code the chroma block. The first nonCCP chroma intra mode may be a nonCCP chroma intra mode that is at the first position after the chroma intra mode reordering. By way of example rather than limitation, the first nonCCP flag may be a DBV chroma flag. In some embodiments, the signaling of the first nonCCP flag may be independent from whether the first nonCCP chroma intra mode is allowed to be used.
[0127] In some embodiments, if chroma intra mode reordering is applied to a chroma block of the current video block, signaling of a third nonCCP flag may be independent from whether a third nonCCP chroma intra mode is used, and the third nonCCP flag may indicate whether the third nonCCP chroma intra mode is used to code the chroma block, and the third nonCCP chroma intra mode may be a nonCCP chroma intra mode that is at the third position after the chroma intra mode reordering. By way of example rather than limitation, the third nonCCP flag may be a DIMD chroma flag.
[0128] In some embodiments, a prediction for a chroma block of the current video block may be determined based on DIMD, if the chroma block is coded with a derived mode (DM) intra mode and a collocated luma block of the chroma block is coded with one of the following: an MIP, an SGPM, an intraTMP, an NNintra, an EIP, a TIMD, or an MRL.
[0129] In some embodiments, the method may be applied for at least one of the following: a single tree partition, a dual tree partition, a chroma coding, a luma coding, an inter block coding, an intra block coding, an IBC coding, an intra slice, or an inter slice.
[0130] In some embodiments, whether to and / or how to apply the method may be indicated at one of the following: a sequence level, a group of pictures level, a picture level, a slice level, or a tile group level.
[0131] In some embodiments, whether to and / or how to apply the method may be indicated in one of the following: a sequence header, a picture header, a sequence parameter set (SPS) , a video parameter set (VPS) , a decoding parameter set (DPS) , a decoding capability information (DCI) , a picture parameter set (PPS) , an adaptation parameter sets (APS) , a slice header, or a tile group header.
[0132] In some embodiments, whether the method is applied to a sequence may be dependent on an SPS flag, or whether the method is applied to a group of pictures may be dependent on an PPS flag.
[0133] In some embodiments, the method may be applied to a screen content coding (SCC) sequence. In some further embodiments, whether the method is applied to a screen content coding (SCC) sequence may be controlled by an SPS flag or a PPS flag. In some other embodiments, whether the method is applied to a screen content coding (SCC) sequence may be determined based on an implicit rule which does not require syntax element signaling.
[0134] In some embodiments, whether to and / or how to apply the method may be indicated at a region containing more than one sample or pixel. By way of example rather than limitation, the region may comprise at least one of the following: a prediction block (PB) , a transform block (TB) , a coding block (CB) , a prediction unit (PU) , a transform unit (TU) , a coding unit (CU) , a virtual pipeline data unit (VPDU) , a coding tree unit (CTU) , a CTU row, a slice, a tile, or a sub-picture.
[0135] In some embodiments, whether to and / or how to apply the method may be dependent on coded information. By way of example rather than limitation, the coded information may comprise at least one of the following: a block size, a color format, a single tree partitioning, a dual tree partitioning, a color component, a slice type, or a picture type.
[0136] In view of the above, the solutions in accordance with some embodiments of the present disclosure can advantageously improve coding efficiency and coding quality.
[0137] According to further embodiments of the present disclosure, a non-transitory computer-readable recording medium is provided. The non-transitory computer-readable recording medium stores a bitstream of a video which is generated by a method performed by an apparatus for video processing. The method comprises: determining a transform kernel for a current video of the video based on at least one of the following: a first intra mode derived based on a decoder side intra mode derivation (DIMD) scheme, a second intra mode derived based on the DIMD scheme, or a planar mode; and generating the bitstream based on the transform kernel.
[0138] According to still further embodiments of the present disclosure, a method for storing bitstream of a video is provided. The method comprises: determining a transform kernel for a current video of the video based on at least one of the following: a first intra mode derived based on a decoder side intra mode derivation (DIMD) scheme, a second intra mode derived based on the DIMD scheme, or a planar mode; generating the bitstream based on the transform kernel; and storing the bitstream in a non-transitory computer-readable recording medium.
[0139] Implementations of the present disclosure can be described in view of the following clauses, the features of which can be combined in any reasonable manner.
[0140] Clause 1. A method for video processing, comprising: determining, for a conversion between a current video block of a video and a bitstream of the video, a transform kernel for the current video block based on at least one of the following: a first intra mode derived based on a decoder side intra mode derivation (DIMD) scheme, a second intra mode derived based on the DIMD scheme, or a planar mode; and performing the conversion based on the transform kernel.
[0141] Clause 2. The method of clause 1, wherein the current video block is coded with a coding mode without angular information.
[0142] Clause 3. The method of any of clauses 1-2, wherein the current video block is coded with at least one of the following: a spatial geometric partitioning mode (SGPM) , a matrix-based intra prediction (MIP) , an intra template matching prediction (intraTMP) , a neural network based intra prediction (NNintra) , an extrapolation filter-based intra prediction (EIP) , a template-based intra mode derivation (TIMD) , a template-based multiple reference line (TMRL) , a position dependent prediction (PDP) , a position dependent prediction based matrix weighted intra prediction (PDP-MIP) , a planar mode, a regular intra mode, an inter mode, or a geometric partitioning mode (GPM) .
[0143] Clause 4. The method of any of clauses 1-3, wherein the first intra mode is an intra mode with the lowest cost, and the second intra mode is an intra mode with the second-lowest cost.
[0144] Clause 5. The method of any of clauses 1-4, wherein the transform kernel is used for at least one of the following: a low-frequency non-separable transform (LFNST) , a non-separable primary transform (NSPT) , or a multiple transform selection (MTS) .
[0145] Clause 6. The method of any of clauses 1-5, wherein all of the first intra mode, the second intra mode and the planar mode are allowed to be used for determining the transform kernel.
[0146] Clause 7. The method of clause 6, wherein at least one of the first intra mode, the second intra mode or the planar mode is used to determine a transform kernel index from a look-up table (LUT) , to determine the transform kernel.
[0147] Clause 8. The method of any of clauses 6-7, wherein in the DIMD scheme, the first intra mode and the second intra mode are derived based on a determination of a histogram of gradients (HoG) .
[0148] Clause 9. The method of clause 8, wherein the HoG is determined based on predicted samples of the current video block or reconstructed samples of at least one neighboring block of the current video block.
[0149] Clause 10. The method of any of clauses 1-9, wherein information regarding whether to use the first intra mode to determine the transform kernel is indicated in the bitstream.
[0150] Clause 11. The method of any of clauses 1-10, wherein in accordance with that the first intra mode is not used to determine the transform kernel, the second intra mode or the planar mode is used to determine the transform kernel.
[0151] Clause 12. The method of clause 11, wherein whether to use the second intra mode or the planar mode is used to determine the transform kernel is determined based on a predetermined rule.
[0152] Clause 13. The method of clause 12, wherein the predetermined rule specifies that: only in accordance with that the first intra mode is the planar mode, the second intra mode is used to determine the transform kernel.
[0153] Clause 14. The method of any of clauses 12-13, wherein the predetermined rule specifies that: in accordance with that the first intra mode is not the planar mode, the planar mode is used to determine the transform kernel.
[0154] Clause 15. The method of any of clauses 1-5, wherein only the first intra mode is allowed to be used for determining the transform kernel.
[0155] Clause 16. The method of clause 15, wherein the first intra mode is used to determine a transform kernel index from a look-up table (LUT) , to determine the transform kernel.
[0156] Clause 17. The method of any of clauses 15-16, wherein in the DIMD scheme, the first intra mode is derived based on a determination of a histogram of gradients (HoG) .
[0157] Clause 18. The method of any of clauses 1-17, wherein in accordance with that the current video block is coded with a first prediction mode, the first intra mode is used to determine the transform kernel.
[0158] Clause 19. The method of any of clauses 1-5, wherein only the planar mode is allowed to be used for determining the transform kernel.
[0159] Clause 20. The method of clause 19, wherein the planar mode is used to determine a transform kernel index from a look-up table (LUT) , to determine the transform kernel.
[0160] Clause 21. The method of any of clauses 19-20 wherein the planar mode is derived based on a determination of a histogram of gradients (HoG) .
[0161] Clause 22. The method of any of clauses 1-21, wherein in accordance with that the current video block is coded with a second prediction mode, the planar mode is used to determine the transform kernel.
[0162] Clause 23. The method of any of clauses 1-22, wherein in accordance with that the current video block is coded with a third intra mode, information associated with the third intra mode is converted to obtain converted information, and wherein the third intra mode comprises at least one of the following: EIP, MIP, SGPM, intraTMP.
[0163] Clause 24. The method of clause 23, wherein the information associated with the third intra mode comprises at least one of the following: intra mode information or motion data.
[0164] Clause 25. The method of any of clauses 23-34, wherein the converted information is stored in a buffer for a subsequent coding process of the current video block or a coding process of a subsequent video block of the current video block.
[0165] Clause 26. The method of any of clauses 23-25, wherein the converted information comprises at least one of the following: a regular intra mode or converted motion data.
[0166] Clause 27. The method of clause 26, wherein the regular intra mode comprises an angular mode.
[0167] Clause 28. The method of any of clauses 23-27, wherein the converted information is determined based on a histogram of gradients.
[0168] Clause 29. The method of any of clauses 23-28, wherein the converted information is determined based on at least one block coded before the current video block.
[0169] Clause 30. The method of clause 29, wherein the at least one block comprises at least one of the following: a spatial adjacent block of the current video block, a spatial non-adjacent block of the current video block, or a temporal neighboring block of the current video block.
[0170] Clause 31. The method of any of clauses 26-30, wherein the regular intra mode is used to determine a transform kernel for the current video block.
[0171] Clause 32. The method of any of clauses 26-31, wherein the regular intra mode is used to construct an intra prediction mode list for the subsequent video block.
[0172] Clause 33. The method of any of clauses 26-32, wherein the converted motion data is used to construct a motion list for the subsequent video block.
[0173] Clause 34. The method of clause 33, wherein the converted motion data comprises a block vector (BV) , and the block vector is used for at least one of the following: an intra block copy (IBC) mode, an intraTMP mode, a direct block vector (DBV) chroma mode, a BV guided convolutional cross-component model (CCCM) mode, a BV guided DIMD mode, or a BV guided EIP mode.
[0174] Clause 35. The method of clause 33, wherein the converted motion data comprises a motion vector, and the motion vector is used for an inter mode.
[0175] Clause 36. The method of any of clauses 1-35, wherein in accordance with that the current video block is coded with a fourth intra mode, motion data for the fourth intra mode is converted to obtain converted motion data, and wherein the fourth intra mode comprises at least one of the following: an SGPM mode or an GPM intra-based mode.
[0176] Clause 37. The method of clause 36, wherein the converted motion data is stored in a buffer for a subsequent coding process of the current video block or a coding process of a subsequent video block of the current video block.
[0177] Clause 38. The method of any of clauses 36-37, wherein the converted motion data is determined based on at least one block coded before the current video block.
[0178] Clause 39. The method of clause 38, wherein the at least one block comprises at least one of the following: a spatial adjacent block of the current video block, a spatial non-adjacent block of the current video block, or a temporal neighboring block of the current video block.
[0179] Clause 40. The method of any of clauses 36-39, wherein the current video block is coded with the SGPM mode, and the converted motion data is determined for an intra partition of the current video block.
[0180] Clause 41. The method of any of clauses 36-39, wherein the current video block is coded with a GPM inter-intra mode, and the converted motion data is determined for an intra partition of the current video block.
[0181] Clause 42. The method of any of clauses 37-41, wherein the converted motion data is used to construct a motion list for the subsequent video block.
[0182] Clause 43. The method of any of clauses 24-42, wherein the motion data comprises at least one of the following: a motion vector, a reference index, a prediction direction, or a block vector.
[0183] Clause 44. The method of any of clauses 1-43, wherein in accordance with that chroma intra mode reordering is applied to a chroma block of the current video block, signaling of a first non-cross-component-prediction (nonCCP) flag is independent from at least one of the following: an availability of an IBC-coded collocated luma block or an availability of an intraTMP-coded collocated luma block, and wherein the first nonCCP flag indicates whether a first nonCCP chroma intra mode is used to code the chroma block, and the first nonCCP chroma intra mode is a nonCCP chroma intra mode that is at the first position after the chroma intra mode reordering.
[0184] Clause 45. The method of clause 44, wherein the first nonCCP flag is a DBV chroma flag.
[0185] Clause 46. The method of any of clauses 44-45, wherein the signaling of the first nonCCP flag is independent from whether the first nonCCP chroma intra mode is allowed to be used.
[0186] Clause 47. The method of any of clauses 1-46, wherein in accordance with that chroma intra mode reordering is applied to a chroma block of the current video block, signaling of a third nonCCP flag is independent from whether a third nonCCP chroma intra mode is used, and wherein the third nonCCP flag indicates whether the third nonCCP chroma intra mode is used to code the chroma block, and the third nonCCP chroma intra mode is a nonCCP chroma intra mode that is at the third position after the chroma intra mode reordering.
[0187] Clause 48. The method of clause 47, wherein the third nonCCP flag is a DIMD chroma flag.
[0188] Clause 49. The method of any of clauses 1-48, wherein a prediction for a chroma block of the current video block is determined based on DIMD, in accordance with that the chroma block is coded with a derived mode (DM) intra mode and a collocated luma block of the chroma block is coded with one of the following: an MIP, an SGPM, an intraTMP, an NNintra, an EIP, a TIMD, or an MRL.
[0189] Clause 50. The method of any of clauses 1-49, wherein the method is applied for at least one of the following: a single tree partition, a dual tree partition, a chroma coding, a luma coding, an inter block coding, an intra block coding, an IBC coding, an intra slice, or an inter slice.
[0190] Clause 51. The method of any of clauses 1-50, wherein whether to and / or how to apply the method is indicated at one of the following: a sequence level, a group of pictures level, a picture level, a slice level, or a tile group level.
[0191] Clause 52. The method of any of clauses 1-51, wherein whether to and / or how to apply the method is indicated in one of the following: a sequence header, a picture header, a sequence parameter set (SPS) , a video parameter set (VPS) , a decoding parameter set (DPS) , a decoding capability information (DCI) , a picture parameter set (PPS) , an adaptation parameter sets (APS) , a slice header, or a tile group header.
[0192] Clause 53. The method of any of clauses 1-52, wherein whether the method is applied to a sequence is dependent on an SPS flag, or whether the method is applied to a group of pictures is dependent on an PPS flag.
[0193] Clause 54. The method of clause 53, wherein the method is applied to a screen content coding (SCC) sequence.
[0194] Clause 55. The method of clause 53, wherein whether the method is applied to a screen content coding (SCC) sequence is controlled by an SPS flag or a PPS flag.
[0195] Clause 56. The method of clause 53, wherein whether the method is applied to a screen content coding (SCC) sequence is determined based on an implicit rule which does not require syntax element signaling.
[0196] Clause 57. The method of any of clauses 1-53, wherein whether to and / or how to apply the method is indicated at a region containing more than one sample or pixel.
[0197] Clause 58. The method of clause 57, wherein the region comprises at least one of the following: a prediction block (PB) , a transform block (TB) , a coding block (CB) , a prediction unit (PU) , a transform unit (TU) , a coding unit (CU) , a virtual pipeline data unit (VPDU) , a coding tree unit (CTU) , a CTU row, a slice, a tile, or a sub-picture.
[0198] Clause 59. The method of any of clauses 1-58, wherein whether to and / or how to apply the method is dependent on coded information.
[0199] Clause 60. The method of clause 59, wherein the coded information comprises at least one of the following: a block size, a color format, a single tree partitioning, a dual tree partitioning, a color component, a slice type, or a picture type.
[0200] Clause 61. The method of any of clauses 1-60, wherein the conversion includes encoding the current video block into the bitstream.
[0201] Clause 62. The method of any of clauses 1-60, wherein the conversion includes decoding the current video block from the bitstream.
[0202] Clause 63. An apparatus for video processing comprising a processor and a non-transitory memory with instructions thereon, wherein the instructions upon execution by the processor, cause the processor to perform a method in accordance with any of clauses 1-62.
[0203] Clause 64. A non-transitory computer-readable storage medium storing instructions that cause a processor to perform a method in accordance with any of clauses 1-62.
[0204] Clause 65. A non-transitory computer-readable recording medium storing a bitstream of a video which is generated by a method performed by an apparatus for video processing, wherein the method comprises: determining a transform kernel for a current video of the video based on at least one of the following: a first intra mode derived based on a decoder side intra mode derivation (DIMD) scheme, a second intra mode derived based on the DIMD scheme, or a planar mode; and generating the bitstream based on the transform kernel.
[0205] Clause 66. A method for storing a bitstream of a video, comprising: determining a transform kernel for a current video of the video based on at least one of the following: a first intra mode derived based on a decoder side intra mode derivation (DIMD) scheme, a second intra mode derived based on the DIMD scheme, or a planar mode; generating the bitstream based on the transform kernel; and storing the bitstream in a non-transitory computer-readable recording medium. Example Device
[0206] FIG. 44 illustrates a block diagram of a computing device 4400 in which various embodiments of the present disclosure can be implemented. The computing device 4400 may be implemented as or included in the source device 110 (or the video encoder 114 or 200) or the destination device 120 (or the video decoder 124 or 300) .
[0207] It would be appreciated that the computing device 4400 shown in FIG. 44 is merely for purpose of illustration, without suggesting any limitation to the functions and scopes of the embodiments of the present disclosure in any manner.
[0208] As shown in FIG. 44, the computing device 4400 includes a general-purpose computing device 4400. The computing device 4400 may at least comprise one or more processors or processing units 4410, a memory 4420, a storage unit 4430, one or more communication units 4440, one or more input devices 4450, and one or more output devices 4460.
[0209] In some embodiments, the computing device 4400 may be implemented as any user terminal or server terminal having the computing capability. The server terminal may be a server, a large-scale computing device or the like that is provided by a service provider. The user terminal may for example be any type of mobile terminal, fixed terminal, or portable terminal, including a mobile phone, station, unit, device, multimedia computer, multimedia tablet, Internet node, communicator, desktop computer, laptop computer, notebook computer, netbook computer, tablet computer, personal communication system (PCS) device, personal navigation device, personal digital assistant (PDA) , audio / video player, digital camera / video camera, positioning device, television receiver, radio broadcast receiver, E-book device, gaming device, or any combination thereof, including the accessories and peripherals of these devices, or any combination thereof. It would be contemplated that the computing device 4400 can support any type of interface to a user (such as “wearable” circuitry and the like) .
[0210] The processing unit 4410 may be a physical or virtual processor and can implement various processes based on programs stored in the memory 4420. In a multi-processor system, multiple processing units execute computer executable instructions in parallel so as to improve the parallel processing capability of the computing device 4400. The processing unit 4410 may also be referred to as a central processing unit (CPU) , a microprocessor, a controller or a microcontroller.
[0211] The computing device 4400 typically includes various computer storage medium. Such medium can be any medium accessible by the computing device 4400, including, but not limited to, volatile and non-volatile medium, or detachable and non-detachable medium. The memory 4420 can be a volatile memory (for example, a register, cache, Random Access Memory (RAM) ) , a non-volatile memory (such as a Read-Only Memory (ROM) , Electrically Erasable Programmable Read-Only Memory (EEPROM) , or a flash memory) , or any combination thereof. The storage unit 4430 may be any detachable or non-detachable medium and may include a machine-readable medium such as a memory, flash memory drive, magnetic disk or another other media, which can be used for storing information and / or data and can be accessed in the computing device 4400.
[0212] The computing device 4400 may further include additional detachable / non-detachable, volatile / non-volatile memory medium. Although not shown in FIG. 44, it is possible to provide a magnetic disk drive for reading from and / or writing into a detachable and non-volatile magnetic disk and an optical disk drive for reading from and / or writing into a detachable non-volatile optical disk. In such cases, each drive may be connected to a bus (not shown) via one or more data medium interfaces.
[0213] The communication unit 4440 communicates with a further computing device via the communication medium. In addition, the functions of the components in the computing device 4400 can be implemented by a single computing cluster or multiple computing machines that can communicate via communication connections. Therefore, the computing device 4400 can operate in a networked environment using a logical connection with one or more other servers, networked personal computers (PCs) or further general network nodes.
[0214] The input device 4450 may be one or more of a variety of input devices, such as a mouse, keyboard, tracking ball, voice-input device, and the like. The output device 4460 may be one or more of a variety of output devices, such as a display, loudspeaker, printer, and the like. By means of the communication unit 4440, the computing device 4400 can further communicate with one or more external devices (not shown) such as the storage devices and display device, with one or more devices enabling the user to interact with the computing device 4400, or any devices (such as a network card, a modem and the like) enabling the computing device 4400 to communicate with one or more other computing devices, if required. Such communication can be performed via input / output (I / O) interfaces (not shown) .
[0215] In some embodiments, instead of being integrated in a single device, some or all components of the computing device 4400 may also be arranged in cloud computing architecture. In the cloud computing architecture, the components may be provided remotely and work together to implement the functionalities described in the present disclosure. In some embodiments, cloud computing provides computing, software, data access and storage service, which will not require end users to be aware of the physical locations or configurations of the systems or hardware providing these services. In various embodiments, the cloud computing provides the services via a wide area network (such as Internet) using suitable protocols. For example, a cloud computing provider provides applications over the wide area network, which can be accessed through a web browser or any other computing components. The software or components of the cloud computing architecture and corresponding data may be stored on a server at a remote position. The computing resources in the cloud computing environment may be merged or distributed at locations in a remote data center. Cloud computing infrastructures may provide the services through a shared data center, though they behave as a single access point for the users. Therefore, the cloud computing architectures may be used to provide the components and functionalities described herein from a service provider at a remote location. Alternatively, they may be provided from a conventional server or installed directly or otherwise on a client device.
[0216] The computing device 4400 may be used to implement video encoding / decoding in embodiments of the present disclosure. The memory 4420 may include one or more video coding modules 4425 having one or more program instructions. These modules are accessible and executable by the processing unit 4410 to perform the functionalities of the various embodiments described herein.
[0217] In the example embodiments of performing video encoding, the input device 4450 may receive video data as an input 4470 to be encoded. The video data may be processed, for example, by the video coding module 4425, to generate an encoded bitstream. The encoded bitstream may be provided via the output device 4460 as an output 4480.
[0218] In the example embodiments of performing video decoding, the input device 4450 may receive an encoded bitstream as the input 4470. The encoded bitstream may be processed, for example, by the video coding module 4425, to generate decoded video data. The decoded video data may be provided via the output device 4460 as the output 4480.
[0219] While this disclosure has been particularly shown and described with references to example embodiments thereof, it will be understood by those skilled in the art that various changes in form and details may be made therein without departing from the spirit and scope of the present application as defined by the appended claims. Such variations are intended to be covered by the scope of this present application. As such, the foregoing description of embodiments of the present application is not intended to be limiting.
Claims
1.A method for video processing, comprising:determining, for a conversion between a current video block of a video and a bitstream of the video, a transform kernel for the current video block based on at least one of the following:a first intra mode derived based on a decoder side intra mode derivation (DIMD) scheme,a second intra mode derived based on the DIMD scheme, ora planar mode; andperforming the conversion based on the transform kernel.2.The method of claim 1, wherein the current video block is coded with a coding mode without angular information.3.The method of any of claims 1-2, wherein the current video block is coded with at least one of the following:a spatial geometric partitioning mode (SGPM) ,a matrix-based intra prediction (MIP) ,an intra template matching prediction (intraTMP) ,a neural network based intra prediction (NNintra) ,an extrapolation filter-based intra prediction (EIP) ,a template-based intra mode derivation (TIMD) ,a template-based multiple reference line (TMRL) ,a position dependent prediction (PDP) ,a position dependent prediction based matrix weighted intra prediction (PDP-MIP) ,a planar mode,a regular intra mode,an inter mode, ora geometric partitioning mode (GPM) .4.The method of any of claims 1-3, wherein the first intra mode is an intra mode with the lowest cost, and the second intra mode is an intra mode with the second-lowest cost.5.The method of any of claims 1-4, wherein the transform kernel is used for at least one of the following:a low-frequency non-separable transform (LFNST) ,a non-separable primary transform (NSPT) , ora multiple transform selection (MTS) .6.The method of any of claims 1-5, wherein all of the first intra mode, the second intra mode and the planar mode are allowed to be used for determining the transform kernel.7.The method of claim 6, wherein at least one of the first intra mode, the second intra mode or the planar mode is used to determine a transform kernel index from a look-up table (LUT) , to determine the transform kernel.8.The method of any of claims 6-7, wherein in the DIMD scheme, the first intra mode and the second intra mode are derived based on a determination of a histogram of gradients (HoG) .9.The method of claim 8, wherein the HoG is determined based on predicted samples of the current video block or reconstructed samples of at least one neighboring block of the current video block.10.The method of any of claims 1-9, wherein information regarding whether to use the first intra mode to determine the transform kernel is indicated in the bitstream.11.The method of any of claims 1-10, wherein in accordance with that the first intra mode is not used to determine the transform kernel, the second intra mode or the planar mode is used to determine the transform kernel.12.The method of claim 11, wherein whether to use the second intra mode or the planar mode is used to determine the transform kernel is determined based on a predetermined rule.13.The method of claim 12, wherein the predetermined rule specifies that: only in accordance with that the first intra mode is the planar mode, the second intra mode is used to determine the transform kernel.14.The method of any of claims 12-13, wherein the predetermined rule specifies that: in accordance with that the first intra mode is not the planar mode, the planar mode is used to determine the transform kernel.15.The method of any of claims 1-5, wherein only the first intra mode is allowed to be used for determining the transform kernel.16.The method of claim 15, wherein the first intra mode is used to determine a transform kernel index from a look-up table (LUT) , to determine the transform kernel.17.The method of any of claims 15-16, wherein in the DIMD scheme, the first intra mode is derived based on a determination of a histogram of gradients (HoG) .18.The method of any of claims 1-17, wherein in accordance with that the current video block is coded with a first prediction mode, the first intra mode is used to determine the transform kernel.19.The method of any of claims 1-5, wherein only the planar mode is allowed to be used for determining the transform kernel.20.The method of claim 19, wherein the planar mode is used to determine a transform kernel index from a look-up table (LUT) , to determine the transform kernel.21.The method of any of claims 19-20 wherein the planar mode is derived based on a determination of a histogram of gradients (HoG) .22.The method of any of claims 1-21, wherein in accordance with that the current video block is coded with a second prediction mode, the planar mode is used to determine the transform kernel.23.The method of any of claims 1-22, wherein in accordance with that the current video block is coded with a third intra mode, information associated with the third intra mode is converted to obtain converted information, and wherein the third intra mode comprises at least one of the following: EIP, MIP, SGPM, intraTMP.24.The method of claim 23, wherein the information associated with the third intra mode comprises at least one of the following: intra mode information or motion data.25.The method of any of claims 23-34, wherein the converted information is stored in a buffer for a subsequent coding process of the current video block or a coding process of a subsequent video block of the current video block.26.The method of any of claims 23-25, wherein the converted information comprises at least one of the following: a regular intra mode or converted motion data.27.The method of claim 26, wherein the regular intra mode comprises an angular mode.28.The method of any of claims 23-27, wherein the converted information is determined based on a histogram of gradients.29.The method of any of claims 23-28, wherein the converted information is determined based on at least one block coded before the current video block.30.The method of claim 29, wherein the at least one block comprises at least one of the following:a spatial adjacent block of the current video block,a spatial non-adjacent block of the current video block, ora temporal neighboring block of the current video block.31.The method of any of claims 26-30, wherein the regular intra mode is used to determine a transform kernel for the current video block.32.The method of any of claims 26-31, wherein the regular intra mode is used to construct an intra prediction mode list for the subsequent video block.33.The method of any of claims 26-32, wherein the converted motion data is used to construct a motion list for the subsequent video block.34.The method of claim 33, wherein the converted motion data comprises a block vector (BV) , and the block vector is used for at least one of the following: an intra block copy (IBC) mode, an intraTMP mode, a direct block vector (DBV) chroma mode, a BV guided convolutional cross-component model (CCCM) mode, a BV guided DIMD mode, or a BV guided EIP mode.35.The method of claim 33, wherein the converted motion data comprises a motion vector, and the motion vector is used for an inter mode.36.The method of any of claims 1-35, wherein in accordance with that the current video block is coded with a fourth intra mode, motion data for the fourth intra mode is converted to obtain converted motion data, and wherein the fourth intra mode comprises at least one of the following: an SGPM mode or an GPM intra-based mode.37.The method of claim 36, wherein the converted motion data is stored in a buffer for a subsequent coding process of the current video block or a coding process of a subsequent video block of the current video block.38.The method of any of claims 36-37, wherein the converted motion data is determined based on at least one block coded before the current video block.39.The method of claim 38, wherein the at least one block comprises at least one of the following:a spatial adjacent block of the current video block,a spatial non-adjacent block of the current video block, ora temporal neighboring block of the current video block.40.The method of any of claims 36-39, wherein the current video block is coded with the SGPM mode, and the converted motion data is determined for an intra partition of the current video block.41.The method of any of claims 36-39, wherein the current video block is coded with a GPM inter-intra mode, and the converted motion data is determined for an intra partition of the current video block.42.The method of any of claims 37-41, wherein the converted motion data is used to construct a motion list for the subsequent video block.43.The method of any of claims 24-42, wherein the motion data comprises at least one of the following: a motion vector, a reference index, a prediction direction, or a block vector.44.The method of any of claims 1-43, wherein in accordance with that chroma intra mode reordering is applied to a chroma block of the current video block, signaling of a first non-cross-component-prediction (nonCCP) flag is independent from at least one of the following: an availability of an IBC-coded collocated luma block or an availability of an intraTMP-coded collocated luma block, andwherein the first nonCCP flag indicates whether a first nonCCP chroma intra mode is used to code the chroma block, and the first nonCCP chroma intra mode is a nonCCP chroma intra mode that is at the first position after the chroma intra mode reordering.45.The method of claim 44, wherein the first nonCCP flag is a DBV chroma flag.46.The method of any of claims 44-45, wherein the signaling of the first nonCCP flag is independent from whether the first nonCCP chroma intra mode is allowed to be used.47.The method of any of claims 1-46, wherein in accordance with that chroma intra mode reordering is applied to a chroma block of the current video block, signaling of a third nonCCP flag is independent from whether a third nonCCP chroma intra mode is used, andwherein the third nonCCP flag indicates whether the third nonCCP chroma intra mode is used to code the chroma block, and the third nonCCP chroma intra mode is a nonCCP chroma intra mode that is at the third position after the chroma intra mode reordering.48.The method of claim 47, wherein the third nonCCP flag is a DIMD chroma flag.49.The method of any of claims 1-48, wherein a prediction for a chroma block of the current video block is determined based on DIMD, in accordance with that the chroma block is coded with a derived mode (DM) intra mode and a collocated luma block of the chroma block is coded with one of the following: an MIP, an SGPM, an intraTMP, an NNintra, an EIP, a TIMD, or an MRL.50.The method of any of claims 1-49, wherein the method is applied for at least one of the following: a single tree partition, a dual tree partition, a chroma coding, a luma coding, an inter block coding, an intra block coding, an IBC coding, an intra slice, or an inter slice.51.The method of any of claims 1-50, wherein whether to and / or how to apply the method is indicated at one of the following:a sequence level,a group of pictures level,a picture level,a slice level, ora tile group level.52.The method of any of claims 1-51, wherein whether to and / or how to apply the method is indicated in one of the following:a sequence header,a picture header,a sequence parameter set (SPS) ,a video parameter set (VPS) ,a decoding parameter set (DPS) ,a decoding capability information (DCI) ,a picture parameter set (PPS) ,an adaptation parameter sets (APS) ,a slice header, ora tile group header.53.The method of any of claims 1-52, wherein whether the method is applied to a sequence is dependent on an SPS flag, orwhether the method is applied to a group of pictures is dependent on an PPS flag.54.The method of claim 53, wherein the method is applied to a screen content coding (SCC) sequence.55.The method of claim 53, wherein whether the method is applied to a screen content coding (SCC) sequence is controlled by an SPS flag or a PPS flag.56.The method of claim 53, wherein whether the method is applied to a screen content coding (SCC) sequence is determined based on an implicit rule which does not require syntax element signaling.57.The method of any of claims 1-53, wherein whether to and / or how to apply the method is indicated at a region containing more than one sample or pixel.58.The method of claim 57, wherein the region comprises at least one of the following:a prediction block (PB) ,a transform block (TB) ,a coding block (CB) ,a prediction unit (PU) ,a transform unit (TU) ,a coding unit (CU) ,a virtual pipeline data unit (VPDU) ,a coding tree unit (CTU) ,a CTU row,a slice,a tile, ora sub-picture.59.The method of any of claims 1-58, wherein whether to and / or how to apply the method is dependent on coded information.60.The method of claim 59, wherein the coded information comprises at least one of the following:a block size,a color format,a single tree partitioning,a dual tree partitioning,a color component,a slice type, ora picture type.61.The method of any of claims 1-60, wherein the conversion includes encoding the current video block into the bitstream.62.The method of any of claims 1-60, wherein the conversion includes decoding the current video block from the bitstream.63.An apparatus for video processing comprising a processor and a non-transitory memory with instructions thereon, wherein the instructions upon execution by the processor, cause the processor to perform a method in accordance with any of claims 1-62.64.A non-transitory computer-readable storage medium storing instructions that cause a processor to perform a method in accordance with any of claims 1-62.65.A non-transitory computer-readable recording medium storing a bitstream of a video which is generated by a method performed by an apparatus for video processing, wherein the method comprises:determining a transform kernel for a current video of the video based on at least one of the following:a first intra mode derived based on a decoder side intra mode derivation (DIMD) scheme,a second intra mode derived based on the DIMD scheme, ora planar mode; andgenerating the bitstream based on the transform kernel.66.A method for storing a bitstream of a video, comprising:determining a transform kernel for a current video of the video based on at least one of the following:a first intra mode derived based on a decoder side intra mode derivation (DIMD) scheme,a second intra mode derived based on the DIMD scheme, ora planar mode;generating the bitstream based on the transform kernel; andstoring the bitstream in a non-transitory computer-readable recording medium.