Article identification method, model training method, and device

By processing the features of object images through a recognition model using convolutional and clustering layers, the problem of low object recognition efficiency is solved, achieving more efficient object recognition.

CN113780320BActive Publication Date: 2025-10-24BEIJING WODONG TIANJUN INFORMATION TECH CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202011161727.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-10-27
Publication Date
2025-10-24
Estimated Expiration
2040-10-27

AI Technical Summary

Technical Problem

The problem with the low efficiency of item recognition in existing technologies, especially in online shopping environments, is the low recognition efficiency caused by comparing the similarity of item images with standard images one by one.

Method used

The recognition model, composed of convolutional and clustering layers, generates recognition results by performing convolutional processing and clustering on the features of object images, thus avoiding the need for one-to-one comparison and improving recognition efficiency.

Benefits of technology

Through clustering processing, recognition resources are saved, recognition efficiency is improved, and more efficient object recognition is achieved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113780320B_ABST
    Figure CN113780320B_ABST
Patent Text Reader

Abstract

Embodiments of the present application provide an article identification method and device, a model training method and device, electronic equipment and a storage medium, relating to the technical fields of Internet and deep learning, and including: obtaining respective target picture information corresponding to each of the to-be-identified articles; inputting each target picture information into an identification model; and generating an identification result corresponding to each of the to-be-identified articles. The identification model includes a convolution layer and a clustering layer. The clustering layer is configured to perform clustering processing on each target picture feature output by the convolution layer. Each target picture feature is generated by the convolution layer based on convolution processing of each target picture information. The identification result represents whether each to-be-identified article meets a pre-set article requirement. By increasing the clustering processing on each target picture feature output by the convolution layer, the clustering processing avoids the low identification efficiency caused by the one-by-one identification manner, thereby improving the identification efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] Embodiments of the present application relate to the technical field of Internet and deep learning, and particularly relate to an item identification method and model training method, device, electronic equipment and storage medium. BACKGROUND

[0002] With the rapid development of e-commerce, online shopping has revolutionized the traditional way of shopping. Online shopping has gradually become a favorite shopping method because of its convenience and speed. However, in the face of such a virtual environment as the Internet, there are inevitably some problems of information credibility, such as the authenticity of items. How to identify items has become a problem to be solved.

[0003] In the prior art, the pictures of items are usually compared with the pictures of real items one by one in terms of similarity, and the identification result is determined based on the similarity. If the similarity is greater than a threshold, the item corresponding to the identification result picture is the item that meets the pre-set item requirement, otherwise, it is the item that does not meet the item requirement.

[0004] In the process of implementing the present application, the inventors found that the prior art has at least the following problem: the one-by-one comparison method may cause low identification efficiency. SUMMARY

[0005] Embodiments of the present application provide an item identification method, a model training method, a device, electronic equipment and a storage medium to solve the problem of low identification efficiency.

[0006] In a first aspect, embodiments of the present application provide an item identification method, which comprises:

[0007] obtaining respective target picture information corresponding to each of the items to be identified;

[0008] inputting each of the target picture information into an identification model to generate an identification result corresponding to each of the items to be identified, wherein the identification model comprises a convolution layer and a clustering layer, the clustering layer is used to perform clustering processing on each target picture feature output by the convolution layer, each target picture feature is generated by the convolution layer according to the convolution processing of each target picture information, and the identification result represents whether each item to be identified meets a pre-set item requirement.

[0009] In the present embodiment, by performing clustering processing on each target picture feature output by the convolution layer, the problem of long identification time caused by determining whether each item to be identified meets the item requirement one by one can be avoided, and the technical effects of improving identification efficiency and saving identification resources are achieved.

[0010] In some embodiments, the target picture information of each of the target pictures is input into the recognition model to generate a recognition result corresponding to each of the to-be-recognized items, including:

[0011] The target picture information of each of the to-be-recognized items is extracted based on the convolution layer to obtain target picture features corresponding to each of the to-be-recognized items.

[0012] The target picture features corresponding to each of the to-be-recognized items are processed based on the clustering layer to obtain a target clustering result, the target clustering result representing that each of the to-be-recognized items belongs to N target categories, N being a positive integer greater than or equal to 1.

[0013] The target similarity of each of the target categories is output based on the pooling layer of the recognition model according to the target clustering result, and the recognition result is determined based on the target similarity of each of the target categories according to the pooling layer.

[0014] In this embodiment, the clustering result of each to-be-recognized item belonging to N target categories is obtained by processing each target picture feature, and the target similarity of each of the N target categories is calculated. By calculating the target similarity in units of target categories, the technical effect of saving computing resources and improving resource utilization can be achieved.

[0015] In some embodiments, the target clustering result is obtained by processing the target picture features corresponding to each of the to-be-recognized items based on the clustering layer, including:

[0016] At least one target picture feature is randomly selected from the target picture features corresponding to each of the to-be-recognized items as a target clustering center feature.

[0017] The target clustering result is determined according to the distance between the target picture features corresponding to the remaining to-be-recognized items and the target clustering center feature.

[0018] In this embodiment, by randomly selecting one or more target picture features as a target clustering center feature to determine the target clustering result, the technical effect of flexibility of clustering can be achieved.

[0019] In some embodiments, each of the target categories has at least one target center feature, the target center feature representing the common features of each to-be-recognized item in the target category.

[0020] In some embodiments, the target similarity of each of the target categories is output based on the pooling layer of the recognition model according to the target clustering result, including:

[0021] For each of the target categories, a target cosine similarity between a target center feature of the target category and a preset center feature is calculated based on the pooling layer, and the target cosine similarity is determined as a target similarity corresponding to the target category.

[0022] In the embodiment, the target cosine similarity is determined in units of target categories, and the calculation of the target cosine similarity does not need to be performed for each to-be-identified item, so that the technical effects of saving computing resources and improving computing efficiency can be achieved.

[0023] In some embodiments, the method further includes:

[0024] obtaining target text information corresponding to each of the to-be-identified items;

[0025] In addition, obtaining target picture information of each to-be-identified item includes: if it is determined that at least part of the to-be-identified items are suspected to not meet the item demand according to the target text information of each of the to-be-identified items, obtaining the target picture information of the suspected to-be-identified items that do not meet the item demand.

[0026] In the embodiment, by determining the suspected to-be-identified items that do not meet the item demand based on the target text information first, and then determining the to-be-identified items that do not meet the item demand based on the target picture information, the technical effects of improving the accuracy and reliability of identification can be achieved.

[0027] In some embodiments, after obtaining the target text information of each of the to-be-identified items, the method further includes:

[0028] inputting each of the target text information into a text classification model to generate a classification value, wherein the text classification model includes a linear layer arranged after a masked language modeling layer, the classification value is obtained by linear processing of information output by the masked language modeling layer of the text classification model by the linear layer of the text classification model, and the input of the masked language modeling layer of the text classification model is the target text information;

[0029] if the classification value is greater than a pre-set classification threshold, determining that the to-be-identified item is a suspected to-be-identified item that does not meet the item demand.

[0030] In the embodiment, by linearly processing the information output by the masked language modeling layer by the linear layer to obtain the classification value, the lightweight of the text classification model can be achieved, so that the technical effects of improving the efficiency of classification processing can be achieved.

[0031] In some embodiments, the method further includes:

[0032] obtaining training text information corresponding to each of the to-be-trained items, wherein part of the to-be-trained items do not meet the item demand, and the rest of the to-be-trained items meet the item demand;

[0033] inputting the training text information into a lightweight language representation model to train the text classification model, wherein the lightweight language representation model comprises a linear layer arranged after a masked language modeling layer, and the linear layer of the lightweight language representation model is configured to perform linear processing on information output by the masked language modeling layer of the lightweight language representation model, and the input of the masked language modeling layer of the lightweight language representation model is the training text information.

[0034] In some embodiments, inputting the training text information into a lightweight language representation model to train the text classification model comprises:

[0035] comparing the training value obtained by linear processing of the linear layer of the lightweight language representation model with a preset calibration value to obtain a training loss function;

[0036] adjusting the lightweight language representation model according to the training loss function to generate the text classification model.

[0037] In some embodiments, after obtaining the target text information corresponding to each of the to-be-identified items, the method further comprises:

[0038] inputting the target text information into a text filtering model, wherein the text filtering model is configured to match the target text information with a black and white list to obtain a matching result;

[0039] if the matching result is that the target text information hits a white list in the black and white list, determining that the to-be-identified item is a suspected item that does not meet the item demand.

[0040] In a second aspect, the embodiments of the present application provide a model training method applied to an item identification method, and the method comprises:

[0041] obtaining sample picture information corresponding to each of the sample items, wherein part of the sample items do not meet a preset item demand, and the rest of the sample items meet the item demand;

[0042] Input the sample picture information into a convolutional neural network model to obtain an identification model, wherein the convolutional neural network model comprises a convolutional layer and a clustering layer, the clustering layer is configured to perform clustering processing on sample picture features output by the convolutional layer, and each sample picture feature is generated by the convolutional layer based on convolutional processing of the sample picture information.

[0043] In some embodiments, inputting the sample picture information into a convolutional neural network model to obtain an identification model comprises:

[0044] Based on the convolutional layer, feature extraction is performed on the sample picture information of each sample item to obtain sample picture features corresponding to each sample item;

[0045] Based on the clustering layer, clustering processing is performed on the sample picture features corresponding to each sample item to obtain an initial clustering result, the initial clustering result represents that each sample item belongs to M initial categories, and M is a positive integer greater than or equal to 1;

[0046] Based on a pooling layer of the convolutional neural network model, a training similarity of each initial category is output according to the initial clustering result, and the identification model is generated according to the training similarity of each initial category.

[0047] In some embodiments, based on the clustering layer, clustering processing is performed on the sample picture features corresponding to each sample item to obtain an initial clustering result, comprising:

[0048] At least one sample picture feature is randomly selected from the sample picture features corresponding to each sample item as an initial clustering center feature;

[0049] The initial clustering result is determined according to the distance between the sample picture features corresponding to the remaining sample items and the initial clustering center feature.

[0050] In some embodiments, each initial category has at least one initial center feature, and the initial center feature represents the common features of the sample items in the initial category.

[0051] In some embodiments, based on the pooling layer of the convolutional neural network model, a training similarity of each initial category is output according to the initial clustering result, comprising:

[0052] For each initial category, a training cosine similarity between an initial center feature of the initial category and a preset center feature is calculated based on the pooling layer, and the training cosine similarity is determined as the training similarity corresponding to the initial category.

[0053] In some embodiments, the identification model is generated according to a training similarity of each of the initial categories, including:

[0054] The training similarity is compared with a calibration similarity to obtain a sample loss function;

[0055] The convolutional neural network model is adjusted according to the sample loss function to generate the identification model.

[0056] In a third aspect, the embodiments of the present application provide an article identification device, the device comprising:

[0057] A first acquisition module is configured to acquire target picture information corresponding to each of the articles to be identified;

[0058] A first generation module is configured to input each of the target picture information into an identification model to generate an identification result corresponding to each of the articles to be identified, wherein the identification model comprises a convolutional layer and a clustering layer, the clustering layer is configured to perform clustering processing on each target picture feature output by the convolutional layer, each target picture feature is generated by the convolutional layer based on the convolutional processing of each target picture information, and the identification result represents whether each of the articles to be identified meets a pre-set article demand.

[0059] In some embodiments, the first generation module is configured to perform feature extraction on the target picture information of each of the articles to be identified based on the convolutional layer to obtain a target picture feature corresponding to each of the articles to be identified, perform clustering processing on the target picture feature corresponding to each of the articles to be identified to obtain a target clustering result, the target clustering result represents that each of the articles to be identified belongs to N target categories, N is a positive integer greater than or equal to 1, the pooling layer of the identification model outputs a target similarity of each of the target categories based on the target clustering result, and the pooling layer determines the identification result based on the target similarity of each of the target categories.

[0060] In some embodiments, the first generation module is configured to randomly select at least one target picture feature as a target clustering center feature from the target picture features corresponding to each of the articles to be identified, and determine the target clustering result according to the distance between the target clustering center feature and the target picture features corresponding to the remaining articles to be identified.

[0061] In some embodiments, each of the target categories has at least one target center feature, and the target center feature represents common features of each of the articles to be identified in the target category.

[0062] In some embodiments, the first generation module is configured to, for each of the target categories, calculate a target cosine similarity between a target center feature of the target category and a preset center feature based on the pooling layer, and determine the target cosine similarity as a target similarity corresponding to the target category.

[0063] In some embodiments, the apparatus further comprises:

[0064] The second acquisition module is configured to acquire target text information corresponding to each of the to-be-identified items.

[0065] The first acquisition module is configured to, if it is determined that at least part of the to-be-identified items are suspected to not meet the item requirement according to the target text information of each of the to-be-identified items, acquire the target picture information of the suspected to-be-identified items that do not meet the item requirement.

[0066] In some embodiments, the apparatus further comprises:

[0067] The second generation module is configured to input each of the target text information into a text classification model to generate a classification value, wherein the text classification model comprises a linear layer arranged after a masked language modeling layer, the classification value is obtained by linear processing of information output by the masked language modeling layer of the text classification model, and the input of the masked language modeling layer of the text classification model is the target text information.

[0068] The determination module is configured to determine that a to-be-identified item is a suspected to-be-identified item that does not meet the item requirement if the classification value is greater than a preset classification threshold.

[0069] In some embodiments, the apparatus further comprises:

[0070] The third acquisition module is configured to acquire training text information corresponding to each of the to-be-trained items, wherein part of the to-be-trained items belong to items that do not meet the item requirement, and the remaining to-be-trained items belong to items that meet the item requirement.

[0071] The first training module is configured to input each of the training text information into a lightweight language representation model to train and generate the text classification model, wherein the lightweight language representation model comprises a linear layer arranged after a masked language modeling layer, the linear layer of the lightweight language representation model is configured to linearly process information output by the masked language modeling layer of the lightweight language representation model, and the input of the masked language modeling layer of the lightweight language representation model is each of the training text information.

[0072] In some embodiments, the first training module is configured to compare the training values linearly processed by the linear layer of the lightweight language representation model with preset calibration values, obtain a training loss function, adjust the lightweight language representation model according to the training loss function, and generate the text classification model.

[0073] In some embodiments, the device further comprises:

[0074] The matching module is configured to input each of the target text information into a text filtering model, and the text filtering model is configured to match the target text information with a black and white list to obtain a matching result.

[0075] The determination module is configured to determine that the to-be-identified item is a suspected item that does not meet the item demand if the matching result indicates that the target text information hits a white list in the black and white list.

[0076] In a fourth aspect, an embodiment of the present application provides a model training device applied to an item identification method, and the device comprises:

[0077] The fourth acquisition module is configured to acquire respective sample picture information of respective sample items, wherein part of the sample items belong to items that do not meet a preset item demand, and the rest of the sample items belong to items that meet the item demand.

[0078] The second training module is configured to input each of the sample picture information into a convolutional neural network model to train an identification model, wherein the convolutional neural network model comprises a convolutional layer and a clustering layer, the clustering layer is configured to perform clustering processing on respective sample picture features output by the convolutional layer, and each of the sample picture features is generated by performing convolutional processing on respective sample picture information by the convolutional layer.

[0079] In some embodiments, the second training module is configured to perform feature extraction on sample picture information of each of the sample items based on the convolutional layer to obtain sample picture features corresponding to each of the sample items, perform clustering processing on respective sample picture features corresponding to each of the sample items to obtain an initial clustering result, the initial clustering result represents that each of the sample items belongs to M initial categories, M is a positive integer greater than or equal to 1, and a pooling layer of the convolutional neural network model outputs a training similarity of each of the initial categories according to the initial clustering result, and generates the identification model according to the training similarity of each of the initial categories.

[0080] In some embodiments, the second training module is configured to randomly select at least one sample picture feature as an initial clustering center feature from the respective sample picture features of the sample items, and determine the initial clustering result according to distances between the initial clustering center feature and the respective sample picture features of the remaining sample items.

[0081] In some embodiments, each of the initial categories has at least one initial center feature, and the initial center feature represents a common feature of the sample items in the initial category.

[0082] In some embodiments, the second training module is configured to, for each of the initial categories, calculate a training cosine similarity between the initial center feature of the initial category and the preset center feature based on the pooling layer, and determine the training cosine similarity as a training similarity corresponding to the initial category.

[0083] In some embodiments, the second training module is configured to compare the training similarity with a calibration similarity to obtain a sample loss function, adjust the convolutional neural network model according to the sample loss function, and generate the recognition model.

[0084] In a fifth aspect, an embodiment of the present application provides an electronic device, including: a memory, a processor;

[0085] a memory; and a memory for storing instructions executable by the processor;

[0086] The processor is configured to perform the method in any of the embodiments of the first aspect above; or

[0087] The processor is configured to perform the method in any of the embodiments of the second aspect above.

