Method and device for video encoding

The geometric fusion mode in video encoding and decoding optimizes motion vector prediction by partitioning blocks geometrically, addressing redundancy and achieving higher compression ratios with minimal distortion, applicable to streaming and video conferencing.

RU2801587C1Undetermined Publication Date: 2023-08-11TENCENT AMERICA LLC
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
RU2021128174
Authority / Receiving Office
RU · RU
Patent Type
Patents
Current Assignee / Owner
Priority Date
2020-10-05
Filing Date
2020-10-07
Publication Date
2023-08-11
Estimated Expiration
2040-10-07

AI Technical Summary

Technical Problem

Existing video encoding and decoding technologies face challenges in efficiently reducing redundancy and achieving high compression ratios while maintaining acceptable distortion levels, particularly in applications like consumer streaming and television distribution, where different distortion tolerances are required.

Method used

The implementation of a geometric fusion mode (GEO) that divides blocks into partitions based on geometric partitioning, using weight indices and equations to determine weight coefficients for sample reconstruction, enhancing the efficiency of motion vector prediction and compression.

Benefits of technology

The GEO mode improves coding efficiency by optimizing motion vector prediction, leading to reduced redundancy and higher compression ratios without significant distortion, suitable for various video applications including streaming and video conferencing.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 00000040_ABST
    Figure 00000040_ABST
Patent Text Reader

Abstract

FIELD: encoding.SUBSTANCE: method and devices are proposed in which the prediction information of the current block of the current image in the encoded bitstream is decoded. The prediction information indicates a geometric partitioning mode (GPM) for the current block. The current block is divided into two sections in GPM mode. Each of the partitions is associated with a corresponding predictor. The weight index for the sample of the current block is determined based on the position of the sample. A weighting factor is calculated based on the weight index of the sample according to an equation that converts the weight index into a weighting factor.EFFECT: sample is reconstructed based on the weight and predictor corresponding to the sample.22 cl, 18 dwg, 5 tbl
Need to check novelty before this filing date? Find Prior Art

Description

INCORPORATION BY LINK

[0001] This application claims priority to U.S. Patent Application No. 17 / 063,149, “METHOD AND APPARATUS FOR ENCODING VIDEO,” filed October 5, 2020, which claims priority to U.S. Provisional Application No. 62 / 953,457, “SIMPLICATION FOR INTER-BLOCK GEO,” filed December 24, 2019, and U.S. Provisional Application No. 62 / 955,825, “METHOD WITHOUT USING A WEIGHT INDEX LOOKUP TABLE FOR WEIGHT CONVERSION FOR INTER-BLOCK GEO,” filed December 31, 2019. The entire disclosures of these prior applications are incorporated herein by reference in their entirety. SCOPE TECHNOLOGY TO WHICH THE INVENTION RELATES

[0002] The present invention describes embodiments generally related to video coding.BACKGROUND

[0003] The description of the prior art provided in this document is intended to provide a general context for the invention. The work of the inventors named herein, to the extent described in this section of the description of the prior art, as well as aspects of the description that would not otherwise be considered prior art at the time of filing, are neither expressly nor impliedly admitted as prior art with respect to the present invention.

[0004] Video encoding and decoding can be performed using inter-frame prediction with motion compensation. Uncompressed digital video may include a series of images, with each image having a spatial dimension of, for example, 1920×1080 luminance samples and associated chrominance samples. The series of images may have a fixed or variable picture frequency (informally also known as a frame rate), for example, 60 images per second or 60 Hz. Uncompressed video has significant bitrate requirements. For example, 1080p60 4:2:0 video with a frequency of 8 bits per sample (a resolution of 1920×1080 luminance samples at a frame rate of 60 Hz) requires a bandwidth of close to 1.5 Gbps. An hour of such video requires over 600 GB of disk space.

[0005] One of the goals of video encoding and decoding can be to reduce the redundancy of the input video signal through compression. Compression can help reduce the aforementioned bandwidth or storage space requirements, in some cases by two orders of magnitude or more. Both lossless and lossy compression, as well as a combination of both, can be used. Lossless compression refers to methods that allow an exact copy of the original signal to be reconstructed from the compressed source signal. With lossy compression, the reconstructed signal may not be identical to the original signal, but the distortion between the original and reconstructed signals is small enough to make the reconstructed signal useful for the intended application. Lossy compression is widely used in video.The acceptable level of distortion varies by application; for example, users of certain consumer streaming apps may tolerate higher distortion than users of television distribution apps. Achievable compression ratios may reflect the following: higher permissible / acceptable distortion may result in higher compression ratios.

[0006] A video encoder and video decoder can use techniques from several broad categories, including, for example, motion compensation, transform, quantization, and entropy coding.

[0007] Video codec technologies may include methods known as interprediction. For each interprediction coding unit (CU), the motion parameters include motion vectors, reference picture indices, and a reference picture list usage index, as well as additional information to be used to generate interprediction samples. The motion parameters can be signaled explicitly or implicitly. When a CU is coded in skip mode, the CU is associated with a single prediction unit (PU) and has no meaningful residual coefficients, encoded motion vector delta, or reference picture index. A fusion mode is specified in which the motion parameters for the current CU are obtained from neighboring CUs, including spatial and temporal candidates, and additional schedules are introduced, such as in VVC. The fusion mode can be applied to any interprediction CU, not just the skip mode.An alternative to the fusion mode is explicit transmission of motion parameters. The motion vector, the corresponding reference image index for each reference image list, the reference image list usage flag, and other necessary information are explicitly signaled for each CU.

[0008] Some inter-prediction coding tools include advanced fusion prediction, motion vector difference (MMVD) fusion mode, advanced motion vector prediction (AMVP) mode with symmetric motion vector difference (MVD) signaling, affine prediction with motion compensation, sub-block-based temporal motion vector prediction (SbTMVP), adaptive motion vector resolution (AMVR), motion field storage (storing 1 / 16 MV luminance sample and compressing 8×8 motion field), bi-weighted average prediction (BWA), bi-directional optical flow (BDOF), decoder-side motion vector refinement (DMVR), triangular division mode (TPM), and combined inter- and intra-prediction (CIIP).

[0009] In some cases, the merge candidate list is constructed by including the following five types of candidates in order: (1) spatial MVP from spatial neighboring CUs; ​​(2) temporal MVP from collocated CUs; ​​(3) history-based MVP from the FIFO table; (4) pairwise average MVP; and (5) zero MVs.

[0010] The merge list size is signaled in the slice header, and in some cases the maximum allowed merge list size is, for example, 6. For each CU code in merge mode, the index of the best merge candidate is encoded using truncated unary binarization (TU). The first cell of the merge index is context-encoded, and for other cells, bypass encoding is used.

[0011] Fig. 1A shows exemplary positions of spatial merge candidates. In some cases, up to four merge candidates may be selected from among the candidates at the positions shown in Fig. 1A. The selection order is B1, A1, B0, A0, and B2. The candidate at position B2 is considered only when any CU at positions A0, B0, B1, or A1 is unavailable (e.g., the CU at position A0 belongs to another slice or tile) or is not inter-coded. After the candidate at position A1 is added to the merge candidate list, the addition of the remaining candidates is subject to a redundancy check, which ensures that candidates with the same motion information are excluded from the merge candidate list, so that the coding efficiency is improved.

[0012] Figure 1B shows the candidate pairs considered for the redundancy check of spatial fusion candidates. To reduce computational complexity, not all possible candidate pairs are considered for the redundancy check. Instead, only the pairs indicated by the arrow in Figure 1B are considered, and a candidate is added to the merge candidate list only if the corresponding candidate used for the redundancy check does not have the same motion information.

[0013] Fig. 1C shows the scaling of the motion vector for a temporal fusion candidate. In some cases, only one temporal fusion candidate can be added to the fusion candidate list. Specifically, when obtaining this temporal fusion candidate, a scaled motion vector is obtained based on the co-located CU belonging to the co-located reference picture. The list of reference pictures used to obtain the co-located CU is explicitly signaled in the slice header. The scaled motion vector for the temporal fusion candidate is obtained as shown by the dashed line in Fig. 1C. The scaled motion vector is obtained from the motion vector of the co-located CU using the picture order counter (POC) distances tb and td, where tb is defined as the POC difference between the reference picture of the current picture and the current picture, and td is defined as the POC difference between the reference picture of the co-located picture and the co-located picture.The index of the reference image of the temporary fusion candidate can be set to zero.

[0014] Fig. 1D shows exemplary positions for a temporary merge candidate. The temporary merge candidate is selected between the CUs in positions C0 and C1. If the CU in position C0 is unavailable, not intercoded, or outside the current CTU row, the CU in position C1 is used. Otherwise, the CU in position C0 is used to obtain the temporary merge candidate. DISCLOSURE OF THE INVENTION

[0015] Aspects of the invention relate to methods and devices for video encoding / decoding. In some examples, the video decoding device includes processing circuitry.

[0016] According to aspects of the disclosure, a video decoding method is provided in a decoder. This method decodes prediction information of the current block of the current image in an encoded bitstream. The prediction information indicates a geometric partitioning mode (GPM) for the current block. The current block is divided into two partitions in the GPM mode. Each partition is associated with a corresponding predictor. A weight index for a sample of the current block is determined based on the position of the sample. A weight coefficient is calculated based on the weight index of the sample according to an equation that converts the weight index into a weight coefficient. The sample is reconstructed based on the weight coefficient and predictor corresponding to the sample.

[0017] In this embodiment, a right shift operation is performed on the sum of the weight index and the offset value. The result of the right shift operation is truncated to a predetermined range.

[0018] In an embodiment, the offset value is based on the number of bits shifted by the right shift operation, and the number of bits shifted by the right shift operation is based on at least one of a weight index and a size of a cosine table used to calculate the weight index.

[0019] In this embodiment, the angle index and distance index that define the division boundary between sections of the current block are determined based on the GPM. A weight index for a sample is determined based on the sample position, angle index, and distance index.

[0020] In this embodiment, a partition index is determined based on an angle index. A weighting coefficient is calculated based on the partition index.

[0021] In the embodiment, the equation is in which where idx2wShiftBit specifies the number of bits shifted by the right shift operation, weight is the weighting factor, partIdx is the partition index, wIdx is the weighting index, and Clip3() is the clipping function.

[0022] In an embodiment, the equation is a piecewise constant function that includes an initial value and a plurality of unit step functions. The initial value is one of the minimum value of the weight coefficient and the maximum value of the weight coefficient, and the number of the plurality of unit step functions is equal to the total number of different values ​​of the weight coefficients minus one.

[0023] Aspects of the disclosure provide a device configured to perform any one or a combination of video decoding methods. In an embodiment, the device includes a processing circuit that decodes prediction information of the current block of the current picture in an encoded bitstream. The prediction information indicates a geometric partitioning mode (GPM) for the current block. The current block is divided into two partitions in the GPM mode. Each partition is associated with a corresponding predictor. The processing circuit determines a weight index for a sample of the current block based on the position of the sample. The processing circuit calculates a weight based on the weight index of the sample according to an equation that converts the weight index into a weight. The processing circuit reconstructs the sample based on the weight and predictor corresponding to the sample.

