Attribute encoding method, attribute decoding method, and electronic device

JP2026523212APending Publication Date: 2026-07-13VIVO MOBILE COMM CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
JP2025575037
Authority / Receiving Office
JP · JP
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-07-12
Filing Date
2024-07-05
Publication Date
2026-07-13

Smart Images

  • Figure 2026523212000001_ABST
    Figure 2026523212000001_ABST
Patent Text Reader

Abstract

The embodiments of this application provide an attribute encoding method, an attribute decoding method, and an electronic device, and belong to the technical field of encoding and decoding. The attribute encoding method includes the steps of: (S501) the encoding side determining K first target neighbors from a plurality of candidate neighbors based on the geometric distance and attribute distance between each of the plurality of candidate neighbors and the point to be encoded, wherein the candidate neighbors are at least a part of a plurality of encoded points, the attribute distance is determined based on the attribute information of the point to be encoded and the attribute information of the candidate neighbors, and K is a positive integer of 1 or more; (S502) the encoding side predicts the attributes of the point to be encoded based on the attribute values ​​of each first target neighbor and obtains the predicted attribute value of the point to be encoded; and (S503) the encoding side encodes the attribute residual of the point to be encoded and generates an encoded code stream corresponding to the point to be encoded, wherein the attribute residual of the point to be encoded is determined based on the predicted attribute value of the point to be encoded and the original attribute value of the point to be encoded.
Need to check novelty before this filing date? Find Prior Art

Description

[Technical Field]

[0001] (Cross-reference of related applications) This application claims priority to Chinese Patent Application No. 202310853890.X, filed in China on 12 July 2023, the entirety of which is incorporated herein by reference.

[0002] This application belongs to the technical field of encoding and decoding, and more specifically relates to an attribute encoding method, an attribute decoding method, and electronic equipment. [Background technology]

[0003] A point cloud is a collection of discrete points distributed randomly in space, representing the spatial structure and surface attributes of a three-dimensional object or scene. The point cloud encoding process involves encoding attribute information. Currently, the nearest neighbor point corresponding to the point to be encoded is determined based on the geometric information of the encoded points. Furthermore, a weighted prediction is performed on the attribute values ​​of the nearest neighbor point to obtain the predicted attribute value of the point to be encoded.

[0004] However, in a point cloud, there may be cases where the spatial distance between the point to be encoded and the predicted neighbor is relatively small, but the attribute values ​​differ significantly. If the nearest neighbor is determined based on the geometric information of the encoded point, and the attribute encoding of the point to be encoded is performed based on the attribute values ​​of the nearest neighbor, it is easier to obtain an encoded code stream with information redundancy. [Overview of the Initiative] [Problems that the invention aims to solve]

[0005] The embodiments of this application provide an attribute encoding method, an attribute decoding method, and an electronic device that can solve the technical problem of information redundancy in the encoded code stream. [Means for solving the problem]

[0006] In the first aspect, The encoding side determines K first target neighbors from a plurality of candidate neighbors based on the geometric distance and attribute distance between the point to be encoded and each of the plurality of candidate neighbors, wherein the candidate neighbors are at least a portion of the plurality of encoded points, the attribute distance is determined based on the attribute information of the point to be encoded and the attribute information of the candidate neighbors, and K is a positive integer of 1 or more. The encoding side performs the steps of predicting the attributes of the points to be encoded based on the attribute values ​​of each first target neighbor point and obtaining the predicted attribute values ​​of the points to be encoded. The encoding side provides an attribute encoding method comprising the steps of encoding the attribute residuals of the points to be encoded to generate an encoded code stream corresponding to the points to be encoded, wherein the attribute residuals of the points to be encoded are determined based on the predicted attribute values ​​of the points to be encoded and the original attribute values ​​of the points to be encoded.

[0007] In the second embodiment, The decoding side performs the steps of analyzing the acquired encoded code stream to obtain the point to be decoded and multiple decoded points, The decoding side determines K first target neighbors from the plurality of candidate neighbors based on the geometric distance and attribute distance between the point to be decoded and each of the plurality of candidate neighbors, wherein the candidate neighbors are at least a portion of the plurality of decoded points, the attribute distance is determined based on the attribute information of the point to be decoded and the attribute information of the candidate neighbors, and K is a positive integer of 1 or more. The decoding side performs the steps of predicting the attributes of the points to be decoded based on the attribute values ​​of each first target neighbor point and obtaining the predicted attribute values ​​of the points to be decoded. The decoding side provides an attribute decoding method which includes the step of determining the reconstructed attribute value of the target point based on the predicted attribute value of the target point and the attribute residual of the target point, wherein the attribute residual of the target point is obtained by analyzing the encoded code stream.

[0008] In the third aspect, A first decision module for determining K first target neighbors from a plurality of candidate neighbors based on the geometric distance and attribute distance between a point to be encoded and each of a plurality of candidate neighbors, wherein the candidate neighbors are at least a portion of the plurality of encoded points, the attribute distance is determined based on the attribute information of the point to be encoded and the attribute information of the candidate neighbors, and K is a positive integer of 1 or more. A prediction module for predicting the attributes of the points to be encoded based on the attribute values ​​of each first target neighbor point, and obtaining the predicted attribute values ​​of the points to be encoded. The present invention provides an attribute coding device, which includes a generation module for coding the attribute residuals of the points to be coded and generating an coded stream corresponding to the points to be coded, wherein the attribute residuals of the points to be coded are determined based on the predicted attribute values ​​of the points to be coded and the original attribute values ​​of the points to be coded.

[0009] In the fourth aspect, An analysis module for analyzing the acquired encoded code stream to obtain the decryption target point and multiple decrypted points, A first decision module for determining K first target neighbors from a plurality of candidate neighbors based on the geometric distance and attribute distance between the decoded point and each of the plurality of candidate neighbors, wherein the candidate neighbors are at least a portion of the plurality of decoded points, the attribute distance is determined based on the attribute information of the decoded point and the attribute information of the candidate neighbors, and K is a positive integer of 1 or more. A prediction module for predicting the attributes of the points to be decoded based on the attribute values ​​of each first target neighbor point and obtaining the predicted attribute values ​​of the points to be decoded, The present invention provides an attribute decoding device, which includes a second decision module for determining the reconstructed attribute value of the target point based on the attribute prediction value of the target point and the attribute residual of the target point, wherein the attribute residual of the target point is obtained by analyzing the encoded code stream.

[0010] The fifth embodiment provides an electronic device comprising a processor and memory, wherein the memory stores a program or command executable on the processor, and when the program or command is executed by the processor, the steps of the method according to the first embodiment or the steps of the method according to the second embodiment are realized.

[0011] The sixth aspect provides a readable storage medium in which a program or command is stored, wherein when the program or command is executed by a processor, the steps of the method described in the first aspect or the steps of the method described in the second aspect are realized.

[0012] In the seventh aspect, a chip is provided comprising a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to execute a program or command to implement the method according to the first aspect or the method according to the second aspect.

[0013] The eighth aspect provides a computer program / program product stored on a storage medium, which is executed by at least one processor to realize the steps of the method described in the first aspect or the steps of the method described in the second aspect. [Effects of the Invention]

[0014] In the embodiments of the present application, based on the geometric distance and attribute distance between the point to be encoded and each of the plurality of candidate neighboring points, K first target neighboring points are determined from the plurality of candidate neighboring points. Based on the attribute values of each first target neighboring point, the attribute of the point to be encoded is predicted to obtain the attribute prediction value of the point to be encoded, and the attribute residual of the point to be encoded is encoded to generate an encoded code stream corresponding to the point to be encoded. Compared with the related art that determines the nearest neighbor point only based on the geometric information of the encoded point, in this embodiment, by determining the nearest neighbor point based on the geometric distance and attribute distance between the point to be encoded and each candidate neighboring point, the spatial distance between the nearest neighbor point and the point to be encoded becomes relatively short, and there is also no significant difference in the attribute values. Furthermore, based on the attribute value of the nearest neighbor point, the attribute encoding of the point to be encoded is performed to obtain an encoded code stream with less information redundancy, thereby reducing the code rate of the encoded code stream.

Brief Description of Drawings

[0015] [Figure 1] It is a partial framework schematic diagram of a G-PCC point cloud encoding device. [Figure 2] It is a partial framework schematic diagram of a G-PCC point cloud decoding device. [Figure 3] It is a schematic diagram of an application scenario for updating the nearest neighbor point. [Figure 4] It is a schematic diagram of an application scenario for the azimuth distribution relationship. [Figure 5] It is a flowchart of the attribute encoding method provided in the embodiments of the present application. [Figure 6] It is an application flowchart of the attribute encoding method provided in the embodiments of the present application. [Figure 7] It is a flowchart of the attribute decoding method provided in the embodiments of the present application. [Figure 8] It is a structural diagram of the attribute encoding device provided in the embodiments of the present application. [Figure 9] It is a structural diagram of the attribute decoding device provided in the embodiments of the present application. [Figure 10] It is a structural diagram of the electronic device provided in the embodiments of the present application. [Figure 11] This is a schematic diagram of the hardware structure of the terminal provided in the embodiment of this application. [Modes for carrying out the invention]

[0016] The technical solutions in the embodiments of this application will be clearly described below with reference to the drawings of the embodiments of this application. Naturally, the embodiments described are only a part of the embodiments of this application, not all of them. All other embodiments obtained by those skilled in the art based on the embodiments of this application are all included within the scope of protection of this application.

[0017] The terms "first," "second," etc., used in this application are not intended to describe a specific order or sequence, but rather to distinguish similar objects. It should be understood that these terms may be interchangeable where appropriate so that the embodiments of this application can be carried out in an order other than those illustrated or described herein, and that the objects distinguished by "first" and "second" are generally of one type, without limiting the number of objects; for example, there may be one first object or multiple objects. Also, "or" in this application indicates at least one of the connected objects. For example, "A or B" includes three forms: form 1 which includes A but not B, form 2 which includes B but not A, and form 3 which includes both A and B. The symbol " / " generally indicates that the preceding and following related objects are in an "or" relationship.

[0018] In this application, the term "instruction" may refer to either a direct instruction (i.e., an explicit instruction) or an indirect instruction (i.e., an implicit instruction). Here, a direct instruction can be understood as the sender clearly notifying the receiver of specific information, an operation to be performed, or a desired outcome within the transmitted instruction, while an indirect instruction can be understood as the receiver determining the corresponding information or making a judgment based on the instruction transmitted by the sender, and determining the operation to be performed or the desired outcome according to the result of that judgment.

