Method and device for video processing and medium

By using intra-frame block copy (IBC) technology combined with geometric division mode (GPM) in video encoding and decoding technology, the problem of insufficient encoding and decoding efficiency in the prior art is solved, and more efficient video encoding and decoding performance is achieved.

CN119817100APending Publication Date: 2025-04-11DOUYIN VISION CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202380063265.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Priority Date
2022-09-03
Filing Date
2023-09-01
Publication Date
2025-04-11

AI Technical Summary

Technical Problem

The existing video encoding and decoding technology has shortcomings in improving the encoding and decoding efficiency, especially when processing complex video content, it is difficult to effectively utilize intra-block copying technology to improve performance.

Method used

Intra-block copy (IBC) technology is used in combination with geometric division mode (GPM), and the video unit is divided into multiple subdivisions according to geometric division mode and predicted based on these subdivisions to generate a bitstream of the video unit.

Benefits of technology

This method significantly improves the performance and efficiency of video encoding and decoding, especially when processing complex video content, it is possible to capture the inherent geometric structure of the video more accurately, thereby improving the encoding and decoding performance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119817100A_ABST
    Figure CN119817100A_ABST
Patent Text Reader

Abstract

Embodiments of the present disclosure provide a scheme for video processing. A method for video processing is presented. The method comprises, for a conversion between a video unit of a video and a bitstream of the video unit, obtaining a prediction of at least one object of the video unit by using Intra Block Copy (IBC), where the video unit is encoded and decoded using an IBC-Geometric Partition Mode (GPM) or the video unit is predicted by a plurality of hypotheses, the video unit is geometrically divided into a plurality of sub-partitions in the IBC-GPM; and performing the conversion based on the prediction of the at least one object of the video unit.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] Embodiments of the present disclosure generally relate to video processing techniques, and more particularly to intra-block copying with geometric partitioning. Background Art

[0002] Nowadays, digital video capabilities are being applied to all aspects of people's lives. Various types of video compression technologies, such as MPEG-2, MPEG-4, ITU-TH.263, ITU-TH.264 / MPEG-4 Part 10 Advanced Video Codec (AVC), ITU-TH.265 High Efficiency Video Codec (HEVC) standard, and Versatile Video Codec (VVC) standard, have been proposed for video encoding / decoding. However, it is generally expected to further improve the encoding and decoding efficiency of video encoding and decoding technologies. Summary of the invention