[0088] In a sixth aspect, an embodiment of the present application provides a computer-readable storage medium, and the computer-readable storage medium stores computer-executable instructions. When the computer-executable instructions are executed by a processor, the computer-executable instructions are configured to implement the method in any of the embodiments of the first aspect above; or

[0089] The computer-executable instructions are configured to implement the method in any of the embodiments of the second aspect above when executed by a processor.

[0090] The embodiment of the present application provides an article identification method, a model training method, a device, an electronic device and a storage medium, which comprises the following steps: obtaining target picture information corresponding to each to-be-identified article; inputting each target picture information into an identification model to generate an identification result corresponding to each to-be-identified article, wherein the identification model comprises a convolution layer and a clustering layer, the clustering layer is used for clustering each target picture feature output by the convolution layer, each target picture feature is generated by the convolution layer through convolution processing on each target picture information, and the identification result represents whether each to-be-identified article meets a pre-set article demand. In the identification process, the clustering processing is added to each target picture feature output by the convolution layer, and through the clustering processing, the low identification efficiency caused by the one-by-one identification can be avoided, so that the technical effects of saving identification resources and improving identification efficiency are realized. BRIEF DESCRIPTION OF DRAWINGS

[0091] The accompanying drawings, which are incorporated herein and form part of the specification, illustrate embodiments consistent with the present disclosure and, together with the description, further serve to explain the principles of the present disclosure.

[0092] Figure 1 A schematic diagram of an application scenario of an article identification method according to an embodiment of the present application;

[0093] Figure 2 A schematic diagram of a first embodiment according to the present application;

[0094] Figure 3 A schematic diagram of a second embodiment according to the present application;

[0095] Figure 4 A schematic diagram of an identification model according to the present embodiment;

[0096] Figure 5 A schematic diagram of a third embodiment according to the present application;

[0097] Figure 6 A schematic diagram of a text classification model according to the present embodiment;

[0098] Figure 7 A schematic diagram of a fourth embodiment according to the present application;

[0099] Figure 8 A schematic diagram of a fifth embodiment according to the present application;

[0100] Figure 9 A schematic diagram of a sixth embodiment according to the present application;

[0101] Figure 10 A schematic diagram of a seventh embodiment according to the present application;

[0102] Figure 11 A schematic diagram of an eighth embodiment according to the present application;

[0103] Figure 12 For the ninth embodiment according to the present application;

[0104] The specific embodiments of the present disclosure have been shown by the above-mentioned drawings, and will be described in more detail hereinafter. These drawings and the written description are not intended to limit the scope of the present disclosure concept in any way, but to illustrate the present disclosure concept to those skilled in the art by referring to specific embodiments. DETAILED DESCRIPTION

[0105] The exemplary embodiments will be described in detail herein with reference to the accompanying drawings. In the following description, the same numbers refer to the same or similar elements unless otherwise represented. The embodiments described in the following exemplary embodiments do not represent all the embodiments consistent with the present disclosure. Rather, they are merely examples of devices and methods consistent with some aspects of the present disclosure as detailed in the appended claims.

[0106] The terms related to the embodiments of the present application are explained as follows:

[0107] Network platform: refers to various network service support systems and network service activities based on the Internet technology, such as network shopping services.

[0108] Goods: refers to various things or small items, such as goods (including physical goods and virtual goods), and can also include material resources, etc.

[0109] Illegal goods: refers to goods that do not meet the requirements or rules, such as goods that do not meet the requirements of goods, and when the present embodiment is applied to a network platform, illegal goods can be understood as goods that do not meet the online rules of the network platform. Specifically, if a good is a counterfeit good, the good can be an illegal good.

[0110] Regular goods: is the opposite concept of illegal goods, refers to goods that meet the requirements or rules, such as goods that meet the requirements of goods, and when the present embodiment is applied to a network platform, regular goods can be understood as goods that meet the online rules of the network platform.

[0111] Please refer to Figure 1 , Figure 1 is a schematic diagram of the application scenario of the goods identification method of the present embodiment.

[0112] As Figure 1 shown, it includes a goods provider 100, a network platform 200, and a user device 300.

[0113] Exemplarily, the goods provider 100 can be multiple, such as Figure 1Three item providers 100 are exemplarily shown. The item provider 100 can be an enterprise that produces and / or sells items, or an enterprise or individual that has the right to process (e.g. sell) items. As shown, any item provider 100 can send information about items to the network platform 200 through a terminal device corresponding to the item provider 100. Figure 1

[0114] It should be understood that the terminal device can be a desktop computer as shown in Figure 1 , or other devices that can establish a communication link with the network platform 100, such as a notebook computer, a handheld terminal, a server, etc.

[0115] The network platform 200 can be a shopping platform, and can include a server cluster as shown in Figure 1 , such as a server cluster composed of three servers as shown in Figure 1 . The network platform 200 can receive information about items sent by the item provider 100 through the server cluster, and can process the information about items through the server cluster, such as generating a shopping page and / or a push page including items, and sending the shopping page and / or the push page to the user device 300.

[0116] It should be understood that the network platform 200 can communicate with the item provider 100 and the user device 300 through the server cluster as shown in Figure 1 , or can be implemented by deploying a separate server, or by other virtual servers or processors, etc. The present embodiment is not limited in this regard.

[0117] The user device 300 can include a handheld terminal (such as a mobile phone as shown in Figure 1 , and can also be a palmtop computer), a notebook computer, a desktop computer, etc. Figure 1 Only three types of user devices are exemplarily shown. The user device 300 can show information about items provided by the network platform 200 to the user through a web page or an application program, and the user can purchase items that meet the user's needs through the user device 300.

[0118] It should be noted that the above examples are only used to exemplarily illustrate application scenarios in which the item identification method of the present embodiment can be applied, and cannot be understood as a limitation on the application scenarios. The elements in the application scenarios as shown in Figure 1 may be increased, reduced, and modified accordingly, and cannot be understood as a limitation on the elements.

[0119] ​It is worth noting that the item provider can provide the relevant information of the item to the network platform. In order to ensure the authenticity and reliability of the relevant information of the item provided by the item provider, the network platform can identify the relevant information of the item. For example, if the network platform determines that a certain item is a counterfeit item based on the relevant information of the item, the network platform can send a message to the item provider to reject the item online. If the item is an item that has been online, the network platform can perform offline processing on the item and send the item provider a reason for offline processing.

[0120] It is understood that the above examples are only used to illustrate that the network platform can identify the relevant information of the item provided by the item provider, and cannot be understood as a limitation on the content and effect of the identification by the network platform.

[0121] In the related art, when the network platform identifies the relevant information of the item provided by the item provider, the method usually used is to compare each picture of each item provided by each item provider with a preset standard picture one by one to calculate the similarity. If the similarity is greater than a preset threshold, it means that the item is more likely to be a real item, and the identification result is determined to be a regular item. On the contrary, if the similarity is less than the preset threshold, it means that the item is less likely to be a real item, and the identification result is determined to be a violation item.

[0122] However, the one-by-one comparison method may cause low identification efficiency.

[0123] The inventors of the present application have made creative efforts and obtained the inventive concept of the present application: inputting the pictures of each to-be-identified item into an identification model, performing clustering processing on the picture features output by the convolution layer based on the identification model, and determining the identification result based on the clustering processing result, thereby achieving the technical effect of improving the identification efficiency.

[0124] The technical solutions of the present application and how the technical solutions of the present application solve the above technical problems will be described in detail below with specific embodiments. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments. The embodiments of the present application will be described below with reference to the accompanying drawings.

[0125] Figure 2 According to the first embodiment of the present application, as shown in Figure 2 The item identification method of the present embodiment comprises:

[0126] S101: Obtain the respective target picture information corresponding to each to-be-identified item.

[0127] Exemplarily, the execution subject of the embodiment can be an article identification device (hereinafter referred to as an identification device), and the identification device can be a server (including a local server and a cloud server), a terminal device, a processor, a chip, and the like, which are not limited in the embodiment.

[0128] For example, when the method of the embodiment is applied to the application scenario as shown in Figure 1 , the identification device can be a network platform as shown in Figure 1 , and specifically can be a server cluster as shown in Figure 1 .

[0129] In the embodiment, the number of the to-be-identified articles is multiple, and each to-be-identified article corresponds to at least one target picture information. The target picture information can be used to represent the information of the to-be-identified article in the form of a picture.

[0130] That is, this step can be understood as: the identification device obtains one or more target picture information corresponding to each of the multiple to-be-identified articles.

