Method for predicting morphologies of tissue cells and blood cells of fluorescence in-situ hybridization image
By using multi-scale image enhancement, local extreme feature extraction, energy field gradient mapping model and convex defect analysis techniques in fluorescence in situ hybrid image analysis, the problems of fuzzy cell boundary, heterogeneous cell morphology differences, high noise background and insufficient data labeling in fluorescence in situ hybrid image analysis were solved, and more efficient and accurate cell morphology prediction was achieved.
Patent Information
- Application Number
- CN202510337969.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-21
- Publication Date
- 2025-04-18
AI Technical Summary
The prior art faces problems of fuzzy cell boundary, heterogeneous cell morphology differences, high noise background, insufficient data labeling and balance of segmentation algorithm efficiency and accuracy in fluorescence in situ hybrid image analysis.
A method of morphology prediction of tissue and blood cells in fluorescence in situ hybrid images is proposed. Through multi-scale image enhancement, local extreme feature extraction, energy field gradient mapping model and convex defect analysis technology, the accuracy and morphology prediction of segmentation boundaries are optimized.
It effectively solves the problems of fuzzy cell boundaries, different heterogeneous cell morphology, high noise background and insufficient data labeling, improves segmentation accuracy and efficiency, and reduces subjectivity.
Smart Images

Figure CN119850629A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of data image processing, and in particular to a method for predicting the morphology of tissue cells and blood cells in a fluorescence in situ hybridization image. Background Art
[0002] Fluorescence in situ hybridization (FISH) is a genomics technology that uses fluorescently labeled probes to target and bind to specific nucleic acid sequences in the nuclei of tissue cells and blood cells, thereby visualizing and locating these sequences.
[0003] Tissue cell and blood cell segmentation is an important task in the field of image processing and computer vision. It aims to separate tissue cells and blood cells in the image from the background and other cells. It can help determine the binding position of fluorescent probes to the cell nucleus, and then quantitatively analyze the organization and spatial distribution of the genome. In different tissues, cell morphology and structure vary significantly. The morphological characteristics are not only affected by the cell type, but also by the staining conditions, sample preparation and imaging technology.
[0004] Traditional FISH image analysis relies on manual labeling and empirical rules, which is inefficient and the results are easily affected by subjective factors, especially when the sample size is large or the image is complex, it is difficult to ensure accuracy and consistency. With the rapid development of deep learning in the field of computer vision, image analysis technology based on convolutional neural networks (CNN) has shown excellent performance in the fields of medical image processing and pathological diagnosis. Deep learning can automatically extract high-dimensional features without relying on manual feature design, and has significant advantages in morphological prediction and segmentation of fluorescence images.
[0005] However, there are still some key issues when applying deep learning methods to FISH image analysis: the training of deep learning models requires a large amount of labeled data, but the labeling of fluorescent image samples usually requires professional knowledge, and the cost of obtaining high-quality labeled data is high. Existing deep learning methods may be optimized for general images, but may not be able to effectively adapt to the particularities of FISH images, such as multi-channel fusion and high-noise environments. Summary of the invention
[0006] The present invention aims to solve the challenges faced by tissue cells and blood cells in the prior art, including blurred and overlapping cell boundaries, differences in heterogeneous cell types, changes in nuclear morphology, noise and background interference, and the balance between efficiency and accuracy of segmentation algorithms. The unclear boundaries and irregular morphology between cells increase the difficulty of segmentation, and the morphological differences of heterogeneous cells require the model to have strong adaptability.
[0007] To solve the above technical problems, the present invention is achieved through the following technical solutions: Solution 1: The present invention proposes a method for predicting the morphology of tissue cells and blood cells in fluorescence in situ hybridization images, the method comprising the following steps: Step 1, obtaining tissue cells and blood cells of a fluorescence in situ hybridization image, and performing multi-scale image enhancement on the tissue cells and blood cells of the fluorescence in situ hybridization image; Step 2: Using the local extreme value feature extraction method, extract the local maximum and minimum values of tissue cells and blood cells; Step 3: Based on the maximum and minimum values of the tissue cells and blood cells extracted in step 2, the morphological features of the edge of the cell nucleus are identified to confirm the morphology of the cell nucleus with convex defects; Step 4: Based on the morphological features of the identified cell nucleus edge and the morphological features of the cell nucleus with convex defects, the final morphology of the cell nucleus is predicted.
[0008] Further, a preferred embodiment is provided, in which the method for extracting the local maximum and minimum values of tissue cells and blood cells using the local extreme value feature extraction method in step 2 is: S2.1, processing the fluorescence in situ hybridization images of tissue cells and blood cells; S2.2, calculating the neighborhood index of the fluorescence in situ hybridization image dimension described in S2.1; S2.3, convert the one-dimensional linear index into a multi-dimensional coordinate, initialize an empty two-dimensional array, the two-dimensional array contains the rows and columns of the image, and is used to store the converted coordinates. Loop through each linear index and use a division operation to convert it into row and column coordinates of the image. After each coordinate is calculated, it is updated to prepare for the conversion of the next dimension, and an array containing all coordinates is returned. S2.4, starting from a seed point, expand and mark all connected areas until the entire area is filled to obtain an image of the entire area; S2.5, scan the image of the entire area and find local extreme points; S2.6, filter out extreme points that do not meet the conditions, confirm the remaining local extreme values, and save the confirmed image; S2.7. Based on the image confirmed in S2.6, determine the local extreme point in the local extreme image.
[0009] Furthermore, a preferred embodiment is provided, wherein the processing of the fluorescent in situ hybridization images of tissue cells and blood cells in S2.1 also includes the steps of converting the image color and determining the image threshold.
[0010] Furthermore, a preferred embodiment is provided, in which the morphological features of the edge of the cell nucleus are identified in step 3 by an energy field gradient mapping model.
[0011] Further, a preferred embodiment is provided, in which the method for identifying the morphological features of the edge of the cell nucleus in step 3 is: S3.1, converting the gradient information of the input image into a pseudo-color image; S3.2, calculating the cosine angle between the horizontal component and the amplitude for tone mapping of the pseudo-color image; S3.3, store the integer part of the angle into a for color index calculation, extract the fractional part of the angle, create a zero matrix p with the same shape as the amplitude, t and q are two interpolation parameters, merge the amplitude v, interpolation parameter t, placeholder parameter p and interpolation parameter q along the last dimension, and flatten them into a one-dimensional array; Scale the merged result to the range of [0, 255] and convert it to an 8-bit unsigned integer. Create an index mapping table, generate the final pseudo-color image by reordering the indexes, convert it into a NumPy array, extract the third channel of the image, generate a random 1x1 heat map, multiply the image pixel value by the heat map pixel by pixel, generate a weighted gradient angle, pass the input image into the flow2hsv function, and generate an optical flow pseudo-color image.
[0012] Further, a preferred embodiment is provided, in step 4, the method for predicting the final morphology of the cell nucleus based on the mapping model and the morphology of the cell nucleus of the convex defect is: S4.1, drawing defect points of different colors on the image; S4.2, creating a copy of the image for drawing marks on the original image; S4.3, converting the color image into a grayscale image and extracting the grayscale value for binarization and contour detection; S4.4, extract the complete contour structure in the image for calculating the nucleus morphology of convex defects; S4.5, detecting the concave points in the contour, marking these points in the image, and calculating the convex hull of the contour; S4.6. Visualize and save the detection results to complete the prediction of the final morphology of the cell nucleus.
[0013] Furthermore, a preferred embodiment is provided, wherein the step of extracting a complete contour structure in the image in S4.4 further includes a step of constructing a hierarchical structure based on all extracted contours.
[0014] Furthermore, a preferred embodiment is provided, wherein all extracted contours are realized by the Teh-Chin chain code method.
[0015] Solution 3: A computer device includes a processor and a storage medium, wherein the memory stores a computer program. When the processor runs the computer program stored in the memory, the processor executes any one of the methods described in Solution 1.
[0016] Solution 4: A computer storage medium for storing a computer program. When the computer program is read by a computer, the computer executes any one of the methods described in Solution 1.
[0017] The present invention is beneficial in that: The method for predicting the morphology of tissue cells and blood cells in fluorescence in situ hybridization images described in the present invention solves the common problems of blurred cell boundaries, heterogeneous cell morphological differences, high noise background, insufficient data annotation, inefficiency and subjectivity in FISH image analysis. Through the local extreme value feature extraction technology, the local extreme value points of pixels are identified and the key points of the edge of the cell nucleus are located, thereby optimizing the accuracy of the segmentation boundary. Using the energy field gradient mapping model, an energy distribution map is generated based on the gradient amplitude and direction, and the morphological characteristics and edge structure of the cell nucleus are intuitively presented through pseudo-color images to enhance the segmentation effect. Combined with convex defect analysis technology, the irregularity and local geometric characteristics of the cell nucleus contour are captured, the morphological prediction is optimized and the cell nucleus contour is reconstructed.
[0018] The present invention is also applicable to the fields of biology and cancer detection. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] Figure 1 This is a local extreme value feature extraction diagram for predicting cell morphology in the method for predicting the morphology of tissue cells and blood cells in the original fluorescence in situ hybridization image described in the first embodiment.
[0020] Figure 2 This is a local extreme value feature extraction diagram for predicting cell morphology in the method for predicting the morphology of tissue cells and blood cells in the enhanced fluorescence in situ hybridization image described in the first embodiment.
[0021] Figure 3 This is a schematic diagram of the energy field gradient mapping model described in Implementation Example 11, which describes the morphological characteristics of the cell nucleus through energy distribution.
[0022] Figure 4 This is a schematic diagram of the prediction of cell nucleus morphology based on the mapping model and convex defects as described in the eleventh embodiment.
[0023] Figure 5 This is a schematic diagram of the final morphological label of the predicted cell nucleus as described in Implementation Example 11. DETAILED DESCRIPTION
[0024] In order to make the purpose, technical solutions and advantages of the implementation methods of the present application clearer, the technical solutions in the implementation methods of the present application will be clearly and completely described below in conjunction with the drawings in the implementation methods of the present application. Obviously, the described implementation methods are only part of the implementation methods of the present application, not all of the implementation methods.
[0025] Embodiment 1: This embodiment provides a method for predicting the morphology of tissue cells and blood cells in fluorescence in situ hybridization images, the method comprising the following steps: Step 1, obtaining tissue cells and blood cells of a fluorescence in situ hybridization image, and performing multi-scale image enhancement on the tissue cells and blood cells of the fluorescence in situ hybridization image; Step 2: Using the local extreme value feature extraction method, extract the local maximum and minimum values of tissue cells and blood cells; Step 3: Based on the maximum and minimum values of the tissue cells and blood cells extracted in step 2, the morphological features of the edge of the cell nucleus are identified to confirm the morphology of the cell nucleus with convex defects; Step 4: Based on the morphological features of the identified cell nucleus edge and the morphological features of the cell nucleus with convex defects, the final morphology of the cell nucleus is predicted.
[0026] Embodiment 2: This embodiment further limits the morphological prediction method of tissue cells and blood cells in fluorescence in situ hybridization images described in embodiment 1. The method of extracting the local maximum and minimum values of tissue cells and blood cells using the local extreme value feature extraction method in step 2 is: S2.1, processing the fluorescence in situ hybridization images of tissue cells and blood cells; S2.2, calculating the neighborhood index of the fluorescence in situ hybridization image dimension described in S2.1; S2.3, convert the one-dimensional linear index into a multi-dimensional coordinate, initialize an empty two-dimensional array, the two-dimensional array contains the rows and columns of the image, and is used to store the converted coordinates. Loop through each linear index and use a division operation to convert it into row and column coordinates of the image. After each coordinate is calculated, it is updated to prepare for the conversion of the next dimension, and an array containing all coordinates is returned. S2.4, starting from a seed point, expand and mark all connected areas until the entire area is filled to obtain an image of the entire area; S2.5, scan the image of the entire area and find local extreme points; S2.6, filter out extreme points that do not meet the conditions, confirm the remaining local extreme values, and save the confirmed image; S2.7. Based on the image confirmed in S2.6, determine the local extreme point in the local extreme image.
[0027] Implementation method three: This implementation method further limits the morphology prediction method of tissue cells and blood cells in fluorescence in situ hybridization images described in implementation method one. The processing of fluorescence in situ hybridization images of tissue cells and blood cells in S2.1 also includes the steps of converting image color and determining image threshold.
[0028] Embodiment 4: This embodiment further limits the method for predicting the morphology of tissue cells and blood cells in fluorescence in situ hybridization images described in embodiment 1. In step 3, the morphological features of the edge of the cell nucleus are identified by an energy field gradient mapping model.
[0029] Embodiment 5: This embodiment further limits the method for predicting the morphology of tissue cells and blood cells in fluorescence in situ hybridization images described in embodiment 4. The method for identifying the morphological features of the edge of the cell nucleus in step 3 is: S3.1, converting the gradient information of the input image into a pseudo-color image; S3.2, calculating the cosine angle between the horizontal component and the amplitude for tone mapping of the pseudo-color image; S3.3, store the integer part of the angle into a for color index calculation, extract the fractional part of the angle, create a zero matrix p with the same shape as the amplitude, t and q are two interpolation parameters, merge the amplitude v, interpolation parameter t, placeholder parameter p and interpolation parameter q along the last dimension, and flatten them into a one-dimensional array; Scale the merged result to the range of [0, 255] and convert it to an 8-bit unsigned integer. Create an index mapping table, generate the final pseudo-color image by reordering the indexes, convert it into a NumPy array, extract the third channel of the image, generate a random 1x1 heat map, multiply the image pixel value by the heat map pixel by pixel, generate a weighted gradient angle, pass the input image into the flow2hsv function, and generate an optical flow pseudo-color image.
[0030] Embodiment 6: This embodiment further limits the method for predicting the morphology of tissue cells and blood cells in the fluorescence in situ hybridization image described in embodiment 1. In step 4, the method for predicting the final morphology of the cell nucleus based on the mapping model and the morphology of the cell nucleus of the convex defect is: S4.1, drawing defect points of different colors on the image; S4.2, creating a copy of the image for drawing marks on the original image; S4.3, converting the color image into a grayscale image and extracting the grayscale value for binarization and contour detection; S4.4, extract the complete contour structure in the image for calculating the nucleus morphology of convex defects; S4.5, detecting the concave points in the contour, marking these points in the image, and calculating the convex hull of the contour; S4.6. Visualize and save the detection results to complete the prediction of the final morphology of the cell nucleus.
[0031] Embodiment 7: This embodiment further limits the method for predicting the morphology of tissue cells and blood cells in fluorescence in situ hybridization images described in embodiment 6. Extracting the complete contour structure in the image in S4.4 also includes the step of constructing a hierarchical structure based on all the extracted contours.
[0032] Embodiment 8: This embodiment further limits the method for predicting the morphology of tissue cells and blood cells in fluorescence in situ hybridization images described in embodiment 7. All extracted contours are implemented by the Teh-Chin chain code method.
[0033] Embodiment 9. This embodiment proposes a computer device, including a processor and a storage medium, wherein a computer program is stored in the memory. When the processor runs the computer program stored in the memory, the processor executes the method described in any one of embodiments 1 to 8.
[0034] Embodiment 10: This embodiment proposes a computer storage medium for storing a computer program. When the computer program is read by a computer, the computer executes the method described in any one of Embodiments 1 to 8.
[0035] Implementation 11. This implementation includes an example, which is used to explain the above implementation. Figures 1 to 5 To illustrate this embodiment, the method for predicting the morphology of tissue cells and blood cells in a fluorescence in situ hybridization image described in this embodiment specifically includes the following steps: Acquire tissue cells and blood cells of fluorescence in situ hybridization images, and perform multi-scale image enhancement on the fluorescence images; A local extreme value feature extraction method is used to extract the local maximum and minimum values of the tissue cells and blood cells, identify key points on the edge of the cell nucleus, and find the prominent structure of the cell nucleus in morphological analysis.
[0036] Furthermore, the quantum field gradient mapping model can help capture the details and global trends of cell nuclear morphology, providing valuable information for subsequent morphological analysis.
[0037] The prediction of cell nucleus morphology based on mapping model and convex defect is to predict the cell nucleus morphology by analyzing the energy field and morphological features and combining the defects in the image, such as convex defects.
[0038] Local extreme value feature extraction is used to extract key information of the edge of the cell nucleus; The energy field gradient mapping model is used to describe the morphological characteristics of the cell nucleus through energy distribution; The prediction of cell nucleus morphology based on mapping model and convex defect combines local features, energy field and geometric analysis to predict the final morphology of the cell nucleus; Extracting key information for extracting the edge of the cell nucleus according to the local extreme value feature; Step 1. Import the required library files. NumPy: used for efficient array operations. Images are usually represented as two-dimensional or multi-dimensional arrays. NumPy provides operations on these arrays. Time: used to record the running time of the program to help analyze the performance of the code. Matplotlib.pyplot: used to draw images to help display the results of image processing. cv2: OpenCV library, used for image processing, including operations such as reading images, converting colors, and image thresholding.
[0039] Step 2: Calculate the neighborhood index of a given image dimension. The neighborhood represents the pixel positions around the current pixel, usually a 3x3 window.
[0040] Get the number of dimensions of the image, usually 2 (grayscale image) or 3 (color image), and create a 3x3 block of dim dimension with all elements set to 1. Set the center point (indexed as [1,1,…]) to 0 to indicate the position of the current pixel. Return the indices of all neighboring positions (non-zero positions). Convert the index to a numpy array and transpose it to get the relative position of the neighborhood. Calculate the cumulative product of the image dimensions to get the size of each dimension to assist in subsequent coordinate transformations. Map the neighborhood index to the actual pixel position in the image through matrix multiplication.
[0041] Step 3: Convert the one-dimensional linear index to multi-dimensional coordinates, for example, rows and columns of an image. Initialize an empty two-dimensional array to store the converted coordinates. Loop through each linear index and use the division operation to convert it to the row and column coordinates of the image. After each coordinate is calculated, update idx[i] to prepare for the conversion of the next dimension and return an array rst containing all coordinates.
[0042] Step 4: Starting from a seed point, expand and mark all connected regions until the entire region is filled.
[0043] Mark the seed point p as filled, add the seed point to the buffer buf, and expand the area later. Record the pixel value of the seed point for later judgment of whether to expand. Use the breadth-first search (BFS) algorithm to expand the area. Check each neighboring pixel. If its pixel value is the same as the seed point and is not marked (msk[cp]==1), mark it as 3 and add it to the buffer. Through the loop, gradually expand the area and update the mark.
[0044] Step 5: Scan the image and look for local extreme points (maximum or minimum). mode controls whether to look for local maximum or minimum.
[0045] Get the neighborhood index, convert the image and mask into a one-dimensional array to simplify subsequent index operations. Traverse each pixel, and for each pixel, check whether it is larger (mode=True to find the maximum value) or smaller (mode=False to find the minimum value) than the surrounding neighborhood pixels. If the pixel is an extreme point, call the fill function to fill the area and mark it as processed. Add the pixel positions that meet the conditions to the index idx.
[0046] Step 6: Filter out extreme points that do not meet the conditions to ensure that significant local extreme values are retained.
[0047] Sort the pixel values of the image to ensure that we start processing from the significant extreme values. For each extreme point, check whether its neighborhood meets the threshold condition. mode controls whether to filter the maximum or minimum value, and uses breadth-first search to check the neighborhood to ensure that each extreme point is a local maximum or minimum. Through the filtering process, remove the extreme points that do not meet the conditions.
[0048] Step 7: Find the local extreme points in the image.
[0049] Initialize the mask msk to mark the processed area, use the mark function to find potential extreme points, use the filter function to further filter out the extreme points that meet the conditions, and finally return the coordinates of these extreme points.
[0050] The energy field gradient mapping model is used to describe the morphological characteristics of the cell nucleus through energy distribution; Step 1. Import the required library files: cv2: used for computer vision operations, such as Sobel edge detection, image reading and saving, etc. numpy (np): used for efficient matrix and array operations. PIL.Image: a library for processing images, used to read TIFF format files. matplotlib.pyplot: used to visualize images and data.
[0051] Step 2: Convert the gradient information of the input image img (calculated by Sobel edge detection) into a pseudo-color image (HSV mapping).
[0052] flow_x and flow_y are the horizontal and vertical components of the optical flow field, respectively initialized with random arrays of the same size as img. The optical flow field represents the direction of motion of the image pixels, which will be overwritten by the Sobel edge detection results later, so this is just a placeholder initialization. The Sobel operator is used to calculate the gradient of the image and extract edge features. sobel_x: horizontal gradient. sobel_y: vertical gradient. cv2.CV_64F: Specifies the output data type as a 64-bit floating point number to retain negative values of the gradient. ksize=5: The convolution kernel size is 5, which controls the accuracy of edge detection. Directly assign the Sobel operator results to the horizontal and vertical components of the optical flow. V: The size of the optical flow, calculated using the Pythagorean theorem, represents the gradient amplitude of each pixel. The larger the amplitude, the more drastic the pixel gradient change, that is, the more obvious the edge.
[0053] Step 3, h: The angle of the optical flow. Calculate the cosine angle between the horizontal component and the amplitude for hue mapping of the pseudo-color image. Adjust the angle direction according to the positive or negative sobel_y (vertical gradient). Divide by π * 2 to normalize the angle range from [0,2π] to [0, 1). In order to unify the angle range, add 0.5 to the angle h so that the final range is [0, 1). Normalize the amplitude to [0, 1] to facilitate mapping to the pseudo-color image. Initialize the saturation s to 1 (full saturation). Saturation is usually fixed to 1 to simplify processing.
[0054] Step 4. Store the integer part of the angle in a for subsequent color index calculation, extract the fractional part of the angle, create a zero matrix p with the same shape as the amplitude, t and q are two interpolation parameters for subsequent HSV to RGB mapping, merge v (amplitude), t (interpolation parameter 1), p (placeholder parameter) and q (interpolation parameter 2) along the last dimension, and then flatten it into a one-dimensional array. Scale the merged result to [0, 255] and convert it to an 8-bit unsigned integer, create an index mapping table for rearranging HSV values to RGB. a%6 ensures that the index value range is [0, 5]. By rearranging the index, the final pseudo-color image hsv_image is generated, and its shape is (height, width, 3). Convert it to a NumPy array and extract the third channel of the image to generate a random 1x1 heat map. Multiply the image pixel value and the heat map pixel by pixel to generate a weighted gradient angle. Pass the input image img into the flow2hsv function to generate an optical flow pseudo-color image.
[0055] The prediction of nucleus morphology based on the mapping model and convex defects combines local features Step 1. Import the required library files. cv2: used for image processing operations, such as loading images, detecting contours, convex defect analysis, etc. numpy: used for numerical operations on matrices and arrays. colors: predefined RGB color values, used to draw defect points of different colors on the image.
[0056] Step 2: Keep the original image img to ensure that subsequent processing will not affect the original image. Use OpenCV to load the image file corners_.tif and create an image copy img_copy to draw the mark on the original image.
[0057] Step 3: Extract grayscale values for binarization and contour detection. Convert color images to grayscale images to reduce data dimensions for subsequent processing. Convert grayscale images to binary images. Pixels with grayscale values below the threshold of 10 become 0 (black), and pixels with grayscale values above the threshold become 255 (white). Create a 3x3 structured kernel and apply morphological opening (erosion followed by dilation) to remove small noise points and pseudo-boundaries through 1 iteration.
[0058] Step 4: Extract the complete contour structure in the image for subsequent convex defect calculation. Use OpenCV's cv2.findContours function to detect the contours of the binary image. cv2.CHAIN_APPROX_SIMPLE: compress the redundant points on the horizontal, vertical and diagonal lines, and only retain the key points. cv2.RETR_TREE: extract all contours and build a hierarchy (parent-child relationship). Detect the contours by another method to compare the effects of the two methods. Detect the contours by the CHAIN_APPROX_TC89_L1 method, use the Teh-Chin chain code algorithm for high-precision contour approximation, and use cv2.RETR_LIST to extract all contours, but do not build a hierarchy.
[0059] Step 5. Detect the significant concave points in the contour and mark these points in the image. Calculate the convex hull of the contour: use cv2.convexHull to calculate the convex hull of the contour, returnPoints=False: return the index of the vertex in the convex hull in the contour. Detect convex defects: use cv2.convexityDefects to calculate the concave area (defect) between the convex hull and the contour. Each defect contains 4 values: starting point s, end point e, farthest point f, depth d. Draw defect points: filter out insignificant defects according to depth d>10, and use cv2.circle to draw circles at the defect points. Use red (0, 0, 255) to draw defects detected by the CHAIN_APPROX_SIMPLE method, and use green (0, 255, 0) to draw defects detected by the CHAIN_APPROX_TC89_L1 method.
[0060] Step 6. Visualize and save the detection results for further analysis or verification. Use cv2.imshow to display the labeled image and cv2.imwrite to save the result as file result3.TIF.
[0061] In summary, this embodiment uses local extreme value feature extraction technology to identify local extreme value points of pixels and locate key points of the edge of the cell nucleus, thereby optimizing the accuracy of the segmentation boundary. Using the energy field gradient mapping model, an energy distribution map is generated based on the gradient amplitude and direction, and the morphological characteristics and edge structure of the cell nucleus are intuitively presented through pseudo-color images to enhance the segmentation effect. Combined with convex defect analysis technology, the irregularity and local geometric characteristics of the cell nucleus contour are captured, the morphological prediction is optimized, and the cell nucleus contour is reconstructed.
[0062] Those skilled in the art will appreciate that the above are only preferred embodiments of the present invention, and the various embodiments of the present disclosure and / or the features described in the claims may be combined or combined in various ways, even if such combinations or combinations are not explicitly described in the present disclosure. It is not intended to limit the present invention. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art may still modify the technical solutions described in the aforementioned embodiments, or perform equivalent substitutions on some of the technical features therein. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention shall be included in the protection scope of the present invention.
[0063] Although preferred embodiments of the present invention have been described, additional changes and modifications may be made to these embodiments by those skilled in the art once the basic inventive concepts are known. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the present invention. Obviously, those skilled in the art may make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.
Claims
1. A method for predicting the morphology of tissue cells and blood cells from fluorescence in situ hybridization images, characterized in that: The method comprises the following steps: Step 1, obtaining tissue cells and blood cells of a fluorescence in situ hybridization image, and performing multi-scale image enhancement on the tissue cells and blood cells of the fluorescence in situ hybridization image; Step 2: Using the local extreme value feature extraction method, extract the local maximum and minimum values of tissue cells and blood cells; Step 3: Based on the maximum and minimum values of the tissue cells and blood cells extracted in step 2, the morphological features of the edge of the cell nucleus are identified to confirm the morphology of the cell nucleus with convex defects; Step 4: Based on the morphological features of the identified cell nucleus edge and the morphological features of the cell nucleus with convex defects, the final morphology of the cell nucleus is predicted.
2. The method for predicting the morphology of tissue cells and blood cells in fluorescence in situ hybridization images according to claim 1, characterized in that: The method for extracting the local maximum and minimum values of tissue cells and blood cells using the local extreme value feature extraction method in step 2 is: S2.1, processing the fluorescence in situ hybridization images of tissue cells and blood cells; S2.2, calculating the neighborhood index of the fluorescence in situ hybridization image dimension described in S2.1; S2.3, convert the one-dimensional linear index into a multi-dimensional coordinate, initialize an empty two-dimensional array, the two-dimensional array contains the rows and columns of the image, and is used to store the converted coordinates. Loop through each linear index and use a division operation to convert it into row and column coordinates of the image. After each coordinate is calculated, it is updated to prepare for the conversion of the next dimension, and an array containing all coordinates is returned. S2.4, starting from a seed point, expand and mark all connected areas until the entire area is filled to obtain an image of the entire area; S2.5, scan the image of the entire area and find local extreme points; S2.6, filter out extreme points that do not meet the conditions, confirm the remaining local extreme values, and save the confirmed image; S2.
7. Based on the image confirmed in S2.6, determine the local extreme point in the local extreme image.
3. The method for predicting the morphology of tissue cells and blood cells in fluorescence in situ hybridization images according to claim 1, characterized in that: The processing of the fluorescence in situ hybridization images of tissue cells and blood cells in S2.1 also includes the steps of converting the image color and determining the image threshold.
4. The method for predicting the morphology of tissue cells and blood cells in fluorescence in situ hybridization images according to claim 1, characterized in that: The morphological features of the cell nucleus edge identified in step 3 are achieved through the energy field gradient mapping model.
5. The method for predicting the morphology of tissue cells and blood cells in fluorescence in situ hybridization images according to claim 4, characterized in that: The method for identifying the morphological features of the edge of the cell nucleus in step 3 is: S3.1, converting the gradient information of the input image into a pseudo-color image; S3.2, calculating the cosine angle between the horizontal component and the amplitude for tone mapping of the pseudo-color image; S3.3, store the integer part of the angle into a for color index calculation, extract the fractional part of the angle, create a zero matrix p with the same shape as the amplitude, t and q are two interpolation parameters, merge the amplitude v, interpolation parameter t, placeholder parameter p and interpolation parameter q along the last dimension, and flatten them into a one-dimensional array; Scale the merged result to the range of [0, 255] and convert it to an 8-bit unsigned integer. Create an index mapping table, generate the final pseudo-color image by reordering the indexes, convert it into a NumPy array, extract the third channel of the image, generate a random 1x1 heat map, multiply the image pixel value by the heat map pixel by pixel, generate a weighted gradient angle, pass the input image into the flow2hsv function, and generate an optical flow pseudo-color image.
6. The method for predicting the morphology of tissue cells and blood cells in fluorescence in situ hybridization images according to claim 1, characterized in that: In step 4, based on the mapping model and the morphology of the cell nucleus with convex defects, the method for predicting the final morphology of the cell nucleus is: S4.1, drawing defect points of different colors on the image; S4.2, creating a copy of the image for drawing marks on the original image; S4.3, converting the color image into a grayscale image and extracting the grayscale value for binarization and contour detection; S4.4, extract the complete contour structure in the image for calculating the nucleus morphology of convex defects; S4.5, detecting the concave points in the contour, marking these points in the image, and calculating the convex hull of the contour; S4.
6. Visualize and save the detection results to complete the prediction of the final morphology of the cell nucleus.
7. The method for predicting the morphology of tissue cells and blood cells in fluorescence in situ hybridization images according to claim 6, characterized in that: Extracting the complete contour structure in the image in S4.4 also includes the step of constructing a hierarchical structure based on all the extracted contours.
8. The method for predicting the morphology of tissue cells and blood cells in fluorescence in situ hybridization images according to claim 7, characterized in that: All the extracted contours are implemented by the Teh-Chin chain code method.
9. A computer device comprising a memory and a processor, characterized in that: A computer program is stored in the memory. When the processor runs the computer program stored in the memory, the processor executes the method according to any one of claims 1 to 8.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 8 are implemented.
Citation Information
Cited By
Stacked cell level judgment method based on contouring concavity and convexity
CN121884341A