Method, apparatus, and medium for video processing

By applying separate coding modes and updating chroma component costs, the coding efficiency of video processing is enhanced, addressing inefficiencies in existing video coding technologies.

WO2026153371A1PCT designated stage Publication Date: 2026-07-23DOUYIN VISION CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
DOUYIN VISION CO LTD
Filing Date
2026-01-14
Publication Date
2026-07-23

AI Technical Summary

Technical Problem

Existing video coding technologies face challenges in improving the coding efficiency of chroma components, which affects the overall performance of video encoding and decoding processes.

Method used

Implementing separate coding modes for different chroma components and updating the cost of chroma components based on specific factors during the conversion process to enhance coding performance.

Benefits of technology

This approach improves the coding performance by optimizing the encoding and decoding processes for chroma components, leading to more efficient video processing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2026072545_23072026_PF_FP_ABST
    Figure CN2026072545_23072026_PF_FP_ABST
Patent Text Reader

Abstract

Embodiments of the present disclosure provide a solution for video processing. A method for video processing is proposed. In the method, for a conversion between a current video unit of a video and a bitstream of the video, a first coding mode is applied to a first chroma component of the current video unit and a second coding mode is applied to a second chroma component of the current video unit. The second coding mode is different from the first coding mode. The conversion is performed based on the applying.
Need to check novelty before this filing date? Find Prior Art

Description

METHOD, APPARATUS, AND MEDIUM FOR VIDEO PROCESSINGFIELD

[0001] Embodiments of the present disclosure relate generally to video processing techniques, and more particularly, to coding modes for chroma components.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 efficiency 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: applying, for a conversion between a current video unit of a video and a bitstream of the video, a first coding mode to a first chroma component of the current video unit and a second coding mode to a second chroma component of the current video unit, the second coding mode being different from the first coding mode; and performing the conversion based on the applying. The method in accordance with the first aspect of the present disclosure enables using separate coding modes for different chroma components. The coding performance can thus be improved.

[0005] In a second aspect, another method for video processing is proposed. The method comprises: determining, for a conversion between a current video unit of a video and a bitstream of the video, at least one cost of at least one chroma component of the current video unit; updating the at least one cost based on at least one factor; and performing the conversion based on the at least one updated cost. The method in accordance with the second aspect of the present disclosure enables updating the cost of one or more chroma components before being used. The coding performance can thus be improved.

[0006] In a third 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, or second aspect of the present disclosure.

[0007] In a fourth 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, or second aspect of the present disclosure.

[0008] In a fifth 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: applying a first coding mode to a first chroma component of a current video unit of the video and a second coding mode to a second chroma component of the current video unit, the second coding mode being different from the first coding mode; and generating the bitstream based on the applying.

[0009] In a sixth 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 at least one cost of at least one chroma component of a current video unit of the video; updating the at least one cost based on at least one factor; and generating the bitstream based on the at least one updated cost.

[0010] In a seventh aspect, a method for storing a bitstream of a video is proposed. The method comprises: applying a first coding mode to a first chroma component of a current video unit of the video and a second coding mode to a second chroma component of the current video unit, the second coding mode being different from the first coding mode; generating the bitstream based on the applying; and storing the bitstream in a non-transitory computer-readable recording medium.

[0011] In an eighth aspect, a method for storing a bitstream of a video is proposed. The method comprises: determining at least one cost of at least one chroma component of a current video unit of the video; updating the at least one cost based on at least one factor; generating the bitstream based on the at least one updated cost; and storing the bitstream in a non-transitory computer-readable recording medium.

[0012] 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

[0013] 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.

[0014] Fig. 1 illustrates a block diagram of an example video coding system in accordance with some embodiments of the present disclosure;

[0015] Fig. 2 illustrates a block diagram of an example video encoder in accordance with some embodiments of the present disclosure;

[0016] Fig. 3 illustrates a block diagram of an example video decoder in accordance with some embodiments of the present disclosure;

[0017] Fig. 4 illustrates an example of encoder block diagram;

[0018] Fig. 5 illustrates 67 intra prediction modes;

[0019] Fig. 6A and Fig. 6B illustrate reference samples for wide-angular intra prediction, respectively;

[0020] Fig. 7 illustrates a problem of discontinuity in case of directions beyond 45°;

[0021] Fig. 8 illustrates a matrix weighted intra prediction process;

[0022] Fig. 9 illustrates spatial GPM candidates;

[0023] Fig. 10 illustrates a GPM template;

[0024] Fig. 11 illustrates a GPM blending;

[0025] Fig. 12 illustrates a neighboring reconstructed samples used for DIMD chroma mode;

[0026] Fig. 13A illustrates an illustration of the effect of the slope adjustment parameter “u” using model created with the current CCLM;

[0027] Fig. 13B illustrates an illustration of the effect of the slope adjustment parameter “u” using model updated as proposed;

[0028] Fig. 14 illustrates a spatial part of the convolutional filter;

[0029] Fig. 15 illustrates a reference area (with its paddings) used to derive the filter coefficients;

[0030] Fig. 16 illustrates four Sobel based gradient patterns for GLM;

[0031] Fig. 17 illustrates non-downsampled luma sample;

[0032] Fig. 18 illustrates a reference area for BVG-CCCM;

[0033] Fig. 19 illustrates spatial samples used for GL-CCCM;

[0034] Fig. 20 illustrates various downsampling filters used in cross-component models;

[0035] Fig. 21 illustrates a filter on samples of MM-CCLM / MM-CCCM;

[0036] Fig. 22 illustrates the template adjacent to the current chroma CU;

[0037] Fig. 23 illustrates the InterCCCM method on the decoder;

[0038] Fig. 24 illustrates luma samples L0, . ., L5 in relation to the chroma sample C;

[0039] Fig. 25 illustrates SBT position, type and transform type;

[0040] Fig. 26 illustrates three EIP filter shapes;

[0041] Fig. 27 illustrates three types of reconstructed area for EIP filter;

[0042] Fig. 28 illustrates a L-shaped neighborhood for a given predicted block;

[0043] Fig. 29 illustrates neighbouring blocks for merging checks;

[0044] Fig. 30 illustrates a non-adjacent spatial neighboring candidates for OBIC mode;

[0045] Fig. 31 illustrates neighbouring blocks (L, A, BL, AR, AL) used in the derivation of a general MPM list;

[0046] Fig. 32 illustrates a flowchart of a method for video processing in accordance with some embodiments of the present disclosure;

[0047] Fig. 33 illustrates a flowchart of another method for video processing in accordance with some embodiments of the present disclosure; and

[0048] Fig. 34 illustrates a block diagram of a computing device in which various embodiments of the present disclosure can be implemented.

[0049] Throughout the drawings, the same or similar reference numerals usually refer to the same or similar elements.DETAILED DESCRIPTION

[0050] 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.

[0051] 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.

[0052] 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.

[0053] 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.

[0054] 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

[0055] 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.

[0056] 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.

[0057] 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.

[0058] 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.

[0059] 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.

[0060] 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.

[0061] 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.

[0062] 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.

[0063] 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.

[0064] 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.

[0065] 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.

[0066] 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.

[0067] 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.

[0068] 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.

[0069] 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.

[0070] 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.

[0071] 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.

[0072] 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.

[0073] 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.

[0074] 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.

[0075] 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.

[0076] 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.

[0077] 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.

[0078] 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.

[0079] 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.

[0080] 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.

[0081] After the reconstruction unit 212 reconstructs the video block, loop filtering operation may be performed to reduce video blocking artifacts in the video block.

[0082] 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.

[0083] 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.

[0084] 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.

[0085] 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.

[0086] 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.

[0087] 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.

[0088] 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.

[0089] 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.

[0090] 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.

[0091] 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.

[0092] 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

[0093] This disclosure is related to video coding technologies. Specifically, it is related to how to use separate modes for chroma coding, how to derive or signal the modes for chroma components, and other coding tools in image / video coding. It may be applied to the existing video coding standard like HEVC, or Versatile Video Coding (VVC) . It may be also applicable to future video coding standards or video codec. 2. Introduction

[0094] 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, Joint Video Exploration Team (JVET) was founded by VCEG and MPEG jointly in 2015. Since then, many new methods have been adopted by JVET and put into the reference software named Joint Exploration Model (JEM) . In April 2018, the Joint Video Expert Team (JVET) between VCEG (Q6 / 16) and ISO / IEC JTC1 SC29 / WG11 (MPEG) was created to work on the VVC standard targeting at 50%bitrate reduction compared to HEVC. 2.1. Coding flow of a typical video codec

[0095] Fig. 4 shows an example of encoder block diagram 400 of VVC, which contains three in-loop filtering blocks: deblocking filter (DF) , sample adaptive offset (SAO) and ALF. Unlike DF, which uses predefined filters, SAO and ALF utilize the original samples of the current picture to reduce the mean square errors between the original samples and the reconstructed samples by adding an offset and by applying a finite impulse response (FIR) filter, respectively, with coded side information signalling the offsets and filter coefficients. ALF is located at the last processing stage of each picture and can be regarded as a tool trying to catch and fix artifacts created by the previous stages. 2.2. Intra mode coding with 67 intra prediction modes

[0096] Fig. 5 shows an example 500 of 67 intra prediction modes. To capture the arbitrary edge directions presented in natural video, the number of directional intra modes is extended from 33, as used in HEVC, to 65, as shown in Fig. 5, and the planar and DC modes remain the same. These denser directional intra prediction modes apply for all block sizes and for both luma and chroma intra predictions.

[0097] In the HEVC, every intra-coded block has a square shape and the length of each of its side is a power of 2. Thus, no division operations are required to generate an intra-predictor using DC mode. In VVC, blocks can have a rectangular shape that necessitates the use of a division operation per block in the general case. To avoid division operations for DC prediction, only the longer side is used to compute the average for non-square blocks. 2.2.1. Wide angle intra prediction

[0098] Although 67 modes are defined in the VVC, the exact prediction direction for a given intra prediction mode index is further dependent on the block shape. Conventional angular intra prediction directions are defined from 45 degrees to -135 degrees in clockwise direction. In VVC, several conventional angular intra prediction modes are adaptively replaced with wide-angle intra prediction modes for non-square blocks. The replaced modes are signalled using the original mode indexes, which are remapped to the indexes of wide angular modes after parsing. The total number of intra prediction modes is unchanged, i.e., 67, and the intra mode coding method is unchanged.

[0099] Fig. 6A and Fig. 6B illustrate reference samples for wide-angular intra prediction. To support these prediction directions, the top reference with length 2W+1, and the left reference with length 2H+1, are defined as shown in Fig. 6A and Fig. 6B.

[0100] The number of replaced modes in wide-angular direction mode depends on the aspect ratio of a block. The replaced intra prediction modes are illustrated in Table 1. Table 1 Intra prediction modes replaced by wide-angular modes

[0101] Fig. 7 illustrates an example 700 showing a problem of discontinuity in case of directions beyond 45°. As shown in Fig. 7, two vertically adjacent predicted samples may use two non-adjacent reference samples in the case of wide-angle intra prediction. Hence, low-pass reference samples filter and side smoothing are applied to the wide-angle prediction to reduce the negative effect of the increased gap Δpα. If a wide-angle mode represents a non-fractional offset. There are 8 modes in the wide-angle modes satisfy this condition, which are [-14, -12, -10, -6, 72, 76, 78, 80] . When a block is predicted by these modes, the samples in the reference buffer are directly copied without applying any interpolation. With this modification, the number of samples needed to be smoothing is reduced. Besides, it aligns the design of non-fractional modes in the conventional prediction modes and wide-angle modes.

