Feature search method and device, equipment and storage medium

By constructing an image source linked list and performing feature search in a feature set, the problems of low accuracy and waste of computing resources in pedestrian recognition in scenes with high crowd density are solved, and efficient and accurate feature recognition is achieved.

CN115455215BActive Publication Date: 2025-10-10GUANGZHOU TUPU NETWORK TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211299172.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-10-24
Publication Date
2025-10-10
Estimated Expiration
2042-10-24

AI Technical Summary

Technical Problem

In scenarios with high crowd density, such as commercial properties and hospitals, existing technologies cannot effectively identify pedestrian features, resulting in low recognition accuracy and waste of computing resources.

Method used

By building a linked list with preset image source information, the image source to be searched is determined, and feature search is performed in its feature set. Combined with the feature similarity algorithm, the information of the same person is configured to have the same identifier, and the information of different people is configured to have different identifiers.

Benefits of technology

It improves the accuracy and efficiency of feature search, reduces the consumption of computing resources, and increases processing speed.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115455215B_ABST
    Figure CN115455215B_ABST
Patent Text Reader

Abstract

The application provides a feature search method and device, equipment and a storage medium, and relates to the technical field of data analysis. The feature search method comprises the following steps: performing person identification on a to-be-identified image collected by a preset image source in a preset scene to obtain first person information in the to-be-identified image; determining a to-be-searched image source from a plurality of image sources according to information of the preset image source; performing feature search on a preset database according to first feature information in the first person information to obtain second feature information satisfying a preset similarity condition; determining second person information corresponding to the first person information according to the second feature information; determining that the first person information and the second person information are information of one person, and configuring one person identifier for the information of one person, so that the information of the same person has the same person identifier, and the information of different persons has different person identifiers. The method provided by the application can effectively improve the feature search and identification efficiency and save computing resources.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of data analysis technology, and in particular to a feature search method, device, equipment and storage medium. Background Art

[0002] With the increasing development of artificial intelligence, the optimization and iteration of model algorithms such as deep learning and neural networks, the accuracy of machine recognition of individuals is almost the same as that of human observation and recognition with the naked eye, and there are more and more technologies and applications based on human feature recognition.

[0003] Currently, existing technologies can search, track, and identify pedestrians in surveillance scenarios. However, for business scenarios with high crowd density, such as commercial real estate and hospitals, since these scenarios cover a large area, have many floors, and have a large number of cameras, using cameras to identify pedestrian features will face the problems of high crowd density and large amount of recognition data, and existing technologies cannot accurately identify people.

[0004] Therefore, it is necessary to propose a feature search method that can use the large number of features to perform feature similarity search when the number of features is extremely large, thereby improving the accuracy of recognition, saving computing resources, and improving the real-time performance of recognition. Summary of the Invention

[0005] The purpose of the present invention is to provide a feature search method, device, equipment and storage medium to address the deficiencies in the above-mentioned prior art, so as to improve the accuracy and efficiency of feature search.

[0006] To achieve the above objectives, the technical solutions adopted in the embodiments of the present application are as follows:

[0007] In a first aspect, an embodiment of the present application provides a feature search method, comprising:

[0008] Performing person recognition on an image to be identified that is captured by a preset image source in a preset scene to obtain at least one piece of first person information in the image to be identified; each piece of first person information includes: first feature information and information about the preset image source;

[0009] Determining an image source to be searched from a plurality of image sources in the preset scene according to the information of the preset image source;

[0010] performing a feature search on a feature set corresponding to the image source to be searched in a preset database based on the first feature information in each piece of the first person information, to obtain at least one piece of second feature information that satisfies a preset similarity condition with the first feature information; the preset database comprising: a plurality of pieces of second person information, each piece of second information comprising: second feature information and image source information corresponding to the second feature information;

[0011] Determining, based on the at least one piece of second characteristic information, at least one piece of second character information corresponding to each piece of first character information;

[0012] Determine that each piece of first character information and at least one piece of second character information corresponding to each piece of first character information is information of one character, and configure a character identifier for the information of one character, so that information of the same character has the same character identifier, and information of different characters has different character identifiers.

[0013] In an optional embodiment, determining the image source to be searched from the plurality of image sources in the preset scene according to the information of the preset image source includes:

[0014] According to the information of the preset image source, a linked list of areas where the preset image source is located is obtained; the linked list of areas where the preset image source is located records: information of each image source within the area where the preset image source is located, and positional relationships between the image sources;

[0015] The image source to be searched is determined from the image sources within the area where the preset image source is located according to the positional relationship between the image sources.

