Image matching methods, devices, electronic equipment, and storage media
By filtering and correcting local element attributes in image search technology, the problem of inaccurate matching in image search technology is solved, and efficient image query and accurate target recognition are achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- BEIJING BAIDU NETCOM SCI & TECH CO LTD
- Filing Date
- 2023-05-18
- Publication Date
- 2026-05-26
AI Technical Summary
Existing image search technologies struggle to accurately find images that precisely match the query image, impacting the operational efficiency of intelligent security systems.
By identifying local query image patches from the query image, the matching results between the local image patches to be matched are used to filter out the first candidate local image patches, and the attributes of the query local elements are corrected based on the attributes of the candidate local elements to improve the matching accuracy.
It improves the accuracy and efficiency of image queries, ensuring a high-precision match between the target image and the query image.
Smart Images

Figure CN116662589B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the field of image processing technology, and more particularly to the fields of big data technology and intelligent search technology. Background Technology
[0002] Image search is the process of identifying images from an image library that match images submitted by a user. Image search technology can find images with a high degree of similarity to user-submitted images from an image library. Therefore, image search technology can be applied in scenarios such as urban security and product recommendation to help users find images that match their submissions, thereby enhancing users' personalized search needs. Summary of the Invention
[0003] This disclosure provides an image matching method, apparatus, electronic device, storage medium, and computer program product.
[0004] According to one aspect of this disclosure, an image matching method is provided, comprising: upon receiving a query image related to a target object, determining a local query image patch from the query image, the local query image patch being related to local elements of the target object; determining at least one first candidate local image patch from a set of local image patches to be matched based on a matching result between the local query image patch and a local image patch to be matched, wherein the local image patch to be matched is obtained from the image to be matched; determining a target query local element attribute corresponding to the local query image patch based on the first candidate local element attribute corresponding to each of the first candidate local image patches; and determining a matching image matching the query image from a set of images to be matched containing the image to be matched based on the target query local element attribute.
[0005] According to another aspect of this disclosure, an image matching apparatus is provided, comprising: a local query image patch determination module, configured to determine local query image patches from the query image upon receiving a query image related to a target object, wherein the local query image patches are related to local elements of the target object; a first candidate local image patch acquisition module, configured to determine at least one first candidate local image patch from a set of local image patches to be matched based on a matching result between the local query image patch and a local image patch to be matched, wherein the local image patch to be matched is obtained from the image to be matched; a target query local element attribute determination module, configured to determine a target query local element attribute corresponding to the local query image patch based on the first candidate local element attribute corresponding to each of the first candidate local image patches; and a matching image determination module, configured to determine a matching image matching the query image from a set of images to be matched containing the image to be matched based on the target query local element attribute.
[0006] According to another aspect of this disclosure, an electronic device is provided, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform a method provided according to an embodiment of this disclosure.
[0007] According to another aspect of this disclosure, a non-transitory computer-readable storage medium is provided storing computer instructions, wherein the computer instructions are used to cause the computer to perform a method provided according to an embodiment of this disclosure.
[0008] According to another aspect of this disclosure, a computer program product is provided, including a computer program that, when executed by a processor, implements the method provided according to embodiments of this disclosure.
[0009] It should be understood that the description in this section is not intended to identify key or essential features of the embodiments of this disclosure, nor is it intended to limit the scope of this disclosure. Other features of this disclosure will become readily apparent from the following description. Attached Figure Description
[0010] The accompanying drawings are provided to better understand this solution and do not constitute a limitation of this disclosure. Wherein:
[0011] Figure 1 The illustration schematically shows an exemplary system architecture to which image matching methods and apparatus can be applied according to embodiments of the present disclosure.
[0012] Figure 2 A flowchart illustrating an image matching method according to an embodiment of the present disclosure is shown schematically.
[0013] Figure 3 The illustration shows an application scenario of the image matching method according to an embodiment of the present disclosure.
[0014] Figure 4A The schematic diagram illustrates the principle of obtaining a second candidate local image patch according to an embodiment of the present disclosure.
[0015] Figure 4B The schematic diagram illustrates the principle of obtaining a candidate image set according to an embodiment of the present disclosure.
[0016] Figure 5 The schematic diagram illustrates the principle of determining a matching image according to an embodiment of the present disclosure.
[0017] Figure 6 A block diagram of an image matching apparatus according to an embodiment of the present disclosure is shown schematically.
[0018] Figure 7A schematic block diagram of an example electronic device 700 that can be used to implement embodiments of the present disclosure is shown. Detailed Implementation
[0019] The exemplary embodiments of this disclosure are described below with reference to the accompanying drawings, including various details of the embodiments to aid understanding, and should be considered merely exemplary. Therefore, those skilled in the art will recognize that various changes and modifications can be made to the embodiments described herein without departing from the scope and spirit of this disclosure. Similarly, for clarity and brevity, descriptions of well-known functions and structures are omitted in the following description.
[0020] In the technical solution disclosed herein, the acquisition, storage, and application of user personal information comply with the provisions of relevant laws and regulations, necessary confidentiality measures have been taken, and there is no violation of public order and good morals.
[0021] The number of urban security cameras is increasing daily, and the concept of smart cities is gradually becoming more widespread in urban governance. For example, image acquisition devices in urban security detection systems collect images of people, vehicles, and other target objects in relevant management areas, and then build an image search library based on these images. Relevant management personnel can use image search technology to process the images they need to query, enabling them to find images in the search library that match the query image, thereby obtaining relevant information about the target objects in the images in a timely manner and improving the overall level of security.
[0022] The inventors discovered that the relevant image search technology has difficulty accurately finding images that precisely match the query image, which negatively impacts the operational efficiency of intelligent security systems.
[0023] Embodiments of this disclosure provide an image matching method, apparatus, electronic device, storage medium, and computer program product. The image matching method includes: upon receiving a query image related to a target object, determining local query image blocks from the query image, the local query image blocks being related to local elements of the target object; determining at least one first candidate local image block from a set of local image blocks to be matched based on a matching result between the local query image block and a local image block to be matched, wherein the local image block to be matched is obtained from the image to be matched; determining a target query local element attribute corresponding to a local query image block based on first candidate local element attributes corresponding to each of the first candidate local image blocks; and determining a matching image matching the query image from a set of images to be matched containing the image to be matched based on the target query local element attribute.
[0024] According to embodiments of this disclosure, a first candidate local image block is selected by matching the local query image block related to the local elements of the target object and the local image block to be matched. The target query local element attribute is determined based on the attribute of the first candidate local element. This can correct the judgment error of the local element attribute corresponding to the local query image block, thereby improving the detection accuracy of local element attribute of local image region in the query image. In this way, determining the target image based on the target query local element attribute can improve the matching accuracy between the target image and the query image, thereby improving the query efficiency and accuracy of the image.
[0025] Figure 1 The illustration schematically shows an exemplary system architecture to which image matching methods and apparatus can be applied according to embodiments of the present disclosure.
[0026] It is important to note that Figure 1 The examples shown are merely examples of system architectures that can be applied to embodiments of this disclosure, intended to help those skilled in the art understand the technical content of this disclosure. However, they do not imply that embodiments of this disclosure cannot be used in other devices, systems, environments, or scenarios. For example, in another embodiment, an exemplary system architecture to which the image matching method and apparatus can be applied may include a terminal device. However, the terminal device can implement the image matching method and apparatus provided by embodiments of this disclosure without interacting with a server.
[0027] like Figure 1 As shown, the system architecture 100 according to this embodiment may include terminal devices 101, 102, and 103, a network 104, and a server 105. The network 104 serves as a medium for providing communication links between the terminal devices 101, 102, and 103 and the server 105. The network 104 may include various connection types, such as wired and / or wireless communication links, etc.
[0028] Users can use terminal devices 101, 102, and 103 to interact with server 105 via network 104 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 101, 102, and 103, such as knowledge reading applications, web browser applications, search applications, instant messaging tools, email clients, and / or social platform software, etc. (for example only).
[0029] Terminal devices 101, 102, and 103 can be various electronic devices with displays and web browsing capabilities, including but not limited to smartphones, tablets, laptops, and desktop computers.
[0030] Server 105 can be a server that provides various services, such as a backend management server that supports the content browsed by users using terminal devices 101, 102, and 103 (for example only). The backend management server can analyze and process data such as received user requests, and feed back the processing results (such as web pages, information, or data obtained or generated according to user requests) to the terminal devices.
[0031] It should be noted that the image matching method provided in this embodiment can generally be executed by terminal devices 101, 102, or 103. Accordingly, the image matching device provided in this embodiment can also be disposed in terminal devices 101, 102, or 103.
[0032] Alternatively, the image matching method provided in this embodiment can generally be executed by server 105. Correspondingly, the image matching device provided in this embodiment can generally be located in server 105. The image matching method provided in this embodiment can also be executed by a server or server cluster that is different from server 105 and capable of communicating with terminal devices 101, 102, 103 and / or server 105. Correspondingly, the image matching device provided in this embodiment can also be located in a server or server cluster that is different from server 105 and capable of communicating with terminal devices 101, 102, 103 and / or server 105.
[0033] It should be understood that Figure 1 The number of terminal devices, networks, and servers shown is merely illustrative. Depending on implementation needs, any number of terminal devices, networks, and servers can be included.
[0034] Figure 2 A flowchart illustrating an image matching method according to an embodiment of the present disclosure is shown schematically.
[0035] like Figure 2 As shown, the image matching method includes operations S210 to S240.
[0036] In operation S210, upon receiving a query image related to the target object, a local query image block is determined from the query image, the local query image block being related to local elements of the target object.
[0037] In operation S220, based on the matching result between the local query image patch and the local image patch to be matched, at least one first candidate local image patch is determined from the set of local image patches to be matched, wherein the local image patch to be matched is obtained from the image to be matched.
[0038] In operation S230, the target query local element attribute corresponding to the local query image block is determined based on the first candidate local element attribute corresponding to each of the first candidate local image blocks.
[0039] In operation S240, based on the local element attributes of the target query, a matching image that matches the query image is determined from the set of images to be matched that contains the image to be matched.
[0040] According to embodiments of this disclosure, the target object can be a living organism such as a person, cat, or dog, but is not limited to these. The target object can also be other types of objects such as passenger vehicles or intelligent robots. Embodiments of this disclosure do not limit the specific type of the target object, and those skilled in the art can select one according to actual needs.
[0041] According to embodiments of this disclosure, local elements of the target object can be local characteristic elements related to the target object. For example, if the target object in the query image is a human body, the local elements can include glasses, hats, bow ties, backpacks, etc., related to that human body in the query image. It is understood that local elements can be a part of the target object's body, or they can be other types of local elements related to the target object's body.
[0042] According to embodiments of this disclosure, the query image can be an image that the user needs to query. The query image can be obtained from a terminal such as a camera, smartphone, or computer, or it can be determined from any storage medium through the user's selection operation. Embodiments of this disclosure do not limit the specific method of obtaining the query image.
[0043] According to embodiments of this disclosure, a local query image patch can correspond to a portion of the image region in the query image. Determining the local query image patch from the query image can, for example, involve segmenting the query image based on user actions. However, this is not limited to this; the query image can also be detected using an object detection model, and the local query image patch can be extracted from the query image based on the detection bounding boxes output by the object detection model. Embodiments of this disclosure do not limit the specific method for obtaining the local query image patch.
[0044] According to embodiments of this disclosure, the local image patch to be matched can be a local image region extracted from the image to be matched. For example, the image to be matched can be input into a target detection model, which outputs local element detection boxes corresponding to the local elements, and the local image patch to be matched related to the local elements can be extracted from the image to be matched based on the local element detection boxes. However, it is not limited to this; the local image patch to be matched can also be determined from the image to be matched based on other methods, such as obtaining the local image patch to be matched through manual selection.
[0045] According to embodiments of this disclosure, the matching result between a local query image patch and a local image patch to be matched can characterize the degree of similarity between the local query image patch and the local image patch to be matched. For example, a similarity algorithm can be used to process the local query image patch and the local image patch to be matched to obtain a matching result. Based on the matching result, one or more first candidate local image patches with a high degree of similarity to the local query image patch can be determined from the set of local image patches to be matched.
[0046] According to embodiments of this disclosure, local element attributes can be attribute information that characterizes the element type of the local element. For example, local element attributes can be information that characterizes the element type such as "hat", "square glasses", or "plaid shirt".
[0047] According to embodiments of this disclosure, the first candidate local element attribute may be a local element attribute corresponding to a local element represented by the first candidate local image patch. The target query local element attribute may be a local element attribute corresponding to a local element represented by the local query image patch. Determining the target query local element attribute based on the first candidate local element attribute can correct the initial determination result of the local element attribute for the local query image patch, thereby improving the accuracy of determining the local element attribute for the local query image patch.
[0048] According to embodiments of this disclosure, determining a matching image from a set of images to be matched, based on the target query local element attributes, can be done by querying matching images in the set of images to be matched that match the query image, using feature information related to the target query local element attributes in the local query image blocks. Since the target query local element attributes obtained by the method provided in this disclosure can accurately characterize the local elements of the target object in the local query image blocks, determining the matching image based on these attributes makes the similarity of feature information related to the target query local element attributes between the matching image and the query image more precise, thereby improving the similarity between the matching image and the query image and achieving high-precision searching of the query image.
[0049] According to embodiments of this disclosure, the image matching method may further include: performing local element detection on the image to be matched to obtain a local image block to be matched that is related to the local elements of the object to be matched.
[0050] According to embodiments of this disclosure, local element detection can be performed on the image to be matched based on an object detection algorithm, such as the Feature Pyramid Networks (FPN) algorithm, to improve the detection accuracy of local elements of the object to be matched.
[0051] According to embodiments of this disclosure, the image matching method may further include: segmenting the image to be matched to obtain an initial image block to be matched; and performing target detection on the initial image block to be matched to obtain a local image block to be matched related to local elements of the object to be matched.
[0052] According to embodiments of this disclosure, by segmenting the image to be matched to obtain initial image blocks, and performing target detection on the segmented initial image blocks, fine-grained detection of image regions related to local elements in the image to be matched can be achieved. This reduces the false negative rate for image regions related to local elements in the image to be matched, thereby improving the comprehensiveness of the local image blocks in representing local elements. Consequently, the obtained image to be matched can fully and completely represent the object attributes of the object to be matched in the image. This can improve the similarity of the subsequent matching images and enhance the accuracy of image retrieval.
[0053] According to one embodiment of this disclosure, a set of local image blocks to be matched can be constructed by obtaining a first type of local image block to be matched by performing target detection on the whole of the image to be matched.
[0054] In another embodiment of this disclosure, target detection can be performed on the initial image block to be matched obtained from the image block to be matched to obtain a second type of local image block to be matched, and a set of local image blocks to be matched can be constructed based on the second type of local image block to be matched.
[0055] In another embodiment of this disclosure, a set of local image blocks to be matched can be constructed based on a first type of local image block to be matched and a second type of local image block to be matched. This can increase the data scale and data diversity of the local image blocks to be matched, and improve the accuracy of the similarity between the first candidate local image block and the local query image block obtained through subsequent matching.
[0056] It should be noted that the local image patch to be matched and the image to be matched can be stored in the search database based on the image format, or they can be stored in the search database in the feature vector format. The embodiments of this disclosure do not limit the storage format of the local image patch to be matched and the image to be matched, and those skilled in the art can choose according to actual needs.
[0057] According to embodiments of this disclosure, determining a local query image block from a query image associated with a target object may include: in response to detecting a selection operation on the query image, obtaining a local query image block based on the selection operation.
[0058] Figure 3 The illustration shows an application scenario of the image matching method according to an embodiment of the present disclosure.
[0059] like Figure 3 As shown, in this application scenario, a query image 310 and a set of local image blocks to be matched 320 may be included.
[0060] Users can perform a selection operation through the client, thereby generating a query box 301 on the query image 310. Based on the query box 301, a local query image block 311 can be extracted.
[0061] According to embodiments of this disclosure, the similarity between local query image block 311 and local image blocks to be matched in the set of local image blocks to be matched 320 can be calculated to obtain the matching result between the local query image block and the local image blocks to be matched. Based on the numerical value represented by the matching result, the local image blocks to be matched associated with the matching result are sorted to determine the first candidate local image blocks as first candidate local image blocks 321, 322, and 323. The first candidate local element attributes corresponding to the first candidate local image blocks 321, 322, and 323 can be "bow tie", "beard", and "beard", respectively.
[0062] It should be noted that the attributes of the first candidate local elements corresponding to the first candidate local image blocks 321, 322 and 323 can be obtained before the query image 310 is received.
[0063] According to embodiments of this disclosure, there may be one or more first candidate local image blocks, and the number of first candidate local image blocks is not limited in embodiments of this disclosure.
[0064] According to embodiments of this disclosure, when there are multiple first candidate local image blocks, determining the target query local element attribute corresponding to the local query image block based on the first candidate local element attribute corresponding to each of the first candidate local image blocks may include: determining intermediate local element attributes based on the first candidate local element attributes corresponding to each of the multiple first candidate local image blocks; comparing the intermediate local element attributes with the initial query local element attributes to obtain a comparison result, wherein the initial query local element attributes are obtained after performing local element detection on the local query image block; and determining the intermediate local element attributes as the target query local element attributes when the comparison results match.
[0065] like Figure 3 As shown, the intermediate local element attribute is determined based on the first candidate local element attributes corresponding to each of the multiple first candidate local image blocks. For example, the most numerous first candidate local element attribute "beard" can be determined as the intermediate local element attribute 351 based on the first candidate local element attributes corresponding to each of the first candidate local image blocks 321, 322 and 323.
[0066] like Figure 3 As shown, inputting the local query image patch 311 into the local element detection model 330 constructed based on the object detection algorithm can output initial query local element attributes 341, 342, and 343. The initial query local element attributes 341, 342, and 343 can be "bow tie", "beard", and "black suit", respectively.
[0067] The intermediate local element attributes are compared with the initial query local element attributes to obtain the comparison results. For example, the initial query local element attributes 341, 342, and 343 can be compared with the intermediate local element attribute 351. The comparison result shows that the intermediate local element attribute 351 matches the initial query local element attribute 342. Thus, based on the comparison result, the intermediate local element attribute 351 can be determined as the target query local element attribute 361.
[0068] The target query local element attributes obtained by the image matching method provided in this embodiment can be modified or filtered based on the initial query local element attributes, so that the obtained target query local element attributes can relatively accurately represent the characteristics of the target object in the local query image block. In this way, matching images that match the query image can be searched relatively accurately based on the target query local element attributes, thereby improving the fineness and accuracy of image search.
[0069] According to embodiments of this disclosure, a local query image block has a local query image block location.
[0070] According to embodiments of this disclosure, the location of a local query image patch can be the pixel position of a pixel in the local query image patch relative to the pixel position of the query image, for example, the center pixel of the local query image patch relative to the pixel position of the query image. Correspondingly, the local image patch to be matched can also have a location. For example, the center pixel of the local image patch to be matched relative to the pixel position of the image to be matched.
[0071] According to embodiments of this disclosure, determining the target query local element attribute corresponding to the local query image block based on the first candidate local element attribute corresponding to each of the first candidate local image blocks may further include: determining the position of the local query image block and the image block distance between the position of the local query image block and the position of the local image block to be matched in the case of mismatch in the comparison result representation; determining the target local image block from the set of local image blocks to be matched based on the image block distance; and determining the target query local element attribute based on the target local image block.
[0072] According to embodiments of this disclosure, in cases where the comparison results do not represent a match, it can be preliminarily determined that the initial query local element attributes are difficult to accurately represent the local elements in the local query image patch. By calculating the image patch distance between the position of the local query image patch and the position of the local image patch to be matched, the image patch distance can be made to relatively accurately represent the similarity between the local elements of the target object in the local query image patch and the local elements of the object to be matched in the image to be matched.
[0073] According to embodiments of this disclosure, the local image block to be matched corresponding to the smallest image block distance can be determined as the target local image block, and the target query local element attributes can be determined according to the local element attributes corresponding to the target local image block, thereby achieving adaptive correction of the initial query local element attributes to improve the representation accuracy of local elements in the local query image block, and relatively accurately represent the characteristics of the target object in the local query image block. In this way, matching images that match the query image can be searched relatively accurately according to the target query local element attributes, improving the fineness and accuracy of image search.
[0074] According to embodiments of this disclosure, determining a matching image that matches a query image from a set of images to be matched, based on the target query local element attributes, may include: extracting target query local element features related to the target query local element attributes from local query image blocks; filtering out second candidate local image blocks that match the target query local element features from the set of local image blocks to be matched; and filtering out matching images from the set of images to be matched based on the second candidate local image blocks and the query image.
[0075] Figure 4A The schematic diagram illustrates the principle of obtaining a second candidate local image patch according to an embodiment of the present disclosure.
[0076] like Figure 4A As shown, extracting the target query local element features related to the target query local element attributes from the local query image patch can be achieved by inputting the local query image patch 411 into the first feature extraction network 431 constructed based on the convolutional neural network, and outputting the target query local element features 4111.
[0077] From the set of local image patches to be matched, a second candidate local image patch that matches the local element features of the target query is selected. For example, the target query local element feature 4111 and the local image feature 4211 to be matched can be input into the first similarity detection model 432, and the local feature matching result 441 can be output. The first similarity detection model 432 can be constructed based on a similarity algorithm, and the local feature matching result 441 can be the similarity between the target query local element feature 4111 and the local image feature 4211 to be matched.
[0078] It should be noted that the local image feature 4211 to be matched can be an image feature stored in the retrieval library corresponding to the local image patch 421 to be matched. It should be understood that the local image patch 421 to be matched can be input into the first feature extraction network 431 to obtain the local image feature 4211 to be matched. By inputting each of the local image patches in the set to be matched into the first feature extraction network, the local image features corresponding to each local image patch to be matched can be obtained. The local image features to be matched can be associated with the image to be matched through the image identifier. The local image features to be matched can be fed into the retrieval library to form a local image feature library to be matched.
[0079] According to embodiments of this disclosure, the local feature matching results corresponding to each local image feature in the local image feature library to be matched can be sorted, and the local image features to be matched that are ranked in the top N positions (e.g., the top 100) of the local feature matching results can be determined as second candidate local image features. Then, based on the image identifier of the image to be matched associated with the second candidate local image features, a second candidate local image block 451 that matches the target query local element feature 4111 is selected from the image block set 450 to be matched.
[0080] It should be noted that the number of second candidate local image blocks can be one or more, and the embodiments of this disclosure do not limit the number of second candidate local image blocks. When there are multiple second candidate local image blocks, they can constitute a corresponding subset or set of second candidate local image blocks.
[0081] According to embodiments of this disclosure, matching images are filtered from a set of images to be matched based on a second candidate local image patch and a query image. A first candidate image subset is then filtered from the set of images to be matched based on the association between the image identifiers of the second candidate local image patch and the image to be matched. The first candidate image in the first candidate image subset can be associated with the second candidate local image patch through its image identifier. Furthermore, the first candidate image in the first candidate image subset and the query image are input into a scoring model to determine the matching image that matches the query image.
[0082] According to embodiments of this disclosure, the image matching method may further include: performing target object detection on the query image to obtain a query facial image patch related to the face of the target object; and extracting image features of the query facial image patch to obtain query facial image features.
[0083] Figure 4B The schematic diagram illustrates the principle of obtaining a candidate image set according to an embodiment of the present disclosure.
[0084] like Figure 4B As shown, target object detection of the query image can be performed by inputting the query image 410 into the face detection network 433 and outputting a query face image patch 412. The face detection network 433 can be constructed based on an object detection algorithm. Extracting image features from the query face image patch can be done by inputting the query face image patch 412 into a second feature extraction network 434 and outputting query face image features 4121.
[0085] like Figure 4B As shown, the image to be matched 420 in the image set can also be input into the face detection network 433 at any time (e.g., before the query image is obtained), and the output is a face image block 422 to be matched. The face image block 422 to be matched is input into the second feature extraction network 434, and the output is a face image feature 4221 to be matched.
[0086] According to embodiments of this disclosure, selecting a matching image from a set of images to be matched based on a second candidate local image patch and a query image may include: determining a first candidate image subset from the set of images to be matched based on image identifiers associated with the second candidate local image patch; selecting a second candidate image subset from the set of images to be matched that matches the features of the query facial image; performing a similarity evaluation on the candidate images in the candidate image set and the query image to obtain an evaluation result, wherein the candidate image set is constructed based on the first candidate image subset and the second candidate image subset; and determining a matching image from the candidate image set based on the evaluation results corresponding to each candidate image.
[0087] like Figure 4B As shown, the first candidate image can be selected from the image set 4200 to be matched based on the image identifiers corresponding to the second candidate local image blocks in the second candidate local image block set 460, thereby obtaining the first candidate image subset.
[0088] like Figure 4BAs shown, selecting a second candidate image subset that matches the query facial image features from the set of images to be matched can be achieved by inputting the query facial image features 4121 and the facial image features to be matched 4221 into a second similarity detection model 435, and outputting a facial feature matching result 442. The second similarity detection model 435 can be constructed based on a similarity algorithm. The facial feature matching result 442 can characterize the similarity between the query facial image patch 412 and the facial image patch 422 to be matched. Therefore, based on the facial feature matching result 442, it can be determined whether the target object represented by the query facial image patch 412 is the same as the target object represented by the target object in the target facial image patch 422 (i.e., whether the target object and the target object match). Thus, if the facial feature matching result 442 indicates a match, the image to be matched 420 can be determined as a second candidate image that matches the query facial image features. Therefore, a second candidate image subset containing the second candidate image can be selected from the set of images to be matched 4200.
[0089] Candidate image set 470 can be obtained by taking the union of the first candidate image subset and the second candidate image subset, or by taking the intersection of the first candidate image subset and the second candidate image subset.
[0090] According to embodiments of this disclosure, by determining a first candidate image subset from the set of images to be matched based on the local element features of the target query, and determining a second candidate image subset from the set of images to be matched based on the query facial image patch, it is possible to perform differentiated recall of images to be matched that are similar to the query image in the set of images to be matched from different similarity dimensions, thereby increasing the number of images to be matched and improving search accuracy, so as to facilitate subsequent accurate screening of matching images that match the query image.
[0091] In one embodiment of this disclosure, a user can set recall conditions for candidate images through a client. For example, recall conditions such as the identity attribute of the target object in the candidate image and the image acquisition time attribute of the candidate image can be set. During the process of determining candidate images, images that do not meet the recall conditions can be filtered out through the recall conditions to further improve the recall accuracy of candidate images.
[0092] According to embodiments of this disclosure, similarity evaluation is performed on candidate images and query images in a candidate image set to obtain evaluation results. This evaluation result may include: processing candidate images and query images based on a decision tree algorithm, as well as candidate image attribute information of candidate images and query image attribute information of query images, to obtain evaluation results.
[0093] Figure 5 The schematic diagram illustrates the principle of determining a matching image according to an embodiment of the present disclosure.
[0094] like Figure 5 As shown, the decision tree algorithm is used to process candidate images and query images, as well as the candidate image attribute information of the candidate images and the query image attribute information of the query images. For example, the query image 510 can be input into the feature extraction network 530, which outputs query image features 511, and the candidate image 520 can be input into the feature extraction network 530, which outputs candidate image features 521. The query image features 511, candidate image features 521, candidate image attribute information 522 of candidate image 520, and query image attribute information 512 of query image 510 are input into the scoring model 540 constructed based on the decision tree algorithm, and the evaluation result 551 is output.
[0095] Evaluation result 551 can be a score representing the similarity between query image 510 and candidate image 520. By comparing evaluation result 551 with a preset scoring threshold, if evaluation result 551 is greater than or equal to the preset scoring threshold, candidate image 520 will be determined as matching image 560 based on evaluation result 551, thereby achieving the selection of matching image 560 from candidate image set 5200.
[0096] It should be understood that each candidate image in the candidate image set 5200 can be combined with the query image 510 to form query data, and multiple query data can be processed separately according to the scoring model 540, thereby enabling the selection of one or more matching images from the candidate image set 5200, and each matching image can be associated with a corresponding evaluation result.
[0097] It should be noted that candidate image features can also be stored in the search library before the query image is obtained, in order to improve the timeliness of obtaining matching images.
[0098] According to embodiments of this disclosure, the candidate image attribute information includes at least one of the following: the candidate image acquisition time, the geographical location of the image acquisition device acquiring the candidate image, and the resolution of the candidate image.
[0099] According to embodiments of this disclosure, in the field of intelligent security, such as a security detection system equipped with an image acquisition device, the image acquisition time of candidate images can be recorded. By using the image acquisition time to evaluate the similarity of candidate images, the similarity between the recorded time information of the acquired matching image and the query image can be further improved. This allows for the timely detection of situations where the time of appearance of the target object in the query image is highly probable to the time of appearance of the object to be matched, thereby improving the time overlap rate of subsequent target object identification and enhancing security management.
[0100] According to embodiments of this disclosure, the geographical location of the image acquisition device can be obtained simultaneously with its deployment. By processing the geographical location of the image acquisition device using a decision tree algorithm, a comprehensive evaluation can be performed between the geographical locations of the target object in the query image and the geographical locations of the objects to be matched in the candidate images. This allows for the timely discovery of matching images that match the target object, which is beneficial for the timely identification of missing children, the elderly, and other target groups.
[0101] According to embodiments of this disclosure, the resolution of the candidate image can be obtained based on the image quality detection device. By combining the resolution of the candidate image with the resolution of the query image for similarity evaluation, it is possible to filter out candidate images with lower resolution and improve the image quality of the returned matching image.
[0102] It should be noted that in the image matching method provided in the embodiments of this disclosure, the candidate image attribute information may have the same or corresponding attribute information type as the query image attribute information, and the embodiments of this disclosure will not elaborate on this further.
[0103] According to embodiments of this disclosure, candidate image attribute information may also include other types of attribute information, such as local element attributes corresponding to candidate local image patches in the candidate image, saturation, brightness, etc. of the candidate image. Embodiments of this disclosure do not limit the specific type of attribute information for candidate image attribute information.
[0104] It should be noted that the image matching method provided in this disclosure can be applied to the fields of intelligent security and intelligent city management. Alternatively, it can be used in other fields; the embodiments of this disclosure do not limit the specific application areas of the image matching method.
[0105] For example, based on the query image entered by the administrator with the relevant permissions, matching images that match the query image can be searched, thereby helping the relevant administrators to quickly and accurately obtain relevant clues about the target object in the query image, which helps to improve the level of security.
[0106] For example, based on the query image entered by an administrator with the relevant permissions, matching images related to the missing elderly person in the query image can be found, thereby promptly discovering clues about the missing person and helping relevant personnel to quickly locate the missing person.
[0107] It should be noted that the acquisition of data involved in the image matching method provided in this disclosure, including but not limited to query images and images to be matched, is obtained with the authorization of relevant users or organizations. The image processing process and purpose are disclosed to the user in advance, and necessary encryption measures are taken for the data, which complies with the provisions of relevant laws and regulations.
[0108] Figure 6 A block diagram of an image matching apparatus according to an embodiment of the present disclosure is shown schematically.
[0109] like Figure 6 As shown, the image matching device 600 includes: a local query image block determination module 610, a first candidate local image block acquisition module 620, a target query local element attribute determination module 630, and a matching image determination module 640.
[0110] The local query image block determination module 610 is used to determine local query image blocks from the query image when a query image related to the target object is received. The local query image blocks are related to local elements of the target object.
[0111] The first candidate local image block acquisition module 620 is used to determine at least one first candidate local image block from the set of local image blocks to be matched based on the matching result between the local query image block and the local image block to be matched, wherein the local image block to be matched is obtained from the image to be matched.
[0112] The target query local element attribute determination module 630 is used to determine the target query local element attribute corresponding to the local query image block based on the first candidate local element attribute corresponding to each of the first candidate local image blocks.
[0113] The matching image determination module 640 is used to determine the matching image that matches the query image from a set of images containing the image to be matched, based on the local element attributes of the target query.
[0114] According to embodiments of this disclosure, the first candidate local image block includes a plurality of blocks.
[0115] The target query local element attribute determination module includes: an intermediate local element attribute acquisition submodule, a comparison result acquisition submodule, and a first target query local element attribute acquisition submodule.
[0116] The intermediate local element attribute acquisition submodule is used to determine the intermediate local element attributes based on the first candidate local element attributes corresponding to each of the multiple first candidate local image blocks.
[0117] The comparison result acquisition submodule is used to compare the intermediate local element attributes with the initial query local element attributes to obtain the comparison result. The initial query local element attributes are obtained after performing local element detection on the local query image patch.
[0118] The first target query local element attribute acquisition submodule is used to determine the intermediate local element attributes as the target query local element attributes when the comparison results match.
[0119] According to embodiments of this disclosure, a local query image block has a local query image block location.
[0120] The target query local element attribute determination module includes: an image patch distance acquisition submodule, a target local image patch acquisition submodule, and a second target query local element attribute acquisition submodule.
[0121] The image patch distance acquisition submodule is used to determine the image patch distance between the location of the local query image patch and the location of the local image patch to be matched when the comparison results do not match.
[0122] The target local image patch acquisition submodule is used to determine the target local image patch from the set of local image patches to be matched based on the image patch distance.
[0123] The second target query local element attribute acquisition submodule is used to determine the target query local element attributes based on the target local image patch.
[0124] According to embodiments of this disclosure, the matching image determination module includes: a target query local element feature extraction submodule, a first filtering submodule, and a second filtering submodule.
[0125] The target query local element feature extraction submodule is used to extract the target query local element features in the local query image patch that are related to the target query local element attributes.
[0126] The first filtering submodule is used to filter out second candidate local image patches from the set of local image patches to be matched that match the features of the target query local elements.
[0127] The second filtering submodule is used to filter out matching images from the set of images to be matched based on the second candidate local image patch and the query image.
[0128] According to embodiments of this disclosure, the image matching apparatus further includes: a module for obtaining query facial image blocks and a module for obtaining query facial image features.
[0129] The query face image patch acquisition module is used to perform target object detection on the query image and obtain query face image patches related to the face of the target object.
[0130] The facial image feature acquisition module is used to extract the image features of the query facial image patch to obtain the query facial image features.
[0131] According to embodiments of this disclosure, the second candidate local image block of the second screening submodule includes: a first candidate image subset acquisition unit, a second candidate image subset acquisition unit, an evaluation result acquisition unit, and a matching image acquisition unit.
[0132] The first candidate image subset acquisition unit is used to determine the first candidate image subset from the set of images to be matched based on the image identifier associated with the second candidate local image patch.
[0133] The second candidate image subset acquisition unit is used to filter out a second candidate image subset from the set of images to be matched that matches the features of the query facial image.
[0134] The evaluation result acquisition unit is used to evaluate the similarity between the candidate images in the candidate image set and the query image, and obtain the evaluation result. The candidate image set is constructed based on the first candidate image subset and the second candidate image subset.
[0135] The matching image acquisition unit is used to determine the matching image from the candidate image set based on the evaluation results corresponding to each candidate image.
[0136] According to embodiments of this disclosure, the evaluation result obtaining unit includes an evaluation result obtaining subunit.
[0137] The evaluation result is used to obtain a sub-unit, which is used to process candidate images and query images based on the decision tree algorithm, as well as the candidate image attribute information of the candidate images and the query image attribute information of the query images, to obtain the evaluation result.
[0138] According to embodiments of this disclosure, the candidate image attribute information includes at least one of the following: the candidate image acquisition time, the geographical location of the image acquisition device acquiring the candidate image, and the resolution of the candidate image.
[0139] According to embodiments of this disclosure, the local query image block determination module includes a local query image block acquisition submodule.
[0140] The local query image patch acquisition submodule is used to obtain local query image patches in response to the detection of a bounding box operation on the query image, based on the bounding box operation.
[0141] According to embodiments of the present disclosure, the image matching apparatus further includes: an initial image block acquisition module and a local image block acquisition module.
[0142] The initial image block acquisition module is used to segment the image to be matched and obtain the initial image block to be matched.
[0143] The module for obtaining local image patches to be matched is used to perform target detection on the initial image patch to be matched, and obtain the local image patch to be matched related to the local elements of the object to be matched.
[0144] According to embodiments of this disclosure, this disclosure also provides an electronic device, a readable storage medium, and a computer program product.
[0145] According to an embodiment of the present disclosure, an electronic device includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform the method described above.
[0146] According to embodiments of the present disclosure, a non-transitory computer-readable storage medium stores computer instructions, wherein the computer instructions are used to cause a computer to perform the method described above.
[0147] According to an embodiment of this disclosure, a computer program product includes a computer program that, when executed by a processor, implements the method described above.
[0148] Figure 7 A schematic block diagram of an example electronic device 700 that can be used to implement embodiments of the present disclosure is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the present disclosure described and / or claimed herein.
[0149] like Figure 7 As shown, device 700 includes a computing unit 701, which can perform various appropriate actions and processes based on a computer program stored in read-only memory (ROM) 702 or a computer program loaded from storage unit 708 into random access memory (RAM) 703. RAM 703 may also store various programs and data required for the operation of device 700. The computing unit 701, ROM 702, and RAM 703 are interconnected via bus 704. Input / output (I / O) interface 705 is also connected to bus 704.
[0150] Multiple components in device 700 are connected to I / O interface 705, including: input unit 706, such as keyboard, mouse, etc.; output unit 707, such as various types of monitors, speakers, etc.; storage unit 708, such as disk, optical disk, etc.; and communication unit 709, such as network card, modem, wireless transceiver, etc. Communication unit 709 allows device 700 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.
[0151] The computing unit 701 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the computing unit 701 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 701 performs the various methods and processes described above, such as the image matching method. For example, in some embodiments, the image matching method may be implemented as a computer software program tangibly contained in a machine-readable medium, such as storage unit 708. In some embodiments, part or all of the computer program may be loaded and / or installed on device 700 via ROM 702 and / or communication unit 709. When the computer program is loaded into RAM 703 and executed by the computing unit 701, one or more steps of the image matching method described above may be performed. Alternatively, in other embodiments, the computing unit 701 may be configured to perform the image matching method by any other suitable means (e.g., by means of firmware).
[0152] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SoCs), payload-programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.
[0153] The program code used to implement the methods of this disclosure may be written in any combination of one or more programming languages. This program code may be provided to a processor or controller of a general-purpose computer, special-purpose computer, or other programmable data processing apparatus, such that when executed by the processor or controller, the program code causes the functions / operations specified in the flowcharts and / or block diagrams to be implemented. The program code may be executed entirely on a machine, partially on a machine, as a standalone software package partially on a machine and partially on a remote machine, or entirely on a remote machine or server.
[0154] In the context of this disclosure, a machine-readable medium can be a tangible medium that may contain or store a program for use by or in conjunction with an instruction execution system, apparatus, or device. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can be, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
[0155] To provide interaction with a user, the systems and techniques described herein can be implemented on a computer having: a display device for displaying information to the user (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor); and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the computer. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).
[0156] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as a data server), or computing systems that include middleware components (e.g., an application server), or computing systems that include frontend components (e.g., a user computer with a graphical user interface or web browser through which a user can interact with embodiments of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., a communication network). Examples of communication networks include local area networks (LANs), wide area networks (WANs), and the Internet.
[0157] Computer systems can include clients and servers. Clients and servers are generally located far apart and typically interact via communication networks. Client-server relationships are created by computer programs running on the respective computers and having a client-server relationship with each other. Servers can be cloud servers, distributed system servers, or servers incorporating blockchain technology.
[0158] It should be understood that the various forms of processes shown above can be used to reorder, add, or delete steps. For example, the steps described in this disclosure can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution disclosed in this disclosure can be achieved, and this is not limited herein.
[0159] The specific embodiments described above do not constitute a limitation on the scope of protection of this disclosure. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this disclosure should be included within the scope of protection of this disclosure.
Claims
1. An image matching method, comprising: In response to detecting a bounding box operation on a query image related to a target object, a local query image patch is obtained based on the bounding box operation, the local query image patch representing local elements related to the body of the target object; Based on the matching result between the local query image patch and the local image patch to be matched, at least one first candidate local image patch is determined from the set of local image patches to be matched, wherein the local image patch to be matched is obtained from the image to be matched; Based on the attributes of the first candidate local elements corresponding to each of the multiple first candidate local image blocks, determine the intermediate local element attributes that characterize the element type. The intermediate local element attributes and the initial query local element attributes are compared to obtain the comparison result, wherein the initial query local element attributes are obtained after performing local element detection on the local query image block; If the comparison results match, the intermediate local element attribute is determined as the target query local element attribute corresponding to the local query image block, and the local query image block has a local query image block position. In the case where the comparison results do not match, a target local image block is determined from the set of local image blocks to be matched based on the image block distance between the location of the local query image block and the location of the local image block to be matched, and the target query local element attribute is determined based on the target local image block. Based on the local element attributes of the target query, a matching image that matches the query image is determined from the set of images to be matched that contains the image to be matched.
2. The method according to claim 1, wherein, The step of determining a matching image that matches the query image from a set of images containing the image to be matched based on the local element attributes of the target query includes: Extract the target query local element features from the local query image patch that are related to the target query local element attributes; From the set of local image patches to be matched, a second candidate local image patch that matches the features of the target query local element is selected; Based on the second candidate local image patch and the query image, the matching image is selected from the set of images to be matched.
3. The method according to claim 2, further comprising: Target object detection is performed on the query image to obtain query facial image blocks related to the face of the target object; as well as Extract the image features of the query facial image block to obtain the query facial image features.
4. The method according to claim 3, wherein, The step of filtering the matching image from the set of images to be matched based on the second candidate local image patch and the query image includes: A first candidate image subset is determined from the set of images to be matched based on the image identifiers associated with the second candidate local image patch; From the set of images to be matched, a second subset of candidate images that matches the features of the queried facial image is selected; The similarity between the candidate images in the candidate image set and the query image is evaluated to obtain an evaluation result, wherein the candidate image set is constructed based on the first candidate image subset and the second candidate image subset; and The matching image is determined from the candidate image set based on the evaluation results corresponding to each candidate image.
5. The method according to claim 4, wherein, The similarity evaluation between the candidate images in the candidate image set and the query image yields the following evaluation results: The evaluation result is obtained by processing the candidate image and the query image, as well as the candidate image attribute information and the query image attribute information of the candidate image, based on the decision tree algorithm.
6. The method according to claim 5, wherein, The candidate image attribute information includes at least one of the following: The candidate image acquisition time, the geographical location of the image acquisition device acquiring the candidate image, and the resolution of the candidate image.
7. The method according to any one of claims 1 to 6, further comprising: The image to be matched is segmented to obtain initial image blocks to be matched; as well as Target detection is performed on the initial image block to be matched to obtain the local image block to be matched that is related to the local elements of the object to be matched.
8. An image matching device, comprising: A local query image patch determination module is used to determine local query image patches from a query image that is related to a target object when a query image is received, wherein the local query image patches represent local elements related to the body of the target object; The first candidate local image patch acquisition module is used to determine at least one first candidate local image patch from the set of local image patches to be matched based on the matching result between the local query image patch and the local image patch to be matched, wherein the local image patch to be matched is obtained from the image to be matched; The target query local element attribute determination module is used to determine the target query local element attribute corresponding to the local query image patch based on the first candidate local element attributes corresponding to each of the first candidate local image patches; and The matching image determination module is used to determine a matching image that matches the query image from a set of images containing the image to be matched, based on the local element attributes of the target query. The local query image patch determination module includes: A local query image block acquisition submodule is used to obtain the local query image block in response to detecting a selection operation for the query image, based on the selection operation. The first candidate local image block includes multiple blocks; The target query local element attribute determination module includes: The intermediate local element attribute acquisition submodule is used to determine the intermediate local element attributes that characterize the element type based on the first candidate local element attributes corresponding to each of the multiple first candidate local image blocks. The comparison result acquisition submodule is used to compare the intermediate local element attributes with the initial query local element attributes to obtain the comparison result, wherein the initial query local element attributes are obtained after performing local element detection on the local query image block; The first target query local element attribute acquisition submodule is used to determine the intermediate local element attribute as the target query local element attribute when the comparison result representation matches. The local query image block has a local query image block location; The target query local element attribute determination module includes: The image patch distance acquisition submodule is used to determine the image patch distance between the position of the local query image patch and the position of the local image patch to be matched when the comparison result representation does not match. A target local image patch acquisition submodule is used to determine a target local image patch from the set of local image patches to be matched based on the image patch distance; and The second target query local element attribute acquisition submodule is used to determine the target query local element attributes based on the target local image patch.
9. The apparatus according to claim 8, wherein, The matching image determination module includes: The target query local element feature extraction submodule is used to extract the target query local element features related to the target query local element attributes in the local query image patch; The first filtering submodule is used to filter out second candidate local image patches from the set of local image patches to be matched that match the features of the target query local element; The second filtering submodule is used to filter out the matching image from the set of images to be matched based on the second candidate local image block and the query image.
10. The apparatus according to claim 9, further comprising: The query face image patch acquisition module is used to perform target object detection on the query image and obtain query face image patches related to the face of the target object; as well as The facial image feature acquisition module is used to extract the image features of the query facial image block to obtain the query facial image features.
11. The apparatus according to claim 10, wherein, The second filtering submodule includes: The first candidate image subset obtaining unit is configured to determine a first candidate image subset from the set of images to be matched based on the image identifier associated with the second candidate local image patch; The second candidate image subset obtaining unit is used to filter out a second candidate image subset that matches the features of the query facial image from the set of images to be matched; An evaluation result acquisition unit is used to evaluate the similarity between candidate images in the candidate image set and the query image to obtain an evaluation result, wherein the candidate image set is constructed based on the first candidate image subset and the second candidate image subset; and The matching image acquisition unit is used to determine the matching image from the candidate image set based on the evaluation results corresponding to each of the candidate images.
12. The apparatus according to claim 11, wherein, The evaluation result acquisition unit includes: The evaluation result acquisition subunit is used to process the candidate image and the query image, as well as the candidate image attribute information of the candidate image and the query image attribute information of the query image, based on the decision tree algorithm, to obtain the evaluation result.
13. The apparatus according to claim 12, wherein, The candidate image attribute information includes at least one of the following: The candidate image acquisition time, the geographical location of the image acquisition device acquiring the candidate image, and the resolution of the candidate image.
14. The apparatus according to any one of claims 8 to 13, further comprising: The initial image block acquisition module is used to segment the image to be matched to obtain an initial image block to be matched. as well as The module for obtaining local image patches to be matched is used to perform target detection on the initial image patch to be matched, and obtain the local image patch to be matched related to the local elements of the object to be matched.
15. An electronic device comprising: At least one processor; as well as A memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor to enable the at least one processor to perform the method of any one of claims 1 to 7.
16. A non-transitory computer-readable storage medium storing computer instructions, wherein, The computer instructions are used to cause the computer to perform the method according to any one of claims 1 to 7.
17. A computer program product comprising a computer program that, when executed by a processor, implements the method according to any one of claims 1 to 7.