[0102] In VVC, 4: 2: 2 and 4: 4: 4 chroma formats are supported as well as 4: 2: 0. Chroma derived mode (DM) derivation table for 4: 2: 2 chroma format was initially ported from HEVC extending the number of entries from 35 to 67 to align with the extension of intra prediction modes. Since HEVC specification does not support prediction angle below -135 degree and above 45 degree, luma intra prediction modes ranging from 2 to 5 are mapped to 2. Therefore, chroma DM derivation table for 4: 2: 2: chroma format is updated by replacing some values of the entries of the mapping table to convert prediction angle more precisely for chroma blocks. 2.3. Inter prediction

[0103] For each inter-predicted CU, motion parameters consisting of motion vectors, reference picture indices and reference picture list usage index, and additional information needed for the new coding feature of VVC to be used for inter-predicted sample generation. The motion parameter can be signalled in an explicit or implicit manner. When a CU is coded with skip mode, the CU is associated with one PU and has no significant residual coefficients, no coded motion vector delta or reference picture index. A merge mode is specified whereby the motion parameters for the current CU are obtained from neighbouring CUs, including spatial and temporal candidates, and additional schedules introduced in VVC. The merge mode can be applied to any inter-predicted CU, not only for skip mode. The alternative to merge mode is the explicit transmission of motion parameters, where motion vector, corresponding reference picture index for each reference picture list and reference picture list usage flag and other needed information are signalled explicitly per each CU. 2.4. Intra block copy (IBC)

[0104] Intra block copy (IBC) is a tool adopted in HEVC extensions on SCC. It is well known that it significantly improves the coding efficiency of screen content materials. Since IBC mode is implemented as a block level coding mode, block matching (BM) is performed at the encoder to find the optimal block vector (or motion vector) for each CU. Here, a block vector is used to indicate the displacement from the current block to a reference block, which is already reconstructed inside the current picture. The luma block vector of an IBC-coded CU is in integer precision. The chroma block vector rounds to integer precision as well. When combined with AMVR, the IBC mode can switch between 1-pel and 4-pel motion vector precisions. An IBC-coded CU is treated as the third prediction mode other than intra or inter prediction modes. The IBC mode is applicable to the CUs with both width and height smaller than or equal to 64 luma samples.

[0105] At the encoder side, hash-based motion estimation is performed for IBC. The encoder performs RD check for blocks with either width or height no larger than 16 luma samples. For non-merge mode, the block vector search is performed using hash-based search first. If hash search does not return valid candidate, block matching based local search will be performed.

[0106] In the hash-based search, hash key matching (32-bit CRC) between the current block and a reference block is extended to all allowed block sizes. The hash key calculation for every position in the current picture is based on 4×4 sub-blocks. For the current block of a larger size, a hash key is determined to match that of the reference block when all the hash keys of all 4×4 sub-blocks match the hash keys in the corresponding reference locations. If hash keys of multiple reference blocks are found to match that of the current block, the block vector costs of each matched reference are calculated and the one with the minimum cost is selected.

[0107] In block matching search, the search range is set to cover both the previous and current CTUs.

[0108] At CU level, IBC mode is signalled with a flag and it can be signalled as IBC AMVP mode or IBC skip / merge mode as follows: – IBC skip / merge mode: a merge candidate index is used to indicate which of the block vectors in the list from neighbouring candidate IBC coded blocks is used to predict the current block. The merge list consists of spatial, HMVP, and pairwise candidates. – IBC AMVP mode: block vector difference is coded in the same way as a motion vector difference. The block vector prediction method uses two candidates as predictors, one from left neighbour and one from above neighbour (if IBC coded) . When either neighbour is not available, a default block vector will be used as a predictor. A flag is signalled to indicate the block vector predictor index. 2.5. Matrix weighted Intra Prediction (MIP)

[0109] Matrix weighted intra prediction (MIP) method is a newly added intra prediction technique into VVC. For predicting the samples of a rectangular block of width W and height H, matrix weighted intra prediction (MIP) takes one line of H reconstructed neighbouring boundary samples left of the block and one line of W reconstructed neighbouring boundary samples above the block as input. If the reconstructed samples are unavailable, they are generated as it is done in the conventional intra prediction. The generation of the prediction signal is based on the following three steps, which are averaging, matrix vector multiplication and linear interpolation as shown in Fig. 8, which illustrates an example process 800 of matrix weighted intra prediction. 2.5.1. Averaging neighbouring samples

[0110] Among the boundary samples, four samples or eight samples are selected by averaging based on block size and shape. Specifically, the input boundaries bdrytop and bdryleft are reduced to smaller boundaries and by averaging neighbouring boundary samples according to predefined rule depends on block size. Then, the two reduced boundaries and are concatenated to a reduced boundary vector bdryred which is thus of size four for blocks of shape 4×4 and of size eight for blocks of all other shapes. If mode refers to the MIP-mode, this concatenation is defined as follows: 2.5.2. Matrix Multiplication

[0111] A matrix vector multiplication, followed by addition of an offset, is carried out with the averaged samples as an input. The result is a reduced prediction signal on a subsampled set of samples in the original block. Out of the reduced input vector bdryred a reduced prediction signal predred, which is a signal on the down-sampled block of width Wred and height Hred is generated. Here, Wred and Hred are defined as:

[0112] The reduced prediction signal predred is computed by calculating a matrix vector product and adding an offset: predred=A·bdryred+b.               (2-4) .

[0113] Here, A is a matrix that has Wred· Hred rows and 4 columns if W=H=4 and 8 columns in all other cases. b is a vector of size Wred· Hred. The matrix A and the offset vector b are taken from one of the sets S0, S1, S2. One defines an index idx=idx (W, H) as follows:

[0114] Here, each coefficient of the matrix A is represented with 8 bit precision. The set S0 consists of 16 matrices each of which has 16 rows and 4 columns and 16 offset vectors each of size 16. Matrices and offset vectors of that set are used for blocks of size 4×4. The set S1 consists of 8 matrices each of which has 16 rows and 8 columns and 8 offset vectors each of size 16. The set S2 consists of 6 matrices each of which has 64 rows and 8 columns and of 6 offset vectors of size 64. 2.5.3. Interpolation

[0115] The prediction signal at the remaining positions is generated from the prediction signal on the subsampled set by linear interpolation which is a single step linear interpolation in each direction. The interpolation is performed firstly in the horizontal direction and then in the vertical direction regardless of block shape or block size. 2.5.4. Signalling of MIP mode and harmonization with other coding tools

[0116] For each Coding Unit (CU) in intra mode, a flag indicating whether an MIP mode is to be applied or not is sent. If an MIP mode is to be applied, MIP mode (predModeIntra) is signalled. For an MIP mode, a transposed flag (isTransposed) , which determines whether the mode is transposed, and MIP mode Id (modeId) , which determines which matrix is to be used for the given MIP mode is derived as follows: isTransposed=predModeIntra&1 modeId=predModeIntra>>1                         (2-6) .

[0117] MIP coding mode is harmonized with other coding tools by considering following aspects: – LFNST is enabled for MIP on large blocks. Here, the LFNST transforms of planar mode are used. – The reference sample derivation for MIP is performed exactly as for the conventional intra prediction modes. – For the up-sampling step used in the MIP-prediction, original reference samples are used instead of down-sampled ones. – Clipping is performed before up-sampling and not after up-sampling. – MIP is allowed up to 64×64 regardless of the maximum transform size. The number of MIP modes is 32 for sizeId=0, 16 for sizeId=1 and 12 for sizeId=2. 2.6. Spatial Geometric partitioning mode (SGPM)

[0118] SGPM is an intra mode that resembles the inter coding tool of GPM, where the two prediction parts are generated from intra predicted process. Fig. 9 illustrates spatial GPM candidates. In this mode, a candidate list is built with each entry containing one partition split and two intra prediction modes as shown in Fig. 9.26 partition modes and 3 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.

[0119] Fig. 10 illustrates a GPM template. The list is reordered using template (as shown in Fig. 10) where SAD between the prediction and reconstruction of the template is used for ordering. The template size is fixed to 1.

[0120] 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.

[0121] 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.

[0122] Fig. 11 illustrates GPM blending. 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 Fig. 11 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.

[0123] 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. 2.7. Decoder side intra mode derivation (DIMD)

[0124] When DIMD is applied, up to five intra modes are derived from the reconstructed neighbor samples, and those five predictors are combined with the planar mode predictor with the weights derived from the histogram of gradients. The division operations in weight derivation are performed utilizing the same lookup table (LUT) based indigenization scheme used by the CCLM. For example, the division operation in the orientation calculation Orient=Gy / Gx              (2-7) 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 [normDiff] | 8) + (1<< (x-1) ) ) >> x       (2-8) where DivSigTable

[0016] = {0, 7, 6, 5 , 5, 4, 4, 3, 3, 2, 2, 1, 1, 1, 1, 0} .

[0125] 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.

[0126] If the above histogram is twice the left, then:

[0127] If the left histogram is twice the above, then: where wDimdi is the unmodified uniform weight of the DIMD, Δi is pre-defined and set to 10.

[0128] 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.

[0129] Finally, note the region of neighboring reconstructed samples used for computing the histogram of gradients is modified, 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.7.1. DIMD chroma mode

[0130] 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 as shown Fig. 12, which illustrates neighboring reconstructed samples used for DIMD chroma mode. 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.

[0131] 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.

[0132] Finally, the luma region of reconstructed samples used for computing the histogram of gradients for chroma DIMD mode is modified. For a W×H 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.8. Template-based intra mode derivation (TIMD)

[0133] 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 are selected as the TIMD modes. These two 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.

[0134] 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           (2-11) .

[0135] If this condition is true, the fusion is applied, otherwise the only mode1 is used.

[0136] Weights of the modes are computed from their SATD costs as follows: weight1 = costMode2  /  (costMode1+ costMode2) weight2 = 1 -weight1             (2-12) .

[0137] The division operations are conducted using the same lookup table (LUT) based integerization scheme used by the CCLM. 2.9. Multi-model LM (MMLM)

[0138] 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.10. Slope adjustment of CCLM

[0139] 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.

[0140] 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.

[0141] 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. 13A illustrates the effect of the slope adjustment parameter “u” using the model created with the current CCLM. Fig. 13B illustrates the effect of the slope adjustment parameter “u” using the model updated as proposed.

[0142] 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) .

[0143] 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.

[0144] 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.

[0145] 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.11. Fusion of chroma intra prediction modes

[0146] 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.

[0147] 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) ) ) >>shiftwhere 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.

[0148] 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.

[0149] 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.12. Convolutional cross-component intra prediction model

[0150] 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.

[0151] 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.12.1. Convolutional filter

[0152] 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 in Fig. 14, which illustrates the spatial part of the convolutional filter.

[0153] 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.

[0154] That is, for 10-bit content it is calculated as: P = (C*C + 512 ) >> 10.

[0155] 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) .

[0156] 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.12.2. Calculation of filter coefficients

