A graph neural network pre-training method and system for predicting molecular toxicity based on FCSS
By introducing the electron center of the FCSS as domain knowledge into the pre-training of the graph neural network, the ambiguity problem of traditional pre-training tasks is solved, more accurate molecular toxicity prediction is achieved, and the generalization ability of the model and the efficiency of drug development are improved.
Patent Information
- Application Number
- CN202211683405.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-27
- Publication Date
- 2025-11-07
- Estimated Expiration
- 2042-12-27
AI Technical Summary
Existing graph neural networks have poor generalization ability in molecular toxicity prediction. Traditional pre-training tasks have ambiguity problems and cannot effectively distinguish different chemical semantic information of the same type of atoms, resulting in insufficient prediction accuracy of the model in downstream tasks.
By employing a pre-training method based on FCSS, the electron center is extracted as domain knowledge, and RDKit is used to match and encode it into the central atom. Combined with the atom type as the pre-training target, the ambiguity problem is solved and the chemical semantic representation ability of atoms in local subgraphs is improved.
It improves the accuracy of graph neural networks in predicting molecular toxicity, shortens the drug development cycle, and has high practical value.
Smart Images

Figure CN116343942B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application belongs to the technical field of biological genes, and particularly relates to a graph neural network pre-training method and system for predicting molecular toxicity based on FCSS. BACKGROUND
[0002] Research on molecular toxicity is a very important part of drug research and development, and a large amount of resources are needed for experimental detection. Therefore, how to accurately predict molecular toxicity is crucial. Since molecules can be naturally represented as graphs (atoms are represented as nodes and bonds are represented as edges), predicting the toxicity of molecules through graph neural networks has been widely applied. However, in this field, the labeled data is usually insufficient, and the generalization ability of the graph neural network after training is generally poor. Therefore, a pre-training-fine-tuning method is proposed to improve the generalization ability of the model. The commonly used method is to first define a pre-training task, then pre-train the graph neural network on a large amount of unlabeled data, and finally fine-tune on labeled data. The final model is used to predict the toxicity of molecules.
[0003] The current common node-level graph neural network pre-training method defines the pre-training task as masking the atomic number and predicting it. However, due to the small number of atomic types, this pre-training task has a serious ambiguity problem. Two atoms of the same type may have different semantic information in different chemical environments, but they are not distinguished in the above pre-training task. Therefore, when the knowledge learned by the pre-training model is transferred to the downstream task, the model will have more difficulty in capturing the different semantic information of the same type of atom. In the latest research, it is proposed to use the statistical information in the local subgraph as the context information of the atom or bond, and predict these context information instead of the atomic number in pre-training. Although this statistical information-based method alleviates the ambiguity problem in the previous pre-training task to some extent, since the statistical information cannot represent the chemical semantics, predicting this context information in pre-training may transfer unnecessary and incorrect knowledge to the downstream task model.
[0004] Therefore, the above-mentioned prior art indeed needs to propose a better solution. SUMMARY
[0005] The application aims to provide a graph neural network pre-training method and system for predicting molecular toxicity based on FCSS, which designs a new node-level pre-training task, first extracts the electron center in FCSS as domain knowledge, matches these electron centers on the unlabeled data used in pre-training through RDKit, and encodes this domain knowledge into the central atom, which is combined with the atomic type as the target to be predicted during pre-training; this means that some atoms with the same atomic number will be further divided into different categories according to their chemical environment; by applying domain knowledge to the pre-training task, the prediction target can reflect the context information of the atom when the atom exhibits special chemical semantics in the local subgraph, and only the atomic number is predicted when the atom does not have the above characteristics, thereby better solving the ambiguity problem, migrating useful knowledge to the downstream task, and thus improving the accuracy of molecular toxicity prediction. The method and system overcome the ambiguity of traditional methods, add domain knowledge in FCSS to the pre-training task, enable the model to more accurately predict molecular toxicity, shorten the drug development cycle, and have high practical value.
[0006] The application provides a graph neural network pre-training method for predicting molecular toxicity based on FCSS, which comprises the following steps:
[0007] S1, generating a molecular graph, thereby converting the molecule used for training into a molecular graph by adding node and edge features;
[0008] S2, determining one or more electron centers based on FCSS, and taking the electron centers as electron center descriptors; wherein the electron centers take heteroatoms or carbon atoms connected by double bonds / triple bonds as central atoms;
[0009] S3, matching and encoding the one or more electron centers to obtain extended atomic number features, and updating the features from atomic number representation to electron center representation based on the extended atomic number features;
[0010] S4, pre-training based on the electron center representation, randomly masking part or all of the extended atomic number features corresponding to the molecules used for pre-training multiple times during pre-training and predicting, obtaining a basic graph neural network pre-training model for predicting molecular toxicity, and the predicted features are atomic numbers or electron centers.
[0011] Preferably, the method further comprises:
[0012] S5, obtaining a graph neural network pre-training model by fine-tuning the basic graph neural network pre-training model based on a training set related to a downstream task, and the graph neural network pre-training model is used for predicting molecular toxicity.
[0013] Preferably, the S1 comprises:
[0014] S11, constructing a molecule graph by taking atoms in a molecule as nodes and bonds as edges;
[0015] S12, encoding atom attributes using one-hot feature vectors as attributes of the nodes and encoding bond attributes using one-hot feature vectors as attributes of the edges.
[0016] Preferably, the atom attributes comprise atomic numbers and / or chirality information; and the bond attributes comprise bond types.
[0017] Preferably, the S3 comprises:
[0018] S31, for each molecule used for pre-training, matching one or more central atoms of the molecule, obtaining attributes of nodes and edges around the one or more central atoms, obtaining a first attribute set, and determining whether the central atoms are central atoms of the electronic centers based on the first attribute set;
[0019] S32, taking the electronic centers as first atomic numbers, adding a first dimension to the one-hot feature vector originally used to encode the atomic numbers for encoding the electronic centers, and combining the first atomic numbers and the electronic centers to obtain an expanded atomic number feature, wherein the number of dimensions of the first dimension is the same as the number of electronic centers;
[0020] S33, for one or more central atoms of one or more electronic centers, updating the expanded atomic number feature, and updating the feature from atomic number representation to electronic center representation.
[0021] Preferably, the S4 comprises:
[0022] S41, for a molecule used for pre-training, randomly masking part or all of the expanded atomic number features corresponding to the molecule used for pre-training multiple times in pre-training;
[0023] S42, inputting the molecule graph into a graph neural network primary model;
[0024] S43, taking the masked atomic number feature as a prediction target, pre-training the graph neural network primary model based on the molecule graph and the construction of a multi-classification task.
[0025] The second aspect of the present application provides a graph neural network pre-training system for predicting molecular toxicity based on FCSS, comprising:
[0026] The molecular graph generation module (101) is configured to generate a molecular graph, so as to convert a training molecule into a molecular graph by adding node and edge features;
[0027] The electronic center determination module (102) is configured to determine one or more electronic centers based on the FCSS and take the electronic centers as electronic center descriptors, wherein the electronic centers take heteroatoms or double bond / triple bond connected carbon atoms as central atoms;
[0028] The matching and encoding module (103) is configured to match and encode the one or more electronic centers to obtain an extended atomic number feature, and update the feature from an atomic number representation to an electronic center representation based on the extended atomic number feature.
[0029] The pre-training module (104) is configured to pre-train based on the electronic center representation, in the pre-training, randomly mask part or all of the extended atomic number features corresponding to the molecules for pre-training multiple times and make a prediction, and obtain a basic graph neural network pre-training model for predicting molecular toxicity, wherein the to-be-predicted features are atomic numbers or electronic centers.
[0030] As a preferred embodiment, the application further comprises:
[0031] The adjustment module (105) is configured to fine-tune the basic graph neural network pre-training model based on a training set related to a downstream task to obtain a graph neural network pre-training model, and the graph neural network pre-training model is used for predicting molecular toxicity.
[0032] The third aspect of the application provides an application of a graph neural network pre-training system for predicting molecular toxicity based on FCSS in the establishment of a graph neural network model for predicting molecular toxicity.
[0033] The third aspect of the application provides an application of a graph neural network pre-training system for predicting molecular toxicity based on FCSS in the establishment of a graph neural network model for predicting molecular toxicity.
[0034] The system, method and application provided by the application have the following beneficial technical effects:
[0035] The graph neural network pre-training method for predicting molecular toxicity based on FCSS designs a new node-level pre-training task. First, the electron center in FCSS is extracted as domain knowledge. The electron center is matched on the unlabeled data used for pre-training through RDKit, and this domain knowledge is encoded into the center atom, which is combined with the atom type as the target to be predicted during pre-training. This means that some atoms with the same atomic number will be further divided into different categories according to their chemical environment. By applying domain knowledge to the pre-training task, the prediction target can reflect the context information of the atom when the atom exhibits special chemical semantics in the local subgraph, and only the atomic number is predicted when the atom does not have the above characteristics, thereby better solving the ambiguity problem, migrating useful knowledge to the downstream task, and thus improving the accuracy of molecular toxicity prediction. The method and system overcome the ambiguity of traditional methods, enable the model to more accurately predict molecular toxicity by adding domain knowledge in FCSS to the pre-training task, shorten the drug development cycle, and have high practical value. BRIEF DESCRIPTION OF DRAWINGS
[0036] Figure 1 A flowchart of the graph neural network pre-training method for predicting molecular toxicity based on FCSS according to the preferred embodiment of the present application is shown.
[0037] Figure 2 A schematic diagram of the principle of the graph neural network pre-training method for predicting molecular toxicity based on FCSS according to the preferred embodiment of the present application is shown.
[0038] Figure 3 A system architecture diagram of the graph neural network pre-training system for predicting molecular toxicity based on FCSS according to the preferred embodiment of the present application is shown. DETAILED DESCRIPTION
[0039] The specific embodiments of the present application will be further described in detail below in conjunction with the drawings and examples. The following examples are used to illustrate the present application, but are not used to limit the scope of the present application.
[0040] Example 1
[0041] As shown in Figures 1-2 , a graph neural network pre-training method for predicting molecular toxicity based on FCSS is provided, comprising:
[0042] S1, generating a molecular graph, thereby converting the molecule used for training into a molecular graph by adding features of nodes and edges;
[0043] As a preferred embodiment, the S1 comprises:
[0044] S11, atoms in the molecule are taken as nodes, and bonds are taken as edges to construct a molecule graph;
[0045] S12, atom attributes (such as atomic number, chirality information, etc.) are encoded using one-hot feature vectors as attributes of the nodes, and bond attributes (such as bond types, etc.) are encoded using one-hot feature vectors as attributes of the edges.
[0046] S2, one or more electron centers are determined based on the FCSS, and the electron centers are taken as electron center descriptors; wherein the electron centers take heteroatoms or carbon atoms connected by double / triple bonds as central atoms;
[0047] In the preferred embodiment, 17 electron centers with heteroatoms or carbon atoms connected by double / triple bonds as central atoms are selected from the FCSS molecular descriptor language as electron center descriptors; the electron centers in the FCSS are extracted as domain knowledge.
[0048] S3, the one or more electron centers are matched and encoded to obtain an extended atomic number feature, and the feature is updated from atomic number representation to electron center representation based on the extended atomic number feature;
[0049] As a preferred embodiment, the S3 comprises:
[0050] S31, for each molecule used for pre-training, one or more central atoms of the molecule are matched, the attributes of the nodes and edges around the one or more central atoms are obtained, a first attribute set is obtained, and whether the central atom is a central atom of the electron center is determined based on the first attribute set;
[0051] In this embodiment, for each molecule used for pre-training, the possible central atoms of each molecule are matched using RDKit, the attributes of the nodes and edges around the central atoms are obtained to obtain a first attribute set, and whether the central atom is a central atom of the electron center is determined based on the first attribute set; the electron centers are matched by RDKit on the unlabeled data used for pre-training, the domain knowledge is encoded into the central atoms, and the atom types are combined as the target to be predicted during pre-training.
[0052] S32, the electron center is taken as a first atomic number, a first dimension is added to the one-hot feature vector originally used to encode the atomic number for encoding the electron center, the first atomic number and the encoded electron center are combined to obtain an extended atomic number feature, and the number of dimensions of the first dimension is the same as the number of electron centers;
[0053] In this embodiment, the electron center is taken as a special atomic number, and a one-hot feature vector originally used to encode the atomic number is increased by 17 dimensions to encode the electron center, obtaining an expanded atomic number feature;
[0054] S33, updating the expanded atomic number feature for one or more center atoms of the one or more electron centers, and updating the feature from the atomic number representation to the electron center representation.
[0055] S4, pre-training based on the electron center representation, in which the expanded atomic number feature corresponding to the molecule for pre-training is randomly masked multiple times for prediction, obtaining a basic graph neural network pre-training model for predicting the toxicity of the molecule, and the predicted feature is the atomic number or the electron center;
[0056] As a preferred embodiment, the S4 comprises:
[0057] S41, for the molecule for pre-training, the expanded atomic number feature corresponding to the molecule for pre-training is randomly masked multiple times for pre-training;
[0058] S42, inputting the molecule graph into the graph neural network primary model;
[0059] S43, taking the masked atomic number feature as a prediction target, constructing a multi-classification task based on the molecule graph, and pre-training the graph neural network primary model.
[0060] As a preferred embodiment, the method further comprises:
[0061] S5, obtaining a graph neural network pre-training model by fine-tuning the basic graph neural network pre-training model based on a training set related to a downstream task, and the graph neural network pre-training model is used to predict the toxicity of the molecule.
[0062] Embodiment two
[0063] Referring to Figure 3 , a graph neural network pre-training system for predicting the toxicity of a molecule based on FCSS is provided, comprising:
[0064] The molecule graph generation module 101 is configured to generate a molecule graph, thereby converting the molecule for training into a molecule graph by increasing the features of the nodes and edges;
[0065] The electron center determination module 102 is configured to determine one or more electron centers based on FCSS, and take the electron center as an electron center descriptor; wherein the electron center takes a heteroatom or a carbon atom connected by a double bond / triple bond as a center atom.
[0066] The matching and coding module 103 is configured to match and code the one or more electron centers to obtain an extended atomic number feature, and update the feature from the atomic number feature to the electron center feature based on the extended atomic number feature.
[0067] The pre-training module 104 is configured to pre-train based on the electron center feature, in which a part or all of the extended atomic number features corresponding to the molecules for pre-training are randomly masked multiple times and predicted to obtain a basic graph neural network pre-training model for predicting the molecular toxicity, and the features to be predicted are atomic numbers or electron centers.
[0068] As a preferred embodiment, the system further comprises:
[0069] The adjusting module 105 is configured to fine-tune the basic graph neural network pre-training model based on a training set related to a downstream task to obtain a graph neural network pre-training model for predicting the molecular toxicity.
[0070] Embodiment three
[0071] The application of the graph neural network pre-training system for predicting the molecular toxicity based on the FCSS in the establishment of the graph neural network model for predicting the molecular toxicity is provided.
[0072] Embodiment four
[0073] The application of the graph neural network pre-training system for predicting the molecular toxicity based on the FCSS in the prediction of the molecular toxicity is provided.
[0074] Although the preferred embodiments of the present application have been described, those skilled in the art, once they know the basic creative concept, can make additional changes and modifications to these embodiments. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications falling within the scope of the present application. Obviously, those skilled in the art can make various modifications and variations to the present application without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalent technologies, the present application also intends to include these modifications and variations.
Claims
1. A graph neural network pre-training method for predicting molecular toxicity based on FCSS, characterized in that, Comprising: S1, generating a molecular graph, so as to convert the molecule to be trained into a molecular graph by adding the features of nodes and edges; S2, determining one or more electron centers based on FCSS, and taking the electron center as an electron center descriptor; wherein the electron center takes a heteroatom or a carbon atom connected by a double bond / triple bond as a central atom; S3, obtaining an extended atomic number feature after matching and coding the one or more electron centers, and updating the feature from an atomic number representation to an electron center representation based on the extended atomic number feature; S4, pre-training based on the electron center representation, in which the extended atomic number feature corresponding to the molecule to be pre-trained is randomly masked multiple times for pre-training and prediction, to obtain a basic graph neural network pre-training model for predicting molecular toxicity, and the predicted feature is an atomic number or an electron center; S5, obtaining a graph neural network pre-training model by fine-tuning the basic graph neural network pre-training model based on a training set related to a downstream task, and the graph neural network pre-training model is used to predict molecular toxicity.
2. The FCSS-based molecular toxicity prediction graph neural network pre-training method according to claim 1, wherein, The S1 comprises: S11, constructing a molecular graph by taking atoms in a molecule as nodes and bonds as edges; S12, using one-hot feature vectors to encode atomic properties as attributes of the nodes, and using one-hot feature vectors to encode bond properties as attributes of the edges.
3. The pre-training method of a graph neural network for predicting molecular toxicity based on FCSS according to claim 2, characterized in that, The atomic properties include atomic numbers and / or chirality information; the bond properties include bond types.
4. The pre-training method of a graph neural network for predicting molecular toxicity based on FCSS according to claim 3, characterized in that, The S3 comprises: S31, for each molecule to be pre-trained, matching one or more central atoms of the molecule, obtaining the attributes of the nodes and edges around the one or more central atoms, obtaining a first attribute set, and determining whether the central atom is a central atom of the electron center based on the first attribute set; S32, taking an electron center as a first atomic number, adding a first dimension to the one-hot feature vector originally used to encode the atomic number for encoding the electron center, and obtaining an extended atomic number feature by combining the first atomic number and the encoded electron center, wherein the number of dimensions of the first dimension is the same as the number of electron centers; S33, for one or more central atoms of the one or more electron centers, updating the extended atomic number feature, and updating the feature from an atomic number representation to an electron center representation.
5. The pre-training method of a graph neural network for predicting molecular toxicity based on FCSS according to claim 4, characterized in that, The S4 comprises: S41, for a molecule to be pre-trained, randomly masking part or all of the extended atomic number features corresponding to the molecule to be pre-trained multiple times for pre-training; S42, inputting the molecular graph into a graph neural network primary model; S43, taking the masked atomic number feature as a prediction target, constructing a multi-classification task based on the molecular graph, and pre-training the graph neural network primary model.
6. A graph neural network pre-training system for predicting molecular toxicity based on FCSS, for implementing the method of any one of claims 1-5, characterized in that, Comprising: a molecular graph generation module (101) for generating a molecular graph, so as to convert the molecule to be trained into a molecular graph by adding the features of nodes and edges; An electronic center determination module (102) is configured to determine one or more electronic centers based on the FCSS and take the electronic centers as electronic center descriptors; wherein the electronic center takes a heteroatom or a double bond / triple bond connected carbon atom as a central atom; A matching coding module (103) is configured to match and code the one or more electronic centers to obtain an extended atomic number feature, and update the feature from an atomic number representation to an electronic center representation based on the extended atomic number feature; A pre-training module (104) is configured to pre-train based on the electronic center representation, in which the extended atomic number feature corresponding to the molecule for pre-training is randomly masked multiple times and prediction is performed to obtain a basic graph neural network pre-training model for predicting the toxicity of the molecule, and the feature to be predicted is an atomic number or an electronic center; An adjustment module (105) is configured to fine-tune the basic graph neural network pre-training model based on a training set related to a downstream task to obtain a graph neural network pre-training model for predicting the toxicity of the molecule.
7. An application of the graph neural network pre-training system for predicting the toxicity of the molecule based on the FCSS according to claim 6 in establishing a graph neural network model for predicting the toxicity of the molecule.
8. An application of the graph neural network pre-training system for predicting the toxicity of the molecule based on the FCSS according to claim 6 in predicting the toxicity of the molecule.
Citation Information
Patent Citations
Molecular property prediction method based on graph neural network
CN111798934A
Drug relocation method and system based on drug classification map neural network
CN114613452A