WO2021012523A1 - Three-dimensional image search method and system, computer device, and storage medium - Google Patents

Three-dimensional image search method and system, computer device, and storage medium Download PDF

Info

Publication number
WO2021012523A1
WO2021012523A1 PCT/CN2019/118153 CN2019118153W WO2021012523A1 WO 2021012523 A1 WO2021012523 A1 WO 2021012523A1 CN 2019118153 W CN2019118153 W CN 2019118153W WO 2021012523 A1 WO2021012523 A1 WO 2021012523A1
Authority
WO
WIPO (PCT)
Prior art keywords
dimensional image
corner point
image
target
dimensional
Prior art date
Application number
PCT/CN2019/118153
Other languages
French (fr)
Chinese (zh)
Inventor
陈恺
赵付利
Original Assignee
平安科技(深圳)有限公司
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 平安科技(深圳)有限公司 filed Critical 平安科技(深圳)有限公司
Publication of WO2021012523A1 publication Critical patent/WO2021012523A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/50Information retrieval; Database structures therefor; File system structures therefor of still image data
    • G06F16/53Querying
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/50Information retrieval; Database structures therefor; File system structures therefor of still image data
    • G06F16/55Clustering; Classification
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/50Information retrieval; Database structures therefor; File system structures therefor of still image data
    • G06F16/58Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually
    • G06F16/583Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually using metadata automatically derived from the content
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Definitions

  • This application relates to the technical field of image matching. Specifically, this application relates to a three-dimensional image search method, a three-dimensional image search system, a computer device, and a storage medium.
  • Three-dimensional images are also called stereo images, depth images, and three-dimensional digital models.
  • Three-dimensional images contain the complete information of the three-dimensional coordinates and gray levels of the real object surface, and record the three-dimensional space coordinates of each sampling point on the surface of the object.
  • Three-dimensional images are very different from traditional planar images.
  • the traditional plane image can be regarded as the brightness distribution in the two-dimensional space, and the plane image is obtained by projecting the real three-dimensional world on the two-dimensional image plane.
  • Three-dimensional images carry more information and can be used to display the shape and structure of the product in a three-dimensional and omni-directional manner.
  • three-dimensional images used to display products are widely used, and it is inevitable that the demand for three-dimensional image search to find corresponding products has increased.
  • the inventor realizes that three-dimensional images carry more information. Although the three-dimensional image can be perceived by observing the three-dimensional image, the image acquisition device such as a camera can only collect and record the two-dimensional image of the three-dimensional image at a certain angle of view. Therefore, it is generally impossible to directly obtain the three-dimensional space coordinates described by the three-dimensional image, and it is difficult to search the three-dimensional image by collecting the three-dimensional image.
  • the purpose of this application is to at least solve one of the above-mentioned technical defects, especially the technical defect that the image acquisition device cannot collect 3D images for 3D image search.
  • This application provides a three-dimensional image search method, including the following steps: acquiring a first two-dimensional image of a search object, calculating a first corner point of the first two-dimensional image; comparing the first corner point with each of the image database Match the second corner points of the second two-dimensional image corresponding to the three-dimensional image, determine the target two-dimensional image from the second two-dimensional image; calculate the difference between the first two-dimensional image and the target two-dimensional image The viewing angle difference; the three-dimensional image corresponding to the target two-dimensional image whose viewing angle difference is less than the first threshold is determined as the search result.
  • This application also provides a three-dimensional image search system, including: a corner point calculation module, configured to obtain a first two-dimensional image of the search object, and calculate the first corner point of the first two-dimensional image; a two-dimensional image matching module, Used to match the first corner point with the second corner point of the second two-dimensional image corresponding to each three-dimensional image in the image database, and determine a target two-dimensional image from the second two-dimensional image; a viewing angle difference calculation module , Used to calculate the viewing angle difference between the first two-dimensional image and the target two-dimensional image; a three-dimensional image acquisition module, used to determine the three-dimensional image corresponding to the target two-dimensional image with the viewing angle difference less than the first threshold as search results.
  • a corner point calculation module configured to obtain a first two-dimensional image of the search object, and calculate the first corner point of the first two-dimensional image
  • a two-dimensional image matching module Used to match the first corner point with the second corner point of the second two-dimensional image corresponding to each three-dimensional image in
  • the present application also provides a computer device, including a memory, a processor, and a computer program stored in the memory and running on the processor, and the processor implements the steps of a three-dimensional image search method when the computer program is executed,
  • the steps of the three-dimensional image search method include: acquiring a first two-dimensional image of a search object, calculating a first corner point of the first two-dimensional image; comparing the first corner point with each three-dimensional image in the image database The second corner points of the corresponding second two-dimensional image are matched, and the target two-dimensional image is determined from the second two-dimensional image; the viewing angle difference between the first two-dimensional image and the target two-dimensional image is calculated ; Determine the three-dimensional image corresponding to the target two-dimensional image whose angle of view difference is less than the first threshold as the search result.
  • the present application also provides a computer-readable storage medium on which a computer program is stored.
  • the steps of the three-dimensional image search method include: obtaining search Calculate the first corner of the first two-dimensional image of the object; match the first corner with the second corner of the second two-dimensional image corresponding to each three-dimensional image in the image database , Determine the target two-dimensional image from the second two-dimensional image; calculate the angle of view difference between the first two-dimensional image and the target two-dimensional image; determine the target two-dimensional image whose angle of view difference is less than the first threshold The corresponding three-dimensional image is determined as the search result.
  • the above-mentioned three-dimensional image search method, system, computer equipment and storage medium according to the easy-to-collect first two-dimensional image of the search object, use the easily recognizable corner points in the two-dimensional image to perform image matching, thereby searching for the three-dimensional image and As a result of the search, a three-dimensional image search is realized.
  • two-dimensional images are easy to obtain, and the corner points as features are also easy to identify, which greatly improves the search efficiency; at the same time, considering the three-dimensional characteristics of the search object, it also improves the accuracy of the three-dimensional image search based on the judgment of the viewing angle difference.
  • Fig. 1 is an implementation environment diagram of a three-dimensional image search method provided in an embodiment
  • Figure 2 is a flowchart of a three-dimensional image search method in an embodiment
  • Figure 3 is a flowchart of a three-dimensional image search method in another embodiment
  • Fig. 4 is a schematic structural diagram of a three-dimensional image search system in an embodiment
  • Figure 5 is a schematic diagram of the internal structure of a computer device in an embodiment.
  • FIG. 1 is an implementation environment diagram of a three-dimensional image search method provided in an embodiment.
  • a server 110 and a client 120 are included.
  • the server 110 may be provided with an image database, and the image database may store three-dimensional images and two-dimensional images displayed from the perspective of the three-dimensional images.
  • the server 110 may be built on a computer device or a server device.
  • a camera device may be configured on the client 120, and the client 120 may send a two-dimensional image to the server 110.
  • the client 120 may run on a smart phone, a tablet computer, a notebook computer, or a desktop computer.
  • FIG. 2 is a flowchart of a three-dimensional image search method in an embodiment.
  • a three-dimensional image search method is proposed.
  • the three-dimensional image search method can be applied to the above
  • the server 110 may specifically include the following steps:
  • Step S210 Obtain a first two-dimensional image of the search object, and calculate a first corner point of the first two-dimensional image.
  • the first corner point of the first two-dimensional image may be calculated according to the corner detection.
  • the search object may be a three-dimensional object with a three-dimensional structure, or a visible three-dimensional image with three-dimensional space coordinate information, and the search image can be collected from a perspective to obtain a two-dimensional image.
  • a three-dimensional image can be viewed from an unlimited number of multiple angles, but a group of perspectives that can fully cover the three-dimensional image can be selected reasonably, and multiple two-dimensional images corresponding to the three-dimensional image can be collected according to the group of perspectives.
  • the number of collected 2D images can be reduced appropriately.
  • the corner points have the following characteristics: they can be corner points between contours; for the same scene, even if the viewing angle changes, they usually have the characteristics of stability; the pixels in the area near the point regardless of the gradient direction There is still a big change in its gradient amplitude.
  • the corner point is an intuitive and easy-to-detect feature in the image, and it is also convenient for proper image matching.
  • the step of acquiring the first two-dimensional image of the search object in step S210 and calculating the first corner point of the first two-dimensional image may include:
  • S211 Acquire two original images of the search target through the camera device within a preset time interval.
  • the two-dimensional image of the search object can be quickly collected by the camera device, wherein the two acquired original images belong to the two-dimensional image.
  • S213 Perform corner point screening on the third corner point according to the fourth corner point to obtain the first corner point.
  • the calculated third corner point and the fourth corner point will also have similarity. Therefore, it can be based on the relationship between the corner points. Perform corner point screening to eliminate noise caused by camera capture, or eliminate the interference of corner points in the background, and improve the accuracy of the first corner point.
  • Step S220 Match the first corner point with the second corner point of the second two-dimensional image corresponding to each three-dimensional image in the image database, and determine the target two-dimensional image from the second two-dimensional image.
  • the first corner point is used for matching and searching in the image database to determine a target two-dimensional image similar to the first two-dimensional image.
  • the image database stores the second two-dimensional images corresponding to the three-dimensional images.
  • These second two-dimensional images can come from the two-dimensional images used to display the three-dimensional images in a certain angle of view, or they can be derived from the calculation of the three-dimensional images.
  • Step S230 Calculate the viewing angle difference between the first two-dimensional image and the target two-dimensional image.
  • the visual transformation feature can be used to calculate the angle of view difference between the first two-dimensional image and the target two-dimensional image based on the first corner point of the first two-dimensional image and the second corner point corresponding to the target two-dimensional image .
  • Step S240 Determine the three-dimensional image corresponding to the target two-dimensional image whose viewing angle difference is less than the first threshold as the search result.
  • the accuracy of the corner point matching is further judged, and whether the viewing angle difference is within the error range. If the viewing angle difference is within the error range, that is, the viewing angle difference is less than the first threshold, the three-dimensional image corresponding to the target two-dimensional image is determined Is a search result.
  • the above-mentioned three-dimensional image search method based on the easy-to-collect first two-dimensional image of the search object, performs image matching with the help of easily recognizable corner points in the two-dimensional image, so as to search for the three-dimensional image and use it as the search result to realize the search of the three-dimensional image .
  • two-dimensional images are easy to obtain, and the corner points as features are also easy to identify, which greatly improves the search efficiency; at the same time, considering the three-dimensional characteristics of the search object, it also improves the accuracy of the three-dimensional image search based on the judgment of the viewing angle difference.
  • corner point matching can be divided into the following four steps: 1 Extraction of detectors: Find the most easily recognizable pixels (corners) in the two images to be matched, such as the edges of objects with rich texture Wait. 2Extract descriptors: Use some mathematical features to describe the detected corner points, such as gradient histograms, local random binary features, etc. 3Matching: Judge their corresponding relationship in the two images through the descriptors of each corner point. 4Remove the outer point: remove the wrongly matched outer point and keep the correct inner point.
  • matching strategy 1 Euclidean distance measurement for the descriptor vector, the simplest strategy is to first set a threshold (maximum distance), and then return all matches in another image within the threshold range. Or, matching strategy two: do nearest neighbor matching, that is, compare the ratio of the nearest neighbor distance to the next nearest neighbor distance, that is, the nearest neighbor ratio (NNDR).
  • NDR nearest neighbor ratio
  • step S220 the first corner point is matched with the second corner point of the second two-dimensional image corresponding to each three-dimensional image in the image database, and the step of determining the target two-dimensional image from the second two-dimensional image , Can include:
  • S221 Calculate the first similarity measure between each second two-dimensional image and the first two-dimensional image according to the second corner point and the first corner point of each second two-dimensional image in the image database.
  • the step of calculating the first similarity measure value between each second two-dimensional image and the first two-dimensional image in S221 may include:
  • A1 Obtain the second corner point corresponding to the second two-dimensional image of any three-dimensional image from the image database.
  • A2 Match the first corner point and the second corner point, and extract the corner point pair at the same position.
  • the corner pairs of each group in the first two-dimensional image and the second two-dimensional image can be matched one by one.
  • A3 Calculate the first similarity measure of the second two-dimensional image according to the corner point pair.
  • the first similarity metric value can be determined based on all corner point pairs.
  • S222 Select a second two-dimensional image whose first similarity measure value is within a second preset threshold as the target two-dimensional image.
  • the second preset threshold can be used to filter similarity metric values that meet the accuracy, so as to select a second two-dimensional image that meets the second preset threshold to improve the accuracy of the target two-dimensional image.
  • the step of selecting the second two-dimensional image with the first similarity measure value within the second preset threshold as the target two-dimensional image in S222 may include:
  • the three-dimensional image can include second two-dimensional images with multiple viewing angles. Some of the viewing angles are commonly used viewing angles. It is more likely to collect the first two-dimensional image under common viewing angles. Therefore, the viewing angle can be further considered. Impact on image matching.
  • the viewing angle weight of each second two-dimensional image can be set in advance according to the commonly used degree and importance of the viewing angle.
  • B2 Calculate the second similarity measure of the second two-dimensional image according to the viewing angle weight of the second two-dimensional image and the first similarity measure of the second two-dimensional image.
  • the second similarity measure value is calculated according to the viewing angle weight and the first similarity measure value.
  • the product of the viewing angle weight and the first similarity measure value may be used as the second similarity measure value.
  • B3 Select the second two-dimensional image whose second similarity measure value is within the second preset threshold as the target two-dimensional image.
  • the second preset threshold in this step may be a similarity measure value that satisfies the accuracy after considering the viewing angle weight, so as to select an accurate target two-dimensional image.
  • the above-mentioned three-dimensional image search method uses the corner pair between the second two-dimensional image and the first two-dimensional image to calculate the similarity measurement value, which facilitates the follow-up comparison of similarity measurement values and determines the target two-dimensional image with higher accuracy .
  • the step of calculating the angle of view difference between the first two-dimensional image and the target two-dimensional image in step S230 may include:
  • S231 Establish a perspective transformation matrix according to the coordinates of the corner point pairs in the target two-dimensional image and the first two-dimensional image respectively.
  • the perspective difference between the target two-dimensional image and the first two-dimensional image can be used to represent the same position mapping relationship between the target two-dimensional image and the first two-dimensional image
  • the perspective transformation matrix can be used to represent The mapping relationship between perspectives.
  • the perspective transformation matrix can contain the perspective relationship between the target two-dimensional image and the first two-dimensional image.
  • the perspective transformation matrix can be converted to extract the parameters representing the perspective difference in the perspective transformation matrix, or according to the perspective
  • the parameters in the transformation matrix calculate the difference in viewing angle.
  • the method includes:
  • S251 Calculate the observation angle of the first two-dimensional image according to the angle of view difference and the angle of view of the target two-dimensional image in the three-dimensional image.
  • this observation angle may be the angle of view where the first two-dimensional image is actually displayed in the three-dimensional image; the target two-dimensional image is the second two-dimensional image derived from the three-dimensional image in the image database, so the target two-dimensional image
  • the viewing angle of the image in the three-dimensional image is known, and the observation angle of the first two-dimensional image can be calculated based on the viewing angle difference.
  • the three-dimensional image of the target is placed in the viewing angle for display, and the displayed effect is similar to the first two-dimensional image collected for the search object.
  • the above-mentioned three-dimensional image search method is conducive to searching in the same or similar perspective. Contrast observation between the object and the target three-dimensional image.
  • the target 3D images can also be sorted according to the perspective weight of each target 2D image, and the target 3D image with a higher perspective priority is given priority to display, that is, the target 3D image with a higher priority is displayed first.
  • the downloaded 3D image is convenient for the user to quickly understand the shape of the displayed target 3D image according to the common viewing angle, and it is easy for the user to switch from the common viewing angle to the first two-dimensional image, improving readability.
  • FIG. 3 is a flowchart of a three-dimensional image search method in another embodiment.
  • a three-dimensional image search method is provided, which may specifically include the following steps:
  • S310 Acquire a first two-dimensional image of the search object, and calculate a first corner point of the first two-dimensional image.
  • S320 Match the first corner point with the second corner point of the second two-dimensional image corresponding to each three-dimensional image in the image database, and determine the target two-dimensional image from the second two-dimensional image.
  • a first similarity measure value between each second two-dimensional image and the first two-dimensional image is calculated.
  • a second two-dimensional image whose first similarity measure value is within a second preset threshold is selected as the target two-dimensional image.
  • the second two-dimensional image whose second similarity measure value is within the second preset threshold is selected as the target two-dimensional image.
  • S330 Calculate the viewing angle difference between the first two-dimensional image and the target two-dimensional image.
  • the perspective transformation matrix is established according to the coordinates of the corner point pairs in the target two-dimensional image and the first two-dimensional image; the perspective difference is calculated according to the perspective transformation matrix.
  • S340 Determine a three-dimensional image corresponding to the target two-dimensional image whose viewing angle difference is less than the first threshold as the search result.
  • S350 Calculate the observation angle of the first two-dimensional image according to the angle of view difference and the angle of view of the target two-dimensional image in the three-dimensional image, and display the target three-dimensional image at the observation angle.
  • the above-mentioned three-dimensional image search method uses the easily recognizable corner points in the two-dimensional image to match the image, so as to search for the three-dimensional image and use it as the search result to realize the search of the three-dimensional image .
  • two-dimensional images are easy to obtain, and the corner points as features are also easy to identify, which greatly improves the search efficiency; at the same time, considering the three-dimensional characteristics of the search object, it also improves the accuracy of the three-dimensional image search based on the judgment of the viewing angle difference.
  • FIG. 4 is a schematic structural diagram of a three-dimensional image search system in an embodiment.
  • a three-dimensional image search system which includes a corner point calculation module 410 and two-dimensional image matching.
  • Module 420, angle difference calculation module 430 and 3D image acquisition module 440 wherein:
  • the corner point calculation module 410 is configured to obtain the first two-dimensional image of the search object, and calculate the first corner point of the first two-dimensional image.
  • the corner point calculation module 410 may calculate the first corner point of the first two-dimensional image according to corner point detection in the process of searching for the search object according to the first two-dimensional image.
  • the search object may be a three-dimensional object with a three-dimensional structure, or a visible three-dimensional image with three-dimensional space coordinate information, and the search image can be collected from a perspective to obtain a two-dimensional image.
  • the corner point has the following characteristics: it can be the corner point between the contours; for the same scene, even if the viewing angle changes, it usually has the characteristics of stability; the pixels in the area near the point are either in the gradient direction or There is a big change in the gradient amplitude.
  • the corner point is an intuitive and easy-to-detect feature in the image, and it is also convenient for proper image matching.
  • the two-dimensional image matching module 420 is configured to match the first corner point with the second corner point of the second two-dimensional image corresponding to each three-dimensional image in the image database, and determine the target two-dimensional image from the second two-dimensional image.
  • the two-dimensional image matching module 420 performs matching and searching in the image database based on the first corner point, and determines a target two-dimensional image similar to the first two-dimensional image.
  • the image database stores the second two-dimensional images corresponding to the three-dimensional images.
  • These second two-dimensional images can come from the two-dimensional images used to display the three-dimensional images in a certain angle of view, or they can be derived from the calculation of the three-dimensional images.
  • the viewing angle difference calculation module 430 is configured to calculate the viewing angle difference between the first two-dimensional image and the target two-dimensional image.
  • the viewing angle difference calculation module 430 can use the characteristics of visual transformation to calculate the viewing angle between the first two-dimensional image and the target two-dimensional image according to the first corner point of the first two-dimensional image and the second corner point corresponding to the target two-dimensional image. difference.
  • the three-dimensional image acquisition module 440 is configured to determine the three-dimensional image corresponding to the target two-dimensional image whose angle of view difference is less than the first threshold value as the search result.
  • the three-dimensional image acquisition module 440 detects whether the angle of view difference is within the error range. If the angle of view difference is within the error range, that is, the angle of view difference is less than the first threshold, the three-dimensional image corresponding to the target two-dimensional image Determined as a search result.
  • the above-mentioned three-dimensional image search system uses the easily recognizable corner points in the two-dimensional image to perform image matching, so as to search for the three-dimensional image and use it as the search result to realize the search of the three-dimensional image .
  • two-dimensional images are easy to obtain, and the corner points as features are also easy to identify, which greatly improves the search efficiency; at the same time, considering the three-dimensional characteristics of the search object, it also improves the accuracy of the three-dimensional image search based on the judgment of the viewing angle difference.
  • Each module in the above-mentioned three-dimensional image search system can be implemented in whole or in part by software, hardware, and a combination thereof.
  • the foregoing modules may be embedded in the form of hardware or independent of the processor in the computer device, or may be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the foregoing modules.
  • FIG. 5 is a schematic diagram of the internal structure of a computer device in an embodiment.
  • the computer device includes a processor, a nonvolatile storage medium, a memory, and a network interface connected through a system bus.
  • the non-volatile storage medium of the computer device stores an operating system, a database, and a computer program.
  • the processor can enable the processor to implement a three-dimensional image search method.
  • the processor of the computer equipment is used to provide calculation and control capabilities, and supports the operation of the entire computer equipment.
  • a computer program can be stored in the memory of the computer device, and when the computer program is executed by the processor, the processor can execute a three-dimensional image search method.
  • the network interface of the computer device is used to connect and communicate with the terminal.
  • FIG. 5 is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied.
  • the specific computer device may Including more or fewer parts than shown in the figure, or combining some parts, or having a different arrangement of parts.
  • a computer device which includes a memory, a processor, and a computer program stored in the memory and capable of running on the processor.
  • the processor implements the three-dimensional system in any of the above-mentioned embodiments when the computer program is executed.
  • the steps of the image search method include: acquiring a first two-dimensional image of the search object, calculating a first corner point of the first two-dimensional image; and combining the first corner point with Match the second corner points of the second two-dimensional image corresponding to each three-dimensional image in the image database, determine the target two-dimensional image from the second two-dimensional image; calculate the first two-dimensional image and the target two-dimensional The viewing angle difference between the images; the three-dimensional image corresponding to the target two-dimensional image whose viewing angle difference is less than the first threshold is determined as the search result.
  • a storage medium storing computer-readable instructions is proposed.
  • the storage medium of the computer-readable instructions may be non-volatile or volatile.
  • a computer program is stored thereon.
  • the steps of the three-dimensional image search method include: acquiring a first two-dimensional image of the search object, and calculating the first two-dimensional image Match the first corner point with the second corner point of the second two-dimensional image corresponding to each three-dimensional image in the image database, and determine the target two-dimensional image from the second two-dimensional image; Calculating the viewing angle difference between the first two-dimensional image and the target two-dimensional image; determining the three-dimensional image corresponding to the target two-dimensional image whose viewing angle difference is less than the first threshold value as the search result.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Library & Information Science (AREA)
  • Image Analysis (AREA)
  • Processing Or Creating Images (AREA)

