# US 2021/0344899 A1 · Video encoder, video decoder, and corresponding methods

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

- Number: US 2021/0344899 A1
- Document ID: US20210344899A1
- Status: Published application
- Kind: A1
- Application number: 17/374,004
- Filed: 2021-07-13
- Published: 2021-11-04
- Earliest claimed: 2019-01-14
- Assignees: Huawei Technologies Co., Ltd.
- Applicants: Huawei Technologies Co., Ltd.
- Inventors: Huanbang CHEN; Yin ZHAO; Haitao YANG; Lian ZHANG
- Web page: https://patentgrep.com/patent/US20210344899A1

## CPC

- H04N 19/103: Selection of coding mode or of prediction mode
- H04N 19/13: Adaptive entropy coding, e.g. adaptive variable length coding [AVLC] or context adaptive binary arithmetic coding [CABAC]
- H04N 19/119: Adaptive subdivision aspects, e.g. subdivision of a picture into rectangular or non-rectangular coding blocks
- H04N 19/136: Incoming video signal characteristics or properties
- H04N 19/176: the region being a block, e.g. a macroblock
- H04N 19/50: using predictive coding (H04N19/61 takes precedence)
- H04N 19/70: characterised by syntax aspects related to video coding, e.g. related to compression standards
- H04N 19/91: Entropy coding, e.g. variable length coding [VLC] or arithmetic coding
- H04N 19/96: Tree coding, e.g. quad-tree coding
- H04N: PICTORIAL COMMUNICATION, e.g. TELEVISION

## Abstract

This application discloses a processing method applied to video encoding or video decoding. The method includes: obtaining size information of a current block; determining a context model index ctxInc of a flag of the current block based on the obtained size information of the current block and a size-based constraint; and performing subsequent processing based on the context model index ctxInc of the flag of the current block. The method can be used to improve coding efficiency.

## Claims

### Claim 1

A processing method applied to video encoding or video decoding, wherein the method comprises:
obtaining size information of a current block;
determining a context model index ctxInc of a flag of the current block based on the obtained size information of the current block and a size-based constraint; and
performing subsequent processing based on the context model index ctxInc of the flag of the current block.

### Claim 2 (depends on 1)

The processing method according to claim 1, wherein
the determining a context model index ctxInc of a flag of the current block based on the obtained size information of the current block and a size-based constraint comprises:
if the flag of the current block is skip flag and an area of the current block is less than a threshold th1, determining that a value of the context model index ctxInc used by the flag skip_flag is 3, wherein the obtained size information of the current block comprises the area of the current block, wherein the flag skip flag is used to indicate whether a skip mode is used for the current block.

### Claim 3 (depends on 1)

The processing method according to claim 1, wherein
the determining a context model index ctxInc of a flag of the current block based on the obtained size information of the current block and a size-based constraint comprises:
if the flag of the current block is inter_dir, and an area of the current block is less than a threshold th1, determining that a value of the context model index ctxInc used by the flag inter_dir is 2, wherein the obtained size information of the current block comprises the area of the current block, wherein the flag inter_dir is used to indicate a prediction reference mode used for the current block.

### Claim 4 (depends on 1)

The processing method according to claim 1, wherein
the determining a context model index ctxInc of a flag of the current block based on the obtained size information of the current block and a size-based constraint comprises:
if the flag of the current block is direct flag, and an area of the current block is less than a threshold th1, or a width of the current block is greater than a threshold th2, or a height of the current block is greater than the threshold th2, determining that a value of the context model index ctxInc used by the flag direct_flag is 1, wherein the obtained size information of the current block comprises the area of the current block, or the width of the current block, or the height of the current block, wherein the flag direct_flag is used to indicate whether a direct mode is used for the current block.

### Claim 5 (depends on 1)

The processing method according to claim 1, wherein
the determining a context model index ctxInc of a flag of the current block based on the obtained size information of the current block and a size-based constraint comprises:
if the flag of the current block is pred_mode, and a width of the current block is greater than a threshold th3, or a height of the current block is greater than the threshold th3, determining that a value of the context model index ctxInc used by the flag pred_mode is 5, wherein the obtained size information of the current block comprises the width of the current block or the height of the current block, wherein the flag pred_mode is used to indicate whether an intra prediction mode is used for the current block.

### Claim 6 (depends on 1)