[0131] S102: input each target picture information into an identification model to generate an identification result corresponding to each to-be-identified article, wherein the identification model includes a convolution layer and a clustering layer, the clustering layer is used to perform clustering processing on each target picture feature output by the convolution layer, each target picture feature is generated by the convolution layer according to the convolution processing of each target picture information, and the identification result represents whether each to-be-identified article meets a pre-set article demand.

[0132] Exemplarily, the target picture feature can be used to represent the feature information of the target picture information, such as the features of pixels and colors of the target picture, and the target picture feature can be a feature vector or a hash value.

[0133] In the embodiment, the convolution layer of the identification model can perform convolution processing on each target picture information to generate a target picture feature corresponding to each target picture information, and the clustering layer of the identification model can perform clustering processing on each target picture feature and generate an identification result based on the result of the clustering processing.

[0134] It is worth noting that in the identification process of the embodiment, the clustering processing process is added, and specifically, after obtaining multiple target picture features through convolution operation, the clustering processing is performed, which can avoid the disadvantage of long time consumption caused by one-to-one identification, thereby achieving the technical effect of improving the efficiency of identification.

[0135] Based on the above analysis, the embodiment provides an article identification method, which comprises: obtaining respective target picture information corresponding to each to-be-identified article; inputting each target picture information into an identification model to generate an identification result corresponding to each to-be-identified article, wherein the identification model comprises a convolution layer and a clustering layer, the clustering layer is used for clustering processing each target picture feature output by the convolution layer, each target picture feature is generated by the convolution layer based on convolution processing of each target picture information, and the identification result represents whether each to-be-identified article meets a pre-set article demand. By increasing the clustering processing of each target picture feature output by the convolution layer in the identification process, the low identification efficiency caused by the one-by-one identification can be avoided, thereby achieving the technical effects of saving identification resources and improving identification efficiency.

[0136] Figure 3 According to the second embodiment of the present application, as shown in Figure 3 The article identification method of the embodiment comprises:

[0137] S201: Obtain respective target picture information corresponding to each to-be-identified article.

[0138] For example, the description of S201 can refer to S101, which will not be repeated here.

[0139] S202: Input each target picture information into an identification model, perform feature extraction on each to-be-identified article based on the convolution layer of the identification model, and obtain target picture features corresponding to each to-be-identified article.

[0140] For example, the description of the target picture features can refer to the first embodiment, which will not be repeated here.

[0141] This step can be understood as: for each to-be-identified article, the convolution layer determines the target picture features of the to-be-identified article based on the target picture information of the to-be-identified article. For example, the convolution layer determines the target picture features of a to-be-identified article based on the color and / or pixels in the target picture information of the to-be-identified article.

[0142] In some embodiments, the method for generating the identification model comprises:

[0143] Step 1: Obtain respective sample picture information corresponding to each sample article, wherein part of the sample articles belong to articles that do not meet the article demand, and the remaining sample articles belong to articles that meet the article demand.

[0144] Exemplarily, the sample items can be used for characterization, for training the generated identification model, and accordingly, the sample picture information is picture information corresponding to the sample items, and one sample item includes at least one sample picture information.

[0145] In combination with the application scenario as shown in Figure 1 It can be understood that, in the sample items, there are both irregular items and regular items. For example, the number of sample items is M, and the M sample items include X irregular items and Y regular items, i.e., X+Y=M.

[0146] It should be understood that the total number of sample items, the number of irregular items, and the number of regular items can be set by the identification device based on demand, historical records, and experiments, and the present embodiment is not limited.

[0147] Step 2: input each sample picture information into the convolutional neural network model, and perform feature extraction on each sample item based on the convolutional layer of the convolutional neural network model to obtain sample picture features corresponding to each sample item.

[0148] Similarly, the sample picture features can be used for characterization, and the feature information of the sample picture information, such as the features of pixels and colors of the sample picture, and the sample picture features can be a feature vector or a hash value.

[0149] Step 3: based on the clustering layer of the convolutional neural network model, randomly select at least one sample picture feature from the sample picture features corresponding to each sample item as an initial clustering center feature.

[0150] Exemplarily, the initial clustering center feature can be used for characterization, and the basis for clustering processing of each sample picture feature, that is, the initial clustering center feature can be used to divide each sample picture feature into different initial categories.

[0151] It is worth noting that the present embodiment does not limit the number of sample picture features, which can be one or more, and the initial clustering feature can be randomly selected.

[0152] Step 4: based on the clustering layer, determine the initial clustering result according to the distance between the sample picture features corresponding to the remaining sample items and the initial clustering center feature, and the initial clustering result represents that each sample item belongs to M initial categories, and M is a positive integer greater than or equal to 1.

[0153] Exemplarily, the distance can be used to represent a hash distance between the sample picture feature and the initial clustering center feature. Generally, if the distance between a sample picture feature and an initial clustering center feature is less than a preset distance threshold, the sample picture feature can be considered as a feature of the same category as the initial clustering center feature.

[0154] It is worth noting that the clustering can be an iterative process, which can be implemented by a k-means algorithm.

[0155] Specifically, the identification device can randomly select K sample picture features as initial clustering center features, and then calculate the distance between each sample picture feature and each initial clustering center feature, and assign each sample picture feature to the initial clustering center feature closest to it. The initial clustering center features and the sample picture features assigned to them represent an initial category. The initial clustering center features of the cluster are recalculated according to the existing sample picture features in the cluster every time a sample picture feature is assigned. This process will be repeated until a certain termination condition is met. The termination condition can be that no (or a minimum number of) sample picture features are reassigned to different initial categories, no (or a minimum number of) initial clustering center features change, or the error sum of squares is locally minimized.

[0156] Step 5: For each initial category, calculate the training cosine similarity between the initial center feature of the initial category and the preset center feature based on the pooling layer, and determine the training cosine similarity as the training similarity corresponding to the initial category.

[0157] Exemplarily, each initial category has at least one initial center feature, and the initial center feature represents the common features of the sample items in the initial category. The preset center feature is pre-set to represent the common features of an initial category.

[0158] In this embodiment, the training cosine similarity can be calculated by the pooling layer, and the training cosine similarity can be determined as the training similarity. The method for calculating the training cosine similarity can be referred to related art, which will not be described here.

[0159] Step 6: Determine the training similarity and the calibration similarity for comparison to obtain a sample loss function.

[0160] Exemplarily, the calibration similarity can be used to represent the actual similarity pre-calibrated. The sample loss function is used to represent the difference between the training similarity and the calibration similarity.

[0161] Step 7: Adjust the convolutional neural network model according to the sample loss function to generate an identification model.

[0162] Exemplarily, the parameters (such as weight coefficients of each channel and the like) of the convolutional neural network model are adjusted based on the sample loss function until the sample loss function meets the preset requirement or the iteration number reaches the preset iteration number.

[0163] And based on the above example, the sample loss function is used to represent the difference between the training similarity and the calibration similarity, then for the relatively large sample loss function, the adjustment range can be relatively large, and vice versa, for the relatively small sample loss function, the adjustment range can be relatively small, to improve the efficiency of adjustment and save adjustment resources.

[0164] S203: Select at least one target picture feature as a target clustering center feature from the target picture features corresponding to each of the to-be-identified items.

[0165] Exemplarily, the target clustering center feature can be used to represent the basis feature for clustering the target picture features, that is, the target clustering center feature can be used to divide the target picture features into different target categories.

[0166] It is worth noting that the number of target clustering center features is not limited in this embodiment, which can be one or multiple, and the target clustering center feature can be randomly selected.

[0167] S204: Determine a target clustering result according to the distance between the target picture features corresponding to the remaining target items and the target clustering center feature, the target clustering result representing that each target item belongs to N target categories, N being a positive integer greater than or equal to 1.

[0168] Exemplarily, the description of clustering each target picture feature can be referred to the description of clustering each sample picture feature in the above example, which will not be repeated here.

[0169] Wherein, N and M can be different positive integers or the same positive integer.

[0170] S205: For each target category, calculate a target cosine similarity between the target center feature of the target category and the preset center feature based on the pooling layer, and determine the target cosine similarity as the target similarity corresponding to the target category.

[0171] Exemplarily, the calculation principle of the target similarity can be referred to the calculation principle of the training similarity, which will not be repeated here.

[0172] It is worth noting that in some embodiments, the recognition model includes a convolutional layer, and the clustering operation can be performed by the convolutional layer, that is, S203 and S204 can be performed by the convolutional layer.

[0173] In some other embodiments, the recognition model comprises a pooling layer, and the clustering operation can be performed by the pooling layer, i.e., S203 and S204 can be performed by the pooling layer.

[0174] In some other embodiments, the recognition model comprises a clustering layer, and the clustering operation can be performed by the clustering layer, i.e., S203 and S204 can be performed by the clustering layer.

