Integer cosine transform matrix for picture coding
View Patent ↗An integer transform matrix is used for implementing a Discrete Cosine Transform (DCT). Optimized values for the integer transform matrix are derived that satisfy certain normalization constraints and that also minimize the frequency distortion in the transform matrix.
1. A system for processing data, comprising:
a processor using a transform matrix:
T
16
=
[
t
0
t
1
t
2
t
3
t
4
t
5
t
6
t
7
t
8
t
9
t
10
t
11
t
12
t
13
t
14
t
15
]
=
[
n
0
n
0
n
0
n
0
n
0
n
0
n
1
n
3
n
5
n
7
n
9
n
11
n
2
n
6
n
10
n
14
-
n
14
-
n
10
n
3
n
9
n
15
-
n
11
-
n
5
-
n
1
n
4
n
12
-
n
12
-
n
4
-
n
4
-
n
12
n
5
n
15
-
n
7
-
n
3
-
n
13
n
9
n
6
-
n
14
-
n
2
-
n
10
n
10
n
2
n
7
-
n
11
-
n
3
n
15
n
1
n
13
n
8
-
n
8
-
n
8
n
8
n
8
-
n
8
n
9
-
n
5
-
n
13
n
1
-
n
15
-
n
3
n
10
-
n
2
n
14
n
6
-
n
6
-
n
14
n
11
-
n
1
n
9
n
13
-
n
3
n
7
n
12
-
n
4
n
4
-
n
12
-
n
12
n
4
n
13
-
n
7
n
1
-
n
5
n
11
n
15
n
14
-
n
10
n
6
-
n
2
n
2
-
n
6
n
15
-
n
13
n
11
-
n
9
n
7
-
n
5
n
0
n
0
n
13
n
15
-
n
6
-
n
2
-
n
7
-
n
13
n
12
n
4
n
1
n
11
n
14
-
n
6
-
n
5
-
n
9
-
n
8
n
8
n
11
n
7
n
2
-
n
10
n
15
-
n
5
-
n
4
n
12
-
n
9
n
3
n
10
-
n
14
n
3
-
n
1
n
0
n
0
n
0
n
0
n
0
n
0
n
0
n
0
-
n
15
-
n
13
-
n
11
-
n
9
-
n
7
-
n
5
-
n
3
-
n
1
-
n
2
-
n
6
-
n
10
-
n
14
n
14
n
10
n
6
n
2
n
13
n
7
n
1
n
5
n
11
-
n
15
-
n
9
-
n
3
n
4
n
12
-
n
12
-
n
4
-
n
4
-
n
12
n
12
n
4
-
n
11
-
n
1
-
n
9
n
13
n
3
n
7
-
n
15
-
n
5
-
n
6
n
14
n
2
n
10
-
n
10
-
n
2
-
n
14
n
6
n
9
n
5
-
n
13
-
n
1
-
n
15
n
3
n
11
-
n
7
n
8
-
n
8
-
n
8
n
8
n
8
-
n
8
-
n
8
n
8
-
n
7
-
n
11
n
3
n
15
-
n
1
n
13
n
5
-
n
9
-
n
10
n
2
-
n
14
-
n
6
n
6
n
14
-
n
2
n
10
n
5
-
n
15
-
n
7
n
3
-
n
13
-
n
9
n
1
-
n
11
n
12
-
n
4
n
4
-
n
12
-
n
12
n
4
-
n
4
n
12
-
n
3
n
9
-
n
15
-
n
11
n
5
-
n
1
n
7
-
n
13
-
n
14
n
10
-
n
6
n
2
-
n
2
n
6
-
n
10
n
14
n
1
-
n
3
n
5
-
n
7
n
9
-
n
11
n
13
-
n
15
]
to transform the data, where:
n 0 =17, n 1 =22, n 2 =24, n 3 =28, n 4 =23, n 5 =12, n 6 =20, n 7 =20,
n 8 =17, n 9 =12, n 10 =12, n 11 =16, n 12 =7, n 13 =8, n 14 =6, and n 15 =6.
2. A system according to claim 1 wherein the processor conducts a discrete cosine transform on the data according to the following:
C n×m =T m ×B n×m ×T n T ,
where B n×m is an image block of data with n columns and m rows, T n and T m are the horizontal and vertical transform matrices of size n×n and m×m, respectively, and C n×m denotes the cosine transformed n×m image block.
3. A system according to claim 1 wherein the processor conducts an inverse discrete cosine transform on the data according to the following:
B n×m =T m T ×C n×m ×T n ,
where B n×m denotes the inverse discrete cosine transformed image block with n columns and m rows, T n and T m represent the horizontal and vertical integer transform matrices of size n×n and m×m, respectively, and C n×m denotes a cosine transformed n×m image block.
4. A system according to claim 1 wherein the system is a device that receives, stores or transmits image data.
5. A system according to claim 1 including a memory that stores the transform matrix.
6. A system according to claim 5 wherein the memory stores different sized transform matrices, and the processor applies the different sized transform matrices according to a block size for a portion of the data being transformed.
7. A system according to claim 1 wherein the transform matrix is used for digital video coding.
8. An article of manufacture comprising computer-readable media containing instructions that, when executed or interpreted by a digital processor or cooperating processors, cause that processor or processors to perform a method of processing data, the method comprising:
using a transform matrix to process the data where the transform matrix is a 2 m ×2 m transform matrix that uses the following normalization constraints:
{
n
0
=
norm
∑
i
=
0
2
m
-
1
-
1
n
2
·
i
+
1
2
=
2
m
-
1
·
norm
2
∑
i
=
0
2
m
-
2
-
1
n
4
·
i
+
2
2
=
2
m
-
2
·
norm
2
∑
i
=
0
2
m
-
3
-
1
n
8
·
i
+
4
2
=
2
m
-
3
·
norm
2
⋮
n
2
m
-
1
=
norm
where, norm is an integer representing a normalization factor of the transform matrix; and
selecting the norm that minimizes a DCT distortion function:
E
2
m
=
1
2
m
∑
i
=
0
(
2
m
-
1
)
∑
j
=
0
j
≠
i
(
2
m
-
1
)
d
i
(
j
)
d
i
(
i
)
where d i =t i ·DCT , t i is a base vector of the transform matrix, and DCT is a real Discrete Cosine Transform.
9. The article of manufacture of claim 8 wherein m=16 and the values of the transform matrix comprise the following:
T
16
=
[
t
0
t
1
t
2
t
3
t
4
t
5
t
6
t
7
t
8
t
9
t
10
t
11
t
12
t
13
t
14
t
15
]
=
[
n
0
n
0
n
0
n
0
n
0
n
0
n
1
n
3
n
5
n
7
n
9
n
11
n
2
n
6
n
10
n
14
-
n
14
-
n
10
n
3
n
9
n
15
-
n
11
-
n
5
-
n
1
n
4
n
12
-
n
12
-
n
4
-
n
4
-
n
12
n
5
n
15
-
n
7
-
n
3
-
n
13
n
9
n
6
-
n
14
-
n
2
-
n
10
n
10
n
2
n
7
-
n
11
-
n
3
n
15
n
1
n
13
n
8
-
n
8
-
n
8
n
8
n
8
-
n
8
n
9
-
n
5
-
n
13
n
1
-
n
15
-
n
3
n
10
-
n
2
n
14
n
6
-
n
6
-
n
14
n
11
-
n
1
n
9
n
13
-
n
3
n
7
n
12
-
n
4
n
4
-
n
12
-
n
12
n
4
n
13
-
n
7
n
1
-
n
5
n
11
n
15
n
14
-
n
10
n
6
-
n
2
n
2
-
n
6
n
15
-
n
13
n
11
-
n
9
n
7
-
n
5
n
0
n
0
n
13
n
15
-
n
6
-
n
2
-
n
7
-
n
13
n
12
n
4
n
1
n
11
n
14
-
n
6
-
n
5
-
n
9
-
n
8
n
8
n
11
n
7
n
2
-
n
10
n
15
-
n
5
-
n
4
n
12
-
n
9
n
3
n
10
-
n
14
n
3
-
n
1
n
0
n
0
n
0
n
0
n
0
n
0
n
0
n
0
-
n
15
-
n
13
-
n
11
-
n
9
-
n
7
-
n
5
-
n
3
-
n
1
-
n
2
-
n
6
-
n
10
-
n
14
n
14
n
10
n
6
n
2
n
13
n
7
n
1
n
5
n
11
-
n
15
-
n
9
-
n
3
n
4
n
12
-
n
12
-
n
4
-
n
4
-
n
12
n
12
n
4
-
n
11
-
n
1
-
n
9
n
13
n
3
n
7
-
n
15
-
n
5
-
n
6
n
14
n
2
n
10
-
n
10
-
n
2
-
n
14
n
6
n
9
n
5
-
n
13
-
n
1
-
n
15
n
3
n
11
-
n
7
n
8
-
n
8
-
n
8
n
8
n
8
-
n
8
-
n
8
n
8
-
n
7
-
n
11
n
3
n
15
-
n
1
n
13
n
5
-
n
9
-
n
10
n
2
-
n
14
-
n
6
n
6
n
14
-
n
2
n
10
n
5
-
n
15
-
n
7
n
3
-
n
13
-
n
9
n
1
-
n
11
n
12
-
n
4
n
4
-
n
12
-
n
12
n
4
-
n
4
n
12
-
n
3
n
9
-
n
15
-
n
11
n
5
-
n
1
n
7
-
n
13
-
n
14
n
10
-
n
6
n
2
-
n
2
n
6
-
n
10
n
14
n
1
-
n
3
n
5
-
n
7
n
9
-
n
11
n
13
-
n
15
]
where,
n 0 =17, n 1 =22, n 2 =24, n 3 =28, n 4 =23, n 5 =12, n 6 =20, n 7 =20,
n 8 =17, n 9 =12, n 10 =12, n 11 =16, n 12 =7, n 13 =8, n 14 =6, and n 15 =6.
10. The article of manufacture of claim 8 including to claim 8 including:
receiving variable sized macroblocks of image data;
selecting transform matrices corresponding to the variable sized macroblocks; and
applying the selected transform matrices to the macroblocks.
11. The article of manufacture of claim 8 including using different 4×4, 8×8, and 16×16 transform matrices for Discrete Cosine Transforming different blocks of an image in the data.
12. The article of manufacture of claim 8 including basing the constraints used for deriving the transform matrix on a Hadamard transform.