WO2020220249A1 - 一种数据编码、数据解码方法、设备及存储介质 - Google Patents

一种数据编码、数据解码方法、设备及存储介质 Download PDF

Info

Publication number
WO2020220249A1
WO2020220249A1 PCT/CN2019/085152 CN2019085152W WO2020220249A1 WO 2020220249 A1 WO2020220249 A1 WO 2020220249A1 CN 2019085152 W CN2019085152 W CN 2019085152W WO 2020220249 A1 WO2020220249 A1 WO 2020220249A1
Authority
WO
WIPO (PCT)
Prior art keywords
data
level
level data
code stream
code
Prior art date
Application number
PCT/CN2019/085152
Other languages
English (en)
French (fr)
Inventor
李璞
郑萧桢
Original Assignee
深圳市大疆创新科技有限公司
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by 深圳市大疆创新科技有限公司 filed Critical 深圳市大疆创新科技有限公司
Priority to CN201980008420.5A priority Critical patent/CN111684804B/zh
Priority to PCT/CN2019/085152 priority patent/WO2020220249A1/zh
Publication of WO2020220249A1 publication Critical patent/WO2020220249A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/46Embedding additional information in the video signal during the compression process
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T9/00Image coding
    • G06T9/40Tree coding, e.g. quadtree, octree
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/30Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using hierarchical techniques, e.g. scalability
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/50Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
    • H04N19/597Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding specially adapted for multi-view video sequence encoding

