CN112991521B - Point cloud anisotropic neighborhood searching method based on entropy energy - Google Patents

Point cloud anisotropic neighborhood searching method based on entropy energy Download PDF

Info

Publication number
CN112991521B
CN112991521B CN202110326588.XA CN202110326588A CN112991521B CN 112991521 B CN112991521 B CN 112991521B CN 202110326588 A CN202110326588 A CN 202110326588A CN 112991521 B CN112991521 B CN 112991521B
Authority
CN
China
Prior art keywords
neighborhood
point
individual
population
searched
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202110326588.XA
Other languages
Chinese (zh)
Other versions
CN112991521A (en
Inventor
邓博文
孟子阳
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tsinghua University
Original Assignee
Tsinghua University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tsinghua University filed Critical Tsinghua University
Priority to CN202110326588.XA priority Critical patent/CN112991521B/en
Publication of CN112991521A publication Critical patent/CN112991521A/en
Application granted granted Critical
Publication of CN112991521B publication Critical patent/CN112991521B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T17/00Three dimensional [3D] modelling, e.g. data description of 3D objects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/12Computing arrangements based on biological models using genetic models
    • G06N3/126Evolutionary algorithms, e.g. genetic algorithms or genetic programming
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10028Range image; Depth image; 3D point clouds
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20081Training; Learning

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Health & Medical Sciences (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Biophysics (AREA)
  • Software Systems (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Evolutionary Biology (AREA)
  • Genetics & Genomics (AREA)
  • General Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Biomedical Technology (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Evolutionary Computation (AREA)
  • Physiology (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Mathematical Physics (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Computer Graphics (AREA)
  • Geometry (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

本发明提出一种基于熵能量的点云各向异性邻域搜索方法,属于三维信号处理领域。该方法对点云数据中的每个待搜索点,首先搜索距离该待测点最近的K个点构成的K邻域并作为初始邻域,然后从初始邻域中选取不同的点的组合计算该待搜索点在对应组合下的结构张量特征值,并以特征值计算包括线性度和三维散度的几何特征,将结构张量特征值与几何特征组成熵能量函数,通过遗传算法搜索使得熵能量函数最小的初始邻域内的点的组合构成最终邻域。本发明可提高点云邻域搜索的准确性,使邻域集中于同一平面,避免因邻域存在多平面造成的法向量等相关几何特征求解偏差,该方法具有通用性,在三维重构、导航、定位、虚拟现实等领域具有较大的应用前景。

Figure 202110326588

The invention provides a point cloud anisotropic neighborhood search method based on entropy energy, which belongs to the field of three-dimensional signal processing. For each point to be searched in the point cloud data, the method first searches the K neighborhood formed by the K points closest to the point to be measured as the initial neighborhood, and then selects a combination of different points from the initial neighborhood to calculate The eigenvalues of the structure tensor of the point to be searched under the corresponding combination, and the eigenvalues are used to calculate geometric features including linearity and three-dimensional divergence, and the eigenvalues of the structure tensor and the geometric features form an entropy energy function, and the genetic algorithm is used to search such that The combination of points within the initial neighborhood with the smallest entropy energy function constitutes the final neighborhood. The invention can improve the accuracy of the point cloud neighborhood search, make the neighborhood focus on the same plane, and avoid the deviation of solving related geometric features such as normal vector caused by the existence of multiple planes in the neighborhood. Navigation, positioning, virtual reality and other fields have great application prospects.

Figure 202110326588

Description

一种基于熵能量的点云各向异性邻域搜索方法An Anisotropic Neighborhood Search Method for Point Clouds Based on Entropy Energy

技术领域technical field

本发明属于三维信号处理领域,具体涉及一种基于熵能量的点云各向异性邻域搜索方法。The invention belongs to the field of three-dimensional signal processing, and in particular relates to a point cloud anisotropic neighborhood search method based on entropy energy.

背景技术Background technique

点云(Point Cloud)是指通过三维扫描设备、立体视觉技术或三维模型技术获取的,表征在某三维坐标系下的点的集合,每一点至少包含有三维坐标X,Y,Z。其本质是对真实世界或三维模型的离散化,以点的形式还原物体,被广泛应用于三维重构、导航、定位、虚拟现实以及现实增强等领域。Point cloud refers to a collection of points obtained by 3D scanning equipment, stereo vision technology or 3D model technology, representing a certain 3D coordinate system, and each point contains at least 3D coordinates X, Y, Z. Its essence is to discretize the real world or 3D model, and restore objects in the form of points. It is widely used in 3D reconstruction, navigation, positioning, virtual reality, and augmented reality.

由于通常只含有空间坐标信息,点云数据往往需要另外求取各点的法向量等额外几何信息用以进行后续曲面重构、降噪、导航及定位等工作。点云中各点之间没有明确的几何拓扑关系,在求解某一点的法向量等几何信息时,需要在整个点云数据中进行搜索,寻找与该点有相似特性的点组成该点的邻域,而后在邻域内进行法向量等几何信息的求解。Since it usually only contains spatial coordinate information, the point cloud data often needs to obtain additional geometric information such as the normal vector of each point for subsequent surface reconstruction, noise reduction, navigation and positioning. There is no clear geometric topological relationship between points in the point cloud. When solving geometric information such as the normal vector of a point, it is necessary to search the entire point cloud data to find points with similar characteristics to the point to form the neighbors of the point. domain, and then solve the geometric information such as normal vector in the neighborhood.

传统邻域搜索方法以距离为判定依据进行邻域搜索,程效军在其著作中指出,点云的邻域一般通过对点与周边点的欧式距离排序得出。姜晓通等人以二进制八叉树搜索方式进行点云数据间距离的快速排序查找,实现点云K邻域的快速搜索。赵越华等人将散落点云划分为大小相等的立方体栅格中,而后以点到立方格六面距离为依据,实现点云邻域的快速搜索。距离信息有时不足以完整描述点云的特性且容易受噪声干扰,作为改进,Weinmann等人从点云的K邻域中求取归一化的协方差矩阵特征值,并以这些特征值的信息熵最小为优化目标,迭代的进行K邻域的优化构建,实现点云邻域的搜索。The traditional neighborhood search method uses distance as the basis for neighborhood search. Cheng Xiaojun pointed out in his work that the neighborhood of a point cloud is generally obtained by sorting the Euclidean distance between points and surrounding points. Jiang Xiaotong et al. used a binary octree search method to quickly sort and search the distance between point cloud data to realize the fast search of the point cloud K neighborhood. Zhao Yuehua et al. divided the scattered point cloud into cubic grids of equal size, and then based on the distance from the point to the six sides of the cubic grid to realize the fast search of the point cloud neighborhood. The distance information is sometimes insufficient to fully describe the characteristics of the point cloud and is easily disturbed by noise. As an improvement, Weinmann et al. obtained the normalized covariance matrix eigenvalues from the K neighborhood of the point cloud, and used the information of these eigenvalues. The minimum entropy is the optimization goal, and the optimization of the K neighborhood is iteratively constructed to realize the search of the point cloud neighborhood.

上述方法均为各向同性的搜索方法,在三维重建、导航、定位等领域中,车辆、建筑等人造物是场景中的主要物体,这些人造物具有尖锐的边界点或角点,各向同性的邻域搜索方法会使这些边界点或角点的邻域内存在多个平面,从含有多个平面的邻域内求解法向量时,法向量会倾向于各平面法向量的均值,产生模糊,影响三维重建、导航、定位的精度。The above methods are all isotropic search methods. In the fields of 3D reconstruction, navigation, positioning, etc., artificial objects such as vehicles and buildings are the main objects in the scene. These artificial objects have sharp boundary points or corners, and are isotropic. The neighborhood search method of , will cause multiple planes in the neighborhood of these boundary points or corner points. When solving the normal vector from the neighborhood containing multiple planes, the normal vector will tend to the mean value of the normal vectors of each plane, resulting in blurring and affecting Accuracy of 3D reconstruction, navigation, and positioning.

发明内容SUMMARY OF THE INVENTION

本发明的目的是为克服已有技术的不足之处,提出一种基于熵能量的点云各向异性邻域搜索方法。本发明将点的结构张量特征与几何特征相结合,进行点云各向异性的邻域搜索,使邻域中只存在单一平面,从而解决各向同性邻域搜索方法中出现的邻域内存在多个平面,造成法向量模糊等问题。本发明具有通用性,可直接用于点云邻域搜索,在三维重建、导航、定位以及虚拟现实领域有较大的应用前景。The purpose of the present invention is to propose a point cloud anisotropic neighborhood search method based on entropy energy in order to overcome the shortcomings of the prior art. The invention combines the structural tensor feature of the point with the geometric feature, and performs the anisotropic neighborhood search of the point cloud, so that there is only a single plane in the neighborhood, so as to solve the problem of existence in the neighborhood in the isotropic neighborhood search method. Multiple planes cause problems such as blurred normal vectors. The invention has universality, can be directly used for point cloud neighborhood search, and has great application prospects in the fields of three-dimensional reconstruction, navigation, positioning and virtual reality.

本发明提出一种基于熵能量的点云各向异性邻域搜索方法,其特征在于,该方法对点云数据中的每个待搜索点,首先搜索距离该待测点最近的K个点构成K邻域,将K邻域作为初始邻域,然后从初始邻域中选取不同的点的组合计算该待搜索点在对应组合下的结构张量特征值,并以特征值计算包括线性度和三维散度的几何特征,将结构张量特征值与几何特征组成熵能量函数,通过遗传算法搜索使得熵能量函数最小的初始邻域内的点的组合构成该待搜索点的最终邻域。该方法包括以下步骤:The invention proposes a point cloud anisotropic neighborhood search method based on entropy energy, which is characterized in that, for each point to be searched in the point cloud data, the method first searches for the K points closest to the point to be measured. K neighborhood, take the K neighborhood as the initial neighborhood, and then select different combinations of points from the initial neighborhood to calculate the eigenvalues of the structure tensor of the point to be searched under the corresponding combinations, and use the eigenvalues to calculate the linearity and The geometric features of the three-dimensional divergence, the structure tensor eigenvalues and the geometric features form an entropy energy function, and the combination of points in the initial neighborhood that minimizes the entropy energy function through the genetic algorithm constitutes the final neighborhood of the point to be searched. The method includes the following steps:

1)获取三维点云数据,确定该点云数据中的待搜索点;1) Acquire three-dimensional point cloud data, and determine the point to be searched in the point cloud data;

其中,记点云数据为P={pi,i=1,2,…M,pi∈R3},pi为点云数据中的第i个点,M为点的个数;Among them, the point cloud data is recorded as P={pi, i =1,2,...M,pi ∈R3 }, pi is the ith point in the point cloud data, and M is the number of points;

2)对于任一待搜索点Qi={x,y,z},x,y,z为该点的三维坐标;从P中提取该待搜索点Qi的K邻域NB(Qi,K)={pi1,pi2,pi3,…,piK},其中piK为Qi的K邻域内的第K个点,K为邻域点个数;2) For any point to be searched Qi ={x, y, z}, x, y, z are the three-dimensional coordinates of the point; extract the K neighborhood NB ( Q i , K)={ pi1 , pi2 , pi3 ,..., piK } , where piK is the Kth point in the K neighborhood of Qi, and K is the number of neighborhood points;

3)以遗传算法对待搜索点进行各向异性邻域搜索;具体步骤如下:3) Anisotropic neighborhood search is performed on the search points to be searched by genetic algorithm; the specific steps are as follows:

3-1)初始化遗传算法;3-1) Initialize the genetic algorithm;

