# US 12,113,978 B2 · Encoder, decoder, encoding method, and decoding method

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

- Number: US 12,113,978 B2
- Document ID: US12113978B2
- Status: Granted
- Kind: B2
- Application number: 18/214,653
- Filed: 2023-06-27
- Published: 2023-10-26
- Granted: 2024-10-08
- Earliest claimed: 2017-12-28
- Assignees: Panasonic Intellectual Property Corporation of America
- Applicants: Panasonic Intellectual Property Corporation of America
- Inventors: Masato Ohkawa; Hideo Saitou; Tadamasa Toma; Takahiro Nishi; Kiyofumi Abe; Ryuichi Kanoh
- Web page: https://patentgrep.com/patent/US12113978B2

## CPC

- 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/124: Quantisation
- 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/625: using discrete cosine transform [DCT]
- H04N: PICTORIAL COMMUNICATION, e.g. TELEVISION

## Abstract

When a transform-basis adaptive selection mode is enabled, an encoder that transforms residuals of a current block to encode an image: adaptively selects a first horizontal transform basis from among one or more transform basis candidates when a horizontal size of the current block is greater than a first horizontal threshold size; otherwise selects a fixed horizontal transform basis as a first horizontal transform basis; adaptively selects a first vertical transform basis from among the one or more transform basis candidates when a vertical size of the current block is greater than a first vertical threshold size; otherwise selects a fixed vertical transform basis as a first vertical transform basis; and generates first transform coefficients by performing a first horizontal transform and a first vertical transform on the residuals of the current block, using the first horizontal transform basis selected and the first vertical transform basis selected, respectively.

## Claims

### Claim 1

An encoder comprising:
circuitry; and
memory,
wherein the circuitry, using the memory, performs:
generating first transform coefficients by performing a horizontal transform and a vertical transform on residuals using a horizontal transform basis and a vertical transform basis, respectively, when it is determined that the horizontal transform and the vertical transform are to be performed for the current block;
generating second transform coefficients by performing a non-separable transform on the first transform coefficients when it is determined that the non-separable transform is to be performed for the current block; and
encoding a signal which indicates whether the non-separable transform is performed or not,
wherein (i) when it is determined that a selection of a transform basis based on a size of the current block is performed for the current block, the circuitry performs, before performing the horizontal transform and the vertical transform:
selecting a first transform basis, as the horizontal transform basis, from among transform basis candidates when a horizontal size of the current block is a first horizontal size that is greater than a threshold size;
selecting a second transform basis, as the horizontal transform basis, from among the transform basis candidates when the horizontal size of the current block is a second horizontal size that is smaller than or equal to the threshold size, the second transform basis being different from the first transform basis;
selecting the first transform basis, as the vertical transform basis, from among the transform basis candidates when a vertical size of the current block is a first vertical size that is greater than the threshold size; and
selecting the second transform basis, as the vertical transform basis, from among the transform basis candidates when the vertical size of the current block is a second vertical size that is smaller than or equal to the threshold size, and
wherein (ii) when the non-separable transform is performed for the current block, a basic transform basis is selected as the vertical transform basis and the horizontal transform basis.

### Claim 2

A decoder comprising:
circuitry; and
memory,
wherein the circuitry, using the memory, performs:
decoding a signal which indicates whether a non-separable inverse transform is performed or not from a bitstream;
generating first transform coefficients by performing the non-separable inverse-transform on the second transform coefficients when it is determined that the non-separable inverse-transform is to be performed for the current block; and
generating residuals by performing a horizontal inverse-transform and a vertical inverse-transform on the first transform coefficients using a horizontal inverse-transform basis and a vertical inverse-transform basis, respectively, when it is determined that the horizontal inverse-transform and the vertical inverse-transform are to be performed for the current block,
wherein (i) when it is determined that a selection of a transform basis based on a size of the current block is performed for the current block, the circuitry performs, before performing the horizontal inverse-transform and the vertical inverse-transform:
selecting a first inverse-transform basis, as the horizontal inverse-transform basis, from among inverse-transform basis candidates when a horizontal size of the current block is a first horizontal size that is greater than a threshold size;
selecting a second inverse-transform basis, as the horizontal inverse-transform basis, from among the inverse-transform basis candidates when the horizontal size of the current block is a second horizontal size that is smaller than or equal to the threshold size, the second inverse-transform basis being different from the first inverse-transform basis;
selecting the first inverse-transform basis, as the vertical inverse-transform basis, from among the inverse-transform basis candidates when a vertical size of the current block is a first vertical size that is greater than the threshold size; and
selecting the second inverse-transform basis, as the vertical inverse-transform basis, from among the inverse-transform basis candidates when the vertical size of the current block is a second vertical size that is smaller than or equal to the threshold size, and
wherein (ii) when the non-separable inverse-transform is performed for the current block, a basic inverse-transform basis is selected as the vertical inverse-transform basis and the horizontal inverse-transform basis.

