Large-scale space transcriptome and single cell transcriptome data alignment method

By modeling the alignment relationship between spatial points and cells into probability vectors in large-scale data scenarios, and building a non-parametric decoder without training, combined with a self-supervised neural network, the low alignment accuracy and low alignment accuracy in the existing technology are solved. The problem of not being able to scale to large-scale data achieves efficient and accurate alignment of spatial points with cells.

CN119229976APending Publication Date: 2024-12-31XIDIAN UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411298840.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-18
Publication Date
2024-12-31

AI Technical Summary

Technical Problem

The prior art cannot efficiently align space points with cells in large-scale data scenarios, and the alignment accuracy is not high enough.

Method used

By modeling the alignment relationship between spatial points and cells into normalized probability vectors, and building a non-parametric decoder without training, combining self-supervised neural networks, the input is constructed using the position coordinates of spatial points and other slice information. Embed features of vectors to achieve high-precision alignment.

Benefits of technology

It achieves efficient and accurate spatial point alignment with cells under large-scale data, overcomes the problem that the model cannot be extended to large-scale data in the existing technology, and significantly improves alignment accuracy and operation efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119229976A_ABST
    Figure CN119229976A_ABST
Patent Text Reader

Abstract

The invention discloses a data alignment method for a large-scale space transcriptome and a single cell transcriptome, and mainly solves the problems that in the prior art, during alignment matching, the accuracy is insufficient, and large-scale data cannot be expanded. According to the method, the mapping relation between the spatial points and the cells is accurately modeled by constructing the probability alignment vectors of the spatial points and the cells. According to the method, the complexity of model training is remarkably reduced by constructing a decoder module which does not need training and has no parameters. Meanwhile, the trained self-supervised neural network is adopted, a data set containing millions of spatial points can be processed through a reasoning framework, and the method is suitable for precise alignment tasks of large-scale spatial transcriptome data and single-cell transcriptomes.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of information processing technology, and further relates to a method for aligning large-scale spatial transcriptome and single-cell transcriptome data in the field of biological information data processing technology. The present invention can be used to construct a spatial map at the whole transcriptome level with single-cell resolution. Background Art

[0002] Spatial transcriptome data ST (Spatial transcriptome) contains the gene expression of spatial points in tissue sections, while single-cell transcriptome data SC (Single-cell transcriptome) measures the gene expression of each independent cell. Spatial point and cell alignment can reveal the cell composition in spatial position, aiming to achieve a spatial map at the whole transcriptome level with single-cell resolution. The alignment results can not only improve the resolution of spatial transcriptome data, but can also be applied to tasks such as gene enhancement, cell type deconvolution and information migration, so as to more comprehensively analyze the gene expression and cell composition within the tissue. With the increase in the types and scale of sequencing data, the difficulty of alignment has also increased. In recent years, some methods have proposed methods for aligning spatial points with cells.

[0003] Biancalani et al. proposed a method for aligning spatial points and cells using a gradient descent optimization algorithm in their paper “Deep learning and alignment of spatially resolved single-cell transcriptomes with Tangram” (Nature Methods. 2021 Jul; 18 (7): 725-735.). The implementation steps of this method are: first, cells are randomly assigned to spatial points, and then the cos similarity between the sum of gene expression of cells in the spatial points and the gene expression of the spatial points is calculated. The negative similarity is used as the loss function, and the gradient descent algorithm is used for optimization to maximize the similarity between the spatial points and multiple cells. After the model converges, the alignment result of the spatial points and cells is obtained. There are two shortcomings in this method. First, the method assumes that the cells in the single-cell transcriptome data are filtered using automatically learned parameters, but this method cannot accurately model the relationship between cells and spatial points in real data, resulting in insufficient accuracy of the model; second, the training time of the algorithm is proportional to the number of cells and spatial points, which makes the algorithm unable to run under large-scale data.

