Method and apparatus for motion field storage in video coding
By using larger basic units to store motion vectors, the motion field storage process is simplified, the complex motion vector comparison problem in the prior art is solved, and the coding efficiency is improved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- HFI INNOVATION INC
- Filing Date
- 2020-05-21
- Publication Date
- 2026-05-15
AI Technical Summary
Existing video coding techniques are complex in the process of storing motion fields, especially in the derivation of bidirectional predictive motion vectors, which requires a large number of comparison operations and leads to low efficiency.
Using larger basic units (such as 8×8 or 16×16 sub-blocks) to store motion vectors simplifies the motion field storage process by determining whether to store unidirectional or bidirectional predicted motion vectors by judging the position of the sub-blocks.
This reduces the number of comparisons during motion vector storage, improves coding efficiency, and reduces computational complexity.
Smart Images

Figure CN122053849A_ABST
Abstract
Description
[0001] Cross-reference to related applications This disclosure claims priority to U.S. Provisional Application No. 62 / 865,920, filed June 24, 2019, which is incorporated herein by reference in its entirety. Technical Field
[0002] This disclosure generally relates to video data processing, and more specifically, to a method and apparatus for performing motion field storage in video encoding. Background Technology
[0003] The Joint Video Experts Group (JVET) of the ITU-T Video Coding Experts Group (ITU-T VCEG) and the ISO / IEC Moving Picture Experts Group (ISO / IEC MPEG) is currently developing the Universal Video Coding Standard (VVC / H.266). The VVC standard aims to double the compression efficiency of its predecessor, the High Efficiency Video Coding Standard (HEVC / H.265). In other words, VVC aims to achieve the same subjective quality as HEVC / H.265 using half the bandwidth. Summary of the Invention
[0004] Embodiments of this disclosure provide methods and apparatus for storing motion field data. In some embodiments, an exemplary method includes: determining whether a first unidirectional predicted motion vector for a first partition of a block and a second unidirectional predicted motion vector for a second partition of the block come from the same list of reference images; and in response to the determination that the first unidirectional predicted motion vector and the second unidirectional predicted motion vector are from the same list of reference images, storing one of the first unidirectional predicted motion vector and the second unidirectional predicted motion vector in the motion field of the block for a sub-block located in a bidirectional predicted region of the block.
[0005] In some embodiments, an exemplary device includes: a memory configured to store instructions; and a processor coupled to the memory. The processor is configured to execute the instructions to cause the device to: determine whether a first unidirectional predicted motion vector for a first partition of a block and a second unidirectional predicted motion vector for a second partition of the block originate from the same list of reference images; and, in response to the determination that the first unidirectional predicted motion vector and the second unidirectional predicted motion vector are from the same list of reference images, store one of the first unidirectional predicted motion vector and the second unidirectional predicted motion vector in the motion field of the block for a sub-block located in a bidirectional predicted region of the block.
[0006] In some embodiments, an exemplary non-transitory computer-readable storage medium stores a set of instructions. The set of instructions can be executed by one or more processors of the device to cause the device to: determine whether a first unidirectional predicted motion vector for a first partition of a block and a second unidirectional predicted motion vector for a second partition of the block come from the same list of reference images; and in response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined to come from the same list of reference images, store one of the first unidirectional predicted motion vector and the second unidirectional predicted motion vector in the motion field of the block for a sub-block located in a bidirectional predicted region of the block. Attached Figure Description
[0007] Embodiments and aspects of this disclosure are illustrated in the following detailed description and accompanying drawings. Various features shown in the figures are not drawn to scale.
[0008] Figure 1 This is a schematic diagram illustrating the structure of an example video sequence according to some embodiments of the present disclosure.
[0009] Figure 2 This is a schematic diagram illustrating an exemplary encoder in a hybrid video coding system according to some embodiments of the present disclosure.
[0010] Figure 3 This is a schematic diagram illustrating an exemplary decoder in a hybrid video coding system according to some embodiments of the present disclosure.
[0011] Figure 4 A block diagram of an exemplary device for encoding or decoding video according to some embodiments of the present disclosure is illustrated.
[0012] Figure 5 This is a schematic diagram illustrating an example of inter-frame prediction based on triangular partitioning according to some embodiments of the present disclosure.
[0013] Figure 6 The illustration shows a schematic diagram of an exemplary unidirectional predictive motion vector selection for a partitioned pattern according to some embodiments of the present disclosure.
[0014] Figure 7 This is a schematic diagram illustrating exemplary weights for a mixing process according to some embodiments of the present disclosure.
[0015] Figure 8 This is a schematic diagram illustrating an example of a 4×4 sub-block located in a unidirectional prediction region and a bidirectional prediction region according to some embodiments of the present disclosure.
[0016] Figure 9 This is a schematic diagram illustrating an example of the angular distribution of a geometric partitioning pattern (GPM) according to some embodiments of the present disclosure.
[0017] Figure 10 This is a schematic diagram illustrating an example of the distance distribution of GPM according to some embodiments of the present disclosure.
[0018] Figure 11 This is a schematic diagram illustrating an example of an 8×8 sub-block located in a unidirectional prediction region and a bidirectional prediction region according to some embodiments of the present disclosure.
[0019] Figure 12 A flowchart illustrating an exemplary method for sports field storage according to some embodiments of the present disclosure is shown.
[0020] Figure 13 This is a schematic diagram illustrating an example of a triangular partition according to some embodiments of the present disclosure.
[0021] Figure 14 A flowchart illustrating an exemplary method for generating motion vectors according to some embodiments of the present disclosure is shown.
[0022] Figure 15 A flowchart illustrating another exemplary method for motion vector generation according to some embodiments of the present disclosure is shown.
[0023] Figure 16 A flowchart illustrating another exemplary method for sports field storage according to some embodiments of the present disclosure is shown.
[0024] Figure 17 This is a schematic diagram illustrating an example of geometric partitioning according to some embodiments of the present disclosure.
[0025] Figure 18 This is a schematic diagram illustrating an example of the location of a sub-block according to some embodiments of the present disclosure. Detailed Implementation
[0026] Reference will now be made in detail to exemplary embodiments, examples of which are illustrated in the accompanying drawings. The following description refers to the accompanying drawings, wherein, unless otherwise indicated, the same numerals in different drawings denote the same or similar elements. The implementations set forth in the following description of the exemplary embodiments do not represent all implementations consistent with the present invention. Instead, they are merely examples of devices and methods consistent with aspects of the invention as set forth in the appended claims. Specific aspects of this disclosure are described below in more detail. In the event of any conflict with terms and / or definitions incorporated by reference, the terms and definitions provided herein shall prevail.
[0027] To achieve the same subjective quality as HEVC / H.265 using half the bandwidth, JVET has been using the Joint Exploratory Model (JEM) reference software to develop technologies that surpass HEVC. Because the coding techniques are incorporated into JEM, JEM achieves generally higher coding performance than HEVC. VCEG and MPEG have also officially begun development of next-generation video compression standards that surpass HEVC.
[0028] The VVC standard continues to include more coding techniques that provide better compression performance. VVC is based on the same hybrid video coding system used in modern video compression standards such as HEVC, H.264 / AVC, MPEG2, H.263, etc.
[0029] Video is a collection of still images (or "frames") arranged in chronological order to store visual information. Video capture devices (e.g., cameras) can be used to capture and store those images in chronological order, and video playback devices (e.g., televisions, computers, smartphones, tablets, video players, or any end-user terminal with a display function) can be used to display such images in chronological order. Additionally, in some applications, video capture devices can transmit the captured video in real time to video playback devices (e.g., computers with monitors), such as for surveillance, conferencing, or live broadcasting.
[0030] To reduce the storage space and transmission bandwidth required for such applications, video can be compressed before storage and transmission and decompressed before display. Compression and decompression can be implemented by software executed by a processor (e.g., a processor in a general-purpose computer) or by dedicated hardware. The module used for compression is typically called an "encoder," while the module used for decompression is typically called a "decoder." Encoders and decoders can be collectively referred to as a "codec." Encoders and decoders can be implemented as any of a variety of suitable hardware, software, or combinations thereof. For example, hardware implementations of encoders and decoders can include circuit systems such as one or more microprocessors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), discrete logic, or any combination thereof. Software implementations of encoders and decoders can include program code, computer-executable instructions, firmware, or any suitable computer-implemented algorithm or process embedded in a computer-readable medium. Video compression and decompression can be implemented using various algorithms or standards such as MPEG-1, MPEG-2, MPEG-4, H.26x series, etc. In some applications, a codec can decompress video according to a first coding standard and recompress the decompressed video using a second coding standard. In this case, the codec can be called a "transcoder".
[0031] Video coding processes identify and retain useful information that can be used to reconstruct the image while ignoring information that is not important for reconstruction. If the ignored, unimportant information cannot be fully reconstructed, such a coding process is called "lossy." Otherwise, it can be called "lossless." Most coding processes are lossy, a trade-off to reduce required storage space and transmission bandwidth.
[0032] Useful information about an encoded image (referred to as the "current image") includes changes relative to a reference image (e.g., a previously encoded or reconstructed image). These changes can include variations in pixel position, brightness, or color, with positional changes being the most significant. The positional changes of a set of pixels representing an object can reflect the object's movement between the reference and current images.
[0033] An image encoded without referencing another image (i.e., it is its own reference image) is called an "I-image". An image encoded using a previous image as a reference image is called a "P-image". An image encoded using both a previous image and a future image as reference images (i.e., the reference is "bidirectional") is called a "B-image".
[0034] Figure 1 The diagram illustrates the structure of an example video sequence 100 according to some embodiments of the present disclosure. The video sequence 100 may be live video or video that has been captured and archived. The video 100 may be real-life video, computer-generated video (e.g., computer game video), or a combination thereof (e.g., real-life video with augmented reality effects). The video sequence 100 can be input from a video capture device (e.g., a camera), a video archive containing previously captured video (e.g., a video file stored in a storage device), or a video providing interface (e.g., a video broadcast transceiver) for receiving video from a video content provider.
[0035] like Figure 1 As shown, video sequence 100 can include a series of images arranged temporally along a timeline, including images 102, 104, 106, and 108. Images 102-106 are consecutive, and there are more images between images 106 and 108. Figure 1In this diagram, image 102 is an I-image, and its reference image is image 102 itself. Image 104 is a P-image, and its reference image is image 102, as indicated by the arrow. Image 106 is a B-image, and its reference images are images 104 and 108, as indicated by the arrow. In some embodiments, the reference image of an image (e.g., image 104) may not immediately precede or follow that image. For example, the reference image of image 104 may be an image preceding image 102. It should be noted that the reference images of images 102-106 are merely examples, and this disclosure does not limit the embodiments of the reference images to... Figure 1 The example shown.
[0036] Typically, due to the computational complexity of such tasks, video codecs do not encode or decode the entire image at once. Instead, they are able to segment the image into basic segments and encode or decode the image segment by segment. Such basic segments are referred to herein as basic processing units (“BPUs”). For example, Figure 1 Structure 110 illustrates an example structure of an image (e.g., any one of images 102-108) from video sequence 100. In structure 110, the image is divided into 4×4 basic processing units, the boundaries of which are shown as dashed lines. In some embodiments, the basic processing unit can be referred to as a “macroblock” in some video coding standards (e.g., MPEG series, H.261, H.263, or H.264 / AVC), or as a “coding tree unit” (“CTU”) in some other video coding standards (e.g., H.265 / HEVC or H.266 / VVC). The basic processing units in the image can have variable sizes, such as 128×128, 64×64, 32×32, 16×16, 4×8, 16×32, or any pixel shape and size. The size and shape of the basic processing units for the image can be selected based on a balance between coding efficiency and the level of detail to be preserved within the basic processing units.
[0037] A basic processing unit can be a logical unit that can include a set of different types of video data stored in computer memory (e.g., in a video frame buffer). For example, a basic processing unit for a color image can include a luminance component (Y) representing colorless luminance information, one or more chrominance components (e.g., Cb and Cr) representing color information, and related syntax elements, wherein the luminance and chrominance components can have the same size as the basic processing unit. In some video coding standards (e.g., H.265 / HEVC or H.266 / VVC), the luminance and chrominance components can be referred to as "code tree blocks" ("CTBs"). Any operation performed on a basic processing unit can be repeatedly performed on each of its luminance and chrominance components.
[0038] Video encoding involves multiple operational stages, examples of which are shown in Figure 2 and Figure 3 In each stage, the size of the basic processing unit may still be too large for the processing and can therefore be further divided into segments referred to herein as "basic processing subunits". In some embodiments, the basic processing subunit can be referred to as a "block" in some video coding standards (e.g., MPEG series, H.261, H.263, or H.264 / AVC) or as a "coding unit" ("CU") in some other video coding standards (e.g., H.265 / HEVC or H.266 / VVC). The basic processing subunit can have the same or smaller size as the basic processing unit. Similar to the basic processing unit, the basic processing subunit is also a logical unit that can include a set of different types of video data (e.g., Y, Cb, Cr, and associated syntax elements) stored in computer memory (e.g., in a video frame buffer). Any operation performed on the basic processing subunit can be repeatedly performed on each of its luminance and chrominance components. It should be noted that this division to a further level can be performed depending on the processing needs. It should also be noted that different schemes can be used to divide the basic processing units at different stages.
[0039] For example, in the pattern decision-making phase (an example of which is shown in...) Figure 2 In this context, the encoder can decide which prediction mode (e.g., intra-image prediction or inter-image prediction) to use for basic processing units that may be too large to make such a decision. The encoder can divide the basic processing unit into multiple basic processing subunits (e.g., CUs as in H.265 / HEVC or H.266 / VVC) and decide the prediction type for each individual basic processing subunit.
[0040] For example, in the prediction phase (examples are shown in...) Figure 2 In H.265 / HEVC or H.266 / VVC, the encoder can perform prediction operations at the level of the basic processing subunit (e.g., CU). However, in some cases, the basic processing subunit may still be too large to handle. The encoder can further divide the basic processing subunit into smaller segments (e.g., referred to as "prediction blocks" or "PBs" in H.265 / HEVC or H.266 / VVC), at which prediction operations can be performed.
[0041] For example, in the transformation phase (examples of which are shown in...) Figure 2In H.265 / HEVC or H.266 / VVC, the encoder can perform transform operations on residual basic processing subunits (e.g., CUs). However, in some cases, the basic processing subunits may still be too large to process. The encoder can further divide the basic processing subunits into smaller segments (e.g., referred to as "transform blocks" or "TBs" in H.265 / HEVC or H.266 / VVC), at which transform operations can be performed. It should be noted that the partitioning scheme of the same basic processing subunit can be different in the prediction and transform stages. For example, in H.265 / HEVC or H.266 / VVC, the prediction blocks and transform blocks of the same CU can have different sizes and numbers.
[0042] exist Figure 1 In structure 110, the basic processing unit 112 is further divided into 3×3 basic processing sub-units, the boundaries of which are shown as dashed lines. In different schemes, different basic processing units of the same image can be divided into basic processing sub-units.
[0043] In some implementations, to provide parallel processing and error recovery capabilities for video encoding and decoding, images can be divided into regions for processing, so that for a given region of the image, the encoding or decoding process may not depend on information from any other region of the image. In other words, each region of the image can be processed independently. By doing so, the codec can process different regions of the image in parallel, thereby improving encoding efficiency. Furthermore, when data in a region is corrupted during processing or lost during network transmission, the codec can correctly encode or decode other regions of the same image without relying on the corrupted or lost data, thus providing error recovery capabilities. In some video coding standards, images can be divided into different types of regions. For example, H.265 / HEVC and H.266 / WC provide two types of regions: "slices" and "tiles." It should also be noted that different images in a video sequence 100 can have different partitioning schemes for dividing the image into regions.
[0044] For example, in Figure 1 In the diagram, structure 110 is divided into three regions 114, 116, and 118, whose boundaries are shown as solid lines within structure 110. Region 114 comprises four basic processing units. Each of regions 116 and 118 comprises six basic processing units. It should be noted that... Figure 1 The basic processing unit, basic processing subunit, and region of structure 110 are merely examples, and this disclosure does not limit its embodiments.
[0045] Figure 2The illustration shows a schematic diagram of an exemplary encoder 200 in a hybrid video coding system according to some embodiments of the present disclosure. The video encoder 200 can perform intra-frame or inter-frame coding on blocks or partitions or sub-partitions of video blocks within a video frame (including video blocks). Intra-frame coding can rely on spatial prediction to reduce or remove spatial redundancy in the video within a given video frame. Inter-frame coding can rely on temporal prediction to reduce or remove temporal redundancy in the video within adjacent frames of a video sequence. Intra-frame modes can refer to a number of spatially based compression modes. Inter-frame modes (such as one-way prediction or two-way prediction) can refer to a number of temporally based compression modes.
[0046] refer to Figure 2 The input video signal 202 can be processed block by block. For example, a video block unit can be a 16×16 pixel block (e.g., a macroblock (MB)). The size of the video block unit can vary depending on the coding technique used and the required accuracy and efficiency. In HEVC, the expanded block size (e.g., a coding tree unit (CTU)) can be used to compress video signals at resolutions such as 1080p and higher. In HEVC, a CTU can include up to 64×64 luma samples, corresponding chroma samples, and associated syntax elements. In VVC, the size of the CTU can be further increased to include 128×128 luma samples, corresponding chroma samples, and associated syntax elements. The CTU can be further divided into coding units (CUs) using, for example, quadtrees, binary trees, or ternary trees. CUs can be further partitioned into prediction units (PUs), to which individual prediction methods can be applied. Each input video block can be processed using a spatial prediction unit 260 or a temporal prediction unit 262.
[0047] Spatial prediction unit 260 performs spatial prediction (e.g., intra-frame prediction) on the current block / CU using information about the same image / slice containing the current block. Spatial prediction can use pixels from neighboring blocks already encoded in the same video image frame / slice to predict the current video block. Spatial prediction can reduce the spatial redundancy inherent in the video signal.
[0048] The timing prediction unit 262 performs timing prediction (e.g., inter-frame prediction) on the current block using information from an image / slice different from the one containing the current block. Timing prediction for a video block can be signaled using one or more motion vectors. In unidirectional timing prediction, a prediction signal for the current block is generated using a single motion vector indicating only one reference image. Conversely, in bidirectional timing prediction, a prediction signal for the current block can be generated using two motion vectors (each indicating a corresponding reference image). The motion vectors can indicate the amount and direction of motion between the current block and one or more related blocks in the reference frame. If multiple reference images are supported, one or more reference image indices can be sent for the video block. The one or more reference indices can be used to identify which reference image(s) in the reference image register or decoded image buffer (DPB) 264 the timing prediction signal might originate from.
[0049] The mode decision and encoder control unit 280 in the encoder can select a prediction mode, for example, based on rate distortion optimization. Based on the determined prediction mode, a prediction block can be obtained. The prediction block can be subtracted from the current video block at adder 216. The prediction residual can be transformed by transform unit 204 and quantized by quantization unit 206. The quantization residual coefficients can be inversely quantized at inverse quantization unit 210 and inversely transformed at inverse transform unit 212 to form a reconstruction residual. The reconstruction residual can be added to the prediction block at adder 226 to form a reconstructed video block. The reconstructed video block before loop filtering can be used to provide reference samples for intra-frame prediction.
[0050] The reconstructed video block can undergo loop filtering at loop filter 266. For example, loop filtering techniques such as deblocking filters, sample adaptive offset (SAO), and adaptive loop filters (ALF) can be applied. The reconstructed block after loop filtering can be stored in reference image register 264 and can be used to provide inter-frame prediction reference samples for encoding other video blocks. To form the output video bitstream 220, before the data is compressed and packaged to form the bitstream 220, coding modes (e.g., inter-frame or intra-frame), prediction mode information, motion information, and quantization residual coefficients can be sent to entropy coding unit 208 to further reduce the bit rate.
[0051] Figure 3 A schematic diagram of an example decoder 300 in a hybrid video coding system according to some embodiments of the present disclosure is illustrated. Reference Figure 3The video bitstream 302 can be unpacked or entropy-decoded at the entropy decoding unit 308. Encoding mode information can be used to determine whether spatial prediction unit 360 or temporal prediction unit 362 will be selected. Prediction mode information can be sent to the corresponding prediction unit to generate prediction blocks. For example, motion-compensated prediction can be applied by the temporal prediction unit 362 to form a temporal prediction block.
[0052] The residual coefficients can be sent to the inverse quantization unit 310 and the inverse transform unit 312 to obtain the reconstructed residuals. The predicted block and the reconstructed residuals can be added together at 326 to form a reconstructed block before loop filtering. The reconstructed block can then be loop filtered at the loop filter 366. For example, loop filters such as deblocking filters, SAO, and ALF can be applied. The reconstructed block after loop filtering can then be stored in the reference image register 364. The reconstructed data in the reference image register 364 can be used to obtain the decoded video 320 or to predict future video blocks. The decoded video 320 can be displayed on a display device such as a TV, PC, smartphone, or tablet for viewing by an end user.
[0053] Figure 4 This is a block diagram of an exemplary device 400 for encoding or decoding video according to some embodiments of this disclosure. Figure 4 As shown, device 400 can include processor 402. When processor 402 executes the instructions described herein, device 400 can become a dedicated machine for video encoding or decoding. Processor 402 can be any type of circuit system capable of manipulating or processing information. For example, processor 402 can include any combination of the following: any number of central processing units (or “CPU”), graphics processing units (or “GPU”), neural processing units (“NPU”), microcontroller units (“MCU”), optical processors, programmable logic controllers, microcontrollers, microprocessors, digital signal processors, intellectual property (IP) cores, programmable logic arrays (PLAs), programmable array logic (PALs), general-purpose array logic (GALs), complex programmable logic devices (CPLDs), field-programmable gate arrays (FPGAs), system-on-a-chip (SoCs), application-specific integrated circuits (ASICs), etc. In some embodiments, processor 402 can also be a collection of processors grouped into individual logic components. For example, such as Figure 4 As shown, processor 402 can include multiple processors, including processor 402a, processor 402b and processor 402n.
[0054] Device 400 may also include memory 404 configured to store data (e.g., a set of instructions, computer code, intermediate data, etc.). For example, as Figure 4As shown, the stored data can include program instructions (e.g., for implementing...). Figure 2 or Figure 3 The processor 402 can access the program instructions and the data for processing (e.g., via bus 410) and execute the program instructions to perform operations or manipulations on the data for processing. The memory 404 can include high-speed random access memory or non-volatile memory. In some embodiments, the memory 404 can include any combination of the following: any number of random access memories (RAM), read-only memories (ROM), optical discs, magnetic disks, hard disks, solid-state drives, flash drives, secure digital cards (SD cards), memory sticks, compact flash (CF) cards, etc. The memory 404 can also be a group of memories grouped into single logical components. Figure 4 (Not shown in the image).
[0055] Bus 410 may be a communication device for transferring data between components within device 400, such as an internal bus (e.g., CPU-memory bus), an external bus (e.g., a Universal Serial Bus port, a Peripheral Component Interconnect Fast Port), etc.
[0056] For ease of explanation and to avoid ambiguity, the processor 402 and other data processing circuitry are collectively referred to as "data processing circuitry" in this disclosure. The data processing circuitry can be implemented entirely as hardware or as a combination of software, hardware, or firmware. Furthermore, the data processing circuitry can be a single, independent module or can be wholly or partially integrated into any other component of the device 400.
[0057] Device 400 may also include a network interface 406 to provide wired or wireless communication with a network (e.g., the Internet, intranet, local area network, mobile communication network, etc.). In some embodiments, network interface 406 may include any combination of the following: any number of network interface controllers (NICs), radio frequency (RF) modules, transceivers, transceivers, modems, routers, gateways, wired network adapters, wireless network adapters, Bluetooth adapters, infrared adapters, near field communication (“NFC”) adapters, cellular network chips, etc.
[0058] In some embodiments, the device 400 may optionally include a peripheral interface 408 to provide connectivity to one or more peripheral devices. Figure 4 As shown, peripheral devices may include, but are not limited to, cursor control devices (e.g., mouse, touchpad, or touchscreen), keyboards, displays (e.g., cathode ray tube displays, liquid crystal displays, or light-emitting diode displays), video input devices (e.g., cameras or input interfaces coupled to video files), etc.
[0059] It should be noted that the video codec can be implemented as any combination of any software or hardware module in device 400. For example, it can be implemented as... Figure 2 encoder 200 or Figure 3 Some or all levels of the decoder 300 are implemented as one or more software modules of the device 400, such as program instructions that can be loaded into memory 404. For example, it can... Figure 2 encoder 200 or Figure 3 Some or all levels of the decoder 300 are implemented as one or more hardware modules of the device 400, such as dedicated data processing circuitry (e.g., FPGA, ASIC, NPU, etc.).
[0060] In VTM5, triangular partitioning mode is supported for inter-frame prediction. Triangular partitioning mode is typically applied to CUs coded for 8×8 or larger and coded in triangle skip or merge mode. Triangle skip / merge mode is signaled in parallel with regular merge mode, merge with motion vector difference (MMVD) mode, combined inter-frame and intra-frame prediction (CUP) mode, or sub-block merge mode.
[0061] When using the triangular partitioning mode, use diagonal splitting or anti-diagonal splitting to evenly divide the CU into two triangular partitions. Figure 5 Examples of triangular partition-based inter-frame prediction according to some embodiments of this disclosure are illustrated. Each triangular partition in a CU uses its own motion for inter-frame prediction. Each partition allows unidirectional prediction. Therefore, each partition has a motion vector and a reference index. Unidirectional prediction motion constraints are applied to ensure that, as with conventional bidirectional prediction, each CU requires two motion-compensated predictions. The unidirectional prediction motion for each partition is derived directly from a list of merge candidates constructed for extended merge prediction, and the selection of a unidirectional prediction motion from a given merge candidate in the list can be based on the following process.
[0062] If the triangular partitioning pattern is used for the current CU, a flag indicating the direction of the triangular partition (diagonal or anti-diagonal) and two merge indices (one for each partition) are further signaled. After predicting each triangular partition within the triangular partitions, a blending process with adaptive weights is used to adjust the sample values along the diagonal or anti-diagonal edges. This is the prediction signal for the entire CU and can be transformed and quantized across the entire CU as in other prediction patterns. The motion field of the CU predicted using the triangular partitioning pattern is then stored in 4×4 sub-blocks.
[0063] Given a merge candidate index, the unidirectional predicted motion vector is derived from the merge candidate list constructed for extended merge prediction. Figure 6An exemplary one-way predictive motion vector selection 600 for a partitioning pattern is illustrated according to some embodiments of the present disclosure. In some embodiments, the one-way predictive motion vector selection 600 can be applied to a triangular partitioning pattern. For candidates in the list, their LX motion vectors (where X equals the parity of the merged candidate index values) are used as the one-way predictive motion vectors for the triangular partitioning pattern. These motion vectors in Figure 6 The symbol is marked with "×". In the absence of the corresponding LX motion vector, the L(1-X) motion vector of the same candidate in the expanded merge prediction candidate list is used as the unidirectional prediction motion vector for the triangular partitioning mode.
[0064] After using its own motion to predict each triangular partition, a blend is applied to the two predicted signals to derive samples around the diagonal or anti-diagonal edges. The following weights are used in the blending process: {7 / 8, 6 / 8, 5 / 8, 4 / 8, 3 / 8, 2 / 8, 1 / 8} are used for luminance and {6 / 8, 4 / 8, 2 / 8} are used for chrominance.
[0065] Figure 7 The illustration shows the exemplary weights above for the mixing process 700 according to some embodiments of the present disclosure.
[0066] In the triangular partitioning pattern, the motion vectors of the CU (Cubic Conversion Unit) are stored in 4×4 sub-blocks. Depending on the position of each 4×4 sub-block, either unidirectional or bidirectional predicted motion vectors are stored. For example, as... Figure 5 As shown, Mv1 and Mv2 are represented as unidirectional prediction motion vectors for partition 1 and partition 2, respectively. If a 4×4 sub-block is located in a unidirectional prediction region, then Mv1 or Mv2 is stored for that 4×4 sub-block. Otherwise, if the 4×4 sub-block is located in a bidirectional prediction region, then a bidirectional prediction motion vector is stored. The bidirectional prediction motion vector is derived from Mv1 and Mv2 according to the following process: 1. If Mv1 and Mv2 come from different lists of reference images (e.g., one from L0 and the other from L1), then Mv1 and Mv2 are simply combined to form a bidirectional predicted motion vector; 2. Otherwise, if Mv1 and Mv2 come from the same list, and without loss of generality, then it is assumed that they both come from L0. In this case, 2.1. If a reference image for Mv2 (or Mv1) appears in L1, then the Mv2 (or Mv1) is converted into an L1 motion vector using that reference image in L1. The two motion vectors are then combined to form a bidirectional predicted motion vector; 2.2. Otherwise, instead of bidirectional predicted motion, store unidirectional predicted motion Mv1.
[0067] It should be appreciated that when all samples within a 4×4 sub-block are weighted, the 4×4 sub-block is considered to be in the bi-predictive region. Otherwise, the 4×4 sub-block is considered to be in the uni-predictive region. Figure 8 Examples of 4×4 sub-blocks located in the uni-predictive region or the bi-predictive region (highlighted in grey) according to some embodiments of the present disclosure are illustrated. The following process can be used to determine whether a 4×4 sub-block is located in the bi-predictive region: - If , then the 4×4 sub-block is located in the bi-predictive region; - Otherwise, the 4×4 sub-block is located in the uni-predictive region, where (x, y) represents the position of the top-left sample of the 4×4 sub-block, r x represents the ratio of the block width to the block height and r y represents the ratio of the block height to the block width. Specifically, if the block width and block height are represented as W and H respectively, then: If W >= H, then r x = W / H and r y = 1; if W < H, then r x = 1 and r y = H / W. In one example, for an 8×8 block, r x is set to 1 and r y is set to 1. In another example, for a 32×8 block, r x is set to 4 and r y is set to 1.
[0068] In the VVC draft 9, the triangular partitioning mode can be extended to the geometric partitioning mode (GPM). In the GPM, the number of partitioning methods can be extended from 2 to 64. For example, 20 angles can be supported in the GPM, and for each angle, 4 different distances to the center of the block can be supported. [[ID=?]] Figure 9 FIG. 900 is a schematic diagram illustrating an example of the angle distribution of the GPM according to some embodiments of the present disclosure. Figure 10 FIG. is a schematic diagram illustrating an example of the distance distribution of the GPM according to some embodiments of the present disclosure. Since the distances of distance index = 2 with horizontal angles {0, 12} and vertical angles {6, 18} overlap with the ternary tree segmentation boundary, they can be removed in the GPM.
[0069] There are problems with the current design of the motion field storage process. In the current design, a uni-predictive motion vector is stored for a 4×4 sub-block located in the uni-predictive region, and a bi-predictive motion vector derived from two uni-predictive motion vectors is stored for a 4×4 sub-block located in the bi-predictive region. This design is complex.
[0070] Note: There seems to be a missing figure number in the translation of ID=38. You may want to check and correct it if necessary.For example, for each 4×4 sub-block, two comparisons may be required when storing the motion vector. One comparison is to determine if the sub-block is located in a bidirectional prediction region. The other comparison is to determine if the sub-block is located in a top-right (diagonal segmentation) or top-left (anti-diagonal segmentation) unidirectional prediction region. In the worst case, a total of 2016 comparisons are required for a 128×128 block predicted using the triangular partitioning pattern.
[0071] When it's necessary to derive bidirectional predicted motion (for a sub-block considered within a "bidirectional prediction region"), if two unidirectional predicted motion vectors both originate from the same list of reference images, one of them is transformed to the other list. During this process, the reference image of the unidirectional predicted motion vector is examined to determine if it appears in the other list. That means, in the worst case, the reference image of the unidirectional predicted motion vector needs to be compared with all reference images in the list. This process can be more complex.
[0072] There is a need to address existing problems in the current design. In some embodiments of this disclosure, the number of comparisons when storing motion vectors for blocks can be reduced. The motion field storage process can be simplified.
[0073] In some embodiments of this disclosure, sub-blocks with a width or height greater than 4 are used as basic units for sports field storage. For example, 8×8 or larger sub-blocks are used as basic units for sports field storage in a triangular partitioning pattern.
[0074] In an exemplary embodiment, an 8×8 sub-block is used as the basic unit for motion vector storage. A block predicted using a triangular partitioning pattern can be divided into 8×8 sub-blocks. Depending on the location of each 8×8 sub-block, either a unidirectional or bidirectional predicted motion vector is stored. If an 8×8 sub-block is located in a bidirectional prediction region, a bidirectional predicted motion vector is stored. Otherwise, a unidirectional predicted motion vector is stored for unidirectional prediction regions. It should be understood that an 8×8 sub-block located in a bidirectional prediction region can contain both weighted and unweighted samples. Figure 11 This is a schematic diagram illustrating an example of an 8×8 sub-block located in a unidirectional or bidirectional prediction region according to some embodiments of the present disclosure. For example, in triangular partitioning mode, the following process is used to determine whether the 8×8 sub-block is considered to be in a bidirectional prediction region: -if Then the 8×8 sub-block is located in the bidirectional prediction region; Otherwise, the 8×8 sub-block is located in the one-way prediction region. Where (x, y) represents the position of the top-left sample of the 8×8 sub-block and (r x , r y () represents the ratio of block width to block height.
[0075] In one embodiment, a block with a width and height greater than or equal to 8 is divided into 8×8 sub-blocks. In another embodiment, a block with a width less than 8 is divided into 4×8 sub-blocks. In yet another embodiment, a block with a height less than 8 is divided into 8×4 sub-blocks.
[0076] In the embodiment using 8×8 sub-blocks as the basic unit, a total of 496 comparisons are required for a 128×128 block predicted using the triangular partitioning pattern. As a result, this represents a 75% reduction in comparisons compared to the current VVC draft 5 design.
[0077] In another exemplary embodiment, 16×16 sub-blocks are used as the basic units for motion vector storage. Blocks predicted using a triangular partitioning pattern can be divided into 16×16 sub-blocks. For example, blocks with both width and height greater than or equal to 16 are divided into 16×16 sub-blocks. In another example, a block is divided into sub-blocks with a width equal to min(block width, 16) and a height equal to min(block height, 16).
[0078] In an exemplary embodiment, an M×N sub-block is used as the basic unit for motion vector storage, where M can be equal to N or may not be equal to N. A block predicted using a triangular partitioning pattern can be divided into M×N sub-blocks. Depending on the location of each M×N sub-block, either a unidirectional or bidirectional predicted motion vector is stored. If an M×N sub-block is located within a bidirectional prediction region, a bidirectional predicted motion vector is stored. Otherwise, a unidirectional predicted motion vector is stored for unidirectional prediction regions. It should be understood that an M×N sub-block located within a bidirectional prediction region can contain both weighted and unweighted samples. The following procedure is used to determine whether an M×N sub-block is considered to be within a bidirectional prediction region: -if Then the M×N sub-block is located in the bidirectional prediction region; Otherwise, the M×N sub-block is located in the unidirectional prediction region. Where (x, y) represents the position of the top-left sample of the M×N sub-block and (r x , r y This represents the ratio of block width to block height. (r) x , r y The derivation is as follows: if if In another exemplary embodiment, the size of the sub-block used for motion vector storage depends on the block size. When the block width or height is less than or equal to M, the size of the sub-block is (M / 2) × (M / 2). Otherwise, the size of the sub-block is M × M. In some embodiments, M can be equal to 8, 16, 32, etc. For example, when the block width or height is less than or equal to 8, the size of the sub-block is 4 × 4. Otherwise, the size of the sub-block is 8 × 8. This allows for the storage of motion fields in smaller blocks with finer granularity.
[0079] In yet another exemplary embodiment, the size of the sub-blocks used for motion vector storage is the same as the block size. In this case, the same motion vector is stored in both the bidirectional prediction region and the unidirectional prediction region. The same motion vector can be one of the two unidirectional prediction motion vectors used for partitioning or a bidirectional prediction motion vector derived from the two unidirectional prediction motion vectors.
[0080] Figure 12 A flowchart illustrating an exemplary method 1200 for sports field storage according to some embodiments of the present disclosure is shown. In some embodiments, method 1200 can be generated by an encoder (e.g., Figure 2 The encoder 200) performs the operation or is performed by a device (e.g., Figure 4 The device (400) executes the commands through one or more software or hardware components. For example, a processor (e.g., Figure 4 The processor 402) is capable of executing method 1200. In some embodiments, method 1200 can be implemented by a computer program product embodied in a computer-readable medium, said computer-readable medium comprising a computer (e.g., a processor 402) capable of executing method 1200. Figure 4 The device 400 executes computer-executable instructions, such as program code.
[0081] In step 1202, method 1200 can include determining whether a sub-block of a block (or CU) is within a bidirectional prediction region. The sub-block can have a width, height, or both greater than 4. In some embodiments, at least one of the width and height of the sub-block is equal to or greater than 8. For example, the sub-block can be an 8×8 sub-block, a 4×8 sub-block, an 8×4 sub-block, a 16×16 sub-block, or a min(block width, 16) × min(block height, 16) sub-block. In some embodiments, the size of the sub-block may depend on the size of the block. Method 1200 can be applied to a triangular partitioning pattern or GPM.
[0082] In some embodiments, in the triangular partitioning pattern, the sub-blocks are M×N sub-blocks. Method 1200 can include determining... Is it equal to Where (x, y) represents the position of the top-left sample of the sub-block and (r x , r yThis represents the ratio of the block's width to its height. If... Determined to be equal to Then the sub-block is in the bidirectional prediction region. If Determined not equal to If so, the sub-block is in the unidirectional prediction region.
[0083] In step 1204, method 1200 may include storing a bidirectional predicted motion vector in response to a sub-block being determined to be in a bidirectional prediction region. Method 1200 may also include storing a unidirectional predicted motion vector in response to a sub-block being determined to be outside a bidirectional prediction region.
[0084] In some embodiments, method 1200 may include dividing the block into multiple sub-blocks. In some embodiments, the size of the sub-blocks may be the same as the size of the block. Then, the bidirectional predicted motion vector may be the same as the unidirectional predicted motion vector.
[0085] In current designs for motion field storage procedures, when two unidirectional predicted motion vectors for two partitions both come from the same list of reference images, numerous comparisons are required to transform one of the two unidirectional predicted motion vectors to the other list of reference images. In some embodiments of this disclosure, the transformation process can be eliminated. The generation of bidirectional predicted motion vectors for sub-blocks within a bidirectional prediction region can be simplified. The derivation of motion vectors for sub-blocks located within a bidirectional prediction region can then be simplified.
[0086] In some embodiments, when two unidirectional predicted motion vectors come from different lists of reference images, the two unidirectional predicted motion vectors are combined to form a bidirectional predicted motion vector. Otherwise, one of the two unidirectional predicted motion vectors is stored for a sub-block located in the bidirectional predicted region.
[0087] Figure 13 This is a schematic diagram illustrating an example of triangular partitioning according to some embodiments of the present disclosure. In one example, one of the two unidirectional predicted motion vectors is a motion vector from the top partition, such as... Figure 13 As shown. In another example, one of the two unidirectional predicted motion vectors is a motion vector from the bottom partition, as shown. Figure 13 As shown. In another example, one of the two unidirectional predicted motion vectors is the motion vector from the left partition, as shown. Figure 13 As shown. In another example, one of the two unidirectional predicted motion vectors is a motion vector from the right partition, as shown. Figure 13 As shown.
[0088] In another example, one of the two unidirectional predicted motion vectors is the motion vector of the current image whose reference image is closer to the current block. For example, POC1 and POC2 are represented as the image order counts (POCs) of the reference images for the top and bottom partitions, respectively. The POC of the current image is represented as POC0. If the difference between POC0 and POC1 is less than the difference between POC0 and POC2, the motion vector from the top partition is stored. Otherwise, when the difference between POC0 and POC1 is greater than or equal to the difference between POC0 and POC2, the motion vector from the bottom partition is stored.
[0089] In another example, one of the two unidirectional predicted motion vectors is a motion vector from a reference image with higher quality (i.e., lower QP). For example, the QPs of the reference images for the top and bottom partitions are denoted as QP1 and QP2, respectively. If QP1 is less than or equal to QP2, the motion vector from the top partition is stored. Otherwise, the motion vector from the bottom partition is stored.
[0090] In another example, one of the two unidirectional predicted motion vectors is a motion vector with a smaller amount of motion (e.g., abs(mvx0) + abs(mvy0) <= abs(mvxl) + abs(mvyl)). The motion vector with the smaller amount of motion is stored.
[0091] Figure 14 A flowchart illustrating an exemplary method 1400 for motion vector generation according to some embodiments of the present disclosure is shown. In some embodiments, method 1400 can be generated by an encoder (e.g., Figure 2 The encoder 200) performs the operation or is performed by a device (e.g., Figure 4 The device (400) executes the commands through one or more software or hardware components. For example, a processor (e.g., Figure 4 The processor 402 is capable of executing method 1400. In some embodiments, method 1400 can be implemented by a computer program product embodied in a computer-readable medium, said computer-readable medium comprising a computer (e.g., a processor 402) capable of executing method 1400. Figure 4 The device 400 executes computer-executable instructions, such as program code.
[0092] In step 1402, method 1400 can include determining whether a first unidirectional predicted motion vector for a first partition of a block (or CU) and a second unidirectional predicted motion vector for a second partition of the block come from the same list of reference images. The first and second partitions of the block can be triangular partitions or geometric partitions.
[0093] In step 1404, method 1400 may include storing one of the first and second unidirectional predicted motion vectors for a sub-block located in the bidirectional prediction region of the block, in response to the determination that the first and second unidirectional predicted motion vectors are from the same list of reference images. In some embodiments, one of the stored first and second unidirectional predicted motion vectors may be a motion vector from the top partition, a motion vector from the bottom partition, a motion vector from the left partition, a motion vector from the right partition, a motion vector of the current image whose reference image is closer to the current block, a motion vector of the reference image with higher quality, a motion vector with less motion, etc.
[0094] In some embodiments, method 1400 may include, in response to a first unidirectional predicted motion vector and a second unidirectional predicted motion vector being determined to not come from the same list of reference images, combining the first unidirectional predicted motion vector and the second unidirectional predicted motion vector to form a bidirectional predicted motion vector and storing the bidirectional predicted motion vector for a sub-block located in a bidirectional predicted region of the block.
[0095] In some embodiments, method 1400 may include determining whether a sub-block of a block (or CU) is within a bidirectional prediction region. For example, the sub-block is an M×N sub-block. In triangular partitioning mode, method 1400 may include determining... Is it equal to Where (x, y) represents the position of the top-left sample of the sub-block and (r x , r y This represents the ratio of the block's width to its height. If... Determined to be equal to Then the sub-block is in the bidirectional prediction region. If Being determined does not mean If so, the sub-block is in the unidirectional prediction region.
[0096] In some embodiments, when two unidirectional predicted motion vectors come from different lists of reference images, the two unidirectional predicted motion vectors are combined to form a bidirectional predicted motion vector. Otherwise, the average motion vector of the two unidirectional predicted motion vectors is stored.
[0097] In one example, when the reference images of the two unidirectional predicted motion vectors are the same, the two unidirectional predicted motion vectors are averaged and stored.
[0098] In another example, when the reference images for two unidirectional predicted motion vectors are different from each other, the two unidirectional predicted motion vectors are scaled to the same reference image and then averaged. For example, Mv1 and Mv2 are represented as motion vectors for the top and bottom partitions, respectively. And RefPicl and RefPic2 are represented as reference images for the top and bottom partitions, respectively. When RefPicl is not equal to RefPic2, Mv2 is first scaled to RefPicl. Then, the average motion vector of Mv1 and the scaled motion vector are stored. In an embodiment, the scaling can be performed using the time motion vector scaling procedure in VVC draft 5.
[0099] In another example, when the reference images of two unidirectional predicted motion vectors are different from each other, the two unidirectional predicted motion vectors are averaged and stored regardless of the differences in their reference images.
[0100] Figure 15 A flowchart illustrating another exemplary method 1500 for motion vector generation according to some embodiments of the present disclosure is shown. In some embodiments, method 1500 can be generated by an encoder (e.g., Figure 2 The encoder 200) performs the operation or is performed by a device (e.g., Figure 4 The device (400) executes the commands through one or more software or hardware components. For example, a processor (e.g., Figure 4 The processor 402) is capable of executing method 1500. In some embodiments, method 1500 can be implemented by a computer program product embodied in a computer-readable medium, said computer-readable medium comprising a computer (e.g., a processor 402) capable of executing method 1500. Figure 4 The device 400 executes computer-executable instructions, such as program code.
[0101] In step 1502, method 1500 can include determining whether a first unidirectional predicted motion vector for a first partition of a block (or CU) and a second unidirectional predicted motion vector for a second partition of the block come from the same list of reference images. The first and second partitions of the block can be triangular partitions or geometric partitions.
[0102] In step 1504, method 1500 may include, in response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined to be from the same list of reference images, storing the average motion vector of the first unidirectional predicted motion vector and the second unidirectional predicted motion vector for a sub-block located in the bidirectional prediction region of the block.
[0103] In some embodiments, method 1500 may include, in response to the determination that a first unidirectional predicted motion vector and a second unidirectional predicted motion vector are from the same list of reference images, determining whether a second reference image of the first unidirectional predicted motion vector is the same as a second reference image of the second unidirectional predicted motion vector. If the first reference image is determined to be different from the second reference image, the first and second unidirectional predicted motion vectors may be scaled to the first reference image, and the average motion vector of the scaled first and second unidirectional predicted motion vectors may be stored.
[0104] In some embodiments, method 1500 may further include, in response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined to be not from the same list of reference images, combining the first unidirectional predicted motion vector and the second unidirectional predicted motion vector to form a bidirectional predicted motion vector and storing the bidirectional predicted motion vector for a sub-block located in the bidirectional predicted region of the block.
[0105] In some embodiments, method 1500 may include determining whether a sub-block of a block (or CU) is within a bidirectional prediction region. For example, the sub-block is an M×N sub-block. In triangular partitioning mode, method 1500 may include determining... Is it equal to Where (x, y) represents the position of the top-left sample of the sub-block and (r x , r y This represents the ratio of the block's width to its height. If... Determined to be equal to Then the sub-block is in the bidirectional prediction region. If Being determined does not mean If so, the sub-block is located in the unidirectional prediction region.
[0106] It should be understood that some of the above embodiments can be implemented in combination with each other. The following are some exemplary embodiments for such combinations. It should be understood that although 8×8 sub-blocks are used as the basic unit for motion vector storage in the following embodiments, M×N sub-blocks can also be used.
[0107] In some embodiments, the motion vectors of the CU encoded in triangular partitioning mode or GPM are stored in 8×8 sub-blocks. Depending on the location of each 8×8 sub-block, either a unidirectional or bidirectional predictive motion vector is stored. In triangular partitioning mode, for example, Mv1 and Mv2 are represented as unidirectional predictive motion vectors for the left and right partitions, respectively. If an 8×8 sub-block is located in a unidirectional predictive region, Mv1 or Mv2 is stored for that 8×8 sub-block. Otherwise, if the 8×8 sub-block is located in a bidirectional predictive region, a bidirectional predictive motion vector is stored. The bidirectional predictive motion vector is derived from Mv1 and Mv2 according to the following process: 1. If Mv1 and Mv2 come from different lists of reference images (one from L0 and the other from L1), then Mv1 and Mv2 are simply combined to form a bidirectional predicted motion vector.
[0108] 2. Otherwise, if Mv1 and Mv2 come from the same list, only the unidirectional predicted motion Mv2 is stored.
[0109] The following procedure is used to determine whether an 8×8 sub-block is considered to be within the bidirectional prediction region: - if If so, the sub-block is located in the bidirectional prediction region; Otherwise, the 8×8 sub-block is located in the one-way prediction region. Where (x, y) represents the position of the top-left sample of the 8×8 sub-block and (r x , r y () represents the ratio of block width to block height.
[0110] In another embodiment, the motion vectors of the CU encoded in triangular partitioning mode or GPM are stored in 8×8 sub-blocks. Depending on the location of each 8×8 sub-block, either a unidirectional or bidirectional predictive motion vector is stored. In triangular partitioning mode, for example, Mv1 and Mv2 are represented as unidirectional predictive motion vectors for the top and bottom partitions, respectively. If an 8×8 sub-block is located in a unidirectional predictive region, Mv1 or Mv2 is stored for that 8×8 sub-block. Otherwise, if the 8×8 sub-block is located in a bidirectional predictive region, a bidirectional predictive motion vector is stored. The bidirectional predictive motion vectors are derived from Mv1 and Mv2 according to the following process: 1. If Mv1 and Mv2 come from different lists of reference images (one from L0 and the other from L1), then Mv1 and Mv2 are simply combined to form a bidirectional predicted motion vector.
[0111] 2. Otherwise, if Mv1 and Mv2 come from the same list, only the unidirectional predicted motion Mv2 is stored.
[0112] The following procedure is used to determine whether an 8×8 sub-block is considered to be within the bidirectional prediction region: -if Then the 8×8 sub-block is located in the bidirectional prediction region; Otherwise, the 8×8 sub-block is located in the one-way prediction region. Where (x, y) represents the position of the top-left sample of the 8×8 sub-block and (r x , r y () represents the ratio of block width to block height.
[0113] Figure 16 The illustration shows a flowchart of another exemplary method 1600 for sports field storage according to some embodiments of the present disclosure. In some embodiments, method 1600 can be generated by an encoder (e.g., Figure 2 The encoder 200) performs the operation or is performed by a device (e.g., Figure 4 The device (400) executes the commands through one or more software or hardware components. For example, a processor (e.g., Figure 4 The processor 402) is capable of executing method 1600. In some embodiments, method 1600 can be implemented by a computer program product embodied in a computer-readable medium, said computer-readable medium comprising a computer (e.g., a processor 402) capable of executing method 1600. Figure 4 The device 400 executes computer-executable instructions, such as program code.
[0114] In step 1602, method 1600 may include determining whether a sub-block of the block (or CU) is within the bidirectional prediction region. The sub-block may have a width, height, or both greater than 4. In some embodiments, at least one of the width and height of the sub-block is equal to or greater than 8. For example, the sub-block may be an 8×8 sub-block, a 4×8 sub-block, an 8×4 sub-block, a 16×16 sub-block, or a min(block width, 16) × min(block height, 16) sub-block. In some embodiments, the size of the sub-block may depend on the size of the block.
[0115] In some embodiments, the sub-blocks are M×N sub-blocks. In the triangular partitioning mode, for example, method 1600 can include determining... Is it equal to Where (x, y) represents the position of the top-left sample of the sub-block and (r x , r y This represents the ratio of the block's width to its height. If... Determined to be equal to Then the sub-block is in the bidirectional prediction region. If Determined not equal to If so, the sub-block is in the unidirectional prediction region.
[0116] In step 1604, method 1600 can include determining whether a first unidirectional predicted motion vector for a first partition of the block and a second unidirectional predicted motion vector for a second partition of the block come from the same list of reference images. The first and second partitions of the block can be triangular partitions or geometric partitions.
[0117] In step 1606, method 1600 may include storing one of the first and second unidirectional predictive motion vectors for the sub-block in response to the sub-block being determined to be in a bidirectional prediction region and the first and second unidirectional predictive motion vectors being determined to be from the same list of reference images. In some embodiments, one of the stored first and second unidirectional predictive motion vectors may be a motion vector from the top partition, a motion vector from the bottom partition, a motion vector from the left partition, a motion vector from the right partition, a motion vector of the current image whose reference image is closer to the current block, a motion vector of the reference image with higher quality, a motion vector with less motion, etc.
[0118] In some embodiments, method 1600 may include, in response to a sub-block being determined to be in a bidirectional prediction region and a first unidirectional prediction motion vector and a second unidirectional prediction motion vector being determined to not come from the same list of reference images, combining the first unidirectional prediction motion vector and the second unidirectional prediction motion vector to form a bidirectional prediction motion vector and storing the bidirectional prediction motion vector for the sub-block.
[0119] In some embodiments, method 1600 may include dividing the block into multiple sub-blocks.
[0120] It should be understood that the methods disclosed (e.g., Figure 12 Method 1200 Figure 14 Method 1400 Figure 15 Method 1500 and Figure 16 Method 1600 is not limited to triangular partitioning, but can be applied to geometric partitioning. In geometric partitioning, a block can be divided into two geometrically shaped partitions. Figure 17 This is a schematic diagram illustrating some examples of geometric partitioning according to some embodiments of the present disclosure.
[0121] Each geometric partition can use its own unidirectional predicted motion vector for inter-frame prediction. The unidirectional predicted motion vector for each partition can be derived directly from the list of merge candidates constructed for extended merge prediction, and the selection of a unidirectional predicted motion vector from a given merge candidate in the list can be based on the following process.
[0122] If the geometric partitioning pattern is used for the current CU, then the geometric partition index and two merge indices (one for each partition) indicating the partitioning pattern (angle and offset) are further signaled, as shown in Table 1 below (emphasized in italics): Table 1: Exemplary parts of the merge_data syntax After predicting each part of the geometric partition, a blending process with adaptive weights is used to adjust the sample values along the edges of the geometric partition. This is the prediction signal for the entire CU, and the transformation and quantization process can be applied to the entire CU as in other prediction modes. Finally, the motion field of the CU predicted using the geometric partitioning mode can be stored in 4×4 sub-blocks.
[0123] Given a merge candidate index, the unidirectional predicted motion vector is derived from the merge candidate list constructed for extended merge prediction. Figure 6 An exemplary unidirectional predicted motion vector selection 600 for geometric partitioning is illustrated according to some embodiments of the present disclosure. For candidates in the list, their LX motion vectors (where X equals the parity of the merged candidate index values) are used as unidirectional predicted motion vectors for geometric partitioning. These motion vectors in Figure 6 The symbol is marked with "×". In the absence of a corresponding LX motion vector, the L(1-X) motion vector of the same candidate in the expanded merge prediction candidate list is used as the unidirectional prediction motion vector for geometric partitioning.
[0124] After using its own motion to predict each geometric partition, a blend is applied to the two predicted signals to derive samples around the partition edges. The following weights are used in the blending process: {7 / 8, 6 / 8, 5 / 8, 4 / 8, 3 / 8, 2 / 8, 1 / 8}. The weights used for each sample are described below.
[0125] The blending weights used for each location within a block are derived based on the distance between each location and the partition edge. Location ( x, y The distance to the partition edge is derived as follows: Equation 1 Equation 2 Equation 3 Equation 4 in i , jThese are the indices used for the angles and offsets of the geometric partitions, which depend on the geometric partition indices notified by signals (e.g., merge_gpm_partition_idx[x0][y0]). Indices i and j are derived using the following Table 2: Table 2: Exemplary derivation of indices i and j and The sign depends on the angle index. i The variables (w, h) represent the width and height of the block. The weights for each part used in the geometric partitioning are derived as follows: partIdx = ( i >= 13 && i <= 27 ) ? 0 : 1 Among them, weight w 0( x , y The weights are applied to the samples predicted by deriving the first motion vector using merge_gpm_idx0[x0][y0], and the weights are... w 1( x , y ) is the weight applied to the sample predicted by derivation using the second motion vector of merge_gpm_idx1[x0][y0].
[0126] Motion vectors of blocks encoded in the geometric partitions are stored in 4×4 sub-blocks. Depending on the position of each 4×4 sub-block, either unidirectional or bidirectional predicted motion vectors are stored. Mv1 and Mv2 are represented as unidirectional predicted motion vectors for partition 1 and partition 2, respectively. Mv1 is obtained by using the merge index (e.g., merge_gpm_idx0[x0][y0]) notified by the first signal. Figure 6 The extended merge candidate list shown is derived. Similarly, Mv2 is derived from the extended merge candidate list using a merge index (e.g., merge_gpm_idxl[x0][y0]) signaled by a second semaphore. If the 4×4 sub-block is located in a unidirectional prediction region, then Mv1 or Mv2 is stored for that 4×4 sub-block. Otherwise, if the 4×4 sub-block is located in a bidirectional prediction region, then a bidirectional prediction motion vector is stored. The bidirectional prediction motion vector is derived from Mv1 and Mv2 according to the following process: 1. If Mv1 and Mv2 come from different lists of reference images (e.g., one from L0 and the other from L1), then Mv1 and Mv2 are simply combined to form a bidirectional predicted motion vector; 2. Otherwise, one of the two motion vectors is stored.
[0127] In one example, one of the two motion vectors is Mv1. In another example, one of the two motion vectors is Mv2.
[0128] To determine whether a 4×4 sub-block is located within the bidirectional prediction region, weights are used for the luminance samples located at (4x+2, 4y+2), where (x, y) represents the sub-block position within the block, such as... Figure 18 As shown.
[0129] When the absolute value of the weight is less than a threshold, the 4×4 sub-block is considered a bidirectional prediction region. Otherwise, the 4×4 sub-block is considered a unidirectional prediction region. The following equation can be applied to each 4×4 sub-block: Equation 5 Where motionIdx equals d (4) x + 2, 4 y + 2). When sType equals 2, it is possible to store bidirectional predicted motion vectors into 4×4 sub-blocks.
[0130] In some embodiments, a non-transitory computer-readable storage medium including instructions is also provided, and the instructions can be executed by means of devices such as the disclosed encoders and decoders to perform the methods described above. Common forms of non-transitory media include, for example, floppy disks, flexible disks, hard disks, solid-state drives, magnetic tape or any other magnetic data storage media, CD-ROMs, any other optical data storage media, any physical media with a perforated pattern, RAM, PROMs and EPROMs, FLASH-EPROMs or any other flash memory, NVRAMs, caches, registers, any other memory chips or cartridges, and their networking versions. The device may include one or more processors (CPUs), input / output interfaces, network interfaces, and / or memory.
[0131] The embodiments may be further described using the following terms: 1. A computer-implemented method, comprising: Determine whether the first unidirectional predicted motion vector for the first partition of the block and the second unidirectional predicted motion vector for the second partition of the block come from the same list of reference images; and In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined to be from the same list of reference images, one of the first unidirectional predicted motion vector and the second unidirectional predicted motion vector is stored in the motion field of the block for a sub-block located in the bidirectional predicted region of the block.
[0132] 2. The method according to Clause 1 further includes: In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined not to come from the same list of reference images, Combine the first unidirectional predicted motion vector and the second unidirectional predicted motion vector to form a bidirectional predicted motion vector; and The bidirectional predicted motion vectors are stored in the motion field of the block for the sub-blocks located in the bidirectional prediction region of the block.
[0133] 3. The method according to Clause 1 or Clause 2, wherein the first partition and the second partition are two geometric partitions or two triangular partitions.
[0134] 4. The method according to any one of clauses 1-3, wherein one of the stored first unidirectional predicted motion vector and second unidirectional predicted motion vector is one of the following: a motion vector from the top partition of the block, a motion vector from the bottom partition of the block, a motion vector from the left partition of the block, a motion vector from the right partition of the block, a motion vector from a reference image that is closer to the target image corresponding to the target block, a motion vector from a reference image that has higher quality, and a motion vector with less motion.
[0135] 5. The method according to any one of clauses 1-4, wherein one of the stored first unidirectional predicted motion vector and second unidirectional predicted motion vector is the second unidirectional predicted motion vector.
[0136] 6. The method according to any one of clauses 1-5, wherein the sub-block comprises M×N pixels, and at least one of M and N is greater than 4.
[0137] 7. The method according to any one of clauses 1-6, wherein the sub-block comprises M×N pixel samples, and at least one of M and N is equal to or greater than 8.
[0138] 8. The method according to any one of clauses 1-7, further comprising: Determine whether a sub-block of the block is in the bidirectional prediction region.
[0139] 9. The method according to Clause 8, wherein the sub-block is an M×N sub-block, and determining whether the sub-block is included in the bidirectional prediction region: Sure Is it equal to Where (x, y) represents the position of the top-left pixel sample of the sub-block and (r x , r y ) represents the ratio of the width of the block to the height of the block; and In response to Determined to be equal to The sub-block is determined in the bidirectional prediction region.
[0140] 10. The method according to any one of clauses 1-9, further comprising: The block is divided into multiple sub-blocks, each of which is one of an 8×8 sub-block, a 4×8 sub-block, an 8×4 sub-block, a 16×16 sub-block, and a min(width of the block, 16) × min(height of the block, 16) sub-block.
[0141] 11. An apparatus comprising: Memory, the memory being configured to store instructions; and A processor, coupled to the memory and configured to execute the instructions to cause the device to: Determine whether the first unidirectional predicted motion vector for the first partition of the block and the second unidirectional predicted motion vector for the second partition of the block come from the same list of reference images; and In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined to be from the same list of reference images, one of the first unidirectional predicted motion vector and the second unidirectional predicted motion vector is stored in the motion field of the block for a sub-block located in the bidirectional predicted region of the block.
[0142] 12. The device according to Clause 11, wherein the processor is further configured to execute the instructions to cause the device to: In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined not to come from the same list of reference images, Combine the first unidirectional predicted motion vector and the second unidirectional predicted motion vector to form a bidirectional predicted motion vector; and The bidirectional predicted motion vectors are stored in the motion field of the block for the sub-blocks located in the bidirectional prediction region of the block.
[0143] 13. The device according to Clause 11 or Clause 12, wherein the first partition and the second partition are two geometric partitions or two triangular partitions.
[0144] 14. The device according to claims 11-13, wherein one of the stored first unidirectional predicted motion vector and second unidirectional predicted motion vector is one of the following: a motion vector from the top partition of the block, a motion vector from the bottom partition of the block, a motion vector from the left partition of the block, a motion vector from the right partition of the block, a motion vector from a reference image that is closer to a target image corresponding to the target block, a motion vector from a reference image that has higher quality, and a motion vector with less motion.
[0145] 15. The device according to any one of clauses 11-14, wherein the sub-block comprises M×N pixels, and at least one of M and N is greater than 4.
[0146] 16. The device according to any one of clauses 11-15, wherein the sub-block comprises M×N pixel samples, and at least one of M and N is equal to or greater than 8.
[0147] 17. The device according to any one of clauses 11-16, wherein the processor is further configured to execute the instructions to cause the device to determine whether a sub-block of the block is in the bidirectional prediction region.
[0148] 18. The device according to Clause 17, wherein the sub-block is an M×N sub-block, and the processor is further configured to execute the instructions to cause the device to: Sure Is it equal to Where (x, y) represents the position of the top-left pixel sample of the sub-block and (r x , r y ) represents the ratio of the width of the block to the height of the block; and In response to Determined to be equal to The sub-block is determined in the bidirectional prediction region.
[0149] 19. The device according to any one of clauses 11-18, wherein the processor is further configured to execute the instructions to cause the device to: The block is divided into multiple sub-blocks, each of which is one of an 8×8 sub-block, a 4×8 sub-block, an 8×4 sub-block, a 16×16 sub-block, and a min(width of the block, 16) × min(height of the block, 16) sub-block.
[0150] 20. A non-transitory computer-readable storage medium storing a set of instructions executable by one or more processors of a device, wherein execution of the set of instructions causes the device to perform: Determine whether the first unidirectional predicted motion vector for the first partition of the block and the second unidirectional predicted motion vector for the second partition of the block come from the same list of reference images; and In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined to be from the same list of reference images, one of the first unidirectional predicted motion vector and the second unidirectional predicted motion vector is stored in the motion field of the block for a sub-block located in the bidirectional predicted region of the block.
[0151] 21. The non-transitory computer-readable storage medium according to Clause 20, wherein execution of said set of instructions causes the means to further perform: In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined not to come from the same list of reference images, Combine the first unidirectional predicted motion vector and the second unidirectional predicted motion vector to form a bidirectional predicted motion vector; and The bidirectional predicted motion vectors are stored in the motion field of the block for the sub-blocks located in the bidirectional prediction region of the block.
[0152] 22. The non-transitory computer-readable storage medium as described in Clause 20 or Clause 21, wherein the first partition and the second partition are two geometric partitions or two triangular partitions.
[0153] 23. A non-transitory computer-readable storage medium according to any one of clauses 20-22, wherein one of the stored first unidirectional predicted motion vector and second unidirectional predicted motion vector is one of the following: a motion vector from the top partition of the block, a motion vector from the bottom partition of the block, a motion vector from the left partition of the block, a motion vector from the right partition of the block, a motion vector from a reference image that is closer to a target image corresponding to the target block, a motion vector from a reference image that has higher quality, and a motion vector with less motion.
[0154] 24. A non-transitory computer-readable storage medium according to any one of clauses 20-23, wherein the sub-block comprises M×N pixels, and at least one of M and N is greater than 4.
[0155] 25. A non-transitory computer-readable storage medium according to any one of clauses 20-24, wherein the sub-block comprises M×N pixel samples, and at least one of M and N is equal to or greater than 8.
[0156] 26. The apparatus according to any one of clauses 20-25, wherein execution of said set of instructions causes the apparatus to further perform: Determine whether a sub-block of the block is in the bidirectional prediction region.
[0157] 27. The non-transitory computer-readable storage medium according to Clause 26, wherein the sub-block is an M×N sub-block, and it is determined whether the sub-block is included in the bidirectional prediction region: Sure Is it equal to Where (x, y) represents the position of the top-left pixel sample of the sub-block and (r x , r y ) represents the ratio of the width of the block to the height of the block; and In response to Determined to be equal to The sub-block is determined in the bidirectional prediction region.
[0158] 28. A non-transitory computer-readable storage medium according to any one of clauses 20-27, wherein execution of said set of instructions causes the means to further perform: The block is divided into multiple sub-blocks, each of which is one of an 8×8 sub-block, a 4×8 sub-block, an 8×4 sub-block, a 16×16 sub-block, and a min(width of the block, 16) × min(height of the block, 16) sub-block.
[0159] 29. A computer-implemented method, comprising: Determine whether a sub-block is within the bidirectional prediction region of a block, wherein at least one of the width and height of the sub-block is greater than 4; and In response to the sub-block being identified as being in the bidirectional prediction region, a bidirectional prediction motion vector is stored for the sub-block in the motion field of the block.
[0160] 30. The method according to Clause 29, wherein at least one of the width and height of the sub-block is equal to or greater than 8.
[0161] 31. The method described pursuant to Clause 29 or Clause 30 further includes: In response to the sub-block being determined to be outside the bidirectional prediction region, a unidirectional prediction motion vector is stored for the sub-block in the motion field of the block.
[0162] 32. The method according to any one of clauses 29-31, wherein the sub-block is an M×N sub-block, and determining whether the sub-block is included in the bidirectional prediction region: Sure Is it equal to Where (x, y) represents the position of the top-left pixel sample of the sub-block and (r x , r y ) represents the ratio of the width of the block to the height of the block; and In response to Determined to be equal to The sub-block is determined in the bidirectional prediction region.
[0163] 33. The method described in accordance with Clause 32 further includes: In response to Determined not equal to The sub-block is determined to be within the unidirectional prediction region.
[0164] 34. The method according to Clauses 29-33 further includes: The block is divided into multiple sub-blocks, each of which is one of an 8×8 sub-block, a 4×8 sub-block, an 8×4 sub-block, a 16×16 sub-block, and a min(width of the block, 16) × min(height of the block, 16) sub-block.
[0165] 35. The method according to clauses 29-34, wherein the size of the sub-block depends on the size of the block.
[0166] 36. The method described in accordance with Clause 35 further includes: In response to the sub-block and the block having the same size, it is determined that the bidirectional predicted motion vector is the same as the unidirectional predicted motion vector.
[0167] 37. An apparatus comprising: Memory, the memory being configured to store instructions; and A processor, coupled to the memory and configured to execute the instructions to cause the device to: Determine whether a sub-block is within the bidirectional prediction region of a block, wherein at least one of the width and height of the sub-block is greater than 4; and In response to the sub-block being identified as being in the bidirectional prediction region, a bidirectional prediction motion vector is stored for the sub-block in the motion field of the block.
[0168] 38. The device according to Clause 37, wherein at least one of the width and height of the sub-block is equal to or greater than 8.
[0169] 39. The device according to Clause 37 or Clause 38, wherein the processor is further configured to execute the instructions to cause the device to: In response to the sub-block being determined to be outside the bidirectional prediction region, a unidirectional prediction motion vector is stored for the sub-block in the motion field of the block.
[0170] 40. The device according to any one of clauses 37-39, wherein the sub-block is an M×N sub-block, and the processor is further configured to execute the instructions to cause the device to: Sure Is it equal to Where (x, y) represents the position of the top-left pixel sample of the sub-block and (r x , r y ) represents the ratio of the width of the block to the height of the block; and In response to Determined to be equal to The sub-block is determined in the bidirectional prediction region.
[0171] 41. The device according to clause 40, wherein the processor is further configured to execute the instructions to cause the device to: In response to Determined not equal to The sub-block is determined to be within the unidirectional prediction region.
[0172] 42. The device according to claims 37-41, wherein the processor is further configured to execute the instructions to cause the device to: The block is divided into multiple sub-blocks, each of which is one of an 8×8 sub-block, a 4×8 sub-block, an 8×4 sub-block, a 16×16 sub-block, and a min(width of the block, 16) × min(height of the block, 16) sub-block.
[0173] 43. The device according to clauses 37-42, wherein the size of the sub-block depends on the size of the block.
[0174] 44. The device according to clause 43, wherein the processor is further configured to execute the instructions to cause the device to: In response to the sub-block and the block having the same size, it is determined that the bidirectional predicted motion vector is the same as the unidirectional predicted motion vector.
[0175] 45. A non-transitory computer-readable storage medium storing a set of instructions executable by one or more processors of a device, wherein execution of the set of instructions causes the device to perform a method, the method comprising: Determine whether a sub-block is within the bidirectional prediction region of a block, wherein at least one of the width and height of the sub-block is greater than 4; and In response to the sub-block being identified as being in the bidirectional prediction region, a bidirectional prediction motion vector is stored for the sub-block in the motion field of the block.
[0176] 46. The non-transitory computer-readable storage medium according to Clause 45, wherein at least one of the width and height of the sub-block is equal to or greater than 8.
[0177] 47. A non-transitory computer-readable storage medium as described in Clause 45 or Clause 46, wherein execution of said set of instructions causes the means to further perform: In response to the sub-block being determined to be outside the bidirectional prediction region, a unidirectional prediction motion vector is stored for the sub-block in the motion field of the block.
[0178] 48. A non-transitory computer-readable storage medium according to any one of clauses 45-47, wherein the sub-block is an M×N sub-block, and it is determined whether the sub-block is included in the bidirectional prediction region: Sure Is it equal to Where (x, y) represents the position of the top-left pixel sample of the sub-block and (r x , r y ) represents the ratio of the width of the block to the height of the block; and In response to Determined to be equal to The sub-block is determined in the bidirectional prediction region.
[0179] 49. The non-transitory computer-readable storage medium according to Clause 48, wherein execution of said set of instructions causes the means to further perform: In response to Determined not equal to The sub-block is determined to be within the unidirectional prediction region.
[0180] 50. The non-transitory computer-readable storage medium according to clauses 45-49, wherein execution of said set of instructions causes the means to further perform: The block is divided into multiple sub-blocks, each of which is one of an 8×8 sub-block, a 4×8 sub-block, an 8×4 sub-block, a 16×16 sub-block, and a min(width of the block, 16) × min(height of the block, 16) sub-block.
[0181] 51. The non-transitory computer-readable storage medium according to clauses 45-50, wherein the size of the sub-block depends on the size of the block.
[0182] 52. According to the non-transitory computer-readable storage medium described in Clause 51, execution of the set of instructions causes the apparatus to further perform: In response to the sub-block and the block having the same size, it is determined that the bidirectional predicted motion vector is the same as the unidirectional predicted motion vector.
[0183] 53. A computer-implemented method, comprising: Determine whether the first unidirectional predicted motion vector for the first partition of the block and the second unidirectional predicted motion vector for the second partition of the block come from the same list of reference images; and In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined to be from the same list of reference images, the average motion vector of the first unidirectional predicted motion vector and the second unidirectional predicted motion vector is stored in the motion field of the block for the sub-blocks located in the bidirectional prediction region of the block.
[0184] 54. The method described in accordance with Clause 53 further includes: In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined not to come from the same list of reference images, Combine the first unidirectional predicted motion vector and the second unidirectional predicted motion vector to form a bidirectional predicted motion vector; and The bidirectional predicted motion vectors are stored in the motion field of the block for the sub-blocks located in the bidirectional prediction region of the block.
[0185] 55. The method according to clause 53, wherein storing the average motion vector of the first unidirectional predicted motion vector and the second unidirectional predicted motion vector for a sub-block located in the bidirectional prediction region of the block in the motion field of the block comprises: Determine whether the first reference image of the first unidirectional predicted motion vector is the same as the second reference image of the second unidirectional predicted motion vector; and In response to the first reference image being determined to be different from the second reference image Scale the first unidirectional predicted motion vector and the second unidirectional predicted motion vector to the first reference image; and The average motion vector of the scaled first unidirectional predicted motion vector and the scaled second unidirectional predicted motion vector is stored in the motion field of the block.
[0186] 56. The method according to any one of clauses 53-55, wherein the first partition and the second partition are two geometric partitions or two triangular partitions.
[0187] 57. An apparatus comprising: A memory configured to store instructions; and A processor, coupled to the memory and configured to execute the instructions to cause the device to: Determine whether the first unidirectional predicted motion vector for the first partition of the block and the second unidirectional predicted motion vector for the second partition of the block come from the same list of reference images; and In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined to be from the same list of reference images, the average motion vector of the first unidirectional predicted motion vector and the second unidirectional predicted motion vector is stored in the motion field of the block for the sub-blocks located in the bidirectional prediction region of the block.
[0188] 58. The device according to clause 57, wherein the processor is further configured to execute the instructions to cause the device to: In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined not to come from the same list of reference images, Combine the first unidirectional predicted motion vector and the second unidirectional predicted motion vector to form a bidirectional predicted motion vector; and The bidirectional predicted motion vectors are stored in the motion field of the block for the sub-blocks located in the bidirectional prediction region of the block.
[0189] 59. The apparatus according to clause 57, wherein storing the average motion vector of the first unidirectional predicted motion vector and the second unidirectional predicted motion vector for a sub-block located in a bidirectional prediction region of the block in the motion field of the block comprises: Determine whether the first reference image of the first unidirectional predicted motion vector is the same as the second reference image of the second unidirectional predicted motion vector; and In response to the first reference image being determined to be different from the second reference image Scale the first unidirectional predicted motion vector and the second unidirectional predicted motion vector to the first reference image; and The average motion vector of the scaled first unidirectional predicted motion vector and the scaled second unidirectional predicted motion vector is stored in the motion field of the block.
[0190] 60. The device according to any one of clauses 57-59, wherein the first partition and the second partition are two geometric partitions or two triangular partitions.
[0191] 61. A non-transitory computer-readable storage medium storing a set of instructions executable by one or more processors of a device, wherein execution of the set of instructions causes the device to perform a method, the method comprising: Determine whether the first unidirectional predicted motion vector for the first partition of the block and the second unidirectional predicted motion vector for the second partition of the block come from the same list of reference images; and In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined to be from the same list of reference images, the average motion vector of the first unidirectional predicted motion vector and the second unidirectional predicted motion vector is stored in the motion field of the block for the sub-blocks located in the bidirectional prediction region of the block.
[0192] 62. The non-transitory computer-readable storage medium according to Clause 61, wherein execution of said set of instructions causes the means to further perform: In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined not to come from the same list of reference images, Combine the first unidirectional predicted motion vector and the second unidirectional predicted motion vector to form a bidirectional predicted motion vector; and The bidirectional predicted motion vectors are stored in the motion field of the block for the sub-blocks located in the bidirectional prediction region of the block.
[0193] 63. The non-transitory computer-readable storage medium according to Clause 61, wherein storing the average motion vector of the first unidirectional predicted motion vector and the second unidirectional predicted motion vector for a sub-block located in a bidirectional prediction region of the block in the motion field of the block comprises: Determine whether the first reference image of the first unidirectional predicted motion vector is the same as the second reference image of the second unidirectional predicted motion vector; and In response to the first reference image being determined to be different from the second reference image Scale the first unidirectional predicted motion vector and the second unidirectional predicted motion vector to the first reference image; and The average motion vector of the scaled first unidirectional predicted motion vector and the scaled second unidirectional predicted motion vector is stored in the motion field of the block.
[0194] 64. The device according to any one of clauses 61-63, wherein the first partition and the second partition are two geometric partitions or two triangular partitions.
[0195] It should be noted that relational terms such as “first” and “second” in this document are used only to distinguish one entity or operation from another, without requiring or implying any actual relationship or order between these entities or operations. Furthermore, the words “including,” “having,” “containing,” and “including,” and other similar forms are intended to be semantically equivalent and open-ended, as one or more items immediately following any of these words are not intended to be an exhaustive list of one or more such items, or to be limited to only the listed one or more items.
[0196] As used herein, unless otherwise specifically stated, the term "or" includes all possible combinations, unless impractical. For example, if it is stated that a database may include A or B, then unless otherwise specifically stated or impractical, the database may include A, or B, or A and B. As a second example, if it is stated that a database may include A, B, or C, then unless otherwise specifically stated or impractical, the database may include A, or B, or C, or A and B, or A and C, or B and C, or A and B and C.
[0197] It should be understood that the above embodiments can be implemented by hardware, software (program code), or a combination of hardware and software. If implemented by software, it can be stored in the above-described computer-readable medium. When executed by a processor, the software can perform the disclosed methods. The computing units and other functional units described in this disclosure can be implemented by hardware, software, or a combination of hardware and software. Those skilled in the art will also understand that multiple modules / units in the above modules / units can be combined into one module / unit, and each module / unit in the above modules / units can be further divided into multiple sub-modules / sub-units.
[0198] In the foregoing description, embodiments have been described with reference to numerous specific details that may vary from implementation to implementation. Certain adaptations and modifications can be made to the described embodiments. Other embodiments will be apparent to those skilled in the art based on considerations of the specification and practice of the invention disclosed herein. This specification and examples are intended to be considered exemplary only, while the true scope and spirit of the invention are indicated by the following claims. The order of steps shown in the figures is also intended for illustrative purposes only and is not intended to limit to any particular order of steps. Therefore, those skilled in the art will appreciate that these steps can be performed in different orders while implementing the same method.
[0199] Exemplary embodiments have been disclosed in the accompanying drawings and description. However, many variations and modifications can be made to these embodiments. Therefore, although specific terms have been used, they are used in a general and descriptive sense only and not for limiting purposes.
Claims
1. A video encoding apparatus, comprising: A memory configured to store instructions; A processor, coupled to the memory and configured to execute the instructions to cause the device to perform: Determine whether a first unidirectional predicted motion vector for a first geometric partition of a block and a second unidirectional predicted motion vector for a second geometric partition of the block come from the same list of reference images, wherein the first and second geometric partitions are determined based on a geometric partitioning pattern defined by angles and distances corresponding to indices signaled to the bitstream; as well as In the motion field of the block, store the motion vector of a sub-block located in the bidirectional prediction region of the block; Specifically, when it is determined that the first unidirectional predicted motion vector and the second unidirectional predicted motion vector are from the same list of reference images, the stored motion vector is the second unidirectional predicted motion vector.
2. The apparatus of claim 1, wherein the processor is further configured to execute the instructions to cause the apparatus to: In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined not to come from the same list of reference images, Combine the first unidirectional predicted motion vector and the second unidirectional predicted motion vector to form a bidirectional predicted motion vector; and The bidirectional predicted motion vectors are stored in the motion field of the block for the sub-blocks located in the bidirectional prediction region of the block.
3. The apparatus of claim 1, wherein one of the stored first unidirectional predicted motion vector and second unidirectional predicted motion vector is one of the following: a motion vector from the top partition of the block, a motion vector from the bottom partition of the block, a motion vector from the left partition of the block, a motion vector from the right partition of the block, a motion vector from a reference image that is closer to a target image corresponding to the target block, a motion vector from a reference image that has higher quality, and a motion vector with less motion.
4. The apparatus of claim 1, wherein the sub-block comprises M×N pixels, and at least one of M and N is greater than 4.
5. The apparatus of claim 1, wherein the sub-block comprises M×N pixel samples, and at least one of M and N is equal to or greater than 8.
6. The apparatus of claim 1, wherein the processor is further configured to execute the instructions to cause the apparatus to: The block is divided into multiple sub-blocks, each of which is one of an 8×8 sub-block, a 4×8 sub-block, an 8×4 sub-block, a 16×16 sub-block, and a min(width of the block, 16) × min(height of the block, 16) sub-block.
7. A video decoding method, comprising: Based on the encoded information in the bitstream, it is determined whether a first unidirectional predicted motion vector for a first geometric partition of a block and a second unidirectional predicted motion vector for a second geometric partition of the block come from the same list of reference images, wherein the first and second geometric partitions are determined based on a geometric partitioning pattern defined by the angle and distance corresponding to an index indicated by a signal in the bitstream; as well as In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined to be from the same list of reference images, the second unidirectional predicted motion vector is stored in the motion field of the block for a sub-block located in the bidirectional predicted region of the block.
8. The video decoding method according to claim 7, wherein, In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined not to come from the same list of reference images, Combine the first unidirectional predicted motion vector and the second unidirectional predicted motion vector to form a bidirectional predicted motion vector; and The bidirectional predicted motion vectors are stored in the motion field of the block for the sub-blocks located in the bidirectional prediction region of the block.
9. The video decoding method of claim 7, wherein one of the stored first unidirectional predicted motion vector and second unidirectional predicted motion vector is one of the following: a motion vector from the top partition of the block, a motion vector from the bottom partition of the block, a motion vector from the left partition of the block, a motion vector from the right partition of the block, a motion vector of a reference image that is closer to the target image corresponding to the target block, a motion vector of a reference image with higher quality, and a motion vector with less motion.
10. The video decoding method according to claim 7, wherein the sub-block comprises M×N pixels, and at least one of M and N is greater than 4.
11. The video decoding method according to claim 7, wherein the sub-block comprises M×N pixel samples, and at least one of M and N is equal to or greater than 8.
12. The video decoding method according to claim 7, wherein, The block is divided into multiple sub-blocks, each of which is one of an 8×8 sub-block, a 4×8 sub-block, an 8×4 sub-block, a 16×16 sub-block, and a min(width of the block, 16) × min(height of the block, 16) sub-block.
13. A method for transmitting a bitstream, comprising: generating a video bitstream by performing the following methods; and transmitting the bitstream: Determine whether a first unidirectional predicted motion vector for a first geometric partition of a block and a second unidirectional predicted motion vector for a second geometric partition of the block originate from the same list of reference images, wherein the first and second geometric partitions are determined based on a geometric partitioning pattern defined by angles and distances corresponding to indices signaled to the bitstream; and In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined to be from the same list of reference images, the second unidirectional predicted motion vector is stored in the motion field of the block for a sub-block located in the bidirectional predicted region of the block.
14. The method of claim 13, wherein: In response to the first unidirectional predicted motion vector and the second unidirectional predicted motion vector being determined not to come from the same list of reference images, Combine the first unidirectional predicted motion vector and the second unidirectional predicted motion vector to form a bidirectional predicted motion vector; and The bidirectional predicted motion vectors are stored in the motion field of the block for the sub-blocks located in the bidirectional prediction region of the block.
15. The method of claim 13, wherein one of the stored first unidirectional predicted motion vector and second unidirectional predicted motion vector is one of the following: a motion vector from the top partition of the block, a motion vector from the bottom partition of the block, a motion vector from the left partition of the block, a motion vector from the right partition of the block, a motion vector from a reference image that is closer to a target image corresponding to the target block, a motion vector from a reference image that has higher quality, and a motion vector with less motion.
16. The method of claim 13, wherein the sub-block comprises M×N pixels, and at least one of M and N is greater than 4.