Definitions

  • the present invention relates to the field of data coding and decoding, in particular to a data coding and data decoding method, equipment and storage medium.
  • point cloud data can be collected by laser radars, laser scanners and other equipment.
  • encoding or decoding point cloud data it is usually used to collect data of different levels of the point cloud data in a fixed collection sequence. Encode or decode.
  • the embodiment of the present invention provides a data encoding and data decoding method, device and storage medium, which realizes random access to point cloud data and improves the flexibility of data access.
  • an embodiment of the present invention provides a data encoding method, including:
  • the code stream data includes one or more first-level data, and each of the first-level data includes one or more second-level data;
  • the code stream data further includes identification information used to identify each level of data, and the identification information includes a start code and a code word used to identify the level to which the level data belongs.
  • an embodiment of the present invention provides a data decoding method, including:
  • the code stream data includes a plurality of first-level data, and each of the first-level data includes a plurality of second-level data;
  • the code stream data further includes identification information used to identify each level of data, and the identification information includes a start code and a code word used to identify the level to which the level data belongs.
  • an embodiment of the present invention provides a data encoding device, which is characterized by including: a memory and a processor;
  • the memory is used to store program instructions
  • the processor is configured to call the program instructions, and when the program instructions are executed, to perform the following operations:
  • the code stream data includes one or more first-level data, and each of the first-level data includes one or more second-level data;
  • the code stream data further includes identification information used to identify each level of data, and the identification information includes a start code and a code word used to identify the level to which the level data belongs.
  • an embodiment of the present invention provides a data decoding device, which is characterized by including: a memory and a processor;
  • the memory is used to store program instructions
  • the processor is configured to call the program instructions, and when the program instructions are executed, to perform the following operations:
  • the code stream data includes a plurality of first-level data, and each of the first-level data includes a plurality of second-level data;
  • the code stream data further includes identification information used to identify each level of data, and the identification information includes a start code and a code word used to identify the level to which the level data belongs.
  • an embodiment of the present invention provides a computer-readable storage medium that stores a computer program that, when executed by a processor, implements the data encoding method or the method described in the first aspect above.
  • the data encoding device adds identification information to each level of data to be processed, and encodes the point cloud data after the identification information is added to obtain code stream data, which can realize random access to point cloud data of different levels after decoding. Improve the flexibility of data access.
  • FIG. 1 is a schematic diagram of an encoding process of existing point cloud data provided by an embodiment of the present invention
  • FIG. 2 is a schematic diagram of a decoding process of existing point cloud data according to an embodiment of the present invention
  • FIG. 3 is a schematic diagram of a hierarchical structure of point cloud data provided by an embodiment of the present invention.
  • FIG. 4 is a schematic flowchart of a data encoding method provided by an embodiment of the present invention.
  • FIG. 5 is a schematic flowchart of a data decoding method provided by an embodiment of the present invention.
  • Figure 6 is a schematic structural diagram of a data encoding device provided by an embodiment of the present invention.
  • Fig. 7 is a schematic structural diagram of a data decoding device provided by an embodiment of the present invention.
  • the present invention is aimed at the point cloud data encoding and decoding mode determined by the point cloud data generation method, and determines the data storage file format scheme according to the characteristics of the point cloud data.
  • the following related introductions are made to the point cloud data.
  • the point cloud data is an expression form of a three-dimensional object or scene, and is composed of a set of discrete points in space that are randomly distributed 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 can be encoded and compressed.
  • a point cloud data is usually composed of three-dimensional coordinates (x, y, z) describing coordinate information and attribute information of the location, such as color (R, G, B) or reflectivity.
  • a common point cloud data compression encoding process is shown in FIG. 1, which is a schematic diagram of an existing point cloud data encoding process provided by an embodiment of the present invention.
  • the position coordinates of the input point cloud data are quantified 12
  • the repeated coordinates 121 in the position coordinates are removed
  • the processed position coordinates are position-encoded 13, such as using an eight-pointer
  • the tree is coded, and then the attributes of the input point cloud data are converted 14, and the attributes corresponding to the reordered position order after the position coding are coded 15, and the encoded binary code stream is arithmetic coding 16, thereby Obtain code stream data 17 after encoding the point cloud data.
  • the decoding process of the point cloud data compression is the inverse process of the encoding shown in FIG. 1, specifically as shown in FIG. 2.
  • FIG. 2 is a decoding of existing point cloud data provided by an embodiment of the present invention Schematic diagram of the process. As shown in Figure 2, the bitstream data 21 to be decoded is obtained and arithmetic decoding 22 is performed, and the arithmetic-decoded data is inversely quantized 24 through octree encoding 23 to obtain the position coordinates of the point cloud data, which is decoded by attributes 25 Obtain the attributes of the point cloud data, and finally obtain the decoded point cloud data 26 according to the attributes and position coordinates of the point cloud data.
  • the point cloud data may be collected by a collection device.
  • Common collection devices include but are not limited to lidar, laser scanner, and the like.
  • the point cloud data acquired by this type of acquisition device can generally be divided into the following dimensions: First, the point cloud data acquired within a preset time interval can be regarded as a frame-level data; the preset time interval is the collection A time window of the point cloud data, such as 50 milliseconds, that is, the point cloud data collected within the 50 milliseconds can be regarded as a frame-level data.
  • point cloud data can usually be collected by multiple collection devices at the same time, so the one frame-level data can include collection device-level data collected by multiple collection devices (such as multiple lidars).
  • the collection device-level data of a collection device corresponding to the one frame-level data may include several different packet-level data, and the packet-level data may include different attributes, such as different collection times, different Acquisition accuracy, etc.
  • the point cloud data in the preset time interval is encoded as a frame-level data with a preset time interval (such as 50 milliseconds) as a unit, and the frame-level data is The data volume of the frame-level data is identified in, and the data volume of the frame-level data includes the number of points of the point cloud data, the size of the frame-level data, and so on.
  • the frame-level data of the point cloud data, multiple collection device-level data corresponding to the frame-level data, and data packets of the collection device-level data can be encoded in the collection order Level data.
  • the embodiment of the present invention proposes a data encoding method and a corresponding data decoding method.
  • the data encoding method can be applied to a data encoding device, and the data encoding device can be set on a smart terminal (such as a mobile phone, a tablet computer, etc.).
  • the data decoding method can be applied to a data decoding device, and the data decoding device can also be set on a smart terminal (such as a mobile phone, a tablet computer, etc.).
  • the embodiments of the present invention can also be applied to aircraft (such as unmanned aerial vehicles).
  • the embodiments of the present invention can also be applied to other movable platforms (such as unmanned ships, unmanned aerial vehicles). For automobiles, robots, etc., the embodiment of the present invention does not make specific limitations.
  • the embodiment of the present invention obtains code stream data by acquiring the point cloud data to be encoded, and encoding the point cloud data.
  • the point cloud data includes multiple frame-level data, each frame-level data includes multiple collection device-level data, and the collection device-level data includes multiple packet-level data.
  • the frame-level data, collection device-level data, and packet-level data can be represented by defining a start code (start code) and a code word (code ID).
  • start code can be a prefix.
  • the start code may be a unique identifier in the code stream data obtained by encoding the point cloud data, and random access can be supported by parsing the identifier.
  • the codeword may include a value in a target value set, and different values in the target set respectively represent sequence set data, frame-level data, collection device-level data, packet-level data, and the like.
  • the code stream data obtained by encoding the point cloud data can be divided into four levels of data according to the collection characteristics of the point cloud data.
  • the hierarchical structure is shown in FIG. 3, which is a schematic diagram of a hierarchical structure of point cloud data provided by an embodiment of the present invention.
  • the first level is sequence level data 31, which is the highest level of point cloud data, and the sequence level data is identified by a sequence header;
  • the second level is frame level data 32, which is the highest level of point cloud data.
  • the data can contain multiple frame-level data, and each frame-level data is identified by a frame header;
  • the third level is collection device-level data 33, and the frame-level data can contain multiple collection device-level data.
  • the collection device-level data corresponds to a collection device.
  • the collection device-level data is represented by the collection device data set header; the last level is packet-level data 34, and the collection device-level data contains multiple packet-level data.
  • the packet-level data corresponds to a single attribute, such as the collection time or the initial collection time of the point cloud data in the packet-level data, or the data accuracy of the point cloud data, and the packet-level data is identified by a data packet header.
  • the code stream data is identified by using the start code and the code word as identification information.
  • the start codes used to represent different levels of data in the code stream data are all the same, that is, the code stream data does not have the same identifier as the start code except for the start code itself.
  • only the start code in the code stream data has the identifier, and the data decoding device or point cloud player can find the start of the frame-level data or collect the device-level data or the packet-level data by searching the identifier. Start position. After the starting position is found, the codeword after the starting code can be parsed to determine the frame-level data or collecting device-level data or data packet-level data corresponding to the starting position.
  • pseudo start codes in addition to the start code, there may be pseudo start codes that are not start codes but the same as the binary data of the start codes.
  • the code stream data exists When the pseudo start code is used, the code stream data can be removed from the pseudo start code.
  • the start code is 23 consecutive 0s plus 1 1 from the byte aligned position in the code stream data, and a total of 24 binary bits, that is, 0x000001.
  • the binary bit combinations of the code stream data that may appear in the actual code stream data are diverse, so in addition to the start code, there may be other than the start code but start from the byte alignment in the code stream data. If the data of 0x000001 is added, this situation is generally called a pseudo start code.
  • the code stream data when the code stream data is de-pseudo-start code operation, can be inserted into the same continuous byte as the start code except the start code. Dummy data, so that the same data as the start code does not exist in the code stream data inserted into the pre-fake data.
  • the preset anti-fake data may be an entire byte.
  • the start code is 23 consecutive 0s plus 1 1 from the byte-aligned position in the code stream data, a total of 24 binary bits, that is, 0x000001.
  • the pseudo start code operation can be performed on the code stream data.
  • the de-fake data is preset to be an entire byte of 0x03 bytes, you can insert a byte of 0x03 every time two bytes of 0, namely 0x0000, are encountered during encoding. That is, when the code stream data of the point cloud data is encoded except for the start code, once there are 16 consecutive 0s in the byte alignment, a 0x03 byte is inserted to avoid the occurrence of a pseudo start code.
  • the code stream operation is simple, and it can ensure that in the code stream data, except for the start code itself, other code stream data will not appear in a data string consistent with the start code. , To avoid the pseudo start code.
  • the preset de-fake data may be non-integer bytes.
  • the code stream data may be The pre-fake data of non-integer bytes is inserted into the consecutive bytes that are the same as the start code. If the code stream data is not aligned with the whole byte after inserting the pre-fake data of the non-integer bytes, it can be filled with 0 or 1 after the code stream data to make the insertion of the non-integer data The code stream data after the pre-fake data of the byte is aligned with the whole byte, and the code stream data does not have the same data as the start code.
  • the start code is 23 consecutive 0s plus 1 1 from the byte aligned position in the code stream data, and a total of 24 binary bits, namely 0x000001. If, in addition to the start code, data that is not a start code but 0x000001 appears from the byte alignment point in the code stream data, it is determined that a pseudo start code appears in the code stream data. If the de-false data is preset to be a non-integer byte of 10, you can insert a two-bit number of 10 every time you encounter two bytes of 0, that is, 0x0000 during encoding, and perform an integer after the end of this segment of code stream data. Byte alignment, that is, the last byte of code stream data is filled with 0 or 1 to ensure byte alignment.
  • the code stream is small, and it can be ensured that in the code stream data, except for the start code itself, other code stream data will not have a data string consistent with the start code. , To avoid the pseudo start code.
  • the codeword includes one value in the target value set, and the codewords used to identify different levels of data are different. Assuming that the present invention uses 8bit values for identification, different 8bit values corresponding to the codewords represent different point cloud data types, which can be specifically illustrated by the following examples:
  • Code ID 3: Collecting device data set header, specifically it can be lidar data set header;
  • Code ID 4: Data packet header.
  • the number of collection devices used is limited. Therefore, the collection device of the point cloud data can be coded, and its corresponding code can be encoded in the code ID.
  • the number of the collection device can be described in the following example:
  • Code ID 3 ⁇ 31: Collecting device data set header, specifically it can be a lidar data set header, where the difference between the Code ID value and 3 represents the number of the point cloud data acquisition device;
  • Code ID 32: data packet header.
  • the frame-level data includes different types, such as intra-coded frames and inter-coded frames. Therefore, the type of the frame-level data can be further indicated in the codeword, which can be specifically illustrated by the following examples:
  • Code ID 2 ⁇ 7: Frame header, the Code ID value 2 ⁇ 7 indicate different frame types;
  • the packet-level data in actual encoding, is relatively small, and often only contains a few hundred or a few thousand points. In some applications, if the amount of packet-level data is small, the packet-level data does not need to support random access. At this time, the packet-level data does not need to be identified by a start code plus a codeword. At this time, the packet-level data is stored in the frame-level data in the order in which the packet-level is collected.
  • the size of the packet-level data is encoded with a fixed length (such as 32 bits) at the start position of the packet-level data.
  • the end of each packet-level data needs to be byte-aligned. If it is not aligned, 0 or 1 can be filled after the packet-level data is encoded to ensure byte alignment, so as to improve The decoding efficiency of data decoding equipment and point cloud playback equipment.
  • an encoding method can be illustrated as follows: First, the data encoding device can encode the start code 0x000001 of the sequence header, and then Encode the codeword 0x01 corresponding to the sequence header of the sequence-level data; secondly, encode the start code 0x000001 of the frame header of the frame-level data, and then encode the codeword corresponding to the frame header, if the frame-level data is intra-frame encoded data , Then encode the Code ID value 0x02; again, encode the start code 0x000001 of the collection device data set header of the collection device-level data, and then encode the codeword corresponding to the collection device data set header.
  • the value of the codeword can be all The collection device number value + n, where n is a preset value. For example, assuming that the preset value is 8 and the collection device number is 0, then the Code ID value corresponding to the collection device header is 0x08; Finally, the start code 0x000001 of the data packet header of the data packet-level data is encoded, and the code word 0x20 corresponding to the data packet header is encoded.
  • the data decoding device may obtain the code stream data obtained by encoding, and decode the code stream data to obtain point cloud data corresponding to the code stream data.
  • a decoding method when the data decoding device decodes the code stream data to obtain the point cloud data corresponding to the code stream data, a decoding method can be illustrated as follows: First, the data decoding device can obtain The code stream data encoded by the point cloud data, and the reverse operation of removing the false start code is performed on the code stream data; secondly, the data decoding device decodes to obtain the start code 0x000001, and decodes the code word corresponding to the start code, if A codeword value of 1 indicates the corresponding sequence-level data; again, decode to obtain the start code 0x000001, and decode to obtain the codeword corresponding to the start code.
  • the codeword value is 2 to 7, it indicates the corresponding frame-level data, where,
  • the parsed Code ID value -2 indicates the point cloud frame type. If its value is 0, it means that the frame-level data is intra-frame coded data; again, decode to obtain the start code 0x000001, and decode to obtain the corresponding start code Codeword, if the value of the codeword is 8-8+n, it means the corresponding collection device-level data, where n is the preset value.
  • the preset value is 8
  • the code ID value obtained by the analysis is 8
  • an encoding method can be illustrated as follows: First, the data encoding device can encode the point cloud sequence header start code 0xFFFFFE, Then encode the codeword 0x01 corresponding to the sequence header of the sequence-level data; secondly, encode the start code 0xFFFFFE of the frame header of the frame-level data, and then encode the codeword corresponding to the frame header, if the frame-level data is intra-frame encoding Data, encode the Code ID value of 0x02; again, encode the start code 0xFFFFFE of the collection device data set header of the collection device-level data, and then encode the codeword corresponding to the cloud collection device data set header.
  • the value of the codeword can be Is the number value of the point cloud collection device + n, where n is the preset value agreed by the codec. For example, if the preset value is 8 and the collection device number is 0, then the collection device header The corresponding Code ID value is 0x08; finally, the start code 0xFFFFFE of the data packet header of the data packet-level data is encoded, and the code word 0x20 corresponding to the data packet header is encoded.
  • a decoding method can be illustrated as follows: First, the data decoding device can obtain The code stream data encoded by the point cloud data is subjected to the reverse operation of removing the pseudo start code on the code stream data; secondly, the data decoding device decodes to obtain the start code 0xFFFFFE, and decodes the code word corresponding to the start code, if A codeword value of 1 indicates the corresponding sequence-level data; again, decode to obtain the start code 0xFFFFFE, and decode to obtain the codeword corresponding to the start code. If the codeword value is 2 to 7, it indicates the corresponding frame-level data.
  • the obtained Code ID value -2 indicates the point cloud frame type. If its value is 0, it means that the frame-level data is intra-frame coded data; again, decode to obtain the start code 0xFFFFFE, and decode to obtain the code corresponding to the start code
  • the codeword value is 8 ⁇ 8+n, it means the corresponding collection device-level data, where n is the preset value agreed by the codec; for example, if the preset value is 8, if the code ID value obtained by parsing 8 means that the data corresponds to the acquisition device-level data numbered 0; again, decode to obtain the start code 0xFFFFFE, and decode to obtain the codeword corresponding to the start code, if the codeword value is 0x20, it means packet-level data ; Finally, the packet-level data is used as a unit for decoding.
  • the packet-level data is stored in the frame-level data in the order of the packet-level data collection.
  • the starting position describes the size of the data packet level with a fixed length (such as 32 bits), and then the fixed length information is decoded during decoding to obtain the size of the data packet level.
  • the point cloud data is encoded by using the start code and the code word as identification information, so that random access to the point cloud data can be realized by parsing the identification information; the code words include different values and different values.
  • the value of represents the point cloud frame, the point cloud collection device data set, the point cloud data packet, etc.
  • the combination of the start code and the code word helps to determine the level of a certain piece of data in the code stream data.
  • FIG. 4 is a schematic flowchart of a data encoding method according to an embodiment of the present invention. The method can be applied to a data encoding device, where the explanation of the data encoding device is as described above, and will not be repeated here. Specifically, the method of the embodiment of the present invention includes the following steps.
  • the data encoding device can obtain the point cloud data to be processed.
  • the point cloud data may be obtained through one or more collection devices; in some embodiments, the collection devices may include, but are not limited to, laser radars, laser scanners and other devices.
  • the lidar is a perceptual sensor that can obtain three-dimensional information of the scene.
  • the basic principle is to actively emit laser pulse signals to the detected object and obtain the reflected pulse signals.
  • the depth information of the distance detector of the object to be measured is calculated; Know the launch direction, obtain the angle information of the measured object relative to the lidar; combine the aforementioned depth information and angle information to obtain a large number of detection points (called point cloud data).
  • S402 Encode the point cloud data to obtain bitstream data, where the bitstream data includes one or more first-level data, and each first-level data includes one or more second-level data
  • the code stream data also includes identification information used to identify each level of data, and the identification information includes a start code and a codeword used to identify the level of the hierarchy data.
  • the data encoding device may encode the point cloud data to obtain code stream data, where the code stream data includes one or more first-level data, and each of the first-level data includes One or more second-level data; the code stream data further includes identification information for identifying each level of data, and the identification information includes a start code and a codeword for identifying the level to which the hierarchical data belongs.
  • the identification information is located in the header information of the hierarchical data.
  • the start codes used to identify different levels of data are the same.
  • the start code is binary data
  • the codeword is binary data.
  • the codewords used to identify different levels of data are different.
  • the level to which a certain piece of data in the code stream data belongs can be determined, which is helpful for subsequent analysis by the start code and the code word.
  • Said identification information of, realizes random access to different levels of data.
  • the first level data includes sequence level data
  • the second level data includes frame level data.
  • the sequence-level data includes a start code and a codeword
  • the point cloud data can be collected according to a preset time interval
  • the point cloud data acquired during the preset time interval is frame-level data Encode. Therefore, if the point cloud data is divided according to a preset time interval, two levels of data can be obtained, that is, the first level is sequence level data, and the second level is frame level data.
  • the point cloud data collected in different time intervals can be coded, which improves the coding efficiency and facilitates random access to point cloud data at different time intervals after decoding.
  • each of the second-level data may include one or more third-level data
  • the first-level data includes sequence-level data
  • the second-level data includes frame-level data
  • the The third-level data includes collecting device-level data or packet-level data.
  • the frame-level data is point cloud data acquired in a fixed time period
  • the point cloud data acquired in a fixed time period may be collected by multiple collection devices at different locations. Therefore, if the code stream data is divided hierarchically according to the point cloud data acquisition position, the first-level data includes sequence-level data, the second-level data includes frame-level data, and the third-level data Including collecting device-level data.
  • the third-level data includes collection device-level data
  • each of the third-level data includes one or more fourth-level data
  • the fourth-level data includes packet-level data.
  • the point cloud data collected by the corresponding collection devices in the frame-level data may include packet-level data.
  • the packet-level data includes several different point cloud data packets.
  • each of the third-level data includes one or more fourth-level data
  • the fourth-level data includes packet-level data. That is, the first-level data may include sequence-level data, the second-level data includes frame-level data, the third-level data includes collection device-level data, and the fourth-level data includes packet-level data.
  • the collection device-level data can be divided when the amount of data at the collection device level is large, and one or more packet-level data can be obtained, which improves the coding efficiency and helps to improve the data volume.
  • the codewords of the plurality of second-level data are respectively one of the values in the target value set.
  • the second-level data includes frame-level data; different values in the target value set are used to indicate different types of frames.
  • the type of the frame includes an intra-coded frame or an inter-coded frame.
  • the values 2-7 in the target value set correspond to different frame types.
  • the first level data includes sequence level data
  • the second level data includes collection device level data.
  • the code stream data can be divided into sequence-level data and collection device-level data.
  • the point cloud data collected by different collection devices can be coded, which improves the coding efficiency and facilitates random access to the point cloud data collected by different collection devices after decoding.
  • the second-level data includes a plurality of third-level data
  • the third-level data includes frame-level data.
  • each collection device collects point cloud data at different times. If the code stream data is divided according to the time when each point cloud device collects point cloud data, the first level can be obtained.
  • the data includes sequence-level data
  • the second-level data includes acquisition device-level data
  • the third-level data includes frame-level data.
  • the point cloud data collected by different collection devices at different times can be coded, which improves the coding efficiency and facilitates random access to the point cloud data collected by different collection devices at different times after decoding.
  • the codewords of the plurality of second-level data are respectively one of the values in the target value set.
  • the second-level data includes collection device-level data; different values in the target value set are used to indicate that the data comes from different collection devices. For example, suppose that the number of the collection device corresponding to the value 3 to 31 in the target value set is 0-28, and if the current codeword is the value 3, it can be determined that the point cloud data comes from the collection device 0.
  • the data encoding device after the data encoding device obtains the code stream data, it can determine whether there is a pseudo start code in the code stream data, and if it is determined to exist, it can de-fake the code stream data. Start code operation.
  • the data encoding device when the data encoding device performs a de-false start code operation on the code stream data, it may insert preset de-false data in the data of the code stream data except the start code to The code stream data after inserting the preset de-fake data is different from the start code.
  • the preset anti-fake data includes whole byte data or non-whole byte data.
  • the preset anti-fake data may be an entire byte of data, which can be specifically illustrated. Assume that the preset anti-fake data is a 0x03 byte, and the start code is a byte from the code stream data. The 23 consecutive 0s at the beginning of the alignment plus 1 1, for a total of 24 binary bits, that is, 0x000001.
  • the preset anti-fake data may be non-full-byte data
  • the data encoding device can insert the code after the preset anti-fake data into the data other than the start code of the code stream data.
  • a designated value is added to the end of the stream data to perform full byte alignment, so that the code stream data after the preset de-false data and the designated value are inserted is different from the start code.
  • the preset anti-fake data is a two-bit number of 10
  • the start code is 23 consecutive 0s plus 1 1 from the byte-aligned position in the bitstream data, a total of 24 binary bits. That is, 0x000001.
  • the code stream data other than the start code data that is not the start code but 0x000001 appears from the byte alignment, you can insert 10 after 0x0000, and add the specified value 00 at the end of the code stream data , So that the code stream data 0x001000 after inserting 10 and the specified value 00 is different from the start code 0x000001, so as to avoid the same data as the start code 0x000001 in the code stream data.
  • the data encoding device may add a preset value to the end of the packet-level data of the code stream data to Make the length of the packet-level data in the code stream data equal to the preset length. For example, assuming that the preset length of the packet-level data is 32 bits, if the length of the packet-level data in the code stream data is 30 bits, then 2 bits of 0 or 1 can be added to the end of the packet machine data.
  • the data encoding device can obtain the point cloud data to be processed, determine the different levels of the point cloud data, add identification information to each level of data, and compare the data according to the different levels of the point cloud data.
  • the point cloud data is encoded to obtain code stream data.
  • FIG. 5 is a schematic flowchart of a data decoding method according to an embodiment of the present invention.
  • the method can be applied to a data decoding device, and the specific explanation of the data decoding device is as described above.
  • the method of the embodiment of the present invention includes the following steps.
  • S501 Receive code stream data.
  • the data decoding device can receive code stream data.
  • the code stream data includes multiple first-level data, and each of the first-level data includes multiple second-level data; in some embodiments, the code stream data further includes In order to identify the identification information of each level of data, the identification information includes a start code and a codeword for identifying the level to which the level of data belongs. In some embodiments, the identification information is located in the header information of the hierarchical data. In some embodiments, the start codes used to identify different levels of data are the same. In some embodiments, the start code is binary data, and the codeword is binary data. In some embodiments, the codewords used to identify different levels of data are different.
  • S502 Decode the code stream data to obtain point cloud data corresponding to the code stream data, where the code stream data includes multiple first-level data, and each first-level data includes multiple The second-level data; the code stream data further includes identification information used to identify each level of data, and the identification information includes a start code and a code word used to identify the level of the hierarchical data.
  • the data decoding device may decode the code stream data to obtain point cloud data corresponding to the code stream data.
  • the data decoding device can detect whether the code stream data has undergone a de-false start code operation before decoding the code stream data, and if the detection result is yes, it can check the code stream data.
  • the code stream data undergoes the reverse operation of removing the false start code.
  • the data decoding device detects that the data other than the start code in the code stream data includes preset anti-fake data, it can determine that the code stream data has undergone anti-fake start Code operation.
  • the data decoding device when it performs the reverse operation of removing the false start code on the code stream data, it can obtain the data in the code stream data other than the start code, and delete the code stream data. Pre-fake data in data other than the original code. In some embodiments, the preset anti-fake data includes whole byte data or non-whole byte data.
  • the preset anti-fake data may be an entire byte of data, which can be specifically illustrated by an example. Assume that the start code is 23 consecutive 0s plus 1s starting from the byte alignment in the code stream data. One 1, a total of 24 binary bits, namely 0x000001; assuming that the preset binary data is a 0x03 byte, if 0x000003 appears in the code stream data, the inverse operation of removing the false start code can be performed on the code stream data Delete the preset binary data 0x03 in the code stream data.
  • the preset anti-fake data may be non-full-byte data
  • the data decoding device may obtain data other than the start code in the code stream data, and delete the data except the start code.
  • the pre-fake data and the specified value in the data other than the code For specific examples, suppose the start code is 23 consecutive 0s plus 1 1 from the byte-aligned position in the code stream data, a total of 24 binary bits, namely 0x000001; suppose the preset binary data is two bits The number is 10, and the specified value is 00.
  • the inverse operation of removing the pseudo start code can be performed on the code stream data to delete the two-bit preset binary number in the code stream data Data 10 and the specified value 00 at the end of the code stream data.
  • the codeword includes one value in the target value set; when the data decoding device determines the point cloud data corresponding to the codeword according to the codeword obtained by decoding, it may One of the values in the target value set of the codeword determines the type of the level to which the level data belongs, and determines the point cloud data corresponding to the type of level to which the level data belongs.
  • the specific implementation is as described above and will not be repeated here.
  • the data decoding device may access the point cloud data of the hierarchical data corresponding to the codeword.
  • the data decoding device may randomly access one of the codestream data according to the identification information obtained by decoding the codestream data Hierarchical level data.
  • the codeword in the identification information obtained by decoding the bitstream data is 8
  • the codewords 8 to 31 are used to indicate that the point cloud data is collection device-level data
  • the corresponding relationship between the codeword and the serial number of the collection device It is: the number of the collection device is the difference between the code word and 8, then it can be determined that the number of the collection device is 0.
  • the code stream data includes a plurality of first-level data, and each of the first-level data includes a plurality of second-level data.
  • the first level data includes sequence level data
  • the second level data includes frame level data.
  • the sequence-level data includes a start code and a codeword
  • the point cloud data can be collected according to a preset time interval
  • the point cloud data acquired during the preset time interval is frame-level data Encode. Therefore, if the point cloud data is divided according to a preset time interval, two levels of data can be obtained, that is, the first level is sequence level data, and the second level is frame level data.
  • the point cloud data collected in different time intervals can be decoded, which helps to randomly access the point cloud data in different time intervals.
  • each of the second-level data may include one or more third-level data
  • the first-level data includes sequence-level data
  • the second-level data includes frame-level data
  • the The third-level data includes collecting device-level data or packet-level data.
  • the frame-level data is point cloud data acquired in a fixed time period
  • the point cloud data acquired in a fixed time period may be collected by multiple collection devices at different locations. Therefore, if the code stream data is divided hierarchically according to the point cloud data acquisition position, the first-level data includes sequence-level data, the second-level data includes frame-level data, and the third-level data Including collecting device-level data.
  • the point cloud data collected by different collection devices in different time intervals can be decoded, which helps to randomly access the point cloud data collected by different time intervals and different collection devices.
  • the third-level data includes collection device-level data
  • each of the third-level data includes one or more fourth-level data
  • the fourth-level data includes packet-level data.
  • the point cloud data collected by the corresponding collection devices in the frame-level data may include packet-level data.
  • the packet-level data includes several different point cloud data packets.
  • each of the third-level data includes one or more fourth-level data
  • the fourth-level data includes packet-level data. That is, the first-level data may include sequence-level data, the second-level data includes frame-level data, the third-level data includes collection device-level data, and the fourth-level data includes packet-level data.
  • the flexibility of accessing point cloud data can be improved when the amount of data collected at the device level is large.
  • the codewords of the plurality of second-level data are respectively one of the values in the target value set.
  • the second-level data includes frame-level data; different values in the target value set are used to indicate different types of frames.
  • the type of the frame includes an intra-coded frame or an inter-coded frame.
  • the values 2-7 in the target value set correspond to different frame types.
  • the first level data includes sequence level data
  • the second level data includes collection device level data.
  • the code stream data can be divided into sequence-level data and collection device-level data.
  • the point cloud data collected by different collection devices can be decoded, which helps to randomly access the point cloud data collected by different collection devices.
  • the second-level data includes a plurality of third-level data
  • the third-level data includes frame-level data.
  • each collection device collects point cloud data at different times. If the code stream data is divided according to the time when each point cloud device collects point cloud data, the first level can be obtained.
  • the data includes sequence-level data
  • the second-level data includes acquisition device-level data
  • the third-level data includes frame-level data.
  • the point cloud data collected by different collection devices at different times can be decoded, which helps to randomly access the point cloud data collected by different collection devices at different times.
  • the data decoding device can decode the received code stream data to obtain point cloud data corresponding to the code stream data and including different levels of data and identification information.
  • point cloud data corresponding to the code stream data and including different levels of data and identification information.
  • FIG. 6 is a schematic structural diagram of a data encoding device according to an embodiment of the present invention.
  • the data encoding device includes a memory 601, a processor 602, and a data interface 603.
  • the memory 601 may include a volatile memory (volatile memory); the memory 601 may also include a non-volatile memory (non-volatile memory); the memory 601 may also include a combination of the foregoing types of memories.
  • the processor 602 may be a central processing unit (CPU).
  • the processor 602 may further include a hardware data encoding device.
  • the aforementioned hardware data encoding device may be an application-specific integrated circuit (ASIC), a programmable logic device (PLD), or a combination thereof. For example, it may be a complex programmable logic device (CPLD), a field-programmable gate array (FPGA), or any combination thereof.
  • ASIC application-specific integrated circuit
  • PLD programmable logic device
  • FPGA field-programmable gate array
  • the memory 601 is used to store program instructions.
  • the processor 602 can call the program instructions stored in the memory 601 to perform the following steps:
  • the code stream data includes one or more first-level data, and each of the first-level data includes one or more second-level data;
  • the code stream data further includes identification information used to identify each level of data, and the identification information includes a start code and a code word used to identify the level to which the level data belongs.
  • the first level data includes sequence level data
  • the second level data includes frame level data
  • each of the second-level data includes one or more third-level data
  • the third-level data includes collection device-level data or data packet-level data.
  • the third-level data includes collecting device-level data
  • Each of the third-level data includes one or more fourth-level data, and the fourth-level data includes packet-level data.
  • first level data includes sequence level data
  • second level data includes collection device level data
  • the second-level data includes a plurality of third-level data
  • the third-level data includes frame-level data
  • the identification information is located in the header information of the hierarchical data.
  • start codes used to identify different levels of data are all the same.
  • codewords used to identify different levels of data are different.
  • codewords of the multiple second-level data are respectively one of the values in the target value set.
  • the second-level data includes collecting device-level data
  • the different values in the target value set are used to indicate that the data comes from different collection devices.
  • the second-level data includes frame-level data
  • Different values in the target value set are used to indicate different types of frames.
  • the type of the frame includes an intra-coded frame or an inter-coded frame.
  • start code is binary data
  • code word is binary data
  • processor 602 is further configured to:
  • the processor 602 when the processor 602 performs a de-false start code operation on the code stream data, it is specifically configured to:
  • the preset anti-fake data includes whole byte data or non-whole byte data.
  • the preset anti-fake data includes non-full-byte data
  • the processor 602 is further configured to:
  • the specified value is added at the end of the code stream data inserted into the pre-fake data to perform whole byte alignment.
  • processor 602 is further configured to:
  • a preset value is added to the end of the packet-level data of the code stream data, so that the packet-level data in the code stream data The length of the data is equal to the preset length.
  • the data encoding device can obtain the point cloud data to be processed, determine the different levels of the point cloud data, add identification information to each level of data, and compare the data according to the different levels of the point cloud data.
  • the point cloud data is encoded to obtain code stream data.
  • FIG. 7 is a schematic structural diagram of a data decoding device according to an embodiment of the present invention.
  • the data decoding device includes a memory 701, a processor 702, and a data interface 703.
  • the memory 701 may include a volatile memory (volatile memory); the memory 701 may also include a non-volatile memory (non-volatile memory); the memory 701 may also include a combination of the foregoing types of memories.
  • the processor 702 may be a central processing unit (CPU).
  • the processor 702 may further include a hardware data encoding device.
  • the aforementioned hardware data encoding device may be an application-specific integrated circuit (ASIC), a programmable logic device (PLD), or a combination thereof. For example, it may be a complex programmable logic device (CPLD), a field-programmable gate array (FPGA), or any combination thereof.
  • ASIC application-specific integrated circuit
  • PLD programmable logic device
  • FPGA field-programmable gate array
  • the memory 701 is used to store program instructions.
  • the processor 702 can call the program instructions stored in the memory 701 to perform the following steps:
  • the code stream data includes a plurality of first-level data, and each of the first-level data includes a plurality of second-level data;
  • the code stream data further includes identification information used to identify each level of data, and the identification information includes a start code and a code word used to identify the level to which the level data belongs.
  • processor 702 decodes the code stream data, it is further configured to:
  • the reverse operation of removing the false start code is performed on the code stream data.
  • the processor 702 detects whether the code stream data has undergone a de-false start code operation, it is specifically configured to:
  • the code stream data When it is detected that the data other than the start code in the code stream data includes preset de-fake data, it is determined that the code stream data has undergone a de-fake start code operation.
  • processor 702 when the processor 702 performs the reverse operation of removing the false start code on the code stream data, it is specifically configured to:
  • the preset anti-fake data includes whole byte data or non-whole byte data.
  • the preset anti-fake data includes non-full-byte data; when the processor 702 performs the reverse operation of the anti-fake start code on the code stream data, it is specifically used to:
  • the codeword includes one of the values in the target value set; when the processor 702 determines the point cloud data corresponding to the codeword according to the codeword obtained by decoding, it is specifically used for:
  • the point cloud data corresponding to the type of the level to which the level data belongs is determined.
  • processor 702 determines the point cloud data corresponding to the codeword, it is further configured to:
  • Access point cloud data of the hierarchical data corresponding to the codeword is provided.
  • each of the second-level data includes one or more third-level data
  • the third-level data includes collection device-level data or data packet-level data.
  • the third-level data includes collecting device-level data
  • Each of the third-level data includes one or more fourth-level data, and the fourth-level data includes packet-level data.
  • first level data includes sequence level data
  • second level data includes collection device level data
  • the second-level data includes one or more third-level data; the third-level data includes frame-level data.
  • the identification information is located in the header information of the hierarchical data.
  • start codes used to identify different levels of data are all the same.
  • codewords used to identify different levels of data are different.
  • codewords of the plurality of second-level data are respectively one of the values in the target value set.
  • the second-level data includes collecting device-level data
  • the different values in the target value set are used to indicate that the data comes from different collection devices.
  • the second-level data includes frame-level data
  • Different values in the target value set are used to indicate different types of frames.
  • the type of the frame includes an intra-coded frame or an inter-coded frame.
  • processor 702 randomly accesses the hierarchical data of one of the levels in the code stream data, it is specifically configured to:
  • the data decoding device can decode the received code stream data to obtain point cloud data corresponding to the code stream data and including different levels of data and identification information.
  • point cloud data corresponding to the code stream data and including different levels of data and identification information.
  • a computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the data described in the embodiment of the present invention is realized in FIG. 4
  • the encoding method, or the data decoding method described in Figure 5 can also implement the data encoding device of the corresponding embodiment of the present invention described in Figure 6, or the data decoding device of the corresponding embodiment of the present invention described in Figure 7, in This will not be repeated here.
  • the computer-readable storage medium may be an internal storage unit of the device described in any of the foregoing embodiments, such as a hard disk or memory of the device.
  • the computer-readable storage medium may also be an external storage device of the device, such as a plug-in hard disk equipped on the device, a Smart Media Card (SMC), or a Secure Digital (SD) card. , Flash Card, etc.
  • the computer-readable storage medium may also include both an internal storage unit of the device and an external storage device.
  • the computer-readable storage medium is used to store the computer program and other programs and data required by the device.
  • the computer-readable storage medium can also be used to temporarily store data that has been output or will be output.
  • the program can be stored in a computer readable storage medium. During execution, it may include the procedures of the above-mentioned method embodiments.
  • the storage medium may be a magnetic disk, an optical disc, a read-only memory (Read-Only Memory, ROM), or a random access memory (Random Access Memory, RAM), etc.

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