[0004] Vahid et al. proposed a method for aligning spatial points with cells using the shortest augmented path algorithm in their published paper "High-resolution alignment of single-cell and spatial transcriptomics data" (Nature Biotechnology. 2023Mar; 41 (3): 347-358.). The implementation steps of this method are: first, solve the cell type distribution and cell number of the spatial point, then establish a global cost function, consider the gene expression similarity and spatial position information between cells, and establish a constrained optimization model, which represents the gene expression pattern of the spatial point as a combination of multiple cell types in the point, and then find the optimal solution globally through the optimization algorithm to ensure that the distribution of cell types is consistent with the spatial correlation, and the optimization result is the alignment result between the spatial point and the cell. There are two shortcomings in this method. First, the method models the mapping relationship between cells and spatial points as the gene similarity between the two, and the modeling method is too simplified, resulting in the alignment accuracy of the method not being high enough; second, the method uses a global optimization algorithm, and the training optimization time is also closely related to the number of cell spatial points, resulting in inefficiency in scenarios with large data volumes, and large-scale transcriptome data cannot be aligned.

[0005] The above technologies cannot run in large-scale data sets (millions of data points), and the alignment accuracy is not high enough. Therefore, accurate alignment technology that can adapt to large-scale data is of great significance for the alignment of spatial points and cells. Summary of the invention

[0006] The purpose of the present invention is to provide a method for aligning large-scale spatial transcriptome and single-cell transcriptome data in order to address the deficiencies of the above-mentioned prior art, so as to solve the problem of insufficient alignment accuracy and the problem of being unable to align in large-scale data scenarios.

[0007] The idea of ​​achieving the purpose of the present invention is: the present invention models the alignment relationship between spatial points and cells as a normalized probability vector, and constructs the embedded features of the input vector through the position coordinates of the spatial points and other slice information as additional input information of the encoder, which solves the problem that the modeling mechanism in the prior art does not conform to the real relationship between spatial points and cells, so that the present invention can more accurately achieve the alignment between spatial points and cells. The present invention greatly reduces the training parameters of the model by constructing a non-training, non-parametric decoder, and enables the neural network to learn the alignment function in a self-supervised manner, solving the problem that the prior art model based on the optimization algorithm cannot be extended to large-scale data, so that the present invention can run efficiently in large-scale data scenarios.

[0008] The technical solution for achieving the purpose of the present invention is as follows:

[0009] Step 1, processing the original spatial transcriptome data to obtain a spatial point embedding feature matrix;

[0010] Step 2, construct a self-supervised neural network consisting of an encoder module and a decoder module connected in series;

[0011] Step 3, training the self-supervised neural network;

[0012] Step 4: Extract the spatial point and cell alignment matching matrix:

[0013] In the same way as step 1, the embedded feature matrix of the spatial point to be extracted and the cell spatial transcriptome data is obtained, and the embedded feature matrix is ​​input into the trained self-supervised neural network. The encoder processes the data of each spot and outputs an alignment matrix. In this alignment matrix, each vector represents the probability distribution of the cells contained in the current spot, thereby realizing the probabilistic form of alignment and matching between the spatial point spot and the cell cell.

[0014] Compared with the prior art, the present invention has the following advantages:

[0015] First, the present invention accurately models the mapping relationship existing in real data by constructing a probability vector between spatial points and cells as a representation of the alignment relationship in the encoder module, and constructs an embedding feature that takes the position coordinates of the spatial points and other slice information as input vectors, overcoming the problem of inaccurate modeling methods in the prior art, so that the present invention can achieve high-precision alignment between spatial points and cells.

[0016] Second, the present invention constructs a non-training, non-parametric decoder module, which can greatly reduce the complexity of the optimization process while ensuring the accuracy of alignment. At the same time, the design of the self-supervised framework enables the model to infer the alignment results of the entire data set after training, overcoming the problem that the existing optimization algorithm-based model cannot be extended to large-scale data, making the present invention applicable to the alignment of spatial points and cells under large-scale data. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] Figure 1 is a flow chart of the present invention;

[0018] Figure 2 It is a comparison chart of the algorithm accuracy of the present invention;

[0019] Figure 3 It is a comparison chart of the operating efficiency of the present invention. DETAILED DESCRIPTION

[0020] The embodiments and effects of the present invention are further described in detail below in conjunction with the accompanying drawings.

[0021] Reference Figure 1 , the implementation steps of the embodiments of the present invention are further described in detail.

[0022] Step 1: Preprocess the original spatial transcriptome data to obtain spatial point embedding features.

[0023] Step 1.1: Before running the alignment algorithm, the spatial transcriptome data is quality controlled and filtered to obtain the original gene expression matrix S of the spatial points. r ;