[0016] In an optional embodiment, determining the image source to be searched from the image sources based on the positional relationship between the image sources includes:

[0017] According to the positional relationship between the image sources, an image source within a preset range centered on the preset image source is determined from the image sources as the image source to be searched.

[0018] In an optional embodiment, before obtaining the linked list of areas where the preset image sources are located based on the information of the preset image sources, the method further includes:

[0019] According to the information and positional relationship of each image source in each area of ​​the preset scene, a linked list of each area is constructed.

[0020] In an optional embodiment, the method further comprises:

[0021] If the at least one piece of second feature information does not exist in the feature set corresponding to the image source to be searched, a character identifier is added to each piece of first character information.

[0022] In an optional embodiment, the method further includes: identifying information of a linked list of the region;

[0023] The information of the person and the information of the image source to be searched are stored in the preset database.

[0024] In an optional embodiment, before determining the image source to be searched from the plurality of image sources in the preset scene based on the information of the preset image source, the method further includes:

[0025] Storing the at least one first person information in a preset message queue;

[0026] The step of determining the image source to be searched from the plurality of image sources in the preset scene according to the information of the preset image source includes:

[0027] Obtaining first person information from the preset message queue;

[0028] The image source to be searched is determined from the multiple image sources according to the information of the preset image source in the acquired first person information.

[0029] In a second aspect, an embodiment of the present application further provides a feature search device, comprising:

[0030] an identification module configured to perform person identification on an image to be identified that is captured by a preset image source in a preset scene, and obtain at least one first person information item in the image to be identified; each first person information item includes: first feature information and information about the preset image source;

[0031] A first determining module is configured to determine an image source to be searched from a plurality of image sources in the preset scene according to information of the preset image source;

[0032] A search module is configured to perform a feature search on a feature set corresponding to the image source to be searched in a preset database based on the first feature information in each piece of first character information, to obtain at least one second feature information that satisfies a preset similarity condition with the first feature information; the preset database includes: a plurality of second character information pieces, each second information piece including: second feature information and image source information corresponding to the second feature information;

[0033] a second determining module, configured to determine, based on the at least one piece of second characteristic information, at least one piece of second character information corresponding to each piece of first character information;

[0034] The configuration module is used to determine that each piece of first character information and at least one piece of second character information corresponding to each piece of first character information is information of one character, and configure a character identifier for the information of one character, so that the information of the same character has the same character identifier, and the information of different characters has different character identifiers.

[0035] In a third aspect, the present invention provides a computer device comprising: a processor, a storage medium and a bus, wherein the storage medium stores program instructions executable by the processor. When the computer device is running, the processor and the storage medium communicate through the bus, and the processor executes the program instructions to perform the steps of the feature search method as described in any of the aforementioned embodiments.

[0036] In a fourth aspect, the present invention provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the steps of the feature search method as described in any of the aforementioned embodiments are executed.

[0037] The beneficial effects of this application are:

[0038] In summary, the embodiments of the present application provide a feature search method, apparatus, device and storage medium, including: performing person recognition on an image to be identified collected from a preset image source in a preset scene to obtain at least one first person information in the image to be identified; determining the image source to be searched from multiple image sources in the preset scene based on the information of the preset image source; performing a feature search on a feature set corresponding to the image source to be searched in a preset database based on the first feature information in each first person information, to obtain at least one second feature information that meets a preset similarity condition with the first feature information; determining at least one second person information corresponding to each first person information based on the at least one second feature information; determining each first person information and at least one second person information corresponding to each first person information as information of one person, and configuring a person identifier for the information of one person, so that the information of the same person has the same person identifier, and the information of different people has different person identifiers. The method of the present application determines the image source to be searched from multiple image sources in a preset scene by presetting image source information. When performing feature search on the first feature information identified in the image to be identified, it is only necessary to perform feature search in the feature set corresponding to the image source to be searched, without performing feature search in the entire preset database, which reduces the feature search range and the search calculation amount. At the same time, it also ensures the connectivity of features between image sources, avoids searching all features in the scenario of feature similarity search of large-scale image source scenes, and increases the complexity of calculation. By using the method of the present application, the processing speed can be effectively accelerated, the feature search and recognition efficiency can be improved, computing resources can be saved, and the feature search accuracy can be guaranteed. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments. It should be understood that the following drawings only illustrate certain embodiments of the present invention and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other relevant drawings can be obtained based on these drawings without paying any creative work.

[0040] Figure 1 A flowchart of a feature search method provided in an embodiment of the present application;