设定遗传算法中种群个数为M,种群中每个个体长度为K;随机初始化种群中各个体每一位的编码为0或1,其中,0代表未选中该位置在K领域的对应点,1代表选中该位置在K领域的对应点;设置变异概率PM,交叉概率PC,遗传迭代最大次数为T,;令当前迭代次数t=1;将初始化的种群作为当前种群;The number of populations in the genetic algorithm is set to M, and the length of each individual in the population is K; the code of each individual in the population is randomly initialized as 0 or 1, where 0 means that the corresponding point of the position in the K field is not selected. , 1 represents the corresponding point of the selected position in the K field; set the mutation probability PM, the crossover probability PC, and the maximum number of genetic iterations T, ; let the current iteration number t=1; take the initialized population as the current population;

3-2)计算当前种群中每个个体的个体适应度,具体步骤如下:3-2) Calculate the individual fitness of each individual in the current population, the specific steps are as follows:

3-2-1)令个体序号j=1;3-2-1) Let the individual serial number j=1;

3-2-2)将种群中个体j选中的对应点组成待搜索点邻域NB(Qi,N),其中,N为该个体中编码为1的位置总数;计算待搜索点Qi的结构张量Ci,如式(1)所示:3-2-2) Compose corresponding points selected by individual j in the population into the neighborhood of points to be searched NB(Q i ,N), where N is the total number of positions coded as 1 in the individual; calculate the number of points to be searched for Qi The structure tensor C i , as shown in formula (1):