[0175] For example, when the recognition model comprises the clustering layer and the clustering operation is performed by the clustering layer, the above examples and Figure 4 It can be seen that the recognition model can comprise at least five parts, i.e., an input layer, a convolution layer, a clustering layer, a pooling layer, and an output layer, wherein,

[0176] The input layer can be used to obtain the information of each target picture and send the information of each target picture to the convolution layer.

[0177] The convolution layer can be used to perform convolution processing on the information of each target picture, obtain the target picture features corresponding to the information of each target picture, and send the target picture features to the clustering layer.

[0178] The clustering layer can be used to perform clustering processing on the target picture features, obtain the target clustering results, and send the target clustering results to the pooling layer.

[0179] The pooling layer can be used to determine the target similarity according to the target clustering results and send the target similarity to the output layer.

[0180] The output layer can be used to output the recognition result of whether each to-be-recognized item meets the demand according to the target similarity.

[0181] S206: For each target category, the recognition result is determined according to the target similarity corresponding to the target category, and the recognition result represents whether each to-be-recognized item meets the demand.

[0182] For example, the target similarity of any target category is compared with a preset similarity threshold, if the target similarity of any target category is greater than the similarity threshold, the to-be-recognized item of the any category can be determined as an item meeting the demand, otherwise, if the target similarity of any target category is greater than the similarity threshold, the to-be-recognized item of the any category can be determined as an item not meeting the demand.

[0183] S207: The to-be-recognized item determined as not meeting the demand is processed to avoid.

[0184] Exemplarily, if the identification device determines that one or more of the plurality of to-be-identified items do not meet the item requirements based on the identification, the identification device can perform avoidance processing on the determined items that do not meet the item requirements, of course, the staff can also perform avoidance processing on the items that do not meet the item requirements determined by the identification device, and the present embodiment is not limited thereto. For example, when the method of the present embodiment is applied to the application scenario as shown in Figure 1 , the avoidance processing can be offline processing.

[0185] For example, in combination with the application scenario as shown in Figure 1 , when the identification device (equivalent to the server cluster shown in Figure 1 ) determines that the to-be-identified item A is a violation item, and the violation item is provided by the item provider 1, the identification device performs offline processing on the to-be-identified item A, and sends a prompt message to the item provider 1, the prompt message being used to prompt the reason why the identification device performs offline processing on the to-be-identified item A. Alternatively, in another possible implementation manner, when the identification device determines that the to-be-identified item A is a violation item, the staff can also perform offline processing on the to-be-identified item A.

[0186] Figure 5 For the third embodiment of the present application, as shown in Figure 5 , the item identification method of the present embodiment comprises the following steps.

[0187] S301: Obtain target text information corresponding to each to-be-identified item.

[0188] Exemplarily, the target text information can be used to represent text information for describing the to-be-identified item, and the target text information includes text information provided by the item provider for describing the to-be-identified item, such as title information and text information (such as performance-related information and parameter-related information) of the to-be-identified item; or text information provided by the user for describing the to-be-identified item, such as comments of the user after purchasing the item.

[0189] S302: Input each target text information into a text classification model to generate a classification value, wherein the text classification model comprises a linear layer arranged after a masked language modeling layer, the classification value is obtained by linear processing of information output by the masked language modeling layer of the text classification model, and the input of the masked language modeling layer of the text classification model is the target text information.

[0190] Exemplarily, in combination with Figure 6 , it can be seen that the text classification model at least comprises an input layer (Input), a masked language modeling layer (Masked Language Model, MLM), a linear layer (Linear), and an output layer (Output).

[0191] The input layer can input each target text information to the masked language modeling layer, the masked language modeling layer performs de-noising processing on each target text information, and sends the de-noising processed information to the linear layer, the linear layer performs linear processing (such as linear combination and / or linear transformation, etc.) on the de-noising processed information, obtains a classification value, and sends the classification value to the output layer, and the output layer can be provided with an activation function (sigmoid), and the classification value is compressed by the activation function to obtain a value between 0 and 1.

[0192] In some embodiments, the method of generating a text classification model can include:

[0193] Step 1: Obtain training text information corresponding to each of the to-be-trained items, wherein part of the to-be-trained items belong to items that do not meet the item demand, and the remaining to-be-trained items belong to items that meet the item demand.

[0194] Exemplarily, the to-be-trained items can be used to represent the items for training the text classification model, accordingly, the training text information is the text information corresponding to the to-be-trained items, and one to-be-trained item includes at least one training text information.

[0195] In combination with the application scenario as shown in Figure 1 , it can be understood that in the to-be-trained items, there are both irregular items (at least one of the certificates (which can specifically include a tour guide certificate and a lawyer certificate, etc.), electronic red packets and rebates) and regular items. For example, the number of to-be-trained items is M, including X irregular items and Y regular items, X+Y=M.

[0196] It should be understood that the total number of to-be-trained items, the number of irregular items and the number of regular items can be set by the identification device based on demand, historical records and experiments, and the present embodiment is not limited.

[0197] Step 2: input each training text information to the lightweight language representation (ALBERT) model to obtain a training value, wherein the training value is generated by the linear layer of the lightweight language representation model performing linear processing on the information output by the masked language modeling layer, and the input of the masked language modeling layer of the lightweight language representation model is each training text information.

[0198] Similarly, the input layer of the lightweight language representation model can input each training text information to the masked language modeling layer, the masked language modeling layer performs de-noising processing on each training text information, and sends the de-noising processed information to the linear layer, the linear layer performs linear processing (such as linear combination and / or linear transformation, etc.) on the de-noising processed information, and obtains a training value, wherein the training value can be a linear processed value, or the linear layer sends the linear processing result to the output layer, and the output layer can be provided with an activation function, and the linear processing result is compressed by the activation function to obtain a training value between 0 and 1.

[0199] Step 3: Calculate the training loss function between the training value and the calibration value.

[0200] Step 4: Adjust the lightweight language representation model according to the training loss function to generate a text classification model.

[0201] For example, the parameters (such as weight coefficients of each channel, etc.) of the lightweight language representation model are adjusted based on the training loss function until the training loss function meets the preset requirement, or the iteration number reaches the preset iteration number.

[0202] S303: Determine whether the classification value is greater than a preset classification threshold, if yes, execute S304, if no, execute S307.

[0203] S304: Determine the to-be-identified article as a suspected article that does not meet the article demand if the classification value is greater than the classification threshold.

[0204] For example, the suspected article that does not meet the article demand can be used to represent the to-be-identified article that does not meet the article demand.

[0205] In some embodiments, S302 to S304 can be replaced by the following steps:

[0206] Step 1: Input each target text information to the text filtering model, and the text filtering model is used to match the target text information with the black and white list to obtain a matching result.

[0207] For example, the black and white list includes a blacklist and a whitelist, and the text filtering model matches the target text information with the black and white list.

[0208] In combination with the above example, the blacklist can be a list including at least one keyword in the certificate, electronic red envelope and rebate.

[0209] Step 2: If the matching result is that the target text information hits the whitelist in the black and white list, determine the to-be-identified article as a suspected article that does not meet the article demand.

[0210] Exemplarily, if any target text information hits the white list, the to-be-identified item corresponding to the target text information hitting the black list is determined as a suspected item not satisfying the item demand; conversely, if any target text information hits the black list, the to-be-identified item corresponding to the target text information hitting the black list is determined as an item not satisfying the item demand.

[0211] In some embodiments, the black list or the white list can also be set. Preferably, the black list can be set, if a certain target text information hits the black list, the to-be-identified item corresponding to the target text information is determined as an item not satisfying the item demand, conversely, if no target text information hits the black list, the to-be-identified item corresponding to the target text information is determined as a suspected item not satisfying the item demand, so that the matching efficiency can be improved.

[0212] In some embodiments, part of the keywords can be set by the identification device, and the relevant keywords can be obtained by the identification device performing semantic analysis on the part of the keywords, and the part of the keywords and the relevant keywords are determined as the black and white lists.

[0213] S305: Obtain target picture information corresponding to each suspected item not satisfying the item demand.

[0214] S306: Input the target picture information corresponding to each suspected item not satisfying the item demand into an identification model to generate an identification result corresponding to each suspected item not satisfying the item demand, wherein the identification model comprises a convolution layer and a clustering layer, the clustering layer is used to perform clustering processing on each target picture feature corresponding to each suspected item not satisfying the item demand output by the convolution layer, each target picture feature corresponding to each suspected item not satisfying the item demand is generated by the convolution layer according to each target picture information corresponding to each suspected item not satisfying the item demand, and the identification result represents whether each suspected item not satisfying the item demand is an item not satisfying the item demand.

[0215] S307: Determine the to-be-identified item less than or equal to the classification threshold as an item not satisfying the item demand.

[0216] S308: Perform avoidance processing on the suspected item not satisfying the item demand determined as the item not satisfying the item demand.

[0217] Exemplarily, the principles of S305 and S306 can be referred to the description of the identification of each to-be-identified item in the first embodiment, and can also be referred to the description of the identification of each to-be-identified item in the second embodiment, and the principle of S308 can be referred to the description of the identification of each to-be-identified item in the second embodiment, which will not be described here.

[0218] In some embodiments, S306 can be replaced by the following steps:

[0219] Step 1: For each target picture information corresponding to the suspected unsatisfied item, calculate the hash distance between the target picture information corresponding to the suspected unsatisfied item and the pre-set reference picture information.

[0220] Exemplarily, the reference picture information can be used to represent the information of the picture of the item satisfying the item demand. The description of the hash distance can refer to the above examples, which will not be described here.

[0221] Step 2: Compare the hash distance obtained in step 2 with the pre-set hash distance threshold. If the hash distance obtained in step 2 is greater than the hash distance threshold, it is determined that the suspected unsatisfied item is an unsatisfied item. Otherwise, if the hash distance obtained in step 2 is less than the hash distance threshold, it is determined that the suspected unsatisfied item is a satisfied item.

[0222] In other embodiments, S306 can also be replaced by the following steps:

[0223] Step 1: Extract the picture features of each target picture information corresponding to the suspected unsatisfied item.

[0224] Step 2: Input each picture feature into a lightweight depth separable convolution model (mobilenet_v2 or EfficientNet) to output a similarity.

[0225] Step 3: Compare the similarity with the pre-set similarity threshold. If the similarity is greater than the similarity threshold, the suspected unsatisfied item is determined to be a satisfied item. Otherwise, if the similarity is less than the similarity threshold, the suspected unsatisfied item is determined to be an unsatisfied item.

[0226] Figure 7 For the fourth embodiment according to the present application, as shown in Figure 7 The model training method applied to the item identification method of the present embodiment comprises:

[0227] S401: Obtain the respective sample picture information of each sample item, wherein part of the sample items belong to unsatisfied items, and the remaining sample items belong to satisfied items.

[0228] S402: input each sample picture information to a convolutional neural network model to obtain a recognition model by training, wherein the convolutional neural network model comprises a convolutional layer and a clustering layer, the clustering layer is used for clustering each sample picture feature output by the convolutional layer, and each sample picture feature is generated by the convolutional layer based on convolution processing of each sample picture information.

[0229] In some embodiments, S402 comprises:

[0230] Step 1: feature extraction is performed on the sample picture information of each sample item based on the convolutional layer to obtain sample picture features corresponding to each sample item.

[0231] Step 2: clustering processing is performed on the sample picture features corresponding to each sample item to obtain an initial clustering result, the initial clustering result represents that each sample item belongs to M initial categories, and M is a positive integer greater than or equal to 1.

[0232] Step 3: a training similarity of each initial category is output based on a pooling layer of the convolutional neural network model according to the initial clustering result, and the recognition model is generated according to the training similarity of each initial category.

[0233] In some embodiments, the clustering processing on the sample picture features corresponding to each sample item to obtain an initial clustering result comprises:

[0234] Step 1: at least one sample picture feature is randomly selected from the sample picture features corresponding to each sample item as an initial clustering center feature;

[0235] Step 2: the initial clustering result is determined according to the distance between the sample picture features corresponding to the remaining sample items and the initial clustering center feature.

[0236] In some embodiments, each initial category has at least one initial center feature, and the initial center feature represents the common features of the sample items in the initial category.

[0237] In some embodiments, the training similarity of each initial category is output based on the pooling layer of the convolutional neural network model according to the initial clustering result, comprising:

[0238] For each initial category, a training cosine similarity between the initial center feature of the initial category and a preset center feature is calculated based on the pooling layer, and the training cosine similarity is determined as the training similarity corresponding to the initial category.

[0239] In some embodiments, the recognition model is generated according to the training similarity of each initial category, comprising:

[0240] Step 1: comparing the training similarity with the calibration similarity to obtain a sample loss function;

[0241] Step 2: adjusting the convolutional neural network model according to the sample loss function to generate the identification model.

[0242] Figure 8 For the fifth embodiment of the present application, as shown in Figure 8 The article identification device of the present embodiment comprises:

[0243] The first acquisition module 11 is configured to acquire target picture information corresponding to each of the to-be-identified articles.

[0244] The first generation module 12 is configured to input each of the target picture information into an identification model to generate an identification result corresponding to each of the to-be-identified articles, wherein the identification model comprises a convolutional layer and a clustering layer, the clustering layer is configured to perform clustering processing on each target picture feature output by the convolutional layer, each target picture feature is generated by the convolutional layer based on convolutional processing of each target picture information, and the identification result represents whether each to-be-identified article meets a pre-set article requirement.

[0245] Figure 9 For the sixth embodiment of the present application, as shown in Figure 9 The article identification device of the present embodiment comprises:

[0246] The processing module 13 is configured to perform avoidance processing on the to-be-identified article that is determined as not meeting the article requirement.

[0247] In some embodiments, the first generation module 12 is configured to perform feature extraction on the target picture information of each to-be-identified article based on the convolutional layer to obtain a target picture feature corresponding to each to-be-identified article, perform clustering processing on the target picture feature corresponding to each to-be-identified article to obtain a target clustering result, wherein the target clustering result represents that each to-be-identified article belongs to N target categories, N is a positive integer greater than or equal to 1, the pooling layer of the identification model outputs a target similarity of each target category based on the target clustering result, and the identification result is determined based on the target similarity of each target category.

[0248] In some embodiments, the first generation module 12 is configured to randomly select at least one target picture feature as a target clustering center feature from the target picture features corresponding to each of the to-be-identified articles, and determine the target clustering result based on the distance between the target clustering center feature and the target picture features corresponding to the remaining to-be-identified articles.

[0249] In some embodiments, each of the target categories has at least one target-centric feature, and the target-centric feature represents a common feature of each to-be-identified object in the target category.

[0250] In some embodiments, the first generation module 12 is configured to calculate, for each target category, a target cosine similarity between a target center feature of the target category and a preset center feature based on the pooling layer, and determine the target cosine similarity as the target similarity corresponding to the target category.

[0251] Figure 10 According to the seventh embodiment of the present application, Figure 10 As shown, the object identification device of this embodiment further includes:

[0252] The second acquisition module 14 is used to obtain the target text information corresponding to each of the objects to be identified;

[0253] Furthermore, the first acquisition module 12 is configured to acquire the target image information of the items suspected of not meeting the item requirements if it is determined based on the target text information of each of the items to be identified that at least some of the items to be identified are items suspected of not meeting the item requirements.

[0254] Combine Figure 10 It is known that, in some embodiments, the apparatus further comprises:

[0255] A second generating module 15 is configured to input each target text information into a text classification model to generate a classification value, wherein the text classification model includes a linear layer provided after the masked language modeling layer, and the classification value is obtained by the linear layer of the text classification model performing linear processing on information output by the masked language modeling layer of the text classification model, and the input of the masked language modeling layer of the text classification model is the target text information;

[0256] The determination module 16 is configured to determine that the item to be identified is an item suspected of not meeting the item requirement if the classification value is greater than a preset classification threshold.

[0257] Combine Figure 10 It is known that, in some embodiments, the apparatus further comprises:

[0258] A third acquisition module 17 is configured to acquire training text information corresponding to each to-be-trained item, wherein some of the to-be-trained items do not meet the item requirement, and the remaining to-be-trained items meet the item requirement;

[0259] The first training module 18 is configured to input each of the training text information into a lightweight language representation model to train a text classification model, wherein the lightweight language representation model comprises a linear layer arranged after a masked language modeling layer, the linear layer of the lightweight language representation model is configured to perform linear processing on information output by the masked language modeling layer of the lightweight language representation model, and an input of the masked language modeling layer of the lightweight language representation model is each of the training text information.

[0260] In some embodiments, the first training module 18 is configured to compare a training value obtained by linear processing of the linear layer of the lightweight language representation model with a preset calibration value, obtain a training loss function, adjust the lightweight language representation model according to the training loss function, and generate the text classification model.

[0261] In combination Figure 10 It can be known that, in some embodiments, the device further comprises:

[0262] The matching module 19 is configured to input each of the target text information into a text filtering model, and the text filtering model is configured to match the target text information with a black and white list to obtain a matching result.