[0024] The quality control and filtering process refers to performing quality control and filtering on the original spatial transcriptome data, filtering out the low-quality spatial points in terms of the number of transcripts detected at each spatial point and the mitochondrial gene expression ratio; screening and retaining the co-expressed genes in the spatial transcriptome and single-cell transcriptome datasets, filtering out the genes expressed only in the spatial transcriptome dataset, and obtaining the original gene expression matrix S of the spatial point r .

[0025] Step 1.2: According to the following formula, r Perform standardization to obtain the gene feature matrix S of the spatial point f :

[0026]

[0027] Among them, S f Represents the gene feature matrix of the spatial point, log2(.) represents the logarithmic operation with base 2, and spot_sum represents the sum of gene expression at each spatial point.

[0028] Step 1.3: preprocess the spatial position information and image slice information of the spatial point to obtain the modal feature matrix M of the spatial point f .

[0029] The first step is to normalize the spatial position information and image slice information of each spatial point according to the following formula:

[0030]

[0031] Among them, m norm represents the information features after normalization, and m represents the information before normalization; m min Indicates the minimum value of information before normalization; m max Indicates the maximum value of information before normalization;

[0032] In the second step, the normalized spatial position information features and image slice information features are concatenated in sequence to obtain the modal feature matrix M of the spatial point. f .

[0033] Step 1.4, S f With M f Splicing to form the embedding feature matrix S of the spatial point i , this embedded feature matrix is ​​the input of the encoder; the embedded feature represents the unique feature of each spatial point, which contains the potential information of alignment; the embedded feature is used as the input vector of the neural network, and the spatial point gene feature will be used together with the gene feature of the output of the neural network as shown in the figure to calculate the loss function of the function.

[0034] Step 2: Construct a self-supervised neural network consisting of an encoder module and a decoder module connected in series.

[0035] The self-supervised neural network inputs embedded features and outputs spatial point gene features; it is composed of an encoder and a decoder in series; the encoder module is composed of a linear conversion layer, a BN layer, and a Softmax layer in series; the linear conversion layer is implemented by the torch.nn.Linear function, which converts the gene expression of the spot into a general alignment vector. The conversion function of this step is a function that the neural network automatically learns from the embedded features of the spatial point to the alignment with all cells; the BN layer and the Softmax layer further convert the general alignment vector into a probabilistic alignment vector; the BN layer is implemented by torch.nn.BatchNorm1d, which is used to stabilize the hidden layer values ​​during training and speed up the training; the Softmax layer is implemented by torch.nn.Softmax, in which the parameter dim is set to 1, which is used to normalize the vector to a probability vector with a sum of 1; the general alignment vector passes through the BN layer and the Softmax layer in turn to obtain the probabilistic alignment vector A; the probability vector is used instead of the general alignment vector because the probabilistic normalized alignment vector can more accurately describe the alignment relationship between the spatial point and all cells; from the embedded feature S i The conversion to a probabilistic alignment vector A is the main part of the model output alignment relationship.

[0036] The formula for converting the gene expression of the spot into a general alignment vector is as follows:

[0037] A′=WS i +b

[0038] Where A′ represents the general alignment vector, W represents the learnable weight matrix, and S i represents the embedding feature matrix, and b represents the learnable bias term.

[0039] The decoder module is obtained by the following formula:

[0040] S o =AC f

[0041] This step is from A to S o The decoding part; where S o represents the spatial point gene feature matrix output by the model, A represents the probability alignment vector obtained by the decoder, and C f Represents the single-cell gene feature matrix after quality control and standardization; the decoder restores the spatial point gene feature matrix according to the probability alignment vector and the cell expression matrix, which is the core innovative design of this model. It not only accurately models the probabilistic relationship between spatial points and cell alignment, but also enables the entire model to be trained in a self-supervised paradigm without the need for other labels, and makes the decoder free of training parameters, thereby enhancing the efficiency of the model.

[0042] Step 3: Train the self-supervised neural network.