[0019] In the embodiments of this application, the attribute encoding device corresponding to the attribute encoding method and the attribute decoding device corresponding to the attribute decoding method may be terminals, and such terminals may also be called terminal devices or user equipment (UE), and may be mobile phones, tablet personal computers, laptop computers, notebook computers, personal digital assistants (PDAs), personal information terminals, netbooks, ultra-mobile personal computers (UMPCs), mobile internet devices (MIDs), augmented reality (AR), virtual reality (VR) devices, robots, wearable devices, flight vehicles, vehicle user equipment (VUEs), ship equipment, pedestrian user equipment (PUEs), smart home devices (home devices with wireless communication functions such as refrigerators, televisions, washing machines, and furniture), game consoles, personal computers (PCs), ATMs, kiosks, and other terminal-side equipment. Wearable devices include smartwatches, smart bracelets, smart headphones, smart glasses, smart jewelry (smart bracelets, smart bangles, smart rings, smart necklaces, smart anklet bangles, smart bracelets, etc.), smart wristbands, smart wear, etc. Here, in-vehicle equipment may also be called in-vehicle terminals, in-vehicle controllers, in-vehicle modules, in-vehicle components, in-vehicle chips, or in-vehicle units, etc. In the embodiments of this application, the specific type of terminal is not limited.

[0020] To facilitate understanding, some aspects of the embodiments of this application are described below.

[0021] As shown in Figure 1, current digital audio-video coding standards allow for the encoding of point cloud attribute information using a geometry-based point cloud compression (G-PCC) point cloud encoder. Specifically, the point cloud attribute information is subjected to color transformation and recoloring, and based on the reconstructed geometric information, a region-adaptive transformation based on upsampling prediction or a lifting transformation based on hierarchical structure partitioning is performed on the recolored attribute information to obtain transformation coefficients, the transformation coefficients are quantized to obtain quantization coefficients, and finally, the quantization coefficients are arithmetic-encoded to obtain the attribute bitstream.

[0022] As shown in Figure 2, current digital audio and video coding standards allow for the decoding of point cloud attribute information using a G-PCC point cloud encoder. The process by which the G-PCC point cloud encoder decodes the point cloud attribute information should be understood as the reverse of the coding process, and will not be described in detail again here.

[0023] The process of encoding the attribute information of a point cloud generally involves a lifting transformation based on the Level of Detail (LOD) structure and a predictive transformation based on the LOD structure.

[0024] In a lifting transformation based on an LOD structure, the points in the point cloud are first sorted in Morton order, and then selectively sorted in Morton order using the following method.

[0025] [Mathematics 1] Variable P i The input point cloud is represented by the variable M. i P i This is a Morton code related to the following: The geometric 3D coordinates of a point, specifically the x, y, and z dimensions, are represented by d-bit binary numbers.

[0026] [Math 2] JPEG2026523212000002.jpg21159[Number 3] Here, JPEG2026523212000003.jpg727 are binary numbers corresponding to the most significant bit (l=1) to the least significant bit (l=d) of x, y, and z, respectively. x, y, and z are sorted in Morton order from the most significant bit. The formula for calculating the Morton code for each point is as follows:

[0027] [Math 4] JPEG2026523212000004.jpg1587[Number 5] Here, JPEG2026523212000005.jpg818 represents the values ​​of M from the most significant bit (l'=1) to the least significant bit (l'=3d). After obtaining the Morton code M for each point in the point cloud, the points are sorted again in ascending order of their Morton codes.

[0028] A Level of Data (LOD) is constructed for a point cloud based on an iterative downsampling scheme. This scheme includes, but is not limited to, distance-based, sampling rate-based, and octary structure-based schemes, thereby establishing a hierarchical structure for the point cloud. In some specific examples, a sampling rate-based partitioning scheme divides a point cloud into four levels of detail. For example, to partition a point cloud into four levels of detail, sampling is performed at a rate of y times for the indexes of points obtained in order by Morton values, with one point assigned to a level of detail for every y indices, and all remaining points sampled to the lowest level LOD. For each additional level of detail, sampling is continued at a rate of y times for the remaining points in the point index that have not yet been sampled, with one point assigned to a new level of detail for every y indices, and all remaining points sampled to the level of detail LOD. This iteration continues until all points have been sampled and the highest level of detail LOD is obtained, thereby constructing the final LOD structure of the point cloud.

[0029] In one selective embodiment, lower-level points and reconstructed points within the same level can be used to predict higher-level points, and lower-level and same-level points can be used as reference points.

[0030] In another selective embodiment, the nearest neighbor of the current target to be encoded is searched from the reconstruction point in the encoded frame, and attribute prediction is performed. Specifically, the Morton code of the current target to be encoded is denoted as q, and the first point whose Morton code is greater than or equal to q is searched from the previous encoded frame according to the point index order of that frame. All points in the LOD hierarchy where that point is located are used as a reference point set, points within a certain range are searched, the geometric distance between each point and the target to be encoded is calculated, and this is compared with the distance of the nearest neighbor found within the same frame to select a final number of predicted points.

[0031] Furthermore, after determining multiple neighboring points of the point to be encoded, it is necessary to determine the azimuth distribution and make the distribution of neighboring points multi-directional, thereby improving prediction accuracy.

[0032] Specifically, two lists, List1 and List2, can be constructed. Here, List1 contains multiple nearest neighbors obtained using the G-PCC nearest neighbor search method in the related technology, and List2 contains N points that were discarded during the nearest neighbor update process. For example, when N=3, the generation process of List1 and List2 is as shown in Figure 3.

[0033] Figure 3 shows eight neighboring points N0 to N7, along with the distance between each neighboring point and the point to be encoded. Figure 3 shows that the distribution of neighboring points is not sufficiently spread when the points in List 1, for example, P1 and P2, P1 and P0, and P2 and P0 in the figure, do not all satisfy the condition that their directions are exactly opposite. Therefore, it is necessary to sequentially search whether there are neighboring points in List 2 that are exactly opposite in direction to the points in List 1, according to the order of the candidate points in List 2. If a neighboring point exists in List 2 and satisfies a specific geometric distance constraint, the search is stopped, and that point is updated as the nearest neighbor point furthest from the current point to be encoded in List 1.

[0034] If there are no points in List2 that satisfy the above conditions, and at least one pair of points in List1, such as P1 and P2, P1 and P0, or P2 and P0 in the figure, can satisfy the condition that their directions are roughly opposite, then it is not necessary to update the furthest nearest neighbor.

[0035] If no point in List2 satisfies the above conditions, and the points in List1 do not satisfy the condition that at least one pair of points have roughly opposite directions, then the system sequentially searches for a candidate point in List2 that roughly opposes the direction of the point in List1, in the order of the candidate points in List2. If such a point exists and satisfies a specific geometric distance constraint, the search is stopped, and that point is updated as the furthest nearest neighbor from the current point to be encoded in List1.

[0036] It should be understood that Figure 4 can be used to determine the azimuthal distribution relationship between points.

[0037] For example, in the application scenario shown in Figure 4, point P is the point to be encoded, and a three-dimensional coordinate system is constructed with the encoded point as the center of the coordinate axes.

[0038] Within this context, if one point is located in the region of identifier 0 and another point is located in the region of identifier 7, then the azimuthal distribution relationship between these two points is determined to be strictly opposite. If one point is located in the region of identifier 1 and another point is located in the region of identifier 6, then the azimuthal distribution relationship between these two points is determined to be strictly opposite. If one point is located in the region of identifier 2 and another point is located in the region of identifier 5, then the azimuthal distribution relationship between these two points is determined to be strictly opposite. If one point is located in the region of identifier 3 and another point is located in the region of identifier 4, then the azimuthal distribution relationship between these two points is determined to be strictly opposite.

[0039] Within that context, if one point is in the location area of ​​identifier 0 and another point is in the location area of ​​identifier 3, identifier 5, or identifier 6, the azimuth distribution relationship between these two points is determined to be roughly opposite. If one point is in the location area of ​​identifier 1 and another point is in the location area of ​​identifier 2, identifier 4, or identifier 7, the azimuth distribution relationship between these two points is determined to be roughly opposite. If one point is in the location area of ​​identifier 2 and another point is in the location area of ​​identifier 1, identifier 4, or identifier 7, the azimuth distribution relationship between these two points is determined to be roughly opposite. If one point is in the location area of ​​identifier 3 and another point is in the location area of ​​identifier 0, identifier 5, or identifier 6, the azimuth distribution relationship between these two points is determined to be roughly opposite. If one point is in the location area of ​​identifier 4 and another point is in the location area of ​​identifier 1, identifier 2, or identifier 7, the azimuth distribution relationship between these two points is determined to be roughly opposite. If one point is in the location area of ​​identifier 5 and another point is in the location area of ​​identifier 0, identifier 3, or identifier 6, the azimuthal distribution relationship between these two points is determined to be roughly opposite. If one point is in the location area of ​​identifier 6 and another point is in the location area of ​​identifier 3, identifier 5, or identifier 0, the azimuthal distribution relationship between these two points is determined to be roughly opposite. If one point is in the location area of ​​identifier 7 and another point is in the location area of ​​identifier 1, identifier 2, or identifier 4, the azimuthal distribution relationship between these two points is determined to be roughly opposite.

[0040] After determining the nearest neighbor point, the attribute information of the prediction target point can be predicted by the following formula.

[0041] [Equation 6] JPEG2026523212000006.jpg1323 Here, A i is the predicted value of the attribute of the current point, k is the number of neighboring points, and A j is the reconstructed attribute value of the neighboring point, and w j is its corresponding weight coefficient, which is usually calculated by the following formula.

[0042] [Equation 7] JPEG2026523212000007.jpg2153 Here, d ij is the distance between the neighboring point and the prediction target point, and f(d ij ) is a function related to d ij , that is, based on the distance between each neighboring point and the prediction target point, the relevance weakens as the distance increases. Therefore, a relatively large weight is reconstructed for the neighboring points with a relatively short distance to assign the attribute value.

[0043] In the prediction conversion based on the LOD structure, a rate-distortion optimization technique is introduced. That is, the predicted value corresponding to each neighboring point and the corresponding prediction mode are determined, and the rate-distortion method is used to select the prediction mode. Finally, the selected prediction mode and the quantized residual are jointly encoded into the code stream of the attribute information.

[0044] Thus, in the attribute encoding process of the G-PCC point cloud, the nearest neighbor point corresponding to the encoding target point is determined based only on the geometric information of the encoded points, and further, by performing weighted prediction on the attribute value of the nearest neighbor point, the attribute predicted value of the encoding target point is obtained. However, in the point cloud, there may be a case where the spatial distance between the encoding target point and the neighboring prediction point is relatively close, but the attribute values are significantly different. If the nearest neighbor point is determined based on the geometric information of the encoded points and the attribute encoding of the encoding target point is performed based on the attribute value of the nearest neighbor point, it is easy to obtain a coded code stream with information redundancy.

[0045] To solve the above technical problems, this application provides an attribute encoding method that can be applied to the encoding side. The attribute encoding method provided in the embodiments of this application will be described in detail below with reference to the drawings, by several embodiments and their application scenarios.

[0046] Refer to Figure 5, which is a flowchart of the attribute encoding method according to an embodiment of this application. The attribute encoding method provided in this embodiment includes the following steps S501 to S503.

[0047] In S501, the encoding side determines K first target neighbors from the plurality of candidate neighbors based on the geometric distance and attribute distance between the point to be encoded and each of the plurality of candidate neighbors.