[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 includes: for conversion between a video unit of a video and a bitstream of the video unit, obtaining a prediction of at least one object of the video unit by using intra-frame block copy (IBC), wherein the video unit is encoded and decoded using IBC-geometric partitioning mode (GPM) or the video unit is predicted by multiple hypotheses, in which the video unit is geometrically divided into multiple sub-partitions; and performing conversion based on the prediction of at least one object of the video unit. In this way, the encoding and decoding performance and efficiency can be improved.

[0005] In a second aspect, a device for video processing is provided. The device includes a processor and a non-volatile memory having instructions thereon. The instructions, when executed by the processor, cause the processor to perform the method according to the first aspect of the present disclosure.

[0006] In a third aspect, a non-transitory computer-readable storage medium is provided, wherein the non-transitory computer-readable storage medium stores instructions, wherein the instructions enable a processor to execute the method according to the first aspect of the present disclosure.

[0007] In a fourth aspect, another non-transitory computer-readable recording medium is provided. The non-transitory computer-readable recording medium stores a bitstream of a video generated by a method performed by a device for video processing. The method includes: obtaining a prediction of at least one object of a video unit of the video by using intra-frame block copying (IBC), wherein the video unit is encoded and decoded using IBC-geometric partitioning mode (GPM) or the video unit is predicted by multiple hypotheses, and the video unit is geometrically divided into multiple sub-partitions in IBC-GPM; and generating a bitstream based on the prediction of at least one object of the video unit. In this way, the encoding and decoding performance and efficiency can be improved.

[0008] In a fifth aspect, a method for storing a bitstream of a video is proposed. The method includes: obtaining a prediction of at least one object of a video unit of the video by using intra-frame block copy (IBC), wherein the video unit is encoded and decoded using IBC-geometric partitioning mode (GPM) or the video unit is predicted by multiple hypotheses, in which the video unit is geometrically divided into multiple sub-partitions; generating a bitstream based on the prediction of at least one object of the video unit; and storing the bitstream in a non-transitory computer-readable recording medium. In this way, the encoding and decoding performance and efficiency can be improved.

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

[0010] The above and other objects, features and advantages of the exemplary embodiments of the present disclosure will become more apparent through the following detailed description with reference to the accompanying drawings. In the exemplary embodiments of the present disclosure, the same reference numerals generally refer to the same components.

[0011] Figure 1 shows a block diagram illustrating an example video encoding and decoding system according to some embodiments of the present disclosure;

[0012] Figure 2 shows a block diagram illustrating a first example video encoder according to some embodiments of the present disclosure;

[0013] Figure 3 shows a block diagram illustrating an example video decoder according to some embodiments of the present disclosure;

[0014] Figure 4 An example of an encoder block diagram is shown;

[0015] Figure 5 67 intra prediction modes are shown;

[0016] Figure 6 Reference samples for wide-angle intra prediction are shown;

[0017] Figure 7 The discontinuity problem is shown in the case of orientations exceeding 45°;

[0018] Figure 8 The MMVD search point is shown;

[0019] Fig. 9 It is a diagram for the symmetric MVD mode;

[0020] Fig.10 shows the extended CU area used in BDOF;

[0021] Fig.11 The top and left neighboring blocks used in the CIIP weight derivation are shown;

[0022] Fig.12 An affine motion model based on control points is shown;

[0023] Fig.13 The affine MVF of each sub-block is shown;

[0024] Fig.14 The position of the inherited affine motion predictor is shown;

[0025] Fig.15 Control point motion vector inheritance is shown;

[0026] Fig.16 The positions of candidate positions for the constructed affine merge pattern are shown;

[0027] Fig.17 is a diagram of the use of motion vectors for the proposed combination method;

[0028] Fig.18 Sub-block MV VSB and pixel Δv(i,j) are shown;

[0029] Fig.19A shows the spatially adjacent blocks used by ATVMP;

[0030] Fig.19B shows the derivation of a sub-CU motion field by applying motion shifts from spatial neighbors and scaling motion information from corresponding co-located sub-CUs;

[0031] Fig. 20 Positional illumination compensation is shown;

[0032] Fig.21 No subsampling for the short edges is shown;

[0033] Fig. 22 Decoding side motion vector refinement is shown;

[0034] Fig.23 Diamond-shaped areas in the search area are shown;

[0035] Fig.24 The positions of spatial merging candidates are shown;

[0036] Fig.25 shows candidate pairs considered for redundancy check of spatial merging candidates;

[0037] Fig.26 is an illustration of motion vector scaling for temporal merging candidates;

[0038] Fig. 27 Candidate positions for temporal merging of candidates C0 and C1 are shown;

[0039] Fig.28 The VVC spatial neighboring blocks of the current block are shown;

[0040] Fig.29 is a diagram of the virtual blocks in the i-th search round;

[0041] Fig.30 An example of a GPM split grouped at the same angle is shown;

[0042] Fig.31 Unidirectional prediction MV selection for geometric partitioning mode is shown;

[0043] Fig.32 An example generation of blending weights w0 using a geometric partitioning pattern is shown;

[0044] Fig.33 shows spatial neighboring blocks used to derive spatial merging candidates;

[0045] Fig.34 It shows that template matching is performed on the search area around the initial MV;

[0046] Fig.35 is a diagram of a sub-block to which OBMC is applied;

[0047] Fig.36 The SBT position, type and transformation type are shown;

[0048] Fig.37 Neighboring samples used to calculate SAD are shown;

[0049] Fig.38 Neighboring samples used to calculate SAD for sub-CU level motion information are shown;

[0050] Fig.39 The classification process is shown;

[0051] Fig.40 shows the recorder process in the encoder;

[0052] Fig.41 shows the reordering process in the decoder;

[0053] Fig.42 shows the IBC reference area depending on the current CU position;

[0054] Fig.43 An example of symmetry in a picture of screen content is shown;

[0055] Fig.44A is a diagram of BV adjustment for horizontal flipping;

[0056] Fig.44B is a diagram of BV adjustment for vertical flipping;

[0057] Fig.45 The intra-frame template matching search area used is shown;

[0058] Fig.46 A flowchart showing a method for video processing according to an embodiment of the present disclosure; and

[0059] Fig.47 A block diagram of a computing device is shown in which various embodiments of the present disclosure may be implemented.

[0060] Throughout the drawings, the same or similar reference numbers generally refer to the same or similar elements. DETAILED DESCRIPTION

[0061] The principle of the present disclosure will now be described with reference to some embodiments. It should be understood that these embodiments are described only for the purpose of illustrating and helping those skilled in the art to understand and implement the present disclosure, without implying any limitation on the scope of the present disclosure. In addition to the methods described below, the disclosure described herein can also be implemented in various ways.

[0062] In the following description and claims, unless defined otherwise, all scientific and technical terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which the present disclosure belongs.

[0063] References to "one embodiment," "an embodiment," "an example embodiment," and the like in this disclosure indicate that the described embodiment may include a particular feature, structure, or characteristic, but not every embodiment must include the particular feature, structure, or characteristic. Furthermore, these phrases do not necessarily refer to the same embodiment. Furthermore, when a particular feature, structure, or characteristic is described in conjunction with an example embodiment, whether or not explicitly described, it is considered to be within the knowledge of those skilled in the art to affect such feature, structure, or characteristic in conjunction with other embodiments.

[0064] It should be understood that although the terms "first" and "second" etc. may be used herein to describe various elements, these elements should not be limited to these terms. These terms are only used to distinguish one element from another element. For example, a first element may be referred to as a second element, and similarly, a second element may be referred to as a first element without departing from the scope of the example embodiments. As used herein, the term "and / or" includes any and all combinations of one or more of the listed terms.

[0065] The terms used herein are only used for the purpose of describing specific embodiments and are not intended to limit the exemplary embodiments. As used herein, the singular forms "a", "an", and "the" are also intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the terms "including", "comprising", and / or "having" when used herein indicate the presence of the features, elements, and / or components, etc., but do not exclude the presence or addition of one or more other features, elements, components, and / or combinations thereof. Example Environment

[0066] Figure 1 1 is a block diagram illustrating an example video codec system 100 that may utilize the techniques of the present disclosure. As shown, the video codec system 100 may include a source device 110 and a destination device 120. The source device 110 may also be referred to as a video encoding device, and the destination device 120 may also be referred to as a video decoding device. In operation, the source device 110 may be configured to generate encoded video data, and the destination device 120 may 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.

[0067] The video source 112 may include a source such as a video capture device. Examples of a video capture device include, but are not limited to, an interface for receiving video data from a video content provider, a computer graphics system for generating video data, and / or a combination thereof.

[0068] The video data may include 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 bit sequence that forms a codec representation of the video data. The bitstream may include a codec picture and associated data. The codec picture is a codec representation of the picture. The associated data may include a sequence parameter set, a picture parameter set, and other grammatical structures. The I / O interface 116 may include a modulator / demodulator and / or a transmitter. The encoded video data may be directly transmitted to the destination device 120 via the network 130A via the I / O interface 116. The encoded video data may also be stored on a storage medium / server 130B for access by the destination device 120.

[0069] 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 obtain 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 the user. The display device 122 may be integrated with the destination device 120, or may be outside the destination device 120, which is configured to interface with an external display device.

[0070] The video encoder 114 and the video decoder 124 may operate according to a video compression standard, such as the High Efficiency Video Codec (HEVC) standard, the Versatile Video Codec (VVC) standard, and other existing and / or future standards.

[0071] Figure 2 is a block diagram showing an example of a video encoder 200 according to some embodiments of the present disclosure, which may be Figure 1 An example of a video encoder 114 in the system 100 is shown.

[0072] Video encoder 200 may be configured to implement any or all of the techniques of this disclosure. Figure 2 In the example of , video encoder 200 includes multiple functional components. The techniques described in this disclosure can be shared between the various components of video encoder 200. In some examples, a processor can be configured to perform any or all of the techniques described in this disclosure.

[0073] In some embodiments, the video encoder 200 may include a partitioning unit 201, a prediction unit 202, 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 coding and decoding unit 214, wherein the prediction unit 202 may include a mode selection unit 203, a motion estimation unit 204, a motion compensation unit 205 and an intra-frame prediction unit 206.

[0074] 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, where at least one reference picture is a picture where the current video block is located.

[0075] Furthermore, although some components (such as the motion estimation unit 204 and the motion compensation unit 205) may be integrated, for the purpose of explanation, these components are described in detail below. Figure 2 are shown separately in the example.

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

[0077] The mode selection unit 203 may select one of a plurality of codec modes (intra or inter), for example, based on the error result, and provide the generated intra codec block or inter codec block to the residual generation unit 207 to generate residual block data, and to the reconstruction unit 212 to reconstruct the codec block for use as a reference picture. In some examples, the mode selection unit 203 may select a combined intra and inter prediction (CIIP) mode, where the prediction is based on an inter prediction signal and an intra prediction signal. In the case of inter prediction, the mode selection unit 203 may also select a resolution for the motion vector (e.g., sub-pixel precision or integer pixel precision) for the block.

[0078] To perform inter-frame prediction on the current video block, the motion estimation unit 204 may generate motion information for the current video block by comparing the current video block with one or more reference frames from the buffer 213. 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.

[0079] The motion estimation unit 204 and the motion compensation unit 205 may perform different operations on the 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 consisting of macroblocks that are all based on macroblocks within the same picture. Furthermore, as used herein, in some aspects, "P slices" and "B slices" may refer to portions of a picture consisting of macroblocks that are independent of macroblocks in the same picture.

[0080] In some examples, the motion estimation unit 204 may perform unidirectional prediction on the current video block, and the motion estimation unit 204 may search the reference pictures of list 0 or list 1 to find the reference video block for the current video block. The motion estimation unit 204 may then generate a reference index and a motion vector, the reference index indicating the reference picture in list 0 or list 1 containing the reference video block, and the motion vector indicating the spatial displacement between the current video block and the reference video block. The motion estimation unit 204 may output the reference index, the prediction direction indicator, and the motion vector as the motion information of the current video block. The motion compensation unit 205 may generate a predicted video block for the current video block based on the reference video block indicated by the motion information of the current video block.

[0081] Alternatively, in other examples, the motion estimation unit 204 may perform bidirectional prediction on 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 a plurality of reference indexes and a plurality of motion vectors, the plurality of reference indexes indicating a plurality of reference pictures in list 0 and list 1 containing a plurality of reference video blocks, and the plurality of motion vectors indicating a plurality of spatial displacements between the plurality of reference video blocks and the current video block. The motion estimation unit 204 may output the plurality of reference indexes and the plurality of motion vectors of the current video block as motion information of the current video block. The motion compensation unit 205 may generate a predicted video block for the current video block based on the plurality of reference video blocks indicated by the motion information of the current video block.

[0082] In some examples, motion estimation unit 204 may output a complete set of motion information for use in a decoding process by a decoder. Alternatively, in some embodiments, motion estimation unit 204 may reference motion information of another video block to signal motion information of the current video block. For example, 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.

[0083] In one example, motion estimation unit 204 may indicate to video decoder 300 a value in a syntax structure associated with the current video block that indicates that the current video block has the same motion information as another video block.

[0084] In another example, the motion estimation unit 204 may identify another video block and a motion vector difference (MVD) in a syntax structure associated with the current video block. The motion vector difference indicates the 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.

[0085] As discussed above, the video encoder 200 may predictively signal motion vectors.Two examples of predictive signaling techniques that may be implemented by the video encoder 200 include Advanced Motion Vector Prediction (AMVP) and merge mode signaling.

[0086] 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 prediction video block and various syntax elements.

[0087] The residual generation unit 207 may generate residual data for the current video block by subtracting (e.g., indicated by a minus sign) the prediction 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 corresponding to different sample portions of samples in the current video block.

[0088] In other examples, such as in skip mode, there may be no residual data for the current video block, and the residual generation unit 207 may not perform a subtraction operation.

[0089] Transform processing unit 208 may generate one or more transform coefficient video blocks for a current video block by applying one or more transforms to the residual video block associated with the current video block.

[0090] After transform processing unit 208 generates a transform coefficient video block associated with the current video block, 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.

[0091] The inverse quantization unit 210 and the inverse transform unit 211 may apply inverse quantization and inverse transform 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 prediction video blocks generated by the prediction unit 202 to generate a reconstructed video block associated with the current video block for storage in the buffer 213.

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

[0093] The entropy coding unit 214 may receive data from other functional components of the video encoder 200. When the entropy coding unit 214 receives the data, the entropy coding unit 214 may perform one or more entropy coding operations to generate entropy coded data and output a bitstream including the entropy coded data.

[0094] Figure 3 is a block diagram showing an example of a video decoder 300 according to some embodiments of the present disclosure, which may be Figure 1 An example of a video decoder 124 in the system 100 is shown.

[0095] Video decoder 300 may be configured to perform any or all of the techniques of this disclosure. Figure 3 In the example of , video decoder 300 includes multiple functional components. The techniques described in this disclosure can be shared between the various components of video decoder 300. In some examples, a processor can be configured to perform any or all of the techniques described in this disclosure.

[0096] exist Figure 3 In the example of , 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. In some examples, the video decoder 300 can perform a decoding process that is generally opposite to the encoding process described with respect to the video encoder 200.

[0097] The entropy decoding unit 301 can retrieve the encoded bitstream. The encoded bitstream may include entropy encoded video data (e.g., encoded video data blocks). The entropy decoding unit 301 can decode the entropy encoded video data, and the motion compensation unit 302 can determine motion information from the entropy decoded video data, the motion information including motion vectors, motion vector precision, reference picture list indexes, and other motion information. The motion compensation unit 302 can determine the information, for example, by performing AMVP and merge mode. AMVP is used, including deriving several most likely candidates based on data and reference pictures from adjacent PBs. The motion information typically includes horizontal and vertical motion vector displacement values, one or two reference picture indexes, and in the case of prediction areas in B strips, also includes an identification of which reference picture list is associated with each index. As used herein, in some aspects, "merge mode" may refer to deriving motion information from blocks that are adjacent in space or time.

[0098] The motion compensation unit 302 may generate a motion compensated block, possibly performing interpolation based on an interpolation filter.Identifiers for the interpolation filters used with sub-pixel precision may be included in the syntax elements.

[0099] The motion compensation unit 302 may calculate interpolation values ​​for sub-integer pixels of a reference block using an interpolation filter used by the video encoder 200 during encoding of the video block. The motion compensation unit 302 may determine the interpolation filter used by the video encoder 200 based on received syntax information, and the motion compensation unit 302 may use the interpolation filter to generate a prediction block.

[0100] The motion compensation unit 302 may use at least part of the syntax information to determine the size of blocks used to encode (multiple) frames and / or (multiple) slices of the encoded video sequence, partition information describing how each macroblock of a picture of the encoded video sequence is partitioned, a mode indicating how each partition is encoded, one or more reference frames (and reference frame lists) for each inter-coded block, and other information for decoding the encoded video sequence. As used herein, in some aspects, a "slice" may refer to a data structure that can be decoded independently of other slices of the same picture in terms of entropy coding and decoding, signal prediction, and residual signal reconstruction. A slice may be an entire picture, or it may be a region of a picture.

[0101] The intra prediction unit 303 may use, for example, an intra prediction mode received in the bitstream to form a prediction block from spatially neighboring blocks. The inverse quantization unit 304 inverse quantizes (i.e., dequantizes) the quantized video block coefficients provided in the bitstream and decoded by the entropy decoding unit 301. The inverse transform unit 305 applies an inverse transform.

[0102] The reconstruction unit 306 may obtain the decoded block, for example, by adding the residual block to the corresponding prediction block generated by the motion compensation unit 302 or the intra prediction unit 303. If necessary, a deblocking filter may also be applied to filter the decoded block to remove block artifacts. The decoded video block is then stored in a buffer 307, which provides reference blocks for subsequent motion compensation / intra prediction, and the buffer 307 also generates the decoded video for presentation on a display device.

[0103] Some example embodiments of the present disclosure will be described in detail below. It should be noted that the section titles used in this document are for ease of understanding, and the embodiments disclosed in the section are not limited to the section. In addition, although some embodiments are described with reference to general video codecs or other specific video codecs, the disclosed technology is also applicable to other video coding and decoding technologies. In addition, although some embodiments describe the video encoding steps in detail, it should be understood that the corresponding decoding steps of canceling the encoding will be implemented by the decoder. In addition, the term video processing includes video coding or compression, video decoding or decompression, and video transcoding, in which video pixels are represented from one compression format to another compression format or at different compression bit rates. 1. Brief Overview The present disclosure relates to video coding technology. Specifically, it relates to intra-frame block copying (IBC), how and / or whether to combine IBC with geometric partitioning, and other coding tools in image / video coding. It can be applied to existing video coding standards such as HEVC or universal video codec (VVC). It can also be applied to future video coding standards or video codecs. 2. Introduction Video codec standards have evolved primarily through the development of the well-known ITU-T and ISO / IEC standards. ITU-T developed H.261 and H.263, ISO / IEC developed MPEG-1 and MPEG-4 Visual, and the two organizations jointly developed H.262 / MPEG-2 Video and H.264 / MPEG-4 Advanced Video Codec (AVC) and H.265 / HEVC standards. Since H.262, video codec standards have been based on a hybrid video codec structure, where temporal prediction plus transform codec is used. In order to explore future video codec technologies after HEVC, the Joint Video Exploration Team (JVET) was jointly established by VCEG and MPEG in 2015. Since then, JVET has adopted many new methods and put them into reference software called the Joint Exploration Model (JEM). In April 2018, the Joint Video Experts Group (JVET) between VCEG (Q6 / 16) and ISO / IEC JTC1SC29 / WG11 (MPEG) was created to work on the VVC standard, which aims to reduce bitrate by 50% compared to HEVC. 2.1. Encoding and decoding process of typical video codecs Figure 4 An example of an encoder block diagram for VVC is shown, which contains three in-loop filtering blocks: deblocking filter (DF), sample adaptive offset (SAO) and ALF. Unlike DF, which uses a predefined filter, SAO and ALF use the original samples of the current picture to reduce the mean square error between the original samples and the reconstructed samples by adding an offset and applying a finite impulse response (FIR) filter, respectively, where the offset and filter coefficients are signaled by the codec side information. ALF is located at the last processing stage of each picture and can be seen as a tool that attempts to capture and repair artifacts created by previous stages. 2.2. Intra-mode codec with 67 intra-prediction modes To capture arbitrary edge directions present in natural videos, as used in HEVC, the number of directional intra modes is extended from 33 to 65, as Figure 5 As shown, planar and DC modes remain unchanged. These more dense directional intra prediction modes apply to all block sizes and both luma and chroma intra prediction. In HEVC, each intra-coded block has a square shape, and the length of each side of the square is a power of 2. Therefore, no division operation is required to generate the intra predictor using DC mode. In VVC, blocks can have a rectangular shape, which in general requires the use of a division operation for each block. To avoid division operations for DC prediction, only the longer sides are used to calculate the average value for non-square blocks. 2.2.1 Wide-angle intra prediction Although 67 modes are defined in VVC, the exact prediction direction for a given intra prediction mode index also depends on the block shape. Conventional angular intra prediction directions are defined as 45 degrees to -135 degrees clockwise. In VVC, for non-square blocks, several conventional angular intra prediction modes are adaptively replaced with wide-angle intra prediction modes. The replaced mode is signaled using the original mode index, which is remapped to the index of the wide-angle mode after parsing. The total number of intra prediction modes remains unchanged, i.e. 67, and the intra mode encoding and decoding method remains unchanged. To support these prediction directions, a top reference of length 2W+1 and a left reference of length 2H+1 are provided as follows Figure 6 is defined as shown. The number of replacement modes in the wide direction mode depends on the aspect ratio of the block. The replaced intra prediction modes are shown in Table 2-1. Table 2-1 Intra-frame prediction modes replaced by wide-angle mode like Figure 7 As shown, in the case of wide-angle intra prediction, two vertically adjacent prediction samples can use two non-adjacent reference samples. Therefore, a low-pass reference sample filter and side smoothing are applied to wide-angle prediction to reduce the negative impact of the increased gap Δpα. If the wide-angle mode represents a non-fractional offset. There are 8 modes in the wide-angle mode that meet this condition, and these modes are [-14, -12, -10, -6, 72, 76, 78, 80]. When the 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 that need to be smoothed is reduced. In addition, it aligns the design of the non-fractional modes in the traditional prediction mode and the wide-angle mode. In VVC, 4:2:2 and 4:4:4 as well as 4:2:0 chroma formats are supported. The chroma derivation mode (DM) derivation table for the 4:2:2 chroma format was originally ported from HEVC, which expanded the number of entries from 35 to 67 to align with the expansion of intra prediction modes. Since the HEVC specification does not support prediction angles below -135 degrees and above 45 degrees, the luma intra prediction modes ranging from 2 to 5 are mapped to 2. Therefore, the chroma DM derivation table for the 4:2:2 chroma format is updated by replacing some values ​​of the entries of the mapping table to more accurately convert the prediction angles for the chroma blocks. 2.3. Inter-frame prediction For each inter-predicted CU, motion parameters consisting of motion vector, reference picture index and reference picture list usage index, as well as additional information required for the new codec features of VVC for sample generation for inter-prediction. Motion parameters can be signaled explicitly or implicitly. When a CU is coded and decoded using skip mode, the CU is associated with one PU and has no significant residual coefficients, no coded motion vector delta or reference picture index. Merge mode is specified, whereby the motion parameters for the current CU are obtained from neighboring CUs, which include spatial candidates and temporal candidates, as well as additional arrangements introduced in VVC. Merge mode can be applied to any inter-predicted CU, not just skip mode. An alternative to merge mode is explicit transmission of motion parameters, where motion vectors, corresponding reference picture indexes for each reference picture list and reference picture list usage flags, as well as other required information, are explicitly signaled for each CU. 2.4. Intra-block copy (IBC) Intra-block copying (IBC) is a tool adopted in the HEVC extension on SCC. It is well known that it significantly improves the coding efficiency of screen content materials. Since the IBC mode is implemented in a block-level coding mode, block matching (BM) is performed at the encoder to find the best block vector (or motion vector) for each CU. Here, the block vector is used to indicate the displacement from the current block to the reference block, where the reference block has been reconstructed in the current picture. The luminance block vector of the IBC-coded CU is integer precision. The chrominance block vector is also rounded to integer precision. When combined with AMVR, the IBC mode can switch between 1-pixel and 4-pixel motion vector precision. The IBC-coded CU is regarded as a third prediction mode in addition to the intra or inter prediction mode. The IBC mode is applicable to CUs with width and height less than or equal to 64 luminance samples. On the encoder side, hash-based motion estimation is performed for IBC. The encoder performs RD checks on blocks with a width or height no greater than 16 luma samples. For non-merge mode, block vector search is first performed using a hash-based search. If the hash search does not return a valid candidate, a block matching-based local search will be performed. In the hash-based search, the hash key match (32-bit CRC) between the current block and the reference block is extended to all allowed blocks. The hash key calculation for each position in the current picture is based on a 4×4 sub-block. For current blocks of larger sizes, when all hash keys of all 4×4 sub-blocks match the hash keys of the corresponding reference positions, the hash key is determined to match the hash key of the reference block. If the hash keys of multiple reference blocks are found to match the hash key of the current block, the block vector cost of each matching reference is calculated and the one with the smallest cost is selected. In the block matching search, the search range is set to cover the previous and current CTUs. At CU level, IBC mode is signaled using a flag, and it can be signaled as IBC mode or IBC skip / merge mode as follows: - IBC skip / merge mode: The merge candidate index is used to indicate which block vector from the list of neighboring candidate IBC codec blocks is used to predict the current block. The merge list consists of spatial candidates, HMVP candidates and pairwise candidates. - IBC AMVP mode: Block vector differences are encoded in the same way as motion vector differences. The block vector prediction method uses two candidates as predictors, one from the left neighbor and one from the upper neighbor (if IBC is encoded). When either neighbor is not available, the default block vector will be used as predictor. A flag is signaled to indicate the block vector predictor index. 2.5. Merge Mode with MVD (MMVD) In addition to the merge mode that uses implicitly derived motion information directly for prediction sample generation of the current CU, merge mode with motion vector difference (MMVD) is introduced in VVC. The MMVD flag is signaled immediately after the regular merge flag is sent to specify whether the MMVD mode is used for the CU. In MMVD, after a merge candidate is selected, it is further refined by MVD information that is signaled. Further information includes a merge candidate flag, an index specifying the magnitude of motion, and an index indicating the direction of motion. In MMVD mode, one of the first two candidates in the merge list is selected to be used as the MV basis. The MMVD candidate flag is signaled to specify which one to use between the first and second merge candidates. The distance index specifies the motion magnitude information and indicates a predefined offset from the starting point. Figure 8As shown, the offset is added to the horizontal component or the vertical component of the starting MV. The relationship between the distance index and the predefined offset is specified in Table 2-2. Table 2-2 Relationship between distance index and predefined offset The direction index indicates the direction of the MVD relative to the starting point. The direction index can indicate four directions, as shown in Table 2-3. Note that the meaning of the MVD symbol can change depending on the information of the starting MV. When the starting MV is a non-predicted MV or a bidirectionally predicted MV, where both lists point to the same side of the current picture (i.e., the POCs of both references are greater than the POC of the current picture, or are less than the POC of the current picture), the symbol in Table 2-3 specifies the sign of the MV offset added to the starting MV. When the starting MV is a bidirectionally predicted MV, where the two MVs point to different sides of the current picture (i.e., the POC of one reference is greater than the POC of the current picture, and the POC of the other reference is less than the POC of the current picture), and the difference in POC in List 0 is greater than the difference in POC in List 1, the symbol in Table 2-3 specifies the sign of the MV offset added to the MV component of the starting MV of List 0, and the sign for List 1 MV has an opposite value. Otherwise, if the difference in POC in List 1 is greater than List 0, then the sign in Table 2-3 specifies the sign of the MV offset added to the List 1 MV component of the starting MV, and the sign for List 0 MV has the opposite value. The MVD is scaled according to the difference in POC in each direction. If the POC difference in both lists is the same, no scaling is required. Otherwise, if the POC difference in list 0 is greater than the POC difference in list 1, the MVD for list 1 is scaled, defining the POC difference of L0 as td, and the POC difference of L1 as tb, as Fig.26 If the POC difference of L1 is greater than L0, the MVD for list 0 is scaled in the same way. If the starting MV is unidirectionally predicted, the MVD is added to the available MVs. Table 2-3 Signs of MV offsets specified by direction index Direction Index 00 01 10 11 x-axis + - N / A N / A y-axis N / A N / A + - 2.6. Symmetric MVD encoding and decoding In VVC, in addition to normal uni-prediction and bi-prediction mode MVD signaling, symmetric MVD mode for bi-prediction MVD signaling is applied. In symmetric MVD mode, the motion information including reference picture indexes of both list 0 and list 1 and MVD of list 1 is not signaled but derived. The decoding process of the symmetric MVD mode is as follows: 1. At the stripe level, derive the variables BiDirPredFlag, RefIdxSymL0, and RefIdxSymL1 as follows: – If mvd_l1_zero_flag is 1, then BiDirPredFlag is set equal to 0. Otherwise, if the nearest reference picture in list 0 and the nearest reference picture in list 1 form a preceding-following pair of reference pictures or a preceding-following pair of reference pictures, then BiDirPredFlag is set to 1, and both the list 0 reference picture and the list 1 reference picture are short-term reference pictures. Otherwise, BiDirPredFlag is set to 0. 2. At CU level, if the CU is bi-directionally predicted and BiDirPredFlag is equal to 1, the symmetric mode flag indicating whether the symmetric mode is used is explicitly signaled. When the symmetric mode flag is true, only mvp_l0_flag, mvp_l1_flag and MVD0 are explicitly signaled. The reference index for list0 and list1 are set equal to the reference picture pair, respectively. MVD1 is set equal to (-MVD0). The final motion vector is shown below. In the encoder, symmetric MVD motion estimation starts with initial MV evaluation. The initial MV candidate set includes MVs obtained from unidirectional prediction search, MVs obtained from bidirectional prediction search, and MVs from the AMVP list. The one with the lowest rate-distortion cost is selected as the initial MV for symmetric MVD motion search. 2.7. Bidirectional Optical Flow (BDOF) The Bidirectional Optical Flow (BDOF) tool is included in VVC. BDOF, formerly known as BIO, is included in JEM. Compared to the JEM version, BDOF in VVC is a simpler version that requires much less computation, especially in terms of the number of multiplications and the size of the multipliers. BDOF is used to refine the bidirectional prediction signal of a CU at the 4×4 sub-block level. BDOF is applied to a CU if all of the following conditions are met: – the CU is encoded using “true” bi-prediction mode, i.e., one of the two reference pictures precedes the current picture in display order, and the other of the two reference pictures follows the current picture in display order; – The distances from the two reference pictures to the current picture (i.e., POC differences) are the same; – Both reference images are short-term reference images; –CU is not encoded or decoded using affine mode or SbTMVP merge mode; – CU has more than 64 luma samples; – CU height and CU width are both greater than or equal to 8 luma samples; – BCW weight index indicates equal weight; – WP is not enabled for the current CU; –CIIP mode is not used for the current CU. BDOF is only applied to the luminance component. As the name suggests, BDOF mode is based on the concept of optical flow, which assumes that the motion of objects is smooth. For each 4x4 sub-block, motion refinement (v x ,v y ) is calculated by minimizing the difference between L0 prediction samples and L1 prediction samples. Then motion refinement is used to adjust the bi-prediction sample values ​​in the 4x4 sub-block. The following steps are applied in the BDOF process. First, by directly calculating the difference between two adjacent samples, the horizontal and vertical gradients of the two prediction signals, k=0,1,is calculated, that is, Among them, I (k) (i, j) is the sample value at the prediction signal coordinate (i, j) in list k, k=0,1, and shift1 is calculated based on the luma bit depth bitDepth as shift1=max(6, bitDepth-6). Then, the autocorrelations and cross-correlations of the gradients S1, S2, S3, S5 and S6 are calculated as follows in where Ω is a 6×6 window around a 4×4 sub-block, and n a and n b The values ​​are set to min(1, bitDepth-11) and min(4, bitDepth-8) respectively. Then the motion refinement (v x ,v y ) is derived using the cross-correlation and autocorrelation terms using the following method: in th′ BIO =2 max(5,BD-7) . is the floor function, and Based on the motion refinement and gradients, the following adjustments are calculated for each sample in the 4x4 sub-block: Finally, the BDOF samples of the CU are calculated by adjusting the bidirectional prediction samples as shown below: pred BDOF (x,y)=(I (0) (x,y)+I (1) (x,y)+b(x,y)+o offset )>>shift (2-7) These values ​​are chosen so that the multiplier in the BDOF process does not exceed 15 bits and the maximum bit width of the intermediate parameters in the BDOF process remains within 32 bits. In order to derive the gradient value, some prediction samples I in the list k (k = 0, 1) outside the current CU boundary are (k) (i,j) needs to be generated. Fig.10 As shown, BDOF in VVC uses an extended row / column around the boundary of the CU. In order to control the computational complexity of generating prediction samples outside the boundary, the prediction samples in the extended area (white positions) are generated by directly taking the reference samples at nearby integer positions (using floor() operation on the coordinates) without interpolation, and a conventional 8-tap motion compensated interpolation filter is used to generate prediction samples within the CU (gray positions). These extended sample values ​​are only used for gradient calculations. For the rest of the steps in the BDOF process, if any sample values ​​and gradient values ​​outside the CU boundary are needed, these sample values ​​and gradient values ​​are filled (i.e. repeated) from their nearest neighbors. When the width and / or height of a CU is greater than 16 luma samples, it will be split into sub-blocks with width and / or height equal to 16 luma samples, and the sub-block boundaries are regarded as CU boundaries in the BDOF process. The maximum unit size for the BDOF process is limited to 16x16. For each sub-block, the BDOF process can be skipped. When the SAD between the initial L0 prediction sample and the L1 prediction sample is less than a threshold, the BDOF process is not applied to the sub-block. The threshold is set equal to (8*W*(H>>1), where W represents the sub-block width and H represents the sub-block height. In order to avoid the additional complexity of SAD calculation, the SAD between the initial L0 prediction sample and the L1 prediction sample calculated in the DVMR process is reused here. If BCW is enabled for the current block, that is, the BCW weight index indicates unequal weights, bidirectional optical flow is disabled. Similarly, if WP is enabled for the current block, that is, luma_weight_lx_flag is 1 for either of the two reference pictures, BDOF is also disabled; BDOF is also disabled when the CU is encoded and decoded using symmetric MVD mode or CIIP mode. 2.8. Combined Inter and Intra Prediction (CIIP) In VVC, when a CU is encoded and decoded in merge mode, if the CU contains at least 64 luma samples (i.e., the CU width multiplied by the CU height is equal to or greater than 64), and if both the CU width and the CU height are less than 128 luma samples, an additional flag is signaled to indicate whether the combined inter / intra prediction (CIIP) mode is applied to the current CU. As the name implies, CIIP prediction combines inter prediction signals with intra prediction signals. The inter prediction signal P in CIIP mode inter is derived using the same inter prediction process applied to the normal merge mode; and the intra prediction signal P intra It is derived after the conventional intra prediction process with planar mode. Then, the intra and inter prediction signals are combined using weighted averaging, where the weight values ​​depend on the top and left neighboring blocks (in Fig.11 The codec mode of (depicted in) is calculated as follows: – If the top neighbor is available and intra-coded, set isIntraTop to 1, otherwise set isIntraTop to 0; – If the left neighbor is available and intra-coded, set isIntraLeft to 1, otherwise set isIntraft to 0; – If (isIntraLeft + isIntraTop) is equal to 2, set wt to 3; – Otherwise, if (isIntraLeft + isIntraTop) is equal to 1, set wt to 2; – Otherwise, set wt to 1. The CIIP forecast is formed as follows: P CIIP =((4-wt)*P inter +wt*P intra +2)>>2 (2-1) 2.9. Affine Motion Compensated Prediction In HEVC, only the translation motion model is applied for motion compensated prediction (MCP). In the real world, there are many kinds of motion, such as zooming in / out, rotation, perspective motion, and other irregular motions. In VVC, block-based affine transformation motion compensated prediction is applied. Fig.12 As shown, the affine motion field of a block is described by motion information of two control points (4 parameters) or three control point motion vectors (6 parameters). For the 4-parameter affine motion model, the motion vector at the sample position (x, y) in the block is derived as: For the 6-parameter affine motion model, the motion vector at a sample location (x, y) in a block is derived as: Where (mv 0x ,mv 0y ) is the motion vector of the upper left control point, (mv 1x ,mv 1y ) is the motion vector of the upper right control point, and (mv 2x ,mv 2y ) is the motion vector of the lower left control point. To simplify motion compensated prediction, block-based affine transform prediction is applied. To derive the motion vector for each 4×4 luminance subblock, Fig.13 As shown, the motion vector of the center sample of each subblock is calculated according to the above equation and rounded to 1 / 16 fractional precision. Then the motion compensated interpolation filter is applied to generate a prediction for each subblock with a derived motion vector. The subblock size of the chroma component is also set to 4×4. The MV of a 4×4 chroma subblock is calculated as the average of the MVs of the four corresponding 4×4 luminance subblocks. Like translational motion inter prediction, there are two affine motion inter prediction modes: affine merge mode and affine AMVP mode. 2.9.1. Affine Merge Prediction AF_MERGE mode can be applied to CUs with width and height greater than or equal to 8. In this mode, the CPMV of the current CU is generated based on the motion information of spatially neighboring CUs. There can be up to five CPMVP candidates, and the index is signaled to indicate the CPMVP used for the current CU. The following three types of CPVM candidates are used to form the affine merge candidate list: – Inherited affine merge candidates inferred from the CPMV of neighboring CUs; – The constructed affine merged candidate CPMVP derived using the translation MV of the neighboring CU; – Zero MV. In VVC, there are at most two inherited affine candidates, which are derived from the affine motion models of neighboring blocks, one from the left neighboring CU and one from the upper neighboring CU. Fig.14 As shown in . For the left predictor, the scanning order is A0->A1, and for the upper predictor, the scanning order is B0->B1->B2. Only the first inheritance candidate from each side is selected. No pruning check is performed between two inheritance candidates. When a neighboring affine CU is identified, its control point motion vector is used to derive the CPMVP candidate in the affine merge list of the current CU. As shown in the figure, if the neighboring lower left block A is encoded and decoded in affine mode, the motion vectors v2, v3 and v4 of the upper left, upper right and lower left corners of the CU containing block A are obtained. When block A is encoded and decoded with a 4-parameter affine model, the two CPMVs of the current CU are calculated based on v2, v3 and v4. When block A is encoded and decoded using a 6-parameter affine model, the three CPMVs of the current CU are calculated based on v2, v3 and v4. Constructing Affine Candidates A candidate is constructed by combining the neighboring translational motion information of each control point. The motion information for the control point is obtained from Fig.16 The specified spatial neighbors and the specified temporal neighbors are exported as shown. CPMV k (k=1, 2, 3, 4) indicates the kth control point. For CPMV1, check B2->B3->A2 blocks, and the MV of the first available block is used. For CPMV2, check B1->B0 blocks, and for CPMV3, check A1->A0 blocks. For TMVP, if available, use TMVP as CPMV4. After the MVs of the four control points are obtained, an affine merge candidate is constructed based on the motion information. The following combinations of control point MVs are used to construct in order: {CPMV1,CPMV2,CPMV3},{CPMV1,CPMV2,CPMV4},{CPMV1,CPMV3,CPMV4}, {CPMV2,CPMV3,CPMV4},{CPMV1,CPMV2},{CPMV1,CPMV3} The combination of 3 CPMVs constructs a 6-parameter affine merge candidate, and the combination of 2 CPMVs constructs a 4-parameter affine merge candidate. To avoid the motion scaling process, the relevant combination of control point MVs is discarded if the reference indexes of the control points are different. After the inherited affine merge candidates and the constructed affine merge candidates are checked, if the list is still not full, a zero MV is inserted at the end of the list. 2.9.2. Affine AMVP Prediction Affine AMVP mode can be applied to CUs with width and height both greater than or equal to 16. A CU-level affine flag is signaled in the bitstream to indicate whether the affine AMVP mode is used, and then another flag is signaled to indicate whether it is 4-parameter affine or 6-parameter affine. In this mode, the difference between the CPMVP of the current CU and their predictor CPMVP is signaled in the bitstream. The affine AVMP candidate list size is 2, which is generated in order using the following four types of CPVM candidates: – Inherited affine AMVP candidates inferred from the CPMV of neighboring CUs; – The constructed affine AMVP candidate CPMVP derived using the translation MV of the neighboring CU; – Translational MV from neighboring CU; – Zero MV. The order in which inherited affine AMVP candidates are checked is the same as that of inherited affine merge candidates. The only difference is that for AVMP candidates, only affine CUs with the same reference picture as in the current block are considered. No pruning process is applied when inserting the inherited affine motion predictor into the candidate list. The AMVP candidates constructed from Fig.16 The specified spatial neighbors shown are derived. The same check order as in the affine merge candidate construction is used. In addition, the reference picture index of the neighboring blocks is also checked. The first block in the check order is used, which is inter-coded and has the same reference picture as in the current CU. There is only one. When the current CU is coded using a 4-parameter affine mode and both mv0 and mv1 are available, they are added as a candidate in the affine AMVP list. When the current CU is coded using a 6-parameter affine mode and all three CPMVs are available, they are added as a candidate in the affine AMVP list. Otherwise, the constructed AMVP candidate will be set to unavailable. If the affine AMVP list candidate is still less than 2 after the inherited affine AMVP candidate and the constructed AMVP candidate are checked, mv0, mv1, and mv2 are added as translation MVs in sequence to predict all control point MVs of the current CU when available. Finally, if the affine AMVP list is still not full, the zero MV is used to fill the affine AMVP list. 2.9.3. Affine motion information storage In VVC, the CPMV of an affine CU is stored in a separate buffer. The stored CPMV is only used to generate the inherited CPMV in the affine merge mode and affine AMVP mode for the most recently coded CU. The sub-block MV derived from the CPMV is used for motion compensation, merging of translation MVs / MV derivation of AMVP lists, and deblocking. To avoid picture line buffering for additional CPMV, the affine motion data inheritance from the CU of the upper CTU is handled differently from the inheritance from the normal neighboring CU. If the candidate CU for affine motion data inheritance is in the upper CTU row, the lower left and lower right sub-block MVs in the line buffer are used for affine MVP derivation instead of CPMV. In this way, CPMV is only stored in the local buffer. If the candidate CU is 6-parameter affine coded, the affine model is downgraded to a 4-parameter model. Fig.17 As shown, along the top CTU boundary, the bottom left and bottom right sub-block motion vectors of the CU are used for affine inheritance of the CU in the bottom CTU. 2.9.4. Prediction refinement using optical flow for affine mode Compared with pixel-based motion compensation, sub-block-based affine motion compensation can save memory access bandwidth and reduce computational complexity, but at the expense of prediction accuracy. In order to achieve finer motion compensation granularity, prediction refinement using optical flow (PROF) is used to refine sub-block-based affine motion compensation predictions without increasing the memory access bandwidth of motion compensation. In VVC, after sub-block-based affine motion compensation is performed, the brightness prediction samples are refined by adding the differences derived from the optical flow equation. PROF is described as the following four steps: Step 1) Sub-block based affine motion compensation is performed to generate a sub-block prediction I(i,j). Step 2) Using a 3-tap filter [-1, 0, 1], the spatial gradient g of the sub-block prediction x (i,j) and g y (i,j) is calculated at each sample position. The gradient calculation is exactly the same as the gradient calculation in BDOF. g x (i,j)=(I(i+1,j)>>shift1)-(I(i-1,j)>>shift1) (2-11) g y (i,j)=(I(i,j+1)>>shift1)-(I(i,j-1)>>shift1) (2-12) shift1 is used to control the precision of the gradient. The sub-block (i.e. 4x4) prediction is extended by one sample on each side of the gradient calculation. To avoid extra memory bandwidth and extra interpolation calculations, these extended samples on the extended boundary are copied from the nearest integer pixel position in the reference picture. Step 3) The brightness prediction refinement of the optical flow equation is calculated as follows. ΔI(i,j)=g x (i,j)*Δv x (i,j)+g y (i,j)*Δv y(i,j) (2-13) where Δv(i,j) is the difference between the sample MV calculated for the sample position (i,j), denoted as v(i,j), and the sub-block MV of the sub-block to which the sample (i,j) belongs, as Fig.18 As shown. Δv(i,j) is quantized in units of 1 / 32 luma sample precision. Since the affine model parameters and the sample positions relative to the sub-block center do not change from sub-block to sub-block, Δv(i,j) can be calculated for the first sub-block and reused for other sub-blocks in the same CU. Let dx(i,j) and dy(i,j) be the distance from the sample position (i,j) to the sub-block center (x SB ,y SB )’s horizontal and vertical offsets, Δv(x,y) can be derived from the following equations: To maintain accuracy, the sub-block (x SB ,y SB ) is calculated as ((W SB -1) / 2,(H SB -1) / 2), where W SB and H SB are the width and height of the sub-block respectively. For the 4-parameter affine model, For the 6-parameter affine model, Where (v 0x ,v 0y ), (v 1x ,v 1y ), (v 2x ,v 2y ) are the control point motion vectors of the upper left, upper right and lower left, and w and h are the width and height of the CU. Step 4) Finally, the luma prediction refinement ΔI(i,j) is added to the sub-block prediction I(i,j) and the final prediction I' is generated as follows. I'(i,j)=I(i,j)+ΔI(i,j) (2-18) PROF is not applicable to affine codec CUs in two cases: 1) all control point MVs are the same, which indicates that the CU has only translational motion; 2) the affine motion parameters are larger than the specified limit, because the sub-block based affine MC is downgraded to CU based MC to avoid large memory access bandwidth requirements. A fast codec method is applied to reduce the codec complexity of affine motion estimation using PROF. PROF is not applied to the affine motion estimation stage in the following two cases: a) If the CU is not a root block and the parent block of the CU does not select the affine mode as its best mode, PROF is not applied because the possibility that the current CU selects the affine mode as the best mode is low; b) If the magnitudes of the four affine parameters (C, D, E, F) are all less than a predefined threshold and the current picture is not a low-latency picture, PROF is not applied. In this way, affine motion estimation using PROF can be accelerated. 2.10. Sub-block based temporal motion vector prediction (SbTMVP) VVC supports a sub-block-based temporal motion vector prediction (SbTMVP) method. Similar to the temporal motion vector prediction (TMVP) in HEVC, SbTMVP uses the motion field in the co-located picture to improve the motion vector prediction and merge mode for the CU in the current picture. The same co-located pictures used by TMVP are also used for SbTVMP. SbTMVP differs from TMVP in the following two main aspects: –TMVP predicts motion at CU level, but SbTMVP predicts motion at sub-CU level; –TMVP obtains the temporal motion vector from the co-located block in the co-located picture (the co-located block is the bottom-right or center block relative to the current CU), while SbTMVP applies motion shifting before obtaining the temporal motion information from the co-located picture, where the motion shifting is obtained from the motion vector of one of the spatial neighboring blocks from the current CU. SbTVMP process Fig.19A and Fig.19B As shown in . SbTMVP predicts the motion vector of the sub-CU in the current CU in two steps. In the first step, Fig.19A The spatial neighbors A1 in are checked. If A1 has a motion vector that uses the co-located picture as its reference picture, then that motion vector is selected as the motion shift to be applied. If no such motion is identified, the motion offset is set to (0,0). In the second step, the motion shift identified in step 1 is applied (i.e., added to the coordinates of the current block) to obtain the sub-CU level motion information (motion vector and reference index) with the same picture, as Fig.19B shown. Fig.19BThe example in assumes that the motion shift is set to the motion of block A1. Then, for each sub-CU, the motion information of the corresponding block in the co-located picture (the minimum motion grid covering the center sample) is used to derive the motion information for the sub-CU. After the motion information of the co-located sub-CU is identified, it is converted into a motion vector and reference index of the current sub-CU in a manner similar to the TMVP process of HEVC, where temporal motion scaling is applied to align the reference picture of the temporal motion vector with the reference picture of the current CU. In VVC, a sub-block based merge list containing a combination of both SbTVMP candidates and affine merge candidates is used for signaling of sub-block based merge mode. SbTVMP mode is enabled / disabled by a sequence parameter set (SPS) flag. If SbTMVP mode is enabled, the SbTMVP predictor is added as the first entry in the list of sub-block based merge candidates, followed by the affine merge candidate. The size of the sub-block based merge list is signaled in the SPS, and the maximum allowed size of the sub-block based merge list is 5 in VVC. The sub-CU size used in SbTMVP is fixed to 8x8. Like the affine merge mode, the SbTMVP mode is only applicable to CUs whose width and height are greater than or equal to 8. The encoding logic of the additional SbTMVP merge candidate is the same as that for other merge candidates, ie, for each CU in a P slice or a B slice, an additional RD check is performed to decide whether to use the SbTMVP candidate. 2.11. Adaptive Motion Vector Resolution (AMVR) In HEVC, when use_integer_mv_flag in the slice header is equal to 0, the motion vector difference (MVD) (between the motion vector of the CU and the predicted motion vector) is signaled in units of quarter luma samples. In VVC, a CU-level adaptive motion vector resolution (AMVR) scheme is introduced. AMVR allows the MVD of a CU to be encoded and decoded with different precisions. Depending on the mode for the current CU (normal AMVP mode or affine AVMP mode), the MVD of the current CU can be adaptively selected as follows: – Normal AMVP mode: quarter brightness samples, half brightness samples, integer brightness samples, or quad brightness samples. – Affine AMVP mode: quarter luma samples, integer luma samples, or 1 / 16 luma samples. The CU level MVD resolution indication is conditionally signaled if the current CU has at least one non-zero MVD component.If all MVD components (ie, both horizontal and vertical MVD for reference list L0 and reference list L1) are zero, quarter luma sample MVD resolution is inferred. For a CU with at least one non-zero MVD component, a first flag is signaled to indicate whether quarter luma sample MVD precision is used for the CU. If the first flag is 0, no further signaling is required, and quarter luma sample MVD precision is used for the current CU. Otherwise, a second flag is signaled to indicate that half luma samples or other MVD precision (integer or four luma samples) are used for normal AMVP CUs. In the case of half luma samples, a 6-tap interpolation filter is used for half luma sample positions instead of the default 8-tap interpolation filter. Otherwise, a third flag is signaled to indicate whether integer luma sample MVD precision or four luma sample MVD precision is used for normal AMVP CUs. In the case of affine AMVP CUs, a second flag is used to indicate whether integer luma sample MVD precision or 1 / 16 luma sample MVD precision is used. To ensure that the reconstructed MV has the expected precision (quarter luma sample, half luma sample, integer luma sample, or four luma samples), the motion vector predictor for the CU will be rounded to the same precision, the same as the precision of the MVD before the MVD is added. The motion vector predictor is rounded towards zero (ie, a negative motion vector predictor is rounded towards positive infinity, and a positive motion vector predictor is rounded towards negative infinity). The encoder uses the RD check to determine the motion vector resolution for the current CU. In order to avoid always performing four CU-level RD checks for each MVD resolution, in VTM11, only the RD check of MVD precision other than quarter luma samples is conditionally called. For normal AVMP mode, the RD cost of quarter luma sample MVD precision and integer luma sample MV precision is first calculated. Then, the RD cost of integer luma sample MVD precision is compared with the RD cost of quarter luma sample MVD precision to determine whether further checking of the RD cost of four luma sample MVD precision is required. When the RD cost for quarter luma sample MVD precision is much smaller than the integer luma sample MVD precision, the RD check of four luma sample MVD precision is skipped. Then, if the RD cost of integer luma sample MVD precision is significantly greater than the best RD cost of the previously tested MVD precision, the check of half luma sample MVD precision is skipped. For the affine AMVP mode, if the affine inter mode is not selected after checking the rate-distortion cost of the affine merge / skip mode, merge / skip mode, quarter luma sample MVD accuracy normal AMVP mode, and quarter luma sample MVD accuracy affine AMVP mode, the 1 / 16 luma sample MV accuracy and 1 pixel MV accuracy affine inter modes are not checked. In addition, the affine parameters obtained in the quarter luma sample MV accuracy affine inter mode are used as the starting search points for the 1 / 16 luma sample and quarter luma sample MV accuracy affine inter modes. 2.12. Bidirectional Prediction with CU-Level Weights (BCW) In HEVC, a bidirectional prediction signal is generated by averaging two prediction signals obtained from two different reference pictures and / or using two different motion vectors. In VVC, the bidirectional prediction mode is extended beyond simple averaging to allow weighted averaging of the two prediction signals. P bi-pred =((8-w)*P0+w*P1+4)>>3 (2-19) Five weights are allowed in weighted average bidirectional prediction, w∈{-2,3,4,5,10}. For each bidirectional prediction CU, the weight w is determined in one of two ways: 1) For non-merged CUs, the weight index is signaled after the motion vector difference; 2) For merged CUs, the weight index is inferred from neighboring blocks based on the merge candidate index. BCW is only applied to CUs with 256 or more luma samples (i.e., the CU width multiplied by the CU height is greater than or equal to 256). For low-latency pictures, all 5 weights will be used. For non-low-latency pictures, only 3 weights (w∈{3,4,5}) are used. – At the encoder, fast search algorithms are applied to find the weight index without significantly increasing the encoder complexity. These algorithms are summarized below. The VTM software and document JVET-L0646 can be referenced for further details. When combined with AMVR, unequal weights for 1-pixel and 4-pixel motion vector precision are only conditionally checked if the current picture is a low-latency picture. - When combined with affine, affine ME will be performed for unequal weights if and only if the affine mode is selected as the current best mode. – When the two reference pictures in bidirectional prediction are the same, unequal weights are only checked conditionally. – Unequal weights are not searched when certain conditions are met, which depend on the POC distance between the current picture and its reference pictures, the codec QP, and the temporal layer. The BCW weight index is encoded using a binary bit of context encoding followed by a binary bit of bypass encoding. The first binary bit of context encoding indicates whether equal weights are used; and if unequal weights are used, an additional binary bit is signaled using bypass encoding to indicate which unequal weights are used. Weighted prediction (WP) is a codec tool supported by the H.264 / AVC and HEVC standards for efficient encoding and decoding of video content in fading conditions. Support for WP has also been added to the VVC standard. WP allows weighting parameters (weights and offsets) to be signaled for each reference picture list L0 and each reference picture in list L1. Then, during motion compensation, the weights and offsets of the corresponding reference pictures are applied. WP and BCW are designed for different types of video content. In order to avoid interaction between WP and BCW (which will complicate the VVC decoder design), if the CU uses WP, the BCW weight index is not signaled, and w is inferred to be 4 (ie, equal weights are applied). For the merged CU, the weight index is inferred from the neighboring blocks based on the merge candidate index. This can be applied to the normal merge mode and the inherited affine merge mode. For the constructed affine merge mode, affine motion information is constructed based on the motion information of up to 3 blocks. The BCW index of the CU using the constructed affine merge mode is simply set equal to the BCW index of the first control point MV. In VVC, CIIP and BCW cannot be applied jointly to a CU. When a CU is encoded and decoded using CIIP mode, the BCW index of the current CU is set to 2, for example, equal weight. 2.13. Local Illumination Compensation (LIC) Local illumination compensation (LIC) is a codec tool that addresses the problem of local brightness variations between a current picture and its temporal reference picture. LIC is based on a linear model where a scaling factor and an offset are applied to a reference sample to obtain a predicted sample for the current block. Specifically, LIC can be mathematically modeled by the following equation: P(x,y)=α·P r (x+v x ,y+v y )+β Among them, P(x,y) is the prediction signal of the current block at the coordinate (x,y); P r (x+v x ,y+v y ) is the motion vector (v x ,v y ) points to the reference block; and α and β are the corresponding scaling factors and offsets applied to the reference block. Fig. 20 The LIC process is shown. Fig. 20 In , when applying LIC to a block, the minimum mean square error (LMSE) method is used to minimize the neighboring samples of the current block (i.e. Fig. 20 The template T in the temporal reference picture) and its corresponding reference sample in the temporal reference picture (i.e., Fig. 20In addition, in order to reduce the computational complexity, both the template samples and the reference template samples are subsampled (adaptive subsampling) to derive the LIC parameters, i.e., only Fig. 20 The shadow samples in are used to derive α and β. In order to improve the encoding and decoding performance, the short side is not subsampled, such as Fig.21 shown. 2.14. Decoder-side Motion Vector Refinement (DMVR) To improve the accuracy of the merge mode MV, decoder-side motion vector refinement based on bilateral matching (BM) is applied in VVC. In the bidirectional prediction operation, the refined MV is searched around the initial MV in the reference picture list L0 and the reference picture list L1. The BM method calculates the distortion between two candidate blocks in the reference picture list L0 and the list L1. Fig. 22 As shown, based on each MV candidate (eg, MV0' and MV1') around the initial MV, the SAD between block 2110 and block 2112 is calculated. The MV candidate with the lowest SAD becomes the refined MV and is used to generate a bidirectional prediction signal. In VVC, the application of DMVR is restricted and only applies to CUs coded in the following modes and features: – CU-level merge mode with bi-predictive MV; – Relative to the current picture, one reference picture is in the past and the other reference picture is in the future; – The distances from the two reference pictures to the current picture (i.e., POC differences) are the same; – Both reference images are short-term reference images; – CU has more than 64 luma samples; – CU height and CU width are both greater than or equal to 8 luma samples; – BCW weight index indicates equal weight; – The current block is not WP enabled; –CIIP mode is not used for the current block. The refined MV derived by the DMVR process is used to generate inter-frame prediction samples and is also used for temporal motion vector prediction of future picture encoding and decoding. The original MV is used in the deblocking process and is also used for spatial motion vector prediction of future CU encoding and decoding. Additional features of DMVR are mentioned in the following sub-clauses. 2.14.1. Search solution In DVMR, the search point is around the initial MV, and the MV offset obeys the MV difference mirror rule. In other words, any point examined by DMVR represented by the candidate MV pair (MV0, MV1) follows the following two equations: MV0′=MV0+MV_offset (2-20) MV1′=MV1-MV_offset (2-21) Wherein, MV_offset represents the refinement offset between the initial MV and the refinement MV in one of the reference pictures. The refinement search range is two integer luma samples starting from the initial MV. The search includes an integer sample offset search phase and a fractional sample refinement phase. The integer sample offset search uses a 25-point full search. First, the SAD of the initial MV pair is calculated. If the SAD of the initial MV pair is less than the threshold, the integer sampling stage of DMVR is terminated. Otherwise, the SAD of the remaining 24 points is calculated and checked in raster scan order. The point with the smallest SAD is selected as the output of the integer sample offset search stage. In order to reduce the impact of DMVR refinement uncertainty, it is proposed to support the original MV in the DMVR process. The SAD between the reference blocks referenced by the initial MV candidates is reduced by 1 / 4 of the SAD value. The integer sample search is followed by fractional sample refinement. To save computational complexity, fractional sample refinement is derived using the parametric error surface equations instead of doing an additional search using SAD comparisons. Fractional sample refinement is conditionally called based on the output of the integer sample search stage. When the integer sample search stage ends with a center with minimum SAD in either the first or second iteration search, fractional sample refinement is further applied. In the sub-pixel offset estimation based on the parametric error surface, the cost at the center position and the costs at the four neighboring positions from the center are used to fit a two-dimensional parabolic error surface equation of the following form: E(x,y)=A(x min ) 2 +B(yy min ) 2 +C (2-22) Where (x min ,y min ) corresponds to the fractional position with the minimum cost, and C corresponds to the minimum cost value. By solving the above equation using the cost values ​​of the five search points, (x min ,y min ) is calculated as: x min =(E(-1,0)-E(1,0)) / (2(E(-1,0)+E(1,0)-2E(0,0))) (2-23) y min=(E(0,-1)-E(0,1)) / (2((E(0,-1)+E(0,1)-2E(0,0))) (2-24) x min and min The value of is automatically clamped between -8 and 8, since all cost values ​​are positive, with a minimum value of E(0,0). This corresponds to a half-pixel offset with 1 / 16-pixel MV precision in VVC. The calculated fraction (x min ,y min ) is added to the integer distance refinement MV to obtain a sub-pixel accurate refinement delta MV. 2.14.2. Bilinear interpolation and sample padding In VVC, the resolution of MV is 1 / 16 luma sample. Samples at fractional positions are interpolated using an 8-tap interpolation filter. In DMVR, the search points are around the initial fractional pixel MV with integer sample offsets, so the samples at these fractional positions need to be interpolated for the DMVR search process. In order to reduce the computational complexity, a bilinear interpolation filter is used to generate fractional samples for the search process in DMVR. Another important effect is that by using a bilinear filter, DVMR does not access more reference samples than the normal motion compensation process within the 2-sample search range. After the refined MV is obtained through the DMVR search process, an ordinary 8-tap interpolation filter is applied to generate the final prediction. In order not to access more reference samples for the normal MC process, samples will be filled from those available samples, which are not needed for the interpolation process based on the original MV, but are needed for the interpolation process based on the refined MV. 2.14.3. Maximum DMVR processing unit When the width and / or height of a CU is greater than 16 luma samples, it will be further split into sub-blocks with width and / or height equal to 16 luma samples. The maximum unit size for the DMVR search process is limited to 16x16. 2.15. Multi-pass decoder-side motion vector refinement In this contribution, multi-pass decoder side motion vector refinement is applied instead of DMVR. In the first pass, bilateral matching (BM) is applied to the codec block. In the second pass, BM is applied to each 16x16 sub-block within the codec block. In the third pass, the MV in each 8x8 sub-block is refined by applying bidirectional optical flow (BDOF). The refined MVs are stored for both spatial and temporal motion vector prediction. 2.15.1. First pass - block-based bilateral matching MV refinement In the first pass, refined MVs are derived by applying BM to the codec blocks. Similar to decoder-side motion vector refinement (DMVR), refined MVs are searched around two initial MVs (MV0 and MV1) in reference picture lists L0 and L1. Refined MVs (MV0_pass1 and MV1_pass1) are derived around the initiating MVs based on the minimum bilateral matching cost between the two reference blocks in L0 and L1. BM performs a local search to derive integer sample precision intDeltaMV and half-pixel sample precision halfDeltaMV. The local search applies a 3×3 square search pattern, looping in the horizontal search range [–sHor, sHor] and the vertical search range [–sVer, sVer], where the values ​​of sHor and sVer are determined by the block size and the maximum values ​​of sHor and sVer are 8. The bilateral matching cost is calculated as: bilCost = mvDistanceCost + sadCost. When the block size cbW*cbH is greater than 64, the MRSAD cost function is applied to remove the DC effect of the distortion between the reference blocks. When the bilCost of the center point of the 3×3 search pattern has the minimum cost, the intDeltaMV or halfDeltaMV local search terminates. Otherwise, the current minimum cost search point becomes the new center point of the 3×3 search pattern and continues to search for the minimum cost until it reaches the end of the search range. The existing fractional sample refinement is further applied to derive the final deltaMV. Then the refined MV after the first pass is derived as: MV0_pass1 = MV0 + deltaMV MV1_pass1 = MV1-deltaMV 2.15.2. Second pass – Sub-block based bilateral matching MV refinement In the second pass, refined MVs are derived by applying BM to 16×16 grid sub-blocks. For each sub-block, the refined MVs are searched around the two MVs (MV0_pass1 and MV1_pass1) obtained in the first pass in the reference picture lists L0 and L1. The refined MVs (MV0_pass2(sbIdx2) and MV1_pass2(sbIdx2)) are derived based on the minimum bilateral matching cost between the two reference sub-blocks in L0 and L1. For each subblock, BM performs a full search to derive integer sample precision intDeltaMV. The full search has a search range of [–sHor, sHor] in the horizontal direction and a search range of [–sVer, sVer] in the vertical direction, where the values ​​of sHor and sVer are determined by the block size and the maximum values ​​of sHor and sVert are 8. The bilateral matching cost is calculated by applying the cost factor to the SATD cost between two reference sub-blocks, such as: bilCost = satdCost * costFactor. The search area (2*sHor+1)*(2*sVer+1) is divided into 5 diamond search areas, such as Fig.23 As shown. Each search area is assigned a costFactor determined by the distance (intDeltaMV) between each search point and the starting MV, and each diamond area is processed in order starting from the center of the search area. In each area, the search points are processed in raster scan order, starting from the upper left corner of the area and going to the lower right corner. When the minimum bilCost in the current search area is less than or equal to the threshold of sbW*sbH, the integer pixel (int-pel) full search is terminated, otherwise, the int-pel full search continues to the next search area until all search points are checked. BM performs a local search to derive the half-sample accuracy halfDeltaMv. The search pattern and cost function are the same as defined in 2.9.1. The existing VVC DMVR fractional sample refinement is further applied to derive the final deltaMV (sbIdx2). Then, the refined MV of the second pass is derived as: ·MV0_pass2(sbIdx2)=MV0_pass1+deltaMV(sbIdx2) ·MV1_pass2(sbIdx2)=MV1_pass1-deltaMV(sbIdx2) 2.15.3. Third pass - sub-block-based bidirectional optical flow MV refinement In the third pass, refined MVs are derived by applying BDOF to 8×8 grid sub-blocks. For each 8×8 sub-block, BDOF refinement is applied to derive scaled Vx and Vy without clipping from the refined MV of the parent sub-block of the second pass. The derived bioMv(Vx, Vy) is rounded to 1 / 16 sample precision and clipped between -32 and 32. The refined MVs of the third pass (MV0_pass3(sbIdx3) and MV1_pass3(sbIdx3)) are derived as: ·MV0_pass3(sbIdx3)=MV0_pass2(sbIdx2)+bioMv ·MV1_pass3(sbIdx3)=MV0_pass2(sbIdx2)-bioMv 2.16. Sample-based BDOF In sample-based BDOF, motion refinement (Vx, Vy) is not derived on a block basis, it is performed on a per-sample basis. The codec block is divided into 8×8 sub-blocks. For each sub-block, whether to apply BDOF is determined by checking the SAD between the two reference sub-blocks against a threshold. If it is decided to apply BDOF to a sub-block, for each sample in the sub-block, Vx and Vy are derived using a sliding 5×5 window and applying the existing BDOF process for each sliding window. The derived motion refinement (Vx, Vy) is applied to adjust the bi-predicted sample value of the window center sample. 2.17. Extended Merge Prediction In VVC, the merge candidate list is constructed by including the following five types of candidates in order: (1) Spatial MVP from spatially adjacent CUs (2) Time MVP from the same CU (3) History-based MVP from FIFO table (4) Paired Average MVP (5) Zero MV. The size of the merge list is signaled in the sequence parameter set header, and the maximum allowed size of the merge list is 6. For each CU code in merge mode, the index of the best merge candidate is encoded and decoded using truncated unary binarization (TU). The first bin of the merge index is encoded and decoded using context, while bypass encoding and decoding is used for other bins. The derivation process of merge candidates for each category is provided in this section. As in HEVC, VVC also supports parallel derivation of merge candidate lists for all CUs within a certain size region. 2.17.1. Spatial candidate export The derivation of spatial merge candidates in VVC is the same as that in HEVC, except that the positions of the first two merge candidates are swapped. Among the candidates located at the positions shown, at most four merge candidates are selected. The derivation order is B0, A0, B1, A1 and B2. Position B2 is only considered when one or more CUs at positions B0, A0, B1 and A1 are not available (for example, because it belongs to another slice or tile) or is intra-coded. After the candidate at position A1 is added, a redundancy check is performed on the addition of the remaining candidates, which ensures that candidates with the same motion information are excluded from the list, thereby improving the coding efficiency. In order to reduce computational complexity, not all possible candidate pairs are considered in the mentioned redundancy check. Instead, only the Fig.25 The pairs linked with arrows in , and candidates are added to the list only if the corresponding candidates for redundancy check do not have the same motion information. 2.17.2. Time candidate export In this step, only one candidate is added to the list. In particular, in the derivation of this temporal merge candidate, the scaled motion vector is derived based on the co-located CU belonging to the co-located reference picture. The reference picture list to be used for deriving the co-located CU is explicitly signaled in the slice header. Fig.26 As shown by the dashed line in , the scaled motion vector for the temporal merge candidate is obtained, which is scaled from the motion vector of the co-located CU using the POC distances, tb and td, where tb is defined as the POC difference between the reference picture of the current picture and the current picture, and td is defined as the POC difference between the reference picture of the co-located picture and the co-located picture. The reference picture index of the temporal merge candidate is set equal to zero. like Fig. 27 As shown, the position of the temporal candidate is selected between candidates C0 and C1. If the CU at position C0 is not available and is intra-coded, or the CU at position C0 is outside the current row of the CTU, position C1 is used. Otherwise, position C0 is used in the derivation of the temporal merge candidate. 2.17.3. History-based Merge Candidate Export History-based MVP (HMVP) merge candidates are added to the merge list after spatial MVP and TMVP. In this method, the motion information of the previous codec block is stored in a table and used as the MVP of the current CU. A table with multiple HMVP candidates is maintained during the encoding / decoding process. The table is reset (cleared) when a new CTU row is encountered. Whenever there is a non-sub-block inter-coded CU, the associated motion information is added as a new HMVP candidate to the last entry of the table. The HMVP table size S is set to 6, which indicates that up to 6 history-based MVP (HMVP) candidates can be added to the table. When a new motion candidate is inserted into the table, a constrained first-in-first-out (FIFO) rule is used, where a redundancy check is first applied to find if there is an identical HMVP in the table. If found, the identical HMVP is removed from the table, and then all HMVP candidates are moved forward. HMVP candidates can be used in the merge candidate list construction process. The nearest HMVP candidates in the table are checked in order and inserted into the candidate list after the TMVP candidate. Redundancy check is applied to HMVP candidates to spatial or temporal merge candidates. To reduce the number of redundant checking operations, the following simplifications are introduced: The number of HMPV candidates for merge list generation is set to (N<=4)?M:(8-N), where N indicates the number of existing candidates in the merge list and M indicates the number of available HMVP candidates in the table. Once the total number of available merge candidates reaches the maximum allowed merge candidates minus 1, the merge candidate list construction process from HMVP is terminated. 2.17.4. Pairwise Average Merge Candidate Derivation The pairwise average candidate is generated by averaging the predefined candidate pairs in the existing merge candidate list, and the predefined pairs are defined as {(0, 1), (0, 2), (1, 2), (0, 3), (1, 3), (2, 3)}, where the number represents the merge index of the merge candidate list. The average motion vector is calculated separately for each reference list. If two motion vectors are available in one list, they are averaged even if they point to different reference pictures; if only one motion vector is available, it is used directly; if no motion vector is available, this list is kept invalid. When the merge list is not full after adding pairwise average merge candidates, zero MVPs will be inserted at the end until the maximum number of merge candidates is encountered. 2.17.5 Merging Estimated Regions The merge estimation region (MER) allows the merge candidate list to be derived independently for a CU in the same merge estimation region (MER). For generating the merge candidate list for the current CU, candidate blocks in the same MER as the current CU are not included. In addition, the update process for the history-based motion vector predictor candidate list is updated only when (xCb+cbWidth)>>Log2ParMrgLevel is greater than xCb>>Log2ParMrgLevel and (yCb+cbHeight)>>Log2parMrglevel is greater than (yCb>>Log2ParMrgLevel), and where (xCb, yCb) is the top left luma sample position of the current CU in the picture and (cbWidth, cbHeight) is the CU size. The MER size is selected at the encoder side and signaled in the sequence parameter set as log2_parallel_merge_level_minus2. 2.18. New Merge Candidates 2.18.1. Non-adjacent merge candidate export In VVC, use Fig.28 The five spatial neighboring blocks and one temporal neighboring block shown derive merge candidates. It is proposed to derive additional merge candidates from non-adjacent locations of the current block using the same pattern as VVC. To this end, for each round of search i, a virtual block is generated based on the current block as follows: First, the relative position of the virtual block to the current block is calculated as follows: Offsetx=-i×gridX, Offsety=-i×gridY Where Offsetx and Offsety represent the offset of the upper left corner of the virtual block relative to the upper left corner of the current block, and gridX and gridY are the width and height of the search grid. Second, the width and height of the virtual block are calculated as follows: newWidth=i×2×gridX+currWidth newHeight=i×2×gridY+currHeight. Where currWidth and currHeight are the width and height of the current block. newWidth and newHeight are the width and height of the new virtual block. gridX and gridY are currently set to currWidth and currHeight respectively. Fig.29 The relationship between the virtual block and the current block is shown. After generating the virtual block, block A i,Bi,C i , D i and E i can be considered as VVC spatial neighbors of the virtual block, and their positions are obtained in the same mode as VVC. Obviously, if the i-th search is 0, the virtual block is the current block. In this case, block A i ,Bi,C i , D i and E i It is the spatial neighboring block used in VVC merge mode. When constructing the merge candidate list, pruning is performed to ensure the uniqueness of each element in the merge candidate list. The maximum search round is set to 1, which means that five non-adjacent spatial neighboring blocks are utilized. After temporal merging candidates, non-adjacent spatial merging candidates are inserted into the merging list in the order of B1->A1->C1->D1->E1. 2.18.2STMVP It is proposed to use three spatial merging candidates and one temporal merging candidate to derive an average candidate as the STMVP candidate. The STMVP is inserted before the top left spatial merge candidate. The STMVP candidate is pruned along with all previous merge candidates in the merge list. For spatial candidates, the first three candidates in the current merge candidate list are used. For temporal candidates, the same positions as the VTM / HEVC co-location positions are used. For spatial candidates, the first, second, and third candidates inserted into the current merge candidate list before STMVP are denoted as F, S, and T. The temporal candidate having the same position as the VTM / HEVC co-location used in TMVP is denoted Col. The motion vector of the STMVP candidate in prediction direction X (denoted as mvLX) is derived as follows: 1) If the reference indices of the four merge candidates are all valid and equal to zero in the prediction direction X (X = 0 or 1), then mvLX=(mvLX_F+mvLX_S+mvLX_T+mvLX_Col)>>2 2) If the reference indexes of three of the four merge candidates are valid and equal to zero in the prediction direction X (X=0 or 1), then mvLX=(mvLX_F×3+mvLX_S×3+mvLX_Col×2)>>3 or mvLX=(mvLX_F×3+mvLX_T×3+mvLX_Col×2)>>3 or mvLX=(mvLX_S×3+mvLX_T×3+mvLX_Col×2)>>3 3) If the reference indexes of two of the four merge candidates are valid and equal to zero in the prediction direction X (X=0 or 1), then mvLX=(mvLX_F+mvLX_Col)>>1 or mvLX=(mvLX_S+mvLX_Col)>>1 or mvLX=(mvLX_T+mvLX_Col)>>1 NOTE: If time candidate is not available, STMVP mode is turned off. 2.18.3. Merge list size If both non-adjacent merge candidates and STMVP merge candidates are considered simultaneously, the size of the merge list is signaled in a set of sequence parameter headers, and the maximum allowed size of the merge list is 8. 2.19. Geometric Partitioning Model (GPM) In VVC, geometric partitioning mode is supported for inter prediction. Use CU level flag as a merge mode to signal geometric partitioning mode. Other merge modes include normal merge mode, MMVD mode, CIIP mode and sub-block merge mode. For each possible CU size w×h=2 m ×2 n , where m,n∈{3…6} and excluding 8x64 and 64x8, the geometric partitioning mode supports a total of 64 partitions. When this mode is used, the CU is split into two parts by a geometrically positioned straight line ( Fig.30 ). The position of the partition line is mathematically derived from the angle and offset parameters of the specific partition. Each part of the geometric partition in the CU uses its own motion for inter-frame prediction; each partition only allows unidirectional prediction, that is, each part has a motion vector and a reference index. Unidirectional prediction motion constraints are applied to ensure that, as with traditional bidirectional prediction, only two motion compensated predictions are required for each CU. The unidirectional prediction motion for each partition is derived using the process described in 2.20.1. If a geometric partitioning mode is used for the current CU, a geometric partitioning index indicating the partitioning mode (angle and offset) of the geometric partitioning and two merge indices (one for each partition) are further signaled. The number of maximum GPM candidate sizes is explicitly signaled in the SPS, and the syntax binarization for the GPM merge indices is specified. After predicting each part of the geometric partitioning, a hybrid process with adaptive weights is used as in 2.20.2. to adjust the sample values ​​along the edges of the geometric partitioning. This is the prediction signal for the entire CU, and the transform and quantization processes will be applied to the entire CU as in other prediction modes. Finally, the motion field of the CU predicted using the geometric partitioning mode is stored as in 2.20.3. 2.19.1. One-way prediction candidate list construction The unidirectional prediction candidate list is derived directly from the merge candidate list constructed according to the extended merge prediction process in 2.18. Denote n as the index of the unidirectional prediction motion in the geometric unidirectional prediction candidate list. The LX motion vector of the nth extended merge candidate is used as the nth unidirectional prediction motion vector of the geometric partitioning mode, with X equal to the parity of n. These motion vectors are Fig.31 If the corresponding LX motion vector of the n-th extended merge candidate does not exist, the L(1-X) motion vector of the same candidate is alternatively used as the unidirectional prediction motion vector of the geometric partitioning mode. 2.19.2. Blending Along Geometric Partition Edges After predicting each part of the geometric partition using its own motion, blending is applied to the two prediction signals to derive samples around the geometric partition edges. The blending weights for each position of the CU are derived based on the distance between the individual position and the partition edge. The distance from position (x,y) to the partition edge is derived as: where i,j are the indices of the angle and offset of the geometric partition, which depend on the signaled geometric partition index. x,j and ρ y,j The sign of depends on the angle index i. The weight of each part of the geometric partition is derived as follows: wIdxL(x,y)=partIdx? 32+d(x,y):32-d(x,y) (2-29) w1(x,y)=1-w0(x,y) (2-31) partIdx depends on the angle index i. An example of weight w0 is Fig.32 is shown in . 2.19.3. Motion Field Storage for Geometry Partitioning Patterns Mv1 from the first part of the geometric partitioning, Mv2 from the second part of the geometric partitioning, and the combination Mv of Mv1 and Mv2 are stored in the motion field of the CU encoded in the geometric partitioning mode. The type of motion vector stored for each individual position in the motion field is determined as: sType=abs(motionIdx)<32?2:(motionIdx≤0?(1-partIdx):partIdx) (2-32) Where motionIdx is equal to d(4x+2,4y+2), which is recalculated according to equation (2-18). partIdx depends on the angle index i. If sType is equal to 0 or 1, then Mv0 or Mv1 is stored in the corresponding motion field, otherwise, if sTType is equal to 2, the combined Mv from Mv0 and Mv2 is stored. The combined Mv is generated using the following process: 1) If Mv1 and Mv2 are from different reference picture lists (one from L0 and the other from L1), then Mv1 and Mv2 are simply combined to form a bidirectional prediction motion vector. Otherwise, if Mv1 and Mv2 are from the same list, only the unidirectional predicted motion Mv2 is stored. 2.20. Multi-hypothesis prediction In Multiple Hypothesis Prediction (MHP), on top of Inter AMVP mode, Normal Merge mode, Affine Merge mode and MMVD mode, up to two additional predictors are signaled. The resulting overall prediction signal is iteratively accumulated with each additional prediction signal. p n+1 =(1-α n+1 ) n +α n+1 h n+1 The weight factor α is specified according to the following Table 2-4: Table 2-4 Weight factors for MHP add_hyp_weight_idx α 0 1 / 4 1 -1 / 8 For inter-AMVP mode, MHP is applied only when unequal weights in BCW are selected in bi-prediction mode. Additional assumptions may be merge mode or AMVP mode. In the case of merge mode, motion information is indicated by a merge index, and the merge candidate list is the same as in the geometry partitioning mode. In the case of AMVP mode, reference index, MVP index, and MVD are signaled. 2.21. Non-adjacent spatial candidates Non-adjacent spatial merge candidates are inserted after TMVP in the regular merge candidate list. The pattern of spatial merge candidates is as follows: Fig.33 As shown above, the distance between non-adjacent spatial candidates and the current codec block is based on the width and height of the current codec block. 2.22. Template Matching (TM) Template Matching (TM) is a decoder-side MV derivation method used to refine the motion information of the current CU by finding the closest match between a template in the current picture (i.e., the top and / or left neighboring blocks of the current CU) and a block in a reference picture (i.e., the same size as the template). Fig.34 As shown, in the [-8, +8] pixel search range, a better MV is searched around the initial motion of the current CU. In this contribution, the template matching previously proposed in JVET-J0021 is adopted with two modifications: the search step size is determined based on the AMVR mode, and the TM can cascade the bilateral matching process in the merge mode. In AMVP mode, MVP candidates are determined based on template matching error to select the one that achieves the minimum difference between the current block template and the reference block template, and then TM performs MV refinement only on this specific MVP candidate. TM refines this MVP candidate by using an iterative diamond search, starting with full-pixel MVD accuracy (or 4 pixels for 4-pixel AMVR mode) within the [-8, +8] pixel search range. The AMVP candidate can be further refined by using a cross search with full-pixel MVD accuracy (or 4 pixels for 4-pixel AMVR mode), and then using half-pixels and quarter-pixels in turn according to the AMVR mode specified in Table 2-5. This search process ensures that the MVP candidate still maintains the same MV accuracy as indicated by the AMVR mode after the TM process. Table 2-5 – Search patterns for AMVR and merge patterns with AMVR. In merge mode, a similar search method is applied to the merge candidates indicated by the merge index. As shown in Table 2-5, TM can be performed all the way down to 1 / 8 pixel MVD accuracy, or skip accuracy beyond half-pixel MVD accuracy, depending on whether an alternative interpolation filter is used based on the merged motion information (used when AMVR is half-pixel mode). In addition, when TM mode is enabled, template matching can work as an independent process between block-based and sub-block-based bilateral matching (BM) methods or as an additional MV refinement process, depending on whether BM can be enabled based on its enabling condition check. 2.23. Overlapped Block Motion Compensation (OBMC) Overlapped block motion compensation (OBMC) has been previously used in H.263. In JEM, unlike H.263, OBMC can be turned on and off using CU-level syntax. When OBMC is used in JEM, OBMC is performed on all motion compensated (MC) block boundaries except the right and bottom boundaries of the CU. In addition, it also applies to luma and chroma components. In JEM, an MC block corresponds to a codec block. When a CU is encoded and decoded with sub-CU modes (including sub-CU merging, affine, and FRUC modes), each sub-block of the CU is an MC block. In order to handle CU boundaries in a unified manner, OBMC is performed on all MC block boundaries at the sub-block level, where the sub-block size is set equal to 4×4, as Fig.35 shown. When OBMC is applied to the current sub-block, in addition to the current motion vector, the motion vectors of the four connected neighboring sub-blocks, if available and different from the current motion vector, are also used to derive the prediction block of the current sub-block. These multiple prediction blocks based on multiple motion vectors are combined to generate the final prediction signal of the current sub-block. The prediction block based on the motion vector of the neighboring sub-block is denoted as PN, where N indicates the index of the neighboring upper, lower, left and right sub-blocks, and the prediction block based on the motion vector of the current sub-block is denoted as P C When PN is based on the motion information of a neighboring subblock that contains the same motion information as the current subblock, OBMC is not derived from P N Otherwise, P N Each sample of is added to P C The same sample in P N Four rows / columns are added to P C The weighting factors {1 / 4, 1 / 8, 1 / 16, 1 / 32} are used for P N , and weighting factors {3 / 4, 7 / 8, 15 / 16, 31 / 32} are used for P C . Except for small MC blocks (i.e., when the height or width of the codec block is equal to 4, or when the CU is encoded and decoded in sub-CU mode), there are only two rows / columns of P N Added to P C In this case, weighting factors {1 / 4, 1 / 8} are used for P N , while weighting factors {3 / 4, 7 / 8} are used for PC. For PN generated based on motion vectors of vertically (horizontally) adjacent sub-blocks, samples in the same row (column) of PN are added to P with the same weighting factor. C . In JEM, for CUs with a size less than or equal to 256 luma samples, a CU level flag is signaled to indicate whether OBMC is applied to the current CU. For CUs with a size greater than 256 luma samples or not encoded and decoded using AMVP mode, OBMC is applied by default. At the encoder, when OBMC is applied to a CU, its impact is taken into account in the motion estimation stage. The prediction signal formed by OBMC using the motion information of the top neighboring blocks and the left neighboring blocks is used to compensate the top and left boundaries of the original signal of the current CU, and then the normal motion estimation process is applied. 2.24. Multiple Transform Selection (MTS) for Core Transforms In addition to DCT-II already adopted in HEVC, the Multiple Transform Selection (MTS) scheme is also used for residual coding of inter-frame and intra-frame coded blocks. It uses multiple selected transforms in DCT8 / DST7. The newly introduced transform matrices are DST-VII and DCT-VIII. Table 2 6 shows the basic functions of the selected DST / DCT. Table 2-6 – Transform basis functions for DCT-II / VIII and DST-VII for N-point input To maintain the orthogonality of the transform matrix, the quantization of the transform matrix is ​​more accurate than that in HEVC. To keep the intermediate values ​​of the transform coefficients within 16 bits, all coefficients are 10 bits after horizontal and vertical transforms. To control the MTS scheme, separate enable flags are specified at the SPS level for intra and inter frames respectively. When MTS is enabled at SPS, a CU level flag signal is issued to indicate whether MTS is applied. Here, MTS is only applied to luma. When one of the following conditions applies, MTS signaling will be skipped. – The position of the last significant coefficient of the luma TB is less than 1 (ie DC only). – The last significant coefficient of the luminance TB is located within the MTS zeroing region. If the MTS CU flag is equal to 0, DCT2 is applied in both directions. However, if the MTS CU flag is equal to 1, two other flags are additionally signaled to indicate the transform types in the horizontal and vertical directions, respectively. The transform and signaling mapping table is shown in Table 2-7. The transform selection for ISP and implicit MTS is unified by eliminating intra-frame mode and block shape dependencies. If the current block is in ISP mode or the current block is an intra-frame block and both intra-frame and inter-frame explicit MTS are turned on, only DST7 is used for horizontal and vertical transform cores. In terms of transform matrix accuracy, an 8-bit main transform core is used. Therefore, all transform cores used in HEVC remain the same, including 4-point DCT-2 and DST-7, 8-point, 16-point and 32-point DCT-2. In addition, other transform cores (including 64-point DCT-2, 4-point DCT-8, 8-point, 16-point, 32-point DST-7 and DCT-8) all use 8-bit main transform cores. Table 2-7 Transformation and signaling mapping table To reduce the complexity of large-sized DST-7 and DCT-8, high-frequency transform coefficients are zeroed for DST-7 and DCT-8 blocks with size (width or height, or both) equal to 32. Only coefficients within the 16x16 low-frequency region are retained. As in HEVC, the residual of a block can be coded using transform skip mode. To avoid syntax coding redundancy, the transform skip flag is not signaled when the CU level MTS_CU_flag is not equal to zero. Note that when LFNST or MIP is activated for the current CU, the implicit MTS transform is set to DCT2. In addition, when MTS is enabled for an inter-coded block, implicit MTS can still be enabled. 2.25. Sub-Block Transform (SBT) In VTM, sub-block transform is introduced for inter-predicted CU. In this transform mode, only a sub-part of the residual block is encoded and decoded for the CU. When cu_cbf of an inter-predicted CU is equal to 1, cu_sbt_flag can be signaled to indicate whether the entire residual block or a sub-part of the residual block is encoded and decoded. For the former case, the 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 encoded and decoded by inferring the adaptive transform, while the other part of the residual block is cleared. When SBT is used for an inter-coded CU, the SBT type and SBT position information are signaled in the bitstream. There are two SBT types and two SBT positions, such as Fig.36As shown. For SBT-V (or SBT-H), the TU width (or height) can be equal to half of the CU width (or height) or 1 / 4 of the CU width (or height), resulting in 2:2 partitioning or 1:3 / 3:1 partitioning. 2:2 partitioning is similar to binary tree (BT) partitioning, while 1:3 / 3:1 partitioning is similar to asymmetric binary tree (ABT) partitioning. In ABT splitting, only small areas contain non-zero residuals. If one dimension of the CU is 8 (in units of luminance samples), 1:3 / 3:1 partitioning along this dimension is not allowed. A CU has a maximum of 8 SBT modes. Position-dependent transform kernel selection is applied to luma transform blocks in SBT-V and SBT-H (chroma TBs always use DCT-2). Different kernel transforms are associated with the two positions, SBT-H and SBT-V. More specifically, the horizontal and vertical transforms for each SBT position are in Fig.36 For example, the horizontal and vertical transforms for SBT-V position 0 are DCT-8 and DST-7, respectively. When one side of the residual TU is larger than 32, the transforms for both dimensions are set to DCT-2. Therefore, the sub-block transforms jointly specify the TU tiling, cbf, and the horizontal and vertical core transform types for the residual block. SBT does not apply to CUs coded or decoded using the inter-intra combination mode. 2.26. Adaptive Merging Candidate Reordering Based on Template Matching In order to improve the encoding and decoding efficiency, after building the merge candidate list, the order of each merge candidate is adjusted according to the template matching cost. The merge candidates are arranged in the list according to the template matching cost in ascending order. It operates in the form of subgroups. The template matching cost is measured by the SAD (sum of absolute differences) between the neighboring samples of the current CU and its corresponding reference samples. If the merge candidate includes bidirectional prediction motion information, the corresponding reference sample is the average of the corresponding reference sample in reference list 0 and the corresponding reference sample in reference list 1, such as Fig.37 If the merge candidate includes sub-CU level motion information, the corresponding reference sample is composed of the neighboring samples of the corresponding reference sub-block, such as Fig.38 shown. The sorting process is operated in the form of subgroups, such as Fig.39 As shown in Figure 1, the first three merge candidates are sorted together. The last three merge candidates are sorted together. The template size (width for the left template or height for the upper template) is 1, and the subgroup size is 3. 2.27. Adaptive Merge Candidate List We can assume that the number of merge candidates is 8. We use the first 5 merge candidates as the first subgroup, and the following 3 merge candidates as the second subgroup (ie, the last subgroup). For the encoder, after building the merge candidate list, some merge candidates are adaptively reordered in ascending order of merge candidate cost, e.g. Fig.40 More specifically, the template matching costs of the merge candidates in all subgroups except the last subgroup are calculated; then, except for the last subgroup, the merge candidates in its own subgroup are reordered; finally, a final merge candidate list is obtained. For the decoder, after constructing the merge candidate list, some / no merge candidates are adaptively reordered in ascending order of merge candidate cost, e.g. Fig.41 As shown. Fig.41 In the example, the subgroup in which the selected (signaled) merge candidate is located is called the selected subgroup. More specifically, if the selected merge candidate is located in the last subgroup, the merge candidate list construction process is terminated after the selected merge candidate is derived, and no reordering is performed and the merge candidate list is not changed; otherwise, the execution process is as follows: After all merge candidates in the selected subgroup are derived, the merge candidate list construction process is terminated; the template matching costs of the merge candidates in the selected subgroup are calculated; the merge candidates in the selected subgroup are reordered; and finally, a new merge candidate list is obtained. For both encoder and decoder, The template matching cost is derived as a function of T and RT, where T is the set of samples in the template and RT is the set of reference samples for the template. When deriving the reference samples of the template of the merge candidate, the motion vector of the merge candidate is rounded to integer pixel precision. The reference samples of the template (RT) for bidirectional prediction are derived by weighted averaging the reference samples of the template in reference list 0 (RT0) and the reference samples of the template in reference list 1 (RT1) as follows. RT=((8-w)*RT0+w*RT1+4)>>3 (2-33) The weight of the reference template in reference list 0 (8-w) and the weight of the reference template in reference list 1 (w) are determined by the BCW index of the merge candidate. BCW indexes equal to {0, 1, 2, 3, 4} correspond to w equal to {-2, 3, 4, 5, 10} respectively. If the local illumination compensation (LIC) flag of the merge candidate is true, the reference samples of the template are derived using the LIC method. The template matching cost is calculated based on the sum of absolute differences (SAD) between T and RT. The template size is 1. This means that the width of the template on the left and / or the height of the template above is 1. If the codec mode is MMVD, the merge candidates used to derive the base merge candidate are not reordered. If the coding mode is GPM, the merge candidates used to derive the unidirectional prediction candidate list are not reordered. 2.28. Geometric prediction mode with motion vector difference In the geometric prediction mode with motion vector difference (GMVD), each geometric partition in GPM can decide whether to use GMVD. If GMVD is selected for a geometric region, the MV of the region is calculated as the sum of the MV of the merge candidate and the MVD. All other processing remains the same as GPM. With GMVD, the MVD is signaled as a pair of direction and distance. There are nine candidate distances (1 / 4 pixel, 1 / 2 pixel, 1 pixel, 2 pixels, 3 pixels, 4 pixels, 6 pixels, 8 pixels, 16 pixels) and eight candidate directions (four horizontal / vertical directions and four diagonal directions). In addition, when pic_fpel_mmvd_enabled_flag is equal to 1, the MVD in GMVD is also shifted left by 2, as in MMVD. 2.29. Affine MMVD In affine MMVD, an affine merge candidate (which is called a basic affine merge candidate) is selected, and the MV of the control point is further refined by the signaled MVD information. The MVD information of the MVs of all control points is the same in one prediction direction. When the starting MV is a bidirectional prediction MV with two MVs pointing to different sides of the current picture (i.e., the POC of one reference is greater than the POC of the current picture, and the POC of the other reference is less than the POC of the current picture), the MV offset added to the list 0MV component of the starting MV and the MV offset for the list 1MV have opposite values; otherwise, when the starting MV is a bidirectional prediction MV with two lists pointing to the same side of the current picture (i.e., the POCs of the two references are both greater than the POC of the current picture, or both are less than the POC of the current picture), the MV offset added to the list 0MV component of the starting MV and the MV offset for the list 1MV are the same. 2.30. Adaptive Decoder-side Motion Vector Refinement (ADMVR) In ECM-2.0, the multi-pass decoder-side motion vector refinement (DMVR) method is applied in regular merge mode if the selected merge candidate meets the DMVR conditions. In the first pass, bilateral matching (BM) is applied to the codec block. In the second pass, BM is applied to each 16x16 sub-block within the codec block. In the third pass, the MV in each 8x8 sub-block is refined by applying bidirectional optical flow (BDOF). The adaptive decoder side motion vector refinement method consists of two new merge modes, which are introduced to refine the MV in only one direction (L0 or L1) of bi-directional prediction of merge candidates that meet the DMVR conditions. Multiple passes of DMVR process are applied for the selected merge candidates to refine the motion vectors, however, in the first pass (i.e., PU level) DMVR, MVD0 or MVD1 is set to zero. Similar to the conventional merge mode, the merge candidates for the proposed merge mode are derived from spatially adjacent coded blocks, TMVP, non-adjacent blocks, HMVP, and paired candidates. The difference is that only those that satisfy the DMVR condition are added to the candidate list. The same merge candidate list (i.e., ADMVR merge list) is used by both proposed merge modes, and the merge index is encoded in the conventional merge mode. 2.31. IBC with Template Matching It is proposed to use template matching with IBC also for both IBC Merge mode and IBC AMVP mode. Compared to the merge list used by the regular IBC merge mode, the IBC-TM merge list has been modified so that candidates are selected according to a pruning method with motion distances between candidates as in the regular TM merge mode. The ending zero motion completion (which is meaningless with respect to intra codecs) has been replaced by the motion vectors to the left (-W, 0) CU, the top (0, -H) CU, and the top-left (-W, -H) CU, and then the list is completed with the left CU without pruning if necessary. In IBC-TM merge mode, the selected candidates are refined with template matching method before RDO or decoding process.IBC-TM merge mode has competed with regular IBC merge mode and signals TM merge flag. In IBC-TM AMVP mode, up to 3 candidates are selected from the IBC merge list. Each of these 3 selected candidates is refined using a template matching method and ranked according to their resulting template matching cost. Only the first 2 are then typically considered in the motion estimation process. Template matching refinement for both IBC-TM merge and AMVP mode is very simple, since IBC motion vectors are constrained to be integers and in Fig.42 . Therefore, in IBC-TM merge mode, all refinements are performed with integer precision, and in IBC-TM AMVP mode, refinements are performed with integer or 4-pixel precision. In both cases, the refined motion vectors in each refinement step must obey the constraints of the reference region. 2.32. IBC merge mode with block vector difference The IBC merge mode with block vector difference is shown below. The distance set is {1 pixel, 2 pixels, 4 pixels, 8 pixels, 12 pixels, 16 pixels, 24 pixels, 32 pixels, 40 pixels, 48 ​​pixels, 56 pixels, 64 pixels, 72 pixels, 80 pixels, 88 pixels, 96 pixels, 104 pixels, 112 pixels, 120 pixels, 128 pixels}, and the BVD directions are two horizontal directions and two vertical directions. The base candidate is selected from the first five candidates in the reordered IBC merge list. And all possible MBVD refinement positions (20x4) for each base candidate are reordered based on the SAD cost between the template (one row above the current block and one column to the left) and the reference of each refinement position. Finally, the first 8 refinement positions with the lowest template SAD cost are kept as available positions and thus used for MBVD index encoding and decoding. 2.33. Reconstruction-Reordering IBC (RR-IBC) Screen content codecs such as intra-block copy (IBC) generate prediction blocks by directly copying previously coded reference regions in the same picture. Symmetry is often observed in video content, especially in text character regions and computer-generated graphics in screen content sequences, such as Fig.43 Therefore, a screen content-specific codec that takes symmetry into account will effectively compress such video content. A reconstruction-reordering IBC (RR-IBC) mode for screen content video coding and decoding is proposed. When applied, the samples in the reconstructed block are flipped according to the flip type of the current block. On the encoder side, the original block is flipped before motion search and residual calculation, while the prediction block is derived without flipping. On the decoder side, the reconstructed block is flipped to restore the original block. For RR-IBC codec blocks, two flipping methods are supported, namely horizontal flipping and vertical flipping. First, a syntax flag for the IBC AMVP coded block is signaled, indicating whether the reconstruction is flipped, and if it is flipped, another flag specifying the flip type is further signaled. For IBC merging, the flip type is inherited from the neighboring block without syntax signaling. Taking into account horizontal or vertical symmetry, the current block and the reference block are usually aligned horizontally or vertically. Therefore, when horizontal flipping is applied, the vertical component of BV is not signaled and is inferred to be equal to 0. Similarly, when vertical flipping is applied, the horizontal component of BV is not signaled and is inferred to be equal to 0. In order to better utilize the symmetry property, a flip-aware BV adjustment method is applied to refine the block vector candidates. FIG. 44A to FIG. 44B As shown, (x nbr ,y nbr ) and (x cur ,ycur ) represent the coordinates of the center samples of the neighboring blocks and the current block, BV nbr and BV cur Denote the BV of the neighboring block and the current block respectively. Instead of inheriting the BV directly from the neighboring block, in the case where the neighboring block is coded with horizontal flipping, the motion shift is added to the BV nbr The horizontal component (expressed as BV nbr h ) to calculate BV cur The horizontal component of BV cur h =2(x nbr -x cur )+BV nbr h Similarly, in the case where the neighboring block is coded with vertical flipping, the motion shift is added to BV nbr The vertical component (expressed as BV nbr v ) to calculate BV cur Vertical component, or BV cur v =2(y nbr -y cur )+BV nbr v . 2.34. Intra-frame template matching Intra-frame template matching prediction (Intra-frame TMP) is a special intra-frame prediction mode that copies the best prediction block from the reconstructed part of the current frame. The L-shaped template predicted by intra-frame template matching matches the current template. For a predefined search range, the encoder searches for the template most similar to the current template in the reconstructed part of the current frame and uses the corresponding block as the prediction block. The encoder then signals the use of this mode and performs the same prediction operation on the decoder side. By combining the L-shaped causal neighboring blocks of the current block with the Fig.45 Generate a prediction signal by matching another block in a predefined search area: R1: Current CTU R2: Upper left CTU R3: Upper CTU R4: Left CTU SAD is used as the cost function. In each region, the decoder searches for the template with the minimum SAD relative to the current one and uses its corresponding block as the prediction block. The size of all regions (SearchRange_w, SearchRange_h) is set proportionally to the block size (BlkW, BlkH) so that each pixel has a fixed number of SAD comparisons. That is: SearchRange_w=a*BlkW SearchRange_h=a*BlkH Where "a" is a constant that controls the gain / complexity tradeoff. In practice, "a" is equal to 5. The intra template matching tool is enabled for CUs with size less than or equal to 64 in width and height. This maximum CU size for intra template matching is configurable. When DIMD is not used for the current CU, the intra template matching prediction mode is signaled at the CU level through a dedicated flag. 3. Question In the current design of IBC, the whole block is copied from the reconstructed area in the current picture. The content in the block can come from two or more different objects, and the way of obtaining the prediction of the whole block is not very suitable for this case. 4. Detailed solution The following embodiments should be considered as examples to explain the general concept. These embodiments should not be interpreted in a narrow sense. In addition, these embodiments may be combined in any manner. In the present disclosure, intra-block copying (IBC) may not be limited to current IBC techniques, but may be interpreted as a technique in which a reference (or prediction) block is obtained using samples in the current strip / tile / sub-picture / picture / other video unit (e.g., CTU row), excluding conventional intra-frame prediction methods. Intra-block copying with geometric partitioning 1. It is proposed that intra block copy can be used to obtain prediction of at least one sub-partition in a video unit when the video unit is geometrically partitioned into more than one sub-partition. The coding mode is denoted as IBC-GPM. a. Alternatively, it is proposed that when a video unit is predicted by more than one hypothesis, IBC can be used to obtain a prediction for at least one hypothesis in the video unit, and the hypothesis predictions are geometrically weighted summed to generate a final prediction. b. In one example, when IBC is used to obtain predictions, IBC merge mode and / or IBC AMVP mode may be used. i. In one example, how to obtain a prediction using IBC for at least one sub-partition can be combined with obtaining a prediction using The prediction of the entire block is done in the same way as for the IBC codec. ii. Alternatively, how to obtain prediction using IBC for at least one sub-partition or one hypothesis may be different from the way of obtaining prediction for the entire block decoded with IBC. 1) In one example, the maximum allowed number of merge / AMVP candidates may be different. 2) In one example, the construction of the IBC merge / AMVP candidate list may be different. 3) In one example, the IBC merge candidate list may not be reordered. a) Alternatively, the IBC merge candidate list may be reordered in a different way. iii. In one example, one or more specific patterns may not be used to obtain a prediction. 1) In one example, the specific merge mode may refer to an IBC TM merge / AMVP mode, or an IBC merge mode with BVD, or an RR-IBC merge / AMVP mode for AMVP of IBC. c. In one example, intra prediction may be used to obtain predictions for one or more sub-partitions / hypotheses. i. In one example, intra prediction may refer to a specific codec tool, such as conventional intra prediction, DIMD, TIMD, MRL, ISP, MIP, intra TMP, CCLM, MMLM, CCCM, GLM. ii. In one example, an intra prediction mode (IPM) candidate list is used, and one or more IPMs of the IPM candidate list may be used to obtain predictions for one or more sub-partitions. 1) In one example, the IPM candidate list may include one or more IPMs from the primary MPM list or the secondary MPM list. 2) In one example, the IPM candidate list may be constructed using TIMD and / or DIMD. 3) In one example, the block vector can be used to construct an IPM candidate list. a) For example, the block vector may be used by the IBC to obtain a prediction for one or more sub-partitions / hypotheses. d. In one example, inter prediction may be used to obtain predictions for one or more sub-partitions / hypotheses. i. In one example, inter prediction may refer to a specific codec tool, such as CIIP (eg, CIIP-Plane, CII-TIMD, CIIP-TM), BCW (e.g., BCW index derived from TM), MMVD (e.g., MMVD or TM-based reordering for MMVD), Template Matching (TM), IBC (e.g., IBC-TM, IBC with block vector difference, IBC with reconstruction reordering), Affine (e.g., affine MMVD, TM-based reordering for affine MMVD), DMVR / multi-pass DMVR, PROF, BDOF / sample-based BDOF, Adaptive decoder-side motion vector refinement (ADMVR), OBMC or TM-based OBMC, MHP, GPM (e.g., GPM, GPM-TM, GPM- MMVD, GPM-intra), bilateral / template matching AMVP-merge mode. 2. It is proposed to obtain the prediction of the first component (eg chrominance component) of a video unit in the same way as the second component (eg luminance component). a. In one example, whether and how the prediction of the first component is obtained in the same way as the second component may depend on whether a single tree or a dual tree is used. i. In one example, when a single tree is used, the prediction of the first component is obtained in the same way as the second component. b. In one example, the prediction of the first component may be obtained using a specific prediction method other than IBC-GPM (eg, IBC or intra prediction or inter prediction). 3. In one example, the prediction for the region along the edge of a geometric partition can be obtained by blending the predictions of two sub-partitions. a. In one example, weights for blending can be derived on the fly or predefined. b. In one example, the weight used for blending may depend on the distance between the blending sample and the edge of the geometric partition. c. In one example, the width of the blending region may be signaled. i. In one example, the determination of the mixed region may depend on codec information such as block size. Storage BV and IPM and MV 4. In one example, the codec information of the video unit using the IBC-GPM codec can be stored and used by the subsequent video unit in the current picture and / or the video unit in the subsequent picture. a. In one example, the codec information may refer to a block vector and / or an intra prediction mode and / or a motion vector. b. In one example, one or more BVs may be used to construct a merge / AMVP for subsequent video units candidate list, or is inserted into the historical BV buffer for future reference. i. In one example, a BV in a subpartition having a larger size than other subpartitions may be used. ii. In one example, the BV in the first / last sub-partition may be used. iii. Alternatively, the use of BV in IBC-GPM is not allowed. c. In one example, one or more IPMs may be used to construct an MPM list for subsequent video units, or stored in an IPM buffer, or used for chroma prediction. i. In one example, an IPM in a subpartition having a larger size than other subpartitions may be used. ii. In one example, the IPM in the first / last sub-partition may be used. iii. Alternatively, the use of IPM in IBC-GPM is not allowed. 1) In one example, a default IPM such as Planar or DC may be used. d. In one example, one or more MVs may be used to construct a merge / AMVP candidate list for a subsequent video unit, or stored in a motion information buffer. i. In one example, MVs in subpartitions having a larger size than other subpartitions may be used. ii. In one example, the MV in the first / last sub-partition may be used. iii. Alternatively, the use of MVs in IBC-GPM is not allowed. 1) In one example, the motion information for a video unit is set equal to IBC mode. IBC-GPM enabled controls 5. The determination of whether a block is allowed to utilize IBC-GPM mode coding may depend on the codec information. a. In one example, the encoding information may indicate whether IBC (merging and / or AMVP) is allowed. b. In one example, the codec information may refer to block dimension and / or block size. c. In one example, the codec information may refer to the depth of the block. d. In one example, the codec information may refer to a block position, such as whether the current block is the first line / row of a CTU. e. In one example, the codec information may refer to a slice / picture type. f. In one example, the codec information may refer to information of a time layer (eg, a time layer index). g. In one example, the codec information may refer to information of color components. Signaling for IBC-GPM 6. An indication of the IBC-GPM may be signaled conditionally, wherein the condition may include: a. Is IBC merger / AMVP mode allowed? b. Block size and / or block size c. Codec information can refer to the depth of the block d. Strip / picture type and / or partition tree type (single tree, dual tree, or local dual tree) e. Block location f. Color component. 7. Whether and how IBC-GPM is applied to a video unit may be indicated in the bitstream. a. In one example, whether IBC-GPM is enabled for a video unit may be signaled using one or more syntax elements. i. In one example, a syntax element may be used to indicate whether IBC-GPM is applied to a video unit, and / or one or more syntax elements may be used to indicate whether IBC AMVP / Merge is used to obtain prediction. ii. In one example, a syntax element may be used to indicate whether IBC merge mode is used in IBC-GPM. iii. In one example, a syntax element may be used to indicate whether the IBC AMVP mode is used in the IBC-GPM. b. In one example, how and whether a video unit is divided into more than one sub-partition is predefined or derived or signaled in the bitstream. i. In one example, syntax elements are signaled to indicate how the video units are divided. ii. In one example, one or more syntax elements may be used to indicate how prediction for each sub-partition is obtained, such as IBC and / or inter prediction and / or intra prediction. c. In one example, a syntax element indicating which IPM in the IPM candidate list is used to obtain intra prediction for one or more sub-partitions may be signaled. d. In one example, how to use multiple sub-partitions for mixed prediction can be signaled in the bitstream. i. In one example, a syntax element indicating the mix width may be signaled. e. In one example, the above syntax elements may be binarized using fixed length codec, or truncated unary codec, or unary codec, or EG codec, or may be coded as a flag. i. In one example, syntax elements are bypassed for encoding and decoding. ii. Alternatively, the syntax element is context-encoded. 1) The context may depend on codec information, such as block size and / or block size, and / or slice / picture type, and / or information of neighboring blocks (adjacent or non-adjacent), and / or information of other codec tools used for the current block, and / or information of the temporal layer. f. In one example, one or more syntax elements may be signaled at: sequence header / picture header / SPS / VPS / DPS / DCI / PPS / APS / slice header / tile group header. g. In one example, IBC-GPM and GPM may share a signaling method for at least one syntax element, For example, binarization, signaling conditions, and codec context. General claims 8. In the above examples, a video unit may refer to a color component / sub-picture / slice / tile / codec tree unit (CTU) / CTU row / CTU group / codec unit (CU) / prediction unit (PU) / transform unit (TU) / codec tree block (CTB) / codec block (CB) / transform block (TB) / block / sub-block of a block / sub-region within a block / any other region containing more than one sample or pixel. 9. Whether and / or how to apply the above-disclosed method can be signaled at the following places: sequence level / picture group level / picture level / slice level / tile group level, for example in sequence header / picture header / SPS / VPS / DPS / DCI / PPS / APS / slice header / tile group header. 10. Whether and / or how to apply the above disclosed method can be signaled at the following: PB / TB / CB / PU / TU / CU / VPDU / CTU / CTU row / slice / tile / sub-picture / other type of area containing more than one sample or pixel. 11. Whether and / or how to apply the above disclosed method may depend on codec information, such as block size, color format, single tree / dual tree partitioning, color component, slice / picture type.

