CN-122023731-A - Quadric surface fitting method, model training method, model reasoning method and device
Abstract
The embodiment of the application provides a quadric surface fitting method, a model training method, a model reasoning method and equipment, and relates to the technical field of computer vision. And converting the Mongolian equation corresponding to the local curved surface where the target point is located into a local PCA coordinate system to obtain an implicit curved surface equation. And then solving an implicit surface equation according to the position information of the target point cloud mass in the local PCA coordinate system to obtain the value of the term to be solved. And finally, obtaining differential characteristic parameters of the local curved surface according to the value of the item to be solved. By the technical scheme, the quadric surface fitting precision can be improved, and more accurate differential characteristic parameters can be obtained.
Inventors
- FU RAO
- ZHENG JIANMIN
- YU LIANG
Assignees
- 阿里巴巴(中国)有限公司
- 南洋理工大学
Dates
- Publication Date
- 20260512
- Application Date
- 20260121
Claims (11)
- 1. A quadric fitting method comprising: Determining a local principal component analysis coordinate system corresponding to a local curved surface where a target point is located by using a principal component analysis method PCA, wherein the target point is any point in point cloud data of a target object; Converting a Mongolian equation corresponding to a local curved surface where the target point is located into the local principal component analysis coordinate system to obtain an implicit curved surface equation, wherein the implicit curved surface equation comprises a term to be solved and is used for describing the local curved surface; Solving the implicit surface equation according to the position information of a target point cloud mass in the local principal component analysis coordinate system to obtain the value of the item to be solved, wherein the target point cloud mass comprises the target point and a plurality of points adjacent to the target point; And obtaining the differential characteristic parameters of the local curved surface according to the value of the item to be solved.
- 2. The method of claim 1, wherein solving the implicit surface equation according to the position information of the target point cloud mass in the local principal component analysis coordinate system to obtain the value of the term to be solved, comprises: correcting the position information of the target point cloud mass in the local principal component analysis coordinate system to obtain corrected position information of each point in the target point cloud mass; and solving the implicit surface equation according to the corrected position information of each point to obtain the value of the item to be solved.
- 3. The method of claim 2, wherein correcting the position information of the target point cloud mass in the local principal component analysis coordinate system includes: determining the position offset corresponding to each point in the target point cloud mass by using a target neural network model; and correcting the position information of the target point cloud mass in the local principal component analysis coordinate system according to the position offset.
- 4. The method of claim 2, wherein solving the implicit surface equation according to the corrected position information of each point to obtain the value of the term to be solved, comprises: Establishing an objective function for the item to be solved in the implicit surface equation based on the corrected position information of each point by using a weighted least square method WLSQ; And obtaining the value of the item to be solved by minimizing the objective function.
- 5. The method of claim 4, wherein deriving the value of the term to be solved by minimizing the objective function comprises: converting the process of minimizing the objective function into a rayleigh quotient problem; And obtaining the value of the item to be solved by solving the Rayleigh quotient problem.
- 6. The method of claim 4, wherein the method further comprises: Determining weight values corresponding to all points in the target point cloud mass by using a target neural network model; establishing an objective function for the term to be solved in the implicit surface equation based on the corrected position information of each point by using a weighted least square method WLSQ, wherein the objective function comprises: And establishing an objective function aiming at the item to be solved in the implicit surface equation based on the position information corrected by each point and the weight value by using a weighted least square method WLSQ.
- 7. The method of claim 1, wherein the differential feature parameters include normal vector, gaussian curvature, average curvature.
- 8. A model training method, comprising: Determining sample points cloud mass based on a pre-generated training data set, wherein the training data set comprises a plurality of different quadrics, and the sample points cloud mass comprise data of points corresponding to local surfaces of any quadrics; inputting the sample points cloud mass to a neural network model to be trained, so that the neural network model to be trained obtains initial differential characteristic parameters of the local curved surface by executing the method as set forth in any one of claims 1-7; constructing a loss function according to the initial differential characteristic parameters and the actual differential characteristic parameters of the local curved surface in the training data set; And updating model parameters of the neural network model to be trained based on the loss function to obtain a trained neural network model.
- 9. A model reasoning method, comprising: Inputting a target point cloud mass into a neural network model, wherein the neural network model is trained based on the method according to claim 8, the target point cloud mass comprises a target point and a plurality of points adjacent to the target point, and the target point is any point in point cloud data of a target object; the neural network model obtains differential characteristic parameters of a local curved surface where a target point is located by executing the method as set forth in any one of claims 1-7, wherein the differential characteristic parameters are used for realizing three-dimensional processing of the target object.
- 10. An electronic device comprising a computer storage medium configured to store computer program instructions for performing the method of any one of claims 1 to 9.
- 11. A computer storage medium having at least one piece of program code stored therein, the program code being loaded and executed by a processor to implement the method of any one of claims 1 to 9.
Description
Quadric surface fitting method, model training method, model reasoning method and device Technical Field The embodiment of the application relates to the technical field of computer vision, in particular to a quadric surface fitting method, a model training method, a model reasoning method and equipment. Background In a three-dimensional processing (e.g., surface reconstruction (Surface Reconstruction), rendering (Rendering), re-gridding (REMESHING), etc.) scene of a target object (e.g., a perceived object of a lidar, an object in a virtual reality scene, etc.), one key procedure is to fit a quadric based on point cloud data, thereby obtaining differential characteristics of the quadric, such as normal vector, curvature. The accuracy of the fitting of the quadric surface in the process will influence the fineness of the output result in the three-dimensional processing process. For example, when the accuracy of the normal vector and the curvature obtained by fitting is high, the rendering result can present richer surface details of the target object. Therefore, it is necessary to provide a method capable of accurately achieving quadric fitting. Disclosure of Invention In view of the above, embodiments of the present application provide a quadric surface fitting method, a model training method, a model reasoning method and a device, so as to at least partially solve the above-mentioned problems. According to a first aspect of the embodiment of the application, a quadric surface fitting method is provided, which comprises the steps of determining a local principal component analysis coordinate system corresponding to a local surface where a target point is located by utilizing a principal component analysis method PCA, wherein the target point is any point in point cloud data of a target object, converting a Mongolian equation corresponding to the local surface where the target point is located to the local principal component analysis coordinate system to obtain an implicit surface equation, wherein the implicit surface equation comprises a term to be solved, the implicit surface equation is used for describing the local surface, solving the implicit surface equation according to position information of the target point cloud mass in the local principal component analysis coordinate system to obtain a value of the term to be solved, wherein the target point cloud mass comprises the target point and a plurality of points adjacent to the target point, and obtaining differential characteristic parameters of the local surface according to the value of the term to be solved, wherein the differential characteristic parameters are used for realizing three-dimensional processing of the target object. According to a second aspect of the embodiment of the present application, there is provided a model training method, including determining a sample point cloud mass based on a pre-generated training data set, where the training data set includes a plurality of different quadric surfaces, where the sample point cloud mass includes data of points corresponding to a local surface of any one quadric surface, inputting the sample point cloud mass to a neural network model to be trained, so that the neural network model to be trained obtains initial differential feature parameters of the local surface by executing the method according to the first aspect, constructing a loss function according to the initial differential feature parameters and actual differential feature parameters of the local surface in the training data set, and updating model parameters of the neural network model to be trained based on the loss function, to obtain a trained neural network model. According to a third aspect of an embodiment of the present application, there is provided a model reasoning method, including inputting a target point cloud mass into a neural network model, the neural network model being trained based on the method as described in the second aspect, the target point cloud mass including a target point and a plurality of points adjacent to the target point, the target point being any one point in point cloud data of a target object, the neural network model obtaining, by executing the method as described in the first aspect, a differential feature parameter of a local curved surface where the target point is located, the differential feature parameter being used to implement three-dimensional processing of the target object. According to a fourth aspect of embodiments of the present application there is provided an electronic device comprising a computer storage medium configured to store computer program instructions for performing the methods of the first, second and third aspects. According to a fifth aspect of embodiments of the present application, there is provided a computer storage medium having stored therein at least one program code loaded and executed by a processor to implement the methods of the first, second and