本发明实施例提供了一种数据编码、数据解码方法、设备及存储介质,其中,该方法包括:获取待处理的点云数据;对所述点云数据进行编码得到码流数据;其中,所述码流数据包括一个或多个第一层级数据,每个所述第一层级数据中包括一个或多个第二层级数据;所述码流数据还包括用于标识每一层级数据的标识信息,所述标识信息包括起始码和用于标识所述层级数据的所属层级的码字。通过这种方式可以实现解码后随机访问不同层级的点云数据,提高了数据访问的灵活性。

Description

一种数据编码、数据解码方法、设备及存储介质 技术领域
本发明涉及数据编解码领域,尤其涉及一种数据编码、数据解码方法、设备及存储介质。
背景技术
现有技术中,通过激光雷达、激光扫描仪等设备可以采集得到点云数据,在对点云数据进行编码或解码时,通常采用的是按固定采集顺序对所述点云数据的不同层级数据进行编码或解码。
然而,这种按固定采集顺序对点云数据进行编码的方式,在解码时只能从点云数据码流最开始处开始一一访问,不能对点云数据中的任意一层级数据进行随机访问。因此,如何实现对点云数据的随机访问以提高数据访问灵活性成为研究的重点。
发明内容
本发明实施例提供了一种数据编码、数据解码方法、设备及存储介质,实现了对点云数据的随机访问,提高了对数据访问的灵活性。
第一方面,本发明实施例提供了一种数据编码方法,包括:
获取待处理的点云数据;
对所述点云数据进行编码得到码流数据;
其中,所述码流数据包括一个或多个第一层级数据,每个所述第一层级数据中包括一个或多个第二层级数据;
所述码流数据还包括用于标识每一层级数据的标识信息,所述标识信息包括起始码和用于标识所述层级数据的所属层级的码字。
第二方面,本发明实施例提供了一种数据解码方法,包括:
接收码流数据;
对所述码流数据进行解码,得到与所述码流数据对应的点云数据;
其中,所述码流数据包括多个第一层级数据,每个所述第一层级数据中包括多个第二层级数据;
所述码流数据还包括用于标识每一层级数据的标识信息,所述标识信息包括起始码和用于标识所述层级数据的所属层级的码字。
第三方面,本发明实施例提供了一种数据编码设备,其特征在于,包括:存储器和处理器;
所述存储器,用于存储程序指令;
所述处理器,用于调用所述程序指令,当所述程序指令被执行时,用于执行以下操作:
获取待处理的点云数据;
对所述点云数据进行编码得到码流数据;
其中,所述码流数据包括一个或多个第一层级数据,每个所述第一层级数据中包括一个或多个第二层级数据;
所述码流数据还包括用于标识每一层级数据的标识信息,所述标识信息包括起始码和用于标识所述层级数据的所属层级的码字。
第四方面,本发明实施例提供了一种数据解码设备,其特征在于,包括:存储器和处理器;
所述存储器,用于存储程序指令;
所述处理器,用于调用所述程序指令,当所述程序指令被执行时,用于执行以下操作:
接收码流数据;
对所述码流数据进行解码,得到与所述码流数据对应的点云数据;
其中,所述码流数据包括多个第一层级数据,每个所述第一层级数据中包括多个第二层级数据;
所述码流数据还包括用于标识每一层级数据的标识信息,所述标识信息包括起始码和用于标识所述层级数据的所属层级的码字。
第五方面,本发明实施例提供了一种计算机可读存储介质,该计算机可读存储介质存储有计算机程序,该计算机程序被处理器执行时实现如上述第一方面所述的数据编码方法或上述第二方面所述的数据解码方法。
本发明实施例,通过数据编码设备对待处理的每一层级数据添加标识信息,并对添加标识信息后的点云数据进行编码得到码流数据,可以实现解码后随机访问不同层级的点云数据,提高了数据访问的灵活性。
附图说明
为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1是本发明实施例提供的一种现有点云数据的编码流程示意图;
图2是本发明实施例提供的一种现有点云数据的解码流程示意图;
图3是本发明实施例提供的一种点云数据的层级结构示意图;
图4是本发明实施例提供的一种数据编码方法的流程示意图;
图5是本发明实施例提供的一种数据解码方法的流程示意图;
图6是本发明实施例提供的一种数据编码设备的结构示意图;
图7是本发明实施例提供的一种数据解码设备的结构示意图。
具体实施方式
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。
下面结合附图,对本发明的一些实施方式作详细说明。在不冲突的情况下,下述的实施例及实施例中的特征可以相互组合。
本发明是针对点云数据产生的方法确定的点云数据编码和解码的方式,并根据点云数据的特点确定数据存储的文件格式方案。在介绍本发明之前,首先对点云数据进行如下相关介绍。
在一个实施例中,所述点云数据是三维物体或场景的一种表现形式,是由空间中一组无规则分布、表达三维物体或场景空间结构和表面属性的离散点集所构成。为了准确反映空间中的信息,所需离散点的数目是巨大的。为了减少点云数据存储和传输时所占用的带宽,可以对点云数据进行编码压缩处理。
在一个实施例中,一个点云数据通常由描述坐标信息的三维坐标(x,y,z)以及该位置的属性信息如颜色(R,G,B)或者反射率等属性构成。在一个实施 例中,常见的点云数据压缩的编码流程如图1所示,图1是本发明实施例提供的一种现有点云数据的编码流程示意图。如图1所示,通过输入点云数据11,对输入的点云数据的位置坐标进行量化12,去除位置坐标中的重复坐标121,对处理后的位置坐标进行位置编码13,如使用八叉树进行编码,然后对输入的点云数据的属性进行属性转换14,并对位置编码后重排序的位置顺序对应的属性进行属性编码15,以及对编码后的二进制码流进行算术编码16,从而得到对点云数据编码后的码流数据17。
在一个实施例中,所述点云数据压缩的解码流程是图1所示的编码的逆过程,具体如图2所示,图2是本发明实施例提供的一种现有点云数据的解码流程示意图。如图2所示,获取待解码的码流数据21对其进行算术解码22,通过八叉树编码23对算术解码后的数据进行逆量化24,得到点云数据的位置坐标,通过属性解码25得到点云数据的属性,最后根据点云数据的属性和位置坐标,得到解码的点云数据26。
在一个实施例中,所述点云数据可以由采集设备采集得到,常见的采集设备包括但不限于激光雷达、激光扫描仪等。通过此类采集设备获取的点云数据通常可划分为以下几个维度:首先,在一个预设时间间隔内获取得到的点云数据可视为一个帧级数据;所述预设时间间隔为采集点云数据的一个时间窗,如50毫秒,即在该50毫秒内采集得到的点云数据均可认为是一个帧级数据。其次,点云数据通常可以是由多台采集设备同时采集得到的,因此所述一个帧级数据可以包含多个采集设备(如多台激光雷达)采集得到的采集设备级数据。再次,所述一个帧级数据中对应的一台采集设备的采集设备级数据可以包括若干不同的数据包级数据,所述数据包级数据可以包括不同的属性,如不同的采集时间、不同的采集精度等。
在一个实施例中,通过对所述点云数据按采集时间顺序编码,并加上一定的标识信息可以用于区分不同序列、不同帧、不同采集设备、不同属性的点云数据包的信息。例如,在采集点云数据的过程中,以预设时间间隔(如50毫秒)为单位将在所述预设时间间隔中的点云数据作为一个帧级数据进行编码,并在该帧级数据中标识所述帧级数据的数据量,该帧级数据的数据量包括点云数据的点数、该帧级数据的大小等。
在一个实施例中,当采集设备包含多台采集设备时,可以按采集顺序编码 点云数据的帧级数据、帧级数据对应的多个采集设备级数据、所述采集设备级数据的数据包级数据。
本发明实施例提出了一种数据编码方法以及对应的数据解码方法,所述数据编码方法可以应用于数据编码设备,所述数据编码设备可以设置在智能终端(如手机、平板电脑等)上。所述数据解码方法可以应用于数据解码设备,所述数据解码设备也可以设置在智能终端(如手机、平板电脑等)上。在某些实施例中,本发明实施例还可应用于飞行器(如无人机)上,在其他实施例中,本发明实施例还可以应用于其他可移动平台(如无人船、无人汽车、机器人等)上,本发明实施例不做具体限定。
本发明实施例通过获取待编码的点云数据,对所述点云数据进行编码得到码流数据。在某些实施例中,所述点云数据包含多个帧级数据、每个帧级数据包含多个采集设备级数据、所述采集设备级数据包含多个数据包级数据。
在一个实施例中,所述帧级数据、采集设备级数据、数据包级数据可以通过定义起始码(start code)加码字(code ID)的方式来表示。一个示例中,该起始码可以是前缀符。在某些实施例中,所述起始码可以为点云数据编码得到的码流数据中唯一存在的标识,通过解析该标识可支持随机访问。在某些实施例中,所述码字可以包括目标数值集合中的一个数值,所述目标集合中的不同数值分别表示序列集数据、帧级数据、采集设备级数据、数据包级数据等。通过起始码和码字的组合可确定所述码流数据中某一段数据属于某一个序列级数据或某一个帧级数据或采集设备级数据或数据包级数据。
在一个实施例中,根据点云数据的采集特点可以将点云数据编码得到的码流数据分为四个层级的数据。所述分层结构如图3所示,图3是本发明实施例提供的一种点云数据的层级结构示意图。如图3所示,第一个层级为序列级数据31,此为点云数据的最高层级,所述序列级数据以序列头来标识;第二个层级为帧级数据32,所述序列级数据中可以包含多个帧级数据,每个帧级数据以帧头来标识;第三个层级为采集设备级数据33,所述帧级数据可以包含多个采集设备级数据,所述每个采集设备级数据对应一台采集设备,所述采集设备级数据以采集设备数据集头来表示;最后一个层级为数据包级数据34,所述采集设备级数据中包含多个数据包级数据,所述数据包级数据对应一个单独的属性,如该数据包级数据中点云数据的采集时间或起始采集时间或点云数 据的数据精度,所述数据包级数据以数据包头来标识。
在一个实施例中,以起始码和码字为标识信息的方式对码流数据进行标识。在一个实施例中,所述码流数据中用于表示不同层级数据的起始码均相同,即码流数据中除了起始码本身不会出现与起始码相同的标识。
在一个实施例中,码流数据中有且仅有起始码具有该标识,数据解码设备或点云播放器可以通过查找该标识找到帧级数据或采集设备级数据或数据包级数据的起始位置。找到所述起始位置之后,可以通过解析所述起始码之后的码字,确定所述起始位置对应的帧级数据或采集设备级数据或数据包级数据。
在一个实施例中,在码流数据中除了起始码以外还有可能会出现不是起始码,但却跟起始码的二进制数据相同的伪起始码,当所述码流数据中存在伪起始码时,可以对所述码流数据进行去伪起始码操作。
例如,假设所述起始码为码流数据中从字节对齐处开始的23个连续的0加1个1,总共24个二进制位,即0x000001。在实际的码流数据中可能出现的码流数据的二进制位的组合是多样的,因此在码流数据中除了起始码以外还有可能会出现不是起始码但从字节对齐处开始出现了0x000001的数据,一般把这种情况称为伪起始码。
在一个实施例中,在对所述码流数据进行去伪起始码操作时,可以在所述码流数据除起始码以外的、与起始码一样的连续字节中插入预设去伪数据,以使所述插入预设去伪数据后的码流数据中不存在与所述起始码相同的数据。
在一个实施例中,所述预设去伪数据可以为整字节。具体可举例说明,假设所述起始码为码流数据中从字节对齐处开始的23个连续的0加1个1,总共24个二进制位,即0x000001。如果所述码流数据中出现伪起始码,则可以对所述码流数据进行去伪起始码操作。如果预设去伪数据为一个整字节0x03字节,则可以在编码时每遇到两个字节的0即0x0000,就插入一个字节0x03。即当点云数据经编码之后的码流数据除了起始码以外的数据,一旦出现字节对齐处有16个连续的0则插入一个0x03字节,以避免出现伪起始码的情况。
本发明实施例通过插入整字节的预设去伪数据的方式,码流操作简单,可以确保码流数据中除了起始码本身,其它码流数据不会出现与起始码一致的数据串,避免了出现伪起始码的情况。
在一个实施例中,所述预设去伪数据可以为非整字节,在对所述码流数据 进行去伪起始码操作时,可以在所述码流数据除起始码以外的、与起始码一样的连续字节中插入非整字节的预设去伪数据。如果在插入所述非整字节的预设去伪数据之后,所述码流数据没有整字节对齐,则可以在码流数据后以0或1填充,以使所述插入所述非整字节的预设去伪数据后的码流数据整字节对齐,且码流数据中不存在与所述起始码相同的数据。
具体可举例说明,假设起始码为码流数据中从字节对齐处开始的23个连续的0加1个1,总共24个二进制位,即0x000001。如果在所述码流数据中除了起始码以外还出现不是起始码但从字节对齐处开始出现了0x000001的数据,则确定所述码流数据中出现伪起始码。如果预设去伪数据为一个非整字节的10,则可以在编码时每遇到两个字节的0即0x0000,就插入两比特数10,并在这一段码流数据结束之后进行整字节对齐,即对最后一个字节的码流数据进行填充0或填充1,以保证字节对齐。
本发明实施例通过插入非整字节的预设去伪数据的方式,码流少,可以确保码流数据中除了起始码本身,其它码流数据不会出现与起始码一致的数据串,避免了出现伪起始码的情况。
在一个实施例中,所述码字包括目标数值集合中的其中一个数值,用于标识不同层级数据的码字不同。假设本发明采用8bit数值来标识,所述码字所对应的不同的8bit数值表示不同的点云数据类型,具体可以如下示例进行说明:
Code ID=1:序列头;
Code ID=2:帧头;
Code ID=3:采集设备数据集头,具体的可以为激光雷达数据集头等;
Code ID=4:数据包头。
在一个实施例中,在点云数据实际采集过程中,所使用的采集设备的数量是有限的,因此可以对所述点云数据的采集设备进行编码,在码字code ID中编码其对应的采集设备编号,具体可以如下示例进行说明:
Code ID=1:序列头;
Code ID=2:帧头;
Code ID=3~31:采集设备数据集头,具体的可以为激光雷达数据集头,其中,Code ID值与3的差值表示所述点云数据的采集设备的编号;
Code ID=32:数据包头。
在一个实施例中,所述帧级数据包括不同的类型,如帧内编码帧、帧间编码帧,因此在码字中可以进一步表示所述帧级数据的类型,具体可以如下示例进行说明:
Code ID=1:序列头;
Code ID=2~7:帧头,所述Code ID值2~7表示不同的帧类型;
Code ID=8~31:采集设备数据集头,具体的可以为激光雷达数据集头,其中,Code ID值与8的差值可以表示所述点云数据的采集设备的编号。
Code ID=32:点云数据包头。
在一个实施例中,在实际编码时所述数据包级数据比较少,往往只包含了几百个或几千个点。在一些应用中,如果数据包级数据的数量较少,则数据包级数据不需要支持随机访问,此时数据包级数据不需要通过起始码加码字的方式进行标识。此时,在帧级数据中以采集数据包级的顺序存储数据包级数据。
在一个实施例中,通过在数据包级数据的起始位置以固定长度(如32bit)编码所述数据包级数据的大小。在某些实施例中,所述每个数据包级数据结尾需字节对齐,若不对齐则可以在所述数据包级数据编码完之后填充0或填充1以保证字节对齐,以便于提高数据解码设备以及及点云播放设备的解码效率。
在一个实施例中,数据编码设备在对所述点云数据进行编码得到码流数据时,一种编码方式可以如下示例进行说明:首先,数据编码设备可以编码序列头的起始码0x000001,然后编码序列级数据的序列头对应的码字0x01;其次,编码所述帧级数据的帧头的起始码0x000001,然后编码帧头对应的码字,若所述帧级数据为帧内编码数据,则编码Code ID值0x02;再次,编码所述采集设备级数据的采集设备数据集头的起始码0x000001,然后编码采集设备数据集头对应的码字,所述码字的值可以为所述采集设备编号值+n,其中,n为预设数值,例如,假设所述预设数值为8,所述采集设备编号为0,则所述采集设备集头对应的Code ID值为0x08;最后,编码所述数据包级数据的数据包头的起始码0x000001,并编码所述数据包头对应的码字0x20。
在一个实施例中,数据解码设备可以获取编码得到的码流数据,并对所述码流数据进行解码,得到与所述码流数据对应的点云数据。
在一个实施例中,数据解码设备在对所述码流数据进行解码,得到与所述码流数据对应的点云数据时,一种解码方式可以如下示例进行说明:首先,数 据解码设备可以获取点云数据编码的码流数据,并对所述码流数据进行去伪起始码的逆操作;其次,数据解码设备解码获得起始码0x000001,并解码获得起始码对应的码字,若码字值为1则表示对应序列级数据;再次,解码获得起始码0x000001,并解码获得起始码对应的码字,若码字值为2~7,则表示对应帧级数据,其中,解析得到的Code ID值-2表示点云帧类型,若其值为0,则表示所述帧级数据为帧内编码数据;再次,解码获得起始码0x000001,并解码获得起始码对应的码字,若码字值为8~8+n,则表示对应采集设备级数据,其中,n为预设数值。例如,假设预设数值为8,若解析得到的Code ID值为8,则表示该数据对应编号为0的采集设备级数据;再次,解码获得起始码0x000001,并解码获得起始码对应的码字,若码字值为0x20,则表示数据包级数据;最后,以所述数据包级数据为单位进行解码。
在一个实施例中,数据编码设备在对所述点云数据进行编码得到码流数据时,一种编码方式可以如下示例进行说明:首先,数据编码设备可以编码点云序列头起始码0xFFFFFE,然后编码序列级数据的序列头对应的码字0x01;其次,编码所述帧级数据的帧头的起始码0xFFFFFE,然后编码帧头对应的码字,若所述帧级数据为帧内编码数据,则编码Code ID值0x02;再次,编码所述采集设备级数据的采集设备数据集头的起始码0xFFFFFE,然后编码云采集设备数据集头对应的码字,所述码字的值可以为所述点云采集设备编号值+n,其中n为编解码器约定的预设数值,例如,假设所述预设数值为8,所述采集设备编号为0,则所述采集设备集头对应的Code ID值为0x08;最后,编码所述数据包级数据的数据包头的起始码0xFFFFFE,并编码所述数据包头对应的码字0x20。
在一个实施例中,数据解码设备在对所述码流数据进行解码,得到与所述码流数据对应的点云数据时,一种解码方式可以如下示例进行说明:首先,数据解码设备可以获得点云数据编码的码流数据,并对所述码流数据进行去伪起始码的逆操作;其次,数据解码设备解码获得起始码0xFFFFFE,并解码获得起始码对应的码字,若码字值为1则表示对应序列级数据;再次,解码获得起始码0xFFFFFE,并解码获得起始码对应的码字,若码字值为2~7则表示对应帧级数据,其中,解析得到的Code ID值-2表示点云帧类型,若其值为0,则表示所述帧级数据为帧内编码数据;再次,解码获得起始码0xFFFFFE,并 解码获得起始码对应的码字,若码字值为8~8+n,则表示对应采集设备级数据,其中,n为编解码器约定的预设数值;例如,假设预设数值为8,若解析得到的Code ID值为8,则表示该数据对应编号为0的采集设备级数据;再次,解码获得起始码0xFFFFFE,并解码获得起始码对应的码字,若码字值为0x20,则表示数据包级数据;最后,以所述数据包级数据为单位进行解码。
在一个实施例中,若数据包级数据较少,不支持随机访问功能,则在帧级数据中以数据包级数据的采集顺序存储所述数据包级数据,如果在数据包级数据的起始位置以固定长度(如32bit)描述所述数据包级的大小,则解码时解码所述固定长度的信息,以获得所述数据包级数据的大小。
本发明实施例,通过起始码和码字作为标识信息对点云数据进行编码,可以实现通过解析该标识信息,对所述点云数据进行随机访问;所述码字包括不同的数值,不同的数值分别表示点云帧、点云采集设备数据集、点云数据包等,通过起始码和码字的组合,有助于判断所述码流数据中某一段数据所属的层级。
下面结合附图对本发明实施例提供的数据编码、数据解码方法进行示意性说明。
具体请参见图4,图4是本发明实施例提供的一种数据编码方法的流程示意图。所述方法可以应用于数据编码设备,其中,所述数据编码设备的解释如前所述,此处不再赘述。具体地,本发明实施例的所述方法包括如下步骤。
S401:获取待处理的点云数据。
本发明实施例中,数据编码设备可以获取待处理的点云数据。
在一些实施例中,所述点云数据可以通过一个或多个采集设备获取得到;在某些实施例中,所述采集设备可以包括但不限于激光雷达、激光扫描仪等设备。
需要说明的是,所述激光雷达是一种感知传感器,可以获得场景的三维信息。其基本原理为主动对被探测对象发射激光脉冲信号,并获得其反射回来的脉冲信号,根据发射信号和接收信号之间的时间差计算被测对象的距离探测器的深度信息;基于激光雷达的已知发射方向,获得被测对象相对激光雷达的角度信息;结合前述深度信息和角度信息得到海量的探测点(称为点云数据)。
S402:对所述点云数据进行编码得到码流数据,其中,所述码流数据包括一个或多个第一层级数据,每个所述第一层级数据中包括一个或多个第二层级数据;所述码流数据还包括用于标识每一层级数据的标识信息,所述标识信息包括起始码和用于标识所述层级数据的所属层级的码字。
本发明实施例中,数据编码设备可以对所述点云数据进行编码得到码流数据,其中,所述码流数据包括一个或多个第一层级数据,每个所述第一层级数据中包括一个或多个第二层级数据;所述码流数据还包括用于标识每一层级数据的标识信息,所述标识信息包括起始码和用于标识所述层级数据的所属层级的码字。
在某些实施例中,所述标识信息位于所述层级数据的头信息内。在某些实施例中,用于标识不同层级数据的起始码均相同。在某些实施例中,所述起始码为二进制数据,所述码字为二进制数据。在某些实施例中,用于标识不同层级数据的码字不同。
通过起始码和码字的组合作为每一层级的点云数据的标识信息,可以确定所述码流数据中某一段数据所属的层级,有助于后续通过解析由起始码和码字组成的所述标识信息,实现对不同层级数据的随机访问。
在一个实施例中,所述第一层级数据包括序列级数据,所述第二层级数据包括帧级数据。在一个实施例中,所述序列级数据包括起始码和码字,所述点云数据可以根据预设时间间隔采集得到,将在预设时间间隔里获取到的点云数据为帧级数据进行编码。因此,如果按照预设时间间隔对所述点云数据进行划分,可以得到两个层级的数据,即第一层级为序列级数据,以及第二层级数据为帧级数据。
通过这种实施方式,可以根据不同时间间隔内采集到的点云数据进行编码,提高了编码效率,以及有助于解码后随机访问不同时间间隔的点云数据。
在一些实施例中,每个所述第二层级数据中可以包括一个或多个第三层级数据,所述第一层级数据包括序列级数据,所述第二层级数据包括帧级数据,所述第三层级数据包括采集设备级数据或数据包级数据。在一个实施例中,所述帧级数据是在固定时间段获取到的点云数据,所述在固定时间段获取到的点云数据可以通过不同位置的多台采集设备采集得到的。因此,如果按照点云数据的获取位置对所述码流数据进行层级划分可以得到,所述第一层级数据包括 序列级数据,所述第二层级数据包括帧级数据,所述第三层级数据包括采集设备级数据。
通过这种实施方式,可以根据在不同时间间隔内、不同采集设备采集的点云数据进行编码,提高了编码效率,有助于随机访问不同时间间隔内、不同采集设备采集的点云数据。
在一个实施例中,所述第三层级数据包括采集设备级数据,每个所述第三层级数据包括一个或多个第四层级数据,所述第四层级数据包括数据包级数据。在一些实施例中,当获取到的所述点云数据的数据量非常大时,所述帧级数据中对应的各采集设备采集的点云数据(即采集设备级数据)可以包括数据包级数据,所述数据包级数据包括若干不同的点云数据包。此时,每个所述第三层级数据包括一个或多个第四层级数据,所述第四层级数据包括数据包级数据。即所述第一层级数据可以包括序列级数据,所述第二层级数据包括帧级数据,所述第三层级数据包括采集设备级数据,所述第四层级数据包括数据包级数据。
通过这种实施方式,可以在采集设备级的数据量较大的情况下对采集设备级数据进行划分,得到一个或多个数据包级数据,提高了编码效率,有助于提高在数据量较大的情况下解码后对点云数据访问的灵活性。
在一个实施例中,所述多个第二层级数据的码字分别为目标数值集合中的其中一个数值。在一个实施例中,所述第二层级数据包括帧级数据;所述目标数值集合中的不同数值用于指示帧的不同类型。在某些实施例中,所述帧的类型包括帧内编码帧或帧间编码帧,例如,目标数值集合中数值2~7对应表示不同的帧类型。
在一个实施例中,所述第一层级数据包括序列级数据,所述第二层级数据包括采集设备级数据。在一个实施例中,如果根据采集所述点云数据的设备对所述码流数据进行划分,则可以将所述码流数据划分为序列级数据和采集设备级数据。
通过这种实施方式,可以根据不同采集设备采集的点云数据进行编码,提高了编码效率,有助于解码后随机访问不同采集设备采集的点云数据。
在一个实施例中,所述第二层级数据包括多个第三层级数据,所述第三层级数据包括帧级数据。在一个实施例中,每个采集设备采集点云数据的时间不 相同,如果按照每个点云设备采集点云数据的时间对所述码流数据进行划分,则可以划分得到所述第一层级数据包括序列级数据,所述第二层级数据包括采集设备级数据,所述第三层级数据包括帧级数据。
通过这种实施方式,可以根据不同采集设备在不同时间采集的点云数据进行编码,提高了编码效率,有助于解码后随机访问不同采集设备在不同时间采集的点云数据。
在一个实施例中,所述多个第二层级数据的码字分别为目标数值集合中的其中一个数值。在一个实施例中,所述第二层级数据包括采集设备级数据;所述目标数值集合中的不同数值用于指示数据来自不同的采集设备。例如,假设目标数值集合中数值3~31对应表示的采集设备的编号为0~28,如果当前码字为数值3,则可以确定所述点云数据来自采集设备0。
在一个实施例中,所述数据编码设备在获取到码流数据之后,可以确定所述码流数据中是否存在伪起始码,如果确定存在,则可以对所述码流数据进行去伪起始码操作。
在一个实施例中,所述数据编码设备在对所述码流数据进行去伪起始码操作时,可以在所述码流数据除起始码以外的数据中插入预设去伪数据,以使插入预设去伪数据后的码流数据与所述起始码不相同。在某些实施例中,所述预设去伪数据包括整字节数据或非整字节数据。
在一个实施例中,所述预设去伪数据可以为整字节数据,具体可举例说明,假设预设去伪数据为一个0x03字节,所述起始码为码流数据中从字节对齐处开始的23个连续的0加1个1,总共24个二进制位,即0x000001。如果在码流数据中除了起始码以外的数据中出现不是起始码但从字节对齐处开始出现了0x000001的数据,则可以在0x0000后插入一个字节0x03,以使插入0x03后的码流数据0x000003与所述起始码0x000001不相同,避免在码流数据中出现与起始码0x000001相同数据。
在一个实施例中,所述预设去伪数据可以为非整字节数据,所述数据编码设备可以在所述码流数据除起始码以外的数据中插入预设去伪数据之后的码流数据的结尾添加指定数值,以进行整字节对齐,以使插入预设去伪数据和指定数值后的码流数据与所述起始码不相同。
具体可举例说明,假设预设去伪数据为两比特数10,所述起始码为码流 数据中从字节对齐处开始的23个连续的0加1个1,总共24个二进制位,即0x000001。如果在码流数据中除了起始码以外的数据中出现不是起始码但从字节对齐处开始出现了0x000001的数据,则可以在0x0000后插入10,并在码流数据结尾添加指定数值00,以使插入10和指定数值00后的码流数据0x001000与所述起始码0x000001不相同,避免在码流数据中出现与起始码0x000001相同数据。
通过这种实施方式,可以确保码流数据中除了起始码本身,其它码流数据不会出现与起始码一致的数据串,避免误判起始码。
在一个实施例中,当所述码流数据中数据包级数据的长度小于预设长度时,所述数据编码设备可以在所述码流数据的数据包级数据的结尾添加预设数值,以使所述码流数据中所述数据包级数据的长度等于所述预设长度。例如,假设数据包级数据的预设长度为32bit,如果所述码流数据中数据包级数据的长度为30bit,则可以在数据包机数据的结尾添加2bit的0或1。
本发明实施例中,数据编码设备可以获取待处理的点云数据,确定所述点云数据的不同层级,并对每一层级数据添加标识信息,以及根据所述点云数据的不同层级对所述点云数据进行编码得到码流数据。通过这种实施方式,可以提高编码效率,有助于解码后随机访问不同层级的点云数据。
请参见图5,图5是本发明实施例提供的一种数据解码方法的流程示意图,所述方法可以应用于数据解码设备,其中,所述数据解码设备的具体解释如前所述。具体地,本发明实施例的所述方法包括如下步骤。
S501:接收码流数据。
本发明实施例中,数据解码设备可以接收码流数据。
在一个实施例中,所述码流数据包括多个第一层级数据,每个所述第一层级数据中包括多个第二层级数据;在一些实施例中,所述码流数据还包括用于标识每一层级数据的标识信息,所述标识信息包括起始码和用于标识所述层级数据的所属层级的码字。在某些实施例中,所述标识信息位于所述层级数据的头信息内。在某些实施例中,用于标识不同层级数据的起始码均相同。在某些实施例中,所述起始码为二进制数据,所述码字为二进制数据。在某些实施例中,用于标识不同层级数据的码字不同。
S502:对所述码流数据进行解码,得到与所述码流数据对应的点云数据,其中,所述码流数据包括多个第一层级数据,每个所述第一层级数据中包括多个第二层级数据;所述码流数据还包括用于标识每一层级数据的标识信息,所述标识信息包括起始码和用于标识所述层级数据的所属层级的码字。
本发明实施例中,数据解码设备可以对所述码流数据进行解码,得到与所述码流数据对应的点云数据。
在一个实施例中,所述数据解码设备在对所述码流数据进行解码之前,可以检测所述码流数据是否进行了去伪起始码操作,如果检测结果为是,则可以对所述码流数据进行去伪起始码的逆操作。在一个实施例中,所述数据解码设备当检测到在所述码流数据中除起始码以外的数据中包括预设去伪数据时,可以确定所述码流数据进行了去伪起始码操作。
在一个实施例中,所述数据解码设备对所述码流数据进行去伪起始码的逆操作时,可以获取在所述码流数据中除起始码以外的数据,删除所述除起始码以外的数据中的预设去伪数据。在某些实施例中,所述预设去伪数据包括整字节数据或非整字节数据。
在一个实施例中,所述预设去伪数据可以为整字节数据,具体可举例说明,假设所述起始码为码流数据中从字节对齐处开始的23个连续的0加1个1,总共24个二进制位,即0x000001;假设预设二进制数据为一个0x03字节,如果所述码流数据中出现0x000003,则可以对所述码流数据进行去伪起始码的逆操作删除所述码流数据中的预设二进制数据0x03。
在一个实施例中,所述预设去伪数据可以为非整字节数据,所述数据解码设备可以获取在所述码流数据中除起始码以外的数据,并删除所述除起始码以外的数据中的预设去伪数据和指定数值。具体可举例说明,假设所述起始码为码流数据中从字节对齐处开始的23个连续的0加1个1,总共24个二进制位,即0x000001;假设预设二进制数据为两比特数10,指定数值为00,如果所述码流数据中出现0x001000,则可以对所述码流数据进行去伪起始码的逆操作删除所述码流数据中的两比特数的预设二进制数据10和码流数据结尾的指定数值00。
在一个实施例中,所述码字包括目标数值集合中的其中一个数值;所述数据解码设备在根据解码得到的码字,确定与所述码字对应的点云数据时,可以 根据所述码字的目标数值集合中的其中一个数值,确定所述层级数据的所属层级的类型,并确定与所述层级数据的所属层级的类型对应的点云数据。具体实施例如前所述,此处不再赘述。
在一些实施例中,所述数据解码设备在确定与所述码字对应的点云数据之后,可以访问与所述码字对应的层级数据的点云数据。
在一个实施例中,所述数据解码设备在确定与所述码字对应的点云数据之后,可以根据对所述码流数据解码得到的标识信息,随机访问所述码流数据中的其中一个层级的层级数据。
例如,假设对码流数据进行解码得到的标识信息中的码字为8,如果码字8~31用于表示点云数据为采集设备级数据,所述码字与采集设备的编号的对应关系为:采集设备的编号为码字与8的差值,则可以确定所述采集设备的编号为0。
在一个实施例中,所述码流数据包括多个第一层级数据,每个所述第一层级数据中包括多个第二层级数据。
在一些实施例中,所述第一层级数据包括序列级数据,所述第二层级数据包括帧级数据。在一个实施例中,所述序列级数据包括起始码和码字,所述点云数据可以根据预设时间间隔采集得到,将在预设时间间隔里获取到的点云数据为帧级数据进行编码。因此,如果按照预设时间间隔对所述点云数据进行划分,可以得到两个层级的数据,即第一层级为序列级数据,以及第二层级数据为帧级数据。
通过这种实施方式,可以解码得到不同时间间隔内采集到的点云数据,有助于随机访问不同时间间隔的点云数据。
在一些实施例中,每个所述第二层级数据中可以包括一个或多个第三层级数据,所述第一层级数据包括序列级数据,所述第二层级数据包括帧级数据,所述第三层级数据包括采集设备级数据或数据包级数据。在一个实施例中,所述帧级数据是在固定时间段获取到的点云数据,所述在固定时间段获取到的点云数据可以通过不同位置的多台采集设备采集得到的。因此,如果按照点云数据的获取位置对所述码流数据进行层级划分可以得到,所述第一层级数据包括序列级数据,所述第二层级数据包括帧级数据,所述第三层级数据包括采集设备级数据。
通过这种实施方式,可以解码得到在不同时间间隔内、不同采集设备采集的点云数据,有助于随机访问不同时间间隔、不同采集设备采集的点云数据。
在一个实施例中,所述第三层级数据包括采集设备级数据,每个所述第三层级数据包括一个或多个第四层级数据,所述第四层级数据包括数据包级数据。在一些实施例中,当获取到的所述点云数据的数据量非常大时,所述帧级数据中对应的各采集设备采集的点云数据(即采集设备级数据)可以包括数据包级数据,所述数据包级数据包括若干不同的点云数据包。此时,每个所述第三层级数据包括一个或多个第四层级数据,所述第四层级数据包括数据包级数据。即所述第一层级数据可以包括序列级数据,所述第二层级数据包括帧级数据,所述第三层级数据包括采集设备级数据,所述第四层级数据包括数据包级数据。
通过这种实施方式,可以提高在采集设备级的数据量较大的情况下访问点云数据的灵活性。
在一个实施例中,所述多个第二层级数据的码字分别为目标数值集合中的其中一个数值。在一个实施例中,所述第二层级数据包括帧级数据;所述目标数值集合中的不同数值用于指示帧的不同类型。在某些实施例中,所述帧的类型包括帧内编码帧或帧间编码帧,例如,目标数值集合中数值2~7对应表示不同的帧类型。
在一个实施例中,所述第一层级数据包括序列级数据,所述第二层级数据包括采集设备级数据。在一个实施例中,如果根据采集所述点云数据的设备对所述码流数据进行划分,则可以将所述码流数据划分为序列级数据和采集设备级数据。
通过这种实施方式,可以解码得到不同采集设备采集的点云数据,有助于随机访问不同采集设备采集的点云数据。
在一个实施例中,所述第二层级数据包括多个第三层级数据,所述第三层级数据包括帧级数据。在一个实施例中,每个采集设备采集点云数据的时间不相同,如果按照每个点云设备采集点云数据的时间对所述码流数据进行划分,则可以划分得到所述第一层级数据包括序列级数据,所述第二层级数据包括采集设备级数据,所述第三层级数据包括帧级数据。
通过这种实施方式,可以解码得到不同采集设备在不同时间采集的点云数 据,有助于随机访问不同采集设备在不同时间采集的点云数据。
本发明实施例中,数据解码设备可以对接收到的码流数据进行解码,得到与所述码流数据对应的包括不同层级数据和标识信息的点云数据。通过这种实施方式,可以实现根据标识信息随机访问所述码流数据中不同层级的数据,提高了数据访问的灵活性。
请参见图6,图6是本发明实施例提供的一种数据编码设备的结构示意图,具体的,所述数据编码设备包括:存储器601、处理器602以及数据接口603。
所述存储器601可以包括易失性存储器(volatile memory);存储器601也可以包括非易失性存储器(non-volatile memory);存储器601还可以包括上述种类的存储器的组合。所述处理器602可以是中央处理器(central processing unit,CPU)。所述处理器602还可以进一步包括硬件数据编码设备。上述硬件数据编码设备可以是专用集成电路(application-specific integrated circuit,ASIC),可编程逻辑器件(programmable logic device,PLD)或其组合。具体例如可以是复杂可编程逻辑器件(complex programmable logic device,CPLD),现场可编程逻辑门阵列(field-programmable gate array,FPGA)或其任意组合。
进一步地,所述存储器601用于存储程序指令,当程序指令被执行时所述处理器602可以调用存储器601中存储的程序指令,用于执行如下步骤:
获取待处理的点云数据;
对所述点云数据进行编码得到码流数据;
其中,所述码流数据包括一个或多个第一层级数据,每个所述第一层级数据中包括一个或多个第二层级数据;
所述码流数据还包括用于标识每一层级数据的标识信息,所述标识信息包括起始码和用于标识所述层级数据的所属层级的码字。
进一步地,所述第一层级数据包括序列级数据,所述第二层级数据包括帧级数据。
进一步地,每个所述第二层级数据中包括一个或多个第三层级数据,所述第三层级数据包括采集设备级数据或数据包级数据。
进一步地,所述第三层级数据包括采集设备级数据;
每个所述第三层级数据包括一个或多个第四层级数据,所述第四层级数据 包括数据包级数据。
进一步地,所述第一层级数据包括序列级数据,所述第二层级数据包括采集设备级数据。
进一步地,所述第二层级数据包括多个第三层级数据,所述第三层级数据包括帧级数据。
进一步地,所述标识信息位于所述层级数据的头信息内。
进一步地,用于标识不同层级数据的起始码均相同。
进一步地,用于标识不同层级数据的码字不同。
进一步地,所述多个第二层级数据的码字分别为目标数值集合中的其中一个数值。
进一步地,所述第二层级数据包括采集设备级数据;
所述目标数值集合中的不同数值用于指示数据来自不同的采集设备。
进一步地,所述第二层级数据包括帧级数据;
所述目标数值集合中的不同数值用于指示帧的不同类型。
进一步地,所述帧的类型包括帧内编码帧或帧间编码帧。
进一步地,所述起始码为二进制数据,所述码字为二进制数据。
进一步地,所述处理器602还用于:
确定所述码流数据中是否存在伪起始码;
如果存在,则对所述码流数据进行去伪起始码操作。
进一步地,所述处理器602对所述码流数据进行去伪起始码操作时,具体用于:
在所述码流数据除起始码以外的数据中插入预设去伪数据,以使插入预设去伪数据后的码流数据与所述起始码不相同。
进一步地,所述预设去伪数据包括整字节数据或非整字节数据。
进一步地,所述预设去伪数据包括非整字节数据,所述处理器602还用于:
在插入预设去伪数据的码流数据的结尾添加指定数值,以进行整字节对齐。
进一步地,所述处理器602还用于:
当所述码流数据中数据包级数据的长度小于预设长度时,在所述码流数据的数据包级数据的结尾添加预设数值,以使所述码流数据中所述数据包级数据 的长度等于所述预设长度。
本发明实施例中,数据编码设备可以获取待处理的点云数据,确定所述点云数据的不同层级,并对每一层级数据添加标识信息,以及根据所述点云数据的不同层级对所述点云数据进行编码得到码流数据。通过这种实施方式,可以提高编码效率,有助于解码后随机访问不同层级的点云数据。
请参见图7,图7是本发明实施例提供的一种数据解码设备的结构示意图,具体的,所述数据解码设备包括:存储器701、处理器702以及数据接口703。
所述存储器701可以包括易失性存储器(volatile memory);存储器701也可以包括非易失性存储器(non-volatile memory);存储器701还可以包括上述种类的存储器的组合。所述处理器702可以是中央处理器(central processing unit,CPU)。所述处理器702还可以进一步包括硬件数据编码设备。上述硬件数据编码设备可以是专用集成电路(application-specific integrated circuit,ASIC),可编程逻辑器件(programmable logic device,PLD)或其组合。具体例如可以是复杂可编程逻辑器件(complex programmable logic device,CPLD),现场可编程逻辑门阵列(field-programmable gate array,FPGA)或其任意组合。
进一步地,所述存储器701用于存储程序指令,当程序指令被执行时所述处理器702可以调用存储器701中存储的程序指令,用于执行如下步骤:
接收码流数据;
对所述码流数据进行解码,得到与所述码流数据对应的点云数据;
其中,所述码流数据包括多个第一层级数据,每个所述第一层级数据中包括多个第二层级数据;
所述码流数据还包括用于标识每一层级数据的标识信息,所述标识信息包括起始码和用于标识所述层级数据的所属层级的码字。
进一步地,所述处理器702对所述码流数据进行解码之前,还用于:
检测所述码流数据是否进行了去伪起始码操作;
如果检测结果为是,则对所述码流数据进行去伪起始码的逆操作。
进一步地,所述处理器702检测所述码流数据是否进行了去伪起始码操作时,具体用于:
当检测到在所述码流数据中除起始码以外的数据中包括预设去伪数据时, 确定所述码流数据进行了去伪起始码操作。
进一步地,所述处理器702对所述码流数据进行去伪起始码的逆操作时,具体用于:
获取在所述码流数据中除起始码以外的数据;
删除所述除起始码以外的数据中的预设去伪数据。
进一步地,所述预设去伪数据包括整字节数据或非整字节数据。
进一步地,所述预设去伪数据包括非整字节数据;所述处理器702对所述码流数据进行去伪起始码的逆操作时,具体用于:
获取在所述码流数据中除起始码以外的数据;
删除所述除起始码以外的数据中的预设去伪数据和指定数值。
进一步地,所述码字包括目标数值集合中的其中一个数值;所述处理器702根据解码得到的码字,确定与所述码字对应的点云数据时,具体用于:
根据所述码字的目标数值集合中的其中一个数值,确定所述层级数据的所属层级的类型;
确定与所述层级数据的所属层级的类型对应的点云数据。
进一步地,所述处理器702确定与所述码字对应的点云数据之后,还用于:
访问与所述码字对应的层级数据的点云数据。
进一步地,每个所述第二层级数据中包括一个或多个第三层级数据,所述第三层级数据包括采集设备级数据或数据包级数据。
进一步地,所述第三层级数据包括采集设备级数据;
每个所述第三层级数据包括一个或多个第四层级数据,所述第四层级数据包括数据包级数据。
进一步地,所述第一层级数据包括序列级数据,所述第二层级数据包括采集设备级数据。
进一步地,所述第二层级数据包括一个或多个第三层级数据;所述第三层级数据包括帧级数据。
进一步地,所述标识信息位于所述层级数据的头信息内。
进一步地,用于标识不同层级数据的起始码均相同。
进一步地,用于标识不同层级数据的码字不同。
进一步地,所述多个第二层级数据的码字分别为目标数值集合中的其中一 个数值。
进一步地,所述第二层级数据包括采集设备级数据;
所述目标数值集合中的不同数值用于指示数据来自不同的采集设备。
进一步地,所述第二层级数据包括帧级数据;
所述目标数值集合中的不同数值用于指示帧的不同类型。
进一步地,所述帧的类型包括帧内编码帧或帧间编码帧。
进一步地,根据对所述码流数据解码得到的标识信息,随机访问所述码流数据中的其中一个层级的层级数据。
进一步地,所述处理器702随机访问所述码流数据中的其中一个层级的层级数据时,具体用于:
逐一查找所述码流数据中的起始码,当确认所述起始码后的所述码字指示目标层级数据时,获取所述码字后的层级数据。
本发明实施例中,数据解码设备可以对接收到的码流数据进行解码,得到与所述码流数据对应的包括不同层级数据和标识信息的点云数据。通过这种实施方式,可以实现根据标识信息随机访问所述码流数据中不同层级的数据,提高了数据访问的灵活性。
在本发明的实施例中还提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被处理器执行时实现本发明实施例图4中描述的数据编码方法方式,或图5中描述的数据解码方法方式,也可实现图6所述本发明所对应实施例的数据编码设备,或图7所述本发明所对应实施例的数据解码设备,在此不再赘述。
所述计算机可读存储介质可以是前述任一项实施例所述的设备的内部存储单元,例如设备的硬盘或内存。所述计算机可读存储介质也可以是所述设备的外部存储设备,例如所述设备上配备的插接式硬盘,智能存储卡(Smart Media Card,SMC),安全数字(Secure Digital,SD)卡,闪存卡(Flash Card)等。进一步地,所述计算机可读存储介质还可以既包括所述设备的内部存储单元也包括外部存储设备。所述计算机可读存储介质用于存储所述计算机程序以及所述设备所需的其他程序和数据。所述计算机可读存储介质还可以用于暂时地存储已经输出或者将要输出的数据。
本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程, 是可以通过计算机程序来指令相关的硬件来完成,所述的程序可存储于一计算机可读取存储介质中,该程序在执行时,可包括如上述各方法的实施例的流程。其中,所述的存储介质可为磁碟、光盘、只读存储记忆体(Read-Only Memory,ROM)或随机存储记忆体(Random Access Memory,RAM)等。
以上所揭露的仅为本发明部分实施例而已,当然不能以此来限定本发明之权利范围,因此依本发明权利要求所作的等同变化,仍属本发明所涵盖的范围。