[0263] In addition, the determination module 16 is configured to determine that the to-be-identified article is a suspected article that does not meet the article demand if the matching result is that the target text information hits a white list in the black and white list.

[0264] Figure 11 According to the eighth embodiment of the present application, as shown in the figure, the model training device for the article identification method of the present embodiment comprises: Figure 11

[0265] The fourth acquisition module 21 is configured to acquire respective sample picture information of each sample article, wherein part of the sample articles belong to articles that do not meet the article demand, and the rest of the sample articles belong to articles that meet the article demand.

[0266] The second training module 22 is configured to input each of the sample picture information into a convolutional neural network model to train an identification model, wherein the convolutional neural network model comprises a convolutional layer and a clustering layer, the clustering layer is configured to perform clustering processing on each sample picture feature output by the convolutional layer, and each sample picture feature is generated by convolution processing of the convolutional layer according to each sample picture information.

[0267] ​In some embodiments, the second training module 22 is configured to perform feature extraction on the sample picture information of each of the sample items based on the convolutional layer to obtain sample picture features corresponding to each of the sample items, perform clustering processing on the sample picture features corresponding to each of the sample items respectively to obtain an initial clustering result, wherein the initial clustering result indicates that each of the sample items belongs to M initial categories, M is a positive integer greater than or equal to 1, and the pooling layer of the convolutional neural network model is configured to output a training similarity of each of the initial categories according to the initial clustering result, and generate the recognition model according to the training similarity of each of the initial categories.

[0268] In some embodiments, the second training module 22 is configured to randomly select at least one sample picture feature from the sample picture features corresponding to each of the sample items as an initial clustering center feature, and determine the initial clustering result according to distances between the initial clustering center feature and the sample picture features corresponding to the remaining sample items.

[0269] In some embodiments, each of the initial categories has at least one initial center feature, and the initial center feature indicates a common feature of the sample items in the initial category.

[0270] In some embodiments, the second training module 22 is configured to, for each of the initial categories, calculate a training cosine similarity between an initial center feature of the initial category and a preset center feature based on the pooling layer, and determine the training cosine similarity as the training similarity corresponding to the initial category.

[0271] In some embodiments, the second training module 22 is configured to compare the training similarity with a calibration similarity to obtain a sample loss function, adjust the convolutional neural network model according to the sample loss function, and generate the recognition model.

[0272] According to another aspect of embodiments of the present application, embodiments of the present application also provide an electronic device and a readable storage medium.

[0273] Figure 12 To implement the ninth embodiment of the present application, as shown in Figure 12 The electronic device is intended to represent a variety of forms including, but not limited to, laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device can also represent a variety of mobile devices, such as personal digital assistants, cellular telephones, smart phones, wearable devices, and other similar computing devices. The components shown here, their connections, and their functions, as described above, are meant to be examples only, and are not intended to limit the implementations of the present application as described and / or claimed herein.

[0274] As shown in Figure 12 The electronic device includes one or more processors 101, memory 102, and interfaces for connecting the various components, including high-speed interfaces and low-speed interfaces. The various components are interconnected by different buses, and can be mounted on a common main board or otherwise mounted as needed. The processor can process instructions executed within the electronic device, including instructions stored in the memory or on the memory to display graphical information of a GUI on an external input / output device, such as a display device coupled to the interface. In other embodiments, multiple processors and / or buses can be used with multiple memories and multiple memory, if desired. Also, multiple electronic devices can be connected, each device providing part of the necessary operations (e.g., as a server array, a set of blade servers, or a multi-processor system). Figure 12 The processor 101 is taken as an example in the embodiment.

[0275] The memory 102 is a non-transitory computer readable storage medium provided by the present application. The memory stores instructions executable by at least one processor, so that the at least one processor executes the article identification method or model training method provided by the present application. The non-transitory computer readable storage medium of the present application stores computer instructions for causing a computer to execute the article identification method or model training method provided by the present application.

[0276] The memory 102 is a non-transitory computer readable storage medium, which can be used to store non-transitory software programs, non-transitory computer executable programs and modules. The processor 101 executes various functional applications and data processing of the server by running the non-transitory software programs, instructions and modules stored in the memory 102, that is, implements the article identification method or model training method in the above method embodiments.

[0277] The memory 102 can include a program storage area and a data storage area, wherein the program storage area can store an operating system and application programs required by at least one function; the data storage area can store data created according to the use of the electronic device, etc. In addition, the memory 102 can include a high-speed random access memory, and can also include a non-transitory memory, such as at least one magnetic disk storage device, a flash memory device, or other non-transitory solid-state memory device. In some embodiments, the memory 102 can optionally include a memory disposed remotely with respect to the processor 101, which can be connected to the electronic device through a network. Examples of the above network include but are not limited to the Internet, an intranet, a local area network, a mobile communication network, and a combination thereof.

[0278] The electronic device can further include an input device 103 and an output device 104. The processor 101, the memory 102, the input device 103, and the output device 104 can be connected through a bus or other means, Figure 12 The connection through the bus is taken as an example.

[0279] The input device 103 can receive inputted digital or character information, and generate key signal input related to user settings and function control of the electronic device, such as a touch screen, a keypad, a mouse, a trackpad, a touchpad, a pointing stick, one or more mouse buttons, a trackball, a joystick, etc. The output device 104 can include a display device, an auxiliary lighting device (e.g., an LED), a haptic feedback device (e.g., a vibration motor), etc. The display device can include, but is not limited to, a liquid crystal display (LCD), a light emitting diode (LED) display, and a plasma display. In some embodiments, the display device can be a touch screen.

[0280] Various embodiments of the systems and techniques described here can be realized in digital electronic circuitry, integrated circuitry, specially designed ASICs (application specific integrated circuits), computer hardware, firmware, software, and / or combinations thereof. These various embodiments can include implementation in one or more computer programs that are executable and / or interpretable on a programmable system including at least one programmable processor, which can be special or general purpose, coupled to receive data and instructions from, and to transmit data and instructions to, a storage system, at least one input device, and at least one output device.

[0281] These computer programs (also known as programs, software, software applications or code) include machine instructions for a programmable processor, and can be implemented in a high-level procedural and / or object-oriented programming language, and / or in assembly / machine language. As used herein, the terms "machine-readable medium" and "computer-readable medium" refer to any computer program product, apparatus and / or device (e.g., magnetic discs, optical disks, memory, Programmable Logic Devices (PLDs)) used to provide machine instructions and / or data to a programmable processor, including a machine-readable medium that receives machine instructions as a machine-readable signal. The term "machine-readable signal" refers to any signal used to provide machine instructions and / or data to a programmable processor.

[0282] To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user and a keyboard and a pointing device (e.g., a mouse or a trackball) by which the user can provide input to the computer. Other kinds of devices can be used to provide for interaction with a user as well; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form, including acoustic, speech, or tactile input.