[0024] Aspects of the invention also provide a non-transitory computer-readable medium storing instructions that, when executed by a computer to decode video, cause the computer to perform any one or a combination of video decoding methods.BRIEF DESCRIPTION OF THE DRAWINGS

[0025] Additional features, nature and various advantages of the disclosed subject matter will be more clearly understood from the following detailed description and the accompanying drawings, which show the following.

[0026] Fig. 1A shows approximate positions of spatial fusion candidates.

[0027] Fig. 1B shows the candidate pairs considered for the redundancy test of spatial fusion candidates.

[0028] Fig. 1C shows an example of motion vector scaling for a temporary fusion candidate.

[0029] Fig. 1D shows exemplary positions for a temporary merger candidate.

[0030] Fig. 2 is a schematic illustration of a simplified block diagram of a communication system according to an embodiment.

[0031] Fig. 3 is a schematic illustration of a simplified block diagram of a communication system according to an embodiment.

[0032] Fig. 4 shows a schematic illustration of a simplified block diagram of a decoder according to an embodiment.

[0033] Fig. 5 is a schematic illustration of a simplified block diagram of an encoder according to an embodiment.

[0034] Fig. 6 shows a block diagram of an encoder according to another embodiment.

[0035] Fig. 7 shows a block diagram of a decoder according to another embodiment.

[0036] Fig. 8A and 8B show two exemplary triangular sections according to some embodiments.

[0037] Fig. 9 shows a single prediction motion vector selection for a triangular partition mode according to some embodiments.

[0038] Fig. 10A and 10B show exemplary weight maps for luminance and chrominance according to some embodiments.

[0039] Fig. 11 shows an exemplary geometric separation mode according to some embodiments of the invention.

[0040] Fig. 12 is a flowchart describing an exemplary process according to an embodiment.

[0041] Fig. 13 is a schematic illustration of a computer system according to an embodiment.EMBODIMENT OF THE INVENTION

[0042] The present disclosure includes embodiments directed to a geometric fusion mode (GEO), which may also be referred to as a geometric partition mode (GPM). The embodiments include methods, devices, and non-transitory computer-readable media for improving GEO. Furthermore, a block may refer to a prediction block, a coding block, or a coding unit.

[0043] I. Video encoder and decoder

[0044] Fig. 2 illustrates a simplified block diagram of a communication system (200) according to an embodiment of the present invention. The communication system (200) includes a plurality of end devices that can communicate with each other, for example, via a network (250). For example, the communication system (200) includes a first pair of end devices (210) and (220) connected to each other via a network (250). In the example of Fig. 2, the first pair of end devices (210) and (220) perform unidirectional data transmission. For example, an end device (210) can encode video data (for example, a stream of video images that are captured by the end device (210)) for transmission to another end device (220) via a network (250). The encoded video data can be transmitted in the form of one or more encoded video bitstreams.The end device (220) can receive encoded video data from the network (250), decode the encoded video data to reconstruct video images, and display video images according to the reconstructed video data. Unidirectional data transmission can be common in multimedia serving applications, etc.

[0045] In another example, the communication system (200) includes a second pair of end devices (230) and (240) that perform bidirectional transmission of encoded video data, which can occur, for example, during a video conference. For bidirectional data transmission, in an example, each end device of the end devices (230) and (240) can encode video data (for example, a stream of video images that are captured by the end device) for transmission to another end device of the end devices (230) and (240) via a network (250). Each end device of the end devices (230) and (240) can also receive encoded video data transmitted by the other end device of the end devices (230) and (240), and can decode the encoded video data to restore video images and can display video images on an available display device in accordance with the restored video data.

[0046] In the example of Fig. 2, the terminal devices (210), (220), (230) and (240) can be illustrated as servers, personal computers and smartphones, but the principles of the present disclosure cannot be limited to this. Embodiments of the present invention find application in laptop computers, tablet computers, media players and / or specialized equipment for videoconferencing. The network (250) is any number of networks that transmit encoded video data between the terminal devices (210), (220), (230) and (240), including, for example, wired (connected by wires) and / or wireless communication networks. The communication network (250) can exchange data in circuit-switched and / or packet-switched channels. Representative networks include telecommunication networks, local networks, global networks and / or the Internet.For the purposes of this description, the architecture and topology of the network (250) may be immaterial to the operation of the present invention unless explained below in this document.

[0047] Fig. 3 illustrates, as an example of application for the disclosed subject matter, the placement of a video encoder and video decoder in a streaming environment. The disclosed subject matter may be equally applicable to other video-enabled applications, including, for example, videoconferencing, digital television, storage of compressed video on digital media, including CDs, DVDs, memory cards, and the like.

[0048] The streaming system may include a capture subsystem (313), which may include a video source (301), such as a digital camera, creating, for example, a stream of video images (302) that are not compressed. In an example, the video image stream (302) includes samples captured by the digital camera. The video image stream (302), depicted with a thick line to emphasize the large amount of data compared to the encoded video data (304) (or encoded video bitstreams), can be processed by an electronic device (320), which includes a video encoder (303) connected to the video source (301). The video encoder (303) may include hardware, software, or a combination thereof to include or implement aspects of the disclosed subject matter, as described in more detail below.The encoded video data (304) (or the encoded video bitstream (304)), depicted in a thin line to emphasize the smaller amount of data compared to the video image stream (302), can be stored on the streaming server (305) for future use. One or more client streaming subsystems, such as the client subsystems (306) and (308) in Fig. 3, can access the streaming server (305) to retrieve copies (307) and (309) of the encoded video data (304). The client subsystem (306) can include a video decoder (310), for example, in an electronic device (330). The video decoder (310) decodes the incoming copy (307) of the encoded video data and creates an outgoing stream of video images (311), which can be rendered on a display (312) (for example, a display screen) or another rendering device (not shown).In some streaming systems, encoded video data (304), (307), and (309) (e.g., video bitstreams) may be encoded according to certain video coding / compression standards. Examples of these standards include ITU-T Recommendation H.265. In one example, an emerging video coding standard is informally known as Versatile Video Coding (VVC). The disclosed subject matter can be used in the context of VVC.

[0049] It should be noted that the electronic devices (320) and (330) may include other components (not shown). For example, the electronic device (320) may include a video decoder (not shown), and the electronic device (330) may also include a video encoder (not shown).

[0050] Fig. 4 shows a block diagram of a video decoder (410) according to an embodiment of the present disclosure. The video decoder (410) may be included in an electronic device (430). The electronic device (430) may include a receiver (431) (e.g., a receiving circuit). The video decoder (410) may be used instead of the video decoder (310) in the example of Fig. 3.

[0051] The receiver (431) can receive one or more coded video sequences to be decoded by the video decoder (410); in the same or another embodiment, one coded video sequence at a time, where the decoding of each coded video sequence does not depend on other coded video sequences. The coded video sequence can be received from the channel (401), which can be a hardware / software connection with a storage device in which the coded video data is stored. The receiver (431) can receive the coded video data with other data, such as coded audio data and / or auxiliary data streams, which can be sent to their respective using entities (not shown). The receiver (431) can separate the coded video sequence from the other data.To combat network jitter, a buffer memory (415) may be connected between the receiver (431) and the entropy decoder / parser (420) (hereinafter referred to as the "parser (420)"). In some applications, the buffer memory (415) is part of the video decoder (410). In other cases, it may be located outside the video decoder (410) (not shown). In other cases, there may be a buffer memory (not shown) outside the video decoder (410), for example, to combat network jitter, and, in addition, another buffer memory (415) inside the video decoder (410), for example, to handle playback time. When the receiver (431) receives data from a store / forward device with sufficient bandwidth and controllability or from an isosynchronous network, the buffer memory (415) may not be needed or may be small.For use in high quality packet networks such as the Internet, a buffer memory (415) may be required, which may be relatively large and may preferably be adaptive in size, and may be at least partially implemented in an operating system or similar elements (not shown) outside the video decoder (410).

[0052] The video decoder (410) may include a parser (420) for recovering symbols (421) from the encoded video sequence. The categories of these symbols include information used to control the operation of the video decoder (410) and potentially information for controlling a rendering device, such as a rendering device (412) (e.g., a display screen), which is not an integral part of the electronic device (430), but may be connected to the electronic device (430), as shown in Fig. 4. The control information for the rendering device(s) may be in the form of fragments of a set of additional extended information parameters (SEI messages) or video suitability information (VUI) (not shown). The parser (420) may parse / entropy decode the received encoded video sequence.The encoding of the encoded video sequence may be performed in accordance with a video encoding technology or standard and may follow various principles, including variable-length encoding, Huffman encoding, arithmetic encoding with or without context sensitivity, and so on. The parser (420) may extract from the encoded video sequence a set of subgroup parameters for at least one of the pixel subgroups in the video decoder based on at least one parameter corresponding to the group. Subgroups may include groups of pictures (GOPs), pictures, tiles, slices, macroblocks, coding units (CUs), blocks, transform units (TUs), prediction units (PUs), and so on. The parser (420) may also extract from the encoded video sequence information such as transform coefficients, quantizer parameter values, motion vectors, and so on.

[0053] The parser (420) can perform entropy decoding / parsing operation on the video sequence received from the buffer memory (415) to produce symbols (421).

[0054] Symbol recovery (421) may involve multiple different modules depending on the type of encoded video image or its parts (such as inter- and intra-image, inter- and intra-block) and other factors. Which modules are involved and how can be controlled using subgroup control information parsed from the encoded video sequence by the parser (420). The flow of such subgroup control information between the parser (420) and the multiple modules below is not shown for clarity.

[0055] In addition to the functional blocks already mentioned, the video decoder (410) can be conceptually subdivided into a number of functional modules, as described below. In a practical implementation operating under commercial constraints, many of these modules closely interact with each other and can be, at least partially, integrated into each other. However, for the purposes of describing the disclosed subject matter, the conceptual subdivision into functional modules given below is appropriate.

[0056] The first module is the scaling / inverse transform module (451). The scaling / inverse transform module (451) receives the quantized transform coefficient and control information, including which transform to use, block size, quantization coefficient, quantization scaling matrices, and so on, in the form of symbol(s) (421) from the parser (420). The scaling / inverse transform module (451) can output blocks containing sample values, which can be input to the aggregator (455).

[0057] In some cases, the output samples of the scaling / inverse transform module (451) may relate to an intra-coded block; that is, to a block that does not use prediction information from previously reconstructed images, but may use prediction information from previously reconstructed portions of the current image. Such prediction information may be provided by the intra-frame prediction module (452). In some cases, the intra-frame prediction module (452) generates a block of the same size and shape as the block being reconstructed, using surrounding already reconstructed information retrieved from the current picture buffer (458). The current picture buffer (458) buffers, for example, a partially reconstructed current image and / or a fully reconstructed current image.The aggregator (455) in some cases adds for each sample the prediction information generated by the intra-prediction module (452) to the output sample information provided by the scaling / inverse transform module (451).