Claims (83)

  1. 一种数据编码方法,其特征在于,包括:
    获取待处理的点云数据;
    对所述点云数据进行编码得到码流数据;
    其中,所述码流数据包括一个或多个第一层级数据,每个所述第一层级数据中包括一个或多个第二层级数据;
    所述码流数据还包括用于标识每一层级数据的标识信息,所述标识信息包括起始码和用于标识所述层级数据的所属层级的码字。
  2. 根据权利要求1所述的方法,其特征在于,
    所述第一层级数据包括序列级数据,所述第二层级数据包括帧级数据。
  3. 根据权利要求2所述的方法,其特征在于,
    每个所述第二层级数据中包括一个或多个第三层级数据,所述第三层级数据包括采集设备级数据或数据包级数据。
  4. 根据权利要求3所述的方法,其特征在于,
    所述第三层级数据包括采集设备级数据;
    每个所述第三层级数据包括一个或多个第四层级数据,所述第四层级数据包括数据包级数据。
  5. 根据权利要求1所述的方法,其特征在于,
    所述第一层级数据包括序列级数据,所述第二层级数据包括采集设备级数据。
  6. 根据权利要求5所述的方法,其特征在于,
    所述第二层级数据包括多个第三层级数据,所述第三层级数据包括帧级数据。
  7. 根据权利要求1所述的方法,其特征在于,
    所述标识信息位于所述层级数据的头信息内。
  8. 根据权利要求1所述的方法,其特征在于,
    用于标识不同层级数据的起始码均相同。
  9. 根据权利要求1所述的方法,其特征在于,
    用于标识不同层级数据的码字不同。
  10. 根据权利要求1所述的方法,其特征在于,
    所述多个第二层级数据的码字分别为目标数值集合中的其中一个数值。
  11. 根据权利要求10所述的方法,其特征在于,
    所述第二层级数据包括采集设备级数据;
    所述目标数值集合中的不同数值用于指示数据来自不同的采集设备。
  12. 根据权利要求10所述的方法,其特征在于,
    所述第二层级数据包括帧级数据;
    所述目标数值集合中的不同数值用于指示帧的不同类型。
  13. 根据权利要求12所述的方法,其特征在于,
    所述帧的类型包括帧内编码帧或帧间编码帧。
  14. 根据权利要求1所述的方法,其特征在于,
    所述起始码为二进制数据,所述码字为二进制数据。
  15. 根据权利要求1所述的方法,其特征在于,所述方法还包括:
    确定所述码流数据中是否存在伪起始码;
    如果存在,则对所述码流数据进行去伪起始码操作。
  16. 根据权利要求15所述的方法,其特征在于,所述对所述码流数据进行去伪起始码操作,包括:
    在所述码流数据除起始码以外的数据中插入预设去伪数据,以使插入预设去伪数据后的码流数据与所述起始码不相同。
  17. 根据权利要求16所述的方法,其特征在于,
    所述预设去伪数据包括整字节数据或非整字节数据。
  18. 根据权利要求16所述的方法,其特征在于,所述预设去伪数据包括非整字节数据,所述方法还包括:
    在插入预设去伪数据的码流数据的结尾添加指定数值,以进行整字节对齐。
  19. 根据权利要求1所述的方法,其特征在于,所述方法还包括:
    当所述码流数据中数据包级数据的长度小于预设长度时,在所述码流数据的数据包级数据的结尾添加预设数值,以使所述码流数据中所述数据包级数据的长度等于所述预设长度。
  20. 一种数据解码方法,其特征在于,包括:
    接收码流数据;
    对所述码流数据进行解码,得到与所述码流数据对应的点云数据;
    其中,所述码流数据包括多个第一层级数据,每个所述第一层级数据中包括多个第二层级数据;
    所述码流数据还包括用于标识每一层级数据的标识信息,所述标识信息包括起始码和用于标识所述层级数据的所属层级的码字。
  21. 根据权利要求20所述的方法,其特征在于,所述对所述码流数据进行解码之前,还包括:
    检测所述码流数据是否进行了去伪起始码操作;
    如果检测结果为是,则对所述码流数据进行去伪起始码的逆操作。
  22. 根据权利要求21所述的方法,其特征在于,所述检测所述码流数据是否进行了去伪起始码操作,包括:
    当检测到在所述码流数据中除起始码以外的数据中包括预设去伪数据时,确定所述码流数据进行了去伪起始码操作。
  23. 根据权利要求21所述的方法,其特征在于,所述对所述码流数据进行去伪起始码的逆操作,包括:
    获取在所述码流数据中除起始码以外的数据;
    删除所述除起始码以外的数据中的预设去伪数据。
  24. 根据权利要求23所述的方法,其特征在于,
    所述预设去伪数据包括整字节数据或非整字节数据。
  25. 根据权利要求23所述的方法,其特征在于,所述预设去伪数据包括非整字节数据;所述对所述码流数据进行去伪起始码的逆操作,包括:
    获取在所述码流数据中除起始码以外的数据;
    删除所述除起始码以外的数据中的预设去伪数据和指定数值。
  26. 根据权利要求20所述的方法,其特征在于,所述码字包括目标数值集合中的其中一个数值;所述根据解码得到的码字,确定与所述码字对应的点云数据,包括:
    根据所述码字的目标数值集合中的其中一个数值,确定所述层级数据的所属层级的类型;
    确定与所述层级数据的所属层级的类型对应的点云数据。
  27. 根据权利要求26所述的方法,其特征在于,所述确定与所述码字对应的点云数据之后,还包括:
    访问与所述码字对应的层级数据的点云数据。
  28. 根据权利要求20所述的方法,其特征在于,
    所述第一层级数据包括序列级数据,所述第二层级数据包括帧级数据。
  29. 根据权利要求28所述的方法,其特征在于,
    每个所述第二层级数据中包括一个或多个第三层级数据,所述第三层级数据包括采集设备级数据或数据包级数据。
  30. 根据权利要求29所述的方法,其特征在于,
    所述第三层级数据包括采集设备级数据;
    每个所述第三层级数据包括一个或多个第四层级数据,所述第四层级数据包括数据包级数据。
  31. 根据权利要求20所述的方法,其特征在于,
    所述第一层级数据包括序列级数据,所述第二层级数据包括采集设备级数据。
  32. 根据权利要求31所述的方法,其特征在于,
    所述第二层级数据包括一个或多个第三层级数据;所述第三层级数据包括帧级数据。
  33. 根据权利要求20所述的方法,其特征在于,
    所述标识信息位于所述层级数据的头信息内。
  34. 根据权利要求20所述的方法,其特征在于,
    用于标识不同层级数据的起始码均相同。
  35. 根据权利要求20所述的方法,其特征在于,
    用于标识不同层级数据的码字不同。
  36. 根据权利要求20所述的方法,其特征在于,
    所述多个第二层级数据的码字分别为目标数值集合中的其中一个数值。
  37. 根据权利要求36所述的方法,其特征在于,
    所述第二层级数据包括采集设备级数据;
    所述目标数值集合中的不同数值用于指示数据来自不同的采集设备。
  38. 根据权利要求36所述的方法,其特征在于,
    所述第二层级数据包括帧级数据;
    所述目标数值集合中的不同数值用于指示帧的不同类型。
  39. 根据权利要求38所述的方法,其特征在于,
    所述帧的类型包括帧内编码帧或帧间编码帧。
  40. 根据权利要求20所述的方法,其特征在于,所述方法还包括:
    根据对所述码流数据解码得到的标识信息,随机访问所述码流数据中的其中一个层级的层级数据。
  41. 根据权利要求40所述的方法,其特征在于,所述随机访问所述码流数据中的其中一个层级的层级数据,包括:
    逐一查找所述码流数据中的起始码,当确认所述起始码后的所述码字指示目标层级数据时,获取所述码字后的层级数据。
  42. 一种数据编码设备,其特征在于,包括:存储器和处理器,
    所述存储器,用于存储程序指令;
    所述处理器,用于调用所述程序指令,当所述程序指令被执行时,用于执行以下操作:
    获取待处理的点云数据;
    对所述点云数据进行编码得到码流数据;
    其中,所述码流数据包括一个或多个第一层级数据,每个所述第一层级数据中包括一个或多个第二层级数据;
    所述码流数据还包括用于标识每一层级数据的标识信息,所述标识信息包括起始码和用于标识所述层级数据的所属层级的码字。
  43. 根据权利要求42所述的设备,其特征在于,
    所述第一层级数据包括序列级数据,所述第二层级数据包括帧级数据。
  44. 根据权利要求43所述的设备,其特征在于,
    每个所述第二层级数据中包括一个或多个第三层级数据,所述第三层级数据包括采集设备级数据或数据包级数据。
  45. 根据权利要求44所述的设备,其特征在于,
    所述第三层级数据包括采集设备级数据;
    每个所述第三层级数据包括一个或多个第四层级数据,所述第四层级数据包括数据包级数据。
  46. 根据权利要求42所述的设备,其特征在于,
    所述第一层级数据包括序列级数据,所述第二层级数据包括采集设备级数据。
  47. 根据权利要求46所述的设备,其特征在于,
    所述第二层级数据包括多个第三层级数据,所述第三层级数据包括帧级数据。
  48. 根据权利要求42所述的设备,其特征在于,
    所述标识信息位于所述层级数据的头信息内。
  49. 根据权利要求42所述的设备,其特征在于,
    用于标识不同层级数据的起始码均相同。
  50. 根据权利要求42所述的设备,其特征在于,
    用于标识不同层级数据的码字不同。
  51. 根据权利要求42所述的设备,其特征在于,
    所述多个第二层级数据的码字分别为目标数值集合中的其中一个数值。
  52. 根据权利要求51所述的设备,其特征在于,
    所述第二层级数据包括采集设备级数据;
    所述目标数值集合中的不同数值用于指示数据来自不同的采集设备。
  53. 根据权利要求51所述的设备,其特征在于,
    所述第二层级数据包括帧级数据;
    所述目标数值集合中的不同数值用于指示帧的不同类型。
  54. 根据权利要求53所述的设备,其特征在于,
    所述帧的类型包括帧内编码帧或帧间编码帧。
  55. 根据权利要求42所述的设备,其特征在于,
    所述起始码为二进制数据,所述码字为二进制数据。
  56. 根据权利要求42所述的设备,其特征在于,所述处理器还用于:
    确定所述码流数据中是否存在伪起始码;
    如果存在,则对所述码流数据进行去伪起始码操作。
  57. 根据权利要求56所述的设备,其特征在于,所述处理器对所述码流数据进行去伪起始码操作时,具体用于:
    在所述码流数据除起始码以外的数据中插入预设去伪数据,以使插入预设去伪数据后的码流数据与所述起始码不相同。
  58. 根据权利要求57所述的设备,其特征在于,
    所述预设去伪数据包括整字节数据或非整字节数据。
  59. 根据权利要求57所述的设备,其特征在于,所述预设去伪数据包括非整字节数据,所述处理器还用于:
    在插入预设去伪数据的码流数据的结尾添加指定数值,以进行整字节对齐。
  60. 根据权利要求42所述的设备,其特征在于,所述处理器还用于:
    当所述码流数据中数据包级数据的长度小于预设长度时,在所述码流数据的数据包级数据的结尾添加预设数值,以使所述码流数据中所述数据包级数据的长度等于所述预设长度。
  61. 一种数据解码设备,其特征在于,包括:存储器和处理器,
    所述存储器,用于存储程序指令;
    所述处理器,用于调用所述程序指令,当所述程序指令被执行时,用于执行以下操作:
    接收码流数据;
    对所述码流数据进行解码,得到与所述码流数据对应的点云数据;
    其中,所述码流数据包括多个第一层级数据,每个所述第一层级数据中包括多个第二层级数据;
    所述码流数据还包括用于标识每一层级数据的标识信息,所述标识信息包括起始码和用于标识所述层级数据的所属层级的码字。
  62. 根据权利要求61所述的设备,其特征在于,所述处理器对所述码流数据进行解码之前,还用于:
    检测所述码流数据是否进行了去伪起始码操作;
    如果检测结果为是,则对所述码流数据进行去伪起始码的逆操作。
  63. 根据权利要求62所述的设备,其特征在于,所述处理器检测所述码流数据是否进行了去伪起始码操作时,具体用于:
    当检测到在所述码流数据中除起始码以外的数据中包括预设去伪数据时, 确定所述码流数据进行了去伪起始码操作。
  64. 根据权利要求62所述的设备,其特征在于,所述处理器对所述码流数据进行去伪起始码的逆操作时,具体用于:
    获取在所述码流数据中除起始码以外的数据;
    删除所述除起始码以外的数据中的预设去伪数据。
  65. 根据权利要求64所述的设备,其特征在于,
    所述预设去伪数据包括整字节数据或非整字节数据。
  66. 根据权利要求64所述的设备,其特征在于,所述预设去伪数据包括非整字节数据;所述处理器对所述码流数据进行去伪起始码的逆操作时,具体用于:
    获取在所述码流数据中除起始码以外的数据;
    删除所述除起始码以外的数据中的预设去伪数据和指定数值。
  67. 根据权利要求61所述的设备,其特征在于,所述码字包括目标数值集合中的其中一个数值;所述处理器根据解码得到的码字,确定与所述码字对应的点云数据时,具体用于:
    根据所述码字的目标数值集合中的其中一个数值,确定所述层级数据的所属层级的类型;
    确定与所述层级数据的所属层级的类型对应的点云数据。
  68. 根据权利要求67所述的设备,其特征在于,所述处理器确定与所述码字对应的点云数据之后,还用于:
    访问与所述码字对应的层级数据的点云数据。
  69. 根据权利要求61所述的设备,其特征在于,
    所述第一层级数据包括序列级数据,所述第二层级数据包括帧级数据。
  70. 根据权利要求69所述的设备,其特征在于,
    每个所述第二层级数据中包括一个或多个第三层级数据,所述第三层级数据包括采集设备级数据或数据包级数据。
  71. 根据权利要求70所述的设备,其特征在于,
    所述第三层级数据包括采集设备级数据;
    每个所述第三层级数据包括一个或多个第四层级数据,所述第四层级数据包括数据包级数据。
  72. 根据权利要求61所述的设备,其特征在于,
    所述第一层级数据包括序列级数据,所述第二层级数据包括采集设备级数据。
  73. 根据权利要求72所述的设备,其特征在于,
    所述第二层级数据包括一个或多个第三层级数据;所述第三层级数据包括帧级数据。
  74. 根据权利要求61所述的设备,其特征在于,
    所述标识信息位于所述层级数据的头信息内。
  75. 根据权利要求61所述的设备,其特征在于,
    用于标识不同层级数据的起始码均相同。
  76. 根据权利要求61所述的设备,其特征在于,
    用于标识不同层级数据的码字不同。
  77. 根据权利要求61所述的设备,其特征在于,
    所述多个第二层级数据的码字分别为目标数值集合中的其中一个数值。
  78. 根据权利要求77所述的设备,其特征在于,
    所述第二层级数据包括采集设备级数据;
    所述目标数值集合中的不同数值用于指示数据来自不同的采集设备。
  79. 根据权利要求77所述的设备,其特征在于,
    所述第二层级数据包括帧级数据;
    所述目标数值集合中的不同数值用于指示帧的不同类型。
  80. 根据权利要求79所述的设备,其特征在于,
    所述帧的类型包括帧内编码帧或帧间编码帧。
  81. 根据权利要求61所述的设备,其特征在于,所述处理器还用于:
    根据对所述码流数据解码得到的标识信息,随机访问所述码流数据中的其中一个层级的层级数据。
  82. 根据权利要求81所述的设备,其特征在于,所述处理器随机访问所述码流数据中的其中一个层级的层级数据时,具体用于:
    逐一查找所述码流数据中的起始码,当确认所述起始码后的所述码字指示目标层级数据时,获取所述码字后的层级数据。
  83. 一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,其特征在于,所述计算机程序被处理器执行时实现如权利要求1至41任一项所述方法。