[0041] Figure 2 A flowchart of another feature search method provided in an embodiment of the present application;

[0042] Figure 3 A flowchart of another feature search method provided in an embodiment of the present application;

[0043] Figure 4 A schematic diagram of the functional modules of a feature search device provided in an embodiment of the present application;

[0044] Figure 5 A schematic diagram of a computer device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0045] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments.

[0046] Therefore, the following detailed description of the embodiments of the present application provided in the accompanying drawings is not intended to limit the scope of the present application for protection, but merely represents selected embodiments of the present application. All other embodiments obtained by persons of ordinary skill in the art based on the embodiments in the present application without creative work are within the scope of protection of the present application.

[0047] In the description of this application, it should be noted that if the terms "upper", "lower", etc. appear, the orientation or position relationship indicated is based on the orientation or position relationship shown in the accompanying drawings, or is the orientation or position relationship in which the product of the application is usually placed when in use. It is only for the convenience of describing this application and simplifying the description, and does not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation. Therefore, it cannot be understood as a limitation on this application.

[0048] In addition, the terms "first," "second," and the like in the description and claims of the present invention and the accompanying drawings are used to distinguish similar objects and are not necessarily used to describe a particular order or precedence. It should be understood that the terms used in this manner are interchangeable where appropriate so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having," as well as any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, product, or apparatus comprising a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units that are not explicitly listed or that are inherent to these processes, methods, products, or apparatus.

[0049] It should be noted that, in the absence of conflict, the features in the embodiments of this application can be combined with each other.

[0050] In order to realize the search for character features and make the search for character features more accurate, an embodiment of the present application provides a feature search method, which can filter through a multi-level bidirectional linked list to reduce the feature search range, improve the efficiency of feature search, and improve the accuracy of feature recognition.

[0051] The following describes a detailed explanation of the feature search method provided in the embodiments of the present application using specific examples in conjunction with the accompanying drawings. The feature search method provided in the embodiments of the present application can be implemented by running a computer device pre-installed with a preset model training algorithm or detection software. The computer device can be, for example, a server or a terminal, and the terminal can be a user's computer. Figure 1 This is a flow chart of a feature search method provided in an embodiment of the present application. Figure 1 As shown, the method includes:

[0052] S101: Perform person recognition on an image to be identified that is collected from a preset image source in a preset scene to obtain at least one first person information in the image to be identified.

[0053] In this embodiment, the preset scene may be a crowded scene, such as a commercial scene, a medical scene, a real estate scene, or a scene with a large number of pedestrians. Multiple image acquisition devices, such as cameras, are pre-deployed in the preset scene. The preset image source may be any of the multiple image acquisition devices in the preset scene. The multiple image acquisition devices in the preset scene may be devices that capture images or devices that capture videos. If the preset image source is a device that captures images, the preset image source is an image source; if the preset image source is a device that captures videos, the preset image source is a video source.

[0054] After obtaining the to-be-recognized image, the to-be-recognized image can be preprocessed, and then the preprocessed image is subjected to person recognition to obtain at least one piece of first person information.

[0055] The preprocessing of the to-be-recognized image may, for example, include the following:

[0056] If the preset image source is a video source, the video in the video source needs to be subjected to a screenshot operation according to a parameter rule to obtain the to-be-recognized image, where the parameter rule may be a screenshot size, a screenshot frequency, etc. If the preset image source is a picture source, the to-be-recognized image can be directly obtained, and then the obtained to-be-recognized image is subjected to image compression to reduce the image size and reduce the consumption in the subsequent to-be-recognized image processing flow, such as bandwidth, so as to make the to-be-recognized image processing faster.

[0057] In a possible implementation manner, the to-be-recognized image can be subjected to person detection to obtain information of a person detection frame, and feature extraction is performed according to the person detection frame to obtain at least one piece of first feature information. The information of the preset image source and the at least one piece of first feature information are used to generate at least one piece of first person information. The information of the person detection frame may, for example, be position information of the person detection frame in the to-be-recognized image. The feature extraction according to the person detection frame may, for example, include: first performing person feature extraction according to the person detection frame to obtain at least one piece of person feature information, and performing person attribute extraction according to each piece of person feature information to obtain person attribute information. Correspondingly, each piece of first feature information includes one piece of person feature information and one piece of person attribute information. The person feature information may, for example, include a person facial feature and / or a person body feature, and the person attribute information includes an age, a gender, a clothing combination, etc.

[0058] The information of the preset image source is an identifier of the preset image source or position information in the preset scene, which can be used to represent the source information of the to-be-recognized image.

