# US 2020/0396478 A1 · Picture prediction method and apparatus, and codec

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

- Number: US 2020/0396478 A1
- Document ID: US20200396478A1
- Status: Published application
- Kind: A1
- Application number: 16/915,678
- Filed: 2020-06-29
- Published: 2020-12-17
- Earliest claimed: 2017-12-31
- Assignees: Huawei Technologies Co., Ltd.
- Applicants: Huawei Technologies Co., Ltd.
- Inventors: Xiang MA; Haitao YANG; Huanbang CHEN; Shan GAO
- Web page: https://patentgrep.com/patent/US20200396478A1

## CPC

- H04N 19/52: by predictive encoding
- H04N 19/577: Motion compensation with bidirectional frame interpolation, i.e. using B-pictures
- H04N 19/176: the region being a block, e.g. a macroblock
- H04N 19/182: the unit being a pixel
- H04N 19/56: Motion estimation with initialisation of the vector search, e.g. estimating a good candidate to initiate a search
- H04N: PICTORIAL COMMUNICATION, e.g. TELEVISION

## Abstract

A picture prediction method is provided, which includes: obtaining initial motion information of a current picture block; determining, based on a matching cost criterion, that positions of a pair of reference blocks are a position of a target forward reference block of the current picture block and a position of a target backward reference block of the current picture block, where positions of each pair of reference blocks include a position of a forward reference block and a position of a backward reference block; and for the positions of each pair of reference blocks, a first position offset and a second position offset are in a mirror relationship; and obtaining a predicted value of a pixel value of the current picture block based on a pixel value of the target forward reference block and a pixel value of the target backward reference block.

## Claims

### Claim 1

A picture prediction method, comprising:
obtaining initial motion information of a current picture block;
determining positions of N forward and N backward reference blocks based on the initial motion information, the N forward reference blocks comprising an initial forward reference block, the N backward reference blocks comprising an initial backward reference block, and N is an integer greater than 1;
determining, from the positions of the N forward and N backward reference blocks, based on a matching cost criterion, positions of a target forward reference block and a target backward reference block of the current picture block,
wherein for positions of n-th forward and n-th backward reference blocks of the N forward and N backward reference blocks, a first position offset and a second position offset are in a mirror relationship, the first position offset representing an offset of the position of the n-th forward reference block relative to a position of the initial forward reference block, and the second position offset representing an offset of the position of the n-th backward reference block relative to a position of the initial backward reference block; wherein n is an integer and 0≤n<N or 0<n<N; and
obtaining a predicted value of a pixel value of the current picture block based on a pixel value of the target forward reference block and a pixel value of the target backward reference block.

### Claim 2 (depends on 1)

The method according to claim 1, wherein the position of the target forward reference block is associated with (delta0x′, delta0y′) representing an offset of the position of the target forward reference block relative to the position of the initial forward reference block,
the position of the target backward reference block is associated with (delta1x′, delta1y′) representing an offset of the position of the target backward reference block relative to the position of the initial backward reference block, and
wherein delta0x′=−delta1x′, and delta0y′=−delta1y′.

### Claim 3 (depends on 1)

The method according to claim 1, wherein the positions of the N forward reference blocks comprise a position of the initial forward reference block and positions of (N−1) candidate forward reference blocks; or
the positions of the N backward reference blocks comprise a position of the initial backward reference block and positions of (N−1) candidate backward reference blocks,
for positions of n-th candidate forwad and n-th candidate backward reference blocks of the (N−1) candidate forward and (N−1) candidate backward reference blocks, a first position offset and a second position offset are in a mirror relationship, the first position offset representing an offset of the position of the n-th candidate forward reference block relative to a position of the initial forward reference block, and the second position offset representing an offset of the position of the n-th candidate backward reference block relative to a position of the initial backward reference block n is an integer and 0<n≤N−1.

### Claim 4 (depends on 1)

The method according to claim 1, wherein a direction of the first position offset is opposite to a direction of the second position offset, and an amplitude of the first position offset is the same as an amplitude of the second position offset.