[0157] The filter coefficients ci are calculated by minimising MSE between predicted and reconstructed chroma samples in the reference area. Fig. 15 illustrates a reference area (with its padding) used to derive the filter coefficients. Fig. 15 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.

[0158] 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.

[0159] 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.

[0160] 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.

[0161] 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.

[0162] 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.

[0163] 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.12.3. Gradient Linear Model

[0164] 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.

[0165] 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+β.

[0166] 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·β.

[0167] 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.

[0168] Four gradient filters are enabled for the GLM, as illustrated in Fig. 16, which illustrates four Sobel based gradient patterns for GLM. 2.12.4. CCCM signalling

[0169] 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.12.5. CCCM using non-downsampled luma samples

[0170] 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 as shown in Fig. 17, which illustrates non-downsampled luma samples. 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. 2.12.6. Block-vector guided CCCM (BVG-CCCM)

[0171] 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. Fig. 18 illustrates the reference area in BVG-CCCM method.

[0172] 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.

[0173] 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. 14.

[0174] The nonlinear term P is represented as power of two of the corresponding luma sample and B is the bias term.

[0175] 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.12.7. Gradient and Location based convolutional cross-component model (GL-CCCM)

[0176] 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.

[0177] Where Gy and Gx are the vertical and horizontal gradients, respectively, and are calculated as Fig. 19: Gy = (2N + NW + NE) - (2S + SW + SE) , Gx = (2W + NW + SW) - (2E + NE + SE) .

[0178] Moreover, the Y and X are the spatial coordinates of the center luma sample.

[0179] The rest of the parameters are the same as CCCM tool. The reference area for the parameter calculation is the same as CCCM method.

[0180] 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.

[0181] 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.

[0182] 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.12.8. CCCM with Multiple Downsampling Filters

[0183] 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 as indicated in Fig. 20, 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. 20 illustrates various downsampling filters used in cross-component models. 2.13. Local-Boosting Cross-Component Prediction (LB-CCP)

[0184] Prediction samples of MM-CCLM / MM-CCCM can be filtered with neighbouring samples. Fig. 21 illustrates a filter on samples of MM-CCLM / MM-CCCM. As shown in Fig. 21, 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. 2.14. Cross-Component Prediction (CCP) merge (a. k. a., non-local CCP) mode

[0185] 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

[0186] 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

[0187] 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

[0188] 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

[0189] 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} .

[0190] It is noted that the LB-CCP flag is inherited from a CCP candidate in the CCP merge candidate list.

[0191] 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.15. Decoder derived CCP mode

[0192] 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 Fig. 22, which illustrates the template adjacent to the current chroma CU.

[0193] 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.

[0194] 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.16. InterCCCM

[0195] 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. 23 illustrates the decoder side of the InterCCCM 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.

[0196] 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. 24. Fig. 24 illustrates luma samples L0, ..., L5 in relation to the chroma sample C. 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.

[0197] 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.

[0198] 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.17. CCP merge for chroma inter blocks

[0199] The cross-component prediction merge mode described in section 2.14 is extended to chroma inter coding. The CCP models including CCLM, MMLM, CCCM, GLM, chroma fusion, CCP merge modes, and inter CCCM are stored and inherited for the following coding chroma intra and inter blocks. Similar to the CCP merge for chroma intra blocks, a flag is signaled to indicate whether a chroma inter block is coded using this mode. When the root CBF is equal to 0, a CU-level flag is signalled. Otherwise, a TU-level flag is signalled. If the CCP merge mode is used, a CCP merge list is constructed in a similar way as that for chroma intra blocks except that additional shifted temporal candidates and on-the-fly derived candidates are included in the CCP merge list. The additional shifted temporal candidates are derived from the collocated picture without one-CTU-row buffer constraint. And the position of these candidates is the same as those defined in ECM for regular inter merge prediction candidates with a shift obtained from the motion vector of the current block. The on-the-fly derived candidates are only used for low delay pictures and are obtained using the neighboring reconstructed samples of the current block. At most 1 on-the-fly derived candidates including single / multi-model CCCM and single / multi-model CCLM are added to the CCP merge list. After the CCP merge list is constructed, the candidate with the lowest template cost is selected for the chroma inter block. The chroma inter block is then predicted in the same way as that of inter CCCM. That is, the motion compensation predicted samples are blended with the cross-component predicted samples to form the final prediction. 2.18. Multiple transform selection (MTS) for core transform

[0200] In addition to DCT-II which has been employed in HEVC, a Multiple Transform Selection (MTS) scheme is used for residual coding both inter and intra coded blocks. It uses multiple selected transforms from the DCT8 / DST7. The newly introduced transform matrices are DST-VII and DCT-VIII. Table 2 shows the basis functions of the selected DST / DCT. Table 2 –Transform basis functions of DCT-II / VIII and DSTVII for N-point input

[0201] In order to keep the orthogonality of the transform matrix, the transform matrices are quantized more accurately than the transform matrices in HEVC. To keep the intermediate values of the transformed coefficients within the 16-bit range, after horizontal and after vertical transform, all the coefficients are to have 10-bit.

[0202] In order to control MTS scheme, separate enabling flags are specified at SPS level for intra and inter, respectively. When MTS is enabled at SPS, a CU level flag is signalled to indicate whether MTS is applied or not. Here, MTS is applied only for luma. The MTS signaling is skipped when one of the below conditions is applied. – The position of the last significant coefficient for the luma TB is less than 1 (i.e., DC only) . – The last significant coefficient of the luma TB is located inside the MTS zero-out region. If MTS CU flag is equal to zero, then DCT2 is applied in both directions. However, if MTS CU flag is equal to one, then two other flags are additionally signalled to indicate the transform type for the horizontal and vertical directions, respectively. Transform and signalling mapping table as shown in Table 3. Unified the transform selection for ISP and implicit MTS is used by removing the intra-mode and block-shape dependencies. If current block is ISP mode or if the current block is intra block and both intra and inter explicit MTS is on, then only DST7 is used for both horizontal and vertical transform cores. When it comes to transform matrix precision, 8-bit primary transform cores are used. Therefore, all the transform cores used in HEVC are kept as the same, including 4-point DCT-2 and DST-7, 8-point, 16-point and 32-point DCT-2. Also, other transform cores including 64-point DCT-2, 4-point DCT-8, 8-point, 16-point, 32-point DST-7 and DCT-8, use 8-bit primary transform cores. Table 3 - Transform and signalling mapping table

[0203] To reduce the complexity of large size DST-7 and DCT-8, High frequency transform coefficients are zeroed out for the DST-7 and DCT-8 blocks with size (width or height, or both width and height) equal to 32. Only the coefficients within the 16x16 lower-frequency region are retained.

[0204] As in HEVC, the residual of a block can be coded with transform skip mode. To avoid the redundancy of syntax coding, the transform skip flag is not signalled when the CU level MTS_CU_flag is not equal to zero. Note that implicit MTS transform is set to DCT2 when LFNST or MIP is activated for the current CU. Also the implicit MTS can be still enabled when MTS is enabled for inter coded blocks. 2.19. Subblock transform (SBT)

[0205] In VTM, subblock transform is introduced for an inter-predicted CU. In this transform mode, only a sub-part of the residual block is coded for the CU. When inter-predicted CU with cu_cbf equal to 1, cu_sbt_flag may be signaled to indicate whether the whole residual block or a sub-part of the residual block is coded. In the former case, inter MTS information is further parsed to determine the transform type of the CU. In the latter case, a part of the residual block is coded with inferred adaptive transform and the other part of the residual block is zeroed out.

[0206] When SBT is used for an inter-coded CU, SBT type and SBT position information are signaled in the bitstream. Fig. 25 illustrates examples of SBT position, type and transform type. There are two SBT types and two SBT positions, as indicated in Fig. 25. For SBT-V (or SBT-H) , the TU width (or height) may equal to half of the CU width (or height) or 1 / 4 of the CU width (or height) , resulting in 2: 2 split or 1: 3 / 3: 1 split. The 2: 2 split is like a binary tree (BT) split while the 1: 3 / 3: 1 split is like an asymmetric binary tree (ABT) split. In ABT splitting, only the small region contains the non-zero residual. If one dimension of a CU is 8 in luma samples, the 1: 3 / 3: 1 split along that dimension is disallowed. There are at most 8 SBT modes for a CU.

[0207] Position-dependent transform core selection is applied on luma transform blocks in SBT-V and SBT-H (chroma TB always using DCT-2) . The two positions of SBT-H and SBT-V are associated with different core transforms. More specifically, the horizontal and vertical transforms for each SBT position is specified in Fig. 25. For example, the horizontal and vertical transforms for SBT-V position 0 is DCT-8 and DST-7, respectively. When one side of the residual TU is greater than 32, the transform for both dimensions is set as DCT-2. Therefore, the subblock transform jointly specifies the TU tiling, cbf, and horizontal and vertical core transform type of a residual block.

[0208] The SBT is not applied to the CU coded with combined inter-intra mode. 2.20. Extrapolation filter-based intra prediction (EIP) mode

[0209] 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.

[0210] 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. 26 and Fig. 27, respectively. Fig. 26 illustrates three EIP filter shapes. Fig. 27 illustrates three types of reconstructed area for EIP filter.

[0211] 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.

[0212] 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 the same as that in CCCM.

[0213] 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.21. Matrix based intra prediction replacing conventional intra modes (PDP)

[0214] 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. 28. Fig. 28 illustrates an example of L-shaped neighborhood for a given predicted block.

[0215] 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)           (2-14) where k denotes the index of the reference sample in the template.

[0216] In the test, this prediction is used for block size with both width and height up to 32 (except for 4′32, 32′4, 8′32 and 32′8) . 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 16′16 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.

[0217] The filters are trained with BVI sequences composing of 800 sequences with diverse resolutions. 2.22. Modifications to Matrix-Based Intra Prediction

[0218] Alternative matrices are used for a sub-set of block sizes that support MIP. For blocks with a max size of 32′32, alternative matrices which use the L-shaped causal template (as shown in Fig. 28) as input to generate the W′H prediction block are used in MIP modes. The L-shaped template contains T1′W and T2′H neighbor reference samples and the T1′T2 corner reference samples. T1 and T2 are both set to 2.

[0219] The prediction of a sample P (x, y) can be derived as: P (x, y) = ∑k F (x, y, k) *r (k) ,

[0220] 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) . 2.23. Intra prediction merge mode

[0221] A list of intra mode candidates is constructed using the intra modes from the neighbour blocks. It is similar to inter merge mode, but instead of motion vector the neighbour intra modes are added to the list. A flag is signalled to indicate whether to enable the proposed intra merge mode. If the flag is true, at least one intra merge candidate list is constructed. If there are more than one intra merge lists, a list index is signalled to indicate which intra merge list is selected. An index is further signalled to indicate which candidate is used for this CU. Fig. 29 illustrates neighboring blocks for merging checks. The neighbouring blocks considered for the intra merge list construction are as shown in Fig. 29. 2.24. Occurrence-based intra coding (OBIC)

[0222] 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 [IPM] += 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.

[0223] Fig. 30 illustrates non-adjacent spatial neighboring candidates for OBIC mode. Fig. 30 shows the non-adjacent spatial neighboring blocks that are used in OBIC mode’s histogram generation.

[0224] 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.

