A compound screening method based on adaptive edge attribute enhancement of contrast learning

By constructing an adaptive edge attribute enhancement learner and a contrastive learning method, the edge interactions of the compound molecular graph are explicitly learned, which solves the problems of label scarcity and neglect of edge importance in compound screening, and improves the accuracy and performance of compound screening.

CN116825232BActive Publication Date: 2026-01-20ZHEJIANG UNIV OF TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310869998.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-07-14
Publication Date
2026-01-20
Estimated Expiration
2043-07-14

AI Technical Summary

Technical Problem

Existing graph neural network methods rely on supervised learning for compound property prediction and classification, requiring a large amount of labeled data and ignoring the importance of graph edges, resulting in poor learning performance.

Method used

By constructing an adaptive edge attribute enhancement learner, the edge interactions of the molecular graph are explicitly learned. Combined with contrastive learning, an enhanced view is generated. Contrastive learning is then performed under unsupervised conditions to obtain more reasonable edge weights and improve compound screening performance.

Benefits of technology

This approach solves the problem of tag scarcity, explicitly learns the importance of edges, improves the accuracy and performance of compound screening, removes redundant information interference in the encoding, and preserves the original semantic information of molecules.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116825232B_ABST
    Figure CN116825232B_ABST
Patent Text Reader

Abstract

A compound screening method based on contrast learning adaptive edge attribute enhancement, comprising the following steps: 1) obtaining data and performing topological processing and attribute processing; 2) constructing AE-Learner, jointly analyzing subgraph network topology and original graph network attributes, assigning comprehensive edge weights to molecular graphs, and generating enhanced views; 3) training the AE encoder, and maximizing the difference between different enhanced views through the AE learning target; 4) in the same iteration process, training the GCL encoder, and maximizing the similarity between positive pairs in graph contrast learning through the GCL target; 5) repeating steps 3 and 4 until the GCL target loss tends to be stable; 6) applying the trained GCL encoder to the downstream compound screening task, and performing graph classification and property prediction through the support vector machine based on the encoded graph-level representation. The application provides an enhancement method of explicit edge learning, which combines contrast learning, solves the label scarcity problem, supplements the importance of edges, and improves the performance of compound screening.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the fields of contrastive learning, graph data augmentation and graph classification, and mainly relates to a compound screening method based on contrastive learning adaptive edge attribute augmentation. BACKGROUND

[0002] In new drug design, property prediction and classification of compounds is an important step in screening suitable combinations of compounds. In traditional methods, experts achieve the screening task through a large number of biochemical experiments and high-throughput data analysis, which is long in cycle, high in cost and easily affected by human subjective ideas. In contrast, building a compound screening model through a computer can avoid these problems.

[0003] With the development of modern computer technology and chemical informatics, researchers have applied graph neural networks (GNNs) to the field of chemistry. GNN-based methods have shown state-of-the-art performance in many tasks, such as compound property prediction, drug discovery, and reaction prediction. However, existing GNN methods are mostly trained in a supervised manner, requiring a large amount of high-precision labeled data, which does not meet the actual application environment. To solve this problem, self-supervised learning is further proposed, which can learn its own features from unlabeled data to generate node representations or graph representations that are beneficial to downstream classification tasks. Graph contrastive learning (GCL) is one of the mainstream methods in the field of self-supervised learning. Its paradigm system can be divided into four parts: graph augmentation strategy, GNN-based graph encoding, mapping head, and contrastive learning objective. Among them, the graph augmentation strategy plays an important role, which can indirectly determine which graph structure information the GNN encoder captures. Specifically, GNN updates node representations by transforming, propagating and aggregating node domain information based on a message passing scheme, and further compresses node representations into graph representations through graph pooling technology. Under the above premise, when the graph augmentation strategy only modifies the topology / attributes of the input graph or adds perturbations, the GNN encoder will still focus on node context information or compressed graph-level information, ignoring the importance of the edges of the graph. In the research of GCL, most methods (such as GraphCL, JOAO and RGCL, etc.) have the above problems. In addition, even if the GNN model considers edge features, it only learns edge information implicitly, and the main purpose is still to strengthen node representations or graph representations, and the research on relevant explicit edge representations is currently rare. SUMMARY

