A fast and stable single cell type annotation method
By adaptively determining the optimal hyperparameters, the problem of inaccurate dimensionality reduction results caused by unreasonable hyperparameter selection in single-cell type annotation is solved, and more accurate cell type differentiation and mixing degree judgment are achieved.
Patent Information
- Application Number
- CN202510503735.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-22
- Publication Date
- 2025-09-19
- Estimated Expiration
- 2045-04-22
AI Technical Summary
In the existing single-cell type labeling process, the dimensionality reduction results of cell data are not accurate due to unreasonable hyperparameter selection.
By identifying the cell categories of different cells, the dimensionality reduction processing of the sequencing data of single cells is performed under different set hyperparameters, the data point graphs before and after dimensionality reduction are obtained, the difference in the number distribution of data points in the neighborhood is analyzed, the rationality index is determined, the cell area and boundary area of each cell type are determined, and then the optimal set hyperparameters are selected.
The accuracy of dimensionality reduction results in the single-cell type annotation process is improved, ensuring clear distinction of cell types and accurate judgment of the degree of mixing.
Smart Images

Figure CN120015135B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of bioinformatics, and in particular to a fast and stable single cell type annotation method. Background Art
[0002] The data generated by the single-cell sequencing technology scRNA-seq is very high-dimensional, containing the expression levels of thousands of genes in single cells. By labeling single cell types, it can help researchers discover clusters of specific cell types.
[0003] In the prior art, the UMAP-learn tool is often used to perform UMAP dimensionality reduction on single-cell data during the single-cell type annotation process. However, there are many hyperparameters in the UMAP dimensionality reduction process, such as the number of neighbors and the minimum distance. The rationality of setting these hyperparameters can seriously affect the accuracy of the dimensionality reduction results of the cell data. Currently, the hyperparameters in the UMAP dimensionality reduction process are mainly used to achieve dimensionality reduction of single-cell data by calling default values. However, since different dimensionality reduction parameters should be selected for different cell data, when the hyperparameters determined by calling the default values are unreasonable, the dimensionality reduction results of the cell data are not accurate. Summary of the Invention
[0004] The purpose of the present invention is to provide a fast and stable single cell type labeling method to solve the problem that the dimensionality reduction results of cell data are not accurate due to unreasonable selection of hyperparameters used in the existing single cell type labeling process.
[0005] To solve the above technical problems, in a first aspect, the present invention provides a rapid and stable single cell type annotation method, comprising the following steps:
[0006] Identify cell types of different cells based on sequencing data of different cells;
[0007] Perform dimensionality reduction on the sequencing data of a single cell under different set hyperparameters, and obtain data point graphs before and after dimensionality reduction. Each data point in the data point graph corresponds to a cell.
[0008] Based on the difference between the number of data points of the same cell type and the neighborhood of the data point corresponding to each cell in the data point graph before and after dimensionality reduction, the rationality index of each cell is determined. The rationality index reflects the rationality of the current value of the set hyperparameter for each cell.
[0009] Determine the boundary area and non-boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, and determine the degree of cell mixing in the cell area of each cell type based on the difference between the rationality indicators of the cells corresponding to the data points corresponding to the cell type in the boundary area and the non-boundary area, as well as the distribution of the data points of the cell type pair and the data points corresponding to other cell types in the boundary area;
[0010] Determine the accuracy of the different values of the set hyperparameters based on the overall distribution of the degree of cell mixing in the cell regions of all cell types under the different values of the set hyperparameters;
[0011] The set hyperparameter with the value corresponding to the maximum accuracy is taken as the set hyperparameter with the optimal value, and the data point graph after dimensionality reduction corresponding to the set hyperparameter with the optimal value is taken as the optimal dimensionality reduction result.
[0012] In conjunction with the first aspect above, in some possible implementations, determining the rationality index of each cell includes:
[0013] Determine the proportion of data points of the same cell type as the cell in the neighborhood of the data point corresponding to each cell in the data point graph before dimensionality reduction to obtain a first cell type density;
[0014] Determine the proportion of data points of the same cell type as the cell in the neighborhood of the data point corresponding to each cell in the data point graph after dimensionality reduction, and obtain the second cell type density;
[0015] determining a difference between the density of the second cell type and the density of the first cell type to obtain a first difference;
[0016] The product of the first difference and the second cell type density is determined to obtain a first product, and the first product is used as a rationality indicator for each cell.
[0017] In conjunction with the first aspect above, in some possible implementations, determining the boundary region and non-boundary region of the cell region constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction includes:
[0018] Determine the boundary data points of the cell area composed of the data points corresponding to each cell type in the data point map after dimensionality reduction;
[0019] Construct the k-neighborhood of each boundary data point, and then determine the neighborhood radius of each boundary data point;
[0020] The minimum neighborhood radius among all neighborhood radiuses is used as the boundary distance;
[0021] The area within the cell region constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction and within the boundary line of the cell region is taken as the boundary area, and the other areas within the cell region except the boundary area are taken as the non-boundary area.
[0022] In conjunction with the first aspect above, in some possible implementations, determining the neighborhood radius of each boundary data point includes:
[0023] Determine the distance between each data point in the k-neighborhood of each boundary data point and the corresponding boundary data point as the candidate distance for each boundary data point;
[0024] The maximum distance among all candidate distances of each boundary data point is determined, and the maximum distance is used as the neighborhood radius of each boundary data point.
[0025] In conjunction with the first aspect above, in some possible implementations, determining the degree of cell mixing in a cell region of each cell type includes:
[0026] In the data point graph after dimensionality reduction, the boundary clarity of the boundary region corresponding to each cell type is determined based on the difference between the rationality indicators of the cells corresponding to the data points of the cell type.
[0027] In the boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, the degree of cell mixing of each other cell type in the boundary area corresponding to each cell type is determined based on the difference in the number of data points corresponding to this cell type and the data points corresponding to each other cell types, as well as the area proportion of the data points corresponding to each other cell types;
[0028] The degree of cell mixing of the cell region of each cell type is determined based on the degree of cell mixing of all other cell types in the boundary region corresponding to each cell type and the boundary clarity of the boundary region corresponding to each cell type.
[0029] In conjunction with the first aspect above, in some possible implementations, determining the boundary clarity of the boundary region corresponding to each cell type includes:
[0030] In the data point graph after dimensionality reduction, within the boundary area of the cell area constituted by the data points corresponding to each cell type, determining the average value of the rationality index of the cells corresponding to all the data points corresponding to the cell type, and obtaining a first rationality index mean;
[0031] In the non-boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, the average value of the rationality index of the cells corresponding to all the data points corresponding to the cell type is determined to obtain the second rationality index mean;
[0032] Determining the boundary clarity of the boundary region corresponding to each cell type according to the difference between the mean value of the first rationality index and the mean value of the second rationality index;
[0033] The difference between the mean of the first rationality index and the mean of the second rationality index is determined to obtain a second difference, and negative correlation normalization processing is performed on the second difference to obtain the boundary clarity of the boundary area corresponding to each cell type.
[0034] In conjunction with the first aspect above, in some possible implementations, determining the degree of cell mixing of each other cell type within the boundary region corresponding to each cell type includes:
[0035] In the data point graph after dimensionality reduction, the difference between the number of data points corresponding to the cell type and the number of data points corresponding to each other cell type is determined within the boundary area of the cell area constituted by the data points corresponding to the cell type to obtain a third difference, and a negative correlation process is performed on the third difference to obtain a difference processing result;
[0036] Determine the product of the difference processing result and the area proportion of the data points corresponding to each other cell type in the boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, and obtain a second product, and use the second product as the cell mixing degree of each other cell type in the boundary area corresponding to each cell type.
[0037] In conjunction with the first aspect above, in some possible implementations, determining the degree of cell mixing in a cell region of each cell type includes:
[0038] Determine the maximum cell mixing degree among the cell mixing degrees of all other cell types in the boundary region corresponding to each cell type under different values of the set hyperparameters;
[0039] The ratio of the maximum cell mixing degree to the boundary definition of the boundary area corresponding to each cell type was determined, and the normalized value of the ratio was used as the cell mixing degree of the cell area of each cell type.
[0040] In conjunction with the first aspect above, in some possible implementations, determining the accuracy of different values of set hyperparameters includes:
[0041] Determine the average of the cell mixing degrees of all cell types in the cell regions of the data point graph after dimensionality reduction by setting the hyperparameters at different values, and obtain the average cell mixing degree;
[0042] The average cell mixing degree was negatively correlated to obtain the accuracy of the set hyperparameters with different values.
[0043] In combination with the first aspect above, in some possible implementations, the umap algorithm is used to perform dimensionality reduction processing on the sequencing data of a single cell under different set hyperparameters, where the hyperparameter is set to the number of neighbors.
[0044] To solve the above technical problems, in a second aspect, the present invention further provides a fast and stable single cell type labeling device, the device comprising:
[0045] A cell type recognition module is used to identify the cell types of different cells based on the sequencing data of different cells;
[0046] The data point graph acquisition module is used to perform dimensionality reduction processing on the sequencing data of a single cell under different set hyperparameters and obtain data point graphs before and after dimensionality reduction. Each data point in the data point graph corresponds to a cell.
[0047] The rationality acquisition module is used to determine the rationality index of each cell based on the difference between the number of data points of the same cell type and the neighborhood of the data point corresponding to each cell in the data point graph before and after dimensionality reduction. The rationality index reflects the rationality of the current setting of the hyperparameter for each cell;
[0048] A mixing degree acquisition module is used to determine the boundary area and non-boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, and determine the cell mixing degree of the cell area of each cell type based on the difference between the rationality indicators of the cells corresponding to the data points corresponding to the cell type in the boundary area and the non-boundary area, as well as the distribution of the data points of the cell type pair and the data points corresponding to other cell types in the boundary area;
[0049] an accuracy acquisition module for determining the accuracy of different values of the set hyperparameters based on the overall distribution level of cell mixing of cell regions of all cell types under different values of the set hyperparameters;
[0050] The screening module is used to take the set hyperparameter with the value corresponding to the maximum accuracy as the set hyperparameter with the optimal value, and take the reduced dimensionality data point graph corresponding to the set hyperparameter with the optimal value as the optimal dimensionality reduction result.
[0051] To address the above technical issues, in a third aspect, the present invention further provides a rapid and stable single-cell type annotation system, comprising a memory and a processor. The memory is configured to store an executable computer program, and the processor is configured to retrieve and execute the executable computer program from the memory, so that the system performs the method of the first aspect or any possible implementation of the first aspect.
[0052] In order to solve the above technical problems, in a fourth aspect, the present invention also provides a computer program product, which includes: computer program code, when the computer program code is run on a computer, enables the computer to execute the method in the above first aspect or any possible implementation of the first aspect.
[0053] In order to solve the above technical problems, in the fifth aspect, the present invention also provides a computer-readable storage medium, which stores computer program code. When the computer program code is run on a computer, the computer executes the method in the above first aspect or any possible implementation of the first aspect.
[0054] The present invention has the following beneficial effects: the present invention identifies the cell types of different cells based on sequencing data of different cells, and performs dimensionality reduction processing on the sequencing data of a single cell under different set hyperparameters to obtain data point graphs before and after dimensionality reduction, wherein each data point in the data point graph corresponds to a cell; the data point graphs before and after dimensionality reduction are analyzed, and the rationality index of each cell is determined based on the difference between the number distribution of data points of the same cell type as the cell in the neighborhood of the data point corresponding to each cell in the data point graphs before and after dimensionality reduction; the degree of cell mixing of the cell region of each cell type under different set hyperparameters is determined; and then, the degree of cell mixing of the cell region of each cell type is determined based on the difference between the rationality indexes of the cells corresponding to the data points corresponding to the cell type in the boundary area and the non-boundary area of the cell region constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, as well as the distribution of the data points of the cell type pair and the data points corresponding to other cell types in the boundary area, and finally the accuracy of the set hyperparameters with different values is determined; the set hyperparameter with the maximum accuracy corresponding to the value is used as the optimal set hyperparameter, and the data point graph after dimensionality reduction corresponding to the optimal set hyperparameter is used as the optimal dimensionality reduction result. The present invention performs dimensionality reduction processing on the sequencing data of single cells under different set hyperparameters and analyzes the data point graphs before and after the dimensionality reduction, thereby adaptively determining the optimal set hyperparameters, effectively improving the accuracy of the dimensionality reduction results in the single-cell type labeling process. BRIEF DESCRIPTION OF THE DRAWINGS
[0055] In order to more clearly illustrate the technical solutions and advantages of the embodiments of the present invention or the prior art, the following briefly introduces the drawings required for use in the embodiments or the prior art descriptions. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0056] Figure 1 This is a flowchart of the steps of a rapid and stable single cell type labeling method according to an embodiment of the present invention;
[0057] Figure 2 This is a structural diagram of sequencing data of a cell according to an embodiment of the present invention;
[0058] Figure 3 Schematic diagram of data point distribution determined after dimensionality reduction processing of sequencing data of different cells using the UMAP algorithm with different values of the number of neighbors in an embodiment of the present invention;
[0059] Figure 4 Schematic diagram of the boundary area and non-boundary area of the cell area according to an embodiment of the present invention;
[0060] Figure 5 Schematic diagram of the structure of a fast and stable single cell type labeling device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0061] In order to clearly illustrate the technical features of this solution, the present invention is described in detail below through specific implementation methods in conjunction with the accompanying drawings.
[0062] Embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. Although certain embodiments of the present invention are shown in the accompanying drawings, it should be understood that the present invention can be implemented in various forms and should not be construed as limited to the embodiments described herein. Rather, these embodiments are provided to provide a more thorough and complete understanding of the present invention. It should be understood that the drawings and embodiments of the present invention are for illustrative purposes only and are not intended to limit the scope of protection of the present invention.
[0063] It should be understood that the various steps described in the method embodiments of the present invention may be performed in different orders and / or in parallel. In addition, the method embodiments may include additional steps and / or omit the steps shown. The scope of the present invention is not limited in this respect.
[0064] As used herein, the term "including" and its variations are open-ended, i.e., "including but not limited to." The term "based on" means "based, at least in part, on." The term "one embodiment" means "at least one embodiment," the term "another embodiment" means "at least one additional embodiment," and the term "some embodiments" means "at least some embodiments." Other terms are defined in the following description.
[0065] It should be noted that the concepts of "first" and "second" mentioned in the present invention are only used to distinguish different devices, modules or units, and are not used to limit the order or interdependence of the functions performed by these devices, modules or units.
[0066] Although operations or steps are described in a particular order in the drawings in the embodiments of the present invention, this should not be understood as requiring that these operations or steps be performed in the particular order shown or in a serial order, or that all of the operations or steps shown be performed to obtain a desired result. In the embodiments of the present invention, these operations or steps may be performed serially; they may also be performed in parallel; or a portion of these operations or steps may be performed.
[0067] At the same time, it is understood that the data involved in the technical solutions of the present invention (including but not limited to the data itself, the acquisition or use of the data) must comply with the requirements of relevant laws, regulations and relevant provisions. Unless otherwise defined, all technical and scientific terms used in this invention have the same meanings as those commonly understood by those skilled in the art to which this invention belongs, and all parameters or indicators in the formulas involved in this invention are normalized values to eliminate dimension effects.
[0068] In order to solve the problem that the dimensionality reduction results of cell data are not accurate due to the unreasonable selection of hyperparameters used in the existing single-cell type labeling process, an embodiment of the present invention provides a fast and stable single-cell type labeling method. This method effectively improves the accuracy of the dimensionality reduction results of cell data by adaptively determining the optimal values of the set hyperparameters.
[0069] A fast and stable single cell type labeling method provided by an embodiment of the present invention will be described in detail below with reference to the accompanying drawings.
[0070] Figure 1 FIG. 4 shows a basic flow chart of a fast and stable single cell type annotation method provided by an embodiment of the present invention, as shown in FIG. Figure 1 As shown, the method specifically includes the following steps:
[0071] Step S100: Identifying cell types of different cells based on sequencing data of different cells.
[0072] Specifically, a pre-trained cell type recognition model is obtained, sequencing data of different cells are input into the cell type recognition model, the cell types of different cells are identified using the cell type recognition model, and the cell types of different cells are output, thereby realizing cell category recognition of different cells.
[0073] In this embodiment, training data is obtained from an open source database cell marker. The training data refers to sequencing data of different cells. The training data is input into the transformer network that constitutes the cell type recognition model to match the gene features of the cells. The matching results are used as the features of the single cell and input into a linear classifier. The linear classifier is a fully connected layer with a softmax activation function. The linear classifier outputs a vector whose dimension is the number of all cell categories. The value of each dimension in the vector is the possibility of the labeled cell category of the single cell. The values of each dimension in the vector are normalized, and the largest value among these dimensions is selected as the cell category of the current single cell. A cell category label is set for each cell corresponding to the training data. The cell category obtained by the cell type recognition model is compared with the cell category label of each cell corresponding to the training data. The cell type recognition model is continuously iterated and optimized to improve the accuracy of recognition, and finally the training of the cell type recognition model is completed.
[0074] Users upload sequencing data of different cells through the front-end interface. The sequencing data includes gene expression matrix, gene name, and cell barcode. Figure 2 The structure of the sequencing data is shown in Figure 2. Based on the sequencing data of different cells, the cell type recognition model composed of the transformer network described above is used to complete the type recognition of single cells, and the output vector and the cell type label of the corresponding single cell are recorded simultaneously, thereby realizing the cell type recognition of different cells.
[0075] It should be understood that the above is only a specific method for identifying the cell types of different cells given in this embodiment. Other methods or models can also be used to achieve cell type identification of different cells, which will not be described in detail here.
[0076] Step S200: performing dimensionality reduction processing on the sequencing data of a single cell under different set hyperparameters, and obtaining data point graphs before and after dimensionality reduction, where each data point in the data point graph corresponds to a cell.
[0077] Specifically, the above-mentioned cell type recognition model composed of a transformer network is used to match the genetic characteristics of each cell to complete the type recognition of single cells. However, the sequencing data of single cells often have high-dimensional characteristics. There are thousands of gene expression information in a cell. It is impossible to directly observe and understand the relationship between cells in a high-dimensional space. Therefore, it is necessary to use the UMAP algorithm to reduce the dimensionality of the sequencing data of single cells, so as to facilitate more direct observation of how different types of single cell populations are distributed and the distance between them. This helps to grasp the heterogeneity and similarity of cell populations as a whole, distinguish the clustering morphology of different cell subpopulations in low-dimensional space, and complete the single cell type labeling.
[0078] When using the UMAP algorithm to reduce the dimensionality of single-cell sequencing data, the number of neighbors, n_neighbors, is a key hyperparameter in the UMAP algorithm, significantly affecting the dimensionality reduction results. Its default value is 15. If the number of neighbors is set too small, cells that originally belonged to the same cell subpopulation will be overly dispersed in the low-dimensional space after dimensionality reduction, failing to form tight, clear clusters. This will result in the inability to intuitively distinguish different cell populations in the reduced data, resulting in a chaotic distribution of cells. Conversely, if the number of neighbors is set too large, different cell subpopulations will merge, causing cells that should have been distinguished to overlap after dimensionality reduction by the UMAP algorithm, failing to demonstrate the differences between cell populations.
[0079] To this end, in order to determine the optimal number of neighbors, the output dimension of the UMAP algorithm is set to n_components=2. The UMAP algorithm is used to perform dimensionality reduction on the sequencing data of different cells under different values of the number of neighbors, and the data point graphs before and after dimensionality reduction are obtained. Each data point in the data point graph corresponds to a cell. Figure 3 The figure shows the distribution of data point graphs obtained after dimensionality reduction processing of sequencing data of different cells using the UMAP algorithm with different values of the number of neighbors.
[0080] Among them, when using the UMAP algorithm to perform dimensionality reduction processing on the sequencing data of different cells under different values of the number of neighbors, the interval of the number of neighbors and the traversal step can be set to obtain the corresponding neighbor number traversal sequence, so as to use the UMAP algorithm to perform dimensionality reduction processing on the sequencing data of different cells under each number of neighbors in the neighbor number traversal sequence, and obtain the data point graph before and after each dimensionality reduction corresponding to each number of neighbors in the neighbor number traversal sequence.
[0081] Step S300: Determine the rationality index of each cell based on the difference between the number distribution of the data points in the neighborhood of each cell corresponding to the data point in the data point graph before and after dimensionality reduction and the data points of the same cell category as the cell. The rationality index reflects the rationality of the setting of the current value of the set hyperparameter for each cell.
[0082] Specifically, for each cell—that is, each cell barcode in the sequencing data, which uniquely identifies the cell—a k value is set, and the k-neighborhood of the data point corresponding to that cell in the pre-dimensionality reduction data point graph is obtained. It should be noted that this neighborhood reflects the genetic similarity between cells. For example, if the neighborhood of the data point corresponding to cell A includes data points corresponding to cells B and C, this indicates that these cells have a high degree of similarity in gene expression levels and share a specific gene combination. Simultaneously, the k-neighborhood of the data point corresponding to that cell in the post-dimensionality reduction data point graph is obtained.
[0083] If, after dimensionality reduction, cells can still cluster closely together to form relatively independent clusters at a certain number of neighbors, the number of neighbors chosen is appropriate. Therefore, if cells within the neighborhood exhibit consistent cell types after dimensionality reduction, this indicates that the currently selected number of neighbors does not result in a mix of different cell types in the UMAP dimensionality reduction results, and that different cells can be well distinguished, thus indicating that the current number of neighbors is appropriate.
[0084] Furthermore, the rationality index of each cell is determined based on the difference between the number distribution of data points of the same cell type as the cell in the neighborhood of the data point corresponding to each cell in the data point graph before and after dimensionality reduction. The implementation steps include:
[0085] Determine the proportion of data points of the same cell type as the cell in the neighborhood of the data point corresponding to each cell in the data point graph before dimensionality reduction to obtain a first cell type density;
[0086] Determine the proportion of data points of the same cell type as the cell in the neighborhood of the data point corresponding to each cell in the data point graph after dimensionality reduction, and obtain the second cell type density;
[0087] determining a difference between the density of the second cell type and the density of the first cell type to obtain a first difference;
[0088] The product of the first difference and the second cell type density is determined to obtain a first product, and the first product is used as a rationality indicator for each cell.
[0089] For the above steps, in this embodiment, for any cell in the data point graph after dimensionality reduction , the second cell type density is determined by the following formula:
[0090] ;
[0091] Where: Represents cells after dimensionality reduction density of the second cell type; Represents cells after dimensionality reduction The corresponding data point is in the neighborhood of the cell is the number of data points of the same cell class; Represents cells after dimensionality reduction The number of data points in the neighborhood of the corresponding data point; Indicates the sign after dimensionality reduction.
[0092] In the above formula, the cell after dimensionality reduction Density of the second cell type The larger the value, the better the cell The stronger the consistency of cell types in the neighborhood of the corresponding data point, the greater the possibility that the number of neighbors belongs to the optimal number of neighbors.
[0093] In the same way, the cells before dimensionality reduction can be determined The first cell type density is recorded as , Indicates the sign before dimensionality reduction.
[0094] Considering that cells identified as the same general type also have internal heterogeneity, there may be different cell subpopulations, and the differences between these cell subpopulations sometimes overlap with other types of cells. For example, in the tumor microenvironment, different T cell subpopulations in immune cells, such as regulatory T cells and cytotoxic T cells, have different functions and gene expression characteristics, and the characteristics of some of these subpopulations may be similar to other types of cells such as tumor-associated fibroblasts in some aspects. As a result, when constructing neighborhoods, these cells of different identification types will appear in each other's neighborhoods. This reflects the complex heterogeneity of the cell population itself and is a normal phenomenon caused by differences in the intrinsic characteristics of cells.
[0095] Therefore, considering that the above-mentioned differences will be reflected in cell genes, if there are obvious category differences in the neighborhood of the cell before dimensionality reduction, and the consistency in the neighborhood of the cell after dimensionality reduction is also poor, it is considered a normal phenomenon; if there is strong inconsistency in the neighborhood of the cell before and after dimensionality reduction of the sequencing data, but the consistency is still significantly improved after dimensionality reduction, it can also be said that after dimensionality reduction under the current number of neighbors, there is a better cell cluster performance in the reduced dimensionality space, thereby compensating for the defects of the above-mentioned type density.
[0096] In this embodiment, for any cell after dimensionality reduction, , its rationality index is determined by the following formula:
[0097] ;
[0098] Where: Represents cells rationality indicators; Represents cells after dimensionality reduction density of the second cell type; Represents cells before dimensionality reduction The density of the first cell type.
[0099] In the above formula, Represents cells before and after dimensionality reduction The degree of improvement in cell type consistency within the neighborhood is calculated by comparing the degree of improvement with the cell type consistency after dimensionality reduction. Density of the second cell type The product of , thus obtaining the cell Rationality index The rationality index of a cell reflects the rationality of the current number of neighbors for the cell, preventing the same type of cells from diverging after dimensionality reduction due to a small number of neighbors, thereby affecting the accuracy of cell judgment by dimensionality reduction.
[0100] Step S400: Determine the boundary area and non-boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, and determine the degree of cell mixing of the cell area of each cell type based on the difference between the rationality indicators of the cells corresponding to the data points corresponding to the cell type in the boundary area and the non-boundary area, as well as the distribution of the data points of the cell type pair and the corresponding data points of other cell types in the boundary area.
[0101] Specifically, in the process of finding the optimal number of neighbors, if the optimal number of neighbors for dimensionality reduction by the UMAP algorithm is exceeded, the number of neighbors will be seriously too large. Although cells of the same type show obvious aggregation, which makes the rationality of the cells calculated above too large, cells of different types will also show obvious aggregation, resulting in inaccurate representation of different types of cells, and thus inaccurate cell structure after dimensionality reduction. For example, if the number of neighbors is too large, cell subpopulations that originally had differences will be synthesized into a larger group in the space after dimensionality reduction, which will appear as different types of cells mixed together in the space after dimensionality reduction. Therefore, it is necessary to further judge the rationality of the selection of the number of neighbors in combination with the type information of these cells. While considering the density characteristics of each cell to determine the rationality, that is, considering the characteristics of cells of the same type, it is also necessary to consider the ability to distinguish between different types of cells to prevent the situation where the number of neighbors is too large.
[0102] When different types of cells are mixed, the main manifestation is that different types of cells will be mixed at the boundary part of the cell area composed of the data points corresponding to these different types of cells. Therefore, it is necessary to first obtain the boundary area and non-boundary area of the cell area composed of the data points corresponding to each cell type after dimensionality reduction.
[0103] Furthermore, the steps of determining the boundary area and non-boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction include:
[0104] Determine the boundary data points of the cell area composed of the corresponding data points of each cell type in the data point map after dimensionality reduction;
[0105] Construct the k-neighborhood of each boundary data point, and then determine the neighborhood radius of each boundary data point;
[0106] The minimum neighborhood radius among all neighborhood radiuses is used as the boundary distance;
[0107] The area within the cell region constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction and within the boundary line of the cell region is taken as the boundary area, and the other areas within the cell region except the boundary area are taken as the non-boundary area.
[0108] Following these steps, the data points corresponding to all cells of the same type are obtained from the dimensionality-reduced data point graph. The Graham algorithm is then used to determine the convex hull of these data points, thereby determining the location of the cell region formed by these data points. This operation is repeated for all data points corresponding to different cell types, yielding the location and region information of the cell regions formed by these data points.
[0109] Select any cell type a as the analysis object, obtain the data points whose corresponding data points constitute the boundary of the cell area as the boundary data points of the cell type a, obtain the k-neighborhood after dimensionality reduction constructed by each boundary data point, and determine the neighborhood radius at this time, take the minimum value of the neighborhood radius of each boundary data point, that is, the minimum neighborhood radius, as the boundary distance, and take the area within the boundary distance of the cell area constituted by the corresponding data points of the cell type a as the boundary area of the cell area constituted by the corresponding data points of the cell type a, and record it as At the same time, the area in the cell region except the boundary area is taken as the boundary area of the cell region composed of the corresponding data points of the cell type a, and recorded as The process of determining the k-neighborhood belongs to the prior art and will not be described here. Figure 4It shows that the corresponding data points of cells of a certain cell type constitute the boundary area and non-boundary area of the cell area, where 1 represents the cell area, 2 represents the boundary area, and 3 represents the non-boundary area.
[0110] Among them, in this embodiment, the step of determining the neighborhood radius includes: determining the distance between each data point in the k-neighborhood of each boundary data point and the corresponding boundary data point as the candidate distance for each boundary data point; determining the maximum distance among all the candidate distances for each boundary data point, and using the maximum distance as the neighborhood radius of each boundary data point.
[0111] For any cell type a, the corresponding data points constitute the boundary area of the cell area , if the boundary area The cells corresponding to all data points in the image are still mainly cell type a, and for the boundary areas with a certain degree of mixing, the fewer the mixed boundary areas, the smaller the degree of boundary mixing, which means that the current number of neighbors is reasonable; on the contrary, if the number of neighbors is too large, there will be a large number of data points corresponding to cells of other cell types in the boundary area, the more obvious the mixing between cells of different cell types, and the deeper the degree of boundary mixing.
[0112] Furthermore, the above-mentioned determination of the degree of cell mixing in the cell region of each cell type comprises the following steps:
[0113] In the data point graph after dimensionality reduction, the boundary clarity of the boundary region corresponding to each cell type is determined based on the difference between the rationality indicators of the cells corresponding to the data points of the cell type.
[0114] In the boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, the degree of cell mixing of each other cell type in the boundary area corresponding to each cell type is determined based on the difference in the number of data points corresponding to this cell type and the data points corresponding to each other cell types, as well as the area proportion of the data points corresponding to each other cell types;
[0115] The degree of cell mixing of the cell region of each cell type is determined based on the degree of cell mixing of all other cell types in the boundary region corresponding to each cell type and the boundary clarity of the boundary region corresponding to each cell type.
[0116] For the above steps, in the boundary area and non-boundary area of the cell area constituted by the data points corresponding to each cell type in the data point diagram after dimensionality reduction, if the difference between the rationality indicators of the cells corresponding to the data points of the cell type is small, it means that the cell distribution of the cell type in the boundary area and the non-boundary area is relatively similar, and the possibility of mixing multiple other types of cells is small. At this time, the boundary clarity of the boundary area corresponding to the cell type is higher.
[0117] Furthermore, in the boundary area and non-boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, the boundary clarity of the boundary area corresponding to each cell type is determined according to the difference between the rationality indicators of the cells corresponding to the data points corresponding to the cell type, that is: in the boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, the average value of the rationality indicators of the cells corresponding to all the data points of the cell type is determined to obtain the first rationality indicator mean; in the non-boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, the average value of the rationality indicators of the cells corresponding to all the data points of the cell type is determined to obtain the second rationality indicator mean; according to the difference between the first rationality indicator mean and the second rationality indicator mean, the boundary clarity of the boundary area corresponding to each cell type is determined.
[0118] For the above steps, the data points corresponding to any cell type a constitute the boundary area of the cell area and non-boundary areas , determine the boundary area The mean of the rationality index of cells corresponding to all data points of cell type a is obtained to obtain the first rationality index mean, which is recorded as , and determine the non-boundary area The mean of the rationality index of cells corresponding to all data points of cell type a is obtained to obtain the mean of the second rationality index, which is recorded as According to the mean of the first rationality index and the mean of the second rationality index The difference between the two determines the boundary area corresponding to cell type a The smaller the difference, the greater the value of the boundary clarity.
[0119] In this embodiment, according to the first rationality indicator mean and the mean of the second rationality index The difference between the two is used to determine the boundary area corresponding to cell type a by the following formula Boundary clarity:
[0120] ;
[0121] Where: Indicates the boundary area corresponding to cell type a The clarity of the boundaries; Represents the normalization function.
[0122] In the above formula, if the first rationality index mean and the mean of the second rationality index The smaller the difference between them, the smaller the boundary area corresponding to cell type a. The cells corresponding to the inner data points and the non-boundary area The cells corresponding to the inner data points have a high similarity, so the possibility of mixing multiple types of cells is smaller, and the clarity of the boundary area is higher, and the corresponding The larger the value of .
[0123] In the above manner, the boundary clarity of the boundary region corresponding to each cell type can be determined.
[0124] After determining the boundary clarity of the boundary area corresponding to each cell type, for any cell type a, if the boundary area of the cell area composed of the data points corresponding to the cells of cell type a The more the data points corresponding to the cells of cell type a are, the stronger the significance of the boundary is. The area of data points corresponding to cells of other cell types is large, and the number of data points corresponding to cells of other cell types is close to the number of data points corresponding to cells of cell type a, which indicates that the boundary area The more mixed the data points corresponding to cells of other cell types are, the less significant the boundary will be.
[0125] Furthermore, the above-mentioned determination of the degree of cell mixing of each other cell type within the boundary region corresponding to each cell type includes the following steps:
[0126] In the data point graph after dimensionality reduction, the difference between the number of data points corresponding to the cell type and the number of data points corresponding to each other cell type is determined within the boundary area of the cell area constituted by the data points corresponding to the cell type to obtain a third difference, and a negative correlation process is performed on the third difference to obtain a difference processing result;
[0127] Determine the product of the difference processing result and the area proportion of the data points corresponding to each other cell type in the boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, and obtain a second product, and use the second product as the cell mixing degree of each other cell type in the boundary area corresponding to each cell type.
[0128] In the above steps, in this embodiment, the boundary area of the cell area formed by the data points corresponding to any cell type a is , determine the boundary area The cell region is composed of all corresponding data points of any other cell type b in the cell, and is recorded as Since this cell area The process of determining is exactly the same as the process of determining the area formed by the data points corresponding to the cells of cell type a, and will not be repeated here.
[0129] The boundary area of the cell area formed by the data points corresponding to the cells of cell type a In the cell area, the cell area is composed of all corresponding data points of cell type b. The area ratio, as well as the difference between the number of data points corresponding to cell type a and the number of data points corresponding to cell type b, are used to determine the boundary area corresponding to cell type a using the following formula. The degree of cell mixing of inner cell type b:
[0130] ;
[0131] Where: Indicates the boundary area corresponding to cell type a the degree of cell mixing within cell type b; Represents the boundary area of the cell area composed of data points corresponding to cells of cell type a In the cell type b, the area of the cell region constituted by the corresponding data points; represents the area of the boundary region corresponding to cell type a; Respectively represent the boundary areas of the cell area composed of the data points corresponding to the cells of cell type a Within, the proportion of the number of data points corresponding to cell type a and the proportion of the number of data points corresponding to cell type b; Represents the normalization function.
[0132] In the above formula, Indicates the boundary area corresponding to cell type a The cell area composed of the data points corresponding to cell type b The area ratio reflects the boundary area corresponding to cell type a. The boundary mixing with cell type b, the larger the value, the more serious the mixing. At the same time, the boundary area of the cell area composed of the data points corresponding to the cells of cell type a The proportion of data points corresponding to cell type a The proportion of data points corresponding to cell type b The smaller the difference, the closer the boundary area corresponding to cell type a is. The more severe the degree of cell mixing of inner cell type b.
[0133] According to the above method, the boundary area corresponding to cell type a can be determined The degree of cell mixing of each other cell type in the boundary area can be determined accordingly.
[0134] Based on the cell mixing degree of all other cell types within the boundary region corresponding to each cell type and the boundary clarity of the boundary region corresponding to each cell type, the cell mixing degree of the cell region of each cell type can be determined. Further, determining the cell mixing degree of the cell region of each cell type includes: determining the maximum cell mixing degree among the cell mixing degrees of all other cell types within the boundary region corresponding to each cell type under different set hyperparameters; determining the ratio of the maximum cell mixing degree to the boundary clarity of the boundary region corresponding to each cell type, and using the normalized value of the ratio as the cell mixing degree of the cell region of each cell type.
[0135] Regarding the above steps, in this embodiment, for any cell type a corresponding boundary area The cell mixing degree of other cell types in the cell type a is selected, and the largest cell mixing degree is selected as the boundary area corresponding to cell type a. The degree of cell mixing. At the same time, the boundary area corresponding to cell type a The higher the boundary clarity, the smaller the degree of cell mixing should be. Therefore, the boundary area corresponding to cell type a is used The boundary clarity of the cell type a corresponds to the boundary area The degree of cell mixing is corrected to finally obtain the boundary area corresponding to cell type a Degree of cell mixing:
[0136] ;
[0137] Where: Indicates the boundary area corresponding to cell type a The degree of cell mixing; Indicates the boundary area corresponding to cell type a The maximum cell mixing degree among the cell mixing degrees of other cell types in the Indicates the boundary area corresponding to cell type a The degree of cell mixing with any other cell type b, Indicates taking the maximum value function, that is, taking the boundary area corresponding to cell type a The maximum degree of cell mixing among all other cell types in the Represents the normalization function.
[0138] In this way, the cell mixing degree of the cell region of each cell type can be determined. The cell mixing degree reflects the accuracy of the current neighbor number selection. The higher the cell mixing degree, the lower the accuracy of the previous neighbor number selection.
[0139] Step S500: determining the accuracy of the set hyperparameters with different values according to the overall distribution level of cell mixing degree of cell regions of all cell types under the set hyperparameters with different values.
[0140] Specifically, for each neighbor count value in the neighbor count traversal sequence, the accuracy of the currently selected hyperparameters is determined by comprehensively considering the degree of cell mixing across all cell types. When cell regions of different cell types all have low levels of cell mixing, the accuracy of the currently selected neighbor count value is higher.
[0141] Furthermore, the accuracy of the set hyperparameters with different values is determined based on the overall distribution level of cell mixing in the cell regions of all cell types under the set hyperparameters with different values, and the implementation steps include:
[0142] Determine the maximum cell mixing degree among the cell mixing degrees of all other cell types in the boundary region corresponding to each cell type under different values of the set hyperparameters;
[0143] The ratio of the maximum cell mixing degree to the boundary definition of the boundary area corresponding to each cell type was determined, and the normalized value of the ratio was used as the cell mixing degree of the cell area of each cell type.
[0144] For the above steps, in this embodiment, the accuracy of the set hyperparameters with different values is determined by the following formula based on the overall distribution level of cell mixing degree of cell regions of all cell types under different values of the set hyperparameters:
[0145] ;
[0146] Where: Indicates the accuracy of the set hyperparameters for each value, that is, the accuracy of the number of neighbors for each value; Represents the average cell mixing degree, that is, the cell mixing degree of the cell area of all cell types under each value of the set hyperparameter The average value of .
[0147] According to the above method, the accuracy of the number of neighbors for each value can be determined, that is, the accuracy of the set hyperparameters for each value.
[0148] Step S600: The setting hyperparameter corresponding to the maximum accuracy is used as the setting hyperparameter with the optimal value, and the data point graph after dimensionality reduction corresponding to the setting hyperparameter with the optimal value is used as the optimal dimensionality reduction result.
[0149] Specifically, for each value of the number of neighbors in the neighbor count traversal sequence, the neighbor count with the highest accuracy is selected as the optimal neighbor count, and the resulting dimensionality-reduced data point graph is used as the optimal dimensionality reduction result. Based on this optimal dimensionality reduction result, single cell type annotation is completed, such as using different colors or symbols to mark different cell types in the optimal dimensionality reduction result, analyzing the potential differences between different cells, thereby performing more accurate clustering analysis to discover new cell subpopulations, etc.
[0150] Based on the same inventive concept, the embodiment of the present invention also provides a fast and stable single cell type labeling device, such as Figure 5 As shown, the device includes:
[0151] A cell type recognition module is used to identify the cell types of different cells based on the sequencing data of different cells;
[0152] The data point graph acquisition module is used to perform dimensionality reduction processing on the sequencing data of a single cell under different set hyperparameters and obtain data point graphs before and after dimensionality reduction. Each data point in the data point graph corresponds to a cell.
[0153] The rationality acquisition module is used to determine the rationality index of each cell based on the difference between the number of data points of the same cell type and the neighborhood of the data point corresponding to each cell in the data point graph before and after dimensionality reduction. The rationality index reflects the rationality of the current setting of the hyperparameter for each cell;
[0154] A mixing degree acquisition module is used to determine the boundary area and non-boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, and determine the cell mixing degree of the cell area of each cell type based on the difference between the rationality indicators of the cells corresponding to the data points corresponding to the cell type in the boundary area and the non-boundary area, as well as the distribution of the data points of the cell type pair and the data points corresponding to other cell types in the boundary area;
[0155] an accuracy acquisition module for determining the accuracy of different values of the set hyperparameters based on the overall distribution level of cell mixing of cell regions of all cell types under different values of the set hyperparameters;
[0156] The screening module is used to take the set hyperparameter with the value corresponding to the maximum accuracy as the set hyperparameter with the optimal value, and take the reduced dimensionality data point graph corresponding to the set hyperparameter with the optimal value as the optimal dimensionality reduction result.
[0157] It should be noted that the device provided in the above embodiment is only illustrated by the division of the above functional modules. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the computer device can be divided into different functional modules to complete all or part of the functions described above.
[0158] Based on the same inventive concept, an embodiment of the present invention also provides a fast and stable single-cell type labeling system, which includes: a memory, a processor, and a computer program stored in the memory and running on the processor, wherein when the processor executes the computer program, the system can execute any one of the fast and stable single-cell type labeling methods introduced above.
[0159] In embodiments of the present invention, the system can be divided into functional modules based on the above-described method examples. For example, these modules can correspond to individual functional modules, or two or more functions can be integrated into a single processing module. The integrated modules can be implemented in hardware. It should be noted that the module division in this embodiment is illustrative and represents only a logical functional division. In actual implementation, other division methods may be used.
[0160] Based on the same inventive concept, an embodiment of the present invention further provides a computer program product, which includes: computer program code, which, when executed on a computer, enables the computer to execute any one of the aforementioned fast and stable single-cell type labeling methods.
[0161] Based on the same inventive concept, an embodiment of the present invention also provides a computer-readable storage medium, which stores computer program code. When the computer program code runs on a computer, the computer executes any one of the fast and stable single-cell type labeling methods introduced above.
[0162] It should be noted that the above-described embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the scope of the technical solutions of the various embodiments of the present invention, and should all be included in the protection scope of the present invention.
Claims
1. A fast and stable single cell type annotation method, characterized by: The following steps are involved: Identify cell types of different cells based on sequencing data of different cells; Perform dimensionality reduction on the sequencing data of a single cell under different set hyperparameters, and obtain data point graphs before and after dimensionality reduction. Each data point in the data point graph corresponds to a cell. Based on the difference between the number of data points of the same cell type and the neighborhood of the data point corresponding to each cell in the data point graph before and after dimensionality reduction, the rationality index of each cell is determined. The rationality index reflects the rationality of the current value of the set hyperparameter for each cell. Determine the boundary area and non-boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, and determine the degree of cell mixing in the cell area of each cell type based on the difference between the rationality indicators of the cells corresponding to the data points corresponding to the cell type in the boundary area and the non-boundary area, as well as the distribution of the data points corresponding to the cell type and the data points corresponding to other cell types in the boundary area; Determine the accuracy of the different values of the set hyperparameters based on the overall distribution of the degree of cell mixing in the cell regions of all cell types under the different values of the set hyperparameters; The set hyperparameter with the maximum accuracy is taken as the optimal set hyperparameter, and the data point graph after dimensionality reduction corresponding to the optimal set hyperparameter is taken as the optimal dimensionality reduction result. Determine the plausibility indicators for each cell, including: Determine the proportion of data points of the same cell type as the cell in the neighborhood of the data point corresponding to each cell in the data point graph before dimensionality reduction to obtain a first cell type density; Determine the proportion of data points of the same cell type as the cell in the neighborhood of the data point corresponding to each cell in the data point graph after dimensionality reduction, and obtain the second cell type density; determining a difference between the density of the second cell type and the density of the first cell type to obtain a first difference; determining a product of the first difference and the density of the second cell type to obtain a first product, and using the first product as a rationality indicator for each cell; Determine the degree of cellular intermixing of the cell regions for each cell type, including: In the data point graph after dimensionality reduction, the boundary clarity of the boundary region corresponding to each cell type is determined based on the difference between the rationality indicators of the cells corresponding to the data points of the cell type. In the boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, the degree of cell mixing of each other cell type in the boundary area corresponding to each cell type is determined based on the difference in the number of data points corresponding to this cell type and the data points corresponding to each other cell types, as well as the area proportion of the data points corresponding to each other cell types; Determine the degree of cell mixing of the cell region of each cell type based on the degree of cell mixing of all other cell types within the boundary region corresponding to each cell type and the boundary clarity of the boundary region corresponding to each cell type; Determine the degree of intermixing of each cell type within the boundary region corresponding to each other cell type, including: In the data point graph after dimensionality reduction, the difference between the number of data points corresponding to the cell type and the number of data points corresponding to each other cell type is determined within the boundary area of the cell area constituted by the data points corresponding to the cell type to obtain a third difference, and a negative correlation process is performed on the third difference to obtain a difference processing result; Determine the product of the difference processing result and the area proportion of the data points corresponding to each other cell type in the boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, and obtain a second product, and use the second product as the cell mixing degree of each other cell type in the boundary area corresponding to each cell type.
2. A fast and stable single cell type labeling method according to claim 1, characterized in that: Determine the boundary area and non-boundary area of the cell area composed of the data points corresponding to each cell type in the data point map after dimensionality reduction, including: Determine the boundary data points of the cell area composed of the corresponding data points of each cell type in the data point map after dimensionality reduction; Construct the k-neighborhood of each boundary data point, and then determine the neighborhood radius of each boundary data point; The minimum neighborhood radius among all neighborhood radiuses is used as the boundary distance; The area within the cell region constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction and within the boundary line of the cell region is taken as the boundary area, and the other areas within the cell region except the boundary area are taken as the non-boundary area.
3. A fast and stable single cell type labeling method according to claim 2, characterized in that: Then determine the neighborhood radius of each boundary data point, including: Determine the distance between each data point in the k-neighborhood of each boundary data point and the corresponding boundary data point as the candidate distance for each boundary data point; The maximum distance among all candidate distances of each boundary data point is determined, and the maximum distance is used as the neighborhood radius of each boundary data point.
4. A fast and stable single cell type labeling method according to claim 1, characterized in that: Determine the boundary definition of the border region corresponding to each cell type, including: In the data point graph after dimensionality reduction, within the boundary area of the cell area constituted by the data points corresponding to each cell type, determining the average value of the rationality index of the cells corresponding to all the data points corresponding to the cell type, and obtaining a first rationality index mean; In the non-boundary area of the cell area constituted by the data points corresponding to each cell type in the data point graph after dimensionality reduction, the average value of the rationality index of the cells corresponding to all the data points corresponding to the cell type is determined to obtain the second rationality index mean; Determining the boundary clarity of the boundary region corresponding to each cell type according to the difference between the mean value of the first rationality index and the mean value of the second rationality index; The difference between the mean of the first rationality index and the mean of the second rationality index is determined to obtain a second difference, and negative correlation normalization processing is performed on the second difference to obtain the boundary clarity of the boundary area corresponding to each cell type.
5. A fast and stable single cell type labeling method according to claim 1, characterized in that: Determine the degree of cellular intermixing of the cell regions for each cell type, including: Determine the maximum cell mixing degree among the cell mixing degrees of all other cell types in the boundary region corresponding to each cell type under different values of the set hyperparameters; The ratio of the maximum cell mixing degree to the boundary definition of the boundary area corresponding to each cell type was determined, and the normalized value of the ratio was used as the cell mixing degree of the cell area of each cell type.
6. A fast and stable single cell type labeling method according to claim 1, characterized in that: Determine the accuracy of different values of the set hyperparameters, including: Determine the average of the cell mixing degrees of all cell types in the cell regions of the data point graph after dimensionality reduction by setting the hyperparameters at different values, and obtain the average cell mixing degree; The average cell mixing degree was negatively correlated to obtain the accuracy of the set hyperparameters with different values.
7. A fast and stable single cell type labeling method according to claim 1, characterized in that: The UMAP algorithm was used to perform dimensionality reduction on the sequencing data of a single cell under different values of the set hyperparameter, and the hyperparameter was set as the number of neighbors.
Citation Information
Patent Citations
Cross-species single cell annotation method
CN118298926A
Database visualization method based on single cell
CN119673278A