Abstract

A three-dimensional image search method and system, relating to the technical field of image matching. The method comprises: obtaining a first two-dimensional image of a search object, and calculating a first corner point of the first two-dimensional image (S210); matching the first corner point with a second corner point of a second two-dimensional image corresponding to each three-dimensional image in an image database, and determining a target two-dimensional image from the second two-dimensional images (S220); calculating a viewing angle difference between the first two-dimensional image and the target two-dimensional image (S230); and determining the three-dimensional image corresponding to the target two-dimensional image having the viewing angle difference less than a first threshold value to be a search result (S240). By means of the foregoing three-dimensional image search method, according to the easily acquired first two-dimensional image of the search object, image matching is performed by means of an easy-to-recognize corner point in the two-dimensional image, thereby finding the three-dimensional image and using as the search result, and realizing the search of the three-dimensional image. Moreover, the two-dimensional image in the method is easily obtained, and the corner point serving as a feature is also easily recognized, thereby greatly improving the efficiency of search.

Description

三维图像搜索方法、系统、计算机设备和存储介质Three-dimensional image search method, system, computer equipment and storage medium
本申请要求于2019年07月19日提交中国专利局、申请号为201910656211.3,发明名称为“三维图像搜索方法、系统、计算机设备和存储介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。This application claims the priority of a Chinese patent application filed with the Chinese Patent Office on July 19, 2019, the application number is 201910656211.3, and the invention title is "3D image search method, system, computer equipment and storage medium", the entire content of which is incorporated by reference Incorporated in this application.
技术领域Technical field
本申请涉及图像匹配技术领域,具体而言,本申请涉及一种三维图像搜索方法、三维图像搜索系统、计算机设备和存储介质。This application relates to the technical field of image matching. Specifically, this application relates to a three-dimensional image search method, a three-dimensional image search system, a computer device, and a storage medium.
背景技术Background technique
三维图像,又被称为立体图像、深度图像、三维数字化模型,三维图像包含了真实对象表面的三维坐标和灰度的完整信息,记录着物体表面每个采样点的三维空间坐标。三维图像与传统的平面图像有很大的区别。传统的平面图像可以看作是二维空间中的亮度分布,平面图像是由真实三维世界在二维图像平面上投影而得到的。Three-dimensional images are also called stereo images, depth images, and three-dimensional digital models. Three-dimensional images contain the complete information of the three-dimensional coordinates and gray levels of the real object surface, and record the three-dimensional space coordinates of each sampling point on the surface of the object. Three-dimensional images are very different from traditional planar images. The traditional plane image can be regarded as the brightness distribution in the two-dimensional space, and the plane image is obtained by projecting the real three-dimensional world on the two-dimensional image plane.
三维图像所携带的信息较多,可以用于立体地和全方位地展示产品的形状和构造。随着科技的进步以及商业的发展,用于对产品进行展示的三维图像正广泛应用,难免增长了对三维图像搜索来查找相应的产品的需求。Three-dimensional images carry more information and can be used to display the shape and structure of the product in a three-dimensional and omni-directional manner. With the advancement of science and technology and the development of commerce, three-dimensional images used to display products are widely used, and it is inevitable that the demand for three-dimensional image search to find corresponding products has increased.
发明人意识到三维图像所携带的信息较多,虽然可以通过观察三维图像感知三维图像的立体感,但通过相机等图像采集装置却只能采集和记录三维图像在某个视角下的二维图像,因此一般是无法直接获得三维图像所描述的三维空间坐标,难以通过采集三维图像对该三维图像进行搜索。The inventor realizes that three-dimensional images carry more information. Although the three-dimensional image can be perceived by observing the three-dimensional image, the image acquisition device such as a camera can only collect and record the two-dimensional image of the three-dimensional image at a certain angle of view. Therefore, it is generally impossible to directly obtain the three-dimensional space coordinates described by the three-dimensional image, and it is difficult to search the three-dimensional image by collecting the three-dimensional image.
因此,存在无法通过图像采集装置采集三维图像进行三维图像搜索的问题。Therefore, there is a problem that the three-dimensional image cannot be captured by the image capturing device for three-dimensional image search.
发明内容Summary of the invention
本申请的目的旨在至少能解决上述的技术缺陷之一,特别是无法通过图像采集装置采集三维图像进行三维图像搜索的技术缺陷。The purpose of this application is to at least solve one of the above-mentioned technical defects, especially the technical defect that the image acquisition device cannot collect 3D images for 3D image search.
本申请提供一种三维图像搜索方法,包括如下步骤:获取搜索对象的第一二维图像,计算所述第一二维图像的第一角点;将所述第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从所述第二二维图像中确定目标二维图像;计算所述第一二维图像与所述目标二维图像之间的视角差;将视角差小于第一阈值的目标二维图像所对应的三维图像确定为搜索结果。This application provides a three-dimensional image search method, including the following steps: acquiring a first two-dimensional image of a search object, calculating a first corner point of the first two-dimensional image; comparing the first corner point with each of the image database Match the second corner points of the second two-dimensional image corresponding to the three-dimensional image, determine the target two-dimensional image from the second two-dimensional image; calculate the difference between the first two-dimensional image and the target two-dimensional image The viewing angle difference; the three-dimensional image corresponding to the target two-dimensional image whose viewing angle difference is less than the first threshold is determined as the search result.
本申请还提供一种三维图像搜索系统,包括:角点计算模块,用于获取搜索对象的第一二维图像,计算所述第一二维图像的第一角点;二维图像匹配模块,用于将所述第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从所述第二二维图像中确定目标二维图像;视角差计算模块,用于计算所述第一二维图像与所述目标二维图像之间的视角差;三维图像获取模块,用于将视角差小于第一阈值的目标二维图像所对应的三维图像确定为搜索结果。This application also provides a three-dimensional image search system, including: a corner point calculation module, configured to obtain a first two-dimensional image of the search object, and calculate the first corner point of the first two-dimensional image; a two-dimensional image matching module, Used to match the first corner point with the second corner point of the second two-dimensional image corresponding to each three-dimensional image in the image database, and determine a target two-dimensional image from the second two-dimensional image; a viewing angle difference calculation module , Used to calculate the viewing angle difference between the first two-dimensional image and the target two-dimensional image; a three-dimensional image acquisition module, used to determine the three-dimensional image corresponding to the target two-dimensional image with the viewing angle difference less than the first threshold as search results.
本申请还提供一种计算机设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现一种三维图像搜索方法的步骤,其中,所述三维图像搜索方法的步骤包括:获取搜索对象的第一二维图像,计算所述第一二维图像的第一角点;将所述第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从所述第二二维图像中确定目标二维图像;计算所述第一二维图像与所述目标二维图像之间的视角差;将视角差小于第一阈值的目标二维图像所对应的三维图像确定为搜索结果。The present application also provides a computer device, including a memory, a processor, and a computer program stored in the memory and running on the processor, and the processor implements the steps of a three-dimensional image search method when the computer program is executed, Wherein, the steps of the three-dimensional image search method include: acquiring a first two-dimensional image of a search object, calculating a first corner point of the first two-dimensional image; comparing the first corner point with each three-dimensional image in the image database The second corner points of the corresponding second two-dimensional image are matched, and the target two-dimensional image is determined from the second two-dimensional image; the viewing angle difference between the first two-dimensional image and the target two-dimensional image is calculated ; Determine the three-dimensional image corresponding to the target two-dimensional image whose angle of view difference is less than the first threshold as the search result.
本申请还提供一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现一种三维图像搜索方法的步骤,所述三维图像搜索方法的步骤包括:获取搜索对象的第一二维图像,计算所述第一二维图像的第一角点;将所述第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从所述第二二维图像中确定目标 二维图像;计算所述第一二维图像与所述目标二维图像之间的视角差;将视角差小于第一阈值的目标二维图像所对应的三维图像确定为搜索结果。The present application also provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the steps of a three-dimensional image search method are realized. The steps of the three-dimensional image search method include: obtaining search Calculate the first corner of the first two-dimensional image of the object; match the first corner with the second corner of the second two-dimensional image corresponding to each three-dimensional image in the image database , Determine the target two-dimensional image from the second two-dimensional image; calculate the angle of view difference between the first two-dimensional image and the target two-dimensional image; determine the target two-dimensional image whose angle of view difference is less than the first threshold The corresponding three-dimensional image is determined as the search result.
上述的三维图像搜索方法、系统、计算机设备和存储介质,根据容易采集的搜索对象的第一二维图像,借助二维图像中易于识别的角点,进行图像的匹配,从而搜索出三维图像并作为搜索结果,实现三维图像的搜索。而且,该方法中二维图像容易获得,且作为特征的角点也易于识别,大大提高了搜索的效率;同时考虑搜索对象的三维特性,还根据视角差的判断提高三维图像搜索的准确性。The above-mentioned three-dimensional image search method, system, computer equipment and storage medium, according to the easy-to-collect first two-dimensional image of the search object, use the easily recognizable corner points in the two-dimensional image to perform image matching, thereby searching for the three-dimensional image and As a result of the search, a three-dimensional image search is realized. Moreover, in this method, two-dimensional images are easy to obtain, and the corner points as features are also easy to identify, which greatly improves the search efficiency; at the same time, considering the three-dimensional characteristics of the search object, it also improves the accuracy of the three-dimensional image search based on the judgment of the viewing angle difference.
附图说明Description of the drawings
图1为一个实施例中提供的三维图像搜索方法的实施环境图;Fig. 1 is an implementation environment diagram of a three-dimensional image search method provided in an embodiment;
图2为一个实施例中三维图像搜索方法的流程图;Figure 2 is a flowchart of a three-dimensional image search method in an embodiment;
图3为另一个实施例中三维图像搜索方法的流程图;Figure 3 is a flowchart of a three-dimensional image search method in another embodiment;
图4为一个实施例中三维图像搜索系统的结构示意图;Fig. 4 is a schematic structural diagram of a three-dimensional image search system in an embodiment;
图5为一个实施例中计算机设备的内部结构示意图。Figure 5 is a schematic diagram of the internal structure of a computer device in an embodiment.
具体实施方式Detailed ways
下面详细描述本申请的实施例,所述实施例的示例在附图中示出,其中自始至终相同或类似的标号表示相同或类似的元件或具有相同或类似功能的元件。下面通过参考附图描述的实施例是示例性的,仅用于解释本申请,而不能解释为对本申请的限制。The embodiments of the present application are described in detail below. Examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals indicate the same or similar elements or elements with the same or similar functions. The embodiments described below with reference to the drawings are exemplary, and are only used to explain the present application, and cannot be construed as a limitation to the present application.
本技术领域技术人员可以理解,除非特意声明,这里使用的单数形式“一”、“一个”、“所述”和“该”也可包括复数形式。应该进一步理解的是,本申请的说明书中使用的措辞“包括”是指存在所述特征、整数、步骤、操作、元件和/或组件,但是并不排除存在或添加一个或多个其他特征、整数、步骤、操作、元件、组件和/或它们的组。应该理解,当我们称元件被“连接”或“耦接”到另一元件时,它可以直接连接或耦接到其他元件,或者也可以存在中间元件。此外,这里使用的“连接”或“耦接”可以包括无线 连接或无线耦接。这里使用的措辞“和/或”包括一个或更多个相关联的列出项的全部或任一单元和全部组合。Those skilled in the art can understand that, unless specifically stated, the singular forms "a", "an", "said" and "the" used herein may also include plural forms. It should be further understood that the term "comprising" used in the specification of this application refers to the presence of the described features, integers, steps, operations, elements, and/or components, but does not exclude the presence or addition of one or more other features, Integers, steps, operations, elements, components, and/or groups thereof. It should be understood that when we refer to an element as being "connected" or "coupled" to another element, it can be directly connected or coupled to the other element, or intervening elements may also be present. In addition, "connected" or "coupled" as used herein may include wireless connection or wireless coupling. The term "and/or" as used herein includes all or any unit and all combinations of one or more associated listed items.
如图1所示,图1为一个实施例中提供的三维图像搜索方法的实施环境图,在该实施环境中,包括服务端110以及客户端120。As shown in FIG. 1, FIG. 1 is an implementation environment diagram of a three-dimensional image search method provided in an embodiment. In the implementation environment, a server 110 and a client 120 are included.
服务端110上可以设置有图像数据库,图像数据库中可以存储三维图像以及三维图像在视角下所展现出的二维图像,服务端110可以在计算机设备或服务器设备上搭建。客户端120上可以配置有摄像装置,客户端120可以向服务端110发送二维图像。客户端120可运行在智能手机、平板电脑、笔记本电脑、台式计算机上。The server 110 may be provided with an image database, and the image database may store three-dimensional images and two-dimensional images displayed from the perspective of the three-dimensional images. The server 110 may be built on a computer device or a server device. A camera device may be configured on the client 120, and the client 120 may send a two-dimensional image to the server 110. The client 120 may run on a smart phone, a tablet computer, a notebook computer, or a desktop computer.
在一个实施例中,如图2所示,图2为一个实施例中三维图像搜索方法的流程图,本实施例中提出了一种三维图像搜索方法,该三维图像搜索方法可以应用于上述的服务端110中,具体可以包括以下步骤:In an embodiment, as shown in FIG. 2, FIG. 2 is a flowchart of a three-dimensional image search method in an embodiment. In this embodiment, a three-dimensional image search method is proposed. The three-dimensional image search method can be applied to the above The server 110 may specifically include the following steps:
步骤S210:获取搜索对象的第一二维图像,计算第一二维图像的第一角点。Step S210: Obtain a first two-dimensional image of the search object, and calculate a first corner point of the first two-dimensional image.
本步骤中,在根据第一二维图像对搜索对象进行搜索的过程中,可以根据角点检测来计算第一二维图像的第一角点。In this step, in the process of searching for the search object according to the first two-dimensional image, the first corner point of the first two-dimensional image may be calculated according to the corner detection.
其中,搜索对象可以是立体的具有三维结构的物体,也可以是具有三维空间坐标信息的可视的三维图像,搜索图像能够在视角上被采集后得到二维图像。三维图像可以被观察多角度有无限个,但是可以合理选择能够全面覆盖三维图像的一组视角,根据该组视角采集三维图像对应的多个二维图像。另外,对于一些具有对称性质的三维图像,可以适量减少采集的二维图像的数量。Wherein, the search object may be a three-dimensional object with a three-dimensional structure, or a visible three-dimensional image with three-dimensional space coordinate information, and the search image can be collected from a perspective to obtain a two-dimensional image. A three-dimensional image can be viewed from an unlimited number of multiple angles, but a group of perspectives that can fully cover the three-dimensional image can be selected reasonably, and multiple two-dimensional images corresponding to the three-dimensional image can be collected according to the group of perspectives. In addition, for some symmetrical 3D images, the number of collected 2D images can be reduced appropriately.
其中,直观地概况下,角点具有以下的特征:可以是轮廓之间的角点;对于同一场景,即使视角发生变化,通常具备稳定性质的特征;该点附近区域的像素点无论在梯度方向上还是其梯度幅值上有着较大变化。角点是图像中直观和易于检测的特征,也便于进行合适的图像匹配。Among them, under an intuitive overview, the corner points have the following characteristics: they can be corner points between contours; for the same scene, even if the viewing angle changes, they usually have the characteristics of stability; the pixels in the area near the point regardless of the gradient direction There is still a big change in its gradient amplitude. The corner point is an intuitive and easy-to-detect feature in the image, and it is also convenient for proper image matching.
具体地,步骤S210中获取搜索对象的第一二维图像,计算第一二维图像的第一角点的步骤,可以包括:Specifically, the step of acquiring the first two-dimensional image of the search object in step S210 and calculating the first corner point of the first two-dimensional image may include:
S211:在预设时间间隔内通过摄像设备获取搜索对象的两张原始图 像。S211: Acquire two original images of the search target through the camera device within a preset time interval.
本步骤中,通过摄像设备可以快速采集搜索对象的二维图像,其中所获取的两张原始图像属于二维图像。In this step, the two-dimensional image of the search object can be quickly collected by the camera device, wherein the two acquired original images belong to the two-dimensional image.
S212:分别计算原始图像对应的第三角点和第四角点。S212: Calculate the third corner point and the fourth corner point corresponding to the original image respectively.
S213:根据第四角点对第三角点进行角点筛选,获得第一角点。S213: Perform corner point screening on the third corner point according to the fourth corner point to obtain the first corner point.
上述计算第一角点的方式中,由于两张原始图像之间具有一定的相似性,所计算的第三角点和第四角点之间也会存在相似性,因此可以根据角点之间关系进行角点筛选,排除因摄像采集造成的噪点,或者可以排除背景中存在的角点的干扰,提高第一角点的准确性。In the above method of calculating the first corner point, since the two original images have a certain similarity, the calculated third corner point and the fourth corner point will also have similarity. Therefore, it can be based on the relationship between the corner points. Perform corner point screening to eliminate noise caused by camera capture, or eliminate the interference of corner points in the background, and improve the accuracy of the first corner point.
步骤S220:将第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从第二二维图像中确定目标二维图像。Step S220: Match the first corner point with the second corner point of the second two-dimensional image corresponding to each three-dimensional image in the image database, and determine the target two-dimensional image from the second two-dimensional image.
本步骤中,依靠第一角点在图像数据库中进行匹配和查找,确定与第一二维图像相似的目标二维图像。In this step, the first corner point is used for matching and searching in the image database to determine a target two-dimensional image similar to the first two-dimensional image.
其中,图像数据库中存储着三维图像对应的第二二维图像,这些第二二维图像可以来自于用于展示三维图像在某视角下的二维图像,也可以是来自于对三维图像特意计算某视角下的二维图像。由于三维图像具有立体的三维特性,所携带的信息较多,一般单个视角下的二维图像只能够局部地展示三维图像,一般在图像数据库中的三维图像可以对应存储有多个视角下的第二二维图像。Among them, the image database stores the second two-dimensional images corresponding to the three-dimensional images. These second two-dimensional images can come from the two-dimensional images used to display the three-dimensional images in a certain angle of view, or they can be derived from the calculation of the three-dimensional images. A two-dimensional image at a certain angle of view. Since 3D images have stereoscopic 3D characteristics, they carry more information. Generally, 2D images under a single view can only partially display 3D images. Generally, 3D images in an image database can be stored corresponding to the first view from multiple views. Two-dimensional image.
步骤S230:计算第一二维图像与目标二维图像之间的视角差。Step S230: Calculate the viewing angle difference between the first two-dimensional image and the target two-dimensional image.
本步骤中,可以借助视觉变换的特点,根据第一二维图像的第一角点和目标二维图像对应的第二角点可以计算第一二维图像与目标二维图像之间的视角差。In this step, the visual transformation feature can be used to calculate the angle of view difference between the first two-dimensional image and the target two-dimensional image based on the first corner point of the first two-dimensional image and the second corner point corresponding to the target two-dimensional image .
步骤S240:将视角差小于第一阈值的目标二维图像所对应的三维图像确定为搜索结果。Step S240: Determine the three-dimensional image corresponding to the target two-dimensional image whose viewing angle difference is less than the first threshold as the search result.
本步骤中,进一步判断角点匹配的准确性,检测视角差是否在误差范围内,若视角差在误差范围内,即视角差小于第一阈值,则将目标二维图像所对应的三维图像确定为搜索结果。In this step, the accuracy of the corner point matching is further judged, and whether the viewing angle difference is within the error range. If the viewing angle difference is within the error range, that is, the viewing angle difference is less than the first threshold, the three-dimensional image corresponding to the target two-dimensional image is determined Is a search result.
上述三维图像搜索方法,根据容易采集的搜索对象的第一二维图像, 借助二维图像中易于识别的角点,进行图像的匹配,从而搜索出三维图像并作为搜索结果,实现三维图像的搜索。而且,该方法中二维图像容易获得,且作为特征的角点也易于识别,大大提高了搜索的效率;同时考虑搜索对象的三维特性,还根据视角差的判断提高三维图像搜索的准确性。The above-mentioned three-dimensional image search method, based on the easy-to-collect first two-dimensional image of the search object, performs image matching with the help of easily recognizable corner points in the two-dimensional image, so as to search for the three-dimensional image and use it as the search result to realize the search of the three-dimensional image . Moreover, in this method, two-dimensional images are easy to obtain, and the corner points as features are also easy to identify, which greatly improves the search efficiency; at the same time, considering the three-dimensional characteristics of the search object, it also improves the accuracy of the three-dimensional image search based on the judgment of the viewing angle difference.
在其中一个实施例中,角点匹配可以分为以下四个步骤:①提取检测子:在两张待匹配的图像中寻找那些最容易识别的像素点(角点),比如纹理丰富的物体边缘点等。②提取描述子:对于检测出的角点,用一些数学上的特征对其进行描述,如梯度直方图,局部随机二值特征等。③匹配:通过各个角点的描述子来判断它们在两张图像中的对应关系。④去外点:去除错误匹配的外点,保留正确的内点。其中,匹配策略一:对描述子向量做欧式距离度量,最简单的一个策略就是先设定一个阈值(最大距离),然后返回在这个阈值范围之内的另外一个图像中的所有匹配。或者,匹配策略二:做最近邻匹配,即比较最近邻距离和次近邻距离的比值,即最近邻比率(NNDR)。In one of the embodiments, corner point matching can be divided into the following four steps: ① Extraction of detectors: Find the most easily recognizable pixels (corners) in the two images to be matched, such as the edges of objects with rich texture Wait. ②Extract descriptors: Use some mathematical features to describe the detected corner points, such as gradient histograms, local random binary features, etc. ③Matching: Judge their corresponding relationship in the two images through the descriptors of each corner point. ④Remove the outer point: remove the wrongly matched outer point and keep the correct inner point. Among them, matching strategy 1: Euclidean distance measurement for the descriptor vector, the simplest strategy is to first set a threshold (maximum distance), and then return all matches in another image within the threshold range. Or, matching strategy two: do nearest neighbor matching, that is, compare the ratio of the nearest neighbor distance to the next nearest neighbor distance, that is, the nearest neighbor ratio (NNDR).
在一个实施例中,步骤S220中将第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从第二二维图像中确定目标二维图像的步骤,可以包括:In one embodiment, in step S220, the first corner point is matched with the second corner point of the second two-dimensional image corresponding to each three-dimensional image in the image database, and the step of determining the target two-dimensional image from the second two-dimensional image , Can include:
S221:根据图像数据库中各个第二二维图像的第二角点和第一角点,计算各第二二维图像与第一二维图像之间的第一相似度量值。S221: Calculate the first similarity measure between each second two-dimensional image and the first two-dimensional image according to the second corner point and the first corner point of each second two-dimensional image in the image database.
本步骤中,第二角点和第一角点之间的可以匹配的角点越多且相似性越高,则第一相似度量值越高,对应的第二二维图像与第一二维图像之间的相似度越高。In this step, the more matching corner points and the higher the similarity between the second corner point and the first corner point, the higher the first similarity measure value, and the corresponding second two-dimensional image and the first two-dimensional The higher the similarity between the images.
具体地,S221中计算各第二二维图像与第一二维图像之间的第一相似度量值的步骤,可以包括:Specifically, the step of calculating the first similarity measure value between each second two-dimensional image and the first two-dimensional image in S221 may include:
A1:从图像数据库中获取任意一个三维图像的第二二维图像对应的第二角点。A1: Obtain the second corner point corresponding to the second two-dimensional image of any three-dimensional image from the image database.
A2:将第一角点和该第二角点进行匹配,提取相同位置的角点对。A2: Match the first corner point and the second corner point, and extract the corner point pair at the same position.
本步骤中,可以一一匹配出第一二维图像与第二二维图像中各组的角点对。In this step, the corner pairs of each group in the first two-dimensional image and the second two-dimensional image can be matched one by one.
A3:根据角点对计算该第二二维图像的第一相似度量值。A3: Calculate the first similarity measure of the second two-dimensional image according to the corner point pair.
本步骤中,可以根据所有的角点对确定第一相似度量值。In this step, the first similarity metric value can be determined based on all corner point pairs.
S222:选取第一相似度量值在第二预设阈值内的第二二维图像作为目标二维图像。S222: Select a second two-dimensional image whose first similarity measure value is within a second preset threshold as the target two-dimensional image.
本步骤中,第二预设阈值可以用于筛选满足精度的相似度量值,以便于选取符合第二预设阈值的第二二维图像,提高目标二维图像的准确性。In this step, the second preset threshold can be used to filter similarity metric values that meet the accuracy, so as to select a second two-dimensional image that meets the second preset threshold to improve the accuracy of the target two-dimensional image.
具体地,S222中选取第一相似度量值在第二预设阈值内的第二二维图像作为目标二维图像的步骤,可以包括:Specifically, the step of selecting the second two-dimensional image with the first similarity measure value within the second preset threshold as the target two-dimensional image in S222 may include:
B1:获取各第二二维图像对应在三维图像中的视角权重。B1: Obtain the viewing angle weight corresponding to each second two-dimensional image in the three-dimensional image.
本步骤中,三维图像可以包含多个视角的第二二维图像,其中某些视角是常用观察视角,在常用观察视角下采集第一二维图像的可能性较大,因此还可以进一步考虑视角对图像匹配的影响。另外可以预先按照视角的常用程度和重要性设置各个第二二维图像的视角权重。In this step, the three-dimensional image can include second two-dimensional images with multiple viewing angles. Some of the viewing angles are commonly used viewing angles. It is more likely to collect the first two-dimensional image under common viewing angles. Therefore, the viewing angle can be further considered. Impact on image matching. In addition, the viewing angle weight of each second two-dimensional image can be set in advance according to the commonly used degree and importance of the viewing angle.
B2:根据第二二维图像的视角权重和第二二维图像的第一相似度量值计算第二二维图像的第二相似度量值。B2: Calculate the second similarity measure of the second two-dimensional image according to the viewing angle weight of the second two-dimensional image and the first similarity measure of the second two-dimensional image.
本步骤中,考虑视角对图像匹配的影响,根据视角权重和第一相似度量值计算第二相似度量值。例如,可以将视角权重与第一相似度量值的乘积作为第二相似度量值。In this step, considering the influence of the viewing angle on the image matching, the second similarity measure value is calculated according to the viewing angle weight and the first similarity measure value. For example, the product of the viewing angle weight and the first similarity measure value may be used as the second similarity measure value.
B3:选取第二相似度量值在第二预设阈值内的第二二维图像作为目标二维图像。B3: Select the second two-dimensional image whose second similarity measure value is within the second preset threshold as the target two-dimensional image.
本步骤中,此步骤中第二预设阈值可以是考虑了视角权重后筛选满足精度的相似度量值,以便于选取准确的目标二维图像。In this step, the second preset threshold in this step may be a similarity measure value that satisfies the accuracy after considering the viewing angle weight, so as to select an accurate target two-dimensional image.
上述三维图像搜索方法,通过第二二维图像与第一二维图像之间角点对进行相似度量值的计算,便于后续跟进相似度量值的比较,确定准确度更高的目标二维图像。The above-mentioned three-dimensional image search method uses the corner pair between the second two-dimensional image and the first two-dimensional image to calculate the similarity measurement value, which facilitates the follow-up comparison of similarity measurement values and determines the target two-dimensional image with higher accuracy .
在一个实施例中,步骤S230中计算第一二维图像与目标二维图像之间的视角差的步骤,可以包括:In an embodiment, the step of calculating the angle of view difference between the first two-dimensional image and the target two-dimensional image in step S230 may include:
S231:根据角点对分别在目标二维图像和第一二维图像中的坐标建立透视变换矩阵。S231: Establish a perspective transformation matrix according to the coordinates of the corner point pairs in the target two-dimensional image and the first two-dimensional image respectively.
本步骤中,目标二维图像和第一二维图像之间视角差异,透视变换矩阵可以用于表示目标二维图像和第一二维图像中相同位置映射关系,透视变换矩阵以可以用于表示视角之间变换的映射关系。In this step, the perspective difference between the target two-dimensional image and the first two-dimensional image, the perspective transformation matrix can be used to represent the same position mapping relationship between the target two-dimensional image and the first two-dimensional image, and the perspective transformation matrix can be used to represent The mapping relationship between perspectives.
S232:根据透视变换矩阵计算视角差。S232: Calculate the viewing angle difference according to the perspective transformation matrix.
上述三维图像搜索方法,透视变换矩阵可以蕴藏着目标二维图像和第一二维图像之间视角的关联关系,可以通过换算透视变换矩阵,提取透视变换矩阵中代表视角差的参数,或者根据透视变换矩阵中的参数推算视角差。In the above-mentioned three-dimensional image search method, the perspective transformation matrix can contain the perspective relationship between the target two-dimensional image and the first two-dimensional image. The perspective transformation matrix can be converted to extract the parameters representing the perspective difference in the perspective transformation matrix, or according to the perspective The parameters in the transformation matrix calculate the difference in viewing angle.
在一个实施例中,在步骤S240中将视角差小于第一阈值的目标二维图像所对应的三维图像确定为搜索结果的步骤之后,包括:In one embodiment, after the step S240 of determining the three-dimensional image corresponding to the target two-dimensional image whose angle of view difference is less than the first threshold as the search result, the method includes:
S251:根据视角差和目标二维图像在三维图像中视角,计算第一二维图像的观察视角。S251: Calculate the observation angle of the first two-dimensional image according to the angle of view difference and the angle of view of the target two-dimensional image in the three-dimensional image.
本步骤中,这个观察视角可以是第一二维图像实际在三维图像中展示时所处于的视角;其中目标二维图像是来源于图像数据库中三维图像的第二二维图像,因此目标二维图像在三维图像中所处的视角是可知的,再根据视角差可以推算第一二维图像的观察视角。In this step, this observation angle may be the angle of view where the first two-dimensional image is actually displayed in the three-dimensional image; the target two-dimensional image is the second two-dimensional image derived from the three-dimensional image in the image database, so the target two-dimensional image The viewing angle of the image in the three-dimensional image is known, and the observation angle of the first two-dimensional image can be calculated based on the viewing angle difference.
S252:在观察视角展示目标三维图像。S252: Display a three-dimensional image of the target at the observation perspective.
本步骤中,将目标三维图像放置在该观察视角中进行展示,所展示的效果与对搜索对象所采集的第一二维图像相似,上述三维图像搜索方法,利于在相同视角或相近视角对搜索对象与目标三维图像之间进行对比观察。In this step, the three-dimensional image of the target is placed in the viewing angle for display, and the displayed effect is similar to the first two-dimensional image collected for the search object. The above-mentioned three-dimensional image search method is conducive to searching in the same or similar perspective. Contrast observation between the object and the target three-dimensional image.
另外,对于目标三维图像可以包括多个时,还可以根据各个目标二维图像的视角权重对目标三维图像进行排序,优先显示对应视角优先级较高的目标三维图像,即优先显示处于易于观察角度下的三维图像,便于用户根据常见视角下快速读懂展示的目标三维图像的形状,以及易于用户常见视角转换至第一二维图像的视角,提高可读性。In addition, when multiple target 3D images can be included, the target 3D images can also be sorted according to the perspective weight of each target 2D image, and the target 3D image with a higher perspective priority is given priority to display, that is, the target 3D image with a higher priority is displayed first. The downloaded 3D image is convenient for the user to quickly understand the shape of the displayed target 3D image according to the common viewing angle, and it is easy for the user to switch from the common viewing angle to the first two-dimensional image, improving readability.
在另一个实施例中,如图3所示,图3为另一个实施例中三维图像搜索方法的流程图,本实施例中提供一种三维图像搜索方法,具体可以包括以下步骤:In another embodiment, as shown in FIG. 3, FIG. 3 is a flowchart of a three-dimensional image search method in another embodiment. In this embodiment, a three-dimensional image search method is provided, which may specifically include the following steps:
S310:获取搜索对象的第一二维图像,计算第一二维图像的第一角点。S310: Acquire a first two-dimensional image of the search object, and calculate a first corner point of the first two-dimensional image.
在预设时间间隔内通过摄像设备获取搜索对象的两张原始图像;分别计算原始图像对应的第三角点和第四角点;根据第四角点对第三角点进行角点筛选,获得第一角点。Obtain two original images of the search object within a preset time interval through the camera device; calculate the third and fourth corner points corresponding to the original image respectively; perform corner filtering on the third corner point according to the fourth corner point to obtain the first corner.
S320:将第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从第二二维图像中确定目标二维图像。S320: Match the first corner point with the second corner point of the second two-dimensional image corresponding to each three-dimensional image in the image database, and determine the target two-dimensional image from the second two-dimensional image.
首先,根据图像数据库中各个第二二维图像的第二角点和第一角点,计算各第二二维图像与第一二维图像之间的第一相似度量值。从图像数据库中获取任意一个三维图像的第二二维图像对应的第二角点;将第一角点和该第二角点进行匹配,提取相同位置的角点对;根据角点对计算该第二二维图像的第一相似度量值。First, according to the second corner point and the first corner point of each second two-dimensional image in the image database, a first similarity measure value between each second two-dimensional image and the first two-dimensional image is calculated. Obtain the second corner point corresponding to the second two-dimensional image of any three-dimensional image from the image database; match the first corner point and the second corner point to extract the corner point pair at the same position; calculate the corner point pair according to the corner point pair The first similarity measure of the second two-dimensional image.
然后,选取第一相似度量值在第二预设阈值内的第二二维图像作为目标二维图像。获取各第二二维图像对应在三维图像中的视角权重;根据第二二维图像的视角权重和第二二维图像的第一相似度量值计算第二二维图像的第二相似度量值;选取第二相似度量值在第二预设阈值内的第二二维图像作为目标二维图像。Then, a second two-dimensional image whose first similarity measure value is within a second preset threshold is selected as the target two-dimensional image. Acquiring the viewing angle weight of each second two-dimensional image corresponding to the three-dimensional image; calculating the second similarity measure value of the second two-dimensional image according to the viewing angle weight of the second two-dimensional image and the first similarity measure value of the second two-dimensional image; The second two-dimensional image whose second similarity measure value is within the second preset threshold is selected as the target two-dimensional image.
S330:计算第一二维图像与目标二维图像之间的视角差。S330: Calculate the viewing angle difference between the first two-dimensional image and the target two-dimensional image.
根据角点对分别在目标二维图像和第一二维图像中的坐标建立透视变换矩阵;根据透视变换矩阵计算视角差。The perspective transformation matrix is established according to the coordinates of the corner point pairs in the target two-dimensional image and the first two-dimensional image; the perspective difference is calculated according to the perspective transformation matrix.
S340:将视角差小于第一阈值的目标二维图像所对应的三维图像确定为搜索结果。S340: Determine a three-dimensional image corresponding to the target two-dimensional image whose viewing angle difference is less than the first threshold as the search result.
S350:根据视角差和目标二维图像在三维图像中视角,计算第一二维图像的观察视角,在观察视角展示目标三维图像。S350: Calculate the observation angle of the first two-dimensional image according to the angle of view difference and the angle of view of the target two-dimensional image in the three-dimensional image, and display the target three-dimensional image at the observation angle.
上述三维图像搜索方法,根据容易采集的搜索对象的第一二维图像,借助二维图像中易于识别的角点,进行图像的匹配,从而搜索出三维图像并作为搜索结果,实现三维图像的搜索。而且,该方法中二维图像容易获得,且作为特征的角点也易于识别,大大提高了搜索的效率;同时考虑搜索对象的三维特性,还根据视角差的判断提高三维图像搜索的准确性。The above-mentioned three-dimensional image search method, based on the easy-to-collect first two-dimensional image of the search object, uses the easily recognizable corner points in the two-dimensional image to match the image, so as to search for the three-dimensional image and use it as the search result to realize the search of the three-dimensional image . Moreover, in this method, two-dimensional images are easy to obtain, and the corner points as features are also easy to identify, which greatly improves the search efficiency; at the same time, considering the three-dimensional characteristics of the search object, it also improves the accuracy of the three-dimensional image search based on the judgment of the viewing angle difference.
在一个实施例中,如图4所示,图4为一个实施例中三维图像搜索系 统的结构示意图,本实施例中提供一种三维图像搜索系统,包括角点计算模块410、二维图像匹配模块420、视角差计算模块430和三维图像获取模块440,其中:In an embodiment, as shown in FIG. 4, FIG. 4 is a schematic structural diagram of a three-dimensional image search system in an embodiment. In this embodiment, a three-dimensional image search system is provided, which includes a corner point calculation module 410 and two-dimensional image matching. Module 420, angle difference calculation module 430 and 3D image acquisition module 440, wherein:
角点计算模块410,用于获取搜索对象的第一二维图像,计算第一二维图像的第一角点。The corner point calculation module 410 is configured to obtain the first two-dimensional image of the search object, and calculate the first corner point of the first two-dimensional image.
角点计算模块410在根据第一二维图像对搜索对象进行搜索的过程中,可以根据角点检测来计算第一二维图像的第一角点。The corner point calculation module 410 may calculate the first corner point of the first two-dimensional image according to corner point detection in the process of searching for the search object according to the first two-dimensional image.
其中,搜索对象可以是立体的具有三维结构的物体,也可以是具有三维空间坐标信息的可视的三维图像,搜索图像能够在视角上被采集后得到二维图像。直观地概况下,角点具有以下的特征:可以是轮廓之间的角点;对于同一场景,即使视角发生变化,通常具备稳定性质的特征;该点附近区域的像素点无论在梯度方向上还是其梯度幅值上有着较大变化。角点是图像中直观和易于检测的特征,也便于进行合适的图像匹配。Wherein, the search object may be a three-dimensional object with a three-dimensional structure, or a visible three-dimensional image with three-dimensional space coordinate information, and the search image can be collected from a perspective to obtain a two-dimensional image. Intuitively, the corner point has the following characteristics: it can be the corner point between the contours; for the same scene, even if the viewing angle changes, it usually has the characteristics of stability; the pixels in the area near the point are either in the gradient direction or There is a big change in the gradient amplitude. The corner point is an intuitive and easy-to-detect feature in the image, and it is also convenient for proper image matching.
二维图像匹配模块420,用于将第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从第二二维图像中确定目标二维图像。The two-dimensional image matching module 420 is configured to match the first corner point with the second corner point of the second two-dimensional image corresponding to each three-dimensional image in the image database, and determine the target two-dimensional image from the second two-dimensional image.
二维图像匹配模块420依靠第一角点在图像数据库中进行匹配和查找,确定与第一二维图像相似的目标二维图像。The two-dimensional image matching module 420 performs matching and searching in the image database based on the first corner point, and determines a target two-dimensional image similar to the first two-dimensional image.
其中,图像数据库中存储着三维图像对应的第二二维图像,这些第二二维图像可以来自于用于展示三维图像在某视角下的二维图像,也可以是来自于对三维图像特意计算某视角下的二维图像。由于三维图像具有立体的三维特性,所携带的信息较多,一般单个视角下的二维图像只能够局部地展示三维图像,一般在图像数据库中的三维图像可以对应存储有多个视角下的第二二维图像。Among them, the image database stores the second two-dimensional images corresponding to the three-dimensional images. These second two-dimensional images can come from the two-dimensional images used to display the three-dimensional images in a certain angle of view, or they can be derived from the calculation of the three-dimensional images. A two-dimensional image at a certain angle of view. Since 3D images have stereoscopic 3D characteristics, they carry more information. Generally, 2D images under a single view can only partially display 3D images. Generally, 3D images in an image database can be stored corresponding to the first view from multiple views. Two-dimensional image.
视角差计算模块430,用于计算第一二维图像与目标二维图像之间的视角差。The viewing angle difference calculation module 430 is configured to calculate the viewing angle difference between the first two-dimensional image and the target two-dimensional image.
视角差计算模块430可以借助视觉变换的特点,根据第一二维图像的第一角点和目标二维图像对应的第二角点可以计算第一二维图像与目标二维图像之间的视角差。The viewing angle difference calculation module 430 can use the characteristics of visual transformation to calculate the viewing angle between the first two-dimensional image and the target two-dimensional image according to the first corner point of the first two-dimensional image and the second corner point corresponding to the target two-dimensional image. difference.
三维图像获取模块440,用于将视角差小于第一阈值的目标二维图像所对应的三维图像确定为搜索结果。The three-dimensional image acquisition module 440 is configured to determine the three-dimensional image corresponding to the target two-dimensional image whose angle of view difference is less than the first threshold value as the search result.
进一步判断角点匹配的准确性,三维图像获取模块440检测视角差是否在误差范围内,若视角差在误差范围内,即视角差小于第一阈值,则将目标二维图像所对应的三维图像确定为搜索结果。To further determine the accuracy of the corner point matching, the three-dimensional image acquisition module 440 detects whether the angle of view difference is within the error range. If the angle of view difference is within the error range, that is, the angle of view difference is less than the first threshold, the three-dimensional image corresponding to the target two-dimensional image Determined as a search result.
上述三维图像搜索系统,根据容易采集的搜索对象的第一二维图像,借助二维图像中易于识别的角点,进行图像的匹配,从而搜索出三维图像并作为搜索结果,实现三维图像的搜索。而且,该方法中二维图像容易获得,且作为特征的角点也易于识别,大大提高了搜索的效率;同时考虑搜索对象的三维特性,还根据视角差的判断提高三维图像搜索的准确性。The above-mentioned three-dimensional image search system, based on the easy-to-collect first two-dimensional image of the search object, uses the easily recognizable corner points in the two-dimensional image to perform image matching, so as to search for the three-dimensional image and use it as the search result to realize the search of the three-dimensional image . Moreover, in this method, two-dimensional images are easy to obtain, and the corner points as features are also easy to identify, which greatly improves the search efficiency; at the same time, considering the three-dimensional characteristics of the search object, it also improves the accuracy of the three-dimensional image search based on the judgment of the viewing angle difference.
关于三维图像搜索系统的具体限定可以参见上文中对于三维图像搜索方法的限定,在此不再赘述。上述三维图像搜索系统中的各个模块可全部或部分通过软件、硬件及其组合来实现。上述各模块可以硬件形式内嵌于或独立于计算机设备中的处理器中,也可以以软件形式存储于计算机设备中的存储器中,以便于处理器调用执行以上各个模块对应的操作。For the specific limitation of the 3D image search system, please refer to the above limitation of the 3D image search method, which will not be repeated here. Each module in the above-mentioned three-dimensional image search system can be implemented in whole or in part by software, hardware, and a combination thereof. The foregoing modules may be embedded in the form of hardware or independent of the processor in the computer device, or may be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the foregoing modules.
如图5所示,图5为一个实施例中计算机设备的内部结构示意图。该计算机设备包括通过系统总线连接的处理器、非易失性存储介质、存储器和网络接口。其中,该计算机设备的非易失性存储介质存储有操作系统、数据库和计算机程序,该计算机程序被处理器执行时,可使得处理器实现一种三维图像搜索方法。该计算机设备的处理器用于提供计算和控制能力,支撑整个计算机设备的运行。该计算机设备的存储器中可存储有计算机程序,该计算机程序被处理器执行时,可使得处理器执行一种三维图像搜索方法。该计算机设备的网络接口用于与终端连接通信。本领域技术人员可以理解,图5中示出的结构,仅仅是与本申请方案相关的部分结构的框图,并不构成对本申请方案所应用于其上的计算机设备的限定,具体的计算机设备可以包括比图中所示更多或更少的部件,或者组合某些部件,或者具有不同的部件布置。As shown in FIG. 5, FIG. 5 is a schematic diagram of the internal structure of a computer device in an embodiment. The computer device includes a processor, a nonvolatile storage medium, a memory, and a network interface connected through a system bus. Wherein, the non-volatile storage medium of the computer device stores an operating system, a database, and a computer program. When the computer program is executed by the processor, the processor can enable the processor to implement a three-dimensional image search method. The processor of the computer equipment is used to provide calculation and control capabilities, and supports the operation of the entire computer equipment. A computer program can be stored in the memory of the computer device, and when the computer program is executed by the processor, the processor can execute a three-dimensional image search method. The network interface of the computer device is used to connect and communicate with the terminal. Those skilled in the art can understand that the structure shown in FIG. 5 is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may Including more or fewer parts than shown in the figure, or combining some parts, or having a different arrangement of parts.
在一个实施例中,提出了一种计算机设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,处理器执行所述计算机 程序时实现上述任一实施例中三维图像搜索方法的步骤,其中,所述三维图像搜索方法的步骤包括:获取搜索对象的第一二维图像,计算所述第一二维图像的第一角点;将所述第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从所述第二二维图像中确定目标二维图像;计算所述第一二维图像与所述目标二维图像之间的视角差;将视角差小于第一阈值的目标二维图像所对应的三维图像确定为搜索结果。In one embodiment, a computer device is proposed, which includes a memory, a processor, and a computer program stored in the memory and capable of running on the processor. The processor implements the three-dimensional system in any of the above-mentioned embodiments when the computer program is executed. The steps of the image search method, wherein the steps of the three-dimensional image search method include: acquiring a first two-dimensional image of the search object, calculating a first corner point of the first two-dimensional image; and combining the first corner point with Match the second corner points of the second two-dimensional image corresponding to each three-dimensional image in the image database, determine the target two-dimensional image from the second two-dimensional image; calculate the first two-dimensional image and the target two-dimensional The viewing angle difference between the images; the three-dimensional image corresponding to the target two-dimensional image whose viewing angle difference is less than the first threshold is determined as the search result.
在一个实施例中,提出了一种存储有计算机可读指令的存储介质,所述计算机可读指令的存储介质可以是非易失性,也可以是易失性,其上存储有计算机程序,计算机程序被处理器执行时实现上述任一实施例中三维图像搜索方法的步骤,其中,所述三维图像搜索方法的步骤包括:获取搜索对象的第一二维图像,计算所述第一二维图像的第一角点;将所述第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从所述第二二维图像中确定目标二维图像;计算所述第一二维图像与所述目标二维图像之间的视角差;将视角差小于第一阈值的目标二维图像所对应的三维图像确定为搜索结果。In one embodiment, a storage medium storing computer-readable instructions is proposed. The storage medium of the computer-readable instructions may be non-volatile or volatile. A computer program is stored thereon. When the program is executed by the processor, the steps of the three-dimensional image search method in any of the above embodiments are implemented, wherein the steps of the three-dimensional image search method include: acquiring a first two-dimensional image of the search object, and calculating the first two-dimensional image Match the first corner point with the second corner point of the second two-dimensional image corresponding to each three-dimensional image in the image database, and determine the target two-dimensional image from the second two-dimensional image; Calculating the viewing angle difference between the first two-dimensional image and the target two-dimensional image; determining the three-dimensional image corresponding to the target two-dimensional image whose viewing angle difference is less than the first threshold value as the search result.
应该理解的是,虽然附图的流程图中的各个步骤按照箭头的指示依次显示,但是这些步骤并不是必然按照箭头指示的顺序依次执行。除非本文中有明确的说明,这些步骤的执行并没有严格的顺序限制,其可以以其他的顺序执行。而且,附图的流程图中的至少一部分步骤可以包括多个子步骤或者多个阶段,这些子步骤或者阶段并不必然是在同一时刻执行完成,而是可以在不同的时刻执行,其执行顺序也不必然是依次进行,而是可以与其他步骤或者其他步骤的子步骤或者阶段的至少一部分轮流或者交替地执行。It should be understood that, although the various steps in the flowchart of the drawings are shown in sequence as indicated by the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless explicitly stated in this article, the execution of these steps is not strictly limited in order, and they can be executed in other orders. Moreover, at least part of the steps in the flowchart of the drawings may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and the order of execution is also It is not necessarily performed sequentially, but may be performed alternately or alternately with other steps or at least a part of sub-steps or stages of other steps.
以上所述仅是本申请的部分实施方式,应当指出,对于本技术领域的普通技术人员来说,在不脱离本申请原理的前提下,还可以做出若干改进和润饰,这些改进和润饰也应视为本申请的保护范围。The above are only part of the implementation of this application. It should be pointed out that for those of ordinary skill in the art, without departing from the principle of this application, several improvements and modifications can be made, and these improvements and modifications are also Should be regarded as the scope of protection of this application.

