WO2021046817A1 - Point cloud data encoding and decoding method and system and storage medium - Google Patents
Point cloud data encoding and decoding method and system and storage medium Download PDFInfo
- Publication number
- WO2021046817A1 WO2021046817A1 PCT/CN2019/105764 CN2019105764W WO2021046817A1 WO 2021046817 A1 WO2021046817 A1 WO 2021046817A1 CN 2019105764 W CN2019105764 W CN 2019105764W WO 2021046817 A1 WO2021046817 A1 WO 2021046817A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- point cloud
- cloud data
- decoding
- attribute
- leaf node
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Ceased
Links
Images
Classifications
-
- H—ELECTRICITY
- H03—ELECTRONIC CIRCUITRY
- H03M—CODING; DECODING; CODE CONVERSION IN GENERAL
- H03M7/00—Conversion of a code where information is represented by a given sequence or number of digits to a code where the same, similar or subset of information is represented by a different sequence or number of digits
Definitions
- the present invention generally relates to the technical field of point cloud coding, and more specifically relates to a coding and decoding method, system and storage medium for point cloud data.
- a point cloud is a form of expression of a three-dimensional object or scene. It is composed of a set of discrete points that are randomly distributed in space and express the spatial structure and surface properties of the three-dimensional object or scene. In order to accurately reflect the information in the space, the number of discrete points required is huge. In order to reduce the bandwidth occupied by point cloud data storage and transmission, the point cloud data needs to be encoded and compressed.
- the existing point cloud data encoding method is: first encoding the position coordinates, and then encoding the attribute values after the encoding of the position coordinates is finished;
- the existing point cloud data decoding method is: first decoding the code stream of the position coordinates, After decoding all the position coordinate code streams, decode the attribute value code streams.
- this encoding and decoding method has a problem: when the amount of data of the point cloud data point is large, there is a certain delay in the decoding process under this encoding and decoding scheme, and the decoder needs to decode all the position coordinates before it can be used. Decode the attribute value. When part of the point cloud data points need to be used, it is also necessary to decode the attribute values corresponding to each position coordinate one by one after decoding all the position coordinates, and then a complete and usable point cloud data point can be obtained. This obviously increases a lot of unnecessary calculations and makes efficiency low.
- the present invention provides a point cloud data coding and decoding scheme, which combines the characteristics of position coordinate coding and attribute coding, and adopts a coding scheme that combines position coordinate coding and attribute coding, so that when part of the point cloud data needs to be used, there is no need to After decoding the position coordinates of all the point cloud data, the attribute value decoding is performed, thereby improving the decoding efficiency.
- a point cloud data encoding method comprising: performing a hybrid encoding of position coordinates and attributes on the input point cloud data; and performing arithmetic encoding on the result of the hybrid encoding to obtain The code stream of the point cloud data; wherein, the hybrid encoding includes: performing multi-tree division on the space where the point cloud data is located to obtain multiple leaf nodes, and performing position encoding on the point cloud data in the leaf nodes, and Attribute coding; wherein the attribute data of a leaf node is located between the position data of the one leaf node and the position data of another leaf node in the code stream.
- the encoding method further includes: quantizing the position coordinates of the input point cloud data before performing hybrid encoding of the position coordinates and attributes of the input point cloud data, and The hybrid coding is performed based on the quantized position coordinates.
- the encoding method further includes: after quantizing the position coordinates of the input point cloud data, merging the attribute values of the point cloud data obtained by quantizing the same position coordinates; and Performing position coding and attribute coding on the point cloud data of any leaf node includes: coding the unique attribute value of the point cloud data in any leaf node.
- the encoding method further includes: after quantizing the position coordinates of the input point cloud data, not merging the attribute values of the point cloud data obtained by quantizing the same position coordinates;
- performing position coding and attribute coding on the point cloud data of any leaf node includes: respectively coding the number and attribute values of the point cloud data in any leaf node.
- the encoding method further includes: when any leaf node includes more than one point cloud data, combining the attribute values of the point cloud data in any leaf node; and
- the position encoding and attribute encoding of the point cloud data of any leaf node includes: encoding the merged attribute value of the point cloud data in the any leaf node.
- the encoding method further includes: when any leaf node includes more than one point cloud data, not merging the attribute values of the point cloud data in any leaf node; and Performing position coding and attribute coding on the point cloud data of any leaf node includes: respectively coding the number and attribute values of the point cloud data in any leaf node.
- the code stream includes an attribute merging flag bit, and the value of the attribute merging flag bit indicates whether the attribute values of the point cloud data are merged during the encoding process.
- encoding the attribute value of the point cloud data includes: performing binary encoding on the attribute value of the point cloud data.
- the performing binarization coding on the attribute value of the point cloud data includes: performing fixed-length coding, truncated Rice coding, or exponential Golomb coding on the attribute value of the point cloud data .
- a method for decoding point cloud data includes: performing arithmetic decoding on a bitstream of the point cloud data to obtain an arithmetic decoding result; and performing position coordinates on the arithmetic decoding result and Hybrid decoding of attributes to obtain the respective position coordinates and attribute values of the point cloud data; wherein, the hybrid decoding includes: decoding the position coordinates based on multi-tree division to obtain multiple leaf nodes, wherein the attribute of one leaf node The data is located between the position data of the one leaf node and the position data of another leaf node in the code stream; position decoding and attribute decoding are performed on the point cloud data contained in the leaf node.
- the decoding method further includes: determining, based on the code stream, whether the position coordinates of the point cloud data are quantized during the encoding process of the point cloud data, if so For quantization, inverse quantization is performed on the position coordinates obtained by the hybrid decoding.
- the decoding method further includes: after quantizing the position coordinates of the point cloud data in the encoding process of the point cloud data, determining the encoding process of the point cloud data Whether the attribute values of the point cloud data with the same position coordinates obtained by quantization have been merged; if it is determined that the merge has been carried out, the position decoding and attribute decoding on the point cloud data of any leaf node includes: Decoding the unique attribute value of the point cloud data in the node; if it is determined that the merging is not performed, the position decoding and attribute decoding on the point cloud data of any leaf node includes: The number and attribute value are decoded separately.
- the decoding method further includes: determining, based on the code stream, whether to correct the point cloud data in any leaf node that includes more than one point cloud data during the encoding process of the point cloud data. If it is determined to be merged, the position decoding and attribute decoding of the point cloud data of any leaf node includes: performing the merged attribute value of the point cloud data in any leaf node Decoding; if it is determined that no merging is performed, performing position decoding and attribute decoding on the point cloud data of any leaf node includes: decoding the number and attribute values of the point cloud data in any leaf node respectively.
- the decoding method further includes: determining whether the attribute values of the point cloud data are merged during the encoding process based on the attribute merging flag in the code stream, and based on the determined As a result, position decoding and attribute decoding are performed on the leaf node.
- decoding the attribute value of the point cloud data includes: performing binarization decoding on the attribute value of the point cloud data.
- the performing binarization decoding on the attribute value of the point cloud data includes: performing fixed-length decoding, truncated Rice decoding, or exponential Columbus decoding on the attribute value of the point cloud data .
- a point cloud data encoding system includes a storage device and a processor, and the storage device stores a computer program run by the processor, and the computer program The point cloud data encoding method described in any one of the above is executed when being run by the processor.
- a point cloud data decoding system includes a storage device and a processor.
- the storage device stores a computer program run by the processor, and the computer program
- the point cloud data decoding method described in any one of the above is executed when being run by the processor.
- a storage medium is provided, and a computer program is stored on the storage medium, and the computer program executes the point cloud data encoding method described in any one of the above items when the computer program is running.
- a storage medium having a computer program stored on the storage medium, and the computer program executes the point cloud data decoding method described in any one of the above items when the computer program is running.
- a coding scheme that combines position coordinate coding and attribute coding is adopted, so that part of the point cloud is used when needed.
- Fig. 1 shows a schematic flowchart of a point cloud data encoding method according to an embodiment of the present invention
- Fig. 2 shows a schematic diagram of octree division according to an embodiment of the present invention
- Fig. 3 shows a schematic diagram of recursive division of an octree according to an embodiment of the present invention
- Fig. 4 shows a schematic block diagram of a point cloud data encoding system according to an embodiment of the present invention
- Fig. 5 shows a schematic flowchart of a point cloud data decoding method according to an embodiment of the present invention
- Fig. 6 shows a schematic block diagram of a point cloud data decoding system according to an embodiment of the present invention.
- the current point cloud data encoding method encodes the attribute value of the point cloud data only after all the position coordinates of the point cloud data are encoded, so that all the position coordinates need to be decoded before the attribute value can be decoded.
- the coding and decoding efficiency is low. Based on this, the present invention provides an encoding and decoding solution for point cloud data.
- the encoding and decoding solution for point cloud data according to embodiments of the present invention will be described below with reference to the accompanying drawings.
- Fig. 1 shows a schematic flowchart of a point cloud data encoding method 100 according to an embodiment of the present invention.
- the point cloud data encoding method 100 may include the following steps:
- step S110 perform hybrid encoding of position coordinates and attributes on the input point cloud data.
- the hybrid encoding includes: multi-tree division of the space where the point cloud data is located to obtain multiple leaf nodes, The point cloud data is position-encoded and attribute-encoded.
- a distance measuring device such as a laser scanner and a lidar may be used to collect point cloud data for a certain object or a certain scene.
- the collected point cloud data includes position coordinates in a three-dimensional direction and attribute information of the position.
- the position coordinates of each point cloud data can be expressed as (x, y, z)
- the attribute information of each point cloud data can include attribute values such as color (R, G, B) or reflectance.
- the point cloud data is subjected to mixed coding of position coordinates and attributes, that is, a mixed coding of position coordinate coding (also referred to as position coding for short) and attribute coding.
- the encoding of the position coordinates may adopt multi-tree partition encoding (for example, octree partition encoding), and the encoding of the attributes is performed in the process of encoding the position coordinates.
- multi-tree division is performed on the space where the point cloud data is located to obtain multiple leaf nodes (that is, the nodes of the last layer obtained by multi-tree division), and the leaf nodes may have a side length less than or equal to the set minimum side Long block.
- Position coding and attribute coding are performed on the point cloud data in the leaf node, and the attribute coding result of one leaf node is located between the position coding result of one leaf node and the position coding result of another leaf node.
- the following uses octree division coding as an example to detail the above-mentioned mixed coding of position coordinates and attributes on point cloud data proposed by the present invention.
- the octree partition coding is a method of using octree partitioning and compressing the coordinate position.
- the division of each layer of the octree uses the coordinates of the center point of the current block to divide the current block into eight small sub-blocks through the center point.
- a schematic diagram of performing an octree division on a coding block is shown in Figure 2.
- the octree division can be implemented according to the following process: First, according to the maximum value of the position coordinates of the point cloud data (hereinafter referred to as the position coordinates) in each of the three directions, one of the three maximum values is obtained. The maximum value in the selected value is used to determine the side length of the initialization block used to initialize the octree division.
- the side length of the initialization block can be an integer power of 2 and be greater than or equal to and closest to the selected value. It should be understood that the selected value can be written into the header information of the code stream file for use by the decoding end.
- the octree partition coding can be started. The division of each layer of the octree uses the coordinates of the center point of the current block for sub-block division, and the current block is divided into eight small sub-blocks through the center point.
- the sub-block After the sub-block is divided, it will judge whether there is point cloud data in each sub-block, and the sub-blocks with point cloud data will be further divided until the sub-block is divided to the minimum, for example, the side length of the sub-block reaches the preset minimum side Long (usually set the preset minimum side length to 1), that is, stop dividing when the leaf node is obtained.
- the preset minimum side Long usually set the preset minimum side length to 1
- the schematic diagram of the recursive division of the octree is shown in Figure 3.
- the encoding is performed layer by layer, and the division of each octree is encoded layer by layer.
- the eight sub-blocks obtained after the octree division of each block will determine whether it contains point cloud data points. If it contains point cloud data points, it will be further divided. Taking Figure 3 as an example, the black squares in the figure indicate that the current sub-block contains point cloud data points, and the white squares indicate that the current sub-block does not contain point cloud data points.
- the root node When the root node is divided into an octree, it is determined in turn whether there are point cloud data points in each small block.
- the third block in the first divided octree contains For point cloud data points, the remaining seven blocks do not contain point cloud data points, so this division can be represented by 8 bits, specifically 0010 0000.
- the block containing the data points that is, the second level of division in Figure 3.
- the third block and the eighth block contain point cloud data points this time, then this octree division can be used 0010 0001.
- the left sub-block is first divided, and the result of the division is shown in the left half of the third layer in Figure 3.
- the first and fourth sub-blocks contain point cloud data points, then this octree division It can be represented by 1001 0000.
- the result of the division is shown in the right half of the third layer in Figure 3.
- the second and eighth sub-blocks contain point cloud data points.
- this octree division can be represented by 0100 0001.
- the division of the latter layers is similar to the previous description, and is divided layer by layer in the order of breadth first traversal.
- the binary code stream corresponding to the division result in Figure 3 is 0010 0000 0010 0001 1001 0000 0100 0001....
- the deepest position of the octree division has been reached at this time, that is, the leaf node block of the current octree has been reached, and no further division is required
- the number of point cloud data points contained in the current leaf node block and the respective attribute values of the one or more point cloud data points can be encoded.
- the leaf node block when the leaf node block contains a point cloud data point, it can be directly encoded with a 0 to represent it, and then the attribute value corresponding to this position coordinate will be encoded; when the leaf node block contains more than one point cloud
- For data points suppose that there are n point cloud data points in the current leaf node block. At this time, a 1 will be coded, then the value (n-1) will be coded, and then the attribute values corresponding to the n point cloud data points will be coded continuously . The number of point cloud points contained in each leaf node block and the corresponding attribute value are sequentially coded to obtain the result of the mixed coding of the position coordinates and attributes of the point cloud data.
- the encoding of the attribute value of the point cloud data may be binary encoding.
- the encoding of the attribute value of the point cloud data may be fixed-length encoding, truncated Rice encoding, or exponential Golomb encoding.
- this is only exemplary, and any other suitable method may be used to encode the attribute value of the point cloud data. The following describes the above three attribute encoding methods in detail.
- the attribute value of the point cloud data may be binarized by using a fixed-length code scheme.
- the bit depth of the fixed-length code scheme of the attribute value can be determined according to the largest value among the attribute values of all the point cloud data.
- the point cloud data acquisition device may also determine the bit depth of the fixed-length code scheme of the attribute value, that is, determine the bit depth of the fixed-length code scheme of the attribute value according to the bit depth of the acquired attribute value .
- the attribute value of the point cloud data can be converted into a binary number with a bit width equal to the above determined bit depth to realize the attribute value of the point cloud data The binarization.
- the attribute value of the point cloud data may be binarized by using a truncated Rice scheme.
- the threshold value can be set to cMax
- the Rice parameter is R
- the attribute value is Ref.
- the truncated Rice code is formed by concatenating the prefix code and the suffix code.
- the prefix code is composed of P 1s and one 0, and the length is P+1; if the prefix value P is greater than or equal to the value (cMax>>R), the prefix The code consists of (cMax>>R) 1s, and the length is (cMax>>R).
- the attribute value of the point cloud data may be binarized by adopting a k-order exponential Golomb code scheme.
- the k-order exponential Golomb code consists of a prefix and a suffix. Both the prefix and the suffix depend on the order k of the exponential Golomb code.
- the k-order exponential Golomb code used to represent the non-negative integer attribute value Ref can be generated by the following steps: (1) Write the attribute value Ref in binary form, remove the lowest k bits, and then add 1; (2) Calculate and leave For the number of bits under, subtract 1 from this number, that is, the number of prefix zeros that need to be added; (3) The lowest k bits removed in step (1) are added to the end of the bit string.
- the prefix is composed of m consecutive 0s and one 1
- the suffix is composed of m+k, which is the binary representation of Ref-2 k (2 m -1). According to this, the attribute value of any point cloud data of any leaf node block can be binarized.
- the point cloud data in the leaf node is encoded with position and attribute, and the attribute encoding result of one leaf node is located between the position encoding result of one leaf node and the position encoding result of another leaf node, namely The result of hybrid coding of the position coordinates and attributes of the point cloud data is obtained.
- step 110 of the point cloud data encoding method 100 exemplarily describes the process of step 110 of the point cloud data encoding method 100 according to the embodiment of the present invention.
- the subsequent steps of the encoding method 100 are described below with reference to FIG. 1.
- step 120 arithmetic coding is performed on the result of the hybrid coding to obtain a code stream of point cloud data, wherein the attribute data of one leaf node is located in the code stream at the position data of the one leaf node and the other leaf node Between the location data.
- the mixed coding result (binary code stream) obtained in step S120 can be sent to the arithmetic coding engine for arithmetic coding, then the position coordinates and attribute code streams of the point cloud data can be obtained, and the point-matching can be realized.
- the position coordinate coding and attribute coding of cloud data can be sent to the arithmetic coding engine for arithmetic coding, then the position coordinates and attribute code streams of the point cloud data can be obtained, and the point-matching can be realized.
- the encoding method 100 may further include (not shown in FIG. 1): before performing mixed encoding of the position coordinates and attributes of the input point cloud data, performing the mixed encoding of the input point
- the position coordinates of the cloud data are quantized, and the hybrid coding is performed based on the quantized position coordinates.
- the position coordinates of each input point cloud data are quantized to simplify the coding operation of the position coordinates of the point cloud data.
- the position coordinates of the input point cloud data can be converted into integer coordinates greater than or equal to zero by quantization.
- duplicate coordinate values may appear.
- the same position coordinate corresponds to multiple point cloud data, that is, the same position coordinate may correspond to multiple attributes value.
- the attribute values of the point cloud data obtained by quantizing the same position coordinates may be merged.
- the combination of attribute values may be, for example, performing a weighted summation, averaging, or other suitable operations on multiple attribute values. In short, multiple attribute values are converted into one attribute value.
- each leaf node obtained after the multi-tree division can be regarded as including only one point cloud data point.
- the attribute value is also one. Because although the leaf node may include multiple point cloud data points, its position coordinates are the same, so the position is regarded as one point (position encoding is based on including a point cloud data point for position encoding, that is, as mentioned above, the leaf The node includes a point cloud data point code 0), and its attribute values are merged, so the attribute code is to encode the unique attribute value.
- the leaf node always includes a point cloud data point and an attribute value, so the number of point cloud data points may not be encoded when encoding (because the number of point cloud data points in each leaf node The number of point cloud data is 1), and only the unique attribute value of the point cloud data point in each leaf node can be encoded, which can further reduce the number of bit stream bits and save encoding overhead.
- the attribute merging flag can be set in the code stream, and this flag can be used to identify the point in the encoding process.
- the attribute values of cloud data have been merged.
- the attribute values of the point cloud data can also be merged by default in the encoding process without setting the attribute merge flag bit.
- the attribute values of the point cloud data obtained by quantizing the same position coordinates may not be merged.
- the leaf nodes obtained after the multi-tree division may include the situation where there are multiple point cloud data points in the leaf nodes. And each point cloud data point has its own attribute value.
- the encoding of the point cloud data in the leaf node may include encoding the number of point cloud data in the leaf node and separately encoding the attribute value of each point cloud data.
- the attribute merging flag can be set in the code stream, and the flag can be used to identify the point cloud during the encoding process.
- the attribute values of the data are not merged.
- the encoding method 100 may further include (not shown in FIG. 1): when any leaf node includes more than one point cloud data, combining the point cloud data in any leaf node The attribute values of the data are merged; and the position encoding and attribute encoding of the point cloud data of any leaf node includes: encoding the merged attribute value of the point cloud data in any leaf node.
- each leaf node includes one point cloud data and one attribute value, so the leaf node
- the leaf node When encoding, it is sufficient to encode only the unique attribute value of the leaf node (for example, the merged attribute value, referred to as the merged attribute value), without the need to encode the number of point cloud data in the leaf node, thereby reducing the bit stream bit. Save coding overhead.
- the attribute merging flag can be set in the code stream, and this flag can be used to identify the point in the encoding process.
- the attribute values of cloud data have been merged.
- the attribute values of the point cloud data can also be merged by default in the encoding process without setting the attribute merge flag bit.
- the encoding method 100 may further include (not shown in FIG. 1): when any leaf node includes more than one point cloud data, the Merging the attribute values of the point cloud data; and performing position encoding and attribute encoding on the point cloud data of any leaf node includes: respectively encoding the number and attribute values of the point cloud data in any leaf node .
- the attribute value of each point cloud data in any leaf node that includes more than one point cloud data is not merged, so when encoding the leaf node, it is still necessary to encode the number and points of the point cloud data in the leaf node. The attribute value of the cloud data.
- the attribute merging flag can be set in the code stream, and the flag can be used to identify the point cloud during the encoding process.
- the attribute values of the data are not merged.
- the point cloud data coding method according to the embodiment of the present invention combines the characteristics of position coordinate coding and the characteristics of attribute coding, and adopts a coding scheme that combines position coordinate coding and attribute coding, so that part of the point cloud data is used when needed. In this case, it is not necessary to decode the position coordinates of all the point cloud data and then decode the attribute values, thereby improving the decoding efficiency.
- the method for encoding point cloud data according to an embodiment of the present invention may be implemented in a device, device, or system having a memory and a processor.
- FIG. 4 shows a schematic block diagram of a point cloud data encoding system 400 according to an embodiment of the present invention.
- the point cloud data encoding system 400 includes a storage device 410 and a processor 420.
- the storage device 410 stores a program for implementing the corresponding steps in the method for encoding point cloud data according to an embodiment of the present invention.
- the processor 420 is configured to run a program stored in the storage device 410 to execute corresponding steps of the point cloud data encoding method according to the embodiment of the present invention.
- the point cloud data encoding system 400 when the program is executed by the processor 420, the point cloud data encoding system 400 is caused to perform the following steps: perform a hybrid encoding of position coordinates and attributes on the input point cloud data; The result is arithmetic coding to obtain the code stream of the point cloud data; wherein, the hybrid coding includes: multi-tree division of the space where the point cloud data is located to obtain a plurality of leaf nodes, and the point cloud in the leaf nodes The data is subjected to position coding and attribute coding; wherein, the attribute data of one leaf node is located between the position data of the one leaf node and the position data of another leaf node in the code stream.
- the point cloud data encoding system 400 when the program is run by the processor 420, the point cloud data encoding system 400 is also caused to perform the following steps: before the input point cloud data is mixed encoding of position coordinates and attributes Quantifying the position coordinates of the input point cloud data, and performing the hybrid coding based on the quantized position coordinates.
- the point cloud data encoding system 400 when the program is run by the processor 420, the point cloud data encoding system 400 is also caused to perform the following steps: after quantizing the position coordinates of the input point cloud data, The attribute values of the point cloud data with the same position coordinates are quantified and merged; and the position coding and attribute coding of the point cloud data of any leaf node includes: performing the unique attribute value of the point cloud data in any leaf node coding.
- the point cloud data encoding system 400 when the program is run by the processor 420, the point cloud data encoding system 400 is also caused to perform the following steps: after quantizing the position coordinates of the input point cloud data, Quantifying the attribute values of the point cloud data with the same position coordinates are not merged; and performing position coding and attribute coding on the point cloud data of any leaf node includes: summing the number of point cloud data in any leaf node The attribute values are coded separately.
- the point cloud data encoding system 400 when the program is run by the processor 420, the point cloud data encoding system 400 is also caused to perform the following steps: when any leaf node includes more than one point cloud data, the any Merging the attribute values of the point cloud data in a leaf node; and performing position encoding and attribute coding on the point cloud data of any leaf node includes: merging attribute values of the point cloud data in any leaf node Encode.
- the point cloud data encoding system 400 when the program is run by the processor 420, the point cloud data encoding system 400 is also caused to perform the following steps: when any leaf node includes more than one point cloud data, the Merging the attribute values of the point cloud data in any leaf node; and performing position encoding and attribute encoding on the point cloud data of any leaf node includes: the number of point cloud data in any leaf node And the attribute value are coded separately.
- the code stream includes an attribute merging flag bit, and the value of the attribute merging flag bit indicates whether the attribute values of the point cloud data are merged during the encoding process.
- the point cloud data encoding system 400 when the program is executed by the processor 420, the point cloud data encoding system 400 is executed to encode the attribute value of the point cloud data, including: encoding the point cloud data
- the attribute value of is binary coded.
- the point cloud data encoding system 400 executes the binary encoding of the attribute values of the point cloud data, including:
- the attribute values of the point cloud data are subjected to fixed-length coding, truncated Rice coding or exponential Golomb coding.
- a storage medium on which program instructions are stored, and the program instructions are used to execute the point cloud data in the embodiments of the present invention when the program instructions are run by a computer or a processor.
- the storage medium may include, for example, a memory card of a smart phone, a storage component of a tablet computer, a hard disk of a personal computer, a read-only memory (ROM), an erasable programmable read-only memory (EPROM), a portable compact disk read-only memory (CD-ROM), USB memory, or any combination of the above storage media.
- the computer-readable storage medium may be any combination of one or more computer-readable storage media.
- the computer program instructions can execute the point cloud data encoding method according to the embodiment of the present invention when being executed by a computer.
- the computer program instructions when run by the computer or processor, cause the computer or processor to perform the following steps: perform hybrid encoding of position coordinates and attributes on the input point cloud data; and encode the hybrid encoding The result is arithmetic coding to obtain the code stream of the point cloud data; wherein, the hybrid coding includes: multi-tree division of the space where the point cloud data is located to obtain a plurality of leaf nodes, and the point cloud in the leaf nodes The data is subjected to position coding and attribute coding, wherein the attribute data of one leaf node is located between the position data of the one leaf node and the position data of another leaf node in the code stream.
- the computer or the processor executes the following steps: before performing the mixed encoding of the position coordinates and attributes on the input point cloud data Quantifying the position coordinates of the input point cloud data, and performing the hybrid coding based on the quantized position coordinates.
- the computer or the processor when the computer program instructions are executed by the computer or the processor, the computer or the processor further executes the following steps: after quantifying the position coordinates of the input point cloud data, The attribute values of the point cloud data with the same position coordinates are quantified and merged; and the position coding and attribute coding of the point cloud data of any leaf node includes: performing the unique attribute value of the point cloud data in any leaf node coding.
- the computer or the processor when the computer program instructions are executed by the computer or the processor, the computer or the processor further executes the following steps: after quantifying the position coordinates of the input point cloud data, Quantifying the attribute values of the point cloud data with the same position coordinates are not merged; and performing position coding and attribute coding on the point cloud data of any leaf node includes: summing the number of point cloud data in any leaf node The attribute values are coded separately.
- the computer or the processor when the computer program instructions are executed by the computer or the processor, the computer or the processor also executes the following steps: when any leaf node includes more than one point cloud data, the Merging the attribute values of the point cloud data in a leaf node; and performing position encoding and attribute coding on the point cloud data of any leaf node includes: merging attribute values of the point cloud data in any leaf node Encode.
- the computer or the processor when the computer program instructions are executed by the computer or the processor, the computer or the processor also executes the following steps: when any leaf node includes more than one point cloud data, the Merging the attribute values of the point cloud data in any leaf node; and performing position encoding and attribute encoding on the point cloud data of any leaf node includes: the number of point cloud data in any leaf node And the attribute value are coded separately.
- the code stream includes an attribute merging flag bit, and the value of the attribute merging flag bit indicates whether the attribute values of the point cloud data are merged during the encoding process.
- the computer or the processor executes the encoding of the attribute value of the point cloud data, including:
- the attribute value is binary coded.
- the method when the computer program instructions cause the computer or the processor to execute the binary encoding of the attribute value of the point cloud data when being executed by the computer or the processor, the method includes:
- the attribute value of the point cloud data is coded with fixed length, truncated Rice coding or exponential Golomb coding.
- a method for decoding point cloud data is also provided. Since the point cloud data decoding method according to the embodiment of the present invention corresponds to the point cloud data encoding method according to the embodiment of the present invention, for the sake of brevity, some processes in the decoding process that are similar or identical to the encoding process are no longer Go into details.
- FIG. 5 shows a schematic flowchart of a method 500 for decoding point cloud data according to an embodiment of the present invention. As shown in FIG. 5, the method 500 for decoding point cloud data may include the following steps:
- step S510 arithmetic decoding is performed on the bit stream of the point cloud data to obtain the arithmetic decoding result.
- step S510 corresponds to step S120 of the point cloud data encoding method 100 according to the embodiment.
- the code stream of the point cloud data is subjected to the inverse process of arithmetic encoding, that is, arithmetic decoding , Get the arithmetic decoding result.
- step S520 perform hybrid decoding of the position coordinates and attributes of the arithmetic decoding result to obtain the respective position coordinates and attribute values of the point cloud data; wherein, the hybrid decoding includes: performing position coordinates based on multitree division A plurality of leaf nodes are obtained by decoding, wherein the attribute data of one leaf node is located between the position data of the one leaf node and the position data of another leaf node in the code stream; Point cloud data performs position decoding and attribute decoding.
- step S520 corresponds to step S110 of the point cloud data encoding method 100 according to the embodiment.
- the arithmetic decoding result obtained in step S520 is decoded with position coordinates and attributes.
- the header information of the code stream can be decoded to obtain the maximum value of the maximum value of the position coordinates of the point cloud data in each of the three directions, and then based on this value, the edge of the initialization block used for multi-tree division can be determined long.
- multitree division decoding for example, octree division decoding
- the following uses octree division decoding as an example to detail the above-mentioned hybrid decoding of the position coordinates and attributes of the arithmetic decoding result proposed by the present invention.
- Decode 8 bits in turn to determine the octree division of a block. Each bit indicates whether a sub-block contains point cloud data points. If it is 1, it means it contains point cloud data points. If it is 0, it means it does not contain point cloud data points.
- the octree division and decoding are continued on the block containing the point cloud data points. When the octree division and decoding process proceeds until the side length of the block reaches the preset minimum side length (the preset minimum side length is usually set to 1), it indicates that the division has ended. Next, decode the number of point cloud points contained in each leaf node.
- the decoding numerical scheme should be a scheme corresponding to the encoding scheme for the attribute value adopted in the encoding process.
- the encoding of the attribute value of the point cloud data may be binary encoding.
- the encoding of the attribute value of the point cloud data may be fixed-length encoding, truncated Rice encoding, or exponential Golomb encoding. Therefore, correspondingly, in the embodiment of the present invention, the decoding of the attribute value of the point cloud data may be binarization decoding.
- the decoding of the attribute value of the point cloud data may be fixed-length decoding, truncated Rice decoding, or exponential Golomb decoding. It should be understood that this is only exemplary, and the decoding of the attribute value of the point cloud data may also be any other suitable method, depending on the encoding method adopted for the attribute value. The above three attribute decoding methods are described in detail below.
- the attribute value of the point cloud data is binarized using a fixed-length code scheme.
- the header information in the code stream can be decoded to obtain the bit depth used by the fixed-length code binarization scheme, and the bit width binary code stream represented by the bit depth can be decoded to obtain the corresponding attribute value.
- the attribute value of the point cloud data is binarized using a truncated Rice scheme.
- the header information in the code stream can be decoded to obtain the threshold value cMax and the Rice parameter R, and then the prefix code and the suffix code can be decoded.
- the attribute value of the point cloud data is binarized using a k-order exponential Golomb code scheme.
- the first non-zero bit is searched from the current position of the bit stream, and the number of zero bits found is recorded as m. After the first non-zero bit, m+
- the number of point cloud points contained in each leaf node block and the corresponding attribute value are sequentially decoded, that is, the result of a mixed decoding of the position coordinates and attributes of the arithmetic decoding result is obtained.
- the decoding method 500 may further include (not shown in FIG. 5): determining, based on the code stream, whether to position the point cloud data during the encoding process of the point cloud data.
- the coordinates are quantized, and if they are quantized, the position coordinates obtained by the hybrid decoding are inversely quantized.
- the code stream (for example, the quantization flag in the code stream) is used to determine whether the point cloud data is quantized during encoding. If quantization is performed, the position in the mixed decoding result obtained in step S520 needs to be determined.
- the decoding result is inversely quantized to obtain the position coordinates of the point cloud data.
- the decoding method 500 may further include (not shown in FIG. 5): determining the point cloud data after the position coordinates of the point cloud data are quantified in the encoding process of the point cloud data In the encoding process, whether the attribute values of the point cloud data with the same position coordinates obtained by the quantization are merged; if it is determined that the merge is performed, the position decoding and attribute decoding of the point cloud data of any leaf node includes: Decoding the unique attribute value of the point cloud data in any leaf node; if it is determined that no merging has been performed, performing position decoding and attribute decoding on the point cloud data of any leaf node includes: decoding the point in any leaf node The number of cloud data and the attribute value are decoded separately.
- the position coordinates of the point cloud data are quantized during the encoding process. Since the position coordinates of all the point cloud data are quantized, there may be repeated coordinate values. At this time, the same position Coordinates correspond to multiple point cloud data, that is, the same location coordinate may correspond to multiple attribute values. Therefore, it can be further determined whether the attribute values of the point cloud data with the same position coordinates obtained by quantization are merged (for example, determined by the attribute merge flag bit, of course, it can also be merged or not merged by default without the flag bit and the Confirm the steps).
- each leaf node can be regarded as including only one point cloud data point, and the attribute value is also one. Therefore, you can directly The unique attribute value of the point cloud data in each leaf node is decoded, without the need to decode the number of point cloud data, because the number of point cloud data in each leaf node is one, and there is no need to waste encoding bit pairs during encoding. It is encoded. Conversely, if it is determined that the attribute values of the point cloud data with the same position coordinates obtained after quantization are not merged, it means that the number of point cloud data and the attribute value of each point cloud data need to be decoded when decoding the leaf nodes.
- the method 500 may further include (not shown in FIG. 5): determining, based on the code stream, whether the point cloud data is encoded in the process of encoding more than one point cloud data.
- the attribute values of the point cloud data in any leaf node are merged; if it is determined that the merging is carried out, performing position decoding and attribute decoding on the point cloud data of any leaf node includes: Decoding the merged attribute value of the point cloud data of the point cloud; if it is determined that the merge is not performed, the position decoding and attribute decoding of the point cloud data of any leaf node includes: The number and attribute value are decoded separately.
- the point cloud data decoding method according to the embodiment of the present invention adopts a decoding scheme that combines position coordinate decoding and attribute decoding, so that when part of the point cloud data needs to be used, there is no need to decode the position coordinates of all the point cloud data. Then decode the attribute value to improve the decoding efficiency.
- the method for decoding point cloud data according to an embodiment of the present invention may be implemented in a device, device, or system having a memory and a processor.
- FIG. 6 shows a schematic block diagram of a point cloud data decoding system 600 according to an embodiment of the present invention.
- the point cloud data decoding system 600 includes a storage device 610 and a processor 620.
- the storage device 610 stores a program for implementing the corresponding steps in the point cloud data decoding method according to the embodiment of the present invention.
- the processor 620 is configured to run a program stored in the storage device 610 to execute corresponding steps of the point cloud data decoding method according to the embodiment of the present invention.
- the point cloud data decoding system 600 when the program is run by the processor 620, the point cloud data decoding system 600 is caused to perform the following steps: perform arithmetic decoding on the bitstream of the point cloud data to obtain the arithmetic decoding result; and perform the arithmetic decoding result on the arithmetic decoding result Performing hybrid decoding of position coordinates and attributes to obtain respective position coordinates and attribute values of the point cloud data; wherein, the hybrid decoding includes: performing position coordinate decoding based on multi-tree division to obtain multiple leaf nodes, one of which is The attribute data of the leaf node is located between the position data of the one leaf node and the position data of another leaf node in the code stream; the position decoding and attribute decoding are performed on the point cloud data contained in the leaf node.
- the point cloud data decoding system 600 when the program is run by the processor 620, the point cloud data decoding system 600 is also caused to perform the following steps: based on the code stream, it is determined whether the point cloud data is correctly encoded during the encoding process. The position coordinates of the point cloud data are quantized, and if quantized, the position coordinates obtained by the hybrid decoding are inversely quantized.
- the point cloud data decoding system 600 when the program is run by the processor 620, the point cloud data decoding system 600 is also caused to perform the following steps: in the process of determining the encoding of the point cloud data, After the position coordinates are quantified, it is determined whether the attribute values of the quantized point cloud data with the same position coordinates are merged in the encoding process of the point cloud data; if it is determined that the merge is performed, the point of any leaf node is determined
- the position decoding and attribute decoding of cloud data includes: decoding the unique attribute value of the point cloud data in any leaf node; if it is determined that no merging is performed, then performing position decoding and attribute decoding on the point cloud data of any leaf node
- the decoding includes: respectively decoding the number and attribute value of the point cloud data in any of the leaf nodes.
- the point cloud data decoding system 600 when the program is run by the processor 620, the point cloud data decoding system 600 is also caused to perform the following steps: based on the code stream, it is determined whether the point cloud data is correctly encoded during the encoding process.
- the attribute values of the point cloud data in any leaf node that includes more than one point cloud data are merged; if it is determined that the merge is performed, the position decoding and attribute decoding on the point cloud data of any leaf node includes: Decoding the merged attribute value of the point cloud data in any one of the leaf nodes; if it is determined that the merge has not been performed, then performing position decoding and attribute decoding on the point cloud data of any one of the leaf nodes includes: The number and attribute value of the point cloud data in the node are decoded separately.
- the point cloud data decoding system 600 when the program is run by the processor 620, the point cloud data decoding system 600 is also caused to perform the following steps: determine whether to correct in the encoding process based on the attribute merging flag bit in the code stream The attribute values of the point cloud data are merged, and the position decoding and attribute decoding are performed on the leaf node based on the result of the determination.
- the decoding system 600 for point cloud data is executed to decode the attribute value of the point cloud data, including: The attribute value is decoded into binarization.
- the point cloud data decoding system 600 executes the binarization decoding of the attribute value of the point cloud data, including: The attribute values of the point cloud data are subjected to fixed-length decoding, truncated Rice decoding, or exponential Columbus decoding.
- a storage medium on which program instructions are stored, and the program instructions are used to execute the point cloud data in the embodiments of the present invention when the program instructions are run by a computer or a processor.
- the storage medium may include, for example, a memory card of a smart phone, a storage component of a tablet computer, a hard disk of a personal computer, a read-only memory (ROM), an erasable programmable read-only memory (EPROM), a portable compact disk read-only memory (CD-ROM), USB memory, or any combination of the above storage media.
- the computer-readable storage medium may be any combination of one or more computer-readable storage media.
- the computer program instructions can execute the point cloud data decoding method according to the embodiment of the present invention when being executed by a computer.
- the computer program instructions when run by the computer or processor, cause the computer or processor to perform the following steps: perform arithmetic decoding on the code stream of the point cloud data to obtain the arithmetic decoding result; and perform the arithmetic decoding result on the arithmetic decoding result Performing hybrid decoding of position coordinates and attributes to obtain respective position coordinates and attribute values of the point cloud data; wherein, the hybrid decoding includes: performing position coordinate decoding based on multi-tree division to obtain multiple leaf nodes, one of which is The attribute data of the leaf node is located between the position data of the one leaf node and the position data of another leaf node in the code stream; the position decoding and attribute decoding are performed on the point cloud data contained in the leaf node.
- the computer or the processor when the computer program instructions are executed by the computer or the processor, the computer or the processor also executes the following steps: based on the code stream, it is determined whether the point cloud data is correct or not during the encoding process of the point cloud data.
- the position coordinates of the point cloud data are quantized, and if quantized, the position coordinates obtained by the hybrid decoding are inversely quantized.
- the computer or the processor when the computer program instructions are executed by the computer or the processor, the computer or the processor also executes the following steps: in the process of determining the encoding of the point cloud data, After the position coordinates are quantified, it is determined whether the attribute values of the quantized point cloud data with the same position coordinates are merged in the encoding process of the point cloud data; if it is determined that the merge is performed, the point of any leaf node is determined.
- the position decoding and attribute decoding of cloud data includes: decoding the unique attribute value of the point cloud data in any leaf node; if it is determined that no merging is performed, then performing position decoding and attribute decoding on the point cloud data of any leaf node
- the decoding includes: respectively decoding the number and attribute value of the point cloud data in any of the leaf nodes.
- the computer or the processor when the computer program instructions are executed by the computer or the processor, the computer or the processor also executes the following steps: based on the code stream, it is determined whether the point cloud data is correct or not during the encoding process of the point cloud data.
- the attribute values of the point cloud data in any leaf node that includes more than one point cloud data are merged; if it is determined that the merge is performed, the position decoding and attribute decoding on the point cloud data of any leaf node includes: Decoding the merged attribute value of the point cloud data in any one of the leaf nodes; if it is determined that the merge has not been performed, then performing position decoding and attribute decoding on the point cloud data of any one of the leaf nodes includes: The number and attribute value of the point cloud data in the node are decoded separately.
- the computer or the processor when the computer program instructions are run by the computer or the processor, the computer or the processor also executes the following steps: based on the attribute merging flag bit in the code stream, it is determined whether to correct during the encoding process. The attribute values of the point cloud data are merged, and the position decoding and attribute decoding are performed on the leaf node based on the result of the determination.
- the computer program instructions when executed by the computer or processor to decode the attribute values of the point cloud data, the computer program instructions include: The attribute value is decoded into binarization.
- the method when the computer program instructions cause the computer or the processor to execute the binary decoding of the attribute value of the point cloud data when being executed by the computer or the processor, the method includes: The attribute values of the point cloud data are subjected to fixed-length decoding, truncated Rice decoding, or exponential Columbus decoding.
- the point cloud data coding and decoding method, system and storage medium combine the characteristics of position coordinate coding and the characteristics of attribute coding, and adopt a coding scheme that combines position coordinate coding and attribute coding, so that When it is necessary to use part of the point cloud data, it is not necessary to decode the position coordinates of all the point cloud data and then decode the attribute value, thereby improving the decoding efficiency.
- the disclosed device and method may be implemented in other ways.
- the device embodiments described above are only illustrative.
- the division of the units is only a logical function division, and there may be other divisions in actual implementation, for example, multiple units or components can be combined or It can be integrated into another device, or some features can be ignored or not implemented.
- the various component embodiments of the present invention may be implemented by hardware, or by software modules running on one or more processors, or by a combination of them.
- a microprocessor or a digital signal processor (DSP) may be used in practice to implement some or all of the functions of some modules according to the embodiments of the present invention.
- DSP digital signal processor
- the present invention can also be implemented as a device program (for example, a computer program and a computer program product) for executing part or all of the methods described herein.
- Such a program for realizing the present invention may be stored on a computer-readable medium, or may have the form of one or more signals.
- Such a signal can be downloaded from an Internet website, or provided on a carrier signal, or provided in any other form.
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Compression, Expansion, Code Conversion, And Decoders (AREA)
- Compression Or Coding Systems Of Tv Signals (AREA)
Abstract
Description
说明书Manual
本发明总地涉及点云编码技术领域,更具体地涉及一种点云数据的编解码方法、系统和存储介质。The present invention generally relates to the technical field of point cloud coding, and more specifically relates to a coding and decoding method, system and storage medium for point cloud data.
点云是三维物体或场景的一种表现形式,是由空间中一组无规则分布、表达三维物体或场景空间结构和表面属性的离散点集所构成。为了准确反映空间中的信息,所需离散点的数目是巨大的。为了减少点云数据存储和传输时所占用的带宽,需要对点云数据进行编码压缩处理。A point cloud is a form of expression of a three-dimensional object or scene. It is composed of a set of discrete points that are randomly distributed in space and express the spatial structure and surface properties of the three-dimensional object or scene. In order to accurately reflect the information in the space, the number of discrete points required is huge. In order to reduce the bandwidth occupied by point cloud data storage and transmission, the point cloud data needs to be encoded and compressed.
在点云数据编解码过程中,包括对点云数据点的位置坐标的编解码和属性值的编解码,且对位置坐标的编解码和对属性值的编解码是分开进行的。具体地,现有的点云数据编码方法是:先编码位置坐标,在对位置坐标编码结束后再进行属性值的编码;现有的点云数据解码方法是:先解码位置坐标的码流,在解码了全部的位置坐标码流之后再解码属性值的码流。In the point cloud data encoding and decoding process, the encoding and decoding of the position coordinates of the point cloud data points and the encoding and decoding of the attribute values are included, and the encoding and decoding of the position coordinates and the encoding and decoding of the attribute values are performed separately. Specifically, the existing point cloud data encoding method is: first encoding the position coordinates, and then encoding the attribute values after the encoding of the position coordinates is finished; the existing point cloud data decoding method is: first decoding the code stream of the position coordinates, After decoding all the position coordinate code streams, decode the attribute value code streams.
然而,这样的编解码方法存在问题:当点云数据点的数据量较大时,这种编码解码方案下在解码过程中存在一定的时延,解码器需要在解码出全部位置坐标之后才可以解码属性值。当需要使用部分的点云数据点时,也需要在解码全部位置坐标之后再逐个解码每个位置坐标对应的属性值,然后才能可以获得完整可用的点云数据点。这样显然增加了许多不必要的计算量,使得效率低下。However, this encoding and decoding method has a problem: when the amount of data of the point cloud data point is large, there is a certain delay in the decoding process under this encoding and decoding scheme, and the decoder needs to decode all the position coordinates before it can be used. Decode the attribute value. When part of the point cloud data points need to be used, it is also necessary to decode the attribute values corresponding to each position coordinate one by one after decoding all the position coordinates, and then a complete and usable point cloud data point can be obtained. This obviously increases a lot of unnecessary calculations and makes efficiency low.
发明内容Summary of the invention
为了解决上述问题而提出了本发明。本发明提供一种点云数据的编解码方案,其结合位置坐标编码的特点以及属性编码的特点,采用位置坐标编码与属性编码相混合的编码方案,使得在需要使用部分点云数据时,无需解码全部点云数据的位置坐标后再进行属性值解码,从而提高解码效率。 下面简要描述本发明提出的点云数据的编解码方案,更多细节将在后续结合附图在具体实施方式中加以描述。In order to solve the above-mentioned problems, the present invention has been proposed. The present invention provides a point cloud data coding and decoding scheme, which combines the characteristics of position coordinate coding and attribute coding, and adopts a coding scheme that combines position coordinate coding and attribute coding, so that when part of the point cloud data needs to be used, there is no need to After decoding the position coordinates of all the point cloud data, the attribute value decoding is performed, thereby improving the decoding efficiency. The following briefly describes the point cloud data encoding and decoding scheme proposed by the present invention, and more details will be described later in the specific implementation with reference to the accompanying drawings.
根据本发明一方面,提供了一种点云数据的编码方法,所述编码方法包括:对输入的点云数据进行位置坐标与属性的混合编码;以及对所述混合编码的结果进行算术编码得到所述点云数据的码流;其中,所述混合编码包括:对所述点云数据所在的空间进行多叉树划分得到多个叶子节点,并对叶子节点中的点云数据进行位置编码和属性编码;其中,一个叶子节点的属性数据在所述码流中位于所述一个叶子节点的位置数据与另一个叶子节点的位置数据之间。According to one aspect of the present invention, there is provided a point cloud data encoding method, the encoding method comprising: performing a hybrid encoding of position coordinates and attributes on the input point cloud data; and performing arithmetic encoding on the result of the hybrid encoding to obtain The code stream of the point cloud data; wherein, the hybrid encoding includes: performing multi-tree division on the space where the point cloud data is located to obtain multiple leaf nodes, and performing position encoding on the point cloud data in the leaf nodes, and Attribute coding; wherein the attribute data of a leaf node is located between the position data of the one leaf node and the position data of another leaf node in the code stream.
在本发明的一个实施例中,所述编码方法还包括:在对所述输入的点云数据进行位置坐标与属性的混合编码之前,对所述输入的点云数据的位置坐标进行量化,并基于经量化的位置坐标进行所述混合编码。In an embodiment of the present invention, the encoding method further includes: quantizing the position coordinates of the input point cloud data before performing hybrid encoding of the position coordinates and attributes of the input point cloud data, and The hybrid coding is performed based on the quantized position coordinates.
在本发明的一个实施例中,所述编码方法还包括:在对所述输入的点云数据的位置坐标进行量化之后,对经量化得到相同位置坐标的点云数据的属性值进行合并;并且对任一叶子节点的点云数据进行位置编码和属性编码包括:对所述任一叶子节点中的点云数据的唯一属性值进行编码。In an embodiment of the present invention, the encoding method further includes: after quantizing the position coordinates of the input point cloud data, merging the attribute values of the point cloud data obtained by quantizing the same position coordinates; and Performing position coding and attribute coding on the point cloud data of any leaf node includes: coding the unique attribute value of the point cloud data in any leaf node.
在本发明的一个实施例中,所述编码方法还包括:在对所述输入的点云数据的位置坐标进行量化之后,对经量化得到相同位置坐标的点云数据的属性值不进行合并;并且对任一叶子节点的点云数据进行位置编码和属性编码包括:对所述任一叶子节点中的点云数据的个数和属性值分别进行编码。In an embodiment of the present invention, the encoding method further includes: after quantizing the position coordinates of the input point cloud data, not merging the attribute values of the point cloud data obtained by quantizing the same position coordinates; In addition, performing position coding and attribute coding on the point cloud data of any leaf node includes: respectively coding the number and attribute values of the point cloud data in any leaf node.
在本发明的一个实施例中,所述编码方法还包括:当任一叶子节点中包括不止一个点云数据时,将所述任一叶子节点中的点云数据的属性值进行合并;并且对所述任一叶子节点的点云数据进行位置编码和属性编码包括:对所述任一叶子节点中的点云数据的合并属性值进行编码。In an embodiment of the present invention, the encoding method further includes: when any leaf node includes more than one point cloud data, combining the attribute values of the point cloud data in any leaf node; and The position encoding and attribute encoding of the point cloud data of any leaf node includes: encoding the merged attribute value of the point cloud data in the any leaf node.
在本发明的一个实施例中,所述编码方法还包括:当任一叶子节点中包括不止一个点云数据时,不将所述任一叶子节点中的点云数据的属性值进行合并;并且对所述任一叶子节点的点云数据进行位置编码和属性编码包括:对所述任一叶子节点中的点云数据的个数和属性值分别进行编码。In an embodiment of the present invention, the encoding method further includes: when any leaf node includes more than one point cloud data, not merging the attribute values of the point cloud data in any leaf node; and Performing position coding and attribute coding on the point cloud data of any leaf node includes: respectively coding the number and attribute values of the point cloud data in any leaf node.
在本发明的一个实施例中,所述码流中包括属性合并标志位,所述属 性合并标志位的取值表示在编码过程中是否对点云数据的属性值进行了合并。In an embodiment of the present invention, the code stream includes an attribute merging flag bit, and the value of the attribute merging flag bit indicates whether the attribute values of the point cloud data are merged during the encoding process.
在本发明的一个实施例中,对所述点云数据的属性值进行编码,包括:对所述点云数据的属性值进行二值化编码。In an embodiment of the present invention, encoding the attribute value of the point cloud data includes: performing binary encoding on the attribute value of the point cloud data.
在本发明的一个实施例中,所述对所述点云数据的属性值进行二值化编码,包括:对所述点云数据的属性值进行定长编码、截断莱斯编码或者指数哥伦布编码。In an embodiment of the present invention, the performing binarization coding on the attribute value of the point cloud data includes: performing fixed-length coding, truncated Rice coding, or exponential Golomb coding on the attribute value of the point cloud data .
根据本发明另一方面,提供了一种点云数据的解码方法,所述解码方法包括:对点云数据的码流进行算术解码得到算术解码结果;以及对所述算术解码结果进行位置坐标与属性的混合解码,以得到所述点云数据各自的位置坐标和属性值;其中,所述混合解码包括:基于多叉树划分进行位置坐标解码得到多个叶子节点,其中,一个叶子节点的属性数据在所述码流中位于所述一个叶子节点的位置数据与另一个叶子节点的位置数据之间;对所述叶子节点中所含的点云数据进行位置解码和属性解码。According to another aspect of the present invention, there is provided a method for decoding point cloud data. The decoding method includes: performing arithmetic decoding on a bitstream of the point cloud data to obtain an arithmetic decoding result; and performing position coordinates on the arithmetic decoding result and Hybrid decoding of attributes to obtain the respective position coordinates and attribute values of the point cloud data; wherein, the hybrid decoding includes: decoding the position coordinates based on multi-tree division to obtain multiple leaf nodes, wherein the attribute of one leaf node The data is located between the position data of the one leaf node and the position data of another leaf node in the code stream; position decoding and attribute decoding are performed on the point cloud data contained in the leaf node.
在本发明的一个实施例中,所述解码方法还包括:基于所述码流确定在所述点云数据的编码过程中是否对所述点云数据的位置坐标进行了量化,如果是进行了量化,则对所述混合解码得到的位置坐标进行逆量化。In an embodiment of the present invention, the decoding method further includes: determining, based on the code stream, whether the position coordinates of the point cloud data are quantized during the encoding process of the point cloud data, if so For quantization, inverse quantization is performed on the position coordinates obtained by the hybrid decoding.
在本发明的一个实施例中,所述解码方法还包括:在确定所述点云数据的编码过程中对所述点云数据的位置坐标进行了量化之后,确定所述点云数据的编码过程中是否对经量化得到相同位置坐标的点云数据的属性值进行了合并;如果确定进行了合并,则对任一叶子节点的点云数据进行位置解码和属性解码包括:对所述任一叶子节点中的点云数据的唯一属性值进行解码;如果确定未进行合并,则对任一叶子节点的点云数据进行位置解码和属性解码包括:对所述任一叶子节点中的点云数据的个数和属性值分别进行解码。In an embodiment of the present invention, the decoding method further includes: after quantizing the position coordinates of the point cloud data in the encoding process of the point cloud data, determining the encoding process of the point cloud data Whether the attribute values of the point cloud data with the same position coordinates obtained by quantization have been merged; if it is determined that the merge has been carried out, the position decoding and attribute decoding on the point cloud data of any leaf node includes: Decoding the unique attribute value of the point cloud data in the node; if it is determined that the merging is not performed, the position decoding and attribute decoding on the point cloud data of any leaf node includes: The number and attribute value are decoded separately.
在本发明的一个实施例中,所述解码方法还包括:基于所述码流确定在所述点云数据的编码过程中是否对包括不止一个点云数据的任一叶子节点中的点云数据的属性值进行了合并;如果确定进行了合并,则对所述任一叶子节点的点云数据进行位置解码和属性解码包括:对所述任一叶子节点中的点云数据的合并属性值进行解码;如果确定未进行合并,则对所述 任一叶子节点的点云数据进行位置解码和属性解码包括:对所述任一叶子节点中的点云数据的个数和属性值分别进行解码。In an embodiment of the present invention, the decoding method further includes: determining, based on the code stream, whether to correct the point cloud data in any leaf node that includes more than one point cloud data during the encoding process of the point cloud data. If it is determined to be merged, the position decoding and attribute decoding of the point cloud data of any leaf node includes: performing the merged attribute value of the point cloud data in any leaf node Decoding; if it is determined that no merging is performed, performing position decoding and attribute decoding on the point cloud data of any leaf node includes: decoding the number and attribute values of the point cloud data in any leaf node respectively.
在本发明的一个实施例中,所述解码方法还包括:基于所述码流中的属性合并标志位确定在编码过程中是否对点云数据的属性值进行了合并,并基于所述确定的结果对所述叶子节点进行位置解码和属性解码。In an embodiment of the present invention, the decoding method further includes: determining whether the attribute values of the point cloud data are merged during the encoding process based on the attribute merging flag in the code stream, and based on the determined As a result, position decoding and attribute decoding are performed on the leaf node.
在本发明的一个实施例中,对所述点云数据的属性值进行解码,包括:对所述点云数据的属性值进行二值化解码。In an embodiment of the present invention, decoding the attribute value of the point cloud data includes: performing binarization decoding on the attribute value of the point cloud data.
在本发明的一个实施例中,所述对所述点云数据的属性值进行二值化解码,包括:对所述点云数据的属性值进行定长解码、截断莱斯解码或者指数哥伦布解码。In an embodiment of the present invention, the performing binarization decoding on the attribute value of the point cloud data includes: performing fixed-length decoding, truncated Rice decoding, or exponential Columbus decoding on the attribute value of the point cloud data .
根据本发明又一方面,提供了一种点云数据的编码系统,所述编码系统包括存储装置和处理器,所述存储装置上存储有由所述处理器运行的计算机程序,所述计算机程序在被所述处理器运行时执行上述任一项所述的点云数据的编码方法。According to another aspect of the present invention, a point cloud data encoding system is provided, the encoding system includes a storage device and a processor, and the storage device stores a computer program run by the processor, and the computer program The point cloud data encoding method described in any one of the above is executed when being run by the processor.
根据本发明又一方面,提供了一种点云数据的解码系统,所述编码系统包括存储装置和处理器,所述存储装置上存储有由所述处理器运行的计算机程序,所述计算机程序在被所述处理器运行时执行上述任一项所述的点云数据的解码方法。According to another aspect of the present invention, a point cloud data decoding system is provided. The encoding system includes a storage device and a processor. The storage device stores a computer program run by the processor, and the computer program The point cloud data decoding method described in any one of the above is executed when being run by the processor.
根据本发明再一方面,提供了一种存储介质,所述存储介质上存储有计算机程序,所述计算机程序在运行时执行上述任一项所述的点云数据的编码方法。According to another aspect of the present invention, a storage medium is provided, and a computer program is stored on the storage medium, and the computer program executes the point cloud data encoding method described in any one of the above items when the computer program is running.
根据本发明再一方面,提供了一种存储介质,所述存储介质上存储有计算机程序,所述计算机程序在运行时执行上述任一项所述的点云数据的解码方法。According to another aspect of the present invention, there is provided a storage medium having a computer program stored on the storage medium, and the computer program executes the point cloud data decoding method described in any one of the above items when the computer program is running.
根据本发明实施例的点云数据的编解码方法、系统和存储介质结合位置坐标编码的特点以及属性编码的特点,采用位置坐标编码与属性编码相混合的编码方案,使得在需要使用部分点云数据时,无需解码全部点云数据的位置坐标后再进行属性值解码,从而提高解码效率。According to the point cloud data coding and decoding method, system and storage medium of the embodiment of the present invention, combining the characteristics of position coordinate coding and the characteristics of attribute coding, a coding scheme that combines position coordinate coding and attribute coding is adopted, so that part of the point cloud is used when needed. When data, it is not necessary to decode the position coordinates of all the point cloud data and then decode the attribute value, thereby improving the decoding efficiency.
图1示出根据本发明实施例的点云数据的编码方法的示意性流程图;Fig. 1 shows a schematic flowchart of a point cloud data encoding method according to an embodiment of the present invention;
图2示出根据本发明实施例的八叉树划分示意图;Fig. 2 shows a schematic diagram of octree division according to an embodiment of the present invention;
图3示出根据本发明实施例的八叉树递归划分示意图;Fig. 3 shows a schematic diagram of recursive division of an octree according to an embodiment of the present invention;
图4示出根据本发明实施例的点云数据的编码系统的示意性框图;Fig. 4 shows a schematic block diagram of a point cloud data encoding system according to an embodiment of the present invention;
图5示出根据本发明实施例的点云数据的解码方法的示意性流程图;Fig. 5 shows a schematic flowchart of a point cloud data decoding method according to an embodiment of the present invention;
图6示出根据本发明实施例的点云数据的解码系统的示意性框图。Fig. 6 shows a schematic block diagram of a point cloud data decoding system according to an embodiment of the present invention.
为了使得本发明的目的、技术方案和优点更为明显,下面将参照附图详细描述根据本发明的示例实施例。显然,所描述的实施例仅仅是本发明的一部分实施例,而不是本发明的全部实施例,应理解,本发明不受这里描述的示例实施例的限制。基于本发明中描述的本发明实施例,本领域技术人员在没有付出创造性劳动的情况下所得到的所有其它实施例都应落入本发明的保护范围之内。In order to make the objectives, technical solutions, and advantages of the present invention more obvious, the exemplary embodiments according to the present invention will be described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments of the present invention, and it should be understood that the present invention is not limited by the exemplary embodiments described herein. Based on the embodiments of the present invention described in the present invention, all other embodiments obtained by those skilled in the art without creative work should fall within the protection scope of the present invention.
在下文的描述中,给出了大量具体的细节以便提供对本发明更为彻底的理解。然而,对于本领域技术人员而言显而易见的是,本发明可以无需一个或多个这些细节而得以实施。在其他的例子中,为了避免与本发明发生混淆,对于本领域公知的一些技术特征未进行描述。In the following description, a lot of specific details are given in order to provide a more thorough understanding of the present invention. However, it is obvious to those skilled in the art that the present invention can be implemented without one or more of these details. In other examples, in order to avoid confusion with the present invention, some technical features known in the art are not described.
应当理解的是,本发明能够以不同形式实施,而不应当解释为局限于这里提出的实施例。相反地,提供这些实施例将使公开彻底和完全,并且将本发明的范围完全地传递给本领域技术人员。It should be understood that the present invention can be implemented in different forms and should not be construed as being limited to the embodiments presented here. On the contrary, the provision of these embodiments will make the disclosure thorough and complete, and will fully convey the scope of the present invention to those skilled in the art.
在此使用的术语的目的仅在于描述具体实施例并且不作为本发明的限制。在此使用时,单数形式的“一”、“一个”和“所述/该”也意图包括复数形式,除非上下文清楚指出另外的方式。还应明白术语“组成”和/或“包括”,当在该说明书中使用时,确定所述特征、整数、步骤、操作、元件和/或部件的存在,但不排除一个或更多其它的特征、整数、步骤、操作、元件、部件和/或组的存在或添加。在此使用时,术语“和/或”包括相关所列项目的任何及所有组合。The purpose of the terms used here is only to describe specific embodiments and not as a limitation of the present invention. When used herein, the singular forms "a", "an" and "the/the" are also intended to include plural forms, unless the context clearly indicates otherwise. It should also be understood that the terms "composition" and/or "including", when used in this specification, determine the existence of the described features, integers, steps, operations, elements and/or components, but do not exclude one or more other The existence or addition of features, integers, steps, operations, elements, components, and/or groups. As used herein, the term "and/or" includes any and all combinations of related listed items.
为了彻底理解本发明,将在下列的描述中提出详细的步骤以及详细的 结构,以便阐释本发明提出的技术方案。本发明的较佳实施例详细描述如下,然而除了这些详细描述外,本发明还可以具有其他实施方式。In order to thoroughly understand the present invention, detailed steps and detailed structures will be presented in the following description to explain the technical solutions proposed by the present invention. The preferred embodiments of the present invention are described in detail as follows. However, in addition to these detailed descriptions, the present invention may also have other embodiments.
如前所述,目前的点云数据的编码方法在对点云数据的全部位置坐标进行编码后才对点云数据的属性值进行编码,使得解码时需要解码出全部位置坐标才可以解码属性值,当仅需要使用部分点云数据点时,编解码效率低下。基于此,本发明提供一种点云数据的编解码方案,下面结合附图来描述根据本发明实施例的点云数据的编解码方案。As mentioned above, the current point cloud data encoding method encodes the attribute value of the point cloud data only after all the position coordinates of the point cloud data are encoded, so that all the position coordinates need to be decoded before the attribute value can be decoded. , When only part of the point cloud data points need to be used, the coding and decoding efficiency is low. Based on this, the present invention provides an encoding and decoding solution for point cloud data. The encoding and decoding solution for point cloud data according to embodiments of the present invention will be described below with reference to the accompanying drawings.
图1示出根据本发明实施例的点云数据的编码方法100的示意性流程图。如图1所示,点云数据的编码方法100可以包括如下步骤:Fig. 1 shows a schematic flowchart of a point cloud
在步骤S110,对输入的点云数据进行位置坐标与属性的混合编码,所述混合编码包括:对所述点云数据所在的空间进行多叉树划分得到多个叶子节点,并对叶子节点中的点云数据进行位置编码和属性编码。In step S110, perform hybrid encoding of position coordinates and attributes on the input point cloud data. The hybrid encoding includes: multi-tree division of the space where the point cloud data is located to obtain multiple leaf nodes, The point cloud data is position-encoded and attribute-encoded.
在本发明的实施例中,可以采用激光扫描仪、激光雷达等测距装置来针对某物体或某场景采集点云数据。一般地,经采集的点云数据包括三维方向的位置坐标以及该位置的属性信息。例如,每个点云数据的位置坐标可以表示为(x,y,z),每个点云数据的属性信息可以包括诸如颜色(R,G,B)或者反射率等属性的值。In the embodiment of the present invention, a distance measuring device such as a laser scanner and a lidar may be used to collect point cloud data for a certain object or a certain scene. Generally, the collected point cloud data includes position coordinates in a three-dimensional direction and attribute information of the position. For example, the position coordinates of each point cloud data can be expressed as (x, y, z), and the attribute information of each point cloud data can include attribute values such as color (R, G, B) or reflectance.
在本发明的实施例中,将点云数据进行位置坐标与属性的混合编码,即位置坐标编码(也可以简称为位置编码)与属性编码相混合的编码。其中,对位置坐标的编码可以采用多叉树划分编码(例如八叉树划分编码),对属性的编码在位置坐标编码的过程中进行。具体地,对点云数据所在的空间进行多叉树划分得到多个叶子节点(即多叉树划分得到的最后一层的节点),该叶子节点可以是边长小于等于所设定的最小边长的块。并对叶子节点中的点云数据进行位置编码和属性编码,一个叶子节点的属性编码结果位于所述一个叶子节点的位置编码结果与另一个叶子节点的位置编码结果之间。下面以八叉树划分编码为例来详细本发明提出的上述对点云数据进行位置坐标与属性的混合编码。In the embodiment of the present invention, the point cloud data is subjected to mixed coding of position coordinates and attributes, that is, a mixed coding of position coordinate coding (also referred to as position coding for short) and attribute coding. Wherein, the encoding of the position coordinates may adopt multi-tree partition encoding (for example, octree partition encoding), and the encoding of the attributes is performed in the process of encoding the position coordinates. Specifically, multi-tree division is performed on the space where the point cloud data is located to obtain multiple leaf nodes (that is, the nodes of the last layer obtained by multi-tree division), and the leaf nodes may have a side length less than or equal to the set minimum side Long block. Position coding and attribute coding are performed on the point cloud data in the leaf node, and the attribute coding result of one leaf node is located between the position coding result of one leaf node and the position coding result of another leaf node. The following uses octree division coding as an example to detail the above-mentioned mixed coding of position coordinates and attributes on point cloud data proposed by the present invention.
八叉树划分编码是用八叉树划分压缩坐标位置的方法。每层八叉树的划分均利用当前块的中心点的坐标进行子块划分,通过中心点将当前块划 分为八个小的子块。对一个编码块进行一次八叉树划分的示意图如图2所示。八叉树划分可以按照下面的过程来实现:首先,根据点云数据的位置坐标(以下简称为位置坐标)在三个方向中每个方向上的最大值,并求出这三个最大值之中的最大值,根据该选定值来确定用于初始化八叉树划分的初始化块的边长。通常,初始化块的边长可以为2的整数次幂且为大于等于并最接近该选定值。应理解,可以将该选定值写入到码流文件的头信息中供解码端使用。基于对初始化块的边长的确定,可以开始进行八叉树划分编码。每层八叉树的划分均利用当前块的中心点的坐标进行子块划分,通过中心点将当前块划分为八个小的子块。得到子块划分后,会判断每个子块内是否存在点云数据,对存在点云数据的子块会再进一步进行划分,直至子块划分至最小时,例如子块边长达到预设最小边长(通常将预设最小边长为设置为1)即得到叶子节点时停止划分。The octree partition coding is a method of using octree partitioning and compressing the coordinate position. The division of each layer of the octree uses the coordinates of the center point of the current block to divide the current block into eight small sub-blocks through the center point. A schematic diagram of performing an octree division on a coding block is shown in Figure 2. The octree division can be implemented according to the following process: First, according to the maximum value of the position coordinates of the point cloud data (hereinafter referred to as the position coordinates) in each of the three directions, one of the three maximum values is obtained. The maximum value in the selected value is used to determine the side length of the initialization block used to initialize the octree division. Generally, the side length of the initialization block can be an integer power of 2 and be greater than or equal to and closest to the selected value. It should be understood that the selected value can be written into the header information of the code stream file for use by the decoding end. Based on the determination of the side length of the initialization block, the octree partition coding can be started. The division of each layer of the octree uses the coordinates of the center point of the current block for sub-block division, and the current block is divided into eight small sub-blocks through the center point. After the sub-block is divided, it will judge whether there is point cloud data in each sub-block, and the sub-blocks with point cloud data will be further divided until the sub-block is divided to the minimum, for example, the side length of the sub-block reaches the preset minimum side Long (usually set the preset minimum side length to 1), that is, stop dividing when the leaf node is obtained.
八叉树递归划分的示意图如图3所示。在对点云数据的位置坐标进行压缩编码时,按照八叉树的广度优先遍历顺序,逐层进行编码,逐层逐个编码每个八叉树的划分情况。并且,对每个块进行八叉树划分后得到的八个子块会判断是否含有点云数据点。如果含有点云数据点则会进一步进行划分。以图3为例,图中黑色方块表示当前子块内含有点云数据点,白色方块表示当前子块内不含有点云数据点。在对根节点进行八叉树划分时,依次判断每个小块内是否含有点云数据点,以图3中的第一层为例,第一次划分的八叉树中第三个块含有点云数据点,剩余七个块不含有点云数据点,则这样的划分可以用8bit来表示,具体为0010 0000。接着对含有数据点的块接着进行划分,即图3中的第二层划分,结果此次得到第三个块与第八个块内含有点云数据点,则这次八叉树划分可以用0010 0001来表示。接着依次对这两个有点云数据点的子块进行划分。按照广度优先的顺序进行进一步划分。在第三层首先划分左边的子块,划分结果如图3中第三层左半部分所示,第一个子块和第四个子块内含有点云数据点,则这次八叉树划分可以用1001 0000进行表示。接着对第二层的第二个有点云数据点的子块进行划分,划分结果如图3中第三层右半部分所示,第二个子块和第八个子块内含有点云数据点,则这次八叉树划分可以用0100 0001所表示。后面层的划分与前面描述相似,按照广度优先遍历的顺序逐层进行划 分。图3中的划分结果对应的二进制码流为0010 0000 0010 0001 1001 0000 0100 0001……。当划分到最后一层,即子块的边长达到预设最小边长时,此时已经到达八叉树划分的最深位置,即到达了当前八叉树的叶子节点块,不需要再进一步划分,根据本发明的实施例,此时可以接着编码当前叶子节点块内含有的点云数据点的数目以及这一个或多个点云数据点各自的属性值。The schematic diagram of the recursive division of the octree is shown in Figure 3. When compressing and encoding the position coordinates of the point cloud data, according to the breadth-first traversal order of the octree, the encoding is performed layer by layer, and the division of each octree is encoded layer by layer. In addition, the eight sub-blocks obtained after the octree division of each block will determine whether it contains point cloud data points. If it contains point cloud data points, it will be further divided. Taking Figure 3 as an example, the black squares in the figure indicate that the current sub-block contains point cloud data points, and the white squares indicate that the current sub-block does not contain point cloud data points. When the root node is divided into an octree, it is determined in turn whether there are point cloud data points in each small block. Take the first layer in Figure 3 as an example, the third block in the first divided octree contains For point cloud data points, the remaining seven blocks do not contain point cloud data points, so this division can be represented by 8 bits, specifically 0010 0000. Then divide the block containing the data points, that is, the second level of division in Figure 3. As a result, the third block and the eighth block contain point cloud data points this time, then this octree division can be used 0010 0001. Then divide the two sub-blocks of cloud data points in turn. It is further divided in the order of breadth first. In the third layer, the left sub-block is first divided, and the result of the division is shown in the left half of the third layer in Figure 3. The first and fourth sub-blocks contain point cloud data points, then this octree division It can be represented by 1001 0000. Then divide the second sub-block of the second layer of cloud data points. The result of the division is shown in the right half of the third layer in Figure 3. The second and eighth sub-blocks contain point cloud data points. Then this octree division can be represented by 0100 0001. The division of the latter layers is similar to the previous description, and is divided layer by layer in the order of breadth first traversal. The binary code stream corresponding to the division result in Figure 3 is 0010 0000 0010 0001 1001 0000 0100 0001.... When it is divided to the last layer, that is, the side length of the sub-block reaches the preset minimum side length, the deepest position of the octree division has been reached at this time, that is, the leaf node block of the current octree has been reached, and no further division is required According to the embodiment of the present invention, at this time, the number of point cloud data points contained in the current leaf node block and the respective attribute values of the one or more point cloud data points can be encoded.
在本发明的实施例中,当叶子节点块内含有一个点云数据点时,可以直接编码一个0进行表示,接着会编码这个位置坐标对应的属性值;当叶子节点块内含有不止一个点云数据点时,设当前叶子节点块内含有n个点云数据点,此时会先编码一个1,接着编码数值(n-1),接着会连续编码这n个点云数据点对应的属性值。依次编码每个叶子节点块内含有的点云点的数目以及对应属性值,即得到对点云数据进行的位置坐标与属性的混合编码的结果。In the embodiment of the present invention, when the leaf node block contains a point cloud data point, it can be directly encoded with a 0 to represent it, and then the attribute value corresponding to this position coordinate will be encoded; when the leaf node block contains more than one point cloud For data points, suppose that there are n point cloud data points in the current leaf node block. At this time, a 1 will be coded, then the value (n-1) will be coded, and then the attribute values corresponding to the n point cloud data points will be coded continuously . The number of point cloud points contained in each leaf node block and the corresponding attribute value are sequentially coded to obtain the result of the mixed coding of the position coordinates and attributes of the point cloud data.
在本发明的实施例中,对点云数据的属性值的编码可以为二值化编码。示例性地,对点云数据的属性值的编码可以为定长编码、截断莱斯编码或者指数哥伦布编码。当然,这仅是示例性的,还可以采用任何其他合适的方法来对点云数据的属性值进行编码。下面详细描述上述三种属性编码方法。In the embodiment of the present invention, the encoding of the attribute value of the point cloud data may be binary encoding. Exemplarily, the encoding of the attribute value of the point cloud data may be fixed-length encoding, truncated Rice encoding, or exponential Golomb encoding. Of course, this is only exemplary, and any other suitable method may be used to encode the attribute value of the point cloud data. The following describes the above three attribute encoding methods in detail.
在本发明的一个实施例中,可以对点云数据的属性值采用定长码的方案进行二值化。在一个示例中,可以根据所有点云数据的属性值中的最大取值确定属性值的定长码方案的比特深度。在另一个示例中,也可以由点云数据的采集装置来确定属性值的定长码方案的比特深度,即根据采集得到的属性值的比特深度来确定属性值的定长码方案的比特深度。在对任一叶子节点块的任一点云数据的属性值进行编码时,可以将该点云数据的属性值转化为位宽等于上述确定的比特深度的二进制数,实现该点云数据的属性值的二值化。In an embodiment of the present invention, the attribute value of the point cloud data may be binarized by using a fixed-length code scheme. In an example, the bit depth of the fixed-length code scheme of the attribute value can be determined according to the largest value among the attribute values of all the point cloud data. In another example, the point cloud data acquisition device may also determine the bit depth of the fixed-length code scheme of the attribute value, that is, determine the bit depth of the fixed-length code scheme of the attribute value according to the bit depth of the acquired attribute value . When encoding the attribute value of any point cloud data of any leaf node block, the attribute value of the point cloud data can be converted into a binary number with a bit width equal to the above determined bit depth to realize the attribute value of the point cloud data The binarization.
在本发明的另一个实施例中,可以对点云数据的属性值采用截断莱斯的方案进行二值化。在一个示例中,可以设门限值为cMax,莱斯参数为R,属性值为Ref。截断莱斯码由前缀码和后缀码串联而成。其中,前缀码依据前缀值P而生成,前缀值P的计算方法为P=Ref>>R。通过计算,若前缀 值P小于值(cMax>>R),则前缀码由P个1和一个0组成,长度为P+1;若前缀值P大于等于值(cMax>>R),则前缀码由(cMax>>R)个1组成,长度为(cMax>>R)。后缀码依据后缀值S而生成:当属性值Ref小于cMax时,后缀值S的计算方法为S=Ref-(P<<R),后缀码为S的二元化串,长度为R;当属性值Ref大于等于cMax时,无后缀码。据此即可实现对任一叶子节点块的任一点云数据的属性值的二值化。In another embodiment of the present invention, the attribute value of the point cloud data may be binarized by using a truncated Rice scheme. In an example, the threshold value can be set to cMax, the Rice parameter is R, and the attribute value is Ref. The truncated Rice code is formed by concatenating the prefix code and the suffix code. The prefix code is generated according to the prefix value P, and the calculation method of the prefix value P is P=Ref>>R. Through calculation, if the prefix value P is less than the value (cMax>>R), the prefix code is composed of P 1s and one 0, and the length is P+1; if the prefix value P is greater than or equal to the value (cMax>>R), the prefix The code consists of (cMax>>R) 1s, and the length is (cMax>>R). The suffix code is generated according to the suffix value S: when the attribute value Ref is less than cMax, the calculation method of the suffix value S is S=Ref-(P<<R), the suffix code is a binary string of S, and the length is R; When the attribute value Ref is greater than or equal to cMax, there is no suffix code. According to this, the attribute value of any point cloud data of any leaf node block can be binarized.
在本发明的又一个实施例中,可以对点云数据的属性值采用k阶指数哥伦布码的方案进行二值化。k阶指数哥伦布码由前缀和后缀两部分组成,前缀和后缀都依赖于指数哥伦布码的阶数k。用来表示非负整数属性值Ref的k阶指数哥伦布码可用如下步骤生成:(1)将属性值Ref以二进制形式写出,去掉最低的k个比特位,之后加1;(2)计算留下的比特位数,将此数减1,即是需要增加的前缀零的个数;(3)将步骤(1)中去掉的最低k个比特位补回比特串尾部。下面以属性值Ref=4、一阶指数哥伦布码(即k=1)为例来描述:(1)4的二进制表示为100,去掉最低1个比特位0变为10,加1后变为11;(2)11的比特数为2,因此前缀中0的个数为1;(3)在比特串最低比特位补上步骤(1)中去掉的0,最终码字为0110。对于k阶指数哥伦布码,前缀由m个连续的0和一个1构成,后缀由m+k构成,是Ref-2 k(2 m-1)的二进制表示。据此即可实现对任一叶子节点块的任一点云数据的属性值的二值化。 In another embodiment of the present invention, the attribute value of the point cloud data may be binarized by adopting a k-order exponential Golomb code scheme. The k-order exponential Golomb code consists of a prefix and a suffix. Both the prefix and the suffix depend on the order k of the exponential Golomb code. The k-order exponential Golomb code used to represent the non-negative integer attribute value Ref can be generated by the following steps: (1) Write the attribute value Ref in binary form, remove the lowest k bits, and then add 1; (2) Calculate and leave For the number of bits under, subtract 1 from this number, that is, the number of prefix zeros that need to be added; (3) The lowest k bits removed in step (1) are added to the end of the bit string. The following describes the attribute value Ref = 4, the first-order exponential Golomb code (ie k = 1) as an example: (1) The binary representation of 4 is 100, and after removing the lowest 1 bit, 0 becomes 10, and after adding 1, it becomes 11; (2) The number of bits of 11 is 2, so the number of 0s in the prefix is 1; (3) The lowest bit of the bit string is filled with the 0 removed in step (1), and the final codeword is 0110. For the k-order exponential Golomb code, the prefix is composed of m consecutive 0s and one 1, and the suffix is composed of m+k, which is the binary representation of Ref-2 k (2 m -1). According to this, the attribute value of any point cloud data of any leaf node block can be binarized.
如前所述,对叶子节点中的点云数据进行位置编码和属性编码,一个叶子节点的属性编码结果位于所述一个叶子节点的位置编码结果与另一个叶子节点的位置编码结果之间,即得到对点云数据进行的位置坐标与属性的混合编码的结果。As mentioned above, the point cloud data in the leaf node is encoded with position and attribute, and the attribute encoding result of one leaf node is located between the position encoding result of one leaf node and the position encoding result of another leaf node, namely The result of hybrid coding of the position coordinates and attributes of the point cloud data is obtained.
以上示例性地描述了根据本发明实施例的点云数据的编码方法100的步骤110的过程,下面继续参考图1,描述编码方法100的后续步骤。The above exemplarily describes the process of step 110 of the point cloud
在步骤120,对所述混合编码的结果进行算术编码得到点云数据的码流,其中,一个叶子节点的属性数据在所述码流中位于所述一个叶子节点的位置数据与另一个叶子节点的位置数据之间。In step 120, arithmetic coding is performed on the result of the hybrid coding to obtain a code stream of point cloud data, wherein the attribute data of one leaf node is located in the code stream at the position data of the one leaf node and the other leaf node Between the location data.
在本发明的实施例中,可将步骤S120得到的混合编码结果(二进制码流)送入算术编码引擎中进行算术编码,即可得到点云数据的位置坐标 与属性的码流,实现对点云数据的位置坐标编码和属性编码。In the embodiment of the present invention, the mixed coding result (binary code stream) obtained in step S120 can be sent to the arithmetic coding engine for arithmetic coding, then the position coordinates and attribute code streams of the point cloud data can be obtained, and the point-matching can be realized. The position coordinate coding and attribute coding of cloud data.
在本发明进一步的实施例中,编码方法100还可以包括(未在图1中示出):在对所述输入的点云数据进行位置坐标与属性的混合编码之前,对所述输入的点云数据的位置坐标进行量化,并基于经量化的位置坐标进行所述混合编码。In a further embodiment of the present invention, the
示例性地,可以根据输入的点云数据的位置坐标在三个方向(即x轴方向、y轴方向和z轴方向)中每个方向上的最大值与最小值之间的差值、以及根据输入的量化精度参数,对输入的每个点云数据的位置坐标进行量化,以简化对点云数据的位置坐标的编码操作。示例性地,可以通过量化将输入的点云数据的位置坐标转换为大于等于零的整数坐标。Exemplarily, the difference between the maximum value and the minimum value in each of the three directions (ie, the x-axis direction, the y-axis direction, and the z-axis direction) according to the position coordinates of the input point cloud data, and According to the input quantization precision parameter, the position coordinates of each input point cloud data are quantized to simplify the coding operation of the position coordinates of the point cloud data. Exemplarily, the position coordinates of the input point cloud data can be converted into integer coordinates greater than or equal to zero by quantization.
进一步地,在将所有点云数据的位置坐标进行量化后,可能会出现重复的坐标值,此时,同一个位置坐标对应于多个点云数据,即同一个位置坐标可能对应于多个属性值。基于此,在一个示例中,在对所述输入的点云数据的位置坐标进行量化之后,可以对经量化得到相同位置坐标的点云数据的属性值进行合并。其中,属性值的合并例如可以为将多个属性值进行加权求和、求平均值或其他合适的操作等,总之是将多个属性值变为一个属性值。在该示例中,由于将量化后相同位置坐标的点云数据的属性值进行了合并,因此在多叉树划分后得到的每个叶子节点中,均可视为仅包括一个点云数据点,属性值也为一个。因为虽然叶子节点中有可能包括多个点云数据点,但其位置坐标相同所以位置上视为一个点(位置编码是基于包括一个点云数据点进行位置编码,即如前所述的,叶子节点包括一个点云数据点时编码0),且其属性值进行了合并,因此属性编码是对该唯一属性值进行编码即可。进一步地,经过上面的分析,在该示例中叶子节点总是包括一个点云数据点和一个属性值,因此编码时也可以不对点云数据点的个数进行编码(因为每个叶子节点中的点云数据的个数都是1),而仅对每个叶子节点中的点云数据点的唯一属性值进行编码即可,这样可进一步减少码流位数,节省编码开销。此外,为了使解码端明了解码叶子节点时仅需解码属性值而无需解码点云数据点的个数,可以在编码码流中设置属性合并标志位,并通过该标志位标识编码过程中对点云数据的属性值进行了合并。当然,也可以默认编码过程对点云数据的属性值进行了合并而 无需设置该属性合并标志位。Further, after quantifying the position coordinates of all point cloud data, duplicate coordinate values may appear. At this time, the same position coordinate corresponds to multiple point cloud data, that is, the same position coordinate may correspond to multiple attributes value. Based on this, in an example, after the position coordinates of the input point cloud data are quantified, the attribute values of the point cloud data obtained by quantizing the same position coordinates may be merged. Among them, the combination of attribute values may be, for example, performing a weighted summation, averaging, or other suitable operations on multiple attribute values. In short, multiple attribute values are converted into one attribute value. In this example, since the attribute values of the point cloud data at the same position coordinates after quantization are merged, each leaf node obtained after the multi-tree division can be regarded as including only one point cloud data point. The attribute value is also one. Because although the leaf node may include multiple point cloud data points, its position coordinates are the same, so the position is regarded as one point (position encoding is based on including a point cloud data point for position encoding, that is, as mentioned above, the leaf The node includes a point cloud data point code 0), and its attribute values are merged, so the attribute code is to encode the unique attribute value. Further, after the above analysis, in this example, the leaf node always includes a point cloud data point and an attribute value, so the number of point cloud data points may not be encoded when encoding (because the number of point cloud data points in each leaf node The number of point cloud data is 1), and only the unique attribute value of the point cloud data point in each leaf node can be encoded, which can further reduce the number of bit stream bits and save encoding overhead. In addition, in order to make the decoder know that when decoding leaf nodes, only the attribute values need to be decoded without the need to decode the number of point cloud data points, the attribute merging flag can be set in the code stream, and this flag can be used to identify the point in the encoding process. The attribute values of cloud data have been merged. Of course, the attribute values of the point cloud data can also be merged by default in the encoding process without setting the attribute merge flag bit.
在另一个示例中,在对所述输入的点云数据的位置坐标进行量化之后,可以对经量化得到相同位置坐标的点云数据的属性值不进行合并。在该示例中,由于量化后相同位置坐标的点云数据的属性值未进行合并,因此在多叉树划分后得到的叶子节点中,可能包括叶子节点中存在多个点云数据点的情况,且每个点云数据点均具有其各自的属性值。在该情况下,对叶子节点中的点云数据的编码可以包括对该叶子节点中点云数据的个数进行编码以及对各点云数据的属性值分别进行编码。类似地,为了使解码端明了解码叶子节点时点云数据点的个数和属性值均需解码,可以在编码码流中设置属性合并标志位,并通过该标志位标识编码过程中对点云数据的属性值未进行合并。当然,也可以默认编码过程不对点云数据的属性值进行合并而无需设置该属性合并标志位。In another example, after the position coordinates of the input point cloud data are quantified, the attribute values of the point cloud data obtained by quantizing the same position coordinates may not be merged. In this example, since the attribute values of the point cloud data at the same position coordinates are not merged after quantization, the leaf nodes obtained after the multi-tree division may include the situation where there are multiple point cloud data points in the leaf nodes. And each point cloud data point has its own attribute value. In this case, the encoding of the point cloud data in the leaf node may include encoding the number of point cloud data in the leaf node and separately encoding the attribute value of each point cloud data. Similarly, in order to make the decoding end understand that the number of point cloud data points and attribute values need to be decoded when decoding leaf nodes, the attribute merging flag can be set in the code stream, and the flag can be used to identify the point cloud during the encoding process. The attribute values of the data are not merged. Of course, it is also possible to default the encoding process not to merge the attribute values of the point cloud data without setting the attribute merging flag bit.
在本发明进一步的实施例中,编码方法100还可以包括(未在图1中示出):当任一叶子节点中包括不止一个点云数据时,将所述任一叶子节点中的点云数据的属性值进行合并;并且对所述任一叶子节点的点云数据进行位置编码和属性编码包括:对所述任一叶子节点中的点云数据的合并属性值进行编码。在该实施例中,对任一包括不止一个点云数据的叶子节点中各点云数据的属性值进行合并,这样默认每个叶子节点均包括一个点云数据及一个属性值,因此对叶子节点编码时可以仅对该叶子节点的唯一属性值(例如合并后的属性值,简称合并属性值)进行编码即可,而无需编码叶子节点中点云数据的个数,从而减少码流位数,节省编码开销。此外,为了使解码端明了解码叶子节点时仅需解码属性值而无需解码点云数据点的个数,可以在编码码流中设置属性合并标志位,并通过该标志位标识编码过程中对点云数据的属性值进行了合并。当然,也可以默认编码过程对点云数据的属性值进行了合并而无需设置该属性合并标志位。In a further embodiment of the present invention, the
在本发明的另一个实施例中,编码方法100还可以包括(未在图1中示出):当任一叶子节点中包括不止一个点云数据时,不将所述任一叶子节点中的点云数据的属性值进行合并;并且对所述任一叶子节点的点云数据进行位置编码和属性编码包括:对所述任一叶子节点中的点云数据的个数和属性值分别进行编码。在该实施例中,对任一包括不止一个点云数据的 叶子节点中各点云数据的属性值不进行合并,这样对叶子节点编码时还是需要编码叶子节点中点云数据的个数和点云数据的属性值。类似地,为了使解码端明了解码叶子节点时点云数据点的个数和属性值均需解码,可以在编码码流中设置属性合并标志位,并通过该标志位标识编码过程中对点云数据的属性值未进行合并。当然,也可以默认编码过程不对点云数据的属性值进行合并而无需设置该属性合并标志位。In another embodiment of the present invention, the
以上示例性地描述了根据本发明实施例的点云数据的编码方法。基于上面的描述,根据本发明实施例的点云数据的编码方法结合位置坐标编码的特点以及属性编码的特点,采用位置坐标编码与属性编码相混合的编码方案,使得在需要使用部分点云数据时,无需解码全部点云数据的位置坐标后再进行属性值解码,从而提高解码效率。示例性地,根据本发明实施例的点云数据的编码方法可以在具有存储器和处理器的设备、装置或者系统中实现。The above exemplarily describes the point cloud data encoding method according to the embodiment of the present invention. Based on the above description, the point cloud data coding method according to the embodiment of the present invention combines the characteristics of position coordinate coding and the characteristics of attribute coding, and adopts a coding scheme that combines position coordinate coding and attribute coding, so that part of the point cloud data is used when needed. In this case, it is not necessary to decode the position coordinates of all the point cloud data and then decode the attribute values, thereby improving the decoding efficiency. Exemplarily, the method for encoding point cloud data according to an embodiment of the present invention may be implemented in a device, device, or system having a memory and a processor.
下面结合图4描述根据本发明实施例的点云数据的编码系统。图4示出了根据本发明实施例的点云数据的编码系统400的示意性框图。点云数据的编码系统400包括存储装置410以及处理器420。The following describes a point cloud data encoding system according to an embodiment of the present invention with reference to FIG. 4. Fig. 4 shows a schematic block diagram of a point cloud
其中,存储装置410存储用于实现根据本发明实施例的点云数据的编码方法中的相应步骤的程序。处理器420用于运行存储装置410中存储的程序,以执行根据本发明实施例的点云数据的编码方法的相应步骤。Wherein, the
在一个实施例中,在所述程序被处理器420运行时使得点云数据的编码系统400执行以下步骤:对输入的点云数据进行位置坐标与属性的混合编码;以及对所述混合编码的结果进行算术编码得到所述点云数据的码流;其中,所述混合编码包括:对所述点云数据所在的空间进行多叉树划分得到多个叶子节点,并对叶子节点中的点云数据进行位置编码和属性编码;其中,一个叶子节点的属性数据在所述码流中位于所述一个叶子节点的位置数据与另一个叶子节点的位置数据之间。In one embodiment, when the program is executed by the
在本发明的一个实施例中,在所述程序被处理器420运行时还使得点云数据的编码系统400执行以下步骤:在对所述输入的点云数据进行位置坐标与属性的混合编码之前,对所述输入的点云数据的位置坐标进行量化,并基于经量化的位置坐标进行所述混合编码。In an embodiment of the present invention, when the program is run by the
在本发明的一个实施例中,在所述程序被处理器420运行时还使得点云数据的编码系统400执行以下步骤:在对所述输入的点云数据的位置坐标进行量化之后,对经量化得到相同位置坐标的点云数据的属性值进行合并;并且对任一叶子节点的点云数据进行位置编码和属性编码包括:对所述任一叶子节点中的点云数据的唯一属性值进行编码。In an embodiment of the present invention, when the program is run by the
在本发明的一个实施例中,在所述程序被处理器420运行时还使得点云数据的编码系统400执行以下步骤:在对所述输入的点云数据的位置坐标进行量化之后,对经量化得到相同位置坐标的点云数据的属性值不进行合并;并且对任一叶子节点的点云数据进行位置编码和属性编码包括:对所述任一叶子节点中的点云数据的个数和属性值分别进行编码。In an embodiment of the present invention, when the program is run by the
在本发明的一个实施例中,在所述程序被处理器420运行时还使得点云数据的编码系统400执行以下步骤:当任一叶子节点中包括不止一个点云数据时,将所述任一叶子节点中的点云数据的属性值进行合并;并且对所述任一叶子节点的点云数据进行位置编码和属性编码包括:对所述任一叶子节点中的点云数据的合并属性值进行编码。In an embodiment of the present invention, when the program is run by the
在本发明的一个实施例中,在所述程序被处理器420运行时还使得点云数据的编码系统400执行以下步骤:当任一叶子节点中包括不止一个点云数据时,不将所述任一叶子节点中的点云数据的属性值进行合并;并且对所述任一叶子节点的点云数据进行位置编码和属性编码包括:对所述任一叶子节点中的点云数据的个数和属性值分别进行编码。In an embodiment of the present invention, when the program is run by the
在本发明的一个实施例中,所述码流中包括属性合并标志位,所述属性合并标志位的取值表示在编码过程中是否对点云数据的属性值进行了合并。In an embodiment of the present invention, the code stream includes an attribute merging flag bit, and the value of the attribute merging flag bit indicates whether the attribute values of the point cloud data are merged during the encoding process.
在本发明的一个实施例中,在所述程序被处理器420运行时还使得点云数据的编码系统400执行的对所述点云数据的属性值进行编码,包括:对所述点云数据的属性值进行二值化编码。In an embodiment of the present invention, when the program is executed by the
在本发明的一个实施例中,在所述程序被处理器420运行时还使得点云数据的编码系统400执行的所述对所述点云数据的属性值进行二值化编码,包括:对所述点云数据的属性值进行定长编码、截断莱斯编码或者指数哥伦布编码。In an embodiment of the present invention, when the program is executed by the
此外,根据本发明实施例,还提供了一种存储介质,在所述存储介质上存储了程序指令,在所述程序指令被计算机或处理器运行时用于执行本发明实施例的点云数据的编码方法的相应步骤。所述存储介质例如可以包括智能电话的存储卡、平板电脑的存储部件、个人计算机的硬盘、只读存储器(ROM)、可擦除可编程只读存储器(EPROM)、便携式紧致盘只读存储器(CD-ROM)、USB存储器、或者上述存储介质的任意组合。所述计算机可读存储介质可以是一个或多个计算机可读存储介质的任意组合。In addition, according to an embodiment of the present invention, there is also provided a storage medium on which program instructions are stored, and the program instructions are used to execute the point cloud data in the embodiments of the present invention when the program instructions are run by a computer or a processor. The corresponding steps of the encoding method. The storage medium may include, for example, a memory card of a smart phone, a storage component of a tablet computer, a hard disk of a personal computer, a read-only memory (ROM), an erasable programmable read-only memory (EPROM), a portable compact disk read-only memory (CD-ROM), USB memory, or any combination of the above storage media. The computer-readable storage medium may be any combination of one or more computer-readable storage media.
在一个实施例中,所述计算机程序指令在被计算机运行时可以执行根据本发明实施例的点云数据的编码方法。In an embodiment, the computer program instructions can execute the point cloud data encoding method according to the embodiment of the present invention when being executed by a computer.
在一个实施例中,所述计算机程序指令在被计算机或处理器运行时使计算机或处理器执行以下步骤:对输入的点云数据进行位置坐标与属性的混合编码;以及对所述混合编码的结果进行算术编码得到所述点云数据的码流;其中,所述混合编码包括:对所述点云数据所在的空间进行多叉树划分得到多个叶子节点,并对叶子节点中的点云数据进行位置编码和属性编码,其中,一个叶子节点的属性数据在所述码流中位于所述一个叶子节点的位置数据与另一个叶子节点的位置数据之间。In one embodiment, the computer program instructions, when run by the computer or processor, cause the computer or processor to perform the following steps: perform hybrid encoding of position coordinates and attributes on the input point cloud data; and encode the hybrid encoding The result is arithmetic coding to obtain the code stream of the point cloud data; wherein, the hybrid coding includes: multi-tree division of the space where the point cloud data is located to obtain a plurality of leaf nodes, and the point cloud in the leaf nodes The data is subjected to position coding and attribute coding, wherein the attribute data of one leaf node is located between the position data of the one leaf node and the position data of another leaf node in the code stream.
在本发明的一个实施例中,所述计算机程序指令在被计算机或处理器运行时还使计算机或处理器执行以下步骤:在对所述输入的点云数据进行位置坐标与属性的混合编码之前,对所述输入的点云数据的位置坐标进行量化,并基于经量化的位置坐标进行所述混合编码。In an embodiment of the present invention, when the computer program instructions are executed by the computer or the processor, the computer or the processor executes the following steps: before performing the mixed encoding of the position coordinates and attributes on the input point cloud data Quantifying the position coordinates of the input point cloud data, and performing the hybrid coding based on the quantized position coordinates.
在本发明的一个实施例中,所述计算机程序指令在被计算机或处理器运行时还使计算机或处理器执行以下步骤:在对所述输入的点云数据的位置坐标进行量化之后,对经量化得到相同位置坐标的点云数据的属性值进行合并;并且对任一叶子节点的点云数据进行位置编码和属性编码包括:对所述任一叶子节点中的点云数据的唯一属性值进行编码。In an embodiment of the present invention, when the computer program instructions are executed by the computer or the processor, the computer or the processor further executes the following steps: after quantifying the position coordinates of the input point cloud data, The attribute values of the point cloud data with the same position coordinates are quantified and merged; and the position coding and attribute coding of the point cloud data of any leaf node includes: performing the unique attribute value of the point cloud data in any leaf node coding.
在本发明的一个实施例中,所述计算机程序指令在被计算机或处理器运行时还使计算机或处理器执行以下步骤:在对所述输入的点云数据的位置坐标进行量化之后,对经量化得到相同位置坐标的点云数据的属性值不进行合并;并且对任一叶子节点的点云数据进行位置编码和属性编码包括:对所述任一叶子节点中的点云数据的个数和属性值分别进行编码。In an embodiment of the present invention, when the computer program instructions are executed by the computer or the processor, the computer or the processor further executes the following steps: after quantifying the position coordinates of the input point cloud data, Quantifying the attribute values of the point cloud data with the same position coordinates are not merged; and performing position coding and attribute coding on the point cloud data of any leaf node includes: summing the number of point cloud data in any leaf node The attribute values are coded separately.
在本发明的一个实施例中,所述计算机程序指令在被计算机或处理器运行时还使计算机或处理器执行以下步骤:当任一叶子节点中包括不止一个点云数据时,将所述任一叶子节点中的点云数据的属性值进行合并;并且对所述任一叶子节点的点云数据进行位置编码和属性编码包括:对所述任一叶子节点中的点云数据的合并属性值进行编码。In an embodiment of the present invention, when the computer program instructions are executed by the computer or the processor, the computer or the processor also executes the following steps: when any leaf node includes more than one point cloud data, the Merging the attribute values of the point cloud data in a leaf node; and performing position encoding and attribute coding on the point cloud data of any leaf node includes: merging attribute values of the point cloud data in any leaf node Encode.
在本发明的一个实施例中,所述计算机程序指令在被计算机或处理器运行时还使计算机或处理器执行以下步骤:当任一叶子节点中包括不止一个点云数据时,不将所述任一叶子节点中的点云数据的属性值进行合并;并且对所述任一叶子节点的点云数据进行位置编码和属性编码包括:对所述任一叶子节点中的点云数据的个数和属性值分别进行编码。In an embodiment of the present invention, when the computer program instructions are executed by the computer or the processor, the computer or the processor also executes the following steps: when any leaf node includes more than one point cloud data, the Merging the attribute values of the point cloud data in any leaf node; and performing position encoding and attribute encoding on the point cloud data of any leaf node includes: the number of point cloud data in any leaf node And the attribute value are coded separately.
在本发明的一个实施例中,所述码流中包括属性合并标志位,所述属性合并标志位的取值表示在编码过程中是否对点云数据的属性值进行了合并。In an embodiment of the present invention, the code stream includes an attribute merging flag bit, and the value of the attribute merging flag bit indicates whether the attribute values of the point cloud data are merged during the encoding process.
在本发明的一个实施例中,所述计算机程序指令在被计算机或处理器运行时使计算机或处理器执行的对所述点云数据的属性值进行编码,包括:对所述点云数据的属性值进行二值化编码。In an embodiment of the present invention, when the computer program instructions are executed by the computer or the processor, the computer or the processor executes the encoding of the attribute value of the point cloud data, including: The attribute value is binary coded.
在本发明的一个实施例中,所述计算机程序指令在被计算机或处理器运行时使计算机或处理器执行的所述对所述点云数据的属性值进行二值化编码,包括:对所述点云数据的属性值进行定长编码、截断莱斯编码或者指数哥伦布编码。In an embodiment of the present invention, when the computer program instructions cause the computer or the processor to execute the binary encoding of the attribute value of the point cloud data when being executed by the computer or the processor, the method includes: The attribute value of the point cloud data is coded with fixed length, truncated Rice coding or exponential Golomb coding.
根据本发明的另一方面,还提供了一种点云数据的解码方法。由于根据本发明实施例的点云数据的解码方法是与根据本发明实施例的点云数据的编码方法是相对应的,为了简洁,解码过程中的一些与编码过程相似或相同的过程不再详细赘述。According to another aspect of the present invention, a method for decoding point cloud data is also provided. Since the point cloud data decoding method according to the embodiment of the present invention corresponds to the point cloud data encoding method according to the embodiment of the present invention, for the sake of brevity, some processes in the decoding process that are similar or identical to the encoding process are no longer Go into details.
图5示出根据本发明实施例的点云数据的解码方法500的示意性流程图。如图5所示,点云数据的解码方法500可以包括如下步骤:FIG. 5 shows a schematic flowchart of a
在步骤S510,对点云数据的码流进行算术解码得到算术解码结果。In step S510, arithmetic decoding is performed on the bit stream of the point cloud data to obtain the arithmetic decoding result.
在本发明的实施例中,步骤S510是与根据实施例的点云数据的编码方法100的步骤S120相对应的,在该步骤对点云数据的码流进行算术编码的逆过程,即算术解码,得到算术解码结果。In the embodiment of the present invention, step S510 corresponds to step S120 of the point cloud
在步骤S520,对所述算术解码结果进行位置坐标与属性的混合解码,以得到所述点云数据各自的位置坐标和属性值;其中,所述混合解码包括:基于多叉树划分进行位置坐标解码得到多个叶子节点,其中,一个叶子节点的属性数据在所述码流中位于所述一个叶子节点的位置数据与另一个叶子节点的位置数据之间;对所述叶子节点中所含的点云数据进行位置解码和属性解码。In step S520, perform hybrid decoding of the position coordinates and attributes of the arithmetic decoding result to obtain the respective position coordinates and attribute values of the point cloud data; wherein, the hybrid decoding includes: performing position coordinates based on multitree division A plurality of leaf nodes are obtained by decoding, wherein the attribute data of one leaf node is located between the position data of the one leaf node and the position data of another leaf node in the code stream; Point cloud data performs position decoding and attribute decoding.
在本发明的实施例中,步骤S520是与根据实施例的点云数据的编码方法100的步骤S110相对应的,在该步骤,对步骤S520得到的算术解码结果进行位置坐标与属性的混合解码。首先可以对码流的头信息进行解码,得到点云数据的位置坐标在三个方向中每个方向的最大值中的最大值,然后基于该值确定用于多叉树划分的初始化块的边长。基于对初始化块的边长的确定,可以开始进行多叉树划分解码(例如八叉树划分解码)。下面以八叉树划分解码为例详细本发明提出的上述对算术解码结果进行的位置坐标与属性的混合解码。In the embodiment of the present invention, step S520 corresponds to step S110 of the point cloud
依次解码8bit确定一个块的八叉树划分情况,每一位bit表示一个子块内是否含有点云数据点,如果为1表示含有点云数据点,如果为0表示不含有点云数据点。对含有点云数据点的块继续进行八叉树划分解码。当八叉树划分解码过程进行到块的边长达到预设最小边长(预设最小边长通常设置为1)时,即表明划分已经结束。接下来解码每个叶子节点内含有的点云点的数目。当解码到一个0时,表明当前叶子节点块内含有一个点云数据点,接着解码该点云数据点的位置坐标对应的属性值。当解码到一个1时,表明当前叶子节点块内含有的点云点数目不止一个,接着解码得到数值(n-1),即说明当前叶子节点块内含有n个点云数据点。接着会连续解码n个属性值即为该叶子节点块内的点云点的位置坐标对应的属性值。其中,解码数值型的方案应当是与编码过程中采用的对属性值的编码方案相对应的方案。Decode 8 bits in turn to determine the octree division of a block. Each bit indicates whether a sub-block contains point cloud data points. If it is 1, it means it contains point cloud data points. If it is 0, it means it does not contain point cloud data points. The octree division and decoding are continued on the block containing the point cloud data points. When the octree division and decoding process proceeds until the side length of the block reaches the preset minimum side length (the preset minimum side length is usually set to 1), it indicates that the division has ended. Next, decode the number of point cloud points contained in each leaf node. When decoded to a 0, it indicates that the current leaf node block contains a point cloud data point, and then decode the attribute value corresponding to the position coordinate of the point cloud data point. When decoded to a 1, it indicates that the current leaf node block contains more than one point cloud point, and then decodes to obtain a value (n-1), which means that the current leaf node block contains n point cloud data points. Then, the n attribute values are continuously decoded, which are the attribute values corresponding to the position coordinates of the point cloud points in the leaf node block. Among them, the decoding numerical scheme should be a scheme corresponding to the encoding scheme for the attribute value adopted in the encoding process.
如前所述,在本发明的实施例中,对点云数据的属性值的编码可以为二值化编码。示例性地,对点云数据的属性值的编码可以为定长编码、截断莱斯编码或者指数哥伦布编码。因此,对应地,在本发明的实施例中,对点云数据的属性值的解码可以为二值化解码。示例性地,对点云数据的 属性值的解码可以为定长解码、截断莱斯解码或者指数哥伦布解码。应理解,这仅是示例性的,对点云数据的属性值的解码还可以为其他任何合适的方法,这取决于对属性值采用的编码方法。下面详细描述上述三种属性解码方法。As mentioned above, in the embodiment of the present invention, the encoding of the attribute value of the point cloud data may be binary encoding. Exemplarily, the encoding of the attribute value of the point cloud data may be fixed-length encoding, truncated Rice encoding, or exponential Golomb encoding. Therefore, correspondingly, in the embodiment of the present invention, the decoding of the attribute value of the point cloud data may be binarization decoding. Exemplarily, the decoding of the attribute value of the point cloud data may be fixed-length decoding, truncated Rice decoding, or exponential Golomb decoding. It should be understood that this is only exemplary, and the decoding of the attribute value of the point cloud data may also be any other suitable method, depending on the encoding method adopted for the attribute value. The above three attribute decoding methods are described in detail below.
在本发明的一个实施例中,对点云数据的属性值采用定长码的方案进行二值化。在一个示例中,可以对码流中的头信息进行解码得到定长码二值化方案所采用的比特深度,解码该比特深度所表示的位宽的二进制码流,得到相应的属性值。In an embodiment of the present invention, the attribute value of the point cloud data is binarized using a fixed-length code scheme. In an example, the header information in the code stream can be decoded to obtain the bit depth used by the fixed-length code binarization scheme, and the bit width binary code stream represented by the bit depth can be decoded to obtain the corresponding attribute value.
在本发明的另一个实施例中,对点云数据的属性值采用截断莱斯的方案进行二值化。在一个示例中,可以对码流中的头信息进行解码得到门限值cMax和莱斯参数R,然后对前缀码和后缀码进行解码。首先解码前缀码,逐比特进行解码,若解码到一比特的0,或者解码比特数大于等于(cMax>>R)则停止解码前缀码。若前缀码比特数大于等于(cMax>>R),则属性值为cMax。否则,可设前缀码为P个1和一个0,接着解码R比特,属性值Ref的计算用公式表示可以为:Ref=S+(P=R),据此即可实现对截断莱斯码的解码。In another embodiment of the present invention, the attribute value of the point cloud data is binarized using a truncated Rice scheme. In an example, the header information in the code stream can be decoded to obtain the threshold value cMax and the Rice parameter R, and then the prefix code and the suffix code can be decoded. First decode the prefix code and decode it bit by bit. If it is decoded to a bit of 0, or if the number of decoded bits is greater than or equal to (cMax>>R), stop decoding the prefix code. If the number of prefix code bits is greater than or equal to (cMax>>R), the attribute value is cMax. Otherwise, the prefix code can be set to P 1s and one 0, and then R bits are decoded. The calculation of the attribute value Ref can be expressed by the formula: Ref=S+(P=R), based on which the truncated Rice code can be realized decoding.
在本发明的又一个实施例中,对点云数据的属性值采用k阶指数哥伦布码的方案进行二值化。在一个示例中,解码k阶指数哥伦布码时,首先从比特流的当前位置开始寻找第一个非零比特,并将找到的零比特个数记为m,第一个非零比特之后m+k位二进制比特串的十进制值为value,计算出的解码值Ref用公式表示可以为:Ref=2 m+k-2 k+Value,即可实现对这个位置坐标对应的属性值解码。 In yet another embodiment of the present invention, the attribute value of the point cloud data is binarized using a k-order exponential Golomb code scheme. In an example, when decoding the k-order exponential Golomb code, the first non-zero bit is searched from the current position of the bit stream, and the number of zero bits found is recorded as m. After the first non-zero bit, m+ The decimal value of the k-bit binary bit string is value, and the calculated decoded value Ref can be expressed by a formula: Ref=2 m+k -2 k +Value, and the attribute value corresponding to this position coordinate can be decoded.
依次解码每个叶子节点块内含有的点云点的数目以及对应属性值,即得到对算术解码结果进行位置坐标与属性的混合解码的结果。The number of point cloud points contained in each leaf node block and the corresponding attribute value are sequentially decoded, that is, the result of a mixed decoding of the position coordinates and attributes of the arithmetic decoding result is obtained.
在本发明进一步的实施例中,解码方法500还可以包括(未在图5中示出):基于所述码流确定在所述点云数据的编码过程中是否对所述点云数据的位置坐标进行了量化,如果是进行了量化,则对所述混合解码得到的位置坐标进行逆量化。在该实施例中,通过码流(例如码流中的量化标志位)确定点云数据编码过程中是否进行了量化,如果进行了量化,则还需对步骤S520得到的混合解码结果中的位置解码结果进行逆量化,以得到点 云数据的位置坐标。In a further embodiment of the present invention, the
进一步地,解码方法500还可以包括(未在图5中示出):在确定所述点云数据的编码过程中对所述点云数据的位置坐标进行了量化之后,确定所述点云数据的编码过程中是否对经量化得到相同位置坐标的点云数据的属性值进行了合并;如果确定进行了合并,则对任一叶子节点的点云数据进行位置解码和属性解码包括:对所述任一叶子节点中的点云数据的唯一属性值进行解码;如果确定未进行合并,则对任一叶子节点的点云数据进行位置解码和属性解码包括:对所述任一叶子节点中的点云数据的个数和属性值分别进行解码。Further, the
在该实施例中,已确定编码过程中对点云数据的位置坐标进行了量化,由于在将所有点云数据的位置坐标进行量化后,可能会出现重复的坐标值,此时,同一个位置坐标对应于多个点云数据,即同一个位置坐标可能对应于多个属性值。因此,可进一步确定经量化得到相同位置坐标的点云数据的属性值是否进行了合并(例如通过属性合并标志位来确定,当然也可以是默认进行了合并或未合并而无需该标志位和该确定步骤)。如果确定经量化得到相同位置坐标的点云数据的属性值进行了合并,意味着每个叶子节点中均可视为仅包括一个点云数据点,属性值也为一个,因此解码时可直接对每个叶子节点中点云数据的唯一属性值进行解码,而无需解码点云数据的个数,因为每个叶子节点中的点云数据的个数均为一个,在编码时无需浪费编码位对其进行编码。反之,如果确定经量化得到相同位置坐标的点云数据的属性值未进行合并,则意味着解码叶子节点时需要解码点云数据的个数和各点云数据的属性值。In this embodiment, it has been determined that the position coordinates of the point cloud data are quantized during the encoding process. Since the position coordinates of all the point cloud data are quantized, there may be repeated coordinate values. At this time, the same position Coordinates correspond to multiple point cloud data, that is, the same location coordinate may correspond to multiple attribute values. Therefore, it can be further determined whether the attribute values of the point cloud data with the same position coordinates obtained by quantization are merged (for example, determined by the attribute merge flag bit, of course, it can also be merged or not merged by default without the flag bit and the Confirm the steps). If it is determined that the attribute values of the point cloud data with the same position coordinates obtained after quantization are combined, it means that each leaf node can be regarded as including only one point cloud data point, and the attribute value is also one. Therefore, you can directly The unique attribute value of the point cloud data in each leaf node is decoded, without the need to decode the number of point cloud data, because the number of point cloud data in each leaf node is one, and there is no need to waste encoding bit pairs during encoding. It is encoded. Conversely, if it is determined that the attribute values of the point cloud data with the same position coordinates obtained after quantization are not merged, it means that the number of point cloud data and the attribute value of each point cloud data need to be decoded when decoding the leaf nodes.
在本发明的另一个实施例中,方法500还可以包括(未在图5中示出):基于所述码流确定在所述点云数据的编码过程中是否对包括不止一个点云数据的任一叶子节点中的点云数据的属性值进行了合并;如果确定进行了合并,则对所述任一叶子节点的点云数据进行位置解码和属性解码包括:对所述任一叶子节点中的点云数据的合并属性值进行解码;如果确定未进行合并,则对所述任一叶子节点的点云数据进行位置解码和属性解码包括:对所述任一叶子节点中的点云数据的个数和属性值分别进行解码。In another embodiment of the present invention, the
在该实施例中,可以基于码流确定编码过程中是否对包括不止一个点 云数据的叶子节点中的点云数据的属性值进行了合并(例如通过码流中的属性合并标志位来确定,当然也可以是默认进行了合并或未合并而无需该标志位和该确定步骤),如果确定对包括不止一个点云数据的叶子节点中的点云数据的属性值进行了合并,则表示解码时对这样的叶子节点均只需要解码唯一的属性值即可。反之,如果确定对包括不止一个点云数据的叶子节点中的点云数据的属性值未进行合并,则表示解码时需要对这样的叶子节点解码点云数据的个数和各点云数据的属性值。In this embodiment, it can be determined based on the code stream whether the attribute values of the point cloud data in the leaf nodes that include more than one point cloud data are merged in the encoding process (for example, determined by the attribute merge flag in the code stream, Of course, it can also be merged or not merged by default without the flag bit and the determination step). If it is determined that the attribute values of the point cloud data in the leaf nodes that include more than one point cloud data are merged, it means that when decoding For such leaf nodes, only the unique attribute value needs to be decoded. Conversely, if it is determined that the attribute values of the point cloud data in the leaf nodes that include more than one point cloud data are not merged, it means that the number of point cloud data and the attributes of each point cloud data need to be decoded for such leaf nodes during decoding value.
以上示例性地描述了根据本发明实施例的点云数据的解码方法。基于上面的描述,根据本发明实施例的点云数据的解码方法采用位置坐标解码与属性解码相混合的解码方案,使得在需要使用部分点云数据时,无需解码全部点云数据的位置坐标后再进行属性值解码,从而提高解码效率。示例性地,根据本发明实施例的点云数据的解码方法可以在具有存储器和处理器的设备、装置或者系统中实现。The above exemplarily describes the point cloud data decoding method according to the embodiment of the present invention. Based on the above description, the point cloud data decoding method according to the embodiment of the present invention adopts a decoding scheme that combines position coordinate decoding and attribute decoding, so that when part of the point cloud data needs to be used, there is no need to decode the position coordinates of all the point cloud data. Then decode the attribute value to improve the decoding efficiency. Exemplarily, the method for decoding point cloud data according to an embodiment of the present invention may be implemented in a device, device, or system having a memory and a processor.
下面结合图6描述根据本发明实施例的点云数据的解码系统。图6示出了根据本发明实施例的点云数据的解码系统600的示意性框图。点云数据的解码系统600包括存储装置610以及处理器620。The following describes a point cloud data decoding system according to an embodiment of the present invention with reference to FIG. 6. Fig. 6 shows a schematic block diagram of a point cloud
其中,存储装置610存储用于实现根据本发明实施例的点云数据的解码方法中的相应步骤的程序。处理器620用于运行存储装置610中存储的程序,以执行根据本发明实施例的点云数据的解码方法的相应步骤。Wherein, the
在一个实施例中,在所述程序被处理器620运行时使得点云数据的解码系统600执行以下步骤:对点云数据的码流进行算术解码得到算术解码结果;以及对所述算术解码结果进行位置坐标与属性的混合解码,以得到所述点云数据各自的位置坐标和属性值;其中,所述混合解码包括:基于多叉树划分进行位置坐标解码得到多个叶子节点,其中,一个叶子节点的属性数据在所述码流中位于所述一个叶子节点的位置数据与另一个叶子节点的位置数据之间;对所述叶子节点中所含的点云数据进行位置解码和属性解码。In one embodiment, when the program is run by the
在本发明的一个实施例中,在所述程序被处理器620运行时还使得点云数据的解码系统600执行以下步骤:基于所述码流确定在所述点云数据的编码过程中是否对所述点云数据的位置坐标进行了量化,如果是进行了 量化,则对所述混合解码得到的位置坐标进行逆量化。In an embodiment of the present invention, when the program is run by the
在本发明的一个实施例中,在所述程序被处理器620运行时还使得点云数据的解码系统600执行以下步骤:在确定所述点云数据的编码过程中对所述点云数据的位置坐标进行了量化之后,确定所述点云数据的编码过程中是否对经量化得到相同位置坐标的点云数据的属性值进行了合并;如果确定进行了合并,则对任一叶子节点的点云数据进行位置解码和属性解码包括:对所述任一叶子节点中的点云数据的唯一属性值进行解码;如果确定未进行合并,则对任一叶子节点的点云数据进行位置解码和属性解码包括:对所述任一叶子节点中的点云数据的个数和属性值分别进行解码。In an embodiment of the present invention, when the program is run by the
在本发明的一个实施例中,在所述程序被处理器620运行时还使得点云数据的解码系统600执行以下步骤:基于所述码流确定在所述点云数据的编码过程中是否对包括不止一个点云数据的任一叶子节点中的点云数据的属性值进行了合并;如果确定进行了合并,则对所述任一叶子节点的点云数据进行位置解码和属性解码包括:对所述任一叶子节点中的点云数据的合并属性值进行解码;如果确定未进行合并,则对所述任一叶子节点的点云数据进行位置解码和属性解码包括:对所述任一叶子节点中的点云数据的个数和属性值分别进行解码。In an embodiment of the present invention, when the program is run by the
在本发明的一个实施例中,在所述程序被处理器620运行时还使得点云数据的解码系统600执行以下步骤:基于所述码流中的属性合并标志位确定在编码过程中是否对点云数据的属性值进行了合并,并基于所述确定的结果对所述叶子节点进行位置解码和属性解码。In an embodiment of the present invention, when the program is run by the
在本发明的一个实施例中,在所述程序被处理器620运行时使得点云数据的解码系统600执行的对所述点云数据的属性值进行解码,包括:对所述点云数据的属性值进行二值化解码。In an embodiment of the present invention, when the program is executed by the
在本发明的一个实施例中,在所述程序被处理器620运行时使得点云数据的解码系统600执行的所述对所述点云数据的属性值进行二值化解码,包括:对所述点云数据的属性值进行定长解码、截断莱斯解码或者指数哥伦布解码。In an embodiment of the present invention, when the program is executed by the
此外,根据本发明实施例,还提供了一种存储介质,在所述存储介质上存储了程序指令,在所述程序指令被计算机或处理器运行时用于执行本 发明实施例的点云数据的解码方法的相应步骤。所述存储介质例如可以包括智能电话的存储卡、平板电脑的存储部件、个人计算机的硬盘、只读存储器(ROM)、可擦除可编程只读存储器(EPROM)、便携式紧致盘只读存储器(CD-ROM)、USB存储器、或者上述存储介质的任意组合。所述计算机可读存储介质可以是一个或多个计算机可读存储介质的任意组合。In addition, according to an embodiment of the present invention, there is also provided a storage medium on which program instructions are stored, and the program instructions are used to execute the point cloud data in the embodiments of the present invention when the program instructions are run by a computer or a processor. The corresponding steps of the decoding method. The storage medium may include, for example, a memory card of a smart phone, a storage component of a tablet computer, a hard disk of a personal computer, a read-only memory (ROM), an erasable programmable read-only memory (EPROM), a portable compact disk read-only memory (CD-ROM), USB memory, or any combination of the above storage media. The computer-readable storage medium may be any combination of one or more computer-readable storage media.
在一个实施例中,所述计算机程序指令在被计算机运行时可以执行根据本发明实施例的点云数据的解码方法。In an embodiment, the computer program instructions can execute the point cloud data decoding method according to the embodiment of the present invention when being executed by a computer.
在一个实施例中,所述计算机程序指令在被计算机或处理器运行时使计算机或处理器执行以下步骤:对点云数据的码流进行算术解码得到算术解码结果;以及对所述算术解码结果进行位置坐标与属性的混合解码,以得到所述点云数据各自的位置坐标和属性值;其中,所述混合解码包括:基于多叉树划分进行位置坐标解码得到多个叶子节点,其中,一个叶子节点的属性数据在所述码流中位于所述一个叶子节点的位置数据与另一个叶子节点的位置数据之间;对所述叶子节点中所含的点云数据进行位置解码和属性解码。In one embodiment, the computer program instructions, when run by the computer or processor, cause the computer or processor to perform the following steps: perform arithmetic decoding on the code stream of the point cloud data to obtain the arithmetic decoding result; and perform the arithmetic decoding result on the arithmetic decoding result Performing hybrid decoding of position coordinates and attributes to obtain respective position coordinates and attribute values of the point cloud data; wherein, the hybrid decoding includes: performing position coordinate decoding based on multi-tree division to obtain multiple leaf nodes, one of which is The attribute data of the leaf node is located between the position data of the one leaf node and the position data of another leaf node in the code stream; the position decoding and attribute decoding are performed on the point cloud data contained in the leaf node.
在本发明的一个实施例中,所述计算机程序指令在被计算机或处理器运行时还使计算机或处理器执行以下步骤:基于所述码流确定在所述点云数据的编码过程中是否对所述点云数据的位置坐标进行了量化,如果是进行了量化,则对所述混合解码得到的位置坐标进行逆量化。In an embodiment of the present invention, when the computer program instructions are executed by the computer or the processor, the computer or the processor also executes the following steps: based on the code stream, it is determined whether the point cloud data is correct or not during the encoding process of the point cloud data. The position coordinates of the point cloud data are quantized, and if quantized, the position coordinates obtained by the hybrid decoding are inversely quantized.
在本发明的一个实施例中,所述计算机程序指令在被计算机或处理器运行时还使计算机或处理器执行以下步骤:在确定所述点云数据的编码过程中对所述点云数据的位置坐标进行了量化之后,确定所述点云数据的编码过程中是否对经量化得到相同位置坐标的点云数据的属性值进行了合并;如果确定进行了合并,则对任一叶子节点的点云数据进行位置解码和属性解码包括:对所述任一叶子节点中的点云数据的唯一属性值进行解码;如果确定未进行合并,则对任一叶子节点的点云数据进行位置解码和属性解码包括:对所述任一叶子节点中的点云数据的个数和属性值分别进行解码。In an embodiment of the present invention, when the computer program instructions are executed by the computer or the processor, the computer or the processor also executes the following steps: in the process of determining the encoding of the point cloud data, After the position coordinates are quantified, it is determined whether the attribute values of the quantized point cloud data with the same position coordinates are merged in the encoding process of the point cloud data; if it is determined that the merge is performed, the point of any leaf node is determined The position decoding and attribute decoding of cloud data includes: decoding the unique attribute value of the point cloud data in any leaf node; if it is determined that no merging is performed, then performing position decoding and attribute decoding on the point cloud data of any leaf node The decoding includes: respectively decoding the number and attribute value of the point cloud data in any of the leaf nodes.
在本发明的一个实施例中,所述计算机程序指令在被计算机或处理器运行时还使计算机或处理器执行以下步骤:基于所述码流确定在所述点云 数据的编码过程中是否对包括不止一个点云数据的任一叶子节点中的点云数据的属性值进行了合并;如果确定进行了合并,则对所述任一叶子节点的点云数据进行位置解码和属性解码包括:对所述任一叶子节点中的点云数据的合并属性值进行解码;如果确定未进行合并,则对所述任一叶子节点的点云数据进行位置解码和属性解码包括:对所述任一叶子节点中的点云数据的个数和属性值分别进行解码。In an embodiment of the present invention, when the computer program instructions are executed by the computer or the processor, the computer or the processor also executes the following steps: based on the code stream, it is determined whether the point cloud data is correct or not during the encoding process of the point cloud data. The attribute values of the point cloud data in any leaf node that includes more than one point cloud data are merged; if it is determined that the merge is performed, the position decoding and attribute decoding on the point cloud data of any leaf node includes: Decoding the merged attribute value of the point cloud data in any one of the leaf nodes; if it is determined that the merge has not been performed, then performing position decoding and attribute decoding on the point cloud data of any one of the leaf nodes includes: The number and attribute value of the point cloud data in the node are decoded separately.
在本发明的一个实施例中,所述计算机程序指令在被计算机或处理器运行时还使计算机或处理器执行以下步骤:基于所述码流中的属性合并标志位确定在编码过程中是否对点云数据的属性值进行了合并,并基于所述确定的结果对所述叶子节点进行位置解码和属性解码。In an embodiment of the present invention, when the computer program instructions are run by the computer or the processor, the computer or the processor also executes the following steps: based on the attribute merging flag bit in the code stream, it is determined whether to correct during the encoding process. The attribute values of the point cloud data are merged, and the position decoding and attribute decoding are performed on the leaf node based on the result of the determination.
在本发明的一个实施例中,所述计算机程序指令在被计算机或处理器运行时使计算机或处理器执行的对所述点云数据的属性值进行解码,包括:对所述点云数据的属性值进行二值化解码。In an embodiment of the present invention, when the computer program instructions are executed by the computer or processor to decode the attribute values of the point cloud data, the computer program instructions include: The attribute value is decoded into binarization.
在本发明的一个实施例中,所述计算机程序指令在被计算机或处理器运行时使计算机或处理器执行的所述对所述点云数据的属性值进行二值化解码,包括:对所述点云数据的属性值进行定长解码、截断莱斯解码或者指数哥伦布解码。In an embodiment of the present invention, when the computer program instructions cause the computer or the processor to execute the binary decoding of the attribute value of the point cloud data when being executed by the computer or the processor, the method includes: The attribute values of the point cloud data are subjected to fixed-length decoding, truncated Rice decoding, or exponential Columbus decoding.
以上示例性地描述了根据本发明实施例的点云数据的编解码方法、系统以及存储介质采集点云数据的采集设备。基于上面的描述,根据本发明实施例的点云数据的编解码方法、系统和存储介质结合位置坐标编码的特点以及属性编码的特点,采用位置坐标编码与属性编码相混合的编码方案,使得在需要使用部分点云数据时,无需解码全部点云数据的位置坐标后再进行属性值解码,从而提高解码效率。The foregoing exemplarily describes the point cloud data encoding and decoding method and system according to the embodiments of the present invention, and the point cloud data collection device for the storage medium. Based on the above description, the point cloud data coding and decoding method, system and storage medium according to the embodiments of the present invention combine the characteristics of position coordinate coding and the characteristics of attribute coding, and adopt a coding scheme that combines position coordinate coding and attribute coding, so that When it is necessary to use part of the point cloud data, it is not necessary to decode the position coordinates of all the point cloud data and then decode the attribute value, thereby improving the decoding efficiency.
尽管这里已经参考附图描述了示例实施例,应理解上述示例实施例仅仅是示例性的,并且不意图将本发明的范围限制于此。本领域普通技术人员可以在其中进行各种改变和修改,而不偏离本发明的范围和精神。所有这些改变和修改意在被包括在所附权利要求所要求的本发明的范围之内。Although the exemplary embodiments have been described herein with reference to the accompanying drawings, it should be understood that the above-described exemplary embodiments are merely exemplary, and are not intended to limit the scope of the present invention thereto. Those of ordinary skill in the art can make various changes and modifications therein without departing from the scope and spirit of the present invention. All these changes and modifications are intended to be included within the scope of the present invention as claimed in the appended claims.
本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、或者计算机软件和电子硬件 的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本发明的范围。A person of ordinary skill in the art may be aware that the units and algorithm steps of the examples described in conjunction with the embodiments disclosed herein can be implemented by electronic hardware or a combination of computer software and electronic hardware. Whether these functions are executed by hardware or software depends on the specific application and design constraint conditions of the technical solution. Professionals and technicians can use different methods for each specific application to implement the described functions, but such implementation should not be considered as going beyond the scope of the present invention.
在本申请所提供的几个实施例中,应该理解到,所揭露的设备和方法,可以通过其它的方式实现。例如,以上所描述的设备实施例仅仅是示意性的,例如,所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个设备,或一些特征可以忽略,或不执行。In the several embodiments provided in this application, it should be understood that the disclosed device and method may be implemented in other ways. For example, the device embodiments described above are only illustrative. For example, the division of the units is only a logical function division, and there may be other divisions in actual implementation, for example, multiple units or components can be combined or It can be integrated into another device, or some features can be ignored or not implemented.
在此处所提供的说明书中,说明了大量具体细节。然而,能够理解,本发明的实施例可以在没有这些具体细节的情况下实践。在一些实例中,并未详细示出公知的方法、结构和技术,以便不模糊对本说明书的理解。In the instructions provided here, a lot of specific details are explained. However, it can be understood that the embodiments of the present invention can be practiced without these specific details. In some instances, well-known methods, structures, and technologies are not shown in detail, so as not to obscure the understanding of this specification.
类似地,应当理解,为了精简本发明并帮助理解各个发明方面中的一个或多个,在对本发明的示例性实施例的描述中,本发明的各个特征有时被一起分组到单个实施例、图、或者对其的描述中。然而,并不应将该本发明的方法解释成反映如下意图:即所要求保护的本发明要求比在每个权利要求中所明确记载的特征更多的特征。更确切地说,如相应的权利要求书所反映的那样,其发明点在于可以用少于某个公开的单个实施例的所有特征的特征来解决相应的技术问题。因此,遵循具体实施方式的权利要求书由此明确地并入该具体实施方式,其中每个权利要求本身都作为本发明的单独实施例。Similarly, it should be understood that in order to simplify the present invention and help understand one or more of the various aspects of the invention, in the description of the exemplary embodiments of the present invention, the various features of the present invention are sometimes grouped together into a single embodiment. , Or in its description. However, the method of the present invention should not be construed as reflecting the intention that the claimed invention requires more features than those explicitly stated in each claim. To be more precise, as reflected in the corresponding claims, the point of the invention is that the corresponding technical problems can be solved with features that are less than all the features of a single disclosed embodiment. Therefore, the claims following the specific embodiment are thus explicitly incorporated into the specific embodiment, wherein each claim itself serves as a separate embodiment of the present invention.
本领域的技术人员可以理解,除了特征之间相互排斥之外,可以采用任何组合对本说明书(包括伴随的权利要求、摘要和附图)中公开的所有特征以及如此公开的任何方法或者设备的所有过程或单元进行组合。除非另外明确陈述,本说明书(包括伴随的权利要求、摘要和附图)中公开的每个特征可以由提供相同、等同或相似目的的替代特征来代替。Those skilled in the art can understand that in addition to mutual exclusion between the features, any combination of all features disclosed in this specification (including the accompanying claims, abstract, and drawings) and any method or device disclosed in this manner can be used. Processes or units are combined. Unless expressly stated otherwise, each feature disclosed in this specification (including the accompanying claims, abstract and drawings) may be replaced by an alternative feature providing the same, equivalent or similar purpose.
此外,本领域的技术人员能够理解,尽管在此所述的一些实施例包括其它实施例中所包括的某些特征而不是其它特征,但是不同实施例的特征的组合意味着处于本发明的范围之内并且形成不同的实施例。例如,在权利要求书中,所要求保护的实施例的任意之一都可以以任意的组合方式来 使用。In addition, those skilled in the art can understand that although some embodiments described herein include certain features included in other embodiments but not other features, the combination of features of different embodiments means that they are within the scope of the present invention. Within and form different embodiments. For example, in the claims, any one of the claimed embodiments can be used in any combination.
本发明的各个部件实施例可以以硬件实现,或者以在一个或者多个处理器上运行的软件模块实现,或者以它们的组合实现。本领域的技术人员应当理解,可以在实践中使用微处理器或者数字信号处理器(DSP)来实现根据本发明实施例的一些模块的一些或者全部功能。本发明还可以实现为用于执行这里所描述的方法的一部分或者全部的装置程序(例如,计算机程序和计算机程序产品)。这样的实现本发明的程序可以存储在计算机可读介质上,或者可以具有一个或者多个信号的形式。这样的信号可以从因特网网站上下载得到,或者在载体信号上提供,或者以任何其他形式提供。The various component embodiments of the present invention may be implemented by hardware, or by software modules running on one or more processors, or by a combination of them. Those skilled in the art should understand that a microprocessor or a digital signal processor (DSP) may be used in practice to implement some or all of the functions of some modules according to the embodiments of the present invention. The present invention can also be implemented as a device program (for example, a computer program and a computer program product) for executing part or all of the methods described herein. Such a program for realizing the present invention may be stored on a computer-readable medium, or may have the form of one or more signals. Such a signal can be downloaded from an Internet website, or provided on a carrier signal, or provided in any other form.
应该注意的是上述实施例对本发明进行说明而不是对本发明进行限制,并且本领域技术人员在不脱离所附权利要求的范围的情况下可设计出替换实施例。在权利要求中,不应将位于括号之间的任何参考符号构造成对权利要求的限制。本发明可以借助于包括有若干不同元件的硬件以及借助于适当编程的计算机来实现。在列举了若干装置的单元权利要求中,这些装置中的若干个可以是通过同一个硬件项来具体体现。单词第一、第二、以及第三等的使用不表示任何顺序。可将这些单词解释为名称。It should be noted that the above-mentioned embodiments illustrate rather than limit the present invention, and those skilled in the art can design alternative embodiments without departing from the scope of the appended claims. In the claims, any reference signs placed between parentheses should not be constructed as a limitation to the claims. The invention can be implemented by means of hardware comprising several different elements and by means of a suitably programmed computer. In the unit claims that list several devices, several of these devices may be embodied in the same hardware item. The use of the words first, second, and third, etc. do not indicate any order. These words can be interpreted as names.
以上所述,仅为本发明的具体实施方式或对具体实施方式的说明,本发明的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本发明揭露的技术范围内,可轻易想到变化或替换,都应涵盖在本发明的保护范围之内。本发明的保护范围应以权利要求的保护范围为准。The above are only specific implementations or descriptions of specific implementations of the present invention. The protection scope of the present invention is not limited thereto. Any person skilled in the art can easily fall within the technical scope disclosed by the present invention. Any change or replacement should be included in the protection scope of the present invention. The protection scope of the present invention shall be subject to the protection scope of the claims.
Claims (20)
Priority Applications (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201980096972.6A CN113906681B (en) | 2019-09-12 | 2019-09-12 | Point cloud data encoding and decoding method, system and storage medium |
| PCT/CN2019/105764 WO2021046817A1 (en) | 2019-09-12 | 2019-09-12 | Point cloud data encoding and decoding method and system and storage medium |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| PCT/CN2019/105764 WO2021046817A1 (en) | 2019-09-12 | 2019-09-12 | Point cloud data encoding and decoding method and system and storage medium |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2021046817A1 true WO2021046817A1 (en) | 2021-03-18 |
Family
ID=74866941
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2019/105764 Ceased WO2021046817A1 (en) | 2019-09-12 | 2019-09-12 | Point cloud data encoding and decoding method and system and storage medium |
Country Status (2)
| Country | Link |
|---|---|
| CN (1) | CN113906681B (en) |
| WO (1) | WO2021046817A1 (en) |
Cited By (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20220210480A1 (en) * | 2020-12-29 | 2022-06-30 | Qualcomm Incorporated | Hybrid-tree coding for inter and intra prediction for geometry coding |
| WO2023061420A1 (en) * | 2021-10-13 | 2023-04-20 | Beijing Bytedance Network Technology Co., Ltd. | Method, apparatus, and medium for point cloud coding |
Citations (6)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN104750854A (en) * | 2015-04-16 | 2015-07-01 | 武汉海达数云技术有限公司 | Mass three-dimensional laser point cloud compression storage and rapid loading and displaying method |
| CN108009979A (en) * | 2017-12-15 | 2018-05-08 | 湖北大学 | Three-dimensional point cloud compression and storage method and system based on space-time data fusion |
| CN108804714A (en) * | 2018-06-30 | 2018-11-13 | 浙江同创空间技术有限公司 | Point cloud data storage method and device |
| US20190018680A1 (en) * | 2017-07-12 | 2019-01-17 | Topcon Positioning Systems, Inc. | Point cloud data method and apparatus |
| US20190114808A1 (en) * | 2017-10-12 | 2019-04-18 | Sony Corporation | Octree traversal for anchor point cloud compression |
| WO2019147816A1 (en) * | 2018-01-26 | 2019-08-01 | Sony Corporation | Hybrid projection-based point cloud texture coding |
Family Cites Families (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN106815875B (en) * | 2016-12-06 | 2020-02-07 | 腾讯科技(深圳)有限公司 | Method and device for encoding and decoding information bitmap |
| US10861196B2 (en) * | 2017-09-14 | 2020-12-08 | Apple Inc. | Point cloud compression |
| WO2019111012A1 (en) * | 2017-12-06 | 2019-06-13 | V-Nova International Ltd | Method and apparatus for decoding a received set of encoded data |
-
2019
- 2019-09-12 WO PCT/CN2019/105764 patent/WO2021046817A1/en not_active Ceased
- 2019-09-12 CN CN201980096972.6A patent/CN113906681B/en active Active
Patent Citations (6)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN104750854A (en) * | 2015-04-16 | 2015-07-01 | 武汉海达数云技术有限公司 | Mass three-dimensional laser point cloud compression storage and rapid loading and displaying method |
| US20190018680A1 (en) * | 2017-07-12 | 2019-01-17 | Topcon Positioning Systems, Inc. | Point cloud data method and apparatus |
| US20190114808A1 (en) * | 2017-10-12 | 2019-04-18 | Sony Corporation | Octree traversal for anchor point cloud compression |
| CN108009979A (en) * | 2017-12-15 | 2018-05-08 | 湖北大学 | Three-dimensional point cloud compression and storage method and system based on space-time data fusion |
| WO2019147816A1 (en) * | 2018-01-26 | 2019-08-01 | Sony Corporation | Hybrid projection-based point cloud texture coding |
| CN108804714A (en) * | 2018-06-30 | 2018-11-13 | 浙江同创空间技术有限公司 | Point cloud data storage method and device |
Cited By (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20220210480A1 (en) * | 2020-12-29 | 2022-06-30 | Qualcomm Incorporated | Hybrid-tree coding for inter and intra prediction for geometry coding |
| US12301890B2 (en) * | 2020-12-29 | 2025-05-13 | Qualcomm Incorporated | Hybrid-tree coding for inter and intra prediction for geometry coding |
| WO2023061420A1 (en) * | 2021-10-13 | 2023-04-20 | Beijing Bytedance Network Technology Co., Ltd. | Method, apparatus, and medium for point cloud coding |
Also Published As
| Publication number | Publication date |
|---|---|
| CN113906681A (en) | 2022-01-07 |
| CN113906681B (en) | 2022-10-18 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN111699683B (en) | Point cloud encoding method, point cloud decoding method and related equipment | |
| CN112470469B (en) | Method and equipment for point cloud coding and decoding | |
| CN115379190B (en) | Point cloud processing method and device, computer equipment and storage medium | |
| US20220108494A1 (en) | Method, device, and storage medium for point cloud processing and decoding | |
| US9532056B2 (en) | Method for adaptive entropy coding of tree structures | |
| JP5944510B2 (en) | Context-Adaptive Binary Arithmetic Coding Method and Apparatus for Syntax Element Context-Adaptive Binary Arithmetic Coding | |
| CN112995662A (en) | Method and device for attribute entropy coding and entropy decoding of point cloud | |
| CN100547615C (en) | Coding scheme for representing data streams of time-varying graphical models | |
| CN113630125B (en) | Data compression, encoding and decompression method, device, electronic equipment and storage medium | |
| KR101782278B1 (en) | Coding and decoding of spectral peak positions | |
| EP4090019A1 (en) | Intra-frame prediction method and apparatus, coder, decoder and storage medium | |
| CN113632492B (en) | Method, equipment and storage medium for point cloud processing and decoding | |
| CN115917604A (en) | Point cloud decoding device, point cloud decoding method and program | |
| WO2021062772A1 (en) | Prediction method, encoder, decoder, and computer storage medium | |
| US20220005229A1 (en) | Point cloud attribute encoding method and device, and point cloud attribute decoding method and devcie | |
| US20240187645A1 (en) | Method and device for intra prediction | |
| CN112740707B (en) | Point cloud encoding and decoding method and device | |
| WO2021046817A1 (en) | Point cloud data encoding and decoding method and system and storage medium | |
| CN113840150B (en) | A point cloud reflectivity attribute entropy encoding and decoding method | |
| WO2021196038A1 (en) | Point cloud encoding and decoding methods and devices | |
| CN113678460B (en) | Data encoding and decoding method, device and storage medium | |
| CN115396668B (en) | Decoding method, encoding device, storage medium and equipment for point cloud data | |
| CN112449191B (en) | Method for compressing multiple images, method and device for decompressing images | |
| CN103517022A (en) | Image data compression and decompression method and device | |
| CN100568284C (en) | Computer graphics data encoding device, decoding device, encoding method, and decoding method |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 19945151 Country of ref document: EP Kind code of ref document: A1 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |
|
| 122 | Ep: pct application non-entry in european phase |
Ref document number: 19945151 Country of ref document: EP Kind code of ref document: A1 |