MVD Scaling for Joint MVD Coding
By deriving and scaling joint motion vector differences for video blocks, the method improves video coding efficiency by reducing redundancy and lowering bitrate requirements, addressing challenges in existing video coding technologies.
Patent Information
- Application Number
- JP2023556726
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2022-10-07
- Filing Date
- 2022-10-13
- Publication Date
- 2024-10-31
AI Technical Summary
Existing video coding technologies face challenges in efficiently compressing and decoding video data, particularly in reducing redundancy in motion vectors and motion vector differences, which affects compression efficiency and bitrate requirements.
The method involves deriving and scaling joint motion vector differences (MVD) for composite inter prediction of video blocks, quantizing the scaled MVD to achieve a desired precision, and signaling this information for improved compression and decoding.
This approach enhances video coding efficiency by reducing redundancy in motion vectors, leading to improved compression ratios and lower bitrate requirements without significant distortion.
Smart Images

Figure 2024539785000001_ABST
Abstract
Description
[Technical field]
[0001] [Incorporated by reference] This application is based on and claims the benefit of priority to U.S. Provisional Patent Application No. 63 / 281,010, filed November 18, 2021, and U.S. Provisional Patent Application No. 63 / 289,017, filed December 13, 2021, both of which are entitled "MVD Scaling for Joint MVD Coding," and U.S. Nonprovisional Patent Application No. 17 / 962,028, filed October 7, 2022. These prior patent applications are incorporated herein by reference in their entireties.
[0002] [Technical field] This disclosure relates generally to video coding, and more particularly to methods and systems for joint motion vector differential (MVD) derivation and scaling in MVD scaling for hybrid inter prediction of video blocks, and signaling therefor. [Background technology]
[0003] This background discussion provided herein is intended to generally present the context of the present disclosure. The work of the presently named inventors is not admitted expressly or impliedly as prior art to the present disclosure, as are aspects of the description that are not admitted as prior art at the time of the filing of this application, to the extent that such work is described in this background section.
[0004] Video coding and decoding can be performed using inter-picture prediction with motion compensation. Uncompressed digital video can include a sequence of pictures, each having spatial dimensions of, for example, 1920x1080 luminance samples and associated full or subsampled chrominance samples. The sequence of pictures can have a fixed or variable picture rate (alternatively called frame rate), for example, 60 pictures / second or 60 frames / second. Uncompressed video has specific bit rate requirements for streaming or data processing. For example, a video with a pixel resolution of 1920x1080, a frame rate of 60 frames / second, and chroma subsampling of 4:2:0 with 8 bits / pixel per color channel requires a bandwidth close to 1.5 Gbit / second. One hour of such video requires more than 600 gigabytes of storage space.
[0005] One goal of video coding and decoding may be to reduce redundancy in the uncompressed input video signal through compression. Compression can help reduce the aforementioned bandwidth and / or storage space requirements, in some cases by more than one order of magnitude. Both lossless and lossy compression and combinations of these may be employed. Lossless compression refers to techniques where an exact copy of the original signal can be reconstructed from the compressed original signal through the decoding process. Lossy compression refers to a coding / decoding process where the original video information is not fully preserved during coding and is not fully recoverable during decoding. When using lossy compression, the reconstructed signal may not be identical to the original signal, but the distortion between the original and reconstructed signals is made small enough to make the reconstructed signal useful for the intended application, albeit with some information loss. For video, lossy compression is widely adopted in many applications. The amount of acceptable distortion depends on the application. For example, users of a particular consumer video streaming application may tolerate higher distortion than users of a movie or television broadcast application. The compression ratio achievable by a particular coding algorithm may be selected or adjusted to reflect different distortion tolerances. A higher tolerable distortion generally allows for coding algorithms that result in higher loss and higher compression ratios.
[0006] Video encoders and decoders can utilize techniques from a number of broad categories and steps, including, for example, motion compensation, Fourier transform, quantization, and entropy coding.
[0007] Video codec technology can include a technique known as intra-coding. In intra-coding, sample values are represented without reference to samples or other data from previously reconstructed reference pictures. In some video codecs, a picture is spatially subdivided into blocks of samples. When all blocks of samples are coded in intra mode, the picture may be called an intra-picture. Intra-pictures and their derivatives, such as independent decoder refresh pictures, can be used to reset the decoder state and thus can be used as the first picture in a coded video bitstream and a video session or as a still image. The samples of the block after intra prediction can then undergo a transform to the frequency domain, and the transform coefficients so generated can be quantized before entropy coding. Intra-prediction represents a technique that minimizes sample values in the pre-transform domain. In some cases, the smaller the DC value after the transform and the smaller the AC coefficients, the fewer bits are required at a given quantization step size to represent the block after entropy coding.
[0008] Conventional intra-coding, for example as known from MPEG-2 generation coding techniques, does not use intra-prediction. However, some newer video compression techniques include techniques that attempt to code / decode a block based on surrounding sample data and / or metadata obtained during the encoding and / or decoding of its spatial neighbors and that precede in decoding order the block of data being intra-coded or decoded. Such techniques are hereinafter referred to as "intra-prediction" techniques. It should be noted that, at least in some cases, intra-prediction uses only reference data from the current picture being reconstructed and not from other reference pictures.
[0009] There may be many different forms of intra prediction. When more than one of such techniques are available in a given video coding technique, the technique in use may be referred to as an intra prediction mode. In a particular codec, one or more intra prediction modes may be provided. In certain cases, a mode may have sub-modes and / or may be associated with various parameters, and the mode / sub-mode information and intra coding parameters for a block of video may be coded individually or collectively included in a mode codeword. As to which codeword should be used for a given mode, sub-mode, and / or parameter combination, this may affect the coding efficiency gain from intra prediction, and therefore also the entropy coding technique used to convert the codeword into a bitstream.
[0010] Certain modes of intra prediction were introduced in H.264, improved in H.265, and further refined in newer coding techniques such as the Joint Search Model (JEM), Versatile Video Coding (VVC), and Benchmark Set (BMS). In general, for intra prediction, a predictor block may be formed using neighboring sample values that have become available. For example, available values of a particular set of neighboring samples along a particular direction and / or line may be copied into the predictor block. A reference to the direction in use may be codeable in the bitstream or may itself be predicted.
[0011] Referring to FIG. 1A, shown at the bottom right is a subset of the nine predictor directions defined in the 33 possible intra predictor directions of H.265 (corresponding to the 33 angle modes of the 35 intra modes defined in H.265). The point where the arrows converge (101) represents the sample being predicted. The arrows represent the direction in which neighboring samples are used to predict the sample of 101. For example, arrow (102) indicates that sample (101) is predicted from one or more neighboring samples to the top right at an angle of 45 degrees from the horizontal. Similarly, arrow (103) indicates that sample (101) is predicted from one or more neighboring samples to the bottom left of sample (101) at an angle of 22.5 degrees from the horizontal.
[0012] Continuing with reference to FIG. 1A, at the top left is shown a square block (104) of 4×4 samples (indicated by a thick dashed line). The square block (104) contains 16 samples, each of which is labeled with "S" and its position in the Y dimension (e.g., row index) and its position in the X dimension (e.g., column index). For example, sample S21 is the second sample (from the top) in the Y dimension and the first sample (from the left) in the X dimension. Similarly, sample S44 is the fourth sample in the block (104) in both the Y and X dimensions. Since the block is 4×4 samples in size, S44 is at the bottom right. Also shown are exemplary reference samples that follow a similar numbering scheme. The reference samples are labeled with R and their Y position (e.g., row index) and X position (column index) relative to the block (104). In both H.264 and H.265, predicted samples that neighbor the block being reconstructed are used.
[0013] Intra-picture prediction of block 104 may start by copying reference sample values from adjacent samples according to the signaled prediction direction. For example, assume that the coded video bitstream includes signaling for this block 104 indicating the prediction direction of the arrow (102), i.e., the sample is predicted from one or more prediction samples to the upper right at an angle of 45 degrees from the horizontal. In such a case, samples S41, S32, S23, and S14 are predicted from the same reference sample R05. And sample S44 is predicted from reference sample R08.
[0014] In certain cases, especially when the orientation is not evenly divisible by 45 degrees, the values of multiple reference samples may be combined, for example by interpolation, to calculate the reference sample.
[0015] As video coding technology continues to develop, the number of possible directions is increasing. For example, in H.264 (2003), nine different directions are available for intra prediction. In H.265 (2013), this increases to 33, and at the time of this disclosure, JEM / VVC / BMS can support up to 65 directions. Experimental studies have been conducted to help identify the most appropriate intra prediction directions, and certain techniques in entropy coding can be used to code those most appropriate directions with fewer bits while accepting certain bit penalties for the directions. Furthermore, the directions themselves can be predicted from neighboring directions used in intra prediction of decoded neighboring blocks.
[0016] FIG. 1B shows a schematic diagram (180) illustrating 65 intra prediction directions according to JEM to illustrate the increasing number of prediction directions in various coding techniques developed over time.
[0017] Methods for mapping bits representing intra-prediction directions to prediction directions in a coded video bitstream may vary from one video coding technique to another, and may range, for example, from simple direct mapping of prediction directions to intra-prediction modes, to codewords, complex adaptation schemes involving most probable modes, and similar techniques. In all cases, however, there may be certain directions for intra-prediction that are statistically less likely to occur in the video content than certain other directions. Since the goal of video compression is to reduce redundancy, those less likely directions may be represented by a larger number of bits than more likely directions in a well-designed video coding technique.
[0018] Inter-picture prediction or inter-prediction may be based on motion compensation. In motion compensation, sample data from a previously reconstructed picture or part thereof (reference picture) may be used to predict a newly reconstructed picture or picture part (e.g., block) after being spatially shifted in a direction indicated by a motion vector (hereinafter, MV). In some cases, the reference picture may be the same as the picture currently being reconstructed. The MV may have two dimensions X and Y, or three dimensions, with the third dimension being an indication of the reference picture in use (similar to the temporal dimension).
[0019] In some video compression techniques, the current MV applicable to a particular area of sample data is predictable from other MVs, e.g., from those other MVs related to other areas of sample data that are spatially adjacent to the area being reconstructed and that precede the current MV in decoding order. Doing so can substantially reduce the overall amount of data required to code the MV by relying on removing redundancy in correlated MVs, thereby increasing compression efficiency. MV prediction can work effectively because, for example, when coding an input video signal derived from a camera (known as natural video), there is a statistical possibility that areas larger than the area to which a single MV is applicable move in a similar direction in the video sequence, and therefore, in some cases, can be predicted using similar motion vectors derived from MVs of neighboring areas. As a result, the actual MV of a given area is similar or identical to the MV predicted from the surrounding MVs. Such an MV can be represented with fewer bits after entropy coding than would have been used if the MV was directly coded instead of predicted from the neighboring MV(s). In some cases, MV prediction can be an example of lossless compression of a signal (i.e., MV) derived from an original signal (i.e., sample stream). In other cases, the MV prediction itself may be lossy, for example due to rounding errors when computing a predictor from several surrounding MVs.
[0020] Various MV prediction mechanisms are described in H.265 / HEVC (ITU-T Rec. H.265, “High Efficiency Video Coding”, December 2016). Among the many MV prediction mechanisms specified by H.265, the one described below is a technique called “spatial merging” hereafter.
[0021] Specifically, referring to FIG. 2, a current block (201) contains samples that were discovered by the encoder during a motion search process to be predictable from a spatially shifted previous block of the same size. Instead of coding its MV directly, the MV may be derived from metadata associated with one or more reference pictures, e.g., from the most recent reference picture (in decoding order), using the MV associated with any one of five surrounding samples, denoted A0, A1, and B0, B1, B2 (202-206, respectively). In H.265, MV prediction may use predictors from the same reference picture as the neighboring blocks use. Summary of the Invention
[0022] The present disclosure generally relates to video coding, and in particular to a method and system for derivation and scaling of a joint motion vector differential (MVD) in MVD scaling for composite inter prediction of a video block, and signaling therefor. In one exemplary implementation, a method and a video device for processing a video block of a video stream are disclosed. For example, the method may include scaling a joint motion vector differential and quantizing the scaled motion vector differential to derive a predicted motion vector according to a pixel resolution of the predicted motion vector.
[0023] In an example implementation, a method for processing a video block of a video stream is disclosed. The method may include: extracting at least one flag from the video stream; and determining, based on the at least one flag, that the video block is inter-predicted by at least a first reference block in a first reference frame located by a first motion vector and a second reference block in a second reference frame located by a second motion vector, the first motion vector should be predicted by a first motion vector differential (MVD) relative to the first reference motion vector, and the second motion vector should be predicted by a second MVD relative to the second reference motion vector, where the first MVD and the second MVD are derived from a single MVD in the video stream. The method may further include receiving a single MVD from the video stream, scaling the single MVD to generate a scaled MVD, quantizing the scaled MVD to generate a quantized MVD having an MVD pixel resolution according to an allowed accuracy of the first motion vector or the second motion vector, generating one of the first motion vector or the second motion vector based on the quantized MVD and a corresponding reference motion vector among the first reference motion vector and the second reference motion vector, and reconstructing one of the first reference block or the second reference block for inter-predicting a video block from one of the first reference frame or the second reference frame based on the first motion vector or the second motion vector.
[0024] In the above implementation, the method may further include extracting, from the video stream, a first frame index for identifying the first reference frame and a second frame index for identifying the second reference frame.
[0025] In any one of the above implementations, at least one flag is signaled in the video stream before the first frame index and the second frame index.
[0026] In any one of the above implementations, the at least one flag includes an indication of a joint MVD mode among the set of composite inter prediction modes.
[0027] In any one of the above implementations, the set of composite inter prediction modes may include a joint MVD mode, in which both the first motion vector and the second motion vector are jointly predicted by a signaled MVD; a NEAR-NEAR inter prediction mode, in which both the first motion vector and the second motion vector are signaled without an MVD; a NEAR-NEW inter prediction mode, in which the first motion vector is signaled without an MVD and the second motion vector is predicted by a signaled MVD; a NEW-NEAR inter prediction mode, in which the second motion vector is signaled without an MVD and the first motion vector is predicted by a signaled MVD; and a NEW-NEW inter prediction mode, in which the first motion vector and the second motion vector are separately predicted by separately signaled MVDs.
[0028] In any one of the above implementations, the joint MVD mode includes a sub-mode of a composite NEW-NEW inter prediction mode in which both the first motion vector and the second motion vector are predicted rather than directly signaled, and at least one flag is included in the video stream and extracted from the video stream in response to the video block being predicted under the composite NEW-NEW inter prediction mode.
[0029] In any one of the above implementations, the MVD pixel resolution of one of the first MVD or the second MVD includes one of 1 / 64 pel, 1 / 32 pel, 1 / 16 pel, 1 / 8 pel, 1 / 4 pel, 1 / 2 pel, or one of integer pixel resolutions.
[0030] In any one of the above implementations, the MVD pixel resolution is pre-set or adaptively signaled in the video stream.
[0031] In any one of the above implementations, the MVD pixel resolution is lower than the as-scaled pixel resolution of the scaled MVD, and the scaled MVD is quantized by reducing the as-scaled pixel resolution of the scaled MVD to the MVD pixel resolution to generate a quantized MVD.
[0032] In any one of the above implementations, the step of scaling the single MVD to generate a scaled MVD is performed based on a first distance between the current frame of the video block and the first reference frame or a second distance between the current frame of the video block and the second reference frame.
[0033] In any one of the above implementations, one of the first motion vector or the second motion vector generated based on the quantized MVD corresponds to a first reference frame or a second reference frame belonging to a predefined reference frame list.
[0034] In any one of the above implementations, when the first distance is equal to the second distance, a scaling factor for performing the scaling is 1.
[0035] In any one of the above implementations, one of the first motion vector or the second motion vector generated based on the quantized MVD corresponds to a reference frame that is closer to the current frame among the first reference frame and the second reference frame. Alternatively, in any one of the above implementations, one of the first motion vector or the second motion vector generated based on the quantized MVD corresponds to a reference frame that is closer to the current frame among the first reference frame and the second reference frame.
[0036] In any one of the above implementations, the scaling step is performed based on an additional scaling factor other than the first distance and the second distance, the additional scaling factor being between −1 and 1.
[0037] In any one of the above implementations, the method may further include extracting the additional scaling factor from the video stream as part of a sequence parameter set (SPS), a video parameter set (VPS), a picture parameter set (PPS), a picture header, a tile header, a slice header, a frame header, or a coding tree unit header.
[0038] In any one of the above implementations, quantizing the scaled MVD includes removing N least significant bits from the scaled MVD, where N is an integer derived based on a difference between the MVD pixel resolution and the as-scaled pixel resolution of the scaled MVD. Alternatively, in any one of the above implementations, quantizing the scaled MVD includes adding a rounding factor and then removing N least significant bits from the scaled MVD, where N is an integer derived based on a difference between the MVD pixel resolution, the as-scaled pixel resolution of the scaled MVD, and the rounding factor.
[0039] Aspects of the present disclosure also provide a video encoding or decoding device or apparatus that includes a circuit or processor configured to perform any of the above method implementations.
[0040] Aspects of the present disclosure also provide a non-transitory computer-readable medium storing instructions that, when executed by a computer, cause the computer to perform a method for video decoding and / or encoding. [Brief description of the drawings]
[0041] Further features, nature and various advantages of the disclosed subject matter will become more apparent from the following detailed description and the accompanying drawings. [Figure 1A] 1 shows a schematic diagram of an example subset of intra-prediction direction modes. [Figure 1B] 1 shows a diagram of an exemplary intra-prediction direction. [Diagram 2] 1 illustrates a schematic diagram of a current block and its surrounding spatial merging candidates for motion vector prediction in an example. [Diagram 3] 1 shows a simplified block diagram schematic of a communication system (300) in accordance with an exemplary embodiment. [Figure 4] 4 shows a simplified block diagram schematic of a communication system (400) in accordance with an example embodiment. [Diagram 5] 1 shows a schematic diagram of a simplified block diagram of a video decoder according to an exemplary embodiment; [Figure 6] 1 shows a schematic diagram of a simplified block diagram of a video encoder according to an example embodiment; [Figure 7] 4 shows a block diagram of a video encoder according to another example embodiment. [Figure 8] 4 shows a block diagram of a video decoder according to another exemplary embodiment. [Figure 9] 1 illustrates a coding block partitioning scheme according to an exemplary embodiment of the present disclosure. [Figure 10]1 illustrates another scheme for coding block partitioning according to an exemplary embodiment of the present disclosure. [Figure 11] 1 illustrates another scheme for coding block partitioning according to an exemplary embodiment of the present disclosure. [Figure 12] 4 illustrates an exemplary partitioning of a base block into coding blocks according to an exemplary partitioning scheme. [Figure 13] 1 illustrates an exemplary ternary partitioning scheme. [Figure 14] 1 illustrates an exemplary quadtree / binary tree coding block partitioning scheme. [Figure 15] 1 illustrates a scheme for partitioning a coding block into multiple transform blocks and a coding order for the transform blocks, according to an example embodiment of this disclosure. [Figure 16] 1 illustrates another scheme for partitioning a coding block into multiple transform blocks and a coding order of the transform blocks according to an example embodiment of this disclosure. [Figure 17] 1 illustrates another scheme for partitioning a coding block into multiple transform blocks, according to an example embodiment of this disclosure. [Figure 18] 1 illustrates a flowchart of a method according to an exemplary embodiment of the present disclosure. [Figure 19] 1 shows a schematic diagram of a computer system according to an exemplary embodiment of the present disclosure. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0042] Throughout this specification and the claims, terms may have subtle meanings that are suggested or implied in the context beyond the explicitly stated meaning. The phrases "in one embodiment" or "in some embodiments" used in this specification do not necessarily refer to the same embodiment, and the phrases "in another embodiment" or "in other embodiments" used in this specification do not necessarily refer to different embodiments. Similarly, the phrases "in one implementation" or "in some implementations" used in this specification do not necessarily refer to the same implementation, and the phrases "in another implementation" or "in other implementations" used in this specification do not necessarily refer to different implementations. For example, the claimed subject matter is intended to include a combination of example embodiments / implementations in whole or in part.
[0043] Generally, terms may be understood at least in part from their usage in context. For example, terms such as "and," "or," or "and / or" as used herein may include various meanings that may depend at least in part on the context in which such terms are used. Typically, when "or" is used to relate a list, such as A, B, or C, it is intended to mean A, B, and C (used herein in an inclusive sense) as well as A, B, or C (used herein in an exclusive sense). In addition, the terms "one or more" or "at least one" as used herein may be used to describe any feature, structure, or characteristic in a singular sense or may be used to describe a combination of features, structures, or characteristics in a plural sense, depending at least in part on the context. Similarly, terms such as "a," "an," or "the" may be understood to convey a singular use or to convey a plural use, depending at least in part on the context. In addition, it may be understood that the terms "based on" or "determined by" are not intended to convey an exclusive set of factors, but instead may allow for the presence of additional factors not necessarily explicitly described, again at least in part depending on the context. FIG. 3 illustrates a simplified block diagram of a communication system (300) according to one embodiment of the present disclosure. The communication system (300) includes multiple terminal devices capable of communicating with each other, for example, via a network (350). For example, the communication system (300) includes a first pair of terminal devices (310) and (320) interconnected via the network (350). In the example of FIG. 3, the first pair of terminal devices (310) and (320) may perform unidirectional transmission of data. For example, the terminal device (310) may code video data (e.g., of a stream of video pictures captured by the terminal device (310)) for transmission to the other terminal device (320) via the network (350).The encoded video data may be transmitted in the form of one or more coded video bitstreams. The terminal device (320) may receive the coded video data from the network (350), decode the coded video data to recover video pictures, and display the video pictures according to the recovered video data. The unidirectional data transmission may be implemented in a media serving application, etc.
[0044] In another example, the communication system (300) includes a second pair of terminal devices (330) and (340) performing bidirectional transmission of coded video data, which may be implemented, for example, in a videoconferencing application. For the bidirectional transmission of data, in one example, each of the terminal devices (330) and (340) may code video data (e.g., of a stream of video pictures captured by the terminal device) for transmission to the other of the terminal devices (330) and (340) over the network (350). Each of the terminal devices (330) and (340) may also receive coded video data transmitted by the other of the terminal devices (330) and (340), decode the coded video data to recover the video pictures, and display the video pictures on an accessible display device according to the recovered video data.
[0045] In the example of FIG. 3, the terminal devices (310), (320), (330), and (340) may be implemented as a server, a personal computer, and a smartphone, although the applicability of the basic principles of the present disclosure may not be so limited. The embodiments of the present disclosure may be implemented in desktop computers, laptop computers, tablet computers, media players, wearable computers, dedicated video conferencing equipment, and / or the like. The network (350) represents any number or type of network that conveys coded video data between the terminal devices (310), (320), (330), and (340), including, for example, wireline (wired) and / or wireless communication networks. The communication network (350) may exchange data over circuit-switched, packet-switched, and / or other types of channels. Representative networks include telecommunications networks, local area networks, wide area networks, and / or the Internet. For purposes of this description, the architecture and topology of the network (350) may not be important to the operation of the present disclosure unless explicitly described herein.
[0046] 4 illustrates an arrangement of a video encoder and a video decoder in a video streaming environment as an example of an application of the disclosed subject matter. The disclosed subject matter may be equally applicable to other video applications, including, for example, video conferencing, digital TV broadcasting, gaming, virtual reality, storage of compressed video on digital media including CDs, DVDs, memory sticks, and the like.
[0047] A video streaming system may include a video source (401) for creating a stream of uncompressed video pictures or images (402), such as a video capture subsystem (413) that may include a digital camera. In one example, the stream of video pictures (402) includes samples recorded by the digital camera of the video source 401. The stream of video pictures (402), shown in bold to emphasize its high data volume compared to the encoded video data (404) (or coded video bitstream), may be processed by an electronic device (420) that includes a video encoder (403) coupled to the video source (401). The video encoder (403) may include hardware, software, or a combination thereof for enabling or implementing aspects of the disclosed subject matter, as described in more detail below. The encoded video data (404) (or encoded video bitstream (404)), shown with thin lines to emphasize its low data volume compared to the stream of uncompressed video pictures (402), may be stored on the streaming server (405) for future use or directly stored on a downstream video device (not shown). One or more streaming client subsystems, such as the client subsystems (406) and (408) of FIG. 4, may access the streaming server (405) to retrieve copies (407) and (409) of the encoded video data (404). The client subsystem (406) may include a video decoder (410), for example, within the electronic device (430). The video decoder (410) decodes the incoming copy of the encoded video data (407) and creates an outgoing stream of video pictures (411) that is uncompressed and can be rendered on a display (412) (e.g., a display screen) or other rendering device (not shown). The video decoder 410 may be configured to perform some or all of the various functions described in this disclosure.In some streaming systems, the encoded video data (404), (407), and (409) (e.g., video bitstreams) may be encoded according to a particular video coding / compression standard. Examples of such standards include ITU-T Recommendation H.265. In one example, a video coding standard under development is informally known as Versatile Video Coding (VVC). The disclosed subject matter may be used in the context of VVC and other video coding standards.
[0048] It should be noted that the electronic devices (420) and (430) may include other components (not shown). For example, the electronic device (420) may include a video decoder (not shown), and similarly, the electronic device (430) may include a video encoder (not shown).
[0049] 5 shows a block diagram of a video decoder (510) according to any of the following embodiments of the present disclosure. The video decoder (510) may be included in an electronic device (530). The electronic device (530) may include a receiver (531) (e.g., a receiving circuit). The video decoder (510) may be used in place of the video decoder (410) in the example of FIG. 4.
[0050] The receiver (531) may receive one or more coded video sequences to be decoded by the video decoder (510). In the same or another embodiment, one coded video sequence may be decoded at a time, where the decoding of each coded video sequence is independent of the other coded video sequences. Each video sequence may be associated with multiple video frames or images. The coded video sequences may be received from a channel (501), which may be a hardware / software link to a storage device that stores the coded video data or a streaming source that transmits the coded video data. The receiver (531) may receive the coded video data along with other data, such as coded audio data and / or auxiliary data streams, which may be forwarded to their respective processing circuits (not shown). The receiver (531) may separate the coded video sequences from other data. To combat network jitter, a buffer memory (515) may be disposed between the receiver (531) and the entropy decoder / parser (520) (hereinafter, "parser (520)"). In certain applications, the buffer memory (515) may be implemented as part of the video decoder (510). In other applications, it may be external and separate from the video decoder (510) (not shown). In still other applications, there may be a buffer memory (not shown) external to the video decoder (510), for example to combat network jitter, and there may be another additional buffer memory (515) internal to the video decoder (510), for example to handle playback timing. When the receiver (531) is receiving data from a storage / forwarding device with sufficient bandwidth and controllability, or from an isosynchronous network, the buffer memory (515) may not be needed or may be small. For use on a best-effort packet network such as the Internet, a buffer memory (515) of sufficient size may be needed, and its size may be relatively large.Such a buffer memory may be implemented with an adaptive size and may be implemented at least in part in an operating system or similar element (not shown) external to the video decoder (510).
[0051] The video decoder (510) may include a parser (520) for reconstructing symbols (521) from the coded video sequence. The categories of symbols include information used to manage the operation of the video decoder (510) and, in some cases, information for controlling a rendering device such as a display (512) (e.g., a display screen) that may or may not be an integral part of the electronic device (530) but may be coupled to the electronic device (530) as shown in FIG. 5. The control information for the rendering device(s) may be in the form of supplemental enhancement information (SEI message) or video usability information (VUI) parameter set fragments (not shown). The parser (520) may parse / entropy decode the coded video sequence received by the parser (520). The entropy coding of the coded video sequence may follow a video coding technique or standard and may follow various principles including variable length coding, Huffman coding, arithmetic coding with or without context sensitivity, etc. The parser (520) may extract, from the coded video sequence, a set of subgroup parameters for at least one of the subgroups of pixels in the video decoder based on at least one parameter corresponding to the subgroup. The subgroup may include a group of pictures (GOP), a picture, a tile, a slice, a macroblock, a coding unit (CU), a block, a transform unit (TU), a prediction unit (PU), etc. The parser (520) may also extract information from the coded video sequence, such as transform coefficients (e.g., Fourier transform coefficients), quantizer parameter values, motion vectors, etc.
[0052] The parser (520) may perform entropy decoding / parsing operations on the video sequence received from the buffer memory (515) to produce symbols (521).
[0053] The reconstruction of the symbols (521) may involve a number of different processing or functional units, depending on the type of coded video picture or portion thereof (such as inter-picture and intra-picture, inter-block and intra-block, etc.), and other factors. The units involved and how they are included may be controlled by subgroup control information parsed from the coded video sequence by the parser (520). The flow of such subgroup control information between the parser (520) and the following processing or functional units is not shown for simplicity.
[0054] Beyond the functional blocks already mentioned, the video decoder (510) may be conceptually subdivided into several functional units, as described below. In an actual implementation operating under commercial constraints, many of these functional units may interact closely with each other and may be at least partially integrated with each other. However, for purposes of clearly describing the various functions of the disclosed subject matter, a conceptual subdivision into functional units is adopted in the following disclosure.
[0055] The first unit may include a scalar / inverse transform unit (551). The scalar / inverse transform unit (551) may receive quantized transform coefficients and control information, including information indicating which type of inverse transform to use, block size, quantization factors / parameters, quantization scaling matrices, and lines as symbol(s) (521) from the parser (520). The scalar / inverse transform unit (551) may output blocks containing sample values that may be input to an aggregator (555).
[0056] In some cases, the output samples of the scaler / inverse transform unit (551) may relate to intra-coded blocks, i.e., blocks that do not use prediction information from a previously reconstructed picture, but can use prediction information from a previously reconstructed portion of the current picture. Such prediction information may be provided by an intra-picture prediction unit (552). In some cases, the intra-picture prediction unit (552) may generate a block of the same size and shape as the block being reconstructed using surrounding block information already reconstructed and stored in the current picture buffer (558). The current picture buffer (558) buffers, for example, a partially reconstructed current picture and / or a fully reconstructed current picture. The aggregator (555) may, in some implementations, add prediction information generated by the intra-picture prediction unit (552) to the output sample information provided by the scaler / inverse transform unit (551) on a sample-by-sample basis.
[0057] In other cases, the output samples of the scalar / inverse transform unit (551) may relate to an inter-coded, possibly motion-compensated, block. In such cases, the motion compensated prediction unit (553) may access the reference picture memory (557) to fetch samples used for inter-picture prediction. After motion compensating the fetched samples according to the symbols (521) associated with the block, these samples may be added by the aggregator (555) to the output of the scalar / inverse transform unit (551) (the output of unit 551 may be referred to as a residual sample or residual signal) to generate output sample information. The address in the reference picture memory (557) from which the motion compensated prediction unit (553) fetches the prediction samples may be controlled by a motion vector available to the motion compensated prediction unit (553) in the form of a symbol (521) that may have, for example, an X, a Y component (shift), and a reference picture component (time). Motion compensation may also include interpolation of sample values as fetched from a reference picture memory (557) when sub-sample accurate motion vectors are used, and may be associated with a motion vector prediction mechanism, etc.
[0058] The output samples of the aggregator (555) may be subjected to various loop filtering techniques in the loop filter unit (556). The video compression techniques may include in-loop filter techniques controlled by parameters contained in the coded video sequence (also called the coded video bitstream) and made available to the loop filter unit (556) as symbols (521) from the parser (520), but may also be responsive to meta-information obtained during decoding of a previous portion (in decoding order) of the coded picture or coded video sequence, or to previously reconstructed and loop filtered sample values. Several types of loop filters may be included as part of the loop filter unit 556 in various orders, as described in more detail below.
[0059] The output of the loop filter unit (556) may be a sample stream that can be output to a rendering device (512) as well as stored in a reference picture memory (557) for use in future inter-picture prediction.
[0060] Once a particular coded picture is fully reconstructed, it can be used as a reference picture for future inter-picture prediction. For example, once a coded picture corresponding to a current picture is fully reconstructed and the coded picture is identified as a reference picture (e.g., by the parser (520)), the current picture buffer (558) can become part of the reference picture memory (557), and a new current picture buffer can be reallocated before beginning reconstruction of the next coded picture.
[0061] The video decoder (510) may perform decoding operations according to a given video compression technique adopted in a standard such as ITU-T Rec. H.265. The coded video sequence may conform to a syntax specified by the video compression technique or standard being used in the sense that the coded video sequence conforms to both the syntax of the video compression technique or standard and the profile documented in the video compression technique or standard. Specifically, a profile may select a particular tool from all tools available in the video compression technique or standard as the only tool available for use under that profile. To conform to a standard, the complexity of the coded video sequence may be within a range defined by a level of the video compression technique or standard. In some cases, the level limits a maximum picture size, a maximum frame rate, a maximum reconstruction sample rate (e.g., measured in megasamples per second), a maximum reference picture size, etc. The limits set by the level may be further limited in some cases through a hypothetical reference decoder (HRD) specification and metadata for HRD buffer management signaled in the coded video sequence.
[0062] In some exemplary embodiments, the receiver (531) may receive additional (redundant) data along with the encoded video. The additional data may be included as part of the coded video sequence(s). The additional data may be used by the video decoder (510) to properly decode the data and / or to more accurately reconstruct the original video data. The additional data may be in the form of, for example, temporal, spatial, or signal-to-noise ratio (SNR) enhancement layers, redundant slices, redundant pictures, forward error correction codes, etc.
[0063] 6 shows a block diagram of a video encoder (603) according to an exemplary embodiment of the present disclosure. The video encoder (603) may be included in an electronic device (620). The electronic device (620) may further include a transmitter (640) (e.g., a transmission circuit). The video encoder (603) may be used in place of the video encoder (403) in the example of FIG. 4.
[0064] The video encoder (603) may receive video samples from a video source (601) (which is not part of the electronic device (620) in the example of FIG. 6) that may capture the video image(s) to be coded by the video encoder (603). In another example, the video source (601) may be implemented as part of the electronic device (620).
[0065] The video source (601) may provide a source video sequence to be coded by the video encoder (603) in the form of a digital video sample stream that may be of any suitable bit depth (e.g., 8-bit, 10-bit, 12-bit, ...), any color space (e.g., BT.601 YCrCb, RGB, XYZ ...), and any suitable sampling structure (e.g., YCrCb 4:2:0, YCrCb 4:4:4). In a media serving system, the video source (601) may be a storage device that can store previously prepared video. In a video conferencing system, the video source (601) may be a camera that captures local image information as a video sequence. The video data may be provided as a number of individual pictures or images that give motion when viewed in succession. The picture itself may be organized as a spatial array of pixels, where each pixel may contain one or more samples depending on the sampling structure, color space, etc. being used. Those skilled in the art can easily understand the relationship between pixels and samples. The following description focuses on samples.
[0066] According to some example embodiments, the video encoder (603) may code and compress pictures of a source video sequence into a coded video sequence (643) in real time or under any other time constraint required by the application. Enforcing an appropriate coding rate constitutes one function of the controller (650). In some embodiments, the controller (650) may be functionally coupled to and control other functional units, as described below. Coupling is not shown for simplicity. Parameters set by the controller (650) may include rate control related parameters (picture skip, quantizer, lambda value of rate distortion optimization techniques, ...), picture size, group of pictures (GOP) layout, maximum motion vector search range, etc. The controller (650) may be configured with other appropriate functions associated with the video encoder (603) optimized for a particular system design.
[0067] In some example embodiments, the video encoder (603) may be configured to operate in a coding loop. As an oversimplified explanation, in one example, the coding loop may include a source coder (630) (e.g., responsible for creating symbols, such as a symbol stream, based on an input picture to be coded and reference picture(s)) and a (local) decoder (633) embedded in the video encoder (603). The decoder (633) reconstructs the symbols to create sample data in a similar manner as the (remote) decoder would, even if the embedded decoder 633 processed the coded video stream by the source coder 630 without entropy coding (since any compression between the symbols and the coded video bitstream in entropy coding may be lossless in the video compression techniques considered in the disclosed subject matter). The reconstructed sample stream (sample data) is input to a reference picture memory (634). Since the decoding of the symbol stream results in bit-exact results independent of the location of the decoder (local or remote), the contents in the reference picture memory (634) are also bit-exact between the local and remote encoders. In other words, the predictive part of the encoder "sees" exactly the same sample values as the reference picture samples that the decoder will "see" when using the prediction during decoding. This basic principle of reference picture synchrony (and the resulting drift if synchrony cannot be maintained, e.g., due to channel errors) is used to improve coding quality.
[0068] The operation of the "local" decoder (633) may be the same as that of a "remote" decoder, such as the video decoder (510) already described in detail above in connection with Figure 5. However, with brief reference also to Figure 5, because symbols are available and the encoding / decoding of symbols into a coded video sequence by the entropy coder (645) and parser (520) may be lossless, the entropy decoding portion of the video decoder (510), including the buffer memory (515) and parser (520), may not be fully implemented in the local decoder (633) within the encoder.
[0069] An observation that can be made at this point is that any decoder technique, except for parsing / entropy decoding, which may only be present in the decoder, may necessarily also need to be present in the corresponding encoder in substantially the same functional form. For this reason, the disclosed subject matter may at times focus on decoder operations related to the decoding portion of the encoder. Thus, a description of the encoder technique may be omitted, since it is the reverse of the decoder technique described generically. Only in certain areas or aspects is a more detailed description of the encoder provided below.
[0070] During operation in some example implementations, the source coder (630) may perform motion-compensated predictive coding, which predictively codes an input picture with reference to one or more previously coded pictures from a video sequence designated as "reference pictures." In this manner, the coding engine (632) codes differences (or residuals) in color channels between pixel blocks of the input picture and pixel blocks of reference picture(s) that may be selected as predictive reference(s) to the input picture. The terms "residue" and its adjective form "residual" may be used interchangeably.
[0071] The local video decoder (633) may decode coded video data of pictures that may be designated as reference pictures based on symbols created by the source coder (630). The operation of the coding engine (632) may advantageously be a lossy process. When the coded video data may be decoded in a video decoder (not shown in FIG. 6), the reconstructed video sequence may be a replica of the source video sequence, typically with some errors. The local video decoder (633) may replicate the decoding process that may be performed by the video decoder on the reference pictures and store the reconstructed reference pictures in a reference picture cache (634). In this way, the video encoder (603) may locally store copies of reconstructed reference pictures that have common content with reconstructed reference pictures obtained by a far-end (remote) video decoder (without transmission errors).
[0072] The predictor (635) may perform the prediction search of the coding engine (632). That is, for a new picture to be coded, the predictor (635) may search the reference picture memory (634) for sample data (as candidate reference pixel blocks) or specific metadata such as reference picture motion vectors, block shapes, etc., that may serve as suitable prediction references for the new picture. The predictor (635) may operate on a sample block-by-pixel block basis to find a suitable prediction reference. In some cases, as determined by the search results obtained by the predictor (635), the input picture may have prediction references drawn from multiple reference pictures stored in the reference picture memory (634).
[0073] The controller (650) may manage the coding operations of the source coder (630), including, for example, setting the parameters and subgroup parameters used to encode the video data.
[0074] The output of all the aforementioned functional units may undergo entropy coding in entropy coder 645. The entropy coder (645) converts the symbols produced by the various functional units into a coded video sequence by losslessly compressing the symbols according to techniques such as Huffman coding, variable length coding, arithmetic coding, etc.
[0075] The transmitter (640) may buffer the coded video sequence(s) created by the entropy coder (645) in preparation for transmission over a communication channel (660), which may be a hardware / software link to a storage device that stores the coded video data. The transmitter (640) may merge the coded video data from the video encoder (603) with other data to be transmitted, such as coded audio data and / or auxiliary data streams (sources not shown).
[0076] The controller (650) may manage the operation of the video encoder (603). During coding, the controller (650) may assign a particular coded picture type to each coded picture, which may affect the coding technique that may be applied to the respective picture. For example, pictures may often be assigned as one of the following picture types:
[0077] An intra picture (I-picture) may be one that can be coded and decoded without using other pictures in a sequence as a source of prediction. Some video codecs allow different types of intra pictures, including, for example, independent decoder refresh ("IDR") pictures. Those skilled in the art are aware of these variations of I-pictures, as well as their respective uses and characteristics.
[0078] A predictive picture (P picture) may be one that can be coded and decoded using intra- or inter-prediction, which uses at most one motion vector and reference index to predict sample values for each block.
[0079] Bidirectionally predictive pictures (B-pictures) may be those that can be coded and decoded using intra- or inter-prediction, which uses at most two motion vectors and reference indices to predict the sample values of each block. Similarly, multiple-predictive pictures may use more than two reference pictures and associated metadata for the reconstruction of a single block.
[0080] A source picture may generally be spatially subdivided into multiple sample coding blocks (e.g., blocks of 4x4, 8x8, 4x8, or 16x16 samples each) and coded block-by-block. A block may be predictively coded with reference to other (already coded) blocks as determined by a coding assignment applied to the respective picture of the block. For example, a block of an I picture may be non-predictively coded or predictively coded with reference to an already coded block of the same picture (spatial or intra prediction). A pixel block of a P picture may be predictively coded via spatial prediction or via temporal prediction with reference to one previously coded reference picture. A block of a B picture may be predictively coded via spatial prediction or via temporal prediction with reference to one or two previously coded reference pictures. A source picture or an intermediate processed picture may be subdivided into other types of blocks for other purposes. The division of coding blocks and other types of blocks may or may not follow the same method, as described in more detail below.
[0081] The video encoder (603) may perform coding operations in accordance with a predetermined video coding technique or standard, such as ITU-T Rec. H.265. In its operations, the video encoder (603) may perform various compression operations, including predictive coding operations that exploit temporal and spatial redundancy in the input video sequence. Thus, the coded video data may conform to a syntax specified by the video coding technique or standard being used.
[0082] In some example embodiments, the transmitter (640) may transmit additional data along with the encoded video. The source coder (630) may include such data as part of the coded video sequence. The additional data may include temporal / spatial / SNR enhancement layers, other forms of redundant data such as redundant pictures and slices, SEI messages, VUI parameter set fragments, etc.
[0083] A video may be captured as multiple source pictures (video pictures) in a time sequence. Intra-picture prediction (often abbreviated as intra-prediction) exploits spatial correlation in a given picture, while inter-picture prediction exploits temporal or other correlation between pictures. For example, a particular picture being coded / decoded, called a current picture, may be partitioned into blocks. When a block in a current picture is similar to a reference block in a previously coded and still buffered reference picture in the video, it may be coded by a vector, called a motion vector. A motion vector points to a reference block in a reference picture and may have a third dimension that identifies the reference picture in question when multiple reference pictures are used.
[0084] In some exemplary embodiments, a bi-prediction technique may be used for inter-picture prediction. According to such a bi-prediction technique, two reference pictures are used, such as a first reference picture and a second reference picture, both of which precede the current picture in the video in decoding order (but may be past or future, respectively, in display order). A block in the current picture may be coded by a first motion vector that points to a first reference block in the first reference picture and a second motion vector that points to a second reference block in the second reference picture. A block may be co-predicted by a combination of the first reference block and the second reference block.
[0085] In addition, a merge mode technique may be used in inter-picture prediction to improve coding efficiency.
[0086] According to some exemplary embodiments of the present disclosure, predictions such as inter-picture prediction and intra-picture prediction are performed on a block-by-block basis. For example, a picture in a sequence of video pictures is partitioned into coding tree units (CTUs) for compression, and the CTUs in a picture may have the same size, such as 64×64 pixels, 32×32 pixels, or 16×16 pixels. In general, a CTU may include three parallel coding tree blocks (CTBs), i.e., one luma CTB and two chroma CTBs. Each CTU may be recursively quadtree partitioned into one or more coding units (CUs). For example, a CTU of 64×64 pixels may be partitioned into one CU of 64×64 pixels, or four CUs of 32×32 pixels. Each of one or more of the 32×32 blocks may be further partitioned into four CUs of 16×16 pixels. In some exemplary embodiments, each CU may be analyzed during encoding to determine the prediction type of that CU from among various prediction types, such as inter prediction type or intra prediction type. A CU may be divided into one or more prediction units (PUs) according to temporal and / or spatial predictability. In general, each PU includes one luma prediction block (PB) and two chroma PBs. In one embodiment, prediction operations during coding (encoding / decoding) are performed on a prediction block basis. The division of a CU into PUs (or PBs of different color channels) may be performed in various spatial patterns. For example, a luma or chroma PB may include a matrix of sample values (e.g., luma values), such as 8×8 pixels, 16×16 pixels, 8×16 pixels, 16×8 samples, etc.
[0087] 7 shows a diagram of a video encoder (703) according to another exemplary embodiment of the present disclosure. The video encoder (703) is configured to receive a processed block (e.g., a predictive block) of sample values in a current video picture in a sequence of video pictures and to encode the processed block into a coded picture that is part of a coded video sequence. The exemplary video encoder (703) may be used in place of the video encoder (403) in the example of FIG. 4.
[0088] For example, the video encoder (703) receives a matrix of sample values for a processing block, such as a predictive block of 8×8 samples. The video encoder (703) then determines whether the processing block is best coded using intra-mode, inter-mode, or bi-predictive mode, for example, using rate-distortion optimization (RDO). When it is determined that the processing block is coded in intra-mode, the video encoder (703) may use intra-prediction techniques to code the processing block into a coded picture, and when it is determined that the processing block is coded in inter-mode or bi-predictive mode, the video encoder (703) may use inter-prediction techniques or bi-prediction techniques to code the processing block into a coded picture, respectively. In some exemplary embodiments, merge mode may be used as a sub-mode of inter-picture prediction, where a motion vector is derived from one or more motion vector predictors without the aid of coded motion vector components outside the predictors. In some other exemplary embodiments, there may be motion vector components applicable to the current block. Accordingly, the video encoder (703) may include components not explicitly shown in FIG. 7, such as a mode decision module, to determine the prediction mode of a processing block.
[0089] In the example of FIG. 7, the video encoder (703) includes an inter-encoder (730), an intra-encoder (722), a residual calculator (723), a switch (726), a residual encoder (724), an overall controller (721), and an entropy encoder (725), coupled together as shown in the exemplary configuration of FIG.
[0090] The inter encoder (730) is configured to receive a sample of a current block (e.g., a processing block), compare the block to one or more reference blocks in a reference picture (e.g., blocks in previous and subsequent pictures in display order), generate inter prediction information (e.g., a description of redundant information due to inter encoding techniques, motion vectors, merge mode information), and calculate an inter prediction result (e.g., a predicted block) based on the inter prediction information using any suitable technique. In some examples, the reference picture is a decoded reference picture decoded based on the encoded video information using a decoding unit 633 embedded in the example encoder 603 of FIG. 6 (depicted as a residual decoder 728 of FIG. 7, as described in more detail below).
[0091] The intra encoder (722) is configured to receive samples of a current block (e.g., a processing block), compare the block with already coded blocks in the same picture, generate transformed quantized coefficients, and possibly generate intra prediction information (e.g., intra prediction direction information according to one or more intra encoding techniques). The intra encoder (722) may calculate intra prediction results (e.g., predicted blocks) based on the intra prediction information and reference blocks in the same picture.
[0092] The overall controller (721) may be configured to determine overall control data and control other components of the video encoder (703) based on the overall control data. In one example, the overall controller (721) determines a prediction mode of the block and provides a control signal to the switch (726) based on the prediction mode. For example, if the prediction mode is an intra mode, the overall controller (721) controls the switch (726) to select an intra mode result for use by the residual calculator (723) and controls the entropy encoder (725) to select intra prediction information and include the intra prediction information in the bitstream, and if the prediction mode of the block is an inter mode, the overall controller (721) controls the switch (726) to select an inter prediction result for use by the residual calculator (723) and controls the entropy encoder (725) to select inter prediction information and include the inter prediction information in the bitstream.
[0093] The residual calculator (723) may be configured to calculate a difference (residual data) between a received block and a prediction result for a block selected from the intra-encoder (722) or the inter-encoder (730). The residual encoder (724) may be configured to encode the residual data to generate transform coefficients. For example, the residual encoder (724) may be configured to transform the residual data from the spatial domain to the frequency domain to generate transform coefficients. The transform coefficients then undergo a quantization process to obtain quantized transform coefficients. In various exemplary embodiments, the video encoder (703) also includes a residual decoder (728). The residual decoder (728) is configured to perform an inverse transform and generate decoded residual data. The decoded residual data may be used by the intra-encoder (722) and the inter-encoder (730) as appropriate. For example, the inter-encoder (730) may generate decoded blocks based on the decoded residual data and the inter-prediction information, and the intra-encoder (722) may generate decoded blocks based on the decoded residual data and the intra-prediction information. The decoded blocks may be appropriately processed to generate decoded pictures, which may be buffered in a memory circuit (not shown) and used as reference pictures.
[0094] The entropy encoder (725) may be configured to format a bitstream to include the encoded blocks and perform entropy coding. The entropy encoder (725) may be configured to include various information in the bitstream. For example, the entropy encoder (725) may be configured to include overall control data, selected prediction information (e.g., intra-prediction information or inter-prediction information), residual information, and other suitable information in the bitstream. When coding a block in a merged sub-mode of either an inter mode or a bi-prediction mode, the residual information may be absent.
[0095] 8 shows a diagram of an exemplary video decoder (810) according to another embodiment of the present disclosure. The video decoder (810) is configured to receive coded pictures that are part of a coded video sequence and decode the coded pictures to generate reconstructed pictures. In one example, the video decoder (810) may be used in place of the video decoder (410) in the example of FIG. 4.
[0096] In the example of FIG. 8, the video decoder (810) includes an entropy decoder (871), an inter decoder (880), a residual decoder (873), a reconstruction module (874), and an intra decoder (872), coupled to each other as shown in the exemplary configuration of FIG. 8.
[0097] The entropy decoder (871) may be configured to reconstruct from the coded picture certain symbols representing syntax elements that make up the coded picture. Such symbols may include, for example, prediction information (e.g., intra- or inter-prediction information) that may identify the mode in which the block is coded (e.g., intra-mode, inter-mode, bi-prediction mode, merged sub-mode, or another sub-mode), certain samples or metadata used for prediction by the intra-decoder (872) or inter-decoder (880), residual information in the form of quantized transform coefficients, etc. In one example, if the prediction mode is an inter- or bi-prediction mode, the inter-prediction information is provided to the inter-decoder (880), and if the prediction type is an intra-prediction type, the intra-prediction information is provided to the intra-decoder (872). The residual information may undergo inverse quantization and is provided to the residual decoder (873).
[0098] The inter decoder (880) may be configured to receive inter prediction information and generate inter prediction results based on the inter prediction information.
[0099] The intra decoder (872) may be configured to receive intra prediction information and generate a prediction result based on the intra prediction information.
[0100] The residual decoder (873) may be configured to perform inverse quantization to extract inverse quantized transform coefficients and process the inverse quantized transform coefficients to transform the residual from the frequency domain to the spatial domain. The residual decoder (873) may also utilize certain control information (to include quantizer parameters (QP)), which may be provided by the entropy decoder (871) (data path not shown as this may be only low data volume control information).
[0101] The reconstruction module (874) may be configured to combine, in the spatial domain, the residual output by the residual decoder (873) with a prediction result (output by the inter prediction module or the intra prediction module, as the case may be) to form a reconstructed block that forms part of the reconstructed picture as part of the reconstructed video. It should be noted that other suitable operations, such as a deblocking operation, may also be performed to improve visual quality.
[0102] It should be noted that the video encoders (403), (603), and (703) and the video decoders (410), (510), and (810) may be implemented using any suitable technique. In some exemplary embodiments, the video encoders (403), (603), and (703) and the video decoders (410), (510), and (810) may be implemented using one or more integrated circuits. In another embodiment, the video encoders (403), (603), and (703) and the video decoders (410), (510), and (810) may be implemented using one or more processors executing software instructions.
[0103] Turning to block partitioning for coding and decoding, a general partitioning may start from a base block and may follow a predefined set of rules, a specific pattern, a partition tree, or any partition structure or scheme. The partitioning may be hierarchical and recursive. After splitting or partitioning the base block according to the exemplary partitioning procedure or any of the other procedures described below, or a combination thereof, a final set of partitions or coding blocks may be obtained. Each of these partitions may be at one of various partitioning levels in the partitioning hierarchy and may be of various shapes. Each of the partitions may be referred to as a coding block (CB). For various exemplary partitioning implementations described further below, each resulting CB may be of any of the allowed sizes and partitioning levels. Such partitions are referred to as coding blocks because they may form a unit around which some basic coding / decoding decisions may be made and coding / decoding parameters may be optimized, determined, and signaled in the encoded video bitstream. The highest or deepest level in the final partition represents the depth of the coding block partitioning structure of the tree. A coding block may be a luma coding block or a chroma coding block. The CB tree structure for each color may be referred to as a coding block tree (CBT).
[0104] The coding blocks of all color channels may be collectively referred to as a coding unit (CU). The hierarchical structure of all color channels may be collectively referred to as a coding tree unit (CTU). The partitioning pattern or structure for various color channels in a CTU may or may not be the same.
[0105] In some implementations, the partition tree scheme or structure used for the luma channel and the chroma channel may not need to be the same. In other words, the luma channel and the chroma channel may have separate coding tree structures or patterns. Furthermore, whether the luma channel and the chroma channel use the same or different coding partition tree structures, and the actual coding partition tree structure to be used, may depend on whether the slice being coded is a P slice, a B slice, or an I slice. For example, for an I slice, the chroma channel and the luma channel may have separate coding partition tree structures or coding partition tree structure modes, while for a P or B slice, the luma channel and the chroma channel may share the same coding partition tree scheme. When separate coding partition tree structures or modes are applied, the luma channel may be partitioned into CBs by one coding partition tree structure, and the chroma channel may be partitioned into chroma CBs by another coding partition tree structure.
[0106] In some exemplary implementations, a predefined partitioning pattern may be applied to the base block. As shown in FIG. 9, an exemplary 4-way partition tree may start at a first predefined level (e.g., 64×64 block level or other size as the base block size), and the base block may be partitioned hierarchically down to a predefined lowest level (e.g., 4×4 level). For example, the base block may receive four predefined partitioning options or patterns, as indicated by 902, 904, 906, and 908, and the partition designated as R allows for recursive partitioning in that the same partitioning options as shown in FIG. 9 may be repeated at a lower scale down to the lowest level (e.g., 4×4 level). In some implementations, additional restrictions may be applied to the partitioning scheme of FIG. 9. In the implementation of FIG. 9, rectangular partitions (e.g., 1:2 / 2:1 rectangular partitions) may be allowed, but they may not be allowed to be recursive, whereas square partitions are allowed to be recursive. Partitioning according to FIG. 9 with recursion generates a final set of coding blocks, if necessary. A coding tree depth may be further defined to indicate the partition depth from the root node or root block. For example, the coding tree depth for a root node or root block, e.g., a 64×64 block, may be set to 0, and the coding tree depth is increased by 1 after the root block is further divided according to FIG. 9. The maximum or deepest level from the 64×64 base block to the 4×4 smallest partition is 4 (starting from level 0) in the above scheme. Such a partitioning scheme may be applied to one or more of the color channels. Each color channel may be partitioned independently according to the scheme of FIG. 9 (e.g., partitioning patterns or options among predefined patterns may be determined independently for each of the color channels at each hierarchical level).Alternatively, two or more of the color channels may share the same hierarchical pattern tree as in FIG. 9 (e.g., the same partitioning pattern or options among predefined patterns may be chosen for two or more color channels at each hierarchical level).
[0107] FIG. 10 illustrates another exemplary predefined partitioning pattern that allows recursive partitioning to form a partitioning tree. As shown in FIG. 10, an exemplary 10-way partitioning structure or pattern may be predefined. A root block may start at a predefined level (e.g., from a base block at a 128×128 level or a 64×64 level). The exemplary partitioning structure of FIG. 10 includes various 2:1 / 1:2 and 4:1 / 1:4 rectangular partitions. A partition type having three subpartitions, indicated at 1002, 1004, 1006, and 1008 in the second row of FIG. 10, may be referred to as a “T-shaped” partition. The “T-shaped” partitions 1002, 1004, 1006, and 1008 may be referred to as a left T-shaped, an upper T-shaped, a right T-shaped, and a lower T-shaped. In some exemplary implementations, none of the rectangular partitions of FIG. 10 allow further subdivision. A coding tree depth may be further defined to indicate the division depth from the root node or root block. For example, the coding tree depth for the root node or root block, e.g., a 128x128 block, may be set to 0, and the coding tree depth is increased by 1 after the root block is further divided according to FIG. 10. In some implementations, only the full square partition at 1010 may be allowed to recursively partition to the next level of the partitioning tree according to the pattern of FIG. 10. In other words, recursive partitioning may not be allowed for the square partitions in the T-shaped patterns 1002, 1004, 1006, and 1008. The partitioning procedure according to FIG. 10 with recursion generates a final set of coding blocks, as necessary. Such a scheme may be applied to one or more of the color channels. In some implementations, more flexibility may be added to the use of partitions below the 8x8 level. For example, 2x2 chroma inter prediction may be used in certain cases.
[0108] In some other example implementations for coding block partitioning, a quadtree structure may be used to divide a base block or an intermediate block into quadtree partitions. Such quadtree division may be applied hierarchically and recursively to any square partition. Whether a base block or an intermediate block or partition is further quadtree divided may be adapted to various local characteristics of the base block or intermediate block / partition. The quadtree partitioning at the picture boundary may be further adapted. For example, an implicit quadtree division may be performed at the picture boundary such that a block continues to be quadtree divided until its size fits the picture boundary.
[0109] In some other example implementations, hierarchical binary partitioning from a base block may be used. For such a scheme, a base block or a mid-level block may be partitioned into two partitions. The binary partitioning may be either horizontal or vertical. For example, horizontal binary partitioning may divide a base block or a mid-level block into equal right and left partitions. Similarly, vertical binary partitioning may divide a base block or a mid-level block into equal top and bottom partitions. Such binary partitioning may be hierarchical and recursive. At each of the base or mid-level blocks, a decision may be made as to whether the binary partitioning scheme should continue and, if the scheme continues further, whether horizontal or vertical binary partitioning should be used. In some implementations, further partitioning may stop at a predefined minimum partition size (in one or both dimensions). Alternatively, further partitioning may stop when a predefined partitioning level or depth from the base block is reached. In some implementations, the aspect ratio of the partitions may be limited. For example, the aspect ratio of a partition will not be smaller than 1:4 (or larger than 4:1). Thus, a vertical strip partition having a 4:1 vertical-to-horizontal aspect ratio may be further binary partitioned only vertically into a top partition and a bottom partition, each having a 2:1 vertical-to-horizontal aspect ratio.
[0110] In yet some other examples, a ternary partitioning scheme may be used to partition the base block or any intermediate blocks, as shown in FIG. 13. The ternary pattern may be implemented vertically, as shown in 1302 of FIG. 13, or horizontally, as shown in 1304 of FIG. 13. The exemplary division ratio of FIG. 13 is shown as 1:2:1, either vertically or horizontally, but other ratios may be predefined. In some implementations, two or more different ratios may be predefined. Such a ternary partitioning scheme may be used to complement a quadtree or binary tree partitioning structure, in that while quadtrees and binary trees always divide along block centers, resulting in objects being divided into separate partitions, such ternary tree partitioning is capable of capturing objects located at block centers in one contiguous partition. In some implementations, the width and height of the exemplary ternary tree partitions are always powers of two to avoid additional transformations.
[0111] The above partitioning schemes may be combined in any manner at different partitioning levels. As an example, the above-described quadtree and binary partitioning schemes may be combined to partition the base block into a quadtree-binary tree (QTBT) structure. In such a scheme, the base block or intermediate blocks / partitions may be either quadtree partitioned or binary partitioned according to a set of predefined conditions, if specified. A specific example is shown in FIG. 14. In the example of FIG. 14, the base block is first quadtree partitioned into four partitions, as shown by 1402, 1404, 1406, and 1408. Each of the resulting partitions is then either quadtree partitioned into four further partitions (such as 1408), binary partitioned into two further partitions at the next level (such as 1402 or 1406, both symmetrical, either horizontally or vertically), or not partitioned (1404). Binary or quadtree partitioning may be allowed recursively for square partitions, as shown by the overall example partition pattern in 1410 and the corresponding tree structure / representation in 1420, where solid lines represent quadtree partitioning and dashed lines represent binary partitioning. A flag may be used for each binary partition node (non-leaf binary partition) to indicate whether the binary partitioning is horizontal or vertical. For example, as shown in 1420, consistent with the partitioning structure in 1410, flag "0" may represent horizontal binary partitioning and flag "1" may represent vertical binary partitioning. In the case of quadtree partitioned partitions, there is no need to indicate the partition type, since quadtree partitioning always splits a block or partition both horizontally and vertically to generate four sub-blocks / partitions with equal size. In some implementations, flag "1" may represent horizontal binary partitioning and flag "0" may represent vertical binary partitioning.
[0112] In some example implementations of QTBT, the quadtree and binary splitting rule sets may be represented by the following predefined parameters and their associated corresponding functions: - CTU size: Size of the root node of the quadtree (size of the base block) - MinQTSize: The minimum allowable quadtree leaf node size. - MaxBTSize: Maximum allowed binary tree root node size - MaxBTDepth: Maximum allowed binary tree depth - MinBTSize: The minimum allowable binary tree leaf node size In some example implementations of the QTBT partitioning structure, the CTU size may be set as 128×128 luma samples with two corresponding 64×64 blocks of chroma samples (when considering and using the example chroma subsampling), MinQTSize may be set as 16×16, MaxBTSize may be set as 64×64, MinBTSize (both width and height) may be set as 4×4, and MaxBTDepth may be set as 4. Quad-tree partitioning may be applied to the CTU first to generate quad-tree leaf nodes. The quad-tree leaf nodes may have a size from its minimum allowed size of 16×16 (i.e., MinQTSize) to 128×128 (i.e., CTU size). If a node is 128×128, it will not be split by the binary tree first because the size exceeds MaxBTSize (i.e., 64×64). Otherwise, nodes that do not exceed MaxBTSize may be partitioned by binary tree. In the example of FIG. 14, the base block is 128×128. The base block can only be quadtree partitioned according to a predefined set of rules. The base block has a partitioning depth of 0. Each of the resulting four partitions is 64×64, does not exceed MaxBTSize, and may be further quadtree or binary tree partitioned at level 1. The process continues. When the binary tree depth reaches MaxBTDepth (i.e., 4), no further partitions will be considered. When a binary tree node has a width equal to MinBTSize (i.e., 4), no further horizontal partitions will be considered. Similarly, when the height of a binary tree node is equal to MinBTSize, no further vertical partitions will be considered.
[0113] In some example implementations, the above QTBT schemes may be configured to support flexibility for luma and chroma to have the same or separate QTBT structures. For example, for P slices and B slices, the luma CTB and chroma CTB in one CTU may share the same QTBT structure. However, for I slices, the luma CTB may be partitioned into CBs by a QTBT structure, and the chroma CTB may be partitioned into chroma CBs by another QTBT structure. This means that CUs may be used to refer to different color channels in an I slice, for example, an I slice may be composed of one luma component coding block or two chroma component coding blocks, and a CU in a P slice or B slice may be composed of all three color component coding blocks.
[0114] In some other implementations, the QTBT scheme may be supplemented with the ternary scheme described above. Such implementations may be referred to as a multi-type tree (MTT) structure. For example, in addition to the binary partitioning of the nodes, one of the ternary partition patterns of FIG. 13 may be chosen. In some implementations, only square nodes may be subject to ternary partitioning. An additional flag may be used to indicate whether the ternary partitioning is horizontal or vertical.
[0115] The design of two-level or multi-level trees, such as the QTBT implementation and the QTBT implementation supplemented by ternary partitioning, may be motivated primarily by complexity reduction. In theory, the complexity of traversing a tree can be reduced by T D where T denotes the number of split types and D is the depth of the tree. Trade-offs can be made by using multiple types (T) while reducing the depth (D).
[0116] In some implementations, the CB may be further partitioned. For example, the CB may be further partitioned into multiple prediction blocks (PBs) for the purpose of intra- or inter-frame prediction during the coding and decoding process. In other words, the CB may be further divided into different sub-partitions at which individual prediction decisions / configurations may be made. In parallel, the CB may be further partitioned into multiple transform blocks (TBs) for the purpose of delineating the level at which the transformation or inverse transformation of the video data is performed. The partitioning scheme of the CB into PBs and TBs may be the same or different. For example, each partitioning scheme may be performed using its own procedure, for example, based on various characteristics of the video data. The PB and TB partitioning schemes may be independent in some exemplary implementations. The PB and TB partitioning schemes and boundaries may be correlated in some other exemplary implementations. In some implementations, for example, the TB may be partitioned into PB partitions, and in particular, the PB may be further partitioned into one or more TBs after being determined according to the partitioning of the coding blocks. For example, in some implementations, the PB may be divided into one, two, four, or other number of TBs.
[0117] In some implementations, the luma and chroma channels may be treated differently for partitioning base blocks into coding blocks and further partitioning into predictive and / or transform blocks. For example, in some implementations, partitioning of coding blocks into predictive and / or transform blocks may be allowed for the luma channel, but such partitioning of coding blocks into predictive and / or transform blocks may not be allowed for the chroma channel(s). In such implementations, transform and / or prediction of luma blocks may thus be performed only at the coding block level. In another example, the minimum transform block size for the luma and chroma channel(s) may be different, e.g., coding blocks for the luma channel may be allowed to be partitioned into smaller transform and / or predictive blocks than the chroma channels. As yet another example, the maximum depth of partitioning of coding blocks into transform and / or predictive blocks may differ between luma and chroma channels, e.g., coding blocks for the luma channel may be allowed to be partitioned into deeper transform and / or predictive blocks than the chroma channel(s). In a specific example, a luma coding block may be partitioned into transform blocks of multiple sizes that can be expressed with recursive partitions going up to two levels down, and transform block shapes such as square, 2:1 / 1:2, and 4:1 / 1:4, as well as transform block sizes from 4×4 to 64×64 may be allowed. However, for chroma blocks, only the largest possible transform block specified for the luma block may be allowed.
[0118] In some example implementations for partitioning a coding block into PBs, the depth, shape, and / or other characteristics of the PB partitioning may depend on whether the PB is intra-coded or inter-coded.
[0119] Partitioning of coding blocks (or predictive blocks) into transform blocks may be implemented in various exemplary manners, including but not limited to recursive or non-recursive quadtree partitioning and predefined pattern partitioning, with additional consideration of transform blocks at coding or predictive block boundaries. In general, the resulting transform blocks may be at different partitioning levels, may not be the same size, and may not need to be square in shape (e.g., they may be rectangular with some allowed size and aspect ratio). Further examples are described in more detail below with respect to Figures 15, 16, and 17.
[0120] However, in some other implementations, the CB obtained through any of the above partitioning schemes may be used as a basic or minimum coding block for prediction and / or transformation. In other words, no further partitioning is performed for inter-prediction / intra-prediction purposes and / or transformation purposes. For example, the CB obtained from the above QTBT scheme may be directly used as a unit for performing prediction. Specifically, such a QTBT structure removes the concept of multiple partition types, i.e., it removes the separation of CU, PU and TU, and supports more flexibility for CU / CB partition shapes as described above. In such a QTBT block structure, the CU / CB can have either a square or rectangular shape. The leaf nodes of such a QTBT are used as units for prediction and transformation processing without further partitioning. This means that the CU, PU, and TU have the same block size in such an exemplary QTBT coding block structure.
[0121] The various CB partitioning schemes described above, as well as further partitioning of the CB into PB and / or TB (including no PB / TB partitioning), may be combined in any manner. The following specific implementations are provided as non-limiting examples.
[0122] A specific exemplary implementation of coding block and transform block partitioning is described below. In such an exemplary implementation, a base block may be divided into coding blocks using a recursive quadtree division or a predefined division pattern described above (such as those in Figures 9 and 10). At each level, whether to continue further quadtree division of a particular partition may be determined by local video data characteristics. The resulting CBs may be at various quadtree division levels and various sizes. A decision on whether to code a picture area using inter-picture (temporal) prediction or intra-picture (spatial) prediction may be made at the CB level (or at the CU level for all three color channels). Each CB may be further divided into one, two, four, or other number of PBs according to a predefined PB division type. Inside one PB, the same prediction process may be applied, and related information may be transmitted to the decoder for each PB. After obtaining the residual block by applying a prediction process based on the PB division type, the CB may be partitioned into TBs according to another quadtree structure similar to the coding tree for the CB. In this particular implementation, the CB or TB may be limited to a square, but need not be limited thereto. Furthermore, in this particular example, the PB may be square or rectangular for inter prediction, and only square for intra prediction. A coding block may be divided, for example, into four square TBs. Each TB may be further divided recursively (using quadtree partitioning) into smaller TBs called residual quadtrees (RQTs).
[0123] Another exemplary implementation for partitioning a base block into CB, PB, and / or TB is further described below. For example, rather than using multiple partition unit types such as those shown in FIG. 9 or FIG. 10, a quadtree with nested multi-type tree using a binary and ternary partition segmentation structure (e.g., QTBT or QTBT with ternary partitioning as described above) may be used. Separation of CB, PB, and TB (i.e., partitioning of CB into PB and / or TB and partitioning of PB into TB) may be abandoned except when required for CBs with a size that is too large for the maximum transform length, and such CBs may require further partitioning. This exemplary partitioning scheme may be designed to support more flexibility for CB partition shapes, such that both prediction and transformation may be performed at the CB level without further partitioning. In such a coding tree structure, the CB may have either a square or rectangular shape. Specifically, the coding tree block (CTB) may be first partitioned by a quadtree structure. The quadtree leaf nodes can then be further partitioned by a nested multi-type tree structure. An example of a nested multi-type tree structure using binary or ternary partitioning is shown in FIG. 11. Specifically, the exemplary multi-type tree structure in FIG. 11 includes four partition types called vertical binary partitioning (SPLIT_BT_VER) (1102), horizontal binary partitioning (SPLIT_BT_HOR) (1104), vertical ternary partitioning (SPLIT_TT_VER) (1106), and horizontal ternary partitioning (SPLIT_TT_HOR) (1108). And CB corresponds to the leaf of the multi-type tree. In this exemplary implementation, as long as CB is not too large for the maximum transform length, this segmentation is used for both prediction and transform processing without further partitioning. This means that in most cases, CB, PB, and TB have the same block size in a quadtree with a nested multi-type tree coding block structure.An exception occurs when the maximum supported transform length is smaller than the width or height of the color components of the CB. In some implementations, in addition to binary or ternary partitioning, the nested pattern of FIG. 11 may further include a quadtree partitioning.
[0124] One specific example for quadtree with nested multi-type tree coding block structure of block partition (including quadtree, binary, and ternary split options) for one base block is shown in FIG. 12. More specifically, FIG. 12 shows that a base block 1200 is quadtree split into four square partitions 1202, 1204, 1206, and 1208. A decision to further use the multi-type tree structure and quadtree of FIG. 11 for further splitting is made for each of the quadtree split partitions. In the example of FIG. 12, partition 1204 is not split any further. Partitions 1202 and 1208 each adopt another quadtree split. For partition 1202, the second level quadtree split upper left, upper right, lower left, and lower right partitions adopt third level split of quadtree, horizontal binary split 1104 of FIG. 11, non-split, and horizontal ternary split 1108 of FIG. 11, respectively. Partition 1208 adopts another quadtree partitioning, and the second-level quadtree partitioned top-left, top-right, bottom-left, and bottom-right partitions adopt the third-level partitioning of vertical ternary partitioning 1106, not partitioned, not partitioned, and horizontal binary partitioning 1104 of FIG. 11, respectively. Two of the subpartitions of the top-left partition of the third level of 1208 are further divided according to horizontal binary partitioning 1104 and horizontal ternary partitioning 1108 of FIG. 11, respectively. Partition 1206 adopts the partitioning pattern according to vertical binary partitioning 1102 of FIG. 11 at the second level into two partitions, and these partitions are further divided according to horizontal ternary partitioning 1108 and vertical binary partitioning 1102 of FIG. 11 at the third level. A fourth-level partitioning is further applied to one of them according to horizontal binary partitioning 1104 of FIG. 11.
[0125] In the above specific example, the maximum luma transform size may be 64×64, and the maximum supported chroma transform size may differ, for example, luma at 32×32. Although the above example CB in FIG. 12 is generally not further divided into smaller PBs and / or TBs, when the width or height of a luma coding block or chroma coding block is larger than the maximum transform width or height, the luma coding block or chroma coding block may be automatically divided horizontally and / or vertically to meet the transform size limitation in that direction.
[0126] In a specific example for partitioning the above base blocks into CBs, as described above, the coding tree scheme may support the ability for luma and chroma to have separate block tree structures. For example, for P slices and B slices, the luma CTB and chroma CTB in one CTU may share the same coding tree structure. For I slices, for example, luma and chroma may have separate coding block tree structures. When separate block tree structures are applied, the luma CTB may be partitioned into luma CBs by one coding tree structure, and the chroma CTB is partitioned into chroma CBs by another coding tree structure. This means that a CU in an I slice may be composed of one luma component coding block or two chroma component coding blocks, and a CU in a P or B slice is always composed of coding blocks of all three color components, unless the video is monochrome.
[0127] When a coding block is further partitioned into multiple transform blocks, the transform blocks therein may be ordered in the bitstream according to various orders or scanning methods. Exemplary implementations for partitioning a coding block or a predictive block into transform blocks and the coding order of the transform blocks are described in further detail below. In some exemplary implementations, as described above, the transform partitioning may support transform blocks of multiple shapes, e.g., 1:1 (square), 1:2 / 2:1, and 1:4 / 4:1, with transform block sizes ranging, e.g., from 4×4 to 64×64. In some implementations, when a coding block is 64×64 or smaller, the transform block partitioning may be applied only to the luma component, and thus, for chroma blocks, the transform block size is the same as the coding block size. Otherwise, if the coding block width or height is greater than 64, both the luma coding block and the chroma coding block may be implicitly divided into multiples of min(W,64)×min(H,64) and min(W,32)×min(H,32) transform blocks, respectively.
[0128] In some example implementations of transform block partitioning, for both intra-coded and inter-coded blocks, the coding block may be further partitioned into multiple transform blocks at a partition depth up to a predefined number of levels (e.g., two levels). The transform block partition depth and size may be related. For some example implementations, the mapping from the transform size of the current depth to the transform size of the next depth is shown in Table 1 below. [Table 1]
[0129] Based on the example mapping of Table 1, for a 1:1 square block, the next level transform partition may create four 1:1 square sub-transform blocks. The transform partition may stop at, for example, 4×4. So, a transform size of 4×4 at the current depth corresponds to the same size of 4×4 at the next depth. In the example of Table 1, for a 1:2 / 2:1 non-square block, the next level transform partition may create two 1:1 square sub-transform blocks, while for a 1:4 / 4:1 non-square block, the next level transform partition may create two 1:2 / 2:1 sub-transform blocks.
[0130] In some example implementations, for the luma components of intra-coded blocks, additional restrictions may be applied regarding transform block partitioning. For example, for each level of transform partitioning, all sub-transform blocks may be restricted to have equal size. For example, for a 32×16 coding block, level 1 transform partitioning creates two 16×16 sub-transform blocks, and level 2 transform partitioning creates eight 8×8 sub-transform blocks. In other words, the second level partitioning must be applied to all first level sub-blocks to keep the transform units equal in size. An example of transform block partitioning for an intra-coded square block according to Table 1 is shown in FIG. 15 with the coding order indicated by the arrows. Specifically, 1502 shows a square coding block. The first level partitioning according to Table 1 into four equal-sized transform blocks is shown in 1504 with the coding order indicated by the arrows. The second level partitioning according to Table 1 into all 16 equal-sized transform blocks is shown in 1506 with the coding order indicated by the arrows.
[0131] In some example implementations, for the luma components of an inter-coded block, the above restrictions for intra-coding may not apply. For example, after the first level of transform partitioning, any one of the sub-transform blocks may be partitioned independently at another level. Thus, the resulting transform blocks may or may not be of the same size. An example partitioning of an inter-coded block into transform blocks is shown in FIG. 16 along with their coding order. In the example of FIG. 16, an inter-coded block 1602 is partitioned into transform blocks at two levels according to Table 1. At the first level, the inter-coded block is partitioned into four transform blocks of equal size. Then, as indicated by 1604, only one of the four transform blocks (but not all of them) is further partitioned into four sub-transform blocks, resulting in a total of seven transform blocks with two different sizes. An example coding order of these seven transform blocks is indicated by arrows at 1604 in FIG. 16.
[0132] In some example implementations, for the chroma component(s), some additional restrictions for the transform block may be applied. For example, for the chroma component(s), the transform block size can be as large as the coding block size, but cannot be smaller than a predefined size, e.g., 8×8.
[0133] In some other example implementations, for coding blocks with either width (W) or height (H) greater than 64, both luma and chroma coding blocks may be implicitly divided into multiples of min(W,64)×min(H,64) and min(W,32)×min(H,32) transform units, respectively, where in this disclosure, “min(a,b)” may return the smaller of a and b.
[0134] Figure 17 further illustrates another alternative exemplary scheme for partitioning coding blocks or predictive blocks into transform blocks. As shown in Figure 17, instead of using recursive transform partitioning, a predefined set of partitioning types may be applied to a coding block according to the transform type of the coding block. In the particular example shown in Figure 17, one of six exemplary partitioning types may be applied to split the coding block into various numbers of transform blocks. Such a scheme for generating transform block partitioning may be applied to either coding blocks or predictive blocks.
[0135] More specifically, the partitioning scheme of FIG. 17 provides up to six exemplary partition types for any given transform type (transform type refers to the type of primary transform, e.g., ADST). In this scheme, every coding or predictive block may be assigned a transform partition type based on, e.g., rate-distortion cost. In one example, the transform partition type assigned to a coding or predictive block may be determined based on the transform type of the coding or predictive block. A particular transform partition type may correspond to a transform block partition size and pattern, as illustrated by the six transform partition types illustrated in FIG. 17. The correspondence between various transform types and various transform partition types may be predefined. An example is shown below, with capitalized labels indicating transform partition types that may be assigned to a coding or predictive block based on rate-distortion cost: · PARTITION_NONE: Allocates a transformation size equal to the block size. · PARTITION_SPLIT: Allocates a transformation size that is 1 / 2 the width of the block size and 1 / 2 the height of the block size. · PARTITION_HORZ: Allocates a transformation size with width equal to the block size and height 1 / 2 the block size. · PARTITION_VERT: Allocates a transformation size with a width half the block size and a height equal to the block size. · PARTITION_HORZ4: Allocates a transformation size with width equal to the block size and height 1 / 4 of the block size. · PARTITION_VERT4: Allocates a transformation size with width 1 / 4 of the block size and height equal to the block size.
[0136] In the above example, all transform partition types include a uniform transform size for the partitioned transform blocks, as shown in Figure 17. This is merely an example and not a limitation. In some other implementations, mixed transform block sizes may be used for the partitioned transform blocks in a particular partition type (or pattern).
[0137] The PBs (or CBs, also called PBs when not further partitioned into predictive blocks) obtained from any of the above partitioning schemes can then become individual blocks for coding via either intra-prediction or inter-prediction. In the case of inter-prediction for the current PB, a residual between the current block and the predictive block can be generated, coded, and included in the coded bitstream.
[0138] Inter prediction may be implemented, for example, in single reference mode or mixed reference mode. In some implementations, a skip flag may be included in the (or higher level) bitstream for the current block first to indicate whether the current block is inter-coded and should not be skipped. If the current block is inter-coded, another flag may be further included as a signal in the bitstream to indicate whether a single reference mode or a mixed reference mode is used for predicting the current block. In the case of a single reference mode, one reference block may be used to generate a predictive block for the current block. In the case of a mixed reference mode, two or more reference blocks may be used to generate a predictive block, for example, by weighted averaging. A mixed reference mode may be referred to as a more-than-one-reference mode, a two-reference mode, or a multiple-reference mode. One or more reference blocks may be identified using one or more reference frame indexes and additionally using one or more corresponding motion vectors indicating a location relative to the frame, for example, a shift(s) between the reference block(s) and the current block in horizontal and vertical pixels. For example, in a single reference mode, an inter-predicted block for a current block may be generated from a single reference block identified as a predictive block by one motion vector in a reference frame, while in a mixed reference mode, the predictive block may be generated by a weighted average of two reference blocks in two reference frames indicated by two reference frame indexes and two corresponding motion vectors. The motion vector(s) may be coded in various ways and included in the bitstream.
[0139] In some implementations, the encoding or decoding system may maintain a decoded picture buffer (DPB). Some images / pictures are maintained in the DPB waiting to be displayed (in the decoding system), and some images / pictures in the DPB may be used as reference frames to enable inter prediction (in the decoding system or the encoding system). In some implementations, the reference frames in the DPB may be tagged as either short-term or long-term references for the current image being encoded or decoded. For example, short-term reference frames may include frames used for inter prediction for blocks in the current frame or in a predefined number (e.g., two) subsequent video frames closest to the current frame in decoding order. Long-term reference frames may include frames in the DPB that can be used to predict image blocks of frames that are more than a predefined number away from the current frame in decoding order. Information regarding such tags for short-term and long-term reference frames may be referred to as a reference picture set (RPS) and may be added to the header of each frame in the encoded bitstream. Each frame in the encoded video stream may be identified by a Picture Order Counter (POC), which is numbered according to the playback sequence, either in an absolute manner or in relation to a group of pictures starting, for example, with an I-frame.
[0140] In some example implementations, one or more reference picture lists including identification of short-term and long-term reference frames for inter prediction may be formed based on information in the RPS. For example, for unidirectional inter prediction, a single picture reference list may be formed, denoted as L0 reference (or reference list 0), and for bidirectional inter prediction, two picture reference lists may be formed, denoted as L0 (or reference list 0) and L1 (or reference list 1), for each of the two prediction directions. The reference frames included in the L0 and L1 lists may be ordered in various predetermined manners. The lengths of the L0 and L1 lists may be signaled in the video bitstream. The unidirectional inter prediction may be either a single reference mode or a mixed reference mode when multiple references for generating a predictive block by weighted averaging in a mixed prediction mode are on the same side of the frame where the block to be predicted is located. The bidirectional inter prediction may be a mixed mode only in that the bidirectional inter prediction involves at least two reference blocks.
[0141] In some implementations, a merge mode (MM) for inter prediction may be implemented. In general, for the merge mode, one or more of the motion vectors in single reference prediction or the motion vectors in mixed reference prediction for the current PB may be derived from other motion vector(s) instead of being calculated and signaled independently. For example, in an encoding system, a current motion vector(s) for the current PB may be represented by a difference(s) between the current motion vector(s) and one or more other already coded motion vectors (referred to as reference motion vectors). Such difference(s) of the motion vector(s) rather than the entire current motion vector(s) may be coded and included in the bitstream and linked to the reference motion vector(s). Correspondingly, in a decoding system, a motion vector(s) corresponding to the current PB may be derived based on the decoded motion vector difference(s) and the decoded reference motion vector(s) linked thereto. As a specific form of general merge mode (MM) inter prediction, such inter prediction based on motion vector differential(s) may be referred to as merge mode with motion vector differential (MMVD). Thus, general MM or MMVD in particular may be implemented to exploit the correlation between motion vectors associated with different PBs to increase coding efficiency. For example, adjacent PBs may have similar motion vectors, so that MVD may be small and efficiently coded. In another example, motion vectors may be correlated temporally (between frames) for similarly located / positioned blocks in space.
[0142] In some example implementations, an MM flag may be included in the bitstream during the encoding process to indicate whether the PB is currently in merge mode. Additionally or alternatively, an MMVD flag may be included and signaled in the bitstream during the encoding process to indicate whether the PB is currently in MMVD mode. The MM flag and / or MMVD flag or indicator may be provided at the PB level, CB level, CU level, CTB level, CTU level, slice level, frame level, picture level, sequence level, etc. For a particular example, both the MM flag and the MMVD flag may be included for the current CU, and the MMVD flag may be signaled immediately after the skip flag and the MM flag to specify whether the MMVD mode is used for the current CU.
[0143] In some example implementations of MMVD, a list of reference motion vector (RMV) or MV predictor candidates for motion vector prediction may be formed for a block being predicted. The list of RMV candidates may include a predetermined number (e.g., two) of MV predictor candidate blocks whose motion vectors may be used to predict the current motion vector. The RMV candidate blocks may include blocks selected from neighboring blocks in the same frame and / or temporal blocks (e.g., similarly located blocks in a preceding or subsequent frame of the current frame). These options represent blocks at spatial or temporal locations relative to the current block that are likely to have similar or identical motion vectors to the current block. The size of the list of MV predictor candidates may be predetermined. For example, the list may include two or more candidates. To be on the list of RMV candidates, a candidate block may be required, for example, to have the same reference frame(s) as the current block, must exist (e.g., a boundary check needs to be performed when the current block is near an edge of a frame), must have been previously coded during the coding process, and / or must have been previously decoded during the decoding process. In some implementations, the list of merge candidates may be filled first with spatially adjacent blocks (scanned in a certain predefined order) if available and satisfy the above conditions, and then with temporal blocks if there is still space available in the list. The adjacent RMV candidate blocks may be selected, for example, from the left and top blocks of the current block. The list of RMV predictor candidates may be dynamically formed at various levels (sequence, picture, frame, slice, superblock, etc.) as a dynamic reference list (DRL). The DRL may be signaled in the bitstream.
[0144] In some implementations, the actual MV predictor candidate used as the reference motion vector for predicting the motion vector of the current block may be signaled. When the RMV candidate list includes two candidates, a one-bit flag called a merge candidate flag may be used to indicate the selection of the reference merge candidate. For a current block predicted in a mixed mode, each of the multiple motion vectors predicted using the MV predictor may be associated with a reference motion vector from the merge candidate list. The encoder may determine which of the RMV candidates more closely predicts the MV of the current coding block and signal the selection as an index to the DRL.
[0145] In some exemplary implementations of MMVD, after an RMV candidate is selected and used as a base motion vector predictor for a motion vector to be predicted, a motion vector differential (MVD or delta MV, representing the difference between the motion vector to be predicted and the reference candidate motion vector) may be calculated in the coding system. Such an MVD may include information representing the magnitude of the MV difference and the direction of the MV difference, both of which may be signaled in the bitstream. The magnitude of the motion vector difference and the direction of the motion vector difference may be signaled in various ways.
[0146] In some exemplary implementations of MMVD, the distance index may be used to specify the magnitude information of the motion vector differential and to indicate one of a set of predefined offsets representing a predefined motion vector differential from a starting point (reference motion vector). Then, the MV offset according to the signaled index may be added to either the horizontal or vertical component of the starting (reference) motion vector. Whether the horizontal or vertical component of the reference motion vector should be offset may be determined by the direction information of the MVD. An exemplary predefined relationship between the distance index and the predefined offset is set forth in Table 2. [Table 2]
[0147] In some exemplary implementations of MMVD, a direction index may be further signaled and used to represent the direction of the MVD relative to the reference motion vector. In some implementations, the direction may be limited to one of the horizontal and vertical directions. An exemplary 2-bit direction index is shown in Table 3. In the example of Table 3, the interpretation of the MVD may change according to the information of the start / reference MV. For example, when the start / reference MV corresponds to a uni-predictive block or a bi-predictive block where both reference frame lists point to the same side of the current picture (i.e., the POCs of the two reference pictures are both greater than or both less than the POC of the current picture), the code in Table 3 may specify the sign (direction) of the MV offset added to the start / reference MV. When the start / reference MV corresponds to a bi-predictive block with two reference pictures on different sides of the current picture (i.e., the POC of one reference picture is larger than that of the current picture and the POC of the other reference picture is smaller than that of the current picture) and the difference between the reference POC in picture reference list 0 and the current frame is larger than the difference between the reference POC in picture reference list 1 and the current frame, the code in Table 3 may specify the sign of the MV offset to be added to the reference MV corresponding to the reference picture in picture reference list 0, and the sign of the offset of the MV corresponding to the reference picture in picture reference list 1 may have the opposite value (opposite sign of the offset). Otherwise, when the difference between the reference POC in picture reference list 1 and the current frame is larger than the difference between the reference POC in picture reference list 0 and the current frame, the code in Table 3 may specify the sign of the MV offset to be added to the reference MV associated with picture reference list 1, and the sign of the offset to the reference MV associated with picture reference list 0 has the opposite value. [Table 3]
[0148] In some example implementations, the MVD may be scaled 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 reference list 0 is greater than that of reference list 1, the MVD for reference list 1 is scaled. If the POC difference in reference list 1 is greater than list 0, the MVD for list 0 may be scaled in the same manner. If the starting MV is uni-predicted, the MVD is added to the available or reference MV.
[0149] In some example implementations of MVD coding and signaling for bidirectional composite prediction, in addition to or as an alternative to coding and signaling two MVDs separately, symmetric MVD coding may be implemented such that only one MVD needs to be signaled and the other MVD may be derived from the signaled MVD. In such implementations, motion information including reference picture indexes of both list 0 and list 1 is signaled. However, for example, only the MVD associated with reference list 0 is signaled, and the MVD associated with reference list 1 is derived rather than signaled. Specifically, at the slice level, a flag called "mvd_l1_zero_flag" may be included in the bitstream to indicate whether reference list 1 is not signaled in the bitstream. If this flag is 1, indicating that reference list 1 is equal to 0 (and thus not signaled), a bidirectional prediction flag called "BiDirPredFlag" may be set to 0, meaning there is no bidirectional prediction. Otherwise, if mvd_l1_zero_flag is 0, and the closest reference picture in list 0 and the closest reference picture in list 1 form a forward-backward pair of reference pictures or a backward-forward pair of reference pictures, BiDirPredFlag may be set to 1, and the reference pictures in list 0 and list 1 are both short-term reference pictures. Otherwise, BiDirPredFlag is set to 0. A BiDirPredFlag of 1 may indicate that a symmetric mode flag is additionally signaled in the bitstream. A decoder may extract the symmetric mode flag from the bitstream if BiDirPredFlag is 1. The symmetric mode flag may be signaled, for example, at the CU level (if necessary) to indicate whether a symmetric MVD coding mode is used for the corresponding CU.When the symmetric mode flag is 1, it indicates the use of symmetric MVD coding mode and that only the reference picture indexes of both list 0 and list 1 (called "mvp_l0_flag" and "mvp_l1_flag") are signaled along with the MVD associated with list 0 (called "MVD0"), and the other motion vector differential "MVD1" should be derived rather than signaled. For example, MVD1 may be derived as -MVD0. Thus, only one MVD is signaled in the exemplary symmetric MVD mode. In some other exemplary implementations for MV prediction, harmonized schemes may be used to implement general merge mode, MMVD, and some other types of MV prediction for both single and mixed reference modes of MV prediction. Various syntax elements may be used to signal how the MV for the current block is predicted.
[0150] For example, for single reference modes, the following MV prediction modes may be signaled: NEARMV - Uses one of the motion vector predictors (MVPs) in the list indicated by the DRL (Dynamic Reference List) index directly, without MVD. NEWMV - Use one of the motion vector predictors (MVPs) in the list signaled by the DRL index as a reference and apply a delta to the MVP (eg, using MVD). GLOBALMV - Use motion vectors based on frame-level global motion parameters.
[0151] Similarly, for a mixed reference inter prediction mode using two reference frames corresponding to the two MVs to be predicted, the following MV prediction modes may be signaled: NEAR_NEARMV - For each of two of the MVs to be predicted, use one of the motion vector predictors (MVPs) in the list signaled by the DRL index without the MVD. NEAR_NEWMV - to predict the first of two motion vectors, one of the motion vector predictors (MVPs) in the list signaled by the DRL index is used as a reference MV without MVD, and to predict the second of two motion vectors, one of the motion vector predictors (MVPs) in the list signaled by the DRL index is used as a reference MV with an additionally signaled delta MV (MVD). NEW_NEARMV - to predict the second of two motion vectors, one of the motion vector predictors (MVPs) in the list signaled by the DRL index is used as a reference MV without MVD, and to predict the first of two motion vectors, one of the motion vector predictors (MVPs) in the list signaled by the DRL index is used as a reference MV with an additionally signaled delta MV (MVD). NEW_NEWMV - Use one of the motion vector predictors (MVPs) in the list signaled by the DRL index as a reference MV and use it together with the additionally signaled delta MV to predict for each of the two MVs. GLOBAL_GLOBALMV - Use the MV from each reference based on their frame-level global motion parameters.
[0152] Thus, the term "NEAR" above refers to MV prediction using a reference MV without any MVD as a general merge mode, and the term "NEW" refers to MV prediction with using a reference MV and offsetting it with a signaled or derived MVD, as in the MMVD mode. In the case of composite inter prediction, both the reference-based motion vector and the motion vector delta above may generally differ or be independent between the two references or two MVDs, even though, for example, the two MVDs may be correlated and such correlation may be exploited to reduce the amount of information required to signal the two motion vector deltas. To exploit such correlation, joint signaling () of the two MVDs may be implemented and indicated in the bitstream, as described in more detail below.
[0153] In some implementations, optical flow-based techniques may be implemented to refine MVs at the sub-block level for composite inter prediction. Specifically, optical flow equations are applied to formulate a least-squares problem, from which fine-grained motions can be derived from gradients of composite inter prediction samples. With these fine-grained motions, the MVs per sub-block can be refined within the prediction block, thus improving the inter prediction quality. This coding feature reflects an extension of the concept of bidirectional optical flow techniques, since it supports MV refinement when two reference blocks have any temporal distance to the current block. Thus, in some exemplary implementations, four additional composite modes can be added, as listed below: NEAR_NEARMV_OPTFLOW; NEAR_NEWMV_OPTFLOW; NEW_NEARMV_OPTFLOW; NEW_NEWMV_OPTFLOW.
[0154] These modes are sometimes called optical flow modes, and the reference MV type is defined as in the conventional composite modes (e.g., NEAR_NEWMV_OPTFLOW has the same reference MV type as in NEAR_NEWMV), but composite prediction is performed based on the refined MV on a sub-block basis rather than the original MV.
[0155] In some example implementations of MVD, a predefined pixel resolution for MVD may be allowed. For example, a motion vector precision (or accuracy) of 1 / 8 pixel may be allowed. The above-described MVD in various MV prediction modes may be configured and signaled in various ways. In some implementations, various syntax elements may be used to signal the above motion vector differential(s) in reference frame list 0 or list 1.
[0156] For example, a syntax element called "mv_joint" may specify which components of its associated motion vector differential are non-zero. In the case of MVD, this is jointly signaled for all non-zero components. For example, A mv_joint with a value of 0 may indicate that there is no non-zero MVD in either the horizontal or vertical direction. A mv_joint with a value of 1 may indicate that there is non-zero MVD only along the horizontal direction. A mv_joint with a value of 2 may indicate that there is non-zero MVD only along the vertical direction. A mv_joint with a value of 3 may indicate that there is non-zero MVD along both the horizontal and vertical directions.
[0157] When the "mv_joint" syntax element for MVD signals that there are no non-zero MVD components, no further MVD information may be signaled. However, if the "mv_joint" syntax signals that there are one or two non-zero components, additional syntax elements may be further signaled for each of the non-zero MVD components, as described below.
[0158] For example, a syntax element called "mv_sign" may be used to additionally specify whether the corresponding motion vector differential component is positive or negative.
[0159] In another example, a syntax element called "mv_class" may be used to specify a class of a motion vector differential among a predefined set of classes for the corresponding non-zero MVD component. The predefined classes for motion vector differentials may be used, for example, to divide a continuous magnitude space of motion vector differentials into non-overlapping ranges, each range corresponding to an MVD class. Thus, the signaled MVD class indicates the magnitude range of the corresponding MVD component. In the example implementation shown in Table 4 below, higher classes correspond to motion vector differentials with a larger magnitude range. In Table 4, the symbol (n,m] is used to represent a range of motion vector differentials that are greater than n pixels and less than or equal to m pixels. [Table 4]
[0160] In some other examples, a syntax element called "mv_bit" may be further used to specify the integer portion of the offset between the non-zero motion vector differential component and the starting magnitude of the correspondingly signaled MV class magnitude range. Thus, the mv_bit may indicate the magnitude or amplitude of the MVD. The number of bits required in the "mv_bit" to signal the full range of each MVD class may vary as a function of the MV class. As an example, MV_CLASS 0 and MV_CLASS 1 in the implementation of Table 4 may only require a single bit to indicate an integer pixel offset of 1 or 2 from a starting MVD of 0, and each higher MV_CLASS in the example implementation of Table 4 may require progressively one more bit for the "mv_bit" than the previous MV_CLASS.
[0161] In some other examples, a syntax element called "mv_fr" may be further used to specify the first two fractional bits of the motion vector differential for the corresponding non-zero MVD component, and a syntax element called "mv_hp" may be used to specify the third fractional bit (high resolution bit) of the motion vector differential for the corresponding non-zero MVD component. The two bits of "mv_fr" may essentially provide ¼ pixel MVD resolution, and the "mv_hp" bits may further provide ⅛ pixel resolution. In some other implementations, two or more "mv_hp" bits may be used to provide MVD pixel resolution finer than ⅛ pixel. In some example implementations, additional flags may be signaled at one or more of various levels to indicate whether ⅛ pixel or finer MVD resolutions are supported. If an MVD resolution does not apply to a particular coding unit, the above syntax elements for the corresponding unsupported MVD resolutions may not be signaled.
[0162] In some example implementations above, the fractional resolution may be independent of different classes of MVD. In other words, similar options for motion vector resolution may be provided using a predefined number of "mv_fr" and "mv_hp" bits to signal fractional MVD of non-zero MVD components, regardless of the magnitude of the motion vector differential.
[0163] However, in some other example implementations, the resolutions for motion vector differentials in various MVD magnitude classes may be differentiated. Specifically, a high-resolution MVD for a large MVD magnitude of a higher MVD class may not statistically provide a significant improvement in compression efficiency or coding gain. Therefore, the MVD may be coded with reduced resolution (integer pixel resolution or fractional pixel resolution) for a larger MVD magnitude range corresponding to a higher MVD magnitude class. Similarly, the MVD may be coded with reduced resolution (integer pixel resolution or fractional pixel resolution) for a larger MVD value in general. Such MVD class-dependent or MVD magnitude-dependent MVD resolution may generally be referred to as adaptive MVD resolution, magnitude-dependent adaptive MVD resolution, or magnitude-dependent MVD resolution. The term "resolution" may further be referred to as "pixel resolution". The adaptive MVD resolution may be implemented in various ways as described by the following example implementations to achieve better overall compression efficiency. In particular, the reduction in the number of signaling bits by targeting a less accurate MVD may be greater than the additional bits required to code the inter-prediction residual as a result of such a less accurate MVD, due to the statistical observation that treating the MVD resolution for a large magnitude or high class MVD at a similar level to the MVD resolution for a small magnitude or low class MVD in a non-adapted manner cannot significantly improve the inter-prediction residual coding efficiency of blocks with a large magnitude or high class MVD. In other words, using a higher MVD resolution for a large magnitude or high class MVD may not result in more coding gain than using a lower MVD resolution.
[0164] In some typical example implementations, the pixel resolution or precision for the MVD may decrease or not increase as the MVD class increases. Decreasing the pixel resolution for the MVD corresponds to a coarser MVD (or a larger step from one MVD level to the next MVD level). In some implementations, the correspondence between MVD pixel resolution and MVD class may be specified, predefined, or preset, and thus would not need to be signaled in the encoded bitstream.
[0165] In some example implementations, each of the MV classes in Table 3 may be associated with a different MVD pixel resolution.
[0166] In some example implementations, each MVD class may be associated with a single allowed resolution. In some other implementations, one or more MVD classes may each be associated with two or more optional MVD pixel resolutions. Thus, a signal in the bitstream for a current MVD component having such an MVD class may be followed by additional signaling to indicate the optional pixel resolution selected for the current MVD component.
[0167] In some example implementations, the adaptively allowed MVD pixel resolutions may include, but are not limited to, (in descending order of resolution) 1 / 64 pel (pixel), 1 / 32 pel, 1 / 16 pel, 1 / 8 pel, 1 / 4 pel, 1 / 2 pel, 1 pel, 2 pel, 4 pel.... Thus, each of the ascending MVD classes may be associated with one of these MVD pixel resolutions in a non-ascending manner. In some implementations, an MVD class may be associated with two or more resolutions above, where the higher resolution may be less than or equal to the lower resolution for the preceding MVD class. For example, if MV_CLASS_3 in Table 4 is associated with optional 1-pel and 2-pel resolutions, then the highest resolution to which MV_CLASS_4 in Table 4 may be associated would be 2-pel. In some other implementations, the highest allowed resolution for an MV class may be higher than the lowest allowed resolution of the preceding (lower) MV class. However, the average of allowed resolutions for ascending MV classes may only be non-ascending.
[0168] In some implementations, if fractional pixel resolution higher than 1 / 8 pel is allowed, then the "mv_fr" and "mv_hp" signaling may be extended to accommodate a total of more than 3 fractional bits.
[0169] In some example implementations, fractional pixel resolution may be allowed only for MVD classes equal to or less than the threshold MVD class. For example, fractional pixel resolution may be allowed only for MV_CLASS_0 and not allowed for all other MV classes in Table 4. Similarly, fractional pixel resolution may be allowed only for MVD classes equal to or less than any one of the other MV classes in Table 4. For other MVD classes above the threshold MVD class, only integer pixel resolution for the MVD is allowed. In such a manner, fractional resolution signaling, such as one or more of the "mv_fr" and / or "mv_hp" bits, may not need to be signaled for MVDs signaled in MVD classes equal to or greater than the threshold MVD class. For MVD classes with resolution less than one pixel, the number of bits in the "mv_bit" signaling may be further reduced. For example, for MV_CLASS_5 in Table 4, the range of MVD pixel offsets is (32,64], so 5 bits are required to signal the entire range at 1 pel resolution. However, if MV_CLASS_5 is associated with a 2-pel MVD resolution (lower than 1 pixel resolution), then 4 bits may be required for "mv_bit" instead of 5 bits, and neither "mv_fr" nor "mv_hp" need to be signaled following the signaling of "mv_class" as MV_CLASS_5.
[0170] In some example implementations, fractional pixel resolution may be allowed only for MVDs with integer values below a threshold integer pixel value. For example, fractional pixel resolution may be allowed only for MVDs less than 5 pixels. Corresponding to this example, fractional resolution would be allowed for MV_CLASS_0 and MV_CLASS_1 in Table 4, and not allowed for all other MV classes. In another example, fractional pixel resolution may be allowed only for MVDs less than 7 pixels. Corresponding to this example, fractional resolution may be allowed for MV_CLASS_0 and MV_CLASS_1 in Table 4 (having a range below 5 pixels), and not allowed for MV_CLASS_3 and above (having a range above 5 pixels). For MVDs belonging to MV_CLASS_2, whose pixel range includes 5 pixels, fractional pixel resolution for the MVD may or may not be allowed depending on the "mv-bit" value. If the 'mv_bit' value is signaled as 1 or 2 (the integer part of the signaled MVD, calculated as the start of the pixel range for MV_CLASS_2 with offset 1 or 2 indicated by 'mv_bit', is 5 or 6), then fractional pixel resolution may be allowed. Otherwise, if the 'mv_bit' value is signaled as 3 or 4 (the integer part of the signaled MVD is 7 or 8), then fractional pixel resolution may not be allowed.
[0171] In some other implementations, for MV classes equal to or greater than the threshold MV class, only a single MVD value may be allowed. For example, such a threshold MV class may be MV_CLASS 2. Thus, MV_CLASS_2 and above may only be allowed to have a single MVD value and have no fractional pixel resolution. The single allowed MVD value for these MV classes may be predefined. In some examples, the allowed single value may be the upper end value of the respective range for these MV classes in Table 4. For example, MV_CLASS_2 through MV_CLASS_10 may be equal to or greater than the threshold class of MV_CLASS 2, and the allowed single MVD values for these classes may be predefined as 8, 16, 32, 64, 128, 256, 512, 1024, and 2048, respectively. In some other examples, the allowed single value may be the middle value of the respective range for these MV classes in Table 4. For example, MV_CLASS_2 through MV_CLASS_10 may be above the class threshold, and the allowed single MVD values for these classes may be predefined, respectively, as 3, 6, 12, 24, 48, 96, 192, 384, 768, and 1536. Any other value within the range may also be defined as the single allowed resolution for the respective MVD class.
[0172] In the above implementation, when the signaled "mv_class" is equal to or greater than the predefined MVD class threshold, only the "mv_class" signaling is sufficient to determine the MVD value. Then, the magnitude and direction of the MVD will be determined using "mv_class" and "mv_sign".
[0173] Therefore, when an MVD is signaled for only one reference frame (from either reference frame list 0 or list 1, but not both) or when it is signaled jointly for two reference frames, the accuracy (or resolution) of the MVD may depend on the associated class of motion vector differential in Table 3 and / or the magnitude of the MVD.
[0174] In some other implementations, the pixel resolution or precision for the MVD may decrease or not increase as the MVD magnitude increases. For example, the pixel resolution may depend on the integer part of the MVD magnitude. In some implementations, fractional pixel resolution may only be allowed for MVD magnitudes below an amplitude threshold. For a decoder, first, the integer part of the MVD magnitude may be extracted from the bitstream. The pixel resolution may then be determined, and then a determination may be made as to whether any fractional MVD is present in the bitstream and needs to be parsed (e.g., if fractional pixel resolution is not allowed for a particular extracted MVD integer magnitude, no fractional MVD bits will be included in the bitstream that requires extraction). The exemplary implementations described above related to MVD class-dependent adaptive MVD pixel resolution are applied to MVD magnitude-dependent adaptive MVD pixel resolution. In a particular example, MVD classes that exceed or encompass a magnitude threshold may be allowed to have only one predefined value.
[0175] Turning to various composite inter-prediction modes in which each MV may be predicted by a reference motion vector and coded by an MVD, the two MVDs may be signaled separately or jointly signaled in the bitstream as described above. Therefore, in some example implementations, in addition to the above-described NEAR_NEARMV, NEAR_NEWMV, NEW_NEARMV, NEW_NEWMV, and GLOBAL_GLOBALMV modes, another inter-prediction mode called JOINT_NEWMV may be introduced for a mode in which the MVDs for reference list 0 and reference list 1 are jointly signaled. In particular, when the inter-prediction mode is indicated as NEW_NEWMV, the MVDs for reference list 0 and reference list 1 are signaled separately, and when the inter-prediction mode is indicated as JOINT_NEWMV mode, the MVDs for reference list 0 and reference list 1 are jointly signaled. In particular, for joint MVD, only one MVD, called joint_delta_mv, may need to be signaled and transmitted in the bitstream, and the MVDs for reference list 0 and reference list 1 may be derived from joint_delta_mv. The derived MVD may then be combined with the reference motion vectors in reference list 0 or reference list 1 to generate two motion vectors for locating reference blocks for joint inter prediction.
[0176] In some implementations of composite inter prediction, the JOINT_NEWMV mode may be signaled along with the NEAR_NEARMV, NEAR_NEWMV, NEW_NEARMV, NEW_NEWMV, and GLOBAL_GLOBALMV modes. In such implementations, syntax for an indication of any one of these alternative composite inter prediction modes at any one of various signaling levels (e.g., sequence level, picture level, frame level, slice level, tile level, superblock level, etc.) may be included in the bitstream. Alternatively, the JOINT_NEWMV mode may be implemented as a submode of the NEW_NEWMV mode. In other words, under the NEW_NEWMV mode, the two MVDs for the two reference blocks are either jointly signaled (hence the JOINT_NEWMV submode) or are not jointly signaled (another submode of the NEW_NEWMV mode). In such an implementation, a first syntax element may be included in the bitstream to indicate any one of the NEAR_NEARMV, NEAR_NEWMV, NEW_NEARMV, NEW_NEWMV, and GLOBAL_GLOBALMV modes, and if the first syntax element indicates that the NEW_NEWMV mode is selected for a coding block, a second syntax element may be further included in the bitstream and extractable by a decoder to indicate whether the MVD for the coding block is signaled separately or jointly.
[0177] For joint MVD implementations in composite inter prediction, the MVD associated with the reference MV may be derived from a signaled joint MVD from the bitstream, e.g., joint_delta_mv described above. Such derivation may involve, for example, scaling the signaled joint MVD to obtain one or both of the two MVDs. In other words, the signaled joint MVD may be scaled before being added to the motion vector predictor(s) (MVP), or the reference MV(s). As a result of the scaling, the precision or pixel resolution of the scaled MVD may differ from the allowed precision of the motion vector differential. In some example implementations, such MVD(s) scaled from the jointly signaled MVD may first be quantized to the allowed precision of the MVD(s) for the current picture or slice or tile or superblock or coded block before being added to the reference MVD(s) for generating the motion vector.
[0178] In some example implementations, a frame index for a reference frame in a composite inter-prediction mode may be signaled in a bitstream. The frame index may correspond to a picture order counter (POC) associated with the reference frame. The distance between the reference frame and the current frame may be defined and represented by the difference between the corresponding POCs. The direction of the reference frame (before or after the current frame) may be represented by a code. Thus, a signed distance may be used to represent the position of the reference frame relative to the current frame. The reference frames for the composite inter-prediction mode may be referred to as a first reference frame and a second reference frame.
[0179] In some example implementations, the reference frame index(es) for indicating the reference frame(s) may be signaled before the syntax indicating whether the MVD(s) are jointly signaled. As further shown below, the distance(s) between the reference frame(s) and the current frame may be used to derive the MVD(s) from the jointly signaled MVD. By signaling one or more frame indexes of the reference frame(s) before the signaling of whether the joint MVD is used or before the signaling of the joint MVD, the distance(s) between the reference frame(s) and the current frame are made available in the buffer when needed.
[0180] In some example implementations, the allowable precision of the MVD(s) may include, but is not limited to, 1 / 64 pel, 1 / 32 pel, 1 / 16 pel, 1 / 8 pel, 1 / 4 pel, 1 / 2 pel, integer pel (also called full pel), 2 pel, 3 pel, 4 pel, or other integer precision. As described above, the allowable precision of the MVD(s) may be, for example, predetermined or adaptively determined. The adaptive MVD resolution may be determined, for example, by the corresponding MVD amplitude or MV class, as described above.
[0181] In one particular example implementation, only full-pel MVD may be allowed for the currently coded block (or superblock or picture), and the precision of the scaled MVD from the jointly signaled MVD may be higher than full-pel due to scaling. For example, the scaled MVD may have a precision of 1 / 2 pel. In that situation, the precision of the scaled MVD may need to be quantized to full-pel.
[0182] Similarly, in another particular example implementation, a 1 / 4-pel MVD may be allowed for the currently coded block (or superblock or picture), and the precision of the scaled MVD from the jointly signaled MVD may be higher than 1 / 4-pel due to scaling. For example, the scaled MVD may have a precision of 1 / 8-pel. In that situation, the precision of the scaled MVD may need to be quantized to 1 / 4-pel.
[0183] In some example implementations, when the distances between the two reference frames and the current frame are the same, no scaling may be performed. In other words, the jointly signaled MVD may be directly used as the actual MVD for both motion vectors for the two reference frames.
[0184] In some example implementations, a joint MVD may be signaled such that for one of the reference motion vectors, the jointly signaled MVD may be used directly and only needs to be scaled to derive the other MVD for the other reference motion vector. For example, in some implementations, the MVD associated with a reference frame from a given reference list (e.g., one of reference list 0 or reference list 1) may be signaled directly, and the other MVD associated with the other reference list may be derived or scaled from the signaled MVD. Such derivation or scaling may be based on the distance between the two reference frames and the current frame. In a particular example, the MVD for the first reference frame of reference list 1 may be signaled directly, and the MVD for the second reference frame in reference list 0 may be derived / scaled from the signaled MVD. The scaling of the signaled MVD to generate an MVD associated with a second reference frame in reference list 0 may be based on the first frame distance (between the first reference frame and the current frame) and the second frame distance (between the current frame and the second reference frame). For example, such scaling of the jointly signaled MVD to generate an MVD for the second reference frame may be based on a ratio between the first distance and the second distance.
[0185] In some other example implementations, the joint MVD may be signaled such that for one of the reference motion vectors, the jointly signaled MVD may be used directly and only needs to be scaled to derive the other MVD for the other reference motion vector. For example, in some implementations, the MVD associated with the reference frame of the two reference frames that has a shorter distance to the current frame may be directly signaled as the joint MVD without the need for scaling, and the reference frame of the two reference frames that has a longer distance to the current frame is derived / scaled from the jointly signaled MVD. Such derivation or scaling may be based on the distance between the two reference frames and the current frame. For example, the scaling of the signaled joint MVD to generate the MVD for the reference frame with the longer distance may be based on the ratio between the longer frame distance and the shorter frame distance.
[0186] Similarly, in some example implementations, the joint MVD may be signaled such that for one of the reference motion vectors, the jointly signaled MVD may be used directly and only needs to be scaled to derive the other MVD for the other reference motion vector. For example, in some implementations, the MVD associated with the reference frame of the two reference frames that has a longer distance to the current frame may be directly signaled as the joint MVD without the need for scaling, and the reference frame of the two reference frames that has a shorter distance to the current frame is derived / scaled from the jointly signaled MVD. Such derivation or scaling may be based on the distance between the two reference frames and the current frame. For example, the scaling of the signaled joint MVD to generate the MVD for the reference frame with the shorter distance may be based on the ratio between the shorter frame distance and the longer frame distance.
[0187] In some example implementations, the scaling described above may be further based on the orientation of the reference frame. For example, the direction of the scaling (upscaling or downscaling) may depend on the orientation of the reference frame (whether the reference frame has a higher or lower POC).
[0188] In some other implementations, an additional scaling factor or weighting factor may be applied directly to the jointly signaled MVD or to the jointly signaled MVD scaled above to derive one or both of the MVDs. Such factors may be predefined or signaled at various levels (e.g., SPS, VPS, PPS, picture header, tile header, slice header, frame header, CTU (or superblock) header, as part of the block level, sequence, picture, frame, slice, tile, superblock, etc.). In some situations, this additional or alternative scaling factor implementation may help to increase coding gain in that the actual jointly signaled MVD may be represented by a smaller number of bits when the additional scaling factor or weighting factor is left out and signaled more sparsely in a higher syntax level (e.g., SPS, VPS, PPS, picture header, tile header, slice header, frame header, CTU (or superblock) header). In some example implementations, such a scaling or weighting factor may be between −1 and 1. For example, such a scaling or weighting factor may be 1 / 2.
[0189] Quantization of the scaled co-signaled MVD to a permitted precision of the MVD or motion vector for the current picture, slice, tile, superblock, or coding block may be implemented in various ways. For example, the scaled MVD value may be quantized to the next lower permitted value according to the permitted precision of the MVD or MV. In another example, the scaled MVD value may be quantized to the next higher permitted value according to the permitted precision of the MVD or MV.
[0190] In one particular example implementation, quantization of the scaled jointly signaled MVD to keep the precision aligned with the allowed precision may be performed by dropping the N least significant bits of the scaled MVD, where N is an integer and is determined by the difference between the precision of the scaled MVD and the allowed precision for the MVD.
[0191] In another alternative exemplary implementation, quantization of the scaled jointly signaled MVD to keep the precision aligned with the allowed precision may be performed by adding a rounding factor and then dropping the N least significant bits. Both the rounding factor and the integer N may be determined, for example, based at least on the difference between the precision and the scaled MVD and the allowed precision for the MVD.
[0192] FIG. 18 shows a flowchart 1800 of an example method according to the principles underlying the above implementations for scaling a jointly signaled MVD and quantizing the scaled MVD. The example method flow starts at 1801. At S1810, at least one flag is extracted from a video stream. At S1820, based on the extracted flag, it may be determined that a video block is inter-predicted by at least a first reference block in a first reference frame located by a first motion vector and a second reference block in a second reference frame located by a second motion vector, the first motion vector should be predicted by a first motion vector differential (MVD) relative to the first reference motion vector, and the second motion vector should be predicted by a second MVD relative to the second reference motion vector, and the first MVD and the second MVD are jointly signaled as a single MVD in the video stream. At S1830, the single MVD is received from the video stream. At S1840, the single MVD is scaled to generate a scaled MVD. At S1850, the scaled MVD is quantized to generate a quantized MVD having an MVD pixel resolution according to an allowable accuracy of the first motion vector or the second motion vector. At S1860, one of the first motion vector and the second motion vector is generated based on the quantized MVD and a corresponding reference motion vector of the first reference motion vector and the second reference motion vector. At S1870, one of the first reference block or the second reference block for inter predicting the video block is reconstructed from one of the first reference frame or the second reference frame based on one of the first motion vector or the second motion vector. The exemplary method stops at S1899.
[0193] In the embodiments and implementations of the present disclosure, any steps and / or operations may be combined or arranged in any quantity or order as desired. Two or more of the steps and / or operations may be performed in parallel. The embodiments and implementations in the present disclosure may be used separately or combined in any order. Furthermore, each of the method (or embodiment), the encoder, and the decoder may be implemented by a processing circuit (e.g., one or more processors or one or more integrated circuits). In one example, the one or more processors execute a program stored in a non-transitory computer-readable medium. The embodiments in the present disclosure may be applied to a luma block or a chroma block. The term block may be interpreted as a prediction block, a coding block, or a coding unit, i.e., a CU. The term block in this specification may also be used to refer to a transform block. In the following items, when referring to a block size, it may refer to either the width or height of the block, or the maximum value of the width and height, or the minimum value of the width and height, or the area size (width*height), or the aspect ratio of the block (width:height, or height:width).
[0194] The techniques described above may be implemented as computer software using computer-readable instructions and physically stored on one or more computer-readable media. For example, FIG. 19 illustrates a computer system (1900) suitable for implementing certain embodiments of the disclosed subject matter.
[0195] Computer software may be coded using any suitable machine code or computer language that may be subject to assembly, compilation, linking, or similar mechanisms to create code containing instructions that may be executed by one or more computer central processing units (CPUs), graphics processing units (GPUs), etc., directly, or through interpretation, microcode execution, etc.
[0196] The instructions may be executed on various types of computers or components thereof including, for example, personal computers, tablet computers, servers, smartphones, gaming devices, Internet of Things devices, and the like.
[0197] 19 with respect to the computer system (1900) are exemplary in nature and are not intended to suggest any limitation as to the scope of use or functionality of the computer software implementing the embodiments of the present disclosure, nor should the arrangement of components be interpreted as having any dependency or requirement regarding any one or combination of components illustrated in the exemplary embodiment of the computer system (1900).
[0198] The computer system (1900) may include certain human interface input devices. Such human interface input devices may respond to input by one or more human users through, for example, tactile input (keystrokes, swipes, data glove movements, etc.), audio input (voice, clapping, etc.), visual input (gestures, etc.), olfactory input (not shown). Human interface devices may also be used to capture certain media that are not necessarily directly related to conscious human input, such as audio (speech, music, ambient sounds, etc.), images (scanned images, photographic images obtained from a still image camera, etc.), video (two-dimensional video, three-dimensional video including stereoscopic video, etc.), etc.
[0199] The input human interface devices may include one or more (only one of each is shown) of a keyboard (1901), a mouse (1902), a trackpad (1903), a touch screen (1910), a data glove (not shown), a joystick (1905), a microphone (1906), a scanner (1907), and a camera (1908).
[0200] The computer system (1900) may also include certain human interface output devices. Such human interface output devices may stimulate one or more of the senses of a human user, for example, through haptic output, sound, light, and smell / taste. Such human interface output devices may include haptic output devices (e.g., haptic feedback via a touch screen (1910), data gloves (not shown), or joystick (1905), although there may also be haptic feedback devices that do not function as input devices), audio output devices (speakers (1909), headphones (not shown), etc.), visual output devices (such as screens (1910), including CRT screens, LCD screens, plasma screens, OLED screens, etc., each with or without touch screen input capability, each with or without haptic feedback capability, some of which may be capable of outputting two-dimensional visual output or output in more than three dimensions by means of stereographic output, virtual reality glasses (not shown), holographic displays, and smoke tanks (not shown), etc.), and printers (not shown).
[0201] The computer system (1900) may also include human accessible storage devices and their associated media, such as optical media including CD / DVD ROM / RW (1920) with CD / DVD or similar media (1921), thumb drives (1922), removable hard drives or solid state drives (1923), legacy magnetic media such as tapes and floppy disks (not shown), and dedicated ROM / ASIC / PLD based devices (not shown) such as security dongles.
[0202] Those skilled in the art should also understand that the term "computer-readable medium" as used in connection with the subject matter of this disclosure does not encompass transmission media, carrier waves, or other transitory signals.
[0203] The computer system (1900) may also include an interface (1954) to one or more communication networks (1955). The networks may be, for example, wireless, wireline, optical. The networks may further be local, wide area, metropolitan, vehicular and industrial, real-time, delay tolerant, etc. Examples of networks include local area networks such as Ethernet, wireless LAN, cellular networks including GSM, 3G, 4G, 5G, LTE, etc., TV wireline or wireless wide area digital networks including cable TV, satellite TV, and terrestrial broadcast TV, vehicular and industrial including CANBus, etc. Certain networks generally require an external network interface adapter attached to a particular general-purpose data port or peripheral bus (1949) (e.g., a USB port of the computer system (1900)), while others are generally integrated into the core of the computer system (1900) by attachment to a system bus as described below (e.g., an Ethernet interface to a PC computer system or a cellular network interface to a smartphone computer system). Using any of these networks, the computer system (1900) can communicate with other entities. Such communications may be one-way receive only (e.g., broadcast TV), one-way transmit only (e.g., CANbus to a particular CANbus device), or bidirectional to other computer systems using, for example, local or wide area digital networks. Specific protocols and protocol stacks may be used with each of these networks and network interfaces, as described above.
[0204] The aforementioned human interface devices, human accessible storage devices, and network interfaces may be attached to the core (1940) of the computer system (1900).
[0205] The cores (1940) may include one or more central processing units (CPUs) (1941), graphics processing units (GPUs) (1942), dedicated programmable processing units in the form of field programmable gate areas (FPGAs) (1943), hardware accelerators for specific tasks (1944), graphics adapters (1950), and the like. These devices may be connected through a system bus (1948), along with read only memory (ROM) (1945), random access memory (1946), internal mass storage devices (1947) such as internal hard drives, SSDs, etc. that are not user accessible. In some computer systems, the system bus (1948) may be accessible in the form of one or more physical plugs to allow expansion with additional CPUs, GPUs, etc. Peripheral devices may be connected directly to the core's system bus (1948) or through a peripheral bus (1949). In one example, a screen (1910) may be connected to the graphics adapter (1950). Peripheral bus architectures include PCI, USB, etc.
[0206] The CPU (1941), GPU (1942), FPGA (1943), and accelerator (1944) can execute certain instructions that, in combination, can constitute the aforementioned computer code. The computer code can be stored in ROM (1945) or RAM (1946). Transient data can also be stored in RAM (1946), and persistent data can be stored, for example, in internal mass storage (1947). Rapid storage and retrieval in any of the memory devices can be made possible by the use of cache memory, which can be closely associated with one or more of the CPU (1941), GPU (1942), mass storage (1947), ROM (1945), RAM (1946), etc.
[0207] The computer-readable medium can bear computer code for performing various computer-implemented operations. The medium and computer code may be specially designed and constructed for the purposes of the present disclosure, or they may be of the kind well known and available to those skilled in the computer software arts.
[0208] By way of example and not limitation, a computer system (1900) having the architecture, and in particular the core (1940), can provide functionality as a result of a processor(s) (including CPUs, GPUs, FPGAs, accelerators, etc.) executing software embodied in one or more tangible computer-readable media. Such computer-readable media can be user-accessible mass storage devices as introduced above, as well as media associated with specific storage devices of the core (1940) that are non-transitory in nature, such as the core internal mass storage device (1947) or ROM (1945). Software implementing various embodiments of the present disclosure can be stored in such devices and executed by the core (1940). The computer-readable media can include one or more memory devices or chips according to particular needs. The software can cause the core (1940) and specifically the processors therein (including CPUs, GPUs, FPGAs, etc.) to execute certain processes or certain portions of certain processes described herein, including defining data structures stored in RAM (1946) and modifying such data structures according to processes defined by the software. Additionally or alternatively, the computer system can provide functionality as a result of logic hardwired or otherwise embodied in circuitry (e.g., accelerators (1944)), which can operate in place of or in conjunction with software to execute certain processes or certain portions of certain processes described herein. Reference to software can encompass logic, where appropriate, and vice versa. Reference to computer-readable media can encompass circuitry (such as integrated circuits (ICs)) that stores software for execution, circuitry that embodies logic for execution, or both, where appropriate. The present disclosure encompasses any suitable combination of hardware and software.
[0209] While this disclosure has described several exemplary embodiments, there are alterations, permutations, and various substitute equivalents that fall within the scope of this disclosure. It will thus be appreciated that those skilled in the art will be able to devise numerous systems and methods that, although not explicitly shown or described herein, embody the principles of the present disclosure and are therefore within its spirit and scope. [Appendix A: Acronyms] JEM: joint exploration model VVC: versatile video coding BMS:benchmark set MV: Motion Vector HEVC: High Efficiency Video Coding SEI: Supplementary Enhancement Information VUI: Video Usability Information GOPs: Groups of Pictures TUs: Transform Units PUs: Prediction Units CTUs: Coding Tree Units CTB: Coding Tree Blocks PB: Prediction Blocks HRD: Hypothetical Reference Decoder SNR: Signal Noise Ratio CPUs: Central Processing Units GPUs: Graphics Processing Units CRT:Cathode Ray Tube LCD: Liquid-Crystal Display OLED: Organic Light-Emitting Diode CD: Compact Disc DVD: Digital Video Disc ROM: Read-Only Memory RAM: Random Access Memory ASIC: Application-Specific Integrated Circuit PLD: Programmable Logic Device LAN: Local Area Network GSM: Global System for Mobile communications LTE: Long-Term Evolution CANBus: Controller Area Network Bus USB: Universal Serial Bus PCI: Peripheral Component Interconnect FPGA: Field Programmable Gate Areas SSD: solid-state drive IC: Integrated Circuit HDR: high dynamic range SDR: standard dynamic range JVET: Joint Video Exploration Team MPM: Most probable mode WAIP: Wide-Angle Intra Prediction CU: Coding Unit PU: Prediction Unit TU: Transform Unit CTU: Coding Tree Unit PDPC: Position Dependent Prediction Combination ISP: Intra Sub-Partitions SPS: Sequence Parameter Set PPS: Picture Parameter Set APS: Adaptation Parameter Set VPS:Video Parameter Set DPS: Decoding Parameter Set ALF: Adaptive Loop Filter SAO: Sample Adaptive Offset CC-ALF: Cross-Component Adaptive Loop Filter CDEF: Constrained Directional Enhancement Filter CCSO: Cross-Component Sample Offset LSO:Local Sample Offset LR: Loop Restoration Filter AV1: AOMedia Video 1 AV2: AOMedia Video 2 MVD: Motion Vector Difference CfL: Chroma from Luma SDT: Semi Decoupled Tree SDP: Semi Decoupled Partitioning SST: Semi Separate Tree SB: Super Block IBC (or IntraBC): Intra Block Copy CDF: Cumulative Density Function SCC: Screen Content Coding GBI: Generalized Bi-prediction BCW: Bi-prediction with CU-level Weights CIIP: Combined intra-inter prediction POC: Picture Order Counter RPS: Reference Picture Set DPB: Decoded Picture Buffer MMVD: Merge Mode with Motion Vector Difference
Claims
1. 1. A method for processing video blocks of a video stream, comprising the steps of: extracting at least one flag from the video stream; Based on the at least one flag, the video block is inter predicted with at least a first reference block in a first reference frame located by a first motion vector and a second reference block in a second reference frame located by a second motion vector; The first motion vector is to be predicted by a first motion vector differential (MVD) relative to a first reference motion vector; and the second motion vector is to be predicted by a second MVD with respect to a second reference motion vector; determining a the first MVD and the second MVD are jointly signaled as a single MVD in the video stream; receiving said single MVD signaled in said video stream; scaling the single MVD to generate a scaled MVD; quantizing the scaled MVD to generate a quantized MVD having an MVD pixel resolution according to a tolerance accuracy of the first motion vector or the second motion vector; generating one of the first motion vector and the second motion vector based on the quantized MVD and a corresponding reference motion vector among the first reference motion vector and the second reference motion vector; reconstructing one of the first reference block or the second reference block for inter-predicting the video block from one of the first reference frame or the second reference frame based on the one of the first motion vector and the second motion vector; The method includes:
2. 2. The method of claim 1, further comprising extracting from the video stream a first frame index for identifying the first reference frame and a second frame index for identifying the second reference frame.
3. The method of claim 2 , wherein the at least one flag is signaled in the video stream before the first frame index and the second frame index.
4. The method of claim 1 , wherein the at least one flag includes an indication of a joint MVD mode among a set of composite inter prediction modes.
5. The set of composite inter prediction modes includes: the joint MVD mode, in which both the first motion vector and the second motion vector are jointly predicted by a signaled MVD; a NEAR-NEAR inter prediction mode, in which both the first motion vector and the second motion vector are signaled without MVD; a NEAR-NEW inter prediction mode, in which the first motion vector is signaled without MVD and the second motion vector is predicted by a signaled MVD; a NEW-NEAR inter prediction mode, in which the second motion vector is signaled without MVD and the first motion vector is predicted by a signaled MVD; a NEW-NEW inter prediction mode, in which the first motion vector and the second motion vector are predicted separately by separately signaled MVDs; The method of claim 4 , comprising:
6. the joint MVD mode includes a sub-mode of a combined NEW-NEW inter prediction mode in which both the first motion vector and the second motion vector are predicted rather than directly signaled; the at least one flag is included in the video stream and is extracted from the video stream in response to the video block being predicted under the composite NEW-NEW inter prediction mode. The method according to claim 4.
7. 2. The method of claim 1, wherein the MVD pixel resolution of the one of the first MVD or the second MVD comprises one of 1 / 64 pel, 1 / 32 pel, 1 / 16 pel, 1 / 8 pel, 1 / 4 pel, 1 / 2 pel, or integer pixel resolution.
8. The method of claim 7 , wherein the MVD pixel resolution is pre-set or adaptively signaled in the video stream.
9. the MVD pixel resolution is less than the as-scaled pixel resolution of the scaled MVD; the scaled MVD is quantized by reducing the scaled pixel resolution of the scaled MVD to the MVD pixel resolution to generate the quantized MVD. The method according to claim 7.
10. 2. The method of claim 1 , wherein scaling the single MVD to generate the scaled MVD is performed based on a first distance between the current frame of the video block and the first reference frame or a second distance between the current frame of the video block and the second reference frame.
11. The method of claim 10 , wherein the one of the first motion vector and the second motion vector generated based on the quantized MVD corresponds to the first reference frame or the second reference frame belonging to a predefined reference frame list.
12. The method of claim 10 , wherein a scaling factor for performing the scaling is 1 when the first distance is equal to the second distance.
13. The method of claim 10, wherein the one of the first motion vector or the second motion vector generated based on the quantized MVD corresponds to a reference frame among the first reference frame and the second reference frame that has a smaller distance to the current frame.
14. The method of claim 10, wherein the one of the first motion vector or the second motion vector generated based on the quantized MVD corresponds to a reference frame among the first reference frame and the second reference frame that has a greater distance to the current frame.
15. The method of claim 10, wherein the scaling step is performed based on an additional scaling factor other than the first distance and the second distance, the additional scaling factor being between −1 and 1.
16. 16. The method of claim 15, further comprising extracting the additional scaling factor from the video stream as part of a sequence parameter set (SPS), a video parameter set (VPS), a picture parameter set (PPS), a picture header, a tile header, a slice header, a frame header, or a coding tree unit header.
17. 2. The method of claim 1, wherein quantizing the scaled MVD comprises removing N least significant bits from the scaled MVD, where N is an integer derived based on a difference between the MVD pixel resolution and an as-scaled pixel resolution of the scaled MVD.
18. 2. The method of claim 1, wherein quantizing the scaled MVD comprises adding a rounding factor and then removing N least significant bits from the scaled MVD, where N is an integer derived based on a difference between the MVD pixel resolution, the as-scaled pixel resolution of the scaled MVD, and the rounding factor.
19. A video processing device comprising a memory for storing instructions and a processor, the processor being configured to execute the instructions to perform a method according to any one of claims 1 to 18.
20. A computer program causing a computer to carry out the method according to any one of claims 1 to 18.
Citation Information
Patent Citations
Image encoding / decoding method and device, and recording medium storing bitstream
JP2019536376A
Improvements on merge mode with motion vector difference
WO2021129683A1