[0104] As used herein, the term "video unit" or "video block" may be a sequence, a picture, a slice, a tile, a block, a sub-picture, a codec tree unit (CTU) / codec tree block (CTB), a CTU / CTB row, one or more codec units (CU) / codec blocks (CB), one or more CTU / CTBs, one or more virtual pipeline data units (VPDU), a sub-region within a picture / slice / tile / brick. The term "reference row" may refer to a row and / or column reconstructed sample adjacent or non-adjacent to a current block, which is used to derive an intra-frame prediction of the current video unit via a difference filter along a specific direction, and the specific direction is determined by an intra-frame prediction mode (e.g., a conventional intra-frame prediction with an intra-frame prediction mode), or via weighting the reference samples of the reference row using a matrix or vector (e.g., MIP) to derive the intra-frame prediction of the current video unit.

[0105] Fig.46 A flow chart of a method 4600 for video processing according to an embodiment of the present disclosure is shown. The method 4600 is implemented during conversion between a video unit of a video and a bit stream of the video.

[0106] At block 4610, for conversion between a video unit of a video and a bitstream of the video unit, a prediction of at least one object of the video unit is obtained by using intra-block copying (IBC). The video unit is encoded and decoded using an IBC-geometric partitioning mode (GPM) in which the video unit is geometrically divided into a plurality of sub-partitions. The term "object" as used herein may refer to a portion of a video unit, for example, a geometrically divided sub-partition of a video unit. Alternatively, the term "object" as used herein may refer to a hypothesis of a video unit.