Figure BDA0002994887560000021
Figure BDA0002994887560000021

其中,Pij为邻域NB(Qi,N)内的第j个点,

Figure BDA0002994887560000022
为邻域NB(Qi,N)的几何中心点;Among them, P ij is the jth point in the neighborhood NB(Q i ,N),
Figure BDA0002994887560000022
is the geometric center point of the neighborhood NB(Q i ,N);

3-2-3)对结构张量Ci进行特征值分解,并将特征值从小到大排序,得到特征值排序结果为:0≤λ0≤λ1≤λ23-2-3) Decompose the eigenvalues of the structure tensor C i , and sort the eigenvalues from small to large, and obtain the eigenvalue sorting result: 0≤λ 0 ≤λ 1 ≤λ 2 ;

3-2-4)对特征值λ012分别进行归一化获得对应的归一化后的特征值γ0123-2-4) Normalize the eigenvalues λ 0 , λ 1 , and λ 2 respectively to obtain the corresponding normalized eigenvalues γ 0 , γ 1 , γ 2 ;

3-2-5)计算待测点线性度α1D,如式(2)所示:3-2-5) Calculate the linearity α 1D of the point to be measured, as shown in formula (2):

Figure BDA0002994887560000031
Figure BDA0002994887560000031

3-2-6)计算待测点三维散度α3D,如式(3)所示:3-2-6) Calculate the three-dimensional divergence α 3D of the point to be measured, as shown in formula (3):

Figure BDA0002994887560000032
Figure BDA0002994887560000032

3-2-7)计算熵能量函数E2D,其倒数作为个体j的个体适应度Fj,如式(4)所示:3-2-7) Calculate the entropy energy function E 2D , the reciprocal of which is taken as the individual fitness F j of individual j , as shown in formula (4):

Figure BDA0002994887560000033
Figure BDA0002994887560000033

其中,ω,μ分别为控制因子;Among them, ω and μ are control factors, respectively;

3-2-8)令j=j+1,然后返回步骤3-2-2)计算下一个个体的个体适应度,直至当前种群内所有个体的个体适应度全部计算完毕,进入步骤3-3);3-2-8) Let j=j+1, then go back to step 3-2-2) to calculate the individual fitness of the next individual, until the individual fitness of all individuals in the current population has been calculated, go to step 3-3 );

3-3)根据步骤3-2)得到的所有个体的个体适应度,进行种群个体选择,生成新种群;具体步骤如下:3-3) According to the individual fitness of all individuals obtained in step 3-2), select population individuals to generate a new population; the specific steps are as follows:

3-3-1)依据每个个体的个体适应度Fj,计算该个体被选中的概率ρj,j=1,2,…M,如式(5)所示:3-3-1) According to the individual fitness F j of each individual, calculate the probability ρ j of the individual being selected, j=1,2,...M, as shown in formula (5):

Figure BDA0002994887560000034
Figure BDA0002994887560000034

3-3-2)利用步骤3-3-1)的结果,通过概率选择方法,对种群内的个体进行选择,共选中M个个体复制进入新种群;3-3-2) Using the result of step 3-3-1), select the individuals in the population through the probability selection method, and select M individuals to copy into the new population;

3-4)根据交叉概率PC,对步骤3-3)得到的新种群个体进行交叉,得到更新后的新种群;3-4) According to the crossover probability PC, cross the new population individuals obtained in step 3-3) to obtain an updated new population;

3-5)根据变异概率PM,对步骤3-4)更新后的新种群进行变异,得到更新后的新种群;3-5) According to the mutation probability PM, mutate the updated new population in step 3-4) to obtain the updated new population;

3-6)令迭代次数t=t+1,将步骤3-5)得到的更新后的新种群作为当前种群,然后重新返回步骤3-2);直至t达到遗传迭代最大次数T,种群更新完毕,得到最终的种群;3-6) Let the number of iterations t=t+1, take the updated new population obtained in step 3-5) as the current population, and then return to step 3-2); until t reaches the maximum number of genetic iterations T, the population is updated Finished, get the final population;

3-7)重复步骤3-2),计算最终种群中每个个体的个体适应度,从中选择熵能量函数值最小的个体作为最终个体;根据最终个体每一位的编码值,将该个体中选中的点组成待搜索点Qi的最终邻域

Figure BDA0002994887560000035
其中L为最终个体选中的K邻域点个数,完成该待搜索点的邻域搜索;3-7) Repeat step 3-2), calculate the individual fitness of each individual in the final population, and select the individual with the smallest entropy energy function value as the final individual; The selected points form the final neighborhood of the point Qi to be searched
Figure BDA0002994887560000035
Among them, L is the number of K neighborhood points selected by the final individual to complete the neighborhood search of the point to be searched;