The processing method according to claim 1, wherein
the determining a context model index ctxInc of a flag of the current block based on the obtained size information of the current block and a size-based constraint comprises:
if the flag of the current block is root_cbf, and a width of the current block is greater than a threshold th3, or a height of the current block is greater than the threshold th3, determining that a value of the context model index ctxInc used by the flag root_cbf is 1, wherein the obtained size information of the current block comprises the width of the current block or the height of the current block, wherein the flag root_cbf is used to indicate whether there is a residual after the current block is coded.

### Claim 7 (depends on 1)

The processing method according to claim 1, wherein
the determining a context model index ctxInc of a flag of the current block based on the obtained size information of the current block and a size-based constraint comprises:
if the flag of the current block is qt_split_flag, and a picture region in which the current block is located is an I slice or an I frame, and a width of the current block is th4, determining that a value of the context model index ctxInc used by the flag qt_split_flag is 3, wherein the obtained size information of the current block comprises the width of the current block and a height of the current block, wherein the flag qt_split_flag is used to indicate whether quadtree split is used for the current block.

### Claim 8 (depends on 1)

The processing method according to claim 1, wherein
the determining a context model index ctxInc of a flag of the current block based on the obtained size information of the current block and a size-based constraint comprises:
if the flag of the current block is split_dir, and a width of the current block corresponding to a current to-be-split node is a threshold th5, and a height of the current block is greater than the threshold th5, determining that a value of the context model index ctxInc used by the flag split_dir is 3; or
if the flag of the current block is split_dir, and a height of the current block corresponding to a current to-be-split node is the threshold th5, and a width of the current block is greater than the threshold th5, determining that the value of the context model index ctxInc used by the flag split_dir is 4, wherein the obtained size information of the current block comprises the width of the current block and the height of the current block, wherein the flag split_dir is used to indicate a split direction of the current block.

### Claim 9

A processing apparatus used in video encoding or video decoding, comprising:
a memory; and
a processor coupled to the memory and configured to:
obtain size information of a current block;
determine a context model index ctxInc of a flag of the current block based on the obtained size information of the current block and a size-based constraint; and
perform subsequent processing based on the context model index ctxInc of the flag of the current block.

### Claim 10 (depends on 9)

The processing apparatus according to claim 9, wherein
wherein the processor is further to: determines that a value of the context model index ctxInc used by a flag skip_flag is 3 when determining that an area of the current block is less than a threshold th1 and the flag of the current block is skip_flag, wherein the size information of the current block comprises the area of the current block, wherein the flag skip_flag is used to indicate whether a skip mode is used for the current block.

### Claim 11 (depends on 9)

The processing apparatus according to claim 9,
wherein the processor is further to: determines that a value of the context model index ctxInc used by a flag inter_dir is 2 when an area of the current block is less than a threshold th1 and the flag of the current block is inter_dir, wherein the size information of the current block comprises the area of the current block, wherein the flag inter_dir is used to indicate a prediction reference mode used for the current block.

### Claim 12 (depends on 9)

The processing apparatus according to claim 9, wherein; and
wherein the processor is further to: determine that a value of the context model index ctxInc used by a flag direct_flag is 1 when an area of the current block is less than a threshold th1, or a width of the current block is greater than a threshold th2, or a height of the current block is greater than the threshold th2, and when the flag of the current block is direct flag, wherein the size information of the current block comprises the area of the current block, or the width of the current block, or the height of the current block, wherein the flag direct flag is used to indicate whether a direct mode is used for the current block.

### Claim 13 (depends on 9)

The processing apparatus according to claim 9, wherein; and
wherein the processor is further to: determines that a value of the context model index ctxInc used by a flag pred_mode is 5 when a width of the current block is greater than a threshold th3, or a height of the current block is greater than the threshold th3, and when the flag of the current block is pred_mode, wherein the size information of the current block comprises the width of the current block or the height of the current block, wherein the flag pred_mode is used to indicate whether an intra prediction mode is used for the current block.

### Claim 14 (depends on 9)

The processing apparatus according to claim 9,
wherein the processor is further to: determines that a value of the context model index ctxInc used by a flag root_cbf is 1 when a width of the current block is greater than a threshold th3, or a height of the current block is greater than the threshold th3, and when the flag of the current block is root_cbf, wherein the size information of the current block comprises the width of the current block or the height of the current block, wherein the flag root_cbf is used to indicate whether there is a residual after the current block is coded.

### Claim 15 (depends on 9)

The processing apparatus according to claim 9,
wherein the processor is further to: determines that a value of the context model index ctxInc used by flag qt_split_flag is 3 when a picture region in which the current block is located is an I slice or an I frame, and a width of the current block is th4, and when the flag of the current block is qt_split_flag, wherein the size information of the current block comprises the width of the current block and a height of the current block, wherein the flag qt_split_flag is used to indicate whether quadtree split is used for the current block.

