CN110162645A - Image search method, device and electronic equipment based on index - Google Patents

Image search method, device and electronic equipment based on index Download PDF

Info

Publication number
CN110162645A
CN110162645A CN201910450287.0A CN201910450287A CN110162645A CN 110162645 A CN110162645 A CN 110162645A CN 201910450287 A CN201910450287 A CN 201910450287A CN 110162645 A CN110162645 A CN 110162645A
Authority
CN
China
Prior art keywords
picture
user
index
file
identity
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201910450287.0A
Other languages
Chinese (zh)
Inventor
姚林
詹建勤
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong 3vjia Information Technology Co Ltd
Original Assignee
Guangdong 3vjia Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangdong 3vjia Information Technology Co Ltd filed Critical Guangdong 3vjia Information Technology Co Ltd
Priority to CN201910450287.0A priority Critical patent/CN110162645A/en
Publication of CN110162645A publication Critical patent/CN110162645A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/50Information retrieval; Database structures therefor; File system structures therefor of still image data
    • G06F16/51Indexing; Data structures therefor; Storage structures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/50Information retrieval; Database structures therefor; File system structures therefor of still image data
    • G06F16/58Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually
    • G06F16/583Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually using metadata automatically derived from the content
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • General Physics & Mathematics (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Library & Information Science (AREA)
  • Databases & Information Systems (AREA)
  • Software Systems (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Evolutionary Biology (AREA)
  • Evolutionary Computation (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Processing Or Creating Images (AREA)

Abstract

Image search method based on index, device and electronic equipment provided by the invention, are related to field of image search, wherein this method comprises: receiving the image data that user uploads;Feature extraction is carried out to image data based on deep learning model trained in advance, generates picture feature;Picture searching is carried out in the index cluster constructed in advance based on picture feature, generates search result;Wherein index cluster is index related with the identity of multiple users and/or index cluster is index related with plurality of picture type;Search result is sent to user.The image data uploaded by reception user in the index related with the identity of multiple users and/or index cluster constructed in advance is searched in index cluster related with plurality of picture type, improves recall precision;The index file for indexing cluster simultaneously is stored in different storage servers by the way of distributed storage, and the storage performance requirement of storage server is reduced.

Description

Image search method, device and electronic equipment based on index
Technical field
The present invention relates to image retrieval technologies fields, more particularly, to a kind of image search method based on index, device And electronic equipment.
Background technique
With the raising of residenter house increased and people require living environment, Decoration Industry increasingly rises, especially It is the general choice for customizing finishing and being increasingly becoming modern.
Enterprise or user for house ornamentation, in the prior art user usually in a search engine input keyword from searching A large amount of pictures of rope engine feedback search identification carrying out human eye and find the picture of oneself demand, it is such by keyword then The retrieval mode recall precision for searching identification by human eye is lower, while damaging to user's eyesight, and user experience is poor.House ornamentation Enterprise or user how quickly to be found in the various products of a large amount of household industry with oneself need or like close to production Product become a urgent problem to be solved.
Summary of the invention
In view of this, the purpose of the present invention is to provide image search method, device and electronic equipment based on index, with Alleviate or the lower technical problem of recall precision existing in the prior art is alleviated in part, can be improved recall precision.
In a first aspect, the embodiment of the invention provides a kind of image search methods based on index, comprising the following steps:
Receive the image data that user uploads;
Feature extraction is carried out to the image data based on deep learning model trained in advance, generates picture feature;
Picture searching is carried out in the index cluster constructed in advance based on the picture feature, generates search result;Wherein The index cluster is index related with the identity of multiple users and/or the index cluster is and plurality of picture type Related index;
The search result is sent to the user.
Further, building obtains the index cluster one of in the following manner:
Mode A:
Identity according to each user is respectively that each user creates user file;
Batch extracting goes out picture from the picture library of each user;
The picture is imported into user file corresponding with the identity of each user, the rope of each user is generated Quotation part;
Index file building index cluster based on each user;
Mode B:
It is respectively each picture type creation category file according to different picture types;
Batch extracting goes out picture from the picture library of multiple users;
The picture is imported into category file corresponding with the picture type of the picture, each picture type is generated Index file;
Index file building index cluster based on each picture type;
Mode C:
Identity according to each user is respectively that each user creates user file;
It is respectively that each picture type creates category file in user file according to different picture types;
Batch extracting goes out picture from the picture library of each user;
By the picture of each user imported into user file corresponding with the identity of each user with the figure In the corresponding category file of the picture type of piece, the index file of each user is generated;
Index file building index cluster based on each user;
Mode D:
It is respectively each picture type creation category file according to different picture types;
It is respectively that each user creates user file in each category file;
Batch extracting goes out picture from the picture library of each user;
By the picture of each user imported into category file corresponding with the picture type of the picture with each use In the corresponding user file of the identity at family, the index file of each picture type is generated;
Index file building index cluster based on each picture type.
Further, the image data includes the identity and picture type of the user;
It is described that picture searching is carried out in the index cluster constructed in advance based on the picture feature, search result is generated, Include:
The identity with the user is searched in identity based on the user in the index cluster constructed in advance Identify corresponding index file;
It is searched in index file corresponding with the identity of the user based on the picture type and the picture The corresponding index file of type;
Picture searching is carried out in index file corresponding with the picture type based on the picture feature, generates retrieval As a result.
Further, the image data includes the identity and picture type of the user;
It is described that picture searching is carried out in the index cluster constructed in advance based on the picture feature, search result is generated, Include:
Rope corresponding with the picture type is searched in the index cluster constructed in advance based on the picture type Quotation part;
Identity based on the user is searched in the corresponding index file of the picture type with the user's The corresponding index file of identity;
Picture searching is carried out in index file corresponding with the identity of the user based on the picture feature, it is raw At search result.
Further, described that picture searching is carried out in the index cluster constructed in advance based on the picture feature, it generates Search result, comprising:
The Europe for indexing every picture in cluster for calculating the picture feature using Euclidean distance algorithm and constructing in advance Formula distance generates list of matches;
It is similar features figure by the picture indicia for being greater than preset threshold in list of matches;
Search result is generated based on the similar features figure.
Further, the index file be in the form of character string in distributed storage server.
Second aspect, the embodiment of the present invention also provide a kind of image retrieving apparatus based on index, comprising:
Receiving module, for receiving the image data of user's upload;
Extraction module, it is raw for carrying out feature extraction to the image data based on deep learning model trained in advance At picture feature;
Retrieval module is generated for carrying out picture searching in the index cluster constructed in advance based on the picture feature Search result;Wherein the indexed set group is index related with the identity of multiple users and/or the index cluster is Index related with plurality of picture type;
Output module, for the search result to be sent to the user.
Further, building obtains the index cluster one of in the following manner:
Mode A:
Identity according to each user is respectively that each user creates user file;
Batch extracting goes out picture from the picture library of each user;
The picture is imported into user file corresponding with the identity of each user, the rope of each user is generated Quotation part;
Index file building index cluster based on each user;
Mode B:
It is respectively each picture type creation category file according to different picture types;
Batch extracting goes out picture from the picture library of multiple users;
The picture is imported into category file corresponding with the picture type of the picture, each picture type is generated Index file;
Index file building index cluster based on each picture type;
Mode C:
Identity according to each user is respectively that each user creates user file;
It is respectively that each picture type creates category file in user file according to different picture types;
Batch extracting goes out picture from the picture library of each user;
By the picture of each user imported into user file corresponding with the identity of each user with the figure In the corresponding category file of the picture type of piece, the index file of each user is generated;
Index file building index cluster based on each user;
Mode D:
It is respectively each picture type creation category file according to different picture types;
It is respectively that each user creates user file in each category file;
Batch extracting goes out picture from the picture library of each user;
By the picture of each user imported into category file corresponding with the picture type of the picture with each use In the corresponding user file of the identity at family, the index file of each picture type is generated;
Index file building index cluster based on each picture type.
Further, the retrieval module is used for:
The Europe for indexing every picture in cluster for calculating the picture feature using Euclidean distance algorithm and constructing in advance Formula distance generates list of matches;
It is similar features figure by the picture indicia for being greater than preset threshold in list of matches;
Search result is generated based on the similar features figure.
The third aspect the embodiment of the invention also provides a kind of electronic equipment, including memory, processor and is stored in institute The computer program that can be run on memory and on the processor is stated, the processor executes real when the computer program The step of existing above-mentioned image search method based on index.
Fourth aspect, the embodiment of the invention also provides a kind of machine readable storage medium, the machine readable storage is situated between Matter is stored with machine-executable instruction, and when being called and being executed by processor, the machine can be held the machine-executable instruction Row instruction promotes the processor to realize the above method.
The embodiment of the present invention bring it is following the utility model has the advantages that
Image search method based on index, device, electronic equipment and machine readable storage provided in an embodiment of the present invention Medium, being wherein somebody's turn to do the image search method based on index includes: the image data for receiving user and uploading;Based on depth trained in advance It spends learning model and feature extraction is carried out to image data, generate picture feature;Based on picture feature in the indexed set constructed in advance Picture searching is carried out in group, generates search result;Wherein index cluster be it is related with the identity of multiple users index and/ Or index cluster is index related with plurality of picture type;Search result is sent to user.Therefore, the embodiment of the present invention mentions The technical solution of confession passes through building and User Identity (Identification, abridge ID) or the relevant rope of picture type Draw cluster, the picture of different type or User ID is stored in different index files (index file is in different databases) In, the image data to be retrieved that user directly uploads is received, is existed respectively according to its picture type or its User ID for being included It is searched in corresponding index file in index cluster, improves recall precision;The index file of cluster is indexed simultaneously using distribution The mode of formula storage is stored in different storage servers, reduces the storage performance requirement of storage server.
Other features and advantages of the present invention will illustrate in the following description, also, partly become from specification It obtains it is clear that understand through the implementation of the invention.The objectives and other advantages of the invention are in specification, claims And specifically noted structure is achieved and obtained in attached drawing.
To enable the above objects, features and advantages of the present invention to be clearer and more comprehensible, preferred embodiment is cited below particularly, and cooperate Appended attached drawing, is described in detail below.
Detailed description of the invention
It, below will be to specific in order to illustrate more clearly of the specific embodiment of the invention or technical solution in the prior art Embodiment or attached drawing needed to be used in the description of the prior art be briefly described, it should be apparent that, it is described below Attached drawing is some embodiments of the present invention, for those of ordinary skill in the art, before not making the creative labor It puts, is also possible to obtain other drawings based on these drawings.
Fig. 1 is a kind of flow chart of the image search method based on index provided in an embodiment of the present invention;
Fig. 2 is the flow chart of another image search method based on index provided in an embodiment of the present invention;
Fig. 3 is the application scenario diagram of the third image search method based on index provided in an embodiment of the present invention;
Fig. 4 is the schematic diagram of the third image search method based on index provided in an embodiment of the present invention;
Fig. 5 is a kind of schematic diagram of the image retrieving apparatus based on index provided in an embodiment of the present invention;
Fig. 6 is the schematic diagram of a kind of electronic equipment provided in an embodiment of the present invention.
Specific embodiment
In order to make the object, technical scheme and advantages of the embodiment of the invention clearer, below in conjunction with attached drawing to the present invention Technical solution be clearly and completely described, it is clear that described embodiments are some of the embodiments of the present invention, rather than Whole embodiments.Based on the embodiments of the present invention, those of ordinary skill in the art are not making creative work premise Under every other embodiment obtained, shall fall within the protection scope of the present invention.
At present for the enterprise of house ornamentation or user, user usually inputs keyword in a search engine in the prior art The a large amount of pictures fed back from search engine search the picture that oneself demand is found in identification to carry out human eye, such to pass through keyword Then the retrieval mode recall precision for searching identification by human eye is lower, while damaging to user's eyesight, and user experience is poor, Based on this, a kind of image search method based on index, device and electronic equipment provided in an embodiment of the present invention, can alleviate or The lower technical problem of recall precision existing in the prior art is alleviated in part, can be improved recall precision.
For convenient for understanding the present embodiment, first to a kind of image based on index disclosed in the embodiment of the present invention Search method describes in detail.
Embodiment one:
The embodiment of the invention provides a kind of image search methods based on index, can be applied to household industry, by family The terminal device for occupying industry executes, and terminal device here can be server (such as cluster server).
As shown in Figure 1, the embodiment of the invention provides a kind of image search method based on index the following steps are included:
Step S102 receives the image data that user uploads;
Wherein user here for example can be the user of household industry, specifically, user can be house ornamentation enterprise, can also To be the upstream and downstream firms of house ornamentation enterprise, such as purchaser, dealer, consumption user etc., to this, this embodiment is not limited.
Specifically, user can directly upload the picture number for oneself needing or liking by the interface that cluster server provides According to;Cluster server receives the image data that user uploads;
Since server provides the interface of uploading pictures function for user, cluster server can be obtained by interface The picture type got the identity of user or include from image data;Here image data for example can be plane Picture (such as the photo on a surface of the objects such as furniture) is also possible to stereotome (such as the perspective view of an object Or the photo of illustraton of model);Correspondingly, picture type can be plane type and stereoscopic type.
It should be noted that in other embodiments, the identity mark of user can also be got by user login information Know;Picture type is directly obtained by the picture type of user's input or specified retrieval.
Step S104 carries out feature extraction to image data based on deep learning model trained in advance, it is special to generate picture Sign;
Here the samples pictures of some different picture types can be acquired and carry out machine learning using deep learning algorithm, Training obtains the deep learning model for being able to carry out picture feature extraction.Specific training process belongs to the prior art, here not Make excessive explanation.
Step S106 carries out picture searching based on picture feature in the index cluster constructed in advance, generates search result; Wherein index cluster be and the identity of multiple users it is related index and/or index cluster be related with plurality of picture type Index;
Consider how to search and improve recall precision, when specific implementation, index cluster can in the following manner in A kind of building obtain:
Mode A:
It A1, is respectively that each user creates user file according to the identity of each user;
A2, batch extracting goes out picture from the picture library of each user;
A3, the picture is imported into user file corresponding with the identity of each user, generates each user Index file;
A4, the index file building index cluster based on each user.
By establishing user file for each user, and the picture in the picture library of each user is imported into and its identity It identifies in corresponding user file, and user file is added into index (such as character string of User ID), constitute each user's The index file of index file, each user can be stored in different storage servers by way of distributed storage, Different storage servers constitutes cluster server, and the set of index file constitutes index cluster, needs to retrieve in a user In the case where picture, retrieval is directly searched from the user file of the user according to the identity of the user, improves retrieval Efficiency, while the picture retrieval for being biased to user demand is obtained as a result, improving user experience.
Mode B:
It B1, is respectively that each picture type creates category file according to different picture types;
B2, batch extracting goes out picture from the picture library of multiple users;
B3, the picture is imported into category file corresponding with the picture type of the picture, generates each picture The index file of type;
B4, the index file building index cluster based on each picture type;
By establishing category file for each picture type, and it is all existing by what is extracted from the picture library of multiple users Picture according to picture type be directed respectively into in corresponding category file, and by category file addition index (such as picture category The character string of type), the index file of each picture type is constituted, the index file of each picture type can be deposited by distribution The mode of storage is stored in different storage servers, and different storage servers constitutes cluster server, the collection of index file It closes and constitutes index cluster, in the case where a user needs retrieving image, directly according to the picture type of retrieval from the picture Retrieval is searched in the index file of type, improves recall precision, while obtaining the picture retrieval for being biased to user demand or hobby As a result, improving user experience.
Mode C:
It C1, is respectively that each user creates user file according to the identity of each user;
It C2, is respectively each picture type creation category file in user file according to different picture types;
C3, batch extracting goes out picture from the picture library of each user;
C4, by the picture of each user imported into user file corresponding with the identity of each user with it is described In the corresponding category file of the picture type of picture, the index file of each user is generated;
C5, the index file building index cluster based on each user;
User file is established for each user first, then different picture types is created under the user file of each user Build the category file of various picture types;And by the existing picture extracted from the picture library of each user according to picture type Difference imported into the corresponding category file under the user file, and by user file addition index (such as User ID Character string), category file addition index (such as character string of picture type) constitutes the index file of each user, here often It include multiple category files in the index file of a user;The index file of each user can pass through the side of distributed storage Formula is stored in different storage servers, and the different classes of file of certain each user also can store in different services In device;All storage servers constitute cluster server, and the set of index file constitutes index cluster, needs to examine in a user In the case where rope picture, the user file of the user is directly found according to the identity of the user, then according to picture type Retrieval is searched in category file corresponding with the picture type under user file, improves recall precision, while being obtained partially To the picture retrieval of user demand as a result, improving user experience.Further, since index more refines, therefore, recall precision is more Height, search result are also more accurate.
Mode D:
It D1, is respectively that each picture type creates category file according to different picture types;
It D2, is respectively that each user creates user file in each category file;
D3, batch extracting goes out picture from the picture library of each user;
D4, by the picture of each user imported into category file corresponding with the picture type of the picture with it is each In the corresponding user file of the identity of user, the index file of each picture type is generated;
D 5, the index file building index cluster based on each picture type.
Category file is established for each picture type first, is then that each user creates use under different category files Family file;And the existing picture extracted from the picture library of each user is imported into the category according to the difference of picture type In corresponding user file under file, category file is added into index (such as character string of picture type), and user is literary Part addition index (such as character string of User ID), constitutes the index file of each picture type, here each picture type Index file includes multiple user files;The index file of each picture type can be stored in by way of distributed storage In different storage servers, the user file of the different user of certain each picture type also be can store in different services In device;All storage servers constitute cluster server, and the set of index file constitutes index cluster, needs to examine in a user In the case where rope picture, category file corresponding with the picture type is directly found according to picture type, then according to the user Identity the user file of the user is found under category file, retrieval is searched in the user file found, is improved Recall precision, while the picture retrieval for being biased to user demand is obtained as a result, improving user experience.Further, since index more refinement Change, therefore, recall precision is higher, and search result is also more accurate.
Correspondingly, one, when image data only includes the identity of user;
It is described that picture searching is carried out in the index cluster constructed in advance based on the picture feature, search result is generated, Include:
The body with the user is searched in identity of the a1 based on the user in the index cluster constructed in advance Part identifies corresponding index file;Here index file refers to the index file of user.
A2 is searched in index file corresponding with the identity of the user based on the picture feature, generates retrieval As a result.
Two, when image data only includes picture type;
It is described that picture searching is carried out in the index cluster constructed in advance based on the picture feature, search result is generated, It is realized by following steps:
B1 is searched in the index cluster constructed in advance corresponding with the picture type based on the picture type Index file;Here index file refers to the index file of image type.
B2 is based on the picture feature and searches in index file corresponding with the picture type, generates search result.
Three, when image data includes the identity and picture type of user;
In one embodiment, step S 106 can be executed by following steps:
The body with the user is searched in identity of the c1 based on the user in the index cluster constructed in advance Part identifies corresponding index file;
C2 is searched in index file corresponding with the identity of the user and the figure based on the picture type The corresponding index file of sheet type;
C3 is based on the picture feature and carries out picture searching in index file corresponding with the picture type, generates inspection Hitch fruit.
In another embodiment, step S106 includes following sub-step:
D1 is searched in the index cluster constructed in advance corresponding with the picture type based on the picture type Index file;
Identity of the d2 based on the user is searched and the user in the corresponding index file of the picture type The corresponding index file of identity;
D3 carries out picture searching in index file corresponding with the identity of the user based on the picture feature, Generate search result.
Search result is sent to user by step S108.
Further, above-mentioned index file be in the form of character string in distributed storage server.
Further, the Image ID in the index file is also to be stored in the form of character string.
Image search method provided in an embodiment of the present invention based on index is directly uploaded to be retrieved by reception user Image data, then according to the identity of the picture type of image data and/or upload user in advance by different type And/or the picture of User Identity is stored in building in different index file (index file is in different databases) and obtains Index cluster relevant to picture type and/or User Identity in find corresponding index file and in the index found It is searched in file, improves recall precision;The index file for indexing cluster simultaneously is stored in not by the way of distributed storage In same storage server, the storage performance requirement of storage server is reduced.
Further, referring to Fig. 2, the image search method the embodiment of the invention provides another kind based on index, comprising:
Step S202 receives the image data that user uploads;
Step S204 carries out feature extraction to the image data based on deep learning model trained in advance, generates figure Piece feature;
Step S206, the every picture indexed in cluster for calculating picture feature using Euclidean distance algorithm and constructing in advance Euclidean distance, generate list of matches;
It considers how to reduce calculation amount to improve matching efficiency, therefore, in the present embodiment, index cluster passes through above-mentioned Mode C constructs to obtain;
Specifically, step S206 can be executed by following steps:
Picture feature is calculated using Euclidean distance algorithm to index in cluster under the user file of the user with what is constructed in advance Category file in every picture Euclidean distance, generate list of matches.
The picture indicia for being greater than preset threshold in list of matches is similar features figure by step S208;
By in this present embodiment using the indexed mode of refinement, thus preset threshold here can be set compared with Greatly, such as it is set as 99%, i.e., the picture that the image data similarity uploaded with user reaches 99% or more can be just marked as Similar features figure.
Step S210 generates search result based on similar features figure;
Search result is sent to user by step S212.
Image search method provided in this embodiment based on index, by the phase for comparing picture using Euclidean distance algorithm Like degree, only picture similarity is more than that the picture of preset threshold just appears in search result, it is ensured that the standard of search result Exactness is conducive to improve user experience.
Embodiment two:
In order to make it easy to understand, as scene and Fig. 3 is combined to be based on rope to provided in an embodiment of the present invention using household industry below The image search method drawn is illustrated.
Specifically, referring to Fig. 3 and Fig. 4, should image search method based on index the following steps are included:
Step S302, by the existing image data of each enterprise's batch extracting enterprise;
Step S304, respectively each enterprise create index file, building index cluster;
Step S306, the image data that interface user uploads;
The image data of upload for example can be the picture or user preference of a product that enterprise where it newly releases The picture of product;
Here user refers to that the user of enterprise (such as can be the interior employee of enterprise or the seller of enterprise, adopt Purchaser).
Step S308, the cluster server for handling picture feature receives image data, and uses deep learning mould after training Type extracts picture feature;
Step S310 searches similar features figure in its enterprise index using the feature of uploading pictures, and returns to similarity High Image ID.
In specific steps S302, a feature extraction server cluster, referred to herein as GPU (Graphics are constructed Processing Unit, graphics processor) cluster server, it is responsible for receiving and reading image data, extracts picture feature, And construct index.Different user groups has different enterprise ID, each enterprise ID to correspond to a collection of picture, is divided into again in picture vertical Body figure, two class of plan view.
In specific steps S304, GPU cluster server construction index cluster is respectively created for each different enterprise ID Perspective view, plan view two class index, index are stored in distributed storage server with character string forms.It is indexed when update Server obtains index from storage server;Here index server refers to GPU cluster server.
In specific steps S306, GPU cluster server passes through interface user uploading pictures data, contains in data User ID, and specified retrieval classification is plan view or perspective view.
In specific steps S310, when GPU cluster server carries out picture searching, according to finding each enterprise ID and retrieval Classification finds index, is passed to picture feature, calculates the Euclidean distance of each picture in picture feature and the index found, obtains phase Like Image ID (such as similarity up to 99% or more Image ID) list.Here Image ID.
Compared with prior art, the image search method provided in an embodiment of the present invention based on index is a kind of distributed phase Like the more indexed search methods of image, using Open Framework, it is respectively created solely to different enterprises and different product types respectively Vertical index.So that different enterprises, which can according to need, finds different products, it is suitably applied in household industry various products (include: three-dimensional finished product furniture, such as sofa, tea table;Planar products, such as ceramic tile, floor, wallpaper) search is searched, it improves Recall precision is partially separated in addition, this method also has the advantage that search characteristic extraction part with index, reduces coupling It is right, improve the robustness of system;Index uses distributed storage, and index server can share index data, improves and is System performance.
Embodiment three:
As shown in figure 5, the embodiment of the invention also provides a kind of image retrieving apparatus based on index, comprising:
Receiving module 100, for receiving the image data of user's upload;
Extraction module 200, for carrying out feature extraction to the image data based on deep learning model trained in advance, Generate picture feature;
Retrieval module 300, it is raw for carrying out picture searching in the index cluster constructed in advance based on the picture feature At search result;Wherein the indexed set group is index related with the identity of multiple users and/or the index cluster It is index related with plurality of picture type;
Output module 400, for the search result to be sent to the user.
Further, building obtains index cluster one of in the following manner:
Mode A:
Identity according to each user is respectively that each user creates user file;
Batch extracting goes out picture from the picture library of each user;
The picture is imported into user file corresponding with the identity of each user, the rope of each user is generated Quotation part;
Index file building index cluster based on each user;
Mode B:
It is respectively each picture type creation category file according to different picture types;
Batch extracting goes out picture from the picture library of multiple users;
The picture is imported into category file corresponding with the picture type of the picture, each picture type is generated Index file;
Index file building index cluster based on each picture type;
Mode C:
Identity according to each user is respectively that each user creates user file;
It is respectively that each picture type creates category file in user file according to different picture types;
Batch extracting goes out picture from the picture library of each user;
By the picture of each user imported into user file corresponding with the identity of each user with the figure In the corresponding category file of the picture type of piece, the index file of each user is generated;
Index file building index cluster based on each user;
Mode D:
It is respectively each picture type creation category file according to different picture types;
It is respectively that each user creates user file in each category file;
Batch extracting goes out picture from the picture library of each user;
By the picture of each user imported into category file corresponding with the picture type of the picture with each use In the corresponding user file of the identity at family, the index file of each picture type is generated;
Index file building index cluster based on each picture type.
Further, retrieval module 300 is used for: being calculated the picture feature using Euclidean distance algorithm and is in advance constructed The Euclidean distance of every picture in cluster is indexed, list of matches is generated;The picture mark of preset threshold will be greater than in list of matches It is denoted as similar features figure;Search result is generated based on the similar features figure.
Image retrieving apparatus provided in an embodiment of the present invention based on index, with provided by the above embodiment based on index Image search method technical characteristic having the same reaches identical technical effect so also can solve identical technical problem.
It is apparent to those skilled in the art that for convenience and simplicity of description, the device of foregoing description Specific work process, can refer to corresponding processes in the foregoing method embodiment, details are not described herein.
Unless specifically stated otherwise, the opposite step of the component and step that otherwise illustrate in these embodiments, digital table It is not limit the scope of the invention up to formula and numerical value.
In all examples being illustrated and described herein, any occurrence should be construed as merely illustratively, without It is as limitation, therefore, other examples of exemplary embodiment can have different values.
Referring to Fig. 6, the embodiment of the present invention also provides a kind of electronic equipment 10, comprising: processor 40, memory 41, bus 42 and communication interface 43, the processor 40, communication interface 43 and memory 41 are connected by bus 42;Processor 40 is for holding The executable module stored in line storage 41, such as computer program.
Wherein, memory 41 may include high-speed random access memory (RAM, Random Access Memory), It may further include nonvolatile memory (non-volatile memory), for example, at least a magnetic disk storage.By at least One communication interface 43 (can be wired or wireless) realizes the communication between the system network element and at least one other network element Connection, can be used internet, wide area network, local network, Metropolitan Area Network (MAN) etc..
Bus 42 can be isa bus, pci bus or eisa bus etc..The bus can be divided into address bus, data Bus, control bus etc..Only to be indicated with a four-headed arrow convenient for indicating, in Fig. 6, it is not intended that an only bus or A type of bus.
Wherein, memory 41 is for storing program, and the processor 40 executes the journey after receiving and executing instruction Sequence, method performed by the device that the stream process that aforementioned any embodiment of the embodiment of the present invention discloses defines can be applied to handle In device 40, or realized by processor 40.
Processor 40 may be a kind of IC chip, the processing capacity with signal.During realization, above-mentioned side Each step of method can be completed by the integrated logic circuit of the hardware in processor 40 or the instruction of software form.Above-mentioned Processor 40 can be general processor, including central processing unit (Central Processing Unit, abbreviation CPU), network Processor (Network Processor, abbreviation NP) etc.;It can also be digital signal processor (Digital Signal Processing, abbreviation DSP), specific integrated circuit (Application Specific Integrated Circuit, referred to as ASIC), ready-made programmable gate array (Field-Programmable Gate Array, abbreviation FPGA) or other are programmable Logical device, discrete gate or transistor logic, discrete hardware components.It may be implemented or execute in the embodiment of the present invention Disclosed each method, step and logic diagram.General processor can be microprocessor or the processor is also possible to appoint What conventional processor etc..The step of method in conjunction with disclosed in the embodiment of the present invention, can be embodied directly in hardware decoding processing Device executes completion, or in decoding processor hardware and software module combination execute completion.Software module can be located at Machine memory, flash memory, read-only memory, programmable read only memory or electrically erasable programmable memory, register etc. are originally In the storage medium of field maturation.The storage medium is located at memory 41, and processor 40 reads the information in memory 41, in conjunction with Its hardware completes the step of above method.
The computer program product of the image search method based on index is carried out provided by the embodiment of the present invention, including is deposited The machine readable storage medium of the executable non-volatile program code of processor is stored up, the instruction that said program code includes can For executing previous methods method as described in the examples, specific implementation can be found in embodiment of the method, and details are not described herein.
Finally, it should be noted that embodiment described above, only a specific embodiment of the invention, to illustrate the present invention Technical solution, rather than its limitations, scope of protection of the present invention is not limited thereto, although with reference to the foregoing embodiments to this hair It is bright to be described in detail, those skilled in the art should understand that: anyone skilled in the art In the technical scope disclosed by the present invention, it can still modify to technical solution documented by previous embodiment or can be light It is readily conceivable that variation or equivalent replacement of some of the technical features;And these modifications, variation or replacement, do not make The essence of corresponding technical solution is detached from the spirit and scope of technical solution of the embodiment of the present invention, should all cover in protection of the invention Within the scope of.Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (10)

1. a kind of image search method based on index, which comprises the following steps:
Receive the image data that user uploads;
Feature extraction is carried out to the image data based on deep learning model trained in advance, generates picture feature;
Picture searching is carried out in the index cluster constructed in advance based on the picture feature, generates search result;It is wherein described Index cluster is that and the related index of the identity of the multiple users and/or index cluster is related with plurality of picture type Index;
The search result is sent to the user.
2. the method according to claim 1, wherein the index cluster one of in the following manner building It obtains:
Mode A:
Identity according to each user is respectively that each user creates user file;
Batch extracting goes out picture from the picture library of each user;
The picture is imported into user file corresponding with the identity of each user, the index text of each user is generated Part;
Index file building index cluster based on each user;
Mode B:
It is respectively each picture type creation category file according to different picture types;
Batch extracting goes out picture from the picture library of multiple users;
The picture is imported into category file corresponding with the picture type of the picture, the rope of each picture type is generated Quotation part;
Index file building index cluster based on each picture type;
Mode C:
Identity according to each user is respectively that each user creates user file;
It is respectively that each picture type creates category file in user file according to different picture types;
Batch extracting goes out picture from the picture library of each user;
By the picture of each user imported into user file corresponding with the identity of each user with the picture In the corresponding category file of picture type, the index file of each user is generated;
Index file building index cluster based on each user;
Mode D:
It is respectively each picture type creation category file according to different picture types;
It is respectively that each user creates user file in each category file;
Batch extracting goes out picture from the picture library of each user;
By the picture of each user imported into category file corresponding with the picture type of the picture with each user's In the corresponding user file of identity, the index file of each picture type is generated;
Index file building index cluster based on each picture type.
3. the method according to claim 1, wherein the image data include the identity of the user with And picture type;
It is described that picture searching is carried out in the index cluster constructed in advance based on the picture feature, generate search result, comprising:
The identity with the user is searched in identity based on the user in the index cluster constructed in advance Corresponding index file;
It is searched in index file corresponding with the identity of the user based on the picture type and the picture type Corresponding index file;
Picture searching is carried out in index file corresponding with the picture type based on the picture feature, generates retrieval knot Fruit.
4. the method according to claim 1, wherein the image data include the identity of the user with And picture type;
It is described that picture searching is carried out in the index cluster constructed in advance based on the picture feature, generate search result, comprising:
Index text corresponding with the picture type is searched in the index cluster constructed in advance based on the picture type Part;
Identity based on the user is searched and the identity of the user in the corresponding index file of the picture type Identify corresponding index file;
Picture searching is carried out in index file corresponding with the identity of the user based on the picture feature, generates inspection Hitch fruit.
5. the method according to claim 1, wherein it is described based on the picture feature in the index constructed in advance Picture searching is carried out in cluster, generates search result, comprising:
Using Euclidean distance algorithm calculate the picture feature and every picture in the index cluster that in advance constructs it is European away from From generation list of matches;
It is similar features figure by the picture indicia for being greater than preset threshold in list of matches;
Search result is generated based on the similar features figure.
6. according to the described in any item methods of claim 2-4, which is characterized in that the index file is in the form of character string In distributed storage server.
7. a kind of image retrieving apparatus based on index characterized by comprising
Receiving module, for receiving the image data of user's upload;
Extraction module generates figure for carrying out feature extraction to the image data based on deep learning model trained in advance Piece feature;
Retrieval module generates retrieval for carrying out picture searching in the index cluster constructed in advance based on the picture feature As a result;Wherein the indexed set group be it is related with the identity of multiple users index and/or the index cluster be with it is more The related index of kind picture type;
Output module, for the search result to be sent to the user.
8. device according to claim 7, which is characterized in that the index cluster one of in the following manner building It obtains:
Mode A:
Identity according to each user is respectively that each user creates user file;
Batch extracting goes out picture from the picture library of each user;
The picture is imported into user file corresponding with the identity of each user, the index text of each user is generated Part;
Index file building index cluster based on each user;
Mode B:
It is respectively each picture type creation category file according to different picture types;
Batch extracting goes out picture from the picture library of multiple users;
The picture is imported into category file corresponding with the picture type of the picture, the rope of each picture type is generated Quotation part;
Index file building index cluster based on each picture type;
Mode C:
Identity according to each user is respectively that each user creates user file;
It is respectively that each picture type creates category file in user file according to different picture types;
Batch extracting goes out picture from the picture library of each user;
By the picture of each user imported into user file corresponding with the identity of each user with the picture In the corresponding category file of picture type, the index file of each user is generated;
Index file building index cluster based on each user;
Mode D:
It is respectively each picture type creation category file according to different picture types;
It is respectively that each user creates user file in each category file;
Batch extracting goes out picture from the picture library of each user;
By the picture of each user imported into category file corresponding with the picture type of the picture with each user's In the corresponding user file of identity, the index file of each picture type is generated;
Index file building index cluster based on each picture type.
9. device according to claim 7, which is characterized in that the retrieval module is used for:
Using Euclidean distance algorithm calculate the picture feature and every picture in the index cluster that in advance constructs it is European away from From generation list of matches;
It is similar features figure by the picture indicia for being greater than preset threshold in list of matches;
Search result is generated based on the similar features figure.
10. a kind of electronic equipment, including memory, processor and it is stored on the memory and can transports on the processor Capable computer program, which is characterized in that the processor realizes the claims 1 to 6 when executing the computer program The step of described in any item methods.
CN201910450287.0A 2019-05-28 2019-05-28 Image search method, device and electronic equipment based on index Pending CN110162645A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910450287.0A CN110162645A (en) 2019-05-28 2019-05-28 Image search method, device and electronic equipment based on index

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910450287.0A CN110162645A (en) 2019-05-28 2019-05-28 Image search method, device and electronic equipment based on index

Publications (1)

Publication Number Publication Date
CN110162645A true CN110162645A (en) 2019-08-23

Family

ID=67629546

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910450287.0A Pending CN110162645A (en) 2019-05-28 2019-05-28 Image search method, device and electronic equipment based on index

Country Status (1)

Country Link
CN (1) CN110162645A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112328826A (en) * 2020-11-03 2021-02-05 珠海大横琴科技发展有限公司 Ship image retrieval method and device, electronic equipment and storage medium
CN113407749A (en) * 2021-06-28 2021-09-17 北京百度网讯科技有限公司 Picture index construction method and device, electronic equipment and storage medium

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130121589A1 (en) * 2005-05-09 2013-05-16 Salih Burak Gokturk System and method for enabling the use of captured images through recognition
CN103914463A (en) * 2012-12-31 2014-07-09 北京新媒传信科技有限公司 Method and device for retrieving similarity of picture messages
CN104462325A (en) * 2014-12-02 2015-03-25 百度在线网络技术(北京)有限公司 Search recommendation method and device
CN104765891A (en) * 2015-05-06 2015-07-08 苏州搜客信息技术有限公司 Searching shopping method based on pictures
CN106383776A (en) * 2016-08-30 2017-02-08 北京北信源软件股份有限公司 Monitoring and self-healing method and apparatus for distributed search cluster system
CN106445995A (en) * 2016-07-18 2017-02-22 腾讯科技(深圳)有限公司 Picture classification method and apparatus
CN106844421A (en) * 2016-11-30 2017-06-13 上海仙剑文化传媒股份有限公司 A kind of digital picture management method and system
CN107239571A (en) * 2017-06-28 2017-10-10 浪潮金融信息技术有限公司 Index structuring method based on multidimensional data space technology
CN108664583A (en) * 2018-05-04 2018-10-16 北京物灵智能科技有限公司 A kind of index tree method for building up and image search method
CN108830137A (en) * 2018-04-26 2018-11-16 深圳市赛亿科技开发有限公司 A kind of Intelligent mirror control method and system

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130121589A1 (en) * 2005-05-09 2013-05-16 Salih Burak Gokturk System and method for enabling the use of captured images through recognition
CN103914463A (en) * 2012-12-31 2014-07-09 北京新媒传信科技有限公司 Method and device for retrieving similarity of picture messages
CN104462325A (en) * 2014-12-02 2015-03-25 百度在线网络技术(北京)有限公司 Search recommendation method and device
CN104765891A (en) * 2015-05-06 2015-07-08 苏州搜客信息技术有限公司 Searching shopping method based on pictures
CN106445995A (en) * 2016-07-18 2017-02-22 腾讯科技(深圳)有限公司 Picture classification method and apparatus
CN106383776A (en) * 2016-08-30 2017-02-08 北京北信源软件股份有限公司 Monitoring and self-healing method and apparatus for distributed search cluster system
CN106844421A (en) * 2016-11-30 2017-06-13 上海仙剑文化传媒股份有限公司 A kind of digital picture management method and system
CN107239571A (en) * 2017-06-28 2017-10-10 浪潮金融信息技术有限公司 Index structuring method based on multidimensional data space technology
CN108830137A (en) * 2018-04-26 2018-11-16 深圳市赛亿科技开发有限公司 A kind of Intelligent mirror control method and system
CN108664583A (en) * 2018-05-04 2018-10-16 北京物灵智能科技有限公司 A kind of index tree method for building up and image search method

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112328826A (en) * 2020-11-03 2021-02-05 珠海大横琴科技发展有限公司 Ship image retrieval method and device, electronic equipment and storage medium
CN113407749A (en) * 2021-06-28 2021-09-17 北京百度网讯科技有限公司 Picture index construction method and device, electronic equipment and storage medium
CN113407749B (en) * 2021-06-28 2024-04-30 北京百度网讯科技有限公司 Picture index construction method and device, electronic equipment and storage medium

Similar Documents

Publication Publication Date Title
US11216861B2 (en) Color based social networking recommendations
US10049466B2 (en) Color name generation from images and color palettes
CN110245160B (en) Method and system for determining house decoration scheme
US10186054B2 (en) Automatic image-based recommendations using a color palette
US9679532B2 (en) Automatic image-based recommendations using a color palette
US9542704B2 (en) Automatic image-based recommendations using a color palette
US9135719B1 (en) Color name generation from images and color palettes
US9697573B1 (en) Color-related social networking recommendations using affiliated colors
CN104834693B (en) Visual pattern search method and system based on deep search
US20150379001A1 (en) Automatic color validation of image metadata
US20150379006A1 (en) Automatic image-based recommendations using a color palette
CN104537341B (en) Face picture information getting method and device
JP2019533205A (en) User keyword extraction apparatus, method, and computer-readable storage medium
JP6428795B2 (en) Model generation method, word weighting method, model generation device, word weighting device, device, computer program, and computer storage medium
JP6276279B2 (en) Method and apparatus for graphic code database update and retrieval
CN110515896A (en) Model resource management method, model file production method, device and system
CN104615639B (en) A kind of method and apparatus for providing the presentation information of picture
KR20170141246A (en) Target Search Method, Device and Server
CN108734510B (en) Advertisement recommendation method and system based on attribute matching
CN110162645A (en) Image search method, device and electronic equipment based on index
CN106407281B (en) Image retrieval method and device
CN110019646B (en) Method and device for establishing index
CN108491555B (en) Display device, display method thereof, and computer-readable storage medium
CN106649300A (en) Intelligent clothing matching recommendation method and system based on cloud platform
CN110287348A (en) A kind of GIF format picture searching method based on machine learning

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20190823