WO2025138048A1 - Coding method, decoding method, code stream, coder, decoder and storage medium - Google Patents
Coding method, decoding method, code stream, coder, decoder and storage medium Download PDFInfo
- Publication number
- WO2025138048A1 WO2025138048A1 PCT/CN2023/142978 CN2023142978W WO2025138048A1 WO 2025138048 A1 WO2025138048 A1 WO 2025138048A1 CN 2023142978 W CN2023142978 W CN 2023142978W WO 2025138048 A1 WO2025138048 A1 WO 2025138048A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- layers
- value
- point cloud
- transformation
- coefficient
- 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.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T9/00—Image coding
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N19/00—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
- H04N19/10—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
- H04N19/102—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
- H04N19/12—Selection from among a plurality of transforms or standards, e.g. selection between discrete cosine transform [DCT] and sub-band transform or selection between H.263 and H.264
Definitions
- the embodiments of the present application relate to the field of video coding and decoding technology, and in particular, to a coding and decoding method, a bit stream, an encoder, a decoder, and a storage medium.
- the coded AC coefficient value obtained by the transform gradually decreases, so that in the last few layers of the radar point cloud, a large number of 0s appear in the coded AC coefficient value at this time.
- the encoding of the AC coefficient values of the last few layers will result in a waste of code stream, reducing the coding efficiency.
- the embodiments of the present application provide a coding and decoding method, a bit stream, an encoder, a decoder and a storage medium, which can improve the coding and decoding efficiency of RAHT transformation.
- an embodiment of the present application provides a decoding method, which is applied to a decoder, and the method includes:
- the first decoding parameter indicates that k transform layers of the current point cloud are to be skipped and decoded
- one or more AC coefficient residual values of the k transform layers are determined to be preset values; wherein k is an integer greater than zero;
- the reconstructed point cloud of the current point cloud is determined according to the residual values of the AC coefficients of the k transformation layers and the residual values of the AC coefficients of other transformation layers.
- an embodiment of the present application provides an encoding method, which is applied to an encoder, and the method includes:
- the first encoding parameter indicates that the k transformation layers of the current point cloud are to be skip-encoded, determining one or more AC coefficient residual values of the k transformation layers to be preset values; wherein k is an integer greater than zero;
- One or more AC coefficient residual values of k transformation layers are coded according to preset values, and the obtained coded bits are written into the bit stream.
- an embodiment of the present application provides a code stream, which is generated by bit encoding according to information to be encoded; wherein the information to be encoded includes at least one of the following:
- the AC coefficient residual values of multiple transformation layers corresponding to the current point cloud, the DC coefficient value of the root node of the current point cloud, the AC coefficient residual values of k transformation layers of the current point cloud are preset values, the AC coefficient residual values of other transformation layers other than the k transformation layers in the current point cloud, the value of the first coding parameter, the value of the second coding parameter and the value of the third coding parameter;
- the first coding parameter is used to indicate whether to perform jump coding on the k transformation layers of the current point cloud
- the second coding parameter is used to indicate whether to turn on jump coding of the current point cloud
- the third coding parameter is used to indicate whether to perform jump coding on the k transformation layers of the current point cloud to be processed.
- an encoder including a first determining unit and an encoding unit, wherein:
- a first determining unit is configured to determine a value of a first encoding parameter; when the first encoding parameter indicates that k transformation layers of the current point cloud are to be skip-encoded, one or more AC coefficient residual values of the k transformation layers are determined to be preset values; wherein k is an integer greater than zero;
- the encoding unit is configured to encode one or more AC coefficient residual values of k transformation layers according to preset values, and write the obtained encoding bits into the bit stream.
- an encoder including a first memory and a first processor, wherein:
- a first memory for storing a computer program that can be run on the first processor
- the first processor is configured to execute the method according to the second aspect when running the computer program.
- an embodiment of the present application provides a decoder, including a second determination unit, a decoding unit, and a reconstruction unit, wherein:
- the second determination unit is configured to determine a value of the first decoding parameter; when the first decoding parameter indicates to perform skip decoding on k transformation layers of the current point cloud, determine one or more AC coefficient residual values of the k transformation layers to be a preset value; wherein k is an integer greater than zero;
- a decoding unit configured to decode the bit stream and determine residual values of AC coefficients of other transform layers other than k transform layers in the current point cloud
- the reconstruction unit is configured to determine the reconstructed point cloud of the current point cloud according to the residual values of the AC coefficients of the k transformation layers and the residual values of the AC coefficients of other transformation layers.
- an embodiment of the present application provides a decoder, including a second memory and a second processor, wherein:
- a second memory for storing a computer program that can be run on a second processor
- the second processor is configured to execute the method described in the first aspect when running the computer program.
- an embodiment of the present application provides a computer-readable storage medium, which stores a computer program.
- the computer program When executed by at least one processor, it implements the method described in the first aspect or the method described in the second aspect.
- Point Cloud is a three-dimensional representation of the surface of an object.
- Point cloud (data) on the surface of an object can be collected through acquisition equipment such as photoelectric radar, lidar, laser scanner, and multi-view camera.
- a point cloud is a set of irregularly distributed discrete points in space that express the spatial structure and surface properties of a three-dimensional object or scene.
- FIG1A shows a three-dimensional point cloud image
- FIG1B shows a partial magnified view of the three-dimensional point cloud image. It can be seen that the point cloud surface is composed of densely distributed points.
- Two-dimensional images have information expressed at each pixel point, and the distribution is regular, so there is no need to record its position information additionally; however, the distribution of points in point clouds in three-dimensional space is random and irregular, so it is necessary to record the position of each point in space in order to fully express a point cloud.
- each position in the acquisition process has corresponding attribute information, usually RGB color values, and the color value reflects the color of the object; for point clouds, in addition to color information, the attribute information corresponding to each point is also commonly the reflectance value, which reflects the surface material of the object. Therefore, point cloud data usually includes the position information of the point and the attribute information of the point. Among them, the position information of the point can also be called the geometric information of the point.
- the geometric information of the point can be the three-dimensional coordinate information of the point (x, y, z).
- the attribute information of the point can include color information and/or reflectivity, etc.
- reflectivity can be one-dimensional reflectivity information (r); color information can be information on any color space, or color information can also be three-dimensional color information, such as RGB information.
- R represents red (Red, R)
- G represents green (Green, G)
- B blue (Blue, B).
- the color information may be luminance and chrominance (YCbCr, YUV) information, where Y represents brightness (Luma), Cb (U) represents blue color difference, and Cr (V) represents red color difference.
- Figure 2A and Figure 2B a point cloud image and its corresponding data storage format are shown.
- Figure 2A provides six viewing angles of the point cloud image
- Figure 2B consists of a file header information part and a data part.
- the header information includes the data format, data representation type, the total number of point cloud points, and the content represented by the point cloud.
- the point cloud is in the ".ply" format, represented by ASCII code, with a total number of 207242 points, and each point has three-dimensional coordinate information (x, y, z) and three-dimensional color information (r, g, b).
- Point clouds can be divided into the following categories according to the way they are obtained:
- Dynamic point cloud The object is moving, but the device that obtains the point cloud is stationary;
- Category 2 Point cloud perceived by the human eye, which can be used in point cloud application scenarios such as digital cultural heritage, free viewpoint broadcasting, 3D immersive communication, and 3D immersive interaction.
- Point clouds can flexibly and conveniently express the spatial structure and surface properties of three-dimensional objects or scenes. Point clouds are obtained by directly sampling real objects, so they can provide a strong sense of reality while ensuring accuracy. Therefore, they are widely used, including virtual reality games, computer-aided design, geographic information systems, automatic navigation systems, digital cultural heritage, free viewpoint broadcasting, three-dimensional immersive remote presentation, and three-dimensional reconstruction of biological tissues and organs.
- Point clouds can be collected mainly through the following methods: computer generation, 3D laser scanning, 3D photogrammetry, etc.
- Computers can generate point clouds of virtual three-dimensional objects and scenes; 3D laser scanning can obtain point clouds of static real-world three-dimensional objects or scenes, and can obtain millions of point clouds per second; 3D photogrammetry can obtain point clouds of dynamic real-world three-dimensional objects or scenes, and can obtain tens of millions of point clouds per second.
- 3D photogrammetry can obtain point clouds of dynamic real-world three-dimensional objects or scenes, and can obtain tens of millions of point clouds per second.
- the number of points in each point cloud frame is 700,000, and each point has coordinate information xyz (float) and color information RGB (uchar).
- point cloud compression has become a key issue in promoting the development of the point cloud industry.
- the point cloud is a collection of massive points, storing the point cloud will not only consume a lot of memory, but also be inconvenient for transmission. There is also not enough bandwidth to support direct transmission of the point cloud at the network layer without compression. Therefore, the point cloud needs to be compressed.
- the point cloud coding framework that can compress point clouds can be the geometry-based point cloud compression (G-PCC) codec framework or the video-based point cloud compression (V-PCC) codec framework provided by the Moving Picture Experts Group (MPEG), or the AVS-PCC codec framework provided by AVS.
- the G-PCC codec framework can be used to compress the first type of static point cloud and the third type of dynamically acquired point cloud, which can be based on the point cloud compression test platform (Test Model Compression 13, TMC13), and the V-PCC codec framework can be used to compress the second type of dynamic point cloud, which can be based on the point cloud compression test platform (Test Model Compression 2, TMC2). Therefore, the G-PCC codec framework is also called the point cloud codec TMC13, and the V-PCC codec framework is also called the point cloud codec TMC2.
- FIG3 is a schematic diagram of a network architecture of point cloud encoding and decoding.
- the network architecture includes one or more electronic devices 13 to 1N and a communication network 01, wherein the electronic devices 13 to 1N can perform video interaction through the communication network 01.
- the electronic device can be various types of devices with point cloud encoding and decoding functions.
- the electronic device can include a mobile phone, a tablet computer, a personal computer, a personal digital assistant, a navigator, a digital phone, a video phone, a television, a sensor device, a server, etc., which is not limited by the embodiment of the present application.
- the decoder or encoder in the embodiment of the present application can be the above-mentioned electronic device.
- the electronic device in the embodiment of the present application has a point cloud encoding and decoding function, generally including a point cloud encoder (ie, encoder) and a point cloud decoder (ie, decoder).
- a point cloud encoder ie, encoder
- a point cloud decoder ie, decoder
- the point cloud data is first divided into multiple slices by slice division.
- the geometric information of the point cloud and the attribute information corresponding to each point are encoded separately.
- FIG4 is a schematic diagram of a composition framework of a G-PCC encoder.
- the G-PCC encoding framework for the code to be encoded
- the point cloud data is first divided into multiple slices through slice division.
- the geometric information of the point cloud and the attribute information corresponding to each point cloud are encoded separately.
- the coordinate transformation of the geometric information is performed so that all the point clouds are contained in a Bounding Box, and then quantization is performed.
- This step of quantization mainly plays a role in scaling. Due to the quantization rounding, the geometric information of a part of the point cloud is the same, so it is decided whether to remove duplicate points based on parameters.
- the Trisoup does not need to divide the point cloud into unit cubes with a side length of 1 ⁇ 1 ⁇ 1 step by step. Instead, the division stops when the sub-block (Block) has a side length of W.
- the surface and the twelve edges of the block are used to obtain at most twelve intersections (Vertex).
- the Vertex is arithmetically encoded (surface fitting is performed based on the intersections) to generate a binary geometric bit stream, i.e., a geometric code stream. Vertex is also used to implement the process of geometric reconstruction, and the reconstructed set information is used when encoding the attributes of the point cloud.
- the attribute encoding process After the geometric encoding is completed and the geometric information is reconstructed, color conversion is performed to convert the color information (i.e., attribute information) from the RGB color space to the YUV color space. Then, the point cloud is recolored using the reconstructed geometric information so that the unencoded attribute information corresponds to the reconstructed geometric information. Attribute encoding is mainly performed on color information. In the color information encoding process, there are two main transformation methods: one is the distance-based lifting transformation that relies on LOD division, and the other is direct RAHT transformation. Both methods will convert color information from the spatial domain to the frequency domain, and obtain high-frequency coefficients and low-frequency coefficients through transformation.
- the coefficients are quantized (i.e., quantized coefficients).
- the geometric encoding data after octree division and surface fitting and the attribute encoding data processed by quantization coefficients are sliced and synthesized, and the Vertex coordinates of each Block are encoded in turn (i.e., arithmetic coding) to generate a binary attribute bit stream, i.e., attribute code stream.
- FIG5 is a schematic diagram of the composition framework of a G-PCC decoder.
- the geometric bit stream and the attribute bit stream in the binary code stream are first decoded independently.
- the geometric information of the point cloud is obtained through arithmetic decoding-octree synthesis-surface fitting-reconstruction of geometry-inverse coordinate conversion;
- the attribute information of the point cloud is obtained through arithmetic decoding-inverse quantization-LOD-based lifting inverse transform or RAHT-based inverse transform-inverse color conversion, and the three-dimensional image model of the point cloud data to be encoded is restored based on the geometric information and attribute information.
- Figure 6 is a schematic diagram of the RAHT encoding process.
- intra-frame prediction or inter-frame prediction can be performed.
- the original point cloud is upsampled and predicted to obtain a predicted point cloud, and then a RAHT transform is performed to determine the predicted AC coefficient;
- a reference point cloud can be obtained based on the adjacent frames of the original point cloud, and then a RAHT transform can also determine the predicted AC coefficient.
- Performing a RAHT transform on the original point cloud can determine the DC coefficient and the original AC coefficient of the root node; subtracting the original AC coefficient from the predicted AC coefficient can obtain a predicted residual, and after quantizing and entropy encoding the predicted residual, an attribute code stream can be generated.
- a video frame can be understood as an image.
- the current frame can be understood as the current image
- the reference frame can be understood as the reference image.
- the method may further include: determining that all AC coefficient residual values of k transformation layers are preset values. That is, in an embodiment of the present application, for determining one or more AC coefficient residual values of k transformation layers, when determining to jump decode the k transformation layers of the current point cloud, it is also possible to determine that all AC coefficient residual values of the k transformation layers are preset values.
- the method may further include: dividing the points in the current point cloud into layers, determining multiple transformation layers corresponding to the current point cloud and the root node of the current point cloud; wherein the multiple transformation layers include k transformation layers and other transformation layers.
- the points in the current point cloud can be divided into layers based on the octree structure to obtain multiple transformation layers. Specifically, for the divided octree structure, each layer can be transformed from the root node to the child node from top to bottom.
- the method may also include: setting the k transformation layers to be the last k transformation layers from the root node from top to bottom in the multiple transformation layers.
- the AC coefficient residual value is located in the attribute code stream unit of the code stream.
- the method may include: decoding the attribute code stream unit in the code stream to determine the AC coefficient residual value of other transform layers.
- the multiple transformation layers corresponding to the current point cloud may include k transformation layers and other transformation layers except the k transformation layers.
- the reconstructed point cloud of the current point cloud is determined according to the residual values of the AC coefficients of the k transformation layers and the residual values of the AC coefficients of the other transformation layers, that is, according to the residual values of the AC coefficients of the multiple transformation layers.
- the method may further include:
- the method may also include: decoding the attribute code stream unit in the code stream to determine the AC coefficient residual values of the multiple transform layers.
- the first decoding parameter and the AC coefficient residual value are both located in the attribute code stream unit of the code stream.
- the method may also include: in the attribute code stream unit, determining that the field corresponding to the first decoding parameter is located after the field corresponding to the AC coefficient residual value.
- the decoding end first decodes the value of the first decoding parameter to determine the number of transformation layers of the AC coefficient residual value that needs to be decoded, and then decodes the AC coefficient residual value that needs to be decoded according to the indication of the first decoding parameter, and restores the AC coefficient residual values of the k transformation layers for performing jump decoding to 0.
- the method may further include: decoding the code stream and determining the DC coefficient value of the root node of the current point cloud.
- the method may also include: decoding the attribute bitstream unit in the bitstream to determine the DC coefficient value of the root node of the current point cloud.
- the DC coefficient value can be directly passed to the next layer at each transformation, but the AC coefficient value needs to be residually calculated, and the AC coefficient residual value of each layer needs to be quantized and entropy encoded.
- the attribute value of the point can be directly passed to the next layer as the DC coefficient value.
- the method further includes: saving the DC coefficient value of the root node to the first parameter matrix of the current point cloud.
- the method may further include: saving the residual values of the AC coefficients of k transformation layers and the residual values of the AC coefficients of other transformation layers to the first parameter matrix of the current point cloud.
- the residual values of the AC coefficients of multiple transformation layers may be saved to the first parameter matrix of the current point cloud.
- the decoding end parses the bitstream and first decodes the first decoding parameter at the end of the bitstream. If the decoded value of the first decoding parameter is k, the residual values of the AC coefficients of the k transform layers are all decoded as 0, and the residual values of the AC coefficients of other transform layers are decoded normally and stored in the first parameter matrix; if the decoded value of the first decoding parameter is 0, all the residual values of the AC coefficients of multiple transform layers are decoded and stored in the first parameter matrix. It should be noted that in the process of decoding the residual values of the AC coefficients, the DC coefficient value of the decoded root node will also be stored in the first parameter matrix.
- the method may further include: performing inverse quantization processing on parameter values in the first parameter matrix of the current point cloud.
- both the DC coefficient values and the AC coefficient residual values in the first parameter matrix need to be dequantized.
- the method may include:
- S1401 determine attribute prediction values of points in multiple transformation layers.
- the component to be processed may include at least one of the first color component, the second color component and the third color component.
- the AC coefficient prediction value can be determined based on intra-frame prediction or inter-frame prediction, and then the AC coefficient reconstruction value can be determined based on the AC coefficient prediction value and the dequantized AC coefficient residual value. After the AC coefficient reconstruction value is subjected to RAHT inverse transform, To obtain the corresponding reconstructed attribute value.
- the specific implementation of the program on the decoding end is as follows.
- the flag .skip_raht_enabled_flag is decoded in the attribute parameter set APS. This flag determines whether the technical solution of the embodiment of the present application is turned on; if it is true, the flag flag in the attribute code stream is first decoded in the code stream and transmitted to the RAHT sub-function. If the decoded flag value is k, the residual value of the AC coefficient of the last k layers of RAHT is restored according to the value of 0 for the next attribute reconstruction; if the decoded flag value is 0, the residual value of the AC coefficient of all layers of RAHT is restored according to the original coding value.
- the residual value of the AC coefficient is stored in the parameter matrix transformPredBuf.
- the embodiment of the present application provides a decoding method, which determines the value of a first decoding parameter; when the first decoding parameter indicates that the k transform layers of the current point cloud are to be skip decoded, determines that one or more residual values of the AC coefficients of the k transform layers are preset values; decodes the code stream to determine the residual values of the AC coefficients of other transform layers other than the k transform layers in the current point cloud; and determines the reconstructed point cloud of the current point cloud based on the residual values of the AC coefficients of the k transform layers and the residual values of the AC coefficients of other transform layers.
- one or more residual values of the AC coefficients of the k transform layers are directly decoded according to the preset values, which can effectively improve the phenomenon that too many 0s appear in the residual values of the AC coefficients of the last few layers in the RAHT transform, thereby improving the encoding and decoding efficiency, and using a flag to record whether the skip decoding operation is performed and on which layers it is performed, thereby improving the reconstruction quality at the average bit rate, and thus improving the encoding and decoding performance of the point cloud.
- FIG18 is a flow chart of a coding method provided in an embodiment of the present application. As shown in FIG18 , the method may include:
- a point cloud encoder hereinafter referred to as "encoder”
- a point cloud encoding method is mainly provided, more specifically, a skip encoding method for RAHT transform coefficients, which can improve the phenomenon that too many 0s appear in the last few layers of encoded AC coefficient values in RAHT transform.
- the first encoding parameter can be used to indicate whether to perform skip encoding on the k transformation layers of the current point cloud.
- the method may include:
- S1901 determining a first generation value for encoding all AC coefficient residual values of k transformation layers, and determining a second generation value for encoding one or more AC coefficient residual values of k transformation layers according to a preset value.
- the value of the first encoding parameter can be determined according to the first generation value and the second generation value. Or it can be said that it is determined whether to perform jump encoding on the k transformation layers of the current point cloud according to the first generation value and the second generation value. Where k is an integer greater than zero.
- the cost value here can be determined according to the cost result of Rate-Distortion Optimization (RDO), or according to the cost result of Sum of Absolute Difference (SAD), or even according to the cost result of Sum of Absolute Transformed Difference (SATD), but no limitation is made here.
- RDO Rate-Distortion Optimization
- SAD Sum of Absolute Difference
- SATD Sum of Absolute Transformed Difference
- bit rate and distortion after coding are in a contradictory relationship. If you want to obtain a higher quality reconstructed video with less distortion, you need to increase the transmission bit rate; however, the bit rate cannot be increased indefinitely. In some cases, you need to reduce the bit rate to ensure the smoothness of video transmission. In order to better improve the efficiency of coding, it is necessary to comprehensively consider the bit rate and distortion and find a compromise between the two so that the distortion is as small as possible under the condition of a fixed bit rate.
- the formula can be expressed as:
- D represents distortion
- R represents bit rate
- Formula (11) is a constrained optimization problem, which can be transformed into the following form using Lagrange multipliers:
- RDcost is the rate-distortion cost
- ⁇ is the Lagrange multiplier. This is the rate-distortion optimization problem in the field of video coding.
- ⁇ D can be represented by the square value of all AC coefficient residual values of k transform layers, which is used to refer to the distortion cost after all these coefficient residual values are not encoded
- Rorg is the bitstream consumption in the coding scheme of the related technology
- the bitrate consumption after all the AC coefficient residual values of k transform layers are not encoded is only 1 bit occupied by the first syntax element (flag bit flag), so ⁇ R represents the difference in bitrate consumption between not encoding and encoding the residual values of k transform layers AC coefficients, that is, the bitstream saved by not encoding the residual values of k transform layers AC coefficients.
- the calculated ⁇ RDcost is greater than 0, it means that the distortion cost of not encoding is large, and the flag bit flag is set to 0; if the calculated ⁇ RDcost is less than 0, it means that the bitrate saving of not encoding is large, and it is necessary to continue to compare the ⁇ RDcost of other transform layers to decide whether to set the flag bit flag to k.
- the Lagrange multiplier ⁇ is selected in the form of H.266/VCC video coding, as shown in the following formula:
- c is a constant and QP is a quantization step size.
- the values of c are selected as 0.01, 0.1, 0.2, 0.3, and 0.4, and the attribute compression performance of the test point cloud under the C1 condition is selected to analyze and find the optimal interval of c.
- the search step size is further reduced, and the optimal value of the constant c is finally determined to be 0.12.
- the cost of encoding all the residual values of the AC coefficients of the k transform layers using the rate-distortion optimization method can be calculated to obtain the first generation value.
- the cost of encoding one or more residual values of the AC coefficients of the k transform layers according to the preset value can be calculated to obtain the second generation value.
- the method may include: if the first generation value is greater than the second generation value, determining to perform skip encoding on the k transformation layers of the current point cloud; if the first generation value is less than the second generation value, determining not to perform skip encoding on the k transformation layers of the current point cloud.
- the method may include: if the value of the first encoding parameter is a first value, determining that the first encoding parameter indicates that skip encoding is to be performed on the k transform layers of the current point cloud; if the value of the first encoding parameter is a second value, determining that the first encoding parameter indicates that no skip encoding is to be performed on the k transform layers of the current point cloud.
- the first coding parameter can be expressed in the form of a syntax element.
- the first coding parameter can be called a first syntax element, represented by flagzero.
- the first syntax element can also be used to indicate whether to skip-code the k transform layers of the current point cloud.
- the method may also include: determining a first generation value for encoding all AC coefficient residual values of the k transform layers, and determining a second generation value for encoding one or more AC coefficient residual values of the k transform layers according to a preset value; determining the value of the first syntax element based on the first generation value and the second generation value.
- the method may further include: if the first generation value is greater than the second generation value, determining that the first syntax element indicates that the k transform layers of the current point cloud are skip encoded; if the first generation value is less than the second generation value, determining that the first syntax element indicates that the k transform layers of the current point cloud are not skip encoded.
- the method may include: if the k transform layers of the current point cloud are skip-coded, then determining the value of the first syntax element to be the first value; if the k transform layers of the current point cloud are not skip-coded, then Determine that a value of the first syntax element is a second value.
- the first-generation value can be processed with reference to the case where the first-generation value is greater than the second-generation value, such as determining to skip encoding the k transformation layers of the current point cloud; or, it can be processed with reference to the case where the first-generation value is less than the second-generation value, such as determining not to skip encoding the k transformation layers of the current point cloud. No limitation is made here.
- the method may further include: performing encoding processing on the value of the first encoding parameter, and writing the obtained encoding bits into a bit stream.
- encoding the value of the first encoding parameter and writing the obtained encoding bits into the code stream may include: encoding the value of the first encoding parameter and writing the obtained encoding bits into the attribute code stream unit in the code stream. That is, the first encoding parameter is specifically an attribute code stream unit in the code stream.
- the first value is different from the second value.
- the first value can be set to an integer greater than zero, such as 1, 2, 3, etc.; the second value can be set to 0.
- the cost of encoding all the residual values of the AC coefficients of the m transform layers using the rate-distortion optimization method can be calculated to obtain the third generation value.
- the cost of encoding one or more residual values of the AC coefficients of the m transform layers according to the preset value can be calculated to obtain the fourth generation value.
- the dth transformation layer includes m nodes.
- the AC coefficient prediction residuals of points in multiple transformation layers it can be obtained by subtracting the initial value of the AC coefficient from the predicted value of the AC coefficient, as shown below:
- the first coding parameter and the AC coefficient residual value are both located in the attribute code stream unit of the code stream.
- the method may also include: in the attribute code stream unit, determining that the field corresponding to the first coding parameter is located after the field corresponding to the AC coefficient residual value.
- the method may further include: encoding the DC coefficient value of the root node, and writing the obtained encoding bits into the attribute code stream unit in the code stream.
- the DC coefficient value can be directly passed to the next layer at each transformation, but the residual calculation of the AC coefficient value is required, and the residual value of the AC coefficient of each layer is quantized and entropy encoded.
- the attribute value of the point can be directly passed to the next layer as the DC coefficient value. In this process, only the DC coefficient value of the root node needs to be written into the bitstream.
- the method further comprises: encoding the value of the second encoding parameter, and writing the obtained encoding bits into the bitstream.
- encoding the value of the second encoding parameter, and writing the obtained encoding bits into the attribute parameter set unit in the bitstream encoding the value of the second encoding parameter, and writing the obtained encoding bits into the attribute parameter set unit in the bitstream. That is, the second encoding parameter is specifically an attribute parameter set unit in the bitstream.
- determining the value of the second coding parameter according to the value of the second syntax element may include: setting the value of the second coding parameter to be equal to the value of the second syntax element.
- the third value is different from the fourth value.
- the third value can be set to 1 and the fourth value can be set to 0; or, the third value can be set to 0 and the fourth value can be set to 1; or, the third value can be set to true (true) and the fourth value can be set to false (false); or, the third value can be set to false (false) and the fourth value can be set to true (true).
- the third value is set to 1 and the fourth value is set to 0, but this is not limited to any limitation.
- the method may further include: determining a value of a third coding parameter; wherein the second coding parameter is used to indicate whether to perform jump coding on the to-be-processed components of the k transformation layers of the current point cloud; encoding the value of the third coding parameter, and writing the obtained coding bits into the bit stream.
- the component to be processed may include at least one of the first color component, the second color component and the third color component.
- three flags flag_Y, flag_U, and flag_V can be set to record the number of coefficient layers for skip coding respectively.
- FIG23 is a detailed flow chart of a coding method provided by an embodiment of the present application.
- intra-frame prediction or inter-frame prediction can be performed for the original point cloud (or referred to as "initial point cloud").
- the original point cloud is upsampled and predicted to obtain a predicted point cloud, and then a RAHT transform is performed to determine the predicted AC coefficient;
- a reference point cloud can be obtained according to the adjacent frames of the original point cloud, and then a RAHT transform can also be performed to determine the predicted AC coefficient.
- Performing a RAHT transform on the original point cloud can determine the DC coefficient and the original AC coefficient of the root node; subtracting the original AC coefficient from the predicted AC coefficient can obtain a predicted residual, and after quantizing the predicted residual, the jump coding mode for the RAHT transform coefficient can be determined according to the value of the flag.
- the flag is set to the minimum RDcost corresponding layer k, and only the AC coefficient residual values of the previous transformed layers are coded; if the rate-distortion cost of not coding is high, the flag is set to 0, and all AC coefficient residual values are coded to obtain the attribute code stream.
- the specific operation flow is shown in Figure 23.
- the AC coefficient residual values of multiple transformation layers corresponding to the current point cloud, the DC coefficient value of the root node of the current point cloud, one or more AC coefficient residual values of k transformation layers of the current point cloud are preset values, the AC coefficient residual values of other transformation layers outside the k transformation layers in the current point cloud, the value of the first coding parameter, the value of the second coding parameter and the value of the third coding parameter.
- the first encoding parameter is used to indicate whether to perform jump encoding on the k transformation layers of the current point cloud
- the second encoding parameter is used to indicate whether to turn on jump encoding of the current point cloud
- the third encoding parameter is used to indicate whether to perform jump encoding on the k transformation layers of the current point cloud to be processed.
- the parameters obtained by the decoding end through decoding the code stream can be called "decoding parameters", and the meanings of the two are the same, but the names at the encoding end and the decoding end are different.
- the embodiment of the present application provides a coding method, which determines the value of a first coding parameter; when the first coding parameter indicates that the k transformation layers of the current point cloud are to be skip-coded, determines that one or more residual values of the AC coefficients of the k transformation layers are preset values; encodes the one or more residual values of the AC coefficients of the k transformation layers according to the preset values, and writes the obtained coded bits into the bitstream.
- the one or more residual values of the AC coefficients of the k transformation layers are directly encoded according to the preset values, which can effectively improve the phenomenon that too many 0s appear in the AC coefficient values of the last few layers of coding in the RAHT transform, thereby improving the coding efficiency, achieving quality enhancement of the point cloud reconstructed at the decoding end at the average bit rate, and further improving the encoding and decoding performance of the point cloud.
- a jump coding mode for RAHT transform coefficients is proposed here.
- the number of layers increases, the number of coded AC coefficients obtained by the transformation gradually increases, and the coefficient value gradually decreases.
- the number of AC coefficients occupies more than half of all AC coefficients, but the number of 0s in these layers occupies more than 95%, so the encoding of the last few layers of AC coefficients must have a large waste of code stream.
- This technical solution proposes to judge the jump coding mode of RAHT transform coefficients based on the rate-distortion optimization method, and use rate-distortion optimization to determine the RDO cost of not encoding the AC coefficients of the last m layers, m-1 layers... of multiple parameters, and the RDO cost of encoding all coefficients. If the cost of not encoding the AC coefficient is less than the total encoding cost, the RDO cost of not encoding is the smallest when used for several layers, and the value of the flag is set to the number of layers k corresponding to the minimum cost, and entropy coding is performed at the same time.
- the decoding end first decodes the flag flag, and if the value of flag is k, the AC coefficient residual values of level n-k+1 to level n are reconstructed as 0, otherwise they are reconstructed as original values.
- the implementation process of the encoding and decoding method may include:
- bit rate and distortion after coding are in a contradictory relationship. If you want to obtain a higher quality reconstructed video with smaller distortion, you need to increase the transmission bit rate; however, the bit rate cannot be increased indefinitely. In some cases, you need to reduce the bit rate to ensure the smoothness of video transmission. In order to better improve the efficiency of coding, it is necessary to comprehensively consider the bit rate and distortion and find a compromise between the two so that the distortion is as small as possible under the condition of a fixed bit rate, as shown in formula (11). Where D represents distortion, R represents bit rate, represents the conditional parameter configuration of encoding, such as quantization step size.
- the above formula is a constrained optimization problem, which can be transformed into the form shown in formula (12) using Lagrange multipliers.
- RDcost is the rate-distortion cost
- ⁇ is the Lagrange multiplier. This is the rate-distortion optimization problem in the field of video coding.
- ⁇ D is represented by the square value of all AC coefficient residual values of the last k layers, which is used to refer to the distortion cost after all these coefficient residual values are not encoded
- R org is the code stream consumption in the coding scheme of the related technology
- the code rate consumption after all the last k layers of AC coefficient residual values are not encoded is only 1 bit occupied by the flag bit flag, so ⁇ R represents the difference in code rate consumption between the last k layers of AC coefficient residual values not encoded and encoded, that is, the code stream saved by not encoding the last k layers of AC coefficient residual values.
- the calculated ⁇ RDcost is greater than 0, it means that the distortion cost of not encoding is large, and the flag is set to 0; if the calculated ⁇ RDcost is less than 0, it means that the bit rate saving of not encoding is large, and it is necessary to continue to compare the ⁇ RDcost of other layers to decide whether to set the flag to k.
- the Lagrange multiplier ⁇ is selected in the form of H.266/VCC video coding, as shown in equation (16).
- c is a constant
- QP is the quantization step size.
- the values of c are selected as 0.01, 0.1, 0.2, 0.3, and 0.4, and the attribute compression performance of the test point cloud under the C1 condition is selected to analyze and find the optimal interval of c.
- the search step size is further reduced, and the optimal value of the constant c is finally determined to be 0.12.
- the flag is set to the minimum RDcost corresponding to the layer number k, and only the AC coefficient residual values of the previous layers are encoded; if the rate-distortion cost of not encoding is high, the flag is set to 0, and all AC coefficient residual values are encoded to obtain the attribute code stream.
- the operation flow chart at the encoding end is shown in the aforementioned Figure 23.
- the code stream structure diagram is shown in Figures 21 and 22, where bits and flag represent the coded quantization coefficient residual and the RDO layer zero flag respectively, and n represents the total number of points in the point cloud.
- the DC coefficient value of the root node and all the AC coefficient residual values are entropy encoded and written into the code stream, and then the flag flag is arithmetic encoded and written into the code stream.
- the flag is first decoded to obtain the number of RAHT parameter layers to be decoded, and then the AC coefficient residual values to be decoded are decoded into the corresponding parameter matrix by entropy decoding according to the indication of the flag flag, and the AC coefficient residual values of the remaining layers are restored to 0.
- the operation flow chart at the decoding end is shown in Figure 17.
- the decoding end reads the bit stream and first decodes the zero flag flag at the end of the bit stream. If the decoded flag value is k, the last k layers of AC coefficient residual values are all decoded as 0, and the remaining coefficients are decoded normally and stored in the parameter matrix; if the decoded flag value is 0, the DC coefficient value and all AC coefficient residual values are solved and stored in the parameter matrix.
- the decoding process is still carried out from top to bottom.
- the DC coefficient value of the root node and the residual value of the AC coefficient of the first layer are obtained, and the RAHT inverse transform is performed to obtain the reconstructed attribute value; if the configuration allows intra-frame prediction or inter-frame prediction, the first-layer AC residual obtained is first added to the predicted AC coefficient to obtain the reconstructed AC coefficient, and the obtained reconstructed AC coefficient is subjected to the RAHT inverse transform together with the DC coefficient of the root node to obtain the reconstructed attribute value of the first layer.
- the 8 reconstructed attribute values obtained can be used to calculate the DC coefficient values of the 8 nodes of the second layer, and then the decoded second-layer AC residual is added to the predicted AC coefficient to obtain the reconstructed AC coefficient.
- the obtained DC coefficient value is subjected to the RAHT inverse transform with the reconstructed AC coefficient of the second layer respectively, and the reconstructed attribute value of the third layer can be obtained, and so on. If the flag value is k, when decoding to the last k layers, the AC coefficient residual values are all restored to 0.
- the specific implementation of the decoding end program is as follows: first, the flag is decoded in the attribute parameter set APS .skip_raht_enabled_flag, this flag determines whether the technical solution of the embodiment of the present application is enabled; if it is true, the flag flag in the code stream is first decoded in the attribute code stream and transmitted to the RAHT sub-function. If the decoded flag value is k, the last k layers of RAHT AC coefficient residual values are restored according to the value of 0 for the next attribute reconstruction; if the decoded flag value is 0, all AC coefficient residual values of RAHT are restored according to the original coding value.
- the attribute AC coefficient residual is stored in the parameter matrix transformPredBuf.
- the RDO judgment scheme for whether to encode the last few layers of coefficients of the RAHT transformation of the point cloud attributes in the technical solution can replace the original entire encoding scheme.
- flag bit flag in the technical solution, it can be expanded to three channels in the dense point cloud color attributes and use the skip coding mode for RAHT transform coefficients at the same time, and set three flag bits flag_Y, flag_U, and flag_V to respectively record the number of coefficient layers that are not encoded.
- the technical solution proposed in the embodiment of the present application was implemented on the G-PCC reference software TMC13V23.0 and GES-TM V2.0, and then tested under the CTC-C1 and CTC-C2 test conditions.
- the test results are detailed in Tables 1 to 4.
- Table 1 is a test result under the C1 condition
- Table 2 is a test result under the C2 condition
- Table 3 is another test result under the C1 condition
- Table 4 is another test result under the C2 condition.
- the C1 condition is a lossless geometry, lossless attribute coding method (lossless geometry, lossy attribute)
- the C2 condition is a lossless geometry, lossy attribute coding method (lossless geometry, lossy attribute).
- End-to-End BD-AttrRate in Tables 1 to 4 represents the BD-Rate of the end-to-end attribute value for the attribute bitstream.
- BD-Rate reflects the difference in PSNR curves between the two cases (with or without filtering).
- PSNR PSNR
- Cat3-frame average represents the average value of the test results of multi-frame radar point cloud datasets
- Cat3-fused average dataset represents the fused point cloud dataset
- Cat2 dataset is a multi-frame dense point cloud.
- Overall average is the average value of the test results of all sequences.
- the present technical scheme obtains a gain of -1.3% on the Reflectance component of the Cat3-frame average data set under TMC13 and CTC-C1 test conditions, a gain of -2.6% on the Reflectance component of the Cat3-frame average data set under CTC-C2 test conditions, and a gain of 0.6%, -6.8%, and -7.0% on the Luma, Chroma Cb, and Chroma Cr components of the Cat3-fused average data set, respectively.
- the present technical scheme obtains a gain of 0.2%, -0.5%, and -0.2% on the Luma, Chroma Cb, and Chroma Cr components of the Cat2 data set under GES-TM and CTC-C1 test conditions, and a gain of 0.8%, -1.8%, and -0.5% on the Luma, Chroma Cb, and Chroma Cr components of the Cat2 data set under CTC-C2 test conditions, respectively.
- FIG25 is a schematic diagram of the composition structure of an encoder provided in an embodiment of the present application.
- the encoder 250 may include a first determining unit 2501 and an encoding unit 2502, wherein:
- the first determining unit 2501 is configured to determine a value of a first coding parameter; when the first coding parameter indicates that k transformation layers of the current point cloud are skip-coded, determine that one or more AC coefficient residual values of the k transformation layers are preset values; wherein k is an integer greater than zero;
- the encoding unit 2502 is configured to encode one or more AC coefficient residual values of k transformation layers according to preset values, and write the obtained encoding bits into the bit stream.
- the first determining unit 2501 is further configured to determine a first generation value for encoding all the AC coefficient residual values of the k transform layers, and to determine a second generation value for encoding one or more AC coefficient residual values of the k transform layers according to a preset value. value; determine the value of the first encoding parameter according to the first generation value and the second generation value.
- the first determination unit 2501 is further configured to determine the value of the first encoding parameter to be the first value if the first generation value is greater than the second generation value; and to determine the value of the first encoding parameter to be the second value if the first generation value is less than the second generation value.
- the first determination unit 2501 is further configured to, if the value of the first encoding parameter is a first value, determine that the first encoding parameter indicates that the k transformation layers of the current point cloud are skip encoded; if the value of the first encoding parameter is a second value, determine that the first encoding parameter indicates that the k transformation layers of the current point cloud are not skip encoded.
- the encoding unit 2502 is further configured to perform encoding processing on the value of the first encoding parameter and write the obtained encoding bits into the bit stream.
- the encoding unit 2502 is further configured to perform encoding processing on the value of the first encoding parameter, and write the obtained encoding bits into the attribute code stream unit in the code stream.
- the first determination unit 2501 is further configured to set the first value equal to the value of k when the first encoding parameter indicates that k transform layers of the current point cloud are to be skip encoded.
- the first determination unit 2501 is further configured to determine that all AC coefficient residual values of k transformation layers are preset values.
- the encoder 250 may further include a first division unit 2503 configured to perform layer division on points in the current point cloud, determine multiple transformation layers corresponding to the current point cloud and a root node of the current point cloud; wherein the multiple transformation layers include k transformation layers and other transformation layers.
- the first determining unit 2501 is further configured to set the k transformation layers as the last k transformation layers from the root node in a downward direction among the multiple transformation layers.
- the encoder 250 may further include a first transformation unit 2504, configured to determine initial attribute values of points in a plurality of transformation layers; and perform regional adaptive hierarchical transformation on the initial attribute values of the points in the plurality of transformation layers to determine initial AC coefficient values of the points in the plurality of transformation layers and DC coefficient values of the root nodes.
- a first transformation unit 2504 configured to determine initial attribute values of points in a plurality of transformation layers; and perform regional adaptive hierarchical transformation on the initial attribute values of the points in the plurality of transformation layers to determine initial AC coefficient values of the points in the plurality of transformation layers and DC coefficient values of the root nodes.
- the first determination unit 2501 is also configured to determine the AC coefficient prediction values of points in multiple transformation layers; and determine the AC coefficient residual values of multiple transformation layers based on the AC coefficient initial values of points in multiple transformation layers and the AC coefficient prediction values of points in multiple transformation layers.
- the first determination unit 2501 is also configured to perform a subtraction operation on the initial values of the AC coefficients of points in multiple transformation layers and the predicted values of the AC coefficients of points in multiple transformation layers to obtain the AC coefficient prediction residuals of the points in multiple transformation layers; and to quantize the AC coefficient prediction residuals of the points in multiple transformation layers to obtain the AC coefficient residual values of multiple transformation layers.
- the first determination unit 2501 is further configured to determine the residual values of the AC coefficients of other transformation layers other than k transformation layers among multiple transformation layers when the first encoding parameter indicates that the k transformation layers of the current point cloud are to be skip encoded; the encoding unit 2502 is further configured to encode the residual values of the AC coefficients of other transformation layers and write the obtained encoding bits into the bitstream.
- the encoding unit 2502 is further configured to perform encoding processing on the AC coefficient residual values of other transform layers, and write the obtained encoding bits into the attribute code stream unit in the code stream.
- the encoding unit 2502 is further configured to encode the residual values of the AC coefficients of multiple transform layers when the first encoding parameter indicates that the k transform layers of the current point cloud are not to be skip-encoded, and write the obtained encoding bits into the bitstream.
- the encoding unit 2502 is further configured to perform encoding processing on the AC coefficient residual values of multiple transform layers, and write the obtained encoding bits into the attribute code stream unit in the code stream.
- the first determining unit 2501 is further configured to determine, in the attribute code stream unit, that the field corresponding to the first coding parameter is located after the field corresponding to the AC coefficient residual value.
- the first transformation unit 2504 is further configured to determine the attribute prediction values of points in multiple transformation layers; and perform regional adaptive hierarchical transformation on the attribute prediction values of points in multiple transformation layers to determine the AC coefficient prediction values of points in multiple transformation layers.
- the first determination unit 2501 is further configured to perform intra-frame prediction on points in multiple transformation layers and determine attribute prediction values of the points in multiple transformation layers when the current point cloud allows the use of intra-frame prediction; when the current point cloud allows the use of inter-frame prediction, determine the reference point cloud of the current point cloud, and perform inter-frame prediction on points in multiple transformation layers based on the reference point cloud to determine the attribute prediction values of the points in multiple transformation layers.
- the encoding unit 2502 is further configured to encode the DC coefficient value of the root node and write the obtained encoding bits into the bit stream.
- the first determination unit 2501 is further configured to determine a value of a second encoding parameter; when the second encoding parameter indicates to start skip encoding of the current point cloud, the step of determining a value of the first encoding parameter is performed.
- the encoding unit 2502 is further configured to perform encoding processing on the value of the second encoding parameter and write the obtained encoding bits into the bit stream.
- the encoding unit 2502 is further configured to perform encoding processing on the value of the second encoding parameter, and write the obtained encoding bits into the attribute parameter set unit in the bitstream.
- the first determination unit 2501 is further configured to determine the value of a third encoding parameter; wherein the third encoding parameter is used to indicate whether to perform jump encoding on the to-be-processed components of the k transformation layers of the current point cloud; the encoding unit 2502 is further configured to perform encoding processing on the value of the third encoding parameter and write the obtained encoding bits into the bitstream.
- the component to be processed includes at least one of a first color component, a second color component, and a third color component.
- the first determination unit 2501 is further configured to determine that one or more AC coefficient residual values of the k transform layers to be processed are preset values when jump encoding is performed on the k transform layers to be processed components of the current point cloud; the encoding unit 2502 is further configured to encode one or more AC coefficient residual values of the k transform layers to be processed components according to the preset values, and write the obtained encoding bits into the bit stream.
- a "unit” may be a part of a circuit, a part of a processor, a part of a program or software, etc., and of course, it may be a module, or it may be non-modular.
- the components in the present embodiment may be integrated into a processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
- the above-mentioned integrated unit may be implemented in the form of hardware or in the form of a software functional module.
- the integrated unit is implemented in the form of a software function module and is not sold or used as an independent product, it can be stored in a computer-readable storage medium.
- the technical solution of this embodiment is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product.
- the computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, server, or network device, etc.) or a processor to perform all or part of the steps of the method described in this embodiment.
- the aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk, etc., various media that can store program codes.
- an embodiment of the present application provides a computer-readable storage medium, which is applied to the encoder 250.
- the computer-readable storage medium stores a computer program, and when the computer program is executed by the first processor, the method described in any one of the aforementioned embodiments is implemented.
- Figure 26 is a schematic diagram of the specific hardware structure of an encoder provided in an embodiment of the present application.
- the encoder 250 may include: a first communication interface 2601, a first memory 2602 and a first processor 2603; each component is coupled together through a first bus system 2604.
- the first bus system 2604 is used to realize the connection and communication between these components.
- the first bus system 2604 also includes a power bus, a control bus and a status signal bus.
- various buses are marked as the first bus system 2604 in Figure 26. Among them,
- the first communication interface 2601 is used for receiving and sending signals during the process of sending and receiving information with other external network elements;
- a first memory 2602 used to store a computer program that can be run on the first processor 2603;
- the first processor 2603 is configured to, when running the computer program, execute:
- the first memory 2602 in the embodiment of the present application can be a volatile memory or a non-volatile memory, or can include both volatile and non-volatile memories.
- the non-volatile memory can be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory.
- the volatile memory can be a random access memory (RAM), which is used as an external cache.
- RAM static RAM
- DRAM dynamic RAM
- SDRAM synchronous DRAM
- DDRSDRAM double data rate synchronous DRAM
- ESDRAM enhanced SDRAM
- SLDRAM synchronous link DRAM
- DRRAM direct RAM bus RAM
- the first processor 2603 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by a hardware integrated logic circuit or software instructions in the first processor 2603.
- the first processor 2603 may be a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), or a processor. Specific Integrated Circuit, ASIC), field programmable gate array (Field Programmable Gate Array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components.
- DSP digital signal processor
- ASIC application-specific integrated circuit
- FPGA field programmable gate array
- the methods, steps and logic block diagrams disclosed in the embodiments of the present application can be implemented or executed.
- the general processor can be a microprocessor or the processor can also be any conventional processor, etc.
- the steps of the method disclosed in the embodiments of the present application can be directly embodied as a hardware decoding processor to be executed, or a combination of hardware and software modules in the decoding processor to be executed.
- the software module can be located in a mature storage medium in the field such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory or an electrically erasable programmable memory, a register, etc.
- the storage medium is located in the first memory 2602, and the first processor 2603 reads the information in the first memory 2602, and completes the steps of the above method in combination with its hardware.
- the processing unit can be implemented in one or more application specific integrated circuits (Application Specific Integrated Circuits, ASIC), digital signal processors (Digital Signal Processing, DSP), digital signal processing devices (DSP Device, DSPD), programmable logic devices (Programmable Logic Device, PLD), field programmable gate arrays (Field-Programmable Gate Array, FPGA), general processors, controllers, microcontrollers, microprocessors, other electronic units for performing the functions described in this application or a combination thereof.
- ASIC Application Specific Integrated Circuits
- DSP Digital Signal Processing
- DSP Device digital signal processing devices
- PLD programmable logic devices
- FPGA field programmable gate array
- general processors controllers, microcontrollers, microprocessors, other electronic units for performing the functions described in this application or a combination thereof.
- the technology described in this application can be implemented by a module (such as a process, function, etc.) that performs the functions described in this application.
- the software code can be stored in a memory and executed by a processor.
- the memory can be implemented in the processor or outside the processor.
- the first processor 2603 is further configured to execute the method described in any one of the aforementioned embodiments when running the computer program.
- the present embodiment provides an encoder, which, when determining to skip encode the k transformation layers of the current point cloud, directly encodes one or more AC coefficient residual values of the k transformation layers according to preset values, can effectively improve the phenomenon of too many zeros in the AC coefficient values of the last few layers of encoding in the RAHT transform, thereby improving the encoding and decoding efficiency, and achieving quality enhancement of the reconstructed point cloud at the decoding end at an average bit rate, thereby improving the encoding and decoding performance of the point cloud.
- FIG27 is a schematic diagram of the composition structure of a decoder provided in an embodiment of the present application.
- the decoder 270 may include a second determination unit 2701, a decoding unit 2702, and a reconstruction unit 2703, wherein:
- the second determining unit 2701 is configured to determine a value of the first decoding parameter; when the first decoding parameter indicates to perform skip decoding on k transform layers of the current point cloud, determine one or more AC coefficient residual values of the k transform layers to be a preset value; wherein k is an integer greater than zero;
- a decoding unit 2702 is configured to decode the bit stream and determine the residual values of the AC coefficients of other transform layers other than the k transform layers in the current point cloud;
- the second determination unit 2701 is further configured to determine a value of a second decoding parameter; and when the second decoding parameter indicates to start jump decoding of the current point cloud, execute the step of determining a value of the first decoding parameter.
- the second determination unit 2701 is further configured to determine that all AC coefficient residual values of k transformation layers are preset values.
- the second determining unit 2701 is further configured to perform inverse quantization processing on the parameter values in the first parameter matrix of the current point cloud.
- the second determination unit 2701 is further configured to perform intra-frame prediction on points in multiple transformation layers and determine attribute prediction values of the points in multiple transformation layers when the current point cloud allows the use of intra-frame prediction; when the current point cloud allows the use of inter-frame prediction, determine the reference point cloud of the current point cloud, and perform inter-frame prediction on points in multiple transformation layers based on the reference point cloud to determine the attribute prediction values of the points in multiple transformation layers.
- the second reconstruction unit 2703 is further configured to perform a regional adaptive hierarchical inverse transform based on the DC coefficient value of the root node and the AC coefficient reconstruction value of the point of the current transformation layer when the current transformation layer is the first transformation layer, so as to obtain the reconstructed attribute value of the point of the first transformation layer; when the current transformation layer is not the first transformation layer, determine the DC coefficient value of the point of the current transformation layer based on the reconstructed attribute value of the point of the previous transformation layer of the current transformation layer, and perform a regional adaptive hierarchical inverse transform based on the DC coefficient value of the point of the current transformation layer and the AC coefficient reconstruction value of the point of the current transformation layer to obtain the reconstructed attribute value of the point of the non-first transformation layer.
- the decoding unit 2702 is further configured to decode the code stream and determine that one or more AC coefficient residual values of k transform layers are preset values.
- the decoding unit 2702 is further configured to decode the bitstream and determine a value of a third decoding parameter
- the second determining unit 2701 is further configured to determine one or more AC coefficient residual values of the components to be processed of the k transform layers to be processed as preset values when the third decoding parameter indicates to skip decoding the components to be processed of the k transform layers of the current point cloud;
- the decoding unit 2702 is further configured to decode the code stream to determine the residual values of the AC coefficients of the components to be processed in other transform layers other than the k transform layers in the current point cloud;
- the reconstruction unit 2703 is further configured to determine the reconstructed point cloud of the to-be-processed component of the current point cloud according to the AC coefficient residual values of the to-be-processed components of the k transformation layers and the AC coefficient residual values of the to-be-processed components of other transformation layers.
- the component to be processed includes at least one of a first color component, a second color component, and a third color component.
- a "unit" can be a part of a circuit, a part of a processor, a part of a program or software, etc., and of course it can also be a module, or it can be non-modular.
- the components in this embodiment can be integrated into a processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
- the above-mentioned integrated unit can be implemented in the form of hardware or in the form of a software functional module.
- the integrated unit is implemented in the form of a software function module and is not sold or used as an independent product, it can be stored in a computer-readable storage medium.
- this embodiment provides a computer-readable storage medium, which is applied to the decoder 270, and the computer-readable storage medium stores a computer program. When the computer program is executed by the second processor, the method described in any one of the above embodiments is implemented.
- FIG. 28 is a decoder provided in an embodiment of the present application.
- the decoder 270 may include: a second communication interface 2801, a second memory 2802 and a second processor 2803; each component is coupled together through a second bus system 2804.
- the second bus system 2804 is used to achieve connection and communication between these components.
- the second bus system 2804 also includes a power bus, a control bus and a status signal bus.
- various buses are marked as the second bus system 2804 in Figure 28. Among them,
- the second communication interface 2801 is used for receiving and sending signals during the process of sending and receiving information with other external network elements;
- the second memory 2802 is used to store a computer program that can be run on the second processor 2803;
- the second processor 2803 is configured to, when running the computer program, execute:
- the second processor 2803 is further configured to execute any one of the methods described in the foregoing embodiments when running the computer program.
- the present embodiment provides a decoder, which, when determining to skip encode the k transformation layers of the current point cloud, directly encodes one or more AC coefficient residual values of the k transformation layers according to preset values, can effectively improve the phenomenon of too many zeros in the AC coefficient values of the last few layers of encoding in the RAHT transform, thereby improving the encoding and decoding efficiency, and achieving quality enhancement of the reconstructed point cloud at the decoding end at an average bit rate, thereby improving the encoding and decoding performance of the point cloud.
- FIG29 is a schematic diagram of the composition structure of a coding and decoding system provided in an embodiment of the present application.
- the coding and decoding system 290 may include an encoder 2901 and a decoder 2902 .
- the encoder 2901 may be the encoder described in any one of the aforementioned embodiments
- the decoder 2902 may be the decoder described in any one of the aforementioned embodiments.
- the value of the first encoding parameter is determined; when the first encoding parameter indicates that the k transform layers of the current point cloud are to be skip-encoded, one or more residual values of the AC coefficients of the k transform layers are determined to be preset values; one or more residual values of the AC coefficients of the k transform layers are encoded according to the preset values, and the obtained encoded bits are written into the bitstream.
- the value of the first decoding parameter is determined; when the first decoding parameter indicates that the k transform layers of the current point cloud are to be skip-decoded, one or more residual values of the AC coefficients of the k transform layers are determined to be preset values; the bitstream is decoded to determine the residual values of the AC coefficients of other transform layers other than the k transform layers in the current point cloud; based on the residual values of the AC coefficients of the k transform layers and the residual values of the AC coefficients of the other transform layers, the reconstructed point cloud of the current point cloud is determined.
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Multimedia (AREA)
- Discrete Mathematics (AREA)
- Signal Processing (AREA)
- Theoretical Computer Science (AREA)
- Compression Or Coding Systems Of Tv Signals (AREA)
Abstract
Description
本申请实施例涉及视频编解码技术领域,尤其涉及一种编解码方法、码流、编码器、解码器以及存储介质。The embodiments of the present application relate to the field of video coding and decoding technology, and in particular, to a coding and decoding method, a bit stream, an encoder, a decoder, and a storage medium.
在基于几何的点云压缩(Geometry-based Point Cloud Compression,G-PCC)编解码框架中,点云的几何信息和属性信息是分开进行编码的。其中,G-PCC的属性编码可以包括:预测变换(Predicting Transform,PT)、提升变换(Lifting Transform,LT)以及区域自适应分层变换(Region Adaptive Hierarchical Transform,RAHT)。In the geometry-based point cloud compression (G-PCC) codec framework, the geometry information and attribute information of the point cloud are encoded separately. Among them, the attribute encoding of G-PCC can include: Predicting Transform (PT), Lifting Transform (LT) and Region Adaptive Hierarchical Transform (RAHT).
对于RAHT变换来说,从根节点到子节点逐层计算的过程中,随着层数的增加,变换所得的编码AC系数值逐渐减小,以至于在雷达点云的最后几层,这时候的编码AC系数值出现了大量的0,对最后几层AC系数值的编码会存在码流浪费,降低了编码效率。For the RAHT transform, in the process of layer-by-layer calculation from the root node to the child node, as the number of layers increases, the coded AC coefficient value obtained by the transform gradually decreases, so that in the last few layers of the radar point cloud, a large number of 0s appear in the coded AC coefficient value at this time. The encoding of the AC coefficient values of the last few layers will result in a waste of code stream, reducing the coding efficiency.
发明内容Summary of the invention
本申请实施例提供一种编解码方法、码流、编码器、解码器以及存储介质,能够提高RAHT变换的编解码效率。The embodiments of the present application provide a coding and decoding method, a bit stream, an encoder, a decoder and a storage medium, which can improve the coding and decoding efficiency of RAHT transformation.
本申请实施例的技术方案可以如下实现:The technical solution of the embodiment of the present application can be implemented as follows:
第一方面,本申请实施例提供了一种解码方法,应用于解码器,该方法包括:In a first aspect, an embodiment of the present application provides a decoding method, which is applied to a decoder, and the method includes:
确定第一解码参数的取值;Determining a value of a first decoding parameter;
在第一解码参数指示对当前点云的k个变换层进行跳跃解码时,确定k个变换层的一个或多个交流系数残差值为预设数值;其中,k是大于零的整数;When the first decoding parameter indicates that k transform layers of the current point cloud are to be skipped and decoded, one or more AC coefficient residual values of the k transform layers are determined to be preset values; wherein k is an integer greater than zero;
解码码流,确定当前点云中k个变换层之外其他变换层的交流系数残差值;Decode the bitstream and determine the residual values of the AC coefficients of other transform layers other than the k transform layers in the current point cloud;
根据k个变换层的交流系数残差值和其他变换层的交流系数残差值,确定当前点云的重建点云。The reconstructed point cloud of the current point cloud is determined according to the residual values of the AC coefficients of the k transformation layers and the residual values of the AC coefficients of other transformation layers.
第二方面,本申请实施例提供了一种编码方法,应用于编码器,该方法包括:In a second aspect, an embodiment of the present application provides an encoding method, which is applied to an encoder, and the method includes:
确定第一编码参数的取值;Determining a value of a first encoding parameter;
在第一编码参数指示对当前点云的k个变换层进行跳跃编码时,确定k个变换层的一个或多个交流系数残差值为预设数值;其中,k为大于零的整数;When the first encoding parameter indicates that the k transformation layers of the current point cloud are to be skip-encoded, determining one or more AC coefficient residual values of the k transformation layers to be preset values; wherein k is an integer greater than zero;
对k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,将所得到的编码比特写入码流。One or more AC coefficient residual values of k transformation layers are coded according to preset values, and the obtained coded bits are written into the bit stream.
第三方面,本申请实施例提供了一种码流,该码流是根据待编码信息进行比特编码生成的;其中,待编码信息包括下述至少一项:In a third aspect, an embodiment of the present application provides a code stream, which is generated by bit encoding according to information to be encoded; wherein the information to be encoded includes at least one of the following:
当前点云对应的多个变换层的交流系数残差值、当前点云的根节点的直流系数值、当前点云的k个变换层的交流系数残差值为预设数值、当前点云中k个变换层之外其他变换层的交流系数残差值、第一编码参数的取值、第二编码参数的取值和第三编码参数的取值;The AC coefficient residual values of multiple transformation layers corresponding to the current point cloud, the DC coefficient value of the root node of the current point cloud, the AC coefficient residual values of k transformation layers of the current point cloud are preset values, the AC coefficient residual values of other transformation layers other than the k transformation layers in the current point cloud, the value of the first coding parameter, the value of the second coding parameter and the value of the third coding parameter;
其中,第一编码参数用于指示对当前点云的k个变换层是否进行跳跃编码,第二编码参数用于指示是否开启当前点云的跳跃编码,第三编码参数用于指示对当前点云的k个变换层待处理分量的是否进行跳跃编码。Among them, the first coding parameter is used to indicate whether to perform jump coding on the k transformation layers of the current point cloud, the second coding parameter is used to indicate whether to turn on jump coding of the current point cloud, and the third coding parameter is used to indicate whether to perform jump coding on the k transformation layers of the current point cloud to be processed.
第四方面,本申请实施例提供了一种编码器,包括第一确定单元和编码单元,其中:In a fourth aspect, an embodiment of the present application provides an encoder, including a first determining unit and an encoding unit, wherein:
第一确定单元,配置为确定第一编码参数的取值;在第一编码参数指示对当前点云的k个变换层进行跳跃编码时,确定k个变换层的一个或多个交流系数残差值为预设数值;其中,k为大于零的整数;A first determining unit is configured to determine a value of a first encoding parameter; when the first encoding parameter indicates that k transformation layers of the current point cloud are to be skip-encoded, one or more AC coefficient residual values of the k transformation layers are determined to be preset values; wherein k is an integer greater than zero;
编码单元,配置为对k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,将所得到的编码比特写入码流。The encoding unit is configured to encode one or more AC coefficient residual values of k transformation layers according to preset values, and write the obtained encoding bits into the bit stream.
第五方面,本申请实施例提供了一种编码器,包括第一存储器和第一处理器,其中:In a fifth aspect, an embodiment of the present application provides an encoder, including a first memory and a first processor, wherein:
第一存储器,用于存储能够在第一处理器上运行的计算机程序;A first memory, for storing a computer program that can be run on the first processor;
第一处理器,用于在运行所述计算机程序时,执行如第二方面所述的方法。 The first processor is configured to execute the method according to the second aspect when running the computer program.
第六方面,本申请实施例提供了一种解码器,包括第二确定单元、解码单元和重建单元,其中:In a sixth aspect, an embodiment of the present application provides a decoder, including a second determination unit, a decoding unit, and a reconstruction unit, wherein:
第二确定单元,配置为确定第一解码参数的取值;在第一解码参数指示对当前点云的k个变换层进行跳跃解码时,确定k个变换层的一个或多个交流系数残差值为预设数值;其中,k是大于零的整数;The second determination unit is configured to determine a value of the first decoding parameter; when the first decoding parameter indicates to perform skip decoding on k transformation layers of the current point cloud, determine one or more AC coefficient residual values of the k transformation layers to be a preset value; wherein k is an integer greater than zero;
解码单元,配置为解码码流,确定当前点云中k个变换层之外其他变换层的交流系数残差值;A decoding unit configured to decode the bit stream and determine residual values of AC coefficients of other transform layers other than k transform layers in the current point cloud;
重建单元,配置为根据k个变换层的交流系数残差值和其他变换层的交流系数残差值,确定当前点云的重建点云。The reconstruction unit is configured to determine the reconstructed point cloud of the current point cloud according to the residual values of the AC coefficients of the k transformation layers and the residual values of the AC coefficients of other transformation layers.
第七方面,本申请实施例提供了一种解码器,包括第二存储器和第二处理器,其中:In a seventh aspect, an embodiment of the present application provides a decoder, including a second memory and a second processor, wherein:
第二存储器,用于存储能够在第二处理器上运行的计算机程序;A second memory for storing a computer program that can be run on a second processor;
第二处理器,用于在运行所述计算机程序时,执行如第一方面所述的方法。The second processor is configured to execute the method described in the first aspect when running the computer program.
第八方面,本申请实施例提供了一种计算机可读存储介质,该计算机可读存储介质存储有计算机程序,所述计算机程序被至少一个处理器执行时实现如第一方面所述的方法、或者如第二方面所述的方法。In an eighth aspect, an embodiment of the present application provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by at least one processor, it implements the method described in the first aspect or the method described in the second aspect.
本申请实施例提供了一种编解码方法、码流、编码器、解码器以及存储介质,在编码端,确定第一编码参数的取值;在第一编码参数指示对当前点云的k个变换层进行跳跃编码时,确定k个变换层的一个或多个交流系数残差值为预设数值;对k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,将所得到的编码比特写入码流。在解码端,确定第一解码参数的取值;在第一解码参数指示对当前点云的k个变换层进行跳跃解码时,确定k个变换层的一个或多个交流系数残差值为预设数值;解码码流,确定当前点云中k个变换层之外其他变换层的交流系数残差值;根据k个变换层的交流系数残差值和其他变换层的交流系数残差值,确定当前点云的重建点云。也就是说,无论是编码端还是解码端,在确定对当前点云的k个变换层进行跳跃编码时,这时候直接将这k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,可以有效改善RAHT变换中最后几层编码AC系数值出现过多0的现象,从而提高了编解码效率,而且实现了解码端重建点云在平均码率下的质量增强,进而能够提升点云的编解码性能。The embodiment of the present application provides a coding and decoding method, a code stream, an encoder, a decoder, and a storage medium. At the encoding end, the value of the first coding parameter is determined; when the first coding parameter indicates that the k transformation layers of the current point cloud are to be skip-encoded, one or more residual values of the AC coefficients of the k transformation layers are determined to be preset values; one or more residual values of the AC coefficients of the k transformation layers are encoded according to the preset values, and the obtained coded bits are written into the code stream. At the decoding end, the value of the first decoding parameter is determined; when the first decoding parameter indicates that the k transformation layers of the current point cloud are to be skip-decoded, one or more residual values of the AC coefficients of the k transformation layers are determined to be preset values; the code stream is decoded to determine the residual values of the AC coefficients of other transformation layers other than the k transformation layers in the current point cloud; based on the residual values of the AC coefficients of the k transformation layers and the residual values of the AC coefficients of the other transformation layers, the reconstructed point cloud of the current point cloud is determined. That is to say, whether it is the encoding end or the decoding end, when it is determined to skip encoding the k transformation layers of the current point cloud, one or more AC coefficient residual values of these k transformation layers are directly encoded according to the preset values. This can effectively improve the phenomenon of too many 0s in the AC coefficient values of the last few layers of encoding in the RAHT transform, thereby improving the encoding and decoding efficiency, and achieving quality enhancement of the reconstructed point cloud at the average bit rate at the decoding end, thereby improving the encoding and decoding performance of the point cloud.
图1A为一种三维点云图像示意图;FIG1A is a schematic diagram of a three-dimensional point cloud image;
图1B为一种三维点云图像的局部放大图;FIG1B is a partial enlarged view of a three-dimensional point cloud image;
图2A为一种点云图像的六个观看角度示意图;FIG2A is a schematic diagram of six viewing angles of a point cloud image;
图2B为一种点云图像对应的数据存储格式示意图;FIG2B is a schematic diagram of a data storage format corresponding to a point cloud image;
图3为一种点云编解码的网络架构示意图;FIG3 is a schematic diagram of a network architecture for point cloud encoding and decoding;
图4为一种G-PCC编码器的组成框架示意图;FIG4 is a schematic diagram of a composition framework of a G-PCC encoder;
图5为一种G-PCC解码器的组成框架示意图;FIG5 is a schematic diagram of a composition framework of a G-PCC decoder;
图6为一种RAHT的编码流程示意图;FIG6 is a schematic diagram of a RAHT encoding process;
图7A为一种当前节点的结构示意图;FIG7A is a schematic diagram of the structure of a current node;
图7B为一种子节点的结构示意图;FIG7B is a schematic diagram of the structure of a subnode;
图8为一种基于变换方向的RAHT变换示意图;FIG8 is a schematic diagram of a RAHT transformation based on a transformation direction;
图9为一种RAHT的正变换过程示意图;FIG9 is a schematic diagram of a RAHT forward transformation process;
图10为一种RAHT的逆变换过程示意图;FIG10 is a schematic diagram of an inverse transformation process of RAHT;
图11为一种RAHT的帧间预测过程示意图;FIG11 is a schematic diagram of an inter-frame prediction process of RAHT;
图12为本申请实施例提供的一种解码方法的流程示意图一;FIG12 is a flowchart diagram 1 of a decoding method provided in an embodiment of the present application;
图13为本申请实施例提供的一种解码方法的流程示意图二;FIG13 is a second flow chart of a decoding method provided in an embodiment of the present application;
图14为本申请实施例提供的一种解码方法的流程示意图三;FIG14 is a third flow chart of a decoding method provided in an embodiment of the present application;
图15为本申请实施例提供的一种解码方法的流程示意图四;FIG15 is a fourth flowchart of a decoding method provided in an embodiment of the present application;
图16为本申请实施例提供的一种解码方法的流程示意图五;FIG16 is a flowchart diagram 5 of a decoding method provided in an embodiment of the present application;
图17为本申请实施例提供的一种解码方法的详细流程示意图;FIG17 is a detailed flowchart of a decoding method provided in an embodiment of the present application;
图18为本申请实施例提供的一种编码方法的流程示意图一;FIG18 is a flowchart diagram 1 of an encoding method provided in an embodiment of the present application;
图19为本申请实施例提供的一种编码方法的流程示意图二;FIG19 is a second flow chart of an encoding method provided in an embodiment of the present application;
图20为本申请实施例提供的一种编码方法的流程示意图三;FIG20 is a third flow chart of an encoding method provided in an embodiment of the present application;
图21为一种相关技术的码流结构示意图;FIG21 is a schematic diagram of a code stream structure of a related technology;
图22为本申请实施例提供的一种码流结构示意图;FIG22 is a schematic diagram of a code stream structure provided in an embodiment of the present application;
图23为本申请实施例提供的一种编码方法的详细流程示意图;FIG23 is a detailed flowchart of an encoding method provided in an embodiment of the present application;
图24为本申请实施例提供的一种编解码方法的整体流程示意图; FIG24 is a schematic diagram of the overall flow of a coding and decoding method provided in an embodiment of the present application;
图25为本申请实施例提供的一种编码器的组成结构示意图;FIG25 is a schematic diagram of the composition structure of an encoder provided in an embodiment of the present application;
图26为本申请实施例提供的一种编码器的具体硬件结构示意图;FIG26 is a schematic diagram of a specific hardware structure of an encoder provided in an embodiment of the present application;
图27为本申请实施例提供的一种解码器的组成结构示意图;FIG27 is a schematic diagram of the composition structure of a decoder provided in an embodiment of the present application;
图28为本申请实施例提供的一种解码器的具体硬件结构示意图;FIG28 is a schematic diagram of a specific hardware structure of a decoder provided in an embodiment of the present application;
图29为本申请实施例提供的一种编解码系统的组成结构示意图。FIG. 29 is a schematic diagram of the composition structure of a coding and decoding system provided in an embodiment of the present application.
为了能够更加详尽地了解本申请实施例的特点与技术内容,下面结合附图对本申请实施例的实现进行详细阐述,所附附图仅供参考说明之用,并非用来限定本申请实施例。In order to enable a more detailed understanding of the features and technical contents of the embodiments of the present application, the implementation of the embodiments of the present application is described in detail below in conjunction with the accompanying drawings. The attached drawings are for reference only and are not used to limit the embodiments of the present application.
除非另有定义,本文所使用的所有的技术和科学术语与属于本申请的技术领域的技术人员通常理解的含义相同。本文中所使用的术语只是为了描述本申请实施例的目的,不是旨在限制本申请。Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein are only for the purpose of describing the embodiments of this application and are not intended to limit this application.
在以下的描述中,涉及到“一些实施例”,其描述了所有可能实施例的子集,但是可以理解,“一些实施例”可以是所有可能实施例的相同子集或不同子集,并且可以在不冲突的情况下相互结合。In the following description, reference is made to “some embodiments”, which describe a subset of all possible embodiments, but it will be understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.
还需要指出,本申请实施例所涉及的术语“第一\第二\第三”仅是用于区别类似的对象,不代表针对对象的特定排序,可以理解地,“第一\第二\第三”在允许的情况下可以互换特定的顺序或先后次序,以使这里描述的本申请实施例能够以除了在这里图示或描述的以外的顺序实施。It should also be pointed out that the terms "first\second\third" involved in the embodiments of the present application are only used to distinguish similar objects and do not represent a specific ordering of the objects. It can be understood that "first\second\third" can be interchanged in a specific order or sequence where permitted, so that the embodiments of the present application described here can be implemented in an order other than that illustrated or described here.
对本申请实施例进行进一步详细说明之前,先对本申请实施例中涉及的名词和术语进行说明,本申请实施例中涉及的名词和术语适用于如下的解释:Before further describing the embodiments of the present application in detail, the nouns and terms involved in the embodiments of the present application are described first. The nouns and terms involved in the embodiments of the present application are subject to the following interpretations:
基于几何的点云压缩(Geometry-based Point Cloud Compression,G-PCC/GPCC);Geometry-based Point Cloud Compression (G-PCC/GPCC);
基于视频的点云压缩(Video-based Point Cloud Compression,V-PCC或VPCC);Video-based Point Cloud Compression (V-PCC or VPCC);
细节层次(Level of Detail,LOD);Level of Detail (LOD);
区域自适应分层变换(Region Adaptive Hierarchal Transform,RAHT);Region Adaptive Hierarchal Transform (RAHT);
交流高频系数(Alternating Current,AC);Alternating Current (AC);
直流低频系数(Direct Current,DC);Direct Current, DC;
属性参数集(Attribute Parameter Set,APS);Attribute Parameter Set (APS);
峰值信噪比(Peak Signal to Noise Ratio,PSNR);Peak Signal to Noise Ratio (PSNR);
率失真优化(Rate–distortion optimization,RDO);Rate–distortion optimization (RDO);
率失真优化量化(Rate–distortion optimization Quantization,RDOQ);Rate–distortion optimization Quantization (RDOQ);
亮度分量(Luminance,Luma或Y);Luminance component (Luminance, Luma or Y);
蓝色色度分量(Chroma blue,Cb);Chroma blue (Cb);
红色色度分量(Chroma red,Cr)。Red chromaticity component (Chroma red, Cr).
点云(Point Cloud)是物体表面的三维表现形式,通过光电雷达、激光雷达、激光扫描仪、多视角相机等采集设备,可以采集得到物体表面的点云(数据)。Point Cloud is a three-dimensional representation of the surface of an object. Point cloud (data) on the surface of an object can be collected through acquisition equipment such as photoelectric radar, lidar, laser scanner, and multi-view camera.
点云是空间中一组无规则分布的、表达三维物体或场景的空间结构及表面属性的离散点集,图1A展示了三维点云图像和图1B展示了三维点云图像的局部放大图,可以看到点云表面是由分布稠密的点所组成的。A point cloud is a set of irregularly distributed discrete points in space that express the spatial structure and surface properties of a three-dimensional object or scene. FIG1A shows a three-dimensional point cloud image and FIG1B shows a partial magnified view of the three-dimensional point cloud image. It can be seen that the point cloud surface is composed of densely distributed points.
二维图像在每一个像素点均有信息表达,分布规则,因此不需要额外记录其位置信息;然而点云中的点在三维空间中的分布具有随机性和不规则性,因此需要记录每一个点在空间中的位置,才能完整地表达一幅点云。与二维图像类似,采集过程中每一个位置均有对应的属性信息,通常为RGB颜色值,颜色值反映物体的色彩;对于点云来说,每一个点所对应的属性信息除了颜色信息以外,还有比较常见的是反射率(reflectance)值,反射率值反映物体的表面材质。因此,点云数据通常包括点的位置信息和点的属性信息。其中,点的位置信息也可称为点的几何信息。例如,点的几何信息可以是点的三维坐标信息(x,y,z)。点的属性信息可以包括颜色信息和/或反射率等等。例如,反射率可以是一维反射率信息(r);颜色信息可以是任意一种色彩空间上的信息,或者颜色信息也可以是三维颜色信息,如RGB信息。在这里,R表示红色(Red,R),G表示绿色(Green,G),B表示蓝色(Blue,B)。再如,颜色信息可以是亮度色度(YCbCr,YUV)信息。其中,Y表示明亮度(Luma),Cb(U)表示蓝色色差,Cr(V)表示红色色差。Two-dimensional images have information expressed at each pixel point, and the distribution is regular, so there is no need to record its position information additionally; however, the distribution of points in point clouds in three-dimensional space is random and irregular, so it is necessary to record the position of each point in space in order to fully express a point cloud. Similar to two-dimensional images, each position in the acquisition process has corresponding attribute information, usually RGB color values, and the color value reflects the color of the object; for point clouds, in addition to color information, the attribute information corresponding to each point is also commonly the reflectance value, which reflects the surface material of the object. Therefore, point cloud data usually includes the position information of the point and the attribute information of the point. Among them, the position information of the point can also be called the geometric information of the point. For example, the geometric information of the point can be the three-dimensional coordinate information of the point (x, y, z). The attribute information of the point can include color information and/or reflectivity, etc. For example, reflectivity can be one-dimensional reflectivity information (r); color information can be information on any color space, or color information can also be three-dimensional color information, such as RGB information. Here, R represents red (Red, R), G represents green (Green, G), and B represents blue (Blue, B). For another example, the color information may be luminance and chrominance (YCbCr, YUV) information, where Y represents brightness (Luma), Cb (U) represents blue color difference, and Cr (V) represents red color difference.
根据激光测量原理得到的点云,点云中的点可以包括点的三维坐标信息和点的反射率值。再如,根据摄影测量原理得到的点云,点云中的点可以可包括点的三维坐标信息和点的三维颜色信息。再如,结合激光测量和摄影测量原理得到点云,点云中的点可以可包括点的三维坐标信息、点的反射率值和点的三维颜色信息。 For a point cloud obtained according to the principle of laser measurement, the points in the point cloud may include the three-dimensional coordinate information of the points and the reflectivity value of the points. For another example, for a point cloud obtained according to the principle of photogrammetry, the points in the point cloud may include the three-dimensional coordinate information of the points and the three-dimensional color information of the points. For another example, a point cloud obtained by combining the principles of laser measurement and photogrammetry may include the three-dimensional coordinate information of the points, the reflectivity value of the points and the three-dimensional color information of the points.
如图2A和图2B所示为一幅点云图像及其对应的数据存储格式。其中,图2A提供了点云图像的六个观看角度,图2B则是由文件头信息部分和数据部分组成,头信息包含了数据格式、数据表示类型、点云总点数、以及点云所表示的内容。例如,点云为“.ply”格式,由ASCII码表示,总点数为207242,每个点具有三维坐标信息(x,y,z)和三维颜色信息(r,g,b)。As shown in Figure 2A and Figure 2B, a point cloud image and its corresponding data storage format are shown. Figure 2A provides six viewing angles of the point cloud image, and Figure 2B consists of a file header information part and a data part. The header information includes the data format, data representation type, the total number of point cloud points, and the content represented by the point cloud. For example, the point cloud is in the ".ply" format, represented by ASCII code, with a total number of 207242 points, and each point has three-dimensional coordinate information (x, y, z) and three-dimensional color information (r, g, b).
点云可以按获取的途径分为:Point clouds can be divided into the following categories according to the way they are obtained:
静态点云:即物体是静止的,获取点云的设备也是静止的;Static point cloud: the object is stationary, and the device that obtains the point cloud is also stationary;
动态点云:物体是运动的,但获取点云的设备是静止的;Dynamic point cloud: The object is moving, but the device that obtains the point cloud is stationary;
动态获取点云:获取点云的设备是运动的。Dynamic point cloud acquisition: The device used to acquire the point cloud is in motion.
例如,按点云的用途分为两大类:For example, point clouds can be divided into two categories according to their usage:
类别一:机器感知点云,其可以用于自主导航系统、实时巡检系统、地理信息系统、视觉分拣机器人、抢险救灾机器人等场景;Category 1: Machine perception point cloud, which can be used in autonomous navigation systems, real-time inspection systems, geographic information systems, visual sorting robots, disaster relief robots, etc.
类别二:人眼感知点云,其可以用于数字文化遗产、自由视点广播、三维沉浸通信、三维沉浸交互等点云应用场景。Category 2: Point cloud perceived by the human eye, which can be used in point cloud application scenarios such as digital cultural heritage, free viewpoint broadcasting, 3D immersive communication, and 3D immersive interaction.
点云可以灵活方便地表达三维物体或场景的空间结构及表面属性,并且由于点云通过直接对真实物体采样获得,在保证精度的前提下能提供极强的真实感,因而应用广泛,其范围包括虚拟现实游戏、计算机辅助设计、地理信息系统、自动导航系统、数字文化遗产、自由视点广播、三维沉浸远程呈现、生物组织器官三维重建等。Point clouds can flexibly and conveniently express the spatial structure and surface properties of three-dimensional objects or scenes. Point clouds are obtained by directly sampling real objects, so they can provide a strong sense of reality while ensuring accuracy. Therefore, they are widely used, including virtual reality games, computer-aided design, geographic information systems, automatic navigation systems, digital cultural heritage, free viewpoint broadcasting, three-dimensional immersive remote presentation, and three-dimensional reconstruction of biological tissues and organs.
点云的采集主要有以下途径:计算机生成、3D激光扫描、3D摄影测量等。计算机可以生成虚拟三维物体及场景的点云;3D激光扫描可以获得静态现实世界三维物体或场景的点云,每秒可以获取百万级点云;3D摄影测量可以获得动态现实世界三维物体或场景的点云,每秒可以获取千万级点云。这些技术降低了点云数据获取成本和时间周期,提高了数据的精度。点云数据获取方式的变革,使大量点云数据的获取成为可能,伴随着应用需求的增长,海量3D点云数据的处理遭遇存储空间和传输带宽限制的瓶颈。Point clouds can be collected mainly through the following methods: computer generation, 3D laser scanning, 3D photogrammetry, etc. Computers can generate point clouds of virtual three-dimensional objects and scenes; 3D laser scanning can obtain point clouds of static real-world three-dimensional objects or scenes, and can obtain millions of point clouds per second; 3D photogrammetry can obtain point clouds of dynamic real-world three-dimensional objects or scenes, and can obtain tens of millions of point clouds per second. These technologies reduce the cost and time cycle of point cloud data acquisition and improve the accuracy of data. The change in the way point cloud data is acquired makes it possible to acquire a large amount of point cloud data. With the growth of application demand, the processing of massive 3D point cloud data encounters bottlenecks in storage space and transmission bandwidth.
示例性地,以帧率为30帧每秒(fps)的点云视频为例,每帧点云的点数为70万,每个点具有坐标信息xyz(float)和颜色信息RGB(uchar),则10s点云视频的数据量大约为0.7million×(4Byte×3+1Byte×3)×30fps×10s=3.15GB,其中,1Byte为10bit;而YUV采样格式为4:2:0,帧率为24fps的1280×720二维视频,其10s的数据量约为1280×720×12bit×24fps×10s≈0.33GB,10s的两视角三维视频的数据量约为0.33×2=0.66GB。由此可见,点云视频的数据量远超过相同时长的二维视频和三维视频的数据量。因此,为更好地实现数据管理,节省服务器存储空间,降低服务器与客户端之间的传输流量及传输时间,点云压缩成为促进点云产业发展的关键问题。For example, taking a point cloud video with a frame rate of 30 frames per second (fps) as an example, the number of points in each point cloud frame is 700,000, and each point has coordinate information xyz (float) and color information RGB (uchar). The data volume of a 10s point cloud video is about 0.7 million × (4Byte × 3 + 1Byte × 3) × 30fps × 10s = 3.15GB, where 1Byte is 10bit; and a 1280 × 720 two-dimensional video with a YUV sampling format of 4:2:0 and a frame rate of 24fps, the data volume of 10s is about 1280 × 720 × 12bit × 24fps × 10s ≈ 0.33GB, and the data volume of a 10s two-view three-dimensional video is about 0.33 × 2 = 0.66GB. It can be seen that the data volume of a point cloud video far exceeds that of a two-dimensional video and a three-dimensional video of the same length. Therefore, in order to better realize data management, save server storage space, and reduce the transmission traffic and transmission time between the server and the client, point cloud compression has become a key issue in promoting the development of the point cloud industry.
也就是说,由于点云是海量点的集合,存储点云不仅会消耗大量的内存,而且不利于传输,也没有这么大的带宽可以支持将点云不经过压缩直接在网络层进行传输,因此,需要对点云进行压缩。That is to say, since the point cloud is a collection of massive points, storing the point cloud will not only consume a lot of memory, but also be inconvenient for transmission. There is also not enough bandwidth to support direct transmission of the point cloud at the network layer without compression. Therefore, the point cloud needs to be compressed.
目前,可对点云进行压缩的点云编码框架可以是运动图像专家组(Moving Picture Experts Group,MPEG)提供的基于几何的点云压缩(Geometry-based Point Cloud Compression,G-PCC)编解码框架或基于视频的点云压缩(Video-based Point Cloud Compression,V-PCC)编解码框架,也可以是AVS提供的AVS-PCC编解码框架。G-PCC编解码框架可用于针对第一类静态点云和第三类动态获取点云进行压缩,其可以是基于点云压缩测试平台(Test Model Compression 13,TMC13),V-PCC编解码框架可用于针对第二类动态点云进行压缩,其可以是基于点云压缩测试平台(Test Model Compression 2,TMC2)。故G-PCC编解码框架也称为点云编解码器TMC13,V-PCC编解码框架也称为点云编解码器TMC2。At present, the point cloud coding framework that can compress point clouds can be the geometry-based point cloud compression (G-PCC) codec framework or the video-based point cloud compression (V-PCC) codec framework provided by the Moving Picture Experts Group (MPEG), or the AVS-PCC codec framework provided by AVS. The G-PCC codec framework can be used to compress the first type of static point cloud and the third type of dynamically acquired point cloud, which can be based on the point cloud compression test platform (Test Model Compression 13, TMC13), and the V-PCC codec framework can be used to compress the second type of dynamic point cloud, which can be based on the point cloud compression test platform (Test Model Compression 2, TMC2). Therefore, the G-PCC codec framework is also called the point cloud codec TMC13, and the V-PCC codec framework is also called the point cloud codec TMC2.
本申请实施例提供了一种包含解码方法和编码方法的点云编解码系统的网络架构,图3为一种点云编解码的网络架构示意图。如图3所示,该网络架构包括一个或多个电子设备13至1N和通信网络01,其中,电子设备13至1N可以通过通信网络01进行视频交互。电子设备在实施的过程中可以为各种类型的具有点云编解码功能的设备,例如,所述电子设备可以包括手机、平板电脑、个人计算机、个人数字助理、导航仪、数字电话、视频电话、电视机、传感设备、服务器等,本申请实施例不作限制。其中,本申请实施例中的解码器或编码器就可以为上述电子设备。The embodiment of the present application provides a network architecture of a point cloud encoding and decoding system including a decoding method and an encoding method. FIG3 is a schematic diagram of a network architecture of point cloud encoding and decoding. As shown in FIG3, the network architecture includes one or more electronic devices 13 to 1N and a communication network 01, wherein the electronic devices 13 to 1N can perform video interaction through the communication network 01. During the implementation process, the electronic device can be various types of devices with point cloud encoding and decoding functions. For example, the electronic device can include a mobile phone, a tablet computer, a personal computer, a personal digital assistant, a navigator, a digital phone, a video phone, a television, a sensor device, a server, etc., which is not limited by the embodiment of the present application. Among them, the decoder or encoder in the embodiment of the present application can be the above-mentioned electronic device.
其中,本申请实施例中的电子设备具有点云编解码功能,一般包括点云编码器(即编码器)和点云解码器(即解码器)。Among them, the electronic device in the embodiment of the present application has a point cloud encoding and decoding function, generally including a point cloud encoder (ie, encoder) and a point cloud decoder (ie, decoder).
下面以G-PCC编解码框架为例进行相关技术的详细介绍。The following takes the G-PCC codec framework as an example to introduce the relevant technologies in detail.
可以理解,在点云G-PCC编解码框架中,针对待编码的点云数据,首先通过片(slice)划分,将点云数据划分为多个slice。在每一个slice中,点云的几何信息和每个点所对应的属性信息是分开进行编码的。It can be understood that in the point cloud G-PCC encoding and decoding framework, for the point cloud data to be encoded, the point cloud data is first divided into multiple slices by slice division. In each slice, the geometric information of the point cloud and the attribute information corresponding to each point are encoded separately.
图4为一种G-PCC编码器的组成框架示意图。如图4所示,在该G-PCC编码框架中,针对待编码 的点云数据,首先通过slice划分,将点云数据划分为多个slice。在每一个slice中,点云的几何信息和每个点云所对应的属性信息是分开进行编码的。在几何编码过程中,对几何信息进行坐标转换,使点云全都包含在一个Bounding Box中,然后再进行量化,这一步量化主要起到缩放的作用,由于量化取整,使得一部分点云的几何信息相同,于是再基于参数来决定是否移除重复点,量化和移除重复点这一过程又被称为体素化过程。接着对Bounding Box进行八叉树划分。在基于八叉树的几何信息编码流程中,将包围盒八等分为8个子立方体,对非空的(包含点云中的点)的子立方体继续进行八等分,直到划分得到的叶子结点为1×1×1的单位立方体时停止划分,对叶子结点中的点进行算术编码,生成二进制的几何比特流,即几何码流。在基于三角面片集(Triangle soup,Trisoup)的几何信息编码过程中,同样也要先进行八叉树划分,但区别于基于八叉树的几何信息编码,该Trisoup不需要将点云逐级划分到边长为1×1×1的单位立方体,而是划分到子块(Block)边长为W时停止划分,基于每个Block种点云的分布所形成的表面,得到该表面与block的十二条边所产生的至多十二个交点(Vertex),对Vertex进行算术编码(基于交点进行表面拟合),生成二进制的几何比特流,即几何码流。Vertex还用于在几何重建的过程的实现,而重建的集合信息在对点云的属性编码时使用。FIG4 is a schematic diagram of a composition framework of a G-PCC encoder. As shown in FIG4, in the G-PCC encoding framework, for the code to be encoded The point cloud data is first divided into multiple slices through slice division. In each slice, the geometric information of the point cloud and the attribute information corresponding to each point cloud are encoded separately. In the process of geometric encoding, the coordinate transformation of the geometric information is performed so that all the point clouds are contained in a Bounding Box, and then quantization is performed. This step of quantization mainly plays a role in scaling. Due to the quantization rounding, the geometric information of a part of the point cloud is the same, so it is decided whether to remove duplicate points based on parameters. The process of quantization and removal of duplicate points is also called voxelization. Then the Bounding Box is divided into octrees. In the octree-based geometric information encoding process, the bounding box is divided into 8 sub-cubes in eight equal parts, and the non-empty (containing points in the point cloud) sub-cubes are further divided into eight equal parts until the leaf node obtained by division is a 1×1×1 unit cube. The division is stopped, and the points in the leaf nodes are arithmetically encoded to generate a binary geometric bit stream, that is, a geometric code stream. In the process of geometric information encoding based on triangle soup (Trisoup), octree division must also be performed first. However, unlike the geometric information encoding based on octree, the Trisoup does not need to divide the point cloud into unit cubes with a side length of 1×1×1 step by step. Instead, the division stops when the sub-block (Block) has a side length of W. Based on the surface formed by the distribution of the point cloud in each Block, the surface and the twelve edges of the block are used to obtain at most twelve intersections (Vertex). The Vertex is arithmetically encoded (surface fitting is performed based on the intersections) to generate a binary geometric bit stream, i.e., a geometric code stream. Vertex is also used to implement the process of geometric reconstruction, and the reconstructed set information is used when encoding the attributes of the point cloud.
在属性编码过程中,几何编码完成,对几何信息进行重建后,这时候进行颜色转换,将颜色信息(即属性信息)从RGB颜色空间转换到YUV颜色空间。然后,利用重建的几何信息对点云重新着色,使得未编码的属性信息与重建的几何信息对应起来。属性编码主要针对颜色信息进行,在颜色信息编码过程中,主要有两种变换方法,一是依赖于LOD划分的基于距离的提升变换,二是直接进行RAHT变换,这两种方法都会将颜色信息从空间域转换到频域,通过变换得到高频系数和低频系数,最后对系数进行量化(即量化系数),最后,将经过八叉树划分及表面拟合的几何编码数据与量化系数处理属性编码数据进行slice合成后,依次编码每个Block的Vertex坐标(即算术编码),生成二进制的属性比特流,即属性码流。In the attribute encoding process, after the geometric encoding is completed and the geometric information is reconstructed, color conversion is performed to convert the color information (i.e., attribute information) from the RGB color space to the YUV color space. Then, the point cloud is recolored using the reconstructed geometric information so that the unencoded attribute information corresponds to the reconstructed geometric information. Attribute encoding is mainly performed on color information. In the color information encoding process, there are two main transformation methods: one is the distance-based lifting transformation that relies on LOD division, and the other is direct RAHT transformation. Both methods will convert color information from the spatial domain to the frequency domain, and obtain high-frequency coefficients and low-frequency coefficients through transformation. Finally, the coefficients are quantized (i.e., quantized coefficients). Finally, the geometric encoding data after octree division and surface fitting and the attribute encoding data processed by quantization coefficients are sliced and synthesized, and the Vertex coordinates of each Block are encoded in turn (i.e., arithmetic coding) to generate a binary attribute bit stream, i.e., attribute code stream.
图5为一种G-PCC解码器的组成框架示意图。如图5所示,在该G-PCC解码框架中,针对所获取的二进制码流,首先对二进制码流中的几何比特流和属性比特流分别进行独立解码。在对几何比特流的解码时,通过算术解码-八叉树合成-表面拟合-重建几何-逆坐标转换,得到点云的几何信息;在对属性比特流的解码时,通过算术解码-反量化-基于LOD的提升逆变换或者基于RAHT的逆变换-逆颜色转换,得到点云的属性信息,基于几何信息和属性信息还原待编码的点云数据的三维图像模型。FIG5 is a schematic diagram of the composition framework of a G-PCC decoder. As shown in FIG5, in the G-PCC decoding framework, for the acquired binary code stream, the geometric bit stream and the attribute bit stream in the binary code stream are first decoded independently. When decoding the geometric bit stream, the geometric information of the point cloud is obtained through arithmetic decoding-octree synthesis-surface fitting-reconstruction of geometry-inverse coordinate conversion; when decoding the attribute bit stream, the attribute information of the point cloud is obtained through arithmetic decoding-inverse quantization-LOD-based lifting inverse transform or RAHT-based inverse transform-inverse color conversion, and the three-dimensional image model of the point cloud data to be encoded is restored based on the geometric information and attribute information.
还可以理解,对于点云属性信息的RAHT编码来说,图6为一种RAHT编码的流程示意图。如图6所示,对于原始点云(或称为“初始点云”),可以进行帧内预测或者帧间预测。其中,在帧内预测过程中,对原始点云进行上采样预测,可以得到预测点云,然后进行RAHT变换能够确定预测AC系数;在帧间预测过程中,根据原始点云的相邻帧,可以得到参考点云,然后进行RAHT变换也能够确定预测AC系数。对于原始点云进行RAHT变换可以确定根节点的DC系数和原始AC系数;对原始AC系数与预测AC系数进行减法运算,可以得到预测残差,在对预测残差进行量化与熵编码之后,就可以生成属性码流。It can also be understood that for the RAHT encoding of point cloud attribute information, Figure 6 is a schematic diagram of the RAHT encoding process. As shown in Figure 6, for the original point cloud (or referred to as the "initial point cloud"), intra-frame prediction or inter-frame prediction can be performed. Among them, in the intra-frame prediction process, the original point cloud is upsampled and predicted to obtain a predicted point cloud, and then a RAHT transform is performed to determine the predicted AC coefficient; in the inter-frame prediction process, a reference point cloud can be obtained based on the adjacent frames of the original point cloud, and then a RAHT transform can also determine the predicted AC coefficient. Performing a RAHT transform on the original point cloud can determine the DC coefficient and the original AC coefficient of the root node; subtracting the original AC coefficient from the predicted AC coefficient can obtain a predicted residual, and after quantizing and entropy encoding the predicted residual, an attribute code stream can be generated.
在这里,RAHT变换基于哈尔小波变换,其核心是对于分层的树结构,从根节点到子节点自下而上递归变换,变换所得的DC系数传递给下一层,AC系数进行量化与编码。主要的编码过程是:首先根据点云划分的八叉树结构,判断其是否使用上采样预测或帧间预测;其次从根节点到子节点自下而上进行递归变化得到逐层的AC系数,若有预测,则将预测AC系数与原始AC系数作差得到当前的预测残差;最后,对AC系数的预测残差进行量化与编码,生成属性码流。Here, RAHT transform is based on Haar wavelet transform, and its core is to recursively transform the hierarchical tree structure from the root node to the child node from bottom to top, and pass the transformed DC coefficient to the next layer, and the AC coefficient is quantized and encoded. The main encoding process is: first, according to the octree structure divided by the point cloud, determine whether it uses upsampling prediction or inter-frame prediction; secondly, recursively change from the root node to the child node from bottom to top to obtain the AC coefficient of each layer. If there is a prediction, the predicted AC coefficient is subtracted from the original AC coefficient to obtain the current prediction residual; finally, the prediction residual of the AC coefficient is quantized and encoded to generate an attribute code stream.
还可以理解,在本申请实施例中,一个视频帧可以理解为一幅图像。示例性地,当前帧可以理解为当前图像,参考帧可以理解为参考图像。It can also be understood that in the embodiment of the present application, a video frame can be understood as an image. Exemplarily, the current frame can be understood as the current image, and the reference frame can be understood as the reference image.
在一种具体的实现方式中,RAHT编码的详细步骤如下:In a specific implementation, the detailed steps of RAHT encoding are as follows:
步骤1、RAHT变换。Step 1: RAHT transformation.
G-PCC采用的RAHT变换方法,首先基于划分的八叉树结构,从父节点到子节点自下而上沿着每一个维度进行递归变换,变换过程由以下式子得到:
The RAHT transformation method adopted by G-PCC first performs a recursive transformation from parent nodes to child nodes along each dimension from bottom to top based on the divided octree structure. The transformation process is obtained by the following formula:
其中,wi,j为第i层第j个待变换节点的权重,gi,j为叶子结点的属性值,hi,j为AC系数,hi,j为DC系数。每次变换后,将DC系数直接传给下一层,AC系数进行量化与熵编码;若该层只有一个点时,直 接将该点的属性值当做DC系数传给下一层。对于RAHT变换,图7A为一种当前节点的结构示意图,其中,网格填充的立方体为当前节点,斜线填充的立方体为当前节点的邻居节点。图7B为一种子节点的结构示意图,具体如点填充的小立方体为当前节点的子节点。另外,图8为一种基于变换方向的RAHT变换示意图。如图8所示,黑色箭头表示变换方向,按照八叉树结构,采用自下向上的方式对每一层中的节点分别沿变换方向(例如x轴方向、y轴方向、z轴方向等)的维度进行变换。在变换过程中,同一层节点变换之后的DC系数将传递到下一层,而每一层变换后的AC系数将进行量化与熵编码。Among them, w i,j is the weight of the jth node to be transformed in the i-th layer, g i,j is the attribute value of the leaf node, h i,j is the AC coefficient, and h i,j is the DC coefficient. After each transformation, the DC coefficient is directly passed to the next layer, and the AC coefficient is quantized and entropy coded; if there is only one point in the layer, The attribute value of the point is then passed to the next layer as the DC coefficient. For the RAHT transform, Figure 7A is a schematic diagram of the structure of a current node, wherein the cube filled with a grid is the current node, and the cube filled with a diagonal line is the neighbor node of the current node. Figure 7B is a schematic diagram of the structure of a child node, specifically, the small cube filled with dots is the child node of the current node. In addition, Figure 8 is a schematic diagram of a RAHT transform based on the transformation direction. As shown in Figure 8, the black arrow indicates the transformation direction. According to the octree structure, the nodes in each layer are transformed along the dimensions of the transformation direction (for example, the x-axis direction, the y-axis direction, the z-axis direction, etc.) in a bottom-up manner. During the transformation process, the DC coefficient of the nodes in the same layer after transformation will be passed to the next layer, and the AC coefficient of each layer after transformation will be quantized and entropy encoded.
步骤2,上采样预测。Step 2, upsample prediction.
为了进一步去除冗余,提高点的压缩效率,引入了上采样预测的方法。上采样预测的核心是帧内预测,利用已编码好的点的属性信息,来预测当前点的属性信息,从而得到预测AC系数。随后通过编码预测AC系数与原始AC系数之间的预测残差来达到去除冗余的目的。In order to further remove redundancy and improve the compression efficiency of points, the upsampling prediction method is introduced. The core of upsampling prediction is intra-frame prediction, which uses the attribute information of the encoded points to predict the attribute information of the current point, thereby obtaining the predicted AC coefficient. Then, the prediction residual between the predicted AC coefficient and the original AC coefficient is encoded to achieve the purpose of removing redundancy.
RAHT变换的树结构由自下而上变为自上而下,变换仍在一个2×2×2的块内进行。利用其父节点以及父节点的共面、共线邻居节点的重建属性值对这些子节点进行属性预测得到子节点的预测属性值。对这些块内子节点的原始属性值和预测属性值分别进行RAHT变换得到相应的DC系数和AC系数,将真实属性得到的AC系数与预测属性得到的AC系数进行差分得到预测残差进行量化及熵编码,具体过程如图9所示。The tree structure of RAHT transformation changes from bottom-up to top-down, and the transformation is still performed in a 2×2×2 block. The attributes of these child nodes are predicted using the reconstructed attribute values of their parent nodes and the coplanar and colinear neighbor nodes of the parent nodes to obtain the predicted attribute values of the child nodes. The original attribute values and predicted attribute values of the child nodes in these blocks are RAHT transformed to obtain the corresponding DC coefficients and AC coefficients, and the AC coefficients obtained by the real attributes are differentiated from the AC coefficients obtained by the predicted attributes to obtain the prediction residuals for quantization and entropy coding. The specific process is shown in Figure 9.
在进行RAHT逆变换时,DC系数继承上一层父节点的重建属性值,将解码端得到的AC系数残差与上采样预测属性值变换得到的预测AC系数进行累加,再与继承得到的DC系数一起进行RAHT逆变换,就可以得到重建属性值,具体过程如图10所示。When performing the RAHT inverse transform, the DC coefficient inherits the reconstructed attribute value of the parent node in the previous layer. The AC coefficient residual obtained at the decoding end is accumulated with the predicted AC coefficient obtained by the upsampling predicted attribute value transformation, and then the RAHT inverse transform is performed together with the inherited DC coefficient to obtain the reconstructed attribute value. The specific process is shown in Figure 10.
步骤3,帧间预测。Step 3: inter-frame prediction.
帧间预测是利用已经编码的参考图像信息,对当前图像进行预测编码,以达到减少冗余的作用。将参考图像进行八叉树结构划分,参考图像经过RAHT变换后,记忆每个参考节点的AC系数,以进行下一帧的帧间预测。在目标节点的编码中,利用参考图像和当前图像的系数计算系数残差,并对系数残差进行熵编码。解码器具有相同的过程。在这里,帧间预测过程如图11所示。Inter-frame prediction is to use the information of the already encoded reference image to predict the current image to reduce redundancy. The reference image is divided into an octree structure. After the reference image is transformed by RAHT, the AC coefficients of each reference node are memorized to perform inter-frame prediction for the next frame. In the encoding of the target node, the coefficients of the reference image and the current image are used to calculate the coefficient residual, and the coefficient residual is entropy encoded. The decoder has the same process. Here, the inter-frame prediction process is shown in Figure 11.
只有在当前的点云和参考点云具有相同的八叉树划分结构且在相同位置节点时,才会应用帧间预测。如果参考缓冲区中不存在预测系数值,则不应用帧间预测。如果参考缓冲区中不存在相应的AC系数,则不应用帧间预测。Inter prediction is applied only when the current point cloud and the reference point cloud have the same octree partitioning structure and are at the same position node. If there is no prediction coefficient value in the reference buffer, inter prediction is not applied. If there is no corresponding AC coefficient in the reference buffer, inter prediction is not applied.
步骤4,编码系数残差及残差RDOQ。Step 4, encode coefficient residual and residual RDOQ.
通过上述帧内预测或帧间预测得到当前2×2×2的块中每点的预测属性值,对这些块内子节点的真实属性值和预测属性值分别进行RAHT变换得到相应的DC系数和AC系数,针对所得到的第i个预测AC系数(k为8)。令(ACi)i∈1…k-1为第i个原始AC系数(即真实AC系数),则编码AC系数残差(ri)i∈0…k-1记为:
The predicted attribute value of each point in the current 2×2×2 block is obtained through the above intra-frame prediction or inter-frame prediction. The real attribute value and predicted attribute value of the child nodes in these blocks are respectively subjected to RAHT transformation to obtain the corresponding DC coefficient and AC coefficient. For the i-th predicted AC coefficient (k is 8). Let (AC i ) i∈1…k-1 be the i-th original AC coefficient (i.e., the true AC coefficient), then the coded AC coefficient residual (r i ) i∈0…k-1 is recorded as:
随后进行对于AC系数残差的率失真优化判断,若将该系数置为0的率失真代价RDcost小于原始编码的率失真代价RDcost,则将该系数置为0。Then, a rate-distortion optimization judgment is performed on the AC coefficient residual. If the rate-distortion cost RDcost of setting the coefficient to 0 is less than the rate-distortion cost RDcost of the original coding, the coefficient is set to 0.
进一步地,对RDO判断后的预测残差进行量化:
Furthermore, the prediction residual after RDO judgment is quantified:
其中,Qi表示当前点i的量化后的属性残差,Qs为量化步长(Quantization step,Qs),可以由CTC规定的量化参数(Quantization Parameter,QP)计算得出。Among them, Qi represents the quantized attribute residual of the current point i, and Qs is the quantization step (Quantization step, Qs), which can be calculated by the quantization parameter (Quantization Parameter, QP) specified by CTC.
步骤5,编码端重建属性值。Step 5: The encoding end reconstructs the attribute value.
编码端重建的目的是为了后续点的预测。在重建属性值之前,需要对编码AC残差进行反量化,记为反量化后的残差:
The purpose of reconstruction at the encoding end is to predict subsequent points. Before reconstructing the attribute value, the encoded AC residual needs to be dequantized. is the residual after inverse quantization:
与预测AC系数相加可以得到当前块内的第i个重建AC系数具体如下:
and predicted AC coefficient Adding together can get the i-th reconstructed AC coefficient in the current block The details are as follows:
最后对重建AC系数与在上一层父节点继承得到的DC系数一起进行RAHT逆变换,即可得到重建属性值。Finally, the AC coefficients are reconstructed The reconstructed attribute value can be obtained by performing an inverse RAHT transform together with the DC coefficient inherited from the parent node in the previous layer.
也就是说,在相关技术中,RAHT目前是从根节点开始向子节点进行逐层计算、量化与编码的。由于从叶节点到根节点,每一层的直流分量及其属性信息是逐层累积的,使得根节点变换所得的编码AC系数值较大,而随着层数的增加,变换所得的编码AC系数值逐渐减少,以至于在雷达点云的最后几层,经RDOQ和属性量化后的AC系数出现了大量的0。经统计,点云后几层AC系数中0的个数占据了95%以上。然而,雷达点云最后几层AC系数的个数又占据了全部AC系数的大半;因此对最后几层AC系数的编码必然有很大的码流浪费。 That is to say, in the relevant technology, RAHT currently calculates, quantizes and encodes layer by layer from the root node to the child node. Since the DC component and its attribute information of each layer are accumulated layer by layer from the leaf node to the root node, the encoded AC coefficient value obtained by the root node transformation is relatively large, and as the number of layers increases, the encoded AC coefficient value obtained by the transformation gradually decreases, so that in the last few layers of the radar point cloud, a large number of 0s appear in the AC coefficients after RDOQ and attribute quantization. According to statistics, the number of 0s in the AC coefficients of the last few layers of the point cloud accounts for more than 95%. However, the number of AC coefficients in the last few layers of the radar point cloud accounts for more than half of all AC coefficients; therefore, the encoding of the AC coefficients of the last few layers will inevitably result in a large waste of code streams.
基于此,本申请实施例提供了一种编码方法,确定第一编码参数的取值;在第一编码参数指示对当前点云的k个变换层进行跳跃编码时,确定k个变换层的一个或多个交流系数残差值为预设数值;对k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,将所得到的编码比特写入码流。本申请实施例还提供了一种解码方法,确定第一解码参数的取值;在第一解码参数指示对当前点云的k个变换层进行跳跃解码时,确定k个变换层的一个或多个交流系数残差值为预设数值;解码码流,确定当前点云中k个变换层之外其他变换层的交流系数残差值;根据k个变换层的交流系数残差值和其他变换层的交流系数残差值,确定当前点云的重建点云。Based on this, an embodiment of the present application provides an encoding method to determine the value of a first encoding parameter; when the first encoding parameter indicates that the k transformation layers of the current point cloud are to be skip encoded, one or more residual values of the AC coefficients of the k transformation layers are determined to be preset values; one or more residual values of the AC coefficients of the k transformation layers are encoded according to the preset values, and the obtained encoded bits are written into the code stream. An embodiment of the present application also provides a decoding method to determine the value of a first decoding parameter; when the first decoding parameter indicates that the k transformation layers of the current point cloud are to be skip decoded, one or more residual values of the AC coefficients of the k transformation layers are determined to be preset values; the code stream is decoded to determine the residual values of the AC coefficients of other transformation layers other than the k transformation layers in the current point cloud; based on the residual values of the AC coefficients of the k transformation layers and the residual values of the AC coefficients of the other transformation layers, the reconstructed point cloud of the current point cloud is determined.
也就是说,无论是编码端还是解码端,在确定对当前点云的k个变换层进行跳跃编码时,这时候直接将这k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,可以有效改善RAHT变换中最后几层编码AC系数值出现过多0的现象,从而提高了编解码效率,而且实现了解码端重建点云在平均码率下的质量增强,进而能够提升点云的编解码性能。That is to say, whether it is the encoding end or the decoding end, when it is determined to skip encoding the k transformation layers of the current point cloud, one or more AC coefficient residual values of these k transformation layers are directly encoded according to the preset values. This can effectively improve the phenomenon of too many 0s in the AC coefficient values of the last few layers of encoding in the RAHT transform, thereby improving the encoding and decoding efficiency, and achieving quality enhancement of the reconstructed point cloud at the average bit rate at the decoding end, thereby improving the encoding and decoding performance of the point cloud.
下面将结合附图对本申请各实施例进行详细说明。The embodiments of the present application will be described in detail below with reference to the accompanying drawings.
在本申请的一实施例中,图12为本申请实施例提供的一种解码方法的流程示意图一。如图12所示,该方法可以包括:In one embodiment of the present application, FIG12 is a flowchart of a decoding method provided by the embodiment of the present application. As shown in FIG12, the method may include:
S1201,确定第一解码参数的取值。S1201: Determine a value of a first decoding parameter.
需要说明的是,在本申请实施例中,该方法应用于点云解码器(可简称为“解码器”)。这里,主要是提供了一种点云解码方法,更具体地,是一种面向RAHT变换系数的跳跃解码方法,能够改善RAHT变换中最后几层编码AC系数值出现过多0的现象。It should be noted that in the embodiment of the present application, the method is applied to a point cloud decoder (hereinafter referred to as "decoder"). Here, a point cloud decoding method is mainly provided, more specifically, a skip decoding method for RAHT transform coefficients, which can improve the phenomenon that too many 0s appear in the last few layers of coded AC coefficient values in RAHT transform.
还需要说明的是,在本申请实施例中,对于第一解码参数来说,第一解码参数可以用于指示对当前点云的k个变换层是否进行跳跃解码。在一些实施例中,若第一解码参数的取值为第一值,则确定第一解码参数指示对当前点云的k个变换层进行跳跃解码;若第一解码参数的取值为第二值,则确定第一解码参数指示对当前点云的k个变换层不进行跳跃解码。其中,k是大于零的整数。It should also be noted that, in the embodiment of the present application, for the first decoding parameter, the first decoding parameter can be used to indicate whether to perform jump decoding on the k transform layers of the current point cloud. In some embodiments, if the value of the first decoding parameter is a first value, it is determined that the first decoding parameter indicates that the k transform layers of the current point cloud are to be skipped and decoded; if the value of the first decoding parameter is a second value, it is determined that the first decoding parameter indicates that the k transform layers of the current point cloud are not to be skipped and decoded. Wherein, k is an integer greater than zero.
在一些实施例中,对于确定第一解码参数的取值,该方法可以包括:解码码流,确定第一解码参数的取值。In some embodiments, for determining the value of the first decoding parameter, the method may include: decoding a bitstream, and determining the value of the first decoding parameter.
需要说明的是,在本申请实施例中,第一解码参数可以用语法元素的形式表示,此时第一解码参数可以称为第一语法元素,用flagzero表示。换句话说,在本申请实施例中,这里也可以是:解码码流,确定第一语法元素的取值。其中,第一语法元素也可以用于指示对当前点云的k个变换层是否进行跳跃解码。若第一语法元素的取值为第一值,则确定对当前点云的k个变换层进行跳跃解码;若第一语法元素的取值为第二值,则确定对当前点云的k个变换层不进行跳跃解码。It should be noted that, in the embodiment of the present application, the first decoding parameter can be expressed in the form of a syntax element. In this case, the first decoding parameter can be called the first syntax element, represented by flagzero. In other words, in the embodiment of the present application, it can also be: decode the code stream and determine the value of the first syntax element. Among them, the first syntax element can also be used to indicate whether to skip decode the k transform layers of the current point cloud. If the value of the first syntax element is the first value, it is determined that the k transform layers of the current point cloud are skip decoded; if the value of the first syntax element is the second value, it is determined that the k transform layers of the current point cloud are not skip decoded.
还需要说明的是,在本申请实施例中,第一值与第二值不同。其中,第一值可以设置为大于零的整数,例如1,2,3,…等;第二值可以设置为0。It should also be noted that in the embodiment of the present application, the first value is different from the second value. The first value can be set to an integer greater than zero, such as 1, 2, 3, etc.; the second value can be set to 0.
可以理解,k的取值与第一值之间具有关联关系。在一种具体的实施例中,该方法还包括:在第一解码参数指示对当前点云的k个变换层进行跳跃解码时,可以将k的取值设置为等于第一值。It can be understood that there is an association between the value of k and the first value. In a specific embodiment, the method further includes: when the first decoding parameter indicates to perform skip decoding on k transform layers of the current point cloud, the value of k can be set to be equal to the first value.
还可以理解,对于码流来说,其可以包括几何码流单元、属性码流单元、属性参数集(Attribute Parameter Set,APS)单元等。在一些实施例中,解码码流,确定第一解码参数的取值,可以包括:解码码流中的属性码流单元,确定第一解码参数的取值。也就是说,在解码码流时,第一解码参数具体是位于码流中的属性码流单元。It can also be understood that, for a code stream, it may include a geometric code stream unit, an attribute code stream unit, an attribute parameter set (APS) unit, etc. In some embodiments, decoding the code stream and determining the value of the first decoding parameter may include: decoding the attribute code stream unit in the code stream and determining the value of the first decoding parameter. That is, when decoding the code stream, the first decoding parameter is specifically the attribute code stream unit located in the code stream.
S1202,在第一解码参数指示对当前点云的k个变换层进行跳跃解码时,确定k个变换层的一个或多个交流系数残差值为预设数值。S1202, when the first decoding parameter indicates to skip decoding the k transformation layers of the current point cloud, determine that one or more AC coefficient residual values of the k transformation layers are preset values.
需要说明的是,在本申请实施例中,预设数值可以设置为0。这样,如果确定对当前点云的k个变换层进行跳跃解码,那么这时候可以将k个变换层的一个或多个交流系数残差值按照0进行恢复。It should be noted that, in the embodiment of the present application, the preset value can be set to 0. In this way, if it is determined to perform skip decoding on the k transformation layers of the current point cloud, then one or more AC coefficient residual values of the k transformation layers can be restored to 0 at this time.
还需要说明的是,在本申请实施例中,k是大于零的整数。在确定对当前点云的k个变换层进行跳跃解码时,k的取值可以设置为等于所确定的第一解码参数的第一值,或者说是第一语法元素的第一值。It should also be noted that, in the embodiment of the present application, k is an integer greater than 0. When determining to perform skip decoding on k transform layers of the current point cloud, the value of k can be set to be equal to the first value of the determined first decoding parameter, or the first value of the first syntax element.
也就是说,对于解码第一解码参数来说,如果第一解码参数的第一值为k,那么可以确定对当前点云的k个变换层进行跳跃解码;如果第一解码参数的第二值为0,那么可以确定对当前点云的k个变换层不进行跳跃解码,即此时需要解码当前点云的全部变换层的交流系数残差值。That is to say, for decoding the first decoding parameter, if the first value of the first decoding parameter is k, then it can be determined that the k transform layers of the current point cloud will be skip decoded; if the second value of the first decoding parameter is 0, then it can be determined that the k transform layers of the current point cloud will not be skip decoded, that is, at this time it is necessary to decode the AC coefficient residual values of all transform layers of the current point cloud.
在一些实施例中,该方法还可以包括:解码码流,确定k个变换层的一个或多个交流系数残差值为预设数值。也就是说,在本申请实施例中,对于k个变换层的一个或多个交流系数残差值来说,这里是按照预设数值写入码流的。这样,解码端也需要解码码流,以确定出k个变换层的一个或多个交流系数残差值为预设数值。In some embodiments, the method may further include: decoding the bitstream, and determining that one or more residual values of the AC coefficients of the k transform layers are preset values. That is, in the embodiment of the present application, for one or more residual values of the AC coefficients of the k transform layers, the bitstream is written according to the preset values. In this way, the decoding end also needs to decode the bitstream to determine that one or more residual values of the AC coefficients of the k transform layers are preset values.
在一些实施例中,该方法还可以包括:确定k个变换层的全部交流系数残差值为预设数值。也就是 说,在本申请实施例中,对于确定k个变换层的一个或多个交流系数残差值来说,在确定对当前点云的k个变换层进行跳跃解码时,这时候也可以确定k个变换层的全部交流系数残差值为预设数值。In some embodiments, the method may further include: determining that all AC coefficient residual values of k transformation layers are preset values. That is, in an embodiment of the present application, for determining one or more AC coefficient residual values of k transformation layers, when determining to jump decode the k transformation layers of the current point cloud, it is also possible to determine that all AC coefficient residual values of the k transformation layers are preset values.
在一些实施例中,该方法还可以包括:对当前点云中的点进行层划分,确定当前点云对应的多个变换层以及当前点云的根节点;其中,多个变换层包括k个变换层和其他变换层。In some embodiments, the method may further include: dividing the points in the current point cloud into layers, determining multiple transformation layers corresponding to the current point cloud and the root node of the current point cloud; wherein the multiple transformation layers include k transformation layers and other transformation layers.
需要说明的是,在本申请实施例中,可以基于八叉树结构对当前点云中的点进行层划分,得到多个变换层。具体地,对于划分的八叉树结构,可以是从根节点到子节点自上向下进行每一层的变换。It should be noted that in the embodiment of the present application, the points in the current point cloud can be divided into layers based on the octree structure to obtain multiple transformation layers. Specifically, for the divided octree structure, each layer can be transformed from the root node to the child node from top to bottom.
还需要说明的是,在实际应用中,在当前点云的最后几层,这几层中交流系数残差值为0个个数占据95%以上。为了提升编解码效率,在一些实施例中,该方法还可以包括:将k个变换层设置为多个变换层中从根节点自上向下的最后k个变换层。It should also be noted that, in practical applications, in the last few layers of the current point cloud, the number of residual values of the AC coefficients in these layers that are 0 accounts for more than 95%. In order to improve the encoding and decoding efficiency, in some embodiments, the method may also include: setting the k transformation layers to be the last k transformation layers from the root node from top to bottom in the multiple transformation layers.
也就是说,这里主要是针对当前点云的最后k个变换层是否进行跳跃解码。示例性地,在第一解码参数指示对当前点云的最后k个变换层进行跳跃解码时,那么可以将最后k个变换层的一个或多个交流系数残差值按照0进行恢复,从而能够提升编解码效率。That is to say, here it is mainly about whether to perform skip decoding on the last k transform layers of the current point cloud. For example, when the first decoding parameter indicates to perform skip decoding on the last k transform layers of the current point cloud, then one or more AC coefficient residual values of the last k transform layers can be restored to 0, thereby improving the encoding and decoding efficiency.
S1203,解码码流,确定当前点云中k个变换层之外其他变换层的交流系数残差值。S1203, decoding the code stream, and determining the residual values of the AC coefficients of other transformation layers other than the k transformation layers in the current point cloud.
S1204,根据k个变换层的交流系数残差值和其他变换层的交流系数残差值,确定当前点云的重建点云。S1204, determining a reconstructed point cloud of the current point cloud according to the AC coefficient residual values of k transformation layers and the AC coefficient residual values of other transformation layers.
需要说明的是,在本申请实施例中,交流系数残差值是位于码流的属性码流单元中。在一些实施例中,该方法可以包括:解码码流中的属性码流单元,确定其他变换层的交流系数残差值。It should be noted that, in the embodiment of the present application, the AC coefficient residual value is located in the attribute code stream unit of the code stream. In some embodiments, the method may include: decoding the attribute code stream unit in the code stream to determine the AC coefficient residual value of other transform layers.
还需要说明的是,在本申请实施例中,当前点云对应的多个变换层可以包括k个变换层和除k个变换层之外的其他变换层。这样,根据k个变换层的交流系数残差值和其他变换层的交流系数残差值,也即根据多个变换层的交流系数残差值,确定当前点云的重建点云。It should also be noted that, in the embodiment of the present application, the multiple transformation layers corresponding to the current point cloud may include k transformation layers and other transformation layers except the k transformation layers. In this way, the reconstructed point cloud of the current point cloud is determined according to the residual values of the AC coefficients of the k transformation layers and the residual values of the AC coefficients of the other transformation layers, that is, according to the residual values of the AC coefficients of the multiple transformation layers.
在一些实施例中,参见图13,在步骤S1201之后,该方法还可以包括:In some embodiments, referring to FIG. 13 , after step S1201, the method may further include:
S1301,在第一解码参数指示对当前点云的k个变换层不进行跳跃解码时,解码码流,确定当前点云对应的多个变换层的交流系数残差值。S1301, when the first decoding parameter indicates that the k transform layers of the current point cloud are not to be skip-decoded, decode the bitstream to determine the residual values of the AC coefficients of the multiple transform layers corresponding to the current point cloud.
S1302,根据多个变换层的交流系数残差值,确定当前点云的重建点云。S1302, determining a reconstructed point cloud of the current point cloud according to the AC coefficient residual values of multiple transformation layers.
需要说明的是,在本申请实施例中,如果对当前点云的k个变换层不进行跳跃解码,那么可以说明当前点云对应的多个变换层均需要解码各自的交流系数残差值。在一些实施例中,该方法还可以包括:解码码流中的属性码流单元,确定多个变换层的交流系数残差值。It should be noted that, in the embodiment of the present application, if the k transform layers of the current point cloud are not skip-decoded, it can be said that the multiple transform layers corresponding to the current point cloud all need to decode their respective AC coefficient residual values. In some embodiments, the method may also include: decoding the attribute code stream unit in the code stream to determine the AC coefficient residual values of the multiple transform layers.
也就是说,在本申请实施例中,第一解码参数和交流系数残差值都是位于码流的属性码流单元中。具体地,在一些实施例中,该方法还可以包括:在属性码流单元中,确定第一解码参数对应的字段位于交流系数残差值对应的字段之后。That is, in the embodiment of the present application, the first decoding parameter and the AC coefficient residual value are both located in the attribute code stream unit of the code stream. Specifically, in some embodiments, the method may also include: in the attribute code stream unit, determining that the field corresponding to the first decoding parameter is located after the field corresponding to the AC coefficient residual value.
这样,解码端先解码第一解码参数的取值,以确定出需要解码的交流系数残差值的变换层数,然后按照第一解码参数指示的将需要解码的交流系数残差值解码出来,并且针对执行跳跃解码的k个变换层的交流系数残差值按照0恢复。In this way, the decoding end first decodes the value of the first decoding parameter to determine the number of transformation layers of the AC coefficient residual value that needs to be decoded, and then decodes the AC coefficient residual value that needs to be decoded according to the indication of the first decoding parameter, and restores the AC coefficient residual values of the k transformation layers for performing jump decoding to 0.
在一些实施例中,该方法还可以包括:解码码流,确定当前点云的根节点的直流系数值。In some embodiments, the method may further include: decoding the code stream and determining the DC coefficient value of the root node of the current point cloud.
需要说明的是,在本申请实施例中,只有根节点的直流系数值需要写入码流中。在一些实施例中,该方法还可以包括:解码码流中的属性码流单元,确定当前点云的根节点的直流系数值。It should be noted that, in the embodiment of the present application, only the DC coefficient value of the root node needs to be written into the bitstream. In some embodiments, the method may also include: decoding the attribute bitstream unit in the bitstream to determine the DC coefficient value of the root node of the current point cloud.
还需要说明的是,在本申请实施例中,对于多个变换层,在每次变换时,可以将直流系数值直接传递给下一层,但是需要对交流系数值进行进行残差计算,并对每一层的交流系数残差值进行量化与熵编码。另外,如果某一变换层只有一个点时,可以直接将该点的属性值作为直流系数值传递给下一层。It should also be noted that in the embodiment of the present application, for multiple transformation layers, the DC coefficient value can be directly passed to the next layer at each transformation, but the AC coefficient value needs to be residually calculated, and the AC coefficient residual value of each layer needs to be quantized and entropy encoded. In addition, if a certain transformation layer has only one point, the attribute value of the point can be directly passed to the next layer as the DC coefficient value.
在一些实施例中,该方法还包括:将根节点的直流系数值保存至当前点云的第一参数矩阵中。另外,该方法还可以包括:将k个变换层的交流系数残差值和其他变换层的交流系数残差值保存至当前点云的第一参数矩阵中。也就是说,可以将多个变换层的交流系数残差值保存至当前点云的第一参数矩阵中。In some embodiments, the method further includes: saving the DC coefficient value of the root node to the first parameter matrix of the current point cloud. In addition, the method may further include: saving the residual values of the AC coefficients of k transformation layers and the residual values of the AC coefficients of other transformation layers to the first parameter matrix of the current point cloud. In other words, the residual values of the AC coefficients of multiple transformation layers may be saved to the first parameter matrix of the current point cloud.
在本申请实施例中,解码端解析码流,首先解码出位于码流最后端的第一解码参数,若解码出第一解码参数的取值为k,则将k个变换层的交流系数残差值全部按0解码,其他变换层的交流系数残差值正常解码,并存入第一参数矩阵中;若解码出第一解码参数的取值为0,则解码出多个变换层的全部交流系数残差值,并存入第一参数矩阵中。需要注意的是,在解码交流系数残差值的过程中,解码出根节点的直流系数值也会存入第一参数矩阵中。In the embodiment of the present application, the decoding end parses the bitstream and first decodes the first decoding parameter at the end of the bitstream. If the decoded value of the first decoding parameter is k, the residual values of the AC coefficients of the k transform layers are all decoded as 0, and the residual values of the AC coefficients of other transform layers are decoded normally and stored in the first parameter matrix; if the decoded value of the first decoding parameter is 0, all the residual values of the AC coefficients of multiple transform layers are decoded and stored in the first parameter matrix. It should be noted that in the process of decoding the residual values of the AC coefficients, the DC coefficient value of the decoded root node will also be stored in the first parameter matrix.
在一些实施例中,该方法还可以包括:对当前点云的第一参数矩阵中的参数值进行反量化处理。In some embodiments, the method may further include: performing inverse quantization processing on parameter values in the first parameter matrix of the current point cloud.
也就是说,在本申请实施例中,在进行RAHT逆变换之前,对于第一参数矩阵中的直流系数值和交流系数残差值来说,还都需要进行反量化处理。That is to say, in the embodiment of the present application, before performing the RAHT inverse transform, both the DC coefficient values and the AC coefficient residual values in the first parameter matrix need to be dequantized.
在一些实施例中,对于确定当前点云的重建点云,参见图14,该方法可以包括:In some embodiments, for determining a reconstructed point cloud of a current point cloud, referring to FIG. 14 , the method may include:
S1401,确定多个变换层中的点的属性预测值。 S1401, determine attribute prediction values of points in multiple transformation layers.
S1402,对多个变换层中的点的属性预测值进行区域自适应分层变换,确定多个变换层中的点的交流系数预测值。S1402, performing region-adaptive hierarchical transformation on the attribute prediction values of the points in the multiple transformation layers to determine the AC coefficient prediction values of the points in the multiple transformation layers.
S1403,根据当前点云的第一参数矩阵和多个变换层中的点的交流系数预测值,确定当前点云的第二参数矩阵。S1403, determining a second parameter matrix of the current point cloud according to the first parameter matrix of the current point cloud and the predicted values of the AC coefficients of the points in the multiple transformation layers.
S1404,对当前点云的第二参数矩阵进行区域自适应分层逆变换,确定当前点云的重建点云。S1404, performing a region-adaptive hierarchical inverse transform on the second parameter matrix of the current point cloud to determine a reconstructed point cloud of the current point cloud.
需要说明的是,在本申请实施例中,对于确定当前点云的重建点云,具体可以是:确定多个变换层中的点的交流系数预测值;然后根据当前点云的第一参数矩阵和多个变换层中的点的交流系数预测值,确定当前点云的第二参数矩阵;再对当前点云的第二参数矩阵进行区域自适应分层逆变换,确定当前点云的重建点云。其中,直流系数也可以称为低频系数,用DC系数表示;交流系数也可以称为高频系数,用AC系数表示。It should be noted that, in the embodiment of the present application, the reconstructed point cloud of the current point cloud can be determined by: determining the predicted values of the AC coefficients of the points in multiple transformation layers; then determining the second parameter matrix of the current point cloud based on the first parameter matrix of the current point cloud and the predicted values of the AC coefficients of the points in multiple transformation layers; and then performing a regional adaptive hierarchical inverse transformation on the second parameter matrix of the current point cloud to determine the reconstructed point cloud of the current point cloud. Among them, the DC coefficient can also be called the low-frequency coefficient, represented by the DC coefficient; the AC coefficient can also be called the high-frequency coefficient, represented by the AC coefficient.
还需要说明的是,在本申请实施例中,对于确定多个变换层中的点的交流系数预测值,首先需要确定当前点云中的点的属性预测值。在一些实施例中,该方法可以包括:在当前点云允许使用帧内预测时,对多个变换层中的点进行帧内预测,确定多个变换层中的点的属性预测值;在当前点云允许使用帧间预测时,确定当前点云的参考点云,并根据参考点云对多个变换层中的点进行帧间预测,确定多个变换层中的点的属性预测值。It should also be noted that in the embodiments of the present application, in order to determine the AC coefficient prediction values of points in multiple transformation layers, it is first necessary to determine the attribute prediction values of points in the current point cloud. In some embodiments, the method may include: when the current point cloud allows the use of intra-frame prediction, intra-frame prediction is performed on the points in multiple transformation layers to determine the attribute prediction values of the points in the multiple transformation layers; when the current point cloud allows the use of inter-frame prediction, a reference point cloud of the current point cloud is determined, and inter-frame prediction is performed on the points in multiple transformation layers based on the reference point cloud to determine the attribute prediction values of the points in the multiple transformation layers.
这样,在确定多个变换层中的点的属性预测值之后,基于区域自适应分层变换可以确定出对应的交流系数预测值。其中,区域自适应分层变换可以用Tnode表示。对应的属性变换公式如下所示:
In this way, after determining the attribute prediction values of points in multiple transformation layers, the corresponding AC coefficient prediction values can be determined based on the regional adaptive hierarchical transformation. The regional adaptive hierarchical transformation can be represented by T node . The corresponding attribute transformation formula is as follows:
在一些实施例中,根据当前点云的第一参数矩阵和多个变换层中的点的交流系数预测值,确定当前点云的第二参数矩阵。以多个变换层中的当前变换层为例,该方法可以包括:基于当前点云中的当前变换层的点,确定在第一参数矩阵中的当前变换层的点的交流系数残差值,以及确定当前变换层的点的交流系数预测值;对交流系数残差值和交流系数预测值进行加法运算,得到当前变换层的点的交流系数重建值;在得到多个变换层的点的交流系数重建值之后,根据根节点的直流系数值和多个变换层的点的交流系数重建值,确定当前点云的第二参数矩阵。In some embodiments, the second parameter matrix of the current point cloud is determined based on the first parameter matrix of the current point cloud and the AC coefficient prediction values of the points in the multiple transformation layers. Taking the current transformation layer among the multiple transformation layers as an example, the method may include: determining the AC coefficient residual values of the points of the current transformation layer in the first parameter matrix based on the points of the current transformation layer in the current point cloud, and determining the AC coefficient prediction values of the points of the current transformation layer; adding the AC coefficient residual values and the AC coefficient prediction values to obtain the AC coefficient reconstruction values of the points of the current transformation layer; after obtaining the AC coefficient reconstruction values of the points of the multiple transformation layers, determining the second parameter matrix of the current point cloud based on the DC coefficient value of the root node and the AC coefficient reconstruction values of the points of the multiple transformation layers.
示例性地,以第d变换层为例,第d变换层包括m个节点。其中,第一参数矩阵可以表示为交流系数预测值可以表示为第二参数矩阵可以表示为如此,根据当前点云的第一参数矩阵和多个变换层中的点的交流系数预测值,确定当前点云的第二参数矩阵,具体可以为:对当前点云的第一参数矩阵和多个变换层中的点的交流系数预测值进行加法运算,确定当前点云的第二参数矩阵,具体如下所示:
For example, taking the dth transformation layer as an example, the dth transformation layer includes m nodes. The first parameter matrix can be expressed as The predicted value of the AC coefficient can be expressed as The second parameter matrix can be expressed as In this way, according to the first parameter matrix of the current point cloud and the predicted values of the AC coefficients of the points in the multiple transformation layers, the second parameter matrix of the current point cloud is determined. Specifically, the first parameter matrix of the current point cloud and the predicted values of the AC coefficients of the points in the multiple transformation layers are added to determine the second parameter matrix of the current point cloud, as shown below:
在一些实施例中,对当前点云的第二参数矩阵进行区域自适应分层逆变换,确定当前点云的重建点云,该方法可以包括:在当前变换层为第一变换层时,根据根节点的直流系数值和当前变换层的点的交流系数重建值进行区域自适应分层逆变换,得到第一变换层的点的重建属性值;在当前变换层为非第一变换层时,根据当前变换层的上一变换层的点的重建属性值确定当前变换层的点的直流系数值,根据当前变换层的点的直流系数值和当前变换层的点的交流系数重建值进行区域自适应分层逆变换,得到非第一变换层的点的重建属性值。In some embodiments, a regional adaptive hierarchical inverse transform is performed on the second parameter matrix of the current point cloud to determine a reconstructed point cloud of the current point cloud. The method may include: when the current transformation layer is the first transformation layer, a regional adaptive hierarchical inverse transform is performed based on the DC coefficient value of the root node and the AC coefficient reconstruction value of the points of the current transformation layer to obtain the reconstructed attribute values of the points of the first transformation layer; when the current transformation layer is not the first transformation layer, the DC coefficient value of the points of the current transformation layer is determined based on the reconstructed attribute values of the points of the previous transformation layer of the current transformation layer, and a regional adaptive hierarchical inverse transform is performed based on the DC coefficient value of the points of the current transformation layer and the AC coefficient reconstruction value of the points of the current transformation layer to obtain the reconstructed attribute values of the points of the non-first transformation layer.
需要说明的是,在本申请实施例中,解码的过程依旧从上往下进行,首先得到根节点的DC系数值与第一层的AC系数残差值,进行RAHT逆变换得到第一层的重建属性值;如果配置允许帧内预测或帧间预测,则先将第一层的AC系数残差值与预测AC系数值相加,得到重建AC系数值,将所得到的重建AC系数值与根节点的DC系数值一起进行RAHT逆变换就可以得到第一层的重建属性值。然后将得到的8个重建属性值可以用于计算第二层8个节点的DC系数至,然后根据解码出的第二层的AC系数残差值与预测AC系数值相加可以得到第二层的重建AC系数值;根据第二层的重建AC系数值与DC系数值一起进行RAHT逆变换得到第三层的重建属性值,依次类推,直至所有变换层全部解码完成。 It should be noted that in the embodiment of the present application, the decoding process is still carried out from top to bottom. First, the DC coefficient value of the root node and the residual value of the AC coefficient of the first layer are obtained, and the RAHT inverse transform is performed to obtain the reconstructed attribute value of the first layer; if the configuration allows intra-frame prediction or inter-frame prediction, the AC coefficient residual value of the first layer is first added to the predicted AC coefficient value to obtain the reconstructed AC coefficient value, and the obtained reconstructed AC coefficient value and the DC coefficient value of the root node are subjected to the RAHT inverse transform to obtain the reconstructed attribute value of the first layer. Then the obtained 8 reconstructed attribute values can be used to calculate the DC coefficients of the 8 nodes of the second layer, and then the decoded AC coefficient residual value of the second layer is added to the predicted AC coefficient value to obtain the reconstructed AC coefficient value of the second layer; the reconstructed AC coefficient value of the second layer is subjected to the RAHT inverse transform together with the DC coefficient value to obtain the reconstructed attribute value of the third layer, and so on, until all transformation layers are fully decoded.
示例性地,仍以第d变换层为例,第d变换层的重建属性值可以表示为区域自适应分层逆变换可以用Tnode
-1表示。对应的属性逆变换公式如下所示:
Exemplarily, still taking the dth transformation layer as an example, the reconstruction property value of the dth transformation layer can be expressed as The regional adaptive hierarchical inverse transformation can be represented by T node -1 . The corresponding attribute inverse transformation formula is as follows:
在一些实施例中,在图12所示解码方法的基础上,参见图15,对于步骤S1201来说,可以包括:In some embodiments, based on the decoding method shown in FIG. 12 , referring to FIG. 15 , step S1201 may include:
S1501,确定第二解码参数的取值。S1501: Determine a value of a second decoding parameter.
S1502,在第二解码参数指示开启当前点云的跳跃解码时,确定第一解码参数的取值。S1502, when the second decoding parameter indicates to start skip decoding of the current point cloud, determine the value of the first decoding parameter.
需要说明的是,在本申请实施例中,对于第二解码参数来说,第二解码参数可以用于指示是否开启当前点云的跳跃解码,即用于指示本申请实施例的技术方案是否开启。在一些实施例中,若第二解码参数的取值为第三值,则确定第二解码参数指示开启当前点云的跳跃解码;若第二解码参数的取值为第四值,则确定第二解码参数指示不开启当前点云的跳跃解码。It should be noted that in the embodiment of the present application, for the second decoding parameter, the second decoding parameter can be used to indicate whether to enable the jump decoding of the current point cloud, that is, to indicate whether the technical solution of the embodiment of the present application is enabled. In some embodiments, if the value of the second decoding parameter is the third value, it is determined that the second decoding parameter indicates to enable the jump decoding of the current point cloud; if the value of the second decoding parameter is the fourth value, it is determined that the second decoding parameter indicates not to enable the jump decoding of the current point cloud.
在一些实施例中,对于确定第二解码参数的取值,该方法可以包括:解码码流,确定第二解码参数的取值。In some embodiments, for determining the value of the second decoding parameter, the method may include: decoding a bitstream, and determining the value of the second decoding parameter.
需要说明的是,在本申请实施例中,该方法还可以包括:解码码流中的属性参数集单元,确定第二解码参数的取值。也就是说,在解码码流时,第二解码参数具体是位于码流中的属性参数集单元。It should be noted that, in the embodiment of the present application, the method may further include: decoding the attribute parameter set unit in the code stream to determine the value of the second decoding parameter. That is, when decoding the code stream, the second decoding parameter is specifically the attribute parameter set unit in the code stream.
还需要说明的是,在本申请实施例中,第二解码参数可以用语法元素的形式表示,此时第二解码参数可以称为第二语法元素,用skip_raht_enabled_flag表示。换句话说,在本申请实施例中,这里也可以是:解码码流,确定第二语法元素的取值。其中,第二语法元素也可以用于指示是否开启当前点云的跳跃解码,即用于指示本申请实施例的技术方案是否开启。在一些实施例中,若第二语法元素的取值为第三值,则确定第二语法元素指示开启当前点云的跳跃解码;若第二语法元素的取值为第四值,则确定第二语法元素指示不开启当前点云的跳跃解码。It should also be noted that, in the embodiment of the present application, the second decoding parameter can be expressed in the form of a syntax element. In this case, the second decoding parameter can be called a second syntax element, represented by skip_raht_enabled_flag. In other words, in the embodiment of the present application, it can also be: decode the code stream and determine the value of the second syntax element. Among them, the second syntax element can also be used to indicate whether to enable skip decoding of the current point cloud, that is, to indicate whether the technical solution of the embodiment of the present application is enabled. In some embodiments, if the value of the second syntax element is the third value, it is determined that the second syntax element indicates that skip decoding of the current point cloud is enabled; if the value of the second syntax element is the fourth value, it is determined that the second syntax element indicates that skip decoding of the current point cloud is not enabled.
还需要说明的是,在本申请实施例中,第三值与第四值不同。其中,第三值可以设置为1,第四值可以设置为0;或者,第三值可以设置为0,第四值可以设置为1;或者,第三值可以设置为真(true),第四值可以设置为假(false);或者,第三值可以设置为假(false),第四值可以设置为真(true)。在一种具体的实施例中,第三值设置为1,第四值设置为0,但是不作任何限定。It should also be noted that in the embodiment of the present application, the third value is different from the fourth value. The third value can be set to 1 and the fourth value can be set to 0; or, the third value can be set to 0 and the fourth value can be set to 1; or, the third value can be set to true (true) and the fourth value can be set to false (false); or, the third value can be set to false (false) and the fourth value can be set to true (true). In a specific embodiment, the third value is set to 1 and the fourth value is set to 0, but this is not limited to any limitation.
在一些实施例中,参见图16,该方法还可以包括:In some embodiments, referring to FIG. 16 , the method may further include:
S1601,解码码流,确定第三解码参数的取值。S1601, decoding a bitstream and determining a value of a third decoding parameter.
S1602,在第三解码参数指示对当前点云的k个变换层的待处理分量进行跳跃解码时,确定k个变换层的待处理分量的一个或多个交流系数残差值为预设数值。S1602: When the third decoding parameter indicates to skip decoding the components to be processed of the k transform layers of the current point cloud, determine that one or more AC coefficient residual values of the components to be processed of the k transform layers are preset values.
S1603,解码码流,确定当前点云中k个变换层之外其他变换层的待处理分量的交流系数残差值。S1603, decoding the code stream, and determining the AC coefficient residual values of the components to be processed in other transformation layers other than the k transformation layers in the current point cloud.
S1604,根据k个变换层的待处理分量的交流系数残差值和其他变换层的待处理分量的交流系数残差值,确定当前点云的待处理分量的重建点云。S1604, determining the reconstructed point cloud of the to-be-processed component of the current point cloud according to the AC coefficient residual values of the to-be-processed components of k transformation layers and the AC coefficient residual values of the to-be-processed components of other transformation layers.
需要说明的是,在本申请实施例中,待处理分量可以包括第一颜色分量、第二颜色分量和第三颜色分量中的至少一项。It should be noted that, in the embodiment of the present application, the component to be processed may include at least one of the first color component, the second color component and the third color component.
还需要说明的是,在本申请实施例中,第三解码参数可以用语法元素的形式表示,此时第三解码参数可以称为第三语法元素。其中,当待处理分量为第一颜色分量(例如Y分量)时,这时候可以用flag_Y表示,用于指示对当前点云的k个变换层的Y分量是否进行跳跃解码;当待处理分量为第二颜色分量(例如U分量)时,这时候可以用flag_U表示,用于指示对当前点云的k个变换层的U分量是否进行跳跃解码;当待处理分量为第三颜色分量(例如V分量)时,这时候可以用flag_V表示,用于指示对当前点云的k个变换层的V分量是否进行跳跃解码。也就是说,在稠密点云的颜色属性中,可以扩展到三通道同时使用面向RAHT变换系数的跳跃解码模式,这时候对于第三编码参数来说,可以设置三个标志位flag_Y、flag_U、flag_V分别记录进行跳跃解码的系数层数。It should also be noted that, in an embodiment of the present application, the third decoding parameter can be expressed in the form of a syntax element, and the third decoding parameter can be referred to as a third syntax element. Among them, when the component to be processed is the first color component (for example, the Y component), it can be represented by flag_Y at this time to indicate whether the Y component of the k transform layers of the current point cloud is skip-decoded; when the component to be processed is the second color component (for example, the U component), it can be represented by flag_U at this time to indicate whether the U component of the k transform layers of the current point cloud is skip-decoded; when the component to be processed is the third color component (for example, the V component), it can be represented by flag_V at this time to indicate whether the V component of the k transform layers of the current point cloud is skip-decoded. That is to say, in the color attributes of the dense point cloud, it can be extended to three channels and use the skip decoding mode for RAHT transform coefficients at the same time. At this time, for the third coding parameter, three flags flag_Y, flag_U, and flag_V can be set to record the number of coefficient layers for skip decoding respectively.
在一种具体的实施例中,图17为本申请实施例提供的一种解码方法的详细流程示意图。如图17所示,在属性码流中,首先解码出第一解码参数(标志位flag),如果flag=0,那么需要解码DC与全部AC系数(具体为DC系数值与全部的AC系数残差值);如果flag=k,那么需要解码系数(具体为DC系数值与其他层的AC系数残差值,最后k层按0解码);然后针对这些系数进行反量化。在允许预测的情况下,可以基于帧内预测或者帧间预测来确定AC系数预测值,然后根据AC系数预测值与反量化后的AC系数残差值,可以确定出AC系数重建值。对于AC系数重建值进行RAHT逆变换之后,可 以得到对应的重建属性值。In a specific embodiment, FIG17 is a detailed flowchart of a decoding method provided by an embodiment of the present application. As shown in FIG17, in the attribute code stream, the first decoding parameter (flag bit flag) is first decoded. If flag = 0, then it is necessary to decode the DC and all AC coefficients (specifically, the DC coefficient value and all AC coefficient residual values); if flag = k, then it is necessary to decode the coefficients (specifically, the DC coefficient value and the AC coefficient residual value of other layers, and the last k layer is decoded as 0); and then dequantize these coefficients. When prediction is allowed, the AC coefficient prediction value can be determined based on intra-frame prediction or inter-frame prediction, and then the AC coefficient reconstruction value can be determined based on the AC coefficient prediction value and the dequantized AC coefficient residual value. After the AC coefficient reconstruction value is subjected to RAHT inverse transform, To obtain the corresponding reconstructed attribute value.
在本申请实施例中,解码端的程序具体实现如下所示。首先在属性参数集APS中解码出标志位.skip_raht_enabled_flag,此标志位决定本申请实施例的技术方案是否开启;若为true则先在属性码流中解出码流中的标志位flag,并将其传输到RAHT子函数中。如果解码的flag值为k,则RAHT的最后k层AC系数残差值按照0值恢复,以进行下一步属性重建;若解码的flag值为0,则RAHT的所有层的AC系数残差值按原始编码值恢复。在这里,AC系数残差值存放在参数矩阵transformPredBuf中。
In the embodiment of the present application, the specific implementation of the program on the decoding end is as follows. First, the flag .skip_raht_enabled_flag is decoded in the attribute parameter set APS. This flag determines whether the technical solution of the embodiment of the present application is turned on; if it is true, the flag flag in the attribute code stream is first decoded in the code stream and transmitted to the RAHT sub-function. If the decoded flag value is k, the residual value of the AC coefficient of the last k layers of RAHT is restored according to the value of 0 for the next attribute reconstruction; if the decoded flag value is 0, the residual value of the AC coefficient of all layers of RAHT is restored according to the original coding value. Here, the residual value of the AC coefficient is stored in the parameter matrix transformPredBuf.
本申请实施例提供了一种解码方法,确定第一解码参数的取值;在第一解码参数指示对当前点云的k个变换层进行跳跃解码时,确定k个变换层的一个或多个交流系数残差值为预设数值;解码码流,确定当前点云中k个变换层之外其他变换层的交流系数残差值;根据k个变换层的交流系数残差值和其他变换层的交流系数残差值,确定当前点云的重建点云。这样,在确定对当前点云的k个变换层进行跳跃编码时,这时候直接将这k个变换层的一个或多个交流系数残差值按照预设数值进行解码处理,可以有效改善RAHT变换中最后几层AC系数残差值出现过多0的现象,从而提高了编解码效率,而且通过一个标志位flag来记录跳跃解码操作是否执行以及对几层执行,从而还提高了平均码率下的重建质量,进而能够提升点云的编解码性能。The embodiment of the present application provides a decoding method, which determines the value of a first decoding parameter; when the first decoding parameter indicates that the k transform layers of the current point cloud are to be skip decoded, determines that one or more residual values of the AC coefficients of the k transform layers are preset values; decodes the code stream to determine the residual values of the AC coefficients of other transform layers other than the k transform layers in the current point cloud; and determines the reconstructed point cloud of the current point cloud based on the residual values of the AC coefficients of the k transform layers and the residual values of the AC coefficients of other transform layers. In this way, when it is determined that the k transform layers of the current point cloud are to be skip encoded, one or more residual values of the AC coefficients of the k transform layers are directly decoded according to the preset values, which can effectively improve the phenomenon that too many 0s appear in the residual values of the AC coefficients of the last few layers in the RAHT transform, thereby improving the encoding and decoding efficiency, and using a flag to record whether the skip decoding operation is performed and on which layers it is performed, thereby improving the reconstruction quality at the average bit rate, and thus improving the encoding and decoding performance of the point cloud.
在本申请的另一实施例中,图18为本申请实施例提供的一种编码方法的流程示意图一。如图18所示,该方法可以包括:In another embodiment of the present application, FIG18 is a flow chart of a coding method provided in an embodiment of the present application. As shown in FIG18 , the method may include:
S1801,确定第一编码参数的取值。S1801, determine the value of the first encoding parameter.
需要说明的是,在本申请实施例中,该方法应用于点云编码器(可简称为“编码器”)。这里,主要是提供了一种点云编码方法,更具体地,是一种面向RAHT变换系数的跳跃编码方法,能够改善RAHT变换中最后几层编码AC系数值出现过多0的现象。It should be noted that in the embodiment of the present application, the method is applied to a point cloud encoder (hereinafter referred to as "encoder"). Here, a point cloud encoding method is mainly provided, more specifically, a skip encoding method for RAHT transform coefficients, which can improve the phenomenon that too many 0s appear in the last few layers of encoded AC coefficient values in RAHT transform.
还需要说明的是,在本申请实施例中,对于第一编码参数来说,第一编码参数可以用于指示对当前点云的k个变换层是否进行跳跃编码。在一些实施例中,参见图19,该方法可以包括:It should also be noted that, in the embodiment of the present application, for the first encoding parameter, the first encoding parameter can be used to indicate whether to perform skip encoding on the k transformation layers of the current point cloud. In some embodiments, referring to FIG. 19 , the method may include:
S1901,确定对k个变换层的全部交流系数残差值进行编码的第一代价值,以及确定对k个变换层的一个或多个交流系数残差值按照预设数值进行编码的第二代价值。S1901, determining a first generation value for encoding all AC coefficient residual values of k transformation layers, and determining a second generation value for encoding one or more AC coefficient residual values of k transformation layers according to a preset value.
S1902,若第一代价值大于第二代价值,则确定第一编码参数的取值为第一值。S1902: If the first generation value is greater than the second generation value, determine that the value of the first encoding parameter is the first value.
S1903,若第一代价值小于第二代价值,则确定第一编码参数的取值为第二值。S1903: If the first generation value is less than the second generation value, determine that the value of the first encoding parameter is the second value.
需要说明的是,在本申请实施例中,在确定出第一代价值与第二代价值之后,可以根据第一代价值和第二代价值,确定第一编码参数的取值。或者也可以说是根据第一代价值和第二代价值,确定对当前点云的k个变换层是否进行跳跃编码。其中,k是大于零的整数。 It should be noted that in the embodiment of the present application, after the first generation value and the second generation value are determined, the value of the first encoding parameter can be determined according to the first generation value and the second generation value. Or it can be said that it is determined whether to perform jump encoding on the k transformation layers of the current point cloud according to the first generation value and the second generation value. Where k is an integer greater than zero.
还需要说明的是,在本申请实施例中,这里的代价值可以是根据率失真优化(Rate-Distortion Optimization,RDO)的代价结果进行确定,也可以是根据绝对误差和(Sum of Absolute Difference,SAD)的代价结果进行确定,甚至也可以根据绝对变换差和(Sum of Absolute Transformed Difference,SATD)的代价结果进行确定,但是这里并不作任何限定。It should also be noted that, in the embodiments of the present application, the cost value here can be determined according to the cost result of Rate-Distortion Optimization (RDO), or according to the cost result of Sum of Absolute Difference (SAD), or even according to the cost result of Sum of Absolute Transformed Difference (SATD), but no limitation is made here.
可以理解地,在视频编码领域中,编码后的码率和失真是相互矛盾的关系,如果想要更小的失真来获得更高质量的重建视频,就需要提高传输的码率;但是码率不能无限制的提高,有些情况下就需要降低码率来保证视频传输的流畅性。为了更好地提高编码的效率,需要综合的考虑码率与失真,找到二者的折中点,使得在固定码率的条件下,失真尽可能的小,用公式可以表达为:
Understandably, in the field of video coding, the bit rate and distortion after coding are in a contradictory relationship. If you want to obtain a higher quality reconstructed video with less distortion, you need to increase the transmission bit rate; however, the bit rate cannot be increased indefinitely. In some cases, you need to reduce the bit rate to ensure the smoothness of video transmission. In order to better improve the efficiency of coding, it is necessary to comprehensively consider the bit rate and distortion and find a compromise between the two so that the distortion is as small as possible under the condition of a fixed bit rate. The formula can be expressed as:
其中,D表示失真,R表示码率,表示编码的条件参数配置,如量化步长等。式(11)是一个有约束的优化问题,可以利用拉格朗日乘子将其转化为以下形式:
Where D represents distortion, R represents bit rate, Represents the conditional parameter configuration of the encoding, such as the quantization step size, etc. Formula (11) is a constrained optimization problem, which can be transformed into the following form using Lagrange multipliers:
其中,RDcost为率失真代价值,λ为拉格朗日乘子。这便是视频编码领域中的率失真优化问题。Among them, RDcost is the rate-distortion cost, and λ is the Lagrange multiplier. This is the rate-distortion optimization problem in the field of video coding.
在本申请实施例中,这里提出了计算当前点云多参数的m层、m-1层...AC系数残差值不编码的RDOcost,与系数残差值全部编码的RDOcost,相互比较从而决定是否编码这些系数残差值的方法来提高编码效率。由于RDcost计算不方便,可以采取计算ΔRDcost的方法,以k层为例,计算公式如下:
ΔR=Rorg-1 (14)
ΔRDcost=ΔD-λ·ΔR (15)In the embodiment of the present application, it is proposed to calculate the RDOcost of the m-layer, m-1-layer...AC coefficient residual values of the current point cloud multi-parameters without encoding, and the RDOcost of the coefficient residual values with all encoded values, and compare them to decide whether to encode these coefficient residual values to improve the encoding efficiency. Since the RDcost calculation is inconvenient, the method of calculating ΔRDcost can be adopted. Taking the k-layer as an example, the calculation formula is as follows:
ΔR=R org -1 (14)
ΔRDcost=ΔD-λ·ΔR (15)
其中,ΔD可以用k个变换层所有AC系数残差值的平方值表示,用来指代这些系数残差值全部不编码后的失真代价,Rorg是相关技术的编码方案中的码流消耗,而k个变换层AC系数残差值全部不编码后的码率消耗仅有第一语法元素(标志位flag)所占的1bit,因此ΔR表示k个变换层AC系数残差值不编码与编码的码率消耗之差,即k个变换层AC系数残差值不编节省的码流。此时,计算所得的ΔRDcost若大于0,表示不编码的失真代价较大,此时将标志位flag置为0;若计算所得的ΔRDcost小于0,表示不编码的码率节省较大,需要继续比较其他变换层的ΔRDcost,决定是否将标志位flag置为k。Among them, ΔD can be represented by the square value of all AC coefficient residual values of k transform layers, which is used to refer to the distortion cost after all these coefficient residual values are not encoded, Rorg is the bitstream consumption in the coding scheme of the related technology, and the bitrate consumption after all the AC coefficient residual values of k transform layers are not encoded is only 1 bit occupied by the first syntax element (flag bit flag), so ΔR represents the difference in bitrate consumption between not encoding and encoding the residual values of k transform layers AC coefficients, that is, the bitstream saved by not encoding the residual values of k transform layers AC coefficients. At this time, if the calculated ΔRDcost is greater than 0, it means that the distortion cost of not encoding is large, and the flag bit flag is set to 0; if the calculated ΔRDcost is less than 0, it means that the bitrate saving of not encoding is large, and it is necessary to continue to compare the ΔRDcost of other transform layers to decide whether to set the flag bit flag to k.
拉格朗日乘子λ的选取采用H.266/VCC视频编码中的形式,如下公式所示:
The Lagrange multiplier λ is selected in the form of H.266/VCC video coding, as shown in the following formula:
其中,c为常数,QP为量化步长。选取c的值为0.01、0.1、0.2、0.3、0.4,并选取测试点云在C1条件下测试的属性压缩性能,分析找到c的最优区间。继续缩小搜索步长,最终确定常数c的最优取值为0.12。Where c is a constant and QP is a quantization step size. The values of c are selected as 0.01, 0.1, 0.2, 0.3, and 0.4, and the attribute compression performance of the test point cloud under the C1 condition is selected to analyze and find the optimal interval of c. The search step size is further reduced, and the optimal value of the constant c is finally determined to be 0.12.
在这里,以率失真优化方式为例,对于确定对k个变换层的全部交流系数残差值进行编码的第一代价值,可以是利用率失真优化方式对k个变换层的全部交流系数残差值进行编码的代价计算,得到第一代价值。对于确定对k个变换层的一个或多个交流系数残差值按照预设数值进行编码的第二代价值,可以是利用率失真优化方式对k个变换层的一个或多个交流系数残差值按照预设数值进行编码的代价计算,得到第二代价值。Here, taking the rate-distortion optimization method as an example, for determining the first generation value for encoding all the residual values of the AC coefficients of the k transform layers, the cost of encoding all the residual values of the AC coefficients of the k transform layers using the rate-distortion optimization method can be calculated to obtain the first generation value. For determining the second generation value for encoding one or more residual values of the AC coefficients of the k transform layers according to the preset value, the cost of encoding one or more residual values of the AC coefficients of the k transform layers according to the preset value can be calculated to obtain the second generation value.
在一种可能的实现方式中,对于确定对当前点云的k个变换层是否进行跳跃编码,该方法可以包括:若第一代价值大于第二代价值,则确定对当前点云的k个变换层进行跳跃编码;若第一代价值小于第二代价值,则确定对当前点云的k个变换层不进行跳跃编码。In one possible implementation, for determining whether to perform skip encoding on the k transformation layers of the current point cloud, the method may include: if the first generation value is greater than the second generation value, determining to perform skip encoding on the k transformation layers of the current point cloud; if the first generation value is less than the second generation value, determining not to perform skip encoding on the k transformation layers of the current point cloud.
在另一种可能的实现方式中,对于确定对当前点云的k个变换层是否进行跳跃编码,该方法可以包括:若第一编码参数的取值为第一值,则确定第一编码参数指示对当前点云的k个变换层进行跳跃编码;若第一编码参数的取值为第二值,则确定第一编码参数指示对当前点云的k个变换层不进行跳跃编码。In another possible implementation, for determining whether to skip encode the k transform layers of the current point cloud, the method may include: if the value of the first encoding parameter is a first value, determining that the first encoding parameter indicates that skip encoding is to be performed on the k transform layers of the current point cloud; if the value of the first encoding parameter is a second value, determining that the first encoding parameter indicates that no skip encoding is to be performed on the k transform layers of the current point cloud.
需要说明的是,在本申请实施例中,第一编码参数可以用语法元素的形式表示,此时第一编码参数可以称为第一语法元素,用flagzero表示。其中,第一语法元素也可以用于指示对当前点云的k个变换层是否进行跳跃编码。在一些实施例中,该方法还可以包括:确定对k个变换层的全部交流系数残差值进行编码的第一代价值,以及确定对k个变换层的一个或多个交流系数残差值按照预设数值进行编码的第二代价值;根据第一代价值和第二代价值,确定第一语法元素的取值。It should be noted that, in an embodiment of the present application, the first coding parameter can be expressed in the form of a syntax element. In this case, the first coding parameter can be called a first syntax element, represented by flagzero. Among them, the first syntax element can also be used to indicate whether to skip-code the k transform layers of the current point cloud. In some embodiments, the method may also include: determining a first generation value for encoding all AC coefficient residual values of the k transform layers, and determining a second generation value for encoding one or more AC coefficient residual values of the k transform layers according to a preset value; determining the value of the first syntax element based on the first generation value and the second generation value.
在一种可能的实现方式中,该方法还可以包括:若第一代价值大于第二代价值,则确定第一语法元素指示对当前点云的k个变换层进行跳跃编码;若第一代价值小于第二代价值,则确定第一语法元素指示对当前点云的k个变换层不进行跳跃编码。In a possible implementation, the method may further include: if the first generation value is greater than the second generation value, determining that the first syntax element indicates that the k transform layers of the current point cloud are skip encoded; if the first generation value is less than the second generation value, determining that the first syntax element indicates that the k transform layers of the current point cloud are not skip encoded.
在这种实现方式下,对于确定第一语法元素的取值,该方法可以包括:若对当前点云的k个变换层进行跳跃编码,则确定第一语法元素的取值为第一值;若对当前点云的k个变换层不进行跳跃编码,则 确定第一语法元素的取值为第二值。In this implementation, for determining the value of the first syntax element, the method may include: if the k transform layers of the current point cloud are skip-coded, then determining the value of the first syntax element to be the first value; if the k transform layers of the current point cloud are not skip-coded, then Determine that a value of the first syntax element is a second value.
还需要说明的是,对于第一代价值等于第二代价值的情况,可以是参照第一代价值大于第二代价值的情况进行处理,例如确定对当前点云的k个变换层进行跳跃编码;或者,也可以是参照第一代价值小于第二代价值的情况进行处理,例如确定对当前点云的k个变换层不进行跳跃编码,这里不作任何限定。It should also be noted that, for the case where the first-generation value is equal to the second-generation value, it can be processed with reference to the case where the first-generation value is greater than the second-generation value, such as determining to skip encoding the k transformation layers of the current point cloud; or, it can be processed with reference to the case where the first-generation value is less than the second-generation value, such as determining not to skip encoding the k transformation layers of the current point cloud. No limitation is made here.
在一些实施例中,该方法还可以包括:对第一编码参数的取值进行编码处理,将所得到的编码比特写入码流。In some embodiments, the method may further include: performing encoding processing on the value of the first encoding parameter, and writing the obtained encoding bits into a bit stream.
可以理解,对于码流来说,其可以包括几何码流单元、属性码流单元、属性参数集(Attribute Parameter Set,APS)单元等。在一些实施例中,对第一编码参数的取值进行编码处理,将所得到的编码比特写入码流,可以包括:对第一编码参数的取值进行编码处理,将所得到的编码比特写入码流中的属性码流单元。也就是说,第一编码参数具体是位于码流中的属性码流单元。It can be understood that, for a code stream, it may include a geometric code stream unit, an attribute code stream unit, an attribute parameter set (APS) unit, etc. In some embodiments, encoding the value of the first encoding parameter and writing the obtained encoding bits into the code stream may include: encoding the value of the first encoding parameter and writing the obtained encoding bits into the attribute code stream unit in the code stream. That is, the first encoding parameter is specifically an attribute code stream unit in the code stream.
需要说明的是,在本申请实施例中,第一值与第二值不同。其中,第一值可以设置为大于零的整数,例如1,2,3,…等;第二值可以设置为0。It should be noted that in the embodiment of the present application, the first value is different from the second value. The first value can be set to an integer greater than zero, such as 1, 2, 3, etc.; the second value can be set to 0.
还需要说明的是,k的取值与第一值之间具有关联关系。在一种具体的实施例中,该方法还包括:在第一编码参数指示对当前点云的k个变换层进行跳跃编码时,可以将第一值设置为等于k的取值。It should also be noted that there is an association between the value of k and the first value. In a specific embodiment, the method further includes: when the first encoding parameter indicates skip encoding of k transformation layers of the current point cloud, the first value can be set to be equal to the value of k.
在一些实施例中,对于k的取值,参见图20,该方法可以包括:In some embodiments, for the value of k, referring to FIG. 20 , the method may include:
S2001,确定对m个变换层的全部交流系数残差值进行编码的第三代价值,以及确定对m个变换层的一个或多个交流系数残差值按照预设数值进行编码的第四代价值。S2001, determining a third generation value for encoding all AC coefficient residual values of m transformation layers, and determining a fourth generation value for encoding one or more AC coefficient residual values of m transformation layers according to a preset value.
S2002,在第三代价值大于第四代价值时,确定当前点云的i个变换层按照预设数值进行编码的第五代价值,其中,i=1,2,…,m,m为大于零的整数。S2002, when the third generation value is greater than the fourth generation value, determine the fifth generation value of the i transformation layers of the current point cloud encoded according to the preset value, where i = 1, 2, ..., m, m is an integer greater than zero.
S2003,在得到m个第五代价值之后,从m个第五代价值中确定最小代价值。S2003, after obtaining m fifth-generation values, determine the minimum value from the m fifth-generation values.
S2004,根据最小代价值对应的i的取值,确定k的取值。S2004, determining the value of k according to the value of i corresponding to the minimum cost value.
需要说明的是,在本申请实施例中,仍以率失真优化方式为例,对于确定对m个变换层的全部交流系数残差值进行编码的第三代价值,可以是利用率失真优化方式对m个变换层的全部交流系数残差值进行编码的代价计算,得到第三代价值。对于确定对m个变换层的一个或多个交流系数残差值按照预设数值进行编码的第四代价值,可以是利用率失真优化方式对m个变换层的一个或多个交流系数残差值按照预设数值进行编码的代价计算,得到第四代价值。It should be noted that, in the embodiment of the present application, still taking the rate-distortion optimization method as an example, for determining the third generation value for encoding all the residual values of the AC coefficients of the m transform layers, the cost of encoding all the residual values of the AC coefficients of the m transform layers using the rate-distortion optimization method can be calculated to obtain the third generation value. For determining the fourth generation value for encoding one or more residual values of the AC coefficients of the m transform layers according to the preset value, the cost of encoding one or more residual values of the AC coefficients of the m transform layers according to the preset value can be calculated to obtain the fourth generation value.
还需要说明的是,在根据第三代价值和第四代价值确定出对m个变换层的一个或多个交流系数残差值进行跳跃编码时,还可以进一步确定k的取值,即具体对几个变换层的一个或多个交流系数残差值进行跳跃编码。在这里,可以确定m层、m-1层...、2层、1层的AC系数残差值不编码的RDOcost,然后从中选取RDOcost最小值,将RDOcost最小值对应的层数确定为k的取值。It should also be noted that when it is determined based on the third-generation value and the fourth-generation value that one or more AC coefficient residual values of m transform layers are skip-coded, the value of k can be further determined, that is, one or more AC coefficient residual values of several transform layers are skip-coded. Here, the RDOcost of the AC coefficient residual values of m layers, m-1 layers, ..., 2 layers, and 1 layer that are not coded can be determined, and then the minimum RDOcost value is selected therefrom, and the number of layers corresponding to the minimum RDOcost value is determined as the value of k.
需要注意的是,对于第三代价值等于第四代价值的情况,可以参照第三代价值大于第四代价值的情况,即确定当前点云的i(i=1,2,...,m)个变换层按照预设数值进行编码的第五代价值,以便进一步确定出对当前点云的k个变换层进行跳跃编码;或者,也可以参照第三代价值小于第四代价值的情况,即执行对当前点云的所有交流系数残差值全部进行编码的步骤,这里也不作任何限定。It should be noted that, for the case where the third-generation value is equal to the fourth-generation value, reference can be made to the case where the third-generation value is greater than the fourth-generation value, that is, the fifth-generation value of the i (i=1,2,...,m) transformation layers of the current point cloud encoded according to the preset value is determined, so as to further determine the jump encoding of the k transformation layers of the current point cloud; or, reference can be made to the case where the third-generation value is less than the fourth-generation value, that is, the step of encoding all the AC coefficient residual values of the current point cloud is executed, and no limitation is made here.
S1802,在第一编码参数指示对当前点云的k个变换层进行跳跃编码时,确定k个变换层的一个或多个交流系数残差值为预设数值。S1802, when the first encoding parameter indicates to skip encode the k transformation layers of the current point cloud, determine that one or more AC coefficient residual values of the k transformation layers are preset values.
需要说明的是,在本申请实施例中,预设数值可以设置为0。这样,如果确定对当前点云的k个变换层进行跳跃编码,那么这时候可以将k个变换层的一个或多个交流系数残差值按照0进行编码。It should be noted that, in the embodiment of the present application, the preset value can be set to 0. In this way, if it is determined to perform skip encoding on the k transformation layers of the current point cloud, then one or more AC coefficient residual values of the k transformation layers can be encoded as 0 at this time.
还需要说明的是,在本申请实施例中,k是大于零的整数。在确定对当前点云的k个变换层进行跳跃编码时,可以将第一编码参数的取值设置为等于k的取值。It should also be noted that, in the embodiment of the present application, k is an integer greater than 0. When determining to perform skip encoding on k transformation layers of the current point cloud, the value of the first encoding parameter may be set equal to the value of k.
也就是说,对于第一编码参数来说,如果第一编码参数的第一值为k,那么可以确定对当前点云的k个变换层进行跳跃编码;如果第一编码参数的第二值为0,那么可以确定对当前点云的k个变换层不进行跳跃编码,即此时需要编码当前点云的全部变换层的交流系数残差值。That is to say, for the first coding parameter, if the first value of the first coding parameter is k, then it can be determined that the k transformation layers of the current point cloud are skipped and encoded; if the second value of the first coding parameter is 0, then it can be determined that the k transformation layers of the current point cloud are not skipped and encoded, that is, at this time, the residual values of the AC coefficients of all the transformation layers of the current point cloud need to be encoded.
在一些实施例中,该方法还可以包括:对k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,将所得到的编码比特写入码流。也就是说,在本申请实施例中,对于k个变换层的一个或多个交流系数残差值来说,这里是按照预设数值写入码流的。这样,解码端也需要解码码流,以确定出k个变换层的一个或多个交流系数残差值为预设数值。In some embodiments, the method may further include: encoding one or more AC coefficient residual values of k transform layers according to preset values, and writing the obtained coded bits into the bitstream. That is, in the embodiment of the present application, for one or more AC coefficient residual values of k transform layers, the bitstream is written according to the preset values. In this way, the decoding end also needs to decode the bitstream to determine that one or more AC coefficient residual values of k transform layers are the preset values.
在一些实施例中,该方法还可以包括:确定k个变换层的全部交流系数残差值为预设数值。也就是说,在本申请实施例中,对于确定k个变换层的一个或多个交流系数残差值来说,在确定对当前点云的k个变换层进行跳跃编码时,这时候也可以确定k个变换层的全部交流系数残差值为预设数值。In some embodiments, the method may further include: determining that all AC coefficient residual values of k transform layers are preset values. That is, in the embodiment of the present application, for determining one or more AC coefficient residual values of k transform layers, when determining to skip-code the k transform layers of the current point cloud, all AC coefficient residual values of the k transform layers may also be determined as preset values.
在一些实施例中,该方法还可以包括:对当前点云中的点进行层划分,确定当前点云对应的多个变换层以及当前点云的根节点;其中,多个变换层包括k个变换层和其他变换层。 In some embodiments, the method may further include: dividing the points in the current point cloud into layers, determining multiple transformation layers corresponding to the current point cloud and the root node of the current point cloud; wherein the multiple transformation layers include k transformation layers and other transformation layers.
需要说明的是,在本申请实施例中,可以基于八叉树结构对当前点云中的点进行层划分,得到多个变换层。具体地,对于划分的八叉树结构,可以是从根节点到子节点自上向下进行每一层的变换。It should be noted that in the embodiment of the present application, the points in the current point cloud can be divided into layers based on the octree structure to obtain multiple transformation layers. Specifically, for the divided octree structure, each layer can be transformed from the root node to the child node from top to bottom.
还需要说明的是,在实际应用中,在当前点云的最后几层,这几层中交流系数残差值为0个个数占据95%以上。为了提升编码效率,在一些实施例中,该方法还可以包括:将k个变换层设置为多个变换层中从根节点自上向下的最后k个变换层。It should also be noted that, in practical applications, in the last few layers of the current point cloud, the number of AC coefficient residual values in these layers that are 0 accounts for more than 95%. In order to improve coding efficiency, in some embodiments, the method may also include: setting the k transformation layers to be the last k transformation layers from the root node from top to bottom in the multiple transformation layers.
也就是说,这里主要是针对当前点云的最后k个变换层是否进行跳跃编码。示例性地,在第一编码参数指示对当前点云的最后k个变换层进行跳跃编码时,那么可以直接将最后k个变换层的一个或多个交流系数残差值按照0进行编码处理,从而能够提升编码效率。That is to say, here it is mainly about whether to skip code the last k transformation layers of the current point cloud. For example, when the first coding parameter indicates to skip code the last k transformation layers of the current point cloud, then one or more AC coefficient residual values of the last k transformation layers can be directly coded as 0, thereby improving coding efficiency.
S1803,对k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,将所得到的编码比特写入码流。S1803, performing encoding processing on one or more AC coefficient residual values of k transformation layers according to preset values, and writing the obtained encoding bits into the bit stream.
需要说明的是,在本申请实施例中,交流系数残差值是位于码流的属性码流单元中。在一些实施例中,该方法可以包括:对k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,将所得到的编码比特写入码流中的属性码流单元。It should be noted that, in the embodiment of the present application, the AC coefficient residual value is located in the attribute code stream unit of the code stream. In some embodiments, the method may include: encoding one or more AC coefficient residual values of k transform layers according to preset values, and writing the obtained encoding bits into the attribute code stream unit in the code stream.
还需要说明的是,在本申请实施例中,当前点云对应的多个变换层可以包括k个变换层和除k个变换层之外的其他变换层。这样,除了k个变换层之外,其他变换层的交流系数残差值需要正常编码。在一些实施例中,该方法还可以包括:在第一编码参数指示对当前点云的k个变换层进行跳跃编码时,确定多个变换层中k个变换层之外其他变换层的交流系数残差值;对其他变换层的交流系数残差值进行编码处理,将所得到的编码比特写入码流。It should also be noted that, in an embodiment of the present application, the multiple transformation layers corresponding to the current point cloud may include k transformation layers and other transformation layers except the k transformation layers. In this way, except for the k transformation layers, the residual values of the AC coefficients of other transformation layers need to be encoded normally. In some embodiments, the method may also include: when the first encoding parameter indicates that the k transformation layers of the current point cloud are to be skipped, determining the residual values of the AC coefficients of other transformation layers except the k transformation layers in the multiple transformation layers; encoding the residual values of the AC coefficients of other transformation layers, and writing the obtained encoding bits into the bitstream.
在一种具体的实施例中,对其他变换层的交流系数残差值进行编码处理,将所得到的编码比特写入码流,可以包括:对其他变换层的交流系数残差值进行编码处理,将所得到的编码比特写入码流中的属性码流单元。In a specific embodiment, encoding the AC coefficient residual values of other transformation layers and writing the obtained coded bits into the bitstream may include: encoding the AC coefficient residual values of other transformation layers and writing the obtained coded bits into the attribute bitstream unit in the bitstream.
在一些实施例中,该方法还可以包括:确定多个变换层中的点的交流系数预测值;根据多个变换层中的点的交流系数初始值和多个变换层中的点的交流系数预测值,确定多个变换层的交流系数残差值。In some embodiments, the method may further include: determining AC coefficient prediction values of points in multiple transformation layers; determining AC coefficient residual values of multiple transformation layers based on the AC coefficient initial values of points in multiple transformation layers and the AC coefficient prediction values of points in multiple transformation layers.
需要说明的是,在本申请实施例中,该方法还包括:确定多个变换层中的点的属性初始值;对多个变换层中的点的属性初始值进行区域自适应分层变换,确定多个变换层中的点的交流系数初始值以及根节点的直流系数值。It should be noted that, in an embodiment of the present application, the method also includes: determining the initial values of the attributes of points in multiple transformation layers; performing regional adaptive hierarchical transformation on the initial values of the attributes of points in multiple transformation layers, and determining the initial values of the AC coefficients of the points in multiple transformation layers and the DC coefficient value of the root node.
在这里,直流系数也可以称为低频系数,用DC系数表示;交流系数也可以称为高频系数,用AC系数表示。示例性地,以第d变换层为例,第d变换层包括m个节点。区域自适应分层变换可以用Tnode表示。其中,对于属性初始值来说,对应的属性变换公式如下所示:
Here, the DC coefficient can also be called a low-frequency coefficient and is represented by a DC coefficient; the AC coefficient can also be called a high-frequency coefficient and is represented by an AC coefficient. For example, taking the dth transformation layer as an example, the dth transformation layer includes m nodes. The regional adaptive hierarchical transformation can be represented by T node . For the initial value of the attribute, the corresponding attribute transformation formula is as follows:
还需要说明的是,在本申请实施例中,该方法还包括:确定多个变换层中的点的属性预测值;对多个变换层中的点的属性预测值进行区域自适应分层变换,确定多个变换层中的点的交流系数预测值。It should also be noted that, in an embodiment of the present application, the method also includes: determining the attribute prediction values of points in multiple transformation layers; performing regional adaptive hierarchical transformation on the attribute prediction values of points in multiple transformation layers to determine the AC coefficient prediction values of points in multiple transformation layers.
在这里,对于确定多个变换层中的点的属性预测值,可以是基于帧内预测或者帧间预测来确定的。在一些实施例中,该方法可以包括:在当前点云允许使用帧内预测时,对多个变换层中的点进行帧内预测,确定多个变换层中的点的属性预测值;在当前点云允许使用帧间预测时,确定当前点云的参考点云,并根据参考点云对多个变换层中的点进行帧间预测,确定多个变换层中的点的属性预测值。Here, the attribute prediction values of points in multiple transform layers can be determined based on intra-frame prediction or inter-frame prediction. In some embodiments, the method may include: when the current point cloud allows the use of intra-frame prediction, intra-frame prediction is performed on the points in multiple transform layers to determine the attribute prediction values of the points in the multiple transform layers; when the current point cloud allows the use of inter-frame prediction, a reference point cloud of the current point cloud is determined, and inter-frame prediction is performed on the points in multiple transform layers based on the reference point cloud to determine the attribute prediction values of the points in the multiple transform layers.
这样,在确定多个变换层中的点的属性预测值之后,基于区域自适应分层变换可以确定出对应的交流系数预测值。其中,区域自适应分层变换可以用Tnode表示。对应的属性变换公式如下所示:
In this way, after determining the attribute prediction values of points in multiple transformation layers, the corresponding AC coefficient prediction values can be determined based on the regional adaptive hierarchical transformation. The regional adaptive hierarchical transformation can be represented by T node . The corresponding attribute transformation formula is as follows:
在一些实施例中,根据多个变换层中的点的交流系数初始值和多个变换层中的点的交流系数预测值,确定多个变换层的交流系数残差值,可以包括:对多个变换层中的点的交流系数初始值和多个变换层中的点的交流系数预测值进行减法运算,得到多个变换层中的点的交流系数预测残差;对多个变换层中的点的交流系数预测残差进行量化处理,得到多个变换层的交流系数残差值。In some embodiments, determining AC coefficient residual values of multiple transformation layers based on AC coefficient initial values of points in multiple transformation layers and AC coefficient predicted values of points in multiple transformation layers can include: performing subtraction operations on the AC coefficient initial values of points in multiple transformation layers and the AC coefficient predicted values of points in multiple transformation layers to obtain AC coefficient prediction residuals of points in multiple transformation layers; and quantizing the AC coefficient prediction residuals of points in multiple transformation layers to obtain AC coefficient residual values of multiple transformation layers.
示例性地,以第d变换层为例,第d变换层包括m个节点。对于多个变换层中的点的交流系数预测残差来说,可以根据交流系数初始值与交流系数预测值进行减法运算得到,具体如下所示:
For example, taking the dth transformation layer as an example, the dth transformation layer includes m nodes. For the AC coefficient prediction residuals of points in multiple transformation layers, it can be obtained by subtracting the initial value of the AC coefficient from the predicted value of the AC coefficient, as shown below:
在一些实施例中,该方法还可以包括:在第一编码参数指示对当前点云的k个变换层不进行跳跃编码时,对多个变换层的交流系数残差值进行编码处理,将所得到的编码比特写入码流。In some embodiments, the method may further include: when the first coding parameter indicates that the k transformation layers of the current point cloud are not to be skip-coded, encoding the residual values of the AC coefficients of the multiple transformation layers, and writing the obtained coding bits into the bitstream.
需要说明的是,在本申请实施例中,如果对当前点云的k个变换层不进行跳跃编码,那么可以说明当前点云对应的多个变换层均需要编码各自的交流系数残差值。在一些实施例中,该方法还可以包括:对多个变换层的交流系数残差值进行编码处理,将所得到的编码比特写入码流中的属性码流单元。It should be noted that, in the embodiment of the present application, if the k transformation layers of the current point cloud are not skip-coded, it can be said that the multiple transformation layers corresponding to the current point cloud all need to encode their respective AC coefficient residual values. In some embodiments, the method may also include: encoding the AC coefficient residual values of the multiple transformation layers, and writing the obtained encoding bits into the attribute code stream unit in the code stream.
也就是说,在本申请实施例中,第一编码参数和交流系数残差值都是位于码流的属性码流单元中。具体地,在一些实施例中,该方法还可以包括:在属性码流单元中,确定第一编码参数对应的字段位于交流系数残差值对应的字段之后。That is, in the embodiment of the present application, the first coding parameter and the AC coefficient residual value are both located in the attribute code stream unit of the code stream. Specifically, in some embodiments, the method may also include: in the attribute code stream unit, determining that the field corresponding to the first coding parameter is located after the field corresponding to the AC coefficient residual value.
需要说明的是,在本申请实施例中,只有根节点的直流系数值需要写入码流中。在一些实施例中,该方法还可以包括:对根节点的直流系数值进行编码处理,将所得到的编码比特写入码流。It should be noted that, in the embodiment of the present application, only the DC coefficient value of the root node needs to be written into the bitstream. In some embodiments, the method may further include: encoding the DC coefficient value of the root node, and writing the obtained encoding bits into the bitstream.
需要说明的是,在本申请实施例中,该方法还可以包括:对根节点的直流系数值进行编码处理,将所得到的编码比特写入码流中的属性码流单元。It should be noted that, in an embodiment of the present application, the method may further include: encoding the DC coefficient value of the root node, and writing the obtained encoding bits into the attribute code stream unit in the code stream.
还需要说明的是,在本申请实施例中,对于多个变换层,在每次变换时,可以将直流系数值直接传递给下一层,但是需要对交流系数值进行残差计算,并对每一层的交流系数残差值进行量化与熵编码。另外,如果某一变换层只有一个点时,可以直接将该点的属性值作为直流系数值传递给下一层。在该过程中,只有根节点的直流系数值需要写入码流中。It should also be noted that in the embodiment of the present application, for multiple transformation layers, the DC coefficient value can be directly passed to the next layer at each transformation, but the residual calculation of the AC coefficient value is required, and the residual value of the AC coefficient of each layer is quantized and entropy encoded. In addition, if there is only one point in a transformation layer, the attribute value of the point can be directly passed to the next layer as the DC coefficient value. In this process, only the DC coefficient value of the root node needs to be written into the bitstream.
对于属性码流来说,图21为一种相关技术的码流结构示意图,图22为本申请实施例提供的一种码流结构示意图。其中,如图22所示,bits、flag分别代表编码量化系数残差、RDO层置零标志位,n代表点云中点的总个数。在编码时,先将根节点的DC系数值与全部AC系数残差值熵编码写入码流,随后将标志位flag采用算术编码写入码流。这样在解码端,可以先将标志位解出,以确定出需要解码的交流系数残差值的变换层数,然后按照第一解码参数指示的将需要解码的交流系数残差值解码出来,并且针对执行跳跃解码的k个变换层的交流系数残差值按照0恢复。For the attribute code stream, Figure 21 is a schematic diagram of a code stream structure of a related technology, and Figure 22 is a schematic diagram of a code stream structure provided by an embodiment of the present application. Among them, as shown in Figure 22, bits and flag represent the coded quantization coefficient residual and the RDO layer zero flag respectively, and n represents the total number of points in the point cloud. During encoding, the DC coefficient value of the root node and all AC coefficient residual values are entropy encoded and written into the code stream, and then the flag flag is written into the code stream using arithmetic coding. In this way, at the decoding end, the flag can be first decoded to determine the number of transformation layers of the AC coefficient residual value that needs to be decoded, and then the AC coefficient residual value that needs to be decoded is decoded according to the indication of the first decoding parameter, and the AC coefficient residual value of the k transformation layers for performing jump decoding is restored to 0.
在一些实施例中,该方法还可以包括:确定第二编码参数的取值;在第二编码参数指示开启当前点云的跳跃编码时,执行确定第一编码参数的取值的步骤。In some embodiments, the method may further include: determining a value of a second encoding parameter; and when the second encoding parameter indicates starting jump encoding of the current point cloud, executing the step of determining a value of the first encoding parameter.
需要说明的是,在本申请实施例中,对于第二编码参数来说,第二编码参数可以用于指示是否开启当前点云的跳跃编码,即用于指示本申请实施例的技术方案是否开启。在一些实施例中,若第二编码参数的取值为第三值,则确定第二编码参数指示开启当前点云的跳跃编码;若第二编码参数的取值为第四值,则确定第二编码参数指示不开启当前点云的跳跃编码。It should be noted that in the embodiment of the present application, for the second encoding parameter, the second encoding parameter can be used to indicate whether to enable the jump encoding of the current point cloud, that is, to indicate whether the technical solution of the embodiment of the present application is enabled. In some embodiments, if the value of the second encoding parameter is the third value, it is determined that the second encoding parameter indicates that the jump encoding of the current point cloud is enabled; if the value of the second encoding parameter is the fourth value, it is determined that the second encoding parameter indicates that the jump encoding of the current point cloud is not enabled.
在一些实施例中,该方法还包括:对第二编码参数的取值进行编码处理,将所得到的编码比特写入码流。在一种具体的实施例中,对第二编码参数的取值进行编码处理,将所得到的编码比特写入码流中的属性参数集单元。也就是说,第二编码参数具体是位于码流中的属性参数集单元。In some embodiments, the method further comprises: encoding the value of the second encoding parameter, and writing the obtained encoding bits into the bitstream. In a specific embodiment, encoding the value of the second encoding parameter, and writing the obtained encoding bits into the attribute parameter set unit in the bitstream. That is, the second encoding parameter is specifically an attribute parameter set unit in the bitstream.
还需要说明的是,在本申请实施例中,第二编码参数可以用语法元素的形式表示,此时第二编码参数可以称为第二语法元素,用skip_raht_enabled_flag表示。其中,第二语法元素也可以用于指示是否开启当前点云的跳跃编码,即用于指示本申请实施例的技术方案是否开启。在一些实施例中,若开启当前点云的跳跃编码,则确定第二语法元素的取值为第三值;若不开启当前点云的跳跃编码,则确定第二语法元素的取值为第四值。It should also be noted that, in the embodiment of the present application, the second coding parameter can be expressed in the form of a syntax element. In this case, the second coding parameter can be called a second syntax element, represented by skip_raht_enabled_flag. Among them, the second syntax element can also be used to indicate whether the skip coding of the current point cloud is enabled, that is, to indicate whether the technical solution of the embodiment of the present application is enabled. In some embodiments, if the skip coding of the current point cloud is enabled, the value of the second syntax element is determined to be a third value; if the skip coding of the current point cloud is not enabled, the value of the second syntax element is determined to be a fourth value.
也就是说,在本申请实施例中,根据第二语法元素的取值,确定第二编码参数的取值,可以包括:将第二编码参数的取值设置为等于第二语法元素的取值。That is, in the embodiment of the present application, determining the value of the second coding parameter according to the value of the second syntax element may include: setting the value of the second coding parameter to be equal to the value of the second syntax element.
还需要说明的是,在本申请实施例中,第三值与第四值不同。其中,第三值可以设置为1,第四值可以设置为0;或者,第三值可以设置为0,第四值可以设置为1;或者,第三值可以设置为真(true),第四值可以设置为假(false);或者,第三值可以设置为假(false),第四值可以设置为真(true)。在一种具体的实施例中,第三值设置为1,第四值设置为0,但是不作任何限定。It should also be noted that in the embodiment of the present application, the third value is different from the fourth value. The third value can be set to 1 and the fourth value can be set to 0; or, the third value can be set to 0 and the fourth value can be set to 1; or, the third value can be set to true (true) and the fourth value can be set to false (false); or, the third value can be set to false (false) and the fourth value can be set to true (true). In a specific embodiment, the third value is set to 1 and the fourth value is set to 0, but this is not limited to any limitation.
在一些实施例中,该方法还可以包括:在对当前点云的k个变换层的待处理分量进行跳跃编码时,确定k个变换层的待处理分量的一个或多个交流系数残差值为预设数值;对k个变换层的待处理分量的一个或多个交流系数残差值按照预设数值进行编码处理,将所得到的编码比特写入码流。In some embodiments, the method may also include: when skip encoding the to-be-processed components of the k transformation layers of the current point cloud, determining that one or more AC coefficient residual values of the to-be-processed components of the k transformation layers are preset values; encoding the one or more AC coefficient residual values of the to-be-processed components of the k transformation layers according to the preset values, and writing the obtained coded bits into the bit stream.
需要说明的是,在本申请实施例中,该方法还可以包括:确定当前点云中k个变换层之外其他变换层的待处理分量的交流系数残差值;对其他变换层的待处理分量的交流系数残差值进行编码处理,将所得到的编码比特写入码流。 It should be noted that in an embodiment of the present application, the method may also include: determining the AC coefficient residual values of the components to be processed in other transformation layers other than the k transformation layers in the current point cloud; encoding the AC coefficient residual values of the components to be processed in other transformation layers, and writing the obtained coded bits into the bit stream.
还需要说明的是,在本申请实施例中,该方法还可以包括:确定第三编码参数的取值;其中,第二编码参数用于指示对当前点云的k个变换层的待处理分量是否进行跳跃编码;对第三编码参数的取值进行编码处理,将所得到的编码比特写入码流。It should also be noted that, in an embodiment of the present application, the method may further include: determining a value of a third coding parameter; wherein the second coding parameter is used to indicate whether to perform jump coding on the to-be-processed components of the k transformation layers of the current point cloud; encoding the value of the third coding parameter, and writing the obtained coding bits into the bit stream.
需要说明的是,在本申请实施例中,待处理分量可以包括第一颜色分量、第二颜色分量和第三颜色分量中的至少一项。It should be noted that, in the embodiment of the present application, the component to be processed may include at least one of the first color component, the second color component and the third color component.
还需要说明的是,在本申请实施例中,第三编码参数可以用语法元素的形式表示,此时第三编码参数可以称为第三语法元素。其中,当待处理分量为第一颜色分量(例如Y分量)时,这时候可以用flag_Y表示,用于指示对当前点云的k个变换层的Y分量是否进行跳跃编码;当待处理分量为第二颜色分量(例如U分量)时,这时候可以用flag_U表示,用于指示对当前点云的k个变换层的U分量是否进行跳跃编码;当待处理分量为第三颜色分量(例如V分量)时,这时候可以用flag_V表示,用于指示对当前点云的k个变换层的V分量是否进行跳跃编码。也就是说,在稠密点云的颜色属性中,可以扩展到三通道同时使用面向RAHT变换系数的跳跃编码模式,这时候对于第三编码参数来说,可以设置三个标志位flag_Y、flag_U、flag_V分别记录进行跳跃编码的系数层数。It should also be noted that in an embodiment of the present application, the third coding parameter can be expressed in the form of a syntax element, and the third coding parameter can be called a third syntax element. Among them, when the component to be processed is the first color component (for example, the Y component), it can be represented by flag_Y at this time to indicate whether the Y component of the k transform layers of the current point cloud is skip-coded; when the component to be processed is the second color component (for example, the U component), it can be represented by flag_U at this time to indicate whether the U component of the k transform layers of the current point cloud is skip-coded; when the component to be processed is the third color component (for example, the V component), it can be represented by flag_V at this time to indicate whether the V component of the k transform layers of the current point cloud is skip-coded. That is to say, in the color attributes of the dense point cloud, it can be extended to three channels and use the skip coding mode for RAHT transform coefficients at the same time. At this time, for the third coding parameter, three flags flag_Y, flag_U, and flag_V can be set to record the number of coefficient layers for skip coding respectively.
在一种具体的实施例中,图23为本申请实施例提供的一种编码方法的详细流程示意图。如图23所示,对于原始点云(或称为“初始点云”),可以进行帧内预测或者帧间预测。其中,在帧内预测过程中,对原始点云进行上采样预测,可以得到预测点云,然后进行RAHT变换能够确定预测AC系数;在帧间预测过程中,根据原始点云的相邻帧,可以得到参考点云,然后进行RAHT变换也能够确定预测AC系数。对于原始点云进行RAHT变换可以确定根节点的DC系数和原始AC系数;对原始AC系数与预测AC系数进行减法运算,可以得到预测残差,在对预测残差进行量化之后,可以根据标志位flag的取值确定面向RAHT变换系数的跳跃编码模式。其中,在RAHT算法中,原始点云从根节点开始,从上向下对于每一个2×2×2的块逐层RAHT变换。对于多参数的后m层,分别将后k(k=1,2,...,m)层的AC系数残差值进行RDO判断,若编码的率失真代价高,则置flag为最小RDcost对应层数k,只编码前面变换层的AC系数残差值;若不编码的率失真代价高,则置flag为0,将全部AC系数残差值均进行编码得到属性码流。具体操作流程如图23所示。In a specific embodiment, FIG23 is a detailed flow chart of a coding method provided by an embodiment of the present application. As shown in FIG23, intra-frame prediction or inter-frame prediction can be performed for the original point cloud (or referred to as "initial point cloud"). In the intra-frame prediction process, the original point cloud is upsampled and predicted to obtain a predicted point cloud, and then a RAHT transform is performed to determine the predicted AC coefficient; in the inter-frame prediction process, a reference point cloud can be obtained according to the adjacent frames of the original point cloud, and then a RAHT transform can also be performed to determine the predicted AC coefficient. Performing a RAHT transform on the original point cloud can determine the DC coefficient and the original AC coefficient of the root node; subtracting the original AC coefficient from the predicted AC coefficient can obtain a predicted residual, and after quantizing the predicted residual, the jump coding mode for the RAHT transform coefficient can be determined according to the value of the flag. In the RAHT algorithm, the original point cloud starts from the root node, and RAHT transforms each 2×2×2 block layer by layer from top to bottom. For the latter m layers of multiple parameters, the AC coefficient residual values of the latter k (k = 1, 2, ..., m) layers are respectively subjected to RDO judgment. If the rate-distortion cost of coding is high, the flag is set to the minimum RDcost corresponding layer k, and only the AC coefficient residual values of the previous transformed layers are coded; if the rate-distortion cost of not coding is high, the flag is set to 0, and all AC coefficient residual values are coded to obtain the attribute code stream. The specific operation flow is shown in Figure 23.
在本申请的又一实施例中,本申请实施例提供了一种码流,其中,码流是根据待编码信息进行比特编码生成的;其中,待编码信息包括下述至少一项:In another embodiment of the present application, the embodiment of the present application provides a code stream, wherein the code stream is generated by bit encoding according to information to be encoded; wherein the information to be encoded includes at least one of the following:
当前点云对应的多个变换层的交流系数残差值、当前点云的根节点的直流系数值、当前点云的k个变换层的一个或多个交流系数残差值为预设数值、当前点云中k个变换层之外其他变换层的交流系数残差值、第一编码参数的取值、第二编码参数的取值和第三编码参数的取值。The AC coefficient residual values of multiple transformation layers corresponding to the current point cloud, the DC coefficient value of the root node of the current point cloud, one or more AC coefficient residual values of k transformation layers of the current point cloud are preset values, the AC coefficient residual values of other transformation layers outside the k transformation layers in the current point cloud, the value of the first coding parameter, the value of the second coding parameter and the value of the third coding parameter.
在本申请实施例中,第一编码参数用于指示对当前点云的k个变换层是否进行跳跃编码,第二编码参数用于指示是否开启当前点云的跳跃编码,第三编码参数用于指示对当前点云的k个变换层待处理分量的是否进行跳跃编码。In an embodiment of the present application, the first encoding parameter is used to indicate whether to perform jump encoding on the k transformation layers of the current point cloud, the second encoding parameter is used to indicate whether to turn on jump encoding of the current point cloud, and the third encoding parameter is used to indicate whether to perform jump encoding on the k transformation layers of the current point cloud to be processed.
还需要说明的是,在本申请实施例中,对于编码参数而言,解码端通过解码码流获得的参数可以称为“解码参数”,两者的含义是相同的,只是在编码端和解码端的名称不同而已。It should also be noted that in the embodiment of the present application, for the encoding parameters, the parameters obtained by the decoding end through decoding the code stream can be called "decoding parameters", and the meanings of the two are the same, but the names at the encoding end and the decoding end are different.
本申请实施例提供了一种编码方法,确定第一编码参数的取值;在第一编码参数指示对当前点云的k个变换层进行跳跃编码时,确定k个变换层的一个或多个交流系数残差值为预设数值;对k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,将所得到的编码比特写入码流。这样,在确定对当前点云的k个变换层进行跳跃编码时,这时候直接将这k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,可以有效改善RAHT变换中最后几层编码AC系数值出现过多0的现象,从而提高了编码效率,实现了解码端重建点云在平均码率下的质量增强,进而提升了点云的编解码性能。The embodiment of the present application provides a coding method, which determines the value of a first coding parameter; when the first coding parameter indicates that the k transformation layers of the current point cloud are to be skip-coded, determines that one or more residual values of the AC coefficients of the k transformation layers are preset values; encodes the one or more residual values of the AC coefficients of the k transformation layers according to the preset values, and writes the obtained coded bits into the bitstream. In this way, when it is determined that the k transformation layers of the current point cloud are to be skip-coded, the one or more residual values of the AC coefficients of the k transformation layers are directly encoded according to the preset values, which can effectively improve the phenomenon that too many 0s appear in the AC coefficient values of the last few layers of coding in the RAHT transform, thereby improving the coding efficiency, achieving quality enhancement of the point cloud reconstructed at the decoding end at the average bit rate, and further improving the encoding and decoding performance of the point cloud.
在本申请的又一实施例中,基于前述实施例所述的编解码方法,这里提出了一种面向RAHT变换系数的跳跃编码模式。其中,在RAHT算法从根节点到子节点逐层计算的过程中,随着层数的增加,变换所得的编码AC系数的个数逐渐增多,系数值逐渐减少。在雷达点云的最后几层,AC系数的个数又占据了全部AC系数的大半,然而这几层中0的个数却占据了95%以上,因此对最后几层AC系数的编码必然有很大的码流浪费。本技术方案提出基于率失真优化方式来判断RAHT变换系数的跳跃编码模式,使用率失真优化确定对于多参数的最后m层、m-1层...AC系数不编码的RDO代价,与系数全部编码的RDO代价。若对于AC系数不编码的代价小于全部编码代价,则比较不编码的RDO代价在对几层使用时最小,并将标志位flag的取值设置为最小代价对应层数k,同时进行熵编码。解码器解码时,若解码到标志位flag为k则对最后k层的AC系数残差值按照0重建;若解码出flag为0则全部按原值重建,本技术方案的整体流程如图24所示,具体可以包括:In another embodiment of the present application, based on the encoding and decoding method described in the above embodiment, a jump coding mode for RAHT transform coefficients is proposed here. Among them, in the process of layer-by-layer calculation of the RAHT algorithm from the root node to the child node, as the number of layers increases, the number of coded AC coefficients obtained by the transformation gradually increases, and the coefficient value gradually decreases. In the last few layers of the radar point cloud, the number of AC coefficients occupies more than half of all AC coefficients, but the number of 0s in these layers occupies more than 95%, so the encoding of the last few layers of AC coefficients must have a large waste of code stream. This technical solution proposes to judge the jump coding mode of RAHT transform coefficients based on the rate-distortion optimization method, and use rate-distortion optimization to determine the RDO cost of not encoding the AC coefficients of the last m layers, m-1 layers... of multiple parameters, and the RDO cost of encoding all coefficients. If the cost of not encoding the AC coefficient is less than the total encoding cost, the RDO cost of not encoding is the smallest when used for several layers, and the value of the flag is set to the number of layers k corresponding to the minimum cost, and entropy coding is performed at the same time. When the decoder decodes, if the decoded flag flag is k, the AC coefficient residual value of the last k layers is reconstructed as 0; if the decoded flag is 0, all are reconstructed according to the original value. The overall process of this technical solution is shown in Figure 24, which may specifically include:
S2401,计算多参数层leveln-m~leveln AC系数残差值编码的每层的RDcost以及不编码的RDcost并 进行比较,若不编码的RDcost小,则置标志位flag为最小代价RDcost的对应层总数k,否则置为0。S2401, calculate the RDcost of each layer of the multi-parameter layer level nm ~ level n AC coefficient residual value encoding and the RDcost of each layer not encoded and After comparison, if the uncoded RDcost is smaller, the flag is set to the total number of layers k corresponding to the minimum cost RDcost, otherwise it is set to 0.
S2402,对标志位flag进行算术编码。S2402, perform arithmetic coding on the flag bit flag.
S2403,解码端先解码出标志位flag,若flag的取值为k,则将leveln-k+1~leveln的AC系数残差值按0重建,否则按照原值重建。S2403, the decoding end first decodes the flag flag, and if the value of flag is k, the AC coefficient residual values of level n-k+1 to level n are reconstructed as 0, otherwise they are reconstructed as original values.
在一种具体的实现方式中,该编解码方法的实施过程可以包括:In a specific implementation, the implementation process of the encoding and decoding method may include:
(1)率失真优化技术原理。(1) Principle of rate-distortion optimization technology.
在视频编码领域中,编码后的码率和失真是相互矛盾的关系,如果想要更小的失真来获得更高质量的重建视频,就需要提高传输的码率;但是码率不能无限制的提高,有些情况下就需要降低码率来保证视频传输的流畅性。为了更好地提高编码的效率,需要综合的考虑码率与失真,找到二者的折中点,使得在固定码率的条件下,失真尽可能的小,可以如式(11)所示。其中,D表示失真,R表示码率,表示编码的条件参数配置,如量化步长等。上式是一个有约束的优化问题,可以利用拉格朗日乘子将其转化为如式(12)所示的形式。其中,RDcost为率失真代价,λ为拉格朗日乘子。这便是视频编码领域中的率失真优化问题。In the field of video coding, the bit rate and distortion after coding are in a contradictory relationship. If you want to obtain a higher quality reconstructed video with smaller distortion, you need to increase the transmission bit rate; however, the bit rate cannot be increased indefinitely. In some cases, you need to reduce the bit rate to ensure the smoothness of video transmission. In order to better improve the efficiency of coding, it is necessary to comprehensively consider the bit rate and distortion and find a compromise between the two so that the distortion is as small as possible under the condition of a fixed bit rate, as shown in formula (11). Where D represents distortion, R represents bit rate, represents the conditional parameter configuration of encoding, such as quantization step size. The above formula is a constrained optimization problem, which can be transformed into the form shown in formula (12) using Lagrange multipliers. Among them, RDcost is the rate-distortion cost, and λ is the Lagrange multiplier. This is the rate-distortion optimization problem in the field of video coding.
在本申请实施例中,这里提出了计算雷达点云多参数的最后m层、m-1层...AC系数残差值不编码的RDOcost,与系数残差值全部编码的RDOcost,相互比较从而决定是否编码这些系数残差值的方法来提高编码效率。由于RDcost计算不方便,可以采取计算ΔRDcost的方法,以k层为例,计算公式如式(13)~(15)所示。其中,ΔD用后k层所有AC系数残差值的平方值表示,用来指代这些系数残差值全部不编码后的失真代价,Rorg是相关技术的编码方案中的码流消耗,而最后k层AC系数残差值全部不编码后的码率消耗仅有标志位flag所占的1bit,因此ΔR表示最后k层AC系数残差值不编码与编码的码率消耗之差,即最后k层AC系数残差值不编节省的码流。此时,计算所得的ΔRDcost若大于0,表示不编码的失真代价较大,此时将标志位flag置为0;若计算所得的ΔRDcost小于0,表示不编码的码率节省较大,需要继续比较其他层的ΔRDcost,决定是否将标志位flag置为k。In the embodiment of the present application, it is proposed to calculate the RDOcost of the last m layers, m-1 layers...AC coefficient residual values of the radar point cloud multi-parameters without coding, and compare them with the RDOcost of all the coefficient residual values encoded, so as to decide whether to encode these coefficient residual values. The method of improving the coding efficiency. Since the calculation of RDcost is inconvenient, the method of calculating ΔRDcost can be adopted. Taking the k layer as an example, the calculation formula is shown in equations (13) to (15). Among them, ΔD is represented by the square value of all AC coefficient residual values of the last k layers, which is used to refer to the distortion cost after all these coefficient residual values are not encoded, R org is the code stream consumption in the coding scheme of the related technology, and the code rate consumption after all the last k layers of AC coefficient residual values are not encoded is only 1 bit occupied by the flag bit flag, so ΔR represents the difference in code rate consumption between the last k layers of AC coefficient residual values not encoded and encoded, that is, the code stream saved by not encoding the last k layers of AC coefficient residual values. At this time, if the calculated ΔRDcost is greater than 0, it means that the distortion cost of not encoding is large, and the flag is set to 0; if the calculated ΔRDcost is less than 0, it means that the bit rate saving of not encoding is large, and it is necessary to continue to compare the ΔRDcost of other layers to decide whether to set the flag to k.
拉格朗日乘子λ的选取采用H.266/VCC视频编码中的形式,如式(16)所示。其中c为常数,QP为量化步长。选取c的值为0.01、0.1、0.2、0.3、0.4,并选取测试点云在C1条件下测试的属性压缩性能,分析找到c的最优区间。继续缩小搜索步长,最终确定常数c的最优取值为0.12。The Lagrange multiplier λ is selected in the form of H.266/VCC video coding, as shown in equation (16). Where c is a constant and QP is the quantization step size. The values of c are selected as 0.01, 0.1, 0.2, 0.3, and 0.4, and the attribute compression performance of the test point cloud under the C1 condition is selected to analyze and find the optimal interval of c. The search step size is further reduced, and the optimal value of the constant c is finally determined to be 0.12.
(2)编码端实现细节。(2) Implementation details on the encoding side.
在RAHT算法中,原始点云从根节点开始,从上到下对于每一个2×2×2的块逐层RAHT变换,如果允许帧内预测或帧间预测,将预测后的点进行RAHT变换,得到的预测AC系数值与原始AC系数值相减,将残差值进行量化。对于多参数的最后m层,分别将最后k(k=1,2,...,m)层的AC系数残差值进行RDO判断,若编码的率失真代价高,则置flag为最小RDcost对应层数k,只编码前面层的AC系数残差值;若不编码的率失真代价高,则置flag为0,将全体AC系数残差值均进行编码得到属性码流。在编码端操作流程图如前述的图23所示。In the RAHT algorithm, the original point cloud starts from the root node, and RAHT transforms each 2×2×2 block layer by layer from top to bottom. If intra-frame prediction or inter-frame prediction is allowed, the predicted points are RAHT transformed, and the predicted AC coefficient value is subtracted from the original AC coefficient value, and the residual value is quantized. For the last m layers of multiple parameters, the AC coefficient residual values of the last k (k=1,2,...,m) layers are respectively subjected to RDO judgment. If the encoding rate-distortion cost is high, the flag is set to the minimum RDcost corresponding to the layer number k, and only the AC coefficient residual values of the previous layers are encoded; if the rate-distortion cost of not encoding is high, the flag is set to 0, and all AC coefficient residual values are encoded to obtain the attribute code stream. The operation flow chart at the encoding end is shown in the aforementioned Figure 23.
(3)码流结构。(3) Code stream structure.
在这里,码流结构图如图21和图22所示,其中,bits,flag分别代表编码量化系数残差、RDO层置零标志位,n代表点云中点的总个数。编码时,先将根节点的DC系数值与全部AC系数残差值熵编码写入码流,随后将标志位flag采用算术编码写入码流。在解码端,先将标志位解出,以得到需要解码的RAHT参数层数,随后将按照标志位flag的指示将需要解码的AC系数残差值采用熵解码的方式解到对应参数矩阵中,其余层的AC系数残差值按0恢复。Here, the code stream structure diagram is shown in Figures 21 and 22, where bits and flag represent the coded quantization coefficient residual and the RDO layer zero flag respectively, and n represents the total number of points in the point cloud. During encoding, the DC coefficient value of the root node and all the AC coefficient residual values are entropy encoded and written into the code stream, and then the flag flag is arithmetic encoded and written into the code stream. At the decoding end, the flag is first decoded to obtain the number of RAHT parameter layers to be decoded, and then the AC coefficient residual values to be decoded are decoded into the corresponding parameter matrix by entropy decoding according to the indication of the flag flag, and the AC coefficient residual values of the remaining layers are restored to 0.
(4)解码端实现细节。(4) Implementation details of the decoding end.
在解码端操作流程图如图17所示,解码端读取码流,首先解码出位于码流最后端的置零标志位flag,若解码出flag值为k,则将最后k层AC系数残差值全部按0解码,其余系数正常解码,并存入参数矩阵;若解码出flag值为0,则解出DC系数值与全部AC系数残差值,并存入参数矩阵。The operation flow chart at the decoding end is shown in Figure 17. The decoding end reads the bit stream and first decodes the zero flag flag at the end of the bit stream. If the decoded flag value is k, the last k layers of AC coefficient residual values are all decoded as 0, and the remaining coefficients are decoded normally and stored in the parameter matrix; if the decoded flag value is 0, the DC coefficient value and all AC coefficient residual values are solved and stored in the parameter matrix.
随后将所有解码系数进行反量化,解码的过程依旧从上往下进行,首先拿到根节点的DC系数值与第一层的AC系数残差值,进行RAHT逆变换得到重建属性值;如果配置允许帧内预测或帧间预测,则先将拿到的第一层AC残差与预测AC系数相加,得到重建AC系数,将所得到的重建AC系数与根节点的DC系数一起进行RAHT逆变换得到第一层的重建属性值。所得到的8个重建属性值可以用于计算第二层8个节点的DC系数值,然后根据解码出的第二层AC残差与预测AC系数相加,得到重建AC系数,将所得到的DC系数值分别与第二层的重建AC系数进行RAHT逆变换,可以得到第三层的重建属性值,依次类推。如果标志位flag的值为k,当解码到最后k层时,AC系数残差值全部按照0恢复,此时只需要往下传递上一层计算得到的DC系数值,用上一层传递的DC系数值加上所得到的重建AC系数来计算子节点的重建属性值,直到叶子结点,至此解码过程结束。Then all decoded coefficients are dequantized, and the decoding process is still carried out from top to bottom. First, the DC coefficient value of the root node and the residual value of the AC coefficient of the first layer are obtained, and the RAHT inverse transform is performed to obtain the reconstructed attribute value; if the configuration allows intra-frame prediction or inter-frame prediction, the first-layer AC residual obtained is first added to the predicted AC coefficient to obtain the reconstructed AC coefficient, and the obtained reconstructed AC coefficient is subjected to the RAHT inverse transform together with the DC coefficient of the root node to obtain the reconstructed attribute value of the first layer. The 8 reconstructed attribute values obtained can be used to calculate the DC coefficient values of the 8 nodes of the second layer, and then the decoded second-layer AC residual is added to the predicted AC coefficient to obtain the reconstructed AC coefficient. The obtained DC coefficient value is subjected to the RAHT inverse transform with the reconstructed AC coefficient of the second layer respectively, and the reconstructed attribute value of the third layer can be obtained, and so on. If the flag value is k, when decoding to the last k layers, the AC coefficient residual values are all restored to 0. At this time, it is only necessary to pass the DC coefficient value calculated by the previous layer downward, and use the DC coefficient value passed by the previous layer plus the obtained reconstructed AC coefficient to calculate the reconstructed attribute value of the child node until the leaf node, at which point the decoding process ends.
在本申请的案例中,解码端的程序具体实现如下所示,首先在属性参数集APS中解码出标志
位.skip_raht_enabled_flag,此标志位决定本申请实施例的技术方案是否开启;若为true则先在属性码流中解出码流中的标志位flag,并将其传输到RAHT子函数中,如果解码的flag值为k,则RAHT的最后k层AC系数残差值按照0值恢复,以进行下一步属性重建;若解码的flag值为0,则RAHT的所有AC系数残差值按原始编码值恢复。在这里,属性AC系数残差存放在参数矩阵transformPredBuf中。
In the case of this application, the specific implementation of the decoding end program is as follows: first, the flag is decoded in the attribute parameter set APS .skip_raht_enabled_flag, this flag determines whether the technical solution of the embodiment of the present application is enabled; if it is true, the flag flag in the code stream is first decoded in the attribute code stream and transmitted to the RAHT sub-function. If the decoded flag value is k, the last k layers of RAHT AC coefficient residual values are restored according to the value of 0 for the next attribute reconstruction; if the decoded flag value is 0, all AC coefficient residual values of RAHT are restored according to the original coding value. Here, the attribute AC coefficient residual is stored in the parameter matrix transformPredBuf.
还需要说明的是,在本申请实施例中,对于本技术方案中对点云属性RAHT变换的最后几层系数是否编码的RDO判断方案,可以代替相原先全部编码方案。It should also be noted that in the embodiment of the present application, the RDO judgment scheme for whether to encode the last few layers of coefficients of the RAHT transformation of the point cloud attributes in the technical solution can replace the original entire encoding scheme.
还需要说明的是,在本申请实施例中,对于本技术方案中的标志位flag,可以在稠密点云颜色属性中,扩展到三通道同时使用面向RAHT变换系数的跳跃编码模式,同时设置3个标志位flag_Y、flag_U、flag_V分别记录不编码的系数层数。It should also be noted that in the embodiment of the present application, for the flag bit flag in the technical solution, it can be expanded to three channels in the dense point cloud color attributes and use the skip coding mode for RAHT transform coefficients at the same time, and set three flag bits flag_Y, flag_U, and flag_V to respectively record the number of coefficient layers that are not encoded.
示例性地,本申请实施例提出的技术方案在G-PCC参考软件TMC13V23.0与GES-TM V2.0上实现后,在CTC-C1、CTC-C2测试条件下进行了测试,测试结果详见表1~表4。其中,表1为一种在C1条件下的测试结果,表2为一种在C2条件下的测试结果,表3为另一种在C1条件下的测试结果,表4为另一种在C2条件下的测试结果。其中,C1条件为几何无损、属性无损编码方式(lossless geometry,lossless attribute),C2条件为几何无损、属性有损编码方式(lossless geometry,lossy attribute)。表1~表4中End-to-End BD-AttrRate表示端到端属性值针对属性码流的BD-Rate。BD-Rate反映的是两种情况下(有无滤波)PSNR曲线的差异,BD-Rate减少时,表示在PSNR相等的情况下,码率减少,性能提高;反之性能下降。即BD-Rate下降越多则压缩效果越好。Cat3-frame average代表多帧雷达点云数据集测试效果的平均值,Cat3-fused average数据集代表融合点云数据集,Cat2数据集为多帧稠密点云。最后Overall average为所有序列测试效果的平均值。Exemplarily, the technical solution proposed in the embodiment of the present application was implemented on the G-PCC reference software TMC13V23.0 and GES-TM V2.0, and then tested under the CTC-C1 and CTC-C2 test conditions. The test results are detailed in Tables 1 to 4. Among them, Table 1 is a test result under the C1 condition, Table 2 is a test result under the C2 condition, Table 3 is another test result under the C1 condition, and Table 4 is another test result under the C2 condition. Among them, the C1 condition is a lossless geometry, lossless attribute coding method (lossless geometry, lossy attribute), and the C2 condition is a lossless geometry, lossy attribute coding method (lossless geometry, lossy attribute). End-to-End BD-AttrRate in Tables 1 to 4 represents the BD-Rate of the end-to-end attribute value for the attribute bitstream. BD-Rate reflects the difference in PSNR curves between the two cases (with or without filtering). When BD-Rate decreases, it means that when PSNR is equal, the bit rate decreases and the performance improves; otherwise, the performance decreases. That is, the more BD-Rate decreases, the better the compression effect. Cat3-frame average represents the average value of the test results of multi-frame radar point cloud datasets, Cat3-fused average dataset represents the fused point cloud dataset, and Cat2 dataset is a multi-frame dense point cloud. Finally, Overall average is the average value of the test results of all sequences.
表1
Table 1
表2
Table 2
表3
Table 3
表4
Table 4
与相关技术相比,本技术方案在TMC13、CTC-C1测试条件下Cat3-frame average数据集Reflectance分量上获得了-1.3%的增益,CTC-C2测试条件下Cat3-frame average数据集Reflectance分量上获得了-2.6%的增益,Cat3-fused average数据集Luma、Chroma Cb、Chroma Cr分量上分别获得了0.6%、-6.8%、-7.0%的增益。与相关技术相比,本技术方案在GES-TM、CTC-C1测试条件下Cat2数据集Luma、Chroma Cb、Chroma Cr分量上分别获得了0.2%、-0.5%、-0.2%的增益,CTC-C2测试条件下Cat2数据集Luma、Chroma Cb、Chroma Cr分量上分别获得了0.8%、-1.8%、-0.5%的增益。Compared with the related art, the present technical scheme obtains a gain of -1.3% on the Reflectance component of the Cat3-frame average data set under TMC13 and CTC-C1 test conditions, a gain of -2.6% on the Reflectance component of the Cat3-frame average data set under CTC-C2 test conditions, and a gain of 0.6%, -6.8%, and -7.0% on the Luma, Chroma Cb, and Chroma Cr components of the Cat3-fused average data set, respectively. Compared with the related art, the present technical scheme obtains a gain of 0.2%, -0.5%, and -0.2% on the Luma, Chroma Cb, and Chroma Cr components of the Cat2 data set under GES-TM and CTC-C1 test conditions, and a gain of 0.8%, -1.8%, and -0.5% on the Luma, Chroma Cb, and Chroma Cr components of the Cat2 data set under CTC-C2 test conditions, respectively.
在本申请实施例中,通过上述实施例对前述实施例的具体实现进行了详细阐述,从中可以看出,根据前述实施例的技术方案,这里提出了一种面向RAHT变换系数的跳跃编码模式,通过率失真优化技术,判断点云在RAHT变换中多0值的后几层编码的率失真代价,将编码率失真代价高的点云后几层AC系数不编码,同时编码flag标志位来记录不编码操作是否执行、对几层执行,有效改善了RAHT算法中后几层编码系数0值过多的现象,提高了编码效率,并实现了解码端重建点云平均码率下的质量增强,能够提高属性编码平均码率下的重建质量,进而提升了编解码效率。In the embodiments of the present application, the specific implementation of the aforementioned embodiments is elaborated in detail through the above embodiments. It can be seen that, according to the technical scheme of the aforementioned embodiments, a skip coding mode for RAHT transform coefficients is proposed here. Through the rate-distortion optimization technology, the rate-distortion cost of encoding the latter layers of the point cloud with more 0 values in the RAHT transform is determined, and the AC coefficients of the latter layers of the point cloud with high rate-distortion cost are not encoded. At the same time, the flag bit is encoded to record whether the non-encoding operation is performed and for which layers it is performed. This effectively improves the phenomenon of too many 0 values in the encoding coefficients of the latter layers in the RAHT algorithm, improves the encoding efficiency, and realizes quality enhancement at the average bit rate of the reconstructed point cloud at the decoding end, which can improve the reconstruction quality at the average bit rate of the attribute encoding, thereby improving the encoding and decoding efficiency.
在本申请的再一实施例中,基于前述实施例相同的发明构思,图25为本申请实施例提供的一种编码器的组成结构示意图。如图25所示,该编码器250可以包括第一确定单元2501和编码单元2502,其中:In another embodiment of the present application, based on the same inventive concept as the above-mentioned embodiment, FIG25 is a schematic diagram of the composition structure of an encoder provided in an embodiment of the present application. As shown in FIG25, the encoder 250 may include a first determining unit 2501 and an encoding unit 2502, wherein:
第一确定单元2501,配置为确定第一编码参数的取值;在第一编码参数指示对当前点云的k个变换层进行跳跃编码时,确定k个变换层的一个或多个交流系数残差值为预设数值;其中,k为大于零的整数;The first determining unit 2501 is configured to determine a value of a first coding parameter; when the first coding parameter indicates that k transformation layers of the current point cloud are skip-coded, determine that one or more AC coefficient residual values of the k transformation layers are preset values; wherein k is an integer greater than zero;
编码单元2502,配置为对k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,将所得到的编码比特写入码流。The encoding unit 2502 is configured to encode one or more AC coefficient residual values of k transformation layers according to preset values, and write the obtained encoding bits into the bit stream.
在一些实施例中,第一确定单元2501,还配置为确定对k个变换层的全部交流系数残差值进行编码的第一代价值,以及确定对k个变换层的一个或多个交流系数残差值按照预设数值进行编码的第二代 价值;根据第一代价值和第二代价值,确定第一编码参数的取值。In some embodiments, the first determining unit 2501 is further configured to determine a first generation value for encoding all the AC coefficient residual values of the k transform layers, and to determine a second generation value for encoding one or more AC coefficient residual values of the k transform layers according to a preset value. value; determine the value of the first encoding parameter according to the first generation value and the second generation value.
在一些实施例中,第一确定单元2501,还配置为若第一代价值大于第二代价值,则确定第一编码参数的取值为第一值;若第一代价值小于第二代价值,则确定第一编码参数的取值为第二值。In some embodiments, the first determination unit 2501 is further configured to determine the value of the first encoding parameter to be the first value if the first generation value is greater than the second generation value; and to determine the value of the first encoding parameter to be the second value if the first generation value is less than the second generation value.
在一些实施例中,第一确定单元2501,还配置为若第一编码参数的取值为第一值,则确定第一编码参数指示对当前点云的k个变换层进行跳跃编码;若第一编码参数的取值为第二值,则确定第一编码参数指示对当前点云的k个变换层不进行跳跃编码。In some embodiments, the first determination unit 2501 is further configured to, if the value of the first encoding parameter is a first value, determine that the first encoding parameter indicates that the k transformation layers of the current point cloud are skip encoded; if the value of the first encoding parameter is a second value, determine that the first encoding parameter indicates that the k transformation layers of the current point cloud are not skip encoded.
在一些实施例中,编码单元2502,还配置为对第一编码参数的取值进行编码处理,将所得到的编码比特写入码流。In some embodiments, the encoding unit 2502 is further configured to perform encoding processing on the value of the first encoding parameter and write the obtained encoding bits into the bit stream.
在一些实施例中,编码单元2502,还配置为对第一编码参数的取值进行编码处理,将所得到的编码比特写入码流中的属性码流单元。In some embodiments, the encoding unit 2502 is further configured to perform encoding processing on the value of the first encoding parameter, and write the obtained encoding bits into the attribute code stream unit in the code stream.
在一些实施例中,第一确定单元2501,还配置为在第一编码参数指示对当前点云的k个变换层进行跳跃编码时,将第一值设置为等于k的取值。In some embodiments, the first determination unit 2501 is further configured to set the first value equal to the value of k when the first encoding parameter indicates that k transform layers of the current point cloud are to be skip encoded.
在一些实施例中,第一确定单元2501,还配置为确定对m个变换层的全部交流系数残差值进行编码的第三代价值,以及确定对m个变换层的一个或多个交流系数残差值按照预设数值进行编码的第四代价值;在第三代价值大于第四代价值时,确定当前点云的i个变换层按照预设数值进行编码的第五代价值,其中,i=1,2,…,m,m为大于零的整数;以及在得到m个第五代价值之后,从m个第五代价值中确定最小代价值;根据最小代价值对应的i的取值,确定k的取值。In some embodiments, the first determination unit 2501 is further configured to determine a third generation value for encoding all AC coefficient residual values of m transformation layers, and to determine a fourth generation value for encoding one or more AC coefficient residual values of m transformation layers according to a preset value; when the third generation value is greater than the fourth generation value, determine a fifth generation value for encoding i transformation layers of the current point cloud according to a preset value, where i = 1, 2, ..., m, and m is an integer greater than zero; and after obtaining m fifth generation values, determine a minimum cost value from the m fifth generation values; and determine the value of k based on the value of i corresponding to the minimum cost value.
在一些实施例中,第一确定单元2501,还配置为确定k个变换层的全部交流系数残差值为预设数值。In some embodiments, the first determination unit 2501 is further configured to determine that all AC coefficient residual values of k transformation layers are preset values.
在一些实施例中,参见图25,该编码器250还可以包括第一划分单元2503,配置为对当前点云中的点进行层划分,确定当前点云对应的多个变换层以及当前点云的根节点;其中,多个变换层包括k个变换层和其他变换层。In some embodiments, referring to FIG. 25 , the encoder 250 may further include a first division unit 2503 configured to perform layer division on points in the current point cloud, determine multiple transformation layers corresponding to the current point cloud and a root node of the current point cloud; wherein the multiple transformation layers include k transformation layers and other transformation layers.
在一些实施例中,第一确定单元2501,还配置为将k个变换层设置为多个变换层中从根节点自上向下的最后k个变换层。In some embodiments, the first determining unit 2501 is further configured to set the k transformation layers as the last k transformation layers from the root node in a downward direction among the multiple transformation layers.
在一些实施例中,参见图25,该编码器250还可以包括第一变换单元2504,,配置为确定多个变换层中的点的属性初始值;以及对多个变换层中的点的属性初始值进行区域自适应分层变换,确定多个变换层中的点的交流系数初始值以及根节点的直流系数值。In some embodiments, referring to FIG. 25 , the encoder 250 may further include a first transformation unit 2504, configured to determine initial attribute values of points in a plurality of transformation layers; and perform regional adaptive hierarchical transformation on the initial attribute values of the points in the plurality of transformation layers to determine initial AC coefficient values of the points in the plurality of transformation layers and DC coefficient values of the root nodes.
在一些实施例中,第一确定单元2501,还配置为确定多个变换层中的点的交流系数预测值;以及根据多个变换层中的点的交流系数初始值和多个变换层中的点的交流系数预测值,确定多个变换层的交流系数残差值。In some embodiments, the first determination unit 2501 is also configured to determine the AC coefficient prediction values of points in multiple transformation layers; and determine the AC coefficient residual values of multiple transformation layers based on the AC coefficient initial values of points in multiple transformation layers and the AC coefficient prediction values of points in multiple transformation layers.
在一些实施例中,第一确定单元2501,还配置为对多个变换层中的点的交流系数初始值和多个变换层中的点的交流系数预测值进行减法运算,得到多个变换层中的点的交流系数预测残差;以及对多个变换层中的点的交流系数预测残差进行量化处理,得到多个变换层的交流系数残差值。In some embodiments, the first determination unit 2501 is also configured to perform a subtraction operation on the initial values of the AC coefficients of points in multiple transformation layers and the predicted values of the AC coefficients of points in multiple transformation layers to obtain the AC coefficient prediction residuals of the points in multiple transformation layers; and to quantize the AC coefficient prediction residuals of the points in multiple transformation layers to obtain the AC coefficient residual values of multiple transformation layers.
在一些实施例中,第一确定单元2501,还配置为在第一编码参数指示对当前点云的k个变换层进行跳跃编码时,确定多个变换层中k个变换层之外其他变换层的交流系数残差值;编码单元2502,还配置为对其他变换层的交流系数残差值进行编码处理,将所得到的编码比特写入码流。In some embodiments, the first determination unit 2501 is further configured to determine the residual values of the AC coefficients of other transformation layers other than k transformation layers among multiple transformation layers when the first encoding parameter indicates that the k transformation layers of the current point cloud are to be skip encoded; the encoding unit 2502 is further configured to encode the residual values of the AC coefficients of other transformation layers and write the obtained encoding bits into the bitstream.
在一些实施例中,编码单元2502,还配置为对其他变换层的交流系数残差值进行编码处理,将所得到的编码比特写入码流中的属性码流单元。In some embodiments, the encoding unit 2502 is further configured to perform encoding processing on the AC coefficient residual values of other transform layers, and write the obtained encoding bits into the attribute code stream unit in the code stream.
在一些实施例中,编码单元2502,还配置为在第一编码参数指示对当前点云的k个变换层不进行跳跃编码时,对多个变换层的交流系数残差值进行编码处理,将所得到的编码比特写入码流。In some embodiments, the encoding unit 2502 is further configured to encode the residual values of the AC coefficients of multiple transform layers when the first encoding parameter indicates that the k transform layers of the current point cloud are not to be skip-encoded, and write the obtained encoding bits into the bitstream.
在一些实施例中,编码单元2502,还配置为对多个变换层的交流系数残差值进行编码处理,将所得到的编码比特写入码流中的属性码流单元。In some embodiments, the encoding unit 2502 is further configured to perform encoding processing on the AC coefficient residual values of multiple transform layers, and write the obtained encoding bits into the attribute code stream unit in the code stream.
在一些实施例中,第一确定单元2501,还配置为在属性码流单元中,确定第一编码参数对应的字段位于交流系数残差值对应的字段之后。In some embodiments, the first determining unit 2501 is further configured to determine, in the attribute code stream unit, that the field corresponding to the first coding parameter is located after the field corresponding to the AC coefficient residual value.
在一些实施例中,第一变换单元2504,还配置为确定多个变换层中的点的属性预测值;以及对多个变换层中的点的属性预测值进行区域自适应分层变换,确定多个变换层中的点的交流系数预测值。In some embodiments, the first transformation unit 2504 is further configured to determine the attribute prediction values of points in multiple transformation layers; and perform regional adaptive hierarchical transformation on the attribute prediction values of points in multiple transformation layers to determine the AC coefficient prediction values of points in multiple transformation layers.
在一些实施例中,第一确定单元2501,还配置为在当前点云允许使用帧内预测时,对多个变换层中的点进行帧内预测,确定多个变换层中的点的属性预测值;在当前点云允许使用帧间预测时,确定当前点云的参考点云,并根据参考点云对多个变换层中的点进行帧间预测,确定多个变换层中的点的属性预测值。In some embodiments, the first determination unit 2501 is further configured to perform intra-frame prediction on points in multiple transformation layers and determine attribute prediction values of the points in multiple transformation layers when the current point cloud allows the use of intra-frame prediction; when the current point cloud allows the use of inter-frame prediction, determine the reference point cloud of the current point cloud, and perform inter-frame prediction on points in multiple transformation layers based on the reference point cloud to determine the attribute prediction values of the points in multiple transformation layers.
在一些实施例中,编码单元2502,还配置为对根节点的直流系数值进行编码处理,将所得到的编码比特写入码流。 In some embodiments, the encoding unit 2502 is further configured to encode the DC coefficient value of the root node and write the obtained encoding bits into the bit stream.
在一些实施例中,第一确定单元2501,还配置为确定第二编码参数的取值;在第二编码参数指示开启当前点云的跳跃编码时,执行确定第一编码参数的取值的步骤。In some embodiments, the first determination unit 2501 is further configured to determine a value of a second encoding parameter; when the second encoding parameter indicates to start skip encoding of the current point cloud, the step of determining a value of the first encoding parameter is performed.
在一些实施例中,编码单元2502,还配置为对第二编码参数的取值进行编码处理,将所得到的编码比特写入码流。In some embodiments, the encoding unit 2502 is further configured to perform encoding processing on the value of the second encoding parameter and write the obtained encoding bits into the bit stream.
在一些实施例中,编码单元2502,还配置为对第二编码参数的取值进行编码处理,将所得到的编码比特写入码流中的属性参数集单元。In some embodiments, the encoding unit 2502 is further configured to perform encoding processing on the value of the second encoding parameter, and write the obtained encoding bits into the attribute parameter set unit in the bitstream.
在一些实施例中,第一确定单元2501,还配置为确定第三编码参数的取值;其中,第三编码参数用于指示对当前点云的k个变换层的待处理分量是否进行跳跃编码;编码单元2502,还配置为对第三编码参数的取值进行编码处理,将所得到的编码比特写入码流。In some embodiments, the first determination unit 2501 is further configured to determine the value of a third encoding parameter; wherein the third encoding parameter is used to indicate whether to perform jump encoding on the to-be-processed components of the k transformation layers of the current point cloud; the encoding unit 2502 is further configured to perform encoding processing on the value of the third encoding parameter and write the obtained encoding bits into the bitstream.
在一些实施例中,待处理分量包括第一颜色分量、第二颜色分量和第三颜色分量中的至少一项。In some embodiments, the component to be processed includes at least one of a first color component, a second color component, and a third color component.
在一些实施例中,第一确定单元2501,还配置为在对当前点云的k个变换层的待处理分量进行跳跃编码时,确定k个变换层的待处理分量的一个或多个交流系数残差值为预设数值;编码单元2502,还配置为对k个变换层的待处理分量的一个或多个交流系数残差值按照预设数值进行编码处理,将所得到的编码比特写入码流。In some embodiments, the first determination unit 2501 is further configured to determine that one or more AC coefficient residual values of the k transform layers to be processed are preset values when jump encoding is performed on the k transform layers to be processed components of the current point cloud; the encoding unit 2502 is further configured to encode one or more AC coefficient residual values of the k transform layers to be processed components according to the preset values, and write the obtained encoding bits into the bit stream.
可以理解地,在本申请实施例中,“单元”可以是部分电路、部分处理器、部分程序或软件等等,当然也可以是模块,还可以是非模块化的。而且在本实施例中的各组成部分可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。It is understandable that in the embodiments of the present application, a "unit" may be a part of a circuit, a part of a processor, a part of a program or software, etc., and of course, it may be a module, or it may be non-modular. Moreover, the components in the present embodiment may be integrated into a processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of a software functional module.
所述集成的单元如果以软件功能模块的形式实现并非作为独立的产品进行销售或使用时,可以存储在一个计算机可读取存储介质中,基于这样的理解,本实施例的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)或processor(处理器)执行本实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(Read Only Memory,ROM)、随机存取存储器(Random Access Memory,RAM)、磁碟或者光盘等各种可以存储程序代码的介质。If the integrated unit is implemented in the form of a software function module and is not sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this embodiment is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, server, or network device, etc.) or a processor to perform all or part of the steps of the method described in this embodiment. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk, etc., various media that can store program codes.
因此,本申请实施例提供了一种计算机可读存储介质,应用于编码器250,该计算机可读存储介质存储有计算机程序,所述计算机程序被第一处理器执行时实现前述实施例中任一项所述的方法。Therefore, an embodiment of the present application provides a computer-readable storage medium, which is applied to the encoder 250. The computer-readable storage medium stores a computer program, and when the computer program is executed by the first processor, the method described in any one of the aforementioned embodiments is implemented.
基于上述编码器250的组成以及计算机可读存储介质,图26为本申请实施例提供的一种编码器的具体硬件结构示意图。如图26所示,编码器250可以包括:第一通信接口2601、第一存储器2602和第一处理器2603;各个组件通过第一总线系统2604耦合在一起。可理解,第一总线系统2604用于实现这些组件之间的连接通信。第一总线系统2604除包括数据总线之外,还包括电源总线、控制总线和状态信号总线。但是为了清楚说明起见,在图26中将各种总线都标为第一总线系统2604。其中,Based on the composition of the above-mentioned encoder 250 and the computer-readable storage medium, Figure 26 is a schematic diagram of the specific hardware structure of an encoder provided in an embodiment of the present application. As shown in Figure 26, the encoder 250 may include: a first communication interface 2601, a first memory 2602 and a first processor 2603; each component is coupled together through a first bus system 2604. It can be understood that the first bus system 2604 is used to realize the connection and communication between these components. In addition to the data bus, the first bus system 2604 also includes a power bus, a control bus and a status signal bus. However, for the sake of clarity, various buses are marked as the first bus system 2604 in Figure 26. Among them,
第一通信接口2601,用于在与其他外部网元之间进行收发信息过程中,信号的接收和发送;The first communication interface 2601 is used for receiving and sending signals during the process of sending and receiving information with other external network elements;
第一存储器2602,用于存储能够在第一处理器2603上运行的计算机程序;A first memory 2602, used to store a computer program that can be run on the first processor 2603;
第一处理器2603,用于在运行所述计算机程序时,执行:The first processor 2603 is configured to, when running the computer program, execute:
确定第一编码参数的取值;在第一编码参数指示对当前点云的k个变换层进行跳跃编码时,确定k个变换层的一个或多个交流系数残差值为预设数值;其中,k为大于零的整数;对k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,将所得到的编码比特写入码流。Determine the value of the first coding parameter; when the first coding parameter indicates that k transformation layers of the current point cloud are to be skip-coded, determine that one or more AC coefficient residual values of the k transformation layers are preset values; wherein k is an integer greater than zero; encode the one or more AC coefficient residual values of the k transformation layers according to the preset values, and write the obtained coded bits into the bitstream.
可以理解,本申请实施例中的第一存储器2602可以是易失性存储器或非易失性存储器,或可包括易失性和非易失性存储器两者。其中,非易失性存储器可以是只读存储器(Read-Only Memory,ROM)、可编程只读存储器(Programmable ROM,PROM)、可擦除可编程只读存储器(Erasable PROM,EPROM)、电可擦除可编程只读存储器(Electrically EPROM,EEPROM)或闪存。易失性存储器可以是随机存取存储器(Random Access Memory,RAM),其用作外部高速缓存。通过示例性但不是限制性说明,许多形式的RAM可用,例如静态随机存取存储器(Static RAM,SRAM)、动态随机存取存储器(Dynamic RAM,DRAM)、同步动态随机存取存储器(Synchronous DRAM,SDRAM)、双倍数据速率同步动态随机存取存储器(Double Data Rate SDRAM,DDRSDRAM)、增强型同步动态随机存取存储器(Enhanced SDRAM,ESDRAM)、同步连接动态随机存取存储器(Synchlink DRAM,SLDRAM)和直接内存总线随机存取存储器(Direct Rambus RAM,DRRAM)。本申请描述的系统和方法的第一存储器2602旨在包括但不限于这些和任意其它适合类型的存储器。It can be understood that the first memory 2602 in the embodiment of the present application can be a volatile memory or a non-volatile memory, or can include both volatile and non-volatile memories. Among them, the non-volatile memory can be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory can be a random access memory (RAM), which is used as an external cache. By way of example and not limitation, many forms of RAM are available, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate synchronous DRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), and direct RAM bus RAM (DRRAM). The first memory 2602 of the systems and methods described herein is intended to include, but is not limited to, these and any other suitable types of memory.
而第一处理器2603可能是一种集成电路芯片,具有信号的处理能力。在实现过程中,上述方法的各步骤可以通过第一处理器2603中的硬件的集成逻辑电路或者软件形式的指令完成。上述的第一处理器2603可以是通用处理器、数字信号处理器(Digital Signal Processor,DSP)、专用集成电路(Application Specific Integrated Circuit,ASIC)、现成可编程门阵列(Field Programmable Gate Array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件。可以实现或者执行本申请实施例中的公开的各方法、步骤及逻辑框图。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。结合本申请实施例所公开的方法的步骤可以直接体现为硬件译码处理器执行完成,或者用译码处理器中的硬件及软件模块组合执行完成。软件模块可以位于随机存储器,闪存、只读存储器,可编程只读存储器或者电可擦写可编程存储器、寄存器等本领域成熟的存储介质中。该存储介质位于第一存储器2602,第一处理器2603读取第一存储器2602中的信息,结合其硬件完成上述方法的步骤。The first processor 2603 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by a hardware integrated logic circuit or software instructions in the first processor 2603. The first processor 2603 may be a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), or a processor. Specific Integrated Circuit, ASIC), field programmable gate array (Field Programmable Gate Array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiments of the present application can be implemented or executed. The general processor can be a microprocessor or the processor can also be any conventional processor, etc. The steps of the method disclosed in the embodiments of the present application can be directly embodied as a hardware decoding processor to be executed, or a combination of hardware and software modules in the decoding processor to be executed. The software module can be located in a mature storage medium in the field such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory or an electrically erasable programmable memory, a register, etc. The storage medium is located in the first memory 2602, and the first processor 2603 reads the information in the first memory 2602, and completes the steps of the above method in combination with its hardware.
可以理解的是,本申请描述的这些实施例可以用硬件、软件、固件、中间件、微码或其组合来实现。对于硬件实现,处理单元可以实现在一个或多个专用集成电路(Application Specific Integrated Circuits,ASIC)、数字信号处理器(Digital Signal Processing,DSP)、数字信号处理设备(DSP Device,DSPD)、可编程逻辑设备(Programmable Logic Device,PLD)、现场可编程门阵列(Field-Programmable Gate Array,FPGA)、通用处理器、控制器、微控制器、微处理器、用于执行本申请所述功能的其它电子单元或其组合中。对于软件实现,可通过执行本申请所述功能的模块(例如过程、函数等)来实现本申请所述的技术。软件代码可存储在存储器中并通过处理器执行。存储器可以在处理器中或在处理器外部实现。It is understood that the embodiments described in this application can be implemented in hardware, software, firmware, middleware, microcode or a combination thereof. For hardware implementation, the processing unit can be implemented in one or more application specific integrated circuits (Application Specific Integrated Circuits, ASIC), digital signal processors (Digital Signal Processing, DSP), digital signal processing devices (DSP Device, DSPD), programmable logic devices (Programmable Logic Device, PLD), field programmable gate arrays (Field-Programmable Gate Array, FPGA), general processors, controllers, microcontrollers, microprocessors, other electronic units for performing the functions described in this application or a combination thereof. For software implementation, the technology described in this application can be implemented by a module (such as a process, function, etc.) that performs the functions described in this application. The software code can be stored in a memory and executed by a processor. The memory can be implemented in the processor or outside the processor.
可选地,作为另一个实施例,第一处理器2603还配置为在运行所述计算机程序时,执行前述实施例中任一项所述的方法。Optionally, as another embodiment, the first processor 2603 is further configured to execute the method described in any one of the aforementioned embodiments when running the computer program.
本实施例提供了一种编码器,在确定对当前点云的k个变换层进行跳跃编码时,这时候直接将这k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,可以有效改善RAHT变换中最后几层编码AC系数值出现过多0的现象,从而提高了编解码效率,而且实现了解码端重建点云在平均码率下的质量增强,进而能够提升点云的编解码性能。The present embodiment provides an encoder, which, when determining to skip encode the k transformation layers of the current point cloud, directly encodes one or more AC coefficient residual values of the k transformation layers according to preset values, can effectively improve the phenomenon of too many zeros in the AC coefficient values of the last few layers of encoding in the RAHT transform, thereby improving the encoding and decoding efficiency, and achieving quality enhancement of the reconstructed point cloud at the decoding end at an average bit rate, thereby improving the encoding and decoding performance of the point cloud.
在本申请的再一实施例中,基于前述实施例相同的发明构思,图27为本申请实施例提供的一种解码器的组成结构示意图。如图27所示,该解码器270可以包括第二确定单元2701、解码单元2702和重建单元2703,其中:In yet another embodiment of the present application, based on the same inventive concept as the above-mentioned embodiment, FIG27 is a schematic diagram of the composition structure of a decoder provided in an embodiment of the present application. As shown in FIG27 , the decoder 270 may include a second determination unit 2701, a decoding unit 2702, and a reconstruction unit 2703, wherein:
第二确定单元2701,配置为确定第一解码参数的取值;在第一解码参数指示对当前点云的k个变换层进行跳跃解码时,确定k个变换层的一个或多个交流系数残差值为预设数值;其中,k是大于零的整数;The second determining unit 2701 is configured to determine a value of the first decoding parameter; when the first decoding parameter indicates to perform skip decoding on k transform layers of the current point cloud, determine one or more AC coefficient residual values of the k transform layers to be a preset value; wherein k is an integer greater than zero;
解码单元2702,配置为解码码流,确定当前点云中k个变换层之外其他变换层的交流系数残差值;A decoding unit 2702 is configured to decode the bit stream and determine the residual values of the AC coefficients of other transform layers other than the k transform layers in the current point cloud;
重建单元2703,配置为根据k个变换层的交流系数残差值和其他变换层的交流系数残差值,确定当前点云的重建点云。The reconstruction unit 2703 is configured to determine the reconstructed point cloud of the current point cloud according to the AC coefficient residual values of the k transformation layers and the AC coefficient residual values of other transformation layers.
在一些实施例中,解码单元2702,还配置为解码码流,确定第一解码参数的取值。In some embodiments, the decoding unit 2702 is further configured to decode the code stream and determine the value of the first decoding parameter.
在一些实施例中,解码单元2702,还配置为解码码流中的属性码流单元,确定第一解码参数的取值。In some embodiments, the decoding unit 2702 is further configured to decode an attribute code stream unit in the code stream to determine a value of the first decoding parameter.
在一些实施例中,解码单元2702,还配置为解码码流中的属性码流单元,确定其他变换层的交流系数残差值。In some embodiments, the decoding unit 2702 is further configured to decode the attribute code stream unit in the code stream to determine the residual values of the AC coefficients of other transform layers.
在一些实施例中,第二确定单元2701,还配置为在属性码流单元中,确定第一解码参数对应的字段位于交流系数残差值对应的字段之后。In some embodiments, the second determining unit 2701 is further configured to determine, in the attribute code stream unit, that the field corresponding to the first decoding parameter is located after the field corresponding to the AC coefficient residual value.
在一些实施例中,第二确定单元2701,还配置为确定第二解码参数的取值;以及在第二解码参数指示开启当前点云的跳跃解码时,执行确定第一解码参数的取值的步骤。In some embodiments, the second determination unit 2701 is further configured to determine a value of a second decoding parameter; and when the second decoding parameter indicates to start jump decoding of the current point cloud, execute the step of determining a value of the first decoding parameter.
在一些实施例中,解码单元2702,还配置为解码码流,确定第二解码参数的取值。In some embodiments, the decoding unit 2702 is further configured to decode the code stream and determine a value of the second decoding parameter.
在一些实施例中,解码单元2702,还配置为解码码流中的属性参数集单元,确定第二解码参数的取值。In some embodiments, the decoding unit 2702 is further configured to decode the attribute parameter set unit in the code stream to determine the value of the second decoding parameter.
在一些实施例中,第二确定单元2701,还配置为确定k个变换层的全部交流系数残差值为预设数值。In some embodiments, the second determination unit 2701 is further configured to determine that all AC coefficient residual values of k transformation layers are preset values.
在一些实施例中,参见图27,该解码器270还可以包括第二划分单元2704,配置为对当前点云中的点进行层划分,确定当前点云对应的多个变换层以及当前点云的根节点;其中,多个变换层包括k个变换层和其他变换层。In some embodiments, referring to FIG. 27 , the decoder 270 may further include a second division unit 2704 configured to perform layer division on points in the current point cloud, determine multiple transformation layers corresponding to the current point cloud and a root node of the current point cloud; wherein the multiple transformation layers include k transformation layers and other transformation layers.
在一些实施例中,第二确定单元2701,还配置为将k个变换层设置为多个变换层中从根节点自上向下的最后k个变换层。In some embodiments, the second determining unit 2701 is further configured to set the k transformation layers as the last k transformation layers from the root node in a downward direction among the multiple transformation layers.
在一些实施例中,解码单元2702,还配置为在第一解码参数指示对当前点云的k个变换层不进行跳跃解码时,解码码流,确定当前点云对应的多个变换层的交流系数残差值;第二确定单元2701,还配置为根据多个变换层的交流系数残差值,确定当前点云的重建点云。In some embodiments, the decoding unit 2702 is further configured to decode the code stream and determine the residual values of the AC coefficients of multiple transform layers corresponding to the current point cloud when the first decoding parameter indicates that the k transform layers of the current point cloud do not need to be skipped and decoded; the second determination unit 2701 is further configured to determine the reconstructed point cloud of the current point cloud based on the residual values of the AC coefficients of multiple transform layers.
在一些实施例中,解码单元2702,还配置为解码码流中的属性码流单元,确定多个变换层的交流 系数残差值。In some embodiments, the decoding unit 2702 is further configured to decode the attribute code stream unit in the code stream to determine the communication of multiple transformation layers. The coefficient residual values.
在一些实施例中,第二确定单元2701,还配置为若第一解码参数的取值为第一值,则确定第一解码参数指示对当前点云的k个变换层进行跳跃解码;若第一解码参数的取值为第二值,则确定第一解码参数指示对当前点云的k个变换层不进行跳跃解码。In some embodiments, the second determination unit 2701 is further configured to, if the value of the first decoding parameter is a first value, determine that the first decoding parameter indicates skip decoding of the k transform layers of the current point cloud; if the value of the first decoding parameter is a second value, determine that the first decoding parameter indicates not skip decoding of the k transform layers of the current point cloud.
在一些实施例中,第二确定单元2701,还配置为在第一解码参数指示对当前点云的k个变换层进行跳跃解码时,将k的取值设置为等于第一值。In some embodiments, the second determination unit 2701 is further configured to set the value of k to be equal to the first value when the first decoding parameter indicates to skip decoding k transform layers of the current point cloud.
在一些实施例中,解码单元2702,还配置为解码码流,确定当前点云的根节点的直流系数值;以及将根节点的直流系数值保存至当前点云的第一参数矩阵中。In some embodiments, the decoding unit 2702 is further configured to decode the code stream, determine the DC coefficient value of the root node of the current point cloud; and save the DC coefficient value of the root node to the first parameter matrix of the current point cloud.
在一些实施例中,解码单元2702,还配置为将k个变换层的交流系数残差值和其他变换层的交流系数残差值保存至当前点云的第一参数矩阵中。In some embodiments, the decoding unit 2702 is further configured to save the AC coefficient residual values of k transformation layers and the AC coefficient residual values of other transformation layers into the first parameter matrix of the current point cloud.
在一些实施例中,第二确定单元2701,还配置为对当前点云的第一参数矩阵中的参数值进行反量化处理。In some embodiments, the second determining unit 2701 is further configured to perform inverse quantization processing on the parameter values in the first parameter matrix of the current point cloud.
在一些实施例中,第二确定单元2701,还配置为确定多个变换层中的点的交流系数预测值;根据当前点云的第一参数矩阵和多个变换层中的点的交流系数预测值,确定当前点云的第二参数矩阵;重建单元2703,还配置为对当前点云的第二参数矩阵进行区域自适应分层逆变换,确定当前点云的重建点云。In some embodiments, the second determination unit 2701 is further configured to determine the predicted values of the AC coefficients of points in multiple transformation layers; determine the second parameter matrix of the current point cloud based on the first parameter matrix of the current point cloud and the predicted values of the AC coefficients of points in multiple transformation layers; the reconstruction unit 2703 is further configured to perform a regional adaptive hierarchical inverse transform on the second parameter matrix of the current point cloud to determine the reconstructed point cloud of the current point cloud.
在一些实施例中,参见图27,该解码器270还可以包括第二变换单元2705,配置为确定多个变换层中的点的属性预测值;以及对多个变换层中的点的属性预测值进行区域自适应分层变换,确定多个变换层中的点的交流系数预测值。In some embodiments, referring to FIG. 27 , the decoder 270 may further include a second transformation unit 2705 configured to determine attribute prediction values of points in multiple transformation layers; and perform regional adaptive hierarchical transformation on the attribute prediction values of points in multiple transformation layers to determine AC coefficient prediction values of points in multiple transformation layers.
在一些实施例中,第二确定单元2701,还配置为在当前点云允许使用帧内预测时,对多个变换层中的点进行帧内预测,确定多个变换层中的点的属性预测值;在当前点云允许使用帧间预测时,确定当前点云的参考点云,并根据参考点云对多个变换层中的点进行帧间预测,确定多个变换层中的点的属性预测值。In some embodiments, the second determination unit 2701 is further configured to perform intra-frame prediction on points in multiple transformation layers and determine attribute prediction values of the points in multiple transformation layers when the current point cloud allows the use of intra-frame prediction; when the current point cloud allows the use of inter-frame prediction, determine the reference point cloud of the current point cloud, and perform inter-frame prediction on points in multiple transformation layers based on the reference point cloud to determine the attribute prediction values of the points in multiple transformation layers.
在一些实施例中,第二确定单元2701,还配置为基于当前点云中的当前变换层的点,确定在第一参数矩阵中的当前变换层的点的交流系数残差值,以及确定当前变换层的点的交流系数预测值;对交流系数残差值和交流系数预测值进行加法运算,得到当前变换层的点的交流系数重建值;以及在得到多个变换层的点的交流系数重建值之后,根据根节点的直流系数值和多个变换层的点的交流系数重建值,确定当前点云的第二参数矩阵。In some embodiments, the second determination unit 2701 is further configured to determine the AC coefficient residual value of the points of the current transformation layer in the first parameter matrix and the AC coefficient prediction value of the points of the current transformation layer based on the points of the current transformation layer in the current point cloud; add the AC coefficient residual value and the AC coefficient prediction value to obtain the AC coefficient reconstruction value of the points of the current transformation layer; and after obtaining the AC coefficient reconstruction values of the points of multiple transformation layers, determine the second parameter matrix of the current point cloud according to the DC coefficient value of the root node and the AC coefficient reconstruction values of the points of multiple transformation layers.
在一些实施例中,第二重建单元2703,还配置为在当前变换层为第一变换层时,根据根节点的直流系数值和当前变换层的点的交流系数重建值进行区域自适应分层逆变换,得到第一变换层的点的重建属性值;在当前变换层为非第一变换层时,根据当前变换层的上一变换层的点的重建属性值确定当前变换层的点的直流系数值,根据当前变换层的点的直流系数值和当前变换层的点的交流系数重建值进行区域自适应分层逆变换,得到非第一变换层的点的重建属性值。In some embodiments, the second reconstruction unit 2703 is further configured to perform a regional adaptive hierarchical inverse transform based on the DC coefficient value of the root node and the AC coefficient reconstruction value of the point of the current transformation layer when the current transformation layer is the first transformation layer, so as to obtain the reconstructed attribute value of the point of the first transformation layer; when the current transformation layer is not the first transformation layer, determine the DC coefficient value of the point of the current transformation layer based on the reconstructed attribute value of the point of the previous transformation layer of the current transformation layer, and perform a regional adaptive hierarchical inverse transform based on the DC coefficient value of the point of the current transformation layer and the AC coefficient reconstruction value of the point of the current transformation layer to obtain the reconstructed attribute value of the point of the non-first transformation layer.
在一些实施例中,解码单元2702,还配置为解码码流,确定k个变换层的一个或多个交流系数残差值为预设数值。In some embodiments, the decoding unit 2702 is further configured to decode the code stream and determine that one or more AC coefficient residual values of k transform layers are preset values.
在一些实施例中,解码单元2702,还配置为解码码流,确定第三解码参数的取值;In some embodiments, the decoding unit 2702 is further configured to decode the bitstream and determine a value of a third decoding parameter;
第二确定单元2701,还配置为在第三解码参数指示对当前点云的k个变换层的待处理分量进行跳跃解码时,确定k个变换层的待处理分量的一个或多个交流系数残差值为预设数值;The second determining unit 2701 is further configured to determine one or more AC coefficient residual values of the components to be processed of the k transform layers to be processed as preset values when the third decoding parameter indicates to skip decoding the components to be processed of the k transform layers of the current point cloud;
解码单元2702,还配置为解码码流,确定当前点云中k个变换层之外其他变换层的待处理分量的交流系数残差值;The decoding unit 2702 is further configured to decode the code stream to determine the residual values of the AC coefficients of the components to be processed in other transform layers other than the k transform layers in the current point cloud;
重建单元2703,还配置为根据k个变换层的待处理分量的交流系数残差值和其他变换层的待处理分量的交流系数残差值,确定当前点云的待处理分量的重建点云。The reconstruction unit 2703 is further configured to determine the reconstructed point cloud of the to-be-processed component of the current point cloud according to the AC coefficient residual values of the to-be-processed components of the k transformation layers and the AC coefficient residual values of the to-be-processed components of other transformation layers.
在一些实施例中,待处理分量包括第一颜色分量、第二颜色分量和第三颜色分量中的至少一项。In some embodiments, the component to be processed includes at least one of a first color component, a second color component, and a third color component.
可以理解地,在本实施例中,“单元”可以是部分电路、部分处理器、部分程序或软件等等,当然也可以是模块,还可以是非模块化的。而且在本实施例中的各组成部分可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。It can be understood that in this embodiment, a "unit" can be a part of a circuit, a part of a processor, a part of a program or software, etc., and of course it can also be a module, or it can be non-modular. Moreover, the components in this embodiment can be integrated into a processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of a software functional module.
所述集成的单元如果以软件功能模块的形式实现并非作为独立的产品进行销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本实施例提供了一种计算机可读存储介质,应用于解码器270,该计算机可读存储介质存储有计算机程序,所述计算机程序被第二处理器执行时实现前述实施例中任一项所述的方法。If the integrated unit is implemented in the form of a software function module and is not sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, this embodiment provides a computer-readable storage medium, which is applied to the decoder 270, and the computer-readable storage medium stores a computer program. When the computer program is executed by the second processor, the method described in any one of the above embodiments is implemented.
基于上述解码器270的组成以及计算机可读存储介质,图28为本申请实施例提供的一种解码器的 具体硬件结构示意图。如图28所示,解码器270可以包括:第二通信接口2801、第二存储器2802和第二处理器2803;各个组件通过第二总线系统2804耦合在一起。可理解,第二总线系统2804用于实现这些组件之间的连接通信。第二总线系统2804除包括数据总线之外,还包括电源总线、控制总线和状态信号总线。但是为了清楚说明起见,在图28中将各种总线都标为第二总线系统2804。其中,Based on the composition of the above decoder 270 and the computer-readable storage medium, FIG. 28 is a decoder provided in an embodiment of the present application. Specific hardware structure diagram. As shown in Figure 28, the decoder 270 may include: a second communication interface 2801, a second memory 2802 and a second processor 2803; each component is coupled together through a second bus system 2804. It can be understood that the second bus system 2804 is used to achieve connection and communication between these components. In addition to the data bus, the second bus system 2804 also includes a power bus, a control bus and a status signal bus. However, for the sake of clarity, various buses are marked as the second bus system 2804 in Figure 28. Among them,
第二通信接口2801,用于在与其他外部网元之间进行收发信息过程中,信号的接收和发送;The second communication interface 2801 is used for receiving and sending signals during the process of sending and receiving information with other external network elements;
第二存储器2802,用于存储能够在第二处理器2803上运行的计算机程序;The second memory 2802 is used to store a computer program that can be run on the second processor 2803;
第二处理器2803,用于在运行所述计算机程序时,执行:The second processor 2803 is configured to, when running the computer program, execute:
确定第一解码参数的取值;在第一解码参数指示对当前点云的k个变换层进行跳跃解码时,确定k个变换层的一个或多个交流系数残差值为预设数值;其中,k是大于零的整数;解码码流,确定当前点云中k个变换层之外其他变换层的交流系数残差值;根据k个变换层的交流系数残差值和其他变换层的交流系数残差值,确定当前点云的重建点云。Determine the value of the first decoding parameter; when the first decoding parameter indicates to skip decoding the k transformation layers of the current point cloud, determine one or more AC coefficient residual values of the k transformation layers as preset values; wherein k is an integer greater than zero; decode the code stream to determine the AC coefficient residual values of other transformation layers other than the k transformation layers in the current point cloud; determine the reconstructed point cloud of the current point cloud based on the AC coefficient residual values of the k transformation layers and the AC coefficient residual values of other transformation layers.
可选地,作为另一个实施例,第二处理器2803还配置为在运行所述计算机程序时,执行前述实施例中任一项所述的方法。Optionally, as another embodiment, the second processor 2803 is further configured to execute any one of the methods described in the foregoing embodiments when running the computer program.
可以理解,第二存储器2802与第一存储器2602的硬件功能类似,第二处理器2803与第一处理器2603的硬件功能类似;这里不再详述。It can be understood that the hardware functions of the second memory 2802 and the first memory 2602 are similar, and the hardware functions of the second processor 2803 and the first processor 2603 are similar; they will not be described in detail here.
本实施例提供了一种解码器,在确定对当前点云的k个变换层进行跳跃编码时,这时候直接将这k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,可以有效改善RAHT变换中最后几层编码AC系数值出现过多0的现象,从而提高了编解码效率,而且实现了解码端重建点云在平均码率下的质量增强,进而能够提升点云的编解码性能。The present embodiment provides a decoder, which, when determining to skip encode the k transformation layers of the current point cloud, directly encodes one or more AC coefficient residual values of the k transformation layers according to preset values, can effectively improve the phenomenon of too many zeros in the AC coefficient values of the last few layers of encoding in the RAHT transform, thereby improving the encoding and decoding efficiency, and achieving quality enhancement of the reconstructed point cloud at the decoding end at an average bit rate, thereby improving the encoding and decoding performance of the point cloud.
在本申请的再一实施例中,图29为本申请实施例提供的一种编解码系统的组成结构示意图。如图29所示,编解码系统290可以包括编码器2901和解码器2902。In yet another embodiment of the present application, FIG29 is a schematic diagram of the composition structure of a coding and decoding system provided in an embodiment of the present application. As shown in FIG29 , the coding and decoding system 290 may include an encoder 2901 and a decoder 2902 .
在本申请实施例中,编码器2901可以是前述实施例中任一项所述的编码器,解码器2902可以是前述实施例中任一项所述的解码器。In the embodiment of the present application, the encoder 2901 may be the encoder described in any one of the aforementioned embodiments, and the decoder 2902 may be the decoder described in any one of the aforementioned embodiments.
需要说明的是,在本申请中,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者装置不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者装置所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括该要素的过程、方法、物品或者装置中还存在另外的相同要素。It should be noted that, in this application, the terms "include", "comprises" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "includes a ..." does not exclude the existence of other identical elements in the process, method, article or device including the element.
上述本申请实施例序号仅仅为了描述,不代表实施例的优劣。The serial numbers of the above-mentioned embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.
本申请所提供的几个方法实施例中所揭露的方法,在不冲突的情况下可以任意组合,得到新的方法实施例。The methods disclosed in several method embodiments provided in this application can be arbitrarily combined without conflict to obtain new method embodiments.
本申请所提供的几个产品实施例中所揭露的特征,在不冲突的情况下可以任意组合,得到新的产品实施例。The features disclosed in several product embodiments provided in this application can be arbitrarily combined without conflict to obtain new product embodiments.
本申请所提供的几个方法或设备实施例中所揭露的特征,在不冲突的情况下可以任意组合,得到新的方法实施例或设备实施例。The features disclosed in several method or device embodiments provided in this application can be arbitrarily combined without conflict to obtain new method embodiments or device embodiments.
以上所述,仅为本申请的具体实施方式,但本申请的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本申请揭露的技术范围内,可轻易想到变化或替换,都应涵盖在本申请的保护范围之内。因此,本申请的保护范围应以所述权利要求的保护范围为准。The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
本申请实施例中,在编码端,确定第一编码参数的取值;在第一编码参数指示对当前点云的k个变换层进行跳跃编码时,确定k个变换层的一个或多个交流系数残差值为预设数值;对k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,将所得到的编码比特写入码流。在解码端,确定第一解码参数的取值;在第一解码参数指示对当前点云的k个变换层进行跳跃解码时,确定k个变换层的一个或多个交流系数残差值为预设数值;解码码流,确定当前点云中k个变换层之外其他变换层的交流系数残差值;根据k个变换层的交流系数残差值和其他变换层的交流系数残差值,确定当前点云的重建点云。也就是说,无论是编码端还是解码端,在确定对当前点云的k个变换层进行跳跃编码时,这时候直接将这k个变换层的一个或多个交流系数残差值按照预设数值进行编码处理,可以有效改善RAHT变换中最后几层编码AC系数值出现过多0的现象,从而提高了编解码效率,而且实现了解码端重建点云在平均码率下的质量增强,进而能够提升点云的编解码性能。 In an embodiment of the present application, at the encoding end, the value of the first encoding parameter is determined; when the first encoding parameter indicates that the k transform layers of the current point cloud are to be skip-encoded, one or more residual values of the AC coefficients of the k transform layers are determined to be preset values; one or more residual values of the AC coefficients of the k transform layers are encoded according to the preset values, and the obtained encoded bits are written into the bitstream. At the decoding end, the value of the first decoding parameter is determined; when the first decoding parameter indicates that the k transform layers of the current point cloud are to be skip-decoded, one or more residual values of the AC coefficients of the k transform layers are determined to be preset values; the bitstream is decoded to determine the residual values of the AC coefficients of other transform layers other than the k transform layers in the current point cloud; based on the residual values of the AC coefficients of the k transform layers and the residual values of the AC coefficients of the other transform layers, the reconstructed point cloud of the current point cloud is determined. That is to say, whether it is the encoding end or the decoding end, when it is determined to skip encoding the k transformation layers of the current point cloud, one or more AC coefficient residual values of these k transformation layers are directly encoded according to the preset values. This can effectively improve the phenomenon of too many 0s in the AC coefficient values of the last few layers of encoding in the RAHT transform, thereby improving the encoding and decoding efficiency, and achieving quality enhancement of the reconstructed point cloud at the average bit rate at the decoding end, thereby improving the encoding and decoding performance of the point cloud.
Claims (60)
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| PCT/CN2023/142978 WO2025138048A1 (en) | 2023-12-28 | 2023-12-28 | Coding method, decoding method, code stream, coder, decoder and storage medium |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| PCT/CN2023/142978 WO2025138048A1 (en) | 2023-12-28 | 2023-12-28 | Coding method, decoding method, code stream, coder, decoder and storage medium |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2025138048A1 true WO2025138048A1 (en) | 2025-07-03 |
Family
ID=96216566
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2023/142978 Pending WO2025138048A1 (en) | 2023-12-28 | 2023-12-28 | Coding method, decoding method, code stream, coder, decoder and storage medium |
Country Status (1)
| Country | Link |
|---|---|
| WO (1) | WO2025138048A1 (en) |
Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20220028120A1 (en) * | 2019-04-19 | 2022-01-27 | Panasonic Intellectual Property Corporation Of America | Three-dimensional data encoding method, three-dimensional data decoding method, three-dimensional data encoding device, and three-dimensional data decoding device |
| WO2022170511A1 (en) * | 2021-02-09 | 2022-08-18 | Oppo广东移动通信有限公司 | Point cloud decoding method, decoder, and computer storage medium |
| WO2023287243A1 (en) * | 2021-07-15 | 2023-01-19 | 엘지전자 주식회사 | Point cloud data transmission device, point cloud data transmission method, point cloud data reception device, and point cloud data reception method |
| CN115885317A (en) * | 2020-06-22 | 2023-03-31 | Kddi 株式会社 | Point cloud decoding device, point cloud decoding method and program |
-
2023
- 2023-12-28 WO PCT/CN2023/142978 patent/WO2025138048A1/en active Pending
Patent Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20220028120A1 (en) * | 2019-04-19 | 2022-01-27 | Panasonic Intellectual Property Corporation Of America | Three-dimensional data encoding method, three-dimensional data decoding method, three-dimensional data encoding device, and three-dimensional data decoding device |
| CN115885317A (en) * | 2020-06-22 | 2023-03-31 | Kddi 株式会社 | Point cloud decoding device, point cloud decoding method and program |
| WO2022170511A1 (en) * | 2021-02-09 | 2022-08-18 | Oppo广东移动通信有限公司 | Point cloud decoding method, decoder, and computer storage medium |
| WO2023287243A1 (en) * | 2021-07-15 | 2023-01-19 | 엘지전자 주식회사 | Point cloud data transmission device, point cloud data transmission method, point cloud data reception device, and point cloud data reception method |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| JP2025504039A (en) | Mesh vertex displacement coding | |
| JP2025507557A (en) | Coding of motion fields in dynamic mesh compression. | |
| CN117321991A (en) | Prediction method, device and codec for point cloud attributes | |
| WO2024174086A1 (en) | Decoding method, encoding method, decoders and encoders | |
| WO2025138048A1 (en) | Coding method, decoding method, code stream, coder, decoder and storage medium | |
| WO2024159534A1 (en) | Encoding method, decoding method, bitstream, encoder, decoder and storage medium | |
| WO2024065269A1 (en) | Point cloud encoding and decoding method and apparatus, device, and storage medium | |
| WO2025076659A1 (en) | Point cloud encoding method, point cloud decoding method, code stream, encoder, decoder and storage medium | |
| WO2025076662A1 (en) | Point cloud encoding method, point cloud decoding method, code stream, encoder, decoder, and storage medium | |
| WO2025213421A1 (en) | Encoding method, decoding method, bitstream, encoder, decoder, and storage medium | |
| WO2024187380A1 (en) | Encoding method, decoding method, code stream, encoder, decoder and storage medium | |
| WO2024065406A1 (en) | Encoding and decoding methods, bit stream, encoder, decoder, and storage medium | |
| WO2024174092A1 (en) | Encoding/decoding method, code stream, encoder, decoder, and storage medium | |
| WO2025213480A1 (en) | Encoding method and apparatus, decoding method and apparatus, point cloud encoder, point cloud decoder, bit stream, device, and storage medium | |
| WO2024207235A1 (en) | Encoding/decoding method, bitstream, encoder, decoder, and storage medium | |
| WO2024103304A1 (en) | Point cloud encoding method, point cloud decoding method, encoder, decoder, code stream, and storage medium | |
| WO2025148027A1 (en) | Coding method and apparatus, decoding method and apparatus, and point cloud coder, point cloud decoder, bitstream, device and storage medium | |
| WO2025039120A1 (en) | Encoding method, decoding method, encoder, decoder, and storage medium | |
| WO2025145330A1 (en) | Point cloud coding method, point cloud decoding method, coders, decoders, code stream and storage medium | |
| WO2024216649A1 (en) | Point cloud encoding and decoding method, encoder, decoder, code stream, and storage medium | |
| WO2025039113A1 (en) | Encoding method, decoding method, code stream, encoder, decoder, and storage medium | |
| WO2025039122A1 (en) | Point cloud encoding method, point cloud decoding method, code stream, encoder, decoder, and storage medium | |
| WO2024065408A1 (en) | Coding method, decoding method, code stream, coder, decoder and storage medium | |
| WO2024148598A1 (en) | Encoding method, decoding method, encoder, decoder, and storage medium | |
| WO2024082152A1 (en) | Encoding and decoding methods and apparatuses, encoder and decoder, code stream, device, and storage medium |
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: 23962727 Country of ref document: EP Kind code of ref document: A1 |