[0048] In this step, a color transformation and recoloring process is performed on the point cloud to obtain a geometrically reconstructed point cloud after recoloring. Based on the geometric information of the point cloud, the order of the points in the point cloud can be determined according to a space-filling curve. The ordering method described above includes, but is not limited to, Morton ordering and Hilbert ordering.

[0049] A geometrically rearranged point cloud is partitioned using Line of Directions (LOD) to construct a hierarchical structure of the point cloud. Here, the partitioning method includes, but is not limited to, methods that partition the point cloud based on distance, sampling rate, and octry structure.

[0050] In one selective embodiment, lower-level points are encoded, and then higher-level points are predicted using the lower-level points and reconstructed points of the same level, with the lower-level and same-level points used as reference points to obtain candidate neighbors. In another selective embodiment, in a multi-frame sequence, prediction can be made using reconstructed points in the encoded frames, with points in highly relevant reference frames used as reference points, in which case the reference frames and the points to be encoded are in different time frames, and furthermore, points within a certain search range of the reference points are used as candidate neighbors.

[0051] Note that the above candidate neighbor points are at least a portion of the multiple encoded points.

[0052] In this step, after determining candidate neighbors, the geometric distance between the point to be encoded and each of the candidate neighbors is obtained, and the attribute distance between the point to be encoded and each of the candidate neighbors is determined. Here, the attribute distance is determined based on the attribute information of the point to be encoded and the attribute information of the candidate neighbors. Selectively, the attribute distance between the point to be encoded and the candidate neighbors can be determined based on the difference between the attribute values ​​of the point to be encoded and the attribute values ​​of the candidate neighbors.

[0053] Furthermore, based on the geometric distance and attribute distance between the point to be encoded and each candidate neighbor point, K first target neighbor points are determined from the plurality of candidate neighbor points. Here, K is a positive integer of 1 or greater. The above first target neighbor points can be understood as K candidate neighbor points that are relatively close in geometric distance from the point to be encoded and have the smallest difference in attribute values.

[0054] In S502, the encoding side predicts the attributes of the points to be encoded based on the attribute values ​​of each first target neighbor point, and obtains the predicted attribute values ​​of the points to be encoded.

[0055] In one selective embodiment, the attribute prediction value of the point to be encoded can be calculated using the following formula.

[0056] [Number 8] JPEG2026523212000008.jpg2161 Here, predAttr represents the predicted attribute value of the current target point to be coded, nearestNeighNum represents the number of nearest neighbors ultimately selected for the prediction of the target point to be coded, reconAttr[i] represents the reconstructed attribute value of the i-th nearest neighbor, and w[i] represents the weight coefficient corresponding to the i-th nearest neighbor, which may be determined based on the target distance or geometric distance between the target point to be coded and the first target neighbor, and optionally the reciprocal of the target distance between the target point to be coded and the first target neighbor.

[0057] In another selective embodiment, the rate distortion cost corresponding to each first target neighbor is calculated, and the attribute prediction of the target to be encoded is performed using the first target neighbor with the minimum rate distortion cost to obtain the attribute prediction value of the target to be encoded.

[0058] In S503, the encoding side encodes the attribute residuals of the points to be encoded to generate an encoded code stream corresponding to the points to be encoded.

[0059] It should be understood that the attribute residuals of a point to be encoded are determined based on the predicted attribute values ​​and the original attribute values ​​of the point to be encoded. Selectively, the difference between the original attribute value and the predicted attribute value of a point to be encoded can be determined as the attribute residual of that point, and then the attribute residual of the point to be encoded can be encoded to generate an encoded code stream corresponding to the point to be encoded.

[0060] In the embodiment of this application, K first target neighbors are determined from a plurality of candidate neighbors based on the geometric distance and attribute distance between the point to be encoded and each of a plurality of candidate neighbors. The attribute prediction of the point to be encoded is performed based on the attribute value of each first target neighbor to obtain the attribute prediction value of the point to be encoded. The attribute residual of the point to be encoded is encoded to generate an encoded code stream corresponding to the point to be encoded. Compared with related techniques that determine the nearest neighbor based only on the geometric information of the encoded point, in this embodiment, by determining the nearest neighbor based on the geometric distance and attribute distance between the point to be encoded and each candidate neighbor, the spatial distance between the nearest neighbor and the point to be encoded becomes relatively short, there is no large difference in attribute values, and furthermore, attribute encoding of the point to be encoded is performed based on the attribute value of the nearest neighbor to obtain an encoded code stream with less information redundancy, thereby reducing the code rate of the encoded code stream.

[0061] The step of selectively determining K first target neighbors from the plurality of candidate neighbors based on the geometric distance and attribute distance between the target point to be encoded and each of the plurality of candidate neighbors, The geometric distance between the point to be encoded and each candidate neighbor point is calculated, and the attribute distance between the point to be encoded and each candidate neighbor point is determined based on the attribute information of the point to be encoded and the attribute information of each candidate neighbor point. Based on the geometric distance and attribute distance between the point to be encoded and each candidate neighbor point, the target distance between the point to be encoded and each candidate neighbor point is determined. The process involves selecting K candidate neighbor points from the aforementioned plurality of candidate neighbor points that have the minimum corresponding target distance, and determining these K points as the first neighbor points. This includes updating the K first neighbors based on the azimuthal distribution relationship between the encoded point and each first neighbor, and obtaining the K first target neighbors.

[0062] In this embodiment, geometric information of the point to be encoded and geometric information of each candidate neighbor point can be obtained, and the geometric distance between the point to be encoded and each candidate neighbor point can be calculated based on the geometric information of the point to be encoded and each candidate neighbor point. Here, the geometric information includes geometric coordinates that may be Cartesian coordinates, spherical coordinates, or cylindrical coordinates, and the geometric distance between the point to be encoded and each candidate neighbor point may be the Euclidean distance or Manhattan distance between the point to be encoded and each candidate neighbor point.

[0063] In this embodiment, attribute information of the point to be encoded and attribute information of each candidate neighbor point are obtained, and further, the attribute distance between the point to be encoded and each candidate neighbor point is determined based on the attribute information of the point to be encoded and each candidate neighbor point. The attribute distance can represent the difference between the attribute information of the point to be encoded and the attribute information of the candidate neighbor points.

[0064] The attribute information described above includes two types: reflectance information and color information. Here, the color information should be understood to include Y component information, U component information, and V component information.

[0065] After determining the geometric distance and attribute distance between the point to be encoded and each candidate neighbor point, the target distance between the point to be encoded and each candidate neighbor point can be determined based on the geometric distance and attribute distance. Selectively, the target distance between the point to be encoded and each candidate neighbor point can be obtained by weighting and summing the geometric distance and attribute distance between the point to be encoded and each candidate neighbor point. For specific embodiments of how to determine the target distance between the point to be encoded and each candidate neighbor point, please refer to the subsequent examples.

[0066] The above target distance can represent the relationship between the attribute information of the point to be encoded and the attribute information of the candidate neighbors, and can also represent the relationship between the geometric information of the point to be encoded and the geometric information of the candidate neighbors. Therefore, K candidate neighbors with the smallest corresponding target distance among multiple candidate neighbors can be determined as K first neighbors. In other words, the geometric distance between these K first neighbors and the point to be encoded is relatively close, and the attribute information of these K first neighbors and the attribute information of the point to be encoded are not significantly different.

[0067] In this embodiment, the K first neighbors are updated based on the azimuthal distribution relationship between the point to be encoded and each first neighbor, and the updated K first target neighbors are obtained.

[0068] In this embodiment, the nearest neighbor is determined based on the geometric distance and attribute distance between the point to be encoded and each candidate neighbor, and a first target neighbor is obtained that is spatially close to the point to be encoded and whose attribute value is also close to the point to be encoded.

[0069] In another embodiment, after determining multiple candidate neighbors, the geometric distance between the point to be encoded and each candidate neighbor is calculated to determine K first neighbors, and the K first neighbors are updated based on the azimuthal distribution relationship between the point to be encoded and each first neighbor. Furthermore, the K updated first neighbors are rearranged based on the target distance between the point to be encoded and each updated first neighbor to obtain K first target neighbors.

[0070] In another embodiment, after determining multiple candidate neighbor points, the geometric distance between the point to be encoded and each candidate neighbor point is calculated to determine K first neighbor points, and the K first neighbor points are updated based on the target distance between the point to be encoded and each first neighbor point. Furthermore, K first target neighbor points are obtained based on the azimuthal distribution relationship between the point to be encoded and each updated first neighbor point.

[0071] The step of selectively determining the attribute distance between the target point to be encoded and each candidate neighbor point based on the attribute information of the target point to be encoded and the attribute information of each candidate neighbor point is: For any first candidate neighbor point among the plurality of candidate neighbor points, the attribute difference between the attribute value of the point to be encoded and the attribute value of the first candidate neighbor point is calculated, wherein the attribute value of the point to be encoded is determined based on the attribute information of the point to be encoded, the attribute value of the first candidate neighbor point is determined based on the attribute information of the first candidate neighbor point, and the attribute information of the point to be encoded and the attribute information of the first candidate neighbor point are of the same attribute type. This includes determining the product of the weight value corresponding to the first candidate neighbor point and the attribute difference as the attribute distance between the point to be encoded and the first candidate neighbor point.

[0072] In this embodiment, the attribute distance between the point to be encoded and the first candidate neighbor can be determined by the following formula.

[0073] [Number 9] JPEG2026523212000009.jpg17133[Number 10] Here, attrDis represents the attribute information of the encoded type of the encoded point, attrNeighbour represents the attribute information of the first candidate neighbor point, and these two sets of attribute information are of the same type, and dimAttr represents the number of components included in the attribute information. wAttr[i] represents a predetermined weight that the i-th component of the attribute information occupies when calculating the attribute distance.

[0074] In this embodiment, the attribute distance between the point to be encoded and the candidate neighbor points is determined based on the attribute information of the point to be encoded and the attribute information of the candidate neighbor points. Therefore, the attribute distance between the point to be encoded and the candidate neighbor points can accurately represent the difference between the attribute information of the point to be encoded and the attribute information of each candidate neighbor point.

[0075] The step of selectively determining the target distance between the target point to be encoded and each candidate neighbor point based on the geometric distance and attribute distance between the target point to be encoded and each candidate neighbor point is: This includes determining the target distance between the point to be encoded and the second candidate neighbor point as the sum of the first product corresponding to the second candidate neighbor point and the second product corresponding to the second candidate neighbor point, for any of the multiple candidate neighbor points. Here, the first product is the product of the weight value of the geometric distance corresponding to the second candidate neighbor point and the geometric distance corresponding to the second candidate neighbor point, and the second product is the product of the weight value of the attribute distance corresponding to the second candidate neighbor point and the attribute distance corresponding to the second candidate neighbor point.

[0076] In this embodiment, the target distance between the point to be encoded and the second candidate neighbor can be determined by the following formula.