[0107] For example, it is proposed that intra block copying can be used to obtain a prediction of at least one sub-partition in a video unit when the video unit is geometrically partitioned into more than one sub-partition. The coding mode is denoted as IBC-GPM. Alternatively, the video unit is predicted by multiple hypotheses. For example, it is proposed that when the video unit is predicted by more than one hypothesis, IBC can be used to obtain a prediction of at least one hypothesis in the video unit, and the hypothesis predictions are geometrically weighted summed to generate a final prediction.

[0108] At block 4620, conversion is performed based on the prediction of at least one object of the video unit. In some embodiments, the conversion may include encoding the video unit into a bitstream. Alternatively or in addition, the conversion may include decoding the video unit from the bitstream. This may improve coding efficiency and coding performance.

[0109] In some embodiments, obtaining the prediction includes: obtaining a prediction of at least one sub-partition of the video unit by using IBC based on determining that the video unit is geometrically divided into a plurality of sub-partitions. In some embodiments, obtaining the prediction includes: obtaining a prediction of at least one hypothesis of the video unit based on determining that the video unit is predicted by a plurality of hypotheses. In some embodiments, method 4600 further includes: geometrically summing the predictions of the plurality of hypotheses; and generating a final prediction of the video unit based on the weighted summed prediction.

[0110] In some embodiments, when IBC is used to obtain prediction, at least one of an IBC merge mode or an IBC advanced motion vector prediction (AMVP) mode is used.