[0043] During the training process, the embedding feature matrix S i Random sampling is performed and input into the encoder module in batches to generate a probability alignment vector A between the spatial point and the cell; the probability alignment vector passes through the decoder module and outputs the reconstructed spatial point gene feature matrix S o . Use mean square error MSE and negative entropy regularization as loss function to calculate S f and S o The difference between the two and the sparsity of the alignment relationship is limited; the adaptive momentum estimation optimizer Adam is used to perform back propagation of the network, and the parameters of the self-supervised neural network are iteratively updated until the loss function of the model converges to obtain a trained self-supervised neural network. After the training process converges, the network has learned the function of converting the embedded features of the spatial points into the probability alignment vector, and can infer the entire data set.

[0044] The loss function of the network is as follows:

[0045]

[0046] Where N represents the total number of spatial points, S f Represents the gene feature matrix of the spatial point, λ r Represents the weight of the negative entropy regularization term.

[0047] The limiting the sparsity of the alignment relationship refers to using a negative entropy regularization term to reduce the entropy value of the alignment probability vector, making the alignment probability more concentrated, thereby limiting the number of spatial points aligned with multiple cells, making the result of the alignment probability vector more reasonable and more consistent with the fact that a single spatial point is aligned with 1-10 cells in reality.

[0048] Step 4: Extract the alignment results of spatial transcriptome and single-cell transcriptome data.

[0049] In the same way as step 1, the embedded feature matrix of all spatial transcriptome data is obtained; the embedded feature matrix is ​​input into the trained encoder to obtain the alignment results of all spatial transcriptome and single-cell transcriptome data; the model only needs to continuously extract small batches of spatial transcriptome data for training, and after the model converges, the alignment results of all data sets can be inferred, so that the model can be expanded to large-scale data sets compared with previous optimization algorithms.

[0050] The effect of the present invention is further described below in conjunction with simulation experiments:

[0051] 1. Simulation experimental conditions.

[0052] The software platform of the simulation experiment of the present invention is: Windows 11 operating system and Python 3.11; the hardware platform is: the processor is i7-11700H CPU, the main frequency is 2.50 GHz, and the memory is 32 GB; the graphics card is NVIDIA GeForce RTX 3070TiLaptop GPU.

[0053] 2. Analysis of simulation content and results.

[0054] There are two simulation experiments of the present invention;

[0055] 2.1 Simulation Experiment 1 is a simulation of spatial transcriptome data and single-cell transcriptome data used to evaluate the accuracy.

[0056] The single-cell resolution spatial transcriptome data used are: the mouse brain high-resolution merfish dataset provided by the paper "Spatially resolved cellatlas of the mouse primary motor cortex by merfish"; tissue slice 1 from donor ID 2 was selected as the transcriptome data of the experiment, and its dataset is displayed in Figure 2 (a) Figure 2 Each dot in (a) represents a cell, and different colors represent different cell types. Figure 2 As can be seen in (a), the cell distribution in the mouse brain has a clear spatial pattern. Therefore, this transcriptome data can be used for data simulation. The specific method of simulating data is as follows: Figure 2 (b) is shown. The entire simulation data set is composed of Figure 2 The red box in (a) is intercepted and then used Figure 2(b) The grid shown in the figure is used to segment single cells. All single cells in a grid are considered to be the cells contained in the spatial point represented by the grid. That is, this simulated spatial transcriptome dataset has a real alignment relationship, and the alignment result prediction of different models can be used for benchmark experiments. At the same time, the original gene features of the spatial point represented by the grid are obtained by the sum of the gene features of the cells it contains, the spatial coordinate information is obtained by the center point of the grid, and the image modality information is obtained by the image features of the real dataset. Through the above operations, a simulated spatial transcriptome data set is constructed using a high-resolution dataset. Figure 2 All original cells in (a) are treated as a single-cell transcriptome dataset.

[0057] The simulation experiment 1 of the present invention uses the method of the present invention and multiple existing technologies to construct simulated spatial transcriptome data and single-cell transcriptome data in the above manner. Then, the dataset is used to run the method of the present invention and multiple existing technologies under the same experimental conditions, and the scores of the three indicators are calculated according to the predicted alignment results of the model and the actual alignment relationship: spot align accuracy, such as Figure 2 (c) shows that the cell location MSE is Figure 2 (d) shows, gene recovery PCC Figure 2 As shown in (e), a bar chart comparison of each algorithm is obtained.

[0058] Spot align Accuracy is used to measure the accuracy of alignment from the perspective of a spatial point. Assuming that a spatial point is composed of a different cells, and the model predicts that the number of cells that constitute this spatial point overlaps with these a cells is b, then is the calculation result of this indicator.