[0059] It should be noted that, in order to protect the information privacy and security of the person, the person detection frame can be subjected to mosaic processing before the person feature extraction according to the person detection frame.

[0060] S102, according to the information of the preset image source, determining a to-be-searched image source from a plurality of image sources in a preset scene.

[0061] Specifically, the area where the preset image source is located in the preset scene is determined according to the information of the preset image source, and then the to-be-searched image source is determined according to the area where the preset image source is located in the preset scene.

[0062] S103: Based on the first feature information in each piece of first person information, perform a feature search on a feature set corresponding to the image source to be searched in a preset database to obtain at least one piece of second feature information that meets a preset similarity condition with the first feature information.

[0063] The preset database includes: a plurality of second person information, each second information includes: second feature information, and image source information corresponding to the second feature information.

[0064] In this embodiment, the preset database stores: at least one second character information obtained in advance, and at least one second character information can be character information obtained by historical identification. In each second character information, the second feature information and the information of the image source corresponding to the second feature information can be pre-bound feature information and image source information. Among them, the length of the character feature information in the second feature information can be, for example, a preset feature length, such as 512 features. If the length of the identified character feature information is 256, and the storage requirements of the preset database indicate that the length of a single character feature information is 512, then the identified character feature information must first be padded with zeros to make it conform to the preset feature length. In the case of the acquired second feature information and the information of the image source corresponding to the second feature information, the second feature information and the information of the image source corresponding to the second feature information can be organized into a preset storage data structure of the preset database and then stored in the preset database.

[0065] The preset database has the ability of feature search and query filtering. That is to say, in this embodiment, based on the first feature information, a feature similarity algorithm can be used to perform feature search on the feature set corresponding to the image source to be searched in the preset database to obtain at least one second feature information that meets the preset similarity condition with the first feature information. The preset feature similarity algorithm can be, for example, a K-Nearest Neighbor (KNN) algorithm, a dot product algorithm, a cosine distance algorithm, a Hamming distance algorithm, a Manhattan distance algorithm, a Pearson correlation coefficient algorithm, a Euclidean distance algorithm, etc. The preset similarity condition can preset a similarity threshold. Among them, each second feature information obtained by the search is the second feature information whose similarity with the first feature information in the preset database reaches or exceeds the preset similarity threshold.

[0066] It should be noted that feature search can be performed based on the character attribute information in each first feature information, and the feature search range can be further narrowed down by the feature set in the image source to be searched. For example, if the character attribute information in the first feature information includes: gender: male, age: 20-40 years old, clothing combination: black top, etc., the feature set range in the image source to be searched can be narrowed down by the character attribute information, and other first feature information that does not conform to the character attribute information can be excluded, so as to more quickly obtain at least one second feature information that meets the preset similarity condition with the first feature information, thereby improving the feature search efficiency.

[0067] Since the second feature information and the information of the preset image source are stored one by one as the second character information in the preset database, when the second feature information is searched and obtained, the image source information corresponding to the second feature information can be obtained, which can indicate that the second feature information is a feature obtained by image recognition based on the corresponding image source information.

[0068] During the specific implementation process, a query statement can be generated based on the first feature information in each first character information and the information of the image source to be searched, and based on the query statement, a feature search is performed on the feature set corresponding to the image source to be searched in the preset database to obtain at least one second feature information that meets the preset similarity condition with the first feature information.

[0069] S104: Determine, based on the at least one piece of second characteristic information, at least one piece of second character information corresponding to each piece of first character information.

[0070] Since the second characteristic information and the information of the preset image source are stored one by one as the second character information, the second character information where at least one second characteristic information is located can be the at least one second character information corresponding to each first character information.

[0071] S105: Determine that each piece of first character information and at least one piece of second character information corresponding to each piece of first character information is information of one character, and configure a character identifier for the information of one character, so that information of the same character has the same character identifier, and information of different characters has different character identifiers.

[0072] Specifically, at least one second feature information that meets a preset similarity condition with the first feature information is obtained through a feature similarity algorithm. The second character information in which the at least one second feature information is located is at least one second character information corresponding to each first character information, and a character identifier (Identity document, Id) is configured for the information of a character. That is, if the first character information and the second character information are the character information of the same person, the same character tag, i.e., Id, is assigned to the character, so that the information of the same character has the same character identifier, and the information of different characters has different character identifiers.

