Game Development Reference
In-Depth Information
((
L i ,
R i )/
)
way of merging different contexts is required wherein p
are close
to reduce the number of contexts for conditional entropy coding. Thus, Lmax is
quantized into M levels to form primary contexts. In CBAC, M
Lmax
=
5 is found to
be sufficient. Denote the Lmax quantizer by Q , i.e., Q
:
Lmax
ₒ{
0
,
1
,
2
,
3
,
4
}
.
The quantization criterion is to minimize the conditional entropy of the
(
Level
,
Run
)
pairs. In an off-line design process, a set of
instances
could be from a training set, and use the standard dynamic programming technique
to choose 0
((
absLe
v
el
,
Run
),
Lmax
)
=
q 0
<
q 1
<
q 2
<
q 3
<
q 4
<
q 5
≤∞
to partition Lmax into M
ranges so that the needed average code length
p
(
q i
Lmax
<
q i + 1 )
p
((
L
,
R
) |
q i
Lmax
<
q i + 1 )
log
(
p
((
L
,
R
) |
q i
Lmax
<
q i + 1 )) }
i
(
L
,
R
)
=−
p
(
L
,
R
)
log p
((
L
,
R
) |
q i
Lmax
<
q i + 1 )
(6.15)
i
( L , R )
for coding these pairs is minimized. This quantizer, whose parameters are:
q 1 =
1
,
q 2 =
2
,
q 3 =
3
,
q 4 =
5
(6.16)
works almost as well as the optimal individual-image dependent Lmax quantizer.
The quantization function can also be defined as follows:
,
∈[
,
]
Lmax
Lmax
0
2
4
∈[
,
]
ˇ ( Lmax ) =
3
Lmax
3
4
.
(6.17)
,
otherwise
L i 1
And the primary context index C P ( L , R ) (
ˇ ( Lmax ) . This 5-Level
quantizer for the maximum magnitudes of previously coded coefficients actually
can help small images to generate enough samples for context modeling to learn
p
)
equals to
quickly in adaptive entropy coding. Meanwhile, it can also save
a lot of memory during entropy coding.
((
L i ,
R i )/
Lmax
)
6.3.3.2 Secondary Context
Under each primary context, seven nested secondary contexts are used to code the
bin value corresponding to binary decisions of Level and Run values. The first three
secondary contexts are used to code the bins of absLe
v
el , while the remaining
contexts are used to code the bins of the associated Run .
For the bins of absLe
v
el ,the secondary context index is defined as
C S ( L ) (
j
) = (
j
1
)
? j
:
2
,
(6.18)
 
Search WWH ::




Custom Search