[0111] In some embodiments, the method of obtaining a prediction for at least one sub-partition of a video unit using IBC is the same as the method of obtaining a prediction for an entire block encoded using IBC. In one embodiment, how to obtain a prediction for at least one sub-partition using IBC can be the same as the method of obtaining a prediction for an entire block encoded using IBC.

[0112] In some embodiments, the method of obtaining a prediction for at least one sub-partition or one hypothesis for a video unit using IBC is different from the method of obtaining a prediction for the entire block using IBC codec. In some embodiments, the maximum allowed number of IBC merge candidates or IBC AMVP candidates is different. In some embodiments, the construction of the IBC merge candidate list or IBC AMVP candidate list is different.

[0113] In some embodiments, the IBC merge candidate list is not sorted. Alternatively, the IBC merge candidate list is sorted in a different manner.

[0114] In some embodiments, one or more specific modes are not used to obtain the prediction. In some embodiments, the specific merge modes include at least one of: IBC Template Matching (TM) merge mode, IBC TM AMVP mode, IBC merge mode with Block Vector Difference (BVD), Reconstruct-Reorder IBC (RR-IBC) merge mode, RR-IBC AMVP mode, or Adaptive Motion Vector Resolution (AMVR) for IBC.

[0115] In some embodiments, intra prediction is used to obtain a prediction of at least one sub-partition or hypothesis of a video unit. In some embodiments, intra prediction includes a specific codec tool. In some embodiments, the specific codec tool includes at least one of the following: traditional intra prediction, decoder-side intra mode derivation (DIMD), template-based intra mode derivation (TIMD), multiple reference line intra prediction (MRL), intra sub-partitioning (ISP), matrix weighted intra prediction (MIP), intra template matching prediction (IntraTMP), cross-component linear model (CCLM) mode, multi-modal learner mode (MMLM), convolutional cross-component model (CCCM), or general linear model (GLM).

