# US 2023/0069387 A1 · Encoding Method and Apparatus

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2023/0069387 A1
- Document ID: US20230069387A1
- Status: Published application
- Kind: A1
- Application number: 17/973,151
- Filed: 2022-10-25
- Published: 2023-03-02
- Earliest claimed: 2017-10-16
- Assignees: Huawei Technologies Co., Ltd.
- Applicants: Huawei Technologies Co., Ltd.
- Inventors: Yin Zhao; Haitao Yang; Jianle Chen
- Web page: https://patentgrep.com/patent/US20230069387A1

## CPC

- H04N 19/44: Decoders specially adapted therefor, e.g. video decoders which are asymmetric with respect to the encoder
- H04N 19/119: Adaptive subdivision aspects, e.g. subdivision of a picture into rectangular or non-rectangular coding blocks
- H04N 19/12: Selection from among a plurality of transforms or standards, e.g. selection between discrete cosine transform [DCT] and sub-band transform or selection between H.263 and H.264
- H04N 19/122: Selection of transform size, e.g. 8x8 or 2x4x8 DCT; Selection of sub-band transforms of varying structure or type
- H04N 19/124: Quantisation
- H04N 19/136: Incoming video signal characteristics or properties
- H04N 19/157: Assigned coding mode, i.e. the coding mode being predefined or preselected to be further used for selection of another element or parameter
- H04N 19/176: the region being a block, e.g. a macroblock
- H04N 19/184: the unit being bits, e.g. of the compressed video stream
- H04N 19/186: the unit being a colour or a chrominance component
- H04N 19/51: Motion estimation or motion compensation
- H04N 19/61: in combination with predictive coding
- H04N 19/625: using discrete cosine transform [DCT]
- H04N: PICTORIAL COMMUNICATION, e.g. TELEVISION

## Abstract

A video processing method includes: obtaining prediction information of a CU; obtaining, when the CU comprises only one residual TU and a size of the residual TU is less than a size of the CU, a TU partitioning mode of the CU and a residual position of the residual TU, wherein the TU partitioning mode and the residual position are used to determine a horizontal transform type and a vertical transform type; obtaining transform coefficients of the residual TU based on the horizontal transform type and the vertical transform type; and generating a bitstream that is for storing or transmitting and that includes the prediction information, a first flag that indicates the TU partitioning mode, a second flag that indicates the residual position, and the transform coefficients.

## Claims

### Claim 1

A video processing method, comprising:
obtaining prediction information of a coding unit (CU);
obtaining, when the CU comprises only one residual transform unit (TU) and when a first size of the residual TU is less than a second size of the CU, a TU partitioning mode of the CU and a residual position of the residual TU;
determining, using the TU partitioning mode and the residual position, a horizontal transform type and a vertical transform type;
obtaining transform coefficients of the residual TU based on the horizontal transform type and the vertical transform type; and.
generating a bitstream that comprises the prediction information, a first flag that indicates the TU partitioning mode, a second flag that indicates the residual position, and the transform coefficients.

### Claim 2 (depends on 1)

The video processing method of claim 1, wherein the horizontal transform type is based on discrete sine transform (DST) type VII (DST-7) and the vertical transform type is based on the DST-7, the horizontal transform type is based on the DST-7 and the vertical transform type is based on discrete cosine transform (DCT) type VIII DCT-8), or the horizontal transform type is based on the DCT-8 and the vertical transform type is based on the DST-7.

### Claim 3 (depends on 2)

The video processing method of claim 2, wherein:
the TU partitioning mode specifies that the CU is partitioned into two first TUs that are arranged horizontally and that comprise a left TU and a right TU, wherein a third size of the left TU is smaller than, greater than, or equal to a fourth size of the right TU; or
the TU partitioning mode specifies that the CU is partitioned into two second TUs that are arranged vertically and that comprise a top TU and a bottom TU, wherein a fifth size of the top TU is smaller than, greater than, or equal to a sixth size of the bottom TU.

### Claim 4 (depends on 3)

The video processing method of claim 3, further comprising:
partitioning the CU into the two first TUs, wherein the residual position is left or right; or partitioning the CU into the two second TUs, wherein the residual position is a top or a bottom.

### Claim 5 (depends on 4)

The video processing method of claim 4, wherein the horizontal transform type is the DST-7 and the vertical transform type is the DCT-8 when the CU is partitioned into the two second TUs and the residual position is the top, the horizontal transform type is the DST-7 and the vertical transform type is the DST-7 when the CU is partitioned into the two second TUs and the residual position is the bottom, the horizontal transform type is the DCT-8 and the vertical transform type is the DST-7 when the CU is partitioned into the two first TUs and the residual position is the left, and the horizontal transform type is the DST-7 and the vertical transform type is the DST-7 when the CU is partitioned into the two first TUs and the residual position is the right.

### Claim 6 (depends on 1)

The video processing method of claim 1, wherein the residual TU comprises one or more residuals for one or more of a first chrominance component, a second chrominance component, or a luminance component.

### Claim 7 (depends on 6)

The video processing method of claim 6, wherein the one or more residuals comprise a first residual for the first chrominance component, a second residual for the second chrominance component, and a third residual for the luminance component.

### Claim 8