### Claim 5 (depends on 1)

The method according to claim 1, wherein the first position offset is represented by (delta0x, delta0y) and the second position offset is represented by (delta1x, delta1y), wherein delta0x=−delta1x, and delta0y=−delta1y.

### Claim 6 (depends on 1)

The method according to claim 1, further comprising:
obtaining updated motion information of the current picture block, wherein the updated motion information comprises an updated forward motion vector and an updated backward motion vector,
wherein the updated forward motion vector points to the position of the target forward reference block, and the updated backward motion vector points to the position of the target backward reference block, or
wherein the updated forward motion vector indicates an offset of the position of the target forward reference block relative to the position of the current picture block, and the updated backward motion vector indicates an offset of the position of the target backward reference block relative to the position of the current picture block.

### Claim 7 (depends on 1)

The method according to claim 1, wherein the pixel value of the target forward reference block is determined based on the position of the target forward reference block, and the pixel value of the target backward reference block is determined based on the position of the target backward reference block.

### Claim 8 (depends on 1)

The method according to claim 1, wherein the positions of the N forward reference blocks comprise a position of the initial forward reference block and positions of (N−1) candidate forward reference blocks, and an offset of a position of each candidate forward reference block relative to the position of the initial forward reference block is an integer pixel distance or a fractional pixel distance; or
the positions of the N backward reference blocks comprise a position of the initial backward reference block and positions of (N−1) candidate backward reference blocks, and an offset of a position of each candidate backward reference block relative to the position of the initial backward reference block is an integer pixel distance or a fractional pixel distance.

### Claim 9 (depends on 1)

The method according to claim 1, wherein the initial motion information comprises a first motion vector and a first reference picture index corresponding to a first list (L0), and a second motion vector and a second reference picture index corresponding to a second list (L1); and
wherein the determining positions of N forward and N backward reference blocks comprises:
determining, based on the first motion vector and the position of the current picture block, the position of the initial forward reference block of the current picture block in a forward reference picture corresponding to the first reference picture index, using the position of the initial forward reference block as a first search start point, and determining the positions of the (N−1) candidate forward reference blocks in the forward reference picture, wherein the positions of the N forward reference blocks comprise the position of the initial forward reference block and the positions of the (N−1) candidate forward reference blocks; and
determining, based on the second motion vector and the position of the current picture block, the position of the initial backward reference block of the current picture block in a backward reference picture corresponding to the second reference picture index, using the position of the initial backward reference block as a second search start point, and determining the positions of the (N−1) candidate backward reference blocks in the backward reference picture, wherein the positions of the N backward reference blocks comprise the position of the initial backward reference block and the positions of the (N−1) candidate backward reference blocks.

### Claim 10 (depends on 1)

The method according to claim 1, wherein the determining, from the positions of the N forward and N backward reference blocks based on a matching cost criterion, positions of a target forward reference block and a target backward reference block of the current picture block, comprises:
determining, from the positions of the N forward and N backward reference blocks, the positions of the target forward and target backward reference blocks of the current picture block, wherein the target forward and target backward reference blocks have a minimum matching error among N matching errors of the N forward and N backward reference blocks; or
determining, from the positions of the N forward and N backward reference blocks, the positions of the target forward and target backward reference blocks of the current picture block, wherein the target forward and target backward reference blocks have a matching error less than or equal to a matching error threshold.

### Claim 11 (depends on 1)

The method according to claim 1, wherein the method is used for encoding the current picture block; and the obtaining initial motion information of a current picture block comprises: obtaining the initial motion information from a candidate motion information list of the current picture block; or
the method is used for decoding the current picture block; and before the obtaining initial motion information of a current picture block, the method further comprises: obtaining indication information from a bitstream of the current picture block, wherein the indication information indicates the initial motion information of the current picture block.

### Claim 12 (depends on 1)

The method according to claim 1, wherein the matching cost criterion is an sum of absolute difference (SAD) criterion, the target forward and target backward reference blocks have a minimum SAD value among N SAD values of the N forward and N backward reference blocks.

