Method and apparatus for video coding and decoding

Through geometric merging mode and weighted index technology, the problem of low coding efficiency of high-resolution and high-frame-rate video data in existing video coding technology is solved, and more efficient video data compression and decoding are achieved.

CN118678094APending Publication Date: 2024-09-20TENCENT AMERICA LLC
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410934525.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Priority Date
2020-10-05
Filing Date
2020-10-07
Publication Date
2024-09-20

AI Technical Summary

Technical Problem

Existing video coding technology is difficult to effectively reduce bandwidth and storage space requirements when compressing video signals, especially in high-resolution and high-frame-rate video data, resulting in low coding efficiency.

Method used

Geometric merging mode (GEO) is used for video encoding and decoding, video blocks are divided by geometric partitioning mode, and weighted indexes and weight values ​​are used for sample prediction to improve coding efficiency.

Benefits of technology

It significantly reduces the bandwidth and storage requirements of video data, improves encoding efficiency, and is suitable for high-resolution and high-frame-rate video applications.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118678094A_ABST
    Figure CN118678094A_ABST
Patent Text Reader

Abstract

Aspects of the present disclosure provide methods, apparatus, and non-volatile computer-readable storage media for video encoding / decoding. In one method, prediction information for a current block of a current picture in an encoded bitstream is decoded. The prediction information indicates a geometric partition mode (GPM) of the current block. The current block is partitioned into two partitions in a GPM mode. Each of the partitions is associated with a respective predicted value. A weighted index for the samples of the current block is determined based on the positions of the samples. A weighting factor is calculated based on the weighted index of the sample according to an equation that converts the weighted index into the weighting factor. The sample is reconstructed based on the weighting factor and the predicted value corresponding to the sample. Wherein an angle index and a distance index for defining a segmentation boundary between the partitions of the current block are determined based on the GPM; and determining the weighted index of the sample based on the position, the angle index, and the distance index of the sample.
Need to check novelty before this filing date? Find Prior Art

Description

[0001] This application is a divisional application of the Chinese patent application with application number 202080038220.7 filed with the China Patent Office on October 7, 2020. Technical Field

[0002] This application describes embodiments that generally relate to video encoding and decoding. Background Art

[0003] The background description provided herein is intended to present the background of the present application as a whole. The extent to which the work of the presently named inventors described in the background section and various aspects of this specification is performed does not indicate that it is prior art at the time of filing this application, and it is never explicitly or implicitly admitted that it is prior art for this application.

[0004] Video encoding and decoding are enabled by inter-picture prediction techniques with motion compensation. An uncompressed digital video may include a series of pictures, each picture having spatial dimensions such as 1920×1080 luminance samples and associated chrominance samples. The series of pictures has a fixed or variable picture rate (also informally referred to as a frame rate), such as 60 pictures per second or 60Hz. Uncompressed video has very high bitrate requirements. For example, 1080p604:2:0 video (1920x1080 luminance sample resolution, 60Hz frame rate) with 8 bits per sample requires close to 1.5Gbit / s bandwidth. One hour of such video requires more than 600GB of storage space.

[0005] One goal of video encoding and decoding is to reduce redundant information in the input video signal through compression. Video compression can help reduce the bandwidth or storage space requirements mentioned above, in some cases by two or more orders of magnitude. Both lossless and lossy compression, as well as combinations of the two, can be used. Lossless compression refers to techniques that reconstruct an exact replica of the original signal from the compressed original signal. When lossy compression is used, the reconstructed signal may not be exactly the same as the original signal, but the distortion between the original and the reconstructed signal is small enough that the reconstructed signal can be used for the intended application. Lossy compression is widely used in video. The amount of distortion allowed depends on the application. For example, users of some consumer streaming applications may tolerate higher distortion than users of television applications. The achievable compression ratio reflects that higher allowed / tolerable distortion results in higher compression ratios.

[0006] Video encoders and decoders may utilize techniques from several broad categories including, for example, motion compensation, transforms, quantization, and entropy coding and decoding.

[0007] Video codec techniques may include a technique called inter prediction. For each inter-predicted coding unit (CU, codingunit), motion parameters include motion vectors, reference picture indexes, and reference picture list usage indexes, as well as additional information for inter-prediction sample generation. Motion parameters can be signaled explicitly or implicitly. When a CU is encoded using skip mode, the CU is associated with a prediction unit (PU) and has no significant residual coefficients, encoded motion vector increments, or reference picture indexes. A merge mode is specified, whereby the motion parameters of the current CU are obtained from neighboring CUs, including spatial and temporal candidates, and additional scheduling introduced, for example, in VVC. The merge mode can be applied to any inter-predicted CU, not just to the skip mode. An alternative to the merge mode is the explicit transmission of motion parameters. Motion vectors, corresponding reference picture indexes for each reference picture list, and reference picture list usage flags and other required information are explicitly signaled per CU.

[0008] Some inter prediction codec tools include extended merge prediction, merge mode with motion vector difference (MMVD), advanced motion vector prediction mode (AMVP) with symmetric motion vector difference (MVD) signaling, affine motion compensated prediction, subblock-based temporal motion vector prediction (SbTMVP), adaptive motion vector resolution (AMVR), motion field storage (1 / 16 luma sample MV storage and 8x8 motion field compression), bi-prediction with weighted averaging (BWA), bi-directional optical flow (BDOF), decoder side motion vector refinement (DMVR), triangular partitioning 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 MVPs from spatial neighboring CUs; ​​(2) temporal MVPs of co-located CUs; ​​(3) history-based MVPs in the FIFO table; (4) pairwise average MVPs; and (5) zero MVs.

[0010] The size of the merge list is signaled in the slice header, and in some cases the maximum allowed size of the merge list may be, for example, 6. For each CU code in merge mode, the index of the best merge candidate is encoded using truncated unary (TU). The first binary of the merge index uses context coding, while the other binary numbers use bypass coding.