PCT/CN2019/085152 2019-04-30 2019-04-30 一种数据编码、数据解码方法、设备及存储介质 WO2020220249A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201980008420.5A CN111684804B (zh) 2019-04-30 2019-04-30 一种数据编码、数据解码方法、设备及存储介质
PCT/CN2019/085152 WO2020220249A1 (zh) 2019-04-30 2019-04-30 一种数据编码、数据解码方法、设备及存储介质

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2019/085152 WO2020220249A1 (zh) 2019-04-30 2019-04-30 一种数据编码、数据解码方法、设备及存储介质

Publications (1)

Publication Number Publication Date
WO2020220249A1 true WO2020220249A1 (zh) 2020-11-05

Family

ID=72433223

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/085152 WO2020220249A1 (zh) 2019-04-30 2019-04-30 一种数据编码、数据解码方法、设备及存储介质

Country Status (2)

Country Link
CN (1) CN111684804B (zh)
WO (1) WO2020220249A1 (zh)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP4369712A1 (en) * 2021-08-25 2024-05-15 Huawei Technologies Co., Ltd. Video transmission method and apparatus, and electronic device

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101257624A (zh) * 2007-02-27 2008-09-03 华为技术有限公司 实现随机访问的方法及解码器
CN108369751A (zh) * 2015-12-14 2018-08-03 松下电器(美国)知识产权公司 三维数据编码方法、解码方法、编码装置、解码装置
CN109196559A (zh) * 2016-05-28 2019-01-11 微软技术许可有限责任公司 动态体素化点云的运动补偿压缩
US20190075320A1 (en) * 2017-09-06 2019-03-07 Apple Inc. Point cloud geometry compression
WO2019073939A1 (en) * 2017-10-12 2019-04-18 Mitsubishi Electric Corporation POINT CLOUD ENCODER

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1209703C (zh) * 2003-10-16 2005-07-06 上海广电(集团)有限公司中央研究院 一种可随机访问数据流的组织方法及其对应的解码方法
JP5023739B2 (ja) * 2007-02-28 2012-09-12 ソニー株式会社 画像情報符号化装置及び符号化方法
JP5161936B2 (ja) * 2010-08-11 2013-03-13 株式会社パスコ データ解析装置、データ解析方法、及びプログラム
CN102802023B (zh) * 2012-08-29 2014-08-27 上海国茂数字技术有限公司 一种快速防止出现伪起始码的方法及装置
CN113347447B (zh) * 2016-02-09 2022-10-04 弗劳恩霍夫应用研究促进协会 解码器、编码器、方法、网络设备以及可读存储介质
US10694210B2 (en) * 2016-05-28 2020-06-23 Microsoft Technology Licensing, Llc Scalable point cloud compression with transform, and corresponding decompression
WO2018016168A1 (ja) * 2016-07-19 2018-01-25 パナソニック インテレクチュアル プロパティ コーポレーション オブ アメリカ 三次元データ作成方法、三次元データ送信方法、三次元データ作成装置及び三次元データ送信装置
CN106407408B (zh) * 2016-09-22 2019-08-16 北京数字绿土科技有限公司 一种海量点云数据的空间索引构建方法及装置
CN108009979B (zh) * 2017-12-15 2021-02-26 湖北大学 基于时空数据融合的三维点云压缩存储方法及系统

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101257624A (zh) * 2007-02-27 2008-09-03 华为技术有限公司 实现随机访问的方法及解码器
CN108369751A (zh) * 2015-12-14 2018-08-03 松下电器(美国)知识产权公司 三维数据编码方法、解码方法、编码装置、解码装置
CN109196559A (zh) * 2016-05-28 2019-01-11 微软技术许可有限责任公司 动态体素化点云的运动补偿压缩
US20190075320A1 (en) * 2017-09-06 2019-03-07 Apple Inc. Point cloud geometry compression
WO2019073939A1 (en) * 2017-10-12 2019-04-18 Mitsubishi Electric Corporation POINT CLOUD ENCODER

