Method for predicting temporal motion information, method for constructing a candidate motion information list, and method for video decoding - Patents.com
The method addresses inefficiencies in inter-prediction by using non-adjacent temporal motion information prediction to enhance coding efficiency in video encoding, especially for complex movements not captured by traditional spatial methods.
Patent Information
- Application Number
- JP2024540755
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2022-01-04
- Publication Date
- 2024-12-20
- Estimated Expiration
- 2042-01-04
AI Technical Summary
Existing inter-prediction methods in video coding frameworks fail to efficiently utilize temporal redundancy between frames, leading to suboptimal coding efficiency.
A method for temporal motion information prediction that determines non-adjacent positions in a coded image to derive first temporal motion information, combined with spatial motion information, to construct a candidate motion information list for improved video encoding and decoding.
Enhances coding efficiency by effectively utilizing temporal redundancy, particularly in scenarios where traditional spatial motion information prediction is inadequate, such as movements from right to left or bottom to top, thereby improving compression efficiency.
Smart Images

Figure 2024546394000001_ABST
Abstract
Description
[Technical field]
[0001] TECHNICAL FIELD Embodiments of the present disclosure relate to, but are not limited to, video technology, and more particularly to a temporal motion information prediction method, a candidate motion information list building method, and corresponding apparatus and system. [Background technology]
[0002] Currently, a block-based mixed coding framework is used in general-purpose video coding (including encoding and decoding) standards. Each image or sub-image or frame in a video is divided into largest coding units (LCUs) or coding tree units (CTUs) of the same size (e.g., 128×128, 64×64, etc.). Each largest coding unit or coding tree unit can be divided into rectangular coding units (CUs) based on a rule. The coding units can also be divided into prediction units (PUs), transform units (TUs), etc. The mixed coding framework includes modules such as prediction, transform, quantization, entropy coding, and in-loop filters. The prediction module includes intra prediction and inter prediction. The inter prediction includes motion estimation and motion compensation. Since there is a strong correlation between adjacent samples in a frame in a video, the intra prediction method is used in the video coding technology to eliminate the spatial redundancy between adjacent samples. Since there is a strong similarity between adjacent frames in a video, the inter prediction method is used in the video coding technology to eliminate the temporal redundancy between adjacent frames, so as to improve the coding efficiency.
[0003] However, the coding efficiency of existing inter prediction methods still needs to be improved. Summary of the Invention
[0004] The following is a summary of the subject matter described in detail herein, which is not intended to limit the scope of protection of the claims.
[0005] An embodiment of the present disclosure provides a temporal motion information prediction method, which includes: determining at least one non-adjacent position of a current block; and determining first temporal motion information of the current block according to the motion information of the at least one non-adjacent position in a coded image.
[0006] An embodiment of the present disclosure further provides a method for constructing a candidate motion information list, which includes the following: Perform spatial motion information prediction and temporal motion information prediction on a current block to determine spatial motion information and temporal motion information of the current block; Add the spatial motion information and temporal motion information to a candidate motion information list of the current block in a set order; The temporal motion information prediction uses the temporal motion information prediction method described in any one of the embodiments of the present disclosure; The temporal motion information includes a first temporal motion information.
[0007] An embodiment of the present disclosure further provides a video encoding method, which includes: constructing a candidate motion information list for a current block according to the candidate motion information list constructing method described in any one of the embodiments of the present disclosure; selecting one or more candidate motion information from the candidate motion information list, and recording an index of the selected candidate motion information; determining a prediction block for the current block according to the selected candidate motion information, encoding the current block according to the prediction block, and encoding an index of the candidate motion information.
[0008] An embodiment of the present disclosure further provides a video decoding method, which constructs a candidate motion information list of a current block according to the candidate motion information list constructing method described in any one of the embodiments of the present disclosure; selects one or more candidate motion information from the candidate motion information list according to an index of the candidate motion information of the current block obtained by decoding; determines a prediction block of the current block according to the selected candidate motion information, and reconstructs the current block according to the prediction block.
[0009] An embodiment of the present disclosure further provides a time motion information prediction device, which includes a processor and a memory storing a computer program, and when the processor executes the computer program, executes the time motion information prediction method according to any one of the embodiments of the present disclosure.
[0010] An embodiment of the present disclosure further provides a candidate motion information list construction device, which comprises a processor and a memory storing a computer program. When the processor executes the computer program, the processor executes the candidate motion information list construction method described in any one of the embodiments of the present disclosure.
[0011] An embodiment of the present disclosure further provides a video encoding device, the video encoding device comprising: a processor and a memory in which a computer program is stored, the processor, when executing the computer program, performs the video encoding method according to any one of the embodiments of the present disclosure.
[0012] An embodiment of the present disclosure further provides a video decoding device, which includes a processor and a memory in which a computer program is stored, and when the processor executes the computer program, performs the video decoding method according to any one of the embodiments of the present disclosure.
[0013] An embodiment of the present disclosure further provides a video coding system, which includes a video encoding device according to any one of the embodiments of the present disclosure and a video decoding device according to any one of the embodiments of the present disclosure.
[0014] An embodiment of the present disclosure further provides a non-transitory computer-readable storage medium, the computer-readable storage medium storing a computer program, the computer program being executed by a processor to perform the method according to any one of the embodiments of the present disclosure.
[0015] An embodiment of the present disclosure further provides a bitstream, the bitstream being generated by the video encoding method according to any one of the embodiments of the present disclosure.
[0016] Other aspects may be appreciated after reading and understanding the drawings and detailed description. [Brief description of the drawings]
[0017] The drawings are provided for understanding the embodiments of the present disclosure and are a part of the specification. The drawings and the embodiments of the present disclosure are used to explain the technical solution of the present disclosure, and are not intended to limit the technical solution of the present disclosure. [Figure 1A] FIG. 1A is a schematic diagram illustrating a coding system according to one embodiment of the present disclosure. [Figure 1B] FIG. 1B is a diagram illustrating a structure of a video encoding device according to one embodiment of the present disclosure. [Figure 1C] FIG. 1C is a diagram illustrating a structure of a video decoding device according to one embodiment of the present disclosure. [Diagram 2] FIG. 2 is a schematic diagram showing a reference relationship between a current block and reference blocks in both directions. [Diagram 3] FIG. 3 is a schematic diagram illustrating neighboring positions of a current block used to derive spatial and temporal motion information. [Figure 4] FIG. 4 is a schematic diagram illustrating calculating a motion vector from a current block to a reference block based on a motion vector from a collocated block to a collocated reference block. [Diagram 5] FIG. 5 is an image in which there is right-to-left motion. [Figure 6] FIG. 6 is an image in which there is right-to-left motion. [Figure 7] FIG. 7 is an image in which there is right-to-left motion. [Figure 8] FIG. 8 is a flowchart illustrating a method for predicting temporal motion information according to an embodiment of the present disclosure. [Figure 9] FIG. 9 is a flow chart illustrating a method for constructing a list of candidate motion information according to one embodiment of the present disclosure. [Figure 10] FIG. 10 is a schematic diagram illustrating an example of non-adjacent locations used to derive temporal motion information according to an embodiment of the present disclosure. [Figure 11] FIG. 11 is a schematic diagram illustrating another example of non-adjacent positions used to derive temporal motion information according to an embodiment of the present disclosure. [Figure 12] FIG. 12 is a schematic diagram illustrating various positions and their order used to derive spatial and temporal motion information according to one embodiment of the present disclosure. [Figure 13] FIG. 13 is a schematic diagram illustrating another example of non-adjacent locations used to derive temporal motion information according to an embodiment of the present disclosure. [Figure 14] FIG. 14 is a flowchart illustrating a video encoding method according to one embodiment of the present disclosure. [Figure 15] FIG. 15 is a flowchart illustrating a video decoding method according to one embodiment of the present disclosure. [Figure 16] FIG. 16 is a schematic diagram illustrating a time motion information prediction device according to an embodiment of the present disclosure. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0018] While the present disclosure describes multiple embodiments, the descriptions are illustrative and not limiting, and it will be apparent to one skilled in the art that many more examples and embodiments may be included within the scope of the embodiments described in the present disclosure.
[0019] In the description of the present disclosure, the terms "exemplary" or "for example" mean "as an example, illustration, explanation". In the present disclosure, any embodiment described as "for example" or "exemplary" should not be construed as being superior to other embodiments. The term "and / or" in this specification describes the related relationship of related objects and indicates that there are three types of relationships. For example, in the case of A and / or B, it indicates three situations: only A exists, A and B exist simultaneously, and only B exists. "Plural" means two or more. In addition, in order to clearly describe the technical proposal of the embodiment of the present disclosure, terms such as "first" and "second" are used to distinguish between those that have almost the same or similar functions and roles. Those skilled in the art can understand the following. Terms such as "first" and "second" do not limit the number or execution order, and terms such as "first" and "second" do not necessarily limit different things.
[0020] In describing representative exemplary embodiments, the present specification may present a method and / or process as a specific sequence of steps. However, the method or process does not depend on the specific sequence of steps described herein, and the method or process should not be limited to the specific sequence of steps described. As will be understood by one of ordinary skill in the art, other orders of steps are possible. Thus, the specific order of steps described in the specification should not be construed as a limitation on the scope of the claims. Furthermore, claims corresponding to methods and / or processes should not be limited to performing in the order described. One of ordinary skill in the art can readily appreciate that these orders may be varied and still fall within the spirit and scope of the embodiments of the present disclosure.
[0021] In this specification, a video image is abbreviated to an image, and the image includes a video image and a part of a region in the video image. The part of the region in the video image may be, for example, a sub-image divided from the video image, or a slice or slice segment divided from the video image.
[0022] In this specification, the motion information derived by motion information prediction used to represent the prediction operation includes reference picture information and motion vector (MV) information. In related video standards, the same prediction operation may be represented by "motion vector predictor", and the derived information includes not only motion vector information but also reference picture information. "Motion vector predictor" may also be understood as motion information prediction used to represent the prediction operation in this specification.
[0023] In this specification, "temporal motion information" refers to motion information obtained by temporal motion information predictor (temporal motion information predictor or temporal motion vector predictor). Temporal motion information prediction may also be referred to as "temporal motion vector prediction" in standards. In this specification, "spatial motion information" refers to motion information obtained by spatial motion information predictor (spatial motion vector predictor). Spatial motion information prediction may also be referred to as "spatial motion vector prediction" in standards. In this specification, "motion information" as a prediction result is also referred to as "motion vector prediction" in some standards.
[0024] As used herein, a non-adjacent location of the current block is a location whose coordinates are not adjacent to any sample within the current block, and a adjacent location of the current block is a location whose coordinates are adjacent to at least one sample within the current block.
[0025] In this specification, the current block may be a current coding unit (CU) or a current prediction unit (PU), etc. The current image is the image in which the current block is located, and the current image sequence is the image sequence in which the current block is located.
[0026] FIG. 1A is a block diagram showing a video coding system applicable to an embodiment of the present disclosure. As shown in the figure, the system is divided into an encoding device 1 and a decoding device 2. The encoding device 1 generates a bitstream. The decoding device 2 can decode the bitstream. The encoding device 1 and the decoding device 2 can include one or more processors and memories coupled to the one or more processors. Examples of the memory include random access memory, electrically erasable programmable read-only memory, flash memory, or other media. The encoding device 1 and the decoding device 2 can be realized in various devices, such as a desktop computer, a mobile computing device, a notebook computer, a tablet computer, a set top box (STB), a television, a camera, a display device, a digital media player, an in-vehicle computer, or other similar devices.
[0027] The decoding device 2 can receive the bitstream from the encoding device 1 via the link 3. The link 3 includes one or more media or devices that can move the bitstream from the encoding device 1 to the decoding device 2. In one example, the link 3 includes one or more communication media that enable the encoding device 1 to directly transmit the bitstream to the decoding device 2. The encoding device 1 can modulate the bitstream according to a communication standard (e.g., a wireless communication protocol) and transmit the modulated bitstream to the decoding device 2. The one or more communication media include wireless communication media and / or wired communication media, such as a radio frequency (RF) spectrum or one or more physical transmission lines. The one or more communication media can form part of a packet-based network, which can be, for example, a local area network (LAN), a wide area network (WAN), or a global network (e.g., the Internet). The one or more communication media may include a router, a switch, a base station, or other devices that facilitate communication from the encoding device 1 to the decoding device 2. In another example, the bitstream may be output from the output interface 15 to a storage device. The decoding device 2 may read the stored data from the storage device via streaming or downloading.
[0028] In the example shown in Figure 1A, the encoding device 1 includes a data source 11, an encoder 13, and an output interface 15. In some examples, the data source 11 includes a video capture device (e.g., a camera), an archive containing previously captured data, a feeding interface for receiving data from a content provider, a computer graphics system for generating data, or a combination of these sources. The encoder 13 can encode data from the data source 11 and output it to the output interface 15. The output interface 15 can include at least one of a conditioner, a modem, and a transmitter.
[0029] In the example shown in FIG. 1A, the decoding side device 2 includes an input interface 21, a decoder 23, and a display device 25. In some examples, the input interface 21 includes at least one of a receiver and a modem. The input interface 21 can receive a bit stream via the link 3 or from a storage device. The decoder 23 decodes the received bit stream. The display device 25 is used to display the decoded data. The display device 25 may be integrated with other components of the decoding side device 2 or may be provided separately. The display device 25 may be, for example, a liquid crystal display (LCD), a plasma display, an organic light emitting diode (OLED) display, or other types of display devices. Also, in other examples, the decoding side device 2 may not include the display device 25, or may include other devices or equipment to which the decoded data is applicable.
[0030] Based on the video coding system shown in FIG. 1A, various video coding methods can be used to realize video compression. International video coding standards include H.264 / Advanced Video Coding (AVC), H.265 / high efficiency video coding (HEVC), H.266 / Versatile Video Coding (VVC), moving picture experts group (MPEG), Alliance for Open Media (AOM), audio video standard (AVS), and any other standard that is an extension or customized of these standards. In these standards, video compression techniques are used to reduce the amount of data transmitted and stored, thereby realizing more efficient video coding and transmission and storage. All of the above video coding standards use a block-based hybrid coding scheme. The embodiments of the present disclosure are applied to the basic flow of video coding in the block-based hybrid coding framework, but are not limited to this framework and flow.
[0031] FIG. 1B is a block diagram of an example video encoding device that may be used in embodiments of the present disclosure.
[0032] As shown in the figure, the video encoding apparatus 1000 includes a prediction processing unit 1100, a division unit 1101, a residual generation unit 1102, a transform processing unit 1104, a quantization unit 1106, an inverse quantization unit 1108, an inverse transform processing unit 1110, a reconstruction unit 1112, a filter unit 1113, a decoded image buffer 1114, an image resolution adjustment unit 1115, and an entropy encoding unit 1116. The prediction processing unit 1100 includes an inter-prediction processing unit 121 and an intra-prediction processing unit 1126. The video encoder 20 may also include more, fewer, or different functional components compared to this example.
[0033] The division unit 1101 cooperates with the prediction processing unit 1100 to divide the received video data into slices, CTUs, or other relatively large units. The video data received by the division unit 1101 may be a video sequence including video frames such as I frames, P frames, and B frames.
[0034] The prediction processing unit 1100 may divide the CTU into CUs and perform intra-predictive coding or inter-predictive coding on the CUs. When performing intra-prediction and inter-prediction on the CUs, the CUs may be divided into one or more Prediction Units (PUs).
[0035] The inter-prediction processing unit 1121 may perform inter prediction on the PU to generate prediction data for the PU. The prediction data includes a prediction block for the PU, motion information of the PU, and various syntax elements.
[0036] The intra-prediction processing unit 1126 may perform intra prediction on the PU to generate predictive data for the PU. The predictive data for the PU may include a predictive block for the PU and various syntax elements.
[0037] The residual generation unit 1102 may subtract the prediction block of the PU obtained by dividing the CU from the original block of the CU to generate a residual block of the CU.
[0038] The transform processing unit 1104 may divide a CU into one or more transform units (TUs). A residual block associated with a TU is a sub-block obtained by dividing the residual block of the CU. A coefficient block associated with a TU is generated by applying one or more transforms to the residual block associated with the TU.
[0039] The quantization unit 1106 may quantize the coefficients in the coefficient block based on a selected quantization parameter (QP). The degree of quantization to the coefficient block may be adjusted by adjusting the QP value.
[0040] An inverse quantization unit 1108 and an inverse transform processing unit 1110 may apply inverse quantization and inverse transform, respectively, to the coefficient block to obtain a reconstructed residual block associated with the TU.
[0041] The reconstruction unit 1112 may generate a reconstructed block for the CU by adding the reconstructed residual block and the prediction block generated by the prediction processing unit 1100.
[0042] The filter unit 1113 performs in-loop filtering on the reconstructed block, and then stores the reconstructed block as a reference image in the decoded image buffer 1114. The intra-prediction processing unit 1126 can extract a reference image of a block adjacent to the PU from the decoded image buffer 1114 to perform intra prediction. The inter-prediction processing unit 1121 can perform inter prediction on the PU of the current image using the reference image of the previous image cached in the decoded image buffer 1114.
[0043] The image resolution adjustment unit 1115 resamples the reference images stored in the decoded image buffer 1114. The resampling may include upsampling and / or downsampling. The resulting multi-resolution reference images are stored in the decoded image buffer 1114.
[0044] The entropy encoding unit 1116 performs an entropy encoding operation on the received data (eg, syntax elements, quantized system blocks, motion information, etc.).
[0045] FIG. 1C is a block diagram of an example video decoding device that may be used in embodiments of the present disclosure.
[0046] As shown in the figure, video decoding device 101 includes an entropy decoding unit 150, a prediction processing unit 152, an inverse quantization unit 154, an inverse transform processing unit 156, a reconstruction unit 158 (illustrated in the figure by a circle with a +), a filter unit 159, and an image buffer 160. In other embodiments, video decoder 30 may include more, fewer, or different functional components.
[0047] The entropy decoding unit 150 may perform entropy decoding on the received bitstream to extract information such as syntax elements, quantized coefficient blocks, and motion information of PUs. The prediction processing unit 152, the inverse quantization unit 154, the inverse transform processing unit 156, the reconstruction unit 158, and the filter unit 159 may all perform corresponding operations based on the syntax elements extracted from the bitstream.
[0048] As a functional component that performs a reconstruction operation, inverse quantization unit 154 may inverse quantize a coefficient block associated with a quantized TU. Inverse transform processing unit 156 may apply one or more inverse transforms to the inverse quantized coefficient block to generate a reconstructed residual block of the TU.
[0049] Prediction processing unit 152 includes inter-prediction processing unit 162 and intra-prediction processing unit 164. When intra-prediction coding is used for the PU, intra-prediction processing unit 164 can determine an intra-prediction mode of the PU based on syntax elements parsed from the bitstream, and perform intra prediction based on the determined intra-prediction mode and neighboring reconstructed reference information of the PU obtained from image buffer 60 to generate a predictive block of the PU. When inter-prediction coding is used for the PU, inter-prediction processing unit 162 can determine one or more reference blocks of the PU based on the motion information and corresponding syntax elements of the PU, and generate a predictive block of the PU based on the reference blocks.
[0050] The reconstruction unit 158 can obtain a reconstructed block of a CU based on a reconstructed residual block associated with the TU and a predicted block of a PU (i.e., intra-predicted data or inter-predicted data) generated by the prediction processing unit 152.
[0051] The filter unit 159 may perform in-loop filtering on the reconstructed block of the CU to obtain a reconstructed image. The reconstructed image is stored in the image buffer 160. The image buffer 160 may provide a reference image for subsequent motion compensation, intra-prediction, inter-prediction, etc., and may also output the reconstructed video data as decoded video data for presentation on a display device.
[0052] Display 105 can be, for example, a liquid crystal display (LCD), a plasma display, an organic light emitting diode (OLED) display, or other types of display devices, and in other examples, the decoding side may not include a display 105, but instead include other devices to which the decoded data is applicable.
[0053] The basic flow of video coding is as follows. On the encoding side, an image is divided into blocks, and a prediction block of the current block is generated by performing intra prediction or inter prediction on the current block, the prediction block is subtracted from the original block of the current block to obtain a residual block, the residual block is transformed and quantized to obtain a quantization coefficient matrix, and the quantization coefficient matrix is entropy coded and output to a bitstream. On the decoding side, a prediction block of the current block is generated by performing intra prediction or inter prediction on the current block, while the bitstream is decoded to obtain a quantization coefficient matrix, the quantization coefficient matrix is inverse quantized and inverse transformed to obtain a residual block, and the prediction block and the residual block are added to obtain a reconstructed block. The reconstructed block forms a reconstructed image. The reconstructed image is in-loop filtered based on the image or block to obtain a decoded image. On the encoding side, a process similar to that on the decoding side is also required to obtain a decoded image. The decoded image can be a reference image for inter prediction of a subsequent image. The block partition information determined by the encoding side, and mode information or parameter information such as prediction, transformation, quantization, entropy coding, in-loop filtering, etc. are output to the bitstream as necessary. The decoding side analyzes and parses existing information to determine the same block partition information, mode information or parameter information such as prediction, transformation, quantization, entropy coding, in-loop filtering, etc. as the encoding side. This ensures that the decoded image obtained by the encoding side is the same as the decoded image obtained by the decoding side. The decoded image obtained by the encoding side is usually also called a reconstructed image. During prediction, the current block can be divided into prediction units. The above is the basic flow of a video codec (including an encoder and a decoder) in a block-based mixed coding framework. As technology develops, some modules or steps in the framework or flow may be optimized.
[0054] Movement and movement information
[0055] A video is composed of images. To make a video look smooth, every second of the video contains tens to hundreds of frames of images. For example, 24 frames per second, 30 frames per second, 50 frames per second, 60 frames per second, 120 frames per second, etc. Thus, there is a very significant temporal redundancy in the video. In other words, there is a lot of temporal correlation. Therefore, inter prediction usually utilizes temporal correlation in "motion". One very simple "motion" model is that an object is at a certain position in an image corresponding to a certain time, and after a certain time, it translates to another position in the image corresponding to this time. This is the most basic and commonly used translation motion in video coding. In inter prediction, motion information is used to represent "motion". Basic motion information includes reference picture (e.g., reference frame) information and motion vector (MV) information. The codec determines a reference image based on reference image information, and determines the coordinates of the reference block based on the motion vector information and the coordinates of the current block. The reference block is determined using the coordinates of the reference block in the reference image. Motion in a video is not necessarily such a simple motion. Even motion that is considered to be translational may have subtle changes over time, such as subtle deformation, brightness change, and noise change. In order to achieve a better prediction effect, the current block may be predicted using multiple reference blocks. For example, in currently commonly used bidirectional prediction, two reference blocks are used to predict the current block. The two reference blocks may be one forward reference block and one backward reference block. In addition, both of the two reference blocks may be forward reference blocks or both of the two reference blocks may be backward reference blocks.Forward means that the time corresponding to the reference picture is before the current picture, and backward means that the time corresponding to the reference picture is after the current picture. In other words, forward means that the position of the reference picture in the video is located before the current picture, and backward means that the position of the reference picture in the video is located after the current picture. In other words, forward means that the picture order count (POC) of the reference picture is smaller than the POC of the current picture, and backward means that the POC of the reference picture is larger than the POC of the current picture. Future video coding standards may support prediction with more reference blocks. One simple way to generate a prediction block using two reference blocks is to average sample values at positions corresponding to the two reference blocks to obtain a prediction block. To obtain better prediction results, a weighted average such as BCW (Bi-prediction with CU-level weight), which is currently used in VVC, can also be used. The geometric partitioning mode (GPM) in VVC can also be understood as a special bidirectional prediction. To be able to use bidirectional prediction, it is necessary to find two reference blocks. Therefore, two sets of reference picture information and motion vector information are required. Each set can be understood as one unidirectional piece of motion information.
[0056] Motion in a video can take many forms, including not only simple translation, but also scaling, rotation, distortion, and so on. The above two sets are combined to form one bidirectional motion information. In concrete implementation, the unidirectional motion information and the bidirectional motion information can use the same data structure, and in the bidirectional motion information, two sets of reference image information and motion vector information are both valid, while in the unidirectional motion information, one of the two sets of reference image information and motion vector information is invalid. Motion can be complex. In VVC, some simple motions are simulated by affine. In the affine model in VVC, two or three control points are used, and a linear model is adopted based on these control points to derive the motion vectors of each subblock in the current block. Here, the reason why only motion vectors are mentioned, rather than motion information, is that all motion vectors point to the same reference image. In normal translational motion, the "whole block" is found from the reference image, whereas in affine, a set of non-adjacent "subblocks" is found from the reference image. All of the above are in the category of unidirectional prediction. Affine can also realize bidirectional prediction and prediction by more "reference blocks". Here, the reference block is a combination of sub-blocks. In concrete terms, one unidirectional motion information in the data structure of affine motion information can include one reference image information and two or three motion vector information, or two or three sets of reference image information and motion vector information, but these reference image information are the same.
[0057] Of course, in addition to basic reference image information and motion vector information, the motion information can include additional information such as whether a BCW is used and the index of the BCW.
[0058] Reference Image (Reference Frame)
[0059] Without considering parallel processing, video is processed picture by picture. Pictures that have already been coded (including encoding and decoded) are stored in a buffer and used as reference pictures for the pictures to be coded subsequently. Current coding standards have a reference picture management method that manages reference pictures. The reference picture management method is used to manage which pictures can be used as reference pictures for the current picture, the indexes of these reference pictures, which pictures need to be stored in the buffer, and which pictures can no longer be used as reference pictures and can be removed from the buffer.
[0060] Due to the difference in the coding order of pictures, currently commonly used scenarios can be divided into two types: random access (abbreviated as RA) and low delay (abbreviated as LD). In a low-delay scenario, the picture display order and the coding order are the same, while in a random access scenario, the picture display order and the coding order can be different. Generally speaking, in a low-delay scenario, the picture is coded according to the order of the video itself. In a random access scenario, the order of the video itself can be disrupted, and some pictures are not coded first, and the following pictures are coded first, and then the skipped pictures are coded. The advantage of random access is that some pictures can refer to both the previous and following reference pictures, so that "motion" can be well utilized to improve compression efficiency.
[0061] A typical GOP (Group of Pictures) structure of RA is shown in Figure 2. In the figure, P frames (Predictive Frames) are frames that can only be predicted in one direction (forward), and B frames (Bi-predictive Frames) are frames that can be predicted in two directions. This restriction on reference relationships can also be applied to a level below the picture level, such as P slices and B slices that are divided at the slice level.
[0062] The arrows in Figure 2 indicate the reference relationships. I-frames do not require a reference image. After coding an I-frame with POC 0, code a P-frame with POC 4. When coding the P-frame with POC 4, the I-frame with POC 0 can be referenced. Next, code a B-frame with POC 2. When coding the B-frame with POC 2, the I-frame with POC 0 and the P-frame with POC 4 can be referenced.
[0063] The codec manages reference pictures using a reference picture list. In VVC, two reference picture lists are supported, denoted as RPL0 and RPL1, where RPL is an abbreviation of Reference Picture List. In VVC, a P slice can only use RPL0, and a B slice can use RPL0 and RPL1. For one slice, each reference picture list has several reference pictures, and the codec uses a reference picture index to find a particular reference picture. In VVC, motion information is represented by a reference picture index and a motion vector. For example, for the bidirectional motion information, in VVC, a reference picture index refIdxL0 corresponding to RPL0, a motion vector mvL0 corresponding to RPL0, and a reference picture index refIdxL1 corresponding to RPL1, a motion vector mvL0 corresponding to RPL1 are used. The reference picture index corresponding to RPL0 and the reference picture index corresponding to RPL1 can be understood as the reference picture information. In VVC, two flags indicate whether the motion information corresponding to RPL0 is used, and whether the motion information corresponding to RPL0 is used, and the two flags are represented as predFlagL0 and predFlagL1, respectively. Also, predFlagL0 and predFlagL1 can be understood to indicate whether the unidirectional motion information is "valid or not."
[0064] Motion vectors are not limited to integer-pixel accuracy; VVC allows prediction with half-pixel, quarter-pixel, eighth-pixel, and sixteenth-pixel accuracy. Fractional-pixel prediction requires integer-pixel interpolation, which allows for finer motion vectors and improved prediction quality.
[0065] Motion vector prediction (or motion information prediction)
[0066] For a current block, a reference block can be found from a reference image using the motion information, and a prediction block for the current block can be determined based on the reference block.
[0067] The motion information used for the current block can be predicted using some related information, which can be called motion information prediction or motion vector prediction. For example, the motion information used for adjacent coded blocks around the current block in the current image (e.g., frame or slice) can be used. This is because there is a strong correlation between adjacent blocks. Also, the motion information used for non-adjacent coded blocks around the current block in the current image can be used. This is because there is a certain degree of correlation between blocks in a relatively close area and the current block, even if they are not adjacent. In this way, a method of performing motion information prediction using motion information used for coded blocks around the current block in the current image is generally called spatial motion information prediction. In addition to coded blocks around the current block, motion information prediction can also be performed for the current block using motion information of blocks related to the position of the current block in the coded image, which is generally called temporal motion information prediction. Furthermore, the motion information of coded blocks can be maintained in a list according to the coding order. Generally, a plurality of different motion information that have been coded most recently is left in the list, and motion information prediction is performed for the current block using the motion information in this list. This is generally called history-based motion vector prediction. It can be easily understood that spatial motion information is derived using motion information of an image that is the same as the current block, and temporal motion information is derived using motion information of an image that is different from the current block.
[0068] To use spatial motion information prediction, it is necessary to store the motion information of the coded block in the current image (or slice). Generally, a minimum storage unit is set, for example, a size of 4×4 is set as the minimum storage unit, but it may be 8×8 or other sizes. Every time the codec codes a block, it stores the motion information for all the minimum storage units corresponding to this block. To find the motion information of the blocks around the current block, it can find the minimum storage unit based on the coordinate position to obtain the motion information. Similarly, to use temporal motion information prediction, it is necessary to store the motion information of the coded image (or slice). Generally, a minimum storage unit is also set. It may have the same size as the storage unit of spatial motion information, or it may have a different size, and is determined by the provisions of the standard. To find the motion information of a block in the image (or slice) for the current block, it can find the minimum storage unit based on the coordinate position to obtain the motion information. Due to the limitations of storage space or implementation complexity, it may be possible to only obtain the temporal motion information or spatial motion information within a certain range of coordinate positions for the current block.
[0069] Through motion information prediction, one or more motion information can be obtained. When multiple motion information is obtained, it is usually necessary to select which one or more motion information, or to indicate which one or more motion information to select according to some predefined rules. For example, two motion information need to be used for GPM in VVC, and for example, one motion information needs to be used for each subblock in sub-block based TMVP (abbreviated as SbTMVP). TMVP refers to temporal motion vector predictor. In this specification, TMVP is used to represent temporal motion information prediction based on neighboring positions.
[0070] To use motion information obtained by prediction, certain motion information obtained by prediction can be directly used as the motion information of the current block. One example is merge in HEVC. Or, new motion information is obtained by adding motion vector difference (MVD) to certain motion information obtained by prediction. By design, the closer the predicted motion information is to the actual motion information, the better. However, since it is not possible to ensure that motion information prediction is always accurate, the motion vector difference can be used to obtain more accurate motion information. A new method of expressing motion vector difference has been added to VVC, and the combination of motion vector prediction and the new method of expressing motion vector difference can be used in the merge mode, which is called MMVD (merge with MVD). That is, the motion information prediction can be used directly or in combination with other methods.
[0071] The following is an example of how to build a merge motion information candidate list in VVC.
[0072] The merge motion information candidate list is denoted as mergeCandList. When constructing mergeCandList, first check the spatial motion information prediction based on positions 1 to 5 in FIG. 3, and then check the temporal motion information prediction. When checking the temporal motion information prediction, if position 6 is available, derive (drive) the temporal motion information prediction based on position 6. Derivation is also called derivation. That is, calculate step by step based on position 6 to obtain the temporal motion information. Position 6 being available refers to position 6 not exceeding the boundary of an image or sub-image and being in the same CTU row as the current block, for details, please refer to the text of the standard. If position 6 is unavailable, derive the temporal motion information prediction based on position 7. Position 6 can be represented by coordinates (xColBr, yColBr), and position 7 can be represented by coordinates (xColCtr, yColCtr).
[0073] A specific method for determining spatial motion information is as follows. Take the spatial motion information of position 2 in FIG. 3 as an example, position 2 is denoted as B1, or the block where position 2 is located is denoted as B1. Derive an available flag availableFlagB1, a reference image index refIdxLXB1, a reference image list use flag predFlagLXB1, and a motion vector mvLXB1. The availableFlagB1 can be used to indicate whether the spatial motion information of B1 is available. The reference image index refIdxLXB1, the reference image list use flag predFlagLXB1, and the motion vector mvLXB1 together constitute the motion information. X=0..1.
[0074] Note that (xCb, yCb) are the coordinates of the top-left corner of the current block relative to the top-left corner of the current image, cbWidth is the width of the current block, and cbHeight is the height of the current block.
[0075] Set the coordinate (xNbB1, yNbB1) in the neighboring block B1 to (xCb + cbWidth - 1, yCb - 1). Determine whether the block where (xNbB1, yNbB1) is located is available. One way to determine is as follows: if the block where (xNbB1, yNbB1) is located has already been coded and inter-coded, then the block is available; otherwise, the block is unavailable. Of course, there can be additional conditions to determine. For example, if xCb >> Log2ParMrgLevel is equal to xNbB1>> Log2ParMrgLevel and yCb >> Log2ParMrgLevel is equal to yNbB1>> Log2ParMrgLevel, then the block is unavailable. Log2ParMrgLevel is a variable determined by the sequence level parameter. ">>" indicates a right shift operation.
[0076] --If the block where (xNbB1, yNbB1) is located is unavailable, the value of availableFlagB1 is set to 0, the values of the horizontal and vertical components of mvLXB1 are both set to 0, the value of refIdxLXB1 is set to -1, the value of predFlagLXB1 is set to 0, and X = 0..1. --If not, the value of availableFlagB1 is set to 1 and is assigned a value as follows: mvLXB1 = MvLX[ xNbB1][ yNbB1] refIdxLXB1= RefIdxLX[ xNbB1][ yNbB1] predFlagLXB1= PredFlagLX[ xNbB1][ yNbB1]
[0077] As one understanding, the motion information at (xNbB1, yNbB1) is used for spatial motion information prediction based on position B1, and spatial motion information prediction based on other positions can be derived in a similar manner.
[0078] Derivation of time movement information
[0079] As shown in FIG. 4, currPic is a current image, currCb is a current block, currRef is a reference image for temporal motion information of the current block, colCb is a co-located block, colPic is an image where the co-located block is located, and colRef is a reference image for motion information used for the co-located block. In deriving temporal motion information, first, find colCb from colPic based on one position information, and find the motion information of colCb. The motion information of colCb shown in FIG. 4 is a motion vector (shown by a solid line) from colPic to colRef. The temporal motion information is obtained by scaling the motion vector shown by the solid line to a motion vector from currPic to currRef (i.e., the motion vector shown by a dotted line). tb is a variable determined based on the difference between the POC of currPic and the POC of currRef, and td is a variable determined based on the difference between the POC of colPic and the POC of colRef. The motion vector is scaled based on tb and td. What is shown is unidirectional motion information or the scaling of one motion vector, it can be understood that the temporal motion information can use bidirectional motion information.
[0080] A specific method for deriving temporal motion information is as follows. Take deriving temporal motion information of position 6 in FIG. 3 as an example, position 6 is denoted as Col, or the block where position 6 is located in the reference image is denoted as Col. Col is an abbreviation of collocated, and this block is called a collocated block, and this reference image is called a collocated image. An available flag availableFlagCol, a reference image index refIdxLXCol, a reference image list usage flag predFlagLXCol, and a motion vector mvLXCol are derived. The above availableFlagCol can be used to indicate whether the temporal motion information of Col is available. The reference image index refIdxLXCol, the reference image list usage flag predFlagLXCol, and the motion vector mvLXCol together constitute the motion information. X=0..1.
[0081] Denote the coordinates (xColBr, yColBr) of position 6 as (xCb + cbWidth, yCb + cbHeight). If the coordinates (xColBr, yColBr) meet the requirements, e.g., do not exceed the bounds of the current image or subimage, or the bounds of the CTU row in which the current block is located, then denote the coordinates ( xColCb, yColCb ) of the colocated block as ( ( xColBr>> 3)<<3, ( yColBr>>3 )<<3 ). Denote the current block as currCb, the colocated block on the colocated image ColPic is colCb, and colCb is the block that covers ( xColCb, yColCb ). currPic is the current image. The coordinates are calculated by first shifting right by 3 bits (>>) and then shifting left by 3 bits (<<) because the motion information in the collocated image in this example is stored in a minimum storage unit of 8x8 (the granularity of caching the reference image motion information can be relatively coarse to save buffer space). By first shifting right by 3 bits and then shifting left by 3 bits, the last 3 bits become 0. For example, the binary of 10 is 1010, and by first shifting right by 3 bits and then shifting left by 3 bits, it becomes 8, and the binary is 1000. Different embodiments may convert the coordinates differently.
[0082] Here, for convenience of explanation, some simplifying assumptions are made. In this example, both the motion information of the co-located block and the temporal motion information to be derived use only one reference image list L0. In this example, all Xs appearing below are 0. However, in practice, it should be noted that these two motion information are allowed to use two reference image lists in some scenarios. In addition, the forward motion information or backward motion information of the temporal motion information derived based on the forward motion information or backward motion information of the co-located block may have multiple combination methods, which are not limited in the present disclosure, and only the simplest example will be described. For simplicity, refIdxLX is also set to 0. refIdxLX may have multiple possible values, which are not limited in the present disclosure, and only the simplest example will be described.
[0083] mvLXCol and availableFlagCol are derived based on the following method: If colCb is encoded in Intra mode, Intra Block Copy (IBC) mode, or palette mode, and both the horizontal and vertical components of mvLXCol are set to 0, and availableFlagCol is set to 0, then the colocated block is considered unavailable. -- Otherwise, availableFlagCol is set to 1 and the motion vector mvCol, reference picture index refIdxCol and reference picture list indication listCol are derived based on the following method: mvCol, refIdxCol and listCol constitute the motion information of the collocated block used for scaling. mvCol, refIdxCol and listCol are set to mvL0Col[xColCb][yColCb], refIdxL0Col[xColCb][yColCb], L0, respectively.
[0084] predFlagLXCol is set to 1.
[0085] mvLXCol is derived based on the following method. --refPicList[listCol][refIdxCol] is the reference image for motion information of colCb, i.e., colRef in the figure. RefPicList[X][refIdxLX] is the reference image for temporal motion information, i.e., currRef in the figure. Calculate the POC distance colPocDiff between ColPic and refPicList[listCol][refIdxCol], and calculate the POC distance currPocDiff between currPic and RefPicList[X][refIdxLX]. colPocDiff = DiffPicOrderCnt( ColPic, refPicList[ listCol ][ refIdxCol ] ) currPocDiff = DiffPicOrderCnt( currPic, RefPicList[ X ][ refIdxLX ] ) If colPocDiff is equal to currPocDiff, mvLXCol = Clip3( -131072, 131071, mvCol ) Otherwise, mvLXCol is scaled based on mvCol. tx = ( 16384 + ( Abs( td ) >> 1 ) ) / td distScaleFactor = Clip3( -4096, 4095, ( tb * tx + 32 ) >> 6 ) mvLXCol = Clip3( -131072, 131071, (distScaleFactor * mvCol + 128-( distScaleFactor * mvCol >= 0 ) ) >> 8 ) Where: td = Clip3( -128, 127, colPocDiff ). tb = Clip3( -128, 127, currPocDiff ).
[0086] Here, clip3 is the clipping function, and -131072, 131071, -4096, 4095, etc. in clip3 are related to data precision, and these values may be different under different precision regulations. You can refer to the relevant standards for the above calculations.
[0087] When adding each candidate motion information to mergeCandList, an identity check or similarity check can be performed to ensure that the same or very similar motion information is not added to mergeCandList, which helps mergeCandList to provide more candidates in practice.
[0088] Taking the motion information in VVC as an example, a method for determining whether the motion information is the same will first be described. The motion information in VVC includes predFlagLX, refIdxLX, and mvLX. X=0..1. Two pieces of motion information are denoted as mi0 and mi1, respectively, and one method for determining whether the two pieces of motion information are the same is as follows. Whether X is 0 or 1, if mi0.predFlagLX is equal to mi1.predFlagLX, mi0.refIdxLX is equal to mi1.refIdxLX, and mi0.mvLX is equal to mi1.mvLX, mi0 and mi1 are the same. If predFlagLX is 0, it is assumed that the corresponding refIdxLX and mvLX are preset values, i.e., they are not random values.
[0089] Or, if predFlagLX is 1, a comparison between refIdxLX and a comparison between mvLX are performed. If predFlagLX is 0, there is no need to perform a comparison between refIdxLX and a comparison between mvLX. If the same reference image is present in two reference image lists, even if each predFlagLX is different and each refIdxLX is different, they may point to the same reference image. If the corresponding mvLX is the same, the motion information may actually be the same. A reference image whose index in the reference image list LX is refIdxLX is written as refPicList[LX][refIdxLX]. In general, since there are no two identical reference images in the same reference image list, an example can be given in which two unidirectional motion information uses different reference image lists. That is, one of mi0.predFlagL0 and mi0.predFlagL1 is 1 and the other is 0, and the one that is 1 is written as corresponding to list A. One of mi1.predFlagL0 and mi1.predFlagL1 is 1 and the other is 0, and the one that is 1 corresponds to list B. If mi0.refPicList[LA][refIdxLA] is equal to mi1.refPicList[LB][refIdxLB] and mi0.mvLA is equal to mi1.mvLB, the two motion information are the same. The above two methods are respectively a method of directly comparing each parameter and a method of comparing derived reference images.
[0090] The following introduces that two motion information are similar. The motion information in VVC includes predFlagLX, refIdxLX, and mvLX. X = 0..1. Denote the two motion information as mi0 and mi1 respectively. One of the methods to determine whether the two motion information are similar is as follows. Whether X is 0 or 1, if mi0.predFlagLX is equal to mi1.predFlagLX, mi0.refIdxLX is equal to mi1.refIdxLX, and diff(mi0.mvLX, mi1.mvLX) < diffTh, then mi0 and mi1 are similar. If predFlagLX is 0, assume that the corresponding refIdxLX and mvLX are preset values, that is, they are not random values.
[0091] Alternatively, when predFlagLX is 1, perform the comparison between refIdxLX and the comparison between mvLX. When predFlagLX is 0, there is no need to perform the comparison between refIdxLX and the comparison between mvLX. If there are the same reference images in the two reference image lists, even if each predFlagLX is different and each refIdxLX is different, they may point to the same reference image. If the corresponding mvLX are similar, the motion information may actually be similar. The reference image with the index refIdxLX in the reference image list LX is denoted as refPicList[LX][refIdxLX]. Generally, since there are no two identical reference images in the same reference image list, take as an example the case where two unidirectional motion information use different reference image lists respectively. That is, one of mi0.predFlagL0 and mi0.predFlagL1 is 1 and the other is 0, and the one that is 1 is denoted as corresponding to list A. One of mi1.predFlagL0 and mi1.predFlagL1 is 1 and the other is 0, and the one that is 1 is denoted as corresponding to list B. When mi0.refPicList[LA][refIdxLA] is equal to mi1.refPicList[LB][refIdxLB] and diff(mi0.mvLX, mi1.mvLX) < diffTh, the two motion information are similar. diff(mi0.mvLX, mi1.mvLX) can be used to represent the difference between the two motion vectors. For example, it can be the sum of the absolute value of the difference between the horizontal components of the two motion vectors and the absolute value of the difference between the vertical components of the two motion vectors, or the maximum value of the absolute value of the difference between the horizontal components of the two motion vectors and the absolute value of the difference between the vertical components of the two motion vectors. diffTh is a threshold for determining whether they are similar. If the difference is less than diffTh, it is determined that the two motion vectors (information) are similar; otherwise, it is determined that the two motion vectors (information) are not similar. The above two methods are respectively the method of directly comparing each parameter and the method of comparing the derived reference images.
[0092] The video coding order is generally from left to right and top to bottom. For example, within a slice, coding starts from the first CTU in the upper left corner, then goes to the right, processes one CTU row, and continues coding from the first CTU on the left of the second row. And within a CTU, the order is from left to right and top to bottom. This processing order determines that relevant information from the left side and top is more easily obtained, and relevant information from the right side and bottom is less easily obtained. One important piece of relevant information is motion information. Motion can point in any one direction. There is left-to-right motion, and there is also right-to-left motion. Taking a simple scenario as an example, in the coding arrangement of a low delay scenario, all pictures are coded in temporal order. Assuming that an object moves from right to left, if the collocated block at position 6 used to derive temporal motion information does not contain the content of this object, it is highly likely that motion information cannot be predicted for the current block. Furthermore, if some motion cannot be obtained from the coded portion of the current image, but from the position of the lower right corner adjacent to the current block, it is highly likely that this motion information cannot be predicted. For example, a jockey moving from right to left in the image RaceHorses in Fig. 5, a person moving from the lower right to the upper left in the image BasketballDrill in Fig. 6, and a car moving from the upper right to the lower left in the image BQTerrace in Fig. 7. In these scenarios, existing motion information prediction methods cannot predict such motion information well.
[0093] If an object does not appear in the coded part, it is difficult to obtain the motion information of the object by performing spatial motion information prediction on the current block. Therefore, we can resort to temporal motion information prediction. For temporal motion information prediction, the position of the lower right corner adjacent to the current block is used. However, even under the placement of a random access scenario, the motion information at one position is often insufficient because the co-located block at that position may not contain the object.
[0094] This is especially true in the case of GPM mode. In GPM mode, some segmentations simulate the edges of two objects. If there is one object in the upper left corner and another object in the lower right corner, it is easy to obtain the relevant information of the object in the upper left corner, but it is difficult to obtain the relevant information of the object in the lower right corner. Since the motion information of the object in the lower right corner is not obtained, GPM may not be usable.
[0095] To solve this problem, temporal motion information prediction can be performed using one or more locations that are not adjacent to the current block.
[0096] An embodiment of the present disclosure provides a temporal motion information prediction method, the method includes:
[0097] Step 110: Determine at least one non-adjacent location of the current block.
[0098] Step 120: Determine first temporal motion information of the current block based on the motion information of at least one non-adjacent position in the coded image.
[0099] In this specification, the temporal motion information prediction based on non-adjacent positions in claim 1 is called temporal motion information prediction based on non-adjacent positions, and is abbreviated as NATMVP in English. The reason why a motion vector is used instead of motion information is because it is consistent with the common term. The motion vector here still includes reference image information such as a reference image index and a reference image list usage flag. In this specification, the first temporal motion information is also called "temporal motion information determined by NATMVP".
[0100] In this specification, the motion information of the current block determined by temporal motion information prediction is referred to as temporal motion information of the current block, and the motion information of the current block determined by spatial motion information prediction is referred to as spatial motion information of the current block.
[0101] In one exemplary embodiment of the present disclosure, the temporal motion information prediction method further includes adjacent position-based temporal motion information prediction, i.e., adjacent position-based temporal motion information prediction of a current block (abbreviated as TMVP). If the temporal motion information cannot be obtained from the adjacent position of the current block, the temporal motion information can also be obtained from inside the current block.
[0102] When performing temporal motion information prediction based on a non-adjacent position of a current block, a collocated block corresponding to the current block in a reference image can be determined based on the coordinates of the non-adjacent position (the collocated block is a coding unit or a minimum storage unit in a reference image that includes the non-adjacent position, and the reference image is a collocated image), and obtains motion information of the collocated block, and scales the motion vector in the motion information to obtain temporal motion information of the current block. Since the temporal motion information is derived based on the non-adjacent position, in this specification, the non-adjacent position is also referred to as a position for deriving the temporal motion information.
[0103] In this specification, spatial motion information prediction based on a position adjacent to the current block (i.e., an adjacent position of the current block) is abbreviated as SMVP (spatial motion vector predictor). Of course, spatial motion information prediction can also be performed based on a position not adjacent to the current block (i.e., a non-adjacent position of the current block), and this prediction is abbreviated as NASMVP (non adjacent spatial motion vector predictor) in this specification.
[0104] In one exemplary embodiment of the present disclosure, the at least one non-adjacent location includes any one or more of the following non-adjacent locations in the following directions: A non-adjacent position to the right of the current block, a non-adjacent location below the current block, and A non-adjacent position on the bottom-right side of the current block.
[0105] As shown in Fig. 10, the big square in the figure represents a 16x16 block, and the current block is located at the center. The small square with the section line in the figure is a 4x4 block, which corresponds to the smallest storage unit. For ease of representation, one small square is used in Fig. 10 to represent non-adjacent positions whose coordinates fall within the small square.
[0106] In one example, the non-adjacent positions on the right side of the current block refer to non-adjacent positions whose abscissa is greater than xCb+cbWidth and whose ordinate is in the interval [yCb, yCb+cbHeight-1]. The non-adjacent positions below the current block refer to non-adjacent positions whose abscissa is greater than yCb+cbHeight and whose abscissa is in the interval [xCb, xCb+cbWidth-1]. The non-adjacent positions on the right and bottom side of the current block refer to non-adjacent positions whose abscissa is greater than xCb+cbWidth and whose ordinate is greater than yCb+cbHeight. These can be seen in the three bold boxes in FIG. 10.
[0107] In FIG. 10, the position of the lower right corner adjacent to the current block is the position used for TMVP. If the position of the lower right corner adjacent to the current block is unavailable, the position of the center of the current block is used. It is considered that the positions of the upper right side and the lower left side used for NASMVP are often unavailable. In another embodiment, the position of the upper right side and / or the position of the lower left side of the current block can be used for NATMVP, as shown in FIG. 11. In another embodiment, the positions of all directions around the current block can be used for NATMVP, including non-adjacent positions in at least one direction of the left side, the upper side, and the upper left side, which are already coded in the reference image. In actual applications, only some positions may be used. It should be noted that the specific coordinates of the non-adjacent positions actually used in the embodiments of the present disclosure may change based on what is shown in the figures, for example, performing an operation of "+1" or "-1" on at least one of the horizontal coordinate and the vertical coordinate. Reflected in the figure, the small square corresponding to one non-adjacent position may be changed from the lower left corner of one large square to the upper left corner of the next large square.
[0108] In one exemplary embodiment of the present disclosure, the horizontal distance and / or the vertical distance between the non-adjacent position and the set sample in the current block is a preset fixed value, or The horizontal and / or vertical distance between the non-adjacent location and the set sample in the current block is variable and is determined based on the following parameters, or any combination of the following parameters: The size of the current block, The parameters of the current image sequence, Sequence level flags for the current image sequence, The image-level flags for the current image, and Current image slice level flags.
[0109] In one example, the horizontal distance (i.e., horizontal distance) and vertical distance (i.e., vertical distance) between the non-adjacent position and the set sample in the current block can be preset, for example, the horizontal distance and vertical distance from position 10 in FIG. 12 to the bottom right corner of the current block are both 16 pixels, and the horizontal distance and vertical distance from position 16 in FIG. 12 to the bottom right corner of the current block are both 16*2 pixels, or 32 pixels, and the following can be inferred in this manner.
[0110] In one example, the non-adjacent position can be determined based on the position of the current block. Note that (xCb, yCb) are the coordinates of the top left corner of the current block relative to the top left corner of the current image, cbWidth is the width of the current block, and cbHeight is the height of the current block. In this example, the horizontal and / or vertical distance between the non-adjacent position and the set sample in the current block is determined according to the size of the current block. For example, the horizontal distance from position 10 in FIG. 12 to the bottom right corner of the current block is cbWidth, the vertical distance is cbHeight, and the coordinates of position 10 are (xCb+2*cbWidth-1, yCb+2*cbHeight-1). The horizontal distance from position 16 in FIG. 12 to the bottom right corner of the current block is 2*cbWidth, the vertical distance is 2*cbHeight, and the coordinates of position 16 are (xCb+3*cbWidth-1, yCb+3*cbHeight-1). The following can be analogized in this way.
[0111] In one example, the horizontal and / or vertical distance between the non-adjacent position and the set sample in the current block is determined based on the parameters (e.g., resolution) of the current image sequence. For example, in a current image sequence of 1920×1080, the horizontal and vertical distances from position 10 in FIG. 12 to the bottom right corner of the current block are both 32 pixels, and in a current image sequence of 1280×720, the horizontal and vertical distances from position 10 in FIG. 5 to the bottom right corner of the current block are both 16 pixels.
[0112] In one example, the horizontal and / or vertical distance between the non-adjacent position and the set sample in the current block is determined based on a flag, such as a sequence level (sequence parameter set) flag or a picture level flag or a slice level (slice header) flag of the current image sequence. As an example, a sequence level flag or a picture level flag or a slice level flag (which may be a 1-bit flag) of 0 means that the horizontal and vertical distances from the position 10 in FIG. 12 to the lower right corner of the current block are both 32 pixels, and these flags of 1 mean that the horizontal and vertical distances from the position 10 in FIG. 12 to the lower right corner of the current block are both 16 pixels. The sequence level flag, the picture level flag and the slice level flag may be newly added flags or may reuse existing flags, and indicate a value to be selected from a plurality of pre-defined values, which are the horizontal and / or vertical distances between the non-adjacent position and the set sample in the current block.
[0113] In one exemplary embodiment of the present disclosure, the coded image is a reference image of the current block. Determining the first temporal motion information of the current block based on the motion information of at least one non-adjacent position in the coded image includes: determining a collocated block corresponding to the non-adjacent position in the reference image; obtaining the motion information of the collocated block; and scaling a motion vector in the obtained motion information to obtain the first temporal motion information of the current block. In this embodiment, the collocated block corresponding to the non-adjacent position in the reference image is a coding unit or a smallest storage unit at the non-adjacent position in the reference image. Or, if the coordinate range of one coding unit or a smallest storage unit in the reference image includes the coordinates of the non-adjacent position, the coding unit or the smallest storage unit is a collocated block corresponding to the non-adjacent position in the reference image.
[0114] In one exemplary embodiment of the present disclosure, all of the non-adjacent locations are within the range of the largest coding unit (LCU) or coding tree unit (CTU) in which the current block is located, or all of the non-adjacent locations are within the range of the LCU row or CTU row in which the current block is located. Considering storage costs, the decoding device may generally cache only a part of the motion information stored in the co-located image. Thus, the range of motion information in the co-located image that can be read for the current block may be limited. For example, for the current block, only the motion information stored in the co-located image at the position corresponding to the current CTU may be read, or for the current block, only the motion information stored in the co-located image at the position corresponding to the current CTU row may be read. This restriction may also be applied to all the above methods. If the location used to derive temporal motion information is beyond the range available for the current block, for example, beyond the current CTU or the current CTU row, the co-located block at this position is unavailable, and the derivation of temporal motion information for this position may be terminated.
[0115] In one exemplary embodiment of the present disclosure, the horizontal distance and / or vertical distance between the non-adjacent position and the set sample in the current block can also be determined based on a combination of multiple parameters. For example, if the sequence level flag of the current image sequence is 1 and the size of the current block is 16×16, the horizontal distance and vertical distance are set to 16. Different combinations correspond to different horizontal distances and vertical distances.
[0116] In one exemplary embodiment of the present disclosure, the temporal motion information prediction method further includes temporal motion information prediction based on adjacent positions, ie, includes both NATMVP and TMVP.
[0117] In one exemplary embodiment of the present disclosure, when there are at least three positions for deriving the first temporal motion information in the same direction, the distance between adjacent positions among the at least three positions is the same, or the distance between adjacent positions among the at least three positions is variable, and the distance between two adjacent positions increases as the positions move away from the current block. That is, the distance between positions in the same direction may be fixed or variable. Referring to FIG. 12, there are three positions numbered 17, 25, and 33 on the right side of the current block. The distance between position 17 and position 25 is equal to the distance between position 25 and position 33, that is, position 17, position 25, and position 33 are set at equal distances. In another example, the distance between position 25 and position 33 may be greater than the distance between position 17 and position 25.
[0118] In one exemplary embodiment of the present disclosure, the at least one non-adjacent location includes any one or more of the following locations: The coordinates are (xCb+2*k_cbWidth-1, yCb+2*k_cbHeight-1), (xCb+2*k_cbWidth, yCb+2*k_cbHeight-1), (xCb+2*k_cbWidth-1, yCb+2*k_cbHeight), or (xCb+2*k_cbWidth, yCb+2*k_cbHeight), The coordinates are (xCb+3*k_cbWidth-1, yCb+3*k_cbHeight-1), (xCb+3*k_cbWidth, yCb+3*k_cbHeight-1), (xCb+3*k_cbWidth-1, yCb+3*k_cbHeight), or (xCb+3*k_cbWidth, the second position, which is yCb+3*k_cbHeight), The coordinates are (xCb+3*k_cbWidth-1, yCb+k_cbHeight / 2-1), (xCb+3*k_cbWidth, yCb+k_cbHeight / 2-1), (xCb+3*k_cbWidth-1, yCb+k_cbHeight / 2), or (xCb+3*k_cbWidth, the third position, which is yCb+k_cbHeight / 2), The fourth position where the coordinates are (xCb + k_cbWidth / 2, yCb + 3*k_cbHeight - 1), (xCb + k_cbWidth / 2, yCb + 3*k_cbHeight), (xCb + k_cbWidth / 2 - 1, yCb + 3*k_cbHeight - 1), or (xCb + k_cbWidth / 2 - 1, yCb + 3*k_cbHeight), The fifth position where the coordinates are (xCb + 2*k_cbWidth - 1, yCb + k_cbHeight / 2 - 1), (xCb + 2*k_cbWidth, yCb + k_cbHeight / 2 - 1), (xCb + 2*k_cbWidth - 1, yCb + k_cbHeight / 2), or (xCb + 2*k_cbWidth, yCb + k_cbHeight / 2), The sixth position where the coordinates are (xCb + k_cbWidth / 2, yCb + 2*k_cbHeight - 1), (xCb + k_cbWidth / 2, yCb + 2*k_cbHeight), (xCb + k_cbWidth / 2 - 1, yCb + 2*k_cbHeight - 1), or (xCb + k_cbWidth / 2 - 1, yCb + 2*k_cbHeight), The seventh position where the coordinates are (xCb + k_cbWidth, yCb + 2*k_cbHeight), (xCb + k_cbWidth, yCb + 2*k_cbHeight - 1), (xCb + k_cbWidth - 1, yCb + 2*k_cbHeight), or (xCb + k_cbWidth - 1, yCb + 2*k_cbHeight - 1), and The eighth position where the coordinates are (xCb + 2*k_cbWidth, yCb + k_cbHeight), (xCb + 2*k_cbWidth - 1, yCb + k_cbHeight), (xCb + 2*k_cbWidth, yCb + k_cbHeight - 1), or (xCb + 2*k_cbWidth - 1, yCb + k_cbHeight - 1).
[0119] where xCb is the abscissa of the top-left corner of the current block, yCb is the ordinate of the top-left corner of the current block, k_cbWidth is the width of the current block, or ½ the width, or ¼ the width, or twice the width, k_cbHeight is the height of the current block, or ½ the height, or ¼ the height, or twice the height, and "*" indicates a multiplication operation.
[0120] 12 and 13, the position with coordinates (xCb+2*cbWidth-1, yCb+2*cbHeight-1) is represented as position 10 in FIG. 12, the position with coordinates (xCb+3*cbWidth-1, yCb+3*cbHeight-1) is represented as position 16 in FIG. 12, and other positions are not detailed.
[0121] In one exemplary embodiment of the present disclosure, the temporal motion information prediction method further includes predicting temporal motion information based on adjacent positions, where the adjacent positions include an adjacent position of a lower right corner of a current block, the non-adjacent positions of the current block and the adjacent position of the lower right corner of the current block are distributed in an array, the upper left corner of the array is the adjacent position of the lower right corner of the current block, and different positions in the array are distributed in different minimum storage units in the coded image.
[0122] Each position in the array can be obtained by scanning within a set range, for example, scanning within a rectangular region shown in the lower right corner of Fig. 13 in a certain order to determine non-adjacent positions used for temporal motion information prediction, and determining temporal motion information based on the scanned positions.
[0123] The width and height of the rectangular region in FIG. 13 may be preset, for example, both the width and height are 64 pixels. Or, the width and height of the rectangular region may be determined based on the size of the current block, for example, the width of the rectangular region is four times the width of the current block, and the height of the rectangular region is four times the height of the current block. Or, the width and height of the rectangular region may be determined based on the parameters of the current image sequence, for example, the width and height of this region in a 1920×1080 sequence are both 64 pixels, and the width and height of this region in a 1280×720 sequence are both 32 pixels. Or, the width and height of the rectangular region may be determined based on a flag, for example, a sequence level (sequence parameter set) flag of the current sequence image, or a slice level (slice header) flag of the current image. For example, a flag of 0 means that the width and height of this region are both 64 pixels, and a flag of 1 means that the width and height of this region are both 32 pixels. The scan order may be a raster scan order, ie, the order shown in the figure, or it may be a zig-zag scan order or some other scan order.
[0124] The motion information of the collocated image is stored in the smallest storage unit, for example, a 4x4 block, an 8x8 block, or a 16x16 block. Only one motion information is stored in the smallest storage unit. Scanning can be performed at the granularity of each smallest storage unit. Reflecting on the coordinates, if the smallest storage unit is an 8x8 block, in the horizontal direction, 8 is added to the abscissa of the next scan position, and there is no change in the ordinate. In the vertical direction, there is no change in the abscissa of the next scan position, and there is no change in the ordinate. The scan granularity can be related to the size of the current block, for example, the horizontal granularity is equal to the width of the current block, and the vertical granularity is equal to the height of the current block. Reflecting on the coordinates, in the horizontal direction, the width of the current block is added to the abscissa of the next scan position, and there is no change in the ordinate. In the vertical direction, there is no change in the abscissa of the next scan position, and there is no change in the height of the current block. The granularity can also be determined based on parameters of the current image sequence, for example, the horizontal and vertical scan granularities in a current image sequence of 1920×1080 are both 16 pixels, and the horizontal and vertical scan granularities in a sequence of 1280×720 are both 32 pixels. The granularity can also be determined based on a flag, for example, a sequence level flag of the current image sequence, or an image level flag of the current image, or a slice level flag of the current image. For example, the flag being 0 means that the horizontal and vertical scan granularities are both 16 pixels, and the flag being 1 means that the horizontal and vertical scan granularities are both 32 pixels.
[0125] During scanning, the method can limit the number of added temporal motion information candidates, i.e., not all positions within a rectangular area are scanned when performing temporal motion information prediction.
[0126] In the temporal motion information prediction method according to the above embodiment of the present disclosure, the temporal motion information of the current block is determined using non-adjacent positions, thereby effectively complementing motion information of some scenarios that cannot be covered by spatial motion information, such as motion from right to left, motion from bottom right to top left, and motion from bottom to top, and improving compression efficiency. In addition, the temporal motion information prediction method according to the above embodiment proposes to set the directions of these non-adjacent positions relative to the current block, the distances between the non-adjacent positions, and the like, to more efficiently extract the temporal motion information of the current block.
[0127] As shown in Figure 9, an embodiment of the present disclosure further provides a candidate motion information list building method. The candidate motion information list building method includes the following contents:
[0128] Step 210: Perform spatial motion information prediction and temporal motion information prediction on the current block to determine spatial motion information and temporal motion information of the current block.
[0129] Step 220: Add the spatial motion information and the temporal motion information to the candidate motion information list of the current block in the set order.
[0130] The temporal motion information prediction utilizes the temporal motion information prediction method described in any one of the embodiments of the present disclosure. The temporal motion information includes first temporal motion information.
[0131] In one exemplary embodiment of the present disclosure, the method for building a candidate motion information list is used for merge mode.
[0132] In HEVC and VVC, the motion information candidate list in merge mode is a common scenario using motion information prediction. In an embodiment of the present disclosure, spatial motion information and temporal motion information (which may also be collectively referred to as candidate motion information) may be added to the candidate motion information list mergeCandList according to a certain order (e.g., order of relevance). One possible process of constructing mergeCandList is as follows: Check whether each motion information candidate, such as spatial motion information at adjacent positions, temporal motion information at adjacent positions, spatial motion information at non-adjacent positions, temporal motion information at non-adjacent positions, and history-based motion information, is similar to the motion information candidate already added to or determined to be added to mergeCandList in a preset order and according to a preset threshold. If the motion information candidate waiting to be added to the list is not similar to the motion information candidate already added to or determined to be added to mergeCandList, it is determined to add the motion information candidate waiting to be added to the list. Otherwise, it is determined not to add the motion information candidate waiting to be added to the list.
[0133] The correlation order can be set as follows: The closer the distance to the current block, the stronger the correlation. If the distance is the same, spatial motion information prediction has a stronger correlation than temporal motion information prediction. However, since NATMVP can provide motion information in some directions that cannot be provided by SMVP and NASMVP, how to add these candidates to mergeCandList becomes an issue to consider.
[0134] In one exemplary embodiment of the present disclosure, the set order is determined based on one or more of the following rules: If the distance of the spatial motion information is less than or equal to the distance of the temporal motion information, the spatial motion information is preferentially added to the candidate motion information list. If the distance of the spatial motion information is greater than that of the temporal motion information, the temporal motion information is preferentially added to the candidate motion information list. When the distances of a plurality of pieces of temporal motion information are different, the temporal motion information with a smaller distance is preferentially added to the candidate motion information list. If the distances of multiple temporal motion information are the same, the order in which they are added to the candidate motion information list is determined according to the statistical rules of the temporal motion information.
[0135] The distance of spatial motion information is the distance from the position where the spatial motion information is derived to the current block, and the distance of temporal motion information is the distance from the position where the temporal motion information is derived to the current block. The distance from a position to the current block is determined based on a rectangular box in which the position is located or adjacent to the position. The current block is surrounded by the rectangular box and is located at the center of the rectangular box. The width of the rectangular box is an integer multiple of the width of the current block, and the height of the rectangular box is an integer multiple of the height of the current block, and the larger the area of the rectangular box, the larger the distance from the position to the current block. For example, in FIG. 12, the distances from positions 11, 14, 15, 13, 12, 17, 16, and 18 to the current block are considered to be the same. Any of the above positions may include adjacent positions and non-adjacent positions. The abscissa deviation from the position to the closest sample in the current block is the absolute value of the difference between the abscissa of the position and the abscissa of the closest sample in the current block, and the ordinate deviation from the position to the closest sample in the current block is the absolute value of the difference between the ordinate of the position and the ordinate of the closest sample in the current block.
[0136] The order of the correlation may refer to the order of the positions shown in FIG. 12. The small black squares in the figure represent positions used for spatial motion information prediction, and the small squares with cut lines represent positions used for temporal motion information prediction. It can be seen that: If the distance of the spatial motion information is less than or equal to the distance of the temporal motion information, for example, position 16 is a position used for temporal motion information prediction, position 11 is a position used for spatial motion information prediction, and the distance from position 16 to the current block is the same as the distance from position 11 to the current block, then the spatial motion information derived based on position 11 is preferentially added to the candidate motion information list. As another example, position 19 is a position used for spatial motion information prediction, and the distance from position 19 to the current block is greater than the distance from position 16 to the current block, so the temporal motion information derived based on position 16 is preferentially added to the candidate motion information list over the spatial motion information derived based on position 19. As another example, since positions 10 and 16 are both positions used to derive temporal motion information, and the distance from position 10 to the current block is smaller, the temporal motion information derived based on position 10 is preferentially added to the candidate motion information list.
[0137] In one example, the first temporal motion information includes at least two of the first temporal motion information derived based on a non-adjacent position on the lower right side of the current block, the first temporal motion information derived based on a non-adjacent position on the right side of the current block, and the first temporal motion information derived based on a non-adjacent position below the current block. When the distances of the multiple first temporal motion information are the same, determining the order of adding to the candidate motion information list according to the statistical law of the temporal motion information includes: The first temporal motion information derived based on the non-adjacent position on the lower right side of the current block is added to the candidate motion information list with priority over the first temporal motion information derived based on the non-adjacent position on the right side of the current block. The first temporal motion information derived based on the non-adjacent position on the right side of the current block is added to the candidate motion information list with priority over the first temporal motion information derived based on the non-adjacent position below the current block.
[0138] Still taking FIG. 12 as an example, positions 18, 16, and 17 are all used to derive temporal motion information. It is necessary to determine the order of adding to the candidate motion information list according to the statistical law of temporal motion information. Research has shown that in this order, the lower right position has priority over the right position, and the right position has priority over the lower position. Therefore, the correlation of the temporal motion information derived based on position 16 is the highest, the correlation of the temporal motion information derived based on position 17 is the second highest, and the correlation of the temporal motion information derived based on position 18 is the lowest. The order of the temporal motion information with high correlation is at the front, that is, the temporal motion information with high correlation is preferentially added to the candidate motion information list.
[0139] There are two positions 6 in the figure. If position 6 on the bottom right side of the current block is unavailable, it can be replaced by position 6 in the center of the current block. If position 6 on the bottom right side of the current block is available, position 6 in the center of the current block is not used. In a real application, it is possible to trade off performance and complexity and not use as many candidates as in the figure, or to use more candidates according to the above principles.
[0140] In this embodiment, the positions used to derive spatial motion information are shown by small black squares in FIG. 12, the large square with a cut line in the center is the current block, and the five positions adjacent to the current block, namely positions 1 to 5, are the positions used for spatial motion information prediction to derive spatial motion information. Outside these positions, some non-adjacent positions can be used to perform spatial motion information prediction based on non-adjacent positions (NASMVP). As shown in FIG. 12, the non-adjacent positions on the lower left, left, upper left, upper, and upper right sides of the current block can be used to derive spatial motion information. The blocks on the right, lower right, and lower sides have not yet been coded, so they cannot be used for spatial motion information prediction. There is a certain distance between these non-adjacent positions and the current block. In one example, the horizontal distance between these positions and the current block is related to the length of the current block, and the vertical distance between these positions and the current block is related to the width of the current block. For example, the non-adjacent positions are determined by expanding outward by the length and width of the current block. Positions in the inner layer are preferentially added to the list because they are closer.
[0141] An example of spatial motion information prediction is as shown in Figure 12. The motion information is added to the list according to the order shown in the figure, which takes into account the characteristics of correlation and statistical law of motion.
[0142] In one exemplary embodiment of the present disclosure, the order of the earliest first temporal motion information among the first temporal motion information is determined in at least one of the following manners. In the geometric partitioning mode (GPM), the sequence number set for the earliest first temporal motion information is less than or equal to the maximum number of candidate motion information allowed to be added to the candidate motion information list. In a set fast motion scenario, the sequence number set for the earliest first temporal motion information is less than or equal to the maximum number of candidate motion information that is allowed to be added to the candidate motion information list.
[0143] In this embodiment, in some specific cases, in order to better utilize the temporal motion information of non-adjacent positions and effectively compensate for the lack of spatial motion information prediction, in the GPM, the sequence number set for the first temporal motion information can be equal to or less than the maximum number of candidate motion information allowed to be added to the candidate motion information list. For example, if the maximum number of candidate motion information allowed to be added to the candidate motion information list is 6, the sequence number of the first temporal motion information can be set to 6 or a value smaller than 6. The sequence number here means the order in which motion information is added to the candidate motion information list. A sequence number of 1 means that it is added to the candidate motion information list first, and a sequence number of 2 means that it is added to the candidate motion information list second, and so on. By setting in this way, it can be ensured that the first temporal motion information can also be added to the candidate motion information list even if all the upper motion information is valid and added to the candidate motion information list. However, in these specific cases, to ensure that the first temporal motion information can be added to the candidate motion information list, the ranking of the first temporal motion information can be increased, and the maximum number of candidate motion information allowed to be added to the candidate motion information list can also be increased, for example, from 6 to 7 in these specific cases. The above fast motion scenarios may be set by a user or may be obtained by the system's own learning.
[0144] When adding each candidate motion information to mergeCandList, an identity check or similarity check can be performed to prevent the same motion information or very similar motion information from being added to mergeCandList. This helps mergeCandList to provide more candidates in practice. The methods and standards for checking the similarity may be different in temporal motion information prediction and spatial motion information prediction. For example, SMVP and NASMVP based on different positions can provide some similar motion information (such as some gradual changes or subtle changes) inside the same object. However, temporal motion information, especially NATMVP, requires more "different" motion information. The so-called "different" refers to motion information with a larger difference compared to "similar". The difference between "different" and "similar" can be reflected in the difference in thresholds.
[0145] Each spatial motion information, temporal motion information, and other motion information is added to mergeCandList in a certain order. When constructing the candidate list, the above-mentioned identity check or similarity check can be used. One method is to discard the same or similar motion information candidates and not add them to mergeCandList. When adding the temporal motion information derived based on non-adjacent positions, a different threshold for determining similarity can be used. For example, the similarity threshold used for the temporal motion information derived based on non-adjacent positions is larger than the similarity threshold used for the spatial motion information derived based on adjacent positions (e.g., one threshold set for the motion vector).
[0146] In one exemplary embodiment of the present disclosure, adding the spatial motion information and the temporal motion information to the candidate motion information list of the current block in a set order includes the following contents: Before adding the spatial motion information or the temporal motion information to the candidate motion information list, a similarity check (including an identity check) is performed. If the similarity check determines that the spatial motion information or the temporal motion information is not similar to any of the candidate motion information already added or determined to be added to the candidate motion information list, the spatial motion information or the temporal motion information is added to the candidate motion information list. A first similarity threshold θ1 is used when performing a similarity check on the first temporal motion information, and a second similarity threshold θ2 is used when performing a similarity check on the spatial motion information, where θ1>θ2 or θ1=θ2.
[0147] In one exemplary embodiment of the present disclosure, the temporal motion information further includes temporal motion information determined by temporal motion information prediction based on adjacent positions, and a third similarity threshold θ3 is used when performing a similarity check on the temporal motion information determined by the temporal motion information prediction based on adjacent positions, and θ1>θ3 or θ1=θ3. That is, in this embodiment, the similarity threshold set on the temporal motion information determined by the temporal motion information prediction based on adjacent positions may be smaller than the similarity threshold set on the temporal motion information determined by NATMVP, so that the temporal motion information determined by the temporal motion information prediction based on adjacent positions is more likely to pass the similarity check.
[0148] In one exemplary embodiment of the present disclosure, the first similarity threshold is determined based on one of the parameters of the current image sequence and the parameters of the current image. In one example, the parameters of the current image sequence include the resolution of the sequence. The parameters of the current image include one or more of the following: image width, image height, and number of samples of the image. There are multiple first similarity thresholds, and the larger the first similarity threshold, the larger the value of the corresponding parameter. That is, the first similarity threshold in this embodiment is related to some parameters of the sequence or the image. As can be seen, the same motion has a larger motion vector in a video with a higher resolution compared to a video with a lower resolution. Therefore, the similarity threshold of the temporal motion information derived based on the non-adjacent positions can be set based on the parameters of the sequence or the parameters of the image, for example, based on the resolution of the sequence, the width and / or height of the image, or the number of samples of the image. For example, for a 1920x1080 sequence, the threshold is set to 64, and for a 1280x720 sequence, the threshold is set to 16. The threshold can be calculated based on the width and / or height of the image. For example, say the threshold is diffThT, the image width is picWidth, and the image height is picHeight, where diffThT=picWidth*picHeight>> 14. ">>" denotes a right shift, i.e., a divide by 2 operation.
[0149] In one exemplary embodiment of the present disclosure, the first similarity threshold is determined based on a reference relationship of the current image, and the reference relationship includes unidirectional reference and bidirectional reference. The first similarity threshold determined when the reference relationship is unidirectional reference is smaller than the first similarity threshold determined when the reference relationship is bidirectional reference. The forward reference refers to only the forward reference image or the backward reference image being available for the current image, and the bidirectional reference refers to both the forward reference image and the backward reference image being available for the current image.
[0150] That is, the first similarity threshold can be related to the reference relationship of the image. As mentioned above, compared with the random access arrangement, it is more difficult to obtain directional motion information such as from right to left and from bottom to top in the low latency arrangement. This is because in the low latency arrangement, the current image can only refer to a reference image that is in front of the current image according to the POC or a reference image that is in front of the current image according to the temporal order. In contrast, in the random access arrangement, the image can refer to both a reference image that is in front of the current image according to the POC and a reference image that is in back of the current image according to the POC. Therefore, the setting of the first similarity threshold can be related to the reference relationship of the current image. One possible method is as follows. If the current image can only refer to a reference image that is in front of the current image according to the POC, the threshold of the image is multiplied by a relatively small coefficient. If the current image can only refer to a reference image that is in front of the current image according to the POC, the threshold of the image is multiplied by a relatively small coefficient. As an example, the relatively small coefficient is 1, and the relatively large coefficient is 4. For example, the threshold is denoted as diffThT, and the base threshold is denoted as diffThBase. diffThBase can be obtained by other methods mentioned above. If the current image can only refer to a reference image that is before the current image according to the POC, diffThT=diffThBase*1. If the current image can refer to both a reference image that is before the current image according to the POC and a reference image that is after the current image according to the POC, diffThT=diffThBase*4.
[0151] In one exemplary embodiment of the present disclosure, the first similarity threshold is determined based on whether or not template matching is used for the current prediction mode, and the first similarity threshold determined when template matching is used is greater than the first similarity threshold determined when template matching is not used. The template matching method can realize a search within a certain range, so that the motion information can be optimized to a certain extent, and the search range can be widened by the template, so that candidate motion information that is too similar is not required in the candidate motion information list, and the more different the two motion information, the more effective it becomes. Therefore, when the template matching method is used for the current block, the threshold used to determine the similarity can be set larger than when the template matching method is not used.
[0152] In one exemplary embodiment of the present disclosure, the first similarity threshold is determined based on any one or more of a preset value, a parameter of the current image sequence, a parameter of the current image, a size of the current block, a sequence level flag of the current image sequence, a slice level flag of the current image, an image level flag of the current image, a flag indicating whether template matching is used for the current prediction mode, and a reference relationship of the current image. In one example, the similarity threshold of the temporal motion information derived based on the non-adjacent positions may be a fixed value such as 16, 32, 64, 128, etc. Since the motion information can support fractional pixel accuracy, the threshold can represent one pixel unit, two pixel units, four pixel units, eight pixel units, etc., where the pixel unit can be, for example, 1 / 16 pixel. In another example, the first similarity threshold can be related to the size of the current block, for example, the threshold is determined based on the width and / or height of the current block, or the number of samples. For example, if the number of samples of the current block is greater than 64, the threshold is set to 32, and if not, the threshold is set to 16. In a further example, the first similarity threshold is established based on a flag, such as a sequence level flag, or an image level flag, or a slice level flag, etc. As an example, a flag of 0 represents the threshold value being 16, and a flag of 1 represents the threshold value being 32.
[0153] In one example of this embodiment, determining the first similarity threshold based on any of a plurality of parameters includes setting the first similarity threshold to the maximum value of the first similarity thresholds determined based on a plurality of methods. The time motion information derived based on non-adjacent positions can be determined as the maximum value of the similarity thresholds set based on a plurality of factors. If the threshold for similarity judgment preset for the time motion information derived based on non-adjacent positions is 16 and the threshold determined based on other parameters is 1, the threshold for similarity judgment for the time motion information derived based on non-adjacent positions is set to 16. If the threshold for similarity judgment set for the time motion information derived based on non-adjacent positions is 16 and the threshold determined based on other parameters is 32, the threshold for similarity judgment for the time motion information derived based on non-adjacent positions is set to 32. However, in another example, it is also possible to determine different first similarity thresholds based on different combinations of parameters.
[0154] The number of added temporal motion information candidates can be limited, for example, a maximum of two temporal motion information candidates can be added, and when two pieces of temporal motion information that can be added to mergeCandList are determined, temporal motion information prediction based on the subsequent position is terminated.
[0155] After the motion information to be added to mergeCandList is determined based on all the above methods, the motion information can be ordered according to some rule to determine mergeCandList.
[0156] In an exemplary embodiment of the present disclosure, the temporal motion information prediction method further includes: determining whether the temporal motion information prediction based on non-adjacent positions is permitted to be used for the current block according to a first flag; and if it is determined that the temporal motion information prediction based on non-adjacent positions is permitted to be used, executing the method according to claim 1. The first flag includes one or more of the following: a first sequence level flag for indicating whether non-adjacent position based temporal motion information prediction is permitted to be utilized for the current image sequence; a first picture level flag for indicating whether non-adjacent position based temporal motion information prediction is allowed to be used for the current picture; and A first slice-level flag to indicate whether temporal motion information prediction based on non-adjacent positions is allowed to be utilized for the current slice.
[0157] In this embodiment, the first flag includes at least two of a first sequence level flag, a first picture level flag, and a first slice level flag. The first sequence level flag has a higher level than the first picture level flag, and the first picture level flag has a higher level than the first slice level flag. Determining whether the non-adjacent position-based temporal motion information prediction is permitted to be used for the current block based on the first flag includes: Analyzing the first flags in descending order of levels; If the flag of a higher level indicates that the non-adjacent position-based temporal motion information prediction is permitted to be used, analyzing the flag of a lower level; If all the flags of all levels indicate that the non-adjacent position-based temporal motion information prediction is permitted to be used, determining that the non-adjacent position-based temporal motion information prediction is permitted to be used.
[0158] In an exemplary embodiment of the present disclosure, the temporal motion information prediction method further includes: determining whether the first flag needs to be analyzed according to the second flag; analyzing the first flag when it is determined that the first flag needs to be analyzed; and determining whether the temporal motion information prediction based on the non-adjacent position is allowed to be used for the current block according to the first flag. The second flag is the following flag: a flag indicating whether the temporal motion information is permitted to be used for the current image sequence, and if the flag indicates that the temporal motion information is not permitted to be used for the current image sequence, it is determined that there is no need to analyze the first flag; a flag indicating whether the time motion information is permitted to be used for the current image, and if the flag indicates that the time motion information is not permitted to be used for the current image, it is determined that there is no need to analyze the first flag; a flag indicating whether non-adjacent positions are permitted to be used for deriving motion information, and if the flag indicates that the non-adjacent positions are not permitted to be used for deriving motion information, it is determined that there is no need to analyze the first flag; and This includes any one or more of the following. If it is determined based on the second flag that the first flag needs to be parsed, the first flag is parsed.
[0159] In the above embodiment, a flag is used to control whether NATMVP is enabled or disabled.
[0160] A flag can be used to control whether non-adjacent location-based temporal motion prediction (NATMVP) is enabled or disabled. The flag may be a sequence level (sequence parameter set) or picture level (picture header or picture parameter set) or slice level (slice header) flag or block level flag. The flag can control whether the NATMVP technique described in the present invention is used (or is permitted to be used) for the corresponding sequence, picture, slice, or block. As an example, if the value of the flag is 1, the NATMVP technique described in the present invention is used (or is permitted to be used) for the current sequence, picture, slice, or block. If the value of the flag is 0, the NATMVP technique described in the present invention is not used (or is not permitted to be used) for the current sequence, picture, slice, or block. The flag may depend on some other flags. For example, sps_temporal_mvp_enabled_flag or ph_temporal_mvp_enabled_flag. The flag sps_temporal_mvp_enabled_flag controls whether temporal motion information is allowed to be used for the current sequence. The flag ph_temporal_mvp_enabled_flag controls whether temporal motion information is allowed to be used for the current picture. As can be seen, if temporal motion information is allowed to be used for the current sequence or the current picture, the decoder needs to analyze a flag to control whether the use of temporal motion information prediction based on non-adjacent positions is allowed. Otherwise, the decoder does not need to analyze a flag to control whether the use of temporal motion information prediction based on non-adjacent positions is allowed. The flag may depend on other flags, such as a flag indicating whether the use of motion information derived based on non-adjacent positions is allowed.
[0161] Flags for controlling NATMVP can be graded, with lower-level flags depending on higher-level flags. For example, the sequence-level flag sps_natmvp_enabled_flag controls whether NATMVP is enabled for the current sequence, and the picture-level flag ph_natmvp_enabled_flag controls whether NATMVP is enabled for the current picture. If sps_natmvp_enabled_flag has a value of 1, the decoder must parse ph_natmvp_enabled_flag. If sps_natmvp_enabled_flag has a value of 0, the decoder does not need to parse ph_natmvp_enabled_flag.
[0162] In the candidate motion information list construction method of the above embodiment of the present disclosure, temporal motion information derived based on non-adjacent positions can be added to the candidate motion information list, and by taking into account the order of correlation between the temporal motion information derived based on non-adjacent positions and other motion information, the motion information of some scenarios that cannot be covered by spatial motion information can be effectively complemented, and compression efficiency can be improved.
[0163] An embodiment of the present disclosure further provides a video encoding method, as shown in Figure 14, the video encoding method includes:
[0164] Step 310: Construct a candidate motion information list for the current block according to the candidate motion information list constructing method described in any one of the embodiments of the present disclosure.
[0165] Step 320: Select one or more candidate motion information from the candidate motion information list, and record the indexes of the selected candidate motion information.
[0166] Step 330: determine a prediction block of the current block according to the selected candidate motion information, encode the current block according to the prediction block, and encode an index of the candidate motion information.
[0167] According to the selected candidate motion information, the position of the reference block of the current block in the reference image can be determined. In this case, the reference block can be obtained by adding the motion vector difference to the selected candidate motion information. According to the reference block (for example, one or two), a prediction block can be obtained. Then, the residual between the prediction block and the current block can be calculated and encoded.
[0168] An embodiment of the present disclosure further provides a video decoding method, as shown in Figure 5, the video decoding method includes:
[0169] Step 410: Construct a candidate motion information list for the current block according to the candidate motion information list constructing method described in any one of the embodiments of the present disclosure.
[0170] Step 420: Select one or more candidate motion information from the candidate motion information list according to the indexes of the candidate motion information of the current block obtained by decoding.
[0171] Step 430: Determine a prediction block of the current block according to the selected candidate motion information, and reconstruct the current block according to the prediction block.
[0172] An embodiment of the present disclosure further provides a time motion information prediction device. As shown in Fig. 16, the time motion information prediction device includes a processor 71 and a memory 73 in which a computer program is stored. When the processor 71 executes the computer program, the time motion information prediction device executes the time motion information prediction method described in any one of the embodiments of the present disclosure.
[0173] An embodiment of the present disclosure further provides a candidate motion information list construction device. As shown in Figure 16, the candidate motion information list construction device includes a processor and a memory storing a computer program. When the processor executes the computer program, it executes the candidate motion information list construction method described in any one of the embodiments of the present disclosure.
[0174] An embodiment of the present disclosure further provides a video encoding device. As shown in Fig. 16, the video encoding device includes a processor and a memory in which a computer program is stored. When the processor executes the computer program, the video encoding device executes the video encoding method according to any one of the embodiments of the present disclosure.
[0175] An embodiment of the present disclosure further provides a video decoding device. As shown in Figure 16, the video decoding device includes a processor and a memory in which a computer program is stored. When the processor executes the computer program, the video decoding device executes the video decoding method according to any one of the embodiments of the present disclosure.
[0176] An embodiment of the present disclosure further provides a video coding system, which includes a video encoding device according to any one of the embodiments of the present disclosure and a video decoding device according to any one of the embodiments of the present disclosure.
[0177] An embodiment of the present disclosure further provides a non-transitory computer-readable storage medium, the computer-readable storage medium storing a computer program, the computer program being executed by a processor to perform the method according to any one of the embodiments of the present disclosure.
[0178] An embodiment of the present disclosure further provides a bitstream, the bitstream being generated by the video encoding method according to any one of the embodiments of the present disclosure.
[0179] The video encoding device and / or the video decoding device of the above embodiments of the present disclosure may be realized using any one or any combination of the following circuits: one or more microprocessors, digital signal processors (DSPs), application specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), discrete logic circuits, and hardware. When the present disclosure is partially implemented in software, instructions used in the software may be stored in a suitable non-volatile computer-readable storage medium, and one or more processors may be used to implement the methods of the embodiments of the present disclosure by executing the instructions in hardware.
[0180] In one or more exemplary embodiments, the functions described may be implemented by hardware, software, firmware, or any combination thereof. If implemented by software, the functions may be stored on or transmitted via a computer-readable medium as one or more instructions or codes and executed by a hardware-based processing unit. A computer-readable medium may include a computer-readable medium that is a tangible medium, such as a data storage medium, or may include any communication medium that facilitates the transmission of a computer program from one place to another, for example according to a communication protocol. As such, a computer-readable medium may typically be a non-transitory tangible computer-readable storage medium, or a communication medium, such as a signal or carrier. A data storage medium may be any available medium that can be accessed by one or more computers or one or more processors to retrieve instructions, codes, and / or data structures for implementing the techniques described in this disclosure. A computer program product may include a computer-readable medium.
[0181] By way of example and not limitation, such computer-readable storage media may include random access memory (RAM), read only memory (ROM), electrically erasable programmable ROM (EEPROM), compact disk ROM (CD-ROM) or other optical disk storage, magnetic disk storage or other magnetic storage, flash memory, or any other medium that stores desired program code in the form of instructions or data structures and that can be accessed by a computer. Also, any connection may be referred to as a computer-readable storage medium, and by way of example, when instructions are transmitted from a website, server, or other remote source using coaxial cable, fiber optic cable, twisted-pair cabling, digital subscriber line (DSL), or wireless technologies such as infrared, radio, microwave, etc., coaxial cable, fiber optic cable, twisted-pair cabling, DSL, or wireless technologies such as infrared, radio, microwave, etc., are included in the definition of medium. However, computer-readable storage media and data storage media do not include connections, carriers, signals, or other temporary (transient) media, but are non-transitory tangible storage media. As used herein, magnetic disks and optical disks include compact disks (CDs), laser disks, optical disks, digital versatile discs (DVDs), floppy disks, or Blu-ray disks, etc., where magnetic disks typically reproduce data magnetically and optical disks reproduce data optically using lasers. Combinations of the above should also be included within the scope of computer-readable media.
[0182] The instructions may be executed by one or more processors, such as, for example, one or more DSPs, general-purpose microprocessors, ASICs, FPGAs, or other equivalent integrated circuits or discrete logic circuits. Thus, the term "processor" as used herein may refer to any one of the above structures, or any other structure suitable for implementing the techniques described herein. Furthermore, in some aspects, the functionality described herein may be provided in dedicated hardware and / or software modules configured for use in encoding and decoding, or may be incorporated into an integrated encoder-decoder. Additionally, the techniques described herein may be fully implemented in one or more circuit or logic elements.
[0183] The technical solutions of the embodiments of the present disclosure may be implemented in various devices or equipment, including a wireless mobile phone, an integrated circuit (IC), or a set of ICs (e.g., a chipset). The embodiments of the present disclosure highlight the functionality of a device configured to execute the described techniques using various components, modules, or units, and not necessarily realized by different hardware units. As described above, the various units may be combined in a hardware unit of a codec, or may be provided in a collection of interoperable hardware units (including one or more processors as described above) in combination with appropriate software and / or firmware.
Claims
1. A method for predicting temporal motion information, comprising: determining at least one non-adjacent location of the current block; determining first temporal motion information of the current block based on motion information of the at least one non-adjacent position in the coded image; Including, A method for predicting temporal motion information comprising:
2. The non-adjacent locations are non-adjacent locations in the following directions: a non-adjacent location to the right of the current block; a non-adjacent location below the current block; and a non-adjacent position on the lower right side of the current block; Any one or more of the following:
2. The method of claim 1 .
3. the horizontal and / or vertical distance between the non-adjacent position and the set sample in the current block is a preset fixed value, or The horizontal and / or vertical distance between the non-adjacent location and the set sample in the current block is variable and depends on the following parameters: The size of the current block, The parameters of the current image sequence, Sequence level flags for the current image sequence, The image-level flags for the current image, and The slice level flags for the current image, The determination is based on any one or any combination of the following:
2. The method of claim 1 .
4. the coded image is a reference image of the current block; determining first temporal motion information of the current block based on motion information of the at least one non-adjacent position in the coded image, determining collocated blocks in the reference image that correspond to the non-adjacent locations; obtaining motion information of the co-located block; and scaling a motion vector in the obtained motion information to obtain first temporal motion information of the current block.
2. The method of claim 1 .
5. The non-adjacent locations are all located within a largest coding unit (LCU) or coding tree unit (CTU) in which the current block is located, or the non-adjacent locations are all located within an LCU row or a CTU row in which the current block is located.
2. The method of claim 1 .
6. The method for predicting temporal motion information further includes predicting temporal motion information based on adjacent positions, the adjacent positions include a lower right corner adjacent position of the current block, the non-adjacent positions of the current block and the lower right corner adjacent position of the current block are distributed in an array, the upper left corner of the array is the lower right corner adjacent position of the current block, and different positions in the array are distributed in different minimum storage units in the coded image; 2. The method of claim 1 .
7. When there are at least three positions for deriving the first temporal motion information in the same direction, the distance between adjacent positions among the at least three positions is the same, or the distance between adjacent positions among the at least three positions is variable, and the distance between two adjacent positions increases with distance from the current block.
3. The method of claim 2 .
8. The method for predicting temporal motion information includes: determining whether a non-adjacent position based temporal motion information prediction is permitted to be used for the current block based on a first flag; If it is determined that the non-adjacent location-based temporal motion information prediction is permitted to be utilized, the method of claim 1 is further included. The first flag is a first sequence level flag for indicating whether the non-adjacent position based temporal motion information prediction is permitted to be utilized for the current image sequence; a first picture level flag for indicating whether the non-adjacent location based temporal motion information prediction is permitted to be used for the current picture; and a first slice-level flag for indicating whether the non-adjacent position-based temporal motion information prediction is permitted to be utilized for the current slice; Any one or more of the following:
2. The method of claim 1 .
9. the first flag includes at least two of the first sequence level flag, the first picture level flag, and the first slice level flag, the first sequence level flag having a higher level than the first picture level flag, and the first picture level flag having a higher level than the first slice level flag; Determining whether or not non-adjacent position-based temporal motion information prediction is permitted to be used for the current block based on the first flag includes: sequentially analyzing the first flags according to descending level; analyzing a lower level flag if the higher level flag indicates that the use of temporal motion information prediction based on the non-adjacent positions is permitted; If all of the flags of all levels indicate that the use of the temporal motion information prediction based on the non-adjacent positions is permitted, determining that the use of the temporal motion information prediction based on the non-adjacent positions is permitted; Including, 9. The method of claim 8.
10. The method for predicting temporal motion information includes: determining whether the first flag needs to be analyzed based on a second flag; If it is determined that the first flag needs to be analyzed, analyzing the first flag; determining whether the non-adjacent position-based temporal motion information prediction is permitted to be used for the current block based on the first flag; The second flag is the following flag: a flag indicating whether or not temporal motion information is permitted to be used for the current image sequence, and if it indicates that temporal motion information is not permitted to be used for the current image sequence, it is determined that there is no need to analyze the first flag; a flag indicating whether or not the use of temporal motion information for the current image is permitted, and if the flag indicates that the use of temporal motion information for the current image is not permitted, it is determined that there is no need to analyze the first flag; and a flag indicating whether non-adjacent positions are permitted to be used for deriving motion information, and if the flag indicates that non-adjacent positions are not permitted to be used for deriving motion information, it is determined that there is no need to analyze the first flag; Any one or more of the following: If it is determined based on the second flag that the first flag needs to be analyzed, the first flag is analyzed.
9. The method of claim 8.
11. The at least one non-adjacent location comprises: The coordinates are (xCb+2*k_cbWidth-1, yCb+2*k_cbHeight-1), (xCb+2*k_cbWidth, yCb+2*k_cbHeight-1), (xCb+2*k_cbWidth-1, yCb+2*k_cbHeight), or (xCb+2*k_cbWidth, yCb+2*k_cbHeight), a second position where the coordinates are (xCb + 3 * k_cbWidth - 1, yCb + 3 * k_cbHeight - 1), (xCb + 3 * k_cbWidth, yCb + 3 * k_cbHeight - 1), (xCb + 3 * k_cbWidth - 1, yCb + 3 * k_cbHeight), or (xCb + 3 * k_cbWidth, yCb + 3 * k_cbHeight), a third position where the coordinates are (xCb + 3 * k_cbWidth - 1, yCb + k_cbHeight / 2 - 1), (xCb + 3 * k_cbWidth, yCb + k_cbHeight / 2 - 1), (xCb + 3 * k_cbWidth - 1, yCb + k_cbHeight / 2), or (xCb + 3 * k_cbWidth, yCb + k_cbHeight / 2), a fourth position where the coordinates are (xCb + k_cbWidth / 2, yCb + 3 * k_cbHeight - 1), (xCb + k_cbWidth / 2, yCb + 3 * k_cbHeight), (xCb + k_cbWidth / 2 - 1, yCb + 3 * k_cbHeight - 1), or (xCb + k_cbWidth / 2 - 1, yCb + 3 * k_cbHeight), a fifth position where the coordinates are (xCb + 2 * k_cbWidth - 1, yCb + k_cbHeight / 2 - 1), (xCb + 2 * k_cbWidth, yCb + k_cbHeight / 2 - 1), (xCb + 2 * k_cbWidth - 1, yCb + k_cbHeight / 2), or (xCb + 2 * k_cbWidth, yCb + k_cbHeight / 2), a sixth position where the coordinates are (xCb + k_cbWidth / 2, yCb + 2 * k_cbHeight - 1), (xCb + k_cbWidth / 2, yCb + 2 * k_cbHeight), (xCb + k_cbWidth / 2 - 1, yCb + 2 * k_cbHeight - 1), or (xCb + k_cbWidth / 2 - 1, yCb + 2 * k_cbHeight), a seventh position where the coordinates are (xCb + k_cbWidth, yCb + 2 * k_cbHeight), (xCb + k_cbWidth, yCb + 2 * k_cbHeight - 1), (xCb + k_cbWidth - 1, yCb + 2 * k_cbHeight), or (xCb + k_cbWidth - 1, yCb + 2 * k_cbHeight - 1), and, The coordinates are (xCb+2*k_cbWidth, yCb+k_cbHeight), (xCb+2*k_cbWidth-1, yCb+k_cbHeight), (xCb+2*k_cbWidth, yCb+k_cbHeight-1), or (xCb+2*k_cbWidth-1, 8th position which is yCb+k_cbHeight-1), Any one or more of the following: xCb is the abscissa of the top left corner of the current block, yCb is the ordinate of the top left corner of the current block, k_cbWidth is the width of the current block, or ½ the width, or ¼ the width, or twice the width, k_cbHeight is the height of the current block, or ½ the height, or ¼ the height, or twice the height, and "*" denotes a multiplication operation.
2. The method of claim 1 .
12. A method for constructing a candidate motion information list, comprising the steps of: Performing spatial motion information prediction and temporal motion information prediction on a current block to determine spatial motion information and temporal motion information of the current block; adding the spatial motion information and the temporal motion information to a candidate motion information list of the current block in a set order; The method according to any one of claims 1 to 8 is used for the temporal motion information prediction, and the temporal motion information includes the first temporal motion information.
23. A method for constructing a candidate motion information list, comprising:
13. The set order follows the following rules: if the distance of the spatial motion information is less than or equal to the distance of the temporal motion information, the spatial motion information is preferentially added to the candidate motion information list; When the distance of the spatial motion information is greater than the distance of the temporal motion information, the temporal motion information is preferentially added to the candidate motion information list; When the distances of a plurality of pieces of temporal motion information are different, the temporal motion information having a smaller distance is preferentially added to the candidate motion information list; and When the distances of a plurality of temporal motion information are the same, the order of adding the temporal motion information to the candidate motion information list is determined according to a statistical rule of the temporal motion information; is determined based on one or more of The spatial motion information distance is the distance from the position where the spatial motion information is derived to the current block, and the temporal motion information distance is the distance from the position where the temporal motion information is derived to the current block, and the distance from a position to the current block is determined based on a rectangular box in which the position is located or adjacent to the position, the current block is surrounded by the rectangular box and located at the center of the rectangular box, the width of the rectangular box is an integer multiple of the width of the current block, and the height of the rectangular box is an integer multiple of the height of the current block, and the larger the area of the rectangular box, the larger the distance from the position to the current block.
13. The method of claim 12.
14. The first temporal motion information is First temporal motion information derived based on a non-adjacent position to a lower right side of the current block; First temporal motion information derived based on a non-adjacent position to the right of the current block; and First temporal motion information derived based on a lower non-adjacent position of the current block; and When the distances of the plurality of first temporal motion information are the same, the order of adding the plurality of first temporal motion information to the candidate motion information list is determined according to a statistical law of the temporal motion information. A first temporal motion information derived based on a non-adjacent position on the lower right side of the current block is added to the candidate motion information list in preference to a first temporal motion information derived based on a non-adjacent position on the right side of the current block; a first temporal motion information derived based on a non-adjacent position to the right of the current block is added to the candidate motion information list in preference to a first temporal motion information derived based on a non-adjacent position below the current block; 14. The method of claim 13.
15. The order of the earliest first temporal motion information among the first temporal motion information is as follows: In a geometric partitioning mode (GPM), a sequence number set for the earliest first temporal motion information is equal to or less than a maximum number of candidate motion information that is allowed to be added to the candidate motion information list; In the set fast motion scenario, a sequence number set for the earliest first temporal motion information is less than or equal to a maximum number of candidate motion information allowed to be added to the candidate motion information list; is determined by at least one of 13. The method of claim 12.
16. adding the spatial motion information and the temporal motion information to a candidate motion information list of the current block in the set order; performing a similarity check before adding the spatial motion information or the temporal motion information to the candidate motion information list; adding the spatial motion information or the temporal motion information to the candidate motion information list if the similarity check determines that the spatial motion information or the temporal motion information is not similar to any of the candidate motion information already added or determined to be added to the candidate motion information list; First similarity threshold θ 1 is used when performing a similarity check on the first temporal motion information, and a second similarity threshold θ 2 is used when performing a similarity check on the spatial motion information, and θ 1 >θ 2 Or θ 1 =θ 2 That is, 13. The method of claim 12.
17. The temporal motion information further includes temporal motion information determined by temporal motion information prediction based on adjacent positions, and a third similarity threshold θ 3 is used when performing a similarity check on the time motion information determined by the time motion information prediction based on the adjacent positions, and θ 1 >θ 3 Or θ 1 =θ 3 That is, 17. The method of claim 16.
18. the first similarity threshold is determined based on one of: parameters of a current image sequence; and parameters of a current image.
17. The method of claim 16.
19. The parameters of the current image sequence include a resolution of the sequence; The parameters of the current image include any one or more of an image width, an image height, and an image sample number; The first similarity threshold is a plurality of first similarity thresholds, and the larger the first similarity threshold, the larger the value of the corresponding parameter.
20. The method of claim 18 .
20. The first similarity threshold is determined based on a reference relationship of the current image, the reference relationship including a unidirectional reference and a bidirectional reference; a first similarity threshold determined when the reference relationship is the unidirectional reference is smaller than a first similarity threshold determined when the reference relationship is the bidirectional reference; The forward reference means that only a forward reference image or a backward reference image can be used for the current image, and the bidirectional reference means that both the forward reference image and the backward reference image can be used for the current image.
17. The method of claim 16.
21. The first similarity threshold is determined based on whether template matching is used for the current prediction mode, and the first similarity threshold determined when template matching is used is greater than the first similarity threshold determined when template matching is not used.
17. The method of claim 16.
22. the first similarity threshold is determined based on one or more of the following parameters: a preset value, a parameter of a current image sequence, a parameter of a current image, a size of a current block, a sequence level flag of a current image sequence, a slice level flag of the current image, an image level flag of the current image, a flag indicating whether template matching is used for a current prediction mode, and a reference relationship of the current image; 17. The method of claim 16.
23. The first similarity threshold is determined based on any one or more parameters, the first similarity threshold is set to a maximum of first similarity thresholds established based on a plurality of manners; 23. The method of claim 22.
24. The method for constructing a candidate motion information list is used in a merge mode.
13. The method of claim 12.
25. 1. A video encoding method, comprising: Building a list of candidate motion information for a current block according to a method according to any one of claims 9 to 21; selecting one or more candidate motion information from the candidate motion information list and recording an index of the selected candidate motion information; determining a prediction block of the current block based on the selected candidate motion information, encoding the current block based on the prediction block, and encoding an index of the candidate motion information; Including, 13. A video encoding method comprising:
26. 1. A video decoding method, comprising: Building a list of candidate motion information for a current block according to a method according to any one of claims 12 to 24; Selecting one or more candidate motion information from the candidate motion information list based on an index of the candidate motion information of the current block obtained by decoding; determining a prediction block of the current block based on the selected candidate motion information, and reconstructing the current block based on the prediction block; Including, 13. A video decoding method comprising:
27. A time movement information prediction device, A processor and a memory in which a computer program is stored, When the processor executes the computer program, the processor executes the method for predicting temporal motion information according to any one of claims 1 to 11. A time movement information prediction device comprising:
28. A candidate motion information list construction device, comprising: A processor and a memory in which a computer program is stored, When the processor executes the computer program, the processor executes the method for constructing a candidate motion information list according to any one of claims 9 to 24.
23. A candidate motion information list construction device comprising:
29. 1. A video encoding device, comprising: A processor and a memory in which a computer program is stored, The processor, when executing the computer program, performs the video encoding method of claim 25. A video encoding device comprising:
30. A video decoding device, comprising: A processor and a memory in which a computer program is stored, The processor, when executing the computer program, performs the video decoding method of claim 26. A video decoding device comprising:
31. A video encoding device according to claim 29 and a video decoding device according to claim 30, A video coding system comprising:
32. A non-transitory computer-readable storage medium having a computer program stored thereon, When the computer program is executed by a processor, the method according to any one of claims 1 to 24 is performed. A non-transitory computer-readable storage medium comprising:
33. Produced by the video encoding method of claim 25. A bitstream comprising:
Citation Information
Patent Citations
Priority-based non-adjacent merge design
US20210127129A1
