A Classification and Retrieval Method and Device Based on a Popular Science Material Classifier

Through the WGDPool network fusion node characteristics and topological structure, multiple loss functions are designed to optimize node allocation, solving the problem of poor classification effect of science material classifier in the weighted graph, and achieving more efficient science material classification and retrieval.

CN117591671BActive Publication Date: 2025-08-05HUNAN UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202311603691.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-11-28
Publication Date
2025-08-05
Estimated Expiration
2043-11-28

AI Technical Summary

Technical Problem

The classification effect of popular science materials in the prior art is limited, especially in weighted graphs, and the loss function design lacks universality, making it difficult to effectively gather similar nodes.

Method used

Using WGDPool network, combining dual-branch ConvGNN units and differentiable k-means units, the node allocation matrix is optimized by constructing a loss function, including cutting loss terms, orthogonal loss terms, clustering loss terms and reconstruction loss terms, and fusing node characteristics, topological structure and edge weight information to achieve more effective node clustering.

Benefits of technology

It improves the classification accuracy and retrieval efficiency of popular science materials, can better gather nodes with similar spaces, adapt to the needs of different graph structures and tasks, and provide more comprehensive graph representation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117591671B_ABST
    Figure CN117591671B_ABST
Patent Text Reader

Abstract

A method and device for constructing, classifying, and retrieving popular science material classifiers. The construction method is as follows: construct a WGDPool network and a loss function \(L_{u}\). The classification method: input the graph structure corresponding to the to-be-classified popular science material into the WGDPool network for training until the loss function converges to obtain a node assignment matrix \(S\). The retrieval method: train the WGDPool network; convert the to-be-retrieved popular science material into node features as the target node, replace the inserted node in \(G'\) with the target node to form \(G''\), reset the value of \(K\), and input \(G''\) into the trained WGDPool network to obtain a node assignment matrix \(S'\). The popular science materials assigned to the same cluster as the to-be-retrieved popular science material are the retrieval results. A popular science material classification device includes a WGDPool network and a loss function construction module.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of information technology, and particularly relates to a classification and retrieval method and device based on a science popularization material classifier. Background Art

[0002] In the information age, science popularization materials widely exist in various media and platforms, including books, articles, videos, blogs, social media, etc. However, this explosive growth of information has brought the problem of information overload, making it difficult for the audience to quickly and accurately obtain high-quality science popularization information.

[0003] Classification and retrieval, as the core functions of information management, provide effective tools for solving the problem of information overload. Through the classification of science popularization materials, the widely scattered information can be organized into a structured form, making it easier for the audience to find content related to their interests. Retrieval is a further key step based on classification, which provides a method for quickly and effectively finding specific information.

[0004] With the rapid development of graph neural networks, the application fields of graph data have been continuously expanded, including the classification and processing of science popularization materials. Constructing science popularization materials into a graph network and using graph neural networks for classification bring more possibilities and opportunities to the science popularization field.

[0005] If science popularization materials are regarded as nodes in a graph, the relevance between science popularization materials as edges between nodes, and the information of science popularization materials as node features. Then the process of the graph neural network clustering nodes is the process of classifying science popularization materials.

[0006] In graph neural networks, node clustering pooling is a commonly used technique. It can not only be inserted as a module into the graph neural network to reduce the dimension and aggregate graph information, but also aggregate nodes to achieve the classification effect. Node clustering pooling is to map nodes to a set of clusters. Generally speaking, it has the following process:

[0007] 1) First, input the node feature matrix X and the topological structure matrix into a Convolutional Graph Neural Network (abbreviated as ConvGNN) to obtain the graph representation C embed ,

[0008] 2) Then perform operations such as Multi-Layer Perception (MLP) or Softmax on the graph representation C embed to obtain the node assignment matrix S,

[0009] 3) Finally, calculate the pooled node feature matrix X pool , topological structure matrix

[0010] It can be known from the node assignment matrix which cluster (category) a node belongs to. In this process, there is a loss function to optimize the assignment matrix, that is, to optimize the node classification effect.