### Claim 13 (depends on 1)

The method according to claim 1, wherein the N forward reference blocks are located in a forward reference picture, and the N backward reference blocks are located in a backward reference picture; and wherein the N forward and N backward reference blocks have the same size with the current picture block.

### Claim 14

A picture prediction apparatus, comprising:
a memory storage comprising instructions; and
one or more processors in communication with the memory, wherein the one or more processors execute the instructions to:
obtain initial motion information of a current picture block;
determining positions of N forward and N backward reference blocks based on the initial motion information, the N forward reference blocks comprising an initial forward reference block, the N backward reference blocks comprising an initial backward reference block, and N is an integer greater than 1;
determine, from the positions of the N forward and N backward reference blocks, based on a matching cost criterion, positions of a target forward reference block and a target backward reference block of the current picture block,
wherein for positions of n-th forward and n-th backward reference blocks of the N forward and N backward reference blocks, a first position offset and a second position offset are in a mirror relationship, the first position offset representing an offset of the position of the n-th forward reference block relative to a position of the initial forward reference block, and the second position offset representing an offset of the position of the n-th backward reference block relative to a position of the initial backward reference block; wherein is an integer and 0≤n<N or 0<n<N; and
obtain a predicted value of a pixel value of the current picture block based on a pixel value of the target forward reference block and a pixel value of the target backward reference block.

### Claim 15 (depends on 14)

The apparatus according to claim 14, wherein the position of the target forward reference block is associated with (delta1x′, delta0y′) representing an offset of the position of the target forward reference block relative to the position of the initial forward reference block,
the position of the target backward reference block is associated with (delta1x′, delta1y′) representing an offset of the position of the target backward reference block relative to the position of the initial backward reference block, and
wherein delta1x′=−delta1x′, and delta0y′=−delta1y′.

### Claim 16 (depends on 14)

The apparatus according to claim 14, wherein the positions of the N forward reference blocks comprise a position of the initial forward reference block and positions of (N−1) candidate forward reference blocks; or
the positions of the N backward reference blocks comprise a position of the initial backward reference block and positions of (N−1) candidate backward reference blocks,
for positions of n-th candidate forward and n-th candidate backward reference blocks of the (N−1) candidate forward and (N−1) candidate backward reference blocks, a first position offset and a second position offset are in a mirror relationship, the first position offset representing an offset of the position of the n-th candidate forward reference block relative to a position of the initial forward reference block, and the second position offset representing an offset of the position of the n-th candidate backward reference block relative to a position of the initial backward reference block n is an integer and 0<n≤N−1.

### Claim 17 (depends on 14)

The apparatus according to claim 14, wherein a direction of the first position offset is opposite to a direction of the second position offset, and an amplitude of the first position offset is the same as an amplitude of the second position offset.

### Claim 18 (depends on 14)

The apparatus according to claim 14, wherein the first position offset is represented by (delta0x, delta0y) and the second position offset is represented by (delta1x, delta1y), wherein delta0x=−delta1x, and delta0y=−delta1y.

### Claim 19 (depends on 14)

The apparatus according to claim 14, wherein the one or more processors further execute the instructions to:
obtain updated motion information of the current picture block, wherein the updated motion information comprises an updated forward motion vector and an updated backward motion vector,
wherein the updated forward motion vector points to the position of the target forward reference block, and the updated backward motion vector points to the position of the target backward reference block, or
wherein the updated forward motion vector indicates an offset of the position of the target forward reference block relative to the position of the current picture block, and the updated backward motion vector indicates an offset of the position of the target backward reference block relative to the position of the current picture block.

### Claim 20 (depends on 14)

The apparatus according to claim 14, wherein the pixel value of the target forward reference block is determined based on the position of the target forward reference block, and the pixel value of the target backward reference block is determined based on the position of the target backward reference block.

### Claim 21 (depends on 14)