[0225] 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.

[0226] 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.

[0227] 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.

[0228] 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.25. MPM sorting

[0229] 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. Fig. 31 illustrates neighboring blocks (L, A, BL, AR, AL) used in the derivation of a general MPM list. 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 as shown in Fig. 31, 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.

[0230] 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.

[0231] 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. 3. Problems

[0232] In current design of video coding framework, a same chroma mode is used for different chroma components. However, different chroma components may favor of different coding modes. 4. Detailed solutions

[0233] 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.

[0234] In this disclosure, cross-component prediction (CCP) may include the CCP methods in the current ECM such as, CCLM, MMLM, GLM, chroma fusion, CCCM, CCCM using non-downsampled luma samples, BVG-CCCM, GL-CCCM, CCCM with multiple downsampling filters, LB-CCP, CCP merge mode, decoder derived CCP mode, interCCCM, CCP merge for chroma inter blocks. And / or other prediction method which uses information from different components to generate the prediction for the current component.

[0235] In the following disclosure, a “video unit” may refer to colour component / sub-picture / slice / tile / coding tree unit (CTU)  / CTU row / groups of CTU / coding unit (CU)  / prediction unit (PU)  / transform unit (TU)  / coding tree block (CTB)  / coding block (CB)  / prediction block (PB)  / transform block (TB)  / ablock / sub-block of a block / sub-region within a block / any other region that contains more than one sample or pixel. The video unit may be a picture, or a slice or a block, or a CTU, or a CU, or a PU, or a TU.Separate modes for chroma coding 1. It is proposed that separate coding modes may be used for different chroma components for a video unit. a. In one example, the coding mode may refer to the prediction mode. i. In one example, the prediction mode may refer to intra prediction mode and / or inter prediction mode. ii. In one example, the prediction mode may refer to a CCP method, such as CCLM, MMLM, GLM, CCCM using non-downsampled luma samples, BVG-CCCM, GL-CCCM, CCCM with multiple downsampling filters, LB-CCP, CCP merge mode, de-coder derived CCP mode, interCCCM, CCP merge for chroma inter blocks, or their variants. iii. In one example, the prediction mode may refer to a non-CCP mode, such as conven-tional intra prediction, IBC, DBV, intraTMP, EIP, MIP, PDP, TIMD, DIMD, chroma TMRL. b. In one example, the coding mode may refer to a transform method such as LFNST, NSPT, MTS. i. In one example, the coding mode may refer to the mode which is used to select the kernel set of LFNST, and / or NSPT, and / or MTS. c. In one example, the coding mode may refer to the partitioning method. i. In one example, different partitioning method may be used for different chroma com-ponents. ii. In one example, the partitioning method may refer to QT / BT / TT or other partitioning shape. d. In one example, whether to use and / or how to use the separate coding modes for different chroma components may be signalled. i. In one example, one or more syntax elements may be used to indicate whether to use the separate coding modes. ii. In one example, one or more syntax elements may be used to indicate which coding mode is used. iii. In one example, the signalling of the first coding mode of the first chroma component may depend on the second coding mode of the second chroma component. 1) In one example, the difference between the first coding mode and the second mode may be signalled. e. In one example, whether to use and / or how to use the separate coding modes for different chroma components may be derived. i. In one example, at least one of the coding modes for different chroma components may be derived. 1) In one example, the template based method may be used. 2) In one example, the coding mode may be derived from a coding mode list. a) In one example, the coding mode list may be constructed using the CCP mode and / or non-CCP mode. b) In one example, how to construct the coding mode list for a first chroma com-ponent may depend on coding information. i. For example, the coding information may refer to the coding mode of a second chroma component. ii. In one example, a first coding mode for the first chroma component is signalled, and a second coding mode for the second chroma component is derived. f. In one example, a first coding mode of the first chroma component may depend on a second coding mode of the second chroma component. i. In one example, the first coding mode is a non-CCP mode when the second coding mode is a non-CCP mode. ii. In one example, the first coding mode is a CCP mode when the second coding mode is a CCP mode. g. In one example, whether to and / or how to use separate modes for chroma components may depend on the coding information of luma component. i. For example, the coding mode of the collocated luma block. ii. For example, the prediction samples and / or reconstruction samples of the collocated luma block. h. In one example, separate coding modes of different chroma modes may be signaled separately. i. In one example, a first coding mode of a first chroma component may be signaled de-pending on a second coding mode of a second chroma component. 1) In one example, the first coding mode may be predicted by the second coding mode. 2) In one example, at least one arithmetic coding context of the first coding mode may be derived depending on the second coding mode. i. In one example, separate coding modes of different chroma modes may be signaled jointly. i. In one example, an SE may be signaled to indicate separate coding modes of different chroma modes. A first coding mode of a first chroma component and a second coding mode of a second chroma component may be derived from the SE. j. In one example, separate coding modes of different chroma modes may be derived at decoder individually. 2. In one example, one or more coding modes of the chroma components in current video unit may be used for the following video units. a. In one example, one coding mode of the chroma components may be used. i. In one example, the coding mode of Cb or the coding mode of Cr may be used. b. In one example, the one or more coding modes may be used to construct a mode candidate list for chroma components. i. In one example, the mode candidate list may refer to the non-CCP mode candidate list. ii. In one example, the mode candidate list may refer to the CCP mode candidate list. iii. In one example, the mode candidate list may refer to the CCP merge mode candidate list. iv. In one example, the mode candidate list may refer to the CCP merge mode candidate list for chroma inter blocks. c. In one example, the one or more coding modes may be used for entropy coding of the following video units. i. In one example, the one or more coding modes may be used to derive the context of one or more syntax elements. d. In one example, individual mode candidate lists may be constructed for different chroma com-ponents. i. In one example, a coding mode of a first chroma component may be used to construct the mode candidate list for the first chroma component. ii. In one example, a coding mode of a first chroma component may be used to construct the mode candidate list for the second chroma component. 3. It is proposed that the costs of one or more chroma components may be modified before the costs are used. a. In one example, the cost may refer to a cost calculated based on one or more samples in the template of the current video unit. i. In one example, the template may consist of neighbouring reconstruction samples. b. In one example, the cost may be used in the reordering where the reordering is used to sort the coding information. i. In one example, the coding information may refer to prediction mode. ii. In one example, the coding information may refer to CCP models. iii. In one example, the reordering may be used in one or more coding tools. 1) In one example, the coding tool may refer to adaptive reordering of non-CCP chroma mode, decoder derived CCP mode, chroma TMRL, EIP, MIP, PDP, In-traTMP, DBV mode, CCP merge mode, CCP merge mode for chroma inter blocks, CCCM and its variants. c. In one example, the cost of one or more chroma components (C) may be modified with a scale factor (S) . i. In one example, the modification may be C’ = C *S or C’ = C  / S. ii. In one example, the modification may be C’ = C + S or C’ = C –S. iii. In one example, the modification may be C’ = C * (1 –S) or C’ = C * (1 + S) . iv. In one example, the modification may be C’ = a*C + b. v. In one example, the modification may be C’ = (a*C + b + offset) >> n, wherein offset = 1<< (n-1) or offset = 0 or offset = (1<< (n-1) ) –1. d. In one example, the scale factor may be signalled or derived. i. In one example, the scale factor may be derived using the coding information. 1) In one example, the scale factor may be derived using the samples of the template. 2) In one example, the scale factor may be derived using the prediction samples of the current video unit. e. In one example, a first scale factor (S1) may be used for a first chroma component and a second scale factor (S2) may be used for a second chroma component. i. In one example, S1 may be derived using the coding information of the first chroma component. ii. In one example, S2 may be derived using the coding information of the second chroma component. f. In one example, the cost may be calculated as: i. The sum of the absolute transformed difference (SATD) between the predicted samples and the reconstructed samples of the template may be calculated and set as the cost. ii. Alternatively, the sum of the squared errors (SSE) may be calculated and set as the cost. iii. Alternatively, the sum of the absolute difference (SAD) may be calculated and set as the cost. iv. Alternatively, a subjective quality metric may be calculated and set as the cost. v. In one example, the structural similarity index measure (SSIM) may be calculated and set as the cost. vi. The cost may be calculated in a form of D + lambda × R, wherein D is a metric of dis-tortion such as SAD, SATD, SSE et. al, R represents the number of bits under consid-eration and lambda is a pre-defined factor.General aspects 4. In above examples, the video unit may refer to colour component / sub-picture / slice / tile / coding tree unit (CTU)  / CTU row / groups of CTU / coding unit (CU)  / prediction unit (PU)  / transform unit (TU)  / coding tree block (CTB)  / coding block (CB)  / prediction block (PB)  / transform block (TB)  / ablock / sub-block of a block / sub-region within a block / any other region that contains more than one sample or pixel. 5. 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. 6. Whether and / or how to apply the above methods may depend on the following information: a. A message signalled in the DPS / SPS / VPS / PPS / APS / picture header / slice header / tile group header / coding tree unit (CTU)  / Coding unit (CU)  / CTU row / group of CTUs / TU / PU block / Video coding unit. b. Position of CU / PU / TU / block / Video coding unit. c. Block dimension of current block and / or its neighbouring blocks. d. Block shape of current block and / or its neighbouring blocks. e. coded mode of a block, e.g., IBC or non-IBC inter mode or non-IBC subblock mode. f. Indication of the colour format (such as 4: 2: 0, 4: 4: 4) . g. Coding tree structure. h. Slice / tile group type and / or picture type. i. Colour component (e.g., may be only applied on chroma components or luma component) . j. Temporal layer ID. k. Profiles / Levels / Tiers of a standard.

[0236] Further embodiments will be described with respect to Fig. 32 to Fig. 33. Fig. 32 illustrates a flowchart of a method 3200 for video processing in accordance with embodiments of the present disclosure. The method 3200 is implemented during a conversion between a video unit of a video and a bitstream of the video. As used herein, the term “aconversion between a video unit (such as a current video unit) of a video and a bitstream of the video” may refer to “encoding the video unit into the bitstream” , “decoding the video unit from the bitstream” , and / or “generating the bitstream from the video” . The generated bitstream may be stored in a non-transitory computer-readable recording medium.

[0237] As used herein, the term “video unit” such as “current video unit” may refer to a color component, a sub-picture, a slice, a tile, a coding tree unit (CTU) , a CTU row, groups of CTUs, a coding unit (CU) , a prediction unit (PU) , a transform unit (TU) , a coding tree block (CTB) , a coding block (CB) , a prediction block (PB) , a transform block (TB) , a block, a sub-block of a block, a sub-region within a block, a region that contains more than one sample or pixel, or any other suitable unit or region.

[0238] At block 3210, for a conversion between a current video unit of a video and a bitstream of the video, a first coding mode is applied to a first chroma component (such as Cb or Cr) of the current video unit and a second coding mode is applied to a second chroma component (such as Cr or Cb) of the current video unit. The second coding mode is different from the first coding mode. At block 3220, the conversion is performed based on the applying.

[0239] The method 3200 enables using separate coding modes for different chroma components. Different chroma components may favor different coding modes. By applying separate coding modes, the coding performance and coding effectiveness can be improved.

[0240] In some embodiments, the first coding mode may be a first prediction mode, and the second coding mode may be a second prediction mode. For example, the first or second prediction mode may be an intra prediction mode and / or an inter prediction mode.

