Code prediction for multiple color components in video coding
Patent Information
- Application Number
- JP2023532597
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2021-12-21
- Filing Date
- 2021-12-22
- Publication Date
- 2024-12-17
- Estimated Expiration
- 2041-12-22
AI Technical Summary
【0012】 1つまたは複数の例の詳細が、添付の図面および以下の説明に記載される。他の特徴、目的、および利点は、説明、図面、および特許請求の範囲から明らかになるであろう。
Smart Images

Figure 00000000_0000_ABST
Abstract
Description
[Technical field]
[0001] This application claims priority to U.S. Application No. 17 / 645,439, filed December 21, 2021, and U.S. Provisional Application No. 63 / 131,615, filed December 29, 2020, the entire contents of which are incorporated herein by reference. U.S. Application No. 17 / 645,439, filed December 21, 2021, claims the benefit of U.S. Provisional Application No. 63 / 131,615, filed December 29, 2020.
[0002] TECHNICAL FIELD This disclosure relates to video encoding and decoding. [Background technology]
[0003] Digital video capabilities may be incorporated into a wide range of devices, including digital televisions, digital direct broadcast systems, wireless broadcast systems, personal digital assistants (PDAs), laptop or desktop computers, tablet computers, e-book readers, digital cameras, digital recording devices, digital media players, video gaming devices, video game consoles, cellular or satellite radio telephones, so-called "smartphones," video teleconferencing devices, video streaming devices, and the like. Digital video devices implement video coding techniques, such as those described in standards defined by MPEG-2, MPEG-4, ITU-T H.263, ITU-T H.264 / MPEG-4, Part 10, Advanced Video Coding (AVC), ITU-T H.265 / High Efficiency Video Coding (HEVC), and extensions to such standards. By implementing such video coding techniques, video devices may more efficiently transmit, receive, encode, decode, and / or store digital video information.
[0004] Video coding techniques include spatial (intra-picture) prediction and / or temporal (inter-picture) prediction to reduce or remove redundancy inherent in video sequences. For block-based video coding, a video slice (e.g., a video picture or a portion of a video picture) may be partitioned into video blocks, which may also be referred to as coding tree units (CTUs), coding units (CUs), and / or coding nodes. Video blocks in an intra-coded (I) slice of a picture are encoded using spatial prediction with respect to reference samples in neighboring blocks in the same picture. Video blocks in an inter-coded (P or B) slice of a picture may use spatial prediction with respect to reference samples in neighboring blocks in the same picture or temporal prediction with respect to reference samples in other reference pictures. A picture may be referred to as a frame, and a reference picture may be referred to as a reference frame. [Prior art documents] [Non-patent literature]
[0005] [Non-Patent Document 1] Bross et al., "Versatile Video Coding (Draft 10)," Joint Video Experts Team (JVET) of ITU-T SG 16 WP 3 and ISO / IEC JTC 1 / SC 29 / WG 11, 18th Meeting: Remote Conference, June 22-July 1, 2020, JVET-S2001-vA [Non-Patent Document 2] The Joint Exploration Model (JEM), ieeexplore.ieee.org / document / 8861068 Summary of the Invention [Means for solving the problem]
[0006] In general, this disclosure describes techniques for coding video data using sign prediction performed based on multiple color components of the video data. To predict a sign value for a coefficient of multiple coefficients of a transform block, a video coder (e.g., a video encoder and / or a video decoder) may reconstruct the transform block using both positive and negative values of the coefficient's sign value. Each block reconstruction using a candidate code value may be referred to as a hypothetical reconstruction. The video coder may evaluate two hypothetical reconstructions for the sign of the coefficient using a cost function and select the hypothetical reconstruction that minimizes the cost function and provides the predicted code value for the coefficient of the transform block. However, in some examples, multiple blocks may be affected by the predicted code value. For example, if the transform block is a joint coding of chroma residual (JCCR) transform block from which the video coder generates multiple transform blocks, each corresponding to a different color component, the multiple transform blocks may all be affected by the predicted code value. Performing sign prediction based on only one color component may be suboptimal because one hypothetical reconstruction may work well for one color component but not for the other color component.
[0007] According to one or more techniques of this disclosure, a video coder (e.g., a video encoder and / or a video decoder) may perform code prediction based on multiple color components of video data. For example, when performing code prediction on a JCCR transform block used to generate multiple transform blocks (e.g., a Cb transform block and a Cr transform block), each corresponding to a different color component, the video coder may perform code prediction based on the multiple color components. By performing code prediction based on the multiple color components, the techniques of this disclosure may improve code prediction. The improved code prediction may reduce the number of bits required to signal a code. In this manner, the techniques of this disclosure may improve coding efficiency.
[0008] In one example, a method for decoding video data includes predicting signs of coefficients of a plurality of coefficients of a joint residual block of a block of video data based on a plurality of color components of the block of video data coded using JCCR, generating, for each color component of the plurality of color components, a coefficient of a respective one of the plurality of residual blocks based on the plurality of coefficients of the joint residual block, and reconstructing the block of video data based on the plurality of residual blocks.
[0009] In another example, a method for encoding video data includes predicting signs of coefficients of a plurality of coefficients of a joint residual block of the block of video data based on a plurality of color components of the block of video data coded using JCCR, generating, for each color component of the plurality of color components, a coefficient of a respective one of the plurality of residual blocks based on the plurality of coefficients of the joint residual block, and reconstructing the block of video data based on the plurality of residual blocks.
[0010] In another example, a device for coding video data includes means for predicting signs of coefficients of a plurality of coefficients of a joint residual block of a block of video data based on a plurality of color components of the block of video data coded using JCCR, means for generating, for each color component of the plurality of color components, a coefficient of a respective residual block of the plurality of residual blocks based on the plurality of coefficients of the joint residual block, and means for reconstructing the block of video data based on the plurality of residual blocks.
[0011] In another example, a computer-readable storage medium stores instructions that, when executed, cause one or more processors of a video coder to predict signs of coefficients of a plurality of coefficients of a joint residual block of a block of video data based on a plurality of color components of the block of video data coded using JCCR, generate, for each color component of the plurality of color components, a coefficient of a respective residual block of the plurality of residual blocks based on the plurality of coefficients of the joint residual block, and reconstruct the block of video data based on the plurality of residual blocks.
[0012] The details of one or more examples are set forth in the accompanying drawings and the description below. Other features, objects, and advantages will become apparent from the description, drawings, and claims. [Brief description of the drawings]
[0013] [Figure 1] FIG. 1 is a block diagram illustrating an example video encoding and decoding system that may implement the techniques of this disclosure. [Figure 2A] FIG. 1 is a conceptual diagram illustrating an exemplary quad-tree binary tree (QTBT) structure. [Figure 2B] FIG. 2 is a conceptual diagram illustrating a corresponding coding tree unit (CTU). [Diagram 3] 1 is a block diagram illustrating an example video encoder that may perform the techniques of this disclosure. [Figure 4] 1 is a block diagram illustrating an example video decoder that may perform the techniques of this disclosure. [Diagram 5] FIG. 1 is a conceptual diagram illustrating coefficient scanning of an 8×8 transform block including four coefficient groups in HEVC. [Figure 6] FIG. 13 is a conceptual diagram illustrating an example of coefficient sign prediction. [Figure 7] 1 is a flowchart illustrating an example method for encoding a current block, in accordance with techniques of this disclosure. [Figure 8]5 is a flowchart illustrating an example method for decoding a current block, in accordance with techniques of this disclosure. [Figure 9] 5 is a flowchart illustrating an example method for decoding a current block using sign prediction based on multiple color components, in accordance with techniques of this disclosure. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0014] In general, this disclosure describes techniques for coding video data using sign prediction performed based on multiple color components of the video data. To predict a sign value for a coefficient of multiple coefficients of a transform block, a video coder (e.g., a video encoder and / or a video decoder) may reconstruct the transform block using both positive and negative values of the coefficient's sign value. Each block reconstruction using a candidate code value may be referred to as a hypothetical reconstruction. The video coder may evaluate two hypothetical reconstructions for the sign of the coefficient using a cost function and select the hypothetical reconstruction that minimizes the cost function and provides the predicted code value for the coefficient of the transform block. However, in some examples, multiple blocks may be affected by the predicted code value. For example, if the transform block is a joint coding of chroma residual (JCCR) transform block from which the video coder generates multiple transform blocks, each corresponding to a different color component, the multiple transform blocks may all be affected by the predicted code value. Performing sign prediction based on only one color component may be suboptimal because one hypothetical reconstruction may work well for one color component but not for the other color component.
[0015] According to one or more techniques of this disclosure, a video coder (e.g., a video encoder and / or a video decoder) may perform code prediction based on multiple color components of video data. For example, when performing code prediction on a JCCR transform block used to generate multiple transform blocks (e.g., a Cb transform block and a Cr transform block), each corresponding to a different color component, the video coder may perform code prediction based on the multiple color components. By performing code prediction based on the multiple color components, the techniques of this disclosure may improve code prediction. The improved code prediction may reduce the number of bits required to signal a code. In this manner, the techniques of this disclosure may improve coding efficiency.
[0016] 1 is a block diagram illustrating an example video encoding and decoding system 100 that may perform techniques of this disclosure. The techniques of this disclosure are generally directed to coding (encoding and / or decoding) video data. In general, video data includes any data for processing video. Thus, video data may include raw uncoded video, coded video, decoded (e.g., reconstructed) video, and video metadata, such as signaling data.
[0017] As shown in Figure 1, system 100 includes a source device 102 that provides encoded video data to be decoded and displayed by a destination device 116, in this example. Specifically, source device 102 provides the video data to destination device 116 via a computer-readable medium 110. Source device 102 and destination device 116 may comprise any of a wide range of devices, including desktop computers, notebook (i.e., laptop) computers, mobile devices, tablet computers, set-top boxes, telephone handsets such as smartphones, televisions, cameras, display devices, digital media players, video gaming consoles, video streaming devices, broadcast receiver devices, and the like. In some cases, source device 102 and destination device 116 may be equipped for wireless communication and therefore may be referred to as wireless communication devices.
[0018] In the example of FIG. 1, source device 102 includes a video source 104, memory 106, video encoder 200, and output interface 108. Destination device 116 includes an input interface 122, a video decoder 300, memory 120, and a display device 118. According to this disclosure, the video encoder 200 of source device 102 and the video decoder 300 of destination device 116 may be configured to apply techniques for code prediction for multiple color components. Thus, source device 102 represents an example of a video encoding device, and destination device 116 represents an example of a video decoding device. In other examples, the source device and destination device may include other components or configurations. For example, source device 102 may receive video data from an external video source, such as an external camera. Similarly, destination device 116 may interface with an external display device rather than including an integrated display device.
[0019] The system 100 as shown in FIG. 1 is only an example. In general, any digital video encoding and / or decoding device may perform techniques for code prediction for multiple color components. The source device 102 and the destination device 116 are only examples of coding devices that generate coded video data for the source device 102 to transmit to the destination device 116. This disclosure refers to devices that perform coding (encoding and / or decoding) of data as "coding" devices. Thus, the video encoder 200 and the video decoder 300 represent examples of coding devices, specifically, video encoders and video decoders, respectively. In some examples, the source device 102 and the destination device 116 may operate in a substantially symmetrical manner such that each of the source device 102 and the destination device 116 includes video encoding and decoding components. Thus, the system 100 may support unidirectional or bidirectional video transmission between the source device 102 and the destination device 116, for example, video streaming, video playback, video broadcasting, or video telephony.
[0020] In general, video source 104 represents a source of video data (i.e., raw, unencoded video data) and provides a continuous series of pictures (also called “frames”) of the video data to video encoder 200, which encodes the data for the pictures. Video source 104 of source device 102 may include a video capture device, such as a video camera, a video archive containing previously captured raw video, and / or a video feed interface for receiving video from a video content provider. As a further alternative, video source 104 may generate computer graphics-based data as source video, or a combination of live, archived, and computer-generated video. In each case, video encoder 200 encodes the captured, pre-captured, or computer-generated video data. Video encoder 200 may reorder the pictures from the order in which they were received (sometimes called “display order”) into a coding order for coding. Video encoder 200 may generate a bitstream including the encoded video data. The source device 102 may then output the encoded video data via the output interface 108 onto a computer-readable medium 110 for receipt and / or retrieval by, for example, an input interface 122 of the destination device 116 .
[0021] The memory 106 of the source device 102 and the memory 120 of the destination device 116 represent general-purpose memories. In some examples, the memories 106, 120 may store raw video data, e.g., raw video from the video source 104 and raw decoded video data from the video decoder 300. Additionally or alternatively, the memories 106, 120 may store software instructions executable by, e.g., the video encoder 200 and the video decoder 300, respectively. Although the memories 106 and 120 are shown separately from the video encoder 200 and the video decoder 300 in this example, it should be understood that the video encoder 200 and the video decoder 300 may also include internal memories for functionally similar or equivalent purposes. Additionally, the memories 106, 120 may store encoded video data, e.g., the output from the video encoder 200 and the input to the video decoder 300. In some examples, a portion of the memory 106, 120 may be allocated as one or more video buffers, for example, for storing raw, decoded, and / or encoded video data.
[0022] The computer-readable medium 110 may represent any type of medium or device capable of transporting encoded video data from the source device 102 to the destination device 116. In one example, the computer-readable medium 110 represents a communication medium that allows the source device 102 to transmit encoded video data directly to the destination device 116 in real time, for example, via a radio frequency network or a computer-based network. The output interface 108 may modulate a transmission signal including the encoded video data and the input interface 122 may demodulate a received transmission signal according to a communication standard such as a wireless communication protocol. The communication medium may comprise any wireless or wired communication medium, such as a radio frequency (RF) spectrum or one or more physical transmission lines. The communication medium may form part of a packet-based network, such as a local area network, a wide area network, or a global network such as the Internet. The communication medium may include routers, switches, base stations, or any other equipment that may be useful to facilitate communication from the source device 102 to the destination device 116.
[0023] In some examples, source device 102 may output the encoded data from output interface 108 to storage device 112. Similarly, destination device 116 may access the encoded data from storage device 112 via input interface 122. Storage device 112 may include any of a variety of distributed or locally accessed data storage media, such as a hard drive, a Blu-ray disc, a DVD, a CD-ROM, flash memory, volatile or non-volatile memory, or any other suitable digital storage medium for storing encoded video data.
[0024] In some examples, source device 102 may output the encoded video data to a file server 114 or another intermediate storage device, which may store the encoded video data generated by source device 102. Destination device 116 may access the stored video data from file server 114 via streaming or download.
[0025] The file server 114 may be any type of server device capable of storing encoded video data and transmitting the encoded video data to the destination device 116. The file server 114 may represent a web server (e.g., for a website), a server configured to provide file transfer protocol services (such as File Transfer Protocol (FTP) or File Delivery over Unidirectional Transport (FLUTE) protocol), a Content Delivery Network (CDN) device, a Hypertext Transfer Protocol (HTTP) server, a Multimedia Broadcast Multicast Service (MBMS) or enhanced MBMS (eMBMS) server, and / or a Network Attached Storage (NAS) device. The file server 114 may additionally or alternatively implement one or more HTTP streaming protocols, such as Dynamic Adaptive Streaming over HTTP (DASH), HTTP Live Streaming (HLS), Real Time Streaming Protocol (RTSP), HTTP Dynamic Streaming, etc.
[0026] The destination device 116 may access the encoded video data from the file server 114 through any standard data connection, including an Internet connection. This may include a wireless channel (e.g., a Wi-Fi connection), a wired connection (e.g., a digital subscriber line (DSL), a cable modem, etc.), or a combination of both suitable for accessing the encoded video data stored on the file server 114. The input interface 122 may be configured to operate according to any one or more of the various protocols discussed above for retrieving or receiving media data from the file server 114 or other such protocols for retrieving media data.
[0027] The output interface 108 and the input interface 122 may represent a wireless transmitter / receiver, a modem, a wired networking component (e.g., an Ethernet card), a wireless communication component operating according to any of the various IEEE 802.11 standards, or other physical components. In examples in which the output interface 108 and the input interface 122 comprise wireless components, the output interface 108 and the input interface 122 may be configured to transfer data, such as encoded video data, according to a cellular communication standard, such as 4G, 4G-LTE (Long Term Evolution), LTE Advanced, 5G, etc. In some examples in which the output interface 108 comprises a wireless transmitter, the output interface 108 and the input interface 122 may be configured to transfer data, such as encoded video data, according to other wireless standards, such as the IEEE 802.11 specification, the IEEE 802.15 specification (e.g., ZigBee™), the Bluetooth™ standard, etc. In some examples, the source device 102 and / or the destination device 116 may include respective system-on-chip (SoC) devices. For example, the source device 102 may include a SoC device for performing functions attributed to the video encoder 200 and / or the output interface 108, and the destination device 116 may include a SoC device for performing functions attributed to the video decoder 300 and / or the input interface 122.
[0028] The techniques of this disclosure may be applied to video coding supporting any of a variety of multimedia applications, such as over-the-air television broadcast, cable television transmission, satellite television transmission, Internet streaming video transmission such as Dynamic Adaptive Streaming over HTTP (DASH), digital video encoded on a data storage medium, decoding of digital video stored on a data storage medium, or other applications.
[0029] The input interface 122 of the destination device 116 receives an encoded video bitstream from the computer-readable medium 110 (e.g., a communication medium, a storage device 112, a file server 114, etc.). The encoded video bitstream may include signaling information defined by the video encoder 200 and also used by the video decoder 300, such as syntax elements having values that describe characteristics and / or processing of video blocks or other coded units (e.g., slices, pictures, groups of pictures, sequences, etc.). The display device 118 displays decoded pictures of the decoded video data to a user. The display device 118 may represent any of a variety of display devices, such as a liquid crystal display (LCD), a plasma display, an organic light emitting diode (OLED) display, or another type of display device.
[0030] 1, in some examples, the video encoder 200 and the video decoder 300 may each be integrated with an audio encoder and / or an audio decoder and may include an appropriate MUX-DEMUX unit, or other hardware and / or software, to process multiplexed streams that include both audio and video in a common data stream. Where applicable, the MUX-DEMUX unit may conform to the ITU H.223 multiplexer protocol or other protocols, such as the User Datagram Protocol (UDP).
[0031] The video encoder 200 and the video decoder 300 may each be implemented as any of a variety of suitable encoder and / or decoder circuits, such as one or more microprocessors, digital signal processors (DSPs), application specific integrated circuits (ASICs), field programmable gate arrays (FPGAs), discrete logic, software, hardware, firmware, or any combination thereof. When the techniques are implemented partially in software, a device may store instructions for the software on a suitable non-transitory computer-readable medium and execute the instructions in hardware using one or more processors to perform the techniques of this disclosure. Each of the video encoder 200 and the video decoder 300 may be included in one or more encoders or decoders, any of which may be integrated as part of a combined encoder / decoder (CODEC) in the respective device. A device including the video encoder 200 and / or the video decoder 300 may comprise an integrated circuit, a microprocessor, and / or a wireless communication device such as a cellular phone.
[0032] Video encoder 200 and video decoder 300 may operate according to a video coding standard, such as ITU-T H.265, also known as High Efficiency Video Coding (HEVC), or extensions thereof, such as multiview and / or scalable video coding extensions. Alternatively, video encoder 200 and video decoder 300 may operate according to other proprietary or industry standards, such as ITU-T H.266, also known as Versatile Video Coding (VVC). A draft of the VVC standard is set forth in Bross et al., "Versatile Video Coding (Draft 10)," Joint Video Experts Team (JVET) of ITU-T SG 16 WP 3 and ISO / IEC JTC 1 / SC 29 / WG 11, 18th Meeting: Remote Conference, June 22-July 1, 2020, JVET-S2001-vA (hereinafter "VVC Draft 10"). However, the techniques of this disclosure are not limited to any particular coding standard.
[0033] In general, the video encoder 200 and the video decoder 300 may perform block-based coding of pictures. The term “block” generally refers to a structure that includes data to be processed (e.g., encoded, decoded, or otherwise used in an encoding and / or decoding process). For example, a block may include a two-dimensional matrix of samples of luminance and / or chrominance data. In general, the video encoder 200 and the video decoder 300 may code video data represented in a YUV (e.g., Y, Cb, Cr) format. That is, rather than coding red, green, and blue (RGB) data for samples of a picture, the video encoder 200 and the video decoder 300 may code luminance and chrominance components, where the chrominance components may include chrominance components of both red and blue hues. In some examples, the video encoder 200 converts received RGB formatted data to a YUV representation prior to encoding, and the video decoder 300 converts the YUV representation to an RGB format. Alternatively, pre-processing and post-processing units (not shown) may perform these conversions.
[0034] This disclosure may generally refer to coding (e.g., encoding and decoding) a picture to include the process of encoding or decoding data for a picture. Similarly, this disclosure may refer to coding of a block of a picture, e.g., predictive and / or residual coding, to include the process of encoding or decoding data for the block. A coded video bitstream generally includes a set of values for syntax elements that represent coding decisions (e.g., coding modes) and partitioning of a picture into blocks. Thus, references to coding a picture or a block should generally be understood as coding values for the syntax elements that form the picture or block.
[0035] HEVC defines various blocks, including coding units (CUs), prediction units (PUs), and transform units (TUs). According to HEVC, a video coder (such as the video encoder 200) partitions coding tree units (CTUs) into CUs according to a quadtree structure. That is, the video coder partitions CTUs and CUs into four equal non-overlapping squares, and each node of the quadtree has either zero or four child nodes. A node without child nodes may be called a "leaf node", and a CU of such a leaf node may include one or more PUs and / or one or more TUs. The video coder may further partition PUs and TUs. For example, in HEVC, a residual quadtree (RQT) represents a partition of TUs. In HEVC, a PU represents inter-predicted data, and a TU represents residual data. An intra-predicted CU includes intra-prediction information, such as an intra-mode indication.
[0036] As another example, the video encoder 200 and the video decoder 300 may be configured to operate according to VVC. According to VVC, a video coder (such as the video encoder 200) partitions a picture into multiple coding tree units (CTUs). The video encoder 200 may partition the CTUs according to a tree structure, such as a quad-tree binary tree (QTBT) structure or a multi-type tree (MTT) structure. The QTBT structure eliminates the concept of multiple partition types, such as the distinction between CUs, PUs, and TUs in HEVC. The QTBT structure includes two levels, a first level partitioned according to a quad-tree partition and a second level partitioned according to a binary tree partition. The root node of the QTBT structure corresponds to a CTU. The leaf nodes of the binary tree correspond to coding units (CUs).
[0037] In the MTT partitioning structure, blocks may be partitioned using quad tree (QT) partitioning, binary tree (BT) partitioning, and one or more types of triple tree (TT) (also called ternary tree (TT)) partitioning. Triple tree or ternary tree partitioning is a partitioning in which a block is divided into three sub-blocks. In some examples, triple tree or ternary tree partitioning divides a block into three sub-blocks without splitting the original block through the center. Partition types in MTT (e.g., QT, BT, and TT) may be symmetric or asymmetric.
[0038] In some examples, video encoder 200 and video decoder 300 may use a single QTBT or MTT structure to represent each of the luminance and chrominance components, while in other examples, video encoder 200 and video decoder 300 may use two or more QTBT or MTT structures, such as one QTBT / MTT structure for the luminance component and another QTBT / MTT structure for both chrominance components (or two QTBT / MTT structures for each chrominance component).
[0039] Video encoder 200 and video decoder 300 may be configured to use quadtree partitioning, QTBT partitioning, MTT partitioning, or other partition structures per HEVC. For purposes of illustration, the description of the techniques of this disclosure is presented with respect to QTBT partitioning. However, it should be understood that the techniques of this disclosure may also be applied to video coders configured to use quadtree partitioning, or other types of partitioning.
[0040] In some examples, the CTU includes a coding tree block (CTB) of luma samples, two corresponding CTBs of chroma samples for a picture with three sample arrays, or a CTB of samples for a picture coded using three separate color planes and syntax structures used to code a monochrome picture or sample. The CTB can be an N×N block of samples for some value of N such that the division of the components into the CTB is partitioned. The components are arrays or single samples of that array from one of three arrays (luma and two chromas) that create a picture in 4:2:0, 4:2:2, or 4:4:4 color format, or an array or single samples of that array that create a picture in monochrome format. In some examples, the coding block is an M×N block of samples for some value of M and N such that the division of the CTB into the coding block is partitioned.
[0041] Blocks (e.g., CTUs or CUs) may be grouped in various ways in a picture. As an example, a brick may refer to a rectangular region of a CTU row in a particular tile in a picture. A tile may be a rectangular region of CTUs in a particular tile column and a particular tile row in a picture. A tile column refers to a rectangular region of CTUs with a height equal to the height of the picture and a width specified by a syntax element (e.g., in a picture parameter set, etc.). A tile row refers to a rectangular region of CTUs with a height specified by a syntax element (e.g., in a picture parameter set, etc.) and a width equal to the width of the picture.
[0042] In some examples, a tile may be partitioned into multiple bricks, each of which may include one or more CTU rows within the tile. A tile that is not partitioned into multiple bricks may also be referred to as a brick. However, a brick that is a true subset of a tile may not be referred to as a tile.
[0043] Bricks in a picture may also be arranged in slices. A slice may be an integer number of bricks of a picture that may be contained exclusively in a single Network Abstraction Layer (NAL) unit. In some examples, a slice may contain either a certain number of complete tiles or only a contiguous sequence of complete bricks of one tile.
[0044] This disclosure may use "NxN" and "N by N" interchangeably to refer to the sample dimensions of a block (such as a CU or other video block) in terms of vertical and horizontal dimensions, e.g., 16x16 samples or 16 by 16 samples. Generally, a 16x16 CU has 16 samples in the vertical direction (y=16) and 16 samples in the horizontal direction (x=16). Similarly, an NxN CU generally has N samples in the vertical direction and N samples in the horizontal direction, where N represents a non-negative integer value. Samples within a CU may be arranged in rows and columns. Furthermore, a CU does not necessarily have to have the same number of samples in the horizontal direction as in the vertical direction. For example, a CU may comprise NxM samples, where M is not necessarily equal to N.
[0045] The video encoder 200 encodes video data for a CU that represents prediction and / or residual information, as well as other information. The prediction information indicates how the CU will be predicted to form a predictive block for the CU. The residual information generally represents sample-by-sample differences between samples of the CU and samples of the predictive block prior to encoding.
[0046] To predict a CU, the video encoder 200 may generally form a predictive block for the CU through inter prediction or intra prediction. Inter prediction generally refers to predicting a CU from data of a previously coded picture, while intra prediction generally refers to predicting a CU from previously coded data of the same picture. To perform inter prediction, the video encoder 200 may generate a predictive block using one or more motion vectors. The video encoder 200 may generally perform motion search to identify a reference block that closely matches the CU, for example, with respect to the difference between the CU and the reference block. The video encoder 200 may calculate a difference metric using a sum of absolute differences (SAD), sum of squared differences (SSD), mean absolute difference (MAD), mean squared difference (MSD), or other such difference calculation to determine whether the reference block closely matches the current CU. In some examples, the video encoder 200 may predict the current CU using unidirectional prediction or bidirectional prediction.
[0047] Some examples of VVC also provide an affine motion compensation mode, which may be considered an inter-prediction mode. In an affine motion compensation mode, the video encoder 200 may determine two or more motion vectors that represent non-translational motion, such as zooming in or out, rotation, perspective motion, or other irregular motion types.
[0048] To perform intra prediction, the video encoder 200 may select an intra prediction mode to generate a predictive block. Some examples of VVC provide 67 intra prediction modes, including various orientation modes, as well as a planar mode and a DC mode. In general, the video encoder 200 selects an intra prediction mode that describes neighboring samples relative to a current block (e.g., a block of a CU) from which to predict samples of the current block. Such samples may generally be above, above and to the left, or to the left of the current block in the same picture as the current block, assuming that the video encoder 200 codes CTUs and CUs in raster scan order (left to right, top to bottom).
[0049] Video encoder 200 encodes data representing a prediction mode for the current block. For example, in the case of an inter prediction mode, video encoder 200 may encode data representing which of various available inter prediction modes is used, as well as motion information for the corresponding mode. In the case of unidirectional or bidirectional inter prediction, for example, video encoder 200 may encode motion vectors using advanced motion vector prediction (AMVP) or merge mode. Video encoder 200 may use similar modes to encode motion vectors for affine motion compensation modes.
[0050] Following prediction, such as intra- or inter-prediction, of a block, the video encoder 200 may calculate residual data for the block. The residual data, such as a residual block, represents sample-by-sample differences between a block and a predictive block for that block formed using a corresponding prediction mode. The video encoder 200 may apply one or more transforms to the residual block to generate transform data in a transform domain rather than the sample domain. For example, the video encoder 200 may apply a discrete cosine transform (DCT), an integer transform, a wavelet transform, or a conceptually similar transform to the residual video data. In addition, the video encoder 200 may apply a secondary transform, such as a mode-dependent non-separable secondary transform (MDNSST), a signal-dependent transform, a Karhunen-Loeve transform (KLT), etc., following the first transform. The video encoder 200 generates transform coefficients following application of the one or more transforms.
[0051] As mentioned above, following any transformation to generate transform coefficients, the video encoder 200 may perform quantization of the transform coefficients. Quantization generally refers to a process in which transform coefficients are quantized to possibly reduce the amount of data used to represent the transform coefficients, achieving further compression. By performing a quantization process, the video encoder 200 may reduce the bit depth associated with some or all of the transform coefficients. For example, the video encoder 200 may truncate an n-bit value to an m-bit value during quantization, where n is greater than m. In some examples, to perform quantization, the video encoder 200 may perform a bitwise right shift of the value to be quantized.
[0052] Following quantization, the video encoder 200 may scan the transform coefficients and generate a one-dimensional vector from the two-dimensional matrix including the quantized transform coefficients. The scan may be designed to place transform coefficients of higher energy (and therefore lower frequency) at the front of the vector and transform coefficients of lower energy (and therefore higher frequency) at the rear of the vector. In some examples, the video encoder 200 may utilize a predefined scan order for scanning the quantized transform coefficients to generate a serialized vector and then entropy encode the quantized transform coefficients of the vector. In other examples, the video encoder 200 may perform an adaptive scan. After scanning the quantized transform coefficients to form the one-dimensional vector, the video encoder 200 may entropy encode the one-dimensional vector, e.g., according to context-adaptive binary arithmetic coding (CABAC). The video encoder 200 may also entropy encode values for syntax elements describing metadata associated with the encoded video data for use by the video decoder 300 in decoding the video data.
[0053] To perform CABAC, the video encoder 200 may assign a context in a context model to a symbol to be transmitted. The context may relate, for example, to whether neighboring values of the symbol are zeroed out or not. The probability determination may be based on the context assigned to the symbol.
[0054] Video encoder 200 may further generate syntax data, such as block-based syntax data, picture-based syntax data, and sequence-based syntax data to video decoder 300, for example in a picture header, a block header, a slice header, or other syntax data, such as a sequence parameter set (SPS), a picture parameter set (PPS), or a video parameter set (VPS). Video decoder 300 may similarly decode such syntax data to determine how to decode corresponding video data.
[0055] In this manner, video encoder 200 may generate a bitstream including syntax elements that describe encoded video data, e.g., partitions of a picture into blocks (e.g., CUs) and predictive and / or residual information for the blocks. Finally, video decoder 300 may receive the bitstream and decode the encoded video data.
[0056] In general, video decoder 300 performs a process that is the inverse of that performed by video encoder 200 to decode encoded video data of a bitstream. For example, video decoder 300 may decode values for syntax elements of a bitstream using CABAC in a manner that is the inverse of but substantially similar to the CABAC encoding process of video encoder 200. The syntax elements may define partition information for partitioning of a picture into CTUs and partitioning of each CTU according to a corresponding partition structure, such as a QTBT structure, to define CUs of the CTUs. The syntax elements may further define prediction and residual information for blocks (e.g., CUs) of video data.
[0057] The residual information may be represented, for example, by quantized transform coefficients. The video decoder 300 may dequantize and inverse transform the quantized transform coefficients of the block to reconstruct a residual block for the block. The video decoder 300 uses the signaled prediction mode (intra-prediction or inter-prediction) and associated prediction information (e.g., motion information for inter-prediction) to form a predictive block for the block. The video decoder 300 may then combine (sample-by-sample) the predictive block and the residual block to reconstruct the original block. The video decoder 300 may perform additional processing, such as performing a deblocking process to reduce visual artifacts along block boundaries.
[0058] As described above, the video encoder 200 may encode the transform coefficients, and the video decoder 300 may decode the transform coefficients. For example, to perform transform coefficient coding according to HEVC, the video coder (e.g., the video encoder 200 and / or the video decoder 300) may divide a transform coefficient block (TB) by coefficient group (CG), where each CG may represent a 4×4 sub-block. As an example, a 32×32 TU may be divided into a total of 64 CGs, and a 16×16 TU may be divided into a total of 16 CGs. The video coder may perform entropy coding of the TB in units of CGs. The video coder may code the CGs inside the TB according to a given scanning order. When coding each CG, the video coder may scan and code the coefficients inside the current CG according to a certain predefined scanning order for 4×4 blocks. In the Joint Exploration Model (JEM), ieeexplore.ieee.org / document / 8861068, the CG size can be either 4×4 or 2×2 depending on whether the height or width of one TB is equal to 2. Figure 5 is a conceptual diagram showing the coefficient scanning of 8×8 TB including 4 CGs in HEVC.
[0059] For each color component, the video coder may signal one flag to indicate whether the current TB has at least one nonzero coefficient. For example, the video coder may signal a coded block flag (CBF) or a coded block pattern (CPB) with a value indicating whether the current TB has at least one nonzero coefficient. If there is at least one nonzero coefficient, the video coder may explicitly signal the position of the last significant coefficient in the coefficient scanning order in the TB with coordinates relative to the upper-left corner of the TB. The vertical or horizontal component of the coordinate may be represented by its prefix and suffix, where the prefix may be binarized using truncated Rice (TR) and the suffix is binarized using a fixed length.
[0060] With such coded position and also coefficient scanning order of CG, the video coder may signal, for CG except the last CG (in scanning order), a flag indicating whether the CG contains a non-zero coefficient. For those CGs that may contain non-zero coefficients, the video coder may signal the significance flag of the non-zero coefficient, the absolute value of the coefficient, and the sign information for each coefficient according to a predefined 4×4 coefficient scanning order. In the HEVC transform coefficient entropy coding scheme, the sign bit, if coded, may always be bypass coded, i.e., no context is applied and always one bit is coded for each sign bit using the equal probability (EP) assumption.
[0061] The description of sign data hiding is as follows: In the case of CG, depending on the criteria, the video coder may omit coding the sign of the last non-zero coefficient (in the reverse scan order) that is the first non-zero coefficient in the forward scan order when using sign data hiding (SDH). Instead, the sign value may be embedded in and determined from the parity of the sum of the levels of the CG using a predefined convention (i.e., even numbers correspond to "+" and odd numbers correspond to "-"). The criterion for using SDH may be the distance in the scan order between the first and last non-zero coefficients of the CG. If this distance is equal to or greater than a threshold (e.g., 4 samples), SDH may be used.
[0062] The explanation of coefficient sign prediction is as follows. In order to improve the coding efficiency of the sign bit information, a coefficient sign prediction method has been proposed in the literature. The sign prediction method is proposed at the beginning of JEM.
[0063] To predict the code for one coefficient, the video coder may reconstruct a transform block (TB) using both positive and negative values of this code, and each block reconstruction using a candidate code value may be called a hypothetical reconstruction. The video coder may evaluate two hypothetical reconstructions with a given spatial domain cost function, and the hypothesis that minimizes the cost function gives the predicted code value.
[0064] Furthermore, to predict multiple codes for the TB, e.g., N codes, the video coder may perform a total of 2 N The video coder may reconstruct the TB using different combinations of candidate code predictors, including different hypothesis reconstructions. Similarly, the video coder may evaluate each hypothesis with a given spatial domain cost function, and the hypothesis that minimizes the cost function gives the combination of predicted code values.
[0065] The cost function generally uses one of the hypotheses to measure the spatial discontinuity between the previously reconstructed neighbor pixels and the currently tested reconstructed block. The hypothesis that shows the smoothest pixel value transition at the block boundary of the current block may be considered as the best prediction.
[0066] A conceptual diagram illustrating coefficient sign prediction is shown in Figure 6. In the example of Figure 6, the cost is measured using the leftmost and topmost pixels of the hypothetical reconstruction.
[0067] The video coder may determine the cost according to the following formula:
[0068]
number
[0069] In the above formula, (2p x,_1 -p x,_2 ) terms and (2p _1,y -p _2,y ) term is the predictive component, and p x,0 and p 0,y is the hypothesis reconstruction component.
[0070] In the particular code prediction scheme described in Figure 6, the encoder may first dequantize the TU and then select n coefficients for which codes are to be predicted. The coefficients may be scanned in raster scan order, and when collecting the n coefficients to work with, dequantized values above a defined threshold are preferred over values below that threshold.
[0071] Using these n values, 2 n Simplified boundary reconstructions, ie, one reconstruction for each unique combination of signs for the n coefficients, may be performed as described below.
[0072] To reduce the complexity of performing code prediction, the video coder may perform a template-based hypothesis reconstruction. For a particular hypothesis reconstruction, the video coder may recreate only the leftmost and topmost pixels of the block from the inverse transform added to the block prediction. While the first (vertical) inverse transform is complete, the second (horizontal) inverse transform only needs to create the leftmost and topmost pixel outputs, and is therefore faster. To enable this, an additional flag "topLeft" may be added to the inverse transform function.
[0073] In addition, the number of inverse transform operations performed is reduced by using a system of "templates." In this way, when predicting n symbols in a block, the video coder may perform n+1 inverse transform operations. 1. A single inverse transform operating on the dequantized coefficients, where all predicted sign values are set to positive. When added to the prediction of the current block, this corresponds to the boundary reconstruction of the first hypothesis. 2. For each of the n coefficients with their predicted signs, an inverse transform operation is performed on the otherwise empty block containing the corresponding dequantized (and positive) coefficient as its only non-null element. The leftmost and topmost boundary values are saved in what is called a "template" for use during later reconstruction.
[0074] The boundary reconstruction for a subsequent hypothesis may begin by taking the appropriate saved reconstruction of the previous hypothesis, which only requires that a single predicted sign be changed from positive to negative to construct the desired current hypothesis. This sign change may then be approximated by doubling and subtracting from the template hypothesis boundary corresponding to the sign being predicted. Then, after determining the cost value, the boundary reconstruction is saved if it is known to be reused to construct the subsequent hypothesis.
[0075] [Table 1]
[0076] The above table shows the save / restore and template application for the case of 3 codes and 8 entries. Note that these approximations may only be used during the process of code prediction, not during the final reconstruction.
[0077] For transform coefficients with larger absolute values, sign prediction generally provides a better chance of achieving accurate prediction, since inaccurate sign prediction for transform coefficients with larger absolute values generally indicates more discrepancy to boundary sample smoothness.
[0078] Using sign prediction instead of coding an explicit sign value, the video coder may code the accuracy of the sign prediction. For example, to predict a coefficient sign that actually has a positive value, if the predicted sign is also positive, i.e., the sign prediction is accurate, the video coder may code the "0" bin. Otherwise, if the predicted sign is negative, i.e., the sign prediction is not accurate, the video coder may code the "1" bin. In this way, the video coder may utilize the level value (absolute value) of the transform coefficient as a context for coding the accuracy of the sign prediction, since a larger absolute value of the transform coefficient leans toward a higher probability of the "0" bin.
[0079] A description of joint coding of chroma residual is as follows. Joint coding of chroma residual (JCCR) is a video coding tool that jointly codes chroma residual. When JCCR is used, a single transform coefficient block is signaled for multiple color components. JCCR is part of VVC, one of the most recent video coding standards. In VVC, the JCCR flag at the TU level is supported when at least one of the chroma CBFs is non-zero. If the JCCR flag is TRUE, the decoder parses a single coefficient block from the bitstream and derives pixel residual blocks of chroma components from the single residual block.
[0080] The explanation of cross-component linear model prediction (CCLM) is as follows. CCLM is a prediction method that reduces inter-component redundancy. CCLM is adopted in the VVC video coding standard. When CCLM is used, chroma prediction samples are generated by applying a linear model to the collocated luma samples, as shown in the following equation: pred C (i,j) = α rec L '(i,j) +β In the formula, pred C (i,j) represents the predicted chroma sample in a CU, and rec L (i,j) represents the downsampled reconstructed luma sample of the same CU.
[0081] The above-mentioned techniques may result in one or more drawbacks. For example, when reconstructed samples of multiple color components may be affected by the current transform block (for example, when CCLM or JCCR modes are used), considering only one color component (for example, in the case of sign prediction) may be suboptimal. In particular, one hypothesis reconstruction may work well for one color component but not for other color components.
[0082] According to the techniques of this disclosure, a video coder (e.g., video encoder 200 and / or video decoder 300) may consider multiple color components when performing sign prediction for residual coding. For example, when performing sign prediction on a JCCR transform block used to generate multiple transform blocks (e.g., a Cb transform block and a Cr transform block), each corresponding to a different color component, the video coder may perform sign prediction based on the multiple color components.
[0083] Section A. Joint Sign Prediction of Multiple Transform Blocks. As an example of considering multiple color components in sign prediction, a video coder may perform joint sign prediction of multiple color components. To perform joint sign prediction, multiple color components having interdependencies may be selected. The selection of color components may be based on predefined rules and / or information signaled in the bitstream. Hypothetical reconstructions of all participating color components are generated, and a joint cost (Cost) is calculated from the hypothetical reconstructions. joint ) is derived. The predicted values of the participating codes are determined by minimizing the joint cost value.
[0084] As explained above, in the case of code prediction for a single block with N predicted codes, N There are different combinations, and one of the combinations is selected as the prediction set. In this example, the video coder may jointly perform code prediction of different color components, and the predicted codes of the participating color components may be combined to create a joint set of predicted codes, as shown in the following equation (1). The video coder may select all the participating color components (Set color ) may perform a union operation (U) on the set of predicted codes.
[0085]
number
[0086] N joint= size(Set joint ), then the sign
[0087]
number
[0088] For each combination, a hypothetical reconstruction of all participating color components is generated, and a joint cost (Cost joint ) is derived. joint is used as a criterion for deciding which combination of codes to use to select as the set of predictors for the predictively coded code.
[0089] A special case of joint set generation is when multiple participating color components share a single transform block. For example, when joint coding of chroma residual (JCCR) is applied and sign prediction is performed jointly on Cb and Cr,
[0090] [Number]
[0091] and therefore,
[0092]
number
[0093] A few examples of this special case are discussed below.
[0094] Section B. Sign Prediction of a Current Transform Block. As another example of considering multiple color components in sign prediction, a video coder may consider multiple color components when performing sign prediction for a single transform block. This example may be applied when there are other color components that depend on the current color component. In this case, each of the hypothetical reconstructions may be evaluated not only based on the current color component, but also based on the other color components that may be affected by the current color component. joint ) may be applied. Similar to what is described above in Section A, hypothetical reconstructions of all participating color components are generated and a joint cost is derived based on all these hypothetical reconstructions. For some of the participating color components, a hypothetical reconstruction is generated for cost calculation, while for other components, a simplified criterion may be applied. For example, in the case of a cross-component linear model (CCLM) in VVC, instead of further generating a hypothetical reconstruction of the chroma component, a predicted block of the corresponding chroma component may be generated based on the hypothetical reconstruction of the luma (Y) component, and the chroma prediction block is calculated based on the joint cost (Cost joint ) can be used to derive
[0095] Section C. A video coder may apply one or more conditions for using sign prediction based on multiple color components. An example of a technique of this disclosure may define a rule for a transform block to determine whether to jointly perform sign prediction of multiple transform blocks (as described above in Section A) or consider multiple color components while performing sign prediction of a current transform block (as described above in Section B). The rule may be predefined for both the encoder and decoder sides, signaled in the bitstream, or performed in combination.
[0096] As an example, for a luma block used for a component-to-component linear model (CCLM) in VVC, if the corresponding chroma block has a coded block flag equal to zero (e.g., meaning there are no nonzero coefficients), then that chroma block is considered in the sign prediction of the luma block. In this case, the hypothetical reconstruction of the corresponding chroma block is equal to the predicted block generated from the hypothetical reconstruction of the luma block. When performing the sign prediction of the luma block, it may not be necessary to derive the sample residual of the chroma block.
[0097] Section D. Derivation of Joint Costs for Multiple Color Components. To consider multiple color components, we use the cost values derived from all participating color components (the “joint costs”). joint As an example, the cost of each participating color component is calculated alone, and the joint cost is derived as a combination of the cost values of all participating color components as shown in equation (2), where S denotes the set of color components involved in the sign-predictive coding of the coefficients. The weights of different color components can be fixed, derived based on predefined rules for both the encoder and decoder sides, or controlled by syntax elements signaled in the bitstream.
[0098]
number
[0099] In a special case, one of the weights may be 1 and all other weights are 0. In that case, the joint cost may correspond to selecting one color component, and the video coder may use the joint cost to perform code prediction of the current block.
[0100] An example of incorporating the techniques of this disclosure into joint coding of chroma residual. In a video codec, a transform block may correspond to pixel residual blocks of multiple color components, e.g., joint coding of chroma residual coding (JCCR) in VVC. In such a case, the Cb and Cr components share a single transform block. When performing joint sign prediction on a pair of JCCR-coded Cb and Cr blocks (as described in Section A), Set joint =∪ color∈{Cb,Cr} Set color = Set Cb = Set Cr , and the hypothetical reconstructions of all participating color components can be evaluated when generating the predicted code of the transform block. joint Different methods of deriving the joint cost Cost described in Section D can be used. joint Use derivation.
[0101]
number
[0102] In the formula, S represents the chroma color component, and w color indicates the weight of the color component color.
[0103] How does the video coder color A few examples of how it may be derived are described below. As an example, a fixed value of 1 is used as the cost weight for different chroma formats. In this case, the joint cost Cost joint is derived as follows:
[0104]
number
[0105] As another example, the chroma components are scanned in a specific order (the order can be derived from predefined rules and / or information signaled in the bitstream), and the weight of the first chroma component in the bitstream with a non-zero CBF is set to 1, while other components use 0. For VVC, the chroma components S={Cb,Cr} are ordered as "1:Cb, 2:Cr", and as an example the weights of Cb and Cr are derived as follows: if (CBF_Cb != 0) { w Cb = 1; w Cr = 0; } else / / CBF Cb == 0 && CBF Cr != 0 { w Cb = 0; w Cr = 1; } As another example, the weight of each color component may also be derived based on the corresponding CBF value. For example, if the CBF value of a color component is 0, the weight is set to 0 for that color component, otherwise the weight is set to 1. For VVC, the chroma components S={Cb,Cr} and weights w Cb , w Cr is derived as follows: w Cb = 0; w Cr = 0; if (CBF_Cb != 0) { w Cb = 1; } if (CBF Cr != 0) { w Cr = 1; }
[0106] Examples incorporating the techniques of the present disclosure may be incorporated into coding tools such as CCLM, CCP, etc. In video codecs, prediction between color components may be applied to exploit correlations between different color components of a video signal. For example, cross-component prediction (CCP) in HEVC Range Extension and cross-component linear model (CCLM) in VVC. For a transform block of a particular color component A, if there are other color components that depend on A, the sign prediction of the transform block may be performed jointly on both A and the color components that depend on it. Examples such as those described in Section A (e.g., performing sign prediction jointly on multiple color components) or Section B (e.g., performing sign prediction on a single color component, but considering the impact on multiple color components) may be applied in this case.
[0107] In the case of CCLM mode, for a luma block used for CCLM mode of one or more chroma components, the techniques of this disclosure may be applied to the associated color component. 1. As an example, for a luma transform block, if there are one or more chroma blocks that use the luma block to perform CCLM mode, for each hypothetical reconstruction of the luma component, a CCLM predictor of the corresponding chroma component (hypothetical CCLM predictor) is generated and evaluated. A joint cost is derived based on the hypothetical reconstruction of the luma component and the hypothetical CCLM predictor of the chroma component. Optionally, conditions described in section C may be applied to control when this embodiment can be used. An example of such a condition is to use this embodiment only when the corresponding chroma component has CBF=0. (In this case, the hypothetical CCLM predictor of the color component is equal to the hypothetical reconstruction.) 2. As another example, for a luma transform block, if there are one or more chroma blocks that use the luma block to perform CCLM mode, hypothesized reconstructions are generated for all participating color components to perform sign prediction. In this case, the residuals of the chroma components are generated and added to the hypothesized CCLM predictor to find the chroma hypothesis reconstruction. If the chroma components also use sign prediction. In that case, sign prediction is performed jointly. 3. Similar to example 2, this example generates hypothetical reconstructions for both the luma component and the associated chroma components when CCLM is used, but only when chroma does not use sign prediction.
[0108] This disclosure may generally refer to "signaling" certain information, such as syntax elements. The term "signaling" may generally refer to communication of values for syntax elements and / or other data used to decode the encoded video data. That is, video encoder 200 may signal values for syntax elements in a bitstream. In general, signaling refers to generating values in a bitstream. As mentioned above, source device 102 may transport the bitstream to destination device 116 substantially in real time or not in real time, such as may occur when storing syntax elements to storage device 112 for later retrieval by destination device 116.
[0109] 2A and 2B are conceptual diagrams illustrating an exemplary quad-tree bi-tree (QTBT) structure 130 and a corresponding coding tree unit (CTU) 132. The solid lines represent quad-tree partitioning, and the dotted lines indicate bi-tree partitioning. At each partition (i.e., non-leaf) node of the bi-tree, one flag is signaled to indicate which partition type (i.e., horizontal or vertical) is used, where in this example, 0 indicates horizontal partitioning and 1 indicates vertical partitioning. For quad-tree partitioning, there is no need to indicate the partition type because the quad-tree node divides a block horizontally and vertically into four sub-blocks of equal size. Thus, the video encoder 200 may encode syntax elements (such as partition information) for the region tree level (i.e., solid lines) of the QTBT structure 130 and syntax elements (such as partition information) for the prediction tree level (i.e., dashed lines) of the QTBT structure 130, and the video decoder 300 may decode those syntax elements. The video encoder 200 may encode, and the video decoder 300 may decode, video data, such as prediction data and transform data, for CUs represented by terminal leaf nodes of the QTBT structure 130.
[0110] 2B may be associated with parameters that define the sizes of blocks corresponding to nodes of the QTBT structure 130 at the first and second levels. These parameters may include a CTU size (representing the size of the CTU 132 in the sample), a minimum quadtree size (MinQTSize, representing the minimum allowed quadtree leaf node size), a maximum bipartite size (MaxBTSize, representing the maximum allowed bipartite root node size), a maximum bipartite depth (MaxBTDepth, representing the maximum allowed bipartite depth), and a minimum bipartite size (MinBTSize, representing the minimum allowed bipartite leaf node size).
[0111] The root node of the QTBT structure corresponding to the CTU may have four child nodes at the first level of the QTBT structure, and each of the child nodes may be partitioned according to a quadtree partition. That is, the nodes at the first level are either leaf nodes (without child nodes) or have four child nodes. The example QTBT structure 130 represents the nodes as including parent nodes and child nodes with solid lines for branching. If the nodes at the first level are not larger than the maximum allowed binary tree root node size (MaxBTSize), these nodes may be further partitioned by their respective binary trees. The binary tree partitioning of a node may be repeated until the resulting node of the partition reaches the minimum allowed binary tree leaf node size (MinBTSize) or the maximum allowed binary tree depth (MaxBTDepth). The example QTBT structure 130 represents the nodes as including dashed lines for branching. The binary tree leaf nodes are called coding units (CUs), which are used for prediction (e.g., intra-picture or inter-picture prediction) and transformation without further division. As explained above, CUs are sometimes called "video blocks" or "blocks."
[0112] In one example of a QTBT partitioning structure, the CTU size is set as 128x128 (luma samples and two corresponding 64x64 chroma samples), MinQTSize is set as 16x16, MaxBTSize is set as 64x64, MinBTSize (for both width and height) is set as 4, and MaxBTDepth is set as 4. To generate a quadtree leaf node, quadtree partitioning is first applied to the CTU. The quadtree leaf node may have a size from 16x16 (i.e., MinQTSize) to 128x128 (i.e., CTU size). If the quadtree leaf node is 128x128, the leaf quadtree node is not further split by the binary tree because the size exceeds MaxBTSize (i.e., 64x64 in this example). Otherwise, the quadtree leaf node is further partitioned by the binary tree. Thus, the quadtree leaf node is also the root node of the binary tree and has the binary tree depth as 0. When the binary tree depth reaches MaxBTDepth (4 in this example), no further splits are allowed. A binary tree node with a width equal to MinBTSize (4 in this example) suggests that no further vertical splits (i.e., width splits) are allowed for that binary tree node. Similarly, a binary tree node with a height equal to MinBTSize suggests that no further horizontal splits (i.e., height splits) are allowed for that binary tree node. As mentioned above, the leaf nodes of the binary tree are called CUs and are further processed according to the prediction and transformation without further partitioning.
[0113] 3 is a block diagram illustrating an example video encoder 200 that may perform techniques of this disclosure. FIG. 3 is provided for purposes of illustration and should not be considered a limitation of the techniques as broadly illustrated and described in this disclosure. For purposes of illustration, this disclosure describes a video encoder 200 according to VVC (ITU-T H.266 under development) and HEVC (ITU-T H.265) techniques. However, the techniques of this disclosure may be performed by video encoding devices configured according to other video coding standards.
[0114] 3, the video encoder 200 includes a video data memory 230, a mode selection unit 202, a residual generation unit 204, a transform processing unit 206, a quantization unit 208, an inverse quantization unit 210, an inverse transform processing unit 212, a reconstruction unit 214, a filter unit 216, a decoded picture buffer (DPB) 218, and an entropy coding unit 220. Any or all of the video data memory 230, the mode selection unit 202, the residual generation unit 204, the transform processing unit 206, the quantization unit 208, an inverse quantization unit 210, an inverse transform processing unit 212, a reconstruction unit 214, a filter unit 216, a DPB 218, and an entropy coding unit 220 may be implemented in one or more processors or in processing circuits. For example, the units of the video encoder 200 may be implemented as one or more circuits or logic elements as part of a hardware circuit, or as part of a processor, an ASIC, or an FPGA. Further, video encoder 200 may include additional or alternative processors or processing circuitry for performing these and other functions.
[0115] The video data memory 230 may store video data to be encoded by the components of the video encoder 200. The video encoder 200 may receive video data stored in the video data memory 230, for example, from the video source 104 (FIG. 1). The DPB 218 may act as a reference picture memory that stores reference video data for use in predicting subsequent video data by the video encoder 200. The video data memory 230 and the DPB 218 may be formed by any of a variety of memory devices, such as dynamic random access memory (DRAM), including synchronous DRAM (SDRAM), magnetoresistive RAM (MRAM), resistive RAM (RRAM), or other types of memory devices. The video data memory 230 and the DPB 218 may be provided by the same memory device or separate memory devices. In various examples, the video data memory 230 may be on-chip with other components of the video encoder 200, as shown, or may be off-chip relative to those components.
[0116] In this disclosure, references to video data memory 230 should not be construed as limited to memory internal to video encoder 200, unless specifically described as such, or to memory external to video encoder 200, unless specifically described as such. Rather, references to video data memory 230 should be understood as a reference memory that stores video data that video encoder 200 receives for encoding (e.g., video data for a current block to be encoded). Memory 106 of FIG. 1 may also provide temporary storage of outputs from various units of video encoder 200.
[0117] The various units in FIG. 3 are illustrated to aid in understanding the operations performed by the video encoder 200. The units may be implemented as fixed-function circuits, programmable circuits, or a combination thereof. Fixed-function circuits refer to circuits that provide specific functions and are preset for operations that may be performed. Programmable circuits refer to circuits that may be programmed to perform various tasks and provide flexible functionality in the operations that may be performed. For example, a programmable circuit may execute software or firmware that causes the programmable circuit to operate in a manner defined by the software or firmware instructions. Although a fixed-function circuit may execute software instructions (e.g., to receive parameters or output parameters), the types of operations that the fixed-function circuit performs are generally invariant. In some examples, one or more of the units may be different circuit blocks (fixed function or programmable), and in some examples, one or more of the units may be integrated circuits.
[0118] The video encoder 200 may include an arithmetic logic unit (ALU), an elementary function unit (EFU), digital circuits, analog circuits, and / or a programmable core formed from programmable circuits. In examples in which the operations of the video encoder 200 are performed using software executed by programmable circuits, the memory 106 (FIG. 1) may store instructions for the software (e.g., object code) that the video encoder 200 receives and executes, or another memory (not shown) within the video encoder 200 may store such instructions.
[0119] The video data memory 230 is configured to store the received video data. The video encoder 200 may retrieve pictures of the video data from the video data memory 230 and provide the video data to the residual generation unit 204 and the mode selection unit 202. The video data in the video data memory 230 may be raw video data to be encoded.
[0120] The mode selection unit 202 includes a motion estimation unit 222, a motion compensation unit 224, and an intra prediction unit 226. The mode selection unit 202 may include additional functional units for performing video prediction according to other prediction modes. By way of example, the mode selection unit 202 may include a palette unit, an intra block copy unit (which may be part of the motion estimation unit 222 and / or the motion compensation unit 224), an affine unit, a linear model (LM) unit, etc.
[0121] The mode selection unit 202 typically coordinates multiple encoding passes to test combinations of encoding parameters and resulting rate-distortion values for such combinations. The encoding parameters may include partitioning of the CTU into CUs, prediction modes for the CUs, transform types for residual data of the CUs, quantization parameters for residual data of the CUs, etc. The mode selection unit 202 may ultimately select a combination of encoding parameters that has a better rate-distortion value than the other tested combinations.
[0122] Video encoder 200 may partition a picture retrieved from video data memory 230 into a series of CTUs and encapsulate one or more CTUs within a slice. Mode selection unit 202 may partition the CTUs of a picture according to a tree structure, such as the QTBT structure or quadtree structure of HEVC described above. As described above, video encoder 200 may form one or more CUs from partitioning the CTUs according to the tree structure. Such a CU may also be generally referred to as a “video block” or a “block.”
[0123] In general, the mode selection unit 202 also controls its components (e.g., motion estimation unit 222, motion compensation unit 224, and intra prediction unit 226) to generate a prediction block for a current block (e.g., a current CU, or in HEVC, an overlapping portion of a PU and a TU). In the case of inter prediction of the current block, the motion estimation unit 222 may perform motion search to identify one or more closely matching reference blocks in one or more reference pictures (e.g., one or more previously coded pictures stored in the DPB 218). Specifically, the motion estimation unit 222 may calculate a value representing how similar a potential reference block is to the current block according to, for example, a sum of absolute differences (SAD), a sum of squared differences (SSD), a mean absolute difference (MAD), a mean squared difference (MSD), etc. The motion estimation unit 222 may generally perform these calculations using a sample-by-sample difference between the current block and the reference block under consideration. Motion estimation unit 222 may identify the reference block having the lowest value resulting from these calculations, which indicates the reference block that most closely matches the current block.
[0124] The motion estimation unit 222 may form one or more motion vectors (MVs) that define the position of a reference block in a reference picture relative to the position of a current block in a current picture. The motion estimation unit 222 may then provide the motion vectors to the motion compensation unit 224. For example, in the case of unidirectional inter prediction, the motion estimation unit 222 may provide a single motion vector, while in the case of bidirectional inter prediction, the motion estimation unit 222 may provide two motion vectors. The motion compensation unit 224 may then generate a predictive block using the motion vectors. For example, the motion compensation unit 224 may use the motion vectors to retrieve data of the reference block. As another example, in the case of a motion vector having fractional sample precision, the motion compensation unit 224 may interpolate values for the predictive block according to one or more interpolation filters. Furthermore, in the case of bidirectional inter prediction, the motion compensation unit 224 may retrieve data for the two reference blocks identified by the respective motion vectors and combine the retrieved data, for example, by sample-wise averaging or weighted averaging.
[0125] As another example, for intra prediction or intra predictive coding, the intra prediction unit 226 may generate a predictive block from samples neighboring the current block. For example, for a directional mode, the intra prediction unit 226 may generally mathematically combine values of neighboring samples and populate these calculated values in a defined direction across the current block to generate a predictive block. As another example, for a DC mode, the intra prediction unit 226 may calculate an average of the neighboring samples for the current block and generate a predictive block to include this resulting average for each sample of the predictive block.
[0126] The mode selection unit 202 provides the prediction block to the residual generation unit 204. The residual generation unit 204 receives a raw, uncoded version of the current block from the video data memory 230 and receives the prediction block from the mode selection unit 202. The residual generation unit 204 calculates sample-by-sample differences between the current block and the prediction block. The resulting sample-by-sample differences define a residual block for the current block. In some examples, the residual generation unit 204 may also determine differences between sample values in the residual block to generate the residual block using residual differential pulse code modulation (RDPCM). In some examples, the residual generation unit 204 may be formed using one or more subtractor circuits that perform binary subtraction.
[0127] In an example where the mode selection unit 202 partitions a CU into PUs, each PU may be associated with a luma prediction unit and a corresponding chroma prediction unit. The video encoder 200 and the video decoder 300 may support PUs having various sizes. As indicated above, the size of a CU may refer to the size of the luma coding block of the CU, and the size of a PU may refer to the size of the luma prediction unit of the PU. Assuming that the size of a particular CU is 2N×2N, the video encoder 200 may support a PU size of 2N×2N or N×N for intra prediction, and a symmetric PU size of 2N×2N, 2N×N, N×2N, N×N, or similar for inter prediction. The video encoder 200 and the video decoder 300 may also support asymmetric partitioning for PU sizes of 2N×nU, 2N×nD, nL×2N, and nR×2N for inter prediction.
[0128] In examples where the mode selection unit 202 does not further partition the CUs into PUs, each PU may be associated with a luma coding block and a corresponding chroma coding block. As described above, the size of a CU may refer to the size of the luma coding block of the CU. The video encoder 200 and the video decoder 300 may support CU sizes of 2N×2N, 2N×N, or N×2N.
[0129] For other video coding techniques, such as intra block copy mode coding, affine mode coding, and linear model (LM) mode coding, as some examples, the mode selection unit 202 generates a predictive block for the current block being coded via a respective unit associated with the coding technique. In some examples, such as palette mode coding, the mode selection unit 202 may not generate a predictive block, but instead generates syntax elements that indicate how to reconstruct the block based on a selected palette. In such modes, the mode selection unit 202 may provide these syntax elements to the entropy coding unit 220 to be coded.
[0130] As described above, the residual generation unit 204 receives video data for a current block and a corresponding predictive block. The residual generation unit 204 then generates a residual block for the current block. To generate the residual block, the residual generation unit 204 calculates sample-by-sample differences between the predictive block and the current block.
[0131] Transform processing unit 206 applies one or more transforms to the residual block to generate a block of transform coefficients (referred to herein as a "transform coefficient block"). Transform processing unit 206 may apply various transforms to the residual block to form the transform coefficient block. For example, transform processing unit 206 may apply a discrete cosine transform (DCT), a directional transform, a Karhunen-Loeve transform (KLT), or a conceptually similar transform to the residual block. In some examples, transform processing unit 206 may perform multiple transforms, e.g., a primary transform and a secondary transform, such as a rotation transform, on the residual block. In some examples, transform processing unit 206 does not apply a transform to the residual block.
[0132] The quantization unit 208 may quantize the transform coefficients in the transform coefficient block to generate a quantized transform coefficient block. The quantization unit 208 may quantize the transform coefficients of the transform coefficient block according to a quantization parameter (QP) value associated with the current block. The video encoder 200 (e.g., via the mode selection unit 202) may adjust the degree of quantization applied to the transform coefficient block associated with the current block by adjusting the QP value associated with the CU. Quantization may result in loss of information, and thus the quantized transform coefficients may have less precision than the original transform coefficients generated by transform processing unit 206.
[0133] The inverse quantization unit 210 and the inverse transform processing unit 212 may apply inverse quantization and inverse transform, respectively, to the quantized transform coefficient block to reconstruct a residual block from the transform coefficient block. The reconstruction unit 214 may generate a reconstructed block that corresponds to the current block (possibly with some distortion) based on the reconstructed residual block and the predictive block generated by the mode selection unit 202. For example, the reconstruction unit 214 may add samples of the reconstructed residual block to corresponding samples from the predictive block generated by the mode selection unit 202 to generate the reconstructed block.
[0134] Filter unit 216 may perform one or more filter operations on the reconstructed blocks. For example, filter unit 216 may perform a deblocking operation to reduce blockiness artifacts along the edges of a CU. The operations of filter unit 216 may be skipped in some examples.
[0135] The video encoder 200 stores the reconstructed blocks in the DPB 218. For example, in examples where the operations of the filter unit 216 are not performed, the reconstruction unit 214 may store the reconstructed blocks in the DPB 218. In examples where the operations of the filter unit 216 are performed, the filter unit 216 may store the filtered and reconstructed blocks in the DPB 218. The motion estimation unit 222 and the motion compensation unit 224 may retrieve reference pictures formed from the reconstructed (and possibly filtered) blocks from the DPB 218 to inter predict blocks of a later-encoded picture. In addition, the intra prediction unit 226 may use the reconstructed blocks in the DPB 218 of the current picture to intra predict other blocks in the current picture.
[0136] In general, the entropy encoding unit 220 may entropy encode syntax elements received from other functional components of the video encoder 200. For example, the entropy encoding unit 220 may entropy encode quantized transform coefficient blocks from the quantization unit 208. As another example, the entropy encoding unit 220 may entropy encode predictive syntax elements (e.g., motion information for inter prediction or intra mode information for intra prediction) from the mode selection unit 202. The entropy encoding unit 220 may perform one or more entropy encoding operations on syntax elements, which are another example of video data, to generate entropy encoded data. For example, the entropy encoding unit 220 may perform a context-adaptive variable length coding (CAVLC) operation, a CABAC operation, a variable-to-variable (V2V) length coding operation, a syntax-based context-adaptive binary arithmetic coding (SBAC) operation, a probability interval partitioned entropy (PIPE) coding operation, an exponential-Golomb coding operation, or another type of entropy coding operation on the data. In some examples, the entropy encoding unit 220 may operate in a bypass mode in which syntax elements are not entropy coded.
[0137] The video encoder 200 may output a bitstream that includes entropy-encoded syntax elements needed to reconstruct blocks of a slice or picture. Specifically, the entropy encoding unit 220 may output the bitstream.
[0138] The operations described above are described with respect to blocks. Such descriptions should be understood as being operations for luma coding blocks and / or chroma coding blocks. As described above, in some examples, the luma coding blocks and chroma coding blocks are luma and chroma components of a CU. In some examples, the luma coding blocks and chroma coding blocks are luma and chroma components of a PU.
[0139] In some examples, operations performed with respect to luma coding blocks do not need to be repeated for chroma coding blocks. As an example, operations for identifying motion vectors (MVs) and reference pictures for luma coding blocks do not need to be repeated to identify MVs and reference pictures for chroma coding blocks. Rather, the MVs for the luma coding blocks may be scaled to determine the MVs for the chroma coding blocks, and the reference pictures may be the same. As another example, the intra prediction process may be the same for luma coding blocks and chroma coding blocks.
[0140] Video encoder 200 represents an example of a device configured to encode video data, the device including a memory configured to store the video data, and one or more processing units implemented in a circuit and configured to predict, based on multiple color components of the block of video data, signs of residual data of color components of the block of video data, and reconstruct the block of video data based on the predicted signs.
[0141] 4 is a block diagram illustrating an example video decoder 300 that may perform techniques of this disclosure. FIG. 4 is provided for purposes of illustration and not to limit the techniques as broadly illustrated and described in this disclosure. For purposes of illustration, this disclosure describes a video decoder 300 according to VVC (ITU-T H.266 under development) and HEVC (ITU-T H.265) techniques. However, the techniques of this disclosure may be performed by video coding devices configured according to other video coding standards.
[0142] In the example of FIG. 4, the video decoder 300 includes a coded picture buffer (CPB) memory 320, an entropy decoding unit 302, a prediction processing unit 304, an inverse quantization unit 306, an inverse transform processing unit 308, a reconstruction unit 310, a filter unit 312, and a decoded picture buffer (DPB) 314. Any or all of the CPB memory 320, the entropy decoding unit 302, the prediction processing unit 304, the inverse quantization unit 306, the inverse transform processing unit 308, the reconstruction unit 310, the filter unit 312, and the DPB 314 may be implemented in one or more processors or processing circuits. For example, the units of the video decoder 300 may be implemented as one or more circuits or logic elements as part of a hardware circuit, or as part of a processor, ASIC, or FPGA. Additionally, the video decoder 300 may include additional or alternative processors or processing circuits for performing these and other functions.
[0143] The prediction processing unit 304 includes a motion compensation unit 316 and an intra prediction unit 318. The prediction processing unit 304 may include additional units for performing prediction according to other prediction modes. By way of example, the prediction processing unit 304 may include a palette unit, an intra block copy unit (which may form part of the motion compensation unit 316), an affine unit, a linear model (LM) unit, etc. In other examples, the video decoder 300 may include more, fewer, or different functional components.
[0144] The CPB memory 320 may store video data, such as an encoded video bitstream, to be decoded by components of the video decoder 300. The video data stored in the CPB memory 320 may be obtained, for example, from the computer-readable medium 110 (FIG. 1). The CPB memory 320 may include a CPB that stores encoded video data (e.g., syntax elements) from the encoded video bitstream. The CPB memory 320 may also store video data other than syntax elements of a coded picture, such as temporary data representing output from various units of the video decoder 300. The DPB 314 generally stores decoded pictures that the video decoder 300 may output and / or use as reference video data when decoding subsequent data or pictures of the encoded video bitstream. The CPB memory 320 and the DPB 314 may be formed by any of a variety of memory devices, such as DRAM, including SDRAM, MRAM, RRAM, or other types of memory devices. The CPU memory 320 and the DPB 314 may be provided by the same memory device or separate memory devices. In various examples, the CPB memory 320 may be on-chip with other components of the video decoder 300, or may be off-chip relative to those components.
[0145] Additionally or alternatively, in some examples, video decoder 300 may retrieve coded video data from memory 120 (FIG. 1). That is, memory 120 may store data such as those described above with respect to CPB memory 320. Similarly, memory 120 may store instructions to be executed by video decoder 300 when some or all of the functionality of video decoder 300 is implemented in software to be executed by processing circuitry of video decoder 300.
[0146] The various units shown in FIG. 4 are illustrated to aid in understanding the operations performed by the video decoder 300. The units may be implemented as fixed-function circuits, programmable circuits, or a combination thereof. As with FIG. 3, fixed-function circuits refer to circuits that provide specific functions and are preset for operations that may be performed. Programmable circuits refer to circuits that may be programmed to perform various tasks and provide flexible functionality in the operations that may be performed. For example, a programmable circuit may execute software or firmware that causes the programmable circuit to operate in a manner defined by the software or firmware instructions. Although a fixed-function circuit may execute software instructions (e.g., to receive parameters or output parameters), the types of operations that the fixed-function circuit performs are generally invariant. In some examples, one or more of the units may be different circuit blocks (fixed function or programmable), and in some examples, one or more of the units may be an integrated circuit.
[0147] The video decoder 300 may include a programmable core formed from ALUs, EFUs, digital circuits, analog circuits, and / or programmable circuits. In examples in which the operations of the video decoder 300 are performed by software executing on programmable circuits, on-chip or off-chip memory may store instructions of the software (e.g., object code) that the video decoder 300 receives and executes.
[0148] The entropy decoding unit 302 may receive the encoded video data from the CPB and entropy decode the video data to recover the syntax elements. The prediction processing unit 304, the inverse quantization unit 306, the inverse transform processing unit 308, the reconstruction unit 310, and the filter unit 312 may generate decoded video data based on the syntax elements extracted from the bitstream.
[0149] In general, the video decoder 300 reconstructs a picture on a block-by-block basis. The video decoder 300 may perform a reconstruction operation on each block individually (wherein the block currently being reconstructed, i.e., decoded, may be referred to as the “current block”).
[0150] The entropy decoding unit 302 may entropy decode the quantized transform coefficients of the quantized transform coefficient block, as well as syntax elements defining transform information, such as a quantization parameter (QP) and / or a transform mode indication. The inverse quantization unit 306 may use the QP associated with the quantized transform coefficient block to determine the degree of quantization and, similarly, the degree of inverse quantization that the inverse quantization unit 306 should apply. The inverse quantization unit 306 may, for example, perform a bitwise left shift operation to inverse quantize the quantized transform coefficients. The inverse quantization unit 306 may thereby form a transform coefficient block including the transform coefficients.
[0151] After the inverse quantization unit 306 forms the transform coefficient block, the inverse transform processing unit 308 may apply one or more inverse transforms to the transform coefficient block to generate a residual block associated with the current block. For example, the inverse transform processing unit 308 may apply an inverse DCT, an inverse integer transform, an inverse Karhunen-Loeve transform (KLT), an inverse rotational transform, an inverse transform, or another inverse transform to the transform coefficient block.
[0152] Further, prediction processing unit 304 generates a prediction block according to the prediction information syntax element entropy decoded by entropy decoding unit 302. For example, if the prediction information syntax element indicates that the current block is inter predicted, motion compensation unit 316 may generate a prediction block. In this case, the prediction information syntax element may indicate a reference picture in DPB 314 from which to retrieve a reference block, as well as a motion vector that identifies the location of the reference block in the reference picture relative to the location of the current block in the current picture. Motion compensation unit 316 may generally perform an inter prediction process in a manner substantially similar to that described with respect to motion compensation unit 224 (FIG. 3).
[0153] As another example, if the prediction information syntax element indicates that the current block is intra predicted, the intra prediction unit 318 may generate a predictive block according to the intra prediction mode indicated by the prediction information syntax element. Again, the intra prediction unit 318 may generally perform an intra prediction process in a manner substantially similar to that described with respect to the intra prediction unit 226 (FIG. 3). The intra prediction unit 318 may retrieve data of neighboring samples for the current block from the DPB 314.
[0154] The reconstruction unit 310 may reconstruct the current block using the predictive block and the residual block. For example, the reconstruction unit 310 may add samples of the residual block to corresponding samples of the predictive block to reconstruct the current block.
[0155] Filter unit 312 may perform one or more filter operations on the reconstructed blocks. For example, filter unit 312 may perform a deblocking operation to reduce blockiness artifacts along the edges of the reconstructed blocks. The operations of filter unit 312 may not be performed in all instances.
[0156] The video decoder 300 may store the reconstructed blocks in the DPB 314. For example, in examples where the operations of the filter unit 312 are not performed, the reconstruction unit 310 may store the reconstructed blocks in the DPB 314. In examples where the operations of the filter unit 312 are performed, the filter unit 312 may store the refined, filtered, and reconstructed blocks in the DPB 314. As described above, the DPB 314 may provide reference information to the prediction processing unit 304, such as samples of the current picture for intra prediction and previously decoded pictures for subsequent motion compensation. Additionally, the video decoder 300 may output the decoded pictures (e.g., decoded video) from the DPB 314 for later presentation on a display device, such as the display device 118 of FIG. 1.
[0157] Thus, the video decoder 300 represents an example of a video decoding device that includes a memory configured to store video data and one or more processing units implemented in a circuit and configured to predict signs of residual data of color components of a block of video data based on multiple color components of the block of video data, and reconstruct the block of video data based on the predicted signs.
[0158] 7 is a flowchart illustrating an example method for encoding a current block according to the techniques of this disclosure. The current block may include a current CU. Although described with respect to video encoder 200 (FIGS. 1 and 3), it should be understood that other devices may be configured to perform a method similar to that of FIG.
[0159] In this example, video encoder 200 first predicts the current block (350). For example, video encoder 200 may form a predictive block for the current block. Video encoder 200 may then calculate a residual block for the current block (352). To calculate the residual block, video encoder 200 may calculate a difference between an original uncoded block and a predictive block for the current block. Video encoder 200 may then transform the residual block and quantize transform coefficients of the residual block (354). Video encoder 200 may then scan the quantized transform coefficients of the residual block (356). During or following the scan, video encoder 200 may entropy code the transform coefficients (358). For example, video encoder 200 may code the transform coefficients using CAVLC or CABAC. Video encoder 200 may then output entropy coded data for the block (360).
[0160] 8 is a flowchart illustrating an example method for decoding a current block of video data in accordance with the techniques of this disclosure. The current block may include a current CU. Although described with respect to video decoder 300 (FIGS. 1 and 4), it should be understood that other devices may be configured to perform a method similar to that of FIG.
[0161] The video decoder 300 may receive entropy coded data for the current block, such as the entropy coded prediction information and the entropy coded data of the transform coefficients of the residual block corresponding to the current block (370). The video decoder 300 may entropy decode the entropy coded data to determine the prediction information for the current block and to reconstruct the transform coefficients of the residual block (372). The video decoder 300 may predict the current block, e.g., using an intra prediction mode or an inter prediction mode as indicated by the prediction information for the current block, to calculate a predictive block for the current block (374). The video decoder 300 may then inverse scan the reconstructed transform coefficients to create a block of quantized transform coefficients (376). The video decoder 300 may then inverse quantize the transform coefficients and apply an inverse transform to the transform coefficients to generate the residual block (378). The video decoder 300 may finally decode the current block by combining the predictive block and the residual block (380).
[0162] FIG. 9 is a flowchart illustrating an example method for decoding a current block using code prediction based on multiple color components according to the techniques of this disclosure. The current block may include a current transform block (TU). Although described with respect to the video decoder 300 (FIGS. 1 and 4), it should be understood that other devices may be configured to perform a method similar to that of FIG. 9. For example, the video encoder 200 (FIGS. 1 and 3) may be configured to perform a method similar to that of FIG. 9 (e.g., by the inverse transform processing unit 212).
[0163] The video decoder 300 may predict a sign of a coefficient of a plurality of coefficients of a joint residual block of a block of video data based on a plurality of color components of the block of video data coded using joint coding of chroma residual (JCCR) (902). For example, the inverse transform processing unit 308 of the video decoder 300 may generate a plurality of hypothetical reconstructions including a first hypothetical reconstruction that the sign is positive and a second hypothetical reconstruction that the sign is negative. The inverse transform processing unit 308 may evaluate the plurality of hypothetical reconstructions using a cost function and select the sign corresponding to the hypothetical reconstruction having the lowest cost value as the predicted sign for the coefficient.
[0164] To predict the sign using the cost function, the inverse transform processing unit 308 may determine a joint cost value for the multiple color components. For example, because the predicted sign of the coefficient of the joint residual block affects the residual block for the multiple color components generated based on the joint residual block (e.g., the Cb residual block and the Cr residual block), the inverse transform processing unit 308 may evaluate the cost for the multiple color components. In some examples, the inverse transform processing unit 308 may determine the joint cost value by determining a joint cost value as a weighted sum of the cost values of at least the multiple color components. For example, the inverse transform processing unit 308 may determine the joint cost value by determining a first weight for at least a first color component of the multiple color components, determining a second weight for a second color component of the multiple color components, and determining a weighted sum of the cost values of the multiple color components based on the first weight and the second weight. As one specific example, the inverse transform processing unit 308 may determine the joint cost value according to the following formula:
[0165]
number
[0166] During the ceremony, Cost joint is the joint cost value, and w coloris the weight of a particular color component among multiple color components, S is a set containing multiple color components, and Cost color is the cost value of a particular color component.
[0167] As explained above, the inverse transform processing unit 308 generates weights (e.g., w color For example, the inverse transform processing unit 308 may determine a first weight for a first color component (e.g., Cb) and a second weight for a second color component (e.g., Cr). In some examples, the inverse transform processing unit 308 may determine the weights based on which color component of the plurality of color components including the Cb color component and the Cr color component has a non-zero coded block flag (CBF) earlier in the scanning order. As an example, if the Cb color component is scanned earlier than the Cr color component in the scanning order, the inverse transform processing unit 308 may determine the first weight to be 1 and the second weight to be 0 in response to determining that the Cb color component has a non-zero CBF. As another example, if the Cb color component is scanned earlier than the Cr color component in the scanning order, the inverse transform processing unit 308 may determine the first weight to be 0 and the second weight to be 1 in response to determining that the Cb color component has a zero CBF and the Cr color component has a non-zero CBF. As yet another example, in response to determining that the Cb color component has a non-zero CBF, the inverse transform processing unit 308 may determine that the first weight is 1, and in response to determining that the Cr color component has a non-zero CBF, the inverse transform processing unit 308 may determine that the second weight is 1.
[0168] As described above, the inverse transform processing unit 308 may determine multiple joint cost values (e.g., multiple hypotheses) to predict the sign for the coefficient of the joint residual block. For example, the inverse transform processing unit 308 may determine a first joint cost value of the multiple color components for a negative sign (e.g., perform a reconstruction with the sign as negative) and determine a second joint cost value of the multiple color components for a positive sign (e.g., perform a reconstruction with the sign as positive). As described above, to determine the cost value, the inverse transform processing unit 308 may select the sign corresponding to the most favorable (e.g., lowest) joint cost value. As an example, in response to determining that the first joint cost value (e.g., the joint cost value for the negative sign) is less than the second joint cost value (e.g., the joint cost value for the positive sign), the inverse transform processing unit 308 may predict the sign to be negative. As another example, in response to determining that the second joint cost value is less than the first joint cost value, the inverse transform processing unit 308 may predict the sign to be positive.
[0169] Although described above as being performed for a single coefficient of the joint residual block, in some examples, the inverse transform processing unit 308 may perform a similar procedure to predict signs for other coefficients of the joint residual block. By predicting one or more signs based on multiple color components, the techniques of this disclosure may enable more efficient signaling of video data. In particular, more accurate sign predictions that may result from the techniques of this disclosure may reduce the number of signs that need to be signaled in the bitstream.
[0170] The inverse transform processing unit 308 may generate coefficients of each of the multiple residual blocks based on the multiple coefficients of the joint residual block for each color component of the multiple color components (904). For example, the inverse transform processing unit 308 may generate a Cb residual block and a Cr residual block according to one of three sub-modes supported by VVC. The inverse transform processing unit 308 may derive a sub-mode index from a combination of the CBF values of the chroma components. If Cbf_Cb == 1 and Cbf_Cr == 0, the sub-mode index is 1. If Cbf_Cb == 1 and Cbf_Cr == 1, the sub-mode index is 2. Otherwise (Cbf_Cb == 0 and Cbf_Cr == 1), the sub-mode index is 3. The following table shows how the inverse transformed joint coefficient block (resJointC) is transformed into Cb and Cr pixel residuals (resCb and resCr).
[0171] [Table 2]
[0172] The inverse transform processing unit 308 converts the value of CSign from ph_joint_cbcr_sign_flag in the picture header, i.e., CSign = 1 - 2 * ph_joint_cbcr_sign_flag can be derived.
[0173] The inverse transform processing unit 308 may reconstruct a block of the video data based on the multiple residual blocks (906). For example, similar to operation 380 of FIG. 8, the reconstruction unit 310 may combine each reconstructed predictive block for a color component with its respective residual block. For example, the reconstruction unit 310 may add values of the Cb residual block with values of the Cb predictive block (e.g., generated by the prediction processing unit 304) to generate a reconstructed Cb block, and add values of the Cr residual block with values of the Cr predictive block (e.g., generated by the prediction processing unit 304) to generate a reconstructed Cr block.
[0174] The following numbered clauses may represent one or more aspects of the disclosure.
[0175] Clause 1A. A method for coding video data, comprising the steps of predicting a sign of residual data of a color component of a block of video data based on a plurality of color components of the block of video data, and reconstructing the block of video data based on the predicted sign.
[0176] Clause 2A. The method of clause 1A, wherein predicting the sign includes jointly predicting signs of multiple color components of the block of video data.
[0177] Clause 3A. The method of clause 2A, wherein the step of jointly predicting the signs includes the steps of determining joint cost values for the multiple color components and predicting the signs for the multiple color components based on the determined joint cost values.
[0178] Clause 4A. The step of determining a joint cost value includes determining a joint cost value according to the following formula: joint =Σ color∈S w color Cost color , in the formula, Cost joint is the joint cost value, and w coloris the weight of a particular color component among multiple color components, S is a set containing multiple color components, and Cost color The method of clause 3A, wherein x is a cost value for a particular color component.
[0179] Clause 5A. The method of any of clauses 1A to 4A, wherein the coding step includes a decoding step.
[0180] Clause 6A. The method of any of clauses 1A to 5A, wherein the coding step includes the encoding step.
[0181] Clause 7A. A device for coding video data, comprising one or more means for performing the method of any of clauses 1A to 6A.
[0182] Clause 8A. The device of clause 7A, wherein the one or more means comprise one or more processors implemented in circuitry.
[0183] Clause 9A. The device of any of clauses 6A and 8A, further comprising a memory for storing video data.
[0184] Clause 10A. The device of any of clauses 6A-9A, further comprising a display configured to display the decoded video data.
[0185] Clause 11A. The device of any of clauses 6A to 10A, wherein the device comprises one or more of a camera, a computer, a mobile device, a broadcast receiver device, or a set-top box.
[0186] Clause 12A. The device of any of clauses 6A to 11A, wherein the device comprises a video decoder.
[0187] Clause 13A. The device of any of clauses 6A to 12A, wherein the device comprises a video encoder.
[0188] Clause 14A. A computer-readable storage medium having instructions stored thereon that, when executed, cause one or more processors to perform the method of any of clauses 1A-6A.
[0189] Clause 1B. A method for decoding video data, comprising: predicting signs of coefficients of a plurality of coefficients of a joint residual block of the block of video data based on a plurality of color components of the block of video data coded using joint coding of chroma residual (JCCR); generating, for each color component of the plurality of color components, a coefficient of a respective one of the plurality of residual blocks based on the plurality of coefficients of the joint residual block; and reconstructing the block of video data based on the plurality of residual blocks.
[0190] Clause 2B. The method of clause 1B, wherein predicting the code includes determining joint cost values for a plurality of color components and predicting the code based on the joint cost values.
[0191] Clause 3B. The method of clause 2B, wherein determining the joint cost value includes determining the joint cost value as a weighted sum of cost values of a plurality of color components.
[0192] Clause 4B. Determining a joint cost value as a weighted sum of cost values of a plurality of color components includes determining a joint cost value according to the following formula:
[0193]
number
[0194] During the ceremony, Cost joint is the joint cost value, and w color is the weight of a particular color component among multiple color components, S is a set containing multiple color components, and Cost colorThe method of clause 3B, wherein x is a cost value for a particular color component.
[0195] Clause 5B. The method of clause 3B, further including determining a first weight for a first color component of the plurality of color components, determining a second weight for a second color component of the plurality of color components, and determining a weighted sum of cost values of the plurality of color components based on the first weight and the second weight.
[0196] Clause 6B. The method of clause 5B, wherein determining the first weight and the second weight includes determining the first weight and the second weight based on which color component of the plurality of color components has a non-zero coded block flag (CBF) preceding it in the scanning order.
[0197] Clause 7B. The method of clause 6B, wherein the first color component is a Cb color component and the second color component is a Cr color component.
[0198] Clause 8B. The method of clause 7B, wherein the Cb color component is scanned before the Cr color component in the scanning order, and the method further includes determining, in response to determining that the Cb color component has a non-zero CBF, that the first weight is 1 and the second weight is 0.
[0199] Clause 9B. The method of clause 7B, wherein the Cb color component is scanned before the Cr color component in the scanning order, and the method further includes determining that the first weight is 0 and the second weight is 1 in response to determining that the Cb color component has a zero CBF and the Cr color component has a non-zero CBF.
[0200] Clause 10B. The method of clause 7B, further comprising: determining a first weight to be 1 in response to determining that the Cb color component has a non-zero CBF; and determining a second weight to be 1 in response to determining that the Cr color component has a non-zero CBF.
[0201] Clause 11B. The method of clause 2B, wherein the step of determining joint cost values for the plurality of color components includes determining a first joint cost value for the plurality of color components for a negative sign and determining a second joint cost value for the plurality of color components for a positive sign, and the step of predicting a sign of the residual data includes, in response to determining that the first joint cost value is less than the second joint cost value, predicting the sign to be negative, and in response to determining that the second joint cost value is less than the first joint cost value.
[0202] Clause 12B. A method for encoding video data, comprising: predicting signs of coefficients of a plurality of coefficients of a joint residual block of the block of video data based on a plurality of color components of the block of video data coded using joint coding of chroma residual (JCCR); generating, for each color component of the plurality of color components, a coefficient of a respective one of the plurality of residual blocks based on the plurality of coefficients of the joint residual block; and reconstructing the block of video data based on the plurality of residual blocks.
[0203] Clause 13B. The method of clause 12B, wherein predicting the code includes determining joint cost values for a plurality of color components and predicting the code based on the joint cost values.
[0204] Clause 14B. The method of clause 13B, wherein determining the joint cost value includes determining the joint cost value as a weighted sum of cost values of a plurality of color components.
[0205] Clause 15B. Determining a joint cost value as a weighted sum of cost values of a plurality of color components includes determining a joint cost value according to the following formula:
[0206]
number
[0207] During the ceremony, Cost joint is the joint cost value, and w color is the weight of a particular color component among multiple color components, S is a set containing multiple color components, and Cost color The method of clause 14B, wherein x is a cost value for a particular color component.
[0208] Clause 16B. The method of clause 14B, further including determining a first weight for a first color component of the plurality of color components, determining a second weight for a second color component of the plurality of color components, and determining a weighted sum of cost values of the plurality of color components based on the first weight and the second weight.
[0209] Clause 17B. The method of clause 16B, wherein determining the first weight and the second weight includes determining the first weight and the second weight based on which color component of the plurality of color components has a non-zero coded block flag (CBF) preceding it in the scanning order.
[0210] Clause 18B. The method of clause 17B, wherein the first color component is a Cb color component and the second color component is a Cr color component.
[0211] Clause 19B. The method of clause 18B, wherein the Cb color component is scanned before the Cr color component in the scanning order, and the method further includes determining, in response to determining that the Cb color component has a non-zero CBF, that the first weight is 1 and the second weight is 0.
[0212] Clause 20B. The method of clause 18B, wherein the Cb color component is scanned before the Cr color component in the scanning order, and the method further includes determining that the first weight is 0 and the second weight is 1 in response to determining that the Cb color component has a zero CBF and the Cr color component has a non-zero CBF.
[0213] Clause 21B. The method of clause 18B, further comprising: determining a first weight to be 1 in response to determining that the Cb color component has a non-zero CBF; and determining a second weight to be 1 in response to determining that the Cr color component has a non-zero CBF.
[0214] Clause 22B. The method of clause 13B, wherein the step of determining joint cost values for the plurality of color components includes determining a first joint cost value for the plurality of color components for a negative sign and determining a second joint cost value for the plurality of color components for a positive sign, and the step of predicting a sign of the residual data includes, in response to determining that the first joint cost value is less than the second joint cost value, predicting the sign to be negative, and in response to determining that the second joint cost value is less than the first joint cost value.
[0215] Clause 23B. A device for decoding video data, comprising: a memory configured to store the video data; and one or more processors implemented in a circuit and configured to: predict signs of coefficients of a plurality of coefficients of a joint residual block of the block of video data based on a plurality of color components of the block of video data coded using joint coding of chroma residual (JCCR); generate, for each color component of the plurality of color components, a coefficient of each of the plurality of residual blocks based on the plurality of coefficients of the joint residual block; and reconstruct the block of video data based on the plurality of residual blocks.
[0216] Clause 24B. The device of clause 23B, wherein to predict the code, the one or more processors are configured to determine joint cost values for a plurality of color components and predict the code based on the joint cost values.
[0217] Clause 25B. The device of clause 24B, wherein to determine the joint cost value, the one or more processors are configured to determine the joint cost value as a weighted sum of the cost values of the multiple color components.
[0218] Clause 26B. The device of clause 25B, wherein the one or more processors are further configured to determine a first weight for a first color component among the plurality of color components, determine a second weight for a second color component among the plurality of color components, and determine a weighted sum of cost values of the plurality of color components based on the first weight and the second weight.
[0219] Clause 27B. The device of clause 26B, wherein to determine the first weight and the second weight, the one or more processors are configured to determine the first weight and the second weight based on which color component of the plurality of color components has a non-zero coded block flag (CBF) earlier in the scanning order.
[0220] Clause 28B. The device of clause 27B, wherein the first color component is a Cb color component and the second color component is a Cr color component.
[0221] Clause 29B. The device of clause 28B, wherein the Cb color component is scanned before the Cr color component in the scanning order, and the one or more processors are further configured to determine, in response to determining that the Cb color component has a non-zero CBF, that the first weight is 1 and the second weight is 0.
[0222] Clause 30B. The device of clause 28B, wherein the Cb color component is scanned before the Cr color component in the scanning order, and the one or more processors are further configured to determine, in response to determining that the Cb color component has a zero CBF and the Cr color component has a non-zero CBF, that the first weight is 0 and the second weight is 1.
[0223] Clause 31B. A device for encoding video data, comprising: a memory configured to store the video data; and one or more processors implemented in a circuit and configured to: predict signs of coefficients of a plurality of coefficients of a joint residual block of the block of video data based on a plurality of color components of the block of video data coded using joint coding of chroma residual (JCCR); generate, for each color component of the plurality of color components, a coefficient of each of the plurality of residual blocks based on the plurality of coefficients of the joint residual block; and reconstruct the block of video data based on the plurality of residual blocks.
[0224] Clause 32B. The device of clause 31B, wherein to predict the code, the one or more processors are configured to determine joint cost values for a plurality of color components and predict the code based on the joint cost values.
[0225] Clause 33B. The device of clause 32B, wherein to determine the joint cost value, the one or more processors are configured to determine the joint cost value as a weighted sum of the cost values of the multiple color components.
[0226] Clause 34B. The device of clause 33B, wherein the one or more processors are further configured to determine a first weight for a first color component among the plurality of color components, determine a second weight for a second color component among the plurality of color components, and determine a weighted sum of cost values of the plurality of color components based on the first weight and the second weight.
[0227] Clause 35B. The device of clause 34B, wherein to determine the first weight and the second weight, the one or more processors are configured to determine the first weight and the second weight based on which color component of the plurality of color components has a non-zero coded block flag (CBF) earlier in the scanning order.
[0228] Clause 36B. The device of clause 35B, wherein the first color component is a Cb color component and the second color component is a Cr color component.
[0229] Clause 37B. The device of clause 36B, wherein the Cb color component is scanned before the Cr color component in the scanning order, and the one or more processors are further configured to determine, in response to determining that the Cb color component has a non-zero CBF, that the first weight is 1 and the second weight is 0.
[0230] Clause 38B. The device of clause 36B, wherein the Cb color component is scanned before the Cr color component in the scanning order, and the one or more processors are further configured to determine, in response to determining that the Cb color component has a zero CBF and the Cr color component has a non-zero CBF, that the first weight is 0 and the second weight is 1.
[0231] Clause 39B. A device for coding video data, comprising: means for predicting signs of coefficients of a plurality of coefficients of a joint residual block of the block of video data based on a plurality of color components of the block of video data coded using joint coding of chroma residual (JCCR); means for each color component of the plurality of color components, generating a coefficient of a respective residual block of the plurality of residual blocks based on the plurality of coefficients of the joint residual block; and means for reconstructing the block of video data based on the plurality of residual blocks.
[0232] Clause 40B. A computer-readable storage medium storing instructions that, when executed, cause one or more processors of a video coder to predict signs of coefficients of a plurality of coefficients of a joint residual block of a block of video data based on a plurality of color components of the block of video data coded using joint coding of chroma residual (JCCR), generate coefficients of each residual block of the plurality of residual blocks based on the plurality of coefficients of the joint residual block for each color component of the plurality of color components, and reconstruct the block of video data based on the plurality of residual blocks.
[0233] Clause 1C. A method for decoding video data, comprising: predicting signs of coefficients of a plurality of coefficients of a joint residual block of the block of video data based on a plurality of color components of the block of video data coded using joint coding of chroma residual (JCCR); generating, for each color component of the plurality of color components, a coefficient of a respective one of the plurality of residual blocks based on the plurality of coefficients of the joint residual block; and reconstructing the block of video data based on the plurality of residual blocks.
[0234] Clause 2C. The method of clause 1C, wherein predicting the code includes determining joint cost values for a plurality of color components and predicting the code based on the joint cost values.
[0235] Clause 3C. The method of clause 2C, wherein determining the joint cost value includes determining the joint cost value as a weighted sum of cost values of a plurality of color components.
[0236] Clause 4C. The step of determining a joint cost value as a weighted sum of cost values of a plurality of color components includes determining a joint cost value according to the following formula:
[0237]
number
[0238] During the ceremony, Cost joint is the joint cost value, and w color is the weight of a particular color component among multiple color components, S is a set containing multiple color components, and Cost color The method of clause 3C, wherein x is the cost value of a particular color component.
[0239] Clause 5C. The method of clause 3C or 4C, further comprising: determining a first weight for a first color component of the plurality of color components; determining a second weight for a second color component of the plurality of color components; and determining a weighted sum of cost values of the plurality of color components based on the first weight and the second weight.
[0240] Clause 6C. The method of clause 5C, wherein determining the first weight and the second weight includes determining the first weight and the second weight based on which color component of the plurality of color components has a non-zero coded block flag (CBF) preceding it in the scanning order.
[0241] Clause 7C. The method of clause 6C, wherein the first color component is a Cb color component and the second color component is a Cr color component.
[0242] Clause 8C. The method of clause 7C, wherein the Cb color component is scanned before the Cr color component in the scanning order, and the method further includes determining, in response to determining that the Cb color component has a non-zero CBF, that the first weight is 1 and the second weight is 0.
[0243] Clause 9C. The method of clause 7C or 8C, wherein the Cb color component is scanned before the Cr color component in the scanning order, and the method further includes determining that the first weight is 0 and the second weight is 1 in response to determining that the Cb color component has a zero CBF and the Cr color component has a non-zero CBF.
[0244] Clause 10C. The method of clause 7C, further comprising: determining a first weight to be 1 in response to determining that the Cb color component has a non-zero CBF; and determining a second weight to be 1 in response to determining that the Cr color component has a non-zero CBF.
[0245] Clause 11C. The method of any of clauses 2C to 10C, wherein the step of determining joint cost values for the plurality of color components includes determining a first joint cost value for the plurality of color components for a negative sign and determining a second joint cost value for the plurality of color components for a positive sign, and the step of predicting the sign of the residual data includes, in response to determining that the first joint cost value is less than the second joint cost value, predicting the sign to be negative, and in response to determining that the second joint cost value is less than the first joint cost value.
[0246] Clause 12C. A method for encoding video data, comprising: predicting signs of coefficients of a plurality of coefficients of a joint residual block of the block of video data based on a plurality of color components of the block of video data coded using joint coding of chroma residual (JCCR); generating, for each color component of the plurality of color components, a coefficient of a respective one of the plurality of residual blocks based on the plurality of coefficients of the joint residual block; and reconstructing the block of video data based on the plurality of residual blocks.
[0247] Clause 13C. The method of clause 12C, wherein predicting the code includes determining joint cost values for a plurality of color components and predicting the code based on the joint cost values.
[0248] Clause 14C. The method of clause 13C, wherein determining the joint cost value includes determining the joint cost value as a weighted sum of cost values of a plurality of color components.
[0249] Clause 15C. The step of determining a joint cost value as a weighted sum of cost values of a plurality of color components includes determining a joint cost value according to the following formula:
[0250] [Number]
[0251] During the ceremony, Cost joint is the joint cost value, and w color is the weight of a particular color component among multiple color components, S is a set containing multiple color components, and Cost color is the cost value of a particular color component.
[0252] Clause 16C. The method of clause 14C or 15C, further comprising determining a first weight for a first color component of the plurality of color components, determining a second weight for a second color component of the plurality of color components, and determining a weighted sum of cost values of the plurality of color components based on the first weight and the second weight.
[0253] Clause 17C. The method of clause 16C, wherein determining the first weight and the second weight includes determining the first weight and the second weight based on which color component of the plurality of color components has a non-zero coded block flag (CBF) preceding it in the scanning order.
[0254] Clause 18C. The method of clause 17C, wherein the first color component is a Cb color component and the second color component is a Cr color component.
[0255] Clause 19C. The method of clause 18C, wherein the Cb color component is scanned before the Cr color component in the scanning order, and the method further includes determining, in response to determining that the Cb color component has a non-zero CBF, that the first weight is 1 and the second weight is 0.
[0256] Clause 20C. The method of clause 18C or 19C, wherein the Cb color component is scanned before the Cr color component in the scanning order, and the method further includes determining, in response to determining that the Cb color component has a zero CBF and the Cr color component has a non-zero CBF, that the first weight is 0 and the second weight is 1.
[0257] Clause 21C. The method of clause 18C, further comprising: determining a first weight to be 1 in response to determining that the Cb color component has a non-zero CBF; and determining a second weight to be 1 in response to determining that the Cr color component has a non-zero CBF.
[0258] Clause 22C. The method of any of clauses 13C to 21C, wherein the step of determining joint cost values for the plurality of color components includes determining a first joint cost value for the plurality of color components for a negative sign and determining a second joint cost value for the plurality of color components for a positive sign, and the step of predicting the sign of the residual data includes, in response to determining that the first joint cost value is less than the second joint cost value, predicting the sign to be negative, and in response to determining that the second joint cost value is less than the first joint cost value.
[0259] Clause 23C. A device for decoding video data, comprising: a memory configured to store the video data; and one or more processors implemented in a circuit and configured to: predict signs of coefficients of a plurality of coefficients of a joint residual block of the block of video data based on a plurality of color components of the block of video data coded using joint coding of chroma residual (JCCR); generate, for each color component of the plurality of color components, a coefficient of each of the plurality of residual blocks based on the plurality of coefficients of the joint residual block; and reconstruct the block of video data based on the plurality of residual blocks.
[0260] Clause 24C. The device of clause 23C, wherein to predict the code, the one or more processors are configured to determine joint cost values for a plurality of color components and predict the code based on the joint cost values.
[0261] Clause 25C. The device of clause 24C, wherein to determine the joint cost value, the one or more processors are configured to determine the joint cost value as a weighted sum of the cost values of the multiple color components.
[0262] Clause 26C. The device of clause 25C, wherein the one or more processors are further configured to determine a first weight for a first color component among the plurality of color components, determine a second weight for a second color component among the plurality of color components, and determine a weighted sum of cost values of the plurality of color components based on the first weight and the second weight.
[0263] Clause 27C. The device of clause 26C, wherein to determine the first weight and the second weight, the one or more processors are configured to determine the first weight and the second weight based on which color component of the plurality of color components has a non-zero coded block flag (CBF) earlier in the scanning order.
[0264] Clause 28C. The device of clause 27C, wherein the first color component is a Cb color component and the second color component is a Cr color component.
[0265] Clause 29C. The device of clause 28C, wherein the Cb color component is scanned before the Cr color component in the scanning order, and the one or more processors are further configured to determine, in response to determining that the Cb color component has a non-zero CBF, that the first weight is 1 and the second weight is 0.
[0266] Clause 30C. The device of clause 28, wherein the Cb color component is scanned before the Cr color component in the scan order, and the one or more processors are further configured to determine, in response to determining that the Cb color component has a zero CBF and the Cr color component has a non-zero CBF, that the first weight is 0 and the second weight is 1.
[0267] Clause 31C. A device for encoding video data, comprising: a memory configured to store the video data; and one or more processors implemented in a circuit and configured to: predict signs of coefficients of a plurality of coefficients of a joint residual block of the block of video data based on a plurality of color components of the block of video data coded using joint coding of chroma residual (JCCR); generate, for each color component of the plurality of color components, a coefficient of each of the plurality of residual blocks based on the plurality of coefficients of the joint residual block; and reconstruct the block of video data based on the plurality of residual blocks.
[0268] Clause 32C. The device of clause 31C, wherein to predict the code, the one or more processors are configured to determine joint cost values for a plurality of color components and predict the code based on the joint cost values.
[0269] Clause 33C. The device of clause 32C, wherein to determine the joint cost value, the one or more processors are configured to determine the joint cost value as a weighted sum of the cost values of the multiple color components.
[0270] Clause 34C. The device of clause 33C, wherein the one or more processors are further configured to determine a first weight for a first color component among the plurality of color components, determine a second weight for a second color component among the plurality of color components, and determine a weighted sum of cost values of the plurality of color components based on the first weight and the second weight.
[0271] Clause 35C. The device of clause 34C, wherein to determine the first weight and the second weight, the one or more processors are configured to determine the first weight and the second weight based on which color component of the plurality of color components has a non-zero coded block flag (CBF) earlier in the scanning order.
[0272] Clause 36C. The device of clause 35C, wherein the first color component is a Cb color component and the second color component is a Cr color component.
[0273] Clause 37C. The device of clause 36C, wherein the Cb color component is scanned before the Cr color component in the scanning order, and the one or more processors are further configured to determine, in response to determining that the Cb color component has a non-zero CBF, that the first weight is 1 and the second weight is 0.
[0274] Clause 38C. The device of clause 36C, wherein the Cb color component is scanned before the Cr color component in the scan order, and the one or more processors are further configured to determine, in response to determining that the Cb color component has a zero CBF and the Cr color component has a non-zero CBF, that the first weight is 0 and the second weight is 1.
[0275] Clause 39C. A device for coding video data, comprising: means for predicting signs of coefficients of a plurality of coefficients of a joint residual block of a block of video data based on a plurality of color components of the block of video data coded using joint coding of chroma residual (JCCR); means for each color component of the plurality of color components for generating a coefficient of a respective residual block of a plurality of residual blocks based on the plurality of coefficients of the joint residual block; and means for reconstructing a block of video data based on the plurality of residual blocks.
[0276] Clause 40C. A computer-readable storage medium storing instructions that, when executed, cause one or more processors of a video coder to predict signs of coefficients of a plurality of coefficients of a joint residual block of a block of video data based on a plurality of color components of the block of video data coded using joint coding of chroma residual (JCCR), generate coefficients of each residual block of the plurality of residual blocks based on the plurality of coefficients of the joint residual block for each color component of the plurality of color components, and reconstruct the block of video data based on the plurality of residual blocks.
[0277] It should be appreciated that, depending on the example, some acts or events of any of the techniques described herein may be performed in a different sequence, or may be added, combined, or omitted entirely (e.g., not all acts or events described are necessary to the practice of the techniques). Furthermore, in some examples, acts or events may be performed simultaneously rather than sequentially, e.g., through multi-threaded processing, interrupt processing, or multiple processors.
[0278] In one or more examples, the described functions may be implemented in hardware, software, firmware, or any combination thereof. If implemented in software, the functions may be stored on or transmitted via a computer-readable medium as one or more instructions or code and executed by a hardware-based processing unit. A computer-readable medium may include a computer-readable storage medium corresponding to a tangible medium, such as a data storage medium, or a communication medium including any medium that facilitates transfer of a computer program from one place to another, for example according to a communication protocol. Thus, a computer-readable medium may generally correspond to (1) a tangible computer-readable storage medium that is non-transitory, or (2) a communication medium such as a signal or carrier wave. A data storage medium may be any available medium that can be accessed by one or more computers or one or more processors to retrieve instructions, code and / or data structures for implementation of the techniques described in this disclosure. A computer program product may include a computer-readable medium.
[0279] By way of example and not limitation, such computer-readable storage media may comprise RAM, ROM, EEPROM, CD-ROM or other optical disk storage, magnetic disk storage or other magnetic storage devices, flash memory, or any other medium that may be used to store desired program code in the form of instructions or data structures and that may be accessed by a computer. Also, any connection is properly referred to as a computer-readable medium. For example, if instructions are transmitted from a website, server, or other remote source using coaxial cable, fiber optic cable, twisted pair, digital subscriber line (DSL), or wireless technologies such as infrared, radio, and microwave, the coaxial cable, fiber optic cable, twisted pair, DSL, or wireless technologies such as infrared, radio, and microwave are included in the definition of the medium. However, it should be understood that computer-readable storage media and data storage media do not include connections, carrier waves, signals, or other transitory media, but instead cover non-transitory tangible storage media. As used herein, disk and disc include compact disc (CD), laser disc, optical disc, digital versatile disc (DVD), floppy disk and Blu-ray disc, where disks typically reproduce data magnetically and discs reproduce data optically using lasers. Combinations of the above should also be included within the scope of computer readable media.
[0280] The instructions may be executed by one or more processors, such as one or more DSPs, general-purpose microprocessors, ASICs, FPGAs, or other equivalent integrated or discrete logic circuits. Thus, the terms "processor" and "processing circuitry" as used herein may refer to any of the above structures or any other structures suitable for implementing the techniques described herein. In addition, in some aspects, the functionality described herein may be provided within dedicated hardware and / or software modules configured for encoding and decoding, or may be incorporated into a combined codec. Also, the techniques may be fully implemented in one or more circuits or logic elements.
[0281] The techniques of the present disclosure may be implemented in a wide variety of devices or apparatuses, including wireless handsets, integrated circuits (ICs) or sets of ICs (e.g., chipsets). Various components, modules, or units have been described in this disclosure to highlight functional aspects of devices configured to perform the disclosed techniques, but they do not necessarily require realization by different hardware units. Rather, as described above, the various units may be combined in a codec hardware unit or may be provided by a collection of interoperable hardware units including one or more processors as described above, along with suitable software and / or firmware.
[0282] Various examples have been described. These and other examples are within the scope of the following claims. [Explanation of symbols]
[0283] 100 Video encoding and decoding system, system 102 Source Device 104 Video Sources 106 Memory 108 Output Interface 110 Computer-readable medium 112 Storage Devices 114 File Server 116 Destination Device 118 Display Devices 120 Memory 122 Input Interface 130 Quad-tree / binary-tree (QTBT) structure, QTBT structure 132 Coding Tree Unit (CTU), CTU 200 Video Encoder 202 Mode Selection Unit 204 Residual Generation Unit 206 Conversion Processing Unit 208 Quantization Units 210 Inverse Quantization Unit 212 Inverse Transformation Processing Unit 214 Reconstruction Unit 216 Filter unit 218 Decoded Picture Buffer (DPB), DPB 220 Entropy Coding Unit 222 Motion Estimation Unit 224 Motion Compensation Unit 226 intra prediction units 230 Video Data Memory 300 Video Decoder 302 Entropy Decoding Unit 304 Prediction Processing Unit 306 Inverse Quantization Unit 308 Inverse Transformation Processing Unit 310 Reconstruction Unit 312 Filter unit 314 Decoded Picture Buffer (DPB), DPB 316 Motion Compensation Unit 318 Intra Prediction Units 320 Coded Picture Buffer (CPB) memory, CPB memory
Claims
1. 1. A method for decoding video data, comprising the steps of: predicting, based on a plurality of color components of a block of video data coded using joint coding of chroma residual (JCCR), a sign of a coefficient of a plurality of coefficients of a joint residual block of the block of video data, the sign predicting comprising: determining a joint cost value for the plurality of color components as a weighted sum of cost values of the plurality of color components; predicting the code based on the joint cost value; Determining the weighted sum of the cost values determining a first weight for a first color component of the plurality of color components and a second weight for a second color component of the plurality of color components; determining the weighted sum of the cost values of the plurality of color components based on the first weight and the second weight; generating, for each color component of the plurality of color components, coefficients of a respective residual block of a plurality of residual blocks based on the plurality of coefficients of the joint residual block; reconstructing the block of video data based on the plurality of residual blocks; The method includes:
2. Determining the joint cost value as the weighted sum of the cost values of the plurality of color components comprises determining the joint cost value according to the following formula: [0010] During the ceremony, Cost joint is the joint cost value, and w color is a weight of a particular color component among the plurality of color components, S denotes a set including the plurality of color components, and Cost color is the cost value of the particular color component, The method of claim 1.
3. determining the first weight and the second weight, determining the first weight and the second weight based on which color component of the plurality of color components has a non-zero coded block flag (CBF) preceding it in scanning order; 2. The method of claim 1, comprising:
4. The method of claim 3 , wherein the first color component is a Cb color component and the second color component is a Cr color component.
5. the Cb color component is scanned before the Cr color component in the scanning order, the method comprising: determining, in response to determining that the Cb color component has a non-zero CBF, that the first weight is one and that the second weight is zero.
5. The method of claim 4, further comprising:
6. the Cb color component is scanned before the Cr color component in the scanning order, the method comprising: determining, in response to determining that the Cb color component has a zero CBF and the Cr color component has a non-zero CBF, that the first weight is zero and that the second weight is one.
5. The method of claim 4, further comprising:
7. determining that the first weight is one in response to determining that the Cb color component has a non-zero CBF; determining that the second weight is one in response to determining that the Cr color component has a non-zero CBF; 5. The method of claim 4, further comprising:
8. determining the joint cost values for the plurality of color components, determining a first joint cost value of the plurality of color components for a negative sign; determining a second joint cost value of the plurality of color components for a positive sign; and predicting the sign of the residual data comprises: predicting the sign to be negative in response to determining that the first joint cost value is less than the second joint cost value; predicting the sign to be positive in response to determining that the second joint cost value is less than the first joint cost value; 2. The method of claim 1, comprising:
9. 1. A method for encoding video data, comprising the steps of: predicting, based on a plurality of color components of a block of video data coded using joint coding of chroma residual (JCCR), a sign of a coefficient of a plurality of coefficients of a joint residual block of the block of video data, the sign predicting comprising: determining a joint cost value for the plurality of color components as a weighted sum of cost values of the plurality of color components; predicting the code based on the joint cost value; Determining the weighted sum of the cost values determining a first weight for a first color component of the plurality of color components and a second weight for a second color component of the plurality of color components; determining the weighted sum of the cost values of the plurality of color components based on the first weight and the second weight; generating, for each color component of the plurality of color components, coefficients of a respective residual block of a plurality of residual blocks based on the plurality of coefficients of the joint residual block; reconstructing the block of video data based on the plurality of residual blocks; The method includes:
10. 1. A device for decoding video data, comprising: a memory configured to store video data; and one or more processors implemented in a circuit, the one or more processors comprising: Predicting a sign of a coefficient among a plurality of coefficients of a joint residual block of a block of video data based on a plurality of color components of the block of video data coded using joint coding of chroma residual (JCCR), wherein to predict the sign, the one or more processors: determining a joint cost value for the plurality of color components as a weighted sum of cost values of the plurality of color components; configured to predict the sign based on the joint cost value; To determine the weighted sum of the cost values, the one or more processors: determining a first weight for a first color component of the plurality of color components and a second weight for a second color component of the plurality of color components; determining the weighted sum of the cost values of the plurality of color components based on the first weight and the second weight; generating, for each color component of the plurality of color components, coefficients of a respective residual block of a plurality of residual blocks based on the coefficients of the joint residual block; reconstructing the block of video data based on the plurality of residual blocks; A device configured to:
11. The device of claim 10, wherein the one or more processors are configured to execute a method according to any one of claims 2 to 8.
12. 1. A device for encoding video data, comprising: a memory configured to store video data; and one or more processors implemented in a circuit, the one or more processors comprising: Predicting a sign of a coefficient among a plurality of coefficients of a joint residual block of a block of video data based on a plurality of color components of the block of video data coded using joint coding of chroma residual (JCCR), wherein to predict the sign, the one or more processors: determining a joint cost value for the plurality of color components as a weighted sum of cost values of the plurality of color components; configured to predict the sign based on the joint cost value; To determine the weighted sum of the cost values, the one or more processors: determining a first weight for a first color component of the plurality of color components and a second weight for a second color component of the plurality of color components; determining the weighted sum of the cost values of the plurality of color components based on the first weight and the second weight; generating, for each color component of the plurality of color components, coefficients of a respective residual block of a plurality of residual blocks based on the coefficients of the joint residual block; reconstructing the block of video data based on the plurality of residual blocks; A device configured to:
13. The device of claim 12, wherein the one or more processors are configured to execute a method according to any one of claims 2 to 8.
14. A computer-readable storage medium storing instructions that, when executed, cause one or more processors of a video coder to perform a method according to any one of claims 1 to 8.
