CN113743436A - Feature selection method and device for generating user portrait - Google Patents

Feature selection method and device for generating user portrait Download PDF

Info

Publication number
CN113743436A
CN113743436A CN202010604427.8A CN202010604427A CN113743436A CN 113743436 A CN113743436 A CN 113743436A CN 202010604427 A CN202010604427 A CN 202010604427A CN 113743436 A CN113743436 A CN 113743436A
Authority
CN
China
Prior art keywords
feature set
feature
threshold
candidate feature
candidate
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202010604427.8A
Other languages
Chinese (zh)
Inventor
陈伯梁
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Jingdong Century Trading Co Ltd
Beijing Wodong Tianjun Information Technology Co Ltd
Original Assignee
Beijing Jingdong Century Trading Co Ltd
Beijing Wodong Tianjun Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Jingdong Century Trading Co Ltd, Beijing Wodong Tianjun Information Technology Co Ltd filed Critical Beijing Jingdong Century Trading Co Ltd
Priority to CN202010604427.8A priority Critical patent/CN113743436A/en
Publication of CN113743436A publication Critical patent/CN113743436A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/953Querying, e.g. by the use of web search engines
    • G06F16/9535Search customisation based on user profiles and personalisation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • G06N3/084Backpropagation, e.g. using gradient descent

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Databases & Information Systems (AREA)
  • Evolutionary Computation (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Evolutionary Biology (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Computational Linguistics (AREA)
  • Biomedical Technology (AREA)
  • Biophysics (AREA)
  • Health & Medical Sciences (AREA)
  • General Health & Medical Sciences (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • Mathematical Physics (AREA)
  • Software Systems (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention discloses a feature selection method and device for generating a user portrait, and relates to the technical field of computers. One specific implementation mode of the method comprises the steps of receiving feature data to be processed and generating a candidate feature set; calculating an evaluation value of each feature in a candidate feature set based on a preset evaluation model, and recording the feature of which the evaluation value is greater than a first threshold value into a first candidate feature set; calculating a correlation coefficient between every two features in the first candidate feature set based on a preset correlation coefficient model, and recording the features of which the correlation coefficients are larger than a second threshold value into a second candidate feature set; and substituting the first threshold, the second threshold, the first candidate feature set and the second candidate feature set into a pre-trained strategy network to obtain a feature set screened by the strategy for generating the user portrait. Therefore, the method and the device for selecting the user portrait features can solve the problems that the existing method for selecting the user portrait features cannot meet the current ultra-large-scale data background, and is low in precision and low in efficiency.

Description

Feature selection method and device for generating user portrait
Technical Field
The invention relates to the technical field of computers, in particular to a feature selection method and device for generating a user portrait.
Background
The user portrait is the key of E-business, search, news recommendation and other marketing activities, personalized recommendation, basic data service and the like. The existing training method for the image model is to train a data model through algorithms such as machine learning and deep learning. In the model training process, the data with huge sample quantity and high data characteristic dimension is always faced, irrelevant and redundant characteristic information in the data can be deleted through characteristic selection, so that the data dimension is reduced, the calculation time and space are improved, overfitting is avoided, and the model precision is improved. The existing image model feature selection methods can be divided into two methods, namely a filtering method (Filter) and an encapsulation method (Wrapper).
In the process of implementing the invention, the inventor finds that at least the following problems exist in the prior art:
the Filter method is sensitive to noise and is often applied to the preliminary screening of features in practical applications. The Wrapper method has the problem of high time complexity and is not suitable for ultra-large-scale data mining tasks.
Disclosure of Invention
In view of the above, embodiments of the present invention provide a method and an apparatus for selecting a feature for generating a user portrait, which can solve the problems that the existing user portrait feature selection method cannot meet the current ultra-large-scale data background, and is low in precision and low in efficiency.
In order to achieve the above object, according to an aspect of the embodiments of the present invention, there is provided a feature selection method for generating a user portrait, including receiving feature data to be processed, and generating a candidate feature set;
calculating an evaluation value of each feature in a candidate feature set based on a preset evaluation model, and recording the feature of which the evaluation value is greater than a first threshold value into a first candidate feature set; calculating a correlation coefficient between every two features in the first candidate feature set based on a preset correlation coefficient model, and recording the features of which the correlation coefficients are larger than a second threshold value into a second candidate feature set;
and substituting the first threshold, the second threshold, the first candidate feature set and the second candidate feature set into a pre-trained strategy network to obtain a feature set screened by the strategy for generating the user portrait.
Optionally, before substituting the first threshold, the second threshold, the first candidate feature set, and the second candidate feature set into the pre-trained policy network, the method includes:
acquiring historical characteristic data and labels thereof, and generating a candidate characteristic set through the historical characteristic data;
when each iteration training strategy network is carried out, calculating an evaluation value of each feature in a candidate feature set based on a preset evaluation model, and recording the feature of which the evaluation value is greater than a first threshold value into a first candidate feature set; calculating a correlation coefficient between every two features in the first candidate feature set based on a preset correlation coefficient model, and recording the features of which the correlation coefficients are larger than a second threshold value into a second candidate feature set; randomly selecting a feature from the first candidate feature set and deleting the feature in the first candidate feature set; substituting the feature, the first threshold, the second threshold, the first candidate feature set and the second candidate feature into a policy network to obtain a feature set of the iteration policy screening, and adjusting the first threshold and the second threshold according to the number of features in the feature set of the iteration policy screening; and inputting the feature set screened by the iteration strategy into a classifier, and calculating a loss function according to the classification result and the corresponding label.
Optionally, calculating a loss function according to the classification result and the corresponding label, including:
and (4) adopting cross entropy as a loss function of model training, and reversely transmitting the obtained cross entropy to the strategy network by using BP.
Optionally, adjusting the first threshold and the second threshold according to the number of features in the feature set of the round of iterative policy screening includes:
and judging whether the feature quantity in the feature set screened by the iteration strategy is greater than a preset quantity threshold value, if so, reducing the first threshold value and the second threshold value, and otherwise, increasing the first threshold value and the second threshold value.
Optionally, the method further comprises:
the policy network employs a random policy selection action.
Optionally, after obtaining the feature set of the iterative strategy screening in the round, the method includes:
obtaining an action instruction returned by the strategy network, if the action instruction is an action increasing instruction, continuing to randomly select a feature from the first candidate feature set and incorporate the feature into the alternative feature set, and deleting the feature in the first candidate feature set to execute the iterative training strategy network;
if the action instruction is a deletion action instruction, acquiring a feature pair with a correlation coefficient larger than a preset coefficient threshold value among features in the candidate feature set based on a preset correlation coefficient model, randomly selecting one feature in the feature pair to be merged into the first candidate feature set, and continuously executing the iterative training strategy network by deleting the feature in the candidate feature set.
Optionally, comprising:
generating an evaluation model through one or more of information gain rate, a kini index and variance, wherein an initialized first threshold value of the evaluation model is an average value of evaluation values obtained by each feature based on the evaluation model;
and generating a correlation coefficient model through one or more of pearson correlation coefficients, spearman coefficients, mutual information and distance correlation coefficients, wherein the initialized second threshold of the correlation coefficient model is an average value of the correlation coefficients obtained between every two features based on the correlation coefficient model.
In addition, the invention also provides a feature selection device for generating the user portrait, which comprises a receiving module, a selecting module and a selecting module, wherein the receiving module is used for receiving the feature data to be processed and generating a candidate feature set; the processing module is used for calculating an evaluation value of each feature in the candidate feature set based on a preset evaluation model, and recording the feature of which the evaluation value is greater than a first threshold value into a first candidate feature set; calculating a correlation coefficient between every two features in the first candidate feature set based on a preset correlation coefficient model, and recording the features of which the correlation coefficients are larger than a second threshold value into a second candidate feature set; and substituting the first threshold, the second threshold, the first candidate feature set and the second candidate feature set into a pre-trained strategy network to obtain a feature set screened by the strategy for generating the user portrait.
One embodiment of the above invention has the following advantages or benefits: in order to improve the efficiency and the precision of feature selection in user portrait model training, the method removes Q table to avoid the occupation of ultra-large memory calculation and disk storage; furthermore, the accuracy and reliability of the action are increased by utilizing various pearson correlation coefficients, spearman coefficients, mutual information, variance, distance correlation coefficients and the like. When the characteristics larger than a certain threshold value are screened, the average value is not used as the threshold value, but is initialized to be the average value, and then the values are added into the strategy network for correction.
The user profile is a virtual data aggregate of a series of data information (for example, shopping information, personal information, etc.) included in a user ID that has been successfully registered in an e-commerce site. The Q table is a table created that stores the actions and states involved in the execution and calculates the maximum future reward expectation for each action performed on each state. action refers to that an agent (agent) in the reinforcement learning algorithm takes some action as action in different states, and the action can receive different rewards fed back by the environment after being sent out.
Further effects of the above-mentioned non-conventional alternatives will be described below in connection with the embodiments.
Drawings
The drawings are included to provide a better understanding of the invention and are not to be construed as unduly limiting the invention. Wherein:
FIG. 1 is a schematic diagram of a main flow of a feature selection method for generating a user representation according to one embodiment of the invention;
FIG. 2 is an architecture diagram of a training strategy network according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of the major modules of a feature selection apparatus for generating a user representation according to an embodiment of the present invention;
FIG. 4 is an exemplary system architecture diagram in which embodiments of the present invention may be employed;
fig. 5 is a schematic block diagram of a computer system suitable for use in implementing a terminal device or server of an embodiment of the invention.
Detailed Description
Exemplary embodiments of the present invention are described below with reference to the accompanying drawings, in which various details of embodiments of the invention are included to assist understanding, and which are to be considered as merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the invention. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
FIG. 1 is a schematic diagram illustrating a main flow of a feature selection method for generating a user representation according to an embodiment of the present invention, as shown in FIG. 1, the feature selection method for generating a user representation includes:
step S101, receiving feature data to be processed and generating a candidate feature set.
In some embodiments, after receiving the feature data to be processed, the feature data to be processed may be preprocessed by a preset quality analysis model, and then a candidate feature set is generated. Preferably, the quality analysis model may include analysis of missing values, noise, outliers, data types, etc., data cleaning (including missing value, noise and outlier processing, etc.), data encoding, data deformation (including normalization, regularization, scaling, etc.) in combination with the analysis results.
Step S102, calculating an evaluation value of each feature in a candidate feature set based on a preset evaluation model, and recording the feature of which the evaluation value is greater than a first threshold value into a first candidate feature set; and then calculating a correlation coefficient between every two features in the first candidate feature set based on a preset correlation coefficient model, and recording the features of which the correlation coefficients are larger than a second threshold value into a second candidate feature set.
In some embodiments, the evaluation model is one or more of an information gain rate, a kini index and a variance, wherein the initialized first threshold corresponding to each evaluation model is an average value of evaluation values obtained by each feature based on the evaluation model, and the initialized first threshold may be subsequently added to a policy network for training and modification.
Where variance is a measure of the degree of dispersion when probability theory and statistical variance measure a random variable or a set of data.
The kini index represents the probability that a randomly selected sample in the sample set is misclassified.
Information gain is the difference between the probability theory and the information theory, in which the information gain is asymmetric, and is used to measure the difference between the two probability distributions P and Q. The information gain describes the difference when coding with Q, then coding with P. Usually P represents the distribution of samples or observations, and possibly also an accurately calculated theoretical distribution.
The correlation coefficient model is one or more of pearson correlation coefficient, spearman coefficient, mutual information and distance correlation coefficient, wherein the initialized second threshold corresponding to each correlation coefficient model is an average value of correlation coefficients obtained between every two features based on the correlation coefficient model, and the initialized second threshold can be added into the strategy network for training and correction.
Mutual Information (Mutual Information) is a useful Information measure in Information theory, and can be regarded as the amount of Information contained in a random variable about another random variable, or the negative of a random variable that is reduced by the knowledge of another random variable.
Pearson Correlation Coefficient (Pearson Correlation Coefficient) is used to measure whether two data sets are on a line, and is used to measure the linear relation between distance variables.
The Spearman correlation coefficient is a non-parametric indicator that measures the dependence of two variables. It evaluates the correlation of two statistical variables using a monotonic equation. If there are no duplicates in the data, and when the two variables are perfectly monotonically correlated, the Spearman correlation coefficient is either +1 or-1.
The distance correlation coefficient includes a cosine distance, a euclidean distance, and the like.
And step S103, substituting the first threshold, the second threshold, the first candidate feature set and the second candidate feature set into a pre-trained strategy network to obtain a feature set screened by a strategy for generating a user portrait.
In an embodiment, the first candidate feature set and the second candidate feature set may constitute a state (i.e., a feature combination). And substituting the State, the first threshold and the second threshold into a pre-trained strategy network to obtain a characteristic set screened by the strategy for generating the user portrait.
In some embodiments, before substituting the first threshold, the second threshold, the first candidate feature set, and the second candidate feature set into the pre-trained policy network, the method includes:
acquiring historical characteristic data and labels thereof, and generating a candidate characteristic set through the historical characteristic data;
when each iteration training strategy network is carried out, calculating an evaluation value of each feature in a candidate feature set based on a preset evaluation model, and recording the feature of which the evaluation value is greater than a first threshold value into a first candidate feature set; calculating a correlation coefficient between every two features in the first candidate feature set based on a preset correlation coefficient model, and recording the features of which the correlation coefficients are larger than a second threshold value into a second candidate feature set; randomly selecting a feature from the first candidate feature set and deleting the feature in the first candidate feature set; substituting the feature, the first threshold, the second threshold, the first candidate feature set and the second candidate feature into a policy network to obtain a feature set of the iteration policy screening, and adjusting the first threshold and the second threshold according to the number of features in the feature set of the iteration policy screening; and inputting the feature set screened by the iteration strategy into a classifier, and calculating a loss function according to the classification result and the corresponding label.
And ending the iteration until the strategy network converges or the first candidate feature set and the second candidate feature set are empty, so as to obtain the trained strategy network.
Preferably, the loss function of the model training adopts cross entropy, and then the obtained cross entropy is reversely propagated to the strategy network by using BP.
As further embodiments of the present invention, adjusting the first threshold and the second threshold according to the number of features in the feature set of the round of iterative policy filtering includes:
and judging whether the feature quantity in the feature set screened by the iteration strategy is greater than a preset quantity threshold value, if so, reducing the first threshold value and the second threshold value, and otherwise, increasing the first threshold value and the second threshold value.
Preferably, the first threshold and the second threshold are decreased by a percentage if the number of features in the feature sets of the iteration policy filtering is greater than a preset number threshold, and the first threshold and the second threshold are increased by a percentage if the number of features in the feature sets of the iteration policy filtering is less than or equal to the preset number threshold.
That is to say, in the process of training the policy network, the first threshold and the second threshold may be adjusted after each iteration, and the adjustment is carried out in the next iteration, so that the policy network may reach higher accuracy, and the dynamic adjustment of the first threshold and the second threshold is realized.
Notably, the policy network employs a random policy selection action. Preferably, after obtaining the feature set of the round of iterative strategy screening, the method includes:
obtaining an action instruction returned by the strategy network, if the action instruction is an action increasing instruction, continuing to randomly select a feature from the first candidate feature set and incorporate the feature into the alternative feature set, and deleting the feature in the first candidate feature set to execute the iterative training strategy network;
if the action instruction is a deletion action instruction, acquiring a feature pair with a correlation coefficient larger than a preset coefficient threshold value among features in the candidate feature set based on a preset correlation coefficient model, randomly selecting one feature in the feature pair to be merged into the first candidate feature set, and continuously executing the iterative training strategy network by deleting the feature in the candidate feature set.
In the process of training the strategy network, after each iteration, the candidate feature set and the features in the first candidate feature set can be dynamically adjusted through the action instructions returned by the strategy network, and then the next iteration calculation is performed, so that the training of the strategy network is efficiently realized, and the strategy network with extremely high accuracy is obtained.
In a specific embodiment of the present invention, the process of training the policy network takes a data set wine commonly used in the field of data mining as an example, the example is to identify wine varieties according to 13 characteristics of wine, and 3 wine category labels label in total belong to a multi-classification task, including the following characteristics:
1) alcohol content 2) malic acid 3) ash 4) ash alkalinity 5) magnesium 6) total phenols 7) flavonoids 8) non-starchy phenols 9) procyanidins 10) color intensity 11) color intensity 12) OD280/OD 31513) proline of diluted wine
Data is a data set line including the above 13 features, and an optimal feature subset S (a partial feature subset of the 13 features) is output. As shown in fig. 2, an architecture diagram of a training strategy network according to an embodiment of the present invention includes:
the method comprises the following steps: the candidate feature set is initialized, i.e. an empty set T is created, and the candidate feature set I ═ f1, f2, …, fD } (f1, f2, …, fD: the 13 feature sets representing the wine mentioned above).
Step two: and calculating the information gain rate, the Gini index, the variance and the like of each feature in the candidate feature set I according to the evaluation model, and then recording the features higher than the first threshold value into the first candidate feature set H. Each evaluation model corresponds to a corresponding initialized first threshold (e.g., a first threshold n corresponding to an information gain ratio, a first threshold m corresponding to a kuni index, and a first threshold p corresponding to a variance) which is an average value of evaluation values obtained by each feature based on the evaluation model.
Step three: pearson correlation coefficients, spearman coefficients, mutual information and distance correlation coefficients (for example, correlation coefficients between alcohol content and malic acid or between ash and magnesium) between every two features in the first candidate feature set H are calculated according to the correlation coefficient model, and features with each coefficient higher than a second threshold value are recorded into a second candidate feature set P. And the initialized second threshold corresponding to each correlation coefficient model is an average value of correlation coefficients obtained between every two characteristics based on the correlation coefficient model. For example, the second threshold corresponding to the pearson correlation coefficient is q.
Step four: randomly adding a feature (such as alcohol content) fadd (fadd element H), assigning the result of taking the union of T and the feature fadd to T (namely T ← T { fadd }), and assigning the result of deleting the feature fadd from H to H (namely H ← H \ fadd }).
Step five: inputting the fadd characteristic, the first threshold value and the second threshold value in the second step and the third step, as well as the first candidate characteristic set and the second candidate characteristic set which are currently screened out into a policy network as a current state, and the policy network outputting an action by adopting a random policy:
π(at|st;θ)=σ(W*St+b)
in the above formula, St is the current state, and σ is sigmoid, π (a)t|st(ii) a Theta) is the probability of action, and then the features obtained after action (action indicates action instructions through two types of 0 and 1, namely whether action instructions are added or deleted) in the round of iteration strategy screening are input into a classifier to be classified to obtain a classification result, for example, only malic acid is left in the features at this time, the precision of the result obtained after the malic acid is used as the features and is calculated by the classifier is a probability value between 0 and 1, and the probability value and label of the training set win.
Step six: specifically, the correction mode can be selected according to the performance of the current state, and whether the number of features in the feature set screened by the iteration strategy in the round is greater than a preset number threshold is judged, if so, the first threshold and the second threshold are reduced by a percentage, and otherwise, the first threshold and the second threshold are increased by a percentage. For example: if the current state results in 3 features and more features need to be added to the training, the first threshold and the second threshold may be set to be appropriately decreased by a percentage in the next round, and more features will be added to the training in the strategy network in the next round, and the features are increased otherwise.
Step seven: and acquiring an action instruction returned by the policy network, and randomly selecting a characteristic fadd, T ← T { fadd }, H ← H \ fadd }, from the first candidate characteristic set H if the action instruction is an action increasing instruction. If the action instruction is an action deletion instruction, finding out several larger pairs of features (namely feature pairs larger than a preset coefficient threshold) in the correlation coefficients among the features in the T by inquiring P, and randomly selecting one feature fdel in the pairs of features, T ← T \ fdel }, H ← H { fdel }.
Step eight: inputting the feature set (assuming that the feature set obtained after the screening in the previous steps is alcohol content and malic acid) of the iteration strategy screening into a classifier, and calculating to obtain reward (R), wherein the reward is obtained by performing log transformation on the probability obtained after the feature and label calculation:
R=log P(y|x)
where y refers to label data (in this example, categories of various wines), and x refers to candidate feature data (alcohol content and malic acid).
Step nine: selecting cross entropy by using a loss function of strategy network training:
Figure RE-RE-GDA0002653840610000101
in step eight, a loss function can be calculated through the features and the labels (label), wherein cross entropy is selected for calculation, and the obtained cross entropy is reversely propagated to the whole policy network by using BP (back propagation) for correcting the policy network parameters.
It should be noted that if the whole loop calculation process (loop iteration from step two to step eight) reaches the termination condition (for example, no feature exists in P and H or the policy network converges), the iteration is stopped, and the policy network obtained after N iterations is the optimal model.
FIG. 3 is a schematic diagram of the main modules of a feature selection apparatus for generating a user representation according to an embodiment of the present invention, and as shown in FIG. 3, the feature selection apparatus 300 for generating a user representation includes a receiving module 301 and a processing module 302. The receiving module 301 receives feature data to be processed, and generates a candidate feature set; the processing module 302 calculates an evaluation value of each feature in the candidate feature set based on a preset evaluation model, and records the feature with the evaluation value larger than a first threshold into a first candidate feature set; calculating a correlation coefficient between every two features in the first candidate feature set based on a preset correlation coefficient model, and recording the features of which the correlation coefficients are larger than a second threshold value into a second candidate feature set; and substituting the first threshold, the second threshold, the first candidate feature set and the second candidate feature set into a pre-trained strategy network to obtain a feature set screened by the strategy for generating the user portrait.
In some embodiments, before the processing module 302 substitutes the first threshold, the second threshold, the first candidate feature set, and the second candidate feature set into the pre-trained policy network, the method includes:
acquiring historical characteristic data and labels thereof, and generating a candidate characteristic set through the historical characteristic data;
when each iteration training strategy network is carried out, calculating an evaluation value of each feature in a candidate feature set based on a preset evaluation model, and recording the feature of which the evaluation value is greater than a first threshold value into a first candidate feature set; calculating a correlation coefficient between every two features in the first candidate feature set based on a preset correlation coefficient model, and recording the features of which the correlation coefficients are larger than a second threshold value into a second candidate feature set; randomly selecting a feature from the first candidate feature set and deleting the feature in the first candidate feature set; substituting the feature, the first threshold, the second threshold, the first candidate feature set and the second candidate feature into a policy network to obtain a feature set of the iteration policy screening, and adjusting the first threshold and the second threshold according to the number of features in the feature set of the iteration policy screening; and inputting the feature set screened by the iteration strategy into a classifier, and calculating a loss function according to the classification result and the corresponding label.
In some embodiments, the processing module 302 calculates a loss function based on the classification results and the corresponding labels, including:
and (4) adopting cross entropy as a loss function of model training, and reversely transmitting the obtained cross entropy to the strategy network by using BP.
In some embodiments, the processing module 302 adjusts the first threshold and the second threshold according to the number of features in the feature set of the round of iterative policy filtering, including:
and judging whether the feature quantity in the feature set screened by the iteration strategy is greater than a preset quantity threshold value, if so, reducing the first threshold value and the second threshold value by a percentage, and otherwise, increasing the first threshold value and the second threshold value by a percentage.
In some embodiments, further comprising: the policy network employs a random policy selection action.
In some embodiments, after the processing module 302 obtains the feature set of the iterative policy screening, it includes:
obtaining an action instruction returned by the strategy network, if the action instruction is an action increasing instruction, continuing to randomly select a feature from the first candidate feature set and incorporate the feature into the alternative feature set, and deleting the feature in the first candidate feature set to execute the iterative training strategy network;
if the action instruction is a deletion action instruction, acquiring a feature pair with a correlation coefficient larger than a preset coefficient threshold value among features in the candidate feature set based on a preset correlation coefficient model, randomly selecting one feature in the feature pair to be merged into the first candidate feature set, and continuously executing the iterative training strategy network by deleting the feature in the candidate feature set.
In some embodiments, the evaluation model is one or more of an information gain rate, a kini index and a variance, wherein the initialized first threshold corresponding to each evaluation model is an average value of evaluation values obtained by each feature based on the evaluation model;
the correlation coefficient model is one or more of pearson correlation coefficient, spearman coefficient, mutual information and distance correlation coefficient, wherein the initialized second threshold corresponding to each correlation coefficient model is an average value of the correlation coefficients obtained between every two characteristics based on the correlation coefficient model.
It should be noted that, the feature selection method for generating a user representation and the feature selection apparatus for generating a user representation according to the present invention have corresponding relationships in implementation contents, and therefore, the repeated contents are not described again.
FIG. 4 illustrates an exemplary system architecture 400 for a feature selection method for generating a user representation or a feature selection apparatus for generating a user representation, a feature selection decision for generating a user representation or a feature selection decision apparatus for generating a user representation to which embodiments of the present invention may be applied.
As shown in fig. 4, the system architecture 400 may include terminal devices 401, 402, 403, a network 404, and a server 405. The network 404 serves as a medium for providing communication links between the terminal devices 401, 402, 403 and the server 405. Network 404 may include various types of connections, such as wire, wireless communication links, or fiber optic cables, to name a few.
A user may use terminal devices 401, 402, 403 to interact with a server 405 over a network 404 to receive or send messages or the like. The terminal devices 401, 402, 403 may have installed thereon various communication client applications, such as shopping-like applications, web browser applications, search-like applications, instant messaging tools, mailbox clients, social platform software, etc. (by way of example only).
The terminal devices 401, 402, 403 may be various electronic devices including, but not limited to, a smart phone, a tablet computer, a laptop portable computer, a desktop computer, and the like, which have a feature selection screen for generating a user representation or a feature selection discrimination screen for generating a user representation and support web browsing.
The server 405 may be a server providing various services, such as a background management server (for example only) providing support for shopping websites browsed by users using the terminal devices 401, 402, 403. The backend management server may analyze and perform other processing on the received data such as the product information query request, and feed back a processing result (for example, target push information, product information — just an example) to the terminal device.
It should be noted that the feature selection method for generating a user representation or the feature selection determination method for generating a user representation provided by the embodiment of the present invention is generally executed by the server 405, and accordingly, the computing device is generally disposed in the server 405.
It should be understood that the number of terminal devices, networks, and servers in fig. 4 is merely illustrative. There may be any number of terminal devices, networks, and servers, as desired for implementation.
Referring now to FIG. 5, shown is a block diagram of a computer system 500 suitable for use with a terminal device implementing an embodiment of the present invention. The terminal device shown in fig. 5 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention.
As shown in fig. 5, the computer system 500 includes a Central Processing Unit (CPU)501 that can perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM)502 or a program loaded from a storage section 508 into a Random Access Memory (RAM) 503. In the RAM503, various programs and data necessary for the operation of the computer system 500 are also stored. The CPU501, ROM502, and RAM503 are connected to each other via a bus 504. An input/output (I/O) interface 505 is also connected to bus 504.
The following components are connected to the I/O interface 505: an input portion 806 including a keyboard, a mouse, and the like; an output section 507 including a display such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), etc. for generating a user image, and a speaker, etc.; a storage portion 508 including a hard disk and the like; and a communication section 509 including a network interface card such as a LAN card, a modem, or the like. The communication section 509 performs communication processing via a network such as the internet. A drive 810 is also connected to the I/O interface 505 as needed. A removable medium 511 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 510 as necessary, so that a computer program read out therefrom is mounted into the storage section 508 as necessary.
In particular, according to the embodiments of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through the communication section 509, and/or installed from the removable medium 511. The computer program performs the above-described functions defined in the system of the present invention when executed by the Central Processing Unit (CPU) 501.
It should be noted that the computer readable medium shown in the present invention can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present invention, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present invention, however, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules described in the embodiments of the present invention may be implemented by software or hardware. The described modules may also be provided in a processor, which may be described as: a processor includes a receiving module and a processing module. Wherein the names of the modules do not in some cases constitute a limitation of the module itself.
As another aspect, the present invention also provides a computer-readable medium that may be contained in the apparatus described in the above embodiments; or may be separate and not incorporated into the device. The computer readable medium carries one or more programs which, when executed by a device, cause the device to include receiving feature data to be processed, generating a candidate feature set; calculating an evaluation value of each feature in a candidate feature set based on a preset evaluation model, and recording the feature of which the evaluation value is greater than a first threshold value into a first candidate feature set; calculating a correlation coefficient between every two features in the first candidate feature set based on a preset correlation coefficient model, and recording the features of which the correlation coefficients are larger than a second threshold value into a second candidate feature set; and substituting the first threshold, the second threshold, the first candidate feature set and the second candidate feature set into a pre-trained strategy network to obtain a feature set screened by the strategy for generating the user portrait.
According to the technical scheme of the embodiment of the invention, the problems that the existing user portrait feature selection method cannot meet the current ultra-large-scale data background, and is low in precision and poor in efficiency can be solved.
The above-described embodiments should not be construed as limiting the scope of the invention. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions can occur, depending on design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims (10)