4)判断是否有其他待搜索点:如果有,则重新返回步骤2);如果没有,则搜索完成。4) Determine whether there are other points to be searched: if so, return to step 2); if not, the search is completed.

本发明的特点及有益效果在于:The characteristics and beneficial effects of the present invention are:

本发明首先建立点云K邻域,在邻域中计算结构张量特征值、线性度、平面度以及三维散度等几何特征,将结构张量特征值、线性度、平面度及三维散度组成熵能量函数,通过遗传算法求解使熵能量函数最小的邻域点组合,实现点云各向异性邻域搜索。本发明可直接用于点云邻域搜索,在三维重建、导航、定位以及虚拟现实等领域有较大的应用前景。The present invention firstly establishes the point cloud K neighborhood, calculates geometric features such as the eigenvalue, linearity, flatness and three-dimensional divergence of the structure tensor in the neighborhood, and calculates the eigenvalue, linearity, flatness and three-dimensional divergence of the structure tensor. The entropy energy function is formed, and the neighborhood point combination that minimizes the entropy energy function is solved by genetic algorithm to realize the anisotropic neighborhood search of point cloud. The invention can be directly used for point cloud neighborhood search, and has great application prospects in the fields of three-dimensional reconstruction, navigation, positioning and virtual reality.

附图说明Description of drawings

图1是本发明方法的整体流程图。FIG. 1 is an overall flow chart of the method of the present invention.

图2是本发明实施例中法兰工件点云数据及待搜索点位置示意图。FIG. 2 is a schematic diagram of the point cloud data of the flange workpiece and the position of the point to be searched in the embodiment of the present invention.

图3是本发明实施例中台阶面上沿待搜索点邻域图。FIG. 3 is a neighborhood diagram of a point to be searched along a step surface in an embodiment of the present invention.

图4是本发明实施例中台阶面下沿待搜索点邻域图。FIG. 4 is a neighborhood diagram of a point to be searched along the lower edge of a step surface in an embodiment of the present invention.

图5是本发明实施例中螺纹孔倒角上沿待搜索点邻域图。5 is a neighborhood diagram of a point to be searched along the upper edge of a chamfered threaded hole in an embodiment of the present invention.

图6是本发明实施例中螺纹孔倒角下沿待搜索点邻域图。6 is a neighborhood diagram of a point to be searched along the lower edge of a chamfered threaded hole in an embodiment of the present invention.

具体实施方式Detailed ways

本发明提出一种基于熵能量的点云各向异性邻域搜索方法,下面结合附图和具体实施例进一步详细说明如下。The present invention proposes a method for searching anisotropic neighborhoods of point clouds based on entropy energy, which will be further described in detail below with reference to the accompanying drawings and specific embodiments.

本发明提出一种基于熵能量的点云各向异性邻域搜索方法,该方法对点云数据中的每个待搜索点,首先搜索距离该待测点最近的K个点构成K邻域,将K邻域作为初始邻域,然后从初始邻域中选取不同的点的组合计算该待搜索点在对应组合下的结构张量特征值,并以特征值计算包括线性度和三维散度的几何特征,将结构张量特征值与几何特征组成熵能量函数,通过遗传算法搜索使得熵能量函数最小的初始邻域内的点的组合构成该待搜索点的最终邻域。该方法整体流程如图1所示,包括以下步骤:The present invention proposes a point cloud anisotropic neighborhood search method based on entropy energy. For each point to be searched in the point cloud data, the method first searches the K points closest to the point to be measured to form a K neighborhood, Take the K neighborhood as the initial neighborhood, and then select the combination of different points from the initial neighborhood to calculate the eigenvalue of the structure tensor of the point to be searched under the corresponding combination, and use the eigenvalue to calculate the linearity and three-dimensional divergence. Geometric feature, the structure tensor feature value and geometric feature form an entropy energy function, and the combination of points in the initial neighborhood with the smallest entropy energy function is searched by genetic algorithm to form the final neighborhood of the point to be searched. The overall process of the method is shown in Figure 1, which includes the following steps:

1)获取三维点云数据,确定该点云数据中的待搜索点;1) Acquire three-dimensional point cloud data, and determine the point to be searched in the point cloud data;

其中,记点云数据为P={pi,i=1,2,…M,pi∈R3},pi为点云数据中的第i个点,M为点的个数。Among them, the point cloud data is recorded as P={pi, i =1,2,...M,pi ∈R3 }, pi is the ith point in the point cloud data, and M is the number of points.

本实施例对一个法兰工件进行三维重建时,首先对该工件进行外形扫描,获取点云数据,而后求解各点法向量并进行三维重建,该法兰工件表面有一个台阶面以及8个螺纹孔,因此存在大量尖锐边沿,以各向同性的邻域搜索方法得到的边沿上的点的邻域在求解法向量时会出现法向量模糊。本实例分别选取法兰工件的台阶面上沿一点、下沿一点,螺纹孔倒角上沿一点、下沿一点,共四个待搜索点进行邻域搜索,如图2所示,黑色大圆点为各待搜索点,灰色点为法兰工件点云数据。When 3D reconstruction is performed on a flange workpiece in this embodiment, the workpiece is first scanned for its shape to obtain point cloud data, and then the normal vector of each point is solved and 3D reconstruction is performed. The surface of the flange workpiece has a stepped surface and 8 threads. Therefore, there are a large number of sharp edges, and the neighborhood of the points on the edge obtained by the isotropic neighborhood search method will appear normal vector ambiguity when solving the normal vector. In this example, we select one point along the step surface and one point on the bottom edge of the flange workpiece, one point on the upper edge and one point on the bottom edge of the chamfering of the threaded hole, a total of four points to be searched for neighborhood search, as shown in Figure 2, the black large circle The points are the points to be searched, and the gray points are the point cloud data of the flange workpiece.