[0077] [Number 11] JPEG2026523212000010.jpg9159 Here, overallDis represents the target distance, geomDis represents the geometric distance, and attrDis[i] represents the distance of the i-th encoded attribute of a different type. attrCodedNum represents the number of types of encoded attribute information, geomW represents the weight corresponding to the geometric distance, and attrW[i] represents the weight corresponding to the distance of the i-th encoded attribute of a different type.

[0078] Selectively, the weights corresponding to the i-th encoded attribute distance of a different type can be determined by the following formula.

[0079] [Number 12] JPEG2026523212000011.jpg667 Here, k and b are arbitrary real numbers, and attrQuantParam represents a given attribute quantization parameter.

[0080] In other embodiments, the target distance between the target point and candidate neighbors can also be obtained by weighting and summing the geometric distance and attribute distance between the target point and candidate neighbors.

[0081] The step of selectively updating the K first neighbors based on the azimuthal distribution relationship between the encoding target point and each first neighbor is: If the azimuthal distribution relationship between the encoding target point and any two first neighboring points is not in opposite directions, the method includes updating some of the K first neighboring points that have the furthest target distance from the encoding target point as the second target neighboring point among the N second neighboring points. Here, the N second neighbor points are a subset of the plurality of candidate neighbor points excluding the K first neighbor points, the second target neighbor point is a second neighbor point among the N second neighbor points that satisfies a predetermined condition, and N is a positive integer of 1 or more. The aforementioned predetermined conditions are: The target distance between the second neighboring point and the point to be encoded is less than or equal to a predetermined distance, The orientation between the second neighbor point and the point to be encoded is opposite to the orientation between any one first neighbor point and the point to be encoded, and the arbitrary one first neighbor point is one of the K first neighbor points excluding the first neighbor point with the furthest target distance from the point to be encoded.

[0082] In this embodiment, the azimuthal distribution relationship between the point to be encoded and any two first neighboring points is determined, and if the azimuthal distribution relationship between the point to be encoded and any two first neighboring points is not in opposite directions, K first neighboring points are updated. Here, an embodiment of how the azimuthal distribution relationship between the point to be encoded and any two first neighboring points is determined may be described by referring to the above embodiment and will not be repeated here.

[0083] A specific method for updating the K first neighbors is: The process involves selecting N neighboring points from a group of candidate neighboring points, excluding K first neighboring points, to be designated as N second neighboring points, and then selecting the second neighboring points that satisfy predetermined conditions from among these N second neighboring points as the second target neighboring points. Here, the number of second target neighboring points may be one or multiple.

[0084] The above predetermined conditions include that the target distance between the second neighbor point and the point to be encoded is less than or equal to a predetermined distance, and that the orientation between the second neighbor point and the point to be encoded is opposite to the orientation between any one first neighbor point and the point to be encoded, and that any one first neighbor point is one of the K first neighbor points excluding the first neighbor point with the furthest target distance from the point to be encoded. Selectively, the condition "the target distance between the second neighbor point and the point to be encoded is less than or equal to a predetermined distance" can be replaced with "the geometric distance between the second neighbor point and the point to be encoded is less than or equal to a predetermined distance".

[0085] For example, if the target distance between the second neighbor point and the point to be encoded is less than a predetermined distance, the orientation between the second neighbor point and the point to be encoded lies within the region where identifier 0 is located in Figure 4, the orientation between the first neighbor point and the point to be encoded lies within the region where identifier 7 is located in Figure 4, and the first neighbor point is not the first neighbor point with the furthest target distance from the point to be encoded among the K first neighbor points, then the second neighbor point is determined to be a second target neighbor point that satisfies the predetermined conditions.

[0086] Selectively, one first neighbor point among the K first neighbor points that has the farthest target distance from the point to be encoded can be updated as one second target neighbor point among the N second neighbor points, and multiple first neighbor points among the K first neighbor points that have the farthest target distance from the point to be encoded can be updated as multiple second target neighbor points among the N second neighbor points. In this embodiment, there is no particular limitation on the specific number of second target neighbor points.

[0087] In this embodiment, by updating some of the K first neighbors that have the furthest target distance from the point to be encoded as second target neighbors, the orientation distributions of the K first target neighbors obtained after the update and the point to be encoded are aligned, improving the accuracy of determining the attribute prediction value of the point to be encoded using the K first target neighbors.

[0088] Before selectively determining K first target neighbors from the plurality of candidate neighbors based on the geometric distance and attribute distance between the point to be encoded and each of the plurality of candidate neighbors, the method: A step of obtaining point cloud data including a point to be encoded, multiple encoded points, and an encoded identifier, If the attribute information of the plurality of encoded points corresponds to different attribute types, and the encoding identifier is used to indicate that attribute encoding based on attribute types is performed on the point to be encoded, the further step includes determining the geometric distance and attribute distance between the point to be encoded and each candidate neighbor point.

[0089] In this embodiment, point cloud data is obtained that includes a point to be coded, multiple coded points, and coded identifiers. Here, the coded identifier is also called an enable identifier for prediction between attribute types, and is selectively included in the sequence parameter set or the attribute parameter set of the point cloud.

[0090] When the attribute information of multiple encoded points corresponds to different attribute types, and the encoding identifier is used to indicate that attribute encoding based on the attribute type should be performed on the point to be encoded, attribute encoding of the point to be encoded is performed using the attribute encoding method provided in the embodiment of this application. That is, the steps of determining the geometric distance and attribute distance between the point to be encoded and each candidate neighbor point are performed.

[0091] In this embodiment, an encoding identifier is set, and this encoding identifier indicates that attribute encoding based on attribute type will be performed on the point to be encoded. Furthermore, if the attribute information of multiple encoded points corresponds to different attribute types, the attribute encoding of the point to be encoded is performed using the attribute encoding method provided in the embodiment of this application. That is, by introducing different types of encoded attribute information into attribute prediction, the relationship between the point to be predicted and neighboring points is evaluated, thereby improving the attribute encoding efficiency.

[0092] To better understand the technical effects resulting from the attribute encoding method provided in the embodiments of this application, please refer to Tables 1 and 2.

[0093] [Table 1]

[0094] [Table 2]

[0095] Here, the values ​​in Tables 1 and 2 are used to represent the code rate ratio between a code stream generated by attribute coding provided in the embodiments of this application and a code stream generated using related techniques, given the same peak signal-to-noise ratio. It should be understood that a lower value indicates a greater reduction in code rate.

[0096] For example, the "-6.5%" in the second row, second column of Table 1 indicates that the code stream corresponding to the Y component generated by the conversion coefficient coding provided in the embodiment of this application reduces the coding rate by 6.5% compared to the code stream corresponding to the Y component generated using the related technology.

[0097] To facilitate understanding of the overall technical solution, as shown in Figure 6, candidate neighbors corresponding to the point to be encoded are determined, and the geometric distance and attribute distance between the point to be encoded and each candidate neighbor are calculated. Furthermore, based on the above geometric distance and attribute distance, a target distance is determined between the point to be encoded and each candidate neighbor, and K first neighbors are determined based on the target distance. After scanning all candidate neighbors, the K first neighbors are updated based on the azimuthal distribution relationship between the point to be encoded and each first neighbor, and K first target neighbors are obtained. Furthermore, attribute prediction of the point to be encoded is performed using the K first target neighbors to obtain the attribute prediction value of the point to be encoded, and the attribute prediction value is encoded to obtain the encoded code stream.

[0098] In other embodiments, the relationships between different types of attribute information can be used to piecewise fit regression curves between the attribute information of the points to be coded and the attribute information of the coded points. Here, the attribute information of the points to be coded is also called the coded type, and the attribute information of the coded points is also called the coded type. Selectively, the form of the regression curve may include, but is not limited to, a linear function. Selectively, L points can be sequentially selected from the point cloud to form a point set, where L is a positive integer greater than or equal to 20. Based on the coded type and coded type of these L points, model parameters are determined. For example, a fitted line y=ax+b between multiple attributes can be obtained by fitting a line using the least squares method. Note that the line can also be fitted using methods other than the least squares method, such as gradient descent or Gauss-Newton method.

[0099] For each point to be coded, the predicted value of the coded type is calculated using the reconstructed attribute value of the coded type and the prediction model. Furthermore, the predicted residual is obtained by verifying the above predicted value against the original attribute value, and the predicted residual is coded to obtain the code stream.

[0100] The decoding side analyzes and obtains the parameters of the prediction model, then determines the predicted value corresponding to the point to be decoded based on these parameters, and obtains the reconstructed attribute value of the point to be decoded based on these predicted value and prediction residual.

[0101] In other embodiments, the relationships between different types of attribute information can be used to piecewise fit regression curves between the attribute information of the points to be encoded and the attribute information of the encoded points.

[0102] For each point to be coded, the attribute residuals of the coded type are shown based on the attribute residuals of the coded type, using the parameters of the prediction model for that point.

[0103] The decoding side analyzes and obtains the parameters of the prediction model, then determines the predicted value corresponding to the point to be decoded based on these parameters, and obtains the reconstructed attribute value of the point to be decoded based on these predicted value and prediction residual.

[0104] Refer to Figure 7, which is a flowchart of the attribute encoding method provided in the embodiment of this application. The attribute decoding method provided in this embodiment includes the following steps S701 to S704.

[0105] In S701, the decryption side analyzes the acquired encoded code stream to obtain the point to be decrypted and multiple decrypted points.

[0106] In this step, the decryption side obtains the encoded code stream and analyzes the encoded code stream to obtain the points to be decoded and multiple encoded points.

[0107] In S702, the decoding side determines K first target neighbors from the plurality of candidate neighbors based on the geometric distance and attribute distance between the decoding target point and each of the plurality of candidate neighbors.

[0108] In one selective embodiment, lower-level points and reconstructed points of the same level are used to predict higher-level points, and the lower-level and same-level points are used as reference points, thereby obtaining candidate neighbors. In another selective embodiment, predictions are made using reconstructed points in the decoded frame, points in highly relevant reference frames are used as reference points, and points within a specific search range of the reference points are further used as candidate neighbors.

[0109] The geometric distance and attribute distance between the point to be decoded and each candidate neighbor point are calculated, and then K first target neighbor points are determined from the multiple candidate neighbor points based on the geometric distance and attribute distance.

[0110] Here, candidate neighbors are part of a group of decoded points, the attribute distance is determined based on the attribute information of the point to be decoded and the attribute information of the candidate neighbors, and K is a positive integer greater than or equal to 1.

[0111] In S703, the decoding side predicts the attributes of the points to be decoded based on the attribute values ​​of each first target neighbor point and obtains the predicted attribute values ​​of the points to be decoded.

[0112] In this step, using the same method as on the encoding side, we can predict the attributes of the points to be decoded based on the attribute values ​​of each first target neighbor point and obtain the predicted attribute values ​​of the points to be decoded. This will not be explained again here.

[0113] In S704, the decoding side determines the reconstructed attribute value of the target point based on the predicted attribute value of the target point and the attribute residual of the target point.

[0114] It should be understood that the attribute residuals of the points to be decoded are obtained by analyzing the encoded code stream. Selectively, the sum of the predicted attribute values ​​of the points to be decoded and the attribute residuals of the points to be decoded can be determined as the reconstructed attribute values ​​of the points to be decoded.

[0115] Compared to related techniques that determine nearest neighbors based solely on the geometric information of decoded points, this embodiment determines nearest neighbors based on the geometric distance and attribute distance between the point to be decoded and each candidate neighbor point. This results in a relatively short spatial distance between the nearest neighbor and the point to be decoded, and there is no significant difference in attribute values. Furthermore, attribute decoding of the point to be decoded is performed based on the attribute values ​​of the nearest neighbor to complete the decoding of a code stream with less information redundancy.

[0116] The step of selectively determining K first target neighbors from the plurality of candidate neighbors based on the geometric distance and attribute distance between the decoding target point and each of the plurality of candidate neighbors, The geometric distance between the decryption target point and each candidate neighbor point is calculated, and the attribute distance between the decryption target point and each candidate neighbor point is determined based on the attribute information of the decryption target point and the attribute information of each candidate neighbor point. Based on the geometric distance and attribute distance between the decoding target point and each candidate neighbor point, the target distance between the decoding target point and each candidate neighbor point is determined. The process involves selecting K candidate neighbor points from the aforementioned plurality of candidate neighbor points that have the minimum corresponding target distance, and determining these K points as the first neighbor points. This includes updating the K first neighbors based on the azimuthal distribution relationship between the decoding target point and each first neighbor, thereby obtaining the K first target neighbors.

[0117] In this embodiment, the Euclidean distance or Manhattan distance between the point to be decoded and the candidate neighbor points can be determined as the geometric distance between the point to be decoded and the candidate neighbor points. Attribute information of the point to be decoded and attribute information of each candidate neighbor point are obtained, and further, the attribute distance between the point to be decoded and each candidate neighbor point is determined based on the attribute information of the point to be decoded and each candidate neighbor point. Furthermore, the target distance between the point to be decoded and each candidate neighbor point is determined based on the geometric distance and the attribute distance.

[0118] In this embodiment, K candidate neighbor points from among multiple candidate neighbor points that have the minimum corresponding target distance can be determined as K first neighbor points that are relatively close in geometric distance from the point to be decoded and whose attribute information does not differ significantly from that of the point to be decoded. Furthermore, based on the azimuthal distribution relationship between the point to be decoded and each first neighbor point, the K first neighbor points are updated to obtain the updated K first target neighbor points.

[0119] The step of selectively determining the attribute distance between the target point to be decoded and each candidate neighbor point based on the attribute information of the target point to be decoded and the attribute information of each candidate neighbor point is: For any of the plurality of candidate neighbor points, the attribute difference between the attribute value of the point to be decoded and the attribute value of the first candidate neighbor point is calculated, wherein the attribute value of the point to be decoded is determined based on the attribute information of the point to be decoded, the attribute value of the first candidate neighbor point is determined based on the attribute information of the first candidate neighbor point, and the attribute information of the point to be decoded and the attribute information of the first candidate neighbor point are of the same attribute type. This includes determining the product of the weight value corresponding to the first candidate neighbor point and the attribute difference as the attribute distance between the point to be decoded and the first candidate neighbor point.

[0120] In this embodiment, the attribute distance between the point to be decoded and each candidate neighbor can be determined using a method in which the encoding side determines the attribute distance, and this will not be explained again here.

[0121] The step of selectively determining the target distance between the decoding target point and each candidate neighbor point based on the geometric distance and attribute distance between the decoding target point and each candidate neighbor point is: The method includes determining the target distance between the decoding target point and the second candidate neighbor point as the sum of the first product corresponding to the second candidate neighbor point and the second product corresponding to the second candidate neighbor point, for any of the multiple candidate neighbor points. Here, the first product is the product of the weight value of the geometric distance corresponding to the second candidate neighbor point and the geometric distance corresponding to the second candidate neighbor point, and the second product is the product of the weight value of the attribute distance corresponding to the second candidate neighbor point and the attribute distance corresponding to the second candidate neighbor point.

[0122] In this embodiment, the target distance between the point to be decoded and each candidate neighbor can be determined using a method in which the encoding side determines the target distance, and this will not be explained again here.

[0123] The step of selectively updating the K first neighbors based on the azimuthal distribution relationship between the decoding target point and each first neighbor is: If the azimuthal distribution relationship between the decoding target point and any two first neighboring points is not in opposite directions, the method includes updating some of the K first neighboring points that have the furthest target distance from the decoding target point as the second target neighboring point among the N second neighboring points. Here, the N second neighbor points are a subset of the K first neighbor points from the plurality of candidate neighbor points, the second target neighbor point is the second neighbor point among the N second neighbor points that satisfies predetermined conditions and has the smallest corresponding target distance, and N is a positive integer of 1 or more. The aforementioned predetermined conditions are: The target distance between the second neighboring point and the point to be decoded is less than or equal to a predetermined distance, The orientation between the second neighbor point and the point to be decoded is opposite to the orientation between any one first neighbor point and the point to be decoded, and the arbitrary one first neighbor point is one of the K first neighbor points excluding the first neighbor point with the furthest target distance from the point to be decoded.

[0124] In this embodiment, the orientation distribution relationship between the point to be decoded and any two first neighboring points is determined, and if the orientation distribution relationship between the point to be decoded and any two first neighboring points is not in opposite directions, the K first neighboring points are updated.

[0125] Here, the K first neighbors can be updated using a method in which the encoding side updates the K first neighbors, which will not be explained again here.

[0126] Selectively, the encoded code stream includes a decryption identifier, and before determining K first target neighbors from the plurality of candidate neighbors based on the geometric distance and attribute distance between the point to be decrypted and each of the plurality of candidate neighbors, the method If the attribute information of the plurality of decoded points corresponds to different attribute types, and the decoding identifier is used to indicate that attribute decoding based on attribute type is performed on the point to be decoded, the further step includes determining the geometric distance and attribute distance between the point to be decoded and each candidate neighbor point.

[0127] In this embodiment, when the encoded code stream transmitted from the encoding side includes an encoded identifier, the attribute information of multiple decoded points corresponds to different attribute types, and the decoded identifier is used to indicate that attribute decoding based on attribute type should be performed on the point to be decoded, attribute decoding of the point to be decoded is performed using the attribute decoding method provided in the embodiment of this application. That is, the step of determining the geometric distance and attribute distance between the point to be decoded and each candidate neighbor point is performed.

[0128] The attribute encoding method provided in the embodiments of this application may have an attribute encoding device as the implementing entity. In the embodiments of this application, the attribute encoding device provided in the embodiments of this application will be described by giving an example in which the attribute encoding device performs the attribute encoding method.

[0129] As shown in Figure 8, the embodiment of this application is A first decision module 801 for determining K first target neighbors from a plurality of candidate neighbors based on the geometric distance and attribute distance between the point to be encoded and each of a plurality of candidate neighbors, wherein the candidate neighbors are at least a portion of the plurality of encoded points, the attribute distance is determined based on the attribute information of the point to be encoded and the attribute information of the candidate neighbors, and K is a positive integer of 1 or more. A prediction module 802 for predicting the attributes of the points to be encoded based on the attribute values ​​of each first target neighbor point and obtaining the predicted attribute values ​​of the points to be encoded, Further, an attribute encoding device 800 is provided, which includes a generation module 803 for encoding the attribute residuals of the points to be encoded and generating an encoded code stream corresponding to the points to be encoded, wherein the attribute residuals of the points to be encoded are determined based on the predicted attribute values ​​of the points to be encoded and the original attribute values ​​of the points to be encoded.

[0130] Selectively, the aforementioned first decision module 801 specifically, The geometric distance between the point to be encoded and each candidate neighbor point is calculated, and the attribute distance between the point to be encoded and each candidate neighbor point is determined based on the attribute information of the point to be encoded and the attribute information of each candidate neighbor point. Based on the geometric distance and attribute distance between the point to be encoded and each candidate neighbor point, the target distance between the point to be encoded and each candidate neighbor point is determined. The process involves selecting K candidate neighbor points from the aforementioned plurality of candidate neighbor points that have the minimum corresponding target distance, and determining these K points as the first neighbor points. This is used to update the K first neighbors based on the azimuthal distribution relationship between the encoded point and each first neighbor, and to obtain the K first target neighbors.

[0131] Selectively, the aforementioned first decision module 801 more specifically, For any first candidate neighbor point among the plurality of candidate neighbor points, the attribute difference between the attribute value of the point to be encoded and the attribute value of the first candidate neighbor point is calculated, wherein the attribute value of the point to be encoded is determined based on the attribute information of the point to be encoded, the attribute value of the first candidate neighbor point is determined based on the attribute information of the first candidate neighbor point, and the attribute information of the point to be encoded and the attribute information of the first candidate neighbor point are of the same attribute type. The product of the weight value corresponding to the first candidate neighbor point and the attribute difference is used to determine the attribute distance between the point to be encoded and the first candidate neighbor point.

[0132] Selectively, the aforementioned first decision module 801 more specifically, For any of the multiple candidate neighbor points mentioned above, the sum of the first product corresponding to the second candidate neighbor point and the second product corresponding to the second candidate neighbor point is used to determine the target distance between the point to be encoded and the second candidate neighbor point. Here, the first product is the product of the weight value of the geometric distance corresponding to the second candidate neighbor point and the geometric distance corresponding to the second candidate neighbor point, and the second product is the product of the weight value of the attribute distance corresponding to the second candidate neighbor point and the attribute distance corresponding to the second candidate neighbor point.

[0133] Selectively, the aforementioned first decision module 801 more specifically, If the azimuthal distribution relationship between the encoding target point and any two first neighboring points is not in opposite directions, some of the K first neighboring points that have the furthest target distance from the encoding target point are used to update the second target neighboring points among the N second neighboring points. Here, the N second neighbor points are a subset of the plurality of candidate neighbor points excluding the K first neighbor points, the second target neighbor point is a second neighbor point among the N second neighbor points that satisfies a predetermined condition, and N is a positive integer of 1 or more. The aforementioned predetermined conditions are: The target distance between the second neighboring point and the point to be encoded is less than or equal to a predetermined distance, The orientation between the second neighbor point and the point to be encoded is opposite to the orientation between any one first neighbor point and the point to be encoded, and the arbitrary one first neighbor point is one of the K first neighbor points excluding the first neighbor point with the furthest target distance from the point to be encoded.

[0134] Selectively, the attribute encoding device 800, An acquisition module for obtaining point cloud data including the point to be encoded, multiple encoded points, and an encoded identifier, If the attribute information of the plurality of coded points corresponds to different attribute types, and the coding identifier is used to indicate that attribute coding based on attribute types is performed on the point to be coded, then the system further includes a second decision module for determining the geometric distance and attribute distance between the point to be coded and each candidate neighbor point.