1. A method of feature selection for generating a representation of a user, comprising:
receiving feature data to be processed and generating a candidate feature set;
calculating an evaluation value of each feature in a candidate feature set based on a preset evaluation model, and recording the feature of which the evaluation value is greater than a first threshold value into a first candidate feature set; calculating a correlation coefficient between every two features in the first candidate feature set based on a preset correlation coefficient model, and recording the features of which the correlation coefficients are larger than a second threshold value into a second candidate feature set;
and substituting the first threshold, the second threshold, the first candidate feature set and the second candidate feature set into a pre-trained strategy network to obtain a feature set screened by the strategy for generating the user portrait.
2. The method of claim 1, wherein before substituting the first threshold, the second threshold, the first candidate feature set, and the second candidate feature set into the pre-trained policy network, comprises:
acquiring historical characteristic data and labels thereof, and generating a candidate characteristic set through the historical characteristic data;
when each iteration training strategy network is carried out, calculating an evaluation value of each feature in a candidate feature set based on a preset evaluation model, and recording the feature of which the evaluation value is greater than a first threshold value into a first candidate feature set; calculating a correlation coefficient between every two features in the first candidate feature set based on a preset correlation coefficient model, and recording the features of which the correlation coefficients are larger than a second threshold value into a second candidate feature set; randomly selecting a feature from the first candidate feature set and deleting the feature in the first candidate feature set; substituting the feature, the first threshold, the second threshold, the first candidate feature set and the second candidate feature into a policy network to obtain a feature set of the iteration policy screening, and adjusting the first threshold and the second threshold according to the number of features in the feature set of the iteration policy screening; and inputting the feature set screened by the iteration strategy into a classifier, and calculating a loss function according to the classification result and the corresponding label.
3. The method of claim 2, wherein computing a loss function from the classification results and the corresponding labels comprises:
and (4) adopting cross entropy as a loss function of model training, and reversely transmitting the obtained cross entropy to the strategy network by using BP.
4. The method of claim 2, wherein adjusting the first threshold and the second threshold according to the number of features in the feature set filtered by the iteration strategy comprises:
and judging whether the feature quantity in the feature set screened by the iteration strategy is greater than a preset quantity threshold value, if so, reducing the first threshold value and the second threshold value, and otherwise, increasing the first threshold value and the second threshold value.
5. The method of claim 2, further comprising:
the policy network employs a random policy selection action.
6. The method of claim 5, wherein obtaining the set of features for the round of iterative strategy screening comprises:
obtaining an action instruction returned by the strategy network, if the action instruction is an action increasing instruction, continuing to randomly select a feature from the first candidate feature set and incorporate the feature into the alternative feature set, and deleting the feature in the first candidate feature set to execute the iterative training strategy network;
if the action instruction is a deletion action instruction, acquiring a feature pair with a correlation coefficient larger than a preset coefficient threshold value among features in the candidate feature set based on a preset correlation coefficient model, randomly selecting one feature in the feature pair to be merged into the first candidate feature set, and continuously executing the iterative training strategy network by deleting the feature in the candidate feature set.
7. The method according to any one of claims 1-6, comprising:
generating an evaluation model through one or more of information gain rate, a kini index and variance, wherein an initialized first threshold value of the evaluation model is an average value of evaluation values obtained by each feature based on the evaluation model;
and generating a correlation coefficient model through one or more of pearson correlation coefficients, spearman coefficients, mutual information and distance correlation coefficients, wherein the initialized second threshold of the correlation coefficient model is an average value of the correlation coefficients obtained between every two features based on the correlation coefficient model.
8. A feature selection apparatus for generating a representation of a user, comprising:
the receiving module is used for receiving the feature data to be processed and generating a candidate feature set;
the processing module is used for calculating an evaluation value of each feature in the candidate feature set based on a preset evaluation model, and recording the feature of which the evaluation value is greater than a first threshold value into a first candidate feature set; calculating a correlation coefficient between every two features in the first candidate feature set based on a preset correlation coefficient model, and recording the features of which the correlation coefficients are larger than a second threshold value into a second candidate feature set; and substituting the first threshold, the second threshold, the first candidate feature set and the second candidate feature set into a pre-trained strategy network to obtain a feature set screened by the strategy for generating the user portrait.
9. An electronic device, comprising:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement the method of any one of claims 1-8.
10. A computer-readable medium, on which a computer program is stored, which, when being executed by a processor, carries out the method according to any one of claims 1-8.
CN202010604427.8A 2020-06-29 2020-06-29 Feature selection method and device for generating user portrait Pending CN113743436A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010604427.8A CN113743436A (en) 2020-06-29 2020-06-29 Feature selection method and device for generating user portrait

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010604427.8A CN113743436A (en) 2020-06-29 2020-06-29 Feature selection method and device for generating user portrait