[0059] Cell location MSE is used to measure the accuracy of alignment from the perspective of the cell. The Euclidean distance between the actual spatial position of the cell and the position of the spatial point to which the cell belongs predicted by the model is the value of this indicator.

[0060] Gene recovery PCC is used to measure the accuracy of alignment from the perspective of gene features. When the gene features of the spatial points reconstructed by the alignment result are similar to the real gene features of the spatial points, the accuracy of the alignment result can be proved. Therefore, this indicator calculates the Pearson correlation between the gene features of the spatial points and the gene features of the reconstructed output.

[0061] The larger the Accuracy and PCC indicators are, the better the model effect is, and the smaller the MSE is, the better the model effect is; Figure 2 (c) Figure 2 (d) Figure 2The horizontal axes of the three bar graphs in (e) represent the values ​​of different indicators, and the vertical axes represent different algorithm models, among which S2CNet adopts the technical method of the present invention.

[0062] In simulation experiment 1, the multiple existing technologies used are:

[0063] The prior art classification method Tangram refers to the method proposed by Biancalani et al. in “Deep learning and alignment of spatially resolved single-cell transcriptomes with Tangram,in:Nature Methods.2021Nov;18(11):1352-1362.”, referred to as Tangram.

[0064] The prior art classification method NovoSpaRc refers to the method proposed by Moriel et al. in “Novosparc: flexible spatial reconstruction of single-cell gene expression with optimal transport, in: Nature Protocols. 2021Sep; 16(9): 4177-4200.”, abbreviated as NovoSpaRc.

[0065] The prior art classification method STEM refers to the method proposed by Hao et al. in “STEM enables mapping of single-cell and spatial transcriptomics data with transfer learning, in: Communications Biology. 2024Feb; 7:56.”, referred to as STEM.

[0066] The prior art classification method CellTrek refers to the method proposed by Vahid et al. in “High-resolution alignment of single-cell and spatial transcriptomics data using CellTrek,in:Nature Methods. 2023Jun15;20(6):598-607.”, referred to as CellTrek.

[0067] The prior art classification method CytoSpace refers to the method proposed by Wan et al. in “Integrating spatial and single-cell transcriptomics data using CytoSpace, in: Nature Biotechnology. 2023Feb 28; 41(2): 252-260.”, referred to as CytoSpace.

[0068] The prior art classification method CeLEry refers to the method proposed by Zhang et al. in “CeLEry: Leveraging spatial transcriptomics data to recover cell locations in single-cell RNA-seq with CeLEry, in: Nature Communications. 2023Jun; 14: 4050.”, abbreviated as CeLEry.

[0069] The prior art classification method scSpace refers to the method proposed by Qian et al. in “scSpace: Reconstruction of the cell pseudo-space from single-cell RNA sequencing data with scSpace, in: Nature Communications. 2023Apr; 14: 2484.”, referred to as scSpace.

[0070] The prior art classification method SpaOTsc refers to the method proposed by Cang et al. in “SpaOTsc: Inferring spatial and signaling relationships between cells from single-cell transcriptomic data, in: Nature Communications. 2020 May; 11: 2084.”, abbreviated as SpaOTsc.

[0071] 2.2 Simulation Experiment 2 is a simulation of spatial transcriptome data and single-cell transcriptome data used to evaluate the operating efficiency under large-scale data.

[0072] The single-cell transcriptome data used in the simulation experiment 2 of the present invention is derived from the single-cell transcriptome data set provided by the cell2location platform, which consists of 73,260 cells. The simulation space points are obtained by the fusion cell method used in experiment 1 to obtain a simulated spatial transcriptome data set.