[0135] Compared to related techniques that determine nearest neighbors based solely on the geometric information of encoded points, this embodiment determines nearest neighbors based on the geometric distance and attribute distance between the point to be encoded and each candidate neighbor. This results in a relatively short spatial distance between the nearest neighbor and the point to be encoded, and there is no significant difference in attribute values. Furthermore, attribute encoding of the point to be encoded is performed based on the attribute values ​​of the nearest neighbor to obtain an encoded code stream with less information redundancy, thereby reducing the coding rate of the encoded code stream.

[0136] This embodiment of the apparatus corresponds to the embodiment of the attribute encoding method shown in Figure 5 above. Each implementation process and method related to the encoding side in the embodiment of the above method is applicable to this embodiment of the apparatus and can achieve the same technical effects.

[0137] The attribute decoding method provided in the embodiments of this application may have an attribute decoding device as the implementing entity. In the embodiments of this application, the attribute decoding device provided in the embodiments of this application will be described by giving an example in which the attribute decoding device performs the attribute decoding method.

[0138] As shown in Figure 9, an embodiment of this application is An analysis module 901 analyzes the acquired encoded code stream to obtain the points to be decoded and multiple decoded points, A first decision module 902 for determining K first target neighbors from a plurality of candidate neighbors based on the geometric distance and attribute distance between the decoded point and each of the plurality of candidate neighbors, wherein the candidate neighbors are at least a portion of the plurality of decoded points, the attribute distance is determined based on the attribute information of the decoded point and the attribute information of the candidate neighbors, and K is a positive integer of 1 or more. A prediction module 903 for predicting the attributes of the points to be decoded based on the attribute values ​​of each first target neighbor point and obtaining the predicted attribute values ​​of the points to be decoded, The attribute decoding device 900 is further provided, which includes a second determination module 904 for determining the reconstructed attribute value of the decoded target point based on the attribute prediction value of the decoded target point and the attribute residual of the decoded target point, wherein the attribute residual of the decoded target point is obtained by analyzing the encoded code stream.

[0139] Selectively, the first decision module 902 specifically, The geometric distance between the decryption target point and each candidate neighbor point is calculated, and the attribute distance between the decryption target point and each candidate neighbor point is determined based on the attribute information of the decryption target point and the attribute information of each candidate neighbor point. Based on the geometric distance and attribute distance between the decoding target point and each candidate neighbor point, the target distance between the decoding target point and each candidate neighbor point is determined. The process involves selecting K candidate neighbor points from the aforementioned plurality of candidate neighbor points that have the minimum corresponding target distance, and determining these K points as the first neighbor points. This is used to update the K first neighbors based on the azimuthal distribution relationship between the decoding target point and each first neighbor, and to obtain the K first target neighbors.

[0140] Selectively, the first decision module 902 more specifically, For any of the plurality of candidate neighbor points, the attribute difference between the attribute value of the point to be decoded and the attribute value of the first candidate neighbor point is calculated, wherein the attribute value of the point to be decoded is determined based on the attribute information of the point to be decoded, the attribute value of the first candidate neighbor point is determined based on the attribute information of the first candidate neighbor point, and the attribute information of the point to be decoded and the attribute information of the first candidate neighbor point are of the same attribute type. The product of the weight value corresponding to the first candidate neighbor point and the attribute difference is used to determine the attribute distance between the point to be decoded and the first candidate neighbor point.

[0141] Selectively, the first decision module 902 more specifically, For any of the aforementioned multiple candidate neighbor points, the sum of the first product corresponding to the second candidate neighbor point and the second product corresponding to the second candidate neighbor point is used to determine the target distance between the point to be decoded and the second candidate neighbor point. Here, the first product is the product of the weight value of the geometric distance corresponding to the second candidate neighbor point and the geometric distance corresponding to the second candidate neighbor point, and the second product is the product of the weight value of the attribute distance corresponding to the second candidate neighbor point and the attribute distance corresponding to the second candidate neighbor point.

[0142] Selectively, the first decision module 902 more specifically, If the azimuthal distribution relationship between the decoding target point and any two first neighboring points is not in opposite directions, some of the K first neighboring points that have the furthest target distance from the decoding target point are used to update the N second neighboring points as second target neighboring points. Here, the N second neighbor points are a subset of the K first neighbor points from the plurality of candidate neighbor points, the second target neighbor point is the second neighbor point among the N second neighbor points that satisfies predetermined conditions and has the smallest corresponding target distance, and N is a positive integer of 1 or more. The aforementioned predetermined conditions are: The target distance between the second neighboring point and the point to be decoded is less than or equal to a predetermined distance, The orientation between the second neighbor point and the point to be decoded is opposite to the orientation between any one first neighbor point and the point to be decoded, and the arbitrary one first neighbor point is one of the K first neighbor points excluding the first neighbor point with the furthest target distance from the point to be decoded.

[0143] Selectively, the attribute decoding device 900, If the attribute information of the plurality of decoded points corresponds to different attribute types, and the decoding identifier is used to indicate that attribute decoding based on attribute type is performed on the point to be decoded, then the system further includes a third decision module for determining the geometric distance and attribute distance between the point to be decoded and each candidate neighbor point.

[0144] Compared to related techniques that determine nearest neighbors based solely on the geometric information of decoded points, this embodiment determines nearest neighbors based on the geometric distance and attribute distance between the point to be decoded and each candidate neighbor. This results in a relatively short spatial distance between the nearest neighbor and the point to be decoded, and there is no significant difference in attribute values. Furthermore, attribute decoding of the point to be decoded is performed based on the attribute values ​​of the nearest neighbor, completing the decoding of a code stream with less information redundancy.

[0145] The attribute decoding device provided in the embodiment of this application can implement each process realized in the embodiment of the method shown in Figure 7 and achieve the same technical effects, and a detailed explanation is omitted here to avoid repetition.

[0146] The attribute encoding device and attribute decoding device in the embodiments of this application may be electronic devices, such as electronic devices equipped with an operating system, or components within electronic devices such as integrated circuits or chips. The electronic devices may be terminals or other devices. Exemplarily, terminals may include, but are not limited to, the types of terminals listed above, and other devices may be servers, network-attached storage (NAS), etc., and are not specifically limited in the embodiments of this application.

[0147] The attribute encoding device provided in the embodiment of this application can implement each process realized in the embodiment of the method shown in Figure 5 and achieve the same technical effects, and a detailed explanation is omitted here to avoid repetition.

[0148] The attribute decoding device provided in the embodiment of this application can implement each process realized in the embodiment of the method shown in Figure 7 and achieve the same technical effects, and a detailed explanation is omitted here to avoid repetition.

[0149] Selectively, as shown in Figure 10, embodiments of the present application further provide an electronic device 1000 comprising a processor 1001 and a memory 1002, the memory 1002 storing a program or command executable on the processor 1001. For example, if the electronic device 1000 is a terminal, when the program or command is executed by the processor 1001, each step in the embodiment of the attribute encoding method is realized, or each step in the embodiment of the attribute decoding method is realized, and the same technical effects can be achieved.

[0150] Embodiments of this application further provide a terminal comprising a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to execute a program or command to realize the steps in the embodiment of the method shown in Figure 5, or the steps in the embodiment of the method shown in Figure 7. Embodiments of this terminal correspond to embodiments of the terminal-side method described above, and each implementation process and implementation method in embodiments of the method described above are applicable to embodiments of this terminal and can achieve the same technical effects. Specifically, Figure 11 is a schematic diagram of the hardware structure of a terminal realizing embodiments of this application.

[0151] The terminal 1100 includes, but is not limited to, components such as a high-frequency unit 1101, a network module 1102, an audio output unit 1103, an input unit 1104, a sensor 1105, a display unit 1106, a user input unit 1107, an interface unit 1108, a memory 1109, and a processor 1110.

[0152] As those skilled in the art will understand, the terminal 1100 may further include a power supply (e.g., a battery) to power each component, and the power supply is logically connected to the processor 1110 by a power management system, and the power management system can further implement functions such as charge / discharge management and power consumption management. The terminal structure shown in Figure 11 is not limiting to the terminal, and the terminal may include more or fewer components than shown, or combinations of some components, or different component arrangements, and a detailed explanation is omitted here.

[0153] In the embodiments of this application, it should be understood that the input unit 1104 may include a graphics processing unit (GPU) 11041 that processes still images or video image data acquired by an image capture device (e.g., a camera) in video capture mode or image capture mode, and a microphone 11042. The display unit 1106 may include a display panel 11061, which may be in the form of a liquid crystal display, organic light-emitting diodes, etc. The user input unit 1107 includes at least one of a touch panel 11071 and other input devices 11072. The touch panel 11071 is also called a touchscreen. The touch panel 11071 may include both a touch detection device and a touch controller. The other input devices 11072 may include, but are not limited to, a physical keyboard, function buttons (e.g., volume control buttons, switch buttons, etc.), a trackball, a mouse, or an operating lever, and a detailed description is omitted here.

[0154] In the embodiments of this application, the high-frequency unit 1101 can receive downlink data from network-side equipment, transmit it to the processor 1111 for processing, and transmit uplink data to network-side equipment. Typically, the high-frequency unit 1101 includes, but is not limited to, an antenna, amplifier, transmitter / receiver, coupler, low-noise amplifier, duplexer, etc.

[0155] Memory 1109 can be used to store software programs or commands and various data. Memory 1109 may mainly include a first storage area for storing programs or commands and a second storage area for storing data. Here, the first storage area can store an operating system, applications or commands necessary for at least one function (e.g., audio playback function, image playback function, etc.). Memory 1109 may also include volatile memory or non-volatile memory. Here, non-volatile memory may be read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (Erasable PROM, EPROM), electrically erasable programmable read-only memory (Electrically EPROM, EEPROM), or flash memory. The volatile memory may be Random Access Memory (RAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), Synchronous Dynamic Random Access Memory (SDRAM), Double Data Rate Synchronous Dynamic Random Access Memory (DDRSDRAM), Enhanced Synchronous Dynamic Random Access Memory (ESDRAM), Synch-link Dynamic Random Access Memory (SLDRAM), and Direct Rambus Random Access Memory (DRRAM). The memory 1109 in the embodiments of this application includes, but is not limited to, these and any other suitable types of memory.

[0156] The processor 1110 may include one or more processing units, and selectively, the processor 1110 can integrate an application processor that primarily processes the operation of an operating system, user interface, and applications, and a modem processor that primarily processes wireless communication signals, such as a baseband processor. It is understood that the above-mentioned modem processor does not necessarily have to be integrated into the processor 1110.

[0157] Here, processor 1110, An operation to determine K first target neighbors from a plurality of candidate neighbors based on the geometric distance and attribute distance between the point to be encoded and each of a plurality of candidate neighbors, wherein the candidate neighbors are at least a portion of the plurality of encoded points, the attribute distance is determined based on the attribute information of the point to be encoded and the attribute information of the candidate neighbors, and K is a positive integer of 1 or more. An operation to predict the attributes of the points to be encoded based on the attribute values ​​of each first target neighboring point, and to obtain the predicted attribute values ​​of the points to be encoded. This is used to perform an operation to encode the attribute residuals of the points to be encoded and generate an encoded code stream corresponding to the points to be encoded, wherein the attribute residuals of the points to be encoded are determined based on the predicted attribute values ​​of the points to be encoded and the original attribute values ​​of the points to be encoded.