[0241] In some embodiments, the first or second prediction mode may include a cross-component prediction (CCP) mode. For example, the CCP mode may be a cross-component linear model (CCLM) mode, a multi-model linear model (MMLM) mode, a gradient linear model (GLM) mode, a convolutional cross-component model (CCCM) mode, a CCCM using non-downsampled luma samples, a block-vector guided CCCM (BVG-CCCM) mode, a gradient and location based CCCM (GL-CCCM) mode, a CCCM with multiple downsampling filters, a local boosting CCP (LB-CCP) mode, a CCP merge mode, a decoder derived CCP mode, an inter CCCM mode, a CCP merge for chroma inter blocks, or a further CCP mode.

[0242] In some embodiments, the first or second prediction may be a non-CCP mode. For example the non-CCP mode may be an intra prediction mode, an intra block copy (IBC) mode, a direct block vector (DBV) mode, an intra template matching prediction (IntraTMP) mode, an extrapolation filter-based intra prediction (EIP) mode, a matrix weighted intra prediction (MIP) mode, a matrix based intra prediction replacing conventional intra mode (PDP) , a template-based intra mode derivation (TIMD) , a decoder side intra mode derivation (DIMD) , or a chroma template-based multiple reference line intra prediction (TMRL) mode.

[0243] In an example, the first coding mode and the second coding mode may be different CCP modes. In another example, the first coding mode and the second coding mode may be different non-CCP modes. In a further example, one of the first and second coding modes is a CCP mode, and another of the first and second coding modes is a non-CCP mode.

[0244] In some embodiments, the first coding mode may be a first transform mode, and the second coding mode may be a second transform mode.

[0245] In some embodiments, the first or second transform mode may be a low-frequency non-separable secondary transform (LFNST) , a non-separable primary transform (NSPT) , a multiple transform selection (MTS) , or any further transform mode. Alternatively, in some embodiments, the first or second coding mode may be a mode for selecting a kernel set of at least one of: an LFNST, an NSPT or an MTS. In an example, the first and second coding modes may be two transform modes. In another example, the first and second coding modes may be two modes for selecting the kernel set of two of the LFNST, NSPT and MTS. In a further example, one of the first and second coding modes is a transform mode such as LFNST, NSPT or MTS, and another is a mode for selecting the kernel set for LFNST, NSPT or MTS.

[0246] In some embodiments, the first coding mode may be a first partitioning mode, and the second coding mode may be a second partitioning mode different from the first partitioning mode. For example, the first or second partitioning mode may be a quadtree (QT) partitioning, a binary tree (BT) partitioning, a ternary tree (TT) partitioning, or a further partitioning mode with a further partitioning shape.

[0247] It is to be understood that the first and second coding modes may refer to different types of modes. For example, the first coding mode may be one of the prediction mode, the transform mode and the partitioning mode, and the second coding mode may be another of the prediction mode, transform mode and the partitioning mode. The first or second coding mode may be other coding mode or coding tool not described above. Embodiments of the present disclosure are not limited here.

[0248] In some embodiments, at least one syntax element in the bitstream indicates whether to apply the first coding mode and the second coding mode to the first and second chroma components.

[0249] In some embodiments, at least one syntax element in the bitstream indicates how to apply the first coding mode and the second coding mode to the first and second chroma components. In some embodiments, the at least one syntax element may indicate the first coding mode and / or the second coding mode. For example, whether to use and / or how to use the separate coding modes for different chroma components may be signalled. One or more syntax elements may be used to indicate whether to use the separate coding modes. One or more syntax elements may be used to indicate which coding mode is used.

[0250] In some embodiments, an indication of the first coding mode of the first chroma component depends on the second coding mode of the second chroma component. For example, the signalling of the first coding mode of the first chroma component may depend on the second coding mode of the second chroma component.

[0251] In some embodiments, a difference between the first coding mode and the second coding mode is indicated in the bitstream. For example, the difference between the first coding mode and the second mode may be signalled.

[0252] In some embodiments, whether to and / or how to apply the first and second coding modes to the first and second chroma components is derived. In other words, whether to use and / or how to use the separate coding modes for different chroma components may be derived.

[0253] In some embodiments, at least one of the first coding mode or the second coding mode is derived. For example, the first coding mode and / or the second coding mode may be derived based on a template-based mechanism.

[0254] In some embodiments, at least one of the first coding mode or the second coding mode is derived from a coding mode list. For example, the coding mode list may be constructed using a CCP mode and / or a non-CCP mode.

[0255] In some embodiments, how to construct the coding mode list for the first chroma component is based on coding information. For example, the coding information may include the second coding mode of the second chroma component.

[0256] In some embodiments, the first coding mode for the first chroma component is indicated in the bitstream, and the second coding mode for the second chroma component is derived.

[0257] In some embodiments, whether to and / or how to apply the first and second coding modes to the first and second chroma components depend on coding information of a luma component associated with the current video unit, such as a coding mode of a colloated luma block, prediction samples of the collocated luma block, reconstruction samples of the collocated luma block, and the like.

[0258] In some embodiments, the first coding mode for the first chroma component is based on the second coding mode for the second chroma component. In an example, if the second coding mode is a non-CCP mode, the first coding mode may be a non-CCP mode. In another example, if the second coding mode is a CCP mode, the first coding mode may be a CCP mode.

[0259] In some embodiments, the first coding mode and the second coding mode are indicated in the bitstream separately. For example, the first coding mode of the first chroma component may be indicated in the bitstream depending on the second coding mode of the second chroma component.

[0260] In an example, the first coding mode may be predicted by the second coding mode. In another example, at least one arithmetic coding context of the first coding mode may be derived based on the second coding mode.

[0261] In some embodiments, the first coding mode and the second coding mode are indicated in the bitstream jointly. For example, a syntax element in the bitstream indicates the first coding mode for the first chroma component and the second coding mode for the second chroma component. The first coding mode for the first chroma component and the second coding mode for the second chroma component may be derived from the syntax element in the bitstream.

[0262] In some embodiments, the first coding mode for the first chroma component and the second coding mode for the second chroma component are derived at a decoder individually.

[0263] In some embodiments, at least one coding mode for at least one chroma component of the current video unit is used for at least one subsequent video unit. For example, one or more coding modes of the chroma components in the current video unit may be used for the following video units. For example, information of the one or more coding modes may be stored for subsequent video coding.

[0264] In some embodiments, the at least one coding mode may be a single coding mode such as the first coding mode for the first chroma component or the second coding mode for the second chroma component. For example, the coding mode for Cb component or the coding mode for Cr component may be used for the following video units.

[0265] In some embodiments, the method 3200 further comprises: constructing a mode candidate list for the at least one chroma component based on the at least one coding mode. The mode candidate list may refer to: a non-CCP mode candidate list, a CCP mode candidate list, a CCP merge mode candidate list, or a CCP merge mode candidate list for chroma inter blocks, and the like.

[0266] In some embodiments, the at least one coding mode is used for entropy coding of the at least one subsequent video unit. For example, the at least one coding mode may be used to derive context of one or more syntax elements for entropy coding.

[0267] In some embodiments, a first mode candidate list for the first chroma component and a second mode candidate list for the second chroma component are constructed based on the at least one coding mode. The first and second mode candidate lists may be used for the at least one subsequent video unit. For example, the first coding mode of the first chroma component may be used to construct the first motion candidate list for the first chroma component. The second coding mode of the second chroma component may be used to construct the second motion candidate list for the second chroma component.

[0268] 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. In the method, a first coding mode is applied to a first chroma component of a current video unit of the video and a second coding mode is applied to a second chroma component of the current video unit. The second coding mode is different from the first coding mode. The bitstream is generated based on the applying.

[0269] According to still further embodiments of the present disclosure, a method for storing bitstream of a video is provided. In the method, a first coding mode is applied to a first chroma component of a current video unit of the video and a second coding mode is applied to a second chroma component of the current video unit. The second coding mode is different from the first coding mode. The bitstream is generated based on the applying. The bitstream is stored in a non-transitory computer-readable recording medium.

[0270] Fig. 33 illustrates a flowchart of a method 3300 for video processing in accordance with embodiments of the present disclosure. The method 3300 is implemented during a conversion between a video unit of a video and a bitstream of the video.

[0271] At block 3310, for a conversion between a current video unit of a video and a bitstream of the video, at least one cost of at least one chroma component of the current video unit is determined. At block 3320, the at least one cost is updated based on at least one factor. The at least one factor may be predefined, or indicated in the bitstream, or derived on-the-fly. At block 3330, the conversion is performed based on the at least one updated cost.

[0272] The method 3300 enables updating or modifying the at least one cost for the chroma component (s) before being used. The coding performance can thus be improved.

[0273] In some embodiments, the at least one cost is determined based on one or more samples in a template of the current video unit. For example, the template comprises neighboring reconstruction samples of the current video unit.

[0274] In some embodiments, the method 3300 further comprises: reordering coding information based on the at least one updated cost. For example, the cost may be used in the reordering where the reordering is used to sort the coding information. By way of example, the coding information may include a prediction mode, and / or at least one CCP model, and the like.

[0275] In some embodiments, the reordering of the coding information is used in at least one coding tool. By way example, the at least one coding tool may include one or more of the following: an adaptive reordering of non-CCP chroma mode, a decoder derived CCP mode, a chroma TMRL, an EIP, an MIP, a PDP, an IntraTMP, a DBV mode, a CCP merge mode, a CCP merge mode for chroma inter blocks, a CCCM, or a further coding tool.

[0276] In some embodiments, the at least one cost is updated by one of: C’ = C *S, C’ = C  / S, C’ = C + S, C’ = C –S, C’ = C * (1 –S) , C’ = C * (1 + S) , C’ = a*C + b, C’ = (a*C + b + offset) >> n, where offset is set to one of: 1<< (n-1) , or (1<< (n-1) ) –1, or 0. Herein, C denotes the at least one cost, C’ denotes the at least one updated cost, S, a, b and n denote the at least one factor. In an example, the at least one factor is indicated in the bitstream. Alternatively, in another example, the at least one factor is derived based on coding information, such as samples of a template of the current video unit, prediction samples of the current video unit, and the like. In a further example, one of the at least one factor may be indicated in the bitstream, and another of the at least one factor may be derived based on coding information or other suitable information.

[0277] In some embodiments, the at least one factor may include a first scale factor for a first chroma component and a second scale factor for a second chroma component. For example, a first scale factor (S1) may be used for a first chroma component and a second scale factor (S2) may be used for a second chroma component.

[0278] In some embodiments, the first scale factor may be derived based on coding information of the first chroma component. Alternatively, or in addition, the second scale factor may be derived based on coding information of the second chroma component.

[0279] In some embodiments, the at least one cost is determined as one of: a sum of absolute transformed difference (SATD) between predicted samples and reconstructed samples of a template of the current video unit, a sum of squared errors (SSE) , a sum of absolute difference (SAD) between the predicted samples and the reconstructed samples, a subjective quality metric associated with the conversion, a structural similarity index measure (SSIM) , or D+lambdaR, where D denotes a metric of distortion (such as SAD, SATD, SSE or the like) , R denotes the number of bits under consideration for the conversion, and lambda denotes a pre-defined factor. It is to be understood that these example calculations of the at least one cost are only for the purpose of illustration, without suggesting any limitation. Any suitable calculation may be applied to derive the at least one cost.