[0058] In other cases, the output samples of the scaling / inverse transform module (451) may relate to an inter-coded block and potentially a motion-compensated block. In such a case, the motion-compensated prediction module (453) may access the reference picture memory (457) to retrieve the samples used for prediction. After motion compensation of the selected samples in accordance with the symbols (421) related to the block, these samples may be added by the aggregator (455) to the output of the scaling / inverse transform module (451) (herein referred to as residual samples or a residual signal) to generate information about the output samples.The addresses in the reference image memory (457), from which the motion compensation prediction module (453) selects prediction samples, may be controlled by motion vectors accessible to the motion compensation prediction module (453) in the form of symbols (421), which may have, for example, X, Y, and reference image components. Motion compensation may also include interpolation of sample values ​​retrieved from the reference image memory (457), when precise sub-sample motion vectors, motion vector prediction mechanisms, and so on are used.

[0059] The output samples of the aggregator (455) may be subjected to various in-loop filtering methods in the in-loop filter module (456). Video compression technologies may include in-loop filtering technologies that are controlled by parameters included in the encoded video sequence (also called the encoded video bitstream) and provided to the in-loop filter module (456) as symbols (421) from the parser (420), but may also respond to metainformation obtained during decoding of previous (in decoding order) portions of the encoded image or encoded video sequence, as well as respond to previously reconstructed and loop-filtered sample values.

[0060] The output signal of the loop filter module (456) may be a sample stream that can be output to a visualization device (412) and also stored in a reference image memory (457) for use in future inter-frame prediction.

[0061] Certain encoded images after full reconstruction can be used as reference images for future prediction. For example, after the encoded image corresponding to the current image is fully reconstructed and the encoded image has been identified as a reference image (e.g., by the parser (420)), the current image buffer (458) can become part of the reference image memory (457), and the buffer of the fresh current image can be reallocated before starting to reconstruct the next encoded image.

[0062] The video decoder (410) may perform decoding operations according to a predetermined video compression technology in a standard, such as ITU-T Recommendation H.265. The encoded video sequence may conform to the syntax defined by the video compression technology or standard used, in the sense that the encoded video sequence conforms to both the syntax of the video compression technology or standard and the profiles documented in the video compression technology or standard. In particular, a profile may select certain tools as the only tools available for use in this profile, from all the tools available in the video compression technology or standard. Conformance may also require that the complexity of the encoded video sequence be within the boundaries defined by the level of the video compression technology or standard.In some cases, levels limit the maximum image size, maximum frame rate, maximum reconstruction sampling rate (measured, for example, in megasamples per second), maximum reference image size, and so on. The limits set by levels can in some cases be further constrained by the specifications of a hypothetical reference decoder (HRD) and HRD buffer management metadata signaled in the encoded video sequence.

[0063] In an embodiment, the receiver (431) can receive additional (redundant) data with the encoded video. The additional data can be included as part of the encoded video sequence(s). The additional data can be used by the video decoder (410) to correctly decode the data and / or to more accurately reconstruct the original video data. The additional data can be in the form of, for example, temporal, spatial or signal-to-noise ratio (SNR) improvement layers, redundant slices, redundant images, forward error correction codes, and so on.

[0064] Fig. 5 shows a block diagram of a video decoder (503) according to an embodiment of the present disclosure. The video encoder (503) is included in an electronic device (520). The electronic device (520) includes a transmitter (540) (e.g., a transmitting circuit). The video encoder (503) can be used instead of the video encoder (303) in the example of Fig. 3.

[0065] The video encoder (503) may receive video samples from a video source (501) (which is not part of the electronic device (520) in the example of Fig. 5), which may capture video image(s) for encoding by the video encoder (503). In another example, the video source (501) is part of the electronic device (520).

[0066] The video source (501) may provide a source video sequence for encoding by the video encoder (503) in the form of a digital stream of video samples, which may have any suitable bit depth (for example: 8 bits, 10 bits, 12 bits, ...), any color space (for example, BT.601 Y CrCb, RGB, ...) and any suitable sampling structure (for example, Y CrCb 4:2:0, Y CrCb 4:4:4). In a multimedia serving system, the video source (501) may be a storage device storing pre-prepared video. In a videoconferencing system, the video source (501) may be a camera that captures local image information in the form of a video sequence. The video data may be provided as a plurality of individual images that convey motion when viewed sequentially.The images themselves can be organized as a spatial array of pixels, in which each pixel can contain one or more samples depending on the sampling structure used, the color space, etc. A person skilled in the art can easily understand the relationship between pixels and samples. The description below focuses on samples.

[0067] According to an embodiment, the video encoder (503) can encode and compress images of the original video sequence into the encoded video sequence (543) in real time or with any other time constraints, as required by the application. Ensuring an appropriate encoding rate is one of the functions of the controller (550). In some embodiments, the controller (550) controls other functional modules, as described below, and is functionally connected to the other functional modules. The connection is not shown for clarity. The parameters set by the controller (550) can include parameters related to rate control (picture skip, quantizer, lambda value of rate-distortion optimization methods, ...), picture size, group of pictures (GOP) layout, maximum allowable reference area of ​​the motion vector, and so on.The controller (550) may be configured to have other suitable functions that relate to a video encoder (503) optimized for a particular system design.

