Inter prediction in video coding
By introducing a bilateral matching AMVP merging mode in video encoding and decoding, using the motion vector candidate list of multiple reference picture lists for merging and selecting, the challenge of improving inter prediction efficiency in the existing technology is solved, and more efficient video programming is achieved Decode compression.
Patent Information
- Application Number
- CN202380027887.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2022-03-14
- Filing Date
- 2023-03-14
- Publication Date
- 2024-11-15
AI Technical Summary
Existing video encoding and decoding standards such as HEVC have room for improvement in compression efficiency. Especially in the development of the new generation of video encoding and decoding standard VVC, how to further improve the encoding and decoding efficiency of inter-frame prediction has become a challenge.
A bilateral matching AMVP merge mode is proposed. By enabling advanced motion vector prediction (AMVP)-merge mode for the current picture or strip in the video decoding and encoding method, using the motion vector candidate list in multiple reference picture lists for Merge and select to improve the accuracy and efficiency of inter-frame prediction.
Through bilateral matching AMVP merge mode, the compression efficiency of video encoding and decoding is significantly improved, the accuracy of inter-frame prediction is enhanced, and the video quality can be maintained or improved at lower bit rates.
Smart Images

Figure CN118975245A_ABST
Abstract
Description
[0001] CROSS-REFERENCE TO RELATED APPLICATIONS
[0002] This application is based on U.S. Provisional Application No. 63 / 319,763, entitled “Inter-frame Prediction in Video Coding and Decoding,” filed on March 14, 2022, and claims priority to the provisional application, the entire contents of which are incorporated herein by reference for reference. Technical Field
[0003] The present disclosure relates to video coding and compression, and in particular, but not limited to, methods and apparatus for inter-frame prediction in video coding. Background Art
[0004] Various video codec technologies can be used to compress video data. Video coding and decoding are performed according to one or more video codec standards. For example, some currently known video codec standards include Versatile Video Codec (VVC), High Efficiency Video Codec (HEVC, also known as H.265 or MPEG-H Part2), and Advanced Video Codec (AVC, also known as H.264 or MPEG-4 Part 10), which are jointly developed by ISO / IEC MPEG and ITU-T VECG. AOMedia Video 1 (AV1) was developed by the Alliance for Open Media (AOM) as a successor to its predecessor standard VP9. Audio and Video Codec (AVS) refers to digital audio and digital video compression standards, and is another video compression standard series developed by the Chinese Audio and Video Codec Standard Working Group. Most of the existing video codec standards are built on the well-known hybrid video codec framework, that is, using block-based prediction methods (e.g., inter-frame prediction, intra-frame prediction) to reduce the redundancy present in video images or sequences, and using transform coding to compress the energy of prediction errors. An important goal of video coding technology is to compress video data into a form that uses a lower bit rate while avoiding or minimizing the degradation of video quality.
[0005] The first version of the HEVC standard was completed in October 2013, and it provides about 50% bitrate savings or equivalent perceptual quality compared to the previous generation video codec standard H.264 / MPEG AVC. Although the HEVC standard provides significant codec improvements over its predecessor, there is evidence that codec efficiency superior to HEVC can be achieved using additional codec tools. Based on this, both VCEG and MPEG have begun exploring new codec technologies for future video codec standardization. In October 2015, ITU-T VECG and ISO / IEC MPEG established a Joint Video Exploration Team (JVET) to begin in-depth research on advanced technologies that can significantly improve codec efficiency. JVET maintains a reference software called the Joint Exploration Test Model (JEM) by integrating several additional codec tools on top of the HEVC Test Model (HM).
[0006] In October 2017, ITU-T and ISO / IEC issued a joint call for proposals (CfP) on video compression with capabilities beyond HEVC. In April 2018, the 10th JVET meeting received and evaluated 23 CfP responses, and the results showed that the compression efficiency was improved by about 40% over HEVC. Based on such evaluation results, JVET launched a new project to develop a new generation of video codec standards, which is called the Versatile Video Codec (VVC). In the same month, a reference software code base, called the VVC Test Model (VTM), was established to demonstrate the reference implementation of the VVC standard.
[0007] In addition, ITU-T VCEG (Q6 / 16) and ISO / IEC MPEG (JTC 1 / SC 29 / WG 11) are studying the potential need for standardization of future video codec technologies that would have compression capabilities significantly beyond the current VVC standard. This future standardization action could take the form of additional extensions to VVC or an entirely new standard. The Joint Video Exploration Team (JVET) is conducting this exploratory activity to evaluate compression technology designs proposed by their experts in the field. The first Exploration Experiment (EE) was established at the JVET meeting from January 6 to 15, 2021, and the exploratory software model was named the Enhanced Compression Model (ECM), with ECM version 2 (ECM2) released in August 2021. Summary of the invention
[0008] The present disclosure provides a technical example related to inter-frame prediction in video coding and decoding, and more specifically, provides a technical example related to the bilateral matching AMVP merge mode in ECM.
[0009] According to a first aspect of the present disclosure, a video decoding method is provided. In the video decoding method, a decoder may determine to enable an advanced motion vector prediction (AMVP)-merge (AM) mode for a current picture or a slice of a current picture. In addition, the decoder may obtain an AMVP motion vector (MV) of a current block in the current picture as an LX MV for a first reference picture list LX, where X is 0 or 1. In addition, the decoder may obtain a valid merge MV candidate list for a second reference picture list L(1-X), where the valid merge MV candidate list includes merge candidates having an L(1-X) MV. Further, the decoder may select an L(1-X) MV of the AM mode in the valid merge MV candidate list.
[0010] According to a second aspect of the present disclosure, a video encoding method is provided. In the video encoding method, an encoder may determine that an advanced motion vector prediction (AMVP)-merge (AM) mode has been enabled for a current picture or a slice of the current picture. In addition, the encoder may obtain an AMVP motion vector (MV) of a current block in the current picture as an LX MV for a first reference picture list LX, where X is 0 or 1. In addition, the encoder may obtain a valid merge MV candidate list for a second reference picture list L(1-X), where the valid merge MV candidate list includes a merge candidate with an L(1-X) MV. Further, the encoder may select the L(1-X) MV of the AM mode in the valid merge MV candidate list.
[0011] According to a third aspect of the present disclosure, a video decoding device is provided. The device includes: one or more processors; and a memory coupled to the one or more processors and configured to store instructions executable by the one or more processors. In addition, when executing the instructions, the one or more processors are configured to perform the method according to the first aspect above.
[0012] According to a fourth aspect of the present disclosure, a video encoding device is provided. The device includes: one or more processors; and a memory coupled to the one or more processors and configured to store instructions executable by the one or more processors. In addition, when executing the instructions, the one or more processors are configured to execute the method according to the second aspect above.
[0013] According to a fifth aspect of the present disclosure, a non-transitory computer-readable storage medium is provided for storing computer-executable instructions. When the computer-executable instructions are executed by one or more computer processors, the one or more computer processors receive a bit stream and execute the method according to the first aspect based on the bit stream.
[0014] According to a sixth aspect of the present disclosure, a non-transitory computer-readable storage medium is provided for storing computer-executable instructions. When the computer-executable instructions are executed by one or more computer processors, the one or more computer processors execute the method according to the second aspect to encode the current block into a bit stream and transmit the bit stream. BRIEF DESCRIPTION OF THE DRAWINGS
[0015] Examples of the present disclosure will be described in more detail with reference to specific examples shown in the accompanying drawings. Given that these drawings depict only a few examples and are not to be considered limiting in scope, these examples will be described and explained with additional specificity and detail through use of the accompanying drawings.
[0016] Figure 1A is a block diagram illustrating a system for encoding and decoding video blocks according to some examples of the present disclosure.
[0017] Figure 1B is a block diagram illustrating an encoder according to some examples of the present disclosure.
[0018] Figure 1C to Figure 1F is a block diagram showing how a frame may be recursively partitioned into multiple video blocks of different sizes and shapes according to some examples of the present disclosure.
[0019] Figure 1G is a block diagram illustrating an exemplary video encoder according to some examples of the present disclosure.
[0020] Figure 2A is a block diagram of a decoder according to some examples of the present disclosure.
[0021] Figure 2B is a block diagram illustrating an exemplary video decoder according to some examples of the present disclosure.
[0022] Figure 3A is a diagram illustrating block partitioning in a multi-type tree structure according to some examples of the present disclosure.
[0023] Figure 3B is a diagram illustrating block partitioning in a multi-type tree structure according to some examples of the present disclosure.
[0024] Figure 3C is a diagram illustrating block partitioning in a multi-type tree structure according to some examples of the present disclosure.
[0025] Figure 3D is a diagram illustrating block partitioning in a multi-type tree structure according to some examples of the present disclosure.
[0026] Figure 3E is a diagram illustrating block partitioning in a multi-type tree structure according to some examples of the present disclosure.
[0027] Figure 4A The locations of spatial merging candidates according to some examples of the present disclosure are shown.
[0028] Figure 4B Candidate pairs for redundancy checking of spatial merging candidates according to some examples of the present disclosure are shown.
[0029] Figure 4C Motion vector scaling of temporal merging candidates according to some examples of the present disclosure is shown.
[0030] Figure 4D Candidate positions of temporal merging candidates C0 and C1 according to some examples of the present disclosure are shown.
[0031] Figure 5 MMVD search points according to some examples of the present disclosure are shown.
[0032] Figure 6 A computing environment according to some examples of the present disclosure is shown.
[0033] Figure 7 is a flowchart illustrating a video decoding method according to some examples of the present disclosure.
[0034] Figure 8 is a diagram showing some examples according to the present disclosure, Figure 7 The video decoding method shown is a flowchart of a video encoding method corresponding to the video decoding method. DETAILED DESCRIPTION
[0035] Reference will now be made in detail to specific embodiments, examples of which are shown in the accompanying drawings. In the following detailed description, a number of non-limiting specific details are set forth to aid in understanding the subject matter presented herein. However, various alternatives may be used without departing from the scope of the claims, and the subject matter may be practiced without these specific details. For example, the subject matter presented herein may be implemented on many types of electronic devices having digital video capabilities.
[0036] The terms used in this disclosure are only used to describe specific embodiments and are not intended to limit the present disclosure. The singular forms "a", "the" and "the" in the present disclosure and the appended claims are also intended to include plural forms, unless otherwise clearly indicated throughout the present disclosure. It should also be understood that the term "and / or" used in this disclosure refers to and includes one or any or all possible combinations of the listed multiple related items.
[0037] In this specification, references to "one embodiment", "an embodiment", "an example", "some embodiments", "some examples" or similar language mean that the specific features, structures or characteristics described are included in at least one embodiment or example. Features, structures, elements or characteristics related to one or some embodiments are also applicable to other embodiments unless otherwise explicitly stated.
[0038] Throughout the disclosure, the terms "first", "second", "third", etc. are used only as names for related elements (e.g., devices, components, compositions, steps, etc.), and do not imply any spatial or temporal order, unless otherwise explicitly specified. For example, "first device" and "second device" may refer to two separately formed devices, or two parts, components, or operating states of the same device, and may be named arbitrarily.
[0039] The terms "module", "sub-module", "circuit", "sub-circuit", "circuitry", "sub-circuitry", "unit", or "sub-unit" may include a memory (shared, dedicated, or group) that stores code or instructions that can be executed by one or more processors. A module may include one or more circuits with or without stored code or instructions. A module or circuit may include one or more directly or indirectly connected components. These components may or may not be physically connected to or adjacent to each other.
[0040] As used herein, the terms "if" or "when" may be understood as "when..." or "in response to..." depending on the context. If these terms appear in a claim, it may not indicate that the related limitation or feature is conditional or optional. For example, a method may include the following steps: i) when condition X exists or if condition X exists, perform function or action X', and ii) when condition Y exists or if condition Y exists, perform function or action Y'. The method may be implemented with both the ability to perform function or action X' and the ability to perform function or action Y'. Therefore, functions X' and Y' may be performed at different times in multiple executions of the method.
[0041] A unit or module may be implemented by pure software, pure hardware, or a combination of hardware and software. In a pure software implementation, for example, a unit or module may include functionally related code blocks or software components that are linked together directly or indirectly to perform a specific function.
[0042] Figure 1A is a block diagram illustrating an exemplary system 10 for encoding and decoding video blocks in parallel according to some embodiments of the present disclosure. Figure 1AAs shown in , system 10 includes a source device 12 that generates and encodes video data to be later decoded by a destination device 14. Source device 12 and destination device 14 may include any of a wide variety of electronic devices, including desktop or laptop computers, tablet computers, smart phones, set-top boxes, digital televisions, cameras, display devices, digital media players, video game consoles, video streaming devices, etc. In some implementations, source device 12 and destination device 14 are equipped with wireless communication capabilities.
[0043] In some embodiments, the target device 14 may receive the encoded video data to be decoded via the link 16. The link 16 may include any type of communication medium or device capable of moving the encoded video data from the source device 12 to the target device 14. In one example, the link 16 may include a communication medium that enables the source device 12 to directly send the encoded video data to the target device 14 in real time. The encoded video data may be modulated according to a communication standard (e.g., a wireless communication protocol) and sent to the target device 14. The communication medium may include any wireless or wired communication medium, such as a radio frequency (RF) spectrum or one or more physical transmission lines. The communication medium may form a portion of a packet-based network (e.g., a local area network, a wide area network, or a global network such as the Internet). The communication medium may include a router, a switch, a base station, or any other device that may be beneficial to facilitate communication from the source device 12 to the target device 14.
[0044] In some other embodiments, the encoded video data may be sent from the output interface 22 to the storage device 32. The encoded video data in the storage device 32 may then be accessed by the target device 14 via the input interface 28. The storage device 32 may include any of a variety of distributed or locally accessed data storage media, such as a hard drive, a Blu-ray disc, a digital versatile disc (DVD), a compact disc read-only memory (CD-ROM), a flash memory, a volatile or non-volatile memory, or any other suitable digital storage medium for storing encoded video data. In another example, the storage device 32 may correspond to a file server or another intermediate storage device that may hold the encoded video data generated by the source device 12. The target device 14 may access the stored video data from the storage device 32 via streaming or downloading. The file server may be any type of computer capable of storing encoded video data and sending the encoded video data to the target device 14. Exemplary file servers include a network server (e.g., for a website), a file transfer protocol (FTP) server, a network attached storage (NAS) device, or a local disk drive. Target device 14 may access the encoded video data through any standard data connection suitable for accessing encoded video data stored on a file server, including a wireless channel (e.g., a Wireless Fidelity (Wi-Fi) connection), a wired connection (e.g., a Digital Subscriber Line (DSL), a cable modem, etc.), or a combination of both wireless channels and wired connections. The transmission of the encoded video data from storage device 32 may be a streaming transmission, a download transmission, or a combination of both streaming and download transmissions.
[0045] like Figure 1A As shown in , source device 12 includes video source 18, video encoder 20 and output interface 22. Video source 18 may include sources such as or a combination of such sources: a video capture device (e.g., a camera), a video archive containing previously captured video, a video feed interface for receiving video from a video content provider, and / or a computer graphics system for generating computer graphics data as source video. As an example, if video source 18 is a camera of a security monitoring system, source device 12 and target device 14 may form a camera phone or a video phone. However, the embodiments described in this application may be generally applicable to video encoding and decoding, and may be applied to wireless and / or wired applications.
[0046] The captured, pre-captured, or computer-generated video may be encoded by the video encoder 20. The encoded video data may be sent directly to the target device 14 via the output interface 22 of the source device 12. The encoded video data may also (or alternatively) be stored on a storage device 32 for later access by the target device 14 or other device for decoding and / or playback. The output interface 22 may further include a modem and / or a transmitter.
[0047] Target device 14 includes input interface 28, video decoder 30, and display device 34. Input interface 28 may include a receiver and / or a modem and receives encoded video data via link 16. The encoded video data transmitted via link 16 or provided on storage device 32 may include various syntax elements generated by video encoder 20 for use by video decoder 30 in decoding the video data. Such syntax elements may be included within the encoded video data sent over a communication medium, stored on a storage medium, or stored on a file server.
[0048] In some implementations, the target device 14 may include a display device 34, which may be an integrated display device and an external display device configured to communicate with the target device 14. The display device 34 displays the decoded video data to a user and may include any of a variety of display devices, such as a liquid crystal display (LCD), a plasma display, an organic light emitting diode (OLED) display, or another type of display device.
[0049] The video encoder 20 and the video decoder 30 can operate according to a proprietary standard or an industry standard (e.g., VVC, HEVC, Part 10 of MPEG-4, AVC) or an extension of such a standard. It should be understood that the present application is not limited to a specific video encoding / decoding standard and can be applied to other video encoding / decoding standards. It is generally believed that the video encoder 20 of the source device 12 can be configured to encode the video data according to any of these current standards or future standards. Similarly, it is also generally believed that the video decoder 30 of the target device 14 can be configured to decode the video data according to any of these current standards or future standards.
[0050] The video encoder 20 and the video decoder 30 may be implemented as any of a variety of suitable encoder and / or decoder circuits, such as one or more microprocessors, digital signal processors (DSPs), application specific integrated circuits (ASICs), field programmable gate arrays (FPGAs), discrete logic devices, software, hardware, firmware, or any combination thereof. When partially implemented in software, the electronic device may store instructions for the software in a suitable non-transitory computer-readable medium, and use one or more processors to execute the instructions in the hardware to perform the video encoding / decoding operations disclosed in the present disclosure. Each of the video encoder 20 and the video decoder 30 may be included in one or more encoders or decoders, and either of the encoders or decoders may be integrated as part of a combined encoder / decoder (CODEC) in the corresponding device.
[0051] Like HEVC, VVC is built on a block-based hybrid video codec framework. Figure 1B 1 is a block diagram illustrating a block-based video encoder according to some embodiments of the present disclosure. In the encoder 100, the input video signal is processed block by block, called a coding unit (CU). The encoder 100 may be as follows: Figure 1A Video encoder 20 shown. In VTM-1.0, a CU can be up to 128x128 pixels. However, unlike HEVC, which partitions blocks based only on quadtrees, in VVC, a coding tree unit (CTU) is split into CUs to accommodate different local features based on quadtrees / binary trees / ternary trees. In addition, the concept of multiple partition unit types in HEVC is deleted, that is, there is no separation of CUs, prediction units (PUs), and transform units (TUs) in VVC; instead, each CU is always used as the basic unit for prediction and transformation without further partitioning. In the multi-type tree structure, a CTU is first partitioned by a quadtree structure. Then, each quadtree leaf node can be further partitioned by a binary tree structure and a ternary tree structure.
[0052] FIG. 3A to FIG. 3E is a schematic diagram illustrating multiple types of tree splitting modes according to some embodiments of the present disclosure. FIG. 3A to FIG. 3E Five split types are shown, including four-way split ( Figure 3A ), vertical binary segmentation ( Figure 3B ), horizontal binary segmentation ( Figure 3C ), vertical expansion of the three-way split ( Figure 3D ) and horizontally extended ternary split ( Figure 3E ).
[0053] For each given video block, spatial prediction and / or temporal prediction can be performed. Spatial prediction (or "intra-frame prediction") uses pixels from samples of neighboring blocks that have been encoded in the same video picture / fragment (called reference samples) to predict the current video block. Spatial prediction reduces the spatial redundancy inherent in the video signal. Temporal prediction (also known as "inter-frame prediction" or "motion compensated prediction") uses reconstructed pixels from an already encoded video picture to predict the current video block. Temporal prediction reduces the temporal redundancy inherent in the video signal. The temporal prediction signal for a given CU is typically signaled by one or more motion vectors (MVs) that indicate the amount and direction of motion between the current CU and its temporal reference. In addition, if multiple reference pictures are supported, a reference picture index is also sent to identify which reference picture in the reference picture storage the temporal prediction signal comes from.
[0054] After spatial and / or temporal prediction, an intra / inter mode decision circuit 121 in the encoder 100 selects the best prediction mode, for example based on a rate-distortion optimization method. The block prediction value 120 is then subtracted from the current video block; and the resulting prediction residual is decorrelated using the transform circuit 102 and the quantization circuit 104. The resulting quantized residual coefficients are dequantized by the dequantization circuit 116 and inversely transformed by the inverse transform circuit 118 to form a reconstructed residual, which is then added back to the predicted block to form a reconstructed signal for the CU. In addition, before the reconstructed CU is placed in the reference picture memory of the picture buffer 117 and used to encode future video blocks, loop filtering 115, such as a deblocking filter, sample adaptive offset (SAO) and / or adaptive loop filter (ALF), can be applied to the reconstructed CU. In order to form an output video bitstream 114, the coding mode (inter or intra), prediction mode information, motion information, and quantized residual coefficients are all sent to the entropy coding unit 106 for further compression and packaging to form a bitstream.
[0055] For example, in the current versions of AVC, HEVC, and VVC, a deblocking filter is available. In HEVC, an additional loop filter called SAO is defined to further improve coding efficiency. In the current version of the VVC standard, another loop filter called ALF is being actively studied and it is likely to be included in the final standard.
[0056] These loop filter operations are optional. Performing these operations helps improve coding efficiency and visual quality. They can also be turned off as a decision made by the encoder 100 to save computational complexity.
[0057] It should be noted that intra prediction is typically based on unfiltered reconstructed pixels, while inter prediction is based on filtered reconstructed pixels (if the encoder 100 has these filtering options turned on).
[0058] Figure 2A is a block diagram showing a block-based video decoder 200 that can be used in conjunction with many video codec standards. The decoder 200 is similar to Figure 1B The block-based video decoder 200 may be as follows: Figure 1A The video decoder 30 shown. In the decoder 200, the incoming video bitstream 201 is first decoded by entropy decoding 202 to obtain the quantization coefficient levels and prediction related information. The quantization coefficient levels are then processed by inverse quantization 204 and inverse transform 206 to obtain reconstructed prediction residuals. The block prediction value mechanism implemented in the intra / inter mode selector 212 is configured to perform intra prediction 208 or motion compensation 210 based on the decoded prediction information. A set of unfiltered reconstructed pixels is obtained by adding the reconstructed prediction residual from the inverse transform 206 to the prediction output generated by the block prediction value mechanism using an adder 214.
[0059] The reconstructed block may further pass through a loop filter 209 before being stored in a picture buffer 213 used as a reference picture memory. The reconstructed video in the picture buffer 213 may be sent to drive a display device and used to predict future video blocks. When the loop filter 209 is turned on, a filtering operation is performed on these reconstructed pixels to obtain a final reconstructed video output 222.
[0060] Figure 1G is a block diagram illustrating another exemplary video encoder 20 according to some embodiments described in the present application. The video encoder 20 can perform intra-frame prediction coding and inter-frame prediction coding on video blocks within a video frame. Intra-frame prediction coding relies on spatial prediction to reduce or remove spatial redundancy in video data within a given video frame or picture. Inter-frame prediction coding relies on temporal prediction to reduce or remove temporal redundancy in video data within adjacent video frames or pictures of a video sequence. It should be noted that in the field of video coding and decoding, the term "frame" can be used as a synonym for the term "image" or "picture".
[0061] like Figure 1GAs shown, the video encoder 20 includes a video data memory 40, a prediction processing unit 41, a decoded picture buffer (DPB) 64, an adder 50, a transform processing unit 52, a quantization unit 54, and an entropy coding unit 56. The prediction processing unit 41 further includes a motion estimation unit 42, a motion compensation unit 44, a segmentation unit 45, an intra-frame prediction processing unit 46, and an intra-frame block copy (BC) unit 48. In some embodiments, the video encoder 20 also includes an inverse quantization unit 58, an inverse transform processing unit 60, and an adder 62 for video block reconstruction. A loop filter 63 such as a deblocking filter can be located between the adder 62 and the DPB 64 to filter the block boundary to remove the block effect from the reconstructed video. In addition to the deblocking filter, another loop filter (e.g., a sample adaptive offset (SAO) filter and / or an adaptive loop filter (ALF)) can also be used to filter the output of the adder 62. In some examples, the loop filter can be omitted, and the decoded video block can be directly provided to the DPB 64 by the adder 62. Video encoder 20 may take the form of a fixed or programmable hardware unit, or may be distributed among one or more of the illustrated fixed or programmable hardware units.
[0062] Video data memory 40 may store video data to be encoded by components of video encoder 20. Figure 1A The video source 18 shown obtains video data in the video data memory 40. The DPB 64 is a buffer that stores reference video data (e.g., reference frames or pictures) for use by the video encoder 20 (e.g., in intra-frame or inter-frame prediction coding mode) when encoding the video data. The video data memory 40 and the DPB 64 can be formed by any of a variety of memory devices. In various examples, the video data memory 40 can be on-chip with other components of the video encoder 20, or off-chip relative to those components.
[0063] like Figure 1GAs shown, after receiving the video data, the segmentation unit 45 within the prediction processing unit 41 segments the video data into video blocks. This segmentation may also include segmenting the video frame into strips, tiles (e.g., a set of video blocks) or other larger coding units (CUs) according to a predefined splitting structure (e.g., a quadtree (QT) structure) associated with the video data. A video frame is or may be considered as a two-dimensional sample array or matrix with sample values. The samples in the array may also be referred to as pixels or picture elements (pel). The number of samples in the horizontal and vertical directions (or axes) of the array or picture defines the size and / or resolution of the video frame. For example, a video frame may be divided into a plurality of video blocks by using QT segmentation. A video block is or may be considered as a two-dimensional sample array or matrix with sample values again, but its dimension is smaller than the dimension of a video frame. The number of samples in the horizontal and vertical directions (or axes) of a video block defines the size of the video block. By, for example, iteratively using QT segmentation, binary tree (BT) segmentation, or ternary tree (TT) segmentation, or any combination thereof, a video block may be further segmented into one or more block partitions or sub-blocks (which may form blocks again). It should be noted that the term "block" or "video block" used herein may be a portion of a frame or picture, in particular a rectangular (square or non-square) portion. With reference to, for example, HEVC and VVC, a block or video block may be or correspond to a coding tree unit (CTU), a CU, a prediction unit (PU) or a transform unit (TU) and / or may be or correspond to a corresponding block (e.g., a coding tree block (CTB), a coding block (CB), a prediction block (PB) or a transform block (TB)) and / or a sub-block.
[0064] The prediction processing unit 41 may select one of a plurality of feasible prediction coding modes for the current video block based on the error results (e.g., coding rate and distortion level), such as one of one or more inter-frame prediction coding modes in a plurality of intra-frame prediction coding modes. The prediction processing unit 41 may provide the resulting intra-frame prediction coding block or inter-frame prediction coding block to the adder 50 to generate a residual block, and to the adder 62 to reconstruct the coding block for subsequent use as part of a reference frame. The prediction processing unit 41 also provides syntax elements (e.g., motion vectors, intra-frame mode indicators, partition information, and other such syntax information) to the entropy coding unit 56.
[0065] To select an appropriate intra-prediction coding mode for the current video block, intra-prediction processing unit 46 within prediction processing unit 41 may perform intra-prediction coding of the current video block in relation to one or more neighboring blocks in the same frame as the current block to be encoded to provide spatial prediction. Motion estimation unit 42 and motion compensation unit 44 within prediction processing unit 41 may perform inter-prediction coding of the current video block in relation to one or more prediction blocks in one or more reference frames to provide temporal prediction. Video encoder 20 may perform multiple encoding passes, for example, to select an appropriate coding mode for each block of video data.
[0066] In some embodiments, motion estimation unit 42 determines an inter-prediction mode for a current video frame by generating a motion vector according to a predetermined pattern within a sequence of video frames, the motion vector indicating the displacement of a video block within the current video frame relative to a prediction block within a reference video frame. Motion estimation performed by motion estimation unit 42 is the process of generating a motion vector that estimates the motion of a video block. For example, a motion vector may indicate the displacement of a video block within a current video frame or picture relative to a prediction block within a reference frame associated with a current block being encoded within the current frame. The predetermined pattern may designate a video frame in a sequence as a P frame or a B frame. Intra BC unit 48 may determine a vector (e.g., a block vector) for intra BC coding in a manner similar to the motion vector determined by motion estimation unit 42 for inter prediction, or may utilize motion estimation unit 42 to determine a block vector.
[0067] In terms of pixel differences, the prediction block for the video block may be or may correspond to a block or reference block of a reference frame that is considered to closely match the video block to be encoded, and the pixel difference may be determined by the sum of absolute differences (SAD), the sum of squared differences (SSD), or other difference metrics. In some embodiments, the video encoder 20 may calculate values for sub-integer pixel positions of the reference frames stored in the DPB 64. For example, the video encoder 20 may interpolate values for quarter-pixel positions, eighth-pixel positions, or other fractional pixel positions of the reference frame. Thus, the motion estimation unit 42 may perform a motion search relative to full pixel positions and fractional pixel positions and output a motion vector with fractional pixel accuracy.
[0068] Motion estimation unit 42 calculates a motion vector for a video block in an inter-prediction coded frame by comparing the position of the video block to the position of a prediction block of a reference frame selected from a first reference frame list (list 0) or a second reference frame list (list 1), each of which identifies one or more reference frames stored in DPB 64. Motion estimation unit 42 sends the calculated motion vector to motion compensation unit 44 and then to entropy encoding unit 56.
[0069] The motion compensation performed by the motion compensation unit 44 may involve obtaining or generating a prediction block based on the motion vector determined by the motion estimation unit 42. After receiving the motion vector for the current video block, the motion compensation unit 44 may locate the prediction block pointed to by the motion vector in one of the reference frame lists, retrieve the prediction block from the DPB 64, and forward the prediction block to the adder 50. The adder 50 then forms a residual video block of pixel difference values by subtracting the pixel values of the prediction block provided by the motion compensation unit 44 from the pixel values of the current video block being encoded. The pixel difference values forming the residual video block may include luminance component differences or chrominance component differences or both. The motion compensation unit 44 may also generate syntax elements associated with the video block of the video frame for use by the video decoder 30 when decoding the video block of the video frame. The syntax elements may include, for example, syntax elements defining a motion vector for identifying a prediction block, any flag indicating a prediction mode, or any other syntax information described herein. It should be noted that the motion estimation unit 42 and the motion compensation unit 44 may be highly integrated, but are described separately for conceptual purposes.
[0070] In some embodiments, the intra BC unit 48 may generate vectors and obtain prediction blocks in a manner similar to that described above in conjunction with the motion estimation unit 42 and the motion compensation unit 44, but these prediction blocks are in the same frame as the current block being encoded, and these vectors are referred to as block vectors rather than motion vectors. Specifically, the intra BC unit 48 may determine the intra prediction mode to be used to encode the current block. In some examples, the intra BC unit 48 may encode the current block using various intra prediction modes, for example, during separate encoding passes, and test their performance through rate-distortion analysis. Next, the intra BC unit 48 may select a suitable intra prediction mode to use among the various tested intra prediction modes and generate an intra mode indicator accordingly. For example, the intra BC unit 48 may calculate rate-distortion values for the various tested intra prediction modes using rate-distortion analysis, and select an intra prediction mode with the best rate-distortion characteristic among the tested modes as a suitable intra prediction mode to use. The rate-distortion analysis generally determines the amount of distortion (or error) between a coded block and the original uncoded block that was encoded to produce the coded block, as well as the bit rate (i.e., the number of bits) used to produce the coded block. Intra BC unit 48 may calculate ratios based on the distortion and rate for the various coded blocks to determine which intra-prediction mode exhibits the best rate-distortion value for the block.
[0071] In other examples, intra BC unit 48 may use, in whole or in part, motion estimation unit 42 and motion compensation unit 44 to perform such functions for intra BC prediction in accordance with embodiments described herein. In either case, for intra block copying, the prediction block may be a block that is considered to closely match the block to be encoded in terms of pixel differences, which may be determined by SAD, SSD, or other difference metrics, and identifying the prediction block may include calculating values for sub-integer pixel positions.
[0072] Regardless of whether the prediction block is from the same frame according to intra-frame prediction or from a different frame according to inter-frame prediction, the video encoder 20 can form a residual video block by subtracting the pixel values of the prediction block from the pixel values of the current video block being encoded. The pixel difference values forming the residual video block may include both luma component differences and chroma component differences.
[0073] As an alternative to the inter-frame prediction performed by the motion estimation unit 42 and the motion compensation unit 44 or the intra-frame block copy prediction performed by the intra BC unit 48 as described above, the intra-frame prediction processing unit 46 can perform intra-frame prediction on the current video block. Specifically, the intra-frame prediction processing unit 46 can determine the intra-frame prediction mode for encoding the current block. To this end, the intra-frame prediction processing unit 46 can use various intra-frame prediction modes to encode the current block, for example, during separate encoding passes, and the intra-frame prediction processing unit 46 (or in some examples, the mode selection unit) can select a suitable intra-frame prediction mode from the tested intra-frame prediction modes to use. The intra-frame prediction processing unit 46 can provide information indicating the intra-frame prediction mode selected for the block to the entropy coding unit 56. The entropy coding unit 56 can encode the information indicating the selected intra-frame prediction mode into the bitstream.
[0074] After prediction processing unit 41 determines a prediction block for the current video block via inter-prediction or intra-prediction, adder 50 forms a residual video block by subtracting the prediction block from the current video block. The residual video data in the residual block may be included in one or more TUs and provided to transform processing unit 52. Transform processing unit 52 transforms the residual video data into residual transform coefficients using a transform (e.g., a discrete cosine transform (DCT) or a conceptually similar transform).
[0075] The transform processing unit 52 may send the resulting transform coefficients to a quantization unit 54. The quantization unit 54 quantizes the transform coefficients to further reduce the bit rate. The quantization process may also reduce the bit depth associated with some or all of the coefficients. The degree of quantization may be modified by adjusting a quantization parameter. In some examples, the quantization unit 54 may then perform a scan on the matrix including the quantized transform coefficients. Alternatively, the entropy coding unit 56 may perform the scan.
[0076] After quantization, entropy coding unit 56 entropy encodes the quantized transform coefficients into a video bitstream using, for example, context adaptive variable length coding (CAVLC), context adaptive binary arithmetic coding (CABAC), syntax-based context adaptive binary arithmetic coding (SBAC), probability interval partitioning entropy (PIPE) coding, or another entropy coding method or technique. The encoded bitstream may then be sent to a video bitstream such as a Figure 1A The video decoder 30 shown, or archived as Figure 1A The video frame may be stored in storage device 32 as shown for later transmission to or retrieval by video decoder 30. Entropy encoding unit 56 may also entropy encode motion vectors and other syntax elements for the current video frame being encoded.
[0077] Inverse quantization unit 58 and inverse transform processing unit 60 apply inverse quantization and inverse transform, respectively, to reconstruct the residual video block in the pixel domain for use in generating reference blocks for predicting other video blocks. As noted above, motion compensation unit 44 may generate a motion compensated prediction block from one or more reference blocks of a frame stored in DPB 64. Motion compensation unit 44 may also apply one or more interpolation filters to the prediction block to calculate sub-integer pixel values for use in motion estimation.
[0078] Adder 62 adds the reconstructed residual block to the motion compensated prediction block generated by motion compensation unit 44 to generate a reference block for storage in DPB 64. The reference block may then be used as a prediction block by intra BC unit 48, motion estimation unit 42, and motion compensation unit 44 to inter-predict another video block in a subsequent video frame.
[0079] Figure 2B 1 is a block diagram showing an exemplary video decoder 30 according to some embodiments of the present application. The video decoder 30 includes a video data memory 79, an entropy decoding unit 80, a prediction processing unit 81, an inverse quantization unit 86, an inverse transform processing unit 88, an adder 90, and a DPB 92. The prediction processing unit 81 further includes a motion compensation unit 82, an intra-frame prediction unit 84, and an intra-frame BC unit 85. The video decoder 30 may perform the above-mentioned Figure 1G The encoding process is substantially the inverse of the decoding process described with respect to video encoder 20. For example, motion compensation unit 82 may generate prediction data based on motion vectors received from entropy decoding unit 80, and intra-prediction unit 84 may generate prediction data based on intra-prediction mode indicators received from entropy decoding unit 80.
[0080] In some examples, units of the video decoder 30 may be tasked to perform embodiments of the present application. In addition, in some examples, embodiments of the present disclosure may be dispersed in one or more of the units of the video decoder 30. For example, the intra BC unit 85 may perform embodiments of the present application alone or in combination with other units of the video decoder 30 (e.g., the motion compensation unit 82, the intra prediction unit 84, and the entropy decoding unit 80). In some examples, the video decoder 30 may not include the intra BC unit 85, and the functions of the intra BC unit 85 may be performed by other components of the prediction processing unit 81 (e.g., the motion compensation unit 82).
[0081] The video data memory 79 may store video data, such as an encoded video bitstream, to be decoded by other components of the video decoder 30. The video data stored in the video data memory 79 may be obtained, for example, from the storage device 32, from a local video source (e.g., a camera), via a wired or wireless network communication of video data, or by accessing a physical data storage medium (e.g., a flash drive or hard disk). The video data memory 79 may include a coded picture buffer (CPB) that stores encoded video data from an encoded video bitstream. The DPB 92 of the video decoder 30 stores reference video data for use by the video decoder 30 when decoding the video data (e.g., in an intra-frame or inter-frame prediction coding mode). The video data memory 79 and the DPB 92 may be formed by any of a variety of memory devices, such as dynamic random access memory (DRAM) (including synchronous DRAM (SDRAM)), magnetoresistive RAM (MRAM), resistive RAM (RRAM), or other types of memory devices. For illustrative purposes, the video data memory 79 and the DPB 92 are shown in FIG. Figure 2B 9 as two different components of the video decoder 30. However, it will be apparent to those skilled in the art that the video data memory 79 and the DPB 92 can be provided by the same memory device or separate memory devices. In some examples, the video data memory 79 can be on-chip with other components of the video decoder 30, or off-chip relative to those components.
[0082] During the decoding process, the video decoder 30 receives an encoded video bitstream representing video blocks of an encoded video frame and associated syntax elements. The video decoder 30 may receive syntax elements at the video frame level and / or the video block level. The entropy decoding unit 80 of the video decoder 30 entropy decodes the bitstream to generate quantization coefficients, motion vectors or intra-frame prediction mode indicators, and other syntax elements. The entropy decoding unit 80 then forwards the motion vectors or intra-frame prediction mode indicators, and other syntax elements to the prediction processing unit 81.
[0083] When a video frame is encoded as an intra-prediction coded (I) frame or for intra-coded prediction blocks in other types of frames, the intra-prediction unit 84 of the prediction processing unit 81 can generate prediction data for a video block of the current video frame based on the intra-prediction mode transmitted by the signal and reference data from a previously decoded block of the current frame.
[0084] When the video frame is encoded as an inter-frame prediction coding (i.e., B or P) frame, the motion compensation unit 82 of the prediction processing unit 81 generates one or more prediction blocks for the video block of the current video frame based on the motion vector and other syntax elements received from the entropy decoding unit 80. Each of the prediction blocks can be generated from a reference frame in one of the reference frame lists. The video decoder 30 can construct the reference frame lists, i.e., List 0 and List 1, based on the reference frames stored in the DPB 92 using a default construction technique.
[0085] In some examples, when a video block is encoded according to the intra BC mode described herein, intra BC unit 85 of prediction processing unit 81 generates a prediction block for the current video block based on the block vector and other syntax elements received from entropy decoding unit 80. The prediction block may be within a reconstructed region of the same picture as the current video block as defined by video encoder 20.
[0086] The motion compensation unit 82 and / or the intra BC unit 85 determine prediction information for a video block of the current video frame by parsing the motion vector and other syntax elements, and then use the prediction information to generate a prediction block for the current video block being decoded. For example, the motion compensation unit 82 uses some of the received syntax elements to determine a prediction mode (e.g., intra prediction or inter prediction) for encoding a video block of a video frame, an inter prediction frame type (e.g., B or P), construction information for one or more of the reference frame lists for the frame, motion vectors for each inter prediction encoded video block of the frame, inter prediction states for each inter prediction encoded video block of the frame, and other information for decoding a video block in the current video frame.
[0087] Similarly, the intra BC unit 85 may use some of the received syntax elements, such as flags, to determine whether the current video block is predicted using intra BC mode, construction information of which video blocks of the frame are within the reconstruction region and should be stored in the DPB 92, block vectors for each intra BC predicted video block of the frame, intra BC prediction status for each intra BC predicted video block of the frame, and other information for decoding the video block in the current video frame.
[0088] Motion compensation unit 82 may also perform interpolation using interpolation filters as used by video encoder 20 during encoding of the video blocks to calculate interpolated values for sub-integer pixels of reference blocks. In this case, motion compensation unit 82 may determine the interpolation filters used by video encoder 20 based on the received syntax elements and use these interpolation filters to produce the prediction blocks.
[0089] Inverse quantization unit 86 inverse quantizes the quantized transform coefficients provided in the bitstream and entropy decoded by entropy decoding unit 80, using the same quantization parameters calculated by video encoder 20 for each video block in the video frame to determine the degree of quantization. Inverse transform processing unit 88 applies an inverse transform (e.g., an inverse DCT, an inverse integer transform, or a conceptually similar inverse transform process) to the transform coefficients to reconstruct the residual block in the pixel domain.
[0090] After the motion compensation unit 82 or the intra BC unit 85 generates a prediction block for the current video block based on the vector and other syntax elements, the adder 90 reconstructs the decoded video block for the current video block by adding the residual block from the inverse transform processing unit 88 to the corresponding prediction block generated by the motion compensation unit 82 and the intra BC unit 85. A loop filter 91 (e.g., a deblocking filter, an SAO filter, and / or an ALF) may be located between the adder 90 and the DPB 92 to further process the decoded video block. In some examples, the loop filter 91 may be omitted, and the decoded video block may be provided directly to the DPB 92 by the adder 90. The decoded video blocks in a given frame are then stored in the DPB 92, which stores reference frames for subsequent motion compensation of the next video block. The DPB 92 or a memory device separate from the DPB 92 may also store the decoded video for later presentation on a display device (e.g., Figure 1A on a display device 34).
[0091] In the current VVC standard, the motion information of the current coding block is copied from the spatial or temporal neighboring blocks specified by the merge candidate index, or obtained through motion estimation that is explicitly signaled.
[0092] In a typical video encoding process, a video sequence typically includes an ordered set of frames or pictures. Each frame may include three sample arrays, denoted as SL, SCb, and SCr. SL is a two-dimensional array of luma samples. SCb is a two-dimensional array of Cb chroma samples. SCr is a two-dimensional array of Cr chroma samples. In other examples, a frame may be monochrome and therefore include only a two-dimensional array of luma samples.
[0093] like Figure 1CAs shown, the video encoder 20 (or more specifically, a segmentation unit in a prediction processing unit of the video encoder 20) generates an encoded representation of a frame by first segmenting the frame into a set of CTUs. A video frame may include an integer number of CTUs sequentially ordered from left to right and from top to bottom in a raster scan order. Each CTU is the largest logical coding unit, and the width and height of the CTU are signaled by the video encoder 20 in a sequence parameter set so that all CTUs in a video sequence have the same size, one of 128×128, 64×64, 32×32, and 16×16. It should be noted, however, that the present application is not necessarily limited to a particular size. As Figure 1D As shown in , each CTU may include one CTB for luma samples, two corresponding coding tree blocks for chroma samples, and syntax elements for encoding samples of the coding tree blocks. The syntax elements describe the properties of different types of units of the coding pixel blocks and how the video sequence can be reconstructed at the video decoder 30, including inter-frame prediction or intra-frame prediction, intra-frame prediction mode, motion vectors, and other parameters. In a monochrome picture or a picture with three separate color planes, a CTU may include a single coding tree block and syntax elements for encoding samples of the coding tree block. The coding tree block may be an N×N block of samples.
[0094] To achieve better performance, the video encoder 20 may recursively perform tree partitioning, such as binary tree partitioning, ternary tree partitioning, quadtree partitioning, or a combination thereof, on the coding tree block of the CTU and divide the CTU into smaller CUs. Figure 1E As depicted in , a 64×64 CTU 400 is first divided into four smaller CUs, each CU having a block size of 32×32. Among the four smaller CUs, CU 410 and CU 420 are respectively divided into four CUs with a block size of 16×16. Two 16×16 CUs 430 and CU 440 are further divided into four CUs with a block size of 8×8. Figure 1F Depicted is a diagram showing Figure 1E The quadtree data structure of the final result of the partitioning process of the CTU 400 depicted in FIG. 4 corresponds to a CU of a corresponding size ranging from 32×32 to 8×8. Figure 1D In the CTU depicted in FIG, each CU may include a CB of luma samples and two corresponding coding blocks of chroma samples of the same size frame, and syntax elements for encoding the samples of the coding blocks. In a monochrome picture or a picture with three separate color planes, a CU may include a single coding block and syntax structures for encoding the samples of the coding block. It should be noted that Figure 1E and Figure 1FThe quadtree partitioning depicted in FIG is for illustrative purposes only, and one CTU can be split into multiple CUs based on quadtree partitioning / ternary tree partitioning / binary tree partitioning to adapt to varying local characteristics. In a multi-type tree structure, one CTU is partitioned according to a quadtree structure, and each quadtree leaf CU can be further partitioned according to a binary and ternary tree structure. FIG. 3A to FIG. 3E As shown, there are five possible partitioning types for a coding block with width W and height H, namely, quadruple partitioning, vertical binary partitioning, horizontal binary partitioning, vertical extended ternary partitioning, and horizontal extended ternary partitioning.
[0095] In some embodiments, the video encoder 20 may further partition the coding block of the CU into one or more M×N PBs. A PB is a rectangular (square or non-square) sample block to which the same prediction (inter or intra) is applied. The PU of a CU may include a PB of luma samples, two corresponding PBs of chroma samples, and syntax elements for predicting the PBs. In a monochrome picture or a picture with three separate color planes, a PU may include a single PB and a syntax structure for predicting the PB. The video encoder 20 may generate a predicted luma block, a predicted Cb block, and a predicted Cr block for the luma PB, Cb PB, and Cr PB of each PU of the CU.
[0096] Video encoder 20 may use intra prediction or inter prediction to generate a prediction block for a PU. If video encoder 20 uses intra prediction to generate a prediction block for a PU, video encoder 20 may generate the prediction block for the PU based on decoded samples of a frame associated with the PU. If video encoder 20 uses inter prediction to generate a prediction block for a PU, video encoder 20 may generate the prediction block for the PU based on decoded samples of one or more frames other than the frame associated with the PU.
[0097] After the video encoder 20 generates a predicted luma block, a predicted Cb block, and a predicted Cr block for one or more PUs of a CU, the video encoder 20 may generate a luma residual block for the CU by subtracting the predicted luma block of the CU from the original luma coding block of the CU, so that each sample in the luma residual block of the CU indicates the difference between a luma sample in one of the predicted luma blocks of the CU and a corresponding sample in the original luma coding block of the CU. Similarly, the video encoder 20 may generate a Cb residual block and a Cr residual block for the CU, respectively, so that each sample in the Cb residual block of the CU indicates the difference between a Cb sample in one of the predicted Cb blocks of the CU and a corresponding sample in the original Cb coding block of the CU, and each sample in the Cr residual block of the CU may indicate the difference between a Cr sample in one of the predicted Cr blocks of the CU and a corresponding sample in the original Cr coding block of the CU.
[0098] In addition, if Figure 1EAs shown in , the video encoder 20 can use quadtree partitioning to decompose the luma residual block, Cb residual block and Cr residual block of the CU into one or more luma transform blocks, Cb transform blocks and Cr transform blocks, respectively. A transform block is a rectangular (square or non-square) sample block to which the same transform is applied. The TU of the CU may include a transform block of luma samples, two corresponding transform blocks of chroma samples, and syntax elements for transforming the transform block samples. Therefore, each TU of the CU may be associated with a luma transform block, a Cb transform block and a Cr transform block. In some examples, the luma transform block associated with the TU may be a sub-block of the luma residual block of the CU. The Cb transform block may be a sub-block of the Cb residual block of the CU. The Cr transform block may be a sub-block of the Cr residual block of the CU. In a monochrome picture or a picture with three separate color planes, a TU may include a single transform block and a syntax structure for transforming the samples of the transform block.
[0099] The video encoder 20 may apply one or more transforms to the luma transform block of the TU to generate a luma coefficient block for the TU. The coefficient block may be a two-dimensional array of transform coefficients. The transform coefficient may be a scalar. The video encoder 20 may apply one or more transforms to the Cb transform block of the TU to generate a Cb coefficient block for the TU. The video encoder 20 may apply one or more transforms to the Cr transform block of the TU to generate a Cr coefficient block for the TU.
[0100] After generating a coefficient block (e.g., a luma coefficient block, a Cb coefficient block, or a Cr coefficient block), the video encoder 20 may quantize the coefficient block. Quantization generally refers to a process in which transform coefficients are quantized to potentially reduce the amount of data used to represent the transform coefficients, thereby providing further compression. After the video encoder 20 quantizes the coefficient block, the video encoder 20 may entropy encode syntax elements indicating the quantized transform coefficients. For example, the video encoder 20 may perform CABAC on the syntax elements indicating the quantized transform coefficients. Finally, the video encoder 20 may output a bitstream including a sequence of bits that form a representation of an encoded frame and associated data, and the bitstream is stored in the storage device 32 or sent to the target device 14.
[0101] After receiving the bitstream generated by the video encoder 20, the video decoder 30 can parse the bitstream to obtain syntax elements from the bitstream. The video decoder 30 can reconstruct the frame of the video data based at least in part on the syntax elements obtained from the bitstream. The process of reconstructing the video data is generally inverse to the encoding process performed by the video encoder 20. For example, the video decoder 30 can perform an inverse transform on the coefficient block associated with the TU of the current CU to reconstruct the residual block associated with the TU of the current CU. The video decoder 30 also reconstructs the coding block of the current CU by adding the samples of the prediction block for the PU of the current CU to the corresponding samples of the transform block of the TU of the current CU. After reconstructing the coding block for each CU of the frame, the video decoder 30 can reconstruct the frame.
[0102] As mentioned above, video coding mainly uses two modes, namely, intra-frame prediction (or intra-frame prediction) and inter-frame prediction (or inter-frame prediction) to achieve video compression. It should be noted that IBC can be regarded as intra-frame prediction or a third mode. Between the two modes, inter-frame prediction contributes more to coding efficiency than intra-frame prediction because motion vectors are used to predict the current video block based on the reference video block.
[0103] But with the ever-improving video data capture technology and finer video block sizes for retaining details in the video data, the amount of data required to represent the motion vector for the current frame has also increased significantly. One way to overcome this challenge benefits from the fact that not only a set of neighboring CUs in both the spatial and temporal domains have similar video data for prediction purposes, but also the motion vectors between these neighboring CUs are similar. Therefore, the motion information of spatially neighboring CUs and / or temporally co-located CUs can be used as an approximation of the motion information (e.g., motion vector) of the current CU (which is also called the "motion vector predictor" (MVP) of the current CU) by exploring their spatial and temporal correlations.
[0104] Instead of combining as above Figure 1B The actual motion vector of the current CU determined by the motion estimation unit is encoded into the video bitstream, and the motion vector prediction value of the current CU is subtracted from the actual motion vector of the current CU to generate a motion vector difference (MVD) for the current CU. By doing so, it is not necessary to encode the motion vector determined by the motion estimation unit for each CU of the frame into the video bitstream, and the amount of data used to represent the motion information in the video bitstream can be significantly reduced.
[0105] Similar to the process of selecting a prediction block in a reference frame during inter-frame prediction of a coding block, both the video encoder 20 and the video decoder 30 need to adopt a set of rules for constructing a motion vector candidate list (also called a "merge list") for the current CU using those potential candidate motion vectors associated with the spatial neighboring CUs and / or temporal co-located CUs of the current CU, and then selecting a member from the motion vector candidate list as the motion vector prediction value for the current CU. By doing so, the motion vector candidate list itself does not need to be sent from the video encoder 20 to the video decoder 30, and the index of the selected motion vector prediction value within the motion vector candidate list is sufficient for the video encoder 20 and the video decoder 30 to use the same motion vector prediction value within the motion vector candidate list to encode and decode the current CU.
[0106] For each inter-prediction CU, motion parameters (including motion vector, reference picture index, and reference picture list usage index) and additional information required for the new coding features of VVC are available for inter-prediction sample generation. Motion parameters can be signaled explicitly or implicitly. When a CU is encoded using skip mode, the CU is associated with one PU and has no significant residual coefficients, no coded motion vector increments (motion vector differences), or reference picture indices. A merge mode is specified, whereby the motion parameters of the current CU are obtained from neighboring CUs (including spatial and temporal candidates) and the additional scheduling introduced in VVC. Merge mode can be applied to any inter-prediction CU, not just skip mode. An alternative to merge mode is to explicitly transmit motion parameters, where motion vectors, corresponding reference picture indices for each reference picture list, and reference picture list usage flags, as well as other required information, are explicitly signaled for each CU.
[0107] Extended Merge Mode
[0108] In some embodiments, the merge candidate list is constructed by including the following five types of candidates in order:
[0109] (1) Spatial MVP from spatially adjacent CUs;
[0110] (2) Temporal MVP from the co-located CU;
[0111] (3) history-based MVP from a first-in, first-out (FIFO) table;
[0112] (4) pairwise average MVP; and
[0113] (5) Zero MV.
[0114] 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 coded in merge mode, the index of the best merge candidate is encoded using truncated unary binarization (TU). The first bin of the merge index is encoded using context, and bypass coding is used for the other bins.
[0115] The above provides a process for obtaining each merge candidate category. In some embodiments, it may support obtaining a merge candidate list for all CUs in a region of a certain size in parallel.
[0116] Get space candidates
[0117] The spatial merge candidates obtained in VVC are the same as those in HEVC, except that the positions of the first two merge candidates are swapped. Figure 4A Select up to four merge candidates from the candidates at the positions shown in . The resulting order is B0, A0, B1, A1 and B2. Position B2 is considered only when one or more CUs at positions B0, A0, B1, A1 are not available (for example, because it belongs to another slice or tile) or is intra-coded. After adding the candidate at position A1, the addition of the remaining candidates is subject to redundancy checking, which ensures that candidates with the same motion information are excluded from the list, thereby improving encoding and decoding efficiency. In order to reduce computational complexity, not all possible candidate pairs are considered in the above-mentioned redundancy check. Instead, only the Figure 4B Pairs are linked using arrows in , and candidates are added to the list only if the corresponding candidates used for redundancy checking do not have the same motion information. Figure 4B Candidate pairs for redundancy check of spatial merging candidates are shown.
[0118] Get time candidate
[0119] In this step, only one candidate is added to the list. Specifically, when the temporal merge candidate is obtained, the scaled motion vector is obtained based on the co-located CU belonging to the co-located reference picture. The reference picture list and reference index used to obtain the co-located CU are explicitly signaled in the slice header. Figure 4C As shown by the dotted line in , the scaled motion vector of 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.
[0120] like Figure 4DAs shown, the position of the temporal candidate is selected between candidates C0 and C1. If the CU at position C0 is not available, is intra-coded, or is outside the current CTU row, position C1 is used. Otherwise, position C0 is used in obtaining the temporal merge candidate.
[0121] History-based merge candidate acquisition
[0122] After spatial MVP and temporal motion vector prediction (TMVP), history-based MVP (HMVP) merge candidates are added to the merge list. In this method, the motion information of previously coded blocks 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-subblock inter-coded CU, the associated motion information is added to the last entry of the table as a new HMVP candidate.
[0123] The HMVP table size S can be set to 6, which means that up to 5 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 all subsequent HMVP candidates are moved forward, and the identical HMVP is inserted into the last entry of the table.
[0124] HMVP candidates can be used in the merge candidate list construction process. The latest few HMVP candidates in the table are checked in turn and inserted into the candidate list after the TMVP candidate. Redundancy check is applied to HMVP candidates relative to spatial or temporal merge candidates.
[0125] In order to reduce the number of redundancy check operations, the following simplifications are introduced. First, the last two entries in the table are redundancy checked with respect to the A1 and B1 spatial candidates, respectively. Second, once the total number of available merge candidates reaches the maximum allowed merge candidate minus 1, the process of building the merge candidate list according to HMVP is terminated.
[0126] Get pairwise average merge candidates
[0127] Pairwise average candidates are generated by averaging predefined candidate pairs in the existing merge candidate list using the first two merge candidates. The first merge candidate is defined as p0Cand, and the second merge candidate can be defined as p1Cand. Separately for each reference list, the average motion vector is calculated based on the availability of motion vectors of p0Cand and p1Cand. If both motion vectors are available in one list, they are averaged and their reference pictures are set to the reference picture of p0Cand even if they point to different reference pictures; if only one motion vector is available, the motion vector is used directly; if no motion vector is available, this list is kept invalid. In addition, if the half-pixel interpolation filter index of p0Cand and p1Cand is different, it is set to 0.
[0128] When the merge list is not full after adding pairwise average merge candidates, zero MVPs are inserted at the end of the merge list until the maximum number of merge candidates is encountered.
[0129] High-precision (1 / 16 pixel) motion compensation and motion vector storage
[0130] In the VVC standard, MV accuracy is increased to 1 / 16 luma samples to improve prediction efficiency for slow-motion videos. This higher motion accuracy is particularly useful for video content with local changes and non-translational motion, such as in the case of affine mode. In order to generate fractional position samples with higher MV accuracy, HEVC's 8-tap luma interpolation filter and 4-tap chroma interpolation filter are extended to luma 16 phases and chroma 32 phases. This extended filter group is applied to the MC process of inter-coded CUs except CUs in affine mode. For affine mode, a set of 6-tap luma interpolation filters with 16 phases is used to reduce computational complexity and save memory bandwidth.
[0131] The highest precision of explicitly signaling motion vectors for non-affine CUs is one-quarter luma sample. In some inter prediction modes (e.g., affine mode), motion vectors can be signaled with 1 / 16 luma sample precision. In all inter-coded CUs with implicitly inferred MVs, MVs are obtained with 1 / 16 luma sample precision, and motion compensated prediction is performed with 1 / 16 sample precision. In terms of internal motion field storage, all motion vectors are stored with 1 / 16 luma sample precision.
[0132] For the temporal motion field storage used by TMVP and SbTVMP, motion field compression is performed at a granularity of 8×8, compared to 16×16 in HEVC.
[0133] Merge Mode Using MVD (MMVD)
[0134] In addition to the merge mode, in which the implicitly obtained motion information is directly used for prediction sample generation of the current CU, a merge mode using motion vector difference (MMVD) is introduced. The MMVD flag is signaled immediately after the regular merge flag is sent to specify whether the MMVD mode is used for the CU. After the merge candidate is selected, it is further refined by the signaled MVD information. Further information includes the merge candidate flag, an index specifying the motion amplitude and an index indicating the motion direction. In MMVD mode, one of the first two candidates in the merge list is selected as the MV basis. The MMVD candidate flag is signaled to specify which one to use between the first and second merge candidates.
[0135] The distance index specifies the motion magnitude information and indicates a predefined offset from the starting point. Figure 5 As 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 shown in Table 1.
[0136] Table 1 Relationship between distance index and predefined offset
[0137]
[0138] 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. It should be noted that the meaning of the MVD symbol can change according to the information of the starting MV. When the starting MV is a non-predicted MV or a bi-predicted MV and 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 specifies the sign of the MV offset added to the starting MV. When the starting MV is a bi-predicted MV and 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 POC difference in List 0 is greater than the POC difference in List 1, the symbol in Table 2 specifies the sign of the MV offset added to the List 0 MV component of the starting MV, while the sign of the List 1 MV has the opposite value. Otherwise, if the POC difference in List 1 is greater than List 0, the symbol in Table 2 specifies the sign of the MV offset added to the List 1 MV component of the starting MV, while the sign of the List 0 MV has the opposite value.
[0139] Scale the MVD according to the POC difference 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, scale the MVD of list 1 by defining the POC difference of L0 as td and the POC difference of L1 as tb, as Figure 4CIf the POC difference of L1 is greater than L0, the MVD of list 0 is scaled in the same way. If the starting MV is uni-predicted, the MVD is added to the available MVs.
[0140] Table 2 Sign of MV offset specified by direction index
[0141] Direction Index 00 01 10 11 x-axis + - N / A N / A y-axis N / A N / A + -
[0142] Symmetric MVD Coding
[0143] In addition to normal uni-prediction and bi-prediction mode MVD signaling, symmetric MVD mode for bi-prediction MVD signaling can also be applied. In symmetric MVD mode, the motion information including reference picture indexes of list 0 and list 1 and MVD of list 1 is not signaled but inferred.
[0144] The decoding process of the symmetric MVD mode is as follows:
[0145] At the stripe level, the variables BiDirPredFlag, RefIdxSymL0, and RefIdxSymL1 are obtained as follows:
[0146] - If mvd_l1_zero_flag is 1, BiDirPredFlag is set equal to 0.
[0147] Otherwise, if the nearest reference picture in list-0 and the nearest reference picture in list-1 form a forward-backward pair of reference pictures or a backward-forward pair of reference pictures, then BiDirPredFlag is set to 1, and both list-0 and list-1 reference pictures are short-term reference pictures. Otherwise, BiDirPredFlag is set to 0.
[0148] At the CU level, if the CU is bidirectionally predictive coded and BiDirPredFlag is equal to 1, the symmetric mode flag indicating whether the symmetric mode is used is explicitly signaled.
[0149] When the symmetric mode flag is true, only mvp_l0_flag, mvp_l1_flag and MVD0 are explicitly signaled. The reference index of list-0 and list-1 are set equal to the reference picture pair respectively. MVD1 is set to (-MVD0). The final motion vector is shown in the following formula.
[0150]
[0151] In the encoder, symmetric MVD motion estimation starts with initial MV evaluation. A set of initial MV candidates includes MVs obtained from uni-prediction search, MVs obtained from bi-prediction search, and MVs from the AMVP list. The MV with the lowest rate-distortion cost is selected as the initial MV for symmetric MVD motion search.
[0152] Bidirectional matching AMVP merge mode
[0153] In the bidirectional matching AMVP merge mode (also referred to as AM mode in this disclosure), the bidirectional prediction value consists of the AMVP prediction value in one direction and the merged prediction value in the other direction. This mode can be enabled for a coding block when the selected merged prediction value and the AMVP prediction value meet the condition that there is at least one reference picture from the past and one reference picture from the future relative to the current picture.
[0154] The AMVP part of the AM mode is signaled as regular unidirectional AMVP, ie the reference index and MVD are signaled, and it has an inferred MVP index if template matching is used, or the MVP index is signaled when template matching is disabled.
[0155] For the AMVP direction LX (X can be 0 or 1; L represents the reference picture list), the merge part in the other direction L(1-X) is implicitly derived by minimizing the bilateral matching cost between the AMVP prediction value and the merge prediction value (i.e., for the AMVP and merge motion vector pairs). For each merge candidate in the merge candidate list with the other direction L(1-X) motion vector, the bilateral matching cost is calculated using the merge candidate MV and the AMVP MV. The merge candidates are then sorted according to the bilateral matching cost. The merge index is then signaled to the bitstream to indicate which merge candidate is selected from the top 2 sorted candidates. The derivation of the L(1-X)mv merge candidate list for AM mode basically follows a similar process to the conventional merge list construction described in the previous paragraph. The encoder or decoder searches for different merge candidates (including spatial, temporal, HMVP, pair average, and zero candidates) and inserts the valid L(1-X)mv of different merge candidates into the mv merge candidate list for AM mode. L(1-X)mv is considered valid when all of the following criteria are met. Otherwise, when at least one of the following criteria is not met, the L(1-X)mv candidate is considered invalid. The criteria are:
[0156] 1. The merge candidate has L(1-X)mv. For example, when X is 0 and the merge candidate is bidirectional prediction or L1 unidirectional prediction, the L(1-X)mv candidate is considered valid.
[0157] 2. The reference picture of the merged candidate L(1-X)mv must be in the opposite direction of the reference picture of the LX mv of the mv obtained in the AMVP mode.
[0158] Bilateral matching refinement or template matching is then applied to the coding block starting from the selected merge candidate MV and AMVP MV. Specifically, when the distances from the two reference pictures to the current picture are the same (the distances are measured by the display order, such as the picture order count defined in VVC or HEVC), bilateral matching MV refinement is applied to the merge candidate MV and AMVP MVP as the starting point. Otherwise, if the template matching function is enabled, template matching MV refinement is applied to the merge prediction value or AMVP prediction value with a higher template matching cost.
[0159] AM mode is indicated by a flag. In current VVC and ECM, since AM mode is not allowed when all reference pictures are from the past (in terms of display order), the indication flag does not need to be signaled under this condition. In addition, if AM mode is enabled for the CU, the AMVP direction LX is also indicated by a flag. However, when "ph_mvd_l1_zero_flag" is enabled for the picture (for example, ph_mvd_l1_zero_flag=1), the indication of AMVP direction LX does not need to be signaled and is assumed to be L0 (in other words, the merge direction is L1), because when "ph_mvd_l1_zero_flag" is enabled, the mvd signal is not signaled for the L1 mv of the bidirectional AMVP coded CU.
[0160] In addition, the reference picture index is conditionally signaled in the bitstream based on whether the reference picture of the AMVP direction LX and the reference picture of the merge direction L(1-X) are in opposite directions, that is, one reference picture is before the current picture (e.g., a past coded picture) and the other reference picture is after the current picture (e.g., a future coded picture).
[0161] As mentioned above, the existing bilateral matching AMVP-merge mode in ECM has a limitation, namely, the mode can be enabled to coding blocks that meet the following two conditions: the selected merged prediction value and the AMVP prediction value meet the DMVR condition, where there is at least one reference picture from the past and one reference picture from the future relative to the current picture; and the distances from the two reference pictures to the current picture are the same.
[0162] In this disclosure, several inter-frame prediction schemes are proposed to change or eliminate the constraints of bilateral matching AMVP-merge mode to achieve higher coding efficiency (eg, better BD-rate performance) or lower complexity. The proposed schemes can be applied independently or in combination.
[0163] In one embodiment, bilateral matching AMVP-merge mode is enabled regardless of whether all reference pictures are from the past or not.
[0164] To construct the mv merge candidate list of L(1-X) in AM mode, the encoder or decoder searches for different merge candidates (including spatial, temporal, HMVP, pair average and zero candidates) and inserts the valid L(1-X)mv of different merge candidates into the mv merge candidate list or valid merge candidate list of AM mode. L(1-X)mv is considered valid when the following criteria are met:
[0165] The merge candidate has L(1-X)mv. For example, when X is 0 and the merge candidate is bidirectional prediction or L1 unidirectional prediction, the L(1-X)mv candidate is considered valid.
[0166] That is, when a merge candidate has L(1-X)mv, L(1-X) is considered valid regardless of whether the reference picture of the L(1-X)MV of the merge candidate is in the opposite direction to the reference picture of the LX MV.
[0167] Then, among all L(1-X) merge candidates, the L(1-X) merge mv of AM mode is implicitly selected as the mv with the minimum matching cost between the L(1-X) merge prediction block associated with each candidate and the LX AMVP prediction block. The matching cost can be the sum of absolute differences (SAD), the sum of squared differences (SSD), or any other method for measuring the similarity between two blocks.
[0168] Bilateral matching refinement or template matching is then applied to the coding block starting from the selected merge candidate MV and AMVP MV. Specifically, when the distance from the two reference pictures to the current picture is the same (the distance is measured by the display order, such as the picture order count defined in VVC or HEVC), bilateral matching MV refinement is applied to the merged MV candidate and AMVP MVP as the starting point. Otherwise, if the template matching function is enabled, template matching MV refinement is applied to the merged prediction value or AMVP prediction value with a higher template matching cost.
[0169] In addition, when only one reference picture is available for AMVP direction LX (X can be 0 or 1; and L represents a reference picture list), signaling the reference picture index can be omitted. Otherwise, when more than one reference picture is available for AMVP direction LX, the reference picture index is always signaled in the bitstream for AMVP direction LX.
[0170] In another embodiment, based on the AM mode shown in the present disclosure, when the template matching function is enabled, the template matching MV refinement can be conditionally applied to the merged prediction value or AMVP prediction value with a higher template matching cost. In one example, when all reference pictures of the current picture are from the past (for example, the display order of all reference pictures is before the current picture), the template matching MV refinement is only applied to the merged prediction value or AMVP prediction value with a higher template matching cost.
[0171] In another example, when the reference pictures of the current picture are not all from the past (eg, at least some of the reference pictures have a display order after the current picture), template matching MV refinement is only applied to the merged prediction value or AMVP prediction value with a higher template matching cost.
[0172] In another example, regardless of whether the template matching function is enabled, the template matching MV refinement is not applied to the merged prediction value or the AMVP prediction value.
[0173] In another embodiment, based on the AM mode shown in the present disclosure, the L(1-X) merged mv of the AM mode is implicitly selected as the mv with the minimum difference between LX mv and L(1-X)mv. It is worth noting that when the reference pictures between LX mv and L(1-X)mv are different, mv scaling may be required. In one example, LX mv and L(1-X)mv have different reference pictures. The L(1-X)mv is then scaled to a new mv pointing to the same picture of the LX mv. The scaling ratio is calculated based on the temporal distance between the current picture and the two reference pictures. The difference between the LX mv and the scaled L(1-X)mv is calculated as the absolute difference of the horizontal component plus the absolute difference of the vertical component.
[0174] In another embodiment, based on the AM mode shown in the present disclosure, the L(1-X) merge mv of the AM mode is explicitly signaled in the bitstream to indicate which merge candidate is selected for the AM mode. The merge candidate list for the AM mode can be generated using the existing methods in the standard or ECM shown in the present disclosure. In addition, after the merge list is generated, candidate reordering can be selectively applied. The reordering can be performed based on the matching cost of the AMVP prediction value and the merge prediction value.
[0175] In another embodiment, different schemes of the AM mode can be used adaptively. In one example, when all reference pictures of the current picture are from the past (e.g., the display order of all reference pictures is before the current picture), the proposed AM mode (shown in the previous embodiment) is used. Otherwise, the original AM mode in the ECM is used.
[0176] In another example, when all reference pictures of the current picture are not from the past (eg, at least some of the reference pictures are displayed after the current picture), the proposed AM mode (shown in the previous embodiment) is used. Otherwise, the original AM mode in ECM is used.
[0177] In another example, when all reference pictures of the current picture are from the past, only one merge candidate is used for AM mode; and the merge candidate is selected among multiple merge candidates based on a predefined criterion (e.g., bilateral matching error). Since only one merge candidate is directly selected, there is no need to signal the merge index into the bitstream. When not all reference pictures of the current picture are from the past, multiple merge candidates can be selected for AM mode; and in this case, the merge index is signaled into the bitstream to indicate which merge candidate is used for AM mode.
[0178] In another embodiment, when "ph_mvd_l1_zero_flag" is enabled for the picture (or slice) (e.g., ph_mvd_l1_zero_flag=1) and the AM mode is also enabled for the picture (or slice), the conventional bidirectional inter mode is not allowed and its associated syntax elements do not need to be signaled into the bitstream. This is because the conventional bidirectional inter mode with list 1 mvd equal to zero highly overlaps the functionality with the AM mode.
[0179] In the VVC specification, the syntax element "inter_pred_idc" is used to indicate whether the current inter-frame block is encoded with list 0 unidirectional prediction, list 1 unidirectional prediction or bidirectional prediction. And the three different values of "inter_pred_idc" indicate three different prediction directions (for example, 0, 1 and 2 represent L0 prediction, L1 prediction and bidirectional prediction, respectively). The binarization of inter_pred_idc is shown in Table 3 below. cbWidth and cbHeight are the width and height of the current block or CU.
[0180] Table 3 Binarization of inter_pred_idc
[0181]
[0182] In the proposed scheme, when "ph_mvd_l1_zero_flag" and AM mode (e.g., ph_mvd_l1_zero_flag=1) are enabled for the picture (or slice), the value of inter_pred_idc indicating bidirectional prediction is omitted (i.e., not signaled), as shown in Table 4 below. Instead, AM mode can be used as an alternative to the conventional bidirectional prediction mode.
[0183] Table 4 Recommended binarization of inter_pred_idc
[0184]
[0185] Figure 6 A computing environment 610 is shown coupled to a user interface 650. The computing environment 610 may be part of a data processing server. The computing environment 610 includes a processor 620, a memory 630, and an input / output (I / O) interface 640.
[0186] The processor 620 generally controls the overall operation of the computing environment 610, such as operations associated with display, data acquisition, data communication, and image processing. The processor 620 may include one or more processors for executing instructions to perform all or some of the steps in the above method. In addition, the processor 620 may include one or more modules that facilitate the interaction between the processor 620 and other components. The processor may be a central processing unit (CPU), a microprocessor, a single-chip microcomputer, a graphics processing unit (GPU), etc.
[0187] The memory 630 is configured to store various types of data to support the operation of the computing environment 610. The memory 630 may include predetermined software 632. Examples of such data include instructions for any application or method operating on the computing environment 610, video data sets, image data, etc. The memory 630 may be implemented by using any type of volatile or non-volatile memory device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk, or optical disk.
[0188] I / O interface 640 provides an interface between processor 620 and peripheral interface modules (e.g., keyboard, click wheel, buttons, etc.). Buttons may include, but are not limited to, a home button, a start scan button, and a stop scan button. I / O interface 640 may be coupled to an encoder and a decoder.
[0189] In an embodiment, a non-transitory computer-readable storage medium including a plurality of programs in, for example, a memory 630 is also provided, wherein the plurality of programs can be executed by a processor 620 in a computing environment 610 to perform the above method. Alternatively, the non-transitory computer-readable storage medium may store a plurality of programs generated by an encoder (for example, Figure 2A The video encoder 20 in FIG. 1 generates a video signal for a decoder (eg, Figure 3AA bitstream or data stream including encoded video information (e.g., video information including one or more syntax elements) used by the video decoder 30 in the video decoder 30 when decoding video data. The non-transitory computer-readable storage medium can be, for example, a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.
[0190] In an embodiment, a computing device is also provided, which includes: one or more processors (e.g., processor 620); and a non-transitory computer-readable storage medium or memory 1630 in which multiple programs that can be executed by the one or more processors are stored, wherein the one or more processors are configured to perform the above-mentioned method when executing the multiple programs.
[0191] In an embodiment, a computer program product is also provided, including a plurality of programs in, for example, a memory 630, which may be executed by a processor 620 in a computing environment 610 for performing the above method. For example, the computer program product may include a non-transitory computer-readable storage medium.
[0192] In an embodiment, the computing environment 1610 may be implemented by one or more ASICs, DSPs, digital signal processing devices (DSPDs), programmable logic devices (PLDs), FPGAs, GPUs, controllers, microcontrollers, microprocessors, or other electronic components for performing the above methods.
[0193] The description of the present disclosure has been presented for purposes of illustration and is not intended to be exhaustive or limited to the present disclosure. Many modifications, variations, and alternative embodiments will be apparent to one of ordinary skill in the art having the benefit of the teachings presented in the foregoing description and the associated drawings.
[0194] Unless otherwise specifically stated, the order of steps of the method according to the present disclosure is intended to be illustrative only, and the steps of the method according to the present disclosure are not limited to the order specifically described above, but can be changed according to actual conditions. In addition, at least one of the steps of the method according to the present disclosure can be adjusted, combined or deleted according to actual needs.
[0195] The examples are chosen and described in order to explain the principles of the present disclosure and to enable other persons skilled in the art to understand the various embodiments of the present disclosure and to best utilize the basic principles and various embodiments with various modifications suitable for the specific use contemplated. Therefore, it will be understood that the scope of the present disclosure is not limited to the specific examples of the disclosed embodiments, and modifications and other embodiments are intended to be included within the scope of the present disclosure.
[0196] Figure 7 is a flowchart illustrating a video decoding method according to an example of the present disclosure.
[0197] In step 701 , the processor 620 at the decoder side may determine whether an advanced motion vector prediction (AMVP)-merge (AM) mode is enabled for a current picture or a slice of the current picture.
[0198] In step 702 , for a first reference picture list LX, the processor 620 may obtain an AMVP motion vector (MV) of a current block in a current picture as LX MV, where X is 0 or 1.
[0199] In step 703 , the processor 620 may obtain a valid merge MV candidate list for the second reference picture list L(1-X), wherein the valid merge MV candidate list includes merge candidates having L(1-X) MVs.
[0200] In step 704, the processor 620 may select the L(1-X) MV of the AM mode from the valid merged MV candidate list.
[0201] In some examples, a merge candidate with an L(1-X) MV is considered valid regardless of whether the reference picture of the merge candidate's L(1-X) MV is in the opposite direction to the reference picture of the LX MV.
[0202] Figure 8 is shown with Figure 7 The video decoding method shown is a flowchart of a video encoding method corresponding to the video decoding method.
[0203] At step 801, the processor 620 at the encoder side may determine to enable the Advanced Motion Vector Prediction (AMVP)-Merge (AM) mode for the current picture or a slice of the current picture;
[0204] In step 802 , the processor 620 may obtain an AMVP motion vector (MV) of a current block in a current picture as an LX MV for a first reference picture list LX (where X is 0 or 1).
[0205] In step 803 , the processor 620 may obtain a valid merge MV candidate list for the second reference picture list L(1-X), wherein the valid merge MV candidate list includes merge candidates having L(1-X) MVs.
[0206] At step 804, the processor 620 may select the L(1-X) MV of the AM mode from the valid merged MV candidate list.
[0207] In some examples, a merge candidate with an L(1-X) MV is considered valid regardless of whether the reference picture of the merge candidate's L(1-X) MV is in the opposite direction to the reference picture of the LX MV.
[0208] In some examples, a device for video decoding is provided. The device includes a processor 620 and a memory 630, wherein the memory 630 is configured to store instructions executable by the processor; wherein after executing the instructions, the processor is configured to perform the following steps: Figure 7 The method shown.
[0209] In some examples, a device for video encoding is provided. The device includes a processor 620 and a memory 630, wherein the memory 630 is configured to store instructions executable by the processor; wherein after executing the instructions, the processor is configured to perform the following steps: Figure 8 The method shown.
[0210] In some other examples, a non-transitory computer-readable storage medium is provided, in which instructions are stored. For example, the instructions may be stored as predetermined software 632, or a portion of the software. When the instructions are executed by the processor 620, the instructions cause the processor to perform the following steps: Figures 7 and 8 In one example, multiple programs can be executed by a processor 620 in a computing environment 610 to receive (e.g., from Figure 1G The video encoder 20 in the computing environment 610 includes a bit stream or data stream of encoded video information (e.g., video blocks representing encoded video frames, and / or one or more associated syntax elements, etc.), and can also be executed by the processor 620 in the computing environment 610 to perform the above decoding method according to the received bit stream or data stream. In another example, multiple programs can be executed by the processor 620 in the computing environment 610 to perform the above encoding and decoding method to encode video information (e.g., video blocks representing video frames, and / or one or more associated syntax elements, etc.) into a bit stream or data stream, and can also be executed by the processor 620 in the computing environment 610 to transmit the bit stream or data stream (e.g., to Figure 2B Alternatively, a non-transitory computer-readable storage medium may store a bit stream or data stream including a video decoder 30 in the video decoder 30. ... Figure 1G The video encoder 20 in the embodiment uses the coded video information (e.g., video blocks representing coded video frames, and / or one or more associated syntax elements, etc.) generated by the above-mentioned coding method for the decoder (e.g., Figure 2B The video decoder 30 in the video decoder 30 is used when decoding video data. The non-transitory computer-readable storage medium may be, for example, a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.
[0211] The above method can be implemented using an apparatus including one or more circuits, including an application specific integrated circuit (ASIC), a digital signal processor (DSP), a digital signal processing device (DSPD), a programmable logic device (PLD), a field programmable gate array (FPGA), a controller, a microcontroller, a microprocessor or other electronic components. The apparatus can use the circuit in combination with other hardware or software components to perform the above method. Each module, submodule, unit or subunit disclosed above can be implemented at least in part using one or more circuits.
[0212] Other examples of the present disclosure will be clearly understood by those skilled in the art from the description and practice disclosed herein. This application is intended to cover any changes, uses or adjustments to the present disclosure in accordance with its general principles, and includes deviations from the present disclosure within the scope of known or customary practice in the art. The description and examples should be regarded as exemplary only.
[0213] It should be understood that the present disclosure is not limited to the exact examples shown in the above description and the accompanying drawings, and that various modifications and changes may be made without departing from the scope thereof.
Claims
1. A video decoding method, comprising: Determined by the decoder to enable Advanced Motion Vector Prediction AMVP-Merge AM mode for the current picture or a slice of the current picture; Obtaining, by the decoder, an AMVP motion vector MV of a current block in the current picture as LX MV for a first reference picture list LX, where X is 0 or 1; Obtaining, by the decoder, a valid merge MV candidate list for a second reference picture list L(1-X), wherein the valid merge MV candidate list includes merge candidates having L(1-X) MVs; as well as The decoder selects the L(1-X) MV of the AM mode from the valid merged MV candidate list.
2. The method according to claim 1, wherein: Regardless of whether the reference picture of the L(1-X)MV of the merge candidate is in the opposite direction to the reference picture of the LXMV, the merge candidate having the L(1-X)MV is determined to be valid.
3. The method according to claim 1, wherein: Among all valid merge MV candidates, the L(1-X) MV of the AM mode is implicitly selected as the MV with the minimum matching cost between the L(1-X) merge prediction block and the LX AMVP prediction block associated with each candidate.
4. The method according to claim 1, wherein: When it is determined that only one reference picture can be used for the LX MV, the reference picture index is not signaled in the bitstream; or when it is determined that more than one reference picture can be used for the LX MV, the reference picture index is signaled in the bitstream.
5. The method according to claim 1, wherein: When it is determined that the template matching function is enabled, template matching MV refinement is conditionally applied to the LX MV or the L(1-X) MV of the AM mode having a higher template matching cost.
6. The method according to claim 5, wherein: Under the condition that all reference pictures have a display order before the current picture, or at least some reference pictures have a display order after the current picture, the template matching MV refinement is applied to the LX MV or the L(1-X) MV of the AM mode with a higher template matching cost.
7. The method according to claim 1, wherein: Regardless of whether the template matching function is enabled, template matching MV refinement is not applied to the L(1-X) MV of the AM mode or the LX MV.
8. The method of claim 1, wherein the L(1-X)MV of the AM mode is implicitly selected as the MV having the minimum difference between the LX MV and the L(1-X)MV.
9. The method according to claim 1, further comprising: When it is determined that the reference picture of the LX MV and the reference picture of the L(1-X) MV of the AM mode are different, a scaled MV of the L(1-X) MV is obtained.
10. The method according to claim 9, further comprising: The scaled MV is obtained based on a scaling ratio calculated based on a temporal distance between the current picture and a reference picture of the LX MV and the L(1-X)MV of the AM mode.
11. The method of claim 1, wherein the L(1-X)MV is explicitly signaled in a bitstream to indicate which merge candidate is selected for the AM mode.
12. The method according to claim 1, wherein: When it is determined that at least some reference pictures have a display order after the current picture, a merge candidate with an L(1-X)MV is deemed invalid, wherein the reference picture of the L(1-X)MV of the merge candidate is in the same direction as the reference picture of the LX MV.
13. The method according to claim 1, wherein: When it is determined that all reference pictures have a display order before the current picture, only one L(1-X)MV of the AM mode is selected among all valid merge MV candidates as the MV with the minimum matching cost between the L(1-X) merge prediction block and the LX AMVP prediction block associated with each candidate, and the merge MV index is not signaled in the bitstream; and when it is determined that at least some reference pictures have a display order after the current picture, the merge MV index is signaled in the bitstream to indicate the L(1-X)MV of the AM mode.
14. The method according to claim 1, wherein: When it is determined that 'ph_mvd_l1_zero_flag' is enabled and the AM mode is enabled for the current picture or a slice of the current picture, a syntax element indicating a normal bi-directional prediction mode is not signaled in the bitstream.
15. A video encoding method, comprising: The encoder determines that the current picture or a slice of the current picture has Advanced Motion Vector Prediction AMVP-Merge AM mode enabled; Obtaining, by the encoder, an AMVP motion vector MV of a current block in the current picture as LX MV for a first reference picture list LX, where X is 0 or 1; Obtaining, by the encoder, a valid merge MV candidate list for a second reference picture list L(1-X), wherein the valid merge MV candidate list includes merge candidates having L(1-X) MVs; as well as The L(1-X) MV of the AM mode is selected by the encoder from the valid merged MV candidate list.
16. The method according to claim 15, wherein: Regardless of whether the reference picture of the L(1-X)MV of the merge candidate is in the opposite direction to the reference picture of the LXMV, the merge candidate having the L(1-X)MV is determined to be valid.
17. The method according to claim 15, wherein: Among all valid merge MV candidates, the L(1-X) MV of the AM mode is implicitly selected as the MV with the minimum matching cost between the L(1-X) merge prediction block and the LX AMVP prediction block associated with each candidate.
18. The method according to claim 15, wherein: When it is determined that only one reference picture can be used for the LX MV, the reference picture index is not signaled in the bitstream; or when it is determined that more than one reference picture can be used for the LX MV, the reference picture index is signaled in the bitstream.
19. The method of claim 15, wherein when it is determined that the template matching function is enabled, template matching MV refinement is conditionally applied to the LX MV or the L(1-X) MV of the AM mode having a higher template matching cost.
20. The method of claim 19, wherein the template matching MV refinement is applied to the LX MV having a higher template matching cost or the L(1-X) MV of the AM mode under the condition that all reference pictures have a display order before the current picture, or at least some reference pictures have a display order after the current picture.
21. The method of claim 15, wherein no template matching MV refinement is applied to the L(1-X) MV or LX MV of the AM pattern regardless of whether the template matching function is enabled.
22. The method of claim 15, wherein the L(1-X)MV of the AM mode is implicitly selected as the MV having the minimum difference between the LX MV and the L(1-X)MV.
23. The method of claim 15, further comprising: When it is determined that the reference picture of the LX MV is different from the reference picture of the L(1-X) MV of the AM mode, a scaled MV of the L(1-X) MV is obtained.
24. The method according to claim 23, further comprising: The scaled MV is obtained based on a scaling ratio calculated based on a temporal distance between the current picture and the reference picture of the LX MV and the L(1-X) MV of the AM mode.
25. The method of claim 15, wherein the L(1-X)MV is explicitly signaled in a bitstream to indicate which merge candidate is selected for the AM mode.
26. The method of claim 15, wherein upon determining that at least some reference pictures have a display order after the current picture, a merge candidate having an L(1-X) MV is deemed invalid, wherein the reference picture of the L(1-X) MV of the merge candidate is in the same direction as the reference picture of the LX MV.
27. The method of claim 15, wherein: When it is determined that all reference pictures have a display order before the current picture, only one L(1-X)MV of the AM mode is selected among all valid merge MV candidates as the MV with the minimum matching cost between the L(1-X) merge prediction block and the LX AMVP prediction block associated with each candidate, and the merge MV index is not signaled in the bitstream; and when it is determined that at least some reference pictures have a display order after the current picture, the merge MV index is signaled in the bitstream to indicate the L(1-X)MV of the AM mode.
28. The method of claim 15, wherein: When it is determined that 'ph_mvd_l1_zero_flag' is enabled and the current picture or a slice of the current picture has the AM mode enabled, a syntax element indicating a normal bi-directional prediction mode is not signaled in the bitstream.
29. A video decoding device, comprising: one or more processors; and a memory coupled to the one or more processors and configured to store instructions executable by the one or more processors, Wherein, when executing the instructions, the one or more processors are configured to perform the method according to any one of claims 1 to 14.
30. A video encoding device, comprising: one or more processors; and a memory coupled to the one or more processors and configured to store instructions executable by the one or more processors, Wherein, when executing the instructions, the one or more processors are configured to perform the method according to any one of claims 15 to 28.
31. A non-transitory computer-readable storage medium for storing computer-executable instructions, which, when executed by one or more computer processors, cause the one or more computer processors to receive a bit stream and perform the method according to any one of claims 1 to 14 based on the bit stream.
32. A non-transitory computer-readable storage medium for storing computer-executable instructions, which, when executed by one or more computer processors, cause the one or more computer processors to perform the method according to any one of claims 15 to 28 to encode the current block into a bit stream and transmit the bit stream.