### Claim 16 (depends on 9)

The processing apparatus according to claim 9; and
wherein the processor is further to: determines that a value of the context model index ctxInc used by flag split_dir is 3 when a width of the current block corresponding to a current to-be-split node is a threshold th5, and a height of the current block is greater than the threshold th5, and when the flag of the current block is split_dir; or
determines that the value of the context model index ctxInc used by the flag split_dir is 4 when a height of the current block corresponding to a current to-be-split node is a threshold th5, and a width of the current block is greater than the threshold th5, and when the flag of the current block is split_dir, wherein the size information of the current block comprises the width of the current block and the height of the current block, wherein the flag split_dir is used to indicate a split direction of the current block.

### Claim 17

A non-transitory computer-readable storage medium storing computer instructions, that when executed by one or more processors, cause the one or more processors to perform operations of:
obtaining size information of a current block;
determining a context model index ctxInc of a flag of the current block based on the obtained size information of the current block and a size-based constraint; and
performing subsequent processing based on the context model index ctxInc of the flag of the current block.

### Claim 18 (depends on 17)

The non-transitory computer-readable storage medium of claim 17, wherein the determining a context model index ctxInc of a flag of the current block based on the obtained size information of the current block and a size-based constraint comprises:
if the flag of the current block is skip_flag and an area of the current block is less than a threshold th1, determining that a value of the context model index ctxInc used by the flag skip_flag is 3, wherein the obtained size information of the current block comprises the area of the current block, wherein the flag skip_flag is used to indicate whether a skip mode is used for the current block;
if the flag of the current block is inter_dir and the area of the current block is less than the threshold th1, determining that the value of the context model index ctxInc used by the flag inter_dir is 2, wherein the obtained size information of the current block comprises the area of the current block, wherein the flag inter_dir is used to indicate a prediction reference mode used for the current block; or
if the flag of the current block is direct flag, and if the area of the current block is less than the threshold th1, or a width of the current block is greater than a threshold th2, or a height of the current block is greater than the threshold th2, determining that the value of the context model index ctxInc used by the flag direct_flag is 1, wherein the obtained size information of the current block comprises the area of the current block, or a width of the current block, or a height of the current block, wherein the flag direct_flag is used to indicate whether a direct mode is used for the current block.

### Claim 19 (depends on 17)

The non-transitory computer-readable storage medium of claim 17, wherein the determining a context model index ctxInc of a flag of the current block based on the obtained size information of the current block and a size-based constraint comprises:
if the flag of the current block is pred_mode, and if a width of the current block is greater than a threshold th3, or a height of the current block is greater than the threshold th3, determining that a value of the context model index ctxInc used by the flag pred_mode is 5, wherein the obtained size information of the current block comprises the width of the current block or the height of the current block, wherein the flag pred_mode is used to indicate whether an intra prediction mode is used for the current block; or
if the flag of the current block is root_cbf, and if a width of the current block is greater than the threshold th3, or a height of the current block is greater than the threshold th3, determining that the value of the context model index ctxInc used by the flag root_cbf is 1, wherein the obtained size information of the current block comprises the width of the current block or the height of the current block, wherein the flag root_cbf is used to indicate whether there is a residual after the current block is coded.

### Claim 20 (depends on 17)

The non-transitory computer-readable storage medium of claim 17, wherein the determining a context model index ctxInc of a flag of the current block based on the obtained size information of the current block and a size-based constraint comprises:
if the flag of the current block is qt_split_flag, a picture region in which the current block is located is an I slice or an I frame, and a width of the current block is th4, determining that a value of the context model index ctxInc used by the flag qt_split_flag is 3, wherein the obtained size information of the current block comprises the width of the current block and a height of the current block, wherein the flag qt_split_flag is used to indicate whether quadtree split is used for the current block; or
if the flag of the current block is split_dir, the width of the current block corresponding to a current to-be-split node is a threshold th5, and the height of the current block is greater than the threshold th5, determining that the value of the context model index ctxInc used by the flag split_dir is 3; or
if the flag of the current block is split_dir, the height of the current block corresponding to a current to-be-split node is the threshold th5, and the width of the current block is greater than the threshold th5, determining that the value of the context model index ctxInc used by the flag split_dir is 4, wherein the obtained size information of the current block comprises the width of the current block and the height of the current block, wherein the flag split_dir is used to indicate a split direction of the current block.