2)对于任一待搜索点Qi={x,y,z},x,y,z为该点的三维坐标;从P中提取该待搜索点Qi的K邻域NB(Qi,K)={pi1,pi2,pi3,…,piK},其中piK为Qi的K邻域内的第K个点,K为人工设定邻域点个数,本实施例取K=100。2) For any point to be searched Qi ={x, y, z}, x, y, z are the three-dimensional coordinates of the point; extract the K neighborhood NB ( Q i , K)={p i1 , p i2 , p i3 ,...,p iK } , where p iK is the Kth point in the K neighborhood of Qi, and K is the number of manually set neighborhood points. K=100.

3)以遗传算法对待搜索点进行各向异性邻域搜索;具体步骤如下:3) Anisotropic neighborhood search is performed on the search points to be searched by genetic algorithm; the specific steps are as follows:

3-1)初始化遗传算法:设定遗传算法中种群个数为M,本实施例取M=200,种群中每个个体长度为K(与K领域中的K取值一致),随机初始化种群中各个体每一位的编码为0或1(其中,0代表未选中该位置在K领域的对应点,1代表选中该位置在K领域的对应点;因此种群中每个个体代表一种从K邻域中选取点的组合方式);设置变异概率PM,本实施例取PM=0.01,交叉概率PC,本实施例取PC=0.9,遗传迭代最大次数为T,本实施例取T=300;令当前迭代次数t=1;将该初始化的种群作为当前种群3-1) Initialize the genetic algorithm: set the number of populations in the genetic algorithm to M, in this embodiment, M=200, the length of each individual in the population is K (the value of K in the K field), and the population is randomly initialized The code of each individual is 0 or 1 (where, 0 represents that the corresponding point of the position in the K field is not selected, and 1 represents that the corresponding point of the position in the K field is selected; therefore, each individual in the population represents a kind of The combination of selected points in the K neighborhood); set the mutation probability PM, this embodiment takes PM=0.01, the crossover probability PC, this embodiment takes PC=0.9, the maximum number of genetic iterations is T, this embodiment takes T=300 ; Let the current iteration number t=1; take the initialized population as the current population

3-2)计算当前种群中每个个体的个体适应度,具体步骤如下:3-2) Calculate the individual fitness of each individual in the current population, the specific steps are as follows:

3-2-1)令个体序号j=1;3-2-1) Let the individual serial number j=1;

3-2-2)将种群中个体j选中的对应点组成待搜索点邻域NB(Qi,N),其中,N为该个体中编码为1的位置总数(也是邻域NB(Qi,N)内点的个数,N≤K);计算待搜索点Qi的结构张量Ci,如式(1)所示,其中,Pij为该邻域内的第j个点,

Figure BDA0002994887560000051
为该邻域的几何中心点;3-2-2) The corresponding points selected by individual j in the population form the neighborhood NB(Q i ,N) of the points to be searched, where N is the total number of positions coded as 1 in the individual (also the neighborhood NB(Q i ) ,N) the number of inner points, N≤K); calculate the structural tensor C i of the point Qi to be searched , as shown in formula (1), where P ij is the jth point in the neighborhood,
Figure BDA0002994887560000051
is the geometric center point of the neighborhood;

Figure BDA0002994887560000052
Figure BDA0002994887560000052

3-2-3)对结构张量Ci进行特征值分解,并将特征值从小到大排序,得到特征值排序结果为:0≤λ0≤λ1≤λ23-2-3) Decompose the eigenvalues of the structure tensor C i , and sort the eigenvalues from small to large, and obtain the eigenvalue sorting result: 0≤λ 0 ≤λ 1 ≤λ 2 ;

3-2-4)对特征值λ012分别进行归一化获得对应的归一化后的特征值γ0123-2-4) Normalize the eigenvalues λ 0 , λ 1 , and λ 2 respectively to obtain the corresponding normalized eigenvalues γ 0 , γ 1 , γ 2 ;

3-2-5)计算待测点线性度α1D,如式(2)所示:3-2-5) Calculate the linearity α 1D of the point to be measured, as shown in formula (2):

Figure BDA0002994887560000053
Figure BDA0002994887560000053

3-2-6)计算待测点三维散度α3D,如式(3)所示:3-2-6) Calculate the three-dimensional divergence α 3D of the point to be measured, as shown in formula (3):

Figure BDA0002994887560000054
Figure BDA0002994887560000054

3-2-7)计算熵能量函数E2D,其倒数作为个体j的个体适应度Fj,如式(4)所示:3-2-7) Calculate the entropy energy function E 2D , the reciprocal of which is taken as the individual fitness F j of individual j , as shown in formula (4):

Figure BDA0002994887560000055
Figure BDA0002994887560000055

其中,ω,μ分别为控制因子,本实例中选取ω=0.6,μ=0.5。Among them, ω and μ are control factors respectively, and in this example, ω=0.6 and μ=0.5 are selected.

3-2-8)令j=j+1,选择种群中新的个体,然后返回步骤3-2-2)计算下一个个体的个体适应度,直至当前种群内所有个体的个体适应度全部计算完毕,进入步骤3-3);3-2-8) Set j=j+1, select a new individual in the population, and then return to step 3-2-2) to calculate the individual fitness of the next individual until the individual fitness of all individuals in the current population is fully calculated Finished, go to step 3-3);

3-3)根据步骤3-2)得到的所有个体的个体适应度,进行种群个体选择,生成新种群;具体步骤如下:3-3) According to the individual fitness of all individuals obtained in step 3-2), select population individuals to generate a new population; the specific steps are as follows:

3-3-1)依据每个个体的个体适应度Fj,计算该个体被选中的概率ρj,(j=1,2,…M),如式(5)所示:3-3-1) According to the individual fitness F j of each individual, calculate the probability ρ j of the individual being selected, (j=1,2,...M), as shown in formula (5):

Figure BDA0002994887560000061
Figure BDA0002994887560000061

3-3-2)利用步骤3-3-1)的结果,以“轮盘赌法”或其他概率选择方法,对种群内的个体进行选择,共选中M个个体复制进入新种群;3-3-2) Using the result of step 3-3-1), select the individuals in the population by "roulette method" or other probability selection methods, and select M individuals to copy into the new population;

3-4)对步骤3-3)得到的新种群个体进行交叉,得到更新后的新种群;具体方法如下:3-4) Crossover the new population individuals obtained in step 3-3) to obtain an updated new population; the specific method is as follows:

根据设定的交叉概率PC,每次从新种群中随机生成父类对,随机选择编码点位进行编码交换交叉操作,生成两个新的个体,以生成的两个新个体替代其父类对;共进行M次操作后,完成新种群交叉,得到更新后的新种群;According to the set crossover probability PC, the parent class pair is randomly generated from the new population each time, and the coding point is randomly selected to carry out the code exchange crossover operation to generate two new individuals, and the two new individuals generated replace their parent class pair; After a total of M operations, the crossover of the new population is completed, and the updated new population is obtained;

3-5)对步骤3-4)更新后的新种群进行变异,得到更新后的新种群;具体方法如下:3-5) mutate the updated new population in step 3-4) to obtain the updated new population; the specific method is as follows:

根据设定的变异概率PM,从新种群中随机选择个体,随机选择编码点位进行编码翻转变异操作,生成新个体,以变异后的新个体替代变异前个体;共进行M次操作后,完成新种群变异操作,得到更新后的种群;According to the set mutation probability PM, individuals are randomly selected from the new population, and the coding points are randomly selected to perform the coding flip mutation operation to generate new individuals, and the mutated new individuals are used to replace the former individuals; after a total of M operations, the new individual is completed. Population mutation operation to get the updated population;

3-6)通过步骤3-3)-3-5)完成种群更新,生成新种群,令迭代次数t=t+1,将该新种群作为当前种群,然后重新返回步骤3-2),再次进行适应度计算,直至达到遗传迭代最大次数T,种群更新完毕,得到最终的种群;3-6) Complete the population update through steps 3-3)-3-5), generate a new population, set the number of iterations t=t+1, take the new population as the current population, and then return to step 3-2), again The fitness calculation is performed until the maximum number of genetic iterations T is reached, the population update is completed, and the final population is obtained;

3-7)重复步骤3-2),计算最终种群中每个个体的个体适应度,从中选择熵能量函数值最小(即个体适应度最大)的个体作为最终个体;根据最终个体每一位的编码值,将该个体中选中的点(即编码为1的位置对应的K邻域中的点)组成待搜索点Qi的最终邻域

Figure BDA0002994887560000062
其中L为最终个体选中的K邻域点个数,完成该待搜索点的邻域搜索;3-7) Repeat step 3-2) to calculate the individual fitness of each individual in the final population, and select the individual with the smallest entropy energy function value (that is, the largest individual fitness) as the final individual; Coding value, the selected point in the individual (that is, the point in the K neighborhood corresponding to the position coded as 1) forms the final neighborhood of the point to be searched Qi
Figure BDA0002994887560000062
Among them, L is the number of K neighborhood points selected by the final individual to complete the neighborhood search of the point to be searched;

4)判断是否有其他待搜索点:如果有,则重新返回步骤2);如果没有则结束搜索过程。4) Determine whether there are other points to be searched: if so, return to step 2); if not, end the search process.

根据本发明,依照步骤1)-3),对实施例的法兰工件进行各待搜索点邻域搜索,结果如图3-6所示,其中,图3为台阶面上沿待搜索点邻域搜索结果,图4为台阶面下沿待搜索点邻域搜索结果,图5为螺纹孔上沿待搜索点邻域搜索结果,图6为螺纹孔下沿待搜索点邻域搜索结果,图中三角形为依照本发明方法进行搜索的邻域,黑色小点为依照Weinmann等人方法进行邻域搜索结果,黑色大圆点为待测点位置,两个椭圆内的点分别属于不同平面,从图中可以看出,基于Weinmann等人方法进行搜索的邻域内含有两个平面,而基于本发明搜索的邻域具有各向异性,内部只含有单一平面,可以有效避免法向量求解模糊的问题。According to the present invention, according to steps 1)-3), the flange workpiece of the embodiment is searched for the neighborhood of each point to be searched, and the result is shown in Fig. 3-6, wherein Fig. 3 shows the neighbors of the point to be searched along the step surface Domain search results, Fig. 4 is the search result of the neighborhood of the point to be searched along the lower edge of the step surface, Fig. 5 is the search result of the neighborhood of the point to be searched along the upper edge of the threaded hole, Fig. 6 is the search result of the neighborhood of the point to be searched along the lower edge of the threaded hole, Fig. The middle triangle is the neighborhood searched according to the method of the present invention, the small black point is the result of the neighborhood search according to the method of Weinmann et al., the large black dot is the position of the point to be measured, and the points in the two ellipses belong to different planes, respectively. As can be seen from the figure, the neighborhood searched based on the method of Weinmann et al. contains two planes, while the neighborhood searched based on the present invention is anisotropic and only contains a single plane, which can effectively avoid the problem of ambiguity in normal vector solution.

Claims (2)

