Visualization method for quantifying glioma invasiveness based on nuclear density functionTechnical Field
The invention belongs to the technical field of biomedicine, and relates to a visualization method for quantifying glioma invasiveness based on a nuclear density function.
Background
Clinical management of gliomas depends to a large extent on the effectiveness of surgery and subsequent radiation therapy. A key problem limiting the success of these procedures is the lack of accurate judgment of the margins in the surgically removed tumor during surgery. In glioma, the invasive boundary of the tumor is difficult to determine due to the growth characteristics of rapid proliferation and wide infiltration, and the determination of the incisional boundary greatly determines the recurrence condition of a patient, such as how to remove the tumor tissue to the maximum extent, and meanwhile, the retention of a normal tissue area is the key for reducing postoperative recurrence and is the biggest problem of glioma treatment.
For the quantification of glioma invasiveness and tumor invasion boundaries, nuclear magnetic resonance is mainly relied on at present for reflection. However, the problem is that the magnetic resonance enhanced signal is not generated on the edema zone around the high-grade glioma, and the signal is not included in the resection range traditionally, but the fluorescence reaction is found on the (sodium fluorescein) fluorescence, and the pathological detection is carried out after the resection to find that a large amount of tumor cells are infiltrated really. This shows that the degree of attack cannot be well controlled by nuclear magnetism alone. The cytological boundaries of tumors are the hot spot of research, and are generally much larger than imaging boundaries. There is no clear conclusion at present, although there is a search, how far the cytological boundary of glioma is from the imaging world.
The established gold standard for tumor boundaries in the frontal zone of invasion requires the aid of pathological diagnosis, which is also the gold standard for the diagnosis of gliomas. Depending on pathological diagnosis, pathologists apply pathological knowledge and methods to examine clinical specimens and to diagnose diseases by morphological observation and analysis of diseased tissues and cells taken from the organism before or after birth. By combining pathological tissue sections, how many tumor cells in the tissues at the front of invasion migrate can be known in detail, and the degree of invasion (how many tumor cells invade) of the tumor can be known, and the invasion depth and the invasion boundary can be judged.
However, in normal research work, especially in the face of glioma tissue sections, researchers have experienced a significant difficulty in how to reflect the invasive state of glioblastomas from the sections. Due to the characteristic of glioma infiltration type growth, the invaded tumor cells are often infiltrated in normal tissues and are difficult to distinguish from the normal tissue cells. Without the ability to read carefully, or without extensive clinical and pathological diagnostic experience, it is difficult to define the affected area. And defining the region of attack requires us to identify from a more macroscopic view rather than from local features. For researchers, the simplest way to find the affected area is to judge the affected area by the density of cell nuclei, and the tumor area is clearly contrasted with the sparse density of the affected area due to the proliferation of a large number of tumor cells, so that the general direction of the affected area can be judged by the trend of the decrease of the density of the cell nuclei. The difficulty of this method lies in how to evaluate the nuclear density characteristics of local regions, which is conventionally identified by cell counting and then the diameter of the region is calculated. Such a method is used regardless of accuracy, and the size of the density is closely related to the size of the proposed area. If the region selection is too large, the density characteristics of the local tissue are not well reflected. This adds to the labor cost and time and effort if the zone selection is too small. This suggested researchers to establish a method of quantifying the nuclear density in sections for assessing glioblastoma invasiveness.
Disclosure of Invention
In view of the above, the present invention provides a visualization method for quantifying glioma invasiveness based on a nuclear density function.
In order to achieve the purpose, the invention provides the following technical scheme:
a visualization method for quantifying glioma invasiveness based on a nuclear density function comprises the following specific steps:
(1) firstly, converting each cell nucleus in a glioma tissue section into a binary image;
(2) then, estimating the nuclear density of the cell nucleus to obtain a nuclear density information map of the cell;
(3) and finally, judging the invasion trend of the tumor through a visualization result.
Preferably, the specific method of step (1) is as follows:
(1-1) acquiring a glioma tissue section image by using image acquisition equipment, importing the image into ImageJ software, and installing a Fiji plug-in package;
and (1-2) opening the picture, running Macro codes to perform batch processing, selecting a color threshold value, and selecting a Convert to Mask column to obtain a binary image.
Further preferably, in the step (1-1), the glioma tissue section image is an HE or immunofluorescence image.
Further preferably, the specific process of step (1-2) is as follows:
(1-2-1) operating Fiji, and opening an HE image or a confocal scanning image; open ("…/…/…");
(1-2-2) automatically selecting a color threshold; setAutoThreshold ("Default dark no-reset"); or a manual selection; run ("threshold.");
(1-2-3) setting a color interval range, and needing manual adjustment; because the hematoxylin staining time and the freshness of the dye can influence the color depth of the cell nucleus, the staining among different batches needs to adjust the threshold value so as to select all the cell nuclei in the picture as much as possible; setThreshold (… ); setOption ("Black background";
(1-2-4) after the cell nucleus area is selected, changing the image into a binary image, namely converting the image into a black and white plate, and converting the black and white plate into values of black foreground color and white background color so as to facilitate various subsequent operations of the binary image; run ("Convert to Mask").
Preferably, the specific method of step (2) is as follows:
(2-1) removing impurity points from the binary image and processing the binary image by a watershed method to obtain positioning information of cell nucleuses;
(2-2) introducing the nuclear localization information obtained in the step (2-1) into the Rstudio, downloading ggplot2 and RColorBrewer packages, and performing mapping by using various nuclear density estimation algorithm-based parameters of ggplot2 to obtain a nuclear density information map of the cells.
Further preferably, in the step (2-1), if the image is an HE stained image, the color threshold needs to be adjusted repeatedly to an optimal value because the depth of hematoxylin staining affects the screening effect; if necessary, the cell nucleus can be adjusted in blocks until all cell nuclei are selected; in the case of fluorescent pictures, only pictures of blue channels were extracted using Photoshop.
Further preferably, the flow of step (2-1) is as follows:
(2-1-1) removing impurities, a median filter, replacing the pixel with an average pixel value of 3 x 3 pixels in its neighborhood; run ("Despeckle");
(2-1-2) performing an expanding operation, and then corroding to smooth the object and fill the vacancy; run ("Close-");
(2-1-3) segmenting the connected cell nucleuses by a watershed method; run ("Watershed").
(2-1-4) analyzing the Particles, clicking Analyze, Analyze Particles, selecting record starts, and obtaining the result XM, YM is the centroid coordinate, File, Save as centroid coordinate result to Excel table.
Preferably, in the step (2-2), the kernel density information map may be set as a two-dimensional statistical histogram or a two-dimensional kernel density histogram, where the two-dimensional statistical histogram may set the visualization type as a square or a hexagon, and the two-dimensional kernel density histogram may set the visualization type as a grid or a polygon. Two-dimensional kernel density histogram method referring to the figures of this example, in addition, if one wants to obtain a simple two-dimensional statistical histogram to reflect the kernel density of a region. The picture region can be divided into many small square lattices, the number of the lattices is realized by setting the bin value, the cell nucleus frequency in the lattices is counted by using the getbin 2d () of ggplot2, and the visualization step is executed.
Preferably, in the step (2-2), visualization is performed by using a stat _ dense _2d () function of the R language ggplot2 package, which can perform nuclear density estimation of cell nuclei in combination with a kde2d () function in the mas package, and perform visualization by using the result; the operation steps and the execution codes are mainly executed:
df represents the coordinate point matrix of the cell nucleus, and V1 and V2 represent the X-axis and Y-axis coordinates respectively
# 2-2-1 scatter plot function
ggplot(df,aes(x,y));
# (2-2-2) drawing a 2D density map function, wherein, the fact that the "raster" indicates that a classic grid map is generated, and the "polygon" can also be set to generate a polygon profile map; use. contour represents the contour line (F is not set);
+stat_density_2d_filled(geom="raster",aes(fill=..density..),contour=F)
# (2-2-3) scale _ fill _ gradientn () setting to fill a color in a density map according to a corresponding density estimate; colormap sets a gradient color interval; limits sets the visual density value range; the break represents that the break parameter redefines the color bar range and divides the color range according to the break range; oob scales:, squish indicates that a color exceeding a threshold range is filled by a limit value; these steps can be set to the same measure among different groups, and the comparison of the invasiveness among the groups is convenient;
+scale_fill_gradientn(colours=colormap,limits=c(2e-07,2e-06),
breaks=seq(2e-07,2e-06,by=1e-09),oob=scales::squish)。
further preferably, the step (2-2) further comprises:
(2-2-4) setting theme parameters
+theme_classic();
(2-2-5) setting the size of the background coordinate axis of the picture, the size of the characters and the like
+theme(panel.background=element_rect(fill="white",
colour ═ black ", size ═ 0.25), and # set the background of the panel
axis.line=element_line(colour="black",size=0.25),
# set coordinate axes color, size
axis.title=element_text(size=13,face="plain",color="black"),
# setting coordinate Axis heading text size, color
axis.text=element_text(size=12,face="plain",color="black"),
legend.position="right")
# sets coordinate axis scale text size, color.
Preferably, the specific method of step (3) is: and judging the distribution density of the tumor cells in the area according to the shade of the color of the nuclear density information map, and roughly judging the invasion trend of the tumor.
The invention has the beneficial effects that:
one method in density function estimation is widely used — two-dimensional histograms. The number of kernels in each region block can be counted by setting the bin value and the geo _ bin2d function for the R language. The characteristic of the graph is simple and easy to understand, the graph is well realized through a computer method, and the counted value can objectively reflect the number of the cell nuclei in the area. But has the following three disadvantages: the density function is not smooth; bin width is considered specified, the density function is greatly affected by the subinterval area, and the same raw data, if taken with different bin values, may exhibit completely different results. The results obtained are shown to be discontinuous, and may differ in the reflection of the invasive properties of the tumor from the actual situation.
The invention relates to a nuclear density estimation map which is used for displaying the distribution condition of data in an X-axis continuous data segment, is a variation of a histogram and uses a smooth curve to draw the distribution trend. Compared to a histogram, it is not affected by the number of packets used, so the distribution shape can be better defined.
The kernel density estimation applied by the invention is used for estimating an unknown density function in a probability wheel, belongs to a non-parameter testing method, and is proposed by Rosenblatt and Emanuel Parzen, also called a Parzen window. It uses a smooth peak function to fit the observed data points and simulates the true probability distribution curve. Kernel density estimation (Kernel density estimation), a non-parametric method for estimating probability density functions, x1,x2…xnThe n sample points are independent and identically distributed F, i is an integer between 1 and n, the probability density function is set as F, and the kernel density is estimated as follows:
k (.) is the kernel density function (non-negative, integral 1, conforming to probability density properties, and mean 0); h >0 is a smoothing parameter, called bandwidth. The kernel density estimation is that the data + bandwidth of each data point is taken as the parameter of the kernel function through the kernel function to obtain n kernel functions, the estimation function of the kernel density is formed through linear superposition, and the kernel density probability density function is obtained after normalization.
In short, when the probability distribution of a certain event is known, if a certain number appears during observation, the probability density of the number is considered to be high, the probability density of the number closer to the certain number is also relatively high, and the probability density of the number farther away from the certain number is relatively low. Based on this consideration, K can be used to fit the far, small, near and large probability density we imagined for the first number in the observation. The probability density distribution functions fitted to each observation are averaged. If some number is important, a weighted average can be taken.
Based on FUJI software and an R language platform, the applicant establishes a set of methods for quantifying glioblastoma multiforme invasiveness by using a Kernel Density Estimation (KDE) algorithm. The invention utilizes the nuclear density estimation algorithm and visualization function encapsulated by the R language ggplot2 package and the MASS package to deduce the nuclear density estimation diagram of the nuclear distribution. The invention can help to effectively judge the invasion condition of the tumor from pathological sections in scientific research work, count the tumor nuclear density of each area by utilizing the nuclear density, roughly judge the invasion trend of the tumor from a visual map, and further reflect the invasion capacity of the tumor from the sections.
Compared with the traditional method for judging the invasion front and quantifying the invasion by mechanically repeating film reading, the method has the advantages that the computer algorithm is adopted, so that the efficiency is high, the time is fast, the accuracy is high, and a large amount of repetitive work such as a large number of film reading and counting is reduced; compared with nuclear magnetic resonance image judgment, the method has high accuracy, overcomes the defect that tumor cells cannot be found microscopically by nuclear magnetic resonance technology, has higher resolution than nuclear magnetic resonance, and has more accurate interpretation on tumor cells in an affected area.
Drawings
In order to make the object, technical scheme and beneficial effect of the invention more clear, the invention provides the following drawings for explanation:
FIG. 1 is a flow chart of the present invention;
FIG. 2 is a schematic view of a process for quantifying an immunodeficient mouse graft tumor by a cell nucleus density method, wherein A is HE for displaying the immunodeficient mouse graft tumor, B is a binarized image for generalizing each cell nucleus into a binarized point, and C is a generated two-dimensional cell nucleus density estimation image;
fig. 3 is a flow chart of quantifying the invasion front of glioblastoma cell by the cell nucleus density method, where a is an immunofluorescence original picture, blue signals represent cell nuclei, B is a generated two-dimensional nuclear density estimation picture, and different nuclear densities are represented by rainbow color block gradients.
Detailed Description
Preferred embodiments of the present invention will be described in detail below with reference to the accompanying drawings.
Example 1:
as shown in fig. 1, a visualization method for quantifying glioma invasiveness based on a nuclear density function specifically includes the following steps:
(1) converting each cell nucleus in the glioma tissue section into a binary image;
the specific method of the step (1) is as follows:
(1-1) acquiring a glioma tissue section image by using image acquisition equipment, and importing the image into ImageJ software; (A in FIG. 2)
And (1-2) opening the picture, running the Macro code of FUJI for batch processing, selecting a color threshold value, and selecting a Convert to Mask column to obtain a binary image.
In the step (1-1), the glioma tissue section image is an HE or immunofluorescence image.
The specific process of the step (1-2) is as follows:
(1-2-1) running FUJI software, and opening an HE image or a confocal scanning image; open ("…/…/…");
(1-2-2) automatically selecting a color threshold; setAutoThreshold ("Default dark no-reset"); or a manual selection; run ("threshold.");
(1-2-3) setting a color interval range, and needing manual adjustment; because the hematoxylin staining time and the freshness of the dye can influence the color depth of the cell nucleus, the staining among different batches needs to adjust the threshold value so as to select all the cell nuclei in the picture as much as possible; setThreshold (… ); setOption ("Black background";
(1-2-4) after the cell nucleus area is selected, changing the image into a binary image, namely converting the image into a black and white plate, and converting the black and white plate into values of black foreground color and white background color so as to facilitate various subsequent operations of the binary image; run ("Convert to Mask").
(2) Performing nuclear density estimation of cell nucleus to obtain nuclear density information map of cell
The specific method of the step (2) is as follows:
(2-1) removing impurity points from the binary image and processing the binary image by a watershed method to obtain positioning information of cell nucleuses; (B in FIG. 2)
(2-2) introducing the nuclear localization information obtained in the step (2-1) into the Rstudio, downloading ggplot2 and RColorBrewer packages, and performing mapping by using various nuclear density estimation algorithm-based parameters of ggplot2 to obtain a nuclear density information map of the cells.
(C in FIG. 2)
In the step (2-1), if the picture is an HE stained picture, the hematoxylin staining depth can affect the screening effect, and the color threshold value needs to be adjusted repeatedly to an optimal value; if necessary, the cell nucleus can be adjusted in blocks until all cell nuclei are selected; in the case of fluorescent pictures, only pictures of blue channels were extracted using Photoshop.
The flow of the step (2-1) is as follows:
(2-1-1) removing impurities, a median filter, replacing the pixel with an average pixel value of 3 x 3 pixels in its neighborhood; run ("Despeckle");
(2-1-2) performing an expanding operation, and then corroding to smooth the object and fill the vacancy; run ("Close-");
(2-1-3) segmenting the connected cell nucleuses by a watershed method; run ("Watershed").
(2-1-4) analyzing the Particles, clicking Analyze, Analyze Particles, selecting record starts, and obtaining the result XM, YM is the centroid coordinate, File, Save as centroid coordinate result to Excel table.
In the step (2-2), the kernel density information map may be set as a two-dimensional statistical histogram or a two-dimensional kernel density histogram, where the two-dimensional statistical histogram may be set as a square or a hexagon in a visualization type, and the two-dimensional kernel density histogram may be set as a grid or a polygon in a visualization type. Two-dimensional kernel density histogram method referring to the figures of this example, in addition, if one wants to obtain a simple two-dimensional statistical histogram to reflect the kernel density of a region. The picture region can be divided into many small square lattices, the number of the lattices is realized by setting the bin value, the cell nucleus frequency in the lattices is counted by using the getbin 2d () of ggplot2, and the visualization step is executed.
In the step (2-2), visualizing by using a stat _ dense _2d () function of an R language ggplot2 package, wherein the core density estimation of the cell nucleus can be carried out by combining a kde2d () function in a MASS package, and the visualization is carried out by using the result; the operation steps and the execution codes are mainly executed:
df represents the coordinate point matrix of the cell nucleus, and V1 and V2 represent the X-axis and Y-axis coordinates respectively
# 2-2-1 scatter plot function
ggplot(df,aes(x,y));
# (2-2-2) drawing a 2D density map function, wherein, the fact that the "raster" indicates that a classic grid map is generated, and the "polygon" can also be set to generate a polygon profile map; use. contour represents the contour line (F is not set);
+stat_density_2d_filled(geom="raster",aes(fill=..density..),contour=F)
# (2-2-3) scale _ fill _ gradientn () setting to fill a color in a density map according to a corresponding density estimate; colormap sets a gradient color interval; limits sets the visual density value range; the break represents that the break parameter redefines the color bar range and divides the color range according to the break range; oob scales:, squish indicates that a color exceeding a threshold range is filled by a limit value; these steps can be set to the same measure among different groups, and the comparison of the invasiveness among the groups is convenient;
+scale_fill_gradientn(colours=colormap,limits=c(2e-07,2e-06),
breaks=seq(2e-07,2e-06,by=1e-09),oob=scales::squish)。
(2-2-4) setting theme parameters
+theme_classic();
(2-2-5) setting the size of the background coordinate axis of the picture, the size of the characters and the like
+theme(panel.background=element_rect(fill="white",
colour ═ black ", size ═ 0.25), and # set the background of the panel
axis.line=element_line(colour="black",size=0.25),
# set coordinate axes color, size
axis.title=element_text(size=13,face="plain",color="black"),
# setting coordinate Axis heading text size, color
axis.text=element_text(size=12,face="plain",color="black"),
legend.position="right")
# sets coordinate axis scale text size, color.
(3) Judging the invasion trend of the tumor through a visualization result
The specific method of the step (3) is as follows: and judging the distribution density of the tumor cells in the area according to the shade of the color of the nuclear density information map, and roughly judging the invasion trend of the tumor.
Example 2:
another immunofluorescence image of human glioblastoma was taken and visualized as in example 1. The results show that this system reflects well the density of nuclei in the local area (fig. 3) and that the trend of tumor invasion can be accurately identified from fig. 3. The area with high nuclear density is the tumor core area at the upper right corner of the figure, and the tumor invasion area is at the left side, so that the color blocks with dark colors can be obviously found to cover the invasion front edge, which represents that the density of the area is relatively high.
Finally, it is noted that the above-mentioned preferred embodiments illustrate rather than limit the invention, and that, although the invention has been described in detail with reference to the above-mentioned preferred embodiments, it will be understood by those skilled in the art that various changes in form and detail may be made therein without departing from the scope of the invention as defined by the appended claims.