[0158] Alternatively, the processor 1110 further, The operation involves analyzing the acquired encoded code stream to obtain the points to be decoded and multiple decoded points, An operation to determine K first target neighbors from a plurality of candidate neighbors based on the geometric distance and attribute distance between the decoded target point and each of the plurality of candidate neighbors, wherein the candidate neighbors are at least a portion of the plurality of decoded points, the attribute distance is determined based on the attribute information of the decoded target point and the attribute information of the candidate neighbors, and K is a positive integer of 1 or more. An operation to predict the attributes of the points to be decoded based on the attribute values ​​of each first target neighboring point, and to obtain the predicted attribute values ​​of the points to be decoded. This is used to perform an operation to determine the reconstructed attribute value of the target point based on the predicted attribute value of the target point and the attribute residual of the target point, wherein the attribute residual of the target point is obtained by analyzing the encoded code stream.

[0159] Embodiments of this application further provide a readable storage medium in which a program or command is stored, and when the program or command is executed by a processor, each process in the embodiment of the attribute encoding method is realized, or each process in the embodiment of the attribute decoding method is realized, and the same technical effects can be achieved. A detailed explanation is omitted here so as not to be repeated.

[0160] Here, the processor is the processor in the terminal described in the above embodiment. The readable storage medium includes, for example, a computer read-only memory ROM, a random access memory RAM, a magnetic disk, or an optical disk. In some examples, the readable storage medium may be a non-temporary readable storage medium.

[0161] Embodiments of this application further provide a chip comprising a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to execute a program or command to implement each process in the embodiment of the attribute encoding method or to implement each process in the embodiment of the attribute decoding method, and can achieve the same technical effects, and a detailed explanation is omitted here so as not to be repeated.

[0162] It should be understood that the chips referred to in the embodiments of this application may also be called system-level chips, system chips, chip systems, or system-on-a-chip, etc.

[0163] Embodiments of this application further provide a computer program / program product stored on a storage medium, and when the computer program / program product is executed by at least one processor, each process in the embodiment of the attribute encoding method is realized, or each process in the embodiment of the attribute decoding method is realized, and the same technical effects can be achieved. Detailed explanations are omitted here to avoid repetition.

[0164] In this specification, the terms “including,” “equipped with,” or any other variation thereof are intended to include non-exclusive inclusion, so that a process, method, article, or apparatus comprising a set of elements includes not only those elements but also other elements not expressly enumerated, or elements specific to such process, method, article, or apparatus. Unless otherwise specified, an element limited by the phrase “including one…” does not preclude the presence of another identical element in a process, method, article, or apparatus comprising that element. It should also be noted that the scope of the methods and apparatus in embodiments of this application is not limited to performing functions in the order illustrated or discussed, but may also include performing functions substantially simultaneously or in reverse order depending on the function. For example, the described methods may be performed in a different order than described, and various steps may be added, omitted, or combined. Furthermore, features described with reference to some examples may be combined in other examples.

[0165] From the above description of the embodiments, those skilled in the art will clearly understand that the methods of the above embodiments can be implemented in the form of a combination of a computer software product and a necessary common hardware platform. Of course, they may also be implemented in hardware. The computer software product is stored in a storage medium (e.g., ROM, RAM, magnetic disk, optical disk, etc.) and includes several commands for a terminal or network-side device to perform the methods described in each embodiment of this application.

[0166] Although embodiments of this application have been described above with reference to the drawings, this application is not limited to the above-described specific embodiments, and the above-described specific embodiments are merely illustrative and not limiting. Many embodiments that a person skilled in the art could make based on the suggestions of this application without departing from the spirit of this application and the scope of protection of the claims are all within the scope of protection of this application.

Claims

1. The encoding side determines K first target neighbors from a plurality of candidate neighbors based on the geometric distance and attribute distance between the point to be encoded and each of the plurality of candidate neighbors, wherein the candidate neighbors are at least a portion of the plurality of encoded points, the attribute distance is determined based on the attribute information of the point to be encoded and the attribute information of the candidate neighbors, and K is a positive integer of 1 or more. The encoding side performs the step of predicting the attributes of the points to be encoded based on the attribute values ​​of each first target neighboring point, and obtaining the predicted attribute values ​​of the points to be encoded. An attribute coding method comprising the steps of: coding the attribute residuals of the points to be coded to generate an coded code stream corresponding to the points to be coded, wherein the attribute residuals of the points to be coded are determined based on the predicted attribute values ​​of the points to be coded and the original attribute values ​​of the points to be coded.

2. The step of determining K first target neighbors from the plurality of candidate neighbors based on the geometric distance and attribute distance between the encoding target point and each of the plurality of candidate neighbors is as follows: The encoding side calculates the geometric distance between the point to be encoded and each candidate neighbor point, and determines the attribute distance between the point to be encoded and each candidate neighbor point based on the attribute information of the point to be encoded and the attribute information of each candidate neighbor point. The encoding side determines the target distance between the point to be encoded and each candidate neighbor point based on the geometric distance and attribute distance between the point to be encoded and each candidate neighbor point. The encoding side determines K candidate neighbor points from among the plurality of candidate neighbor points that have the minimum corresponding target distance as K first neighbor points. The attribute coding method according to claim 1, wherein the coding side updates the K first neighbors based on the azimuthal distribution relationship between the coding target point and each first neighbor, and obtains the K first target neighbors.

3. The step of determining the attribute distance between the target point to be encoded and each candidate neighbor point based on the attribute information of the target point to be encoded and the attribute information of each candidate neighbor point is: The encoding side calculates the attribute difference between the attribute value of the point to be encoded and the attribute value of the first candidate neighbor point for any of the plurality of candidate neighbor points, wherein the attribute value of the point to be encoded is determined based on the attribute information of the point to be encoded, the attribute value of the first candidate neighbor point is determined based on the attribute information of the first candidate neighbor point, and the attribute information of the point to be encoded and the attribute information of the first candidate neighbor point are of the same attribute type. The attribute coding method according to claim 2, wherein the coding side determines the product of the weight value corresponding to the first candidate neighbor point and the attribute difference as the attribute distance between the point to be coded and the first candidate neighbor point.

4. The step of determining the target distance between the target point to be encoded and each candidate neighbor point based on the geometric distance and attribute distance between the target point to be encoded and each candidate neighbor point is as follows: The encoding side includes determining the target distance between the encoding target point and the second candidate neighbor point as the sum of the first product corresponding to the second candidate neighbor point and the second product corresponding to the second candidate neighbor point, for any second candidate neighbor point among the plurality of candidate neighbor points. The attribute coding method according to claim 2, wherein the first product is the product of the weight value of the geometric distance corresponding to the second candidate neighbor point and the geometric distance corresponding to the second candidate neighbor point, and the second product is the product of the weight value of the attribute distance corresponding to the second candidate neighbor point and the attribute distance corresponding to the second candidate neighbor point.

5. The step of updating the K first neighbors based on the azimuthal distribution relationship between the encoded point and each first neighbor is as follows: The encoding side includes updating some of the K first neighbors that have the furthest target distance from the encoding target to the second target neighbor among the N second neighbors, if the azimuthal distribution relationship between the encoding target point and any two first neighbors is not in opposite directions. The N second neighbor points are a subset of the K first neighbor points from the plurality of candidate neighbor points, and the second target neighbor point is a second neighbor point from the N second neighbor points that satisfies a predetermined condition, where N is a positive integer of 1 or more. The aforementioned predetermined conditions are: The target distance between the second neighboring point and the point to be encoded is less than or equal to a predetermined distance, The attribute encoding method according to claim 2, wherein the orientation between the second neighbor point and the point to be encoded is opposite to the orientation between any one first neighbor point and the point to be encoded, and the any one first neighbor point is a first neighbor point among the K first neighbor points excluding the first neighbor point with the furthest target distance from the point to be encoded.

6. Before determining K first target neighbors from the plurality of candidate neighbors based on the geometric distance and attribute distance between the point to be encoded and each of the plurality of candidate neighbors, The encoding side includes the step of acquiring point cloud data including a point to be encoded, a plurality of encoded points, and an encoded identifier, The attribute coding method according to any one of claims 1 to 5, further comprising the step of determining the geometric distance and attribute distance between the target point and each candidate neighbor point, if the coding side is used to indicate that attribute coding based on attribute type is performed on the target point to be coded.

7. The decoding side performs the steps of analyzing the acquired encoded code stream to obtain the point to be decoded and multiple decoded points, The decoding side determines K first target neighbors from the plurality of candidate neighbors based on the geometric distance and attribute distance between the point to be decoded and each of the plurality of candidate neighbors, wherein the candidate neighbors are at least a portion of the plurality of decoded points, the attribute distance is determined based on the attribute information of the point to be decoded and the attribute information of the candidate neighbors, and K is a positive integer of 1 or more. The decoding side performs the steps of predicting the attributes of the points to be decoded based on the attribute values ​​of each first target neighbor point and obtaining the predicted attribute values ​​of the points to be decoded. An attribute decoding method comprising the steps of: determining the reconstructed attribute value of the target point based on the predicted attribute value of the target point and the attribute residual of the target point, wherein the attribute residual of the target point is obtained by analyzing the encoded code stream.

8. The step of determining K first target neighbors from the plurality of candidate neighbors based on the geometric distance and attribute distance between the decoding target point and each of the plurality of candidate neighbors is as follows: The decoding side calculates the geometric distance between the point to be decoded and each candidate neighbor point, and determines the attribute distance between the point to be decoded and each candidate neighbor point based on the attribute information of the point to be decoded and the attribute information of each candidate neighbor point. The decoding side determines the target distance between the decoding target point and each candidate neighbor point based on the geometric distance and attribute distance between the decoding target point and each candidate neighbor point. The decoding side determines K candidate neighbor points from among the plurality of candidate neighbor points that have the minimum corresponding target distance as K first neighbor points. The attribute decoding method according to claim 7, wherein the decoding side updates the K first neighbors based on the azimuthal distribution relationship between the decoding target point and each first neighbor, and obtains the K first target neighbors.

9. The step of determining the attribute distance between the target point to be decoded and each candidate neighbor point based on the attribute information of the target point to be decoded and the attribute information of each candidate neighbor point is as follows: The decoding side calculates the attribute difference between the attribute value of the point to be decoded and the attribute value of the first candidate neighbor point for any of the plurality of candidate neighbor points, wherein the attribute value of the point to be decoded is determined based on the attribute information of the point to be decoded, the attribute value of the first candidate neighbor point is determined based on the attribute information of the first candidate neighbor point, and the attribute information of the point to be decoded and the attribute information of the first candidate neighbor point are of the same attribute type. The attribute decoding method according to claim 8, wherein the decoding side determines the product of the weight value corresponding to the first candidate neighbor point and the attribute difference as the attribute distance between the point to be decoded and the first candidate neighbor point.