Claims (20)

  1. 一种三维图像搜索方法,包括如下步骤:A three-dimensional image search method includes the following steps:
    获取搜索对象的第一二维图像,计算所述第一二维图像的第一角点;Acquiring a first two-dimensional image of the search object, and calculating a first corner point of the first two-dimensional image;
    将所述第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从所述第二二维图像中确定目标二维图像;Matching the first corner point with a second corner point of a second two-dimensional image corresponding to each three-dimensional image in the image database, and determining a target two-dimensional image from the second two-dimensional image;
    计算所述第一二维图像与所述目标二维图像之间的视角差;Calculating a viewing angle difference between the first two-dimensional image and the target two-dimensional image;
    将视角差小于第一阈值的目标二维图像所对应的三维图像确定为搜索结果。The three-dimensional image corresponding to the target two-dimensional image whose viewing angle difference is less than the first threshold is determined as the search result.
  2. 根据权利要求1所述的三维图像搜索方法,所述获取搜索对象的第一二维图像,计算所述第一二维图像的第一角点的步骤,包括:The three-dimensional image search method according to claim 1, wherein the step of obtaining a first two-dimensional image of a search object and calculating a first corner point of the first two-dimensional image comprises:
    在预设时间间隔内通过摄像设备获取所述搜索对象的两张原始图像;Acquiring two original images of the search object within a preset time interval through a camera device;
    分别计算所述原始图像对应的第三角点和第四角点;Respectively calculating the third corner point and the fourth corner point corresponding to the original image;
    根据所述第四角点对所述第三角点进行角点筛选,获得所述第一角点。Performing corner point screening on the third corner point according to the fourth corner point to obtain the first corner point.
  3. 根据权利要求1所述的三维图像搜索方法,所述将所述第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从所述第二二维图像中确定目标二维图像的步骤,包括:The three-dimensional image search method according to claim 1, wherein the first corner point is matched with the second corner point of the second two-dimensional image corresponding to each three-dimensional image in the image database, and the The steps of determining the target two-dimensional image in the image include:
    根据所述图像数据库中各个第二二维图像的第二角点和所述第一角点,计算各所述第二二维图像与所述第一二维图像之间的第一相似度量值;According to the second corner point and the first corner point of each second two-dimensional image in the image database, a first similarity measure value between each second two-dimensional image and the first two-dimensional image is calculated ;
    选取所述第一相似度量值在第二预设阈值内的第二二维图像作为所述目标二维图像。A second two-dimensional image whose first similarity measure value is within a second preset threshold is selected as the target two-dimensional image.
  4. 根据权利要求3所述的三维图像搜索方法,所述计算各所述第二二维图像与所述第一二维图像之间的第一相似度量值的步骤,包括:3. The three-dimensional image search method according to claim 3, wherein the step of calculating the first similarity metric value between each of the second two-dimensional images and the first two-dimensional image comprises:
    从所述图像数据库中获取任意一个三维图像的第二二维图像对应的第二角点;Acquiring, from the image database, the second corner point corresponding to the second two-dimensional image of any one of the three-dimensional images;
    将所述第一角点和该第二角点进行匹配,提取相同位置的角点对;Matching the first corner point and the second corner point, and extracting a corner point pair at the same position;
    根据所述角点对计算该第二二维图像的第一相似度量值。The first similarity measure value of the second two-dimensional image is calculated according to the corner point pair.
  5. 根据权利要求3所述的三维图像搜索方法,所述选取所述第一相似度量值在第二预设阈值内的第二二维图像作为所述目标二维图像的步骤,包括:The 3D image search method according to claim 3, wherein the step of selecting a second 2D image whose first similarity measure value is within a second preset threshold value as the target 2D image comprises:
    获取各所述第二二维图像对应在三维图像中的视角权重;Acquiring a perspective weight corresponding to each of the second two-dimensional images in the three-dimensional image;
    根据所述第二二维图像的视角权重和所述第二二维图像的第一相似度量值计算所述第二二维图像的第二相似度量值;Calculating a second similarity metric value of the second two-dimensional image according to the viewing angle weight of the second two-dimensional image and the first similarity metric value of the second two-dimensional image;
    选取所述第二相似度量值在第二预设阈值内的第二二维图像作为所述目标二维图像。A second two-dimensional image whose second similarity measure value is within a second preset threshold is selected as the target two-dimensional image.
  6. 根据权利要求4所述的三维图像搜索方法,所述计算所述第一二维图像与所述目标二维图像之间的视角差的步骤,包括:The 3D image search method according to claim 4, wherein the step of calculating the angle of view difference between the first 2D image and the target 2D image comprises:
    根据所述角点对分别在所述目标二维图像和所述第一二维图像中的坐标建立透视变换矩阵;Establishing a perspective transformation matrix according to the coordinates of the corner point pairs in the target two-dimensional image and the first two-dimensional image;
    根据所述透视变换矩阵计算所述视角差。Calculate the viewing angle difference according to the perspective transformation matrix.
  7. 根据权利要求1所述的三维图像搜索方法,在所述将视角差小于第一阈值的目标二维图像所对应的三维图像确定为搜索结果的步骤之后,包括:The three-dimensional image search method according to claim 1, after the step of determining the three-dimensional image corresponding to the target two-dimensional image whose angle of view difference is less than the first threshold as the search result, the method comprises:
    根据所述视角差和所述目标二维图像在三维图像中视角,计算所述第一二维图像的观察视角;Calculating the viewing angle of the first two-dimensional image according to the viewing angle difference and the viewing angle of the target two-dimensional image in the three-dimensional image;
    在所述观察视角展示所述目标三维图像。The three-dimensional image of the target is displayed at the viewing angle of view.
  8. 一种三维图像搜索系统,包括:A three-dimensional image search system, including:
    角点计算模块,用于获取搜索对象的第一二维图像,计算所述第一二维图像的第一角点;A corner point calculation module, configured to obtain a first two-dimensional image of the search object, and calculate the first corner point of the first two-dimensional image;
    二维图像匹配模块,用于将所述第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从所述第二二维图像中确定目标二维图像;The two-dimensional image matching module is used to match the first corner point with the second corner point of the second two-dimensional image corresponding to each three-dimensional image in the image database, and determine the target two-dimensional image from the second two-dimensional image. image;
    视角差计算模块,用于计算所述第一二维图像与所述目标二维图像之间的视角差;A viewing angle difference calculation module, configured to calculate a viewing angle difference between the first two-dimensional image and the target two-dimensional image;
    三维图像获取模块,用于将视角差小于第一阈值的目标二维图像所对应的三维图像确定为搜索结果。The three-dimensional image acquisition module is used to determine the three-dimensional image corresponding to the target two-dimensional image whose angle of view difference is less than the first threshold as the search result.
  9. 一种计算机设备,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现一种三维图像搜索方法的步骤,其中,所述三维图像搜索方法的步骤包括:A computer device includes a memory, a processor, and a computer program stored in the memory and capable of running on the processor. The processor implements the steps of a three-dimensional image search method when the computer program is executed, wherein the The steps of the 3D image search method include:
    获取搜索对象的第一二维图像,计算所述第一二维图像的第一角点;Acquiring a first two-dimensional image of the search object, and calculating a first corner point of the first two-dimensional image;
    将所述第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从所述第二二维图像中确定目标二维图像;Matching the first corner point with a second corner point of a second two-dimensional image corresponding to each three-dimensional image in the image database, and determining a target two-dimensional image from the second two-dimensional image;
    计算所述第一二维图像与所述目标二维图像之间的视角差;Calculating a viewing angle difference between the first two-dimensional image and the target two-dimensional image;
    将视角差小于第一阈值的目标二维图像所对应的三维图像确定为搜索结果。The three-dimensional image corresponding to the target two-dimensional image whose viewing angle difference is less than the first threshold is determined as the search result.
  10. 根据权利要求9所述的计算机设备,所述获取搜索对象的第一二维图像,计算所述第一二维图像的第一角点的步骤,包括:The computer device according to claim 9, wherein the step of obtaining a first two-dimensional image of a search object and calculating a first corner point of the first two-dimensional image comprises:
    在预设时间间隔内通过摄像设备获取所述搜索对象的两张原始图像;Acquiring two original images of the search object within a preset time interval through a camera device;
    分别计算所述原始图像对应的第三角点和第四角点;Respectively calculating the third corner point and the fourth corner point corresponding to the original image;
    根据所述第四角点对所述第三角点进行角点筛选,获得所述第一角点。Performing corner point screening on the third corner point according to the fourth corner point to obtain the first corner point.
  11. 根据权利要求9所述的计算机设备,所述将所述第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从所述第二二维图像中确定目标二维图像的步骤,包括:The computer device according to claim 9, wherein the first corner point is matched with a second corner point of a second two-dimensional image corresponding to each three-dimensional image in the image database, and the second corner point is obtained from the second two-dimensional image The steps to determine the two-dimensional image of the target include:
    根据所述图像数据库中各个第二二维图像的第二角点和所述第一角点,计算各所述第二二维图像与所述第一二维图像之间的第一相似度量值;According to the second corner point and the first corner point of each second two-dimensional image in the image database, a first similarity measure value between each second two-dimensional image and the first two-dimensional image is calculated ;
    选取所述第一相似度量值在第二预设阈值内的第二二维图像作为所述目标二维图像。A second two-dimensional image whose first similarity measure value is within a second preset threshold is selected as the target two-dimensional image.
  12. 根据权利要求11所述的计算机设备,所述计算各所述第二二维图像与所述第一二维图像之间的第一相似度量值的步骤,包括:11. The computer device according to claim 11, wherein the step of calculating a first similarity metric value between each of the second two-dimensional images and the first two-dimensional image comprises:
    从所述图像数据库中获取任意一个三维图像的第二二维图像对应的第二角点;Acquiring, from the image database, the second corner point corresponding to the second two-dimensional image of any one of the three-dimensional images;
    将所述第一角点和该第二角点进行匹配,提取相同位置的角点对;Matching the first corner point and the second corner point, and extracting a corner point pair at the same position;
    根据所述角点对计算该第二二维图像的第一相似度量值。The first similarity measure value of the second two-dimensional image is calculated according to the corner point pair.
  13. 根据权利要求11所述的计算机设备,所述选取所述第一相似度量值在第二预设阈值内的第二二维图像作为所述目标二维图像的步骤,包括:11. The computer device according to claim 11, wherein the step of selecting a second two-dimensional image whose first similarity measure value is within a second preset threshold as the target two-dimensional image comprises:
    获取各所述第二二维图像对应在三维图像中的视角权重;Acquiring a perspective weight corresponding to each of the second two-dimensional images in the three-dimensional image;
    根据所述第二二维图像的视角权重和所述第二二维图像的第一相似度量值计算所述第二二维图像的第二相似度量值;Calculating a second similarity metric value of the second two-dimensional image according to the viewing angle weight of the second two-dimensional image and the first similarity metric value of the second two-dimensional image;
    选取所述第二相似度量值在第二预设阈值内的第二二维图像作为所述目标二维图像。A second two-dimensional image whose second similarity measure value is within a second preset threshold is selected as the target two-dimensional image.
  14. 根据权利要求12所述的计算机设备,所述计算所述第一二维图像与所述目标二维图像之间的视角差的步骤,包括:The computer device according to claim 12, wherein the step of calculating the angle of view difference between the first two-dimensional image and the target two-dimensional image comprises:
    根据所述角点对分别在所述目标二维图像和所述第一二维图像中的坐标建立透视变换矩阵;Establishing a perspective transformation matrix according to the coordinates of the corner point pairs in the target two-dimensional image and the first two-dimensional image;
    根据所述透视变换矩阵计算所述视角差。Calculate the viewing angle difference according to the perspective transformation matrix.
  15. 根据权利要求9所述的计算机设备,在所述将视角差小于第一阈值的目标二维图像所对应的三维图像确定为搜索结果的步骤之后,包括:9. The computer device according to claim 9, after the step of determining the three-dimensional image corresponding to the target two-dimensional image whose angle of view difference is less than the first threshold as the search result, comprising:
    根据所述视角差和所述目标二维图像在三维图像中视角,计算所述第一二维图像的观察视角;Calculating the viewing angle of the first two-dimensional image according to the viewing angle difference and the viewing angle of the target two-dimensional image in the three-dimensional image;
    在所述观察视角展示所述目标三维图像。The three-dimensional image of the target is displayed at the viewing angle of view.
  16. 一种计算机可读存储介质,其上存储有计算机程序,所述计算机程序被处理器执行时实现一种三维图像搜索方法的步骤,所述三维图像搜索方法的步骤包括:A computer-readable storage medium having a computer program stored thereon, which when executed by a processor realizes the steps of a three-dimensional image search method, the steps of the three-dimensional image search method include:
    获取搜索对象的第一二维图像,计算所述第一二维图像的第一角点;Acquiring a first two-dimensional image of the search object, and calculating a first corner point of the first two-dimensional image;
    将所述第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从所述第二二维图像中确定目标二维图像;Matching the first corner point with a second corner point of a second two-dimensional image corresponding to each three-dimensional image in the image database, and determining a target two-dimensional image from the second two-dimensional image;
    计算所述第一二维图像与所述目标二维图像之间的视角差;Calculating a viewing angle difference between the first two-dimensional image and the target two-dimensional image;
    将视角差小于第一阈值的目标二维图像所对应的三维图像确定为搜索结果。The three-dimensional image corresponding to the target two-dimensional image whose viewing angle difference is less than the first threshold is determined as the search result.
  17. 根据权利要求16所述的计算机可读存储介质,所述获取搜索对象的第一二维图像,计算所述第一二维图像的第一角点的步骤,包括:15. The computer-readable storage medium according to claim 16, wherein the step of obtaining a first two-dimensional image of a search object and calculating a first corner point of the first two-dimensional image comprises:
    在预设时间间隔内通过摄像设备获取所述搜索对象的两张原始图像;Acquiring two original images of the search object within a preset time interval through a camera device;
    分别计算所述原始图像对应的第三角点和第四角点;Respectively calculating the third corner point and the fourth corner point corresponding to the original image;
    根据所述第四角点对所述第三角点进行角点筛选,获得所述第一角点。Performing corner point screening on the third corner point according to the fourth corner point to obtain the first corner point.
  18. 根据权利要求16所述的计算机可读存储介质,所述将所述第一角点与图像数据库中各个三维图像对应的第二二维图像的第二角点进行匹配,从所述第二二维图像中确定目标二维图像的步骤,包括:The computer-readable storage medium according to claim 16, wherein the first corner point is matched with a second corner point of a second two-dimensional image corresponding to each three-dimensional image in the image database, and The steps of determining the target two-dimensional image in the three-dimensional image include:
    根据所述图像数据库中各个第二二维图像的第二角点和所述第一角点,计算各所述第二二维图像与所述第一二维图像之间的第一相似度量值;According to the second corner point and the first corner point of each second two-dimensional image in the image database, a first similarity measure value between each second two-dimensional image and the first two-dimensional image is calculated ;
    选取所述第一相似度量值在第二预设阈值内的第二二维图像作为所述目标二维图像。A second two-dimensional image whose first similarity measure value is within a second preset threshold is selected as the target two-dimensional image.
  19. 根据权利要求18所述的计算机可读存储介质,所述计算各所述第二二维图像与所述第一二维图像之间的第一相似度量值的步骤,包括:18. The computer-readable storage medium according to claim 18, wherein the step of calculating a first similarity metric value between each of the second two-dimensional image and the first two-dimensional image comprises:
    从所述图像数据库中获取任意一个三维图像的第二二维图像对应的第二角点;Acquiring, from the image database, the second corner point corresponding to the second two-dimensional image of any one of the three-dimensional images;
    将所述第一角点和该第二角点进行匹配,提取相同位置的角点对;Matching the first corner point and the second corner point, and extracting a corner point pair at the same position;
    根据所述角点对计算该第二二维图像的第一相似度量值。The first similarity measure value of the second two-dimensional image is calculated according to the corner point pair.
  20. 根据权利要求18所述的计算机可读存储介质,所述选取所述第一相似度量值在第二预设阈值内的第二二维图像作为所述目标二维图像的步骤,包括:18. The computer-readable storage medium according to claim 18, wherein the step of selecting a second two-dimensional image whose first similarity metric value is within a second preset threshold as the target two-dimensional image comprises:
    获取各所述第二二维图像对应在三维图像中的视角权重;Acquiring a perspective weight corresponding to each of the second two-dimensional images in the three-dimensional image;
    根据所述第二二维图像的视角权重和所述第二二维图像的第一相似度量值计算所述第二二维图像的第二相似度量值;Calculating a second similarity metric value of the second two-dimensional image according to the viewing angle weight of the second two-dimensional image and the first similarity metric value of the second two-dimensional image;
    选取所述第二相似度量值在第二预设阈值内的第二二维图像作为所述目标二维图像。A second two-dimensional image whose second similarity measure value is within a second preset threshold is selected as the target two-dimensional image.