Also Published As

Publication number Publication date
CN111684804B (zh) 2022-05-13
CN111684804A (zh) 2020-09-18

Similar Documents

Publication Publication Date Title
EP3514969B1 (en) Methods and devices using direct coding in point cloud compression
WO2020248187A1 (zh) 一种点云编码方法、点云解码方法及相关设备
CN111699697B (zh) 一种用于点云处理、解码的方法、设备及存储介质
US10693492B1 (en) Context determination for planar mode in octree-based point cloud coding
US20180189982A1 (en) Attribute mapping to encode and decode 3d models
US9532056B2 (en) Method for adaptive entropy coding of tree structures
US10165305B2 (en) Encoding and decoding transform coefficient sub-blocks in same predetermine order
KR102486255B1 (ko) 포인트 클라우드의 하이브리드 기하학적 코딩
WO2021000334A1 (zh) 一种数据编码、数据解码方法、设备及存储介质
WO2021196029A1 (zh) 一种用于点云编码、解码的方法和设备
US7786903B2 (en) Combinatorial coding/decoding with specified occurrences for electrical computers and digital data processing systems
WO2020220249A1 (zh) 一种数据编码、数据解码方法、设备及存储介质
US20220005229A1 (en) Point cloud attribute encoding method and device, and point cloud attribute decoding method and devcie
CN103873868A (zh) 一种位图数据的压缩方法
WO2021103013A1 (zh) 一种数据编码、数据解码方法、设备及存储介质
CN114492322A (zh) 文本压缩方法、模块、芯片、电子设备和存储介质
US20160079996A1 (en) Compression ratio for a compression engine
CN116193160A (zh) 一种数字水印嵌入方法、装置、设备和介质
GB2624835A (en) Point cloud data frames compression
CN102802023B (zh) 一种快速防止出现伪起始码的方法及装置
KR101890365B1 (ko) 압축된 데이터의 오류를 검출하는 방법 및 장치
van der Meer et al. JPEG File Fragmentation Point Detection using Huffman Code and Quantization Array Validation
CN112134644A (zh) 编码方法、装置及存储介质
CN111342844B (zh) 一种基于lzw编码与改进游程编码的雷达数据无损压缩及解压方法
CN114070471B (zh) 一种测试数据包传输方法、装置、系统、设备和介质

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: 19927109

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: 19927109

Country of ref document: EP

Kind code of ref document: A1