[0073] In simulation experiment 2, multiple existing technologies used are the same as some technologies in simulation experiment 1, and the same experimental conditions are used, but multiple spatial transcriptome data sets are simulated in experiment 2, and the number of spatial points simulated in each data set is different, and the number of spatial points is increased by multiples of 10, thereby obtaining simulated data sets with different numbers of spatial points. Then, the technology of the present invention and other different technologies are used to run algorithms on these data sets, and the time for all technologies to run on data sets with different numbers of spatial points is obtained, such as Figure 3 shown. Figure 3 The horizontal axis in the figure represents the number of spatial points in the data set. There are five simulation data sets with different numbers of spatial points (number of spots) from one hundred to one million. The vertical axis represents the execution time of the algorithm (Execution Time) in seconds. The horizontal lines of different colors represent the algorithm execution time results of different technologies, such as Figure 3 As shown, yellow, orange, red, pink, and blue represent the technologies S2CNet, Tangram, CytoSpace, SpaOTsc, and scSpace of the present invention, respectively; Figure 3 Each point in represents the time it takes for the algorithm to execute given the number of spatial points represented by the horizontal axis, and is labeled using commonly used time units. For example, Figure 3 The rightmost point in the figure indicates that the algorithm execution time of the present invention technology on a data set with one million spatial points is two minutes; at the same time, the mark on the horizontal axis indicates that the technical method corresponding to its color has failed on this number of spatial points, and the failure reason is memory overflow or too low accuracy. For example, Figure 3 The rightmost dash on the horizontal axis indicates that the memory will overflow when Tangram technology is running on a data set with about 100,000 spatial points. That is, the dash indicates the maximum number of spatial points that the technology can accommodate.

[0074] 2.3 Combine the following Figure 2 , Figure 3 The simulation diagram of the present invention is further described.

[0075] Figure 2 In (c), the score of the method of the present invention is about 0.96, showing a high alignment accuracy. Meanwhile, the score of SpaOTsc is also relatively high. Figure 2 In (d), the performance of the present invention technology is significantly better than all other methods including SpaOTsc. Figure 2 In (e), the index of the technology of the present invention is significantly higher than that of other technologies. Therefore, it can be seen from the comprehensive indexes of three different angles that the alignment accuracy of the technology of the present invention is significantly better than that of other technologies. It is the best under the comparison of three different indexes.

[0076] Figure 3 The different broken lines reflect the operating efficiency and scalability of different technologies in terms of data scale; although SpaOTsc Figure 2 (c) shows a higher score, but it can be seen that its operating efficiency is the lowest. When the number of spatial points is 1,000, the execution time of this technical method is as high as 38 minutes. After the number of spatial points exceeds 1,000, the SpaOTsc technology is difficult to run successfully. The efficiency of the scSpace, Cytospace, and Tangram algorithms increases successively. Although the Tangram algorithm is more efficient, its running time is still relatively high when the data scale is at the level of 100,000, requiring 20 minutes, and it cannot be expanded to a data set of one million. The method of the present invention can run well on data of different scales and is very efficient, which is better than the operating efficiency of other technologies; even at the data scale of one million, the running time of the technology of the present invention is relatively short. Figure 2 , 3 The comprehensive analysis proves that the technology of the present invention not only has accurate alignment results, but also has strong scalability in data scale, and can be easily expanded to spatial transcriptome data of millions of scales.

Claims

1. A method for aligning large-scale spatial transcriptome and single-cell transcriptome data, characterized in that: In the encoder module, a probability vector between spatial points and cells is constructed as a representation of the alignment relationship, and a non-trainable, non-parametric decoder module is constructed; the steps of the alignment method include the following: Step 1, processing the original spatial transcriptome data to obtain a spatial point embedding feature matrix; Step 2, construct a self-supervised neural network consisting of an encoder module and a decoder module connected in series; Step 3, training the self-supervised neural network; Step 4: Extract the spatial point and cell alignment matching matrix: In the same way as step 1, the embedded feature matrix of the spatial point to be extracted and the cell spatial transcriptome data is obtained, and the embedded feature matrix is ​​input into the trained self-supervised neural network. The encoder processes the data of each spot and outputs an alignment matrix. In this alignment matrix, each vector represents the probability distribution of the cells contained in the current spot, thereby realizing the probabilistic form of alignment and matching between the spatial point spot and the cell cell.

2. The method for aligning large-scale spatial transcriptome and single-cell transcriptome data according to claim 1, characterized in that: The steps to obtain the spatial point embedding feature matrix described in step 1 are as follows: The first step is to perform quality control and filtering on the spatial transcriptome data to obtain the gene expression matrix S of the spatial points. r ; The second step is to r Perform standardization to obtain the gene feature matrix S of the spatial point f ; The third step is to preprocess the spatial position information and image slice information of the spatial point to obtain the modal feature matrix M of the spatial point. f ; Step 4: S f With M f Splicing to form the embedding feature matrix S of the spatial point i .