[0280] 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. In the method, at least one cost of at least one chroma component of a current video unit of the video is determined. The at least one cost is updated based on at least one factor. The bitstream is generated based on the at least one updated cost.

[0281] According to still further embodiments of the present disclosure, a method for storing bitstream of a video is provided. In the method, at least one cost of at least one chroma component of a current video unit of the video is determined. The at least one cost is updated based on at least one factor. The bitstream is generated based on the at least one updated cost. The bitstream is stored in a non-transitory computer-readable recording medium.

[0282] Several embodiments regarding coding modes for chroma components and cost updating for chroma components have been described with respect to Fig. 32 and Fig. 33. It is to be understood that these embodiments described with respect to Fig. 32 and Fig. 33 such as the method 3200 and the method 3300 may be applied separately, or in any combination. With these embodiments, the coding performance may be enhanced.

[0283] In some embodiments, information regarding whether to and / or how to apply the method 3200 and / or the method 3300 may be included in the bitstream. For example, the information may be indicated at one of: a sequence level, a group of pictures level, a picture level, a slice level or a tile group level, and / or wherein the information is indicated in a sequence header, a picture header, a sequence parameter set (SPS) , a video parameter set (VPS) , a decoded parameter set (DPS) , decoding capability information (DCI) , a picture parameter set (PPS) , an adaptation parameter set (APS) , a slice header or a tile group header.

[0284] In some embodiments, information regarding whether to and / or how to apply the method 3200 and / or the method 3300 may be based on at least one of: a message included in the bitstream, a position of a CU, a position of a PU, a position of a TU, a position of a block, a position of a video coding unit, a block dimension of the current video unit, a block dimension of at least one neighboring block of the current video unit, a block shape of the current video unit, a block shape of at least one neighboring block of the current video unit, a coded mode of a block, an indication of a color format (such as 4: 2: 0 or 4: 4: 4) , a coding tree structure, a slice type, a tile group type, a picture type, at least one color component (such as luma component and / or chroma component (s) ) , a temporal layer identifier (ID) , or profiles or levels or tiers of a standard, and the like. For example, the message may be included in one of: a DPS, an SPS, a VPS, a PPS, an APS, a picture header, a slice header, a tile group header, a CTU, a CU, a CTU row, group of CTUs, a TU, a PU, a block, or a video coding unit. The coded mode of the block may include at least one of: an intra block copy (IBC) mode, a non-IBC inter mode, or a non-IBC subblock mode.

[0285] 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.

[0286] Clause 1. A method for video processing, comprising: applying, for a conversion between a current video unit of a video and a bitstream of the video, a first coding mode to a first chroma component of the current video unit and a second coding mode to a second chroma component of the current video unit, the second coding mode being different from the first coding mode; and performing the conversion based on the applying.

[0287] Clause 2. The method of clause 1, wherein the first coding mode comprises a first prediction mode, and the second coding mode comprises a second prediction mode.

[0288] Clause 3. The method of clause 2, wherein the first or second prediction mode comprises an intra prediction mode and / or an inter prediction mode.

[0289] Clause 4. The method of clause 2, wherein the first or second prediction mode comprises a cross-component prediction (CCP) mode, and wherein the CCP mode comprises at least one of: a cross-component linear model (CCLM) mode, a multi-model linear model (MMLM) mode, a gradient linear model (GLM) mode, a convolutional cross-component model (CCCM) mode, a CCCM using non-downsampled luma samples, a block-vector guided CCCM (BVG-CCCM) mode, a gradient and location based CCCM (GL-CCCM) mode, a CCCM with multiple downsampling filters, a local boosting CCP (LB-CCP) mode, a CCP merge mode, a decoder derived CCP mode, an inter CCCM mode, a CCP merge for chroma inter blocks, or a further CCP mode.

[0290] Clause 5. The method of clause 2, wherein the first or second prediction comprises a non-CCP mode, and wherein the non-CCP mode comprises at least one of: an intra prediction mode, an intra block copy (IBC) mode, a direct block vector (DBV) mode, an intra template matching prediction (IntraTMP) mode, an extrapolation filter-based intra prediction (EIP) mode, a matrix weighted intra prediction (MIP) mode, a matrix based intra prediction replacing conventional intra mode (PDP) , a template-based intra mode derivation (TIMD) , a decoder side intra mode derivation (DIMD) , or a chroma template-based multiple reference line intra prediction (TMRL) mode.

[0291] Clause 6. The method of clause 1, wherein the first coding mode comprises a first transform mode, and the second coding mode comprises a second transform mode.

[0292] Clause 7. The method of clause 6, wherein the first or second transform mode comprises at least one of: a low-frequency non-separable secondary transform (LFNST) , a non-separable primary transform (NSPT) , or a multiple transform selection (MTS) .

[0293] Clause 8. The method of clause 1, wherein the first or second coding mode comprises a mode for selecting a kernel set of at least one of: an LFNST, an NSPT or an MTS.

[0294] Clause 9. The method of clause 1, wherein the first coding mode comprises a first partitioning mode, and the second coding mode comprises a second partitioning mode different from the first partitioning mode.

[0295] Clause 10. The method of clause 9, wherein the first or second partitioning mode comprises one of: a quadtree (QT) partitioning, a binary tree (BT) partitioning, a ternary tree (TT) partitioning, or a further partitioning mode with a further partitioning shape.

[0296] Clause 11. The method of any of clauses 1 to 10, wherein at least one syntax element in the bitstream indicates whether to apply the first coding mode and the second coding mode to the first and second chroma components.

[0297] Clause 12. The method of any of clauses 1 to 11, wherein at least one syntax element in the bitstream indicates how to apply the first coding mode and the second coding mode to the first and second chroma components.

[0298] Clause 13. The method of clause 12, wherein the at least one syntax element indicates the first coding mode and / or the second coding mode.

[0299] Clause 14. The method of any of clauses 1 to 13, wherein an indication of the first coding mode of the first chroma component depends on the second coding mode of the second chroma component.

[0300] Clause 15. The method of any of clauses 1 to 14, wherein a difference between the first coding mode and the second coding mode is indicated in the bitstream.

[0301] Clause 16. The method of any of clauses 1 to 10, wherein whether to and / or how to apply the first and second coding modes to the first and second chroma components is derived.

[0302] Clause 17. The method of clause 16, wherein at least one of the first coding mode or the second coding mode is derived.

[0303] Clause 18. The method of clause 17, wherein at least one of the first coding mode or the second coding mode is derived based on a template-based mechanism.

[0304] Clause 19. The method of clause 17, wherein at least one of the first coding mode or the second coding mode is derived from a coding mode list.

[0305] Clause 20. The method of clause 19, wherein the coding mode list is constructed using at least one of: a CCP mode or a non-CCP mode.

[0306] Clause 21. The method of clause 19, wherein how to construct the coding mode list for the first chroma component is based on coding information.

[0307] Clause 22. The method of clause 21, wherein the coding information comprises the second coding mode of the second chroma component.

[0308] Clause 23. The method of any of clauses 1 to 10, wherein the first coding mode for the first chroma component is indicated in the bitstream, and the second coding mode for the second chroma component is derived.

[0309] Clause 24. The method of any of clauses 1 to 10, wherein whether to and / or how to apply the first and second coding modes to the first and second chroma components depend on coding information of a luma component.

[0310] Clause 25. The method of clause 24, wherein the coding information comprises at least one of: a coding mode of a collocated luma block, prediction samples of the collocated luma block, or reconstruction samples of the collocated luma block.

[0311] Clause 26. The method of any of clauses 1 to 25, wherein the first coding mode for the first chroma component is based on the second coding mode for the second chroma component.

[0312] Clause 27. The method of clause 26, wherein in response to the second coding mode comprising a non-CCP mode, the first coding mode comprises a non-CCP mode.

[0313] Clause 28. The method of clause 26, wherein in response to the second coding mode comprising a CCP mode, the first coding mode comprises a CCP mode.

[0314] Clause 29. The method of any of clauses 1 to 28, wherein the first coding mode and the second coding mode are indicated in the bitstream separately.

[0315] Clause 30. The method of clause 29, wherein the first coding mode of the first chroma component is indicated in the bitstream depending on the second coding mode of the second chroma component.

[0316] Clause 31. The method of clause 29, wherein the first coding mode is predicted by the second coding mode.

[0317] Clause 32. The method of clause 29, wherein at least one arithmetic coding context of the first coding mode is derived based on the second coding mode.

[0318] Clause 33. The method of any of clauses 1 to 28, wherein the first coding mode and the second coding mode are indicated in the bitstream jointly.

[0319] Clause 34. The method of clause 33, wherein a syntax element in the bitstream indicates the first coding mode for the first chroma component and the second coding mode for the second chroma component.

[0320] Clause 35. The method of clause 33, wherein the first coding mode for the first chroma component and the second coding mode for the second chroma component are derived from a syntax element in the bitstream.

[0321] Clause 36. The method of any of clauses 1 to 10, wherein the first coding mode for the first chroma component and the second coding mode for the second chroma component are derived at a decoder individually.

[0322] Clause 37. The method of any of clauses 1 to 36, wherein at least one coding mode for at least one chroma component of the current video unit is used for at least one subsequent video unit.

[0323] Clause 38. The method of clause 37, wherein the at least one coding mode comprises the first coding mode or the second coding mode.

[0324] Clause 39. The method of clause 37, wherein the at least one coding mode comprises a coding mode for Cb component or a coding mode for Cr component.

[0325] Clause 40. The method of any of clauses 37 to 39, further comprising: constructing a mode candidate list for the at least one chroma component based on the at least one coding mode.

[0326] Clause 41. The method of clause 40, wherein the mode candidate list comprises at least one of: a non-CCP mode candidate list, a CCP mode candidate list, a CCP merge mode candidate list, or a CCP merge mode candidate list for chroma inter blocks.

[0327] Clause 42. The method of any of clauses 37 to 41, wherein the at least one coding mode is used for entropy coding of the at least one subsequent video unit.

[0328] Clause 43. The method of clause 42, wherein the at least one coding mode is used to derive context of one or more syntax elements for entropy coding.

[0329] Clause 44. The method of any of clauses 37 to 39, wherein a first mode candidate list for the first chroma component and a second mode candidate list for the second chroma component are constructed based on the at least one coding mode, and the first and second mode candidate lists are used for the at least one subsequent video unit.

[0330] Clause 45. The method of clause 44, wherein the first coding mode of the first chroma component is used to construct the first motion candidate list for the first chroma component, and / or wherein the second coding mode of the second chroma component is used to construct the second motion candidate list for the second chroma component.

[0331] Clause 46. A method for video processing, comprising: determining, for a conversion between a current video unit of a video and a bitstream of the video, at least one cost of at least one chroma component of the current video unit; updating the at least one cost based on at least one factor; and performing the conversion based on the at least one updated cost.

[0332] Clause 47. The method of clause 46, wherein the at least one cost is determined based on one or more samples in a template of the current video unit.

[0333] Clause 48. The method of clause 47, wherein the template comprises neighboring reconstruction samples of the current video unit.

[0334] Clause 49. The method of any of clauses 46 to 48, further comprising: reordering coding information based on the at least one updated cost.