[0116] In some embodiments, an intra prediction mode (IPM) candidate list is used, and one or more IPMs of the IPM candidate list are used to obtain a prediction of at least one sub-partition of a video unit. In some embodiments, the IPM candidate list includes one or more IPMs from a primary most probable mode (MPM) list or a secondary MPM list. In some embodiments, the IPM candidate list is constructed using at least one of TIMD and DIMD. In some embodiments, block vectors are used to construct the IPM candidate list. In some embodiments, the block vectors are used by the IBC to obtain a prediction of at least one sub-partition or hypothesis of a video unit. In some embodiments, inter prediction is used to obtain a prediction of at least one sub-partition or hypothesis of a video unit.

[0117] In some embodiments, inter prediction includes at least one of: combined inter and intra prediction (CIIP), bidirectional prediction (BCW) with codec level weights, merge mode with motion vector difference (MMVD), TM, IBC, affine, decoder-side motion vector refinement (DMVR), multi-pass DMVR, prediction refinement with optical flow (PROF), bidirectional optical flow (BDOF), sampling-based BDOF, adaptive decoder-side motion vector refinement (ADMVR), overlapped block motion compensation (OBMC), TM-based OBMC, multiple hypothesis prediction (MHP), geometric partitioning mode (GPM), bilateral AMVP-merge mode, or template matching AMVP-merge mode, or their variants. In some embodiments, CIIP comprises at least one of: CIIP-plane, CIIP-TIMD or CIIM-TM; or wherein BCW comprises a BCW index derived from TM; or wherein MMVD comprises TM-based reordering for MMVD; or wherein IBC comprises at least one of: IBC-TM, IBC with block vector difference, IBC with reconstruction reordering; or wherein affine comprises at least one of: affine-MMVD, TM-based reordering for affine MMVD; or wherein GPM comprises at least one of: GPM-TM, GPM-MMVD, GPM-intra. In one example, inter prediction can refer to specific codec tools, such as CIIP (e.g., CIIP-planar, CIIP-TIMD, CIIM-TM), BCW (e.g., BCW index derived from TM), MMVD (e.g., MMVD or TM-based reordering for MMVD), Template Matching (TM), IBC (e.g., IBC-TM, IBC with block vector difference, IBC with reconstruction reordering), Affine (e.g., affine-MMVD, TM-based reordering for affine MMVD), DMVR / multi-pass DMVR, PROF, BDOF / sample-based BDOF, adaptive decoder-side motion vector refinement (ADMVR), OBMC or TM-based OBMC, MHP, GPM (e.g., GPM, GPM-TM, GPM-MMVD, GPM-intra), bilateral / template matching AMVP-merge mode.

[0118] In some embodiments, the method of obtaining the prediction of the first component (e.g., chroma component) of the video unit is the same as the method of obtaining the prediction of the second component (e.g., luma component). For example, it is proposed to obtain the first component (e.g., chroma component) of the video unit in the same manner as the second component (e.g., luma component).

[0119] In some embodiments, whether and / or how the prediction of the first component is obtained using the same method as the second component depends on whether a single tree or a dual tree is used. In some embodiments, when a single tree is used, the prediction of the first component is obtained using the same method as the second component.

[0120] In some embodiments, the prediction of the first component is obtained using a specific prediction method other than IBC-GPM. In one embodiment, the prediction of the first component may be obtained using a specific prediction method other than IBC-GPM, such as IBC or intra prediction or inter prediction.

[0121] In some embodiments, the prediction of the region along the edge of the geometric partition of the video unit is obtained by combining the predictions of the two sub-partitions of the video unit. In some embodiments, the weights for combining the predictions are derived on the fly or predefined. In some embodiments, the weights for combining the predictions depend on the distance between the combined samples to the edge of the geometric partition. In some embodiments, the width of the region is indicated. In some embodiments, the determination of the region depends on codec information (e.g., block size).

[0122] In some embodiments, the codec information of the video unit using the IBC-GPM codec is stored and used by at least one of: one or more subsequent video units in the current picture, or one or more video units in one or more subsequent pictures. In some embodiments, the codec information refers to at least one of: a block vector (BV), an intra prediction mode, or a motion vector.

[0123] In some embodiments, one or more BVs are used to construct a merge candidate list or an AMVP candidate list for one or more subsequent video units. Alternatively, one or more BVs are inserted into a historical BV buffer for future reference.

[0124] In some embodiments, one or more BVs in a subpartition with a larger size than other subpartitions are used. In some embodiments, one or more BVs in the first subpartition are used. Alternatively, one or more BVs in the last subpartition are used. In some embodiments, no BVs in the IBC-GPM are allowed to be used.

[0125] In some embodiments, one or more IPMs are used to construct an MPM list for subsequent video units, or one or more IPMs are stored in an IPM buffer, or one or more IPMs are used for chroma prediction. In some embodiments, one or more IPMs in a subdivision having a larger size than other subdivisions are used. In some embodiments, one or more IPMs in the first subdivision are used. Alternatively, one or more IPMs in the last subdivision are used. In some embodiments, none of the IPMs in the IBC-GPM are allowed to be used. In some embodiments, a default IPM is used.

[0126] In some embodiments, one or more motion vectors (MVs) are used to construct at least one of: a merge candidate list or an AMVP candidate list for a subsequent video unit. Alternatively, one or more MVs are stored in a motion information buffer.

[0127] In some embodiments, one or more MVs in a sub-partition having a larger size than other sub-partitions are used. In some embodiments, one or more MVs in the first sub-partition are used. Alternatively, one or more MVs in the last sub-partition are used. In some embodiments, no MVs in IBC-GPM are allowed to be used. In some embodiments, the motion information for the video unit is set equal to IBC mode.

[0128] In some embodiments, the determination of whether a video unit is allowed to be encoded and decoded using the IBC-GPM mode depends on the codec information. In some embodiments, the codec information includes at least one of the following: whether the IBC merge mode is allowed, whether the IBC AMVP mode is allowed, block size, block size, depth of the video unit, block position, slice type, picture type, information of the temporal layer, or color component information. In some embodiments, the indication of IBC-GPM is signaled based on a condition. In this case, the condition may include: whether the IBC merge mode is allowed, whether the IBC AMVP mode is allowed, block size, block size, depth of the video unit, slice type, picture type, partition tree type, block position, or color component.

