# US 9,438,905 B2 · LM mode with uniform bit-width multipliers

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

- Number: US 9,438,905 B2
- Document ID: US9438905B2
- Status: Granted
- Kind: B2
- Application number: 13/802,525
- Filed: 2013-03-13
- Published: 2013-10-17
- Granted: 2016-09-06
- Earliest claimed: 2012-04-12
- Assignees: Futurewei Technologies, Inc.
- Applicants: Futurewei Technologies, Inc.
- Inventors: Lingzhi Liu
- Web page: https://patentgrep.com/patent/US9438905B2

## CPC

- H04N 19/50: using predictive coding (H04N19/61 takes precedence)
- H04N 19/119: Adaptive subdivision aspects, e.g. subdivision of a picture into rectangular or non-rectangular coding blocks
- H04N 19/176: the region being a block, e.g. a macroblock
- H04N 19/186: the unit being a colour or a chrominance component
- H04N 19/593: involving spatial prediction techniques
- H04N: PICTORIAL COMMUNICATION, e.g. TELEVISION

## Abstract

A video codec able to generate a predicted chroma sample for a chroma block based on reconstructed luma samples and reconstructed chroma samples. The reconstructed luma samples are located in neighboring blocks of a corresponding reconstructed luma block and adjacent to the corresponding reconstructed luma block. The reconstructed chroma samples are located in neighboring blocks of the chroma block and adjacent to the chroma block. The predicted chroma sample is generated by computing multipliers. Each of the multipliers has a bit width no greater than an input bit depth of the chroma block. The predicted chroma sample is generated without the need for any multiplier having a bit width greater than the input bit depth of the chroma block.

## Claims

### Claim 1

A video codec comprising:
a processor configured to:
generate a predicted chroma sample for a chroma block based on:
a plurality of reconstructed luma samples located in neighboring blocks of a corresponding reconstructed luma block and adjacent to the corresponding reconstructed luma block, and
a plurality of reconstructed chroma samples located in neighboring blocks of the chroma block and adjacent to the chroma block,
wherein generating the predicted chroma sample comprises computing a plurality of multipliers, wherein each of the plurality of multipliers has a bit width no greater than an input bit depth of the chroma block, and wherein generating the predicted chroma sample does not require any multiplier that has a bit width greater than the input bit depth of the chroma block,
wherein generating the predicted chroma sample further comprises generating a plurality of filtered luma samples by filtering the plurality of reconstructed luma samples, and wherein the plurality of multipliers comprises:
a first flooring function of an average of the plurality of filtered luma samples; and
a second flooring function of an average of the plurality of reconstructed chroma samples,
wherein the first and second flooring functions are first and second intermediate variables denoted as avgY′ and avgC respectively, wherein the plurality of multipliers further comprises:
a third intermediate variable, denoted as RErrY′ representing a difference between a sum of the plurality of filtered luma samples and 2*nS*avgY′, and
a fourth intermediate variable, denoted as RErrC, representing a difference between a sum of the plurality of reconstructed chroma samples and 2*nS*avgC, and wherein nS denotes a width of the chroma block, which equals a number of the plurality of filtered luma samples,
wherein generating the predicted chroma sample further comprises computing intermediate variables denoted as a1 and a2 according to the following equations:
a1=LC−(2*nS*avgY′*avgC+avgY′*RErrC+avgC*RErrY′); and
a2=LL−(2*nS*avgY′2+2*avgY′*RErrY′).
wherein LC and LL are intermediate variables determined by the plurality of reconstructed chroma samples and the plurality of filtered luma samples, and wherein the predicted chroma sample is generated based on a1 and a2, and
wherein computing avgY′, avgC, RErrY′, and RErrC uses the following equations:
k0=Log 2((2*nS));
avgY′=L>>k0;
RErrY′=L&((1<<k0)−1);
avgC=C>>k0; and
RErrC=C&((1<<k0)−1),
wherein C denotes a sum of the plurality of reconstructed chroma samples, and wherein L denotes a sum of the plurality of filtered luma samples.