1.一种基于熵能量的点云各向异性邻域搜索方法,其特征在于,该方法对点云数据中的每个待搜索点,首先搜索距离该待搜索点最近的K个点构成K邻域,将K邻域作为初始邻域,然后从初始邻域中选取不同的点的组合计算该待搜索点在对应组合下的结构张量特征值,并以特征值计算包括线性度和三维散度的几何特征,将结构张量特征值与几何特征组成熵能量函数,通过遗传算法搜索使得熵能量函数最小的初始邻域内的点的组合构成该待搜索点的最终邻域;该方法包括以下步骤:1. a point cloud anisotropic neighborhood search method based on entropy energy, it is characterized in that, this method is to each point to be searched in the point cloud data, first searches the K points that are closest to the point to be searched to form K Neighborhood, take the K neighborhood as the initial neighborhood, and then select a combination of different points from the initial neighborhood to calculate the eigenvalue of the structure tensor of the point to be searched under the corresponding combination, and use the eigenvalue to calculate the linearity and three-dimensional The geometric feature of divergence, the structure tensor feature value and the geometric feature are formed into an entropy energy function, and the combination of points in the initial neighborhood where the entropy energy function is minimized is searched through a genetic algorithm to form the final neighborhood of the point to be searched; the method includes: The following steps: 1)获取三维点云数据,确定该点云数据中的待搜索点;1) Acquire three-dimensional point cloud data, and determine the point to be searched in the point cloud data; 其中,记点云数据为P={pi,i=1,2,…M,pi∈R3},pi为点云数据中的第i个点,M为点的个数;Among them, the point cloud data is recorded as P={pi, i =1,2,...M,pi ∈R3 }, pi is the ith point in the point cloud data, and M is the number of points; 2)对于任一待搜索点Qi={x,y,z},x,y,z为该点的三维坐标;从P中提取该待搜索点Qi的K邻域NB(Qi,K)={pi1,pi2,pi3,…,piK},其中piK为Qi的K邻域内的第K个点,K为邻域点个数;2) For any point to be searched Qi ={x, y, z}, x, y, z are the three-dimensional coordinates of the point; extract the K neighborhood NB ( Q i , K)={ pi1 , pi2 , pi3 ,..., piK } , where piK is the Kth point in the K neighborhood of Qi, and K is the number of neighborhood points; 3)以遗传算法对待搜索点进行各向异性邻域搜索;具体步骤如下:3) Anisotropic neighborhood search is performed on the search points to be searched by genetic algorithm; the specific steps are as follows: 3-1)初始化遗传算法;3-1) Initialize the genetic algorithm; 设定遗传算法中种群个数为M,种群中每个个体长度为K;随机初始化种群中各个体每一位的编码为0或1,其中,0代表未选中该位置在K领域的对应点,1代表选中该位置在K领域的对应点;设置变异概率PM,交叉概率PC,遗传迭代最大次数为T;令当前迭代次数t=1;将初始化的种群作为当前种群;The number of populations in the genetic algorithm is set to M, and the length of each individual in the population is K; the code of each individual in the population is randomly initialized as 0 or 1, where 0 means that the corresponding point of the position in the K field is not selected. , 1 represents the corresponding point of the selected position in the K field; set the mutation probability PM, the crossover probability PC, and the maximum number of genetic iterations T; set the current iteration number t=1; take the initialized population as the current population; 3-2)计算当前种群中每个个体的个体适应度,具体步骤如下:3-2) Calculate the individual fitness of each individual in the current population, the specific steps are as follows: 3-2-1)令个体序号j=1;3-2-1) Let the individual serial number j=1; 3-2-2)将种群中个体j选中的对应点组成待搜索点邻域NB(Qi,N),其中,N为该个体中编码为1的位置总数;计算待搜索点Qi的结构张量Ci,如式(1)所示:3-2-2) Compose corresponding points selected by individual j in the population into the neighborhood of points to be searched NB(Q i ,N), where N is the total number of positions coded as 1 in the individual; calculate the number of points to be searched for Qi The structure tensor C i , as shown in formula (1):
Figure FDA0003552815900000011
Figure FDA0003552815900000011
其中,Pij为邻域NB(Qi,N)内的第j个点,
Figure FDA0003552815900000012
为邻域NB(Qi,N)的几何中心点;
Among them, P ij is the jth point in the neighborhood NB(Q i ,N),
Figure FDA0003552815900000012
is the geometric center point of the neighborhood NB(Q i ,N);
3-2-3)对结构张量Ci进行特征值分解,并将特征值从小到大排序,得到特征值排序结果为:0≤λ0≤λ1≤λ23-2-3) Decompose the eigenvalues of the structure tensor C i , and sort the eigenvalues from small to large, and obtain the eigenvalue sorting result: 0≤λ 0 ≤λ 1 ≤λ 2 ; 3-2-4)对特征值λ012分别进行归一化获得对应的归一化后的特征值γ0123-2-4) Normalize the eigenvalues λ 0 , λ 1 , and λ 2 respectively to obtain the corresponding normalized eigenvalues γ 0 , γ 1 , γ 2 ; 3-2-5)计算待测点线性度α1D,如式(2)所示:3-2-5) Calculate the linearity α 1D of the point to be measured, as shown in formula (2):
Figure FDA0003552815900000021
Figure FDA0003552815900000021
3-2-6)计算待测点三维散度α3D,如式(3)所示:3-2-6) Calculate the three-dimensional divergence α 3D of the point to be measured, as shown in formula (3):
Figure FDA0003552815900000022
Figure FDA0003552815900000022
3-2-7)计算熵能量函数E2D,其倒数作为个体j的个体适应度Fj,如式(4)所示:3-2-7) Calculate the entropy energy function E 2D , the reciprocal of which is taken as the individual fitness F j of individual j , as shown in formula (4):
Figure FDA0003552815900000023
Figure FDA0003552815900000023
其中,ω,μ分别为控制因子;Among them, ω and μ are control factors, respectively; 3-2-8)令j=j+1,然后返回步骤3-2-2)计算下一个个体的个体适应度,直至当前种群内所有个体的个体适应度全部计算完毕,进入步骤3-3);3-2-8) Let j=j+1, then go back to step 3-2-2) to calculate the individual fitness of the next individual, until the individual fitness of all individuals in the current population has been calculated, go to step 3-3 ); 3-3)根据步骤3-2)得到的所有个体的个体适应度,进行种群个体选择,生成新种群;具体步骤如下:3-3) According to the individual fitness of all individuals obtained in step 3-2), select population individuals to generate a new population; the specific steps are as follows: 3-3-1)依据每个个体的个体适应度Fj,计算该个体被选中的概率ρj,j=1,2,…M,如式(5)所示:3-3-1) According to the individual fitness F j of each individual, calculate the probability ρ j of the individual being selected, j=1,2,...M, as shown in formula (5):
Figure FDA0003552815900000024
Figure FDA0003552815900000024
3-3-2)利用步骤3-3-1)的结果,通过概率选择方法,对种群内的个体进行选择,共选中M个个体复制进入新种群;3-3-2) Using the result of step 3-3-1), select the individuals in the population through the probability selection method, and select M individuals to copy into the new population; 3-4)根据交叉概率PC,对步骤3-3)得到的新种群个体进行交叉,得到更新后的新种群;3-4) According to the crossover probability PC, cross the new population individuals obtained in step 3-3) to obtain an updated new population; 3-5)根据变异概率PM,对步骤3-4)更新后的新种群进行变异,得到更新后的新种群;3-5) According to the mutation probability PM, mutate the updated new population in step 3-4) to obtain the updated new population; 3-6)令迭代次数t=t+1,将步骤3-5)得到的更新后的新种群作为当前种群,然后重新返回步骤3-2);直至t达到遗传迭代最大次数T,种群更新完毕,得到最终的种群;3-6) Let the number of iterations t=t+1, take the updated new population obtained in step 3-5) as the current population, and then return to step 3-2); until t reaches the maximum number of genetic iterations T, the population is updated Finished, get the final population; 3-7)重复步骤3-2),计算最终种群中每个个体的个体适应度,从中选择熵能量函数值最小的个体作为最终个体;根据最终个体每一位的编码值,将该个体中选中的点组成待搜索点Qi的最终邻域
Figure FDA0003552815900000025
其中L为最终个体选中的K邻域点个数,完成该待搜索点的邻域搜索;
3-7) Repeat step 3-2), calculate the individual fitness of each individual in the final population, and select the individual with the smallest entropy energy function value as the final individual; The selected points form the final neighborhood of the point Qi to be searched
Figure FDA0003552815900000025
Among them, L is the number of K neighborhood points selected by the final individual to complete the neighborhood search of the point to be searched;
4)判断是否有其他待搜索点:如果有,则重新返回步骤2);如果没有,则搜索完成。4) Determine whether there are other points to be searched: if so, return to step 2); if not, the search is completed.
2.如权利要求1 所述的方法,其特征在于,所述概率选择方法为轮盘赌法。2. The method of claim 1, wherein the probability selection method is a roulette method.
CN202110326588.XA 2021-03-26 2021-03-26 Point cloud anisotropic neighborhood searching method based on entropy energy Active CN112991521B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110326588.XA CN112991521B (en) 2021-03-26 2021-03-26 Point cloud anisotropic neighborhood searching method based on entropy energy

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110326588.XA CN112991521B (en) 2021-03-26 2021-03-26 Point cloud anisotropic neighborhood searching method based on entropy energy