10. The step of determining the target distance between the decoding target point and each candidate neighbor point based on the geometric distance and attribute distance between the decoding target point and each candidate neighbor point is: The decoding side includes determining the target distance between the decoding target point and the second candidate neighbor point as the sum of the first product corresponding to the second candidate neighbor point and the second product corresponding to the second candidate neighbor point, for any second candidate neighbor point among the plurality of candidate neighbor points. The attribute decoding method according to claim 8, wherein the first product is the product of the weight value of the geometric distance corresponding to the second candidate neighbor point and the geometric distance corresponding to the second candidate neighbor point, and the second product is the product of the weight value of the attribute distance corresponding to the second candidate neighbor point and the attribute distance corresponding to the second candidate neighbor point.

11. The step of updating the K first neighbors based on the azimuthal distribution relationship between the decoded point and each first neighbor is as follows: The decoding side includes updating a subset of the K first neighbors that have the furthest target distance from the decoding target, as a second target neighbor among the N second neighbors, if the azimuthal distribution relationship between the decoding target point and any two first neighbors is not in opposite directions. The N second neighbor points are a subset of the K first neighbor points from the plurality of candidate neighbor points, and the second target neighbor point is the second neighbor point among the N second neighbor points that satisfies predetermined conditions and has the smallest corresponding target distance, where N is a positive integer of 1 or more. The aforementioned predetermined conditions are: The target distance between the second neighboring point and the point to be decoded is less than or equal to a predetermined distance, The attribute decoding method according to claim 8, wherein the orientation between the second neighbor point and the decoding target point is opposite to the orientation between any one first neighbor point and the decoding target point, and the any one first neighbor point is a first neighbor point among the K first neighbor points excluding the first neighbor point with the furthest target distance from the decoding target point.

12. The encoded code stream includes a decryption identifier, and before determining K first target neighbors from the plurality of candidate neighbors based on the geometric distance and attribute distance between the point to be decrypted and each of the plurality of candidate neighbors, The attribute decoding method according to any one of claims 7 to 11, further comprising the step of determining the geometric distance and attribute distance between the target point and each candidate neighbor point, if the attribute information of the plurality of decoded points corresponds to different attribute types and the decoding identifier is used to indicate that attribute decoding based on attribute type is performed on the target point to be decoded.

13. A first decision module for determining K first target neighbors from a plurality of candidate neighbors based on the geometric distance and attribute distance between a point to be encoded and each of a plurality of candidate neighbors, wherein the candidate neighbors are at least a portion of a plurality of encoded points, the attribute distance is determined based on the attribute information of the point to be encoded and the attribute information of the candidate neighbors, and K is a positive integer of 1 or more. A prediction module for predicting the attributes of the points to be encoded based on the attribute values ​​of each first target neighbor point and obtaining the predicted attribute values ​​of the points to be encoded, An attribute coding device comprising: a generation module for coding the attribute residuals of the points to be coded and generating an coded stream corresponding to the points to be coded, wherein the attribute residuals of the points to be coded are determined based on the predicted attribute values ​​of the points to be coded and the original attribute values ​​of the points to be coded.

14. The first decision module is, The geometric distance between the point to be encoded and each candidate neighbor point is calculated, and the attribute distance between the point to be encoded and each candidate neighbor point is determined based on the attribute information of the point to be encoded and the attribute information of each candidate neighbor point. Based on the geometric distance and attribute distance between the point to be encoded and each candidate neighbor point, the target distance between the point to be encoded and each candidate neighbor point is determined. The K candidate neighbor points among the aforementioned plurality of candidate neighbor points that have the minimum corresponding target distance are determined as the K first neighbor points. An attribute encoding device according to claim 13, used for updating the K first neighbors based on the azimuthal distribution relationship between the encoding target point and each first neighbor, and obtaining the K first target neighbors.

15. The first decision module further, For any first candidate neighbor point among the plurality of candidate neighbor points, the attribute difference between the attribute value of the point to be encoded and the attribute value of the first candidate neighbor point is calculated, wherein the attribute value of the point to be encoded is determined based on the attribute information of the point to be encoded, the attribute value of the first candidate neighbor point is determined based on the attribute information of the first candidate neighbor point, and the attribute information of the point to be encoded and the attribute information of the first candidate neighbor point are of the same attribute type. An attribute encoding device according to claim 14, which is used to determine the product of a weight value corresponding to the first candidate neighbor point and the attribute difference as the attribute distance between the point to be encoded and the first candidate neighbor point.

16. The first decision module further, For any of the aforementioned multiple candidate neighbor points, the sum of the first product corresponding to the second candidate neighbor point and the second product corresponding to the second candidate neighbor point is used to determine the target distance between the point to be encoded and the second candidate neighbor point. The attribute encoding device according to claim 14, wherein the first product is the product of the weight value of the geometric distance corresponding to the second candidate neighbor point and the geometric distance corresponding to the second candidate neighbor point, and the second product is the product of the weight value of the attribute distance corresponding to the second candidate neighbor point and the attribute distance corresponding to the second candidate neighbor point.

17. The first decision module further, If the azimuthal distribution relationship between the encoding target point and any two first neighboring points is not in opposite directions, a subset of the K first neighboring points that have the furthest target distance from the encoding target point is used to update them as second target neighboring points among the N second neighboring points. The N second neighbor points are a subset of the K first neighbor points from the plurality of candidate neighbor points, and the second target neighbor point is a second neighbor point from the N second neighbor points that satisfies a predetermined condition, where N is a positive integer of 1 or more. The aforementioned predetermined conditions are: The target distance between the second neighboring point and the point to be encoded is less than or equal to a predetermined distance, The attribute encoding device according to claim 14, wherein the orientation between the second neighbor point and the point to be encoded is opposite to the orientation between any one first neighbor point and the point to be encoded, and the any one first neighbor point is a first neighbor point among the K first neighbor points excluding the first neighbor point with the furthest target distance from the point to be encoded.

18. An acquisition module for obtaining point cloud data including the point to be encoded, multiple encoded points, and an encoded identifier, The attribute coding apparatus according to any one of claims 13 to 17, further comprising: a second determination module for determining the geometric distance and attribute distance between the target point and each candidate neighbor point, where the attribute information of the plurality of coded points corresponds to different attribute types, and the coding identifier is used to indicate that attribute coding based on attribute type is performed on the target point to be coded.

19. An analysis module for analyzing the acquired encoded code stream to obtain the decryption target point and multiple decrypted points, A first decision module for determining K first target neighbors from a plurality of candidate neighbors based on the geometric distance and attribute distance between the decoded target point and each of the plurality of candidate neighbors, wherein the candidate neighbors are at least a portion of the plurality of decoded points, the attribute distance is determined based on the attribute information of the decoded target point and the attribute information of the candidate neighbors, and K is a positive integer of 1 or more. A prediction module for predicting the attributes of the points to be decoded based on the attribute values ​​of each first target neighbor point and obtaining the predicted attribute values ​​of the points to be decoded, An attribute decoding device comprising: a second determination module for determining the reconstructed attribute value of the target point based on the attribute prediction value of the target point and the attribute residual of the target point, wherein the attribute residual of the target point is obtained by analyzing the encoded code stream.

20. The first decision module is, The geometric distance between the decryption target point and each candidate neighbor point is calculated, and the attribute distance between the decryption target point and each candidate neighbor point is determined based on the attribute information of the decryption target point and the attribute information of each candidate neighbor point. Based on the geometric distance and attribute distance between the decoding target point and each candidate neighbor point, the target distance between the decoding target point and each candidate neighbor point is determined. The K candidate neighbor points among the aforementioned plurality of candidate neighbor points that have the minimum corresponding target distance are determined as the K first neighbor points. An attribute decoding device according to claim 19, used for updating the K first neighbors based on the azimuthal distribution relationship between the decoding target point and each first neighbor, and obtaining the K first target neighbors.

21. The first decision module further, For any first candidate neighbor point among the plurality of candidate neighbor points, the attribute difference between the attribute value of the point to be decoded and the attribute value of the first candidate neighbor point is calculated, wherein the attribute value of the point to be decoded is determined based on the attribute information of the point to be decoded, the attribute value of the first candidate neighbor point is determined based on the attribute information of the first candidate neighbor point, and the attribute information of the point to be decoded and the attribute information of the first candidate neighbor point are of the same attribute type. The attribute decoding device according to claim 20, which is used to determine the attribute distance between the point to be decoded and the first candidate neighbor point as the product of a weight value corresponding to the first candidate neighbor point and the attribute difference.

22. The first decision module further, For any of the aforementioned plurality of candidate neighbor points, the sum of the first product corresponding to the second candidate neighbor point and the second product corresponding to the second candidate neighbor point is used to determine the target distance between the point to be decoded and the second candidate neighbor point. The attribute decoding device according to claim 20, wherein the first product is the product of the weight value of the geometric distance corresponding to the second candidate neighbor point and the geometric distance corresponding to the second candidate neighbor point, and the second product is the product of the weight value of the attribute distance corresponding to the second candidate neighbor point and the attribute distance corresponding to the second candidate neighbor point.

23. The first decision module further, If the azimuthal distribution relationship between the decoded point and any two first neighboring points is not in opposite directions, a subset of the K first neighboring points that have the furthest target distance from the decoded point is used to update the N second neighboring points as the second target neighboring points. The N second neighbor points are a subset of the K first neighbor points from the plurality of candidate neighbor points, and the second target neighbor point is the second neighbor point among the N second neighbor points that satisfies predetermined conditions and has the smallest corresponding target distance, where N is a positive integer of 1 or more. The aforementioned predetermined conditions are: The target distance between the second neighboring point and the point to be decoded is less than or equal to a predetermined distance, The attribute decoding device according to claim 20, wherein the orientation between the second neighbor point and the decoding target point is opposite to the orientation between any one first neighbor point and the decoding target point, and the any one first neighbor point is a first neighbor point among the K first neighbor points excluding the first neighbor point with the furthest target distance from the decoding target point.

24. The encoded code stream includes a decryption identifier, The attribute decoding device according to any one of claims 19 to 23, further comprising a third determination module for determining the geometric distance and attribute distance between the target point and each candidate neighbor point, provided that the attribute information of the plurality of decoded points corresponds to different attribute types and the decoding identifier is used to indicate that attribute decoding based on attribute type is to be performed on the target point to be decoded.

25. An electronic device comprising a processor and memory, wherein the memory stores a program or command executable on the processor, and when the program or command is executed by the processor, the steps of the attribute encoding method described in any one of claims 1 to 6 are realized, or the steps of the attribute decoding method described in any one of claims 7 to 12 are realized.

26. A readable storage medium in which a program or command is stored, wherein when the program or command is executed by a processor, the steps of the attribute encoding method described in any one of claims 1 to 6 are realized, or the steps of the attribute decoding method described in any one of claims 7 to 12 are realized.