The apparatus according to claim 14, wherein the positions of the N forward reference blocks comprise a position of the initial forward reference block and positions of (N−1) candidate forward reference blocks, and an offset of a position of each candidate forward reference block relative to the position of the initial forward reference block is an integer pixel distance or a fractional pixel distance; or
the positions of the N backward reference blocks comprise a position of the initial backward reference block and positions of (N−1) candidate backward reference blocks, and an offset of a position of each candidate backward reference block relative to the position of the initial backward reference block is an integer pixel distance or a fractional pixel distance.

### Claim 22 (depends on 14)

The method according to claim 14, wherein the initial motion information comprises a first motion vector and a first reference picture index corresponding to a first list (L0), and a second motion vector and a second reference picture index corresponding to a second list (L1); and
wherein the one or more processors execute the instructions to:
determine, based on the first motion vector and the position of the current picture block, the position of the initial forward reference block of the current picture block in a forward reference picture corresponding to the first reference picture index, using the position of the initial forward reference block as a first search start point, and determine the positions of the (N−1) candidate forward reference blocks in the forward reference picture, wherein the positions of the N forward reference blocks comprise the position of the initial forward reference block and the positions of the (N−1) candidate forward reference blocks; and
determine, based on the second motion vector and the position of the current picture block, the position of the initial backward reference block of the current picture block in a backward reference picture corresponding to the second reference picture index, using the position of the initial backward reference block as a second search start point, and determine the positions of the (N−1) candidate backward reference blocks in the backward reference picture, wherein the positions of the N backward reference blocks comprise the position of the initial backward reference block and the positions of the (N−1) candidate backward reference blocks.

### Claim 23 (depends on 14)

The apparatus according to claim 14, wherein the one or more processors execute the instructions to:
determine, from the positions of the N forward and N backward reference blocks, the positions of the target forward and target backward reference blocks of the current picture block, wherein the target forward and target backward reference blocks have a minimum matching error among N matching errors of the N forward and N backward reference blocks; or
determine, from the positions of the N forward and N backward reference blocks, the positions of the target forward and target backward reference blocks of the current picture block, wherein the target forward and target backward reference blocks have a matching error less than or equal to a matching error threshold.

### Claim 24 (depends on 14)

The apparatus according to claim 14, wherein the apparatus is an encoding apparatus for encoding the current picture block; and the one or more processors execute the instructions to: obtain the initial motion information from a candidate motion information list of the current picture block; or
the apparatus is a decoding apparatus for decoding the current picture block; and the one or more processors execute the instructions to: obtain indication information from a bitstream of the current picture block, wherein the indication information indicates the initial motion information of the current picture block.

### Claim 25 (depends on 14)

The apparatus according to claim 14, wherein the matching cost criterion is an sum of absolute difference (SAD) criterion, the target forward and target backward reference blocks have a minimum SAD value among N SAD values of the N forward and N backward reference blocks.

### Claim 26 (depends on 14)

The apparatus according to claim 14, wherein the N forward reference blocks are located in a forward reference picture, and the N backward reference blocks are located in a backward reference picture; and wherein the N forward and N backward reference blocks have the same size with the current picture block.

### Claim 27

A non-transitory computer-readable medium carrying a program code which, when executed by a computer device, causes the computer device to perform the method comprising:
obtaining initial motion information of a current picture block;
determining positions of N forward and N backward reference blocks based on the initial motion information, the N forward reference blocks comprising an initial forward reference block, the N backward reference blocks comprising an initial backward reference block, and N is an integer greater than 1;
determining, from the positions of the N forward and N backward reference blocks, based on a matching cost criterion, positions of a target forward reference block and a target backward reference block of the current picture block,
wherein for positions of n-th forward and n-th backward reference blocks of the N forward and N backward reference blocks, a first position offset and a second position offset are in a mirror relationship, the first position offset representing an offset of the position of the n-th forward reference block relative to a position of the initial forward reference block, and the second position offset representing an offset of the position of the n-th backward reference block relative to a position of the initial backward reference block; wherein n is an integer and 0≤n<N or 0<n<N; and
obtaining a predicted value of a pixel value of the current picture block based on a pixel value of the target forward reference block and a pixel value of the target backward reference block.