[0073] In summary, an embodiment of the present application provides a feature search method, which may include performing person recognition on an image to be identified collected from a preset image source in a preset scene to obtain at least one first person information in the image to be identified; determining the image source to be searched from multiple image sources in the preset scene based on the information of the preset image source; performing a feature search on a feature set corresponding to the image source to be searched in a preset database based on the first feature information in each first person information, to obtain at least one second feature information that meets a preset similarity condition with the first feature information; determining at least one second person information corresponding to each first person information based on the at least one second feature information; determining each first person information and at least one second person information corresponding to each first person information as information of one person, and configuring a person identifier for the information of one person, so that the information of the same person has the same person identifier, and the information of different people has different person identifiers. The method of the present application determines the image source to be searched from multiple image sources in a preset scene by presetting image source information. When performing feature search on the first feature information identified in the image to be identified, it is only necessary to perform feature search in the feature set corresponding to the image source to be searched, without performing feature search in the entire preset database, which makes the feature search range smaller and the search calculation amount smaller. At the same time, it also ensures the connectivity of features between image sources, avoids searching all features in the scenario of feature similarity search of large-scale image source scenes, and increases the complexity of calculation. By using the method of the present application, the processing speed can be effectively accelerated, the feature search and recognition efficiency can be improved, computing resources can be saved, and the feature search accuracy can be guaranteed.

[0074] Based on the feature search method provided in the above embodiment, the embodiment of the present application also provides another possible implementation example of the feature search method. Figure 2 This is a flow chart of another feature search method provided in the embodiment of the present application. Figure 2 As shown, according to the information of the preset image source, determining the image source to be searched from multiple image sources in the preset scene includes:

[0075] S201. Obtain a linked list of areas where the preset image source is located according to information of the preset image source.

[0076] The linked list of the area where the preset image source is located records: information of each image source in the area where the preset image source is located, and the positional relationship between each image source.

[0077] In this embodiment, based on the information of the preset image source, the area where the preset image source is located in the preset scene is determined. Since linked list nodes are configured for the image sources in the area where the preset image source is located in the preset scene, and each linked list node can be connected to multiple nodes adjacent to each other, thereby obtaining a linked list of the preset scene area where the preset image source is located, the linked list of the preset scene area where the preset image source is located records the information of other image sources in the area where the preset image source is located, as well as the positional relationship between the preset image source and the other image sources. The linked list is a method of finding a data structure that requires the relationship between adjacent nodes. In the method provided in the present application, it can also be implemented by other data structures, such as arrays.

[0078] S202: Determine an image source to be searched from among the image sources within the area where the preset image source is located according to the positional relationship between the image sources.

[0079] Optionally, based on the positional relationship between the image sources, an image source within a preset range centered on the preset image source is determined from the image sources within the area where the preset image source is located as the image source to be searched, and the image source to be searched and the preset image source are in adjacent positions in the preset scene.

[0080] In the method provided in the embodiment of the present application, based on the information of the preset image source, a linked list of the area where the preset image source is located is obtained, and based on the positional relationship between the image sources, the image source to be searched is determined. By screening the linked list, the search range of the image source can be selected based on the preset range centered on the preset image source, so that the range of the feature search is reduced. The feature search of the person can be achieved by only performing a feature search on the image source in the preset range, the amount of calculation is reduced, and the efficiency of the feature search is greatly improved.

[0081] Before obtaining a linked list of areas where preset image sources are located based on information of preset image sources, an embodiment of the present application also provides another possible implementation example of a feature search method, including: constructing a linked list for each area based on information and positional relationships of each image source in each area in a preset scene.

[0082] Specifically, by configuring a linked list node for each image source in each area of ​​the preset scene, additional information needs to be configured in the linked list node, such as the effective search time, the number of adjacent node weighted circles, etc., where the effective search time indicates the image source acquisition time corresponding to the linked list node, and the number of adjacent node weighted circles can be N circles. Among them, a node in the linked list can be composed of one or more image sources, and each node can be adjacent to multiple nodes, that is, the preset image source can be adjacent to multiple image sources. Finally, a zone relationship is formed, and a linked list for each zone is constructed. Since the zones can be connected through the linked list nodes, the positions of the image sources in each area of ​​the preset scene can be connected and anchored, thereby obtaining a multi-level bidirectional linked list, and the constructed linked list information for each zone is stored in the preset database.

[0083] It should be noted that the effective search time can be set to 3 hours, 2 hours, etc., for example. By judging whether the first person information is recognized within the range of the effective search time, if the first person information is recognized within the range of the effective search time, that is, at least one first person information in the image to be recognized is obtained, then all the person information in the first person information, including the person feature information and the person attribute information, is retained, and the effective search time is updated. This avoids the situation where there is a large amount of first person information accumulated due to the lack of an effective search time limit when there is a large flow of people and a lot of first person information, which is not conducive to feature search.