PCT/CN2019/118153 2019-07-19 2019-11-13 Three-dimensional image search method and system, computer device, and storage medium WO2021012523A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910656211.3 2019-07-19
CN201910656211.3A CN110472085B (en) 2019-07-19 2019-07-19 Three-dimensional image searching method, system, computer device and storage medium

Publications (1)

Publication Number Publication Date
WO2021012523A1 true WO2021012523A1 (en) 2021-01-28

Family

ID=68508326

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/118153 WO2021012523A1 (en) 2019-07-19 2019-11-13 Three-dimensional image search method and system, computer device, and storage medium

Country Status (2)

Country Link
CN (1) CN110472085B (en)
WO (1) WO2021012523A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116274893A (en) * 2023-02-24 2023-06-23 北京瓦特曼智能科技有限公司 Method, processor, device and storage medium for detecting erosion amount of ladle lining

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113793422B (en) * 2021-08-13 2024-02-23 深圳安泰创新科技股份有限公司 Display control method for three-dimensional model, electronic device and readable storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040103093A1 (en) * 2002-11-15 2004-05-27 Olympus Corportion Similarity search of three-dimensional model using two-dimensional image as search key
CN103116904A (en) * 2012-10-23 2013-05-22 北京航空航天大学深圳研究院 Two-dimensional feature extraction system and two-dimensional feature extraction method of three-dimensional model
CN103177098A (en) * 2013-03-19 2013-06-26 浙江大学 Three-dimensional model searching method based on sketching
CN106484692A (en) * 2015-08-25 2017-03-08 北京师范大学 A kind of method for searching three-dimension model
CN107247752A (en) * 2017-05-27 2017-10-13 西安电子科技大学 A kind of image search method based on corner description

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9280597B2 (en) * 2009-12-01 2016-03-08 Apple Inc. System and method for customizing search results from user's perspective
TWI536186B (en) * 2013-12-12 2016-06-01 三緯國際立體列印科技股份有限公司 Three-dimension image file serching method and three-dimension image file serching system
EP3023909A1 (en) * 2014-11-18 2016-05-25 Thomson Licensing Method and apparatus for ranking 2D candidate images
CN107481315A (en) * 2017-06-29 2017-12-15 重庆邮电大学 A kind of monocular vision three-dimensional environment method for reconstructing based on Harris SIFT BRIEF algorithms
CN109708649B (en) * 2018-12-07 2021-02-09 中国空间技术研究院 Attitude determination method and system for remote sensing satellite

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040103093A1 (en) * 2002-11-15 2004-05-27 Olympus Corportion Similarity search of three-dimensional model using two-dimensional image as search key
CN103116904A (en) * 2012-10-23 2013-05-22 北京航空航天大学深圳研究院 Two-dimensional feature extraction system and two-dimensional feature extraction method of three-dimensional model
CN103177098A (en) * 2013-03-19 2013-06-26 浙江大学 Three-dimensional model searching method based on sketching
CN106484692A (en) * 2015-08-25 2017-03-08 北京师范大学 A kind of method for searching three-dimension model
CN107247752A (en) * 2017-05-27 2017-10-13 西安电子科技大学 A kind of image search method based on corner description

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116274893A (en) * 2023-02-24 2023-06-23 北京瓦特曼智能科技有限公司 Method, processor, device and storage medium for detecting erosion amount of ladle lining
CN116274893B (en) * 2023-02-24 2024-02-06 北京瓦特曼智能科技有限公司 Method, processor, device and storage medium for detecting erosion amount of ladle lining