[0129] In some embodiments, whether and / or how IBC-GPM is applied to a video unit is indicated in the bitstream. In some embodiments, whether IBC-GPM is enabled for a video unit is indicated using one or more syntax elements. In some embodiments, syntax elements are used to indicate whether IBC-GPM is applied to a video unit, and / or one or more syntax elements are used to indicate whether IBC AMVP or IBC merge is used to obtain a prediction. In some embodiments, syntax elements are used to indicate whether IBC merge mode is used in IBC-GPM. In some embodiments, syntax elements are used to indicate whether IBC AMVP mode is used in IBC-GPM.

[0130] In some embodiments, how and whether to divide a video unit into multiple sub-partitions is predefined, or how and whether to divide a video unit into multiple sub-partitions is derived, or how and whether to divide a video unit into multiple sub-partitions is signaled in the bitstream. In some embodiments, syntax elements are signaled to indicate the method of dividing the video unit. In some embodiments, one or more syntax elements are used to indicate the method of obtaining a prediction for each sub-partition.

[0131] In some embodiments, a syntax element indicating which IPM in the IPM candidate list is used to obtain intra prediction for one or more sub-partitions is indicated. In some embodiments, a method of combining predictions using multiple sub-partitions of a video unit is indicated in the bitstream. In some embodiments, a syntax element indicating a combination width is indicated.

[0132] In some embodiments, the syntax element is binarized using a fixed length codec, or wherein the syntax element is a truncated unary codec, or the syntax element is a unary codec, or wherein the syntax element is an EG codec, or the syntax element is coded as a flag. Alternatively, the syntax element is a bypass codec.

[0133] In some embodiments, the syntax element is context-coded. In some embodiments, the context depends on codec information. In some embodiments, the codec information includes at least one of: block size, block size, slice type, picture type, information of neighboring blocks (adjacent or non-adjacent), information of other codec tools used for the video unit, or information of a temporal layer.

[0134] In some embodiments, the syntax element is indicated at one of: a sequence header, a picture header, a sequence parameter set (SPS), a video parameter set (VPS), a dependency 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. In some embodiments, the IBC-GPM and the GPM share a signaling method for at least one syntax element.

[0135] In some embodiments, the video unit includes at least one of the following: a color component, a prediction block (PB), a transform block (TB), a codec block (CB), a prediction unit (PU), a transform unit (TU), a codec tree block (CTB), a codec unit (CU), a codec tree unit (CTU), a CTU row, a CTU group, a slice, a tile, a sub-picture, a block, a sub-region within a block, or a region containing more than one sample or pixel.

[0136] In some embodiments, an indication of whether and / or how to obtain prediction of at least one object of a video unit by using IBC is indicated at one of: sequence level, group of picture level, picture level, slice level, or tile group level.

[0137] In some embodiments, an indication of whether and / or how to obtain prediction of at least one object of a video unit by using IBC is indicated in one of the following: a sequence header, a picture header, a sequence parameter set (SPS), a video parameter set (VPS), a dependency 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.

[0138] In some embodiments, an indication of whether and / or how to obtain a prediction of at least one object of a video unit by using IBC is included in one of the following: a prediction block (PB), a transform block (TB), a codec block (CB), a prediction unit (PU), a transform unit (TU), a codec unit (CU), a virtual pipeline data unit (VPDU), a codec tree unit (CTU), a CTU row, a slice, a tile, a sub-picture, or a region containing more than one sample or pixel.

[0139] In some embodiments, method 4600 further includes determining whether and / or how to obtain a prediction of at least one object of the video unit by using IBC based on codec information of the video unit, the codec information including at least one of the following: block size, color format, single tree and / or dual tree partitioning, color component, slice type, or picture type.

[0140] In some embodiments, converting includes encoding the video unit into a bitstream.

[0141] In some embodiments, converting includes decoding the video unit from a bitstream.

[0142] According to another embodiment 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 generated by a method performed by a device for video processing. The method includes: obtaining a prediction of at least one object of a video unit of the video by using intra-frame block copy (IBC), wherein the video unit is encoded and decoded using IBC-geometric partitioning mode (GPM) or the video unit is predicted by multiple hypotheses, in which the video unit is geometrically divided into multiple sub-partitions; and generating a bitstream based on the prediction of at least one object of the video unit.

[0143] According to another embodiment of the present disclosure, a method for storing a bitstream of a video is provided. The method includes: obtaining a prediction of at least one object of a video unit of the video by using intra-frame block copy (IBC), wherein the video unit is encoded and decoded using an IBC-geometric partitioning mode (GPM) or the video unit is predicted by multiple hypotheses, in which the video unit is geometrically divided into multiple sub-partitions; generating a bitstream based on the prediction of at least one object of the video unit; and storing the bitstream in a non-transitory computer-readable recording medium.

[0144] Implementations of the present disclosure may be described according to the following clauses, features of which may be combined in any reasonable way.

[0145] Item 1. A video processing method, comprising: for conversion between a video unit of a video and a bitstream of the video unit, obtaining a prediction of at least one object of the video unit by using intra block copy (IBC), wherein the video unit is encoded and decoded using IBC-Geometric Partitioning Mode (GPM) or the video unit is predicted by multiple hypotheses, in which the video unit is geometrically divided into multiple sub-partitions; and performing the conversion based on the prediction of the at least one object of the video unit.

[0146] Clause 2. The method of clause 1, wherein obtaining the prediction comprises: obtaining the prediction of at least one sub-partition in the video unit by using the IBC based on determining that the video unit is geometrically divided into the plurality of sub-partitions.

[0147] Clause 3. The method of clause 1, wherein obtaining the prediction comprises: obtaining the prediction for at least one hypothesis of the video unit based on determining that the video unit is predicted by a plurality of hypotheses.

[0148] Clause 4. The method of clause 3, further comprising: geometrically summing the predictions of the plurality of hypotheses; and generating a final prediction of the video unit based on the weighted summed predictions.

[0149] Clause 5. The method of clause 1, wherein when the IBC is used to obtain the prediction, at least one of an IBC merge mode or an IBC advanced motion vector prediction (AMVP) mode is used.

[0150] Clause 6. The method of clause 5, wherein the prediction for at least one sub-partition of the video unit is obtained using the IBC in the same way as a prediction for an entire block encoded with the IBC.

[0151] Clause 7. The method of clause 5, wherein the prediction for at least one sub-partition or one hypothesis of the video unit is obtained using the IBC in a different method than a method for obtaining a prediction for an entire block encoded with the IBC.

[0152] Clause 8. The method of clause 7, wherein the maximum allowed number of IBC merge candidates or IBC AMVP candidates is different.

[0153] Clause 9. The method of clause 7, wherein the construction of the IBC merge candidate list or the IBC AMVP candidate list is different.

[0154] Clause 10. The method of clause 7, wherein the IBC merge candidate list is not sorted, or wherein the IBC merge candidate list is sorted in a different manner.

[0155] Clause 11. The method of clause 5, wherein one or more specific patterns are not used to obtain the prediction.

[0156] Clause 12. The method of clause 11, wherein the specific merge mode comprises at least one of: IBC template matching (TM) merge mode, IBC TM AMVP mode, IBC merge mode with block vector difference (BVD), reconstruction-reorder IBC (RR-IBC) merge mode, RR-IBC AMVP mode, or adaptive motion vector resolution (AMVR) for IBC.

[0157] Clause 13. The method of clause 1, wherein intra prediction is used to obtain the prediction for at least one sub-partition or hypothesis of the video unit.

[0158] Clause 14. The method of clause 13, wherein the intra prediction comprises specific codec tools.

[0159] Clause 15. A method according to clause 14, wherein the specific codec tool includes at least one of the following: traditional intra prediction, decoder-side intra mode derivation (DIMD), template-based intra mode derivation (TIMD), multiple reference line intra prediction (MRL), intra sub-partitioning (ISP), matrix weighted intra prediction (MIP), intra template matching prediction (IntraTMP), cross-component linear model (CCLM) mode, multi-modal learner mode (MMLM), convolutional cross-component model (CCCM), or general linear model (GLM).

[0160] Clause 16. The method of clause 13, wherein an intra prediction mode (IPM) candidate list is used, and one or more IPMs of the IPM candidate list are used to obtain the prediction of the at least one sub-partition of the video unit.

[0161] Clause 17. The method of clause 16, wherein the IPM candidate list comprises one or more IPMs from a primary most probable mode (MPM) list or a secondary MPM list.

[0162] Clause 18. The method of Clause 16, wherein the IPM candidate list is constructed using at least one of TIMD and DIMD.

[0163] Clause 19. The method of clause 16, wherein block vectors are used to construct the IPM candidate list.

[0164] Clause 20. The method of clause 19, wherein the block vector is used by an IBC to obtain the prediction of the at least one sub-partition or hypothesis of the video unit.

[0165] Clause 21. The method of clause 1, wherein inter prediction is used to obtain the prediction for at least one sub-partition or hypothesis of the video unit.

[0166] Clause 22. A method according to clause 21, wherein the inter prediction comprises at least one of the following: combined inter and intra prediction (CIIP), a variant of CIIP, bidirectional prediction (BCW) with codec level weights, a variant of BCW, merge mode with motion vector difference (MMVD), a variant of MMVD, TM, a variant of TM, IBC, a variant of IBC, affine, a variant of affine, decoder side motion vector refinement (DMVR), a variant of DMVR, multi-pass DMVR, a variant of multi-pass DMVR, prediction refinement with optical flow (PROF), a variant of PROF, Bidirectional Optical Flow (BDOF), variants of BDOF, sampling-based BDOF, variants of sampling-based BDOF, Adaptive decoder-side motion vector refinement (ADMVR), variants of ADMVR, Overlapped Block Motion Compensation (OBMC), variants of OBMC, TM-based OBMC, variants of TM-based OBMC, Multiple Hypothesis Prediction (MHP), variants of MHP, Geometric Partitioning Mode (GPM), variants of GPM, bilateral AMVP-merge mode, variants of bilateral AMVP-merge mode, template matching AMVP-merge mode, or variants of template matching AMVP-merge mode.

[0167] Clause 23. A method according to clause 22, wherein the CIIP includes at least one of the following: CIIP-plane, CIIP-TIMD or CIIM-TM; or wherein the BCW includes a BCW index derived from a TM; or wherein the MMVD includes a TM-based reordering for the MMVD; or wherein the IBC includes at least one of the following: IBC-TM, IBC with block vector difference, IBC with reconstruction reordering; or wherein the affine includes at least one of the following: affine-MMVD, TM-based reordering for affine MMVD; or wherein the GPM includes at least one of the following: GPM-TM, GPM-MMVD, GPM-intraframe.

[0168] Clause 24. The method of Clause 1, wherein the method of obtaining the prediction of the first component of the video unit is the same as the method of obtaining the prediction of the second component.

[0169] Clause 25. The method of clause 24, wherein whether and / or how the prediction of the first component is obtained using the same method as for the second component depends on whether a single tree or a dual tree is used.

[0170] Clause 26. The method of clause 25, wherein when the single tree is used, the prediction of the first component is obtained using the same method as the second component.

[0171] Clause 27. The method of Clause 24, wherein the prediction of the first component is obtained using a specific prediction method other than IBC-GPM.

[0172] Clause 28. The method of clause 1, wherein the prediction of a region along an edge of a geometric partition of the video unit is obtained by combining predictions of two sub-partitions of the video unit.

[0173] Clause 29. The method of clause 28, wherein weights used to combine the predictions are derived on the fly or predefined.

[0174] Clause 30. The method of clause 28, wherein a weight used to combine the predictions depends on a distance between the combined samples and the edges of the geometric partition.

[0175] Clause 31. The method of clause 28, wherein a width of the region is indicated.

[0176] Clause 32. The method of clause 28, wherein the determination of the region depends on codec information.

[0177] Clause 33. The method of clause 1, wherein codec information for the video unit using IBC-GPM codec is stored and used by at least one of: one or more subsequent video units in a current picture, or one or more video units in one or more subsequent pictures.

[0178] Clause 34. The method of clause 33, wherein the codec information refers to at least one of: a block vector (BV), an intra prediction mode, or a motion vector.

[0179] Clause 35. A method according to clause 33, wherein one or more BVs are used to construct a merge candidate list or an AMVP candidate list for one or more subsequent video units, or wherein the one or more BVs are inserted into a historical BV buffer for future reference.

[0180] Clause 36. The method of clause 35, wherein one or more BVs in a subpartition having a larger size than other subpartitions are used.

[0181] Clause 37. The method of clause 35, wherein one or more BVs in the first subpartition are used, or wherein one or more BVs in the last subpartition are used.

[0182] Clause 38. The method of clause 35, wherein none of the BVs in the IBC-GPM are permitted to be used.

[0183] Clause 39. A method according to clause 33, wherein one or more IPMs are used to construct an MPM list for a subsequent video unit, or wherein the one or more IPMs are stored in an IPM buffer, or wherein the one or more IPMs are used for chroma prediction.

[0184] Clause 40. The method of clause 39, wherein one or more IPMs in a subpartition having a larger size than other subpartitions are used.

[0185] Clause 41. The method of clause 39, wherein one or more IPMs in a first sub-partition are used, or wherein one or more IPMs in a last sub-partition are used.

[0186] Clause 42. The method of clause 39, wherein no IPM in the IBC-GPM is permitted to be used.

[0187] Clause 43. The method of clause 42, wherein a default IPM is used.

[0188] Clause 44. A method according to clause 33, wherein one or more motion vectors (MVs) are used to construct at least one of the following: a merge candidate list or an AMVP candidate list for a subsequent video unit, or wherein the one or more MVs are stored in a motion information buffer.

[0189] Clause 45. The method of clause 44, wherein one or more MVs in a subpartition having a larger size than other subpartitions are used.

[0190] Clause 46. The method of clause 44, wherein one or more MVs in a first sub-partition are used, or wherein one or more MVs in a last sub-partition are used.

[0191] Clause 47. The method of clause 44, wherein no MVs in the IBC-GPM are permitted to be used.

[0192] Clause 48. The method of clause 47, wherein the motion information for the video unit is set equal to IBC mode.

[0193] Clause 49. The method of Clause 1, wherein the determination of whether the video unit is allowed to be encoded using IBC-GPM mode depends on codec information.

[0194] Clause 50. A method according to Clause 49, wherein the codec information includes at least one of the following: whether the IBC merge mode is allowed, whether the IBC AMVP mode is allowed, block size, block size, depth of the video unit, block position, slice type, picture type, temporal layer information, or color component information.

[0195] Clause 51. A method according to clause 1, wherein the indication of IBC-GPM is signaled based on conditions, wherein the conditions include: whether IBC merge mode is allowed, whether IBC AMVP mode is allowed, block size, block size, depth of the video unit, slice type, picture type, partition tree type, block position, or color component.

[0196] Clause 52. The method of clause 1, wherein whether and / or how to apply IBC-GPM to the video unit is indicated in the bitstream.

[0197] Clause 53. The method of clause 52, wherein whether IBC-GPM is enabled for the video unit is indicated using one or more syntax elements.

[0198] Clause 54. The method of clause 53, wherein a syntax element is used to indicate whether IBC-GPM is applied to the video unit, and / or wherein the one or more syntax elements are used to indicate whether IBC AMVP or IBC Merge is used to obtain the prediction.

[0199] Clause 55. The method of clause 53, wherein a syntax element is used to indicate whether IBC merge mode is used in IBC-GPM.

[0200] Clause 56. The method of clause 53, wherein a syntax element is used to indicate whether the IBC AMVP mode is used in the IBC-GPM.

[0201] Clause 57. A method according to clause 52, wherein how and whether the video unit is divided into multiple sub-partitions is predefined, or wherein how and whether the video unit is divided into the multiple sub-partitions is derived, or wherein how and whether the video unit is divided into the multiple sub-partitions is signaled in the bitstream.

[0202] Clause 58. The method of clause 57, wherein a syntax element is signaled to indicate a method of partitioning the video unit.

[0203] Clause 59. The method of clause 57, wherein one or more syntax elements are used to indicate a method of obtaining the prediction for each sub-partition.

[0204] Clause 60. The method of clause 52, wherein a syntax element indicating which IPM in an IPM candidate list is used to obtain the intra prediction of one or more sub-partitions is indicated.

[0205] Clause 61. The method of clause 52, wherein a method of combining the predictions using the multiple sub-partitions of the video unit is indicated in the bitstream.

[0206] Clause 62. The method of clause 61, wherein a syntax element indicative of the combined width is indicated.

[0207] Clause 63. A method according to any one of clauses 52 to 53, wherein the syntax element is binarized using a fixed length codec, or wherein the syntax element is a truncated unary codec, or wherein the syntax element is a unary codec, or wherein the syntax element is an EG codec, or wherein the syntax element is coded as a flag, or wherein the syntax element is bypass coded, or wherein the syntax element is context coded.

[0208] Clause 64. The method of clause 63, wherein the context depends on codec information.

[0209] Clause 65. A method according to clause 64, wherein the codec information includes at least one of the following: block size, block size, slice type, picture type, information of neighboring blocks, information of other codec tools used for the video unit, or information of temporal layers.

[0210] Clause 66. A method according to any one of clauses 52 to 53, wherein the syntax element is indicated at one of: a sequence header, a picture header, a sequence parameter set (SPS), a video parameter set (VPS), a dependency 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.

[0211] Clause 67. The method of clause 1, wherein the IBC-GPM and the GPM share a signaling method for at least one syntax element.

[0212] Clause 68. A method according to any one of clauses 1 to 67, wherein the video unit comprises at least one of the following: a color component, a prediction block (PB), a transform block (TB), a codec block (CB), a prediction unit (PU), a transform unit (TU), a codec tree block (CTB), a codec unit (CU), a codec tree unit (CTU), a CTU row, a CTU group, a slice, a tile, a sub-picture, a block, a sub-region within a block, or a region containing more than one sample or pixel.

[0213] Clause 69. A method according to any one of clauses 1 to 67, wherein an indication of whether and / or how the prediction of at least one object of the video unit is obtained by using IBC is indicated at one of: a sequence level, a picture group level, a picture level, a slice level, or a tile group level.

[0214] Clause 70. A method according to any one of clauses 1 to 67, wherein an indication of whether and / or how to obtain the prediction of at least one object of the video unit by using IBC is indicated in one of the following: a sequence header, a picture header, a sequence parameter set (SPS), a video parameter set (VPS), a dependency 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.

[0215] Clause 71. A method according to any one of clauses 1 to 67, wherein an indication of whether and / or how to obtain the prediction of at least one object of the video unit by using IBC is included in one of the following: a prediction block (PB), a transform block (TB), a codec block (CB), a prediction unit (PU), a transform unit (TU), a codec unit (CU), a virtual pipeline data unit (VPDU), a codec tree unit (CTU), a CTU row, a slice, a tile, a sub-picture, or a region containing more than one sample or pixel.

[0216] Clause 72. The method according to any one of clauses 1 to 67 further includes: determining whether and / or how to obtain the prediction of at least one object of the video unit by using IBC based on the codec information of the video unit, the codec information including at least one of the following: block size, color format, single tree and / or dual tree partitioning, color component, slice type, or picture type.

[0217] Clause 73. The method of any one of clauses 1 to 72, wherein the converting comprises encoding the video unit into the bitstream.

[0218] Clause 74. The method of any one of clauses 1 to 72, wherein the converting comprises decoding the video unit from the bitstream.

[0219] Clause 75. An apparatus for video processing, comprising a processor and a non-transitory memory having instructions thereon, wherein the instructions, when executed by the processor, cause the processor to perform the method of any one of clauses 1 to 74.

[0220] Clause 76. A non-transitory computer-readable storage medium storing instructions that cause a processor to perform the method of any one of clauses 1 to 74.

[0221] Item 77. A non-transitory computer-readable recording medium storing a bitstream of a video generated by a method performed by a device for video processing, wherein the method comprises: obtaining a prediction of at least one object of a video unit of the video by using intra-block copy (IBC), wherein the video unit is encoded and decoded using an IBC-geometric partitioning mode (GPM) or the video unit is predicted by multiple hypotheses, in which the video unit is geometrically divided into multiple sub-partitions; and generating the bitstream based on the prediction of the at least one object of the video unit.

[0222] Clause 78. A method for storing a bitstream of a video, comprising: obtaining a prediction of at least one object of a video unit of the video by using intra-block copy (IBC), wherein the video unit is encoded and decoded using an IBC-geometric partitioning mode (GPM) or the video unit is predicted by multiple hypotheses, in which the video unit is geometrically divided into multiple sub-partitions; generating the bitstream based on the prediction of the at least one object of the video unit; and storing the bitstream in a non-transitory computer-readable recording medium. Example Device