[0068] In some embodiments, the video encoder (503) is configured to operate in a coding loop. As a simplified description, in an example, the coding loop may include a source encoder (530) (e.g., responsible for generating symbols, such as a symbol stream, based on an input picture to be encoded and a reference picture(s), as well as a (local) decoder (533) built into the video encoder (503). The decoder (533) reconstructs the symbols to generate sample data in a similar way as a (remote) decoder can also generate (since any compression between the symbols and the encoded video bitstream is lossless in the video compression technologies considered in the disclosed subject matter). The reconstructed sample stream (sample data) is input into a reference picture memory (534).Because decoding a symbol stream produces bit-accurate results, regardless of the decoder's location (local or remote), the contents of the reference picture memory (534) are also bit-accurate between the local encoder and the remote encoder. In other words, the encoder's prediction portion "sees" as reference picture samples exactly the same sample values ​​that the decoder would "see" if using prediction during decoding. This fundamental principle of reference picture synchronicity (and the resulting drift if synchronicity cannot be maintained, for example, due to channel errors) is also used in some related fields of technology.

[0069] The operation of the "local" decoder (533) may be the same as that of a "remote" decoder, such as the video decoder (410), which has already been described in detail above in connection with Fig. 4. Briefly referring also to Fig. 4, however, since the symbols are available, and the encoding / decoding of the symbols into the encoded video sequence by the entropy encoder (545) and the parser (420) may be lossless, the entropy decoding parts of the video decoder (410), including the buffer memory (415) and the parser (420), cannot be completely implemented in the local decoder (533).

[0070] At this point, it can be observed that any decoding technology, other than parsing / entropy decoding, present in a decoder must also be present in a substantially identical functional form in the corresponding encoder. For this reason, the disclosed subject matter focuses on the operation of the decoder. The description of the encoding technologies can be abbreviated, as they are inverses of the fully described decoding technologies. Only in certain areas is a more detailed description required, which is provided below.

[0071] During operation, in some examples, the source encoder (530) can perform motion-compensated predictive coding, which encodes the input image with prediction by reference to one or more previously encoded images from the video sequence, which were designated as "reference images." Thus, the coding engine (532) encodes the differences between blocks of pixels of the input image and blocks of pixels of the reference image(s), which can be selected as the prediction reference(s) for the input image.

[0072] The local video decoder (533) can decode the encoded video data of pictures, which can be designated as reference pictures, based on the symbols generated by the source encoder (530). The operations of the encoding engine (532) can preferably be lossy processes. When the encoded video data can be decoded in the video decoder (not shown in Fig. 5), the reconstructed video sequence can usually be a copy of the original video sequence with some errors. The local video decoder (533) copies the decoding processes that can be performed by the video decoder on the reference pictures and can cause the reconstructed reference pictures to be stored in the reference picture cache (534). In this way, the video encoder (503) can locally store copies of the reconstructed reference pictures, which have common content, as reconstructed reference pictures, which will be received by the video decoder at the far end (in the absence of transmission errors).

[0073] The predictor (535) can perform predictive searches for the encoding engine (532). That is, for a new image to be encoded, the predictor (535) can search the reference image memory (534) for sample data (as candidates for blocks of reference pixels) or certain metadata, such as motion vectors of reference images, block shapes, and so on, which can serve as suitable prediction references for new images. The predictor (535) can operate on a block-by-pixel basis of samples to find the corresponding prediction references. In some cases, as determined by the search results obtained by the predictor (535), the input image can have prediction references taken from a plurality of reference images stored in the reference image memory (534).

[0074] The controller (550) can control the encoding operations of the source encoder (530), including, for example, setting parameters and subgroup parameters used for encoding video data.

[0075] The output signals of all the above-mentioned functional modules can be entropy-encoded in the entropy encoder (545). The entropy encoder (545) converts the symbols generated by various functional modules into encoded video sequences by lossless compression of the symbols using technologies such as Huffman coding, variable-length coding, arithmetic coding, and so on.

[0076] The transmitter (540) can buffer the encoded video sequence(s) created by the entropy encoder (545) in order to prepare for transmission via the communication channel (560), which can be a hardware / software connection to a storage device that will store the encoded video data. The transmitter (540) can combine the encoded video data from the video encoder (503) with other data to be transmitted, for example, encoded audio data and / or auxiliary data streams (sources not shown).

[0077] The controller (550) can control the operation of the video encoder (503). During encoding, the controller (550) can assign each encoded image to a specific encoded image type, which can affect the encoding methods that can be applied to the corresponding image. For example, images can often be classified into one of the following image types:

[0078] An intra-picture (I-picture) can be one that can be encoded and decoded without using any other picture in the sequence as a prediction source. Some video codecs allow various types of intra-pictures, including, for example, pictures with independent decoder refresh ("IDR"). Those skilled in the art are familiar with these variants of I-pictures and their respective applications and features.

[0079] A predictive image (P-image) may be one that can be encoded and decoded using intra-prediction or inter-prediction using at most one motion vector and a reference index to predict the sample values ​​of each block.

[0080] A bidirectionally predicted image (B-image) can be encoded and decoded using intra-prediction or inter-prediction using no more than two motion vectors and reference indices to predict the sample values ​​of each block. Similarly, multi-predicted images can use more than two reference images and associated metadata to reconstruct a single block.

[0081] Source images can typically be spatially divided into multiple sample blocks (e.g., blocks of 4x4, 8x8, 4x8, or 16x16 samples each) and encoded on a block-by-block basis. Blocks can be predictively encoded with reference to other (already encoded) blocks, as determined by the coding assignment applied to the corresponding block images. For example, blocks of I-pictures can be predictively encoded without prediction or predictively encoded with reference to already encoded blocks of the same picture (spatial prediction or intra-prediction). Pixel blocks of P-pictures can be predictively encoded via spatial prediction or temporal prediction with reference to a previously encoded reference picture.B-picture blocks may be predictively coded, either by spatial prediction or by temporal prediction with reference to one or two previously coded reference pictures.

[0082] The video encoder (503) may perform encoding operations in accordance with a predetermined video coding technology or standard, such as ITU-T Recommendation H.265. In its operation, the video encoder (503) may perform various compression operations, including predictive encoding operations that exploit temporal and spatial redundancy in the input video sequence. The encoded video data may therefore conform to the syntax specified by the video coding technology or standard used.

[0083] In an embodiment, the transmitter (540) may transmit additional data with the encoded video. The source encoder (530) may include such data as part of the encoded video sequence. The additional data may include temporal / spatial / SNR enhancement layers, other forms of redundant data, such as redundant images and slices, SEI messages, VUI parameter set fragments, and so on.

[0084] Video can be captured as multiple source images (video pictures) in a temporal sequence. Intra-frame prediction (often abbreviated as intra-prediction) exploits spatial correlations within a given picture, while inter-frame prediction exploits (temporal or other) correlations between pictures. In this example, a specific picture, called the current picture, is divided into blocks during encoding / decoding. When a block in the current picture is similar to a reference block in a previously encoded and still buffered reference picture in the video, the block in the current picture can be encoded with a vector, called a motion vector. The motion vector points to a reference block in the reference picture and may have a third dimension identifying the reference picture if multiple reference pictures are used.

[0085] In some embodiments, a bi-prediction method may be used for inter-picture prediction. According to the bi-prediction method, two reference images are used, such as a first reference image and a second reference image, which both precede the current picture in the video in decoding order (but may be in the past and future, respectively, in display order). A block in the current picture may be encoded by a first motion vector that points to the first reference block in the first reference image, and a second motion vector that points to the second reference block in the second reference image. The block may be predicted by a combination of the first reference block and the second reference block.

[0086] In addition, the inter-frame prediction can use the fusion mode method to improve the coding efficiency.

[0087] According to some embodiments of the invention, predictions such as inter-frame predictions and intra-frame predictions are performed in a block unit. For example, in accordance with the HEVC standard, an image in a video sequence is divided into coding tree units (CTUs) for compression, wherein the CTUs in the image have the same size, for example, 64x64 pixels, 32x32 pixels, or 16x16 pixels. In general, a CTU includes three coding tree units (CTUs), which are one luma CTU and two chroma CTUs. Each CTU can be recursively divided by a quadtree into one or more CUs. For example, a CTU of size 64x64 pixels can be divided into one CU of 64x64 pixels, or 4 CUs of 32x32 pixels, or 16 CUs of 16x16 pixels. In the example, each CU is analyzed to determine the prediction type for the CU, such as interprediction type or intraprediction type.A CU is divided into one or more prediction units (PUs) based on temporal and / or spatial predictability. Typically, each PU includes a luma prediction unit (PU) and two chroma PUs. In an embodiment, the prediction operation during encoding (encoding / decoding) is performed in units of prediction units. Using a luma prediction unit as an example of a prediction unit, a prediction unit includes a matrix of values ​​(e.g., luma values) for pixels, such as 8x8 pixels, 16x16 pixels, 8x16 pixels, 16x8 pixels, and the like.

[0088] Fig. 6 shows a diagram of a video encoder (603) according to another embodiment of the disclosure. The video encoder (603) is configured to receive a processing unit (e.g., a prediction unit) from sample values ​​in a current video picture in a sequence of video pictures and encode the processing unit into an encoded picture that is part of the encoded video sequence. In one example, the video encoder (603) is used instead of the video encoder (303) in the example of Fig. 3.

[0089] In the HEVC example, the video encoder (603) receives a matrix of sample values ​​for a processing unit, such as an 8×8 sample prediction unit, etc. The video encoder (603) determines whether the processing unit is best encoded using an intra-mode, an inter-mode, or a bi-prediction mode using, for example, rate-distortion optimization. When the processing unit is to be encoded in the intra-mode, the video encoder (603) can use an intra-prediction method to encode the processing unit into a coded image; and when the processing unit is to be encoded in the inter-mode or bi-prediction mode, the video encoder (603) can use an inter-prediction method or a bi-prediction method, respectively, to encode the processing unit into a coded image.In some video coding technologies, the fusion mode may be a submode of interframe prediction, in which the motion vector is derived from one or more motion vector predictors without benefit of the encoded motion vector component outside the predictors. In some other video coding technologies, a motion vector component applicable to the block in question may be present. In one example, the video encoder (603) includes other components, such as a mode selector (not shown), for determining the mode of processing blocks.

[0090] In the example of Fig. 6, the video encoder (603) includes an inter-coder (630), an intra-coder (622), a residual calculator (623), a switch (626), a residual encoder (624), a common controller (621), and an entropy encoder (625), connected together as shown in Fig. 6.

[0091] The inter-coder (630) is configured to receive samples of a current block (e.g., a processing block), compare the block with one or more reference blocks in reference images (e.g., blocks in previous images and subsequent images), generate inter-prediction information (e.g., a description of redundant information according to an inter-coding method, motion vectors, fusion mode information), and calculate inter-prediction results (e.g., a predicted block) based on the inter-prediction information using any suitable method. In some examples, the reference images are decoded reference images that are decoded based on the encoded video information.

[0092] The intra-coder (622) is configured to receive samples of the current block (e.g., a processing block), in some cases, compare the block with blocks already encoded in the same image, generate quantized coefficients after the transformation, and in some cases also intra-prediction information (e.g., intra-prediction direction information according to one or more intra-coding methods). In one example, the intra-coder (622) also calculates intra-prediction results (e.g., a predicted block) based on the intra-prediction information and reference blocks in the same image.

[0093] The common controller (621) is configured to determine common control data and control other components of the video encoder (603) based on the common control data. In one example, the common controller (621) determines a block mode and supplies a control signal to the switch (626) based on the mode. For example, when the mode is an intra-mode, the common controller (621) controls the switch (626) to select the intra-mode result for use by the residual calculator (623), and controls the entropy encoder (625) to select the intra-prediction information and include the intra-prediction information in the bitstream; and when the mode is an inter-mode, the common controller (621) controls the switch (626) to select the inter-prediction result for use by the residual calculator (623), and controls the entropy encoder (625) to select the inter-prediction information and include the inter-prediction information in the bitstream.

[0094] The residual calculator (623) is configured to calculate the difference (residual data) between the received block and the prediction results selected from the intra-coder (622) or the inter-coder (630). The residual encoder (624) is configured to operate based on the residual data to encode the residual data to generate transform coefficients. In one example, the residual encoder (624) is configured to transform the residual data from the spatial domain to the frequency domain and generate transform coefficients. The transform coefficients are then subjected to quantization processing to obtain quantized transform coefficients. In various embodiments, the video encoder (603) also includes a residual decoder (628). The residual decoder (628) is configured to perform the inverse transform and generate decoded residual data. The decoded residual data can be suitably used by the intra-coder (622) and the inter-coder (630).For example, the inter-coder (630) may generate decoded blocks based on the decoded residual data and inter-prediction information, and the intra-coder (622) may generate decoded blocks based on the decoded residual data and intra-prediction information. The decoded blocks are processed accordingly to generate decoded images, and the decoded images may be buffered in a memory circuit (not shown) and used as reference images in some examples.

[0095] The entropy encoder (625) is configured to format the bitstream to include the encoded block. The entropy encoder (625) is configured to include various information in accordance with a suitable standard, such as the HEVC standard. In one example, the entropy encoder (625) is configured to include common control data, selected prediction information (for example, intra-prediction information or inter-prediction information), residual information, and other suitable information in the bitstream. It should be noted that, according to the disclosed subject matter, when encoding a block in the fusion submode of either the inter-mode or the bi-prediction mode, residual information is absent.

[0096] Fig. 7 shows a diagram of a video decoder (710) according to another embodiment of the disclosure. The video decoder (710) is configured to receive encoded images that are part of an encoded video sequence and to decode the encoded images to create reconstructed images. In one example, the video decoder (710) is used instead of the video decoder (310) in the example of Fig. 3.

[0097] In the example of Fig. 7, the video decoder (710) includes an entropy decoder (771), an inter decoder (780), a residual decoder (773), a restoration module (774), and an intra decoder (772), connected together as shown in Fig. 7.

[0098] The entropy decoder (771) can be configured to recover from the encoded image certain symbols that represent syntax elements that make up the encoded image. Such symbols can include, for example, a mode in which a block is encoded (such as, for example, an intra-mode, an inter-mode, a dual prediction mode, where the latter two are in a fusion sub-mode or another sub-mode), prediction information (such as, for example, intra-prediction information or inter-prediction information), which can identify a certain sample or metadata that is used for prediction by the intra-decoder (772) or the inter-decoder (780), respectively, residual information in the form of, for example, quantized transform coefficients, and the like.In one example, when the prediction mode is an inter-mode or a bidirectional prediction mode, the inter-prediction information is provided to the inter-decoder (780); and when the prediction type is an intra-prediction type, the intra-prediction information is provided to the intra-decoder (772). The residual information may be inversely quantized and provided to the residual decoder (773).

[0099] The inter-decoder (780) is configured to receive inter-prediction information and generate inter-prediction results based on the inter-prediction information.

[0100] The intra decoder (772) is configured to receive intra prediction information and generate prediction results based on the intra prediction information.

[0101] The residual decoder (773) is configured to perform inverse quantization to extract dequantized transform coefficients, and process the dequantized transform coefficients to transform the residual from the frequency domain to the spatial domain. The residual decoder (773) may also require certain control information (to enable the quantizer parameter (QP)), and this information can be provided by the entropy decoder (771) (the data path is not shown since this may only be small-volume control information).

[0102] The restoration module (774) is configured to combine in the spatial domain the residual output by the residual decoder (773) and the prediction results (output by the inter- or intra-prediction modules, as appropriate) to form a restored block, which may be part of a restored image, which, in turn, may be part of a restored video. It should be noted that other suitable operations, such as a deblocking operation, etc., may be performed to improve visual quality.

[0103] It should be noted that the video encoders (303), (503) and (603) and the video decoders (310), (410) and (710) can be implemented using any suitable technique. In an embodiment, the video encoders (303), (503) and (603) and the video decoders (310), (410) and (710) can be implemented using one or more integrated circuits. In another embodiment, the video encoders (303), (503) and (603) and the video decoders (310), (410) and (710) can be implemented using one or more processors that execute software instructions.

[0104] II. Triangular Partition Mode (TPM) for Inter Prediction

[0105] In some cases, TPM may be supported for interpretation. TPM can only be applied to CUs of size 8x8 or larger. TPM can be signaled using a CU-level flag as one type of merging mode, with other merging modes including normal merging mode, MMVD mode, SIR mode, and sub-block merging mode.

[0106] When TPM is used, a CU can be divided uniformly into two triangle-shaped partitions using either a diagonal or anti-diagonal partition, as shown in Figs. 8A and 8B. Each triangular partition in a CU can be predicted using interprediction using its own motion parameters. Only one prediction can be allowed for each partition. That is, each partition has one motion vector and one reference index. The single-prediction motion constraint is applied to ensure that the triangular partition is the same as with conventional bi-prediction. That is, only two motion-compensated predictions are needed for each CU. The single-prediction motion for each partition can be obtained using the process described in Figs. 1A-1D.

[0107] If a TPM is used for the current CU, a flag indicating the TPM direction (diagonal or antidiagonal) and two fusion indices (one for each partition) can be additionally signaled. The maximum TPM candidate size can be explicitly signaled at the slice level and specify the syntax binarization for the TPM fusion indices. After predicting each triangular partition, the sample values ​​along the diagonal or antidiagonal edge can be adjusted using a blending process with adaptive weight values. After obtaining the prediction signal for the entire CU, the transform and quantization process can be further applied to the entire CU, as in other prediction modes. Finally, the CU motion field predicted by the TPM can be stored.

[0108] In some cases, TPM cannot be used in conjunction with sub-block conversion (SBT). That is, when the signaled triangle mode is 1, cu_sbt_flag is considered 0 without signaling.

[0109] The single-prediction candidate list can be directly obtained from the merge candidate list generated by the extended merge prediction process. We denote N as the single-prediction motion index in the single-prediction triangular prediction candidate list. The motion vector LX of the Nth extended merge candidate, where X is equal to the parity of N, is used as the Nth single-prediction motion vector for the TPM. These motion vectors are marked as "X" in Fig. 9. If the corresponding motion vector LX of the Nth extended merge candidate does not exist, the motion vector L(1-X) of the same candidate is used instead of the single-prediction motion vector for the TPM.

[0110] After each triangular partition is predicted using its own motion parameters, a blending process can be applied to the two prediction signals to obtain diagonal or anti-diagonal edge samples. The blending process uses the following weighting values: {7 / 8, 6 / 8, 5 / 8, 4 / 8, 3 / 8, 2 / 8, 1 / 8} for luminance and {6 / 8, 4 / 8, 2 / 8} for chrominance, as shown in Figs. 10A and 10B.

[0111] In some cases, CU motion vectors encoded in the TPM can be generated using the following process. If Mv1 and Mv2 are taken from different reference image lists (e.g., one from L0 and the other from L1), then Mv1 and Mv2 are simply combined to form a dual-prediction motion vector. Otherwise, if Mv1 and Mv2 are from the same list, only the single-prediction motion vector Mv2 is retained.

[0112] III. Geometric Fusion Mode (GEO)

[0113] Geometric Fusion Mode (GEO), also known as Geometric Partition Mode (GPM), can support a variety of different partitioning methods. Partitioning methods can be defined by corners and edges. For example, 140 different partitioning methods can be distinguished by 32 corners (quantized from 0 to 360° with an equal separation of 11.25°) and 5 edges relative to the CU center.

[0114] Fig. 11 shows an approximate GEO. In Fig. 11, the angle ϕ i represents a quantized angle between 0 and 360 degrees, and the distance offset ρ i represents the quantized displacement of the largest distance ρ max . The value of ρ max can be obtained geometrically using equation 1 for aw or h, which is equal to 8 and scaled by the log2 scaled length of the short edge. The variables h and w represent the height and width of the current block. When ϕ is 0°, ρ max is equal to w / 2. When ϕ is 90°, ρ max is equal to h / 2. In equation 1, ρ margin=1.0 prevents the split border from being too close to the corner of the current block.

[0115] Each partition mode (i.e., a pair of corner index and edge index) in GEO can be assigned a pixel-adaptive weight table to blend samples in the two partitions. The sample weight value can range from, for example, 0 to 8 and is determined by the L2 distance from the pixel's center position to the edge. When assigning weight values, a per-unit increment limit can be observed. For example, when a small weight value is assigned to a GEO partition, a large additional weight is assigned to the other partition, for a total of 8.

[0116] IV. Weighted Count Prediction Process for GEO

[0117] In GEO, the final predictor P ВThe sample can be obtained using two 3-bit mixing masks (i.e. weight values ​​or weight coefficients) W0 and W1 and two predictors P0 and P1 according to equation 2.

[0118] The blending masks W0 and W1 can be obtained from the lookup table based on their weight indices. The weight index can be obtained based on the distance between the sample position (x, y) and the splitting boundary, as shown in Equation 3. Where

[0119] In Equation 4, n represents the quantization steps of the total distance, ai represents the distance step index for the GEO with angle ϕ, and i <n.

[0120] Finally, the mixing masks W0 and W1(or weight values) of the sample can be set using Table 3, denoted as GeoFilter, as shown in Equation 5.

[0121] An example weighted sample prediction process is described as follows. The inputs to this process include two variables nCbW and nCbH, which define the width and height of the current coding block, two (nCbW)×(nCbH) arrays predSamplesLA and predSamplesLB, a variable angleIdx, which defines the angle index of the geometric partition, a variable distanceIdx, which defines the distance idx of the geometric partition, and a variable cIdx, which defines the color component index. The outputs of this process include an array of (nCbW)×(nCbH) pbSamples prediction sample values ​​and an (nCbW>>2)×(nCbH>>2) array motionIdx.

[0122] The bitDepth variable can be obtained as follows: if cIdx=0, bitDepth=BitDepthY; otherwise, bitDepth=BitDepthC.

[0123] Variables shift1=Max(5, 17-bitDepth) and offset1=1<<(shift1-1).

[0124] An array of weights sampleWeightL[x][y] for luma and sampleWeightC[x][y] for chroma with x=0..nCbW-1 and y=0..nCbH-1 can be obtained as follows:

[0125] Variables wIdx=log2(nCbW) and hIdx=log2(nCbH).

[0126] Variable whRatio=(wIdx>=hIdx)?wIdx-hIdx:hIdx wIdx, scaleIdx=(wIdx>=hIdx)?hIdx-3:wIdx-3.

[0127] Variables displacementX=angleIdx and displacementY=(displacementX+8)%32.

[0128] Variable angle N=(wIdx>=hIdx)?(angleIdx>>3&l)?angleIdx%8:8-angleIdx%8:(angleIdx>>3&1)?8-angleIdx%8:angleIdx%8.

[0129] The variable rho can be set, using lookup tables, to the following value, designated as stepDis and Dis, specified in Table 1 and Table 2. rho=distanceIdx*(stepDis[whRatio][angleN]< <scaleIdx)+(Dis[displacementX]<<wIdx)+(Dis[displacementY]<<hIdx).

[0130] The variables weightIdx and weightIdxAbs can be calculated using lookup table 2 with x=0..nCbW-1 and y=0…nCbH-1. weightIdx=((x<<1)+1)*Dis[displacementX]+((y<<1)+1))*Dis[displacementY]-rho. weightIdxAbs=Clip3(0.26, (abs(weightIdx)+4)>>3).