Also Published As

Publication number Publication date
CN110472085A (en) 2019-11-19
CN110472085B (en) 2023-06-20

Similar Documents

Publication Publication Date Title
Rennie et al. A dataset for improved rgbd-based object detection and pose estimation for warehouse pick-and-place
JP6216508B2 (en) Method for recognition and pose determination of 3D objects in 3D scenes
CN108921895B (en) Sensor relative pose estimation method
CN109544599B (en) Three-dimensional point cloud registration method based on camera pose estimation
WO2017099097A1 (en) Method and system for detecting and localizing object and slam method
CN105934757B (en) A kind of method and apparatus of the key point for detecting the first image and the incorrect incidence relation between the key point of the second image
US10866984B2 (en) Sketch-based image searching system using cell-orientation histograms and outline extraction based on medium-level features
WO2021136386A1 (en) Data processing method, terminal, and server
Hao et al. Efficient 2D-to-3D correspondence filtering for scalable 3D object recognition
CN108764100B (en) Target behavior detection method and server
TW201227615A (en) Moving object detection method and image processing system for moving object detection
WO2021012523A1 (en) Three-dimensional image search method and system, computer device, and storage medium
WO2023016082A1 (en) Three-dimensional reconstruction method and apparatus, and electronic device and storage medium
TW201227602A (en) Method and computer-readable medium for calculating depth of image
CN109872343B (en) Weak texture object posture tracking method, system and device
CN113298871B (en) Map generation method, positioning method, system thereof, and computer-readable storage medium
JP5536124B2 (en) Image processing system and image processing method
CN110793441A (en) High-precision object geometric dimension measuring method and device
CN116823816B (en) Detection equipment and detection method based on security monitoring static memory
Teixeira et al. Epipolar based light field key-location detector
CN117351078A (en) Target size and 6D gesture estimation method based on shape priori
Zhang et al. Camera self-calibration based on multiple view images
JP6304815B2 (en) Image processing apparatus and image feature detection method, program and apparatus thereof
JP2014038566A (en) Image processor
KR101178015B1 (en) Generating method for disparity map

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19938541

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 19938541

Country of ref document: EP

Kind code of ref document: A1