[0004] In view of the above deficiencies of the prior art, the present application provides a compound screening method based on contrastive learning adaptive edge attribute augmentation.

[0005] The present application provides the following technical solutions:

[0006] A compound screening method based on contrastive learning and adaptive edge attribute enhancement includes the following steps:

[0007] S1: Data Acquisition and Preprocessing: Acquire compound molecular data and perform topological and attribute-level processing on the data;

[0008] S2: Construct an adaptive edge attribute enhancement learner (AE-Learner), which assigns comprehensive edge weights to the original molecular graph by jointly analyzing the subgraph network topology of the compound molecule and the network attribute features of the original graph, thereby generating an enhanced view;

[0009] S3: Set the AE encoder to training mode and the GCL encoder to evaluation mode. Input the augmented view into the GCL model to obtain a graph-level representation, and maximize the difference between different augmented views through the AE learning objective.

[0010] S4: In the same iteration, set the AE learner to evaluation mode and the GCL encoder to training mode, obtain the original molecular map and the enhanced view, perform comparative learning operations, and maximize the similarity between opposites through the GCL objective.

[0011] S5: Repeat S3 and S4 until the GCL target loss tends to stabilize;

[0012] S6: The trained contrastive learning encoder is applied to the downstream molecular attribute prediction task, and the encoded graph-level representation is used for graph classification task through support vector machine.

[0013] Preferably, the specific process of topology hierarchy processing in step S1 is as follows:

[0014] First, according to the subgraph network transformation strategy Original molecular diagram Convert to a new graph (first-order subgraph network) In this process, the edges in the original graph are converted into nodes in the new graph, and adjacent edge pairs sharing the same endpoint in the original graph are converted into edges in the new graph, satisfying the following formula:

[0015] (1)

[0016] Secondly, all nodes in the new graph are assigned the attribute x of 1, satisfying the following formula:

[0017] (2)

[0018] Where u is the subgraph network Any node in the middle, The corresponding node The above formula will iterate through the node attributes. Each node in the process.

[0019] Preferably, the attribute hierarchy processing in step S1 involves converting the node attributes x of the one-heat encoded structure in the original molecular graph into a 1-dimensional vector and naming it an attribute molecular network. It satisfies the formula:

[0020] (3)

[0021] in It is the original molecular diagram. Any node in the middle, The corresponding node Node attributes, The function is used to obtain the one-hot encoding structure. The subscript of 1 in the middle These are the processed node attributes; the above formula will iterate through them. Each node in the process.

[0022] Preferably, the adaptive edge attribute enhancement learner (AE-Learner) described in step S2 will simultaneously perform topological hierarchical analysis of the subgraph network and attribute-level analysis of the attribute sub-network. The specific process is as follows:

[0023] In the topological hierarchy analysis of subgraph networks, AE encoder input to AE-Learner In the encoding process, the AE encoder superficially learns the node context information of the subgraph network, but in essence, it has transformed into explicitly learning the edge representation of the original subgraph. This is because the subgraph network models higher-order interactions between edges, and the process satisfies the formula:

[0024] (4)

[0025] Next, the node representation The input is fed into an MLP mapping head with an output dimension of 1 to obtain the edge weights of the original molecular graph at the topological level. The process satisfies the formula:

[0026] (5)

[0027] In the attribute hierarchy analysis of attribute molecular networks, AE encoder input to AE-Learner Encode the data and output the attribute hierarchy node representation of the original molecular graph. The process satisfies the formula:

[0028] (6)

[0029] Next, Concatenate according to edge index edge_index, that is, the node representations of the connected node pairs will be concatenated to obtain the edge representation of the attribute level , the process satisfies the following formula:

[0030] (7)

[0031] wherein, is the edge representation obtained by concatenating all edge indices as a tensor, concatenation operation, is the edge representation obtained by concatenating the node representations, which is an implicit edge representation;