[0131] The variable partIdx can be set to weightIdx>0 if x=0 and y=nCbH-1.

[0132] The value of sampleWeightL[x][y] with x=0..nCbW-1 and y=0..nCbH-1 can be set according to Table 3, denoted as GeoFilter. sampleWeightL[x][y]=weightIdx<=0?GeoFilter[weightIdxAbs]:8-GeoFilter[weightIdxAbs].

[0133] The value of sampleWeightC[x][y] with x=0..nCbW 1 and y=0..nCbH-1 can be set as follows: sampleWeightC[x][y]=sampleWeightL[(x<<(SubWidthC-1))][(y<<(SubHeightC-1))].

[0134] In order to reduce the storage requirements of pre-calculated mixing masks, the minimum mixing mask storage method can achieve a reduction in the memory requirements for storing mixing weights by 84-91%.

[0135] Let g_sampleWeight L [] represents the predefined masks for the mixing weights. Assuming N is the number of predefined masks in each set, and N is set to NA>>1, where NA is the number of angles supported in GEO. M×M represents the size of the predefined masks for the mixing weights, and M is set to 128+((ND-1)×(128>>S))<<1, where ND is the number of steps supported in GEO, and S is set to ND-1. For 32 angles with 5-step setting, N is set to 16 and M is set to 192. For 24 angles with 4-step setting, N is set to 12 and M is set to 224.

[0136] For a block of size W×H with geometric partition index K, the blending weights for the luminance samples are obtained as follows. The angle ϕ and distance ρ variables are obtained from the lookup table using the geometric partition index K. The offsetX and offsetY variables can be calculated as follows:

[0137] An example process for predicting a weighted sample with storing the minimum blending weight mask for GEO is described as follows. The input data for this process includes two variables nCbW and nCbH, defining the width and height of the current coding block, two (nCbW)×(nCbH) arrays predSamplesLA and predSamplesLB, a variable angleIdx, defining the angle index of the geometric partition, a variable distancIdx, defining the distance idx of the geometric partition, and a variable cIdx, defining the color component index. The output data of this process includes an array pbSamples (nCbW)×(nCbH) of prediction sample values ​​and a variable partIdx.

[0138] The bitDepth variable can be obtained as follows: if cIdx=0, bitDepth=BitDepthY; otherwise, bitDepth=BitDepthC.

[0139] Variables shift1=Max(5, 17-bitDepth) and offset1=1<<(shift1-1).

[0140] An array of weights sampleWeightL[x][y] for luma and sampleWeightC[x][y] for chroma with x=0..nCbW-1 and y=0..nCbH-1 can be obtained as follows:

[0141] Variable hwRatio=nCbH / nCbW.

[0142] Variables displacementX=angleIdx and displacementY=(displacementX+8)%32.

[0143] Variable partIdx=(angleIdx>=13&& angleIdx<=27) ? 1:0.

[0144] The variable rho can be set to the following value using lookup table 2. rho=(Dis[displacementX]<<8)+(Dis[displacementY]<<8).

[0145] If ​​one of the following conditions is true, the variable shiftHor=0: (1) angleIdx%16=8; and (2) angleIdx%16!=0 and hwRatio≥1. Otherwise, shiftHor=1.

[0146] If shiftHor=0, offsetX=(256-nCbW)>>1, offsetY=(256-nCbH)>>1+angleIdx<16?(distanceIdx*nCbH)>>3: - ((distanceIdx*nCbH)>>3).

[0147] Otherwise, if shiftHor=1, offsetX=(256-nCbW)>>1+angleIdx<16?(distanceIdx*nCbW)>>3:-((distanceIdx*nCbW)>>3), offsetY=(256-nCbH)>>1.