[0011] Figure 1A shows exemplary locations of spatial merging candidates. In some cases, it is possible to Figure 1A Up to four merge candidates are selected from the candidates at the positions shown in . The selection order is B1, A1, B0, A0, and B2. The candidate at position B2 is considered only when any CU at position A0, B0, B1, or A1 is unavailable (for example, 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, a redundancy check is performed on the addition of the remaining candidates to ensure that candidates with the same motion information are excluded from the merge candidate list, thereby improving encoding and decoding efficiency.

[0012] Figure 1B The candidate pairs considered for the redundancy check of spatial merging candidates are shown. In order to reduce the computational complexity, not all possible candidate pairs are considered in the redundancy check. Instead, only the candidate pairs with Figure 1B The arrows in are linked to pairs, and if the corresponding candidates for redundancy check do not have the same motion information, the candidate is only added to the merge candidate list.

[0013] Figure 1C The motion vector scaling of the temporal merge candidate is shown. In some cases, only one temporal merge candidate may be added to the merge candidate list. Specifically, in the derivation of the temporal merge candidate, the scaled motion vector is derived based on the co-located CU belonging to the same reference picture. The reference picture list used to derive the co-located CU is explicitly signaled in the slice header. Figure 1CAs shown by the dotted line in , the scaled motion vector of the temporal merge candidate is obtained. The scaled motion vector is derived from the motion vector of the co-located CU using the picture order count (POC) distances tb and td, where tb is defined as the POC difference between the reference picture of the current picture and the current picture, and td is defined as the POC difference between the reference picture of the co-located picture and the co-located picture. The reference picture index of the temporal merge candidate can be set equal to zero.

[0014] Figure 1D Example positions of temporal merge candidates are shown. The temporal merge candidate is selected between the CU at position C0 and the CU at C1. If the CU at position C0 is not available, not inter-coded, or outside the current CTU row, the CU at position C1 is used. Otherwise, the CU at position C0 is used when deriving the temporal merge candidate. Summary of the invention

[0015] Various aspects of the present disclosure provide methods and apparatus for performing video encoding / decoding. In some examples, the apparatus for performing video decoding includes a processing circuit.

[0016] According to various methods disclosed herein, a method for performing video decoding in a decoder is provided. In the method, prediction information of a current block of a current picture in an encoded bitstream is decoded, the prediction information indicating a geometric partition mode GPM of the current block, the current block being divided into two partitions under the geometric partition mode GPM, each of the partitions being associated with a corresponding prediction value; a weighted index of the sample of the current block is determined based on the position of the sample; a weighted factor is calculated based on the weighted index of the sample according to an equation for converting the weighted index into a weighted factor; and the sample is reconstructed based on the weighted factor and the prediction value corresponding to the sample.

[0017] In an embodiment, a right shift operation is performed on the sum of the weighted index and the offset value; and a result of the right shift operation is clipped within a predetermined range.

[0018] In an embodiment, the offset value is based on a 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 the weighted index and a size of a cosine table used to calculate the weighted index.

[0019] In an embodiment, an angle index and a distance index for defining a partition boundary between the partitions of the current block are determined based on the GPM; and the weighted index of the sample is determined based on the position of the sample, the angle index and the distance index.

[0020] In an embodiment, a partition index is determined based on the angle index; and the weighting factor is calculated based on the partition index.

[0021] In an embodiment, the equation is

[0022] weight=Clip3(0,8,(wIdxL+(1<<(idx2wShiftBit-1)))>>idx2wShiftBit), where

[0023] wIdxL=(1<<(idx2wShiftBit+2))+(partIdx?wIdx:-wIdx),

[0024] Among them, idx2wShiftBit indicates the number of bits shifted by the right shift operation, weight is the weighting factor, partIdx is the partition index, wIdx is the weighted index, and Clip3() is the clipping function.

[0025] In an embodiment, the equation is a piecewise constant function, the piecewise constant function comprising an initial value and a plurality of unit step functions, the initial value being one of a minimum weighting factor value and a maximum weighting factor value, and the number of the plurality of unit step functions being equal to the total number of different weighting factor values ​​minus one.

[0026] Various aspects of the present disclosure provide a device configured to perform any one or combination of the video decoding methods. In an embodiment, the device includes a processing circuit that decodes prediction information of a current block of a current picture in an encoded bitstream, the prediction information indicating a geometric partition mode GPM of the current block, the current block being divided into two partitions under the geometric partition mode GPM, each of the partitions being associated with a corresponding prediction value; the processing circuit determines a weighted index of the sample of the current block based on the position of the sample; the processing circuit calculates the weighted factor based on the weighted index of the sample according to an equation for converting the weighted index into the weighted factor; and the processing circuit reconstructs the sample based on the weighted factor and the prediction value corresponding to the sample.

[0027] Various aspects of the present disclosure also provide a non-volatile computer-readable storage medium storing instructions, which, when executed by a computer used for video decoding, can enable the computer to perform any one or a combination of the video decoding methods. BRIEF DESCRIPTION OF THE DRAWINGS

[0028] Other features, properties and various advantages of the disclosed subject matter will become more apparent from the following detailed description and accompanying drawings, in which:

[0029] Figure 1AExemplary locations of spatial merging candidates are shown;

[0030] Figure 1B shows candidate pairs considered for redundancy check of spatial merging candidates;

[0031] Figure 1C Motion vector scaling of temporal merging candidates is shown;

[0032] Figure 1D Exemplary locations of temporal merging candidates are shown;

[0033] Figure 2 A schematic diagram of a simplified block diagram of a communication system according to an embodiment;

[0034] Figure 3 A schematic diagram of a simplified block diagram of a communication system according to an embodiment;

[0035] Figure 4 is a schematic diagram of a simplified block diagram of a decoder according to an embodiment;

[0036] Figure 5 is a schematic diagram of a simplified block diagram of an encoder according to an embodiment;

[0037] Figure 6 shows a block diagram of an encoder according to another embodiment;

[0038] Figure 7 shows a block diagram of a decoder according to another embodiment;

[0039] Fig. 8A and Figure 8B Two exemplary triangular partitions according to an embodiment are shown;

[0040] Fig. 9 shows unidirectional prediction motion vector selection for triangular partition mode according to an embodiment;

[0041] Fig. 10A and 10B shows an exemplary weight map for luminance and chrominance according to an embodiment;

[0042] Fig.11 shows an exemplary geometric partitioning pattern according to some embodiments of the present disclosure;

[0043] Fig.12 A flowchart outlining an exemplary process according to an embodiment of the present disclosure is shown.

[0044] Fig.13 A schematic diagram of a computer system according to an embodiment of the present application is shown. DETAILED DESCRIPTION

[0045] The present disclosure includes embodiments related to geometric merge mode (GEO), which may also be referred to as geometric partitioning mode (GPM). Embodiments include methods, apparatus, and non-volatile computer-readable storage media for improving GEO. In addition, a block may refer to a prediction block, a coding block, or a coding unit.

[0046] I. Video Encoders and Decoders

[0047] Figure 2 2 is a simplified block diagram of a communication system (200) according to an embodiment disclosed in the present application. The communication system (200) includes a plurality of terminal devices, which can communicate with each other through, for example, a network (250). For example, the communication system (200) includes a first pair of terminal devices (210) and a terminal device (220) interconnected through the network (250). Figure 2 In an embodiment, the terminal device (210) and the terminal device (220) perform unidirectional data transmission. For example, the terminal device (210) may encode video data (e.g., a video picture stream collected by the terminal device (210)) for transmission to another terminal device (220) via the network (250). The encoded video data is transmitted in the form of one or more encoded video code streams. The terminal device (220) may receive the encoded video data from the network (250), decode the encoded video data to restore the video data, and display the video picture based on the restored video data. Unidirectional data transmission is more common in applications such as media services.

[0048] In another embodiment, the communication system (200) includes a second pair of terminal 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, each of the terminal devices (230) and (240) can encode video data (e.g., a video picture stream collected by the terminal device) for transmission to the other terminal device (230) and (240) through the network (250). Each of the terminal devices (230) and (240) can also receive the encoded video data transmitted by the other terminal device (230) and (240), and can decode the encoded video data to restore the video data, and can display the video picture on an accessible display device based on the restored video data.

[0049] exist Figure 2In the embodiment of the present invention, the terminal device (210), the terminal device (220), the terminal device (230) and the terminal device (240) may be a server, a personal computer and a smart phone, but the principles disclosed in the present application may not be limited thereto. The embodiments disclosed in the present application are applicable to laptop computers, tablet computers, media players and / or dedicated video conferencing equipment. The network (250) represents any number of networks that transmit encoded video data between the terminal devices (210), the terminal devices (220), the terminal devices (230) and the terminal devices (240), including, for example, wired (wired) and / or wireless communication networks. The communication network (250) may exchange data in circuit switching and / or packet switching channels. The network may include a telecommunications network, a local area network, a wide area network and / or the Internet. For the purpose of this discussion, unless explained below, the architecture and topology of the network (250) may be irrelevant to the operation disclosed in the present application.

[0050] As an example, Figure 3 The video encoder and video decoder are shown in a streaming environment. The subject matter disclosed in this application is equally applicable to other video-enabled applications, including, for example, video conferencing, digital TV, storing compressed video on digital media including CDs, DVDs, memory sticks, etc.

[0051] The streaming system may include an acquisition subsystem (313), which may include a video source (301) such as a digital camera, which creates an uncompressed video picture stream (302). In an embodiment, the video picture stream (302) includes samples taken by a digital camera. Compared to the encoded video data (304) (or the encoded video bitstream), the video picture stream (302) is depicted as a thick line to emphasize the high data volume of the video picture stream, and the video picture stream (302) can be processed by an electronic device (320), which includes a video encoder (303) coupled to the video source (301). The video encoder (303) may include hardware, software, or a combination of hardware and software to implement or implement various aspects of the disclosed subject matter as described in more detail below. Compared to the video picture stream (302), the encoded video data (304) (or the encoded video bitstream (304)) is depicted as a thin line to emphasize the lower amount of data of the encoded video data (304) (or the encoded video bitstream (304)), which can be stored on the streaming server (305) for future use. One or more streaming client subsystems, such as Figure 3The client subsystem (306) and the client subsystem (308) in the video transmission system can access the streaming server (305) to retrieve the copy (307) and the copy (309) of the encoded video data (304). The client subsystem (306) may include, for example, a video decoder (310) in the electronic device (330). The video decoder (310) decodes the incoming copy (307) of the encoded video data and generates an output video picture stream (311) that can be presented on a display (312) (e.g., a display screen) or another presentation device (not depicted). In some streaming transmission systems, the encoded video data (304), the video data (307), and the video data (309) (e.g., a video bitstream) can be encoded according to certain video encoding / compression standards. Examples of these standards include ITU-T H.265. In an embodiment, the video coding standard under development is informally referred to as Versatile Video Coding (VVC), and the present application can be used in the context of the VVC standard.

[0052] It should be noted that the electronic device (320) and the electronic device (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).

[0053] Figure 4 4 is a block diagram of a video decoder (410) according to an embodiment disclosed in the present application. The video decoder (410) may be provided 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 to replace Figure 3 A video decoder (310) of an embodiment.

[0054] The receiver (431) may receive one or more encoded video sequences to be decoded by the video decoder (410); in the same or another embodiment, one encoded video sequence is received at a time, wherein the decoding of each encoded video sequence is independent of the other encoded video sequences. The encoded video sequence may be received from a channel (401), which may be a hardware / software link to a storage device storing the encoded video data. The receiver (431) may receive the encoded video data as well as other data, such as encoded audio data and / or auxiliary data streams that may be forwarded to their respective consuming entities (not shown). The receiver (431) may separate the encoded video sequence from the other data. To prevent network jitter, a buffer memory (415) may be coupled between the receiver (431) and the entropy decoder / parser (420) (hereinafter referred to as "parser (420)"). In some applications, the buffer memory (415) is part of the video decoder (410). In other cases, the buffer memory (415) may be provided external to the video decoder (410) (not shown). In other cases, a buffer memory (not shown) is provided outside the video decoder (410) to prevent network jitter, for example, and another buffer memory (415) may be configured inside the video decoder (410) to handle broadcast timing, for example. When the receiver (431) receives data from a storage / forward device with sufficient bandwidth and controllability or from an isochronous network, it may not be necessary to configure the buffer memory (415), or the buffer memory may be made smaller. Of course, in order to use on a service packet network such as the Internet, a buffer memory (415) may also be required, and the buffer memory may be relatively large and have an adaptive size, and may be at least partially implemented in an operating system or a similar element (not shown) outside the video decoder (410).

[0055] The video decoder (410) may include a parser (420) to reconstruct symbols (421) from the encoded video sequence. The types of symbols include information used to manage the operation of the video decoder (410) and potential information used to control a display device such as a display device (412) (e.g., a display screen) that is not part of the electronic device (430) but can be coupled to the electronic device (430), such as Figure 4As shown in . The control information for the display device may be a parameter set fragment (not indicated) of Supplemental Enhancement Information (SEI message) or Video Usability Information (VUI). The parser (420) may parse / entropy decode the received coded video sequence. The encoding of the coded video sequence may be performed according to a video coding technique or standard, and may follow various principles, including variable length coding, Huffman coding, arithmetic coding with or without context sensitivity, and the like. The parser (420) may extract a subgroup parameter set of at least one subgroup of the subgroups of pixels in the video decoder from the coded video sequence based on at least one parameter corresponding to the group. The subgroup may include a Group of Pictures (GOP), a picture, a tile, a slice, a macroblock, a Coding Unit (CU), a block, a Transform Unit (TU), a Prediction Unit (PU), and the like. The parser (420) may also extract information from the encoded video sequence, such as transform coefficients, quantizer parameter values, motion vectors, and so on.

[0056] The parser (420) may perform entropy decoding / parsing operations on the video sequence received from the buffer memory (415), thereby creating symbols (421).

[0057] Depending on the type of coded video picture or portion of coded video picture (e.g., inter- and intra-pictures, inter- and intra-blocks) and other factors, the reconstruction of the symbol (421) may involve multiple different units. Which units are involved and how they are involved may be controlled by subgroup control information parsed by the parser (420) from the coded video sequence. For the sake of brevity, such subgroup control information flow between the parser (420) and the multiple units below is not described.

[0058] In addition to the functional blocks already mentioned, the video decoder (410) can be conceptually subdivided into several functional units as described below. In a practical embodiment operating under commercial constraints, many of these units interact closely with each other and can be integrated with each other. However, for the purpose of describing the disclosed subject matter, the conceptual subdivision into the following functional units is appropriate.

[0059] The first unit is a sealer / inverse transform unit (451). The sealer / inverse transform unit (451) receives quantized transform coefficients as symbols (421) from the parser (420) and control information, including which transform method to use, block size, quantization factor, quantization scaling matrix, etc. The sealer / inverse transform unit (451) can output a block including sample values, which can be input into an aggregator (455).

[0060] In some cases, the output samples of the scaler / inverse transform unit (451) may belong to an intra-coded block; that is, a block that does not use predictive information from a previously reconstructed picture, but may use predictive information from a previously reconstructed portion of the current picture. Such predictive information may be provided by an intra-picture prediction unit (452). In some cases, the intra-picture prediction unit (452) generates surrounding blocks of the same size and shape as the block being reconstructed using reconstructed information extracted from a current picture buffer (458). For example, the current picture buffer (458) buffers a partially reconstructed current picture and / or a fully reconstructed current picture. In some cases, the aggregator (455) adds the prediction information generated by the intra-prediction unit (452) to the output sample information provided by the scaler / inverse transform unit (451) on a per-sample basis.

[0061] In other cases, the output samples of the scaler / inverse transform unit (451) may belong to an inter-frame coded and potentially motion compensated block. In this case, the motion compensated prediction unit (453) may access the reference picture memory (457) to extract samples for prediction. After the extracted samples are motion compensated according to the symbols (421), these samples may be added to the output of the scaler / inverse transform unit (451) (in this case referred to as residual samples or residual signals) by the aggregator (455) to generate output sample information. The acquisition of the predicted samples by the motion compensated prediction unit (453) from the address in the reference picture memory (457) may be controlled by a motion vector, and the motion vector is provided to the motion compensated prediction unit (453) in the form of the symbols (421), for example, including X, Y and reference picture components. Motion compensation may also include interpolation of sample values ​​extracted from the reference picture memory (457) when using sub-sample accurate motion vectors, motion vector prediction mechanisms, and the like.

[0062] The output samples of the aggregator (455) may be employed by various loop filtering techniques in a loop filter unit (456). The video compression techniques may include in-loop filter techniques controlled by parameters included in the encoded video sequence (also referred to as the encoded video bitstream) and available to the loop filter unit (456) as symbols (421) from the parser (420). However, in other embodiments, the video compression techniques may also be responsive to meta-information obtained during decoding of a previous (in decoding order) portion of an encoded picture or encoded video sequence, as well as to previously reconstructed and loop filtered sample values.

[0063] The output of the loop filter unit (456) may be a sample stream that may be output to a display device (412) and stored in a reference picture memory (457) for subsequent inter-picture prediction.

[0064] Once fully reconstructed, certain coded pictures may be used as reference pictures for future prediction. For example, once the coded picture corresponding to the current picture is fully reconstructed, and the coded picture is identified as a reference picture (e.g., by the parser (420)), the current picture buffer (458) may become part of the reference picture memory (457), and a new current picture buffer may be reallocated before starting to reconstruct a subsequent coded picture.

[0065] The video decoder (410) may perform decoding operations according to a predetermined video compression technique, such as in the ITU-T H.265 standard. The encoded video sequence may conform to the syntax specified by the video compression technique or standard used in the sense that the encoded video sequence follows the syntax of the video compression technique or standard and the profile recorded in the video compression technique or standard. Specifically, the profile may select certain tools from all the tools available in the video compression technique or standard as the only tools available for use under the profile. For compliance, the complexity of the encoded video sequence is also required to be within the range defined by the hierarchy of the video compression technique or standard. In some cases, the hierarchy limits the maximum picture size, the maximum frame rate, the maximum reconstruction sampling rate (measured in, for example, mega samples per second), the maximum reference picture size, etc. In some cases, the limits set by the hierarchy may be further limited by the Hypothetical Reference Decoder (HRD) specification and metadata of the HRD buffer management signaled in the encoded video sequence.

[0066] In an embodiment, the receiver (431) may receive additional (redundant) data along with the encoded video. The additional data may be part of the encoded video sequence. The additional data may be used by the video decoder (410) to properly decode the data and / or more accurately reconstruct the original video data. The additional data may be in the form of, for example, temporal, spatial or signal-to-noise ratio (SNR) enhancement layers, redundant slices, redundant pictures, forward error correction codes, etc.

[0067] Figure 5 1 is a block diagram of a video encoder (503) according to an embodiment disclosed in the present application. The video encoder (503) is provided in an electronic device (520). The electronic device (520) includes a transmitter (540) (e.g., a transmission circuit). The video encoder (503) can be used to replace Figure 3 A video encoder (303) in an embodiment.

[0068] The video encoder (503) can be used to obtain the video source (501) (not Figure 5 In another embodiment, the video source (501) is a part of the electronic device (520) to receive video samples, and the video source can collect video images to be encoded by the video encoder (503). In another embodiment, the video source (501) is a part of the electronic device (520).

[0069] The video source (501) may provide a source video sequence in the form of a digital video sample stream to be encoded by the video encoder (503), wherein the digital video sample stream may have any suitable bit depth (e.g., 8-bit, 10-bit, 12-bit, ...), any color space (e.g., BT.601 Y CrCB, RGB, ...), and any suitable sampling structure (e.g., Y CrCb 4:2:0, Y CrCb 4:4:4). In a media service system, the video source (501) may be a storage device storing previously prepared videos. In a video conferencing system, the video source (501) may be a camera that captures local image information as a video sequence. The video data may be provided as a plurality of separate pictures that are given motion when viewed sequentially. The pictures themselves may be constructed as a spatial pixel array, wherein each pixel may include one or more samples depending on the sampling structure, color space, etc. used. The relationship between pixels and samples may be easily understood by those skilled in the art. The following description focuses on the samples.

[0070] According to an embodiment, the video encoder (503) may encode and compress pictures of a source video sequence into an encoded video sequence (543) in real time or under any other time constraints required by the application. Implementing an appropriate encoding speed is a function of the controller (550). In some embodiments, the controller (550) controls other functional units as described below and is functionally coupled to these units. For the sake of brevity, coupling is not indicated in the figure. The parameters set by the controller (550) may include rate control related parameters (picture skipping, quantizer, lambda value of rate distortion optimization technology, etc.), picture size, group of pictures (group of pictures, GOP) layout, maximum motion vector allowed reference area, etc. The controller (550) can be used to have other suitable functions that are related to the video encoder (503) optimized for a certain system design.

[0071] In some embodiments, the video encoder (503) operates in a coding loop. As a simple description, in embodiments, the coding loop may include a source encoder (530) (e.g., responsible for creating symbols, such as a symbol stream, based on an input picture to be encoded and a reference picture) and a (local) decoder (533) embedded in the video encoder (503). The decoder (533) reconstructs the symbols to create sample data in a manner similar to how the (remote) decoder creates sample data (because in the video compression technology considered in this application, any compression between the symbols and the encoded video code stream is lossless). The reconstructed sample stream (sample data) is input to a reference picture memory (534). Since the decoding of the symbol stream produces bit-accurate results that are independent of the decoder 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 reference picture samples "seen" by the prediction part of the encoder are exactly the same as the sample values ​​that the decoder will "see" when using the prediction during decoding. This basic principle of reference picture synchronization (and the drift that occurs when synchronization cannot be maintained, eg due to channel errors) is also used in some related techniques.

[0072] The operation of the "local" decoder (533) may be combined with, for example, Figure 4 The "remote" decoder described in detail for the video decoder (410) is identical. However, additional brief reference is made to Figure 4 , when symbols are available and the entropy encoder (545) and parser (420) are capable of losslessly encoding / decoding the symbols into an encoded video sequence, the entropy decoding portion of the video decoder (410), including the buffer memory (415) and the parser (420), may not be fully implemented in the local decoder (533).

[0073] At this point, it can be observed that any decoder technology other than the parsing / entropy decoding present in the decoder must also be present in the corresponding encoder in substantially the same functional form. For this reason, the present application focuses on decoder operation. The description of encoder technology can be simplified because encoder technology is mutually inverse to the decoder technology described comprehensively. A more detailed description is only needed in certain areas and is provided below.

[0074] During operation, in some embodiments, the source encoder (530) may perform motion compensated predictive coding. The motion compensated predictive coding predictively encodes an input picture with reference to one or more previously encoded pictures from a video sequence designated as "reference pictures." In this manner, the encoding engine (532) encodes the differences between pixel blocks of the input picture and pixel blocks of a reference picture that may be selected as a prediction reference for the input picture.

[0075] The local video decoder (533) may decode the encoded video data of the picture that may be designated as the reference picture based on the symbol created by the source encoder (530). The operation of the encoding engine (532) may be a lossy process. When the encoded video data is available at the video decoder ( Figure 5 When the video sequence is decoded at a remote location (not shown), the reconstructed video sequence may typically be a copy of the source video sequence with some errors. The local video decoder (533) replicates the decoding process that may be performed by the video decoder on the reference picture and may cause the reconstructed reference picture to be stored in the reference picture cache (534). In this way, the video encoder (503) may locally store a copy of the reconstructed reference picture that has common content (absent transmission errors) with the reconstructed reference picture to be obtained by the remote video decoder.

[0076] The predictor (535) may perform a prediction search for the encoding engine (532). That is, for a new picture to be encoded, the predictor (535) may search the reference picture memory (534) for sample data (as candidate reference pixel blocks) or certain metadata, such as reference picture motion vectors, block shapes, etc., that may serve as appropriate prediction references for the new picture. The predictor (535) may operate pixel-by-pixel based on sample blocks to find a suitable prediction reference. In some cases, based on the search results obtained by the predictor (535), it may be determined that the input picture may have prediction references taken from a plurality of reference pictures stored in the reference picture memory (534).

[0077] The controller (550) may manage encoding operations of the source encoder (530), including, for example, setting parameters and subgroup parameters for encoding video data.

[0078] The outputs of all the above functional units may be entropy encoded in an entropy encoder (545). The entropy encoder (545) performs lossless compression on the symbols generated by the various functional units according to techniques such as Huffman coding, variable length coding, arithmetic coding, etc., thereby converting the symbols into a coded video sequence.

[0079] The transmitter (540) may buffer the encoded video sequence created by the entropy encoder (545) in preparation for transmission over a communication channel (560), which may be a hardware / software link to a storage device where the encoded video data will be stored. The transmitter (540) may combine the encoded video data from the video encoder (503) with other data to be transmitted, such as encoded audio data and / or ancillary data streams (source not shown).

[0080] The controller (550) may manage the operation of the video encoder (503). During encoding, the controller (550) may assign a certain coded picture type to each coded picture, but this may affect the coding techniques that can be applied to the corresponding picture. For example, a picture may generally be assigned to any of the following picture types:

[0081] An intra picture (I picture) may be a picture that can be encoded and decoded without using any other picture in the sequence as a prediction source. Some video codecs allow different types of intra pictures, including, for example, Independent Decoder Refresh ("IDR") pictures. Those skilled in the art are aware of the variations of I pictures and their corresponding applications and features.

[0082] A predictive picture (P picture) may be a picture that can be encoded and decoded using intra prediction or inter prediction, which uses at most one motion vector and a reference index to predict sample values ​​for each block.

[0083] Bidirectional predictive pictures (B pictures), which can be pictures that can be encoded and decoded using intra prediction or inter prediction, which uses up to two motion vectors and reference indices to predict the sample values ​​of each block. Similarly, multiple predictive pictures can use more than two reference pictures and associated metadata for reconstruction of a single block.

[0084] The source picture may typically be spatially subdivided into blocks of samples (e.g., blocks of 4×4, 8×8, 4×8, or 16×16 samples), and coded block by block. These blocks may be predictively coded with reference to other (already coded) blocks, which are determined according to the coding allocation applied to the block's corresponding picture. For example, blocks of an I picture may be non-predictively coded, or the blocks may be predictively coded (spatial prediction or intra prediction) with reference to already coded blocks of the same picture. Blocks of pixels of a P picture may be predictively coded by spatial prediction with reference to one previously coded reference picture or by temporal prediction. Blocks of a B picture may be predictively coded by spatial prediction with reference to one or two previously coded reference pictures or by temporal prediction.

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

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

[0087] The captured video may be taken as a plurality of source pictures (video pictures) in a temporal sequence. Intra-picture prediction (often simplified to intra-prediction) exploits spatial correlations in a given picture, while inter-picture prediction exploits (temporal or other) correlations between pictures. In an embodiment, a particular picture being encoded / decoded is divided into blocks, and the particular picture being encoded / decoded is referred to as the current picture. When a block in the current picture is similar to a reference block in a reference picture that was previously encoded in the video and is still buffered, the block in the current picture may be encoded by a vector called a motion vector. The motion vector points to a reference block in a reference picture, and in the case where multiple reference pictures are used, the motion vector may have a third dimension that identifies the reference picture.

[0088] In some embodiments, bidirectional prediction techniques may be used in inter-picture prediction. According to the bidirectional prediction technique, two reference pictures are used, for example, a first reference picture and a second reference picture that are both before the current picture in the video in decoding order (but may be in the past and future in display order, respectively). A block in the current picture may be encoded by a first motion vector pointing to a first reference block in the first reference picture and a second motion vector pointing to a second reference block in the second reference picture. Specifically, the block may be predicted by a combination of the first reference block and the second reference block.

[0089] In addition, merge mode technology can be used in inter-picture prediction to improve coding efficiency.

[0090] According to some embodiments disclosed in the present application, predictions such as inter-picture prediction and intra-picture prediction are performed in blocks. For example, according to the HEVC standard, pictures in a video picture sequence are divided into coding tree units (CTUs) for compression, and the CTUs in the pictures have the same size, such as 64×64 pixels, 32×32 pixels, or 16×16 pixels. In general, a CTU includes three coding tree blocks (CTBs), which are a luminance CTB and two chrominance CTBs. Furthermore, each CTU can be split into one or more coding units (CUs) using a quadtree. For example, a 64×64 pixel CTU can be split into a 64×64 pixel CU, or 4 32×32 pixel CUs, or 16 16×16 pixel CUs. In an embodiment, each CU is analyzed to determine the prediction type for the CU, such as an inter-prediction type or an intra-prediction type. In addition, depending on temporal and / or spatial predictability, the CU is split into one or more prediction units (PUs). Typically, each PU includes a luminance prediction block (PB) and two chrominance PBs. In an embodiment, the prediction operation in encoding (encoding / decoding) is performed in units of prediction blocks. Taking the luminance prediction block as an example of a prediction block, the prediction block includes a matrix of pixel values ​​(e.g., luminance values), such as 8×8 pixels, 16×16 pixels, 8×16 pixels, 16×8 pixels, and the like.

[0091] Figure 6 1 is a diagram of a video encoder (603) according to another embodiment disclosed in the present application. The video encoder (603) is used to receive a processed block (e.g., a prediction block) of sample values ​​in a current video picture in a video picture sequence, and encode the processed block into an encoded picture that is part of an encoded video sequence. In this embodiment, the video encoder (603) is used to replace Figure 3A video encoder (303) in an embodiment.

[0092] In an HEVC embodiment, a video encoder (603) receives a matrix of sample values ​​for a processing block, such as a prediction block of 8×8 samples. The video encoder (603) uses, for example, rate-distortion (RD) optimization to determine whether to use intra mode, inter mode, or bidirectional prediction mode to encode the processing block. When encoding the processing block in intra mode, the video encoder (603) may use intra prediction techniques to encode the processing block into an encoded picture; and when encoding the processing block in inter mode or bidirectional prediction mode, the video encoder (603) may use inter prediction or bidirectional prediction techniques to encode the processing block into an encoded picture, respectively. In some video encoding techniques, the merge mode may be an inter-picture prediction submode, in which a motion vector is derived from one or more motion vector predictors without the aid of an encoded motion vector component external to the predictor. In some other video encoding techniques, there may be a motion vector component applicable to the subject block. In an embodiment, the video encoder (603) includes other components, such as a mode decision module (not shown) for determining the processing block mode.

[0093] exist Figure 6 In an embodiment of the present invention, the video encoder (603) includes: Figure 6 Shown are an inter-frame encoder (630), an intra-frame encoder (622), a residual calculator (623), a switch (626), a residual encoder (624), a common controller (621), and an entropy encoder (625) coupled together.

[0094] The inter-frame encoder (630) is used to receive samples of a current block (e.g., a processing block), compare the block with one or more reference blocks in a reference picture (e.g., blocks in a previous picture and a subsequent picture), generate inter-frame prediction information (e.g., redundant information description according to an inter-frame coding technique, motion vectors, merge mode information), and calculate an inter-frame prediction result (e.g., a predicted block) based on the inter-frame prediction information using any suitable technique. In some embodiments, the reference picture is a decoded reference picture decoded based on the encoded video information.

[0095] The intra-frame encoder (622) is used to receive samples of a current block (e.g., a processing block), compare the block with an encoded block in the same picture in some cases, generate quantization coefficients after transformation, and in some cases also generate intra-frame prediction information (e.g., intra-frame prediction direction information according to one or more intra-frame coding techniques). In an embodiment, the intra-frame encoder (622) also calculates an intra-frame prediction result (e.g., a predicted block) based on the intra-frame prediction information and a reference block in the same picture.

[0096] The general controller (621) is used to determine the general control data and control other components of the video encoder (603) based on the general control data. In an embodiment, the general controller (621) determines the mode of the block and provides a control signal to the switch (626) based on the mode. For example, when the mode is intra mode, the general 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 add the intra prediction information to the bitstream; and when the mode is inter mode, the general 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 add the inter prediction information to the bitstream.

[0097] The residual calculator (623) is used to calculate the difference (residual data) between the received block and the prediction result selected from the intra-frame encoder (622) or the inter-frame encoder (630). The residual encoder (624) is used to operate based on the residual data to encode the residual data to generate a transform coefficient. In an embodiment, the residual encoder (624) is used to convert the residual data from the time domain to the frequency domain and generate a transform coefficient. The transform coefficient is then processed by quantization to obtain a quantized transform coefficient. In various embodiments, the video encoder (603) also includes a residual decoder (628). The residual decoder (628) is used to perform an inverse transform and generate decoded residual data. The decoded residual data can be used appropriately by the intra-frame encoder (622) and the inter-frame encoder (630). For example, the inter-frame encoder (630) can generate a decoded block based on the decoded residual data and the inter-frame prediction information, and the intra-frame encoder (622) can generate a decoded block based on the decoded residual data and the intra-frame prediction information. The decoded blocks are appropriately processed to generate a decoded picture, and in some embodiments, the decoded picture may be buffered in a memory circuit (not shown) and used as a reference picture.

[0098] The entropy encoder (625) is used to format the code stream to produce an encoded block. The entropy encoder (625) generates various information according to a suitable standard such as the HEVC standard. In an embodiment, the entropy encoder (625) is used to obtain general control data, selected prediction information (such as intra-frame prediction information or inter-frame prediction information), residual information, and other suitable information in the code stream. It should be noted that according to the disclosed subject matter, when the block is encoded in the inter-frame mode or the merge sub-mode of the bidirectional prediction mode, there is no residual information.

[0099] Figure 7FIG. 7 is a diagram of a video decoder (710) according to another embodiment disclosed in the present application. The video decoder (710) is used to receive an encoded image as part of an encoded video sequence and decode the encoded image to generate a reconstructed picture. In an embodiment, the video decoder (710) is used to replace Figure 3 A video decoder (310) of an embodiment.

[0100] exist Figure 7 In an embodiment, the video decoder (710) includes Figure 7 An entropy decoder (771), an inter-frame decoder (780), a residual decoder (773), a reconstruction module (774) and an intra-frame decoder (772) coupled together are shown in FIG.

[0101] The entropy decoder (771) may be used to reconstruct certain symbols from the encoded picture, which represent syntax elements constituting the encoded picture. Such symbols may include, for example, a mode for encoding the block (e.g., intra mode, inter mode, bidirectional prediction mode, a merged sub-mode of the latter two, or another sub-mode), prediction information (e.g., intra prediction information or inter prediction information) that may identify certain samples or metadata 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 an embodiment, when the prediction mode is inter or 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 inverse quantized and provided to the residual decoder (773).

[0102] The inter-frame decoder (780) is used for receiving the inter-frame prediction information and generating an inter-frame prediction result based on the inter-frame prediction information.

[0103] The intra-frame decoder (772) is used to receive intra-frame prediction information and generate a prediction result based on the intra-frame prediction information.

[0104] The residual decoder (773) is used to perform inverse quantization to extract dequantized transform coefficients, and process the dequantized transform coefficients to convert the residual from the frequency domain to the spatial domain. The residual decoder (773) may also require some control information (to obtain the quantizer parameter QP), and this information can be provided by the entropy decoder (771) (the data path is not indicated because this is only low-volume control information).

[0105] The reconstruction module (774) is used to combine the residual output by the residual decoder (773) with the prediction result (which can be output by the inter-frame prediction module or the intra-frame prediction module) in the spatial domain to form a reconstructed block, which can be part of a reconstructed picture, which in turn can be part of a reconstructed video. It should be noted that other suitable operations such as deblocking operations can be performed to improve visual quality.

[0106] It should be noted that the video encoder (303), video encoder (503) and video encoder (603) and video decoder (310), video decoder (410) and video decoder (710) may be implemented using any suitable technology. In an embodiment, the video encoder (303), video encoder (503) and video encoder (603) and video decoder (310), video decoder (410) and video decoder (710) may be implemented using one or more integrated circuits. In another embodiment, the video encoder (303), video encoder (503) and video encoder (503603) and video decoder (310), video decoder (410) and video decoder (710) may be implemented using one or more processors that execute software instructions.

[0107] II. Triangle Partition Mode (TPM) for Inter Prediction

[0108] In some cases, TPM can be supported for inter prediction. TPM can only be applied to CUs of 8x8 or larger. TPM can be signaled as a merge mode along with other merge modes using a CU level flag, where the other merge modes can be, for example, normal merge mode, MMVD mode, CIIP mode, and sub-block merge mode. When TPM is used, a CU can be evenly split into two triangular partitions using diagonal splitting or anti-diagonal splitting, for example, Fig. 8A and Figure 8B As shown. Each triangular partition in a CU can be inter-predicted using its own motion parameters. Only unidirectional prediction is allowed for each partition. That is, each partition has one motion vector and one reference index. Unidirectional prediction motion constraints are applied to ensure that triangular partitions are the same as conventional bidirectional prediction. That is, only two motion compensated predictions are required for each CU. Figures 1A to 1D The unidirectional predicted motion for each partition is derived using the procedure described in .

[0109] If TPM is used for the current CU, a flag indicating the direction of the TPM (diagonal or anti-diagonal) and two merge indexes (one for each partition) may be further signaled. The maximum TPM candidate size may be explicitly signaled at the slice level, and the syntax binarization may be specified for the TMP merge index. After predicting each triangle partition, a hybrid process with adaptive weight values ​​may be used to adjust the sample values ​​along the diagonal or anti-diagonal edges. After deriving the prediction signal for the entire CU, a transform and quantization process may be further applied to the entire CU as in other prediction modes. Finally, the motion field of the CU predicted using TPM may be stored.

[0110] In some cases, TPM cannot be used in combination with sub-block transform (SBT), that is, when the signaled triangle mode is equal to 1, cu_sbt_flag is inferred to be 0 without signaling.

[0111] The unidirectional prediction candidate list can be derived directly from the merge candidate list, which is constructed according to the extended merge prediction process. Denote N as the index of the unidirectional prediction motion in the triangular unidirectional prediction candidate list. The LX motion vector (where X equals the parity of N) of the Nth extended merge candidate is used as the Nth unidirectional prediction motion vector of the TPM. Fig. 9 These motion vectors are marked with an "X" in . In the case where there is no corresponding LX motion vector for the N-extended merge candidate, the L(1-X) motion vector of the same candidate is used as the unidirectional prediction motion vector of the TPM.

[0112] After predicting each triangle partition using its own motion parameters, a blending process can be applied to the two prediction signals to derive samples around diagonal or anti-diagonal edges. The following weight values ​​are used in the blending process: {7 / 8, 6 / 8, 5 / 8, 4 / 8, 3 / 8, 2 / 8, 1 / 8} for luma and {6 / 8, 4 / 8, 2 / 8} for chroma, as shown in Fig. 10A and Fig. 10B shown.

[0113] In some cases, the motion vector of a CU encoded in TPM can be generated using the following process. If Mv1 and Mv2 are from different reference picture lists (e.g., one from L0 and the other from L1), Mv1 and Mv2 are simply combined to form a bidirectional prediction motion vector. Otherwise, if Mv1 and Mv2 are from the same list, only the unidirectional prediction motion Mv2 is stored.

[0114] III. Geometric Merge Mode (GEO)

[0115] Geometric merging mode (GEO), also known as geometric partitioning mode (GPM), can support multiple different partitioning methods. Partitioning methods can be defined by angles and edges. For example, 140 different partitioning methods can be distinguished by 32 angles (quantized between 0 and 360°, with equal intervals of 11.25°) and 5 edges relative to the center of the CU.

[0116] Fig.11 An exemplary GEO is shown. Fig.11 center, angle represents a quantized angle between 0 and 360 degrees, and the distance offset ρi represents the quantized offset of the maximum distance ρmax. For w or h equal to 8 and scaled by the short edge length scaled by log2, the value of ρmax can be derived geometrically by Equation 1. The variables h and w represent the height and width of the current block. When When is equal to 0, ρmax is equal to w / 2. When ρmax is equal to h / 2, ρmargin=1.0 in equation 1 is to prevent the segmentation boundary from being too close to the corner of the current block.

[0117]

[0118] Each partition mode in GEO (i.e., a pair of angle index and edge index) can be assigned a pixel adaptive weight table to mix samples in two partition parts. The weight value of the sample can be in the range of, for example, 0 to 8 and is determined by the L2 distance, which is from the center position of the pixel to the edge. When assigning weight values, a unit gain constraint can be followed. For example, when a small weight value is assigned to a GEO partition, a large supplementary value (additional value) is assigned to another partition, totaling 8.

[0119] IV. GEO’s Weighted Sample Prediction Process

[0120] In GEO, the final sample prediction value (predictor) PB can be derived according to Equation 2 through two 3-bit mixing masks (ie, weighting values ​​or weighting factors) W0 and W1 and two prediction values ​​P0 and P1.

[0121] P B =(W0P0+W1P1+4)>>3 (Equation 2)

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

[0123]

[0124] in,

[0125] In Equation 4, n represents the total distance quantization step size, and i represents the angle The distance step index of the GEO, and i <n。

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

[0127]

[0128] An exemplary weighted sample prediction process is described as follows. The inputs to the process include two variables nCbW and nCbH specifying the width and height of the current coding block, two (nCbW) x (nCbH) arrays predSamplesLA and predSamplesLB, a variable angleIdx specifying the angle index of the geometric partition, a variable distanceIdx specifying the distance idx of the geometric partition, and a variable cIdx specifying the color component index. The outputs of the process include a (nCbW) x (nCbH) array pbSamples and a (nCbW>>2) x (nCbH>>2) array motionIdx of predicted sample values.

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

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

[0131] The weight arrays sampleWeightL[x][y] for luma and sampleWeightC[x][y] for chroma, where x = 0..nCbW-1 and y = 0..nCbH-1, can be derived as follows:

[0132] The variables wIdx=log2(nCbW) and hIdx=log2(nCbH).

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

[0134] The variables displacementX=angleIdx and displacementY=(displacementX+8)%32.

[0135] Variable angleN=(wIdx>=hIdx)? (angleIdx>>3&1)? angleIdx%8:8-angleIdx%8:(angleIdx>>3&1)? 8-angleIdx%8: angleIdx%8.

[0136] Using the lookup tables denoted stepDis and Dis specified in Tables 1 and 2, the variable rho can be set to the following value. rho = distanceIdx*(stepDis[whRatio][angleN] < <scaleIdx)+(Dis[displacementX]<<wIdx)+(Dis[displacementY]<<hIdx)。

[0137] The variables weightIdx and weightIdxAbs can be calculated using lookup table 2, where 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).

[0138] If x=0 and y=nCbH-1, the variable partIdx can be set to weightIdx>0.

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

[0140] The value sampleWeightC[x][y], where x=0..nCbW-1 and y=0..nCbH-1, may be set as follows: sampleWeightC[x][y]=sampleWeightL[(x<<(SubWidthC-1))][(y<<(SubHeightC-1))].

[0141] Table 1

[0142]

[0143] Table 2

[0144] idx 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 Dis[idx] 64 63 59 53 45 36 24 12 0 -12 -24 -36 -45 -53 -59 -63 idx 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 Dis[idx] -64 -63 -59 -53 -45 -36 -24 -12 0 12 24 36 45 53 59 63

[0145] Table 3

[0146] idx 0 1 2 3 4 5 6 7 8 9 10 11 12 13 GeoFilter[idx] 4 4 4 4 5 5 5 5 5 5 5 6 6 6 idx 14 15 16 17 18 19 20 21 22 23 24 25 26 GeoFilter[idx] 6 6 6 6 7 7 7 7 7 7 7 7 8

[0147] In order to reduce the storage requirements of pre-computed mixing masks, the minimum mixing mask storage method can achieve a 84-91% reduction in the memory requirements for mixing weight storage.

[0148] Let g_sampleWeightL[] denote the predefined mask for blending weights. Let N denote the number of predefined masks in each group, and N is set to NA>>1, where NA is the number of angles supported in GEO. M×M denotes the size of the predefined mask for blending 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 set in 5 steps, N is set to 16 and M is set to 192. For 24 angles set in 4 steps, N is set to 12 and M is set to 224.

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

[0150]

[0151] An exemplary weighted sample prediction process with minimum hybrid weight mask storage for GEO is described as follows. The input to the process includes two variables nCbW and nCbH specifying the width and height of the current coding block, two (nCbW) x (nCbH) arrays predSamplesLA and predSamplesLB, a variable angleIdx specifying the angle index of the geometric partition, a variable distanceIdx specifying the distance idx of the geometric partition, and a variable cIdx specifying the color component index. The output of the process includes an (nCbW) x (nCbH) array pbSamples of predicted sample values ​​and a variable partIdx.

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

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

[0154] The weight arrays sampleWeightL[x][y] for luma and sampleWeightC[x][y] for chroma, where x = 0..nCbW-1 and y = 0..nCbH-1, can be derived as follows:

[0155] Variable hwRatio=nCbH / nCbW.

[0156] The variables displacementX=angleIdx and displacementY=(displacementX+8)%32.

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

[0158] The variable rho can be set to the following values ​​using Lookup Table 2.

[0159] rho=(Dis[displacementX]<<8)+(Dis[displacementY]<<8).

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

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

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

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

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

[0165] The value of sampleWeightC[x][y], where x=0..nCbW-1 and y=0..nCbH-1, may be set as follows: sampleWeightC[x][y]=sampleWeightL[(x<<(SubWidthC-1))][(y<<(SubHeightC-1))].

[0166] V.GEO motion vector storage process

[0167] In some cases, the luma sample weights at the four corners of a 4x4 motion storage unit may be summed. This sum may be compared to 2 thresholds to determine if one of the two uni-directional prediction motion information and bi-directional prediction motion information is stored. The same process as TPM may be used to derive bi-directional prediction motion information.

[0168] An exemplary motion vector storage process for GEO is described as follows.

[0169] The array motionIdx[xSbIdx][ySbIdx], where xSbIdx = 0..(nCbW>>2)-1 and ySbIdx = 0..(nCbH>>2)-1, can be derived as follows:

[0170] Variable threshScaler=(wIdx+hIdx)>>1)-1, threshLower=32>>threshScaler, threshUpper=32-threshLower, Cnt=sampleWeightL[(xSbIdx<<2)][(ySbId<<2)]+samp leWeightL[(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.

[0171] If merge_geo_flag[xCb][yCb]=1, then sType=motionIdx[xSbIdx][ySbIdx], where xSbIdx=0..numSbX-1, and ySbIdx=0..numSbY-1.

[0172] In some cases, the motion vector storage process is further simplified. The distance between the center position of the 4x4 motion storage unit and the partition boundary can be calculated and compared with a fixed threshold to determine whether unidirectional prediction motion information or bidirectional prediction motion information is stored for the 4x4 motion storage unit. The sign of the distance indicates which unidirectional prediction motion information should be stored in the unidirectional prediction storage box. The correlation between the mixed mask and the motion storage can be removed.

[0173] 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.

[0174] Using the lookup tables denoted stepDis and Dis specified in Tables 1 and 2, the variable rho is set to the following value. rho = distanceIdx*(stepDis[whRatio][angleN] < <scaleIdx)+(Dis[displacementX]<<wIdx)+(Dis[displacementY]<<hIdx)。

[0175] Using the lookup table denoted Dis specified in Tables 1 and 2, the variable motionOffset is set to the following value: motionOffset = 3*Dis[displacementX] + 3*Dis[displacementY].

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

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

[0178] In order to reduce the memory required to store the mask stored for the motion field, all information from the predefined mask can be derived for the mask stored for the motion field in one process. This process is called when a coding unit is decoded with MergeWedgeFlag[xCb][yCb]=1. The inputs to this process include: the luma position (xCb, yCb) indicating the upper left sample of the current coding block relative to the upper left luma sample of the current picture, a variable cbWidth specifying the width of the current coding block in units of luma samples, a variable cbHeight specifying the height of the current coding block in units of luma samples, luma motion vectors mvA and mvB in 1 / 16 fractional sample accuracy, reference indices refIdxA and refIdxB, and prediction list flags predListFlagA and predListFlagB.

[0179] The variables numSbX and numSbY, which specify the number of 4x4 blocks in the horizontal and vertical directions in the current coding block, are set equal to numSbX=cbWidth>>2 and numSbY=cbHeight>>2.

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

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

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

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

[0184] The value of the variable rho is derived from the following equation and the Dis lookup table specified in Table 2.

[0185] rho=(Dis[displacementX]<<8)+(Dis[displacementY]<<8).

[0186] Using the lookup table denoted Dis specified in Tables 1 and 2, the variable motionOffset is set equal to the following value: motionOffset = 3*Dis[displacementX] + 3*Dis[displacementY].

[0187] For each 4x4 sub-block at sub-block index (xSbIdx, ySbIdx), where xSbIdx = 0..numSbX-1 and ySbIdx = 0..numSbY-1, the variable motionIdx is calculated using lookup Table 2 as follows: motionIdx = (((xSbIdx+offsetX)<<3)+1)*Dis[displacementX]+(((xSbIdx+offsetY<<3)+1))*Dis[displacementY]-rho+motionOffset.

[0188] VI. On-the-fly Weighting Index to Weighting Value Calculation

[0189] In the weighted sample process of the above-mentioned GEO, the conversion of the weighted index wIdx(x, y) to the weight value (or weighting factor) weight(x, y) can be derived based on a linear function, as shown in Equations 9 to 11.

[0190] weightIdxL(x,y)=fl2intOp(s×wIdx(x,y)+bias) (Equation 9)

[0191] wValue(x, y)=min(maxValue, weightIdxL(x, y)) (Equation 10)

[0192] weight(x,y)=(wIdx(x,y)<0)? wValue(x, y): -wValue(x, y) (Equation 11)

[0193] In the example, maxValue=8, bias=4, and quantization step size s=1 / 7.2. The f12intOp 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 is an exemplary implementation of the above equation.

[0194] However, since different samples may have different input values ​​to the lookup table, multiple copies of the lookup table may be required to perform parallel processing on these samples when using the above equation. Therefore, the weighted sample process of the above GEO is not friendly to hardware and software implementation. To solve this problem, the present disclosure includes an embodiment of a conversion-based calculation so that weight values ​​of different samples can be derived in parallel.

[0195] According to aspects of the present disclosure, the conversion of the weighted index wIdx(x, y) to the weight value weight(x, y) may be derived based on an on-the-fly calculation with a right shift operation.

[0196] In some embodiments, the dynamic calculation is the sum of the offset value and the weighted index wIdx(x, y), and the offset value is a function of the right shift operand. In addition, the offset value may be rounded.

[0197] In an embodiment, the conversion of the weighted index wIdx(x, y) to the weight value weight(x, y) can be derived according to Equation 12.

[0198] weight(x,y)=(2 idx2wShiftBit+2 -wIdx(x,y))>>idx2wShiftBit (Equation 12)

[0199] In Equation 12, the offset value 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 may represent the number of digits of precision (eg, 3 or 6) of the cosine table (eg, Table 2) used to calculate the weighted index.

[0200] In an embodiment, the conversion of the weighted index wIdx(x, y) to the weight value weight(x, y) may be derived according to Equation 13 or Equation 14.

[0201] weight(x,y)=Clip3(0,8,(idx2wOffset-wIdx(x,y))>>idx2wShiftBit) (Equation 13)

[0202] weight(x,y)=Clip3(0,8,(idx2wOffset I wIdx(x,y))>>idx2wShiftBit) (Equation 14)

[0203] In equations 13 and 14, a clip function Clip3() is used to limit the weight value weight(x, y) to a predetermined 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.

[0204] idx2wOffset=1<<(idx2wShiftBit+2) (Equation 15)

[0205] The right shift operand idx2wShiftBit may be the number of bits of precision (eg, 3, 6, or 9) of a cosine table (eg, Table 2) used to calculate a weighted index and / or a calculated distance value (eg, a weighted index).

[0206] In an embodiment, the weighted index may have a sign conversion according to the partition index partIdx, as shown in Equation 16.

[0207] wIdxFlip(x,y)=partIdx? -wIdx(x, y): wIdx(x, y) (Equation 16)

[0208] Therefore, the weight value can be derived according to Equation 17 or Equation 18.

[0209] weight(x,y)=Clip3(0,8,(idx2wOffset-wIdxFlip(x,y))>>idx2wShiftBit) (Equation 17)

[0210] weight(x,y)=Clip3(0,8,(idx2wOffset+wIdxFlip(x,y))>>idx2wShiftBit) (Equation 18)

[0211] In an example, the partition index partIdx may be set according to the weighted index of the lower left corner sample of the current block. In another example, the partition index partIdx may be set according to the angle index angleIdx in Equation 19, where T1 and T2 are two thresholds. In one embodiment, T1=10 and T2=20.

[0212] partIdx=(angleIdx≥T1&&angleIdx≤T2)? 0:1 (Equation 19)

[0213] In an embodiment, the partition index partIdx may be used as a definition of partitions at different angles. The weight value may be derived according to Equations 20 and 21.

[0214] wIdxL=(1<<(idx2wShiftBit+2))+(partIdx?wIdx:-wwIdx) (Equation 20)

[0215]

[0216] In an embodiment, the weight value may be derived according to Equation 22 and Equation 23.

[0217] wIdxL=(1<<(idx2wShiftBit+2))+wIdx (Equation 22)

[0218]

[0219] The final blending mask of the samples of the current block can then be flipped according to the condition of the angle index angleIdx described in Equation 19.

[0220] According to various aspects of the present disclosure, the conversion of the weighted index wIdx(x, y) to the weight value weight(x, y) can be derived based on a piecewise constant function. The piecewise constant function can include an initial value and multiple single-step functions. In the range of weight factor values, the initial value can be one of the minimum weight factor value and the maximum weight factor value. In addition, the number of multiple unit step functions can be equal to the total number of weight factor values ​​minus 1.

[0221] In an embodiment, the weight value weight(x, y) can be derived from a predefined initial value smallestWeight and four unit step functions, as shown in Equation 24.

[0222]

[0223] Where v is the weighted index, and ω i (v) can be derived according to Equation 25 or Equation 26.

[0224]

[0225] Table 4 shows an exemplary lookup table for mapping weighted indices to weighted values.

[0226] Table 4

[0227] idx 0 1 2 3 4 5 6 7 8 9 10 11 12 13 GeoFilter [idx] 4 4 4 4 5 5 5 5 5 5 5 6 6 6 idx 14 15 16 17 18 19 20 21 22 23 24 25 26 GeoFilter[idx] 6 6 6 6 7 7 7 7 7 7 7 8 8

[0228] If Equation 24 and Equation 25 are used to represent Table 4, the initial value smallestWeight=4, and the threshold weighted indexes C0-C3 may be 4, 11, 18, and 25, respectively.

[0229] If Table 4 is expressed using Equation 24 and Equation 26, the initial value smallestWeight=4, and the threshold weighted indexes P0-P3 may be 3, 10, 17, and 24, respectively.

[0230] Table 5 shows another exemplary lookup table that maps weighted indices to weight values.

[0231] Table 5

[0232]

[0233]

[0234] If Table 5 is expressed using Equation 24 and Equation 25, the initial value smallestWeight=4, and the threshold weighted indexes C0-C3 may be 3, 10, 17, and 26, respectively.

[0235] If Table 5 is expressed using Equation 24 and Equation 26, the initial value smallestWeight=4, and the threshold weight indexes P0-P3 may be 2, 9, 16, and 25, respectively.

[0236] In an embodiment, the weight value weight(x, y) may be derived from a predefined initial value largestWeight and four unit step functions, as shown in Equation 27.

[0237]

[0238] Among them, ω i (v) can be derived according to Equation 28 or Equation 29.

[0239]

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

[0241] If Equation 27 and Equation 29 are used to represent Table 4, the initial value largestWeight=8, and the threshold weight indexes P0-P3 may be 4, 11, 18, and 25, respectively.

[0242] If Equation 27 and Equation 28 are used to represent Table 5, the initial value largestWeight=8, and the threshold weight indexes C0-C3 may be 2, 9, 16, and 25, respectively.

[0243] If Table 5 is expressed using Equation 27 and Equation 29, the initial value largestWeight=8, and the threshold weight indexes P0-P3 may be 3, 10, 17, and 26, respectively.

[0244] Note that the relational operators (≥) and (>) are 1 when the corresponding relation is true and 0 when the corresponding relation is false, for example, as defined in C and C++.

[0245] VII. Flowchart

[0246] Fig.12A flow chart outlining an exemplary process (1200) according to an embodiment of the present disclosure is shown. In various embodiments, the process (1200) is performed by a processing circuit, such as a processing circuit in a terminal device (210), (220), (230), and (240), a processing circuit that performs the functions of a video encoder (303), a processing circuit that performs the functions of a video decoder (310), a processing circuit that performs the functions of a video decoder (410), a processing circuit that performs the functions of an intra-frame prediction module (452), a processing circuit that performs the functions of a video encoder (503), a processing circuit that performs the functions of a predictor (535), a processing circuit that performs the functions of an intra-frame encoder (622), a processing circuit that performs the functions of an intra-frame decoder (772), etc. In some embodiments, the process (1200) is implemented in software instructions, so when the processing circuit executes the software instructions, the processing circuit performs the process (1200).

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

[0248] At step (S1220), the process (1200) determines the weighted index of the samples of the current block based on the positions of the samples. Then, the process (1200) proceeds to step (S1230).

[0249] At step (S1230), the process (1200) calculates a weighting factor based on the weighted index of the sample according to an equation for converting the weighted index into the weighting factor. Then, the process (1200) proceeds to step (S1240).

[0250] At step (S1240), the process (1200) reconstructs the sample based on the weighting factor and the predicted value corresponding to the sample. After reconstructing the sample, the process (1200) ends.

[0251] In an embodiment, a right shift operation is performed on the sum of the weighted index and the offset value, and the result of the right shift operation is clipped within a predetermined range.

[0252] 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 the weighted index and a size of a cosine table used to calculate the weighted index.

[0253] In an embodiment, an angle index and a distance index for defining a partition boundary between partitions of the current block are determined based on the GPM. A weighted index of a sample is determined based on the position, angle index and distance index of the sample.

[0254] In an embodiment, a partition index is determined based on the angle index. A weighting factor is calculated based on the partition index.

[0255] In an embodiment, the equation is

[0256] weight=Clip3(0,8,(wIdxL+(1<<(idx2wShiftBit-1)))

[0257] >>idx2wShiftBit), where

[0258] wIdxL=(1<<(idx2wShiftBit+2))+(partIdx?wIdx:-wIdx),

[0259] Among them, idx2wShiftBit indicates the number of bits shifted by the right shift operation, partIdx is the partition index, and wIdx is the weighted index.

[0260] In an embodiment, the equation is a piecewise constant function including an initial value and a plurality of unit step functions. The initial value is one of a minimum weighting factor value or a maximum weighting factor value, and the number of the plurality of unit step functions is equal to the total number of different weighting factor values ​​minus one.

[0261] VIII. Computer System

[0262] The above techniques may be implemented as computer software via computer-readable instructions and physically stored in one or more computer-readable media. Fig.13 A computer system (1300) is shown that is suitable for implementing certain embodiments of the disclosed subject matter.

[0263] The computer software may be encoded in any suitable machine code or computer language, and may be assembled, compiled, linked, or the like to create a code comprising instructions, which may be directly executed by one or more computer central processing units (CPUs), graphics processing units (GPUs), etc., or executed by decoding, microcode, or the like.

[0264] The instructions may be executed on various types of computers or components thereof, including, for example, personal computers, tablet computers, servers, smartphones, gaming devices, IoT devices, etc.

[0265] Fig.13The components shown for the computer system (1300) are exemplary in nature and are not intended to limit the scope of use or functionality of the computer software implementing the embodiments of the present application. The configuration of the components should not be interpreted as having any dependency or requirement on any component or combination of components shown in the exemplary embodiment of the computer system (1300).

[0266] The computer system (1300) may include certain human-computer interface input devices. Such human-computer interface input devices may respond to input from one or more human users through tactile input (e.g., keyboard input, sliding, data glove movement), audio input (e.g., sound, applause), visual input (e.g., gestures), and olfactory input (not shown). The human-computer interface devices may also be used to capture certain media that are not necessarily directly related to human conscious input, such as audio (e.g., speech, music, ambient sound), images (e.g., scanned images, photographic images obtained from a still image camera), and videos (e.g., two-dimensional video, three-dimensional video including stereoscopic video).

[0267] The human-computer interface input device may include one or more of the following (only one of which is drawn): keyboard (1301), mouse (1302), touchpad (1303), touch screen (1310), data gloves (not shown), joystick (1305), microphone (1306), scanner (1307), camera (1308).

[0268] The computer system (1300) may also include certain human-computer interface output devices. Such human-computer interface output devices may stimulate one or more human user senses through, for example, tactile output, sound, light, and smell / taste. Such human-computer interface output devices may include tactile output devices (e.g., tactile feedback through a touch screen (1310), a data glove (not shown), or a joystick (1305), but there may also be tactile feedback devices that are not used as input devices), audio output devices (e.g., speakers (1309), headphones (not shown)), visual output devices (e.g., screens (1310) including cathode ray tube screens, liquid crystal screens, plasma screens, organic light emitting diode screens, each of which has or does not have a touch screen input function, each of which has or does not have a tactile feedback function - some of which can output two-dimensional visual output or output of more than three dimensions through means such as stereoscopic picture output; virtual reality glasses (not shown), holographic displays, and smoke boxes (not shown)) and printers (not shown). These visual output devices (e.g., screens (1310)) may be connected to the system bus (1348) through a graphics adapter (1350).

[0269] The computer system (1300) may also include human-accessible storage devices and their associated media, such as optical media including high-density read-only / rewritable optical disks (CD / DVD ROM / RW) (1320) with CD / DVD or similar media (1321), thumb drives (1322), removable hard disk drives or solid state drives (1323), traditional magnetic media such as tapes and floppy disks (not shown), special-purpose ROM / ASIC / PLD-based devices such as security software protectors (not shown), and the like.

[0270] Those skilled in the art should also understand that the term "computer-readable media" used in connection with the disclosed subject matter does not include transmission media, carrier waves, or other transient signals.

[0271] The computer system (1300) may also include an interface (1354) to one or more communication networks (1355). The one or more communication networks (1355) may be wireless, wired, or optical. The one or more communication networks (1355) may also be local area networks, wide area networks, metropolitan area networks, vehicle-mounted networks, and industrial networks, real-time networks, delay-tolerant networks, and the like. Examples of the one or more communication networks (1355) may include local area networks such as Ethernet, wireless local area networks, cellular networks (GSM, 3G, 4G, 5G, LTE, etc.), television wired or wireless wide area digital networks (including cable television, satellite television, and terrestrial broadcast television), vehicle-mounted and industrial networks (including CANBus), and the like. Some networks typically require an external network interface adapter for connecting to some universal data port or peripheral bus (1349) (e.g., a USB port of the computer system (1300)); other systems 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 integrated into a PC computer system or a cellular network interface integrated into a smart phone computer system). By using any of these networks, the computer system (1300) can communicate with other entities. The communication can be one-way, for reception only (e.g., wireless television), one-way, for transmission only (e.g., CAN bus to certain CAN bus devices), or two-way, such as to other computer systems via local or wide area digital networks. Each of the above networks and network interfaces can use certain protocols and protocol stacks.

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

[0273] The core (1340) may include one or more central processing units (CPUs) (1341), graphics processing units (GPUs) (1342), dedicated programmable processing units in the form of field programmable gate arrays (FPGAs) (1343), hardware accelerators for specific tasks (1344), etc. These devices, as well as read-only memory (ROM) (1345), random access memory (1346), internal mass storage (e.g., internal non-user accessible hard disk drives, solid-state drives, etc.) (1347), etc., may be connected via a system bus (1348). In some computer systems, the system bus (1348) may be accessed in the form of one or more physical plugs so that it can be expanded by additional central processing units, graphics processing units, etc. Peripheral devices may be directly attached to the core's system bus (1348), or connected via a peripheral bus (1349). The architecture of the peripheral bus includes PCI, USB, etc.

[0274] The CPU (1341), GPU (1342), FPGA (1343) and accelerator (1344) can execute certain instructions, which can be combined to form the above-mentioned computer code. The computer code can be stored in ROM (1345) or RAM (1346). Transition data can also be stored in RAM (1346), while permanent data can be stored in, for example, internal mass storage (1347). Fast storage and retrieval of any memory device can be achieved by using a cache memory, which can be closely associated with one or more CPUs (1341), GPUs (1342), mass storage (1347), ROM (1345), RAM (1346), etc.

[0275] The computer readable medium may have computer code thereon for performing various computer-implemented operations. The medium and computer code may be specially designed and constructed for the purpose of this application, or may be medium and code well known and available to those skilled in the art of computer software.

[0276] As an example and not a limitation, a computer system having an architecture (1300), in particular a core (1340), can provide the function of executing software contained in one or more tangible computer-readable media as a processor (including a CPU, a GPU, an FPGA, an accelerator, etc.). Such a computer-readable medium can be a medium associated with the above-mentioned user-accessible mass storage, as well as a specific memory of the core (1340) having non-volatility, such as a core internal mass storage (1347) or a ROM (1345). Software implementing various embodiments of the present application can be stored in such a device and executed by the core (1340). Depending on specific needs, the computer-readable medium may include one or more storage devices or chips. The software can enable the core (1340), in particular the processor therein (including a CPU, a GPU, an FPGA, etc.) to perform a specific process or a specific part of a specific process described herein, including defining a data structure stored in the RAM (1346) and modifying such a data structure according to a software-defined process. Additionally or alternatively, the computer system may provide functionality hardwired in logic or otherwise contained in circuitry (e.g., accelerator (1344)) that may operate in place of or in conjunction with software to perform a particular process or a particular portion of a particular process described herein. Where appropriate, references to software may include logic and vice versa. Where appropriate, references to computer-readable media may include circuitry (e.g., an integrated circuit (IC)) storing execution software, circuitry containing execution logic, or both. The present application includes any suitable combination of hardware and software.

[0277] Although the present application has described a number of exemplary embodiments, various changes, arrangements and various equivalent substitutions of the embodiments are within the scope of the present application. Therefore, it should be understood that those skilled in the art can design a variety of systems and methods, which, although not explicitly shown or described herein, embody the principles of the present application and are therefore within the spirit and scope of the present application.

[0278] Appendix A: Acronyms

[0279] AMT: Adaptive Multiple Transform

[0280] AMVP: Advanced Motion Vector Prediction

[0281] ASIC: Application-Specific Integrated Circuit

[0282] ATMVP: Optional / Advanced Temporal Motion Vector Prediction BDOF: Bidirectional Optical Flow

[0283] BDPCM (or RDPCM): Residual Pulse Code Modulation BIO: Bidirectional Optical Flow

[0284] BMS: Benchmark Collection

[0285] BT: Binary Tree

[0286] BV: Block Vector

[0287] CANBus: Controller Area Network Bus

[0288] CB: Coded Block

[0289] CBF: Coded Block Flag

[0290] CCLM: Cross-Component Linear Model

[0291] CD: Compact Disc

[0292] CPR: Current Picture Reference

[0293] CPU: Central Processing Unit

[0294] CRT: cathode ray tube

[0295] CTB: Coding Tree Block

[0296] CTU: Coding Tree Unit

[0297] CU: Coding Unit

[0298] DM: Derived Mode

[0299] DPB: Decoder Picture Buffer

[0300] DVD: Digital Video Disc EMT: Enhanced Multi-Transform FPGA: Field Programmable Gate Array

[0301] GOP: Group of Pictures

[0302] GPU: Graphics Processing Unit

[0303] GSM: Global System for Mobile Communications

[0304] HDR: High Dynamic Range

[0305] HEVC: High Efficiency Video Coding

[0306] HRD: Hypothesized Reference Decoder

[0307] IBC: Intra Block Copy

[0308] IC: Integrated Circuit

[0309] IDT: Identification Transformation

[0310] ISP: Intra-frame sub-partitioning

[0311] JEM: Joint Development Model

[0312] JVET: Joint Video Development Team

[0313] LAN: Local Area Network

[0314] LCD: Liquid Crystal Display

[0315] LFNST: Low Frequency Non-separable Transform

[0316] LTE: Long Term Evolution

[0317] L_CCLM: Left Cross-Component Linear Mode / Model

[0318] LT_CCLM: Upper Left Cross-Component Linear Mode / Model

[0319] MIP: Matrix-based intra prediction

[0320] MPM: Maximum Probable Mode

[0321] MRLP (or MRL): Multiple Reference Line Prediction

[0322] MTS:Multiple Transformation Selection

[0323] MV: Motion Vector

[0324] NSST: Non-separable quadratic transform

[0325] OLED: Organic Light Emitting Diode

[0326] PBs: prediction blocks

[0327] PCI: Peripheral Component Interconnect

[0328] PDPC: Position Dependent Prediction Combination

[0329] PLD: Programmable Logic Device

[0330] PPR: Parallel-Processable Region

[0331] PPS: Picture Parameter Set

[0332] PU: prediction unit

[0333] QT: Quadtree

[0334] RAM: Random Access Memory

[0335] ROM: Read Only Memory

[0336] RST: Reduced Quadratic Transform

[0337] SBT: Sub-Block Transform

[0338] SCC: Screen Content Coding

[0339] SCIPU: Minimum Chroma Intra Prediction Unit SDR: Standard Dynamic Range

[0340] SEI: Supplemental Enhancement Information

[0341] SNR: Signal to Noise Ratio

[0342] SPS: Sequence Parameter Set

[0343] SSD: Solid State Drive

[0344] SVT: Space Varying Transform

[0345] TSM: Transform Skip Mode

[0346] TT: Triple Tree

[0347] TU: Transformation Unit

[0348] T_CCLM: Top Cross Component Linear Mode / Model

[0349] USB: Universal Serial Bus

[0350] VPDU:Vision Processing Data Unit

[0351] VPS: Video Parameter Set

[0352] VUI: Video Availability Information

[0353] VVC: Next Generation Video Coding

[0354] WAIP: Wide Angle Intra Prediction

Claims

1. A video decoding method, characterized in that: include: Decoding prediction information of a current block of a current picture in an encoded bitstream, the prediction information indicating a geometric partition mode GPM of the current block, the current block being divided into two partitions under the geometric partition mode GPM, each of the partitions being associated with a corresponding prediction value; Determining a weighted index of the sample of the current block based on a position of the sample; calculating the weighting factor based on the weighted index of the sample according to an equation that converts the weighted index to the weighting factor; as well as reconstructing the sample based on the weighting factor and the predicted value corresponding to the sample; The determining the weighted index comprises: determining, based on the GPM, an angle index and a distance index for defining a partition boundary between the partitions of the current block; as well as The weighted index of the sample is determined based on the position of the sample, the angle index, and the distance index.

2. The method according to claim 1, characterized in that The calculations include: performing a right shift operation on the sum of the weighted index and the offset value; and The result of the right shift operation is clipped within a predetermined range.

3. The method according to claim 2, characterized in that The offset value is based on a 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 the weighted index and a size of a cosine table used to calculate the weighted index.

4. The method according to claim 1, characterized in that: The calculations include: determining a partition index based on the angle index; and The weighting factor is calculated based on the partition index.

5. The method according to claim 4, characterized in that The equation is weight=Clip3(0,8,(wIdxL+(1<<(idx2wShiftBit-1)))>>idx2wShiftBit), in wIdxL=(1<<(idx2wShiftBit+2))+(partIdx?wIdx:-wIdx), Among them, idx2wShiftBit indicates the number of bits shifted by the right shift operation, weight is the weighting factor, partIdx is the partition index, wIdx is the weighted index, and Clip3() is the clipping function.

6. The method according to claim 1, characterized in that The equation is a piecewise constant function including an initial value and a plurality of unit step functions.

7. The method according to claim 6, characterized in that The initial value is one of a minimum weighting factor value and a maximum weighting factor value, and the number of the plurality of unit step functions is equal to a total number of different weighting factor values ​​minus one.

8. A video encoding method for generating a bit stream, characterized in that: include: Setting prediction information of a current block of a current picture, the prediction information indicating a geometric partition mode GPM of the current block, the current block being divided into two partitions under the geometric partition mode GPM, each of the partitions being associated with a corresponding prediction value; Determining a weighted index of the sample of the current block based on a position of the sample; calculating the weighting factor based on the weighted index of the sample according to an equation that converts the weighted index to the weighting factor; as well as encoding the sample based on the weighting factor and the predicted value corresponding to the sample; The determining the weighted index comprises: determining, based on the GPM, an angle index and a distance index for defining a partition boundary between the partitions of the current block; as well as The weighted index of the sample is determined based on the position of the sample, the angle index, and the distance index.

9. A video decoding device, characterized in that: comprising a processing circuit, the processing circuit being configured to: The method for video decoding according to any one of claims 1 to 7 is performed.

10. A video encoding device, characterized in that: The method comprises a processing circuit, wherein the processing circuit is configured to: execute the video encoding method according to any one of claims 1-8.

11. A method for storing a code stream, characterized in that: A video code stream is stored on a non-volatile computer-readable storage medium, wherein the video code stream is generated according to the encoding method according to claim 8, or is decoded according to the decoding method according to any one of claims 1 to 7.

12. A non-volatile computer-readable storage medium storing a program, characterized in that: When the instructions are executed by a computer for video encoding and decoding, the computer is caused to execute: executing the method according to any one of claims 1 to 8.

13. A computer device, characterized in that: The computer device comprises: at least one memory configured to store program code; and At least one processor is configured to read the program code and operate according to instructions of the program code to execute the method according to any one of claims 1 to 8.