[0011] However, the current node clustering pooling methods are basically only applied to unweighted graphs and rarely to weighted graphs. Secondly, in the process of obtaining the node assignment matrix, only simple MLP or Softmax operations are used, and the effect of aggregating similar nodes is limited. Moreover, the loss functions corresponding to different node clustering pooling methods have their own characteristics, but there are few general loss functions designed according to the complexity of the graph structure and the diversity of tasks. Summary of the Invention

[0012] In view of this, the present invention provides a classification and retrieval method and device based on a science popularization material classifier, so as to at least solve the problem of limited classification effect of the classifier in the prior art.

[0013] To achieve the above object, the present invention adopts the following technical solutions:

[0014] A method for constructing a science popularization material classifier includes the following steps:

[0015] Construct a WGDPool network:

[0016] Construct a dual-branch ConvGNN unit and a differentiable k-means unit respectively. The dual-branch ConvGNN unit obtains the combined embedding C of the node embedding X and the edge embedding A embed according to the graph structure embed , where the node feature matrix X ∈ R embed , the topological structure matrix n×d , the weighted adjacency matrix A ∈ R , R is the set of real numbers, n represents the number of nodes, d is the dimension of the node features, and the differentiable k-means unit is used to perform clustering sampling on C n×n to obtain the node assignment matrix S, and take the node assignment matrix S as the classification result; embed Construct a loss function

[0017] where

[0018]

[0019] where is the cutting loss term, is the orthogonality loss term, is the clustering loss term, is the reconstruction loss term, and λ, μ, η, and ξ are all adjustable parameters.

[0020] Preferably, the construction of the dual-branch ConvGNN unit specifically includes:

[0021] Construct a first ConvGNN, a second ConvGNN, and a Concat module;

[0022] The first ConvGNN is used to generate node embedding X based on X and embed , and the second ConvGNN is used to generate edge embedding A based on A and embed :

[0023]

[0024] where Θ ConvGNN and β ConvGNN are the trainable parameters within the first ConvGNN and the second ConvGNN respectively, X embed ∈ R n×a , A embed ∈ R n×b ;

[0025] The Concat unit is used to concatenate X embed and A embed to obtain the combined embedding C embed :

[0026] C embed = Concat(X embed , A embed )

[0027] where C embed ∈ R n×(a+b) .

[0028] Preferably, the construction of the differentiable k-means unit specifically includes:

[0029] Take the i-th row data of the combined embedding C embed as the representation of node i, denoted as c i ; the center of cluster j is denoted as μ j , and s ij represents the degree to which node i is assigned to cluster j:

[0030]

[0031] where ||·|| represents the negative cosine similarity, and β is the inverse temperature hyperparameter; randomly initialize μ, and optimize μ by alternating iterations of s ij and μ j :

[0032]

[0033] Among them, K represents the number of clustering centers, which is also the number of nodes after pooling. After repeated iteration, the node assignment matrix S is obtained.

[0034] Preferably, the pooled node feature matrix X pool , the pooled adjacency matrix A pool and the topological matrix The specific content includes:

[0035]

[0036] Among them, X pool ∈R K×f The x in i,j represents the sum of the scores assigned to cluster i multiplied by the j - dimensional features of all elements. is the pooled weighted adjacency matrix, where a ii represents the weighted sum of the edges inside the clustering center i, and a ij represents the weighted sum of the edges between the clustering center i and the clustering center j; I K represents the identity matrix.

[0037] Preferably, the construction of the loss function The specific content includes:

[0038] The cut loss term is:

[0039]

[0040] Among them, D is the degree matrix;

[0041] Evaluate minCUT based on the node assignment matrix S, and the value range is I K represents the identity matrix, and K is the number of clustering centers;

[0042] The orthogonality loss term

[0043]

[0044] Among them, W v =(w1, w2, …, w n ) T W i represents the weight value of node i, and ||·|| F represents the Frobenius norm;

[0045] Clustering loss term

[0046]

[0047] Among them, KL represents the KL divergence, Q represents the similarity matrix between nodes, which is obtained by calculating the distance between the node embedding representation and the clustering center; P represents a probability matrix, which is used to represent the probability that a node is assigned together with other nodes; the sizes of matrices Q and P are both n×n, where n represents the number of nodes, and q ij represents the similarity between the clustering centers corresponding to node i and node j, and p ij represents the probability that node i is assigned to the cluster center corresponding to node j;

[0048] Reconstruction loss term

[0049]

[0050] Reconstruction loss term Used to evaluate the topological matrix reconstructed by decoding the embedding vector and the true topological matrix between the differences.

[0051] A classification method for a popular science material classifier, including the following steps:

[0052] Set the value of the number of clustering centers K, and input the graph structure corresponding to the popular science material to be classified into the WGDPool network for training until the loss function converges, obtain the node assignment matrix S, and use the node assignment matrix S as the classification result.

[0053] A retrieval method for a popular science material classifier, including the following steps:

[0054] Set the value of the number of clustering centers K, construct the candidate popular science material into a graph structure as the original graph structure, and randomly initialize a popular science material node as an inserted node and insert it into the original graph structure to form a new graph structure G', input G' into the WGDPool network for training until the loss function converges, and obtain the trained WGDPool network;

[0055] Convert the popular science material to be retrieved into node features as the target node, and replace the inserted node in G' with the target node to form a new graph structure G”, reset the value of K, and input G” into the trained WGDPool network to obtain the node assignment matrix S’, and the popular science materials assigned to the same cluster as the popular science material to be retrieved are the retrieval results.

[0056] A popular science material classification device, including the following content:

[0057] The WGDPool network includes a dual-branch ConvGNN unit and a differentiable k-means unit. The dual-branch ConvGNN unit obtains the node embedding X and the edge embedding A embed for the combined embedding C embed where the node feature matrix X ∈ R embed , the topological structure matrix n×d , the weighted adjacency matrix A ∈ R , R is the set of real numbers, n represents the number of nodes, d is the dimension of node features, and the differentiable k-means unit is used to perform clustering sampling on C n×n to obtain the node assignment matrix S, and the node assignment matrix S is used as the classification result; embed

[0058] The loss function construction module is used to construct the loss function

[0059]

[0060] where is the cut loss term, is the orthogonality loss term, is the clustering loss term, is the reconstruction loss term, and λ, μ, η, and ξ are all adjustable parameters.

[0061] Through the above technical solutions, compared with the prior art, the present invention discloses a classification and retrieval method and device based on a popular science material classifier, having the following beneficial effects:

[0062] The present invention cleverly integrates the node features, topological structure, and edge weight information of the weighted graph through the dual-branch CovnGNN architecture, and can obtain a more informative graph representation. Traditional node clustering pooling only uses simple MLP or Softmax operations in node clustering, and has limited performance in aggregating similar nodes. However, the present invention pools together nodes with similar node representations in space by introducing a differentiable version of k-means. The closer the node representations are in space, the higher the probability that they belong to the same class. Therefore, introducing a differentiable version of k-means is beneficial to node clustering. In the design of the loss function, the loss function of the present invention is linearly composed of four loss terms, including the cut loss term, the orthogonality loss term, the clustering loss term, and the reconstruction loss term. This can adjust the parameters in front of the four loss terms according to the complexity of the graph structure and the diversity of the tasks. Brief Description of the Drawings

[0063] ​To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the accompanying drawings required in the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description are only some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other accompanying drawings can be obtained based on these drawings.

[0064] Figure 1 Schematic diagram of the WGDPool network structure provided by the embodiment of the present invention. Specific implementation manners

[0065] The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, rather than all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts belong to the scope protected by the present invention.

[0066] The present invention provides a method for constructing a popular science material classifier, including the following steps:

[0067] Construct a WGDPool network:

[0068] Construct a dual-branch ConvGNN unit and a differentiable k-means unit respectively. The dual-branch ConvGNN unit obtains the combined embedding C of the node embedding X and the edge embedding A embed according to the graph structure, where the node feature matrix X ∈ R embed , the topological structure matrix embed , the weighted adjacency matrix A ∈ R n×d , R is the set of real numbers, n represents the number of nodes, d is the dimension of the node features, and the differentiable k-means unit is used to perform clustering sampling on C to obtain the node assignment matrix S, and use the node assignment matrix S as the classification result; n×n embed

[0069] Construct a loss function

[0070]

[0071] where is the cutting loss term, is the orthogonality loss term, is the clustering loss term,

[0072] is the reconstruction loss term, and λ, μ, η, and ξ are all adjustable parameters.

[0072] It should be noted that:

[0073] In order to classify and retrieve popular science materials, the popular science materials need to be first converted into a graphical form. The popular science materials are encoded into node features X. For example, text popular science materials can be converted into node features X through text vectorization methods. The connections between popular science materials are converted into edges between popular science materials. For example, if there is the same topic label between popular science materials, there is an edge, thus obtaining a topological structure The edge weight value is set to the number of same topic labels, thus obtaining a weighted adjacency matrix A. Such a graph can be used as the input of WGDPool.

[0074] ConvGNN is an operation that generalizes convolutional operations from grid data to graph data and is used to learn graph representations, such as Graph Convolutional Networks (GCN), Graph SAmple and aggreGatE (GraphSAGE), etc.

[0075] Loss function The reason for setting λ, μ, η, and ξ in it is that the importance of each loss function for different tasks is different. In the actual application process, the node clustering task requires more Then the value of η can be increased. The graph partitioning task only requires and Then the values of η and ξ are set to 0. Those skilled in the art can set the above adjustable parameters according to needs.

[0076] To further implement the above technical solution, the content of constructing a dual-branch ConvGNN unit specifically includes:

[0077] Construct a first ConvGNN, a second ConvGNN, and a Concat module;

[0078] The first ConvGNN is used to generate node embedding X according to X and , and the second ConvGNN is used to generate edge embedding A according to A and embed : embed :

[0079]

[0080] where Θ ConvGNN and β ConvGNN are respectively the trainable parameters in the first ConvGNN and the second ConvGNN, X embed ∈R n×a , A embed ∈R n×b ; ​

[0081] The Concat unit is used to concatenate X embed and A embed to obtain the combined embedding C embed :

[0082] C embed = Concat(X embed , A embed )

[0083] where C embed ∈R n×(a+b) .

[0084] It should be noted that:

[0085] X embed and A embed vary in importance depending on the task, so the output dimensions of X embed and A embed can be changed for different tasks. For example, in the node clustering task, more attention is paid to node features, and we can increase the output dimension of X embed , that is, increase the value of a. The graph partitioning task requires edge weight information more than other tasks, so the output dimension of A embed can be increased, that is, increase the value of b.

[0086] The combined embedding C embed obtained through the Concat unit integrates node features, topological structure, and edge weight information.

[0087] To further implement the above technical solution, the specific content of constructing the differentiable k-means unit includes:

[0088] Taking the i-th row data of the combined embedding C embed as the representation of node i, denoted as c i ; the center of cluster j is denoted as μ j , and s ij represents the degree to which node i is assigned to cluster j:

[0089]

[0090] where ||·|| represents negative cosine similarity, and β is the inverse temperature hyperparameter; randomly initialize μ, and optimize μ by alternately iterating s ij and μ j :

[0091]

[0092] where K represents the number of clustering centers, which is also the number of nodes after pooling, and the node assignment matrix S is obtained through repeated iteration.

[0093] It should be noted that:

[0094] Many studies have observed that the distance between nodes in the low-dimensional representation space reflects their similarity in the original graph. Therefore, nodes that are closer in the representation space are considered more similar, and they are more likely to belong to the same class. In the case of downsampled graph representations, clustering nodes with similar representations to form a new node can reduce the impact of noise and redundant information. Since k-means clusters based on spatial distance, the present invention uses a differentiable version of the k-means clustering algorithm to cluster similar nodes. The reason for using the differentiable version of k-means is to be able to train together with a neural network.

[0095] In the traditional k-means algorithm, s ij is a binary value, but the differentiable version of k-means clustering relaxes it to a fractional value to satisfy ∑ j s ij = 1 for all i. Specifically, it uses a soft minimum assignment method based on the distance between nodes and cluster centers.

[0096] To further implement the above technical solution, obtaining the pooled node feature matrix X pool , the pooled adjacency matrix A pool and the topological matrix specifically includes:[[]]

[0097]

[0098] where x pool ∈R K×f in X i,j represents the sum of the scores assigned to cluster i multiplied by the j-th dimensional feature of all elements, is the pooled weighted adjacency matrix, where a ii represents the weighted sum of the edges inside cluster center i, and a ij represents the weighted sum of the edges between cluster center i and cluster center j; I K represents the identity matrix.

[0099] It should be noted that:

[0100] The calculation method of is the same as that of , the difference is that is obtained from the topological matrix and The self-connection is stronger than other connections, but a strong self-connection is not conducive to the propagation of adjacent nodes. Therefore, by setting their diagonal elements to 0, the final pooled adjacency matrix A is obtained pool and the topological matrix

[0101] To further implement the above technical solution, a loss function is constructed The specific content of which includes:

[0102] The cut loss term is:

[0103]

[0104] where D is the degree matrix;

[0105] Evaluate minCUT based on the node assignment matrix S, and the value range is I K represents the identity matrix, and K is the number of cluster centers;

[0106] The orthogonality loss term

[0107]

[0108] where W v =(w1, w2,..., w n ) T , W i represents the weight value of node i, and ||·|| F represents the Frobenius norm;

[0109] The clustering loss term

[0110]

[0111] where KL represents the KL divergence, Q represents the similarity matrix between nodes, which is obtained by calculating the distance between the node embedding representation and the cluster center; P represents a probability matrix, which is used to represent the probability that a node is assigned together with other nodes; the sizes of matrices Q and P are both n×n, where n represents the number of nodes, q ij represents the similarity between the cluster centers corresponding to node i and node j, and p ij represents the probability that node i is assigned to the cluster center corresponding to node j;

[0112] The reconstruction loss term

[0113]

[0114] Reconstruction loss term Used to evaluate the topological matrix reconstructed by decoding the embedding vector And the true topological matrix The difference between them

[0115] It should be noted that

[0116] Here, I K Represents the identity matrix. By multiplying by a smaller value of 10 -5 , numerical calculation problems caused by the values on the main diagonal of the denominator elements being 0 can be avoided. Minimizing Can cluster strongly connected points in a cluster. When calculating , add I K ×10 -5 To the denominator part. Generally speaking, nodes with stronger connections are more likely to belong to the same class. Minimizing Value is beneficial to node clustering to a certain extent. It should be noted that minimizing May cause all nodes to be assigned to one cluster, which is not an ideal result. To avoid this situation, introduce As a penalty term, minimizing Encourages clusters to have similar sizes. However, minimizing Although beneficial to node clustering, some nodes of the same class may not have strong connectivity. Therefore, in order to obtain more significant clustering results, node representation also needs to be considered. Therefore, in this invention, a clustering loss term

[0117] Is a loss term bound to a differentiable version of k-means. Minimizing Pools nodes with similar feature spaces together, compensating for the limitation that Cannot consider node representation

[0118] Reconstruction loss Is used to evaluate the difference between the topological matrix reconstructed by decoding the embedding vector And the true topological matrix Regarding the predicted topological matrix And the actual topological matrix As a binary classification problem, binary cross-entropy is used as the loss function to measure the difference between the predicted value and the real value

[0119] Minimizing the reconstruction loss Makes the topology obtained by decoding the embedding vector closer to the actual topology. This helps to ensure that the graph representation accurately reflects the topological information of the original graph. The graph representation provides a more accurate representation of the original graph information and plays a positive role in clustering during the subsequent pooling process

[0120] A classification method for popular science material classifiers, comprising the following steps:

[0121] Set the value of the number of clustering centers K, and input the graph structure corresponding to the popular science materials to be classified into the WGDPool network for training until the loss function converges, obtaining the node assignment matrix S, and taking the node assignment matrix S as the classification result.

[0122] A retrieval method for popular science material classifiers, comprising the following steps:

[0123] Set the value of the number of clustering centers K, construct the candidate popular science materials into a graph structure as the original graph structure, and randomly initialize a popular science material node as an inserted node and insert it into the original graph structure to form a new graph structure G', and input G' into the WGDPool network for training until the loss function converges, obtaining the trained WGDPool network;

[0124] Convert the popular science materials to be retrieved into node features as the target node, and replace the inserted node in G' with the target node to form a new graph structure G”, reset the value of K, and input G” into the trained WGDPool network, obtaining the node assignment matrix S’, and the popular science materials classified into the same cluster as the popular science materials to be retrieved are the retrieval results.

[0125] A popular science material classification device, comprising the following:

[0126] The WGDPool network, including a dual-branch ConvGNN unit and a differentiable k-means unit, the dual-branch ConvGNN unit obtains the node embedding X embed and the edge embedding A embed combined embedding C embed , where the node feature matrix X ∈ R n×d , the topological structure matrix weighted adjacency matrix A ∈ R n×n , R is the set of real numbers, n represents the number of nodes, d is the dimension of the node features, and the differentiable k-means unit is used to perform clustering sampling on C embed to obtain the node assignment matrix S, and taking the node assignment matrix S as the classification result;

[0127] The loss function construction module is used to construct the loss function

[0128]

[0129] Among them, is the cutting loss term, is the orthogonality loss term, is the clustering loss term, is the reconstruction loss term, and λ, μ, η, and ξ are all adjustable parameters.

[0130] First, the present invention introduces edge weight information as an additional input to WGDPool; edge weight information is an important part of weighted graph information. The present invention proposes a dual-branch ConvGNN structure, which obtains a node embedding and an edge embedding respectively, and then combines them to form a graph representation. This graph representation integrates node features, topological structure, and edge weight information, representing the original graph more comprehensively and meeting the requirements of various graph tasks.

[0131] Second, the present invention introduces a differentiable version of k-means to generate the assignment matrix of nodes in WGDPool. When generating the assignment matrix of nodes, traditional node clustering pooling methods only involve simple MLP or Softmax operations. However, the differentiable version of k-means further combines the spatial distance of node representations, enabling nodes to be clustered based on their distances in space.

[0132] Finally, the present invention designs a parametric multi-loss function to optimize the pooling result. The loss terms include a cut loss term, an orthogonality loss term, a clustering loss term, and a reconstruction loss term. The cut loss term aims to group strongly connected nodes together, the orthogonality loss term aims to balance the number of nodes in a cluster, the clustering loss term helps aggregate node representations of nodes with similar spatial distances, and the reconstruction loss term encourages learning a better graph representation that reflects the topology of the original graph. The parameters of each loss term are adjusted for different graph tasks.

[0133] The above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that: they can still modify the technical solutions recorded in the foregoing embodiments, or perform equivalent replacements for some of the technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the various embodiments of the present application, and should all be included in the protection scope of the present application.

Claims

1. A classification and retrieval method based on a popular science material classifier, characterized in that: The following steps are involved: Building the WGDPool network: Construct a dual-branch ConvGNN unit and a differentiable k-means unit respectively. The dual-branch ConvGNN unit is based on the graph structure. Get node embedding X embed and edge embedding A embed The combination of embedded C embed , where the popular science materials are encoded into node features X, and the connections between the popular science materials are converted into edges between the popular science materials, thus obtaining the topological structure The edge weights are set to the same number of topic labels, that is, the weighted adjacency matrix A is obtained, and the node feature matrix X∈R n×d , topological matrix Weighted adjacency matrix A∈R n×n , R is a set of real numbers, n represents the number of nodes, d is the dimension of node features, and the differentiable k-means unit is used to C embed Perform cluster sampling to obtain the node allocation matrix S, and use the node allocation matrix S as the classification result; Constructing the loss function in, is the cutting loss term, is the orthogonality loss term, is the clustering loss term, is the reconstruction loss term, λ, μ, η and ξ are all adjustable parameters; The classification method based on the popular science material classifier includes the following steps: setting the value of the number of cluster centers K, and dividing the graph structure corresponding to the popular science material to be classified into Input into the WGDPool network for training until the loss function converges, and obtain the node allocation matrix S, which is used as the classification result; The retrieval method based on the popular science material classifier includes the following steps: Set the number of cluster centers K, construct the candidate science popularization materials into a graph structure as the original graph structure, and randomly initialize a science popularization material node as an insertion node to insert into the original graph structure to form a new graph structure G'. Input G' into the WGDPool network for training until the loss function converges, and obtain the trained WGDPool network; The popular science materials to be retrieved are converted into node features as target nodes, and the target nodes replace the inserted nodes in G' to form a new graph structure G", reset the value of K, and input G" into the trained WGDPool network to obtain the node allocation matrix S'. The popular science materials that are divided into the same cluster as the popular science materials to be retrieved are the retrieval results.

2. A classification and retrieval method based on a popular science material classifier according to claim 1, characterized in that: The contents of building a dual-branch ConvGNN unit specifically include: Construct the first ConvGNN, the second ConvGNN and the Concat module; The first ConvGNN is used to calculate the Generate node embedding X embed , the second ConvGNN is used according to A and Generate edge embedding A embed : where Θ ConvGNN and β ConvGNN are the trainable parameters in the first ConvGNN and the second ConvGNN, respectively, embed ∈R n ×a , A embed ∈R n×b ; The Concat unit is used to convert X embed and A embed Connect and get the combined embedding C embed : C embed =Concat(X embed ,A embed ) Among them C embed ∈R n×(a+b) .

3. The classification and retrieval method based on a popular science material classifier according to claim 1, characterized in that: The specific contents of constructing a differentiable k-means unit include: Embed the combination into C embed The i-th row data is used as the representation of node i, denoted as c i ; The center of cluster j is denoted as μ j , s ij represents the degree to which node i is assigned to cluster j: where ||·|| represents the negative cosine similarity, β is the inverse temperature hyperparameter; μ is randomly initialized and s is used to calculate the negative cosine similarity. ij With μ j Alternate iterations to optimize μ: Where K represents the number of cluster centers, which is also the number of nodes after pooling. The node allocation matrix S is obtained through repeated iterations.

4. The classification and retrieval method based on a popular science material classifier according to claim 1, characterized in that: Obtain the pooled node feature matrix X according to the node allocation matrix S pool , pooled adjacency matrix A pool and topological matrix The specific contents include: where X pool ∈R K×f x in i,j represents the sum of the j-th dimension features of all elements multiplied by the scores assigned to cluster i, is the weighted adjacency matrix after pooling, where a ii represents the weighted sum of the internal edges of cluster center i, a ij represents the weighted sum of the edges between cluster center i and cluster center j; I K Represents the identity matrix.

5. The classification and retrieval method based on a popular science material classifier according to claim 1, characterized in that: Constructing the loss function The specific contents include: Cutting loss term for: Where D is the degree matrix; Based on the node allocation matrix S, minCUT is evaluated and the value range is I K represents the identity matrix, K is the number of cluster centers; Orthogonality loss term Where W v =(w1,w2,…,w n ) T , W i represents the weight value of node i, ||·|| F represents the Frobenius norm; Clustering loss Among them, KL represents KL divergence, Q represents the similarity matrix between nodes, which is obtained by calculating the distance between the node embedding representation and the cluster center; P represents a probability matrix, which is used to represent the probability of a node being assigned with other nodes; the size of the matrices Q and P is nxn, where n represents the number of nodes and q ij represents the similarity between the cluster centers corresponding to node i and node j, p ij represents the probability that node i is assigned to the cluster center corresponding to node j; Reconstruction loss Reconstruction loss Used to evaluate the topology matrix reconstructed by decoding the embedding vector With the real topological matrix The difference between.

6. A classification device based on a popular science material classifier, based on the classification and retrieval method based on a popular science material classifier according to any one of claims 1 to 5, characterized in that: Includes the following: WGDPool network, including dual-branch ConvGNN unit and differentiable k-means unit, dual-branch ConvGNN unit according to the graph structure Get node embedding X embed and edge embedding A embed The combination of embedded C embed , where the node feature matrix X∈R n×d , topological matrix Weighted adjacency matrix A∈R n×n , R is a set of real numbers, n represents the number of nodes, d is the dimension of node features, and the differentiable k-means unit is used to C embed Perform cluster sampling to obtain the node allocation matrix S, and use the node allocation matrix S as the classification result; Loss function building module, used to build loss function in, is the cutting loss term, is the orthogonality loss term, is the clustering loss term, is the reconstruction loss term, and λ, μ, η, and ξ are all adjustable parameters.

Citation Information

Patent Citations

  • Object classification method and device, electronic equipment and storage medium

    CN115130554A

  • Sample classification method, apparatus and device, and computer readable storage medium

    CN116127386A