[0335] Clause 50. The method of clause 49, wherein the coding information comprises at least one of: a prediction mode, or at least one CCP model.

[0336] Clause 51. The method of clause 49 or 50, wherein the reordering of the coding information is used in at least one coding tool.

[0337] Clause 52. The method of clause 51, wherein the at least one coding tool comprises at least one of: an adaptive reordering of non-CCP chroma mode, a decoder derived CCP mode, a chroma TMRL, an EIP, an MIP, a PDP, an IntraTMP, a DBV mode, a CCP merge mode, a CCP merge mode for chroma inter blocks, a CCCM, or a further coding tool.

[0338] Clause 53. The method of any of clauses 46 to 52, wherein the at least one cost is updated by one of: C’ = C *S, C’ = C  / S, C’ = C + S, C’ = C –S, C’ = C * (1 –S) , C’ = C * (1 + S) , C’ = a*C + b, C’ = (a*C + b + offset) >> n, wherein offset is set to one of: 1<< (n-1) , or (1<< (n-1) ) –1, or 0, wherein C denotes the at least one cost, C’ denotes the at least one updated cost, S, a, b and n denote the at least one factor.

[0339] Clause 54. The method of any of clauses 46 to 53, wherein the at least one factor is indicated in the bitstream.

[0340] Clause 55. The method of any of clauses 46 to 53, wherein the at least one factor is derived based on coding information.

[0341] Clause 56. The method of clause 55, wherein the coding information comprises at least one of: samples of a template of the current video unit, or prediction samples of the current video unit.

[0342] Clause 57. The method of any of clauses 46 to 56, wherein the at least one factor comprises a first scale factor for a first chroma component and a second scale factor for a second chroma component.

[0343] Clause 58. The method of clause 57, wherein the first scale factor is derived based on coding information of the first chroma component, and / or wherein the second scale factor is derived based on coding information of the second chroma component.

[0344] Clause 59. The method of any of clauses 46 to 58, wherein the at least one cost is determined as one of: a sum of absolute transformed difference (SATD) between predicted samples and reconstructed samples of a template of the current video unit, a sum of squared errors (SSE) , a sum of absolute difference (SAD) between the predicted samples and the reconstructed samples, a subjective quality metric associated with the conversion, a structural similarity index measure (SSIM) , or D+lambdaR, wherein D denotes a metric of distortion, R denotes the number of bits under consideration for the conversion, and lambda denotes a pre-defined factor.

[0345] Clause 60. The method of clause 59, wherein the metric of distortion comprises at least one of: an SAD, an SATD, or an SSE.

[0346] Clause 61. The method of any of clauses 1 to 60, wherein the current video unit comprises one of: a color component, a sub-picture, a slice, a tile, a coding tree unit (CTU) , a CTU row, groups of CTUs, a coding unit (CU) , a prediction unit (PU) , a transform unit (TU) , a coding tree block (CTB) , a coding block (CB) , a prediction block (PB) , a transform block (TB) , a block, a sub-block of a block, a sub-region within a block, or a region that contains more than one sample or pixel.

[0347] Clause 62. The method of any of clauses 1 to 61, wherein information regarding whether to and / or how to apply the method is included in the bitstream, wherein the information is indicated at one of: a sequence level, a group of pictures level, a picture level, a slice level or a tile group level, and / or wherein the information is indicated in a sequence header, a picture header, a sequence parameter set (SPS) , a video parameter set (VPS) , a decoded parameter set (DPS) , decoding capability information (DCI) , a picture parameter set (PPS) , an adaptation parameter set (APS) , a slice header or a tile group header.

[0348] Clause 63. The method of any of clauses 1 to 61, wherein information regarding whether to and / or how to apply the method is based on at least one of: a message included in the bitstream, a position of a CU, a position of a PU, a position of a TU, a position of a block, a position of a video coding unit, a block dimension of the current video unit, a block dimension of at least one neighboring block of the current video unit, a block shape of the current video unit, a block shape of at least one neighboring block of the current video unit, a coded mode of a block, an indication of a color format, a coding tree structure, a slice type, a tile group type, a picture type, at least one color component, a temporal layer identifier (ID) , or profiles or levels or tiers of a standard.

[0349] Clause 64. The method of clause 63, wherein the message is included in one of: a DPS, an SPS, a VPS, a PPS, an APS, a picture header, a slice header, a tile group header, a CTU, a CU, a CTU row, group of CTUs, a TU, a PU, a block, or a video coding unit.

[0350] Clause 65. The method of clause 63, wherein the coded mode of the block comprises at least one of: an intra block copy (IBC) mode, a non-IBC inter mode, or a non-IBC subblock mode.

[0351] Clause 66. The method of clause 63, wherein the indication of the color format indicates a color format of 4: 2: 0 or a color format of 4: 4: 4.

[0352] Clause 67. The method of clause 63, wherein the at least one color component comprises at least one of: a chroma component or a luma component.

[0353] Clause 68. The method of any of clauses 1 to 67, wherein the conversion comprises encoding the current video unit into the bitstream.

[0354] Clause 69. The method of any of clauses 1 to 67, wherein the conversion comprises decoding the current video unit from the bitstream.

[0355] Clause 70. The method of any of clauses 1 to 68, wherein the conversion comprises: generating the bitstream from the video, and wherein the method further comprises: storing the bitstream in a non-transitory computer-readable recording medium.

[0356] Clause 71. 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-70.

[0357] Clause 72. A non-transitory computer-readable storage medium storing instructions that cause a processor to perform a method in accordance with any of clauses 1-70.

[0358] Clause 73. 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: applying a first coding mode to a first chroma component of a current video unit of the video and a second coding mode to a second chroma component of the current video unit, the second coding mode being different from the first coding mode; and generating the bitstream based on the applying.

[0359] Clause 74. A method for storing a bitstream of a video, comprising: applying a first coding mode to a first chroma component of a current video unit of the video and a second coding mode to a second chroma component of the current video unit, the second coding mode being different from the first coding mode; generating the bitstream based on the applying; and storing the bitstream in a non-transitory computer-readable recording medium.

[0360] Clause 75. 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 at least one cost of at least one chroma component of a current video unit of the video; updating the at least one cost based on at least one factor; and generating the bitstream based on the at least one updated cost.

[0361] Clause 76. A method for storing a bitstream of a video, comprising: determining at least one cost of at least one chroma component of a current video unit of the video; updating the at least one cost based on at least one factor; generating the bitstream based on the at least one updated cost; and storing the bitstream in a non-transitory computer-readable recording medium. Example Device

[0362] Fig. 34 illustrates a block diagram of a computing device 3400 in which various embodiments of the present disclosure can be implemented. The computing device 3400 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) .

[0363] It would be appreciated that the computing device 3400 shown in Fig. 34 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.

[0364] As shown in Fig. 34, the computing device 3400 includes a general-purpose computing device 3400. The computing device 3400 may at least comprise one or more processors or processing units 3410, a memory 3420, a storage unit 3430, one or more communication units 3440, one or more input devices 3450, and one or more output devices 3460.

[0365] In some embodiments, the computing device 3400 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 3400 can support any type of interface to a user (such as “wearable” circuitry and the like) .

[0366] The processing unit 3410 may be a physical or virtual processor and can implement various processes based on programs stored in the memory 3420. 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 3400. The processing unit 3410 may also be referred to as a central processing unit (CPU) , a microprocessor, a controller or a microcontroller.

[0367] The computing device 3400 typically includes various computer storage medium. Such medium can be any medium accessible by the computing device 3400, including, but not limited to, volatile and non-volatile medium, or detachable and non-detachable medium. The memory 3420 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 3430 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 3400.

[0368] The computing device 3400 may further include additional detachable / non-detachable, volatile / non-volatile memory medium. Although not shown in Fig. 34, 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.

[0369] The communication unit 3440 communicates with a further computing device via the communication medium. In addition, the functions of the components in the computing device 3400 can be implemented by a single computing cluster or multiple computing machines that can communicate via communication connections. Therefore, the computing device 3400 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.

[0370] The input device 3450 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 3460 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 3440, the computing device 3400 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 3400, or any devices (such as a network card, a modem and the like) enabling the computing device 3400 to communicate with one or more other computing devices, if required. Such communication can be performed via input / output (I / O) interfaces (not shown) .

[0371] In some embodiments, instead of being integrated in a single device, some or all components of the computing device 3400 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.

[0372] The computing device 3400 may be used to implement video encoding / decoding in embodiments of the present disclosure. The memory 3420 may include one or more video coding modules 3425 having one or more program instructions. These modules are accessible and executable by the processing unit 3410 to perform the functionalities of the various embodiments described herein.

[0373] In the example embodiments of performing video encoding, the input device 3450 may receive video data as an input 3470 to be encoded. The video data may be processed, for example, by the video coding module 3425, to generate an encoded bitstream. The encoded bitstream may be provided via the output device 3460 as an output 3480.

[0374] In the example embodiments of performing video decoding, the input device 3450 may receive an encoded bitstream as the input 3470. The encoded bitstream may be processed, for example, by the video coding module 3425, to generate decoded video data. The decoded video data may be provided via the output device 3460 as the output 3480.