A video processing apparatus, comprising:
one or more memories configured to store programming instructions; and
at least one processor coupled to the one or more memories and configured to execute the programming instructions to cause the video processing apparatus to:
obtain prediction information of a coding unit (CU); 2vobtain, when the CU comprises only one residual transform unit (TU) and when a first size of the residual TU is less than a second size of the CU, a TU partitioning mode of the CU and a residual position of the residual TU;
determine, using the TU partitioning mode and the residual position, a horizontal transform type and a vertical transform type;
obtain transform coefficients of the residual TU based on the horizontal transform type and the vertical transform type; and
generate a bitstream that comprises the prediction information, a first flag that indicates the TU partitioning mode, a second flag that indicates the residual position, and the transform coefficients.

### Claim 9 (depends on 8)

The video processing apparatus of claim 8, wherein the horizontal transform type is based on discrete sine transform (DST) type VII (DST-7) and the vertical transform type is based on the DST-7, the horizontal transform type is based on the DST-7 and the vertical transform type is based on discrete cosine transform (DCT) type VIII (DCT-8), or the horizontal transform type is based on the DCT-8 and the vertical transform type is based on the DST-7.

### Claim 10 (depends on 9)

The video processing apparatus of claim 9, wherein:
the TU partitioning mode specifies that the CU is partitioned into two first TUs that are arranged horizontally and that comprise a left TU and a right TU, wherein a third size of the left TU is smaller than, greater than, or equal to a fourth size of the right TU; or
the TU partitioning mode specifies that the CU is partitioned into two second TUs that are arranged vertically and that comprise a top TU and a bottom TU, wherein a fifth size of the top TU is smaller than, greater than, or equal to a sixth size of the bottom TU.

### Claim 11 (depends on 10)

The video processing apparatus of claim 10, wherein when executed by the at least one processor, the programming instructions are further configured to cause the video processing apparatus to:
partition the CU into the two first TUs, wherein the residual position is left or right; or
partition the CU into the two second TUs, wherein the residual position is a top or a bottom.

### Claim 12 (depends on 11)

The video processing apparatus of claim 11, wherein the horizontal transform type is the DST-7 and the vertical transform type is the DCT-8 when the CU is partitioned into the two second TUs and the residual position is the top, the horizontal transform type is the DST-7 and the vertical transform type is the DST-7 when the CU is partitioned into the two second. T1s and the residual position is the bottom, the horizontal transform type is the DCT-8 and the vertical transform type is the DST-7 when the CU is partitioned into the two first T1s and the residual position is the left, and the horizontal transform type is the DST-7 and the vertical transform type is the DST-7 when the CU is partitioned into the two first TUs and the residual. position is the right.

### Claim 13 (depends on 8)

The video processing apparatus of claim 8, wherein the residual TU comprises one or more residuals for one or more of a first chrominance component, a second chrominance component, or a luminance component.

### Claim 14 (depends on 13)

The video processing apparatus of claim 13, wherein the one or more residuals comprise a first residual for the first chrominance component, a second residual for the second chrominance component, and a third residual for the luminance component.

### Claim 15

A non-transitory storage medium storing a bitstream that is generated by:
obtaining prediction information of a coding unit (CU);
obtaining, when the CU comprises only one residual transform unit (TU) and when a first size of the residual TU is less than a second size of the CU, a TU partitioning mode of the CU and a residual position of the residual TU;
determining, using the TU partitioning mode and the residual position, a horizontal transform type and a vertical transform type;
obtaining transform coefficients of the residual TU based on the horizontal transform type and the vertical transform type; and
generating the bitstream, wherein the bitstream comprises the prediction information, a first flag that indicates the TU partitioning mode, a second flag that indicates the residual position, and the transform coefficients.

### Claim 16 (depends on 15)

The non-transitory storage medium of claim 15, wherein the horizontal transform type is based on discrete sine transform (DST) type VII (DST-7) and the vertical transform type is based on the DST-7, the horizontal transform type is based on the DST-7 and the vertical transform type is based on discrete cosine transform (DCT) type VIII (DCT-8), or the horizontal transform type is based on the DCT-8 and the vertical transform type is based on the DST-7.

### Claim 17 (depends on 16)

The non-transitory storage medium of claim 16, wherein:
the TU partitioning mode specifies that the CU is partitioned into two first TUs that are arranged horizontally and that comprise a left TU and a right TU, wherein a third size of the left TU is smaller than, greater than, or equal to a fourth size of the right TU; or
the TU partitioning mode specifies that the CU is partitioned into two second TUs that are arranged vertically and that comprise a top TU and a bottom TU, wherein a fifth size of the top TU is smaller than, greater than, or equal to a sixth size of the bottom TU.

### Claim 18 (depends on 17)

The non-transitory storage medium of claim 17, wherein the bitstream is further generated by:
partitioning the CU into the two second TUs, wherein the residual position is left or right; or
partitioning the CU into the two first TUs, wherein the residual position is a top or a bottom.

### Claim 19 (depends on 18)

The non-transitory storage medium of claim 18, wherein the horizontal transform type is the DST-8 and the vertical transform type is the DCT-S when the CU is partitioned into the two second TUs and the residual position is the top, the horizontal transform type is the DST-7 and the vertical transform type is the DST-7 when the CU is partitioned into the two second TUs and the residual position is the bottom, the horizontal transform type is the DCT-8 and the vertical transform type is the DST-7 when the CU is partitioned into the two first TUs and the residual position is the left, and the horizontal transform type is the DST-7 and the vertical transform type is the DST-7 when the CU is partitioned into the two first TUs and the residual position is the right.

### Claim 20 (depends on 15)

The non-transitory storage medium of claim 15, wherein the residual TU comprises one or more residuals for one or more of a first chrominance component, a second chrominance component, or a luminance component.