[0032] Finally, similar to the topology level analysis, is input into the MLP mapping head with an output dimension of 1 to obtain the edge weight of the original molecular graph at the attribute level , the process satisfies the following formula:

[0033] (8)

[0034] Preferably, the integrated edge weight of step S2 satisfies the following formula:

[0035] (9)

[0036] Preferably, the AE learning goal of step S3 can maximize the difference between different augmented views, and the objective function thereof satisfies the following formula:

[0037] (10)

[0038] wherein, is a cosine similarity function, and represent the graph-level representations of different augmented views under GCL encoding, is the AE objective function, and the smaller the value is, the greater the difference between augmented views of different origins is.

[0039] Preferably, the specific process of the contrast learning operation of step S4 is as follows:

[0040] First, the original molecular graph and the augmented view are input into the same GCL encoder and average pooling readout function in turn to obtain the graph-level representations and , which satisfy the following formula:

[0041] (11)

[0042] Further, the head is obtained by mapping the 3-layer MLP and satisfying the following formula:

[0043] (12)

[0044] Finally, another original molecular graph and its corresponding enhanced view is positive, the original molecular graph and the enhanced view of different origin is negative, according to the following GCL objective function, the similarity between positive pairs is maximized and the similarity of negative pairs is minimized;

[0045] (13)

[0046] wherein is the temperature coefficient, preferably 0.2.

[0047] Compared with the prior art, the present application has the beneficial effects that: the present application models the high-order interaction state of edges by constructing a subgraph network, and learns the edge interaction of the molecular graph explicitly in the topology level, while considering the influence of the actual attributes of the nodes of the molecular graph on the overall properties of the molecular graph, and learning the edges implicitly in the attribute level by splicing the node attributes, and by analyzing the two levels of topology and attributes, more reasonable edge weights are obtained and added to the original molecular graph as an enhanced view, solving the problem of insufficient edge learning; in addition, by unsupervised contrastive learning of the enhanced view and the original molecular graph, the label shortage problem can be solved; since the edges with high weights will have a greater impact on the GCL encoding result and the edges with low weights will have a smaller impact on the GCL encoding result when comparing the original molecular graph and the enhanced view, therefore, compared with other contrastive learning methods, the method can also remove the redundant information interference in the encoding and retain the original semantic information of the molecule without modifying the topology / attributes of the molecular graph. BRIEF DESCRIPTION OF DRAWINGS

[0048] Figure 1 is the overall method flowchart of the method of the present application;

[0049] Figure 2 is a diagram of the enhanced view module;

[0050] Figure 3 is a diagram of the graph contrastive learning module. DETAILED DESCRIPTION

[0051] The specific embodiments of the present application will be further described in detail below in conjunction with the drawings of the specification.

[0052] In conjunction with Figure 1The embodiment method is a compound screening method based on contrast learning adaptive edge attribute enhancement, which comprises the following steps:

[0053] S1: data acquisition and preprocessing: acquiring compound molecular data, and performing topological level processing and attribute level processing on the data;

[0054] S2: constructing an adaptive edge attribute enhancement learner AE-Learner, analyzing the subgraph network topological structure and original graph network attribute features of the compound molecules, adding comprehensive edge weights to the original molecular graph, and generating an enhanced view;

[0055] S3: setting the AE encoder to training mode and the GCL encoder to evaluation mode, inputting the enhanced view into the GCL model to obtain the graph-level representation, and maximizing the difference between different enhanced views through the AE learning target;

[0056] S4: in the same iteration process, set the AE learner to evaluation mode and the GCL encoder to training mode, obtain the original molecular graph and the enhanced view, perform contrast learning operation, and maximize the positive pair similarity through the GCL target;

[0057] S5: repeat S3 and S4 until the GCL target loss tends to be stable;

[0058] S6: apply the trained contrast learning encoder to the downstream molecular attribute prediction task, and perform graph classification task through support vector machine based on the encoded graph-level representation.

[0059] Step S1 specifically comprises:

[0060] S1.1: The present application downloads chemical molecular data sets such as nitro compound data set MUTAG, mouse carcinogenicity data set PTC and anti-tumor data set NCI1 from public large benchmark data set TUDataset; graph data conversion is performed on these data, and the statistical information is shown in Table 1; after further data preprocessing, each molecular graph will have the following attribute features: node attribute x, edge index edge_index and edge weight edge_weight (initialized to 1).

[0061] Table 1. Statistical information of three chemical molecular graph data sets

[0062]

[0063] S1.2: topological level processing of data, comprising the following steps:

[0064] Firstly, the original molecular graph is converted into a first-order subgraph network by a subgraph network conversion strategy, and the specific rules are as follows: the edges in the original graph are converted into nodes in the new graph, and the adjacent edge pairs sharing the same end point in the original graph are converted into edges in the new graph, at this time, the new graph is a first-order subgraph network;

[0065] (1)

[0066] Wherein G is an input original molecular graph, is a subgraph network conversion function, is a new graph.

[0067] Secondly, the purpose of topological level processing is to explicitly analyze the connection of edges, therefore, the role of node attribute is not considered, and the relevant node attribute x is assigned to 1;

[0068] (2)

[0069] Wherein u is any node in the subgraph network is the node attribute of the corresponding node , and formula (2) will traverse each node in .

[0070] S1.3: Considering that the nodes of the chemical molecular graph have actual attribute significance (i.e. atomic attribute), which has an influence on the judgment of the nature of the whole graph, therefore, the present application further performs attribute level processing on the basis of the data of S1.1, converts the node attribute x of the one-hot encoding structure into a 1-dimensional vector, and obtains an attribute level molecular network , which satisfies the formula:

[0071] (3)

[0072] Wherein is any node in the original molecular graph , is the node attribute of the corresponding node , the function is the subscript of 1 in the one-hot encoding structure , is the processed node attribute, and formula (3) will traverse each node in .

[0073] In combination with the graph enhancement module schematic diagram shown, the step S2 includes the following steps: Figure 2

[0074] ​​​​​S2.1: Construct an adaptive edge attribute enhancer learner AE-Learner, the input dimension of which is 1, the hidden dimension is 32, the number of network layers is 5, the basic architecture of the GNN encoder is a weight GIN network based on a message passing scheme, and the input dimension of the mapping head is set to 1;

[0075] S2.2: The topological level subgraph network processed in S1.2 is input into the AE encoder of the AE-Learner for coding. Apparently, the AE encoder has learned the node context information of the subgraph network, but in essence, it has been transformed into explicit learning of the edge representation of the original molecular graph, because the subgraph network is modeling the high-order interaction between edges;

[0076] (4)

[0077] The node representation output by the AE encoder is input into the MLP mapping head, and the output dimension thereof is 1 dimension, representing the corresponding edge weight of the topological level in the original molecular graph .

[0078] (5)

[0079] S2.3: The attribute level molecular network processed in S1.3 is input into the AE encoder of the AE-Learner for coding, and the output result is the attribute level node representation of the original molecular graph ;

[0080] (6)

[0081] According to the edge index edge_index, the node representations of the connected node pairs are concatenated to obtain the edge representation of the attribute level , as shown in equation (7);

[0082] (7)

[0083] wherein, is the edge representation obtained by concatenating all edge indices as a tensor, the concatenation operation, is the edge representation obtained by concatenating the node representations, which is an implicit edge representation;

[0084] Similarly, the edge representation is input into the MLP mapping head, and the output dimension thereof is 1 dimension, representing the corresponding edge weight of the attribute level in the original molecular graph .

[0085] (8)​

[0086] S2.4: By jointly analyzing the subgraph network topology and the original graph network attribute features of the compound molecule, we obtain a comprehensive edge weight , which is attached to the edge_weight attribute of the original graph molecule, and is used as an enhanced view .

[0087] (9)

[0088] The step S3 comprises the following steps:

[0089] S3.1: Obtain the graph-level representation of the enhanced view: set the AE encoder to the training mode, and the subsequent GCL encoder to the evaluation mode, wherein the GNN parameters in the training mode can be adjusted according to the AE target, and the GNN parameters in the evaluation mode will not be changed; the enhanced view with the attached edge weight is input into the GCL encoder and the average pooling readout function to obtain the graph-level representation , which is further mapped into a more rigorous latent space through a 3-layer MLP mapping head;

[0090] (11)

[0091] (12)

[0092] Wherein the GCL encoder is similar to the AE encoder in configuration, the only difference is that the input dimension of the former varies with the node attribute dimension of the original molecule graph, and the output dimension of the MLP mapping head in the contrast learning is set to 32;

[0093] S3.2: Set the AE learning target, and maximize the difference between the graph-level representations of different enhanced views in the latent space, and the objective function satisfies formula (10);

[0094] (10)

[0095] Wherein is the cosine similarity function, and represent the graph-level representations of different enhanced views, is the AE target function, and the smaller the value is, the greater the difference between the enhanced views of different origins is.

[0096] In the same training iteration process, after the AE learner is trained, it is set to the evaluation mode, and the GCL encoder is set to the training mode, to perform the contrast learning module, as shown in the graph contrast learning module schematic diagram of Figure 3 , step S4 comprises the following steps:

[0097] S4.1: input the original molecular graph and the enhanced view The graph-level representation is obtained by inputting the same GCL encoder and average pooling readout function in succession and further mapped by a 3-layer MLP mapping head to obtain and The process satisfies formulas (11) and (12);

[0098] S4.2: another original molecular graph and its corresponding enhanced view The positive pair is the original molecular graph and the enhanced view of different origin The negative pair, the contrastive objective function satisfies formula (13), which can maximize the similarity between the positive pairs and minimize the similarity of the negative pairs;

[0099] (13)

[0100] wherein is the temperature coefficient, generally taken as 0.2.

[0101] In step S5, S3 and S4 are repeated until stop when the loss no longer decreases and tends to be stable.

[0102] In step S6, the trained GCL encoder is applied to the downstream molecular property prediction task, the unknown chemical molecular graph in the data set is input into the GCL encoder to obtain the graph-level representation, and then the support vector machine is used for graph classification task; the present application names the whole model as SGNAE, and compares it with the existing most advanced graph contrastive learning method, proves the superior performance of SGNAE, and the results are shown in Table 2:

[0103] Table 2. Precision of contrastive learning method in the downstream graph classification task under unsupervised environment

[0104]

[0105] The present application provides an enhanced method of explicit edge learning, combined with contrastive learning, which not only solves the problem of label scarcity, but also supplements the importance of edge and improves the performance of compound screening.

[0106] The content described in the embodiments of the present application is only a list of implementation forms of the inventive concept, and the protection scope of the present application should not be regarded as limited to the specific forms stated in the embodiments, and the protection scope of the present application also extends to equivalent technical means that can be thought of by those skilled in the art according to the inventive concept.

Claims

1. A compound screening method based on contrastive learning and adaptive edge attribute enhancement, characterized in that, Includes the following steps: S1: Data Acquisition and Preprocessing: Acquire compound molecular data and perform topological and attribute-level processing on the data; S2: Construct an adaptive edge attribute enhancement learner (AE-Learner), which adds comprehensive edge weights to the original molecular graph by jointly analyzing the subgraph network topology of the compound molecule and the attribute features of the original graph network, generating an enhanced view; the adaptive edge attribute enhancement learner (AE-Learner) will simultaneously perform topological hierarchical analysis of the subgraph network and attribute-level analysis of the attribute molecule network. The topological hierarchy analysis of the subgraph network specifically includes: First, The AE encoder to be input into AE-Learner In the encoding process, the AE encoder superficially learns the node context information of the subgraph network, but in essence, it has transformed into explicitly learning the edge representation of the original subgraph. This is because the subgraph network models the higher-order interactions between edges, and its process satisfies the formula: (4) Next, the node representation The input is fed into an MLP mapping head with an output dimension of 1 to obtain the edge weights of the original molecular graph at the topological level. The process satisfies the formula: (5) The attribute-level analysis of the aforementioned molecular network specifically includes: First The AE encoder to be input into AE-Learner Encode the data and output the attribute hierarchy node representation of the original molecular graph. The process satisfies the formula: (6) Next, Edges are concatenated according to their edge indices (edge_index), meaning the node representations of connected node pairs are chained together to obtain the edge representation at the attribute level. The process satisfies the following formula: (7) in, It involves iterating through all edge indices and concatenating them to store the edge representation as a tensor. Serial splicing operation, It is an edge representation obtained by splicing nodes, and is an implicit edge representation; at last, The input is fed into an MLP mapping head with an output dimension of 1 to obtain the edge weights of the original molecular graph at the attribute level. The process satisfies the following formula: (8) The combined edge weights satisfy the following formula: (9) S3: Set the AE encoder to training mode and the GCL encoder to evaluation mode. Input the augmented view into the GCL model to obtain a graph-level representation, and maximize the difference between different augmented views through the AE learning objective. S4: In the same iteration, set the AE learner to evaluation mode and the GCL encoder to training mode, obtain the original molecular map and the enhanced view, perform comparative learning operations, and maximize the similarity between opposites through the GCL objective. S5: Repeat steps S3 and S4 until the GCL target loss tends to stabilize; S6: The trained contrastive learning encoder is applied to the downstream molecular attribute prediction task, and the encoded graph-level representation is used for graph classification task through support vector machine.

2. The compound screening method based on contrastive learning and adaptive edge attribute enhancement as described in claim 1, characterized in that, In step S1, the specific process of topology hierarchy processing is as follows: First, according to the subgraph network transformation strategy Original molecular diagram Convert to a first-order subgraph network In this process, the edges in the original graph are transformed into nodes in the first-order subgraph network, and adjacent edge pairs sharing the same endpoint in the original graph are transformed into edges in the first-order subgraph network, satisfying the following formula: (1) Secondly, all nodes in the first-order subgraph network are assigned the attribute x of 1, satisfying the following formula: (2) Where u is the subgraph network Any node in the middle, The corresponding node The above formula will iterate through the node attributes. Each node in the process.

3. The compound screening method based on contrastive learning and adaptive edge attribute enhancement as described in claim 1, characterized in that, In step S1, the attribute hierarchy processing involves converting the node attributes x of the one-hot encoded structure in the original molecular graph into a 1-dimensional vector and naming it an attribute molecular network. It satisfies the formula: (3) in It is the original molecular diagram. Any node in the middle, The corresponding node Node attributes, The function is used to obtain the one-hot encoding structure. The subscript of 1 in the middle These are the processed node attributes; the above formula will iterate through them. Each node in the process.

4. The compound screening method based on contrastive learning and adaptive edge attribute enhancement as described in claim 1, characterized in that, The AE learning objective in step S3 can maximize the differences between different augmented views, and its objective function satisfies the following formula: (10) in It is the cosine similarity function. and This represents the graph-level representation of different enhanced views under GCL encoding. It is the objective function of AE, and the smaller its value, the greater the difference between augmented views from different origins.

5. The compound screening method based on contrastive learning and adaptive edge attribute enhancement as described in claim 1, characterized in that, In step S4, the specific process of the comparison learning operation is as follows: First, the original molecular diagram and enhanced view The graph-level representation is obtained by sequentially inputting the data into the same GCL encoder and average pooling readout function. and It satisfies the following formula: (11) Furthermore, it is obtained through a 3-layer MLP mapping head. and It satisfies the following formula: (12) Finally, the original molecular diagram Its corresponding enhanced view For alignment, the original molecular diagram Enhanced views with different origins For negative pairs, according to the following GCL objective function, maximize the similarity between positive pairs and minimize the similarity between negative pairs; (13) in It is the temperature coefficient.

6. The compound screening method based on contrastive learning and adaptive edge attribute enhancement as described in claim 5, characterized in that, Temperature coefficient Take 0.2.

Citation Information

Patent Citations

  • Molecular diagram representation learning method based on contrast learning

    CN112669916A

  • Graph neural network characterization method and device for chemical molecular structure

    CN113314189A