[0375] 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:applying, for a conversion between a current video unit of a video and a bitstream of the video, a first coding mode to a first chroma component of the current video unit and a second coding mode to a second chroma component of the current video unit, the second coding mode being different from the first coding mode; andperforming the conversion based on the applying.2.The method of claim 1, wherein the first coding mode comprises a first prediction mode, and the second coding mode comprises a second prediction mode.3.The method of claim 2, wherein the first or second prediction mode comprises an intra prediction mode and / or an inter prediction mode.4.The method of claim 2, wherein the first or second prediction mode comprises a cross-component prediction (CCP) mode, andwherein the CCP mode comprises at least one of: a cross-component linear model (CCLM) mode, a multi-model linear model (MMLM) mode, a gradient linear model (GLM) mode, a convolutional cross-component model (CCCM) mode, a CCCM using non-downsampled luma samples, a block-vector guided CCCM (BVG-CCCM) mode, a gradient and location based CCCM (GL-CCCM) mode, a CCCM with multiple downsampling filters, a local boosting CCP (LB-CCP) mode, a CCP merge mode, a decoder derived CCP mode, an inter CCCM mode, a CCP merge for chroma inter blocks, or a further CCP mode.5.The method of claim 2, wherein the first or second prediction comprises a non-CCP mode, andwherein the non-CCP mode comprises at least one of: an intra prediction mode, an intra block copy (IBC) mode, a direct block vector (DBV) mode, an intra template matching prediction (IntraTMP) mode, an extrapolation filter-based intra prediction (EIP) mode, a matrix weighted intra prediction (MIP) mode, a matrix based intra prediction replacing conventional intra mode (PDP) , a template-based intra mode derivation (TIMD) , a decoder side intra mode derivation (DIMD) , or a chroma template-based multiple reference line intra prediction (TMRL) mode.6.The method of claim 1, wherein the first coding mode comprises a first transform mode, and the second coding mode comprises a second transform mode.7.The method of claim 6, wherein the first or second transform mode comprises at least one of:a low-frequency non-separable secondary transform (LFNST) , a non-separable primary transform (NSPT) , or a multiple transform selection (MTS) .8.The method of claim 1, wherein the first or second coding mode comprises a mode for selecting a kernel set of at least one of: an LFNST, an NSPT or an MTS.9.The method of claim 1, wherein the first coding mode comprises a first partitioning mode, and the second coding mode comprises a second partitioning mode different from the first partitioning mode.10.The method of claim 9, wherein the first or second partitioning mode comprises one of: a quadtree (QT) partitioning, a binary tree (BT) partitioning, a ternary tree (TT) partitioning, or a further partitioning mode with a further partitioning shape.11.The method of any of claims 1 to 10, wherein at least one syntax element in the bitstream indicates whether to apply the first coding mode and the second coding mode to the first and second chroma components.12.The method of any of claims 1 to 11, wherein at least one syntax element in the bitstream indicates how to apply the first coding mode and the second coding mode to the first and second chroma components.13.The method of claim 12, wherein the at least one syntax element indicates the first coding mode and / or the second coding mode.14.The method of any of claims 1 to 13, wherein an indication of the first coding mode of the first chroma component depends on the second coding mode of the second chroma component.15.The method of any of claims 1 to 14, wherein a difference between the first coding mode and the second coding mode is indicated in the bitstream.16.The method of any of claims 1 to 10, wherein whether to and / or how to apply the first and second coding modes to the first and second chroma components is derived.17.The method of claim 16, wherein at least one of the first coding mode or the second coding mode is derived.18.The method of claim 17, wherein at least one of the first coding mode or the second coding mode is derived based on a template-based mechanism.19.The method of claim 17, wherein at least one of the first coding mode or the second coding mode is derived from a coding mode list.20.The method of claim 19, wherein the coding mode list is constructed using at least one of: a CCP mode or a non-CCP mode.21.The method of claim 19, wherein how to construct the coding mode list for the first chroma component is based on coding information.22.The method of claim 21, wherein the coding information comprises the second coding mode of the second chroma component.23.The method of any of claims 1 to 10, wherein the first coding mode for the first chroma component is indicated in the bitstream, and the second coding mode for the second chroma component is derived.24.The method of any of claims 1 to 10, wherein whether to and / or how to apply the first and second coding modes to the first and second chroma components depend on coding information of a luma component.25.The method of claim 24, wherein the coding information comprises at least one of:a coding mode of a collocated luma block,prediction samples of the collocated luma block, orreconstruction samples of the collocated luma block.26.The method of any of claims 1 to 25, wherein the first coding mode for the first chroma component is based on the second coding mode for the second chroma component.27.The method of claim 26, wherein in response to the second coding mode comprising a non-CCP mode, the first coding mode comprises a non-CCP mode.28.The method of claim 26, wherein in response to the second coding mode comprising a CCP mode, the first coding mode comprises a CCP mode.29.The method of any of claims 1 to 28, wherein the first coding mode and the second coding mode are indicated in the bitstream separately.30.The method of claim 29, wherein the first coding mode of the first chroma component is indicated in the bitstream depending on the second coding mode of the second chroma component.31.The method of claim 29, wherein the first coding mode is predicted by the second coding mode.32.The method of claim 29, wherein at least one arithmetic coding context of the first coding mode is derived based on the second coding mode.33.The method of any of claims 1 to 28, wherein the first coding mode and the second coding mode are indicated in the bitstream jointly.34.The method of claim 33, wherein a syntax element in the bitstream indicates the first coding mode for the first chroma component and the second coding mode for the second chroma component.35.The method of claim 33, wherein the first coding mode for the first chroma component and the second coding mode for the second chroma component are derived from a syntax element in the bitstream.36.The method of any of claims 1 to 10, wherein the first coding mode for the first chroma component and the second coding mode for the second chroma component are derived at a decoder individually.37.The method of any of claims 1 to 36, wherein at least one coding mode for at least one chroma component of the current video unit is used for at least one subsequent video unit.38.The method of claim 37, wherein the at least one coding mode comprises the first coding mode or the second coding mode.39.The method of claim 37, wherein the at least one coding mode comprises a coding mode for Cb component or a coding mode for Cr component.40.The method of any of claims 37 to 39, further comprising:constructing a mode candidate list for the at least one chroma component based on the at least one coding mode.41.The method of claim 40, wherein the mode candidate list comprises at least one of: a non-CCP mode candidate list, a CCP mode candidate list, a CCP merge mode candidate list, or a CCP merge mode candidate list for chroma inter blocks.42.The method of any of claims 37 to 41, wherein the at least one coding mode is used for entropy coding of the at least one subsequent video unit.43.The method of claim 42, wherein the at least one coding mode is used to derive context of one or more syntax elements for entropy coding.44.The method of any of claims 37 to 39, wherein a first mode candidate list for the first chroma component and a second mode candidate list for the second chroma component are constructed based on the at least one coding mode, and the first and second mode candidate lists are used for the at least one subsequent video unit.45.The method of claim 44, wherein the first coding mode of the first chroma component is used to construct the first motion candidate list for the first chroma component, and / orwherein the second coding mode of the second chroma component is used to construct the second motion candidate list for the second chroma component.46.A method for video processing, comprising:determining, for a conversion between a current video unit of a video and a bitstream of the video, at least one cost of at least one chroma component of the current video unit;updating the at least one cost based on at least one factor; andperforming the conversion based on the at least one updated cost.47.The method of claim 46, wherein the at least one cost is determined based on one or more samples in a template of the current video unit.48.The method of claim 47, wherein the template comprises neighboring reconstruction samples of the current video unit.49.The method of any of claims 46 to 48, further comprising:reordering coding information based on the at least one updated cost.50.The method of claim 49, wherein the coding information comprises at least one of: a prediction mode, or at least one CCP model.51.The method of claim 49 or 50, wherein the reordering of the coding information is used in at least one coding tool.52.The method of claim 51, wherein the at least one coding tool comprises at least one of:an adaptive reordering of non-CCP chroma mode, a decoder derived CCP mode, a chroma TMRL, an EIP, an MIP, a PDP, an IntraTMP, a DBV mode, a CCP merge mode, a CCP merge mode for chroma inter blocks, a CCCM, or a further coding tool.53.The method of any of claims 46 to 52, wherein the at least one cost is updated by one of: C’= C *S, C’= C  / S, C’= C + S, C’= C –S, C’= C * (1 –S) , C’= C * (1 + S) , C’= a*C + b, C’= (a*C + b + offset) >> n, wherein offset is set to one of: 1<< (n-1) , or (1<< (n-1) ) –1, or 0,wherein C denotes the at least one cost, C’ denotes the at least one updated cost, S, a, b and n denote the at least one factor.54.The method of any of claims 46 to 53, wherein the at least one factor is indicated in the bitstream.55.The method of any of claims 46 to 53, wherein the at least one factor is derived based on coding information.56.The method of claim 55, wherein the coding information comprises at least one of: samples of a template of the current video unit, or prediction samples of the current video unit.57.The method of any of claims 46 to 56, wherein the at least one factor comprises a first scale factor for a first chroma component and a second scale factor for a second chroma component.58.The method of claim 57, wherein the first scale factor is derived based on coding information of the first chroma component, and / orwherein the second scale factor is derived based on coding information of the second chroma component.59.The method of any of claims 46 to 58, wherein the at least one cost is determined as one of:a sum of absolute transformed difference (SATD) between predicted samples and reconstructed samples of a template of the current video unit,a sum of squared errors (SSE) ,a sum of absolute difference (SAD) between the predicted samples and the reconstructed samples,a subjective quality metric associated with the conversion,a structural similarity index measure (SSIM) , orD + lambda×R, wherein D denotes a metric of distortion, R denotes the number of bits under consideration for the conversion, and lambda denotes a pre-defined factor.60.The method of claim 59, wherein the metric of distortion comprises at least one of: an SAD, an SATD, or an SSE.61.The method of any of claims 1 to 60, wherein the current video unit comprises one of: a color component, a sub-picture, a slice, a tile, a coding tree unit (CTU) , a CTU row, groups of CTUs, a coding unit (CU) , a prediction unit (PU) , a transform unit (TU) , a coding tree block (CTB) , a coding block (CB) , a prediction block (PB) , a transform block (TB) , a block, a sub-block of a block, a sub-region within a block, or a region that contains more than one sample or pixel.62.The method of any of claims 1 to 61, wherein information regarding whether to and / or how to apply the method is included in the bitstream,wherein the information is indicated at one of: a sequence level, a group of pictures level, a picture level, a slice level or a tile group level, and / orwherein the information is indicated in a sequence header, a picture header, a sequence parameter set (SPS) , a video parameter set (VPS) , a decoded parameter set (DPS) , decoding capability information (DCI) , a picture parameter set (PPS) , an adaptation parameter set (APS) , a slice header or a tile group header.63.The method of any of claims 1 to 61, wherein information regarding whether to and / or how to apply the method is based on at least one of:a message included in the bitstream,a position of a CU,a position of a PU,a position of a TU,a position of a block,a position of a video coding unit,a block dimension of the current video unit,a block dimension of at least one neighboring block of the current video unit,a block shape of the current video unit,a block shape of at least one neighboring block of the current video unit,a coded mode of a block,an indication of a color format,a coding tree structure,a slice type,a tile group type,a picture type,at least one color component,a temporal layer identifier (ID) , orprofiles or levels or tiers of a standard.64.The method of claim 63, wherein the message is included in one of: a DPS, an SPS, a VPS, a PPS, an APS, a picture header, a slice header, a tile group header, a CTU, a CU, a CTU row, group of CTUs, a TU, a PU, a block, or a video coding unit.65.The method of claim 63, wherein the coded mode of the block comprises at least one of: an intra block copy (IBC) mode, a non-IBC inter mode, or a non-IBC subblock mode.66.The method of claim 63, wherein the indication of the color format indicates a color format of 4: 2: 0 or a color format of 4: 4: 4.67.The method of claim 63, wherein the at least one color component comprises at least one of: a chroma component or a luma component.68.The method of any of claims 1 to 67, wherein the conversion comprises encoding the current video unit into the bitstream.69.The method of any of claims 1 to 67, wherein the conversion comprises decoding the current video unit from the bitstream.70.The method of any of claims 1 to 68, wherein the conversion comprises: generating the bitstream from the video, andwherein the method further comprises: storing the bitstream in a non-transitory computer-readable recording medium.71.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 to 70.72.A non-transitory computer-readable storage medium storing instructions that cause a processor to perform a method in accordance with any of claims 1 to 70.73.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:applying a first coding mode to a first chroma component of a current video unit of the video and a second coding mode to a second chroma component of the current video unit, the second coding mode being different from the first coding mode; andgenerating the bitstream based on the applying.74.A method for storing a bitstream of a video, comprising:applying a first coding mode to a first chroma component of a current video unit of the video and a second coding mode to a second chroma component of the current video unit, the second coding mode being different from the first coding mode;generating the bitstream based on the applying; andstoring the bitstream in a non-transitory computer-readable recording medium.75.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 at least one cost of at least one chroma component of a current video unit of the video;updating the at least one cost based on at least one factor; andgenerating the bitstream based on the at least one updated cost.76.A method for storing a bitstream of a video, comprising:determining at least one cost of at least one chroma component of a current video unit of the video;updating the at least one cost based on at least one factor;generating the bitstream based on the at least one updated cost; andstoring the bitstream in a non-transitory computer-readable recording medium.