Publications (2)

Publication Number Publication Date
CN112991521A CN112991521A (en) 2021-06-18
CN112991521B true CN112991521B (en) 2022-04-29

Family

ID=76333841

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110326588.XA Active CN112991521B (en) 2021-03-26 2021-03-26 Point cloud anisotropic neighborhood searching method based on entropy energy

Country Status (1)

Country Link
CN (1) CN112991521B (en)

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102143364B (en) * 2011-04-19 2012-11-14 浙江大学 Motion estimation method based on genetic search and template matching
CN105488192A (en) * 2015-12-03 2016-04-13 青岛尤尼科技有限公司 Point cloud data K neighborhood search method
CN110111430B (en) * 2019-04-11 2023-03-10 暨南大学 Method for extracting quadric surface from three-dimensional point cloud
CN110674860A (en) * 2019-09-19 2020-01-10 南京邮电大学 Feature selection method, storage medium and terminal based on neighborhood search strategy

Also Published As

Publication number Publication date
CN112991521A (en) 2021-06-18

Similar Documents

Publication Publication Date Title
Muzahid et al. CurveNet: Curvature-based multitask learning deep networks for 3D object recognition
CN100559398C (en) Automatic deepness image registration method
Shamir A survey on mesh segmentation techniques
CN108171780A (en) A kind of method that indoor true three-dimension map is built based on laser radar
CN110188228A (en) A Cross-Modal Retrieval Method Based on Sketch Retrieval for 3D Models
CN114926699B (en) Method, device, medium and terminal for semantic classification of indoor 3D point cloud
CN109615581B (en) Splicing recovery method of three-dimensional fragments fusing expanded Gaussian balls and color geometric features
CN115222988A (en) PointEFF fine classification method for urban ground objects based on lidar point cloud data
CN115661374A (en) Rapid retrieval method based on space division and model voxelization
CN109299301A (en) A 3D Model Retrieval Method Based on Shape Distribution and Curvature
CN113449733A (en) Point cloud scene tree extraction method based on structural analysis
CN116485821A (en) A method and device for building point cloud segmentation and vector contour extraction
CN109920050A (en) A single-view 3D flame reconstruction method based on deep learning and thin-plate splines
CN109241628B (en) 3D CAD model segmentation method based on atlas theory and clustering
CN114022526B (en) SAC-IA point cloud registration method based on three-dimensional shape context
CN113343765B (en) Scene retrieval method and system based on point cloud rigid registration
CN112991521B (en) Point cloud anisotropic neighborhood searching method based on entropy energy
Zhou et al. Distributed optimization based on graph filter for ensuring invariant simplification of high-volume point cloud
CN111597367B (en) Three-dimensional model retrieval method based on view and hash algorithm
CN116051540B (en) Method and system for acquiring position and pose of transformer terminals based on point cloud model
CN117541807A (en) Terrain characteristic line extraction method based on active learning
CN114862911B (en) A 3D point cloud single target tracking method based on graph convolution
CN117036733A (en) Urban road scene characteristic line extraction method
Rao et al. Light-Net: lightweight object detector
Liu et al. Local topology constrained point cloud registration in building information modeling

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant