A method for making a lightweight control point image database
By establishing a lightweight mapping function, the floating-point feature description in the control point image database is converted into a binary type, which solves the problem of large information storage in traditional databases and improves the processing efficiency of mobile terminals and the support capabilities of intelligent applications. .
Patent Information
- Application Number
- CN202111473657.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-11-29
- Publication Date
- 2024-10-29
- Estimated Expiration
- 2041-11-29
AI Technical Summary
The traditional control point image database stores a large amount of control point information, resulting in high memory usage, limiting the real-time processing efficiency and accuracy of mobile terminals, and hindering the development of intelligent applications.
By establishing a lightweight mapping function, the 128-bit floating-point control point feature description is converted into a binary feature descriptor, which reduces memory usage and achieves efficient matching speed between satellite images and control point image databases on the mobile terminal.
It achieves lightweight processing of control point information, reduces memory usage, and improves the feasibility of mobile terminals and the support capabilities of intelligent applications.
Smart Images

Figure CN114140634B_ABST
Abstract
Description
Technical Field
[0001] The invention relates to a method for preparing a lightweight control point image database, and belongs to the technical field of photogrammetry and remote sensing. Background Art
[0002] The control point image database is the basis of georeferencing, and its production method is an important technology in the field of photogrammetry and remote sensing mapping. A high-precision control point image database can make full use of existing geographic information data resources and provide strong support for emergency response. The control point image database production method includes data source selection and analysis, data acquisition quality control and storage management.
[0003] With the development of domestic satellites, satellite imaging modes and types are becoming increasingly rich and the update speed is accelerating, which can obtain large-scale high-quality basic remote sensing data. Based on the control information accumulated in the early stage and the satellite images obtained, a control point image database can be constructed for the target area. However, since the attribute information of each control point in the traditional control point image database is described by 128-bit floating-point data, this leads to excessive storage of control point information in the database and excessive memory usage, which greatly restricts the ability of the control point image database to be transplanted to mobile terminals with limited memory for surveying and mapping production, limits the efficiency and accuracy of real-time processing of mobile terminals, and hinders the development of intelligent applications. Summary of the invention
[0004] The purpose of the present invention is to provide a method for preparing a lightweight control point image database to solve the problem of large storage volume and high memory usage of control point information in the currently constructed image database.
[0005] The present invention provides a method for preparing a lightweight control point image database, the method comprising the following steps:
[0006] 1) Obtain control point data, aerospace orthophotos and digital elevation products of the target area; and select a pair of aerospace orthophotos with the highest positioning accuracy and the best imaging conditions as the stereo image pair for constructing the lightweight mapping function training data set;
[0007] 2) performing matching processing on the acquired stereo image pair, extracting feature point pairs of the stereo image pair, and using the extracted feature point pairs as a training data set for the lightweight mapping function; wherein the feature point pairs include correctly matched feature point pairs and incorrectly matched feature point pairs;
[0008] 3) establishing a lightweight mapping function for converting control point data into a binary feature descriptor, and training the lightweight mapping function using feature point pairs in the training data set to obtain a trained lightweight mapping function;
[0009] 4) Input the control point data of the target area into the trained lightweight mapping function to obtain the binary feature descriptor corresponding to the control point, thereby making a lightweight control point image database.
[0010] The present invention establishes a lightweight mapping function and uses the lightweight mapping function to convert the 128-bit floating-point control point feature description into binary feature descriptor data to reduce memory usage. The method can realize lightweight processing of control point feature descriptors, reduce the memory usage of control point information, and thus improve the feasibility of transplanting the control point image database to the mobile terminal, and accelerate the matching rate of satellite images and control point image databases, providing strong support for intelligent applications.
[0011] Furthermore, in order to ensure the comprehensiveness of the control point data in the database, the lightweight control point image database also includes an auxiliary image corresponding to each control point, and the auxiliary image is an image block of a set pixel size centered on the control point.
[0012] Furthermore, the lightweight mapping function in step 3) is a hash function, and the calculation formula is:
[0013] g(u)=f(Pu+T)
[0014] Among them, P is the projection matrix calculated using the LDA idea, T is the threshold limit calculated using the feature-by-feature dimension threshold iteration method and the global approximation method, and u is the feature vector of the feature point.
[0015] Furthermore, in order to obtain the optimal projection matrix to ensure the accuracy of the hash function, the training process of the projection matrix P is:
[0016] Feature descriptor differential calculations are performed on the correctly matched feature point pairs and the incorrectly matched feature point pairs of the stereo image pair, respectively, to obtain a positive data set and a negative data set after corresponding differential calculations; a loss function is constructed for the positive data set and the negative data set, and a spatial matrix that minimizes the loss function is output as a projection matrix.
[0017] Furthermore, in order to obtain the optimal threshold limit to ensure the accuracy of the hash function, the calculation process of the limit threshold T is:
[0018] A uses the generated projection matrix to initially map the feature descriptor of each feature point in the feature point pair to obtain the initial mapping value of the feature descriptor of each feature point in the Hamming space;
[0019] B introduces the cumulative distribution function CDF(t) to represent the probability of the corresponding mapping value when the threshold limit is t; solve the threshold t that can maximize the proportion of the same sign in the positive data set and minimize the proportion of the same sign in the negative data set; where the same sign refers to the situation where the feature points are determined to be adjacent according to the set same-name point pair discrimination criterion;
[0020] C constructs a mapping function based on the generated projection matrix and the obtained threshold t, adds a global correction △t of the threshold t, sets the global correction to 0, substitutes it into the constructed mapping function, and performs point-by-point judgment according to the existing same-name point pair discrimination criteria, calculates the number of correct point pairs in the positive and negative data sets, and calculates the survival rate when △t is 0;
[0021] D sets the iteration step and iteration range of the global correction, continuously iterates and updates △t and the mapping function at the same time, calculates the optimal survival rate under different iterations, obtains the optimal global correction △t when the optimal survival rate is the largest, and obtains the final threshold limit of T=t+△t.
[0022] Furthermore, in order to obtain the optimal stereo image pair and ensure the accuracy of the subsequent construction of the hash function, the screening process of the original stereo image pair in step 1) is: according to the image point coordinates of the control point in the orthophoto, the geographic coordinates of the control point are calculated in combination with the coordinate conversion parameters, and the positioning accuracy of the orthophoto is determined based on the digital elevation model, and the two orthophotos with the best positioning accuracy are selected.
[0023] Furthermore, in order to quickly and accurately achieve the matching of stereo image pairs and the elimination of false matches, the matching method of the stereo image pairs is the SIFT method, and the false match elimination method is a combination of GMS and RANSAC.
[0024] Furthermore, in order to avoid erroneous matching results caused by a large difference between the number of correct matching point pairs and the number of incorrect matching point pairs involved in the calculation, the number of incorrect matching feature point pairs to be retained is 1% of the number of correct matching feature point pairs.
[0025] Furthermore, each control point in the lightweight control point image database includes necessary attribute information of the control point, a binary feature descriptor and an auxiliary image, wherein the necessary attribute information of the control point and the auxiliary image are in binary form. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] Figure 1 It is a flow chart of making a lightweight control point image database of the present invention;
[0027] Figure 2 It is a flow chart of the hash function training of the feature point pair descriptor according to the present invention;
[0028] Figure 3It is a schematic diagram of the nested usage mode of the lightweight control point image database based on the satellite platform of the present invention. DETAILED DESCRIPTION
[0029] The specific implementation of the present invention will be further described below in conjunction with the accompanying drawings.
[0030] The present invention provides a method for preparing a lightweight control point image database. The specific process is as follows: Figure 1 As shown. First, the control point information, aerospace orthophotos and digital elevation products of the target area are obtained, and a pair of aerospace orthophotos are selected as a stereo image pair; then the stereo image pair is matched, and the feature point pair is extracted as a training data set for the lightweight mapping function; then the lightweight mapping function is trained using the feature points in the training data set to obtain the trained lightweight mapping function; finally, all control point information is input into the trained lightweight mapping function, and all lightweight control points constitute a lightweight control point image database. The present invention can train a hash function to achieve lightweight feature descriptors of control points based on stereo image pairs of orthophotos of the target area covered by the image, can reduce the memory usage of control information, improve the feasibility of transplanting the control image database to the mobile terminal, and speed up the matching rate between satellite images and control point image databases, providing strong support for intelligent applications.
[0031] Step 1. Obtain survey area data and data screening
[0032] The control point information, aerospace orthophotos, and corresponding digital elevation models (DEMs) of the target area are obtained. In this embodiment, first, the control point information of the database image area is obtained, and according to the scope of the target area, high-resolution aerospace orthophotos, coordinate conversion parameters, and high-precision digital elevation models (DEMs) of the area within one year are collected. According to the obtained control point information, the pixel coordinates of the control points on each aerospace orthophoto are matched, and according to the digital elevation model within the scope of the area to be measured, the pixel coordinates of the control points on the orthophotos are calculated in combination with the coordinate conversion parameters to determine the accuracy of the aerospace orthophotos obtained; according to the judgment, the two orthophotos with the best positioning accuracy are obtained, and the imaging conditions are best met at the same time, and the two images are formed into a stereo image pair to construct the original image of the lightweight mapping function training set.
[0033] Step 2. Build a training dataset for lightweight mapping functions
[0034] According to the stereo image pair obtained in step 1, SIFT is used to match the stereo image pair, and then GMS and RANSAC mismatch elimination methods are used for geometric constraints to screen and retain the matching feature point pairs. The final feature point pairs are divided into two categories: correctly matched feature point pairs and incorrectly matched feature point pairs, which are used as training data sets for constructing lightweight mapping functions.
[0035] If the number of correctly matched feature point pairs is n and the number of incorrectly matched feature point pairs is m, a certain number of incorrectly matched point pairs must be retained for calculation in subsequent training. Therefore, the number of incorrectly matched point pairs involved in the calculation is constrained by setting the weight parameter β, and m is retained. β There are m pairs of feature points that are incorrectly matched. β =n / β. Finally, there are n correctly matched feature point pairs, m β The number of feature point pairs that are incorrectly matched is used as a training data set for constructing a lightweight mapping function. In this embodiment, the value of β is 0.01. As other implementations, the value of β can be determined according to the number of actual matching feature point pairs.
[0036] Step 3. Train the lightweight mapping function
[0037] The lightweight mapping function used in the present invention is a hash function. The specific training process is as follows: Figure 2 shown.
[0038] According to the feature matching point pairs obtained in step 2, the feature descriptors of the correctly matched feature point pairs are differentiated to obtain the positive data set U S , the feature descriptors of the wrongly matched feature point pairs are differentiated to obtain the negative pair dataset U Q The improved LDA method is used to obtain the projection matrix P from the statistical analysis of the feature descriptors. The threshold T is iteratively optimized considering the local dimension and global vector characteristics, and the hash function g(u)=f(Pu+T) is calculated, where u represents the feature vector of the feature point.
[0039] Among them, when the expected Hamming distance in the positive data set is the smallest and the expected Hamming distance in the negative data set is the largest after the hash function mapping, the loss function L can be minimized, and the spatial matrix when the loss function is minimized is the optimal projection matrix. The specific calculation process is as follows:
[0040] The loss function is calculated as:
[0041] L=αE{Dis ham (U R )}-E{Dis ham (U Q )} (1)
[0042] Where α is the balance parameter of the positive and negative data sets, E{·} represents the expected value, Dis ham (U j ), (j=S,Q) represents the Hamming distance of class j data, S is the positive feature point pair data set, and Q is the negative feature point pair data set.
[0043] In order to facilitate the optimization of the loss function and combine the prior information, it is assumed that the required projection matrix P is an orthogonal matrix and tr{·} is the matrix trace, then E{Dis ham (U S )}=tr{P∑SP T},E{Dis ham (U Q )}=tr{P∑QP T}, the loss function can be transformed into L = atr {P∑SP T}-tr{P∑QP T};
[0044] Using the normalization formula φ(u i ) for the correctly matched feature descriptor and the incorrectly matched feature descriptor u i Processing to get u' i ; The covariance matrix of the positive data set is recorded as ∑S, and the covariance matrix of the negative data set is recorded as ∑Q; The normalization formula used in this example is
[0045] Based on the constructed satellite image feature descriptor training set, the feature descriptor u' is multiplied by ∑Q -1 / 2 To transform the coordinates, the second term of L is converted to a constant, and the proportional relationship of the loss function can be obtained: L∝tr{P∑Q -1 / 2 ∑S∑Q -T / 2 P T}=tr{P∑S∑Q -1 P T}=tr{P∑RP T}, where ∑R=∑S∑Q -1 It is the ratio of the covariance of the positive data set to the covariance of the negative data set, and the characteristic decomposition is performed on it, that is, ∑R=VDV T ;
[0046] A projection matrix that minimizes the loss function should be a matrix that projects the feature descriptor to the space of the minimum eigenvector of ∑R. The projection matrix P is:
[0047] The calculation process of the threshold limit T is as follows:
[0048] (1) First, use the generated projection matrix P to map the feature descriptors of each extracted feature point to obtain the initial mapping values of the feature descriptors on the two orthophotos in the Hamming space, denoted as val Si ,val Qi . Let Y_queryIdx i =P i u' ri ,Y_trianIdx i =P i u' ri (i=1,...,M; r=S,P), where, Y_querlyIdx i ,Y_trianIdx i are the vector values of the i-th dimension data of the feature descriptors in the left and right images projected into the Hamming space, P i is the M-dimensional row vector of the i-th row of the projection matrix P, u' ri is the set of i-th dimension values of r-type feature points.
[0049] (2) In order to facilitate calculation, the concept of cumulative distribution function CDF is introduced. CDF(t) represents the probability of all function values less than or equal to t in a continuous function. Here, it is used to represent the probability of the corresponding mapping value when the threshold limit of a certain dimension is t. Find the threshold t that can maximize the proportion of the same sign in the positive data set and minimize the proportion of the same sign in the negative data set. Among them, according to the set same-name point pair discrimination criterion, determine whether the feature point pairs in the positive data set and the negative data set are adjacent. Adjacent feature point pairs are recorded as the same sign, and non-adjacent feature point pairs are recorded as different signs. When (val Si +t i ),(val Qi +t i ) are the same sign, they are considered adjacent, and they are different signs, they are considered far away. max =max{-val Si ,-val Qi},W min =min{-val Si ,-val Qi}, the criteria for determining pairs of points with the same name are:
[0050]
[0051] (3) Construct a mapping function based on the generated projection matrix and the obtained threshold t, add a global correction △t of the threshold t, first set the global correction to 0, substitute it into the constructed mapping function, perform point-by-point judgment according to the existing same-name point pair discrimination criterion, calculate the number of correct point pairs in the positive data set and the negative data set, and calculate the survival rate when △t is 0;
[0052] According to the calculated projection matrix P and threshold t, a mapping function Pu+t is constructed, a global correction value △t is added, and the threshold t is further optimized, so that Δt=Δt0=0, and the matched feature descriptor and Substitute it into the constructed mapping function Pu+t, and judge each point pair according to the same-name point pair discrimination criterion in the above step (2). Accumulate the corresponding number of correct point pairs num0_S, num0_Q, and calculate its storage rate. The formula is as follows:
[0053]
[0054] (4) By setting the iteration step and iteration range of the global correction, △t is continuously updated and the mapping function is updated simultaneously, the optimal global correction △t is obtained when the optimal survival rate is maximum, and the final threshold limit is T = t + △t.
[0055] The last significant digit of the initial t is recorded as the iteration step length d, the iteration range b is a symmetric integer set, and the iterative calculation form is Δt m =b*d+Δt0(b∈Z), m is the number of iterations, then the hash function after each iteration is Pu+t+Δt m , continue to judge point by point using the same-name point pair discrimination criteria in step (2) above, and calculate the survival rate h after each iteration using the formula m , when the number of iterations is met, find the Δt corresponding to the optimal correction value when the optimal rate is the largest m , get the optimal threshold limit t' i =t i +Δt m (t' i ∈T,i=1,2,...,M),t′ i This is the final threshold limit T.
[0056] Step 4. Lightweight control point image database generation
[0057] The control point data of the target area is input into the trained lightweight mapping function to obtain the binary feature descriptors of the lightweight control points; all the lightweight control points constitute a lightweight control point image database.
[0058] At the same time, in order to ensure the comprehensiveness of the database, the satellite image with the best imaging conditions is selected as the image to be cropped. The pixel coordinates of the control point are obtained by inverse calculation according to the auxiliary parameters. The image block with a size of 50*50 pixels is cropped with this point as the center point, and it is converted into a binary data stream as an auxiliary image. As other implementation methods, the cropping size of the control point image can be determined according to the specific actual situation. The control point image block is detected and described using a matching method, and the floating-point feature descriptor of the center pixel is obtained according to the row and column numbers. The trained hash function is used to obtain its binary descriptor expression as feature description information.
[0059] The necessary attribute information such as the longitude and latitude of all acquired control points is converted into binary form, and a binary data stream in the form of "necessary attribute information of control points + feature description information + auxiliary image" is constructed to obtain a lightweight description form of the control point; and the control information is stored in the lightweight control point database in sequence according to the order of longitude and latitude.
[0060] The control point image database obtained by the above method can be directly used for image matching, for example Figure 3 As shown, the generated control point image database is fixed and written on the satellite platform, feature point detection is performed on the on-orbit real-time image, the generated feature points are converted into binary type through the trained hash function, and the Hamming distance similarity is determined with the control points in the generated control point image database, and the successfully matched feature points are output to realize the satellite platform image matching.
Claims
1. A method for preparing a lightweight control point image database, characterized in that: The method comprises the following steps: 1) Obtain control point data, aerospace orthophotos and digital elevation products of the target area; and select a pair of aerospace orthophotos with the highest positioning accuracy and the best imaging conditions as the stereo image pair for constructing the lightweight mapping function training data set; 2) performing matching processing on the acquired stereo image pair, extracting feature point pairs of the stereo image pair, and using the extracted feature point pairs as a training data set for the lightweight mapping function; wherein the feature point pairs include correctly matched feature point pairs and incorrectly matched feature point pairs; 3) Establishing a lightweight mapping function for converting control point data into a binary feature descriptor, using the feature point pairs in the training data set to train the lightweight mapping function, and obtaining a trained lightweight mapping function, the lightweight mapping function is a hash function, and the calculation formula is: g(u)=f(Pu+T) Among them, P is the projection matrix calculated using the LDA idea, T is the threshold limit calculated using the feature-by-feature dimension threshold iteration method and the global approximation method, u is the feature vector of the feature point, and the calculation process of the threshold limit T is: A) using the generated projection matrix to initially map the feature descriptor of each feature point in the feature point pair, and obtaining the initial mapping value of the feature descriptor of each feature point in the Hamming space; B) Introduce the cumulative distribution function CDF(t) to represent the probability of the corresponding mapping value when the threshold limit is t; solve the threshold t that can maximize the proportion of the same sign in the positive data set and minimize the proportion of the same sign in the negative data set; where the same sign refers to the situation where the feature points are determined to be adjacent according to the set same-name point pair discrimination criterion; C) Construct a mapping function based on the generated projection matrix and the obtained threshold t, add a global correction △t of the threshold t, first set the global correction to 0, substitute it into the constructed mapping function, perform point-by-point judgment according to the existing same-name point pair discrimination criteria, calculate the number of correct point pairs in the positive data set and the negative data set, and calculate the survival rate when △t is 0; D) By setting the iteration step and iteration range of the global correction, △t is continuously updated iteratively and the mapping function is updated at the same time, the optimal global correction △t when the optimal survival rate is the largest is obtained, and the final threshold limit is T=t+△t; 4) Input the control point data of the target area into the trained lightweight mapping function to obtain the binary feature descriptor corresponding to the control point, thereby making a lightweight control point image database.
2. The method for preparing a lightweight control point image database according to claim 1, characterized in that: The lightweight control point image database also includes an auxiliary image corresponding to each control point, and the auxiliary image is an image block of a set pixel size centered on the control point.
3. The method for preparing a lightweight control point image database according to claim 1, characterized in that: The training process of the projection matrix P is: Feature descriptor differential calculations are performed on the correctly matched feature point pairs and the incorrectly matched feature point pairs of the stereo image pair, respectively, to obtain a positive data set and a negative data set after corresponding differential calculations; a loss function is constructed for the positive data set and the negative data set, and a spatial matrix that minimizes the loss function is output as a projection matrix.
4. The method for preparing a lightweight control point image database according to claim 1, characterized in that: The screening process of the stereo image pair in step 1) is as follows: according to the image point coordinates of the corresponding control points in the orthophoto, the geographic coordinates of the control points are calculated based on the digital elevation model combined with the coordinate conversion parameters, the positioning accuracy of the orthophoto is determined, and the two orthophotos with the best positioning accuracy and the best imaging conditions are selected.
5. The method for preparing a lightweight control point image database according to claim 1, characterized in that: In the step 2), the matching method of the stereo image pair is the SIFT method, and the method for eliminating mismatches after matching is a combination of GMS and RANSAC.
6. The method for preparing a lightweight control point image database according to claim 1, characterized in that: In step 2), the number of incorrectly matched feature point pairs that need to be retained is one percent of the number of correctly matched feature point pairs.
7. The method for preparing a lightweight control point image database according to claim 2, characterized in that: Each control point in the lightweight control point image database includes necessary attribute information of the control point, a binary feature descriptor and an auxiliary image, wherein the necessary attribute information of the control point and the auxiliary image are in binary form.
