Coding and decoding of spherical coordinates using an optimized spherical quantization dictionary
A method for coding or decoding a spatial direction of a sound source, in which a spherical quantization dictionary is defined on a 3D sphere by coding elevation and azimuth, giving at least one coded elevation index (i) on a number of elevation levels (N φ ) and a number of points per level (Ny θ (i)) determined on the basis of two successive cumulative cardinality values (cumN (i), cumN (i−1)), the cumulative cardinality value (cumN(i)) being representative of a number of points proportional to a total number of points and according to the area of a spherical region comprising at least one region delimited by the upper horizontal plane (φ=(i+½)δ φ ) of the positive elevation level of the coded elevation index (i) and a lower horizontal plane of the sphere.
1 . A method implemented by a coding device and comprising:
receiving a spatial direction parameter of a sound source in a sound scene;
coding the received spatial direction parameter of a sound source, the spatial direction parameter being defined by spherical coordinates comprising an elevation coordinate and an azimuth coordinate, wherein a spherical quantization dictionary is defined on a 3D sphere by an elevation coding and an azimuth coding, and wherein:
the elevation coding uses a scalar quantization, giving at least one coded elevation index (i) on a number of elevation levels (N φ ),
the azimuth coding uses a scalar quantization, according to a number of points per level (N θ (i)) depending on the coded elevation index (i),
the number of points per level (N θ (i)) is determined on the basis of two successive cumulative cardinality values (cumN(i), cumN(i−1)),
the cumulative cardinality value (cumN(i)) for a coded elevation index (i) being representative of a number of points proportional to a total number of points and according to the area of a spherical zone comprising at least one zone delimited by an upper horizontal plane
(
ϕ
=
(
i
+
1
2
)
δ
ϕ
)
of a positive elevation level of the coded elevation index (i) and a lower horizontal plane of the 3D sphere; and
obtaining a quantized spatial direction index based on the elevation coding and the azimuth coding.
2 . The method as claimed in claim 1 , wherein the elevation coding includes levels corresponding to the equator (0°) and to the poles (+/−90°) of the 3D sphere.
3 . The method as claimed in claim 1 , wherein a number of points (N θ (0)) for the azimuth coding is predetermined for the elevation level corresponding to the equator, and the total number of points
(
N
tot
′
)
is obtained by subtracting, from a target number of points (N tot )), the predetermined number of points corresponding to the equator and each of the North and South poles of the 3D sphere, according to the following expression:
N
tot
′
=
N
tot
-
N
θ
(
0
)
-
2
N
θ
(
N
ϕ
-
1
)
,
N tot being the target number of points of the 3D sphere for a given bit budget,
N θ (0), the predetermined number of points for the elevation level corresponding to the equator; and
2N θ (N φ −1) the predetermined number of points for the North and South poles of the 3D sphere.
4 . The method as claimed in claim 3 , wherein the cumulative cardinality value (cumN(i)) for a coded elevation index (i) is representative of a number of points proportional to the total number of points according to the area (A i ) of a spherical zone delimited by the upper horizontal plane
(
ϕ
=
-
(
i
+
1
2
)
δ
ϕ
)
of the positive elevation level of the coded elevation index (i) and this same plane of the 3D sphere symmetrical with respect to the equator
(
ϕ
=
(
i
+
1
2
)
δ
ϕ
)
minus the area (A 0 ) corresponding to the elevation level of the equator, according to the following ratio:
(
A
i
-
A
0
)
(
A
N
ϕ
-
2
-
A
0
)
N
tot
′
N φ −2 being the number of elevation quantization levels without the equator and the North and South poles of the 3D sphere and A N φ -2 , the area of the spherical zone corresponding to an elevation index N φ −2.
5 . The method as claimed in claim 4 , wherein the expression for the cumulative cardinality value is as follows:
c
u
m
N
(
i
)
=
2
A
r
r
i
(
N
tot
′
2
sin
(
(
i
+
1
2
)
δ
ϕ
)
-
sin
(
δ
ϕ
2
)
sin
(
(
N
ϕ
-
1
2
)
δ
ϕ
)
-
sin
(
δ
ϕ
2
)
)
with
i=1, . . . , N φ −2, N φ −2 being the number of elevation quantization levels without the equator and the North and South poles of the 3D sphere,
Arr i ( ) being a rounding to the nearest integer depending on i,
2
A
r
r
i
(
x
2
)
corresponding to a rounding to an even integer and δ φ being a given quantization step of the elevation.
6 . The method as claimed in claim 1 , wherein the elevation coding gives a coded elevation index (i) on a number of elevation levels (N φ ) and sign information.
7 . The method as claimed in claim 1 , wherein a global quantization index to be transmitted (index) is determined based on an azimuth index coded by scalar quantization on a determined number of points per level (N φ (i)) and a cumulative cardinality value obtained based on at least the coded elevation index.
8 . A coding device comprising:
a processing circuit configured to:
receive a spatial direction parameter of a sound source in a sound scene;
code the received spatial direction parameter of a sound source, the spatial direction parameter being defined by spherical coordinates comprising an elevation coordinate and an azimuth coordinate, wherein a spherical quantization dictionary is defined on a 3D sphere by an elevation coding and an azimuth coding, and wherein:
the elevation coding uses a scalar quantization, giving at least one coded elevation index (i) on a number of elevation levels (N φ ),
the azimuth coding uses a scalar quantization, according to a number of points per level (N φ (i)) depending on the coded elevation index (i),
the number of points per level (N θ (i)) is determined on the basis of two successive cumulative cardinality values (cumN(i), cumN(i−1)),
the cumulative cardinality value (cumN(i)) for a coded elevation index (i) being representative of a number of points proportional to a total number of points and according to the area of a spherical zone comprising at least one zone delimited by an upper horizontal plane
(
ϕ
=
(
i
+
1
2
)
δ
ϕ
)
of a positive elevation level of the coded elevation index (i) and a lower horizontal plane of the 3D sphere; and
obtain a quantized spatial direction index based on the elevation coding and the azimuth coding.
9 . The coding device as claimed in claim 8 , wherein the elevation coding includes levels corresponding to the equator (0°) and to the poles (+/−90°) of the 3D sphere.
10 . The coding device as claimed in claim 8 , wherein a number of points (N θ (0)) for the azimuth coding is predetermined for the elevation level corresponding to the equator, and the total number of points
(
N
tot
′
)
is obtained by subtracting, from a target number of points (N tot ), the predetermined number of points corresponding to the equator and each of the North and South poles of the 3D sphere, according to the following expression:
N
tot
′
=
N
tot
-
N
θ
(
0
)
-
2
N
θ
(
N
ϕ
-
1
)
,
N tot being the target number of points of the 3D sphere for a given bit budget,
N θ (0), the predetermined number of points for the elevation level corresponding to the equator; and
2N θ (N φ −1) the predetermined number of points for the North and South poles of the 3D sphere.
11 . The coding device as claimed in claim 10 , wherein the cumulative cardinality value (cumN(i)) for a coded elevation index (i) is representative of a number of points proportional to the total number of points according to the area (A i ) of a spherical zone delimited by the upper horizontal plane
(
ϕ
=
(
i
+
1
2
)
δ
ϕ
)
of the positive elevation level of the coded elevation index (i) and this same plane of the 3D sphere symmetrical with respect to the equator
(
ϕ
=
(
i
+
1
2
)
δ
ϕ
)
minus the area (A 0 ) corresponding to the elevation level of the equator, according to the following ratio:
(
A
i
-
A
0
)
(
A
N
ϕ
-
2
-
A
0
)
N
tot
′
N φ −2 being the number of elevation quantization levels without the equator and the North and South poles of the 3D sphere and A N φ -2 , the area of the spherical zone corresponding to an elevation index N φ −2.
12 . The coding device as claimed in claim 11 , wherein the expression for the cumulative cardinality value is as follows:
c
u
m
N
(
i
)
=
2
A
r
r
i
(
N
tot
′
2
sin
(
(
i
+
1
2
)
δ
ϕ
)
-
sin
(
δ
ϕ
2
)
sin
(
(
N
ϕ
-
1
2
)
δ
ϕ
)
-
sin
(
δ
ϕ
2
)
)
with
i=1, . . . , N φ −2, N φ −2 being the number of elevation quantization levels without the equator and the North and South poles of the 3D sphere,
Arr i ( ) being a rounding to the nearest integer depending on i,
2
A
r
r
i
(
x
2
)
corresponding to a rounding to an even integer and δ φ being a given quantization step of the elevation.
13 . The coding device as claimed in claim 8 , wherein the elevation coding gives a coded elevation index (i) on a number of elevation levels (N φ ) and sign information.
14 . The coding device as claimed in claim 8 , wherein a global quantization index to be transmitted (index) is determined based on an azimuth index coded by scalar quantization on a determined number of points per level (N θ (i)) and a cumulative cardinality value obtained based on at least the coded elevation index.
15 . A non-transitory storage medium able to be read by at least one processor of the coding device and storing a computer program comprising instructions for executing the method as claimed in claim 1 when the instructions are executed by the at least one processor.