The present application is a U.S. national stage application under 35 U.S.C. § 371 of PCT Application No. PCT/CN2020/089592, filed May 11, 2020, which claims priority to Chinese Patent Application No. 202010034025.9, filed Jan. 13, 2020. The disclosures of the aforementioned priority applications are incorporated herein by reference in their entireties.
The present invention relates to the field of point cloud processing, in particular to a point cloud attribute prediction method and device based on a filter.
A 3D point cloud is an important manifestation of digitalization of the real world. With rapid development of 3D scanning devices (laser type, radar type and the like), the precision and the resolution of a point cloud are higher. A high-precision point cloud is widely applied to construction of city digital maps and provides a technical support for many hot researches on smart city, manless driving, preservation of cultural relics and the like. The point cloud is obtained by sampling the surface of an object through the 3D scanning device, and the number of points of one frame of point cloud is of million level, wherein each point contains attribute information including geometrical information, color and reflectivity, and there is a huge amount of data. The huge data amount of the 3D point cloud poses a huge challenge for data storage and transmission and the like, so point cloud compression is very necessary.
Point cloud compression is mainly divided into geometry compression and attribute compression. At present, point cloud attribute compression frameworks described in a test platform TMC13v8 (Test Model for Category 1&3 version 8) provided by international organization for standardization (Moving Picture Experts Group, MPEG) mainly have the following types:
Meanwhile, there is also a point cloud attribute compression method described in a test platform PCEM v0.1 provided by China AVS (Audio Video coding Standard) Point Cloud Compression Working Group at present, and the point cloud attribute compression method mainly employs a Morton sequence based point cloud prediction method, that is, a current point cloud is subjected to Morton sequencing according to position information of the point cloud, an attribute value of a previous point of the current point based on the Morton sequence is selected as the attribute prediction value of the current point, and finally, the attribute prediction value is subtracted from an actual attribute value of the current point to obtain an attribute residual.
However, the above related technologies conduct attribute prediction after finding neighbor points without considering a position relationship between points among the neighbor points and the other points, and original technologies only consider a position relationship between the neighbor points and the current point, so that a filter is proposed, considering both the position relationship between the neighbor points and the current point and the position relationship between points among the neighbor points and the other points. With respect of 2D image compression according to a traditional rule, a reference point is a top left pixel point generally, and a coded certain pixel value or an average of the certain pixel value is used for prediction; however, considering that distribution of the points in each point cloud is irregular and unordered, when the nearest neighbor points are selected in a pred mode, it cannot be guaranteed that when the nearest neighbor points are selected by the KNN, all the neighbor points are uniformly distributed at the periphery of the current point (the ideal condition, as shown in the right diagram of
As shown in the left diagram of
By considering the above case, a method based on quick recoloring between the neighbor points is proposed, with considering both a geometrical relationship between the neighbor points and the current point and a geometrical relationship between the neighbor points, so that the prediction solution of the method is more effective.
The present invention provides a point cloud attribute prediction method and device based on a filter, which improve the compression performance of attributes of point clouds.
The technical solution of the present invention is described as follows:
According to one aspect of the present invention, provided is a point cloud attribute prediction method, comprising: determining K nearest neighbor points of a current point; determining a filter matrix; and determining an attribute prediction value of the current point according to the filter matrix.
According to another aspect of the present invention, provided is a point cloud attribute prediction device, comprising a processor, a memory and a communication bus. A computer readable program which may be executed by the processor is stored on the memory; the communication bus achieves connection communication between the processor and the memory; and the processor achieves the steps of one of the point cloud attribute prediction methods of the above claims when executing the computer readable program.
Compared with the prior art, the present invention has the beneficial effects that:
By using the point cloud attribute prediction method and device based on the filter of the present invention, the accuracy of intra-frame prediction of attributes, and neighbor points in a point cloud sequence is better used to conduct attribute prediction on the current point.
In order to more clearly describe the technical solutions of the embodiments of the present invention, the accompanying drawings required to describe the embodiments or the prior art are briefly described below. Apparently, the accompanying drawings described below are only some embodiments of the present invention. Those of ordinary skill in the art may further obtain other accompanying drawings based on these accompanying drawings without inventive effort.
The present invention is further described in the following embodiments in conjunction with the appended drawing, which do not limit the scope of the present invention in any way.
In order to improve the accuracy of intra-frame prediction of attributes and better use neighbor points in a point cloud sequence to conduct attribute prediction on the current point, the present invention provides a point cloud attribute prediction method and device based on a filter, which improve the compression performance of attributes of point clouds.
As shown in
In the step 1, the K nearest neighbor points of the current point are determined by using a method 1, a method 2, a method 3 or a method 4, wherein
Method 1: K points at the nearest Euclidean distance from a current point under the L2 norm condition are selected as K nearest neighbor points of the current point.
Method 2: K points at the nearest Manhattan distance from the current point under the L1 norm condition are selected as the K nearest neighbor points of the current point.
Method 3: K points at the nearest distance from the current point after Morton sequencing are selected as the K nearest neighbor points of the current point; and specifically, as shown in
Xk=(xN-1kxN-2k . . . x1kx0k).
Yk=(yN-1kyN-2k . . . y1ky0k).
Zk=(zN-1kzN-2k . . . z1kz0k).
A Morton code corresponding to the Ku point may be expressed as follows:
Mk=(xN-1kyN-1kzN-1k,xN-2kyN-2kzN-2k, . . . x1ky1kz1k,x0ky0kz0k).
Each three bits am expressed with an octal number, mnk=(xnkynkznk), n=0, 1, . . . , N−1 and then the Morton code corresponding to the Kth point may be expressed as
Mk=(mN-1kmN-2k . . . m1km0k)
Front K points of the current point after Morton sequencing are found as the K nearest neighbor points of the current point. The sequencing schematic diagram of the Morton sequence is shown in
Method 4: K points at the nearest geodesic distance from the current point are selected as the K nearest neighbor points of the current point; and specifically, as shown in
In the step 2, specifically, the filter matrix may be detected by using a method 1, a method 2 or a method 3, wherein
Method 1: the filter matrix is determined according to the type of a point cloud or an attribute.
Method 2: the filter matrix is obtained according to weighted calculation of geometrical distances between the K nearest neighbor points.
The filter of the current point is automatically calculated according to the geometrical relationship between the K nearest neighbor points. That is, assuming the filter to be
a prediction formula to be
to be a prediction value of the attribute of the current point,
to be an attribute matrix formed by 3 nearest neighbor points of the current point,
to be a weight matrix of the 3 nearest neighbor points of the current point, a calculation formula to be
wherein (δj)j∈N
Let a=f=n be a set fixed value (a number between 0 and 1),
wherein dist13=dist31, dist12=dist21, dist23=dist32, and distij represent a distance from the ith neighbor point to the jth neighbor point. The filter of the current point in a current point cloud is solved by using the geometrical relationship. Finally, the filter is determined to be
Method 3: the filter matrix is determined according to a relationship of sizes of geometrical distances between the K nearest neighbor points. That is, assuming the filter to be
a prediction formula to be
to be a prediction value of the attribute of the current point,
to be an attribute matrix formed by 3 nearest neighbor points of the current point,
to be a weight matrix of the 3 nearest neighbor points of the current point, a calculation formula to be
wherein (δj)j∈N
Let a=f=n be a set fixed value (a number between 0 and 1), wherein dist13=dist31, dist12=dist21, dist23=dist32, and distij represents a distance from the ith neighbor point to the jth neighbor point. Parameters are selected according to the relationship of the sizes of the distances; and assuming that a=f=m=F (F may be an arbitrary number between 0 and 1), the sizes of the distances are compared.
If dist12<dist13, setting that b=01, c=02, or otherwise, setting that c=01, b=02.
In a similar way, if dist21<dist23, setting that e=P1, g=P2, or otherwise, setting that g=P1, e=P2.
In a similar way, if dist31<dist32, setting that l=Q1, m=Q2, or otherwise, setting that m=Q1, l=Q2.
The filter of the current point in the current point cloud is solved by using the geometrical relationship. Finally, the filter is determined to be
Before the filter matrix is finally determined, the step 2 further comprises a method 1 or a method 2.
Method 1, the filter matrix is directly employed as a final filter matrix when being a decimal.
Method 2, when the filter matrix is the decimal, operation of converting a fixed-point number to a floating-point umber is conducted.
For example,
wherein the matrix is also equal to
then fixed-point number conversion is conducted on the filter matrix, and the matrix is changed into
and finally, an attribute prediction value is shifted 3 bits to the right (that is, divided by 8) wholly after being calculated to obtain the attribute prediction value.
On the coding side, determining the filter matrix further comprises: sequentially selecting parameter values of the filter matrix within a set parameter value range of the filter matrix, sequentially calculating corresponding code stream sizes and distortion values according to the parameter values of the filter, calculating rate distortion values according to the code stream sizes and the distortion values, and selecting the filter matrix corresponding to the minimal rate distortion value. On the coding side, determining the filter matrix further comprises a method 1, a method 2, or a method 3,
wherein method 1: values of the parameters of the filter matrix are directly coded into the code streams.
Method 2: a fixed value is subtracted from the values of the parameters of the filter matrix, and then difference values are coded into the code streams. For example,
the fixed value of 0.125 is subtracted, and then obtained is
Method 3: index values of the filter are coded into the code streams.
As shown in
method 1: the directly decoded filter matrix is taken as the filter matrix of the current point according to point cloud attribute code streams.
Method 2: parameters of the directly decoded filter matrix plus a fixed value are taken as the filter matrix of the current int according to the point cloud attribute code streams. For example,
the fixed value of 0.125 is added, and then obtained is
Method 3: the filter matrix obtained by looking up an index table according to the index values of the decoded filter is taken as the filter matrix of the current point according to the point cloud attribute code streams.
In the step 3, determining the attribute prediction value of the current point according to the filter matrix further comprises:
calculating products of the filter matrix and the attribute values of the K nearest neighbor points of the current point to obtain updated attribute values of the K nearest neighbor points, and calculating a weighted sum by multiplying the updated attribute values of the K nearest neighbor points with a weight vector as the attribute prediction value of the current point; or
calculating a weighted sum by multiplying the filter matrix with the weight vector as an updated weight vector, and calculating a weighted sum by multiplying the attribute values of the K nearest neighbor points with the updated weight vector as the attribute prediction value of the current point.
Calculation formulas of the above two are as follows:
When K is defined as 3,
wherein
is the attribute prediction value of the current point,
is the filter matrix,
is an attribute matrix formed by 3 nearest neighbor points of the current point,
is a weight matrix of 3 nearest neighbor points of the current point, and the calculation formula is
wherein (δj)j∈N
On the coding side, determining the attribute prediction value of the current point according to the filter matrix further comprises:
Method 3: a maximum deviation or an average deviation between attributes C of two points of the K nearest neighbor points of the current point is calculated as the deviation value Y:
deviation value=max(Ci−Cj)
or
deviation value=average(Ci−Cj)
wherein 1≤i≤K, 1≤j≤K, i≠j.
Determining the attribute prediction value of the current point according to the filter matrix further comprises: coding an attribute prediction mode corresponding to the attribute prediction value of the current point into the code streams.
On the decoding side, determining the attribute prediction value of the current point according to the filter matrix further comprises: solving the attribute prediction mode according to the point cloud attribute code streams; and determining the attribute prediction value of the current point according to the attribute prediction mode.
As shown in
In order to verify the effect of the present invention, the performance of the embodiments of the method of the present invention is compared with that of a benchmark result of a test platform TMC13v8.
Embodiment 1: in this solution, 3 nearest neighbor points found based on a KNN Euclidean distance is employed; as for a color attribute, an employed filter matrix is
a deviation between attribute information of the neighbor points is employed for selection of a threshold, and the threshold is selected as 64; and as for a reflectivity attribute, the employed filter matrix is
a deviation between attribute information of the neighbor points is employed for selection of the threshold, and the threshold is selected as 64.
Results are as shown in Table 1 and Table 2, wherein Table 1 shows a performance comparison diagram of the embodiment of the method of the present invention and a benchmark result of a currently latest basic platform TMC13v8 of Moving Picture Experts Group (MPEG) under the conditions of lossless geometry and lossless attributes (employing LOD based prediction transformation); and Table 2 shows a performance comparison diagram of the embodiment of the method of the present invention and a benchmark result of the test platform TMC13v8 under the conditions of loss geometry and loss attributes (employing LOD based prediction transformation).
Table 1 Test Form Under Lossless Geometry and Lossless Attributes (Comparing with Currently Latest Basic Platform TMC13v8)
Table 2 Test Form Under Lossless Geometry and Limited Loss Attributes (Comparing with Currently Latest Basic Platform TMC13v8)
Under the conditions of lossless geometry and lossless attributes, a color code rate of the present invention only requires 99.9%, and a reflectivity code rate of the present invention only requires 99.9% (as shown in Table 1).
As for a brightness attribute, under the conditions of lossless geometry and limited loss attributes, end-to-end rate distortion of the present invention is saved by 0.7% (as shown in Table 2).
As for a chromaticity attribute, under the conditions of lossless geometry and limited loss attributes, end-to-end rate distortion of the present invention is saved by 0.7% (as shown in Table 2).
As for the chromaticity attribute, under the conditions of lossless geometry and limited loss attributes, end-to-end rate distortion of the present invention is saved by 0.7% (as shown in Table 2).
As for the reflectivity attribute, under the conditions of lossless geometry and limited loss attributes, end-to-end rate distortion of the present invention is saved by 0.4% (as shown in Table 2).
Embodiment 2: in this solution, 3 nearest neighbor points found based on a KNN Euclidean distance is employed; and as for a color attribute, a filter of a current point is automatically calculated according to a geometrical relationship between K nearest neighbor points. That is, the filter is assumed as
and let a=f=n=0.6, wherein dist13=dist31, dist12=dist21, dist23=dist32, and distij represents a distance from the ith neighbor point to the jth neighbor point. Parameters are selected according to the relationship of the sizes of the distances; and assuming that a=F=m=F (F may be an arbitrary number between 0 and 1), the sizes of the distances are compared.
If dist12<dist13, setting that b=0.1, c=0.3, or otherwise, setting that c=0.1, b=0.3.
In a similar way, if dist21<dist23, setting that e=0.1, g=0.3, or otherwise, setting that g=0.1, e=0.3.
In a similar way, if dist31<dist32, setting that l=0.1, m=0.3, or otherwise, setting that m=0.1, l=0.3. A deviation between attribute information of the neighbor points is employed for selection of a threshold and the threshold is selected as 64.
Table 3 Test Form Under Lossless Geometry and Lossless Attributes (Comparing with Currently Latest Basic Platform TMC13v8)
Table 4 Test Form Under Lossless Geometry and Limited Loss Attributes (Comparing with Currently Latest Basic Platform TMC13v8)
Under the conditions of lossless geometry and lossless attributes, a color code rate of the present invention only requires 99.9% (as shown in Table 3).
As for a brightness attribute, under the conditions of lossless geometry and limited loss attributes, end-to-end rate distortion of the present invention is saved by 2.0% (as shown in Table 4).
As for a chromaticity attribute, under the conditions of lossless geometry and limited loss attributes, end-to-end rate distortion of the present invention is saved by 2.0% (as shown in Table 4).
As for the chromaticity attribute, under the conditions of lossless geometry and limited loss attributes, end-to-end rate distortion of the present invention is saved by 2.0% (as shown in Table 4).
Embodiment 3: in this solution, 3 nearest neighbor points found based on a KNN Euclidean distance is employed; and as for a color attribute, a filter of a current point is automatically calculated according to a geometrical relationship between K nearest neighbor points, and fixed-point number conversion is conducted on the filter. That is, the filter is assumed as
and let a=f=n=4, wherein dist13=dist31, dist12=dist21, dist23=dist32, and distij represents a distance from the ith neighbor point to the jth neighbor point. Parameters are selected according to the relationship of the sizes of the distances; and assuming that a=f=m=F, the sizes of the distances are compared.
If dist12<dist13, setting that b=1, c=3, or otherwise, setting that c=1, b=3.
In a similar way, if dist21<dist23, setting that e=1, g=3, or otherwise setting that g=1, e=3.
In a similar way, if dist31<dist32, setting that l=1, m=3, or otherwise setting that m=1, l=3.
A deviation between attribute information of the neighbor points is employed for selection of a threshold, and the threshold is selected as 64. An attribute prediction value is solved by shifting 3 bits to the right when being calculated finally. Compared with Embodiment 2, this solution has the advantages that the filter matrix is of a fixed-point number, floating-point number calculation cannot be introduced, and storage by the device is facilitated.
As or a brightness attribute, under conditions of lossless geometry and limited loss attributes, end-to-end rate distortion of the present invention is saved by 1.3% (as shown in Table 6).
As for a chromaticity attribute, under the conditions of lossless geometry and limited loss attributes, end-to-end rate distortion of the present invention is saved by 1.3% (as shown in Table 6).
As for the chromaticity attribute, under the conditions of lossless geometry and limited loss attributes, end-to-end rate distortion of the present invention is saved by 1.3% (as shown in Table 6).
A point cloud attribute prediction method and device based on a filter of the present invention are suitable for 3D scanning devices (laser type, radar type and the like), are widely applied to construction of city digital maps and provide a technical support for many hot researches on smart city, manless driving, preservation of cultural relics and the like. The above embodiments are merely specific implementations of the present invention for purpose of illustration rather than to limit the present invention, but the present invention is not restricted thereto. Although the present invention has been described in detail with respect to the previously described embodiments, it should be appreciated by one skilled in art, those familiar with the art may still make modification or readily contemplated changes on the technical solutions recorded in the embodiments, or make equivalent substitutions on part of its technical features; and such modifications changes or substitutions do not deviate the nature of the technical solutions from the spirit and scope of the technical solutions of the various embodiments in the present invention, and should fall within the extent of protection of the present invention. Therefore, the protection scope of the present invention should be defined only in accordance with the appended claims.
Number | Date | Country | Kind |
---|---|---|---|
202010034025.9 | Jan 2020 | CN | national |
Filing Document | Filing Date | Country | Kind |
---|---|---|---|
PCT/CN2020/089592 | 5/11/2020 | WO |
Publishing Document | Publishing Date | Country | Kind |
---|---|---|---|
WO2021/142985 | 7/22/2021 | WO | A |
Number | Name | Date | Kind |
---|---|---|---|
10229533 | Tian | Mar 2019 | B2 |
20170347100 | Chou | Nov 2017 | A1 |
20190081638 | Mammou | Mar 2019 | A1 |
20190156518 | Mammou | May 2019 | A1 |
20190156520 | Mammou | May 2019 | A1 |
20190311500 | Mammou | Oct 2019 | A1 |
20190311502 | Mammou | Oct 2019 | A1 |
20200105025 | Yea | Apr 2020 | A1 |
20210209812 | Han | Jul 2021 | A1 |
Number | Date | Country |
---|---|---|
106548460 | Mar 2017 | CN |
108702502 | Oct 2018 | CN |
109859114 | Jun 2019 | CN |
110418135 | Nov 2019 | CN |
110572655 | Dec 2019 | CN |
Entry |
---|
Lu et al., “PointNGCNN: Deep Convolutional Networks on 3D Point Clouds with Neighborhood Graph Filters” (Year: 2019). |
Gu et al., “3D Point Cloud Attribute Compression via Graph Prediction” (Year: 2020). |
Cohen et al., “Point Cloud Attribute Compression using 3-D Intra Prediction and Shape-Adaptive Transforms” (Year: 2016). |
Wei et al., “Weighted Attribute Prediction Based on Morton Code for Point Cloud Compression” (Year: 2020). |
Number | Date | Country | |
---|---|---|---|
20220254057 A1 | Aug 2022 | US |