3. The method for aligning large-scale spatial transcriptome and single-cell transcriptome data according to claim 2, characterized in that: The quality control and filtering process refers to performing quality control and filtering on the original spatial transcriptome data, filtering out the low-quality spatial points in terms of the number of transcripts detected at each spatial point and the mitochondrial gene expression ratio; screening and retaining the co-expressed genes in the spatial transcriptome and single-cell transcriptome datasets, filtering out the genes expressed only in the spatial transcriptome dataset, and obtaining the original gene expression matrix S of the spatial point r .

4. The method for aligning large-scale spatial transcriptome and single-cell transcriptome data according to claim 2, characterized in that: The pair S r The formula for standardization is as follows: Among them, S f Represents the gene feature matrix of the spatial point, log2(.) represents the logarithmic operation with base 2, and spot_sum represents the sum of gene expression at each spatial point.

5. The method for aligning large-scale spatial transcriptome and single-cell transcriptome data according to claim 2, characterized in that: The steps of preprocessing the spatial position information of the spatial point and the image slice information are as follows: The first step is to normalize the spatial position information and image slice information of each spatial point according to the following formula: Among them, m norm represents the information features after normalization, and m represents the information before normalization; m min Indicates the minimum value of information before normalization; m max Indicates the maximum value of information before normalization; In the second step, the normalized spatial position information features and image slice information features are concatenated in sequence to obtain the modal feature matrix M of the spatial point. f .

6. The method for aligning large-scale spatial transcriptome and single-cell transcriptome data according to claim 1, characterized in that: The encoder module described in step 2 is composed of a linear conversion layer, a BN layer, and a Softmax layer in series; wherein the linear conversion layer is implemented by the torch.nn.Linear function, which converts the gene expression of the spot into a general alignment vector; the BN layer and the Softmax layer further convert the general alignment vector into a probabilistic alignment vector; the BN layer is implemented by torch.nn.BatchNorm1d; the Softmax layer is implemented by torch.nn.Softmax, wherein the parameter dim is set to 1; the general alignment vector passes through the BN layer and the Softmax layer in turn to obtain the probabilistic alignment vector A; The formula for converting the gene expression of the spot into a general alignment vector is as follows: A′=WS i +b Where A′ represents the general alignment vector, W represents the learnable weight matrix, and S i represents the embedding feature matrix, and b represents the learnable bias term.

7. The method for aligning large-scale spatial transcriptome and single-cell transcriptome data according to claim 6, characterized in that: The decoder module described in step 2 is obtained by: S o =AC f Among them, S o represents the spatial point gene feature matrix output by the model, A represents the probability alignment vector obtained by the decoder, and C f Represents the single-cell gene feature matrix after quality control and standardization.

8. The method for aligning large-scale spatial transcriptome and single-cell transcriptome data according to claim 7, characterized in that: The steps for training the self-supervised neural network in step 3 are as follows: embed the feature matrix S i Input to the encoder module to generate a probability alignment vector A between the spatial point and the cell; The probability alignment vector passes through the decoder module and outputs the reconstructed spatial point gene feature matrix S o ; Use mean square error MSE and negative entropy regularization term as loss function to calculate S f and S o The difference between them is calculated and the sparsity of the alignment relationship is limited; the adaptive momentum estimation optimizer Adam is used to perform back propagation of the network, and the parameters of the self-supervised neural network are iteratively updated until the loss function of the model converges to obtain a trained self-supervised neural network.

9. The method for aligning large-scale spatial transcriptome and single-cell transcriptome data according to claim 8, characterized in that: The loss function of the model is as follows: Where N represents the total number of spatial points, S f Represents the gene feature matrix of the spatial point, λ r Represents the weight of the negative entropy regularization term.

10. The method for aligning large-scale spatial transcriptome and single-cell transcriptome data according to claim 8, characterized in that: The limiting the sparsity of the alignment relationship refers to using a negative entropy regularization term to reduce the entropy value of the alignment probability vector, making the alignment probability more concentrated, thereby limiting the number of spatial points aligned with multiple cells, making the result of the alignment probability vector more reasonable and more consistent with the fact that a single spatial point is aligned with 1-10 cells in reality.