| In recent years,demands for indoor positioning is increasingly strong,a variety of indoor positioning technologies has been rapid developed,visual positioning technology has been widely concerned because of its low-cost,high-precision features.In this paper,we studied the method of camera pose estimation based on feature point matching,which needs to build a feature points database and index in the offline stage.In the online stage,the feature points of a single image are extracted,matched with the feature points in the database,and the camera pose is solved according to the matching results.Due to the dimension disaster of traditional retrieval methods when facing high-dimensional massive data feature library,the whole retrieval process is time-consuming and laborious,so it is necessary to introduce a more rapid and efficient feature matching algorithm.At the same time,the false extraction and matching of feature points will also affect the positioning accuracy.In order to avoid this kind of influence,it is necessary to eliminate the false matching point pairs when solving the pose.Based on the above background,this paper first selects the SURF algorithm which has better robustness,stability and calculation speed to extract feature points and build feature point library.Secondly,a kind of index structure of nearest neighbor graph(AKGraph)is proposed,which is similar to k-nn graph.Point by point insertion method is adopted to build the graph,and the time complexity of building the graph is multiple logarithm level.Then greedy search algorithm is used to find the approximate nearest neighbor of the point to be queried on the graph.In order to avoid the query results falling into local optimum,the search algorithm is further optimized.The experimental results showed that the efficiency and recall rate of feature query and matching using neighborhood graph are higher than FLANN and KGraph algorithm and hash algorithm.In this paper,RANSAC algorithm is selected to eliminate the mismatched point pairs and estimate the camera pose.In view of the unstable number of iterations and low calculation efficiency of RANSAC,an improvement is proposed,that is,to introduce the evaluation mechanism in the sampling stage,and select the samples that are more likely to be interior points for model calculation.Experimental results showed that the number of iterations of the improved RANSAC algorithm is reduced and the calculation results are more accurate.Finally,a simple mobile phone vision positioning software is developed,and the improved algorithm is used in real environment to test the effectiveness of this method. |