[0283] The systems and techniques described here can be implemented in a computing system that includes a back end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front end component (e.g., a user computer having a graphical user interface or a Web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back end, middleware, or front end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include a local area network (LAN), a wide area network (WAN), and the Internet.

[0284] The computing system can include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other.

[0285] Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the features of the disclosure disclosed herein. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.

[0286] It is to be understood that the disclosure is not limited to the precise construction described above and shown in the attached drawings, and that various modifications and changes can be made to the embodiments thereof without departing from the scope thereof. The scope of the disclosure is to be limited only by the claims appended hereto.

Claims

1. An article identification method, the method comprising: obtaining respective target picture information of respective articles to be identified; inputting each of the target picture information into an identification model to generate an identification result corresponding to each of the articles to be identified, wherein the identification model comprises a convolution layer and a clustering layer, the clustering layer is configured to perform clustering processing on target picture features output by the convolution layer, each of the target picture information corresponds to a target picture feature generated by the convolution layer based on the convolution processing of each of the target picture information, and the identification result represents whether each of the articles to be identified meets a predefined article standard, wherein a clustering result generated after the clustering processing represents a target category to which each of the articles to be identified belongs, and the identification result is determined according to a similarity between a target center feature of each of the target categories and a preset center feature; the method further comprises: obtaining respective target text information of respective articles to be identified; and obtaining target picture information of each of the articles to be identified, comprising: if it is determined that at least part of the articles to be identified are suspected to not meet an article requirement according to the target text information of each of the articles to be identified, obtaining the target picture information of the articles suspected to not meet the article requirement; after obtaining the target text information of each of the articles to be identified, the method further comprises: inputting each of the target text information into a text classification model to generate a classification value, wherein the text classification model comprises a linear layer arranged after a masked language modeling layer, the classification value is obtained by linear processing of information output by the masked language modeling layer of the text classification model by the linear layer of the text classification model, and the input of the masked language modeling layer of the text classification model is the target text information; if the classification value is greater than a pre-set classification threshold, it is determined that the article to be identified is an article suspected to not meet the article requirement.

2. The method of claim 1, wherein, inputting each of the target picture information into an identification model to generate an identification result corresponding to each of the articles to be identified, comprising: extracting a target picture feature corresponding to each of the articles to be identified based on the convolution layer; performing clustering processing on the target picture feature corresponding to each of the articles to be identified based on the clustering layer to obtain a target clustering result, wherein the target clustering result represents that each of the articles to be identified belongs to N target categories, and N is a positive integer greater than or equal to 1; outputting a target similarity of each of the target categories based on the target clustering result by a pooling layer of the identification model, and determining the identification result based on the target similarity of each of the target categories by the pooling layer.

3. The method of claim 2, wherein, performing clustering processing on the target picture feature corresponding to each of the articles to be identified based on the clustering layer to obtain a target clustering result, comprising: arbitrarily selecting at least one target picture feature from the target picture feature corresponding to each of the articles to be identified as a target clustering center feature; According to distances between the target picture features corresponding to the rest of the to-be-identified items and the target cluster center features, the target clustering result is determined.

4. The method of claim 2, wherein, Each of the target categories has at least one target center feature, and the target center feature represents common features of each to-be-identified item in the target category.

5. The method of claim 4, wherein, The target similarity of each of the target categories is output by a pooling layer of the identification model based on the target clustering result, including: For each of the target categories, a target cosine similarity between the target center feature of the target category and a preset center feature is calculated based on the pooling layer, and the target cosine similarity is determined as the target similarity corresponding to the target category.

6. The method of claim 1, further comprising: obtaining respective training text information corresponding to each of the to-be-trained items, wherein part of the to-be-trained items belong to items that do not meet the item demand, and the rest of the to-be-trained items belong to items that meet the item demand; inputting each of the training text information into a lightweight language representation model to train and generate the text classification model, wherein the lightweight language representation model includes a linear layer arranged after a masked language modeling layer, and the linear layer of the lightweight language representation model is configured to perform linear processing on information output by the masked language modeling layer of the lightweight language representation model, and the input of the masked language modeling layer of the lightweight language representation model is each of the training text information.

7. The method of claim 6, wherein inputting each of the training text information into a lightweight language representation model to train and generate the text classification model comprises: comparing a training value obtained by linear processing of the linear layer of the lightweight language representation model with a preset calibration value to obtain a training loss function; adjusting the lightweight language representation model according to the training loss function to generate the text classification model.

8. The method of claim 1, after obtaining respective target text information corresponding to each of the to-be-identified items, the method further comprises: inputting each of the target text information into a text filtering model, and the text filtering model is configured to match the target text information with a black and white list to obtain a matching result; if the matching result is that the target text information hits a white list in the black and white list, it is determined that the to-be-identified item is a suspected item that does not meet the item demand.

9. A model training method applied to an item identification method, the method comprising: obtaining respective sample picture information corresponding to each of the sample items, wherein part of the sample items belong to items that do not meet a preset item demand, and the rest of the sample items belong to items that do not meet the item demand. inputting each of the sample picture information into a convolutional neural network model to obtain an identification model by training, wherein the convolutional neural network model comprises a convolutional layer and a clustering layer, the clustering layer is configured to perform clustering processing on each sample picture feature output by the convolutional layer, each sample picture feature corresponding to each of the sample picture information is generated by the convolutional layer based on the convolutional processing of each of the sample picture information, and a clustering result generated after the clustering processing is used to represent a category to which each of the sample items belongs, and the identification model obtained by the training is used to implement the method according to any one of claims 1-8.

10. The method of claim 9, wherein, inputting each of the sample picture information into a convolutional neural network model to obtain an identification model by training, comprising: extracting a sample picture feature corresponding to each of the sample items based on the convolutional layer; performing clustering processing on each sample picture feature corresponding to each of the sample items based on the clustering layer to obtain an initial clustering result, wherein the initial clustering result represents that each of the sample items belongs to M initial categories, and M is a positive integer greater than or equal to 1; outputting a training similarity of each of the initial categories based on a pooling layer of the convolutional neural network model according to the initial clustering result, and generating the identification model according to the training similarity of each of the initial categories.

11. The method of claim 10, wherein, performing clustering processing on each sample picture feature corresponding to each of the sample items based on the clustering layer to obtain an initial clustering result, comprising: arbitrarily selecting at least one sample picture feature from each sample picture feature corresponding to each of the sample items as an initial clustering center feature; determining the initial clustering result according to a distance between the initial clustering center feature and a sample picture feature corresponding to each of the remaining sample items.

12. The method of claim 10, wherein, Each of the initial categories has at least one initial center feature, and the initial center feature represents a common feature of each sample item in the initial category.

13. The method of claim 12, wherein, outputting a training similarity of each of the initial categories based on a pooling layer of the convolutional neural network model according to the initial clustering result, comprising: for each of the initial categories, calculating a training cosine similarity between an initial center feature of the initial category and a preset center feature based on the pooling layer, and determining the training cosine similarity as the training similarity corresponding to the initial category.

14. The method of any one of claims 10 to 13, wherein, generating the identification model according to the training similarity of each of the initial categories, comprising: comparing the training similarity with a calibration similarity to obtain a sample loss function; adjusting the convolutional neural network model according to the sample loss function to generate the identification model.

15. An article identification device, the device comprising: a first acquisition module configured to acquire target picture information corresponding to each of the to-be-identified articles; The first generation module is configured to input each of the target picture information into an identification model to generate an identification result corresponding to each of the to-be-identified articles, wherein the identification model comprises a convolution layer and a clustering layer, the clustering layer is configured to perform clustering processing on each target picture feature output by the convolution layer, each target picture feature corresponding to each of the target picture information is generated by performing convolution processing on each of the target picture information by the convolution layer, and the identification result represents whether each of the to-be-identified articles meets a predefined article standard, wherein a clustering result generated after the clustering processing is used to represent a target category to which each of the to-be-identified articles belongs, and the identification result is determined according to a similarity between a target center feature of each of the target categories and a preset center feature; The second acquisition module is configured to acquire target text information corresponding to each of the to-be-identified articles; The first acquisition module is configured to acquire the target picture information of each to-be-identified article, including: if it is determined that at least part of the to-be-identified articles are suspected to not meet the article demand according to the target text information of each of the to-be-identified articles, acquiring the target picture information of the articles suspected to not meet the article demand; After acquiring the target text information of each of the to-be-identified articles, the device further comprises: The second generation module is configured to input each of the target text information into a text classification model to generate a classification value, wherein the text classification model comprises a linear layer arranged after a masked language modeling layer, the classification value is obtained by performing linear processing on information output by the masked language modeling layer of the text classification model by the linear layer of the text classification model, and the input of the masked language modeling layer of the text classification model is the target text information; The determination module is configured to determine that a to-be-identified article is an article suspected to not meet the article demand if the classification value is greater than a pre-set classification threshold.

16. A model training device applied to an article identification method, the device comprising: The fourth acquisition module is configured to acquire sample picture information corresponding to each of sample articles, wherein part of the sample articles belong to articles that do not meet a pre-set article demand, and the remaining sample articles belong to articles that meet the article demand; The second training module is configured to input each of the sample picture information into a convolutional neural network model to train an identification model, wherein the convolutional neural network model comprises a convolution layer and a clustering layer, the clustering layer is configured to perform clustering processing on each sample picture feature output by the convolution layer, each sample picture feature corresponding to each of the sample picture information is generated by performing convolution processing on each of the sample picture information by the convolution layer, wherein a clustering result generated after the clustering processing is used to represent a category to which each of the sample articles belongs, and the trained identification model is used to implement the device of claim 15.

17. An electronic device comprising: a memory and a processor; a memory; a memory for storing the processor-executable instructions; The processor is configured to perform the method of any one of claims 1 to 8; or The processor is configured to perform the method of any one of claims 1 to 8; or The processor is configured to perform the method of any one of claims 9 to 14.

18. A computer readable storage medium, having stored therein computer-executable instructions that, when executed by a processor, perform a method as claimed in any one of claims 1 to 8; or, The computer-executable instructions, when executed by the processor, perform a method as claimed in any one of claims 9 to 14.

Citation Information

Patent Citations

  • Method and device for generating detection model, method and device for detecting target

    CN104217216A

  • Method and apparatus for recognizing image content

    US20170372169A1