Publications (1)

Publication Number Publication Date
CN113743436A true CN113743436A (en) 2021-12-03

Family

ID=78728081

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010604427.8A Pending CN113743436A (en) 2020-06-29 2020-06-29 Feature selection method and device for generating user portrait

Country Status (1)

Country Link
CN (1) CN113743436A (en)

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106991296A (en) * 2017-04-01 2017-07-28 大连理工大学 Ensemble classifier method based on the greedy feature selecting of randomization
CN107368587A (en) * 2017-07-24 2017-11-21 山东省计算中心(国家超级计算济南中心) A kind of system of selection of unsupervised feature based on extension entropy and system
CN108090162A (en) * 2017-12-13 2018-05-29 北京百度网讯科技有限公司 Information-pushing method and device based on artificial intelligence
CN108509996A (en) * 2018-04-03 2018-09-07 电子科技大学 Feature selection approach based on Filter and Wrapper selection algorithms
US20180285730A1 (en) * 2017-03-29 2018-10-04 Alibaba Group Holding Limited Method and apparatus for generating push notifications
CN109816454A (en) * 2019-01-31 2019-05-28 拉扎斯网络科技(上海)有限公司 Method and device for determining policy for merchant, electronic equipment and storage medium
CN110069690A (en) * 2019-04-24 2019-07-30 成都市映潮科技股份有限公司 A kind of theme network crawler method, apparatus and medium
CN110555148A (en) * 2018-05-14 2019-12-10 腾讯科技(深圳)有限公司 user behavior evaluation method, computing device and storage medium

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20180285730A1 (en) * 2017-03-29 2018-10-04 Alibaba Group Holding Limited Method and apparatus for generating push notifications
CN106991296A (en) * 2017-04-01 2017-07-28 大连理工大学 Ensemble classifier method based on the greedy feature selecting of randomization
CN107368587A (en) * 2017-07-24 2017-11-21 山东省计算中心(国家超级计算济南中心) A kind of system of selection of unsupervised feature based on extension entropy and system
CN108090162A (en) * 2017-12-13 2018-05-29 北京百度网讯科技有限公司 Information-pushing method and device based on artificial intelligence
CN108509996A (en) * 2018-04-03 2018-09-07 电子科技大学 Feature selection approach based on Filter and Wrapper selection algorithms
CN110555148A (en) * 2018-05-14 2019-12-10 腾讯科技(深圳)有限公司 user behavior evaluation method, computing device and storage medium
CN109816454A (en) * 2019-01-31 2019-05-28 拉扎斯网络科技(上海)有限公司 Method and device for determining policy for merchant, electronic equipment and storage medium
CN110069690A (en) * 2019-04-24 2019-07-30 成都市映潮科技股份有限公司 A kind of theme network crawler method, apparatus and medium

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
余自林;张晓龙;: "基于有效特征选择的高价值移动通信用户预测方法", 武汉科技大学学报, no. 02, 30 April 2017 (2017-04-30), pages 72 - 77 *