[0148] The variables weightIdx and weightIdxAbs can be calculated using lookup table 2 with x=0..nCbW-1 and y=0..nCbH-1 as follows: weightIdx=(((x+offsetX)<<1)+1)*Dis[displacementX]+(((y+offsetY)<<1)+1))*Dis[displacementY]-rho, weightIdxAbs=Clip3(0, 26, abs (weightIdx)).

[0149] The value of sampleWeightL[x][y] with x=0..nCbW-1 and y=0..nCbH-1 can be set according to Table 3, denoted as GeoFilter. sampleWeightL[x][y]=weightIdx<=0?GeoFilter[weightIdxAbs]:8-GeoFilter[weightIdxAbs].

[0150] The value of sampleWeightC[x][y] with x=0..nCbW-1 and y=0..nCbH-1 can be set as follows: sampleWeightC[x][y]=sampleWeightL[(x<<(SubWidthC-1))][(y<<(SubHeightC-1))].

[0151] V. Process of saving the motion vector for GEO

[0152] In some cases, the weights of the luminance samples at the four corners of a 4x4 motion storage unit can be summed. The sum can be compared with two thresholds to determine whether one of the two types of motion information—single-prediction and dual-prediction—is stored. Dual-prediction motion information can be obtained using the same process as TPM.

[0153] The approximate process of storing the motion vector for GEO is described as follows.

[0154] ​​The motionIdx[xSbIdx][ySbIdx] array with xSbIdx=0..(nCbW>>2)-1 and ySbIdx=0..(nCbH>>2)-1 can be obtained as follows:

[0155] Переменные threshScaler=(wIdx+hIdx)>>1)-1, threshLower=32>>threshScaler, threshUpper=32-threshLower, Cnt=sampleWeightL[(xSbIdx<<2)][(ySbIdx<<2)]+sampleWeightL[(xSbIdx<<2)+3][(ySbIdx<<2)]+sampleWeightL[(xSbIdx<<2)][(ySbIdx<<2)+3]+sampleWeightL[(xSbIdx<<2)+3][(ySbIdx<<2)+3], Cnt=partIdx?32-Cnt:Cnt, motionIdx[xSbIdx][ySbIdx]=Cnt<=threshLower?0:Cnt>=threshUpper?1:2.

[0156] Если the merge_geo_flag[xCb][yCb]=1, sType=motionIdx[xSbIdx][ySbIdx] with xSbIdx=0..numSbX-1, and ySbIdx=0..numSbY-1.

[0157] In some cases, the motion vector storage process is further simplified. The distance between the center position of a 4x4 motion storage unit and the partition boundary can be calculated and compared with a fixed threshold to determine whether single-prediction or dual-prediction motion information is stored for the 4x4 motion storage unit. The sign of the distance indicates which single-prediction motion information should be stored in the case of single-prediction storage. The dependence of the blend mask on motion storage can be removed.

[0158] If merge_geo_flag[xCb][yCb]=1, wIdx=log2(cbWidth), hIdx=log2(cbHeight), whRatio=(wIdx >= hIdx)?wIdx-hIdx:hIdx-wIdx, scaleIdx=(wIdx>=hIdx)?hIdx-3:wIdx-3, displacementX=angleIdx, displacementY=(displacementX+8)%32, angleN=(wIdx>=hIdx)?(angleIdx>>3&1)?angleIdx% 8:8-angleIdx%8:(angleIdx>>3&1)?8-angleIdx%8:angleIdx%8.

[0159] The variable rho can be set, using lookup tables, to the following value, designated as stepDis and Dis, specified in Table 1 and Table 2.rho=distanceIdx*(stepDis[whRatio][angleN]< <scaleIdx)+(Dis[displacementX]<<wIdx)+(Dis[displacementY]<<hIdx).

[0160] The motionOffset variable is set, using lookup tables, to the next value, designated as Dis, specified in Table 1 and Table 2. motionOffset=3*Dis[displacementX]+3*Dis[displacementY].

[0161] The variable motionIdx is calculated using lookup table 2 as follows: motionIdx=((xSbIdx<<3)+1)*Dis[displacementX]+((xSbIdx<<3)+1))*Dis[displacementY]-rho+motionOffset.

[0162] The sType variable is obtained as follows: if partIdx=1, sType=abs(motionIdx)<256?2:motionIdx<=0?1:0; otherwise, sType=abs(motionIdx)<256?2:motionIdx<=0?0:1.

[0163] In order to reduce the memory required to store motion field storage masks, all information from a predefined mask can be obtained for motion field storage masks in a process. This process is called when decoding a coding unit with MergeWedgeFlag[xCb][yCb]=1. The input to this process includes the luma location (xCb, yCb) specifying the upper-left sample of the current coding unit relative to the upper-left luma sample of the current image, the variable cbWidth specifying the width of the current coding unit in luma samples, the variable cbHeight specifying the height of the current coding unit in luma samples, the luma motion vectors with 1 / 16th sample precision mvA and mvB, the reference indices refIdxA and refIdxB, and the prediction list flags predListFlagA and predListFlagB.

[0164] The variables numSbX and numSbY, which determine the number of 4x4 blocks in the current coding block horizontally and vertically, are set to numSbX=cbWidth>>2 and numSbY=cbHeight>>2.

[0165] Variables displacementX=angleIdx, displacementY=(displacementX+8)%32, hwRatio=nCbH / nCbW.

[0166] If one of the following conditions is true, the variable shiftHor=0: (1) angleIdx%16=8; and (2) angleIdx%16!=0 and hwRatio≥1. Otherwise, shiftHor=1.

[0167] Variable partIdx=(angleIdx>=13&&angleIdx<=27)?1:0.

[0168] If shiftHor=0, offsetX=(64-numSbX)>>1, offsetY=(64-numSbY)>>1+angleIdx<16?(distanceIdx*nCbH)>> 5:-((distanceIdx*nCbH)>>5). Otherwise, if shiftHor=1, offsetX=(64-numSbX)>>1+angleIdx<16?(distanceIdx*nCbW)>>5:-((distanceIdx*nCbW)>>5), offsetY=(64 numSbY)>>1.

[0169] The value of the variable rho is output according to the equation below and the Dis reference table specified in Table 2. rho=(Dis[displacementX]<<8)+(Dis[displacementY]<<8).

[0170] The motionOffset variable is set to the following value using lookup tables, denoted as Dis, specified in Table 1 and Table 2. motionOffset=3*Dis[displacementX]+3*Dis[displacementY].

[0171] For each 4×4 sub-block with sub-block index (xSbIdx, ySbIdx) with xSbIdx=0..numSbX-1 and ySbIdx=0..numSbY-1, the variable motionIdx is calculated using look-up table 2 as follows: motionIdx=(((xSbIdx+offsetX)<<3)+1)*Dis[displacementX]+(((xSbIdx+offsetY<<3)+1))*Dis[displacementY]-rho+motionOffset.

[0172] VI. On-the-fly calculation of weight index into weight value

[0173] In the above-mentioned weighted counting process for GEO, the transformation of the weight index wIdx(x, y) into the weight value (or weight coefficient) weight(x, y) can be obtained based on the linear function, as shown in Equation 9 Equation 11.

[0174] In the example, maxValue=8, bias=4, and the quantization step size s=1 / 7.2. The fl2intOp operation is used to convert a floating point value to an integer and can be a combination of round, floor, or ceil. A lookup table such as Table 3 provides an example implementation for the above equations.

[0175] However, since different samples may have different input values ​​for the lookup table, multiple copies of the lookup table may be required to perform parallel processing of these samples when using the above equations. Accordingly, the above-mentioned process of weighted sample for GEO is not suitable for hardware and software implementation. To address this problem, this disclosure includes embodiments for computation-based transformation, so that weight values ​​for different samples can be obtained in parallel.

[0176] According to aspects of the disclosure, the transformation of the weight index wIdx(x, y) into the weight value weight(x, y) can be obtained based on an on-the-fly calculation with a right shift operation.

[0177] In some embodiments, the on-the-fly calculation is the sum of the offset value and the weight index wIdx(x, y), and the offset value is a function of the right shift operand. In addition, the offset value may be rounded.

[0178] In the embodiment, the conversion of the weight index wIdx(x, y) into the weight value weight(x, y) can be obtained according to equation 12.

[0179] In equation 12, the offset value is 2 idx2wShiftBit+2 is the exponential function (with base 2) of the right shift operand idx2wShiftBit. In the example, the right shift operand idx2wShiftBit=m+3, and the weight value weight(x, y)=(2 m+5 -wIdx(x, y))>>(m+3). m can represent the number of bits of precision (e.g., 3 or 6) in the cosine table (e.g., table 2) used to calculate the weight index.

[0180] In the embodiment, the conversion of the weight index wIdx(x, y) into the weight value weight(x, y) can be obtained according to equation 13 or equation 14.

[0181] In Equation 13 and Equation 14, the clipping function Clip3() is used to limit the weight value weight(x, y) within a predefined range, such as [0, 8]. In the example, the offset value idx2wOffset is a linear function of the right shift operand idx2wShiftBit, as shown in Equation 15.

[0182] The right shift operand idx2wShiftBit may be the number of precision bits (e.g. 3, 6 or 9) of the cosine table (e.g. Table 2) which is used to calculate the weight index and / or the calculated distance value (e.g. weight index).

[0183] In an embodiment, the weight index may have a sign transformation in accordance with the section index partIdx, as shown in equation 16.

[0184] Accordingly, the weight value can be obtained according to Equation 17 or Equation 18.

[0185] In this example, the partition index partIdx can be set according to the weight index of the lower-left corner of the current block. In another example, the partition index partIdx can be set according to the angle index angleIdx in Equation 19, where T1 and T2 are two threshold values. In one embodiment, T1 = 10 and T2 = 20.

[0186] In this embodiment, the partition index partIdx can be used as a partition definition for different angles. The weight value can be obtained according to Equation 20 and Equation 21.

[0187] In the embodiment, the weight value can be obtained according to equation 22 and equation 23.

[0188] Then the final blending mask of the current block count can be flipped according to the condition of the angle index angleIdx, which is described in Equation 19.

[0189] According to aspects of the disclosure, the transformation of the weight index wIdx(x, y) into the weight value weight(x, y) can be obtained based on a piecewise constant function. The piecewise constant function may include an initial value and a plurality of unit step functions. Among the range of weight values, the initial value may be one of the minimum weight value and the maximum weight value. Furthermore, the number of the plurality of unit step functions may be equal to the total number of weight values ​​minus 1.

[0190] In an embodiment, the weight value weight(x, y) may be obtained from a predetermined initial value smallest Weight and four unit step functions, as shown in equation 24. where v is the weight index, and ω i (v) can be obtained according to equation 25 or equation 26.

[0191] Table 4 shows a rough reference table for mapping weight index to weight value.

[0192] If Equation 24 and Equation 25 are used to represent Table 4, the initial value of smallest Weight=4, and the threshold weight indices C0-C3 can be 4, 11, 18, and 25, respectively.