[0084] Based on identifying the information of the person, the embodiment of the present application also provides another possible implementation method, including: if there is no at least one second feature information in the feature set corresponding to the image source to be searched, a new person identification is added for each first person information.

[0085] Specifically, if at least one second feature information is not found in the feature set corresponding to the image source to be searched through the feature similarity algorithm, it means that at least one first character information in the image to be identified does not have at least one corresponding second feature information in the preset database, then a new character identifier is added for the first character information corresponding to the at least one first character information.

[0086] The embodiment of the present application also provides another possible implementation example of a feature search method. It includes: identifying the information of a linked list of the area where the person is located, storing the information of a person and the information of the image source to be searched in a preset database. Specifically, the extracted person information, namely person attribute information, person feature information and image source information, and person detection information are split into each person's person information, including respective person detection information, person attribute information, person feature information, feature search information and linked list information, and stored in a preset database according to a certain rule, wherein the certain rule can be specifically for the person feature information, and the length of the person feature information can be set to a preset feature length, such as 512. If the length of the identified person feature information does not meet the preset feature length, the identified person feature information needs to be padded with zeros to make it meet the preset feature length, and the person attribute information is bound to the person feature information. The feature search information is a person tag, namely ID information. The person detection information, person attribute information, person feature information, feature search information and linked list information are organized into a data structure that meets the database storage requirements and stored in the preset database.

[0087] Based on the feature search method provided in the above embodiment, the embodiment of the present application provides another possible implementation example of the feature search method. Figure 3 A flow chart of another feature search method provided in an embodiment of the present application. Figure 3 As shown, before determining the image source to be searched from multiple image sources in the preset scene according to the information of the preset image source, the method further includes:

[0088] S301: Store at least one piece of first person information in a preset message queue.

[0089] In this embodiment, by combining and merging the image source information, person detection information, person attribute information, and person feature information, and sorting out a data structure that conforms to the message queue, compression and encryption operations are performed, and the data is sent to the message queue for storage according to certain rules, specifically input into the corresponding queue according to the person information.

[0090] In the above, determining the image source to be searched from multiple image sources in the preset scene according to the information of the preset image source, the method further includes:

[0091] S302: Obtain first person information from a preset message queue.

[0092] By subscribing to the corresponding message queue data through message subscription, consuming the data of the corresponding message queue, decrypting and decompressing the obtained data, i.e. the first person information, predicting and processing the person feature information, and unifying the length of the person feature information, the first person information can be obtained from the preset message queue.

[0093] S303: Determine an image source to be searched from multiple image sources according to information of a preset image source in the acquired first person information.

[0094] Since the first feature information and the information of the preset image source are stored one by one as the first character information in the message queue, when the first character information is searched, the preset image source information in the first character information can be obtained, and the area where the preset image source is located in the preset scene is determined according to the information of the preset image source, and thus the image source to be searched is determined according to the area where the preset image source is located in the preset scene.

[0095] Part of the features of the first person information can be read from the message queue and stored in a preset database. The first person information can then be re-read from the message queue. The image source to be searched is determined based on the acquired first person information. Finally, a feature search is performed to achieve input / output (IO) separation and improve feature search efficiency. In the method provided in the embodiment of the present application, at least one first person information is stored in a preset message queue to achieve data buffering, business decoupling, peak shaving, and distribution of the person information. The person information data is then read from the message queue and needs to be decompressed and decrypted to determine the image source to be searched, thereby protecting the person information.

[0096] The following continues to explain the model training device, image classification device, computer equipment and computer-readable storage medium provided by any of the above embodiments of the present application. The specific implementation process and the technical effects produced are the same as those of the corresponding method embodiments mentioned above. For the sake of brief description, for the parts not mentioned in this embodiment, please refer to the corresponding content in the method embodiment.

[0097] Figure 4 This is a functional module diagram of a feature search device provided in an embodiment of the present application. Figure 4 As shown, the feature search device 100 includes:

[0098] The recognition module 110 is used to perform person recognition on the image to be recognized collected by the preset image source in the preset scene, and obtain at least one first person information in the image to be recognized; each first person information includes: first feature information and information of the preset image source.

[0099] The first determining module 120 is configured to determine an image source to be searched from a plurality of image sources in a preset scene according to information of a preset image source.

