Data processing method, device, electronic device and storage medium
By obtaining and analyzing the feature frequency of user portrait labels and re-dividing categories, the problem of large differences in the number of people in each category in the GMM clustering model is solved, and the accuracy of user classification and the precision of delivery are improved.
Patent Information
- Application Number
- CN202111018867.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-09-01
- Publication Date
- 2025-09-19
- Estimated Expiration
- 2041-09-01
AI Technical Summary
In the existing technology, the GMM clustering model has limitations in fitting user portrait features, resulting in a huge difference in the number of people in each category in the clustering results, affecting the classification accuracy.
By obtaining the data to be classified, dividing it into a preset number of categories, determining the frequency of the portrait label features of each category, determining the target portrait label features based on the frequency, combining the portrait label features of the object to be classified and the target portrait label features of the category, re-dividing the categories, and iteratively optimizing the total target value to improve the classification accuracy.
It improves the accuracy of user classification, enables more precise campaign delivery and crowd targeting, and improves the conversion rate of delivery data.
Smart Images

Figure CN113657552B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of computer technology, and in particular to a data processing method, device, electronic device, and storage medium. Background Art
[0002] With the increasing popularity of e-commerce platforms and the continuous development of Internet technology, user portraits play an increasingly important role.
[0003] In related technologies, clustering analysis of portrait features using the GMM (Gaussian mixture model) clustering model requires that the user's portrait features can be fitted into a Gaussian distribution. Therefore, the use of the GMM clustering model has limitations. Using traditional clustering algorithms may result in a phenomenon in which the number of people in individual categories is extremely large or extremely small, resulting in the clustering results showing a huge difference in the number of people in each category.
[0004] It should be noted that the information disclosed in the above background technology section is only used to enhance the understanding of the background of the present disclosure, and therefore may include information that does not constitute prior art known to ordinary technicians in the field. Summary of the Invention
[0005] The purpose of the present disclosure is to provide a data processing method, device, electronic device and storage medium, which can enable users of each category to have typical portrait label features, and to a certain extent overcome the problem of extremely different data of objects to be classified in each category in the clustering results.
[0006] Other features and advantages of the present disclosure will become apparent from the following detailed description, or may be learned in part by practice of the present disclosure.
[0007] An embodiment of the present disclosure provides a data processing method, including: obtaining data to be classified, the data to be classified including multiple objects to be classified and portrait label features of each object to be classified under each portrait label; dividing the multiple objects to be classified into a preset number of categories; determining the frequency of each portrait label feature under each portrait label in each category; determining the target portrait label feature under each portrait label in each category based on the frequency of each portrait label feature under each portrait label in each category; determining the target category of each object to be classified based on the portrait label features of each object to be classified under each portrait label and the target portrait label features under each portrait label in each category.
[0008] In some exemplary embodiments of the present disclosure, the above method also includes: determining the target value of each category based on the frequency corresponding to the target portrait label features under each portrait label in each category; determining a first total target value based on the target value of each category; re-dividing the multiple objects to be classified into a preset number of categories based on the target category of each object to be classified; re-determining the target portrait label features under each portrait label in each category, the target category of each object to be classified, and the target value of each category; determining a second total target value based on the re-determined target value of each category; if the difference between the first total target value and the second total target value is less than a preset threshold, the re-determined target category is used as the classification result of each object to be classified.
[0009] In some exemplary embodiments of the present disclosure, target portrait label features under each portrait label in each category are determined based on the frequency of each portrait label feature under each portrait label in each category, including: determining the portrait label feature with the highest frequency under each portrait label as the target portrait label feature under each portrait label in the category.
[0010] In some exemplary embodiments of the present disclosure, the portrait label feature with the highest frequency under each portrait label is determined as the target portrait label feature under each portrait label in the category, including: if there are at least two portrait label features with the highest frequency under the portrait label, then the frequencies of the at least two portrait label features in all categories are determined respectively, and the portrait label feature with the lowest frequency in all categories is determined as the target portrait label feature under the portrait label.
[0011] In some exemplary embodiments of the present disclosure, the target category of each object to be classified is determined based on the portrait label features of each object to be classified under each portrait label and the target portrait label features under each portrait label in each category, including: determining the iteration value of each object to be classified for each category based on the portrait label features of each object to be classified under each portrait label and the target portrait label features under each portrait label in each category; and determining the category with the largest iteration value as the target category of the object to be classified.
[0012] In some exemplary embodiments of the present disclosure, the iteration value of each object to be classified for each category is determined based on the portrait label features of each object to be classified under each portrait label and the target portrait label features in each category under each portrait label, including: judging whether the portrait label features of the object to be classified under the portrait label are the same as the target portrait label features of the portrait label; and determining the iteration value of the object to be classified for the category based on the number of identical features and the number of objects to be classified in the category.
[0013] In some exemplary embodiments of the present disclosure, the data to be classified includes the identification of each object to be classified; dividing the multiple objects to be classified into a preset number of categories includes: determining a hash value of the identification of each object to be classified; and dividing the multiple objects to be classified into a preset number of categories according to the hash value of the identification of each object to be classified.
[0014] An embodiment of the present disclosure provides a data processing device, comprising: a data acquisition module, for acquiring data to be classified, wherein the data to be classified includes multiple objects to be classified and portrait label features of each object to be classified under each portrait label; a category division module, for dividing the multiple objects to be classified into a preset number of categories; a frequency determination module, for determining the frequency of each portrait label feature under each portrait label in each category; a feature determination module, for determining the target portrait label feature under each portrait label in each category according to the frequency of each portrait label feature under each portrait label in each category; and a category determination module, for determining the target category of each object to be classified according to the portrait label features of each object to be classified under each portrait label and the target portrait label features under each portrait label in each category.
[0015] An embodiment of the present disclosure provides an electronic device, comprising: at least one processor; and a storage device for storing at least one program, wherein when the at least one program is executed by the at least one processor, the at least one processor implements any one of the above-mentioned data processing methods.
[0016] An embodiment of the present disclosure provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program implements any of the above-mentioned data processing methods when executed by a processor.
[0017] The data processing method provided by the embodiment of the present disclosure can determine the target portrait label features under each portrait label in each category based on the frequency of each portrait label feature under each portrait label in each category, so that users in each category have typical portrait label features; based on the portrait label features of each object to be classified under each portrait label and the target portrait label features under each portrait label in each category, the target category of each object to be classified can be determined, which can improve the accuracy of classification and overcome the problem of extremely large differences in data of objects to be classified in each category in the clustering results to a certain extent. In addition, the target categories of each object to be classified determined by the embodiment of the present disclosure can be used to more accurately carry out activities such as event delivery and crowd targeting, thereby improving the conversion rate of delivery data.
[0018] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] The accompanying drawings are incorporated into and constitute a part of the specification, illustrate embodiments consistent with the present disclosure, and together with the specification, are used to explain the principles of the present disclosure. Obviously, the drawings described below are only some embodiments of the present disclosure, and those skilled in the art can derive other drawings based on these drawings without inventive effort.
[0020] Figure 1 A schematic diagram showing an exemplary system architecture to which the data processing method according to an embodiment of the present disclosure can be applied.
[0021] Figure 2 is a flowchart showing a data processing method according to an exemplary embodiment.
[0022] Figure 3 is a flowchart showing another data processing method according to an exemplary embodiment.
[0023] Figure 4 is a flowchart of yet another data processing method according to an example.
[0024] Figure 5 is a block diagram showing a data processing device according to an exemplary embodiment.
[0025] Figure 6 is a schematic structural diagram of an electronic device according to an exemplary embodiment. DETAILED DESCRIPTION
[0026] Example embodiments will now be described more fully with reference to the accompanying drawings. However, example embodiments can be embodied in many forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that this disclosure will be thorough and complete and will fully convey the concepts of the example embodiments to those skilled in the art. The described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.
[0027] In addition, the accompanying drawings are merely schematic illustrations of the present disclosure and are not necessarily drawn to scale. Identical reference numerals in the figures denote identical or similar parts, and thus repetitive descriptions thereof will be omitted. Some of the block diagrams shown in the accompanying drawings are functional entities that do not necessarily correspond to physically or logically separate entities. These functional entities may be implemented in software, in one or more hardware modules or integrated circuits, or in different networks and / or processor devices and / or microcontroller devices.
[0028] Figure 1A schematic diagram showing an exemplary system architecture to which the data processing method according to an embodiment of the present disclosure can be applied.
[0029] like Figure 1 As shown, the system architecture may include a server 101, a network 102, and a terminal device 103. The network 102 is used to provide a medium for a communication link between the terminal device 103 and the server 101. The network 102 may include various connection types, such as wired or wireless communication links or fiber optic cables.
[0030] The server 101 may be a server that provides various services, such as a background management server that provides support for devices operated by users using the terminal device 103. The background management server may analyze and process received request data and feed back the processing results to the terminal device 103.
[0031] The terminal device 103 can be a mobile terminal such as a mobile phone, a game console, a tablet computer, an e-book reader, smart glasses, smart home devices, AR (Augmented Reality) devices, VR (Virtual Reality) devices, etc., or the terminal device 103 can also be a personal computer, such as a laptop computer and a desktop computer.
[0032] For example, the server 101 can obtain the data to be classified sent by the terminal device 103, and the data to be classified can include multiple objects to be classified and the portrait label features of each object to be classified under each portrait label; the server 101 can, for example, divide the multiple objects to be classified into a preset number of categories; the server 101 can, for example, determine the frequency of each portrait label feature under each portrait label in each category; the server 101 can, for example, determine the target portrait label features under each portrait label in each category based on the frequency of each portrait label feature under each portrait label in each category; the server 101 can, for example, determine the target category of each object to be classified based on the portrait label features of each object to be classified under each portrait label and the target portrait label features under each portrait label in each category.
[0033] For example, the server 101 can push products or advertisements belonging to the target category to the object to be classified based on the target category of the object to be classified; the server 103 can send the products or advertisements to the terminal device 103, and the user can view and purchase them through the terminal device 103.
[0034] It should be understood that Figure 1The number of terminal devices, networks and servers is only for illustration. Server 101 can be a physical server, a server cluster consisting of multiple servers, or a cloud server. It can have any number of terminal devices, networks and servers according to actual needs.
[0035] Hereinafter, each step of the data processing method in the exemplary embodiment of the present disclosure will be described in more detail with reference to the accompanying drawings and embodiments.
[0036] Figure 2 This is a flow chart of a data processing method according to an exemplary embodiment. The method provided by the embodiment of the present disclosure can be performed as follows: Figure 1 The process is executed in the server or terminal device shown, but the present disclosure is not limited thereto.
[0037] like Figure 2 As shown, the data processing method provided by the embodiment of the present disclosure may include the following steps.
[0038] In step S202, data to be classified is obtained.
[0039] The data to be classified includes multiple objects to be classified and portrait label features of each object to be classified under each portrait label.
[0040] In the embodiment of the present disclosure, the object to be classified may be a user, the portrait label may be an abstract classification and summary of the portrait label features of a certain type of specific group or object, the portrait label feature may be the label value of the portrait label, and a portrait label may include one or more portrait label features.
[0041] For example, the portrait label may be gender, and the portrait label feature may be male, female, or unknown; for another example, the portrait label may be age, and the portrait label feature may be 20-30 years old, 30-40 years old, etc.; for another example, the portrait label may be marital status, and the portrait label feature may be married or unmarried.
[0042] Among them, multiple objects to be classified can be a clustered population, and the number of people in the clustered population can be between 1,000 and 50,000,000, which can improve the availability of the model and data, but the present disclosure does not limit the number of people in the clustered population.
[0043] In the embodiment of the present disclosure, the data to be classified may include multiple users, and portrait label features of each user under multiple portrait labels.
[0044] In the disclosed embodiment, each user can be regarded as an article, and each portrait label feature of the user (such as male) can be regarded as a Word.
[0045] For example, there are multiple users named A, B, C, etc. User A's portrait label features under the portrait labels of gender, age, and marital status are male, 20-30 years old, and single; User B's portrait label features under the portrait labels of gender, age, and marital status are female, 30-40 years old, and married; User C's portrait label features under the portrait labels of gender, age, and marital status are male, 20-30 years old, and married...
[0046] It should be noted that the personal information data involved in the embodiments of the present disclosure have been voluntarily authorized by the user, and the acquisition, storage, processing and transmission of personal information are in compliance with the requirements of relevant laws and regulations.
[0047] In step S204, the plurality of objects to be classified are divided into a preset number of categories.
[0048] The preset number may be K, where K is an integer greater than or equal to 1.
[0049] It should be noted that setting the number of categories K to an integer not exceeding 10 can improve the usability of the model and data, but this disclosure does not impose any limitation on this.
[0050] The K categories into which multiple objects to be classified are divided can be expressed as: cluster1, cluster2, ..., clusterK.
[0051] In the embodiment of the present disclosure, multiple objects to be classified may be randomly divided into K categories, or may be divided into K categories according to preset rules, and the preset rules may be set as needed.
[0052] In an exemplary embodiment, the data to be classified includes identifications of respective objects to be classified.
[0053] The identifier of the object to be classified may be a user ID (identifier), or a unique identifier assigned to the user by the shopping platform. For example, user_log_acct may represent the user's identifier.
[0054] In an exemplary embodiment, a hash value of an identifier of each object to be classified may be determined; and a plurality of objects to be classified may be divided into a preset number of categories according to the hash value of the identifier of each object to be classified.
[0055] In the embodiment of the present disclosure, a hash value of each user's identifier may be determined, and users with the same remainder may be classified into one category by taking the remainder of the hash value of each user's identifier and the number of categories K.
[0056] The cluster population is divided into K categories according to the hash value of each user's identifier, which can initialize the iterative process of model training and ensure that the results of multiple initializations are reproducible when the data set is the same.
[0057] In step S206 , the frequency of each portrait tag feature under each portrait tag in each category is determined.
[0058] In the disclosed embodiment, the frequency of each portrait tag feature under each portrait tag in each category may be statistically obtained.
[0059] For example, in the first category, cluster 1, the frequency (or probability) of male, female, and unknown frequencies are counted under the gender portrait label; the frequency of 20-30 years old and 30-40 years old are counted under the age portrait label; the frequency of married and unmarried are counted under the marital status portrait label.
[0060] For example, in the first category, cluster 1, the frequency of male under the gender portrait label is 0.7, the frequency of female is 0.2, and the frequency of unknown is 0.1. The frequency of 20-30 years old under the age label is 0.3, and the frequency of 30-40 years old under the age label is 0.3, etc.
[0061] In step S208 , target portrait label features under each portrait label in each category are determined according to the frequencies of each portrait label features under each portrait label in each category.
[0062] In the disclosed embodiment, target portrait label features may be selected from the portrait label features according to the frequencies of the portrait label features of each category under each portrait label.
[0063] In an exemplary embodiment, the portrait tag feature with the highest frequency under each portrait tag is determined as the target portrait tag feature under each portrait tag in the category.
[0064] For example, in the first category cluster1, the frequency of male under the gender portrait label is 0.7, the frequency of female is 0.2, and the frequency of unknown is 0.1. Then, the frequency of the male portrait label feature under the gender portrait label is the largest, and the male portrait label feature can be determined as the target portrait label feature under the gender portrait label of the first category cluster1.
[0065] In an exemplary embodiment, if there are at least two portrait label features with the highest frequency under a portrait label, the frequencies of at least two portrait label features in all categories are determined respectively, and the portrait label feature with the lowest frequency in all categories is determined as the target portrait label feature under the portrait label.
[0066] For example, in the first category, cluster1, the frequencies of 20-30 years old and 30-40 years old under the age label are both 0.3, and are the largest in the age label. Then, the frequencies of 20-30 years old and 30-40 years old in all categories (i.e., all clustered populations) are determined respectively, and the smaller frequency of 20-30 years old and 30-40 years old in all categories (if there are three portrait label features with the largest frequency, the smallest one here) is used as the target portrait label feature under the age label.
[0067] For example, the frequency of 20-30 years old in all categories is 0.4, and the frequency of 30-40 years old is 0.2. That is, the frequency of 30-40 years old in all categories is relatively small, so 30-40 years old can be used as the target portrait label feature under the age label.
[0068] If there are at least two portrait label features with the highest frequency under a portrait label in a category, the frequencies of the at least two portrait label features in all categories are determined respectively, and the portrait label feature with the lowest frequency in all categories is determined as the target portrait label feature under the portrait label. This is because the portrait label feature with the lowest frequency in all categories can indirectly reflect that the target portrait label feature has a relatively higher frequency of occurrence in the category compared to other parallel and equal portrait label features.
[0069] If the frequencies of the at least two portrait label features in all categories are also equal, then one of the two portrait label features can be randomly selected as the target portrait label feature, or, after sorting the frequencies, the portrait label feature corresponding to the first frequency can be selected as the target portrait label feature.
[0070] In step S210, the target category of each object to be classified is determined based on the portrait label features of each object to be classified under each portrait label and the target portrait label features of each category under each portrait label.
[0071] In the disclosed embodiment, the target category of each object to be classified and the target portrait label features (also referred to as "typical portrait features") under each portrait label in each category can be output.
[0072] In the disclosed embodiment, the target category of each user can be determined from K categories based on the matching degree or similarity between the portrait label features of each user under each portrait label and the target portrait label features under each portrait label in each determined category.
[0073] For example, according to the above steps, it is determined that the target portrait label features of the first category cluster1 under the gender, age, and marital status portrait labels are male, 20-30 years old, and unmarried, the target portrait label features of the second category cluster2 under the gender, age, and marital status portrait labels are female, 30-40 years old, and married, and the target portrait label features of the third category cluster3 under the gender, age, and marital status portrait labels are male, 30-40 years old, and married...; the portrait label features of user A under the gender, age, and marital status portrait labels are male, 20-30 years old, and unmarried, so it can be determined that user A has the highest degree of match with the first category cluster1, and the target category of user A is the first category; the portrait label features of user B under the gender, age, and marital status portrait labels are female, 30-40 years old, and married, so it can be determined that user B has the highest degree of match with the second category cluster2, and the target category of user B is the second category.
[0074] In an exemplary embodiment, the iteration value of each object to be classified for each category can be determined based on the portrait label features of each object to be classified under each portrait label and the target portrait label features of each category under each portrait label.
[0075] In an exemplary embodiment, it may be determined whether the portrait label feature of the object to be classified under the portrait label is the same as the target portrait label feature of the portrait label.
[0076] For example, when the portrait tag features of a user under a portrait tag are the same as the target portrait tag features of the portrait tag in a category, the value of the portrait tag in the category is 1; when the portrait tag features of a user under a portrait tag are different from the target portrait tag features of the portrait tag in a category, the value of the portrait tag in the category is 0.
[0077] In an exemplary embodiment, the iteration value of the object to be classified for the category may be determined according to the same number of features and the number of objects to be classified in the category.
[0078] For example, the values of the portrait tags in a category can be added together to obtain the sum; the sum is divided by log(10+the number of people in the category) to obtain the iteration value of the user for the category.
[0079] By adding and dividing by log(10 + the number of people in the category), the category with fewer people can have more people, and to a certain extent prevent the phenomenon that the number of people in the largest category and the smallest category in the clustering results is too different.
[0080] It should be noted that, in the embodiments of the present disclosure, other functions or forms may be used to calculate the iteration value according to the specific data distribution, and the present disclosure does not impose any limitation on this.
[0081] In an exemplary embodiment, the category with the largest iteration value may be determined as the target category of the object to be classified.
[0082] In the embodiment of the present disclosure, after determining the target category of the object to be classified, the same product data or advertising data can be pushed to the objects to be classified in the same target category, which can effectively help operators to carry out more accurate activity delivery, crowd targeting and other activities.
[0083] The data processing method provided by the embodiment of the present disclosure can determine the target portrait label features under each portrait label in each category based on the frequency of each portrait label feature under each portrait label in each category, so that users in each category have typical portrait label features; based on the portrait label features of each object to be classified under each portrait label and the target portrait label features under each portrait label in each category, the target category of each object to be classified can be determined, which can improve the accuracy of classification and overcome the problem of extremely large differences in data of objects to be classified in each category in the clustering results to a certain extent. In addition, the target categories of each object to be classified determined by the embodiment of the present disclosure can be used to more accurately carry out activities such as event delivery and crowd targeting, thereby improving the conversion rate of delivery data.
[0084] Figure 3 is a flowchart showing another data processing method according to an exemplary embodiment.
[0085] In the embodiment of the present disclosure, Figure 3 The data processing method shown may include the following steps.
[0086] In step S302, the target value of each category is determined according to the frequency corresponding to the target portrait label feature under each portrait label in each category.
[0087] In the disclosed embodiment, after determining the target portrait label features under each portrait label, the target value of a category can be determined based on the frequency corresponding to the target portrait label features under each portrait label in a category.
[0088] For example, the frequencies corresponding to the target portrait label features of each portrait label in a category can be added together to obtain the sum of the frequencies corresponding to the target portrait label features; the frequencies corresponding to each target portrait label feature can be divided by the sum of the frequencies corresponding to the target portrait features to obtain the weights of each target portrait label feature; the frequencies corresponding to the target portrait label features can be multiplied by the weights to obtain the weighted values of each target portrait label feature; the weighted values of each target portrait label feature can be added together to obtain the target value of the category.
[0089] The calculation process of the target value of a category can be referred to Table 1.
[0090] Table 1
[0091]
[0092] Referring to Table 1, for example, in the first category cluster1, the frequency corresponding to the target portrait label feature in the gender portrait label is 0.7, the frequency corresponding to the target portrait label feature in the age portrait label is 0.1, and the frequency corresponding to the target portrait label feature in the marital status portrait label is 0.6. By adding the frequencies corresponding to the above three target portrait label features, the sum of the frequencies corresponding to the target portrait label features is 1.4; the frequencies corresponding to the above three target portrait label features are divided by the sum of the frequencies corresponding to the target portrait label features, and the weights of the gender, age, and marital status portrait labels are obtained as 0.5, 0.07, and 0.43 respectively; the frequencies corresponding to the above three target portrait label features are multiplied by the weights, and the weighted values of the gender, age, and marital status portrait labels are obtained as 0.35, 0.007, and 0.258 respectively; by adding the above three weighted values, the target value of the first category cluster1 is 0.615.
[0093] The calculation of target values for the second to Kth categories can refer to the calculation process of the target value for the first category, and this disclosure will not go into details here.
[0094] It should be noted that the present disclosure uses the three portrait tags of gender, age, and marital status as examples for illustration in the embodiment, but the present disclosure is not limited to this. The number and specific content of the portrait tags can be set according to actual conditions.
[0095] In step S304, a first total target value is determined based on the target values of each category.
[0096] For example, the target values of each category can be added together to obtain a first total target value.
[0097] For example, when K=3, the target value of the first cluster 1 is 0.615, the target value of the second cluster 2 is 0.6, and the target value of the third cluster 3 is 0.7. The first total target value may be 0.615+0.6+0.7=1.915.
[0098] In step S306 , the plurality of objects to be classified are reclassified into a preset number of categories according to the target category of each object to be classified.
[0099] In the embodiment of the present disclosure, after the target category of each object to be classified is determined, the multiple objects to be classified can be re-divided into K categories according to the target category of each object to be classified.
[0100] For example, after determining that the target category of person A is the first category and the target category of person B is the second category, person A can be classified into the first category and person B can be classified into the second category.
[0101] In step S308, the target portrait label features under each portrait label in each category, the target category of each object to be classified, and the target value of each category are re-determined.
[0102] In the embodiment of the present disclosure, after the users are reclassified, the target portrait label features under each portrait label in each category can be re-determined based on the users in each reclassified category.
[0103] Among them, the re-determination of the target portrait label features of each category under each portrait label can refer to the description of steps S206-S208, and the present disclosure will not repeat them here.
[0104] In the embodiment of the present disclosure, the target category of each object to be classified and the target value of each category can be re-determined.
[0105] Among them, the re-determination of the target category of each object to be classified can refer to the description of step S210, and the re-determination of the target value of each category can refer to the description of step S302, which will not be repeated in this disclosure.
[0106] In step S310, a second overall target value is determined based on the re-determined target values of each category.
[0107] For example, the re-determined target values of each category may be added together to obtain a second total target value.
[0108] In step S312, if the difference between the first total target value and the second total target value is less than a preset threshold, the re-determined target category is used as the classification result of each object to be classified.
[0109] In the embodiment of the present disclosure, the absolute value of the difference between the first total target value and the second total target value can be calculated. If the difference between the first total target value and the second total target value is less than a preset threshold, that is, the total target value decreases or increases by less than the preset threshold in this iteration, the iteration can be stopped and the re-determined target category can be used as the classification result of each object to be classified.
[0110] If the difference between the first total target value and the second total target value is greater than or equal to the preset threshold, the iteration can continue according to the above steps to obtain the third total target value, and determine whether the difference between the second total target value and the third total target value is less than the preset threshold, until the difference is less than the preset threshold or the maximum number of iterations is reached.
[0111] Among them, the preset threshold and the maximum number of iterations can be set according to specific data and application scenarios, and this disclosure does not impose any restrictions on this.
[0112] The data processing method provided by the embodiment of the present disclosure can effectively control the number of iterations and improve computing efficiency by iteratively optimizing the total target value.
[0113] Figure 4 is a flowchart of yet another data processing method according to an example.
[0114] In the embodiment of the present disclosure, Figure 4 The data processing method shown may include the following steps.
[0115] In step S402, the clustered population is divided into K categories according to the hash values of the user identifiers.
[0116] For example, you can input parameters related to the cluster population, the portrait label features of each user in the cluster population, the number of cluster categories K, and the maximum number of iterations of model training, and divide the cluster population into K categories according to the hash value of the user ID of each user.
[0117] In step S404, the probability (or frequency) of each portrait label feature in each category is calculated.
[0118] For example, the probability (or frequency) of each portrait label feature (such as male) in each category can be calculated.
[0119] In step S406 , the probability (or frequency) of the largest portrait tag feature in each portrait tag in each category is determined.
[0120] For example, if the probability (frequency) of a certain category (cluster) in all gender profile labels is the largest, which is 0.7, then the probability value is 0.7.
[0121] In step S408, the optimization target value of the model is calculated.
[0122] For example, the target value of each category can be determined based on the probability of the largest portrait label feature in each portrait label in each category, and the target values of each category can be added together to obtain the optimized target value of the model (also called the total target value).
[0123] In step S410, an iteration value is determined based on the user's portrait label features and the target portrait features of each category, and the user's category is updated.
[0124] For example, the iteration value can be determined based on the degree of matching between the user's portrait label features and the target portrait features of each category, and the user's category can be updated based on the iteration value.
[0125] After updating the user's category, the optimization target value is calculated again. When the increase or decrease in the optimization target value is less than the preset threshold, or when the preset number of iterations is reached, the iteration is stopped and the user's category and the target portrait label features in each category are output.
[0126] It should be noted that the above figures are merely illustrative of the processes included in the methods according to exemplary embodiments of the present disclosure and are not intended to be limiting. It is readily understood that the processes illustrated in the above figures do not indicate or limit the temporal order of these processes. Furthermore, it is readily understood that these processes may be executed synchronously or asynchronously, for example, in multiple modules.
[0127] The following are embodiments of the apparatus disclosed herein, which can be used to implement the method embodiments disclosed herein. For details not disclosed in the apparatus embodiments disclosed herein, please refer to the method embodiments disclosed herein.
[0128] Figure 5 is a block diagram showing a data processing device according to an exemplary embodiment.
[0129] like Figure 5 As shown, the data processing device 500 may include: a data acquisition module 502 , a category classification module 504 , a frequency determination module 506 , a feature determination module 508 and a category determination module 510 .
[0130] Among them, the data acquisition module 502 is used to acquire data to be classified, and the data to be classified includes multiple objects to be classified and portrait label features of each object to be classified under each portrait label; the category division module 504 is used to divide the multiple objects to be classified into a preset number of categories; the frequency determination module 506 is used to determine the frequency of each portrait label feature under each portrait label in each category; the feature determination module 508 is used to determine the target portrait label features under each portrait label in each category based on the frequency of each portrait label feature under each portrait label in each category; the category determination module 510 is used to determine the target category of each object to be classified based on the portrait label features of each object to be classified under each portrait label and the target portrait label features under each portrait label in each category.
[0131] In an exemplary embodiment, the data processing device 500 may also include: a target value determination module for determining the target value of each category based on the frequency corresponding to the target portrait label features under each portrait label in each category; a first total target value determination module for determining a first total target value based on the target value of each category; a category redivision module for redividing the multiple objects to be classified into a preset number of categories based on the target category of each object to be classified; a target value redetermination module for redetermining the target portrait label features under each portrait label in each category, the target category of each object to be classified and the target value of each category; a second total target value determination module for determining a second total target value based on the redetermined target values of each category; a classification result determination module for using the redetermined target category as the classification result of each object to be classified if the difference between the first total target value and the second total target value is less than a preset threshold.
[0132] In an exemplary embodiment, the feature determination module 508 may include: a feature determination unit, configured to determine the portrait tag feature with the highest frequency under each portrait tag as the target portrait tag feature under each portrait tag in the category.
[0133] In an exemplary embodiment, the feature determination unit may include: a feature selection unit, which is used to determine the frequencies of the at least two portrait label features in all categories respectively if there are at least two portrait label features with the highest frequency under the portrait label, and determine the portrait label feature with the lowest frequency in all categories as the target portrait label feature under the portrait label.
[0134] In an exemplary embodiment, the category determination module 510 may include: an iteration value determination unit, used to determine the iteration value of each object to be classified for each category based on the portrait label features of each object to be classified under each portrait label and the target portrait label features of each category under each portrait label; a target category determination unit, used to determine the category with the largest iteration value as the target category of the object to be classified.
[0135] In an exemplary embodiment, the iteration value determination unit may include: a judgment unit, used to judge whether the portrait label feature of the object to be classified under the portrait label is the same as the target portrait label feature of the portrait label; a category iteration value determination unit, used to determine the iteration value of the object to be classified for the category based on the number of identical features and the number of objects to be classified in the category.
[0136] In an exemplary embodiment, the data to be classified includes the identification of each object to be classified; the category classification module 504 includes: a hash value determination unit, used to determine the hash value of the identification of each object to be classified; and a category classification unit, used to divide the multiple objects to be classified into a preset number of categories according to the hash value of the identification of each object to be classified.
[0137] It should be noted that the block diagrams shown in the above figures are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software, in one or more hardware modules or integrated circuits, or in different networks and / or processor devices and / or microcontroller devices.
[0138] Figure 6 is a schematic diagram showing the structure of an electronic device according to an exemplary embodiment. It should be noted that, Figure 6 The electronic device shown is only an example and should not limit the functions and scope of use of the embodiments of the present invention.
[0139] like Figure 6 As shown, electronic device 600 includes a central processing unit (CPU) 601, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 602 or a program loaded from a storage portion 608 into a random access memory (RAM) 603. Various programs and data required for the operation of system 600 are also stored in RAM 603. CPU 601, ROM 602, and RAM 603 are connected to each other via a bus 604. An input / output (I / O) interface 605 is also connected to bus 604.
[0140] The following components are connected to the I / O interface 605: an input section 606 including a keyboard, a mouse, and the like; an output section 607 including devices such as a cathode ray tube (CRT), a liquid crystal display (LCD), and a speaker; a storage section 608 including a hard disk; and a communication section 609 including a network interface card such as a LAN card or a modem. The communication section 609 performs communication processing via a network such as the Internet. A drive 610 is also connected to the I / O interface 605 as needed. A removable medium 611, such as a magnetic disk, an optical disk, a magneto-optical disk, or a semiconductor memory, is installed in the drive 610 as needed, so that computer programs read therefrom can be installed into the storage section 608 as needed.
[0141] In particular, according to an embodiment of the present invention, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present invention includes a computer program product comprising a computer program carried on a computer-readable medium, the computer program comprising program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network via the communication section 609 and / or installed from a removable medium 611. When the computer program is executed by the central processing unit (CPU) 601, the above-mentioned functions defined in the system of the present invention are performed.
[0142] It should be noted that the computer-readable medium described in the present invention can be a computer-readable signal medium or a computer-readable storage medium, or any combination thereof. A computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of computer-readable storage media can include, but are not limited to, an electrical connection having one or more conductors, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof. In the present invention, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. In the present invention, a computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. This propagated data signal can take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. A computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium that can transmit, propagate, or transport a program for use by or in conjunction with an instruction execution system, apparatus, or device. Program code embodied on a computer-readable medium may be transmitted using any suitable medium, including but not limited to wireless, wireline, optical fiber cable, RF, or any suitable combination thereof.
[0143] The flowcharts and block diagrams in the accompanying drawings illustrate the possible implementation architecture, functions and operations of the systems, methods and computer program products according to various embodiments of the present invention. In this regard, each box in the flowchart or block diagram can represent a module, program segment, or a part of code, and the above-mentioned module, program segment, or a part of code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in an order different from that marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flowchart, and the combination of boxes in the block diagram or flowchart, can be implemented with a dedicated hardware-based system that performs the specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0144] The units involved in the embodiments of the present invention may be implemented in software or in hardware. The units described may also be provided in a processor. For example, they may be described as follows: a processor includes a sending unit, an acquisition unit, a determination unit, and a first processing unit. The names of these units do not, in some cases, limit the units themselves. For example, the sending unit may also be described as a "unit that sends a request for obtaining an image to the connected server."
[0145] As another aspect, the present invention also provides a computer-readable medium, which may be included in the device described in the above embodiment; or it may exist independently and not be assembled into the device. The above computer-readable medium carries one or more programs, and when the above one or more programs are executed by a device, the device includes: obtaining data to be classified, the data to be classified including multiple objects to be classified and portrait label features of each object to be classified under each portrait label; dividing multiple objects to be classified into a preset number of categories; determining the frequency of each portrait label feature under each portrait label in each category; determining the target portrait label feature under each portrait label in each category based on the frequency of each portrait label feature under each portrait label in each category; determining the target category of each object to be classified based on the portrait label features of each object to be classified under each portrait label and the target portrait label features under each portrait label in each category.
[0146] While the exemplary embodiments of the present invention have been specifically illustrated and described above, it should be understood that the present invention is not limited to the detailed structures, configurations, or implementations described herein; rather, the present invention is intended to encompass various modifications and equivalent arrangements within the spirit and scope of the appended claims.
Claims
1. A data processing method, characterized in that: Applied to e-commerce platforms, including: Acquire data to be classified, the data to be classified including a plurality of objects to be classified and portrait label features of each object to be classified under each portrait label, wherein the object to be classified is a user; Dividing the plurality of objects to be classified into a preset number of categories; Determine the frequency of each portrait tag feature for users in each category under each portrait tag; Determine the target portrait tag features under each portrait tag in each category based on the frequency of each portrait tag feature under each portrait tag for users in each category; Determine the target category of each object to be classified based on the image label features of each object to be classified under each image label and the target image label features of each category under each image label; Determining, based on the target category of the object to be classified, to push products or advertisements belonging to the target category to the object to be classified; the method further includes: Determine the target value for each category based on the frequency of the target portrait label features under each portrait label in each category; Determine a first overall target value based on the target values of each category; Reclassify the plurality of objects to be classified into a preset number of categories according to the target category of each object to be classified; Re-determine the target portrait label features under each portrait label in each category, the target category of each object to be classified, and the target value of each category; Determine the second overall target value based on the re-determined target values for each category; If the difference between the first total target value and the second total target value is smaller than a preset threshold, the re-determined target category is used as the classification result of each object to be classified.
2. The method according to claim 1, characterized in that According to the frequency of each portrait label feature under each portrait label in each category, the target portrait label feature under each portrait label in each category is determined, including: The portrait label feature with the highest frequency under each portrait label is determined as the target portrait label feature under each portrait label in the category.
3. The method according to claim 2, characterized in that The portrait label feature with the highest frequency under each portrait label is determined as the target portrait label feature under each portrait label in the category, including: If there are at least two portrait label features with the highest frequency under the portrait label, the frequencies of the at least two portrait label features in all categories are determined respectively, and the portrait label feature with the lowest frequency in all categories is determined as the target portrait label feature under the portrait label.
4. The method according to claim 1, wherein According to the image label features of each object to be classified under each image label and the target image label features of each category under each image label, the target category of each object to be classified is determined, including: Determine the iteration value of each object to be classified for each category based on the portrait label features of each object to be classified under each portrait label and the target portrait label features of each category under each portrait label; The category with the largest iteration value is determined as the target category of the object to be classified.
5. The method according to claim 4, characterized in that According to the portrait label features of each object to be classified under each portrait label and the target portrait label features of each category under each portrait label, the iteration value of each object to be classified for each category is determined, including: Determine whether the portrait label feature of the object to be classified under the portrait label is the same as the target portrait label feature of the portrait label; An iteration value of the object to be classified for the category is determined according to the same number of features and the number of objects to be classified in the category.
6. The method according to claim 1, characterized in that The data to be classified includes the identification of each object to be classified; Classifying the plurality of objects to be classified into a preset number of categories includes: Determine the hash value of the identifier of each object to be classified; The multiple objects to be classified are divided into a preset number of categories according to the hash value of the identifier of each object to be classified.
7. A data processing device, characterized in that: include: A data acquisition module is used to acquire data to be classified, wherein the data to be classified includes a plurality of objects to be classified and portrait label features of each object to be classified under each portrait label, wherein the objects to be classified are users; A category classification module, configured to classify the plurality of objects to be classified into a preset number of categories; A frequency determination module is used to determine the frequency of each portrait tag feature under each portrait tag in each category; A feature determination module is used to determine the target portrait label features under each portrait label in each category according to the frequency of each portrait label feature under each portrait label in each category; A category determination module is used to determine the target category of each object to be classified based on the portrait label features of each object to be classified under each portrait label and the target portrait label features under each portrait label in each category; determine to push products or advertisements belonging to the target category to the object to be classified based on the target category of the object to be classified; determine the target value of each category based on the frequency corresponding to the target portrait label features under each portrait label in each category; determine a first total target value based on the target value of each category; re-divide the multiple objects to be classified into a preset number of categories based on the target category of each object to be classified; re-determine the target portrait label features under each portrait label in each category, the target category of each object to be classified and the target value of each category; determine a second total target value based on the re-determined target value of each category; if the difference between the first total target value and the second total target value is less than a preset threshold, the re-determined target category is used as the classification result of each object to be classified.
8. An electronic device, characterized in that: include: at least one processor; A storage device for storing at least one program, which, when executed by the at least one processor, enables the at least one processor to implement the method according to any one of claims 1 to 6.
9. A computer-readable storage medium having computer-executable instructions stored thereon, characterized in that: When the executable instructions are executed by a processor, the method according to any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Group user portrait acquiring method and device
CN108108451A
Information recommendation method and device, server and storage medium
CN112328888A