[0223] Fig.47 A block diagram of a computing device 4700 in which various embodiments of the present disclosure may be implemented is shown. The computing device 4700 may be implemented as a source device 110 (or video encoder 114 or 200) or a destination device 120 (or video decoder 124 or 300), or may be included in a source device 110 (or video encoder 114 or 200) or a destination device 120 (or video decoder 124 or 300).

[0224] It should be understood that Fig.47 The computing device 4700 shown in the figure is for illustrative purposes only and is not intended to in any way imply any limitation on the functionality and scope of the embodiments of the present disclosure.

[0225] like Fig.47 As shown, computing device 4700 includes a general computing device 4700. Computing device 4700 may include at least one or more processors or processing units 4710, memory 4720, storage unit 4730, one or more communication units 4740, one or more input devices 4750, and one or more output devices 4760.

[0226] In some embodiments, the computing device 4700 can be implemented as any user terminal or server terminal with computing capabilities. The server terminal can be a server provided by a service provider, a large computing device, etc. The user terminal can be, for example, any type of mobile terminal, fixed terminal or portable terminal, including a mobile phone, a station, a unit, a device, a multimedia computer, a multimedia tablet computer, an Internet node, a communicator, a desktop computer, a laptop computer, a notebook computer, a netbook computer, a personal communication system (PCS) device, a personal navigation device, a personal digital assistant (PDA), an audio / video player, a digital camera / camcorder, a positioning device, a television receiver, a radio broadcast receiver, an e-book device, a gaming device, or any combination thereof, and includes accessories and peripherals of these devices, or any combination thereof. It is conceivable that the computing device 4700 can support any type of interface to the user (such as a "wearable" circuit, etc.).

[0227] The processing unit 4710 may be a physical processor or a virtual processor and may implement various processes based on a program stored in the memory 4720. In a multi-processor system, multiple processing units execute computer executable instructions in parallel to improve the parallel processing capability of the computing device 4700. The processing unit 4710 may also be referred to as a central processing unit (CPU), a microprocessor, a controller, or a microcontroller.

[0228] The computing device 4700 typically includes various computer storage media. Such media can be any media accessible by the computing device 4700, including but not limited to volatile media and non-volatile media, or removable media and non-removable media. The memory 4720 can be a volatile memory (e.g., a register, a cache, a random access memory (RAM)), a non-volatile memory (such as a read-only memory (ROM), an electrically erasable programmable read-only memory (EEPROM) or flash memory) or any combination thereof. The storage unit 4730 can be any removable or non-removable medium, and can include machine-readable media, such as a memory, a flash drive, a disk, or other media that can be used to store information and / or data and can be accessed in the computing device 4700.

[0229] The computing device 4700 may also include additional removable / non-removable storage media, volatile / non-volatile storage media. Fig.47 Although not shown in the figure, a magnetic disk drive for reading from and / or writing to a removable nonvolatile magnetic disk and an optical disk drive for reading from and / or writing to a removable nonvolatile optical disk may be provided. In this case, each drive may be connected to the bus (not shown) via one or more data medium interfaces.

[0230] The communication unit 4740 communicates with another computing device via a communication medium. In addition, the functions of the components in the computing device 4700 can be implemented by a single computing cluster or multiple computing machines that can communicate via a communication connection. Therefore, the computing device 4700 can operate in a networked environment using logical connections to one or more other servers, networked personal computers (PCs), or other general network nodes.

[0231] Input device 4750 may be one or more of various input devices, such as a mouse, keyboard, trackball, voice input device, etc. Output device 4760 may be one or more of various output devices, such as a display, speaker, printer, etc. With the aid of communication unit 4740, computing device 4700 may also communicate with one or more external devices (not shown), such as storage devices and display devices, and computing device 4700 may also communicate with one or more devices that enable a user to interact with computing device 4700, or any device that enables computing device 4700 to communicate with one or more other computing devices (e.g., a network card, a modem, etc.), if necessary. Such communication may be performed via an input / output (I / O) interface (not shown).

[0232] In some embodiments, some or all components of the computing device 4700 may also be arranged in a cloud computing architecture rather than being integrated in a single device. In a cloud computing architecture, components may be provided remotely and work together to implement the functions described in the present disclosure. In some embodiments, cloud computing provides computing, software, data access and storage services, which will not require the end user to know the physical location or configuration of the system or hardware that provides these services. In various embodiments, cloud computing provides services via a wide area network (such as the Internet) using a suitable protocol. For example, a cloud computing provider provides applications via a wide area network, which can be accessed through a web browser or any other computing component. The software or components of the cloud computing architecture and the corresponding data may be stored on a remote server. The computing resources in a cloud computing environment may be merged or distributed at the location of a remote data center. Cloud computing infrastructures may provide services through a shared data center, although they appear as a single access point for users. Therefore, cloud computing architectures may be used to provide components and functions described herein from a service provider at a remote location. Alternatively, they may be provided by a conventional server, or installed directly or otherwise on a client device.

[0233] In an embodiment of the present disclosure, the computing device 4700 may be used to implement video encoding / decoding. The memory 4720 may include one or more video codec modules 4725 having one or more program instructions. These modules can be accessed and executed by the processing unit 4710 to perform the functions of the various embodiments described herein.

[0234] In an example embodiment performing video encoding, an input device 4750 may receive video data as input 4770 to be encoded. The video data may be processed by, for example, a video codec module 4725 to generate an encoded bitstream. The encoded bitstream may be provided as output 4780 via an output device 4760.

[0235] In an example embodiment performing video decoding, input device 4750 may receive an encoded bitstream as input 4770. The encoded bitstream may be processed by, for example, video codec module 4725 to generate decoded video data. The decoded video data may be provided as output 4780 via output device 4760.

[0236] Although the present disclosure has been specifically shown and described with reference to the preferred embodiments of the present disclosure, it will be understood by those skilled in the art that various changes can be made in form and detail without departing from the spirit and scope of the present application as defined by the appended claims. These changes are intended to be encompassed by the scope of the present application. Therefore, the foregoing description of the embodiments of the present application is not intended to be limiting.

Claims

1. A video processing method, comprising: For conversion between a video unit of a video and a bitstream of the video unit, obtaining prediction of at least one object of the video unit by using intra block copy (IBC), wherein the video unit is encoded or decoded using an IBC-geometric partitioning mode (GPM) in which the video unit is geometrically divided into a plurality of sub-partitions or the video unit is predicted by a plurality of hypotheses; and The converting is performed based on the prediction of the at least one object of the video unit.

2. The method of claim 1 , wherein obtaining the prediction comprises: Based on determining that the video unit is geometrically divided into the plurality of subpartitions, the prediction of at least one subpartition in the video unit is obtained by using the IBC.

3. The method of claim 1 , wherein obtaining the prediction comprises: Based on determining that the video unit is predicted by a plurality of hypotheses, the prediction for at least one hypothesis of the video unit is obtained.

4. The method according to claim 3, further comprising: performing a geometric summation of the predictions of the plurality of hypotheses; as well as A final prediction for the video unit is generated based on the weighted sum prediction.

5. The method of claim 1, wherein when the IBC is used to obtain the prediction, at least one of an IBC merge mode or an IBC advanced motion vector prediction (AMVP) mode is used.

6. The method of claim 5, wherein the prediction for at least one sub-partition of the video unit is obtained using the IBC in the same way as the prediction for the entire block decoded with the IBC.

7. The method of claim 5, wherein the method of obtaining the prediction for at least one sub-partition or one hypothesis of the video unit using the IBC is different from the method of obtaining the prediction for the entire block decoded with the IBC. The method of claim 7 , wherein the maximum allowed number of IBC merge candidates or IBC AMVP candidates is different.

9. The method of claim 7, wherein the construction of the IBC merge candidate list or the IBC AMVP candidate list is different.

10. The method of claim 7, wherein the IBC merge candidate list is not sorted, or wherein the IBC merge candidate list is sorted in a different manner. The method of claim 5 , wherein one or more specific patterns are not used to obtain the prediction.

12. The method according to claim 11, wherein the specific merging mode comprises at least one of the following: IBC Template Matching (TM) Merge Mode, IBC TM AMVP model, IBC merge mode with Block Vector Difference (BVD), Rebuild-Reorder IBC (RR-IBC) merge mode, RR-IBC AMVP mode, or Adaptive Motion Vector Resolution (AMVR) for IBC.

13. The method of claim 1, wherein intra prediction is used to obtain the prediction for at least one sub-partition or hypothesis of the video unit. The method of claim 13 , wherein the intra prediction comprises specific codec tools.

15. The method according to claim 14, wherein the specific codec tool comprises at least one of the following: Traditional intra prediction, Decoder-side intra mode derivation (DIMD), Template-based intra mode derivation (TIMD), Multi-reference line intra prediction (MRL), Intra-frame sub-partitioning (ISP), Matrix Weighted Intra Prediction (MIP), Intra-frame template matching prediction (IntraTMP), Cross-Component Linear Model (CCLM) mode, Multimodal Learner Model (MMLM), Convolutional Cross-Component Model (CCCM), or General linear model (GLM).

16. The method of claim 13, wherein an intra prediction mode (IPM) candidate list is used, and one or more IPMs of the IPM candidate list are used to obtain the prediction of the at least one sub-partition of the video unit.

17. The method of claim 16, wherein the IPM candidate list comprises one or more IPMs from a primary most probable mode (MPM) list or a secondary MPM list.

18. The method of claim 16, wherein the IPM candidate list is constructed using at least one of TIMD and DIMD.

19. The method of claim 16, wherein block vectors are used to construct the IPM candidate list.

20. The method of claim 19, wherein the block vector is used by an IBC to obtain the prediction of the at least one sub-partition or hypothesis of the video unit.

21. The method of claim 1, wherein inter prediction is used to obtain the prediction of at least one sub-partition or hypothesis of the video unit.

22. The method of claim 21, wherein the inter-frame prediction comprises at least one of the following: Combined Inter and Intra Prediction (CIIP), Variants of CIIP, Bidirectional prediction with codec level weights (BCW), A variant of BCW, Merge mode with motion vector difference (MMVD), Variants of MMVD, TM, Variant of TM, IBC, Variants of IBC, Affine, Affine variants, Decoder-side motion vector refinement (DMVR), A variant of DMVR, Multi-pass DMVR, A variant of multi-pass DMVR, Prediction refinement with optical flow (PROF), Variants of PROF, Bidirectional Optical Flow (BDOF), A variant of BDOF, Sampling-based BDOF, A variant of sampling-based BDOF, Adaptive decoder-side motion vector refinement (ADMVR), ADMVR variants, Overlapped Block Motion Compensation (OBMC), Variants of OBMC, OBMC based on TM, A variant of TM-based OBMC, Multiple Hypothesis Prediction (MHP), Variants of MHP, Geometric Partitioning Mode (GPM), A variant of GPM, Bilateral AMVP-Merge Mode, Bilateral AMVP - a variant of the merge model, Template matching AMVP-Merge mode, or Template matching AMVP - a variant of the merge mode.

23. The method of claim 22, wherein the CIIP comprises at least one of: CIIP-Plane, CIIP-TIMD, or CIIM-TM; or wherein the BCW comprises a BCW index derived from a TM; or wherein the MMVD includes TM-based reordering for the MMVD; or The IBC comprises at least one of the following: IBC-TM, IBC with block vector difference, IBC with reconstruction reordering; or wherein the affine comprises at least one of the following: affine-MMVD, TM-based reordering for affine MMVD; or The GPM includes at least one of the following: GPM-TM, GPM-MMVD, GPM-Intra.

24. The method of claim 1, wherein a method of obtaining a prediction for a first component of the video unit is the same as a method of obtaining a prediction for a second component.

25. The method of claim 24, wherein whether and / or how the prediction of the first component is obtained using the same method as for the second component depends on whether a single tree or a dual tree is used.

26. The method of claim 25, wherein when the single tree is used, the prediction of the first component is obtained using the same method as the second component.

27. The method of claim 24, wherein the prediction of the first component is obtained using a specific prediction method other than IBC-GPM.

28. The method of claim 1, wherein prediction of an area along an edge of a geometric partition of the video unit is obtained by combining predictions of two sub-partitions of the video unit.

29. The method of claim 28, wherein weights used to combine the predictions are derived on the fly or predefined.

30. The method of claim 28, wherein a weight used to combine the predictions depends on the distances of combined samples to the edges of the geometric partitions.

31. The method of claim 28, wherein a width of the region is indicated.

32. The method of claim 28, wherein the determination of the region depends on codec information.

33. The method of claim 1, wherein codec information of the video unit using IBC-GPM codec is stored and used by at least one of: one or more subsequent video units in a current picture, or one or more video units in one or more subsequent pictures.

34. The method according to claim 33, wherein the codec information refers to at least one of the following: Block Vector (BV), Intra prediction mode, or Motion vector.

35. The method of claim 33, wherein one or more BVs are used to construct a merge candidate list or an AMVP candidate list for one or more subsequent video units, or The one or more BVs are inserted into a historical BV buffer for future reference.

36. The method of claim 35, wherein one or more BVs in a subpartition having a larger size than other subpartitions are used.

37. The method of claim 35, wherein one or more BVs in the first sub-partition are used, or One or more BVs in the last subpartition are used.

38. The method of claim 35, wherein none of the BV in the IBC-GPM is permitted to be used.

39. The method of claim 33, wherein one or more IPMs are used to construct a list of MPMs for subsequent video units, or wherein the one or more IPMs are stored in an IPM buffer, or The one or more IPMs are used for chrominance prediction.

40. The method of claim 39, wherein one or more IPMs in a subpartition having a larger size than other subpartitions are used.

41. The method of claim 39, wherein one or more IPMs in the first sub-partition are used, or One or more IPMs in the last sub-partition are used.

42. The method of claim 39, wherein no IPM in the IBC-GPM is permitted to be used.

43. The method of claim 42, wherein a default IPM is used.

44. The method of claim 33, wherein one or more motion vectors (MVs) are used to construct at least one of: a merge candidate list or an AMVP candidate list for a subsequent video unit, or The one or more MVs are stored in a motion information buffer.

45. The method of claim 44, wherein one or more MVs in a subpartition having a larger size than other subpartitions are used.

46. ​​The method of claim 44, wherein one or more MVs in the first sub-partition are used, or One or more MVs in the last sub-partition are used.

47. The method of claim 44, wherein no MVs in the IBC-GPM are allowed to be used.

48. The method of claim 47, wherein motion information for the video unit is set equal to IBC mode.

49. The method of claim 1, wherein the determination of whether the video unit is allowed to be encoded using IBC-GPM mode depends on codec information.

50. The method according to claim 49, wherein the codec information comprises at least one of the following: Whether the IBC merge mode is allowed, Is the IBC AMVP mode allowed? Block size, Block size, the depth of the video unit, Block location, Strip type, Image type, Time layer information, or Color component information.

51. The method of claim 1, wherein the indication of the IBC-GPM is signaled based on a condition, wherein the condition comprises: Whether the IBC merge mode is allowed, Is the IBC AMVP mode allowed? Block size, Block size, the depth of the video unit, Strip type, Image type, Partition tree type, block location, or Color components.

52. The method of claim 1, wherein whether and / or how to apply IBC-GPM to the video unit is indicated in the bitstream.

53. The method of claim 52, wherein whether IBC-GPM is enabled for the video unit is indicated using one or more syntax elements.

54. The method of claim 53, wherein a syntax element is used to indicate whether IBC-GPM is applied to the video unit, and / or The one or more syntax elements are used to indicate whether IBC AMVP or IBC merge is used to obtain the prediction.

55. The method of claim 53, wherein a syntax element is used to indicate whether an IBC merge mode is used in an IBC-GPM.

56. The method of claim 53, wherein a syntax element is used to indicate whether the IBC AMVP mode is used in the IBC-GPM.

57. The method of claim 52, wherein how and whether the video unit is divided into a plurality of sub-partitions is predefined, or wherein how and whether to divide the video unit into the plurality of sub-partitions is derived, or How and whether the video unit is divided into the plurality of sub-partitions is signaled in the bitstream.

58. The method of claim 57, wherein syntax elements are signaled to indicate a method of partitioning the video unit.

59. The method of claim 57, wherein one or more syntax elements are used to indicate a method of obtaining the prediction for each sub-partition.

60. The method of claim 52, wherein a syntax element indicating which IPM in an IPM candidate list is used to obtain the intra prediction for one or more subpartitions is indicated.

61. The method of claim 52, wherein a method of combining the predictions using the multiple sub-partitions of the video unit is indicated in the bitstream.

62. The method of claim 61, wherein a syntax element indicative of the combining width is indicated.

63. A method according to any one of claims 52 to 53, wherein the syntax elements are binarized using a fixed length codec, or wherein the syntax element is a truncated unary codec, or wherein the syntax element is a unary codec, or Wherein the syntax element is EG codec, or wherein the syntax element is encoded as a flag, or wherein the syntax element is bypassed for coding, or The syntax elements are context encoded.

64. The method of claim 63, wherein the context depends on codec information.

65. The method according to claim 64, wherein the codec information comprises at least one of the following: Block size, Block size, Strip type, Image type, Information about neighboring blocks, Information about other codecs for the video unit, or Time layer information.

66. The method of any one of claims 52 to 53, wherein the syntax element is indicated at one of: Sequence header, Picture header, Sequence Parameter Set (SPS), Video Parameter Set (VPS), Dependency Parameter Set (DPS), Decoding Capability Information (DCI), Picture Parameter Set (PPS), Adaptive Parameter Set (APS), Strip header, or Tile group header.

67. The method of claim 1, wherein IBC-GPM and GPM share a signaling method for at least one syntax element.

68. The method of any one of claims 1 to 67, wherein the video unit comprises at least one of: Color components, Prediction Block (PB), Transform Block (TB), Codec Block (CB), Prediction Unit (PU), Transformation Unit (TU), Codec Tree Block (CTB), Codec Unit (CU), Codec Tree Unit (CTU), CTU line, CTU group, Strips, Tile, Sub-picture, piece, a sub-region within a block, or An area that contains more than one sample or pixel.

69. The method of any one of claims 1 to 67, wherein an indication of whether and / or how to obtain the prediction of at least one object of the video unit by using IBC is indicated at one of: Sequence level, Picture group level, Picture level, Stripe level, or Tile group level.

70. The method of any one of claims 1 to 67, wherein the indication of whether and / or how to obtain the prediction of at least one object of the video unit by using IBC is indicated in one of: Sequence header, Picture header, Sequence Parameter Set (SPS), Video Parameter Set (VPS), Dependency Parameter Set (DPS), Decoding Capability Information (DCI), Picture Parameter Set (PPS), Adaptive Parameter Set (APS), Strip header, or Tile group header.

71. The method of any one of claims 1 to 67, wherein the indication of whether and / or how to obtain the prediction of at least one object of the video unit by using IBC is comprised in one of: Prediction Block (PB), Transform Block (TB), Codec Block (CB), Prediction Unit (PU), Transformation Unit (TU), Codec Unit (CU), Virtual Pipeline Data Unit (VPDU), Codec Tree Unit (CTU), CTU line, Strips, Tile, sub-image, or An area that contains more than one sample or pixel.

72. The method of any one of claims 1 to 67, further comprising: determining whether and / or how to obtain the prediction of at least one object of the video unit by using IBC based on codec information of the video unit, the codec information comprising at least one of the following: Block size, Color format, Single-tree and / or dual-tree partitioning, Color components, Strip type, or Image type.

73. The method of any one of claims 1 to 72, wherein the converting comprises encoding the video unit into the bitstream.

74. The method of any one of claims 1 to 72, wherein the converting comprises decoding the video unit from the bitstream.

75. An apparatus for video processing, comprising a processor and a non-volatile memory having instructions thereon, wherein the instructions, when executed by the processor, cause the processor to perform the method of any one of claims 1 to 74.

76. A non-transitory computer readable storage medium storing instructions that cause a processor to perform the method of any one of claims 1 to 74.

77. A non-transitory computer-readable recording medium storing a bitstream of a video generated by a method performed by an apparatus for video processing, wherein the method comprises: obtaining a prediction of at least one object of a video unit of the video by using intra block copy (IBC), wherein the video unit is encoded or decoded using an IBC-geometric partitioning mode (GPM) in which the video unit is geometrically divided into a plurality of sub-partitions or the video unit is predicted by a plurality of hypotheses; and The bitstream is generated based on the prediction of the at least one object of the video unit.

78. A method for storing a bitstream of a video, comprising: obtaining a prediction of at least one object of a video unit of the video by using intra block copy (IBC), wherein the video unit is encoded or decoded using an IBC-geometric partitioning mode (GPM) in which the video unit is geometrically divided into a plurality of sub-partitions or the video unit is predicted by a plurality of hypotheses; generating the bitstream based on the prediction of the at least one object of the video unit; as well as The bit stream is stored in a non-transitory computer-readable recording medium.