Similar Documents

Publication Publication Date Title
CN107679211B (en) Method and device for pushing information
CN108108743B (en) Abnormal user identification method and device for identifying abnormal user
US20180248879A1 (en) Method and apparatus for setting access privilege, server and storage medium
CN112527649A (en) Test case generation method and device
CN110866040B (en) User portrait generation method, device and system
CN108595448B (en) Information pushing method and device
CN108540508B (en) Method, device and equipment for pushing information
CN111582314A (en) Target user determination method and device and electronic equipment
CN111368551A (en) Method and device for determining event subject
CN110335061B (en) Transaction mode portrait establishing method, device, medium and electronic equipment
CN111581499B (en) Data normalization method, device, equipment and readable storage medium
CN111368189B (en) Goods source sorting recommendation method and device, electronic equipment and storage medium
CN113743436A (en) Feature selection method and device for generating user portrait
CN115619142A (en) Method, device, equipment and computer readable medium for matching data
CN112633394B (en) Intelligent user label determination method, terminal equipment and storage medium
CN115146191A (en) Method and device for identifying video monitoring assets based on AI (Artificial Intelligence) and electronic equipment
CN109669779B (en) Method and device for determining cleaning path of data and cleaning data
CN112148902A (en) Data processing method, device, server and storage medium
CN113762313A (en) Request identification method and device, electronic equipment and storage medium
CN116911304B (en) Text recommendation method and device
CN112532692B (en) Information pushing method and device and storage medium
CN117217852B (en) Behavior recognition-based purchase willingness prediction method and device
CN116501993B (en) House source data recommendation method and device
CN113327133B (en) Data recommendation method, data recommendation device, electronic equipment and readable storage medium
CN111309766B (en) Service feature construction method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination