A molecular classification method based on heterogeneous graph embedding

By combining simplex structure modeling and hashing algorithms, the problem of high computational overhead in heterogeneous graph embedding methods for capturing high-order interaction information is solved, achieving efficient molecular classification and making it suitable for heterogeneous graph embedding of large-scale molecular graphs.

CN120355989BActive Publication Date: 2025-12-12CENT SOUTH UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510430570.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-04-08
Publication Date
2025-12-12
Estimated Expiration
2045-04-08

AI Technical Summary

Technical Problem

Existing heterogeneous graph embedding methods are difficult to effectively capture high-order interaction information, have limitations in heterogeneous information modeling, and have high computational costs, making them unsuitable for the efficient modeling needs of large-scale molecular graphs.

Method used

A method combining simplex structure modeling and hashing algorithms is adopted. By extracting the simplex and calculating the Hodge Laplacian matrix, local and global information enhancement operators are constructed. Combined with locality-sensitive hashing algorithm for iterative updates, graph-level embeddings are generated.

Benefits of technology

It effectively captures high-order interaction information and heterogeneous features of molecular structures, improves computational efficiency, reduces computational resource consumption, and is suitable for classification tasks of large-scale molecular maps.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120355989B_ABST
    Figure CN120355989B_ABST
Patent Text Reader

Abstract

The application provides a molecular classification method based on heterogeneous graph embedding, and belongs to the technical field of molecular classification; comprising: simplex extraction on a heterogeneous graph; processing structural information of the heterogeneous graph based on the extracted simplex to obtain a local and global information enhancement operator; processing feature information of the heterogeneous graph based on the extracted simplex to obtain a feature matrix; performing hash iteration on the heterogeneous graph based on the local and global information enhancement operator and the feature matrix to obtain graph-level embedding; and performing molecular classification on the graph-level embedding to obtain a molecular classification result. By combining simplex and hash algorithm, the application can effectively capture high-order interaction information and heterogeneous features, significantly improve the calculation efficiency, and provide an efficient and scalable solution for heterogeneous graph analysis.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The application belongs to the technical field of molecular classification, and relates to a molecular classification method based on heterogeneous graph embedding. BACKGROUND

[0002] Molecular classification is an important research direction in the field of bioinformatics, and is widely used in many fields such as drug design, environmental science and material science. By accurately classifying the activity or function of a compound, it not only helps to accelerate the process of new drug discovery and screening, but also has important value in practical applications such as disease diagnosis and toxicity prediction. In practical applications, molecules are often in the form of a graph structure, where nodes represent different types of atoms and edges represent chemical bonds between atoms. In order to achieve molecular classification, it is necessary to encode the molecular graph into a fixed-length feature vector while retaining its key structural and attribute information. Since the molecular graph contains multiple types of nodes and edges, it can be modeled as a heterogeneous graph, and the heterogeneous graph embedding method can be used to convert it into a low-dimensional representation, thereby supporting downstream classification tasks.

[0003] However, existing heterogeneous graph embedding methods still face the following challenges:

[0004] (1) Difficulty in capturing high-order interaction information: Most methods only consider the direct connection relationship between nodes and edges, and are difficult to model the high-order topological structure (such as triangles, tetrahedrons, etc.) in the graph, resulting in insufficient expression ability for complex structural information.

[0005] (2) Limitations in modeling heterogeneous information: The types of nodes and edges in a heterogeneous graph are rich, and these heterogeneous features are crucial for understanding molecular structure. However, existing methods often rely on manually defined meta-paths or meta-graph structures, limiting the flexibility and generalization ability of the model.

[0006] (3) High computational overhead: The graph neural network-based heterogeneous graph embedding methods (such as HGNNs) that have emerged in recent years have certain expression ability, but they rely on a large number of parameters for training and require weight optimization through backpropagation, resulting in high computational and storage resource consumption, making it difficult to adapt to the efficient modeling needs of large-scale molecular graphs. SUMMARY

[0007] To solve the above problems, the present application aims to provide a molecular classification method based on heterogeneous graph embedding that combines the modeling ability of simplex structure and the efficiency of hash algorithm, to effectively capture high-order interaction information and heterogeneous features in molecular structure, while balancing embedding efficiency and model scalability, providing an efficient and practical solution for molecular classification.

[0008] The present application provides a molecular classification method based on heterogeneous graph embedding, comprising the following steps:

[0009] Step one, simplex extraction is performed on the heterogeneous graph g;

[0010] Based on the extracted simplex, the structure information of the heterogeneous graph g is processed to obtain the local and global information enhancement operator N k ;

[0011] Based on the extracted simplex, the feature information of the heterogeneous graph g is processed to obtain the feature matrix

[0012] Step two, based on the local and global information enhancement operator N k and the feature matrix Hash iteration is performed on the heterogeneous graph g to obtain the graph-level embedding x g ;

[0013] Step three, the graph-level embedding x g is classified to obtain the molecular classification result.

[0014] Further, the heterogeneous graph g is derived from the known TUDataset molecular heterogeneous graph dataset, and the molecular heterogeneous graph dataset contains multiple types of heterogeneous graphs g.

[0015] Further, the specific process of simplex extraction on the heterogeneous graph g is as follows:

[0016] All nodes in the node set V in the heterogeneous graph g are taken as the 0-dimensional simplex, and the 0-dimensional simplex set S0 is added, S0 contains all 0-simplices;

[0017] All edges in the edge set E in the heterogeneous graph g are taken as the 1-dimensional simplex, and the 1-dimensional simplex set S1 is added, S1 contains all 1-simplices;

[0018] The simplex set S0 and the simplex set S1 are used to initialize the Simplex tree, and the expansion method in the Simplextree is used to recursively expand from the 2-dimensional simplex, and the higher dimensional simplex is obtained by layer-by-layer expansion until the maximum dimension K is reached, so as to extract the 2-dimensional simplex to the K-dimensional simplex, and obtain S2,…,S K , S2,…,S K are the 2-dimensional to K-dimensional sets respectively.

[0019] Further, the specific process of obtaining the local and global information enhancement operator N k is as follows:

[0020] The Laplacian matrix L k corresponding to the k-dimensional simplex set S k , k∈{0,1,…,K};

[0021] Based on the Hodge Laplacian matrix L k , a local information enhancement operator M k is constructed.

[0022] Based on the local information enhancement operator M k , a local and global information enhancement operator N k is further constructed.

[0023] Further, the specific process of obtaining the feature matrix is as follows:

[0024] A zero matrix of size |S k |×|T v | is created.

[0025] Each k-simplex in S k is traversed to construct the heterogeneous information vector of all nodes contained therein.

[0026] Each k-simplex in S k is traversed to perform element-wise logical OR operation on the heterogeneous information vectors of all nodes contained therein, to obtain a binary vector of length |T v | as the feature vector of .

[0027] The feature vector of each k-simplex is filled into the zero matrix to obtain the feature matrix from the 0th dimension to the maximum dimension K.

[0028] Further, the specific process of obtaining the graph-level embedding x g is as follows:

[0029] (i) Initialization;

[0030] Let r = 1, k = 0. Wherein: r represents the rth iteration, and k represents the k-dimensional simplex.

[0031] (ii) Iteration loop condition judgment;

[0032] Condition: if r≤R, then step (iii) is executed; otherwise, jump to step (vi).

[0033] (iii) Simplex dimension loop condition judgment;

[0034] Condition: if k≤K, then step (iv) is executed; otherwise, jump to step (vi).

[0035] (iv) Temporary feature matrix calculation;

[0036] Computing the temporary feature matrix of the k-simplex in the rth iteration

[0037]

[0038] wherein: is the feature matrix of the k-simplex after the r-1th iteration; W (r-1,k) is a random hash function matrix used to update ;

[0039] (v), sign operation;

[0040] Applying the sign operation sgn to the temporary feature matrix converts each element of into a binary hash code to obtain the updated feature matrix

[0041] The expression of the updated feature matrix is as follows:

[0042]

[0043] (vi), updating the simplex dimension to k';

[0044] Increase k by 1, i.e. k' = k + 1.

[0045] Jump back to step (iii);

[0046] (vi), updating the iteration number to r';

[0047] Increase r by 1, i.e. r' = r + 1.

[0048] Reset k = 0;

[0049] Jump back to step (ii);

[0050] (vii), generating the graph-level embedding x g ;

[0051] Flatten the final simplex feature matrix into vectors respectively, and then concatenate them to obtain the graph-level embedding x g .

[0052] Further, the specific process of molecular isomerism graph classification on the graph-level embedding x g is as follows:

[0053] S3.1, perform a NOT operation on each binary bit of x g , i.e. convert 0 to 1 and convert 1 to 0, to obtain the flipped vector flip(x g );

[0054] S3.2, the original vector x g and the flipped vector flip(x g ) are concatenated into a 2L-dimensional extended vector x e ;

[0055] S3.3, x e is input into a logistic regression classifier for classification.

[0056] Specifically, given x g =[1, 0, 1], flip(x g )=[0, 1, 0], and after concatenation, x e =[1, 0, 1, 0, 1, 0], the final input is the logistic regression classifier for classification.

[0057] Wherein: flip(x g ) is the vector x g after bit inversion; x e is the extended 2L-dimensional vector obtained by .

[0058] Compared with the prior art, the present application has the following beneficial effects:

[0059] (1) The present application proposes a molecular classification method based on heterogeneous graph embedding. The method first preprocesses the heterogeneous graph data, extracts simplices and calculates the corresponding Hodge Laplacian matrix, and then performs element-level multiplication and second-order operation on the Hodge Laplacian matrix to construct local and global graph structure information enhancement operators. At the same time, the simplex features are initialized based on simplices and heterogeneous information. Next, through the local and global information enhancement operator, the simplex features are iteratively updated using the random hash algorithm. Finally, the simplex features of different dimensions obtained by the last iteration are vectorized respectively, and the final heterogeneous graph graph-level embedding is generated through feature concatenation operation. The embedding can be used for downstream tasks such as graph classification. This method effectively integrates the high-order topological information of heterogeneous graph structure and the efficient characteristics of hash algorithm, and provides an effective framework for heterogeneous graph analysis.

[0060] (2) The present application combines simplices and hash algorithm, which not only effectively captures high-order interaction information and heterogeneous features, but also significantly improves the computing efficiency, providing an efficient and scalable solution for heterogeneous graph analysis.

[0061] (3) In the graph embedding of the molecular isomerism graph, the method is based on a message passing mechanism, combines a local and global information enhanced operator, and introduces a random hash algorithm for optimization. Traditional Heterogeneous Graph Neural Networks (HGNNs) rely on a large number of trainable parameters, and the weight is updated through back propagation, which is complex in calculation and prone to overfitting, especially in processing large-scale molecular graph data. The local sensitive hash function is used to replace the nonlinear activation function in the message passing process of the traditional HGNNs method, and the randomly generated hash mapping is used to replace the parameter learning process, which effectively reduces the consumption of computing resources and improves the embedding efficiency of the model in the large-scale molecular graph scene.

[0062] (4) The method has been verified by experiments, and has high accuracy and calculation efficiency in the molecular graph classification task based on heterogeneous graph embedding.

[0063] In addition to the purposes, features and advantages described above, the present application has other purposes, features and advantages. The present application will be further described below with reference to the drawings. BRIEF DESCRIPTION OF DRAWINGS

[0064] The accompanying drawings, which form a part of this application, are included to provide a further understanding of the application, illustrate the preferred embodiments of the application, and assist in explaining the application. In the drawings:

[0065] Figure 1 is a flowchart of a molecular classification method based on heterogeneous graph embedding in an embodiment of the present application. DETAILED DESCRIPTION

[0066] In order to make the above-mentioned purposes, features and advantages of the present application more clear and easy to understand, the specific embodiments of the present application will be described in detail below with reference to the drawings. It should be noted that the drawings of the present application are simplified and use non-accurate proportions, and are only used to facilitate and clearly assist in explaining the embodiments of the present application; the numbers mentioned in the present application are not limited to the specific numbers in the examples of the drawings; the directions or positions mentioned in the present application, such as 'front','middle', 'back', 'left', 'right', 'top', 'bottom', 'top', 'bottom','middle', etc., are all based on the directions or positions shown in the drawings of the present application, and do not indicate or imply that the devices or parts referred to must have a specific direction, nor can it be understood as a limitation of the present application.

[0067] Embodiment:

[0068] Referring to Figure 1 As shown in the drawings, the present application proposes a molecular classification method based on heterogeneous graph embedding, which is used to efficiently complete the molecular graph embedding and classification task; it includes the following steps:

[0069] Step one, data preprocessing.

[0070] Existing heterogeneous graph embedding methods mainly model the direct binary relationship of nodes and edges, or rely on predefined meta-paths, meta-graphs and other substructures, which are difficult to effectively capture high-order interaction features in the graph, resulting in limited model effectiveness. To this end, the simplex is introduced to model the high-order interaction relationship in the heterogeneous graph by capturing high-order topological structures (such as triangles and tetrahedrons). Heterogeneous graphs contain rich heterogeneous semantic information, which is crucial for graph embedding. Therefore, in the data preprocessing stage, the simplex is extracted to capture high-order interactions, and the heterogeneous information is integrated into the simplex, so as to better preserve the structural properties and semantic features of the graph.

[0071] The data used in the present application is derived from the molecular heterogeneous graph dataset in TUDataset. TUDataset is a public graph dataset collection, which contains various types of heterogeneous graph datasets, covering chemical molecules, social networks, biological networks and other fields. In the molecular heterogeneous graph dataset, each heterogeneous graph corresponds to a specific molecular compound.

[0072] Specifically, the heterogeneous graph g is represented as:

[0073] g=(V,E);

[0074] Wherein, V is the node set of the heterogeneous graph g, corresponding to the atoms in the molecular compound, |V| is the total number of nodes in the node set V; E is the edge set of the heterogeneous graph g, corresponding to the chemical bond connection relationship between atoms, |E| is the total number of edges in the edge set E; T v is the node type set, |T v | is the number of types in the node type set, v is any node in the heterogeneous graph g, v∈V; t v is the type label of any node v, t v ∈T v , t v exists in the form of an integer.

[0075] Specifically, the specific process of preprocessing the heterogeneous graph g is as follows:

[0076] S1.1, simplex extraction;

[0077] S1.2, processing the extracted simplex based on its structure information and feature information.

[0078] Further, simplex is a basic concept in topology data analysis, which is used to describe geometric structure in high-dimensional space. The present application uses Simplex tree data structure (Simplex tree is an existing data structure, which represents simplex and its containing relationship through tree structure, and supports fast insertion, query and traversal of simplex) to extract simplex set {S0, S1, …, S k ,…S K} from input heterogeneous graph g=(V, E) in the following way:

[0079] Input: node set V, edge set E of heterogeneous graph g and maximum dimension K of simplex.

[0080] Output: simplex set {S0, S1, …, S k ,…S K};

[0081] Wherein: S0 is the 0-dimensional simplex set, containing all 0-simplices; S1 is the 1-dimensional simplex set, containing all 1-simplices; S k is the k-dimensional simplex set, containing all k-simplices, k∈{0, 1, …, K}; S K is the simplex set of maximum degree K, containing all K-simplices.

[0082] Further, the specific process of simplex extraction is as follows:

[0083] All nodes in node set V are taken as 0-dimensional simplex and added to S0 set;

[0084] All edges in edge set E are taken as 1-dimensional simplex and added to S1 set;

[0085] S0 set and S1 set are used to initialize Simplex tree, and expansion method in Simplex tree is used to recursively expand from 2-dimensional simplex, layer by layer, to obtain higher-dimensional simplex, until maximum dimension K is reached, to extract 2-dimensional simplex to K-dimensional simplex (i.e. S2, …, S K ).

[0086] In the present application, the extraction of simplex set {S0, S1, …, S k ,…S K} from 0-dimensional to maximum dimension K is realized through the above specific process, so as to extract simplices of different dimensions from heterogeneous graph g.

[0087] Further, the k-dimensional simplex set S kFor example, the specific process of structural information processing (i.e. constructing local and global information enhancement operators) on the heterogeneous graph g is as follows:

[0088] ①, calculate the Laplacian matrix L corresponding to the k-dimensional simplex set k ;

[0089] The expression of the Laplacian matrix L k is as follows:

[0090]

[0091] Wherein: is the boundary operator of the k-dimensional simplex, is the transpose of ; is the boundary operator of the k+1-dimensional simplex, is the transpose of .

[0092] In actual calculation, is usually represented by the matrix B k . Define |S k | as the number of k-simplices in the simplex set S k , then |S k-1 | is the number of (k-1)-simplices in the simplex set S k-1 ; define as the jth k-simplex in the simplex set S k ; define as the ith (k-1)-simplex in the simplex set S k-1 ; then the dimension of the matrix B k is |S k-1 |×|S k |, and the expression of the matrix B k is as follows:

[0093]

[0094] Wherein: B k (y,z) is the value of the yth row and zth column in the matrix B k .

[0095] Special note: the characters y and z in B k (y,z) here strictly correspond to the subscript indexes of and , respectively.

[0096] ②, in order to mine more potential information, the present application processes the Laplacian matrix L kFurther change processing is carried out, and an operator construction method of local and global information enhancement is proposed, which is as follows:

[0097] Based on the Hodge Laplacian matrix L k , a local information enhancement operator M k is constructed;

[0098] The expression of the local information enhancement operator M k is as follows:

[0099] M k = L k ⊙L k ;

[0100] Where: ⊙ is an element-level product.

[0101] In the k-simplex and its Hodge Laplacian matrix L k , the local information is defined by the information of each k-simplex itself and its adjacency relationship. The element-level product ⊙ performs nonlinear amplification on each element of L k , which not only enhances the information of a single k-simplex (represented by the diagonal elements of L k ), but also strengthens the adjacency relationship between k-simplices (represented by the non-diagonal elements of L k ). This operation enhances the distinguishability of local information by expanding existing differences to different degrees. This improvement provides more rich local structure information for subsequent graph embedding learning.

[0102] On the basis of the local information enhancement operator M k , a local and global information enhancement operator N k is further constructed;

[0103] The expression of the local and global information enhancement operator N k is as follows:

[0104] N k = (M k ) 2 .

[0105] The global information of a heterogeneous graph involves high-order connection information between k-simplices. The Hodge Laplacian matrix L k cannot directly preserve this information because its corresponding non-diagonal elements are zero. Even after the local information enhancement operator M k is obtained by applying the element-level product, this limitation still exists. By performing a second-order operation on the local information enhancement operator M k , M kThe transformation of zero off-diagonal elements into non-zero values ​​indicates the extraction of certain higher-order connections. Second-order operations further enhance the discriminability of global information by more significantly amplifying strong connections and important information, thereby increasing the relative differences between elements.

[0106] Furthermore, in molecular isomorphic graphs, the isomorphic features of nodes and edges contain rich chemical properties and structural semantic information, which are of great significance for accurately understanding molecular structures and achieving effective graph embedding. Therefore, after extracting the simplex, this invention initializes the simplex features of each dimension based on the isomorphic type information to fully preserve the semantic structural features of the molecule and enhance the embedding expressive power.

[0107] Specifically, the set of simplexes S with the k-th dimension k For example, the method for processing feature information (i.e., simplex feature initialization) of a heterogeneous graph g is as follows:

[0108] Input: A set of simplexes {S0, S1, ..., S} k ,…S K}, the set of nodes V of the heterogeneous graph g;

[0109] Output: Obtain the feature matrices of the simplex from dimension 0 to dimension K.

[0110] Furthermore, define Let be the characteristic matrix of the k-simplex after the r-th iteration. Each row in the matrix represents an eigenvector of a k-simula. The dimension is |S k |×|T v |;To initialize the characteristic matrix of the k-simplex For example, the specific process of feature information processing (i.e., simplex feature initialization) for heterogeneous graph g is as follows:

[0111] (I) Create a space of size |S k |×|T v | zero matrix

[0112] (II) Traversing S k For each k-simula in the model, construct a heterogeneous information vector for all nodes it contains. Specifically, define... For S k The p-th k-simula in the equation, for For each node v in the array, the type label t of node v will be... v Convert it into a one-hot encoded vector, that is, a vector of length |T v | binary vector, where: only tv The corresponding index position is 1, and the rest of the positions are 0.

[0113] (Ⅲ), traverse S k Each k-simplex, construct the feature vector of each k-simplex. Specifically: take the pth k-simplex k In S , perform element-wise logical OR operation on the heterogeneous information vectors of all nodes contained in it to obtain a binary vector of length |T v | as the feature vector of .

[0114] (Ⅳ), fill in the zero matrix Specifically: fill in the feature vector of each k-simplex into the zero matrix .

[0115] In this application, by using the above steps, the features of the simplex of the 0th dimension to the Kth dimension are initialized respectively, and the feature matrix

[0116] Step 2, Hash iteration.

[0117] The existing heterogeneous graph embedding method based on heterogeneous graph neural network realizes feature learning by optimizing neural network parameters. However, this kind of method needs to frequently perform forward propagation and back propagation calculation in the training process, which leads to sharp increase of calculation complexity and growth of training time, restricting the actual application efficiency of the method. In order to improve this problem, after constructing the local and global information enhancement operator N k and initializing the simplex feature to obtain the feature matrix , the simplex feature is iteratively updated by using the local sensitive hashing technology (Locality-Sensitive Hashing, LSH).

[0118] The process of hash iteration on the heterogeneous graph g is as follows:

[0119] Input: feature matrix Local and global information enhancement operator N k and a set of randomly generated random hash functions W (r,k) for updating ; wherein, the expression of the randomly generated random hash function W (r,k) is as follows:

[0120] {W (r,k) |r∈{0,1,…,R-1},k∈{0,1,…,K}};

[0121] Where: R is the number of iterations.

[0122] Output: graph-level embedding x g .

[0123] Specifically, for the rth iteration of k-simplex, a random hash function matrix W (r,k) is generated, which has a shape of |S k | x 25. Each element of the matrix W r,k) is randomly sampled from a standard normal distribution, i.e., randomly generated. Thus, a set of random hash functions is obtained.

[0124] Preferably, the specific steps of the hash iteration on the heterogeneous graph g are as follows:

[0125] (i) initialization;

[0126] Let r = 1, k = 0. Wherein: r represents the rth iteration, and k represents the k-dimensional simplex.

[0127] (ii) iteration loop condition judgment;

[0128] Condition: if r < R, then step (iii) is executed; otherwise, jump to step (vii).

[0129] (iii) simplex dimension loop condition judgment;

[0130] Condition: if k < K, then step (iv) is executed; otherwise, jump to step (vi).

[0131] (iv) temporary feature matrix calculation;

[0132] Calculate the temporary feature matrix of the k-simplex in the rth iteration

[0133]

[0134] Wherein: is the feature matrix of the k-simplex after the (r-1)th iteration; W (r-1,k) is a random hash function matrix used to update .

[0135] (v) sign operation;

[0136] Apply the sign operation sgn (specifically, for the input element, if the element value is greater than 0, return binary 1, if the element value is less than or equal to 0, return binary 0) to the temporary feature matrix , convert each element of to a binary hash code, and obtain the updated feature matrix

[0137] The updated feature matrix The expression of x is as follows:

[0138]

[0139] (vi) updating the simplex dimension k';

[0140] k is increased by 1, that is, k' = k + 1.

[0141] Jump back to step (iii).

[0142] (vi) updating the iteration number r';

[0143] r is increased by 1, that is, r' = r + 1.

[0144] Reset k = 0.

[0145] Jump back to step (ii).

[0146] (vii) generating the graph-level embedding x g .

[0147] The final simplex feature matrix is respectively flattened into a vector, and then connected to obtain the graph-level embedding x g .

[0148] Step three, heterogeneous graph molecule classification, to obtain the molecule classification result.

[0149] In order to further verify the effectiveness and efficiency of the heterogeneous graph embedding method proposed in the application in the molecule classification task, the molecule heterogeneous graph embedding generated by the method is applied to the molecule graph classification task, and the classification accuracy and the calculation time are evaluated.

[0150] The x g obtained in step two is an L-dimensional binary hash code, which is expanded by the negation concatenation operation to obtain an L-dimensional binary hash code x g . The specific steps are as follows:

[0151] S3.1, perform negation operation on each binary bit of x g , that is, convert 0 to 1 and convert 1 to 0, to obtain the negated vector flip(x g );

[0152] S3.2, concatenate the original vector x g and the negated vector flip(x g ) to obtain a 2L-dimensional extended vector x e ;

[0153] S3.3, input x e to a logistic regression classifier for classification. For example: assuming x g= [1, 0, 1], flip(x g ) = [0, 1, 0], and the concatenated vector is x e = [1, 0, 1, 0, 1, 0], which is finally input into the logistic regression classifier for classification.

[0154] Related character definitions:

[0155] x g : L-dimensional binary hash code, representing the graph-level embedding of the heterogeneous graph g.

[0156] flip(x g ): The vector obtained by performing a bitwise XOR operation on x g .

[0157] x e : The extended 2L-dimensional vector obtained by .

[0158] Experimental examples:

[0159] In the examples, the present application selects two molecular heterogeneous graph classification datasets: the sr-ARE dataset and the nr-BIO dataset. These two datasets are used for molecular classification tasks in the field of biomedicine and have important practical significance and application value.

[0160] sr-ARE: Contains 7167 molecular graphs, where different types of nodes represent specific types of atoms, and edges represent chemical bonds between atoms. The sr-ARE dataset contains a large number of molecular graph samples, which puts higher requirements on the performance evaluation of algorithms and their performance in large-scale data processing, and helps to comprehensively evaluate the generalization ability and computational efficiency of embedding methods.

[0161] nr-BIO: The dataset contains 48542 molecular graphs, which is a large-scale molecular heterogeneous graph classification dataset. Its node and edge structure features are similar to the sr-ARE dataset, both of which construct molecular graph structures based on atom types and chemical bond information. This dataset is large in size and is suitable for evaluating the scalability and accuracy of models in large-scale molecular graph classification tasks, and has high challenges for the computational efficiency and expressiveness of embedding methods.

[0162] The process of classifying molecules using the method of the present application:

[0163] In the method of the present application, first, molecular graph data is input, which contains nodes (representing atoms) and edges (representing chemical bonds between atoms), and related isomer information. The data is preprocessed, first extracting simplices and calculating the corresponding Hodge Laplacian matrix. Next, the Hodge Laplacian matrix is processed by element-level multiplication and second-order operation to construct local and global graph structure information enhancement operators. Then, the simplex features are iteratively updated by these enhancement operators and random hash algorithms, and finally the simplex feature vectors with rich information are generated. Finally, after the feature splicing operation, the simplex features in multiple dimensions are spliced into the final isomorphic graph level embedding. After the inverse splicing expansion of the isomorphic graph embedding, it is input into the logistic regression classifier, and the classifier outputs the classification result (0 or 1) of the molecule.

[0164] The results of using the method of the present application to classify molecules of specific molecules are as follows:

[0165] For the sr-ARE data set, when the method of the present application is used for molecular classification, the logistic regression classifier outputs results of 0 or 1. The classification result 0 indicates that the molecule is not active in the antioxidant response element (ARE) stress response test, and 1 indicates that the molecule is active in the test. This classification result can help the initial screening stage in drug research and development, quickly identify compounds with potential antioxidant activity, thereby significantly improving the screening efficiency, shortening the time of drug screening, and improving the accuracy of screening.

[0166] For the nr-BIO data set, when the method of the present application is used for molecular classification, the logistic regression classifier outputs 0 or 1. The classification result 0 indicates that the molecule has low activity or no activity in the nuclear receptor signal transduction experiment, and 1 indicates that the molecule has strong activity. This result provides an important reference for drug discovery, especially in the development of drugs targeting nuclear receptors, which can effectively guide researchers to preferentially select compounds with high activity for subsequent research and development, further improving the success rate and efficiency of drug research and development.

[0167] The data set is schematically illustrated in Table 1:

[0168] Table 1 shows the schematic table of the data set

[0169]

[0170]

[0171] The existing muxGNN heterogeneous graph classification method, the HGCNs heterogeneous graph classification method and the heterogeneous graph classification method of the present application are respectively used to evaluate the classification effect on the above data sets. The muxGNN introduces a multiple graph neural network for heterogeneous graphs, which models the heterogeneity from relation-specific graphs and coupled graphs, and then captures multi-faceted semantic context in a coupled attention mechanism. The HGCNs integrates a relation GCN layer into a heterogeneous graph classification framework, which performs message passing for different types of nodes and edges, and then aggregates features to obtain a graph-level representation.

[0172] Experimental configuration: five-fold cross-validation is used, and logistic regression is used as the classifier. The simplex set size is fixed as |S0| = 20, |S1| = 30 and |S2| = 20 to ensure the fixed length of the embedding.

[0173] The iteration number R of the sr-ARE data set is 2, and the iteration number R of the nr-BIO data set is 3; the maximum simplex dimension K extracted from the two data sets is 2. The upper limit of the experimental running time is 24 hours, and when the method does not complete the calculation within the specified time, the result is represented by the symbol “\” to indicate that the running time is exceeded. The molecular heterogeneous graph classification results and efficiency are shown in Table 2:

[0174] Table 2 Comparison of performance of heterogeneous graph classification methods

[0175]

[0176] In the prior art, the molecular classification methods used also take 0 or 1 as the classification result on the sr-ARE and nr-BIO data sets, respectively indicating whether the compound meets a specific classification standard. From Table 2, it can be concluded that these methods rely on complex graph neural network structures and a large number of parameter learning, resulting in high computational complexity. Specifically, in the sr-ARE data set, although the existing methods can provide relatively accurate classification results, on large-scale data sets, especially the nr-BIO data set, they often face the problem of time-out or storage bottleneck. This is because the nr-BIO data set contains a large number of molecular graph samples, which requires a large amount of computing resources to process. Therefore, the existing methods often cannot effectively cope with these computing and storage challenges when dealing with large-scale data sets, limiting their scalability in practical applications.

[0177] In contrast, the method of the present application avoids the complex mathematical operations and the large parameter learning process in the traditional method by using randomly generated multiple sets of hash functions for heterogeneous graph embedding, thereby greatly reducing the time and storage overhead. In particular on the nr-BIO dataset, the method of the present application can effectively avoid the timeout problem and has a significant advantage in running time. In addition, the classification accuracy of the method of the present application on the sr-ARE dataset is better than HGCNs, although slightly lower than muxGNN, the gap is small, and still maintains a high accuracy. Therefore, the method of the present application considers the accuracy, running time and storage overhead comprehensively, and exhibits higher efficiency and better performance when processing large-scale datasets.

[0178] The above only describes the preferred embodiments of the present application and is not intended to limit the present application. For those skilled in the art, the present application can have various modifications and changes. Any modification, equivalent replacement, improvement, etc. within the spirit and principles of the present application shall be included in the protection scope of the present application.

Claims

1. A molecular classification method based on heteromorphic graph embedding, characterized in that, Includes the following steps: Step 1: Extract the simplex from the heterogeneous graph g; Based on the extracted simplex, the structural information of the heterogeneous graph g is processed to obtain the local and global information enhancement operators N. k ; Based on the extracted simplex, the feature information of the heterogeneous graph g is processed to obtain the feature matrix. Step 2: Enhance the operator N based on local and global information k and feature matrix Perform hash iteration on the heterogeneous graph g to obtain the graph-level embedding x. g ; Step 3: Embed x at the graph level g Perform molecular classification to obtain molecular classification results; Obtain graph-level embedding x g The specific process is as follows: (i) Initialization; Let r = 1 and k = 0; where: r represents the r-th iteration and k represents the k-th dimension of the simplex; (ii) Iteration loop condition judgment; Condition: If r≤R, then execute step (iii); otherwise, jump to step (vii). (iii) Simplex dimension loop condition judgment; Condition: If k≤K, then execute step (iv); otherwise, jump to step (vi). (iv) Calculation of the temporary feature matrix; Calculate the temporary characteristic matrix of the k-simula in the r-th iteration. in: W is the characteristic matrix of the k-simplex after the (r-1)th iteration; (r-1,k) For use in updating A matrix of random hash functions; (v) Symbolic operations; For temporary characteristic matrix Apply the symbolic operation sgn to Each element is converted into a binary hash code to obtain the updated feature matrix. Updated feature matrix The expression is as follows: (vi) Update the simplex dimension to k′; Increase k by 1, that is, k′=k+1; Jump back to step (iii); (vii) The number of update iterations is r′; Increase r by 1, that is, r′ = r + 1; Reset k=0; Jump back to step (ii); (ⅷ) Generating graph-level embeddings x g ; The final simplex characteristic matrix Flatten each vector into a single vector, then concatenate them to obtain the graph-level embedding x. g .

2. The molecular classification method based on heterogeneous graph embedding according to claim 1, characterized in that, The heteromorphic graph g is derived from the molecular heteromorphic graph dataset in the known TUDataset, which contains various types of heteromorphic graphs g.

3. The molecular classification method based on heterogeneous graph embedding according to claim 2, characterized in that, The specific process of simplex extraction for heterogeneous graph g is as follows: All nodes in the node set V of the heterogeneous graph g are treated as simplexes of dimension 0 and added to the simplex set S0 of dimension 0, where S0 contains all 0-simplexes. All edges in the edge set E of the heterogeneous graph g are taken as simplexes of the first dimension and added to the simplex set S1 of the first dimension, where S1 contains all 1-simplexes. The Simplex tree is initialized using simplex sets S0 and S1. Then, the `expansion` method of the Simplex tree is used to recursively expand from the second-dimensional simplex, progressively expanding to higher-dimensional simplexes until the maximum dimension K is reached. This process extracts simplexes from the second to the Kth dimensions, resulting in S2, ..., S... K S2,…,S K These are sets from the second dimension to the largest dimension K.

4. The molecular classification method based on heterogeneous graph embedding according to claim 3, characterized in that, Obtaining local and global information enhancement operator N k The specific process is as follows: Calculate the set S of simplexes in the k-th dimension. k The corresponding Hodge Laplace matrix L k k∈{0,1,…,K}; Based on the Hodge Laplace matrix L k Constructing a local information enhancement operator M k ; In the local information enhancement operator M k Based on this, we further construct local and global information enhancement operators N. k .

5. The molecular classification method based on heterogeneous graph embedding according to claim 4, characterized in that, Obtain the characteristic matrix The specific process is as follows: Create a size of |S k |×|T v | zero matrix Traverse S k For each k-simula in the equation, construct a heterogeneous information vector of all nodes contained therein; Traverse S k For each k-simplex in the algorithm, perform an element-wise logical OR operation on the heterogeneous information vectors of all its nodes to obtain a vector of length |T. v | binary vector, as eigenvectors; Fill the zero matrix with the eigenvectors of each k-simula. In this process, we obtain the feature matrix from dimension 0 to the maximum dimension K.

6. The molecular classification method based on heterogeneous graph embedding according to any one of claims 1-5, characterized in that, For graph-level embedding x g The specific process for classifying molecular isomers is as follows: S3.1, regarding x g Invert each bit of the binary representation, converting 0 to 1 and 1 to 0, to obtain the inverted vector flip(x). g ); S3.2, change the original vector x g and the inverted vector flip(x) g ) concatenate them into a 2L-dimensional extended vector x e ; S3.3, x e The data is input into a logistic regression classifier for classification. Specifically: Let x g = [1,0,1], then flip(x) g ) = [0,1,0], concatenating them yields x e =[1,0,1,0,1,0], which is then input into a logistic regression classifier for classification; Where: flip(x) g ) is x g The vector obtained by bitwise inversion; x e For the expanded 2L-dimensional vector, through x e =[x g ,flip(x g )]get.