### Claim 2 (depends on 1)

The video codec of claim 1, wherein BitDepthC denotes the input bit depth of the chroma block, wherein pY′[x, y] denotes each of the plurality of filtered luma samples, wherein x and y are integers indicating a position, wherein p[x, y] denotes each of the plurality of reconstructed chroma samples, and wherein generating the predicted chroma sample further comprises determining LL and LC via
either equations:
⁢
k
⁢
⁢
3
=
Max
⁡
(
0
,
BitDepth
C
+
log
2
⁡
(
nS
)
-
14
)
;
⁢
LL
=
(
∑
y
=
0
nS
-
1
⁢
p
Y
′
⁡
[
-
1
,
y
]
2
+
∑
x
=
0
nS
-
1
⁢
p
Y
′
⁡
[
x
,
-
1
]
2
)
>>
k
⁢
⁢
3
;
and
LL
=
(
∑
y
=
0
nS
-
1
⁢
p
Y
′
⁡
[
-
1
,
y
]
*
p
⁡
[
-
1
,
y
]
+
∑
x
=
0
nS
-
1
⁢
p
Y
′
⁡
[
x
,
-
1
]
*
p
⁡
[
x
,
-
1
]
)
>>
k
⁢
⁢
3
or equations:
LL
=
(
∑
y
=
0
nS
-
1
⁢
p
Y
′
⁡
[
-
1
,
y
]
2
+
∑
x
=
0
nS
-
1
⁢
p
Y
′
⁡
[
x
,
-
1
]
2
)
;
and
LC
=
(
∑
y
=
0
nS
-
1
⁢
p
Y
′
⁡
[
-
1
,
y
]
*
p
⁡
[
-
1
,
y
]
+
∑
y
=
0
nS
-
1
⁢
p
Y
′
⁡
[
x
,
-
1
]
*
p
⁡
[
x
,
-
1
]
)
.

### Claim 3

A video codec comprising:
a processor configured to:
generate a predicted chroma sample for a chroma block based on:
a plurality of reconstructed luma samples located in neighboring blocks of a corresponding reconstructed luma block and adjacent to the corresponding reconstructed luma block, and
a plurality of reconstructed chroma samples located in neighboring blocks of the chroma block and adjacent to the chroma block,
wherein generating the predicted chroma sample comprises computing a plurality of multipliers, wherein each of the plurality of multipliers has a bit width no greater than an input bit depth of the chroma block, and wherein generating the predicted chroma sample does not require any multiplier that has a bit width greater than the input bit depth of the chroma block,
wherein generating the predicted chroma sample further comprises generating a plurality of filtered luma samples by filtering the plurality of reconstructed luma samples, and wherein the plurality of multipliers comprises:
a first flooring function of an average of the plurality of filtered luma samples; and
a second flooring function of an average of the plurality of reconstructed chroma samples,
wherein the first and second flooring functions are first and second intermediate variables denoted as avgY′ and avgC respectively, wherein the plurality of multipliers further comprises:
a third intermediate variable, denoted as RErrY′, representing a difference between a sum of the plurality of filtered luma samples and 2*nS*avgY′, and
a fourth intermediate variable, denoted as RErrC, representing a difference between a sum of the plurality of reconstructed chroma samples and 2*nS*avgC, and wherein nS denotes a width of the chroma block, which equals a number of the plurality of filtered luma samples,
wherein generating the predicted chroma sample further comprises computing intermediate variables denoted as a1 and a2 according to the following equations:
a1=LC−(2*nS*avgY′*avgC+avgY′*RErrC+avgC*RErrY′); and
a2=LL−(2*nS*avgY′2+2*avgY′*RErrY′).
wherein LC and LL are intermediate variables determined by the plurality of reconstructed chroma samples and the plurality of filtered luma samples, and wherein the predicted chroma sample is generated based on a1 and a2, and
wherein BitDepthC denotes the input bit depth of the chroma block, wherein the plurality of multipliers further comprises an intermediate variable denoted as als, and wherein computing als follows equations:
k1=Max(0,log2(abs(a1))−BitDepthC+2); and
a1s=a1>>k1.