[0193] If Equation 24 and Equation 26 are used to represent Table 4, the initial value of smallestWeight=4, and the threshold weight indices P0-P3 can be 3, 10, 17, and 24, respectively.

[0194] Table 5 shows another approximate reference table for mapping weight index to weight value.

[0195] If we use Equation 24 and Equation 25 to represent Table 5, the initial value of smallest Weight=4, and the threshold weight indices C0-C3 can be 3, 10, 17, and 26, respectively.

[0196] If we use Equation 24 and Equation 26 to represent Table 5, the initial value of smallestWeight=4, and the threshold weight indices P0-P3 can be 2, 9, 16, and 25, respectively.

[0197] In an embodiment, the weight value weight(x, y) may be obtained from a predetermined initial value largestWeight and four unit step functions, as shown in equation 27. where ω i (v) can be obtained according to equation 28 or equation 29.

[0198] If Equation 27 and Equation 28 are used to represent Table 4, the initial value of largestWeight=8, and the threshold weight indices C0-C3 can be 3, 10, 17, and 24, respectively.

[0199] If we use Equation 27 and Equation 29 to represent Table 4, the initial value of largestWeight=8, and the threshold weight indices P0-P3 can be 4, 11, 18, and 25, respectively.

[0200] If we use Equation 27 and Equation 28 to represent Table 5, the initial value of largestWeight=8, and the threshold weight indices C0-C3 can be 2, 9, 16 and 25, respectively.

[0201] If we use Equation 27 and Equation 29 to represent Table 5, the initial value of largestWeight=8, and the threshold weight indices P0-P3 can be 3, 10, 17, and 26, respectively.

[0202] It should be noted that the relational operators (≥) and (>) yield 1 if the corresponding relation is true and 0 if the corresponding relation is false, as defined in C and C++, for example.

[0203] VII. Block diagram

[0204] Fig. 12 is a flowchart describing an example process (1200) according to an embodiment of the disclosure. In various embodiments, the process (1200) is performed by a processing circuit, such as a processing circuit in terminal devices (210), (220), (230), and (240), a processing circuit that performs functions of a video encoder (303), a processing circuit that performs functions of a video decoder (310), a processing circuit that performs functions of a video decoder (410), a processing circuit that performs functions of an intra-prediction module (452), a processing circuit that performs functions of a video encoder (503), a processing circuit that performs functions of a predictor (535), a processing circuit that performs functions of an intra-encoder (622), a processing circuit that performs functions of an intra-decoder (772), and the like.In some embodiments, the process (1200) is implemented in software instructions, such that when the processing circuit executes the software instructions, the processing circuit executes the process (1200).

[0205] The process (1200) may typically begin at step (S1210), where the process (1200) decodes the prediction information of the current block of the current image in the encoded bitstream. The prediction information indicates the geometric partition mode (GPM) for the current block. The current block is divided into two partitions in the GPM mode. Each partition is associated with a corresponding predictor. Then, the process (1200) proceeds to step (S1220).

[0206] In step (S1220), the process (1200) determines the weight index for the current block count based on the count position. Then, the process (1200) proceeds to step (S1230).

[0207] In step (S1230), the process (1200) calculates a weight coefficient based on the reference weight index according to an equation that converts the weight index into a weight coefficient. Then, the process (1200) proceeds to step (S1240).

[0208] In step (S1240), the process (1200) restores the count based on the weight coefficient and predictor corresponding to the count. After restoring the count, the process (1200) ends.

[0209] In this embodiment, a right shift operation is performed on the sum of the weight index and the offset value. The result of the right shift operation is truncated to a predetermined range.

[0210] In an embodiment, the offset value is based on the number of bits shifted by the right shift operation, and the number of bits shifted by the right shift operation is based on at least one of a weight index and a size of a cosine table used to calculate the weight index.

[0211] In this embodiment, the angle index and distance index, which define the division boundary between sections of the current block, are determined based on the GPM. The weight index for a reference is determined based on the reference position, angle index, and distance index.

[0212] In this embodiment, a partition index is determined based on an angle index. A weighting coefficient is calculated based on the partition index.

[0213] In the embodiment, the equation is Where where idx2wShiftBit specifies the number of bits shifted by the right shift operation, partIdx is the partition index, and wIdx is the weight index.

[0214] In an embodiment, the equation is a piecewise constant function that includes an initial value and a plurality of unit step functions. The initial value is one of the minimum value of the weight coefficient or the maximum value of the weight coefficient, and the number of the plurality of unit step functions is equal to the total number of different values ​​of the weight coefficients minus one.

[0215] VIII. Computer system

[0216] The methods described above may be implemented as computer software using machine-readable instructions and physically stored on one or more machine-readable media. For example, Fig. 13 shows a computer system (1300) suitable for implementing certain embodiments of the disclosed subject matter.

[0217] The computer software may be encoded using any suitable machine code or computer language that can be subject to assembly, compilation, linking, or similar mechanisms to produce code containing instructions that can be executed directly or through interpretation, microcode execution, etc., by one or more computer central processing units (CPUs), graphics processing units (GPUs), etc.

[0218] The instructions can be executed on various types of computers or their components, including, for example, personal computers, tablet computers, servers, smartphones, gaming devices, Internet of Things devices, etc.

[0219] The components shown in Fig. 13 for the computer system (1300) are exemplary in nature and are not intended to suggest any limitations with respect to the scope of use or functionality of the computer software implementing embodiments of the present disclosure. The configuration of the components also should not be interpreted as having any dependency or requirement related to any one or combination of components illustrated in the exemplary embodiment of the computer system (1300).

[0220] The computer system (1300) may include certain human-machine interface input devices. Such a human-machine interface input device may respond to input from one or more human users through, for example, tactile input (e.g., keystrokes, swipes, movements of a control glove), audio input (e.g., voice, hand claps), visual input (e.g., gestures), olfactory input (not shown). Human-machine interface devices may also be used to capture certain media that are not necessarily directly related to conscious human input, such as sound (e.g., speech, music, ambient sound), images (e.g., scanned images, photographic images obtained from a still image camera), video (e.g., two-dimensional video, three-dimensional video, including stereoscopic video).

[0221] Human interface input devices may include one or more of the following elements (only one of each is shown): keyboard (1301), mouse (1302), trackpad (1303), touch screen (1310), control glove (not shown), joystick (1305), microphone (1306), scanner (1307), camera (1308).

[0222] The computer system (1300) may also include certain human-machine interface output devices. Such human-machine interface output devices may stimulate the senses of one or more human users through, for example, tactile output, sound, light, and smell / taste.Such human-machine interface output devices may include haptic output devices (e.g., haptic feedback from a touch screen (1310), a control glove (not shown), or a joystick (1305), but there may also be haptic feedback devices that do not serve as input devices), audio output devices (e.g., speakers (1309), headphones (not shown)), image output devices (e.g., screens (1310), including CRT screens, LCD screens, plasma screens, OLED screens, each with or without touch screen input capability, each with or without haptic feedback capability - some of which may be capable of outputting two-dimensional visual output or more than three-dimensional output through such means as stereographic output; virtual reality glasses (not shown), holographic displays and smoke tanks (not shown)) and printers (not shown).These visual output devices (such as screens (1310)) can be connected to the system bus (1348) via a graphics adapter (1350).

[0223] The computer system (1300) may also include human-accessible storage devices and associated media such as optical media including CD / DVD ROM / RW (1320) with CD / DVD or similar media (1321), flash drive (1322), removable hard disk or solid state drive (1323), previously developed magnetic media such as tape and floppy disk (not shown), specialized ROM / ASIC / PLD based devices such as security keys (not shown), and the like.

[0224] Those skilled in the art will also understand that the term "machine-readable medium" as used in connection with the subject matter disclosed herein does not include transmission media, carrier waves, or other timing signals.

[0225] The computer system (1300) may also include a network interface (1354) to one or more communication networks (1355). The one or more communication networks (1355) may be, for example, wireless, wired, optical. The one or more communication networks (1355) may further be local, global, metropolitan, automotive and industrial, real-time, delay-tolerant, and so on. Examples of one or more communication networks (1355) include local networks such as Ethernet, wireless LANs, cellular networks including GSM, 3G, 4G, 5G, LTE, and the like, wired television or wireless global digital networks including cable television, satellite television and terrestrial television broadcasting, automotive and industrial equipment including a CAN bus, etc.Some networks typically require external network interface adapters that are connected to specific general-purpose data ports or peripheral buses (1349) (e.g., USB ports of the computer system (1300)); others are typically integrated into the core of the computer system (1300) by connecting to a system bus, as described below (e.g., an Ethernet interface to a PC computer system or a cellular network interface to a smartphone computer system). Using any of these networks, the computer system (1300) can communicate with other entities. Such communication can be unidirectional, for receiving only (e.g., broadcast television), unidirectional for sending only (e.g., a CAN bus to specific CAN bus devices), or bidirectional, for example, to other computer systems using a local or wide area network. Each of these networks and network interfaces can use specific protocols and protocol stacks, as described above.

[0226] The above-mentioned human-machine interface devices, human-accessible storage devices, and network interfaces may be attached to the core (1340) of the computer system (1300).

[0227] The core (1340) may include one or more central processing units (CPUs) (1341), graphics processing units (GPUs) (1342), specialized programmable processors in the form of field-programmable gate arrays (FPGAs) (1343), hardware accelerators (1344) for certain tasks, etc. These devices, along with read-only memory (ROM) (1345), random access memory (1346), internal mass storage such as internal hard drives not accessible to the user, solid-state drives (SSDs), etc. (1347), may be connected via a system bus (1348). In some computer systems, the system bus (1348) may be available as one or more physical slots to provide the ability to expand with additional CPUs, GPUs, etc. Peripherals can be connected either directly to the core's system bus (1348) or via the peripheral bus (1349).Peripheral bus architecture includes PCI, USB, etc.

[0228] The CPU (1341), GPU (1342), FPGA (1343), and accelerators (1344) can execute certain instructions that, when combined, can constitute the aforementioned computer code. This computer code may be stored in ROM (1345) or RAM (1346). Transient data may also be stored in RAM (1346), while persistent data may be stored, for example, in an internal mass storage device (1347). Fast storage and retrieval to any of the storage devices may be permitted through the use of cache memory, which may be tightly coupled to one or more of the CPU (1341), GPU (1342), mass storage device (1347), ROM (1345), RAM (1346), etc.

[0229] The computer-readable medium may contain computer code for performing various computer-implemented operations. The medium and computer code may be specially designed and constructed for the purposes of the present invention, or they may be well known and accessible to those skilled in the art of computer software.

[0230] By way of example, but not limitation, a computer system having an architecture (1300) and, in particular, a core (1340) may provide functionality through a processor(s) (including CPUs, GPUs, FPGAs, accelerators, etc.) executing software embodied on one or more tangible computer-readable media. Such computer-readable media may be media associated with a user-accessible mass storage device, as described above, as well as certain storage of the core (1340), which are non-transitory in nature, such as internal mass storage device (1347) of the core or ROM (1345). Software implementing various embodiments of the present disclosure may be stored in such devices and executed by the core (1340). The computer-readable medium may include one or more memory devices or chips in accordance with specific needs.The software may cause the core (1340) and, in particular, the processors therein (including CPUs, GPUs, FPGAs, etc.) to execute certain processes or certain portions of specific processes described herein, including defining data structures stored in RAM (1346) and modifying such data structures in accordance with the processes defined by the software. In addition or as an alternative, the computer system may provide functionality as a result of logic embedded in hardware or otherwise embodied in the circuit (e.g., an accelerator (1344)), which may operate instead of or in conjunction with software to execute certain processes or certain portions of specific processes described herein. Reference to software may include logic and vice versa, where applicable.Reference to a computer-readable medium may include a circuit (e.g., an integrated circuit (IC)) storing software for execution, a circuit embodying logic for execution, or both, where applicable. The present invention includes any suitable combination of hardware and software.

[0231] While this description discloses several exemplary embodiments, there are modifications, permutations, and various substitution equivalents that fall within the scope of the invention. It will therefore be appreciated that those skilled in the art will be able to devise numerous systems and methods which, although not explicitly shown or described herein, embody the principles of the invention and are thus within the spirit and scope thereof. Appendix A: Abbreviations AMT: Adaptive Multiple Transform MVP: Advanced Motion Vector Prediction ASIC: Application Specific Integrated Circuit ATMVP: Alternative / Advanced Temporal Motion Vector Prediction BDOF: Bidirectional Optical Flow BDPCM (or RDPCM): Residual Difference Pulse Code Modulation BIO: Bidirectional Optical Flow BMS: Test Suite BT: Binary Tree BV: Block Vector CANBus (CAN Bus): Controller Area Network Bus CB: Coding Block CBF: Coded Block Flag CCLM:Cross-Component Linear Mode / ModelCD: Compact DiscCPR: Current Picture ReferenceCPU: Central Processing UnitCRT: Cathode Ray TubeCTB: Coding Tree UnitCTU: Coding Tree UnitCU: Coding UnitDM: Derivative ModeDPB: Decoder Picture BufferDVD: Digital Video DiscEMT: Extended Multiple TransformFPGA: Field-Programmable Gate ArrayGOP: Picture GroupGPU: Graphics Processing UnitGSM: Global System for Mobile CommunicationsHDR: High Dynamic RangeHEVC: High Efficiency Video CodingHRD: Hypothetical Reference DecoderIBC: Intra-Block CopyIC: Integrated CircuitIDT: Transform DefinitionISP: Inter-Sub-SectionsJEM: Joint Research ModelJVET: Joint Video Research TeamLAN: Local Area NetworkLCD: Liquid Crystal DisplayLFNST: Low-Pass Non-Separable Transform or Low-Pass Non-Separable Secondary TransformLTE: long-termevolutionL_CCLM: Left Cross-Component Linear Mode / ModelLT_CCLM: Left and Top Cross-Component Linear Mode / ModelMIP: Matrix-based Intra PredictionMRM: Most Likely ModeMRLP (or MRL): Multiple Reference Line PredictionMTS: Multiple Transform SelectionMV: Motion VectorNSST: Inseparable Secondary TransformOLED: Organic Light-Emitting DiodePBs: Prediction BlocksPCI: Peripheral Component InterconnectPDPC: Position-Dependent Prediction CombinationPLD: Programmable Logic UnitPPR: Parallel Processing AreaPPS: Picture Parameter SetPU: Prediction UnitQT: QuadtreeRAM: Random Access MemoryROM: Read-Only MemoryRST: Reduced Size TransformSBT: Sub-Block TransformSCC: Screen Content CodingSCIPU: Small Chroma Intra Prediction UnitSDR: Standard Dynamic RangeSEI: Supplementary Extended informationSNR: ratiosignal-to-noise SPS: Sequence Parameter Set SSD: Solid State Drive SVT: Spatially Varying Transform TSM: Transform Skip Mode TT: Ternary Tree TU: Transform Unit T_CCLM: Upper Cross-Component Linear Mode / Model USB: Universal Serial Bus VPDU: Visual Process Data Unit VPS: Video Parameter Set VUI: Video Property Information VVC: Universal Video Coding WAIP: Wide-Angle Intra-Prediction

Claims

1. A method for encoding video in a decoder, comprising: - decoding (S1210) prediction information of a current block of a current image in an encoded bitstream, wherein the prediction information indicates a geometric partition mode (GPM) for the current block, the current block is divided into two sections in the GPM mode, and each of the sections is associated with a corresponding predictor; - determining (S1220) a weight index for counting the current block based on the counting position; - calculating (S1230) a weighting factor based on a reference weighting index according to an equation that converts the weighting index into a weighting factor; and - reconstruction (S1240) of a sample based on a weighting coefficient and a predictor corresponding to the sample; where the equation includes a right shift operation; the calculation contains: - performing a right shift operation based on at least the sum of a weight index and a shift value; the shift value is based on the number of bits shifted by the right shift operation, and the number of bits shifted by the right shift operation is based on at least the size of the cosine table used to calculate the weight index; - truncate the result of the right shift operation to a pre-specified range.

2. The method according to claim 1, wherein the equation includes a piecewise constant function having a number of unit step functions equal to the number of different values ​​of the weighting coefficients minus one.

3. The method according to claim 1, wherein the right shift operation is based on a weight index.

4. The method according to paragraph 1, wherein the determination of the weight index comprises: - determining the angle index and the distance index that define the division boundary between sections of the current block, based on the GPM; and - determination of the weight index for the reference based on the reference position, angle index and distance index.

5. The method according to claim 4, wherein the calculation comprises: - determining the section index based on the angle index; and - calculation of the weighting coefficient based on the section index.

6. The method according to paragraph 5, in which the equation has the following form: weight=Clip3 (0, 8, (wIdxL+(1 <<(idx2wShiftBit-1)))>> idx2wShiftBit), where wIdxL=(1 <<(idx2wShiftBit+2))+(partIdx? wIdx: -wIdx), where idx2wShiftBit specifies the number of bits shifted by the right shift operation, weight is the weight coefficient, partIdx is the partition index, wIdx is the weight index, and Clip3() is the clipping function.

7. The method of claim 1, wherein the piecewise constant function includes an initial value.

8. The method of claim 7, wherein the initial value is one of a minimum value of the weighting factor or a maximum value of the weighting factor.

9. A video decoding device comprising a processing circuit configured to: - decoding (S1210) prediction information of a current block of a current image in an encoded bitstream, wherein the prediction information indicates a geometric partition mode (GPM) for the current block, the current block is divided into two sections in the GPM mode, and each of the sections is associated with a corresponding predictor; - determining (S1220) a weight index for counting the current block based on the counting position; - calculating (S1230) a weighting factor based on a reference weighting index according to an equation that converts the weighting index into a weighting factor; and - reconstruction (S1240) of a count based on a weighting coefficient and a predictor corresponding to the count; where the equation includes a right shift operation; the calculation contains: - performing a right shift operation based on at least the sum of a weight index and a shift value; the shift value is based on the number of bits shifted by the right shift operation, and the number of bits shifted by the right shift operation is based on at least the size of the cosine table used to calculate the weight index; - truncate the result of the right shift operation to a pre-specified range.

10. The device of claim 9, wherein the equation includes a piecewise constant function having a number of unit step functions equal to the number of different values ​​of the weighting coefficients minus one.

11. The device of claim 9, wherein the right shift operation is based on a weight index.

12. The device of claim 9, wherein the processing circuit is further configured to: - defining an angle index and a distance index that define the division boundary between sections of the current block, based on the GPM; and - determining the weight index for the reference based on the reference position, angle index and distance index.

13. The device of claim 12, wherein the processing circuit is further configured to: - determining the section index based on the angle index; and - calculation of the weighting coefficient based on the section index.

14. The device according to claim 13, in which the equation has the following form: weight=Clip3 (0, 8, (wIdxL+(1 <<(idx2wShiftBit-1)))>> idx2wShiftBit), where wIdxL=(l <<(idx2wShiftBit+2))+(partIdx? wIdx: -wIdx), where idx2wShiftBit specifies the number of bits shifted by the right shift operation, weight is the weight coefficient, partIdx is the partition index, wIdx is the weight index, and Clip3() is the clipping function.

15. The device of claim 9, wherein the piecewise constant function includes an initial value.

16. The device of claim 15, wherein the initial value is one of a minimum value of the weighting factor or a maximum value of the weighting factor.

17. A non-transitory machine-readable medium storing a program executable by at least one processor for performing: - decoding (S1210) prediction information of a current block of a current image in an encoded bitstream, wherein the prediction information indicates a geometric partition mode (GPM) for the current block, the current block is divided into two sections in the GPM mode, and each of the sections is associated with a corresponding predictor; - determining (S1220) a weight index for counting the current block based on the counting position; - calculating (S1230) a weighting factor based on a reference weighting index according to an equation that converts the weighting index into a weighting factor; and - reconstruction (S1240) of a count based on a weighting coefficient and a predictor corresponding to the count; where the equation includes a right shift operation; the calculation contains: - performing a right shift operation based on at least the sum of a weight index and a shift value; the shift value is based on the number of bits shifted by the right shift operation, and the number of bits shifted by the right shift operation is based on at least the size of the cosine table used to calculate the weight index; - truncate the result of the right shift operation to a pre-specified range.

18. The non-transitory machine-readable medium of claim 17, wherein the calculation comprises: an equation including a piecewise constant function having a number of unit step functions equal to the number of different values ​​of the weighting coefficients minus one.

19. The non-transitory machine-readable medium of claim 17, wherein the right shift operation is based on a weight index.

20. A non-transitory machine-readable medium according to claim 17, wherein the definition of the weight index comprises: - determining the angle index and the distance index that define the division boundary between sections of the current block, based on the GPM; and - determination of the weight index for the reference based on the reference position, angle index and distance index.

21. A method for encoding video in an encoder, comprising: - receiving the original video sequence from the video source; dividing the current block of the current image of the source video sequence based on the geometric partitioning mode (GPM), wherein the current block is divided into two sections in the GPM mode, and each of the sections is associated with a corresponding predictor; - determination of the weight index for the current block count based on the count position; - calculating a weighting factor based on a reference weighting index according to an equation that transforms the weighting index into a weighting factor; and - coding of a sample based on a weighting coefficient and a predictor corresponding to the sample; where the equation includes a right shift operation; the calculation contains: - performing a right shift operation based on at least the sum of a weight index and a shift value; the shift value is based on the number of bits shifted by the right shift operation, and the number of bits shifted by the right shift operation is based on at least the size of the cosine table used to calculate the weight index; - truncate the result of the right shift operation to a pre-specified range.

22. A device for encoding video, comprising a processing circuit configured to perform the method of claim 21.