CN113963205A - Classification model training method, device, equipment and medium based on feature fusion - Google Patents

Classification model training method, device, equipment and medium based on feature fusion Download PDF

Info

Publication number
CN113963205A
CN113963205A CN202111222241.7A CN202111222241A CN113963205A CN 113963205 A CN113963205 A CN 113963205A CN 202111222241 A CN202111222241 A CN 202111222241A CN 113963205 A CN113963205 A CN 113963205A
Authority
CN
China
Prior art keywords
target
classification model
behavior
characteristic
cluster
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
CN202111222241.7A
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.)
OneConnect Financial Technology Co Ltd Shanghai
Original Assignee
OneConnect Financial Technology Co Ltd Shanghai
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 OneConnect Financial Technology Co Ltd Shanghai filed Critical OneConnect Financial Technology Co Ltd Shanghai
Priority to CN202111222241.7A priority Critical patent/CN113963205A/en
Publication of CN113963205A publication Critical patent/CN113963205A/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
    • 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
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/25Fusion techniques
    • G06F18/253Fusion techniques of extracted features
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/044Recurrent networks, e.g. Hopfield networks
    • 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

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Artificial Intelligence (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Evolutionary Computation (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Evolutionary Biology (AREA)
  • Computer Vision & Pattern Recognition (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 relates to the technical field of artificial intelligence, in particular to a classification model training method, a classification model training device, a classification model training equipment and a classification model training medium based on feature fusion. The classification model training method based on the feature fusion comprises the steps of obtaining static features of a target client and extracting dynamic features according to full-scale historical behavior data; acquiring interval time characteristics of the target trigger behaviors based on the current time and the trigger time of each target trigger behavior; performing feature fusion on the interval time features and the dynamic features to obtain fusion features of the target trigger behavior; constructing a client portrait characteristic of a target client based on the static characteristic and the fusion characteristic of the target triggering behavior; and taking the plurality of client portrait characteristics as a target sample set, and training an original client group classification model based on the target sample set to obtain a target client group classification model. The method can ensure that the customer analysis is carried out by adopting the whole amount of historical behavior data, namely the global distribution characteristic of the behavior data is kept, and meanwhile, the accuracy of customer group classification is improved.

Description

Classification model training method, device, equipment and medium based on feature fusion
Technical Field
The invention relates to the technical field of artificial intelligence, in particular to a classification model training method, a classification model training device, a classification model training equipment and a classification model training medium based on feature fusion.
Background
With the rapid development of artificial intelligence technology, various systems and platforms for customer service are also gradually brought into use. In the field of customer service, in order to improve customer experience, an enterprise or an organization generally classifies a customer group based on an artificial intelligence technology to predict the recent attention of customers to certain types of information, so as to recommend relevant services in a targeted manner.
At present, a traditional passenger group classification method generally directly collects static data (such as an industry to which a user belongs, a user age, a user gender, and the like) of the user and historical behavior data as sample data to construct a classification model for classification, but because the interval time between the trigger time of some behaviors in the historical behavior data and the current time may affect the prediction accuracy of the user on the attention of certain information in the near future, in order to solve the problem, generally only the data of the user in the latest period of time is collected for classification, but the method can only utilize the data of the user in the latest period of time, and cannot retain the global distribution characteristic of the historical behavior data, and different clients have different data amounts in the period of time, so that sample distribution is easily unbalanced, and the model classification accuracy is not high.
Disclosure of Invention
The embodiment of the invention provides a classification model training method, a classification model training device, classification model training equipment and a classification model training medium based on feature fusion, and aims to solve the problem that the classification accuracy of a current passenger group classification model is low when the current passenger group classification model is trained by using full-scale historical behavior data.
A classification model training method based on feature fusion comprises the following steps:
acquiring static characteristics of each target client and dynamic characteristics extracted according to the full amount of historical behavior data; wherein the historical behavior data comprises a plurality of target trigger behaviors, and the dynamic characteristic is a behavior characteristic representation of each target trigger behavior;
acquiring interval time characteristics of each target trigger behavior based on the current time and the trigger time of each target trigger behavior;
performing feature fusion on the interval time feature and the dynamic feature of each target trigger behavior to obtain a fusion feature of each target trigger behavior;
constructing a client representation characteristic of each target client based on the static characteristic and the fusion characteristic of each target triggering behavior;
and taking the client portrait characteristics of the target clients as a target sample set, and training an original client group classification model based on the target sample set to obtain a target client group classification model.
A classification model training device based on feature fusion comprises:
the data acquisition module is used for acquiring the static characteristics of each target client and the dynamic characteristics extracted according to the full amount of historical behavior data; wherein the historical behavior data comprises a plurality of target trigger behaviors, and the dynamic characteristic is a behavior characteristic representation of each target trigger behavior;
the interval time characteristic acquisition module is used for acquiring the interval time characteristic of each target trigger behavior based on the current time and the trigger time of each target trigger behavior;
the fusion module is used for carrying out feature fusion on the interval time feature and the dynamic feature of each target trigger behavior to obtain a fusion feature of each target trigger behavior;
the client portrait characteristic construction module is used for constructing the client portrait characteristics of each target client based on the static characteristics and the fusion characteristics of each target trigger behavior;
and the training module is used for taking the client portrait characteristics of the target clients as a target sample set so as to train an original passenger group classification model based on the target sample set to obtain a target passenger group classification model.
A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, the processor implementing the steps of the above-mentioned feature fusion based classification model training method when executing the computer program.
A computer storage medium, in which a computer program is stored which, when being executed by a processor, carries out the steps of the above-mentioned method for training a classification model based on feature fusion.
In the classification model training method, the classification model training device, the classification model equipment and the classification model medium based on the feature fusion, the static features of each target customer are obtained, and the dynamic features are extracted according to the total historical behavior data, so that the customer group classification is carried out from the global perspective on the basis of the total historical behavior data of the target customers. And then, acquiring interval time characteristics of each target trigger behavior based on the current time and the interval time of the trigger time of each target trigger behavior, and performing characteristic fusion on the interval time characteristics and the dynamic characteristics of each target trigger behavior to obtain fusion characteristics of each target trigger behavior, so that the interval time characteristic information and the behavior characteristics of the target trigger behavior are fused, and the model can learn the influence of the time characteristics on the classification of the passenger groups. Then, based on the static characteristics and the fusion characteristics of each target triggering behavior, the client portrait characteristics of each target client are constructed, the client portrait characteristics of a plurality of target clients are used as a target sample set, an original guest group classification model is trained based on the target sample set to obtain a target guest group classification model, and the client portrait characteristics with time dimension characteristics are used as samples for training, so that the accuracy of guest group classification can be guaranteed while the full amount of historical behavior data is used for guest group classification.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings needed to be used in the description of the embodiments of the present invention will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art that other drawings can be obtained according to these drawings without inventive labor.
FIG. 1 is a schematic diagram of an application environment of a classification model training method based on feature fusion according to an embodiment of the present invention;
FIG. 2 is a flowchart of a method for training a classification model based on feature fusion according to an embodiment of the present invention;
FIG. 3 is a detailed flowchart of step S202 in FIG. 2;
FIG. 4 is a detailed flowchart of step S203 in FIG. 2;
FIG. 5 is a flowchart of a method for training a classification model based on feature fusion according to an embodiment of the present invention;
FIG. 6 is a detailed flowchart of step S501 in FIG. 5;
FIG. 7 is a detailed flowchart of step S602 in FIG. 6;
FIG. 8 is a flowchart of a method for training a classification model based on feature fusion according to an embodiment of the present invention;
FIG. 9 is a schematic diagram of a classification model training apparatus based on feature fusion according to an embodiment of the present invention;
FIG. 10 is a schematic diagram of a computer device according to an embodiment of the invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The classification model training method based on feature fusion can be applied to the application environment as shown in fig. 1, wherein computer equipment is communicated with a server through a network. The computer device may be, but is not limited to, various personal computers, laptops, smartphones, tablets, and portable wearable devices. The server may be an independent server, or may be a cloud server that provides basic cloud computing services such as a cloud service, a cloud database, cloud computing, a cloud function, cloud storage, a Network service, cloud communication, a middleware service, a domain name service, a security service, a Content Delivery Network (CDN), and a big data and artificial intelligence platform.
In an embodiment, as shown in fig. 2, a method for training a classification model based on feature fusion is provided, which is described by taking the method as an example applied to the server in fig. 1, and includes the following steps:
s201: acquiring static characteristics of each target client and dynamic characteristics extracted according to the full amount of historical behavior data; the historical behavior data comprises a plurality of target trigger behaviors, and the dynamic characteristics are behavior characteristic representations of each target trigger behavior.
Specifically, the method can be applied to any customer group classification scene, so that the customer group classification is performed according to the static characteristics and the behavior characteristics of customers, the attention degree of certain information corresponding to different customers is predicted, and corresponding front-end pages are displayed for different customers.
The static features refer to vector representations corresponding to the static information of the clients. The static information refers to inherent attribute information of the target client, such as the industry, age, sex, region of the client, and user's academic history. Historical behavior data refers to the full amount of historical behavior data of the customer prior to the current time in the platform. The historical behavior data includes a plurality of target triggering behaviors, such as service triggering behaviors (i.e. services used by the user), inquiry triggering behaviors (i.e. browsed information), topic comment triggering behaviors (i.e. participated topic comments), training triggering behaviors (i.e. participated training), and the like. The dynamic characteristics refer to vector representations corresponding to target trigger behaviors, each target trigger behavior is used as a characteristic dimension, for example, the structure of the dynamic characteristics is shown in the following table (taking the dynamic characteristics corresponding to 4 customer samples as an example):
Figure 1
in the table, the service triggering behavior may include a plurality of service categories, i.e., A, B, C, D, the query triggering behavior may include a plurality of query categories, i.e., E, F, G, H, the topic review triggering behavior may include a plurality of topic categories, i.e., M, N, P, Q, and the training triggering behavior may include a plurality of training categories, i.e., X, Y, Z, W, wherein, for customer sample 1, the dynamic characteristic "1" of the class B service in the service triggering behavior indicates that the customer used the class B service in the past, and "0" indicates that the customer did not browse/participate. Similarly, the dynamic feature "1" of the N types of clothing topics in the topic comment triggering behavior indicates that the client has participated in the N types of topic comments in the past.
S202: and acquiring interval time characteristics of each target trigger action based on the current time and the trigger time of each target trigger action.
It can be understood that the conventional guest group classification only classifies recent historical behavior data of customers, and different customers have different amounts of recent historical behavior data, which may cause a problem of sample distribution balance, while the use of the full amount of historical behavior data may enable samples to retain the distribution characteristics of historical behaviors, but if the use of the full amount of historical behavior data enables the current guest group classification to perform feature extraction only through the frequency of some trigger behaviors and the like, the influence of the trigger time of the trigger behavior on a prediction target is ignored, and further, the accuracy of the guest group classification is not high.
The different target triggering behaviors correspond to a triggering time, and the interval time between the triggering time and the current time affects the attention degree of the client to different information, so that the interval time characteristic of each target triggering behavior is introduced into the model sample for training, the passenger group classification in the global angle can be realized, and the model accuracy is improved.
Specifically, the interval time of the trigger time and the current time of each target trigger action is used as the interval time characteristic of each target trigger action. Wherein, the current time refers to the current system time, i.e. the current date when the model training is performed, such as 2021-9-15.
S203: and performing feature fusion on the interval time feature and the dynamic feature of each target trigger behavior to obtain a fusion feature of each target trigger behavior.
In this embodiment, the implementation manners of the interval time characteristic and the dynamic characteristic of each target trigger behavior include, but are not limited to, the following two types: firstly, adding the time characteristic and the dynamic characteristic to obtain the fusion characteristic; and secondly, splicing the time characteristic and the dynamic characteristic to obtain the fusion characteristic.
S204: and constructing the client portrait characteristics of each target client based on the static characteristics and the fused characteristics of each target trigger behavior.
Specifically, the client portrait characteristics corresponding to the target client are constructed by simply splicing the fusion characteristics and the static characteristics of each target trigger behavior. For example, the static features are vectors of 1 × N, the fusion features of each target trigger behavior (assuming that there are C target trigger behaviors) are vectors of 1 × M, the fusion features of the target trigger behaviors are first spliced to obtain 1 × (M + C), and then the spliced vectors 1 × (M + C) are spliced with the static features to obtain the customer image features of each target customer, that is, vectors of 1 × (M + N + C).
S205: and taking the client portrait characteristics of a plurality of target clients as a target sample set, and training an original client group classification model based on the target sample set to obtain a target client group classification model.
Specifically, the client portrait characteristics of a plurality of target clients are used as a target sample set, and an original passenger group classification model is trained on the basis of the target sample set to obtain a target passenger group classification model. In this embodiment, since the target sample set is time-series data, after the target sample set is obtained, the original passenger group classification model may be constructed based on the LSTM network, so as to train the original passenger group classification model based on the target sample set to obtain the target passenger group classification model. The LSTM network is a threshold RNN, and is characterized in that the LSTM network can accumulate long-term contact among nodes with long distance by adding an input gate, a forgetting gate and an output gate and designing a weight coefficient among connections to realize long-term memory of data. It should be noted that the process of model training for the LSTM network is consistent with the process of model training for the conventional LSTM network, and is not described in detail here.
In this embodiment, the classification of the guest groups is performed from the global perspective on the basis of the total amount of historical behavior data of the target customers by obtaining the static characteristics of each target customer and the dynamic characteristics extracted according to the total amount of historical behavior data. And then, acquiring interval time characteristics of each target trigger behavior based on the current time and the interval time of the trigger time of each target trigger behavior, and performing characteristic fusion on the interval time characteristics and the dynamic characteristics of each target trigger behavior to obtain fusion characteristics of each target trigger behavior, so that the interval time characteristic information and the behavior characteristics of the target trigger behavior are fused, and the model can learn the influence of the time characteristics on the classification of the passenger groups. Then, based on the static characteristics and the fusion characteristics of each target triggering behavior, the client portrait characteristics of each target client are constructed, the client portrait characteristics of a plurality of target clients are used as a target sample set, an original guest group classification model is trained based on the target sample set to obtain a target guest group classification model, and the client portrait characteristics carrying time information are used as samples for training, so that the accuracy of guest group classification can be guaranteed while the full amount of historical behavior data is used for guest group classification.
In an embodiment, as shown in fig. 3, in step S202, that is, based on the current time and the trigger time of each target trigger action, the obtaining of the interval time characteristic of each target trigger action specifically includes the following steps:
s301: and calculating the interval time between the trigger time and the current time of each target trigger action.
S302: and carrying out discretization processing on the interval time to obtain the interval time characteristic of each target trigger behavior.
In particular, the time interval may be divided into a number of number domains, e.g., [1-30 days), [30-60 days), and so on. And each number domain can be represented by a preset standard value, a corresponding number domain is determined for the calculated interval time, and then the standard value corresponding to the number domain is used as the interval time characteristic of the target trigger behavior.
It can be understood that, for client samples with similar interval time, the time characteristics reflected by the interval time have little influence on the prediction result, so in this embodiment, the interval time may be discretized to obtain the interval time characteristics of each target trigger behavior, thereby reducing the data processing amount of subsequent models and improving the model training efficiency.
In an embodiment, as shown in fig. 4, in step S203, the feature fusion is performed on the interval time feature and the dynamic feature of each target trigger behavior to obtain a fusion feature of each target trigger behavior, which specifically includes the following steps:
s401: and adding the interval time characteristic and the dynamic characteristic to obtain a fused characteristic.
Specifically, the interval time signature X1 and the dynamic signature X2 may be subjected to vector addition, i.e., bitwise addition processing, to obtain the fused signature, i.e., X1+ X2.
S402: and splicing the interval time characteristic and the dynamic characteristic to obtain a fusion characteristic of the target triggering behavior.
Specifically, the interval time features and the dynamic features may be further spliced to obtain fused features, for example, a line vector with time features of 1 × P, and a line vector with fused features of 1 × Q, and the client image features obtained after the splicing are vectors of 1 × P (P + Q).
In an embodiment, as shown in fig. 5, the method for training a classification model based on feature fusion further includes the following steps:
s501: performing clustering analysis on the target sample set by adopting a K-means clustering algorithm to obtain a plurality of clustering clusters; wherein each cluster is used to indicate a customer category.
S502: and labeling the target samples in each cluster based on the client category so as to randomly select at least one labeled target sample from each cluster to form a training sample set.
The kmeans clustering algorithm is also called as a k-means clustering algorithm, is a simple and classical distance-based clustering algorithm, and adopts the distance as an evaluation index of similarity, namely, the closer the distance between two objects is, the greater the similarity of the two objects is. The algorithm considers that the class cluster is composed of objects close in distance, so that a compact and independent cluster is taken as a final target.
Understandably, the problem of greatly reducing the cost of manual labeling can be solved by performing cluster analysis on target sample data by adopting a kmeans clustering algorithm and labeling the client category of a target client in an unsupervised learning mode. In this embodiment, the client category may refer to different categories such as topic, service, inquiry, training, etc. which indicate that the client has a high degree of attention to certain category information.
S503: and training the original passenger group classification model based on the training sample set to obtain a target passenger group classification model.
Specifically, because the similarity of some target samples in the target sample set is high, which is not beneficial to the learning of the model for the sample discrimination, in this embodiment, the target sample set is subjected to cluster analysis to obtain uniform sample distribution, and then at least one labeled target sample is randomly selected from each cluster to form a training sample set for model training, so that the difference between different samples is increased, the data enhancement of the sample data is realized, and the robustness of the classification model is further improved.
Illustratively, assuming that three clustering clusters are obtained by clustering, namely A, B, C, at least one target sample is randomly selected from A, B, C, namely at least one target sample is randomly selected from a, at least one target sample is randomly selected from B, and at least one target sample is randomly selected from C, so that a plurality of target samples obtained by selection form a training sample set.
In an embodiment, as shown in fig. 6, the method for training a classification model based on feature fusion further includes the following steps:
s601: initializing the number of clustering clusters, and randomly selecting a target sample with the number of clustering clusters from a target sample set as an initial centroid; wherein the number of cluster clusters is used to indicate the number of initial centroids;
the number of the cluster clusters refers to the number of the initial centroids or the number of the customer categories, and the setting of the K value in this embodiment may be set according to actual needs, which is not limited herein. In particular, k target samples may be randomly chosen from the set of target samples as initial centroids.
S602: and calculating the sample distance between the initial centroid of each cluster and each target sample in the target sample set so as to cluster the target samples of which the sample distances meet the preset clustering condition in the same cluster.
Specifically, the sample distance between each target sample in the initial centroid target sample set of each cluster can be calculated by methods including, but not limited to, euclidean distance or cosine similarity algorithm to cluster the target samples whose sample distances satisfy the preset clustering condition in the same cluster. Wherein, the sample distance can be characterized by Euclidean distance or cosine similarity. The preset clustering condition may be a preset distance threshold or a similarity threshold, which is not limited herein.
S603: and updating the centroid of each cluster to perform cluster analysis on the target sample set according to the updated centroid to obtain a plurality of clusters.
Specifically, the centroid of each cluster is updated, and steps S602-S603 are repeatedly performed, and clustering is continuously iterated until the distance between the updated centroid corresponding to the cluster and the centroid before updating is less than a preset distance (which may be a preset algorithm stop condition), so as to obtain a plurality of clusters.
Wherein, the calculation formula of the cosine similarity is
Figure BDA0003313025140000111
Wherein a represents an initial centroid (or an updated centroid); b represents target sample data. Specifically, the cosine value ranges from [ -1,1 []The closer the cosine value is to 1, the smaller the included angle between the two vectors is, the more similar the included angle is.
In an embodiment, as shown in fig. 7, in step S602, a sample distance between the initial centroid of each cluster and each target sample in the target sample set is calculated to cluster the target samples whose sample distances satisfy a preset clustering condition in the same cluster, which specifically includes the following steps:
s701: a mean vector is calculated based on the initial centroid and the target sample.
Specifically, because cosine similarity is more sensitive to differences in direction and is insensitive to absolute values, it is impossible to measure the feature differences between each dimension, for example: the two samples X and Y are assumed to be (1,2) and (4,5), respectively, and the result obtained by using the cosine similarity is 0.98, which are very similar to each other, but for the first dimension, the difference between the eigenvalue "1" corresponding to the X sample and the eigenvalue "4" in the Y sample is large, so that the cosine similarity is insensitive to the numerical value to cause the error of the calculation result of the similarity, and in order to correct the irrationality of the calculation result of the cosine similarity, in this embodiment, the samples involved in the calculation are respectively normalized to improve the data accuracy, so as to correct the insensitivity of the cosine similarity to the numerical value.
The average vector is calculated based on the initial centroid and the target sample data, that is, the average is taken in all the feature dimensions of the initial centroid and the target sample data to obtain the average vector, for example, the initial centroid and the target sample data are (1,2) and (4,5), respectively, and the average vector is (1+4/2, 2+ 5/2).
S702: and based on the average value vector, performing normalization processing on the initial centroid and the target sample set to update the initial centroid and the target sample set.
S703: and calculating the updated initial centroid and the cosine similarity between each target sample in the target sample set so as to cluster the target samples of which the cosine similarity meets the preset clustering condition in the same cluster.
In this embodiment, the samples involved in the calculation are normalized respectively, that is, an average vector is subtracted from each sample, for example, the two samples of X and Y are (1,2) and (4,5), the average vector of X and Y is (2.5, 3.5), the updated adjusted initial centroid and the target sample data are (-1.5 ) and (1.5,2.5), respectively, and then the cosine similarity calculation is performed based on the updated initial centroid and the target sample data to obtain a sample distance of-0.98, where the similarity is a negative value and the difference is large, so that an error caused by insensitivity of the cosine similarity to an absolute value can be effectively corrected.
In an embodiment, as shown in fig. 8, the method for training a classification model based on feature fusion further includes the following steps:
s801: and calculating a joint defense difference matrix of each cluster based on the target samples in each cluster.
It is understood that the corresponding covariance matrix is calculated by converting the sample matrix X composed of a plurality of target sample data in each cluster to a zero-mean matrix and then by transposing the zero-mean matrix and the zero-mean matrix. Wherein, the calculation formula of the covariance matrix is,
Figure BDA0003313025140000131
where C represents a covariance matrix, X represents target sample data, and m represents the number of feature factors in the customer representation characteristics.
S802: and carrying out matrix decomposition on the covariance matrix to obtain at least one characteristic value.
Specifically, eigenvalues and corresponding eigenvectors can be obtained by performing SVD matrix decomposition on the covariance matrix. Singular Value Decomposition (SVD) is an important matrix Decomposition in linear algebra, and the matrix Decomposition operation processing can effectively reduce the dimension of large-batch data, so as to reduce the operation amount and save the operation time.
Specifically, two unitary matrices and a positive semidefinite diagonal matrix are obtained by matrix decomposition of the covariance matrix, and values on diagonal lines of the positive semidefinite diagonal matrix are eigenvalues, and the eigenvalues generally contain N (N is greater than 2). The eigenvalue can represent the important information implied in the sample matrix, and the importance is positively correlated with the eigenvalue size.
It is understood that the larger the eigenvalue, the larger the amount of effective information contained in the eigenvalue; conversely, the smaller the feature value, the less the amount of effective information the feature value contains, and the more noise it is assumed to contain. By carrying out matrix decomposition on the covariance matrix, the eigenvalue and the corresponding eigenvector are obtained, the degree of effective information content contained in the eigenvalue can be visually observed, the noise reduction treatment on the sample is facilitated, the subsequent model training data volume is reduced, and the model training efficiency is further improved.
S803: and reducing the dimension of the target sample in the cluster based on the at least one characteristic value so as to update each cluster.
Specifically, the eigenvectors are arranged into a matrix from top to bottom according to the eigenvalues from large to small, and then the eigenvectors with the eigenvalues arranged at the top N bits or larger than a preset threshold are retained to filter out the eigenvectors with less effective information, thereby realizing the dimension reduction of the target sample in each cluster.
For example, assuming that 2 eigenvalues, e.g. 4,0, are obtained by singular value decomposition, the eigenvector corresponding to each eigenvalue is respectively
Figure BDA0003313025140000142
Arranging the eigenvectors into a matrix from top to bottom according to the eigenvalues from large to small
Figure BDA0003313025140000141
It should be understood that, the sequence numbers of the steps in the foregoing embodiments do not imply an execution sequence, and the execution sequence of each process should be determined by its function and inherent logic, and should not constitute any limitation to the implementation process of the embodiments of the present invention.
In an embodiment, a classification model training device based on feature fusion is provided, and the classification model training device based on feature fusion is in one-to-one correspondence with the classification model training method based on feature fusion in the above embodiment. As shown in FIG. 9, the classification model training device based on feature fusion comprises a data acquisition module 10, an interval time feature acquisition module 20, a fusion module 30, a client portrait feature construction module 40 and a training module 50. The functional modules are explained in detail as follows:
the data acquisition module 10 is used for acquiring the static characteristics of each target client and the dynamic characteristics extracted according to the total amount of historical behavior data; wherein the historical behavior data comprises a plurality of target trigger behaviors, and the dynamic characteristic is a behavior characteristic representation of each target trigger behavior;
an interval time characteristic obtaining module 20, configured to obtain an interval time characteristic of each target trigger action based on a current time and a trigger time of each target trigger action;
the fusion module 30 is configured to perform feature fusion on the interval time feature and the dynamic feature of each target trigger behavior to obtain a fusion feature of each target trigger behavior;
a client representation feature construction module 40, configured to construct a client representation feature of each of the target clients based on the static features and the fused features of each of the target trigger behaviors;
and the training module 50 is configured to use the client portrait features of the plurality of target clients as a target sample set, and train an original guest group classification model based on the target sample set to obtain a target guest group classification model.
Specifically, the interval time characteristic acquisition module comprises an interval time acquisition unit and a time characteristic acquisition unit.
The interval time acquisition unit is used for calculating the interval time between the trigger time of each target trigger action and the current time;
and the time characteristic acquisition unit is used for carrying out discretization processing on the interval time to obtain the interval time characteristic of each target trigger behavior.
Specifically, the fusion module includes a first fusion unit and a second fusion unit.
The first fusion unit is used for adding the interval time characteristic and the dynamic characteristic to obtain a fusion characteristic;
and the second fusion unit is used for splicing the interval time characteristic and the dynamic characteristic to obtain a fusion characteristic of the target trigger behavior.
Specifically, the classification model training device based on feature fusion further comprises a clustering module, a sample labeling module and a training module.
The clustering module is used for carrying out clustering analysis on the target sample set by adopting a K-means clustering algorithm to obtain a plurality of clustering clusters; wherein each cluster is used for indicating a customer category;
and the sample marking module is used for marking the target samples in each cluster based on the client category so as to randomly select at least one marked target sample from each cluster to form a training sample set.
And the training module is used for training the original passenger group classification model based on the training sample set to obtain the target passenger group classification model.
Specifically, the clustering module comprises an initialization unit, a clustering unit and an iteration unit.
The initialization unit is used for initializing the number of the clusters and randomly selecting target samples with the number of the clusters from the target sample set as initial centroids; wherein the number of cluster clusters is used to indicate the number of initial centroids;
the clustering unit is used for calculating a sample distance between the initial centroid of each clustering cluster and each target sample in the target sample set so as to cluster the target samples of which the sample distances meet preset clustering conditions in the same clustering cluster;
and the iteration unit is used for updating the mass center of each cluster, and performing cluster analysis on the target sample set according to the updated mass center to obtain a plurality of clusters.
Specifically, the clustering unit includes an average vector calculation subunit, a normalization processing unit, and a clustering subunit.
A mean vector calculation subunit for calculating a mean vector based on the initial centroid and the target sample;
a normalization processing unit, configured to perform normalization processing on the initial centroid and the target sample set based on the average vector to update the initial centroid and the target sample set;
and the clustering subunit is used for calculating the normalized initial centroid and the cosine similarity between each target sample in the target sample set so as to cluster the target samples of which the cosine similarity meets the preset clustering condition in the same clustering cluster.
Specifically, the classification model training device based on feature fusion further comprises a covariance matrix calculation module, a matrix decomposition module and a sample dimension reduction module.
The covariance matrix calculation module is used for calculating a covariance matrix of each clustering cluster based on a plurality of target samples in each clustering cluster;
the matrix decomposition module is used for carrying out matrix decomposition on the joint defense difference matrix to obtain at least one characteristic value;
and the sample dimension reduction module is used for reducing the dimension of the target samples in the clustering clusters based on at least one characteristic value so as to update each clustering cluster.
For the specific definition of the feature fusion based classification model training apparatus, refer to the above definition of the feature fusion based classification model training method, which is not described herein again. The modules in the above-mentioned classification model training device based on feature fusion can be wholly or partially realized by software, hardware and their combination. The modules can be embedded in a hardware form or independent from a processor in the computer device, and can also be stored in a memory in the computer device in a software form, so that the processor can call and execute operations corresponding to the modules.
In one embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as shown in fig. 10. The computer device includes a processor, a memory, a network interface, and a database connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device comprises a computer storage medium and an internal memory. The computer storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of an operating system and computer programs in the computer storage media. The database of the computer device is used for storing data generated or acquired during the execution of the feature fusion based classification model training method, such as historical behavior data. The network interface of the computer device is used for communicating with an external terminal through a network connection. The computer program is executed by a processor to implement a method of classification model training based on feature fusion.
In one embodiment, a computer device is provided, which includes a memory, a processor, and a computer program stored on the memory and executable on the processor, and the processor executes the computer program to implement the steps of the feature fusion-based classification model training method in the above-described embodiments, such as the steps S201-S205 shown in fig. 2 or the steps shown in fig. 3 to 8. Alternatively, when the processor executes the computer program, the functions of each module/unit in the embodiment of the classification model training apparatus based on feature fusion, for example, the functions of each module/unit shown in fig. 9, are not described herein again to avoid repetition.
In an embodiment, a computer storage medium is provided, where a computer program is stored on the computer storage medium, and when executed by a processor, the computer program implements the steps of the classification model training method based on feature fusion in the foregoing embodiments, such as steps S201 to S205 shown in fig. 2 or steps shown in fig. 3 to fig. 8, which are not repeated herein to avoid repetition. Alternatively, when being executed by a processor, the computer program implements functions of each module/unit in the above-mentioned classification model training apparatus based on feature fusion, for example, the functions of each module/unit shown in fig. 9, and are not described herein again to avoid repetition.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware related to instructions of a computer program, which can be stored in a non-volatile computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. Any reference to memory, storage, database, or other medium used in the embodiments provided herein may include non-volatile and/or volatile memory, among others. Non-volatile memory can include read-only memory (ROM), Programmable ROM (PROM), Electrically Programmable ROM (EPROM), Electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), Double Data Rate SDRAM (DDRSDRAM), Enhanced SDRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), Rambus Direct RAM (RDRAM), direct bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-mentioned division of the functional units and modules is illustrated, and in practical applications, the above-mentioned function distribution may be performed by different functional units and modules according to needs, that is, the internal structure of the apparatus is divided into different functional units or modules, so as to perform all or part of the functions described above.
The above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; such modifications and substitutions do not substantially depart from the spirit and scope of the embodiments of the present invention, and are intended to be included within the scope of the present invention.

Claims (10)

1. A classification model training method based on feature fusion is characterized by comprising the following steps:
acquiring static characteristics of each target client and dynamic characteristics extracted according to the full amount of historical behavior data; wherein the historical behavior data comprises a plurality of target trigger behaviors, and the dynamic characteristic is a behavior characteristic representation of each target trigger behavior;
acquiring interval time characteristics of each target trigger behavior based on the current time and the trigger time of each target trigger behavior;
performing feature fusion on the interval time feature and the dynamic feature of each target trigger behavior to obtain a fusion feature of each target trigger behavior;
constructing a client representation characteristic of each target client based on the static characteristic and the fusion characteristic of each target triggering behavior;
and taking the client portrait characteristics of the target clients as a target sample set, and training an original client group classification model based on the target sample set to obtain a target client group classification model.
2. The feature fusion-based classification model training method of claim 1, wherein the obtaining of the interval time feature of each target trigger behavior based on the current time and the trigger time of each target trigger behavior comprises:
calculating the interval time between the trigger time of each target trigger action and the current time;
and carrying out discretization processing on the interval time to obtain the interval time characteristic of each target triggering behavior.
3. The method for training classification models based on feature fusion as claimed in claim 1, wherein the feature fusion of the interval time features and the dynamic features of each target trigger behavior to obtain the fusion features of each target trigger behavior comprises:
adding the interval time characteristic and the dynamic characteristic to obtain a fused characteristic; or,
and splicing the interval time characteristic and the dynamic characteristic to obtain a fusion characteristic of the target triggering behavior.
4. The method of claim 1, wherein before the training of the original object classification model based on the target sample set using the client image features of the target clients as the target sample set to obtain the target object classification model, the method further comprises:
performing clustering analysis on the target sample set by adopting a K-means clustering algorithm to obtain a plurality of clustering clusters; wherein each cluster is used for indicating a customer category;
labeling the target samples in each cluster based on the client category, and randomly selecting at least one labeled target sample from each cluster to form a training sample set;
training an original passenger group classification model based on the target sample set to obtain a target passenger group classification model, including:
and training the original passenger group classification model based on the training sample set to obtain the target passenger group classification model.
5. The method for training classification models based on feature fusion of claim 4, wherein the clustering analysis is performed on the target sample set by using a K-means clustering algorithm to obtain a plurality of clustering clusters, and the method comprises the following steps:
initializing the number of clustering clusters, and randomly selecting a target sample with the number of clustering clusters from the target sample set as an initial centroid;
calculating a sample distance between the initial centroid of each cluster and each target sample in the target sample set, so as to cluster the target samples of which the sample distances meet a preset clustering condition in the same cluster;
and updating the centroid of each cluster, and performing cluster analysis on the target sample set according to the updated centroid to obtain a plurality of clusters.
6. The method for training classification models based on feature fusion according to claim 5, wherein the step of calculating the sample distance between the initial centroid of each cluster and each target sample in the target sample set to cluster the target samples with the sample distances satisfying the preset clustering condition in the same cluster comprises:
calculating a mean vector based on the initial centroid and the target sample;
normalizing the initial centroid and the target sample set based on the mean vector to update the initial centroid and the target sample set;
and calculating the normalized initial centroid and the cosine similarity between each target sample in the target sample set so as to cluster the target samples of which the cosine similarity meets the preset clustering condition in the same clustering cluster.
7. The method for training a classification model based on feature fusion of claim 4, wherein after the clustering analysis is performed on the target sample set by using the K-means clustering algorithm to obtain a plurality of clusters, the method for training a classification model based on feature fusion further comprises:
calculating a joint defense difference matrix of each cluster based on a plurality of target samples in each cluster;
performing matrix decomposition on the covariance matrix to obtain at least one characteristic value;
and reducing the dimension of the target sample in the cluster based on at least one characteristic value so as to update each cluster.
8. The utility model provides a classification model trainer based on feature fusion which characterized in that includes:
the data acquisition module is used for acquiring the static characteristics of each target client and the dynamic characteristics extracted according to the full amount of historical behavior data; wherein the historical behavior data comprises a plurality of target trigger behaviors, and the dynamic characteristic is a behavior characteristic representation of each target trigger behavior;
the interval time characteristic acquisition module is used for acquiring the interval time characteristic of each target trigger behavior based on the current time and the trigger time of each target trigger behavior;
the fusion module is used for carrying out feature fusion on the interval time feature and the dynamic feature of each target trigger behavior to obtain a fusion feature of each target trigger behavior;
the client portrait characteristic construction module is used for constructing the client portrait characteristics of each target client based on the static characteristics and the fusion characteristics of each target trigger behavior;
and the training module is used for taking the client portrait characteristics of the target clients as a target sample set so as to train an original passenger group classification model based on the target sample set to obtain a target passenger group classification model.
9. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor when executing the computer program implements the steps of the feature fusion based classification model training method according to any one of claims 1 to 7.
10. A computer storage medium, in which a computer program is stored, which, when being executed by a processor, carries out the steps of the method for training a classification model based on feature fusion according to any one of claims 1 to 7.
CN202111222241.7A 2021-10-20 2021-10-20 Classification model training method, device, equipment and medium based on feature fusion Pending CN113963205A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111222241.7A CN113963205A (en) 2021-10-20 2021-10-20 Classification model training method, device, equipment and medium based on feature fusion

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111222241.7A CN113963205A (en) 2021-10-20 2021-10-20 Classification model training method, device, equipment and medium based on feature fusion

Publications (1)

Publication Number Publication Date
CN113963205A true CN113963205A (en) 2022-01-21

Family

ID=79464935

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111222241.7A Pending CN113963205A (en) 2021-10-20 2021-10-20 Classification model training method, device, equipment and medium based on feature fusion

Country Status (1)

Country Link
CN (1) CN113963205A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113538020A (en) * 2021-07-05 2021-10-22 深圳索信达数据技术有限公司 Method and device for acquiring guest group feature association degree, storage medium and electronic device
CN115018405A (en) * 2022-04-07 2022-09-06 胜斗士(上海)科技技术发展有限公司 Merchant classification method and device, electronic equipment and medium
CN116402113A (en) * 2023-06-08 2023-07-07 之江实验室 Task execution method and device, storage medium and electronic equipment
CN117970004A (en) * 2024-02-22 2024-05-03 南京莱芯科技有限公司 Method and device for testing power amplifier, medium and electronic equipment

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113538020A (en) * 2021-07-05 2021-10-22 深圳索信达数据技术有限公司 Method and device for acquiring guest group feature association degree, storage medium and electronic device
CN113538020B (en) * 2021-07-05 2024-03-26 深圳索信达数据技术有限公司 Method and device for acquiring association degree of group of people features, storage medium and electronic device
CN115018405A (en) * 2022-04-07 2022-09-06 胜斗士(上海)科技技术发展有限公司 Merchant classification method and device, electronic equipment and medium
CN116402113A (en) * 2023-06-08 2023-07-07 之江实验室 Task execution method and device, storage medium and electronic equipment
CN116402113B (en) * 2023-06-08 2023-10-03 之江实验室 Task execution method and device, storage medium and electronic equipment
CN117970004A (en) * 2024-02-22 2024-05-03 南京莱芯科技有限公司 Method and device for testing power amplifier, medium and electronic equipment

Similar Documents

Publication Publication Date Title
CN109800307B (en) Product evaluation analysis method and device, computer equipment and storage medium
CN113963205A (en) Classification model training method, device, equipment and medium based on feature fusion
CN108536800B (en) Text classification method, system, computer device and storage medium
CN109376222B (en) Question-answer matching degree calculation method, question-answer automatic matching method and device
CN113705772A (en) Model training method, device and equipment and readable storage medium
CN108520041B (en) Industry classification method and system of text, computer equipment and storage medium
CN110135681B (en) Risk user identification method and device, readable storage medium and terminal equipment
CN109726391B (en) Method, device and terminal for emotion classification of text
CN112380344A (en) Text classification method, topic generation method, device, equipment and medium
US20230103635A1 (en) Interaction information determining method, interaction information prediction model training method, device, and medium
CN111831826A (en) Training method, classification method and device of cross-domain text classification model
WO2022148186A1 (en) Behavioral sequence data processing method and apparatus
CN113435912A (en) Data analysis method, device, equipment and medium based on client portrait
CN110162939B (en) Man-machine identification method, equipment and medium
CN111209929A (en) Access data processing method and device, computer equipment and storage medium
CN114266897A (en) Method and device for predicting pox types, electronic equipment and storage medium
CN118043802A (en) Recommendation model training method and device
CN115238909A (en) Data value evaluation method based on federal learning and related equipment thereof
CN113239697B (en) Entity recognition model training method and device, computer equipment and storage medium
Rudner et al. On the connection between neural processes and gaussian processes with deep kernels
US20210312265A1 (en) Response Generation using Memory Augmented Deep Neural Networks
CN110262906B (en) Interface label recommendation method and device, storage medium and electronic equipment
Huang et al. Efficient optimization for linear dynamical systems with applications to clustering and sparse coding
CN116776150A (en) Interface abnormal access identification method and device, computer equipment and storage medium
US20230092949A1 (en) System and method for estimating model metrics without labels

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