Detailed Description
It should be noted that the embodiments and features of the embodiments in the present application may be combined with each other without conflict. The present application will be described in detail below with reference to the embodiments with reference to the attached drawings.
In order to make the technical solutions better understood by those skilled in the art, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only partial embodiments of the present application, but not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
It should be noted that the terms "first," "second," and the like in the description and claims of this application and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It should be understood that the data so used may be interchanged under appropriate circumstances such that embodiments of the application described herein may be used. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
It will be understood that when an element such as a layer, film, region, or substrate is referred to as being "on" another element, it can be directly on the other element or intervening elements may also be present. Also, in the specification and claims, when an element is described as being "connected" to another element, the element may be "directly connected" to the other element or "connected" to the other element through a third element.
For convenience of description, some terms or expressions referred to in the embodiments of the present application are explained below:
and (3) hashing: it is a function of transforming an input of arbitrary length into a fixed length output, the output value is a hash value, the transformation is a compression mapping, that is, the space of the hash value is usually much smaller than that of the input, different inputs may be hashed into the same output, so it is impossible to determine the unique input value from the hash value, which is simply a function of compressing a message of arbitrary length into a message digest of a certain fixed length.
As introduced in the background art, the image clustering efficiency in the prior art is low, and in order to solve the problem of poor image clustering effect, embodiments of the present application provide a method, an apparatus, a storage medium, and a processor for image clustering based on a neural network.
According to an exemplary embodiment of the present application, a method of image clustering based on a neural network is provided.
Fig. 1 is a flow chart of a method of neural network-based image clustering according to an embodiment of the present application. As shown in fig. 1, the method comprises the steps of:
step S101, obtaining an image database comprising a plurality of images;
step S102, establishing a hash list corresponding to the image database;
step S103, determining an image similarity model by utilizing the hash list;
and step S104, constructing a clustering database according to the image similarity model.
In the above scheme, through obtaining the image database, handle the hash list that obtains the image database correspondence to the image in the image database who obtains again, carry out preliminary screening through the image in the hash list to the image database, recycle above-mentioned hash list according to the image of screening out and confirm the image similarity model, the process of clustering so can be accelerated, thereby the efficiency of obtaining the clustering database has been improved, and, filter earlier through the hash list, get rid of some irrelevant images, make image clustering effect better, namely, can realize better image clustering effect.
It should be noted that the steps illustrated in the flowcharts of the figures may be performed in a computer system such as a set of computer-executable instructions and that, although a logical order is illustrated in the flowcharts, in some cases, the steps illustrated or described may be performed in an order different than presented herein.
In an embodiment of the present application, the establishing of the hash list corresponding to the image database includes: preprocessing each image; and establishing a hash list corresponding to the image database according to the preprocessed images, and preprocessing the images, wherein the preprocessing can be normalization processing, and Z-score normalization and other methods can be adopted, so that all the images are unified in one range, the hash list is conveniently established, and the construction of a clustering database is facilitated.
In an embodiment of the present application, the establishing of the hash list corresponding to the image database includes: dividing pixel values of each pixel point of each image in a plurality of image channels to obtain a plurality of divided regions, wherein the pixel values of adjacent divided regions in one image channel are overlapped; respectively representing each divided region of each image channel by using a preset identifier, and determining the identifier of each pixel point on each image channel; determining a joint area identifier of each pixel point according to a plurality of identifiers of each pixel point on a plurality of image channels, wherein the joint area identifier is a hash value; and establishing a hash list corresponding to the image database according to the joint area identifier, wherein in a specific implementation mode, assuming that the image is a three-channel image, the image has 3 channels, the value of a pixel point on each channel is 0-255, and the value of 0-255 on each channel is divided according to a certain interval to obtain a hash key. For example, with a simple uniform overlap division method, as follows:
a first channel: 0 to 31,16 to 47,32 to 63,48 to 79.
A second channel: 0 to 31,16 to 47,32 to 63,48 to 79.
A third channel: 0 to 31,16 to 47,32 to 63,48 to 79.
Each channel is divided into 16 zones with an overlap between adjacent zones. The three channels have 16 × 16 ═ 4096 union regions. We use the letters a-P to denote the zones of each channel separately, and the joint zone identification of the three channels is the hash value. For example, if a pixel point is given as (10,40,8), the first channel is identified as 'a', the second channel belongs to two areas 'B', 'C', and the third channel belongs to 'a', the joint areas of the pixel point are identified as 'ABA' and 'ACA', the joint area is identified as a hash value, and other identification methods may be selected.
In an embodiment of the present application, after the joint area identifier of each pixel point is formed, the hash list corresponding to the image database is established, which further includes: determining the gray distribution characteristics of the image according to the joint area identification of each pixel point; and constructing the hash list according to the gray distribution characteristics of the images, namely determining the gray distribution characteristics of the images according to the joint area identification of each pixel point, and further constructing the hash list according to the gray distribution characteristics of the images.
In an embodiment of the application, determining the gray distribution characteristics of the image according to the joint area identifier of each pixel point includes: determining the frequency of occurrence of each joint region mark in each image; determining the likelihood probability of each joint area mark according to the frequency and the total number of pixel points of the image; determining the gray distribution characteristics of the image according to the likelihood probability, the ID and the joint area identification of the image, in a specific implementation mode, giving an image, calculating the joint area identification of each pixel point, counting the occurrence frequency of all the joint area identifications, and dividing the frequency by the total number of the pixel points of the image to obtain the likelihood probability P of the pixel point occurring in each joint area. For example, there is only one 100 x 100 image in the database, with image ID 3532, where half of the pixel values are (0,0,0) and the other half are (255 ). The gray scale distribution characteristic of this image is then:
{‘AAA’:{ID:3532,P:0.5},‘PPP’:{ID:3532,P:0.5}}
in an embodiment of the present application, after determining the gray scale distribution characteristics of the image, establishing a hash list corresponding to the image database, further includes: establishing a hash list corresponding to the image database according to the gray scale distribution characteristics of each image in the image database, constructing a hash table, summarizing gray scale distribution information of all images, and constructing a hash table, for example, the hash table H is constructed as follows,
H[‘AAA’]=[{ID:3532,P:0.5,CID:NULL},
{ID:22,P:0.23,CID:NULL},...],
H[‘BAA’]=[{ID:23451,P:0.045,CID:NULL},...],....
H[‘PPP’]=[{ID=3532,rate=0.5,CID=NULL},...]
in one embodiment of the present application, there are three image channels, namely, a first channel, a second channel and a third channel, and in the case where the image is a color image, there are three image channels, namely, a red (R) channel, a blue (B) channel and a green (G) channel.
An embodiment of the present application includes a hash table retrieval method, specifically, a given image x is determined, a gray distribution feature of the given image x is determined, a hash value is determined according to the gray distribution feature, and all images having the same gray area as the given image x are retrieved. For example, the gray distribution of x is characterized by { 'AAA': ID:3532, P:0.5}, 'PPP': ID:3532, P:0.5} }, and the search result is:
[{ID:3532,P:0.5,CID:NULL},
{ID:22,P:0.23,CID:NULL},...,
{ID=3532,rate=0.5,CID=NULL},...]
an embodiment of the present application, determining an image similarity model by using the hash list includes: constructing an image characteristic pre-training model; and constructing the image similarity model according to the image feature pre-training model, namely constructing the image feature pre-training model firstly, and constructing the image similarity model on the basis of the image feature pre-training model so as to ensure the accuracy of the image similarity model.
In an embodiment of the present application, the image similarity model includes an objective function, and the objective function is
Wherein D is
mk=||vm-vk||
2α denotes a hyper-parameter, vm and vk denote feature vectors corresponding to the mth image and the kth image, respectively, m is 1 or 2, k denotes a positive integer greater than or equal to 1, m ≠ k, N denotes a positive integer greater than or equal to 3, and two pictures x1 and x2 respectively input S to obtain vector representations v1 and v2, and the similarity D12 between x1 and x2 is defined as the distance between v1 and v2, and may be represented by, for example, a 2 norm:
D12=||v1-v2||2
the hyper-parameter α is set, and if D12< α, x1 and x2 are considered similar.
In the training process, each batch needs special organization training data, namely, images of the same group are extracted in proportion randomly, other images are from different groups, and each batch is guaranteed to contain the images of the same group. For example, assuming that the number of images of a batch is 128, the first two images are designated as the same type of image, and the last 126 images are randomly extracted from the rest of other categories (assuming that the number of categories is greater than 126), the objective function is
Whether the extracted images are of the same class is evaluated by calculating the size of an objective function (loss function).
According to an embodiment of the present application, constructing the image similarity model according to the image feature pre-training model includes: under the condition that the image characteristic pre-training model is a characteristic project, adding a full link layer on the image characteristic pre-training model to determine the image similarity model; and under the condition that the image feature pre-training model is not a feature engineering, adding a preset neural network layer on the image feature pre-training model to form a preset image similarity model, training the preset image similarity model, and determining the image similarity model so as to realize the accurate construction of the image feature pre-training model.
In an embodiment of the present application, constructing a clustering database according to the image similarity model includes: determining the characteristic vector of each image to be clustered according to the image similarity model; determining the images of the same category according to the feature vectors; adopting the images of the same category to construct a clustering database, using the feature vectors to represent the images, further obtaining the images of the same category according to the feature vectors, further adopting the image clustering database of the same category, in a specific implementation mode, using a trained similarity model, calculating the feature vectors of each image, then averaging to obtain the central feature f of the images of a certain category, if some images are clustered into a category, then each category information comprises a category number CID, all image IDs of the category and the central feature f of the category, the clustering database is designed as follows,
{‘CID1’:{images:[ID11,ID12,...]},f:[0.11,0.04,...]},
‘CID2’:{images:[ID21,ID22,...]},f:[0.7,0.001,...]},...}
in an embodiment of the present application, after the images of the same category are the images with the same category number, the same ID, and the same central feature, and a clustering database is constructed by using the images of the same category, the method further includes determining a feature vector of each of the images to be clustered, comparing each of the feature vectors with the central feature of each of the categories in the clustering database to obtain a first comparison result, determining the category of each of the images to be clustered according to whether the first comparison result is within a first predetermined range, adding each of the images to be clustered to the corresponding category, updating the central feature of each of the categories, comparing the updated central features of any two of the categories to obtain a second comparison result, fusing any two of the categories when the second comparison result is within a second predetermined range, updating the clustering database according to the fused categories, wherein N images to be clustered in the clustering database are set, each image is represented by xi, and the total number of the clustering database is α, and the total number of the clustering database is set as α:
and clustering once or for multiple times until a more accurate clustering database is obtained, so as to realize accurate clustering of the images.
The embodiment of the present application further provides a device for image clustering based on a neural network, and it should be noted that the device for image clustering based on a neural network according to the embodiment of the present application can be used for executing the method for image clustering based on a neural network provided by the embodiment of the present application. The following describes an apparatus for image clustering based on a neural network according to an embodiment of the present application.
Fig. 2 is a schematic diagram of an apparatus for neural network-based image clustering according to an embodiment of the present application. As shown in fig. 2, the apparatus includes:
an acquisition unit 10 for acquiring an image database including a plurality of images;
an establishing unit 20, configured to establish a hash list corresponding to the image database;
a first determining unit 30, configured to determine an image similarity model using the hash list;
and the building unit 40 is used for building a clustering database according to the similarity model.
In the above scheme, obtain the image database through the acquisition element, handle the hash list that the image database corresponds that obtains the image database to the image in the image database who obtains again, carry out preliminary screening through the image in the hash list to the image database, first definite unit utilizes above-mentioned hash list to confirm the image similarity model according to the image of screening out again, the process of clustering can accelerate like this, thereby the efficiency of obtaining the cluster database has been improved, and, filter earlier through the hash list, get rid of some irrelevant images, make image clustering effect better, can realize better image clustering effect.
In an embodiment of the application, the establishing unit includes a preprocessing module and an establishing module, and the preprocessing module is configured to preprocess each of the images; the establishing module is used for establishing a hash list corresponding to the image database according to the preprocessed images, preprocessing the images, wherein the preprocessing can be normalization processing, and Z-score normalization and other methods can be adopted, so that all the images are unified in one range, the hash list can be conveniently established, and the clustering database can be favorably established.
In an embodiment of the present application, the creating unit includes a dividing module, a first determining module and a second determining module, where the dividing module is configured to divide pixel values of each pixel point of each of the images in a plurality of image channels to obtain a plurality of divided regions, and the pixel values of adjacent divided regions in one of the image channels overlap each other; the first determining module is used for respectively representing each divided area of each image channel by using a preset identifier and determining the identifier of each pixel point on each image channel; the second determining module is used for determining a joint area identifier of each pixel point according to a plurality of identifiers of each pixel point on a plurality of image channels, wherein the joint area identifier is a hash value; and establishing a hash list corresponding to the image database according to the joint area identifier, wherein in a specific implementation mode, assuming that the image is a three-channel image, the image has 3 channels, the value of a pixel point on each channel is 0-255, and the value of 0-255 on each channel is divided according to a certain interval to obtain a hash key. For example, with a simple uniform overlap division method, as follows:
a first channel: 0 to 31,16 to 47,32 to 63,48 to 79.
A second channel: 0 to 31,16 to 47,32 to 63,48 to 79.
A third channel: 0 to 31,16 to 47,32 to 63,48 to 79.
Each channel is divided into 16 zones with an overlap between adjacent zones. The three channels have 16 × 16 ═ 4096 union regions. We use the letters a-P to denote the zones of each channel separately, and the joint zone identification of the three channels is the hash value. For example, if a pixel point is given as (10,40,8), the first channel is identified as 'a', the second channel belongs to two areas 'B', 'C', and the third channel belongs to 'a', the joint areas of the pixel point are identified as 'ABA' and 'ACA', the joint area is identified as a hash value, and other identification methods may be selected.
In an embodiment of the present application, after the joint area identifier of each pixel point is formed, the establishing unit further includes a third determining module and a first establishing module, where the third determining module is configured to determine a gray distribution characteristic of the image according to the joint area identifier of each pixel point; the first construction module is used for constructing the Hash list according to the gray distribution characteristics of the images, namely determining the gray distribution characteristics of the images according to the joint area identification of each pixel point, and further constructing the Hash list according to the gray distribution characteristics of the images.
In an embodiment of the present application, the third determining module includes a first determining sub-module, a second determining sub-module, and a third determining sub-module, where the first determining sub-module is configured to determine a frequency of occurrence of each joint area identifier in each of the images; the second determining submodule is used for determining the likelihood probability of each joint area mark according to the frequency and the total number of pixel points of the image; and the third determining submodule is used for determining the gray distribution characteristics of the image according to the likelihood probability, the ID and the joint area identification of the image. For example, there is only one 100 x 100 image in the database, with image ID 3532, where half of the pixel values are (0,0,0) and the other half are (255 ). The gray scale distribution characteristic of this image is then:
{‘AAA’:{ID:3532,P:0.5},‘PPP’:{ID:3532,P:0.5}}
in an embodiment of the application, after determining the gray scale distribution characteristics of the images, the establishing unit is further configured to establish a hash list corresponding to the image database according to the gray scale distribution characteristics of each of the images in the image database, construct a hash table, summarize gray scale distribution information of all the images, and construct a hash table, for example, the hash table H is constructed as follows,
H[‘AAA’]=[{ID:3532,P:0.5,CID:NULL},
{ID:22,P:0.23,CID:NULL},...],
H[‘BAA’]=[{ID:23451,P:0.045,CID:NULL},...],....
H[‘PPP’]=[{ID=3532,rate=0.5,CID=NULL},...]
in one embodiment of the present application, there are three image channels, namely, a first channel, a second channel and a third channel, and in the case where the image is a color image, there are three image channels, namely, a red (R) channel, a blue (B) channel and a green (G) channel.
An embodiment of the present application includes a hash table retrieving module, which is specifically configured to give an image x, determine a gray distribution characteristic of the image x, determine a hash value according to the gray distribution characteristic, and retrieve all images having a same gray area as the image x. For example, the gray distribution of x is characterized by { 'AAA': ID:3532, P:0.5}, 'PPP': ID:3532, P:0.5} }, and the search result is:
[{ID:3532,P:0.5,CID:NULL},
{ID:22,P:0.23,CID:NULL},...,
{ID=3532,rate=0.5,CID=NULL},...]
according to one embodiment of the application, the first determining unit comprises a second building module and a third building module, wherein the second building module is used for building an image feature pre-training model; the third construction module is used for constructing the image similarity model according to the image feature pre-training model, namely, firstly constructing the image feature pre-training model, and then constructing the image similarity model on the basis of the image feature pre-training model so as to ensure the accuracy of the image similarity model.
In an embodiment of the present application, the image similarity model includes an objective function, and the objective function is
Wherein D is
mk=||vm-vk||
2α denotes a hyper-parameter, vm and vk denote feature vectors corresponding to the mth image and the kth image, respectively, m is 1 or 2, k denotes a positive integer greater than or equal to 1, m ≠ k, N denotes a positive integer greater than or equal to 3, and two pictures x1 and x2 respectively input S to obtain vector representations v1 and v2, and the similarity D12 between x1 and x2 is defined as the distance between v1 and v2, and may be represented by, for example, a 2 norm:
D12=||v1-v2||2
the hyper-parameter α is set, and if D12< α, x1 and x2 are considered similar.
In the training process, each batch needs special organization training data, namely, images of the same group are extracted in proportion randomly, other images are from different groups, and each batch is guaranteed to contain the images of the same group. For example, assuming that the number of images of a batch is 128, the first two images are designated as the same type of image, and the last 126 images are randomly extracted from the rest of other categories (assuming that the number of categories is greater than 126), the objective function is
Whether the extracted images are of the same class is evaluated by calculating the size of an objective function (loss function).
In an embodiment of the present application, the third building module includes a fourth determining submodule and a fifth determining submodule, where the fourth determining submodule is configured to add a full link layer to the image feature pre-training model to determine the image similarity model when the image feature pre-training model is a feature engineering; and the fifth determining submodule is used for adding a preset neural network layer on the image feature pre-training model to determine a preset image similarity model under the condition that the image feature pre-training model is not a feature project, training the preset image similarity model and determining the image similarity model so as to realize the accurate construction of the image feature pre-training model.
In an embodiment of the present application, the building unit includes a fourth determining module, a fifth determining module, and a fourth building module, where the fourth determining module is configured to determine, according to the image similarity model, a feature vector of each of the images to be clustered; the fifth determining module is used for determining the images of the same category according to the feature vectors; the fourth building module is used for building a clustering database by using the images of the same category, using the feature vectors to represent the images, further obtaining the images of the same category according to the feature vectors, further using the image clustering database of the same category, in a specific implementation mode, using a trained similarity model, calculating the feature vectors of each image, then averaging to obtain the central feature f of the images of a certain category, if some images are clustered into a category, each category information contains a category number CID, all image IDs of the category and the central feature f of the category, the clustering database is designed as follows,
{‘CID1’:{images:[ID11,ID12,...]},f:[0.11,0.04,...]},
‘CID2’:{images:[ID21,ID22,...]},f:[0.7,0.001,...]},...}
in one embodiment of the present application, the image of the same category is the image with the same category number, the same ID and the same central feature, the apparatus further includes a second determining unit, a first comparing unit, a third determining unit, a first updating unit, a second comparing unit, a merging unit and a second updating unit, wherein after the clustering database is constructed by using the images of the same category, a feature vector of each image to be clustered is determined, the first comparing unit is configured to compare each feature vector with the central feature of each category in the clustering database to obtain a first comparison result, the third determining unit is configured to determine the category of each image to be clustered according to whether the first comparison result is within a first predetermined range, the first updating unit is configured to add each image to be clustered to the corresponding category to update the central feature of each category, the second comparing unit is configured to compare the central features of any two updated categories to obtain a second comparison result, the second comparing unit is configured to set the total number of the images to be clustered in the second predetermined range, and set a parameter of the total number of the images to be merged in the clustering database after the clustering database is set as α:
and finishing the first clustering to obtain a clustering database C, and carrying out secondary or multiple clustering on the C. The secondary clustering process is as follows:
and clustering once or for multiple times until a more accurate clustering database is obtained, so as to realize accurate clustering of the images.
The device for image clustering based on the neural network comprises a processor and a memory, wherein the acquiring unit, the establishing unit, the first determining unit, the constructing unit and the like are stored in the memory as program units, and the processor executes the program units stored in the memory to realize corresponding functions.
The processor comprises a kernel, and the kernel calls the corresponding program unit from the memory. One or more than one kernel can be set, and a better image clustering effect is obtained by adjusting kernel parameters.
The memory may include volatile memory in a computer readable medium, Random Access Memory (RAM) and/or nonvolatile memory such as Read Only Memory (ROM) or flash memory (flash RAM), and the memory includes at least one memory chip.
An embodiment of the present invention provides a storage medium on which a program is stored, which when executed by a processor implements the above-described method for image clustering based on a neural network.
The embodiment of the invention provides a processor, which is used for running a program, wherein the method for clustering images based on a neural network is executed when the program runs.
The embodiment of the invention provides equipment, which comprises a processor, a memory and a program which is stored on the memory and can run on the processor, wherein when the processor executes the program, at least the following steps are realized:
step S101, obtaining an image database comprising a plurality of images;
step S102, establishing a hash list corresponding to the image database;
step S103, determining an image similarity model by utilizing the hash list;
and step S104, constructing a clustering database according to the image similarity model.
The device herein may be a server, a PC, a PAD, a mobile phone, etc.
The present application further provides a computer program product adapted to perform a program of initializing at least the following method steps when executed on a data processing device:
step S101, obtaining an image database comprising a plurality of images;
step S102, establishing a hash list corresponding to the image database;
step S103, determining an image similarity model by utilizing the hash list;
and step S104, constructing a clustering database according to the image similarity model.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include forms of volatile memory in a computer readable medium, Random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). The memory is an example of a computer-readable medium.
Computer-readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), Digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium that can be used to store information that can be accessed by a computing device. As defined herein, a computer readable medium does not include a transitory computer readable medium such as a modulated data signal and a carrier wave.
It should also be noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in the process, method, article, or apparatus that comprises the element.
From the above description, it can be seen that the above-described embodiments of the present application achieve the following technical effects:
1) the utility model provides a method for image clustering based on neural network, through obtaining the image database, handle the image in the image database who obtains again and obtain the hash list that the image database corresponds, carry out preliminary screening through the image in the hash list to the image database, recycle above-mentioned hash list according to the image of screening out and confirm the image similarity model, the process of clustering can be quickened like this, thereby the efficiency of obtaining the cluster database has been improved, and, filter earlier through the hash list, get rid of some irrelevant images, make image clustering effect better, can realize better image clustering effect.
2) The utility model provides a device of image clustering based on neural network, through the acquisition element acquisition image database, handle the hash list that the image database corresponds that obtains the image database to the image in the image database who obtains again, carry out preliminary screening through the image in the hash list to the image database, the first unit of confirming of rethread utilizes above-mentioned hash list to confirm the image similarity model, the image similarity model here is improved image similarity model, and then the construction unit constructs the clustering database according to improved image similarity model, can realize better image clustering effect.
The above description is only a preferred embodiment of the present application and is not intended to limit the present application, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, improvement and the like made within the spirit and principle of the present application shall be included in the protection scope of the present application.