Training method of annotation model, cell type annotation method and related equipment
By acquiring and processing spatial transcriptome data and single-cell sequencing data, and combining multimodal prior information for joint annotation, the problem of low accuracy in cell type annotation in existing technologies has been solved, and high-resolution cell type annotation has been achieved.
Patent Information
- Application Number
- CN202411165685.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-23
- Publication Date
- 2025-12-09
- Estimated Expiration
- 2044-08-23
AI Technical Summary
In existing technologies, due to limitations in equipment resources, the resolution of spatial transcriptome information is not high, making it difficult to accurately map single-cell sequencing data to it. This results in low accuracy of cell type annotation in biological samples and tissues, especially in high-density cell clusters.
By acquiring spatial transcriptome data and single-cell sequencing data from sample tissues, segmentation and recognition tools are used to determine reference annotation information and multimodal prior information for single cells. Combined with predicted annotation information, joint annotation processing is performed, and the parameters of the annotation model are adjusted to improve annotation accuracy.
It enables high-resolution cell type annotation of biological samples and tissues, improving the accuracy and comprehensiveness of cell type annotation, and enabling a better understanding of the morphological and spatial distribution characteristics of single cells.
Smart Images

Figure CN119108025B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of biological information analysis, and particularly relates to a training method of an annotation model, a cell type annotation method and related equipment. BACKGROUND
[0002] Cell type annotation is a process of identifying and classifying different cell types in a biological sample. Cell type annotation helps research on cells and promotes the development of biological technology.
[0003] In related technologies, the cell positions of each spatial site of a biological sample tissue are obtained by using spatial transcriptome information, and the corresponding cell type annotation of the biological sample tissue is determined based on the spatial positions and single-cell sequencing data. However, due to the limitation of device resources, the resolution of the obtained spatial transcriptome information is usually not high. When cells in the biological sample tissue gather to form a high-density cell aggregation area, there may be multiple cells in the same spatial site. In this case, it is difficult to accurately map the single-cell sequencing data to the spatial transcriptome information, thereby causing the low accuracy of the cell type annotation of the biological sample tissue in related technologies. SUMMARY
[0004] The main purpose of the embodiments of the present application is to provide a training method of an annotation model, a cell type annotation method and related equipment, which aims to improve the accuracy of cell type annotation of a biological sample tissue.
[0005] To achieve the above-mentioned purpose, a first aspect of the embodiments of the present application provides a training method of an annotation model, which comprises the following steps:
[0006] Obtaining sample tissue data, and spatial transcriptome data and single-cell sequencing data corresponding to the sample tissue data, and inputting the spatial transcriptome data and the single-cell sequencing data into an initial annotation model;
[0007] Determining the reference annotation information corresponding to each target single cell in each spatial site of the sample tissue data according to the single-cell sequencing data, with the spatial transcriptome data as a constraint condition;
[0008] Determining the multi-modal prior information corresponding to each target single cell based on the reference annotation information and the spatial transcriptome data, and determining the predicted annotation information corresponding to the target single cell according to the multi-modal prior information;
[0009] Jointly annotating each target single cell according to the reference annotation information and the predicted annotation information to obtain a sample annotation result corresponding to the sample tissue data;
[0010] The model parameters of the initial annotation model are adjusted according to the sample annotation result, and a trained annotation model is obtained.
[0011] In some embodiments, according to the single-cell sequencing data, reference annotation information corresponding to each target single cell in each spatial site of the sample tissue data is determined under the constraint of the spatial transcriptome data, including:
[0012] The spatial transcriptome data is deconstructed using a preset segmentation tool to obtain a cell number value representing the number of single cells in each spatial site of the sample tissue data, and a cell coordinate position representing the spatial position of each target single cell;
[0013] The first gene expression information of the corresponding target single cell is determined at each cell coordinate position using the single-cell sequencing data, and a first logarithmic operation result is determined according to the cell number value and the first gene expression information;
[0014] The first logarithmic operation result is added to a preset batch variable value and a preset noise variable value to obtain the reference annotation information of the target single cell.
[0015] In some embodiments, based on the reference annotation information and the spatial transcriptome data, multi-modal prior information corresponding to each target single cell is determined, including:
[0016] According to the reference annotation information corresponding to the target single cell and the reference annotation information corresponding to the neighbor single cells of the target single cell, a cell spatial distribution feature of the target single cell in the corresponding spatial site is determined;
[0017] Using a preset recognition tool, morphological recognition processing is performed on the corresponding target single cell at the cell coordinate position to obtain a cell morphological feature of the target single cell;
[0018] Based on the cell spatial distribution feature and the cell morphological feature, multi-modal prior information corresponding to each single cell is determined.
[0019] In some embodiments, according to the multi-modal prior information, predicted annotation information corresponding to the target single cell is determined, including:
[0020] Based on the cell spatial distribution feature, the cell type to which the target single cell belongs is predicted to obtain first prior information;
[0021] Based on the cell morphological feature, the cell type to which the target single cell belongs is predicted to obtain second prior information;
[0022] The product of the first prior information and the second prior information is calculated to obtain multi-modal product data;
[0023] Using the multi-modal product data, second gene expression information of the corresponding target single cell is determined at each cell coordinate position.
[0024] Based on the second gene expression information, determine the predicted annotation information corresponding to the target single cell.
[0025] In some embodiments, according to the reference annotation information corresponding to the target single cell and the reference annotation information corresponding to the neighbor single cell of the target single cell, determine the cell spatial distribution feature of the target single cell at the corresponding spatial site, including:
[0026] If the reference annotation information corresponding to the target single cell is different from the reference annotation information corresponding to the neighbor single cell, obtain a first constraint value;
[0027] If the reference annotation information corresponding to the target single cell is the same as the reference annotation information corresponding to the neighbor single cell, obtain a second constraint value;
[0028] Based on the first constraint value or the second constraint value, obtain the cell spatial distribution feature of the target single cell at the corresponding spatial site.
[0029] In some embodiments, according to the reference annotation information and the predicted annotation information, jointly annotate each target single cell to obtain a sample annotation result corresponding to the sample tissue data, including:
[0030] Based on a preset first weight parameter, update the reference annotation information, and based on a preset second weight parameter, update the predicted annotation information;
[0031] According to the updated reference annotation information and the updated predicted annotation information, jointly annotate each target single cell to obtain a sample cell annotation result corresponding to the sample tissue data.
[0032] In some embodiments, the second weight parameter is obtained by the following steps, including:
[0033] Obtain a sample verification result corresponding to the sample tissue data, and an initial second weight parameter and an initial adjustment ratio;
[0034] If the sample annotation result is different from the sample verification result, update the initial adjustment ratio to obtain an adjustment ratio;
[0035] Based on the adjustment ratio, update the initial second weight parameter to obtain the second weight parameter.
[0036] To achieve the above object, a second aspect of the embodiment of the present application proposes a cell type annotation method, the method comprising:
[0037] Obtain sample tissue data, spatial transcriptome data and single cell sequencing data corresponding to the sample tissue data, and input the spatial transcriptome data and the single cell sequencing data into an initial annotation model;
[0038] The reference annotation information of each target single cell in each spatial site of the sample tissue data is determined according to the single cell sequencing data under the constraint condition of the spatial transcriptome data;
[0039] Based on the reference annotation information and the spatial transcriptome data, the multi-modal prior information corresponding to each target single cell is determined, and the predicted annotation information corresponding to the target single cell is determined according to the multi-modal prior information;
[0040] According to the reference annotation information and the predicted annotation information, the joint annotation processing is performed on each target single cell to obtain the sample annotation result corresponding to the sample tissue data;
[0041] The model parameters of the initial annotation model are adjusted according to the sample annotation result to obtain a trained annotation model;
[0042] The target tissue data, the target spatial transcriptome data and the target single cell sequencing data corresponding to the target tissue data are obtained, and the target spatial transcriptome data and the target single cell sequencing data are input into the trained annotation model;
[0043] According to the target spatial transcriptome data and the target single cell sequencing data, the joint annotation processing is performed on the target tissue data to obtain the target cell annotation result corresponding to the target tissue data.
[0044] To achieve the above-mentioned purpose, a third aspect of an embodiment of the present application provides a cell type annotation device, the device comprising:
[0045] The acquisition module is configured to acquire sample tissue data, spatial transcriptome data and single cell sequencing data corresponding to the sample tissue data, and input the spatial transcriptome data and the single cell sequencing data into an initial annotation model;
[0046] The reference annotation module is configured to determine reference annotation information of each target single cell in each spatial site of the sample tissue data according to the single cell sequencing data under the constraint condition of the spatial transcriptome data;
[0047] The prediction annotation module is configured to determine multi-modal prior information corresponding to each target single cell based on the reference annotation information and the spatial transcriptome data, and determine predicted annotation information corresponding to the target single cell according to the multi-modal prior information;
[0048] The annotation processing module is configured to perform joint annotation processing on each target single cell according to the reference annotation information and the predicted annotation information to obtain a sample annotation result corresponding to the sample tissue data;
[0049] The training module is configured to adjust model parameters of the initial annotation model according to the sample annotation result to obtain a trained annotation model;
[0050] The first target processing module is configured to acquire target tissue data, target spatial transcriptome data corresponding to the target tissue data, and target single-cell sequencing data, and input the target spatial transcriptome data and the target single-cell sequencing data into the trained annotation model.
[0051] The second target processing module is configured to perform joint annotation processing on the target tissue data according to the target spatial transcriptome data and the target single-cell sequencing data, to obtain target cell annotation results corresponding to the target tissue data.
[0052] To achieve the above object, a fourth aspect of the embodiment of the present application provides an electronic device, which comprises a memory and a processor, the memory stores a computer program, and the processor implements the method of the first aspect or the method of the second aspect when executing the computer program.
[0053] To achieve the above object, a fifth aspect of the embodiment of the present application provides a computer readable storage medium, which stores a computer program, and the computer program is executed by a processor to implement the method of the first aspect or the method of the second aspect.
[0054] The cell type annotation method and device, the electronic device and the storage medium provided by the present application can acquire sample tissue data, spatial transcriptome data corresponding to the sample tissue data, and single-cell sequencing data, and input the spatial transcriptome data and the single-cell sequencing data into an initial annotation model; determine reference annotation information corresponding to each target single cell in each spatial site of the sample tissue data according to the single-cell sequencing data, with the spatial transcriptome data as a constraint condition; determine multi-modal prior information corresponding to each target single cell based on the reference annotation information and the spatial transcriptome data, and determine predicted annotation information corresponding to the target single cell according to the multi-modal prior information; the multi-modal prior information can further reveal the cell morphological characteristics of each target single cell itself and the cell spatial characteristic relationship between the target single cell and adjacent single cells in the spatial site, so that the annotation device can better understand each target single cell; perform joint annotation processing on each target single cell according to the reference annotation information and the predicted annotation information, to obtain sample annotation results corresponding to the sample tissue data; the reference annotation information can be better mapped with the spatial transcriptome data through mutual complementation of the reference annotation information and the predicted annotation information, and thus the annotation accuracy and comprehensiveness of the annotation model for the target single cell can be improved; adjust model parameters of the initial annotation model according to the sample annotation results, to obtain a trained annotation model, and the annotation model can perform cell annotation processing on input target tissue data at a single-cell resolution accuracy, thereby improving the accuracy of cell type annotation of biological sample tissue. BRIEF DESCRIPTION OF DRAWINGS
[0055] Figure 1is an application scenario schematic diagram of a training device of an annotation model provided by an embodiment of the present application;
[0056] Figure 2 is an optional flowchart of a training method of an annotation model provided by an embodiment of the present application;
[0057] Figure 3 is an optional flowchart of a cell type annotation method provided by an embodiment of the present application;
[0058] Figure 4 is an optional functional module schematic diagram of a cell type annotation device provided by an embodiment of the present application;
[0059] Figure 5 is a hardware structure schematic diagram of an electronic device provided by an embodiment of the present application. DETAILED DESCRIPTION
[0060] In order to make the purposes, technical solutions and advantages of the present application clearer, the present application is further described in detail below in combination with the drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and do not limit the present application.
[0061] It should be noted that although the functional modules are divided in the device schematic diagram, and the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in a different order than the module division in the device or the order in the flowchart. The terms "first", "second", etc. in the specification and claims and the above-described drawings are used to distinguish similar objects, and do not necessarily describe a specific order or sequence.
[0062] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which the present application belongs. The terms used herein are only for the purpose of describing the embodiments of the present application and are not intended to limit the present application.
[0063] First, the meanings of several terms involved in the present application are analyzed:
[0064] Spatial transcriptomics (ST) sequencing technology aims to retain the precise spatial positioning of cells while measuring gene expression within cells, which is of great significance to the study of growth and development and the occurrence and development of diseases.
[0065] The indicator function is usually defined as a function f(x), where x is a point in the set or region, and f(x) is 1 when x belongs to the set or region; otherwise, f(x) is 0.
[0066] Normalization constant, a concept from mathematical probability theory, refers to a constant contained in any interval of a non-negative function, which makes the integral of the function over a certain interval equal to 1. The concept is usually introduced to convert the function into a probability density function or a probability mass function.
[0067] Potts model, an important theoretical model in statistical physics and condensed matter physics, is mainly used to describe the interaction of particles or spins in a lattice system and their macroscopic properties.
[0068] Maximum A Posteriori (MAP) describes the relationship between prior probability, likelihood function and posterior probability, and estimates model parameters by maximizing posterior probability, where posterior probability refers to the probability distribution of model parameters given the observed data. The goal of the MAP method is to find the best model parameter value that maximizes the posterior probability given the observed data.
[0069] Cell Type Annotation is the process of identifying and classifying different cell types in biological samples. Cell Type Annotation helps researchers study cells and promote the development of biotechnology.
[0070] In related technologies, spatial transcriptome information is used to obtain the cell positions of each spatial site in the biological sample tissue, and based on the spatial position and single-cell sequencing data, the corresponding cell type annotation of the biological sample tissue is determined. However, due to equipment resource limitations, the resolution of the obtained spatial transcriptome information is usually not high; when cells in the biological sample tissue gather to form a high-density cell aggregation area, there may be multiple cells in the same spatial site, in which case it is difficult to accurately map single-cell sequencing data to spatial transcriptome information, resulting in low accuracy of cell type annotation of biological sample tissue in related technologies.
[0071] Therefore, the embodiments of the present application provide a training method of an annotation model, a cell type annotation method and related equipment to improve the accuracy of cell type annotation of biological sample tissue.
[0072] It should be noted that in the embodiments of the present application, when it is necessary to obtain information related to the user's basic information, user identity or characteristics, the user's permission or consent will be obtained first, and the collection, use and processing of these data will comply with relevant laws, regulations and standards. In addition, when the embodiments of the present application need to obtain sensitive personal information of the user, the separate permission or separate consent of the user will be obtained first, and after obtaining the separate permission or separate consent of the user, the necessary data for enabling the embodiments of the present application to operate normally will be obtained, for example, when obtaining a sample tissue containing user sample tissue data to perform the training method of the annotation model or the cell type annotation method proposed in the embodiments of the present application, the consent of the relevant user will be obtained, otherwise the sample tissue data used in the embodiments of the present application cannot be obtained.
[0073] The training method of the annotation model, the cell type annotation method and the related equipment provided by the embodiments of the present application are specifically described by the following embodiments. First, the application scenario of the cell type annotation device in the embodiments of the present application is described, wherein the training method of the annotation model (for the sake of brevity, it can also be referred to as “training method” hereinafter) provided by the embodiments of the present application can be applied to the cell type annotation device (for the sake of brevity, it can also be referred to as “annotation device” hereinafter). The initial annotation model proposed in the embodiments of the present application is arranged in the annotation device, and the initial annotation model can obtain the annotation model after being trained by the training method. As shown in Figure 1 Figure 1 is a schematic diagram of an application scenario of the training device of the annotation model provided by the embodiments of the present application. First, the target spatial transcriptome data and the target single-cell sequencing data corresponding to the target sample tissue are obtained, wherein Figure 1 One small circle in the target spatial transcriptome data represents one spatial site. One spatial site usually includes multiple single cells, but due to various factors such as limited device resources, the obtained target spatial transcriptome data usually has low resolution. Then, the target spatial transcriptome data and the target single-cell sequencing data are input into the annotation device. The annotation device processes the target spatial transcriptome data and the target single-cell sequencing data, and outputs the target cell annotation result representing the cell type results of each target single cell in the target sample tissue. The multiple single cells in each spatial site in the target cell annotation result can be labeled. Compared with the results obtained by using the cell annotation method of the related art, the cell type annotation results corresponding to each single cell in the target sample tissue obtained by the embodiments of the present application have higher accuracy.
[0074] Then, the training method of the annotation model in the embodiments of the present application is specifically described by the following embodiments.
[0075] In the embodiments of the present application, the annotation device will be described from the dimension, which can be integrated in a computer device, such as a server. As shown in Figure 2 Figure 2 is an optional flowchart of the training method of the annotation model provided by the embodiments of the present application, Figure 2 The method in the above embodiment can include, but is not limited to, steps 101-105. When the annotation device executes the training method of the annotation model, the specific process is as follows. It should be first pointed out that the order of steps 101-105 in the above embodiment is not specifically limited, and the order of steps can be adjusted or some steps can be reduced or added according to actual needs. Figure 2
[0076] Step 101, obtaining sample tissue data, and spatial transcriptome data and single-cell sequencing data corresponding to the sample tissue data, and inputting the spatial transcriptome data and single-cell sequencing data into an initial annotation model.
[0077] The step 101 is described in detail below.
[0078] The sample tissue data is obtained from the sample tissue, which is a slice structure based on a specific tissue or organ in a living organism. The living organism can be an individual with life activities, including but not limited to microorganisms, plants, animals, etc. When the living organism is an animal, the specific tissue can be an epithelial tissue, a muscle tissue, a neural tissue, etc. formed by cells with similar morphology, structure and function and intercellular substance combined together, and the organ can be a structure such as heart, lung, liver, etc. After obtaining the sample tissue, the content in the sample tissue is converted into sample tissue data that can be recognized and processed by a computer using related biological equipment. The sample tissue data can be in the form of matrix data, list data or array data, etc. In addition, the sample tissue data can be converted into an image according to actual needs, so that the annotation device or other related equipment can better process the data.
[0079] It should be noted that the source of the sample tissue is not limited in the embodiments of the present application, as long as the sample tissue includes cells that need to be recognized and annotated. Meanwhile, the sample tissue data obtained based on the sample tissue is not limited in the embodiments of the present application, and can be set according to actual conditions.
[0080] The spatial transcriptome data is obtained by spatial transcriptome technology, and the spatial transcriptome data includes rough gene spatial expression data and staining image data. The gene spatial expression data can reflect the average gene expression of each spatial site in the sample tissue. The staining image data is the result of staining the sample tissue according to the gene spatial expression data to highlight different cell types or structures.
[0081] The spatial transcriptomics technology refers to using specific probes (such as spatial barcode probes in the 10x Genomics Visium platform) to capture the gene expression of each spatial site in the sample tissue. The spatial site refers to a different spatial region in the sample tissue data. It can be understood that each spatial site actually includes multiple single cells, and the cell annotation result obtained by the related technology is the average gene expression of each spatial site. That is, the spatial transcriptome data obtained by the related technology can retain the spatial position information of the cells and the corresponding average gene expression information to a certain extent. The average gene expression information is the average gene expression of all single cells in the spatial site, but not the gene expression of a single cell, so the resolution is low.
[0082] The single cell sequencing data (scRNA-seq) can realize sequencing by transcribing a single cell, and thus can have a deeper understanding of the type and expression mode of the single cell in the tissue. However, the scRNA-seq cannot obtain the original spatial position information of the single cell. In addition, in order to reveal the heterogeneous expression of cells in the sample tissue data, usually multiple single cell sequencing data are used to transcribe single cells of different types.
[0083] Therefore, in order to realize that the annotation device can finally output the target cell annotation result with high resolution, the spatial transcriptome data and the single cell sequencing data of the sample tissue are first obtained. The device in the annotation device can be configured to process the sample tissue to obtain the spatial transcriptome data and the single cell sequencing data. The related device can also be accessed through the interface to obtain the spatial transcriptome data and the single cell sequencing data of the sample tissue. The specific configuration can be set according to the actual situation, and the present application does not limit this. Then, the obtained spatial transcriptome data and single cell sequencing data are input into the initial annotation model. The initial annotation model refers to a model that has not been trained by the training method proposed in the present application.
[0084] In step 102, the reference annotation information corresponding to each target single cell in each spatial site of the sample tissue data is determined according to the single cell sequencing data under the constraint condition of the spatial transcriptome data.
[0085] The step 102 is described in detail below.
[0086] In some embodiments, the spatial sites of the sample tissue data are determined based on the spatial transcriptome data, and the reference annotation information corresponding to all target single cells in each spatial site is obtained by transcribing a plurality of target single cells in the spatial site based on scRNA-seq. It can be understood that the reference annotation information can be accurate to the single cell level and has high resolution. The reference annotation information corresponding to each target single cell is used for joint processing of the target single cell together with the predicted annotation information in the subsequent process to finally obtain the sample annotation result.
[0087] In the process of training the annotation model, the single cells that need to be processed for cell annotation are referred to as target single cells in the embodiments of the present application. The target single cells can be all single cells in all spatial sites of the sample tissue data, or all single cells in part of the spatial sites of the sample tissue data, and the embodiments of the present application do not make specific limitations thereto.
[0088] In some embodiments, the reference annotation information corresponding to each target single cell in each spatial site of the sample tissue data is determined according to the single cell sequencing data under the constraint condition of the spatial transcriptome data, including the following steps 201 to 203:
[0089] Step 201, deconstructing the spatial transcriptome data by using a preset segmentation tool to obtain a cell number value representing the number of single cells possessed by each spatial site of the sample tissue data, and a cell coordinate position representing the spatial position of each target single cell.
[0090] Step 202, determining the first gene expression information of the corresponding target single cell at each cell coordinate position by using the single cell sequencing data, and determining the first logarithmic operation result according to the cell number value and the first gene expression information.
[0091] Step 203, adding the first logarithmic operation result to a preset batch variable value and a preset noise variable value to obtain the reference annotation information of the target single cell.
[0092] The steps 201 to 203 are described in detail below.
[0093] The segmentation tool can be a deep learning tool for cell nucleus segmentation, such as StarDist, Cellpose, etc. Of course, the segmentation tool can be selected according to the actual situation, and the present application does not make specific limitations thereto.
[0094] Exemplarily, after obtaining the spatial transcriptome data, the embodiment of the application uses StarDist to perform structural processing on the spatial transcriptome data, and obtains that the cell number value of the spatial site A is 2, indicating that there are 2 single cells in the spatial site A; and since the staining image data is static data, the cell coordinate positions of the 2 single cells can be further obtained, such as the cell coordinate position of the target single cell a1 in the spatial site A is (x1, y1, z1), and the cell coordinate position of the target single cell a2 is (x2, y2, z2), wherein xyz is used to represent three different dimensions of the spatial coordinate.
[0095] Further, after obtaining the number of target single cells contained in each spatial site and the cell coordinate information of each target single cell, the target single cells are transcribed at each cell coordinate position using single cell sequencing data to obtain first gene expression information; then, on the basis of the first gene expression, the reference annotation information y of the target single cell is further obtained according to the following formula (1) i,g :
[0096]
[0097] wherein y i,g is the gene expression observed by the gth gene in the ith spatial site, N i is the total gene expression observed by the ith spatial site, λ i,g is the relative gene expression of the gth gene in the ith spatial position; Poisson is a Poisson distribution, which represents that y i,g obeys the Poisson distribution; represents the gene expression of the gth gene in the ith spatial site obtained by the kth scRNA-seq transcription; M represents the cell number value of the spatial site; is the first logarithmic operation result; γ g is a batch variable value, which is used to explain the batch effect of the gth gene expression between scRNA-seq and spatial transcriptome data, so as to more flexibly process the complex heterogeneity between the spatial transcriptome data obtained by different platforms, and γ g is randomly obtained, which can be set according to actual conditions; ∈ g is a noise variable value, which is introduced by randomly obtaining the noise variable value, so as to more reasonably evaluate the similarity and difference between different target single cells, thereby promoting the effective integration of data in the processing process.
[0098] In step 103, based on the reference annotation information and the spatial transcriptome data, the multi-modal prior information corresponding to each target single cell is determined, and the predicted annotation information corresponding to the target single cell is determined according to the multi-modal prior information.
[0099] The step 103 is described in detail as follows.
[0100] In some embodiments, since the reference annotation information is obtained based on the cell quantity value and the cell coordinate position, but for the first gene expression information obtained by the scRNA-seq transcription, it is not determined which target single cell in the spatial site the obtained first gene expression information is transcribed from, that is, the first gene expression information cannot be well mapped with the spatial transcriptome data, so the reference annotation information obtained is the average gene expression of all target single cells in the spatial site, and the resolution is low. The present application embodiment will further process the spatial transcriptome data based on the reference annotation information to obtain the predicted annotation information for enhancing the resolution of the final output result.
[0101] In some embodiments, based on the reference annotation information and the spatial transcriptome data, the multi-modal prior information corresponding to each target single cell is determined, including the following steps 301 to 303:
[0102] Step 301, according to the reference annotation information corresponding to the target single cell and the reference annotation information corresponding to the neighbor single cell of the target single cell, the cell spatial distribution feature of the target single cell in the corresponding spatial site is determined.
[0103] Step 302, using a preset recognition tool, the morphological recognition processing of the target single cell at the cell coordinate position is performed to obtain the cell morphological feature of the target single cell.
[0104] Step 303, based on the cell spatial distribution feature and the cell morphological feature, the multi-modal prior information corresponding to each single cell is determined.
[0105] The steps 301 to 303 are described in detail as follows.
[0106] In some embodiments, in order to further improve the resolution of the annotation of the target single cell, it is also necessary to determine the multi-modal prior information corresponding to the target single cell according to the reference annotation information and the spatial transcriptome data. The multi-modal prior information can further reveal the cell morphological feature of each target single cell itself in the spatial site and the cell spatial feature relationship between the target single cell and the adjacent single cell, so that the annotation device can better understand each target single cell, thereby improving the accuracy of cell annotation.
[0107] Further, the different cell morphology features of each single cell can reflect the biological classification, cell type, physiological function, reproductive mode, and disease information of the cell. For example, in cancer sample tissue data, tumor cells usually have more irregular shapes, larger nuclear / cytoplasmic ratios, and more abundant organelles than normal cells, which reflect the malignant transformation process of tumor cells. Therefore, the annotation device can improve the annotation ability of cells by using the different cell morphology features of different cells.
[0108] The neighbor single cells of the target single cell refer to other single cells adjacent or close to the target single cell in spatial position. The spatial position here includes two-dimensional space and three-dimensional space.
[0109] Further, after understanding the cell spatial distribution of each spatial site based on the reference annotation information, the morphology of each target single cell in the spatial site is identified to obtain the cell morphology features of each target single cell, so that the subsequent annotation device can better map the results of single cell sequencing data transcription to the multiple target single cells in the spatial site based on the cell morphology features, thereby improving the accuracy of cell annotation.
[0110] The identification tool can be a classic cell profile tool, a tool trained by a convolutional neural network, etc. The identification tool can be specifically selected according to actual conditions, and the embodiments of the present application do not limit this.
[0111] In some embodiments, the cell spatial distribution features of the target single cell in the corresponding spatial site are determined according to the reference annotation information of the target single cell and the reference annotation information of the neighbor single cells of the target single cell, including the following steps 401 to 403:
[0112] Step 401: If the reference annotation information of the target single cell is different from the reference annotation information of the neighbor single cells, a first constraint value is obtained.
[0113] Step 402: If the reference annotation information of the target single cell is the same as the reference annotation information of the neighbor single cells, a second constraint value is obtained.
[0114] Step 403: Based on the first constraint value or the second constraint value, the cell spatial distribution features of the target single cell in the corresponding spatial site are obtained.
[0115] The steps 401 to 403 are described in detail below.
[0116] In some embodiments, after determining the reference annotation information corresponding to the current target single cell and the reference annotation information corresponding to the neighbor single cells of the target single cell, the cell spatial distribution feature v of the target single cell at the corresponding spatial site is determined based on the following formula (2):
[0117]
[0118] wherein, is an indicator function, and k denotes the reference annotation information corresponding to the target single cell i,m , wherein k denotes the reference annotation information of the mth single cell at the ith spatial site i′,m′ ; when k i,m = k i′m′ , a first constraint value is obtained, which can be 1; when k i,m ≠ k i′m′ , a second constraint value is obtained, which can be 0; the cell spatial distribution feature v is used to represent the spatial smoothness of the target single cell at the corresponding spatial site, and the greater v is, the smoother the distribution of the target single cells in the spatial site is; the cell spatial distribution feature can be realized by a Potts model provided in the annotation device.
[0119] Further, for example, in the central nervous system, neurons of the same type are often arranged continuously along a specific anatomical path to form a neural nucleus or a neural fiber bundle, and such an orderly spatial distribution is closely related to the relevant functions of the neurons. Determining the cell spatial distribution feature helps the annotation model to understand the shared features between the target single cells more finely, thereby helping to improve the ability of cell annotation subsequently.
[0120] In some embodiments, the predicted annotation information corresponding to the target single cell is determined according to the multi-modal prior information, including the following steps 501 to 505:
[0121] Step 501, predicting the cell type to which the target single cell belongs based on the cell spatial distribution feature to obtain first prior information.
[0122] Step 502, predicting the cell type to which the target single cell belongs based on the cell morphological feature to obtain second prior information.
[0123] Step 503, calculating the product of the first prior information and the second prior information to obtain multi-modal product data.
[0124] Step 504, determining the second gene expression information of the corresponding target single cell at each cell coordinate position by using the multi-modal product data;
[0125] Step 505, determining the predicted annotation information corresponding to the target single cell based on the second gene expression information.
[0126] The steps 501 to 505 are described in detail below.
[0127] In some embodiments, the cell type to which the target single cell belongs is predicted based on obtained multi-modal prior information, and a plurality of prior information is obtained; the prior information is an important reference for judging the cell type of the target single cell, and can help the annotation device to enhance the accuracy of cell type annotation.
[0128] Further, the cell type to which the target single cell belongs is predicted by the following formula (3) to obtain first prior information:
[0129]
[0130] wherein, is a cell spatial distribution feature; Z is a normalization constant; is a set of adjacent points of the mth cell at the ith spatial position; exp() is an exponential operation with a base number e as a base number.
[0131] Further, a classifier provided in the annotation device is used to predict the cell type to which the target single cell belongs based on the cell morphology feature, and second prior information p(k i,m |E i,m ), wherein E i,m ∈R H , H is the dimension of the cell morphology feature. The second prior information p(k i,m |E i,m ) essentially corresponds to the conditional distribution probability under the classification problem, therefore, a data set collected in advance is used to train the constructed classifier to approximate the expected result p(k i,m |E i,m ), and the classifier can be
[0132] wherein the classifier can be a support vector machine, a random forest classifier, a neural network classifier, etc., and the specific type of the classifier can be set according to actual conditions, and the embodiments of the present application do not limit this. The classifier can be provided in the initial annotation model, so as to be jointly trained with the initial annotation model in the training process, so as to improve the generalization ability of the annotation model obtained after training.
[0133] Further, the multi-modal product data p(k i,m |k -{i,m} , E i,m ) = p(k i,m |E i,m ) x p(k i,m |k -{i,m} ) is obtained. Then, the second gene expression information p(ki,m | k -{i,m} , E i,m ):
[0134] p(k i,m | k -{i,m} , E i,m ) = p(k i,m | E i,m ) x p(k i,m | k -{i,m} ) x const (4)
[0135] wherein const is an error constant, which can be adaptively adjusted according to actual conditions.
[0136] Further, in the case of determining the second gene expression information, the logarithmic operation result of the second gene expression information is determined as the predicted annotation information p(k i,m | k -{i,m} , E i,m ).
[0137] Step 104, according to the reference annotation information and the predicted annotation information, performing joint annotation processing on each target single cell to obtain a sample annotation result corresponding to the sample tissue data.
[0138] In some embodiments, in the case of obtaining the sample annotation result corresponding to the sample tissue data by performing joint annotation processing on each target single cell in the spatial site according to the reference annotation information and the predicted annotation information, the reference annotation information can be better mapped with the spatial transcriptome data through mutual complementation of the reference annotation information and the predicted annotation information, thereby improving the annotation accuracy and comprehensiveness of the annotation model for the target single cell.
[0139] In some embodiments, according to the reference annotation information and the predicted annotation information, performing joint annotation processing on each target single cell to obtain a sample annotation result corresponding to the sample tissue data comprises the following steps 601 to 602:
[0140] Step 601, updating the reference annotation information based on a preset first weight parameter, and updating the predicted annotation information based on a preset second weight parameter.
[0141] Step 602, according to the updated reference annotation information and the updated predicted annotation information, performing joint annotation processing on each target single cell to obtain a sample cell annotation result corresponding to the sample tissue data.
[0142] The steps 601 to 602 are described in detail as follows.
[0143] In some embodiments, the reference annotation information and the predicted annotation information are jointly processed by using a maximum a posteriori estimation method to determine the sample cell annotation result k i,m wherein i = 1, 2, … I, and m = 1, 2, …, M.
[0144]
[0145] wherein logp(k i,m ) is equivalent to logp(k i,m | k -{i,m} , E i,m ), and log(λ i,g ) is equivalent to ; argmax is used to represent the processing result with the largest value; specifically, logp(k i,m ) is taken as a prior term of formula (5), and is taken as a likelihood term of formula (5) to incorporate the prior information into the process of annotation model estimation, and the sample cell annotation result is obtained by maximizing the posterior.
[0146] Further, the annotation model can further set a first weight parameter such as a and a second weight parameter β for the reference annotation information, and then in another embodiment, the sample annotation result can be determined by formula (6) as follows
[0147]
[0148] wherein is the updated reference annotation information, and βlogp(k i,m ) is the updated predicted annotation information; then, each target single cell is jointly annotated and processed in the same manner as formula (5) to obtain the sample cell annotation result corresponding to the sample tissue data
[0149] It should be noted that the first weight parameter and the second weight parameter can be continuously self-adaptively adjusted in the training process until the annotation model after the training is completed, that is, the specific values of the first weight parameter and the second weight parameter are not limited in the embodiments of the present application.
[0150] In some embodiments, the second weight parameter is obtained by the following steps 701 to 703:
[0151] Step 701: obtaining a sample verification result corresponding to the sample tissue data, and an initial second weight parameter and an initial adjustment ratio.
[0152] Step 702: if the sample annotation result is different from the sample verification result, updating the initial adjustment ratio to obtain an adjustment ratio.
[0153] At step 703, the initial second weight parameter is updated based on the adjustment ratio to obtain the second weight parameter.
[0154] The steps 701-703 are described in detail as follows.
[0155] In some embodiments, since the second weight parameter is related to the predicted annotation result, the second weight parameter can be quickly adjusted by comparing the difference between the predicted annotation information and the reference annotation information, so as to improve the efficiency of obtaining the second weight parameter in the training process.
[0156] Further, the initial second weight parameter is allocated to the annotation model in the initial training stage, and the initial adjustment ratio representing the adjustment rate of the initial second weight parameter is obtained. Then, after the annotation model outputs a sample annotation result, the initial adjustment ratio is updated to obtain the adjustment ratio by comparing the sample organization data with the sample verification result. If the sample organization data is different from the sample verification result, or the difference between the sample organization data and the sample verification result exceeds a preset threshold, the initial adjustment ratio is updated to obtain the adjustment ratio. Then, the adjustment ratio is multiplied by the initial second weight parameter to obtain the second weight parameter.
[0157] It can be understood that, if the sample organization data is different from the sample verification result, it indicates that the accuracy of mapping the annotation result to the target single cell is still not enough when the annotation model jointly processes the predicted annotation result and the reference annotation result. In the case that the reference annotation result is accurately obtained from the single cell sequencing data, the accuracy of mapping the annotation result can be improved by adjusting the attention degree (the second weight parameter) of the annotation model to the predicted annotation result. Since the adjustment ratio is introduced, the updated second weight parameter can be obtained at the same time when the first weight parameter is determined, which accelerates the speed of obtaining the output result of the annotation model next time, and thus improves the training efficiency of the annotation model as a whole.
[0158] It should be noted that the initial second weight parameter and the initial adjustment ratio can be obtained according to actual conditions, and the embodiments of the present application do not limit this.
[0159] At step 105, the model parameter of the initial annotation model is adjusted according to the sample annotation result to obtain the trained annotation model.
[0160] The step 105 is described in detail as follows.
[0161] In some embodiments, to better achieve the training of the initial annotation model, a sample verification result corresponding to the sample tissue data can be obtained in advance, the sample verification result being used to represent an output result of the initial annotation model under an ideal condition after the sample tissue data is input into the initial annotation model; the sample verification result is compared with an actual output sample annotation result, a loss value calculated based on the sample verification result and the sample annotation result, and the model parameters of the initial annotation model are adjusted based on the loss value, and the model parameters are continuously updated based on the continuously obtained sample annotation result until a preset training condition is reached, and the trained annotation model is obtained.
[0162] The model parameters can be a learning rate, a number and / or size of hidden layers of a convolutional network, a size of a convolution kernel, a regularization parameter, etc., and the model parameters that need to be adjusted by the annotation model can be set according to actual conditions, which are not limited in the present application.
[0163] The training condition can be a preset training time or a preset training number of times, etc., which is not limited in the embodiments of the present application and can be adjusted according to actual conditions.
[0164] In addition, the annotation device can also execute the cell type annotation method proposed in the embodiments of the present application, as shown in Figure 3 , the cell type annotation method provided in the embodiments of the present application is an optional flowchart, Figure 3 The method in the embodiments of the present application can include but is not limited to steps 801 to 807, and the specific process of the annotation device when executing the cell type annotation method is as follows. It needs to be first pointed out that the order of steps 801 to 807 in the embodiments is not limited, and the order of steps can be adjusted or some steps can be reduced or added according to actual needs. Figure 3 Figure 3 Step 801, obtaining sample tissue data, and spatial transcriptome data and single-cell sequencing data corresponding to the sample tissue data, and inputting the spatial transcriptome data and the single-cell sequencing data into an initial annotation model.
[0165] Step 802, determining reference annotation information corresponding to each target single cell in each spatial site of the sample tissue data according to the single-cell sequencing data under the constraint condition of the spatial transcriptome data.
[0166] Step 803, determining multi-modal prior information corresponding to each target single cell based on the reference annotation information and the spatial transcriptome data, and determining predicted annotation information corresponding to the target single cell according to the multi-modal prior information.
[0167] Step 803, determining multi-modal prior information corresponding to each target single cell based on the reference annotation information and the spatial transcriptome data, and determining predicted annotation information corresponding to the target single cell according to the multi-modal prior information.
[0168] Step 804: Based on the reference annotation information and the predicted annotation information, perform joint annotation processing on each target single cell to obtain the corresponding sample annotation results for the sample tissue data.
[0169] Step 805: Adjust the model parameters of the initial annotation model based on the sample annotation results to obtain the trained annotation model.
[0170] Step 806: Obtain the target tissue data, as well as the corresponding target spatial transcriptome data and target single-cell sequencing data, and input the target spatial transcriptome data and target single-cell sequencing data into the trained annotation model.
[0171] Step 807: Based on the target spatial transcriptome data and the target single-cell sequencing data, perform joint annotation processing on the target tissue data to obtain the corresponding target cell annotation results for the target tissue data.
[0172] Steps 801 to 807 are described in detail below.
[0173] Steps 801 to 805 are similar to steps 101 to 105, and will not be described in detail here. After obtaining the trained annotation model, the target spatial transcriptome data and target single-cell sequencing data of the acquired target tissue data are input into the annotation model. Then, the annotation model performs joint processing on the input data based on the adjusted model parameters and outputs the corresponding target cell annotation results of the target tissue data.
[0174] The output target cell annotation results can be expressed in the form of matrix data, and can be converted into image representations or other forms as needed. This application does not impose any limitations on this.
[0175] Understandably, annotation models can improve the accuracy of mapping between reference annotation information transcribed from target single-cell sequencing data and target single cells based on multimodal prior information obtained from target spatial transcriptome data. This enables the resolution of target cell annotation results to be accurate to each target single cell within each spatial site, thereby improving the accuracy of cell type annotation of sample tissue data and enhancing the quality of output target cell annotation results.
[0176] like Figure 4 As shown, Figure 4 This is a schematic diagram of an optional functional module of the cell type annotation device provided in this application embodiment, wherein the cell type annotation device may include:
[0177] The acquisition module 901 is used to acquire sample tissue data, as well as the corresponding spatial transcriptome data and single-cell sequencing data, and input the spatial transcriptome data and single-cell sequencing data into the initial annotation model.
[0178] Reference annotation module 902 is used to determine the corresponding reference annotation information for each target single cell in each spatial site of the sample tissue data based on single-cell sequencing data, using spatial transcriptome data as a constraint.
[0179] The predictive annotation module 903 is used to determine the corresponding multimodal prior information for each target single cell based on reference annotation information and spatial transcriptome data, and to determine the corresponding predictive annotation information for the target single cell based on the multimodal prior information.
[0180] The annotation processing module 904 is used to perform joint annotation processing on each target single cell based on the reference annotation information and the predicted annotation information to obtain the corresponding sample annotation results of the sample tissue data.
[0181] Training module 905 is used to adjust the model parameters of the initial annotation model based on the sample annotation results, so as to obtain the trained annotation model.
[0182] The first target processing module 906 is used to acquire target tissue data, as well as the corresponding target spatial transcriptome data and target single-cell sequencing data, and input the target spatial transcriptome data and target single-cell sequencing data into the trained annotation model.
[0183] The second target processing module 907 is used to perform joint annotation processing on the target tissue data based on the target spatial transcriptome data and the target single-cell sequencing data, so as to obtain the corresponding target cell annotation results of the target tissue data.
[0184] The specific implementation of this cell type annotation device is basically the same as the specific embodiment of the cell type annotation method described above, and will not be repeated here.
[0185] Furthermore, the cell type annotation device provided in this application can be used in downstream bioinformatics analysis scenarios, including but not limited to cell-cell type spatial distribution scenarios, immune microenvironment scenarios, cell-cell interaction scenarios, cell-environment interaction scenarios, etc.; of course, downstream analysis scenarios can also include more aspects, and the embodiments of this application do not limit this.
[0186] This application also provides an electronic device, which includes a memory and a processor. The memory stores a computer program, and the processor executes the computer program to implement the aforementioned cell type annotation method. This electronic device can be any smart terminal, including tablet computers, in-vehicle computers, etc.
[0187] like Figure 5 As shown, Figure 5 This is a schematic diagram of the hardware structure of an electronic device provided in an embodiment of this application. The electronic device includes:
[0188] The processor 1001 can be implemented by a general-purpose CPU (Central Processing Unit), a microprocessor, an ASIC (Application Specific Integrated Circuit), or one or more integrated circuits, etc., and is configured to execute related programs to implement the technical solutions provided by the embodiments of the present application.
[0189] The memory 1002 can be implemented by a ROM (Read Only Memory), a static storage device, a dynamic storage device, or a RAM (Random Access Memory), etc. The memory 1002 can store an operating system and other application programs. When the technical solutions provided by the embodiments of the present application are implemented by software or firmware, the related program codes are stored in the memory 1002 and are called and executed by the processor 1001 to implement the cell type annotation method of the embodiments of the present application.
[0190] The input / output interface 1003 is configured to implement information input and output.
[0191] The communication interface 1004 is configured to implement the communication interaction between the device and other devices. The communication can be implemented by a wired manner (for example, a USB, a network cable, etc.) or a wireless manner (for example, a mobile network, WIFI, Bluetooth, etc.).
[0192] The bus 1005 is configured to transmit information between various components (for example, the processor 1001, the memory 1002, the input / output interface 1003, and the communication interface 1004) of the device.
[0193] The processor 1001, the memory 1002, the input / output interface 1003, and the communication interface 1004 are connected to each other by the bus 1005 to realize the communication connection between them in the device.
[0194] The embodiments of the present application further provide a computer readable storage medium, which stores a computer program. The computer program is executed by a processor to implement the above-mentioned cell type annotation method.
[0195] Memory, as a non-transitory computer-readable storage medium, can be used to store non-transitory software programs and non-transitory computer-executable programs. In addition, the memory can include a high-speed random access memory and can also include a non-transitory memory, such as at least one magnetic disk storage device, a flash memory device, or other non-transitory solid-state memory device. In some embodiments, the memory can optionally include a memory disposed remotely from the processor, which can be connected to the processor through a network. Examples of the above network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0196] The embodiments described in the embodiments of the present application are used to more clearly illustrate the technical solutions of the embodiments of the present application, and do not constitute a limitation on the technical solutions provided by the embodiments of the present application. Those skilled in the art can know that, with the evolution of technology and the appearance of new application scenarios, the technical solutions provided by the embodiments of the present application are also applicable to similar technical problems.
[0197] Those skilled in the art can understand that the technical solutions shown in the figures do not constitute a limitation on the embodiments of the present application, and can include more or fewer steps than shown in the figures, or combine certain steps, or different steps.
[0198] The device embodiments described above are only schematic, and the units described as separate components can or can not be physically separate, i.e., can be located in one place, or can be distributed on multiple network units. Part or all of the modules can be selected according to actual needs to achieve the purpose of the embodiments of the present application.
[0199] Those skilled in the art can understand that all or some of the steps in the above disclosed method, the functional modules / units in the system and the device can be implemented as software, firmware, hardware and their appropriate combinations.
[0200] The terms "first", "second", "third", "fourth" and the like used in the specification of the present application and the above-described drawings, if any, are used to distinguish similar objects, and do not necessarily have to be used to describe a particular order or sequence. It should be understood that the data thus used can be interchanged under appropriate circumstances, so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein. In addition, the terms "include" and "have" and any variations thereof are intended to cover non-exclusive inclusion, for example, a process, method, system, product or device including a series of steps or units does not have to be limited to only those steps or units clearly listed, but can include other steps or units not clearly listed or inherent to these processes, methods, products or devices.
[0201] It should be understood that, in the application, "at least one" refers to one or more, and "multiple" refers to two or more. "And / or" is used to describe the association relationship of the associated objects, which means that there can be three relationships, for example, "A and / or B" can represent three cases of only A, only B, and A and B existing at the same time, wherein A and B can be singular or plural. The character " / " generally represents an "or" relationship between the associated objects before and after it. "At least one of the following" or similar expressions means any combination of these items, including any combination of single or multiple items. For example, at least one of a, b or c can represent a, b, c, "a and b", "a and c", "b and c", or "a and b and c", wherein a, b, and c can be single or multiple.
[0202] In several embodiments provided in the application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only illustrative, for example, the division of the above units is only a logical function division, and actual implementation can have another division manner, for example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the coupling or direct coupling or communication connection between the displayed or discussed units can be indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.
[0203] The units described above as separate components can or can not be physically separated, and the components shown as units can or can not be physical units, that is, they can be located in one place, or they can be distributed on multiple network units. According to actual needs, some or all of the units can be selected to achieve the purpose of the embodiment scheme.
[0204] In addition, the functional units in each embodiment of the application can be integrated in one processing unit, or each unit can exist physically, or two or more units can be integrated in one unit. The integrated unit can be realized in the form of hardware or in the form of a software functional unit.
[0205] The integrated unit, if implemented in the form of a software function unit and sold or used as an independent product, can be stored in a computer readable storage medium. Based on such understanding, the technical solutions of the present application, essentially or in other words, the part that contributes to the prior art or the whole or part of the technical solutions can be embodied in the form of a software product. The computer software product is stored in a storage medium, and includes multiple instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods of the various embodiments of the present application. The aforementioned storage medium includes: a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, and various program storage media.
[0206] The preferred embodiments of the embodiments of the present application are described above with reference to the accompanying drawings, and are not limited to the scope of the embodiments of the present application. Any modifications, equivalent replacements and improvements made by those skilled in the art without departing from the scope and essence of the embodiments of the present application shall be within the scope of the embodiments of the present application.
Claims
1. A method for training an annotation model, the method comprising: The method comprises: acquiring sample tissue data, and corresponding spatial transcriptome data and single-cell sequencing data of the sample tissue data, and inputting the spatial transcriptome data and the single-cell sequencing data into an initial annotation model; determining reference annotation information of each target single cell in each spatial site of the sample tissue data according to the single-cell sequencing data under the constraint condition of the spatial transcriptome data; determining multi-modal prior information of each target single cell based on the reference annotation information and the spatial transcriptome data, and determining predicted annotation information of the target single cell according to the multi-modal prior information; jointly annotating each target single cell according to the reference annotation information and the predicted annotation information to obtain sample annotation results corresponding to the sample tissue data; adjusting model parameters of the initial annotation model according to the sample annotation results to obtain a trained annotation model; the determination of the reference annotation information of each target single cell in each spatial site of the sample tissue data according to the single-cell sequencing data under the constraint condition of the spatial transcriptome data comprises: deconstructing the spatial transcriptome data by using a preset segmentation tool to obtain a cell number value representing the number of single cells in each spatial site of the sample tissue data, and a cell coordinate position representing the spatial position of each target single cell; determining first gene expression information of the corresponding target single cell at each cell coordinate position by using the single-cell sequencing data, and determining a first logarithm operation result according to the cell number value and the first gene expression information; adding the first logarithm operation result to a preset batch variable value and a preset noise variable value to obtain the reference annotation information of the target single cell.
2. The method of claim 1, wherein, the determination of the multi-modal prior information of each target single cell based on the reference annotation information and the spatial transcriptome data comprises: determining cell spatial distribution characteristics of the target single cell in the corresponding spatial site according to the reference annotation information of the target single cell and the reference annotation information of neighbor single cells of the target single cell; performing morphological identification processing on the corresponding target single cell at the cell coordinate position by using a preset identification tool to obtain cell morphological characteristics of the target single cell; determining the multi-modal prior information of each single cell based on the cell spatial distribution characteristics and the cell morphological characteristics.
3. The method of claim 2, wherein, the determination of the predicted annotation information of the target single cell according to the multi-modal prior information comprises: predicting the cell type to which the target single cell belongs based on the cell spatial distribution characteristics to obtain first prior information; predicting the cell type to which the target single cell belongs based on the cell morphological characteristics to obtain second prior information; calculating the product of the first prior information and the second prior information to obtain multi-modal product data; determining second gene expression information of the corresponding target single cell at each cell coordinate position by using the multi-modal product data; determine predicted annotation information corresponding to the target single cell based on the second gene expression information.
4. The method of claim 2, wherein, The determining of the cell spatial distribution feature of the target single cell at the spatial site corresponding to the target single cell based on the reference annotation information corresponding to the target single cell and the reference annotation information corresponding to the neighbor single cell comprises: if the reference annotation information corresponding to the target single cell is different from the reference annotation information corresponding to the neighbor single cell, a first constraint value is obtained; if the reference annotation information corresponding to the target single cell is the same as the reference annotation information corresponding to the neighbor single cell, a second constraint value is obtained; based on the first constraint value or the second constraint value, a cell spatial distribution feature of the target single cell at the spatial site corresponding to the target single cell is obtained.
5. The method of claim 4, wherein, The joint annotation processing of each target single cell based on the reference annotation information and the predicted annotation information comprises: updating the reference annotation information based on a preset first weight parameter, and updating the predicted annotation information based on a preset second weight parameter; performing joint annotation processing on each target single cell based on the updated reference annotation information and the updated predicted annotation information to obtain a sample annotation result corresponding to the sample tissue data.
6. The method of claim 5, wherein, The second weight parameter is obtained by the following steps, which comprise: obtaining a sample verification result corresponding to the sample tissue data, and an initial second weight parameter and an initial adjustment ratio; if the sample annotation result is different from the sample verification result, updating the initial adjustment ratio to obtain an adjustment ratio; updating the initial second weight parameter based on the adjustment ratio to obtain a second weight parameter.
7. A cell type annotation method, characterized by, The method comprises: obtaining sample tissue data, spatial transcriptome data and single cell sequencing data corresponding to the sample tissue data, and inputting the spatial transcriptome data and the single cell sequencing data into an initial annotation model; determining reference annotation information corresponding to each target single cell in each spatial site of the sample tissue data based on the single cell sequencing data under the constraint condition of the spatial transcriptome data; determining multi-modal prior information corresponding to each target single cell based on the reference annotation information and the spatial transcriptome data, and determining predicted annotation information corresponding to the target single cell based on the multi-modal prior information; performing joint annotation processing on each target single cell based on the reference annotation information and the predicted annotation information to obtain a sample annotation result corresponding to the sample tissue data; adjusting model parameters of the initial annotation model based on the sample annotation result to obtain a trained annotation model; obtaining target tissue data, target spatial transcriptome data and target single cell sequencing data corresponding to the target tissue data, and inputting the target spatial transcriptome data and the target single cell sequencing data into the trained annotation model; According to the target spatial transcriptome data and the target single-cell sequencing data, joint annotation processing is performed on the target tissue data to obtain target cell annotation results corresponding to the target tissue data; According to the single-cell sequencing data, reference annotation information of each target single cell in each spatial site of the sample tissue data is determined under the constraint condition of the spatial transcriptome data, including: The spatial transcriptome data is deconstructed using a preset segmentation tool to obtain a cell number value representing the number of single cells possessed by each spatial site of the sample tissue data, and a cell coordinate position representing the spatial position of each target single cell; According to the cell number value and the first gene expression information, a first logarithm operation result is determined; The first logarithm operation result is added to a preset batch variable value and a preset noise variable value to obtain the reference annotation information of the target single cell.
8. A cell type annotation apparatus characterized by comprising: The device comprises: An acquisition module is configured to acquire sample tissue data, spatial transcriptome data and single-cell sequencing data corresponding to the sample tissue data, and input the spatial transcriptome data and the single-cell sequencing data into an initial annotation model; A reference annotation module is configured to determine reference annotation information of each target single cell in each spatial site of the sample tissue data according to the single-cell sequencing data under the constraint condition of the spatial transcriptome data; A prediction annotation module is configured to determine multi-modal prior information corresponding to each target single cell based on the reference annotation information and the spatial transcriptome data, and determine predicted annotation information corresponding to the target single cell according to the multi-modal prior information; An annotation processing module is configured to perform joint annotation processing on each target single cell according to the reference annotation information and the predicted annotation information to obtain sample annotation results corresponding to the sample tissue data; A training module is configured to adjust model parameters of the initial annotation model according to the sample annotation results to obtain a trained annotation model; A first target processing module is configured to acquire target tissue data, target spatial transcriptome data and target single-cell sequencing data corresponding to the target tissue data, and input the target spatial transcriptome data and the target single-cell sequencing data into the trained annotation model; A second target processing module is configured to perform joint annotation processing on the target tissue data according to the target spatial transcriptome data and the target single-cell sequencing data to obtain target cell annotation results corresponding to the target tissue data; According to the single-cell sequencing data, reference annotation information of each target single cell in each spatial site of the sample tissue data is determined under the constraint condition of the spatial transcriptome data, including: The spatial transcriptome data is deconstructed by using a preset segmentation tool to obtain a cell quantity value representing a number of single cells possessed by each spatial site of the sample tissue data, and a cell coordinate position representing a spatial position of each target single cell; First gene expression information of the target single cell at each cell coordinate position is determined by using the single cell sequencing data, and a first logarithm operation result is determined according to the cell quantity value and the first gene expression information; The first logarithm operation result is added to a preset batch variable value and a preset noise variable value to obtain reference annotation information of the target single cell.
9. An electronic device, comprising: The electronic device includes a memory and a processor, the memory stores a computer program, and the processor implements the training method of the annotation model according to any one of claims 1 to 6 or the cell type annotation method according to claim 7 when executing the computer program.
10. A computer-readable storage medium storing a computer program, the computer program comprising instructions that, when executed by a computer, cause the computer to perform the method of any one of claims 1-9. The computer program is executed by the processor to implement the training method of the annotation model according to any one of claims 1 to 6 or the cell type annotation method according to claim 7.
Citation Information
Patent Citations
Spatial transcriptome biological tissue substructure analysis method fused with single cell transcriptome
CN115359845A
High-resolution spatial transcriptome
US20240158854A1