[0100] The search module 130 is used to perform a feature search on a feature set corresponding to the image source to be searched in a preset database based on the first feature information in each first character information, and obtain at least one second feature information that meets a preset similarity condition with the first feature information; the preset database includes: multiple second character information, each second information includes: second feature information, and image source information corresponding to the second feature information.

[0101] The second determining module 140 is configured to determine, based on at least one piece of second characteristic information, at least one piece of second character information corresponding to each piece of first character information.

[0102] The configuration module 150 is used to determine that each piece of first character information and at least one piece of second character information corresponding to each piece of first character information is information of one character, and configure a character identifier for the information of one character, so that the information of the same character has the same character identifier, and the information of different characters has different character identifiers.

[0103] In an optional embodiment, the first determination module 120 is further used to obtain a linked list of the area where the preset image source is located based on the information of the preset image source; the linked list of the area where the preset image source is located records: information of each image source within the area where the preset image source is located, and the positional relationship between each image source; based on the positional relationship between each image source, determine the image source to be searched from each image source within the area where the preset image source is located.

[0104] In an optional embodiment, the first determining module 120 is further configured to determine, from among the image sources, image sources within a preset range centered on a preset image source as image sources to be searched, based on positional relationships between the image sources.

[0105] In an optional embodiment, the feature search device 100 further includes:

[0106] The construction module is used to construct a linked list for each area according to the information and position relationship of each image source in each area of ​​the preset scene.

[0107] In an optional embodiment, the feature search device 100 further includes:

[0108] The identification module is configured to add a character identification to each piece of first character information if at least one piece of second feature information does not exist in the feature set corresponding to the image source to be searched.

[0109] In an optional embodiment, the feature search device 100 further includes:

[0110] The storage module is used to identify the information of the linked list in the area; store the information of a person and the information of the image source to be searched in a preset database.

[0111] In an optional embodiment, the feature search device 100 further includes:

[0112] An acquisition module is used to store at least one first character information in a preset message queue; determine the image source to be searched from multiple image sources in a preset scene based on the information of the preset image source, including obtaining the first character information from the preset message queue; and determine the image source to be searched from multiple image sources based on the information of the preset image source in the obtained first character information.

[0113] The above-mentioned device is used to execute the method provided in the above-mentioned embodiment. Its implementation principle and technical effect are similar and will not be repeated here.

[0114] The above modules can be one or more integrated circuits configured to implement the above methods, such as one or more application-specific integrated circuits (ASICs), one or more microprocessors, or one or more field programmable gate arrays (FPGAs). For another example, when a module is implemented by scheduling program code through a processing element, the processing element can be a general-purpose processor, such as a central processing unit (CPU) or other processor that can call program code. For another example, these modules can be integrated together and implemented in the form of a system-on-a-chip (SOC).

[0115] Figure 5 This is a schematic diagram of a computer device provided in an embodiment of the present application, which can be used for feature search. Figure 5 As shown, the computer device 200 includes: a processor 210 , a storage medium 220 , and a bus 230 .

[0116] Storage medium 220 stores machine-readable instructions executable by processor 210. When the computer device is running, processor 210 communicates with storage medium 220 via bus 230, and processor 210 executes the machine-readable instructions to perform the steps of the above-described method embodiment. The specific implementation methods and technical effects are similar and will not be repeated here.

[0117] Optionally, the present application further provides a storage medium 220 on which a computer program is stored. When the computer program is executed by a processor, the steps of the above method embodiment are executed. The specific implementation and technical effects are similar and will not be repeated here.

[0118] In several embodiments provided by the present application, it should be understood that the disclosed apparatus and method can be implemented in other manners. For example, the described apparatus embodiments are merely schematic. The units as divided can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the displayed or discussed mutual couplings or direct couplings or communication connections can be indirect couplings or communication connections through some interfaces, devices or units, and can be in electrical, mechanical or other forms.

[0119] The units described as separate components can or can not be physically separate, and the components shown as units can or can not be physical units, i.e., can be located in one place, or can be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purposes of the embodiments.

[0120] In addition, each functional unit in the various embodiments of the present application can be integrated into a processing unit, or each unit can be a physically independent unit, or two or more units can be integrated into a unit. The integrated unit can be implemented in the form of hardware, or in the form of hardware plus software functional units.

[0121] The integrated unit implemented in the form of software functional units can be stored in a computer readable storage medium. The software functional units stored in the storage medium include a plurality of instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) or a processor (English: processor) to execute some steps of the method described in the various embodiments of the present application. The foregoing storage medium includes a U disk, a mobile hard disk, a read-only memory (English: Read-Only Memory, abbreviated as: ROM), a random access memory (English: Random Access Memory, abbreviated as: RAM), a magnetic disk or an optical disk, and various program code storage media.

[0122] The above is merely a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art can easily think of changes or replacements within the technical scope disclosed by the present application, which should be covered within the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.

Claims

1. A feature search method, characterized in that: include: Performing person recognition on an image to be identified that is collected by a preset image source in a preset scene to obtain at least one first person information in the image to be identified; Each piece of first character information includes: first characteristic information and information of the preset image source; Determining an image source to be searched from a plurality of image sources in the preset scene according to the information of the preset image source; performing a feature search on a feature set corresponding to the image source to be searched in a preset database based on the first feature information in each piece of the first character information, to obtain at least one piece of second feature information that satisfies a preset similarity condition with the first feature information; the preset database comprising: a plurality of pieces of second character information, each piece of the second character information comprising: second feature information and image source information corresponding to the second feature information; Determining, based on the at least one piece of second characteristic information, at least one piece of second character information corresponding to each piece of first character information; Determine that each piece of first character information and at least one piece of second character information corresponding to each piece of first character information is information of one character, and configure a character identifier for the information of one character, so that information of the same character has the same character identifier, and information of different characters has different character identifiers.

2. The method according to claim 1, characterized in that The step of determining the image source to be searched from the plurality of image sources in the preset scene according to the information of the preset image source includes: According to the information of the preset image source, a linked list of areas where the preset image source is located is obtained; the linked list of areas where the preset image source is located records: information of each image source within the area where the preset image source is located, and positional relationships between the image sources; The image source to be searched is determined from the image sources within the area where the preset image source is located according to the positional relationship between the image sources.

3. The method according to claim 2, characterized in that The step of determining the image source to be searched from the image sources according to the positional relationship between the image sources comprises: According to the positional relationship between the image sources, an image source within a preset range centered on the preset image source is determined from the image sources as the image source to be searched.

4. The method according to claim 2, characterized in that Before obtaining the linked list of areas where the preset image sources are located based on the information of the preset image sources, the method further includes: According to the information and positional relationship of each image source in each area of ​​the preset scene, a linked list of each area is constructed.

5. The method according to claim 1, wherein The method further comprises: If the at least one piece of second feature information does not exist in the feature set corresponding to the image source to be searched, a character identifier is added to each piece of first character information.

6. The method according to claim 1, characterized in that The method further includes: identifying information of the linked list of the area; The information of the person and the information of the image source to be searched are stored in the preset database.

7. The method according to claim 1, characterized in that Before determining the image source to be searched from the plurality of image sources in the preset scene according to the information of the preset image source, the method further includes: Storing the at least one first person information in a preset message queue; The step of determining the image source to be searched from the plurality of image sources in the preset scene according to the information of the preset image source includes: Obtaining first person information from the preset message queue; The image source to be searched is determined from the multiple image sources according to the information of the preset image source in the acquired first person information.

8. A feature search device, characterized in that: include: a recognition module, configured to perform person recognition on an image to be recognized collected from a preset image source in a preset scene, and obtain at least one first person information in the image to be recognized; Each piece of first character information includes: first characteristic information and information of the preset image source; A first determining module is configured to determine an image source to be searched from a plurality of image sources in the preset scene according to information of the preset image source; A search module is configured to perform a feature search on a feature set corresponding to the image source to be searched in a preset database based on the first feature information in each piece of first character information, to obtain at least one second feature information that satisfies a preset similarity condition with the first feature information; the preset database includes: a plurality of second character information pieces, each second information piece including: second feature information and image source information corresponding to the second feature information; a second determining module, configured to determine, based on the at least one piece of second characteristic information, at least one piece of second character information corresponding to each piece of first character information; A configuration module is used to determine that each piece of first character information and at least one piece of second character information corresponding to each piece of first character information is information of one character, and configure a character identifier for the information of one character, so that the information of the same character has the same character identifier, and the information of different characters has different character identifiers.

9. A computer device, characterized in that: include: A processor, a storage medium and a bus, wherein the storage medium stores program instructions executable by the processor. When the computer device is running, the processor and the storage medium communicate through the bus, and the processor executes the program instructions to perform the steps of the feature search method as described in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that The storage medium stores a computer program, which, when executed by a processor, executes the steps of the feature search method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Portrait searching method, server, storage medium, video processing method and system

    CN111143594A

  • Costume searching method and device, electronic equipment and medium

    CN112905889A