### Claim 3

An encoding method comprising:
generating first transform coefficients by performing a horizontal transform and a vertical transform on residuals using a horizontal transform basis and a vertical transform basis, respectively, when it is determined that the horizontal transform and the vertical transform are to be performed for the current block;
generating second transform coefficients by performing a non-separable transform on the first transform coefficients when it is determined that the non-separable transform is to be performed for the current block; and
encoding a signal which indicates whether the non-separable transform is performed or not,
wherein (i) when it is determined that a selection of a transform basis based on a size of the current block is performed for the current block, the encoding method further comprising, before performing the horizontal transform and the vertical transform:
selecting a first transform basis, as the horizontal transform basis, from among transform basis candidates when a horizontal size of the current block is a first horizontal size that is greater than a threshold size;
selecting a second transform basis, as the horizontal transform basis, from among the transform basis candidates when the horizontal size of the current block is a second horizontal size that is smaller than or equal to the threshold size, the second transform basis being different from the first transform basis;
selecting the first transform basis, as the vertical transform basis, from among the transform basis candidates when a vertical size of the current block is a first vertical size that is greater than the threshold size; and
selecting the second transform basis, as the vertical transform basis, from among the transform basis candidates when the vertical size of the current block is a second vertical size that is smaller than or equal to the threshold size, and
wherein (ii) when the non-separable transform is performed for the current block, a basic transform basis is selected as the vertical transform basis and the horizontal transform basis.

### Claim 4

A decoding method comprising:
decoding a signal which indicates whether a non-separable inverse transform is performed or not from a bitstream;
generating first transform coefficients by performing the non-separable inverse-transform on second transform coefficients when it is determined that the non-separable inverse-transform is to be performed for the current block; and
generating residuals by performing a horizontal inverse-transform and a vertical inverse-transform on the first transform coefficients using a horizontal inverse-transform basis and a vertical inverse-transform basis, respectively, when it is determined that the horizontal inverse-transform and the vertical inverse-transform are to be performed for the current block,
wherein (i) when it is determined that a selection of a transform basis based on a size of the current block is performed for the current block, the circuitry performs, before performing the horizontal inverse-transform and the vertical inverse-transform:
selecting a first inverse-transform basis, as the horizontal inverse-transform basis, from among inverse-transform basis candidates when a horizontal size of the current block is a first horizontal size that is greater than a threshold size;
selecting a second inverse-transform basis, as the horizontal inverse-transform basis, from among the inverse-transform basis candidates when the horizontal size of the current block is a second horizontal size that is smaller than or equal to the threshold size, the second inverse-transform basis being different from the first inverse-transform basis;
selecting the first inverse-transform basis, as the vertical inverse-transform basis, from among the inverse-transform basis candidates when a vertical size of the current block is a first vertical size that is greater than the threshold size; and
selecting the second inverse-transform basis, as the vertical inverse-transform basis, from among the inverse-transform basis candidates when the vertical size of the current block is a second vertical size that is smaller than or equal to the threshold size, and
wherein (ii) when the non-separable inverse-transform is performed for the current block, a basic inverse-transform basis is selected as the vertical inverse-transform basis and the horizontal inverse-transform basis.