### Claim 4 (depends on 3)

The video codec of claim 3, wherein the plurality of multipliers further comprises an intermediate variable denoted as a2t, and wherein a2t is computed based on an intermediate variable a2s following either equations:
a2t=a2s<1?0:(1m Div [a2s]+(1<<15−BitDepthC−1)))>>(15−BitDepthC));
and
a2t=Clip1C(a2t),
or equations:
a2t=a2s<32?0:(1m Div [a2s]+(1<<(15−BitDepthC−1)))>>(15−BitDepthC));
and
a2t=Clip1C(a2t).

### Claim 5 (depends on 1)

The video codec of claim 1, wherein the input bit depth equals 8 or 10, and wherein the width of the chroma block is no less than 4 and no greater than 16.

### Claim 6 (depends on 1)

The video codec of claim 1, wherein the processor is further configured to:
generate a residual sample indicating a difference between the predicted chroma sample and a corresponding chroma sample in the chroma block; and
entropy encode the residual sample to generate an encoded residual sample.

### Claim 7 (depends on 1)

The video codec of claim 1, wherein the processor is further configured to:
decode an encoded residual sample to generate a decoded residual sample; and
combine the decoded residual sample and the predicted chroma sample to generate a corresponding chroma sample in the chroma block.

### Claim 8

A method used in video coding comprising:
generating, using a processor of a video codec, a predicted chroma sample for a chroma block based on:
a plurality of reconstructed luma samples located in neighboring blocks of a corresponding reconstructed luma block and adjacent to the corresponding reconstructed luma block, and
a plurality of reconstructed chroma samples located in neighboring blocks of the chroma block and adjacent to the chroma block,
wherein generating the predicted chroma sample comprises computing a plurality of multipliers, wherein each of the plurality of multipliers has a bit width no greater than an input bit depth of the chroma block, and wherein generating the predicted chroma sample does not require any multiplier that has a bit width greater than the input bit depth of the chroma block,
wherein generating the predicted chroma sample further comprises generating a plurality of filtered luma samples by filtering the plurality of reconstructed luma samples, and wherein the plurality of multipliers comprises:
a first flooring function of an average of the plurality of filtered luma samples; and
a second flooring function of an average of the plurality of reconstructed chroma samples,
wherein the first and second flooring functions are first and second intermediate variable denoted as avgY′ and avgC respectively, wherein the plurality of multipliers further comprises:
a third intermediate variable, denoted as RErrY′, representing a difference between a sum of the plurality of filtered luma samples and 2*nS*avgY′, and
a fourth intermediate variable, denoted as RErrC, representing a difference between a sum of the plurality of reconstructed chroma samples and 2*nS*avgC, and wherein nS denotes a width of the chroma block, which equals a number of the plurality of filtered luma samples,
wherein generating the predicted chroma sample further comprises computing intermediate variables denoted as a1 and a2 according to the following equations:
a1=LC−(2*nS*avgY′*avgC+avgY′*RErrC+avgC*RErrY′); and
a2=LL−(2*nS*avgY′2+2*avgY′*RErrY′).
wherein LC and LL are intermediate variables determined by the plurality of reconstructed chroma samples and the plurality of filtered luma samples, and wherein the predicted chroma sample is generated based on a1 and a2, and
wherein BitDepthC denotes the input bit depth of the chroma block, wherein the plurality of multipliers further comprises an intermediate variable denoted as a1s, and wherein computing a1s follows equations:
k1=Max(0,log2(abs(a1))−BitDepthC+2); and
a1s=a1>>k1.
