A method and device for identifying crypt branches in inflammatory bowel disease

In the inflammatory bowel disease crypt area image, the possibility and degree of crypt are determined according to the grayscale value of pixel points and the change trend of surrounding pixel points, and the grayscale value is adjusted to identify crypt branches, and the existing technology is solved. The problem of low accuracy of segmentation of mid-crypt area has achieved higher recognition accuracy and diagnostic efficiency.

CN119131039BActive Publication Date: 2025-02-11RENMIN HOSPITAL OF WUHAN UNIVERSITY (HUBEI GENERAL HOSPITAL)
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202411627466.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-11-14
Publication Date
2025-02-11
Estimated Expiration
2044-11-14

AI Technical Summary

Technical Problem

In the prior art, the accuracy of segmentation results of crypts of inflammatory bowel disease is low, which affects the accuracy of crypts.

Method used

The probability of crypts for each pixel is determined based on the grayscale value of each pixel in the intestinal crypt grayscale image and the trend of grayscale value of multiple pixels in the preset neighborhood, and the probability of crypts for each pixel is determined based on the surrounding pixels. The crypt probability trend of the point changes, determines the crypt degree of each pixel point, and then adjusts the grayscale value to identify the crypt branch.

Benefits of technology

It improves the recognition accuracy of crypt branches of inflammatory bowel disease, enhances the prominence of crypt areas in the image, and improves diagnostic efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119131039B_ABST
    Figure CN119131039B_ABST
Patent Text Reader

Abstract

The present invention provides a method and device for identifying crypt branches of inflammatory bowel disease, which relates to the field of image processing technology. The method includes: determining the crypt possibility of each pixel point according to the grayscale value of each pixel point in the intestinal crypt grayscale image and the grayscale value change trend of multiple pixels points in the preset neighborhood of each pixel point; determining the crypt degree of each pixel point according to the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixels points around each pixel point; and identifying the crypt branch after adjusting the grayscale value of each pixel point based on the crypt degree of each pixel point. The present invention determines the possibility that each pixel point is located in the crypt area through the grayscale value of each pixel point itself and the grayscale value change trend of multiple pixels points around the pixel point, thereby enhancing the pixels in the crypt area to better identify the crypt branch.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of image processing technology, and in particular to a method and device for identifying crypt branches of inflammatory bowel disease. Background Art

[0002] The results of pathological examination are of great significance for the diagnosis and differentiation of inflammatory bowel disease. Specifically, by detecting whether there are abnormalities in the morphology of structures such as crypts and villi in the pathological images, it can assist in determining whether inflammatory bowel disease occurs.

[0003] At present, threshold-based automatic segmentation technology can automatically segment the crypt area in the pathological image, and identify and quantify abnormalities in the crypt morphology, such as branching, twisting, expansion, etc., which can help doctors make more accurate judgments and treatments, while improving efficiency, greatly shortening the diagnosis time and improving work efficiency.

[0004] However, since the crypt area is close to the villus area, and the crypt area after the lesion is bifurcated, twisted, and expanded, the edge of the crypt area is not obvious and the edge grayscale is not uniform, which affects the segmentation results of the crypt area based on the threshold automatic segmentation, and further affects the accuracy of the crypt area recognition. Summary of the invention

[0005] The present invention provides a method and device for identifying crypt branches in inflammatory bowel disease, so as to solve the defect that the accuracy of the segmentation results of the crypt area in the prior art is low, which in turn affects the accuracy of the identification of the crypt area, and realizes a method and device for identifying crypt branches in inflammatory bowel disease with higher accuracy.

[0006] The present invention provides a method for identifying crypt branches in inflammatory bowel disease, comprising:

[0007] Determine the crypt possibility of each pixel point according to the grayscale value of each pixel point in the intestinal crypt grayscale image and the grayscale value change trend of multiple pixels points in a preset neighborhood of each pixel point;

[0008] Determining the crypt degree of each pixel point according to the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixel points around each pixel point;

[0009] After adjusting the grayscale value of each pixel based on the crypt degree of each pixel, the crypt branch is identified.

[0010] According to a method for identifying crypt branches in inflammatory bowel disease provided by the present invention, the step of determining the crypt possibility of each pixel point according to the grayscale value of each pixel point in the intestinal crypt grayscale image and the grayscale value change trend of multiple pixels points in a preset neighborhood of each pixel point specifically includes:

[0011] Calculating the crypt feature value of each pixel point according to the gray value of each pixel point and the gray average value of multiple pixels in a preset neighborhood of each pixel point;

[0012] The crypt possibility of each pixel is determined according to the crypt feature quantity of each pixel and the gray value change trend of multiple pixels in a preset window of each pixel.

[0013] According to a method for identifying crypt branches in inflammatory bowel disease provided by the present invention, the step of determining the crypt possibility of each pixel point according to the crypt feature quantity of each pixel point and the gray value change trend of multiple pixels in a preset window of each pixel point specifically includes:

[0014] Determining the type of the crypt feature quantity of each pixel point according to the values ​​of the crypt feature quantities of multiple pixels in the preset window of each pixel point;

[0015] Sorting the values ​​of the crypt feature type of each pixel point in ascending order to obtain a crypt feature type sequence of each pixel point;

[0016] The number of crypt feature quantity types of each pixel point is used as the number of rows and columns of the feature matrix of each pixel point to define the feature matrix of each pixel point;

[0017] According to the crypt feature type sequence of each pixel in the preset window of each pixel, all the pixels in the preset window of each pixel are filled into the feature matrix of each pixel;

[0018] The crypt possibility of each pixel is determined according to the feature matrix of each pixel.

[0019] According to a method for identifying crypt branches of inflammatory bowel disease provided by the present invention, the step of determining the crypt degree of each pixel point according to the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixels around each pixel point specifically includes:

[0020] Constructing a trend group for each pixel point according to the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixels around each pixel point;

[0021] Determine the crypt degree of each pixel point according to the trend group of each pixel point for:

[0022] ;

[0023] In the formula, Representativei The number of trend points in a trend group of pixels; Representative i Crypt probability of each pixel; Representative i The trend group of pixels The crypt probability of a trend point.

[0024] According to a method for identifying crypt branches of inflammatory bowel disease provided by the present invention, the step of constructing a trend group of each pixel point according to the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixel points around each pixel point specifically includes:

[0025] Record each pixel point as the first trend point, and perform a search with the first trend point as the starting point;

[0026] Within the eight neighborhoods of each pixel point, the pixel point with the smallest crypt possibility difference with the first trend point is determined as the second trend point;

[0027] Similarly, the pixel point with the smallest difference in crypt possibility between the second trend point and the eight-neighborhood region is determined as the next trend point, and the search is stopped when the next trend point is not a pixel point within a preset range centered on each pixel point, or when there is no pixel point with a smaller crypt possibility than the previous trend point among the pixel points within the preset range centered on each pixel point;

[0028] The trend points obtained by searching and within a preset range centered on each pixel point are constructed as a trend group for each pixel point.

[0029] According to a method for identifying crypt branches of inflammatory bowel disease provided by the present invention, after adjusting the gray value of each pixel based on the crypt degree of each pixel, before the step of identifying the crypt branches, the method further includes:

[0030] After normalizing the crypt degree of each pixel, multiply it by the gray value of each pixel and round the result upward;

[0031] The rounded result is used to update the grayscale value of each pixel.

[0032] The present invention also provides a device for identifying crypt branches in inflammatory bowel disease, comprising:

[0033] A first determination module is used to determine the crypt possibility of each pixel point according to the grayscale value of each pixel point in the intestinal crypt grayscale image and the grayscale value change trend of multiple pixels points in a preset neighborhood of each pixel point;

[0034] A second determination module is used to determine the crypt degree of each pixel point according to the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixels around each pixel point;

[0035] The adjustment and identification module is used to identify the crypt branches after adjusting the gray value of each pixel based on the crypt degree of each pixel.

[0036] The present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, a method for identifying crypt branches of inflammatory bowel disease as described in any one of the above is implemented.

[0037] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements a method for identifying crypt branches in inflammatory bowel disease as described in any one of the above.

[0038] The present invention also provides a computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the method for identifying crypt branches in inflammatory bowel disease as described in any one of the above is implemented.

[0039] The present invention provides a method and device for identifying crypt branches of inflammatory bowel disease. The crypt possibility of each pixel being a pixel in the crypt area is obtained by comparing the grayscale value of each pixel itself with the grayscale value change trend of multiple pixels around the pixel. The crypt degree of each pixel is further obtained based on the crypt possibility change trend of multiple pixels around each pixel, which is used to adjust the grayscale value of each pixel, thereby further highlighting the crypt area in the image and obtaining a more accurate crypt branch identification result. BRIEF DESCRIPTION OF THE DRAWINGS

[0040] In order to more clearly illustrate the technical solutions in the present invention or the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0041] Figure 1 It is a schematic diagram of a process for identifying crypt branches of inflammatory bowel disease provided by the present invention;

[0042] Figure 2 It is a schematic diagram of the structure of a device for identifying inflammatory bowel disease crypt branches provided by the present invention;

[0043] Figure 3 It is a structural schematic diagram of the electronic device provided by the present invention. DETAILED DESCRIPTION

[0044] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be clearly and completely described below in conjunction with the drawings of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0045] Combine the following Figure 1 The present invention introduces a method for identifying crypt branches in inflammatory bowel disease, such as Figure 1 As shown, including:

[0046] Step 101, determining the crypt possibility of each pixel point according to the grayscale value of each pixel point in the intestinal crypt grayscale image and the grayscale value change trend of multiple pixels points in a preset neighborhood of each pixel point;

[0047] The intestinal pathological image is gray-scaled to obtain a gray-scale image of the intestinal crypt. The endoscopic examination is performed under anesthesia or mild sedation. The endoscope is inserted through the anus until it reaches the intestinal segment to be examined. If an abnormal intestinal mucosal area is found through the endoscope, a small piece of tissue sample is removed through the endoscope using a biopsy forceps. After the tissue sample is obtained, it will be sent to the pathology laboratory and observed under a microscope to obtain the pathological image of the mucosal lesions of inflammatory bowel disease.

[0048] Since the crypt is a tubular gland formed by the intestinal epithelium sinking into the lamina propria at the root of the villi and opening between adjacent villi, the identification of the crypt area in the pathological image mainly lies in distinguishing the crypt area from the villus area.

[0049] Furthermore, in the grayscale image of the intestinal crypt, the grayscale value of the pixel points in the crypt area is generally larger than the grayscale value of the pixel points in the villus area. At the same time, due to the presence of Paneth cells at the bottom of the crypt, the grayscale value of the pixel points in the crypt area gradually increases from the edge of the crypt to the center of the crypt.

[0050] In the fluff area of ​​the grayscale image, since the fluff is thicker in the middle and thinner on both sides, in the original grayscale image that has not undergone edge enhancement processing, the pixel points located at the center of the fluff are darker in color, and the pixel points close to the edge of the fluff are lighter in color. Therefore, the grayscale value of the pixel points in the direction from the center of the fluff area to the edge of the fluff area gradually increases.

[0051] In summary, it can be understood that the pixel values ​​of the entire pixel points show a gradually increasing trend from the center of the villus region to the center of the crypt region, and the increase amplitude gradually decreases.

[0052] When the grayscale value difference between each pixel and its corresponding neighboring pixels is large, it means that the pixel is more likely to be a pixel in the villus area. When the grayscale value difference between each pixel and its corresponding neighboring pixels is small, it means that the pixel is more likely to be a pixel in the crypt area. Therefore, the crypt possibility of each pixel is obtained by combining the grayscale value of each pixel and the grayscale value difference between each pixel and its corresponding neighboring pixels.

[0053] On this basis, the crypt possibility of each pixel can be determined according to the grayscale value of each pixel in the intestinal crypt grayscale image and the grayscale value change trend of multiple pixels in the preset neighborhood of each pixel.

[0054] The crypt possibility of each pixel represents the possibility that each pixel is a pixel in the crypt region. The higher the crypt possibility, the more likely the corresponding pixel is to be a pixel in the crypt region.

[0055] The grayscale value variation trend of multiple pixels in the preset neighborhood of each pixel represents the grayscale value variation trend of the pixels around each pixel. Optionally, the range of the preset neighborhood can be determined according to the size of the grayscale image.

[0056] Step 102, determining the crypt degree of each pixel point according to the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixels around each pixel point;

[0057] Furthermore, since the crypt possibility of pixels closer to the center of the crypt area is greater than that of pixels at the edge of the crypt area, the accuracy of judging whether a pixel belongs to a crypt based only on the crypt possibility of each pixel is low.

[0058] Since the crypt possibilities of the pixels in the crypt area are generally similar to those of the surrounding pixels, on the basis of obtaining the crypt possibility of each pixel, the crypt degree of each pixel can be further determined based on the change trend of the crypt possibilities of multiple pixels around each pixel. The higher the crypt degree, the more likely the corresponding pixel is to be a pixel in the crypt area.

[0059] Step 103: After adjusting the grayscale value of each pixel based on the crypt degree of each pixel, identify the crypt branch.

[0060] The gray value of each pixel is adjusted using the crypt degree of each pixel, so as to highlight the crypt area in the gray image, and thus, based on the existing detection technology, the crypt area with deformation such as branching can be better identified.

[0061] Optionally, the grayscale value of each pixel is weighted using the crypt degree, thereby adjusting the grayscale value of each pixel.

[0062] The present invention obtains the crypt possibility of each pixel being a pixel in the crypt area through the grayscale value of each pixel itself and the grayscale value change trend of multiple pixels around the pixel, and further obtains the crypt degree of each pixel according to the crypt possibility change trend of multiple pixels around each pixel, which is used to adjust the grayscale value of each pixel, thereby highlighting the crypt area in the image and obtaining a more accurate crypt branch recognition result.

[0063] In a method for identifying crypt branches of inflammatory bowel disease of the present invention, the step of determining the crypt possibility of each pixel point according to the grayscale value of each pixel point in the intestinal crypt grayscale image and the grayscale value change trend of multiple pixels points in a preset neighborhood of each pixel point specifically includes:

[0064] Calculating the crypt feature value of each pixel point according to the gray value of each pixel point and the gray average value of multiple pixels in a preset neighborhood of each pixel point;

[0065] Optionally, the size of the preset neighborhood is determined based on the size of the pathology image.

[0066] In a feasible implementation, the preset neighborhood side length is , taking each pixel of the intestinal crypt grayscale image as the central pixel, construct × The neighborhood of each pixel point is the corresponding neighborhood of the preset neighborhood side length. In other feasible implementations, the implementer can preset the neighborhood edge length according to the specific implementation situation. The value of .

[0067] Furthermore, the crypt feature of each pixel It can be expressed as:

[0068] ;

[0069] In the formula, Indicates i The gray value of each pixel; Indicates i The grayscale average of multiple pixels in a preset neighborhood of a pixel; exp() is an exponential function with the natural constant e as the base, and || is the absolute value symbol.

[0070] Among them, the crypt feature value of each pixel is The larger the value is, the more likely the pixel is to be a pixel in the crypt area.

[0071] The crypt possibility of each pixel is determined according to the crypt feature quantity of each pixel and the gray value change trend of multiple pixels in a preset window of each pixel.

[0072] It should be noted that it is known that the grayscale value of the pixel points gradually increases from the center of the villus area to the center of the crypt area, and the increase gradually decreases. At the same time, the grayscale of the pixel points near the center of the crypt area is relatively similar, so the crypt feature values ​​of the pixel points near the center of the crypt area are relatively similar. Based on this feature, the crypt possibility of each pixel point is obtained.

[0073] The preset window represents multiple pixel points around each pixel point, and the grayscale value change trend of the multiple pixel points in the preset window is the grayscale value change trend presented by the multiple pixel points around each pixel point.

[0074] In a method for identifying crypt branches of inflammatory bowel disease of the present invention, the step of determining the crypt possibility of each pixel point according to the crypt feature quantity of each pixel point and the gray value change trend of multiple pixels in a preset window of each pixel point specifically includes:

[0075] Determining the type of the crypt feature quantity of each pixel point according to the values ​​of the crypt feature quantities of multiple pixels in the preset window of each pixel point;

[0076] Optionally, the side length of the preset window is β ,set up β =5. In other feasible implementations, the side length of the preset window may be determined accordingly according to the specific implementation, thereby determining the number of pixels in the preset window.

[0077] First i Pixels are used as the center to build β × β The default window is i The same crypt feature value is considered as a category, and the first i The crypt feature type of the pixel in the preset window of pixels.

[0078] Sorting the values ​​of the crypt feature type of each pixel point in ascending order to obtain a crypt feature type sequence of each pixel point;

[0079] The number of crypt feature quantity types of each pixel point is used as the number of rows and columns of the feature matrix of each pixel point to define the feature matrix of each pixel point;

[0080] According to the crypt feature type sequence of each pixel in the preset window of each pixel, all the pixels in the preset window of each pixel are filled into the feature matrix of each pixel;

[0081] Furthermore, i The values ​​corresponding to the types of crypt features of the pixel points are obtained from small to large. i The crypt feature type sequence of each pixel.

[0082] On this basis, the i The number of categories of the crypt feature types of pixels is taken as the i The number of rows and columns of the feature matrix, and the i The crypt feature type sequence of the pixel point is taken as the first i The horizontal index directory and the vertical index directory of the feature matrix of the i-th pixel point define the feature matrix of the i-th pixel point.

[0083] Afterwards, if i The first pixel in the preset window j If there is a right adjacent pixel point, the j The crypt feature value of the pixel point is used as the horizontal index of the pixel point, and the crypt feature value of the pixel point adjacent to the right of the pixel point is used as the vertical index of the pixel point. j The horizontal index and vertical index of the pixel point are j Fill the first pixel i The feature matrix of pixels.

[0084] Optionally, if j If there is no right adjacent pixel point, it is determined whether the pixel point has a lower adjacent pixel point, a left adjacent pixel point or an upper adjacent pixel point, and the crypt feature value of the first existing pixel point is taken as the first j In other feasible implementations, the vertical index of the pixel point can also be determined by searching in the order of top, left, and bottom. j The vertical index of the pixel.

[0085] According to the above method, the i All pixels in the preset window of pixels are filled in i The feature matrix corresponding to each pixel.

[0086] The crypt possibility of each pixel is determined according to the feature matrix of each pixel.

[0087] Optionally, the crypt likelihood for each pixel is:

[0088] ;

[0089] In the formula, Representative i Crypt probability of each pixel; Representative i Crypt feature quantity of each pixel; Representative i The pixel window j The pixel at i The number of pixels with the same index position in the feature matrix of pixels; Representative i The pixel at i The index position of the pixel in the feature matrix is i The pixel window j The pixel at i The Euclidean distance between the index positions in the feature matrix of pixels; Representative i The number of pixels in a window of pixels.

[0090] Among them, norm() represents the normalization function, which uses the linear normalization method and the normalized object is all pixels. The value of .

[0091] On this basis, when as well as The larger the value of i The crypt eigenvalues ​​of all pixels in the window of pixels are relatively similar, so i The greater the probability of a crypt with more pixels.

[0092] In the above manner, the crypt possibility of each pixel can be determined according to the number of pixels at the same position in the feature matrix of each pixel and the Euclidean distance between each pixel in the preset window and the current pixel in the feature matrix.

[0093] In a method for identifying crypt branches of inflammatory bowel disease of the present invention, the step of determining the crypt degree of each pixel point according to the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixels around each pixel point specifically includes:

[0094] Constructing a trend group for each pixel point according to the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixels around each pixel point;

[0095] It should be noted that although the crypt possibility of each pixel has been obtained, it is known that the pixel with a greater crypt possibility is more likely to be a crypt pixel. Since the crypt possibility of the pixel closer to the center of the crypt area is greater than that of the pixel at the edge of the crypt area, it is inaccurate to judge whether the pixel is a crypt pixel only based on the crypt possibility of each pixel.

[0096] Since the crypt possibilities of crypt pixels and their surrounding pixels are relatively similar, we first obtain the trend group of each pixel based on the crypt possibility of each pixel. Finally, we obtain the crypt degree of each pixel based on the approximate crypt possibilities of each pixel and each trend point in its trend group and the number of trend points in the trend group of each pixel.

[0097] It can be understood that the trend group of each pixel point represents the change trend of the crypt possibility of multiple pixel points around each pixel point.

[0098] Determine the crypt degree of each pixel point according to the trend group of each pixel point for:

[0099] ;

[0100] In the formula, Representative i The number of trend points in a trend group of pixels; Representative i Crypt probability of each pixel; Representative i The trend group of pixels The crypt probability of a trend point.

[0101] In the formula, exp() represents an exponential function with a natural constant as the base; || represents the absolute value symbol.

[0102] in, The larger the i The closer a pixel is to the center of the villi, the more likely it is a pixel in the villi area; The smaller the i The closer a pixel is to the crypt center, the more likely it is a pixel in the crypt area.

[0103] Furthermore, since the crypt probability of pixels close to the crypt center is relatively similar, To compare i The crypt probability approximation of a pixel point and each trend point in its trend group. The smaller the value, the more likely the pixel point is to be a crypt pixel point. The larger the value, the iThe more pixels there are, the more likely they are crypt pixels.

[0104] In a method for identifying crypt branches of inflammatory bowel disease of the present invention, the step of constructing a trend group of each pixel point according to the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixel points around each pixel point specifically includes:

[0105] Record each pixel point as the first trend point, and perform a search with the first trend point as the starting point;

[0106] Within the eight neighborhoods of each pixel point, the pixel point with the smallest crypt possibility difference with the first trend point is determined as the second trend point;

[0107] Similarly, the pixel point with the smallest difference in crypt possibility between the second trend point and the eight-neighborhood region is determined as the next trend point, and the search is stopped when the next trend point is not a pixel point within a preset range centered on each pixel point, or when there is no pixel point with a smaller crypt possibility than the previous trend point among the pixel points within the preset range centered on each pixel point;

[0108] The trend points obtained by searching and within a preset range centered on each pixel point are constructed as a trend group for each pixel point.

[0109] In order to obtain the trend group of each pixel, firstly calculate the current i The search starts with a pixel point as the first trend point.

[0110] For the first trend point, the pixel points whose crypt possibility in its eight neighborhoods is less than the crypt possibility of the first trend point are recorded as the neighboring points of the first trend point; the difference between the crypt possibility of the first trend point and all its neighboring points is calculated respectively, and the neighboring point with the smallest difference in crypt possibility is determined as the second trend point.

[0111] In the same way, taking the second trend point as the center, the neighboring points to which it belongs are determined from its eight neighborhoods, and then the next trend point, that is, the third trend point, is determined from the neighboring points according to the crypt possibility difference.

[0112] The search is stopped by analogy until the next trend point obtained by the search is not a pixel point within the preset range centered on the first trend point, or there is no pixel point within the preset range centered on the first trend point that has a smaller crypt probability than the previous trend point.

[0113] Optionally, the preset range can be determined according to the size of the pathology image. In this embodiment, the preset range is set in the same manner as the preset window described above, that is, a 5×5 window centered on the first trend point.

[0114] At this time, for the currently calculated i Pixel points are selected and all trend points found within the preset range are sequentially grouped into trend groups.

[0115] In a method for identifying crypt branches of inflammatory bowel disease of the present invention, after adjusting the gray value of each pixel based on the crypt degree of each pixel, before the step of identifying the crypt branches, the method further includes:

[0116] After normalizing the crypt degree of each pixel, multiply it by the gray value of each pixel and round the result upward;

[0117] The rounded result is used to update the grayscale value of each pixel.

[0118] It should be noted that it is known that the grayscale value of the pixel in the crypt area is large and the crypt degree is large, so after the grayscale value of the pixel is adjusted by multiplying the grayscale value of the pixel with the crypt degree, the grayscale value decreases less; while the grayscale of the pixels in the villus area is uneven and the grayscale value is small, and the crypt degree is small, so after the grayscale value of the pixel is adjusted by multiplying the grayscale value of the pixel with the crypt degree, the grayscale value decreases more, thereby enhancing the contrast between the crypt pixels and the pixels at other positions, and then using the Otsu threshold method for threshold segmentation to obtain the precise crypt area, and finally identifying the crypt branch according to the crypt area.

[0119] In a feasible implementation, the crypt degrees of all pixels in the intestinal crypt grayscale image are normalized and recorded as the normalized crypt degree of each pixel. The product of the normalized crypt degree of each pixel and the grayscale value of each pixel is rounded up and used as the updated grayscale value of each pixel. After the grayscale value of each pixel in the original grayscale image is updated, an adjusted image is obtained, and the adjusted image is segmented using the Otsu threshold method to identify the crypt area in the intestinal crypt grayscale image.

[0120] The crypt region in the grayscale image of the intestinal crypt is input into the trained neural network to obtain the branch region in the crypt region in the grayscale image of the intestinal crypt; the neural network used in this embodiment is YOLOv3, and the method for obtaining the data set for training the neural network is:

[0121] The crypt areas in the intestinal crypt grayscale image are collected, and the branch areas are artificially marked in the crypt areas in each intestinal crypt grayscale image using a bounding box, and the marking result is recorded as the label of the crypt area in the intestinal crypt grayscale image; a large number of crypt areas in the intestinal crypt grayscale images and their corresponding labels are collected to form a data set; the neural network is trained using the data set, and the loss function used in the training process is a cross loss function; the specific training process is a well-known content of the neural network, and the specific training process is not repeated in this embodiment.

[0122] The following is a description of a device for identifying inflammatory bowel disease crypt branches provided by the present invention. The device for identifying inflammatory bowel disease crypt branches described below and the method for identifying inflammatory bowel disease crypt branches described above can refer to each other.

[0123] like Figure 2 As shown, a device for identifying crypt branches of inflammatory bowel disease includes a first determination module 201, a second determination module 202 and an adjustment identification module 203:

[0124] A first determination module 201 is used to determine the crypt possibility of each pixel point according to the grayscale value of each pixel point in the intestinal crypt grayscale image and the grayscale value change trend of multiple pixels points in a preset neighborhood of each pixel point;

[0125] The intestinal pathological image is gray-scaled to obtain a gray-scale image of the intestinal crypt. The endoscopic examination is performed under anesthesia or mild sedation. The endoscope is inserted through the anus until it reaches the intestinal segment to be examined. If an abnormal intestinal mucosal area is found through the endoscope, a small piece of tissue sample is removed through the endoscope using a biopsy forceps. After the tissue sample is obtained, it will be sent to the pathology laboratory and observed under a microscope to obtain the pathological image of the mucosal lesions of inflammatory bowel disease.

[0126] Since the crypt is a tubular gland formed by the intestinal epithelium sinking into the lamina propria at the root of the villi and opening between adjacent villi, the identification of the crypt area in the pathological image mainly lies in distinguishing the crypt area from the villus area.

[0127] Furthermore, in the grayscale image of the intestinal crypt, the grayscale value of the pixel points in the crypt area is generally larger than the grayscale value of the pixel points in the villus area. At the same time, due to the presence of Paneth cells at the bottom of the crypt, the grayscale value of the pixel points in the crypt area gradually increases from the edge of the crypt to the center of the crypt.

[0128] In the fluff area of ​​the grayscale image, since the fluff is thicker in the middle and thinner on both sides, in the original grayscale image that has not undergone edge enhancement processing, the pixel points located at the center of the fluff are darker in color, and the pixel points close to the edge of the fluff are lighter in color. Therefore, the grayscale value of the pixel points in the direction from the center of the fluff area to the edge of the fluff area gradually increases.

[0129] In summary, it can be understood that the pixel values ​​of the entire pixel points show a gradually increasing trend from the center of the villus region to the center of the crypt region, and the increase amplitude gradually decreases.

[0130] When the grayscale value difference between each pixel and its corresponding neighboring pixels is large, it means that the pixel is more likely to be a pixel in the villus area. When the grayscale value difference between each pixel and its corresponding neighboring pixels is small, it means that the pixel is more likely to be a pixel in the crypt area. Therefore, the crypt possibility of each pixel is obtained by combining the grayscale value of each pixel and the grayscale value difference between each pixel and its corresponding neighboring pixels.

[0131] On this basis, the crypt possibility of each pixel can be determined according to the grayscale value of each pixel in the intestinal crypt grayscale image and the grayscale value change trend of multiple pixels in the preset neighborhood of each pixel.

[0132] The crypt possibility of each pixel represents the possibility that each pixel is a pixel in the crypt region. The higher the crypt possibility, the more likely the corresponding pixel is to be a pixel in the crypt region.

[0133] The grayscale value variation trend of multiple pixels in the preset neighborhood of each pixel represents the grayscale value variation trend of the pixels around each pixel. Optionally, the range of the preset neighborhood can be determined according to the size of the grayscale image.

[0134] A second determination module 202 is used to determine the crypt degree of each pixel point according to the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixels around each pixel point;

[0135] Furthermore, since the crypt possibility of pixels closer to the center of the crypt area is greater than that of pixels at the edge of the crypt area, the accuracy of judging whether a pixel belongs to a crypt based only on the crypt possibility of each pixel is low.

[0136] Since the crypt possibilities of the pixels in the crypt area are generally similar to those of the surrounding pixels, on the basis of obtaining the crypt possibility of each pixel, the crypt degree of each pixel can be further determined based on the change trend of the crypt possibilities of multiple pixels around each pixel. The higher the crypt degree, the more likely the corresponding pixel is to be a pixel in the crypt area.

[0137] The adjustment and identification module 203 is used to identify crypt branches after adjusting the gray value of each pixel based on the crypt degree of each pixel.

[0138] The gray value of each pixel is adjusted using the crypt degree of each pixel, so as to highlight the crypt area in the gray image, and thus, based on the existing detection technology, the crypt area with deformation such as branching can be better identified.

[0139] Optionally, the grayscale value of each pixel is weighted using the crypt degree, thereby adjusting the grayscale value of each pixel.

[0140] The present invention obtains the crypt possibility of each pixel being a pixel in the crypt area through the grayscale value of each pixel itself and the grayscale value change trend of multiple pixels around the pixel, and further obtains the crypt degree of each pixel according to the crypt possibility change trend of multiple pixels around each pixel, which is used to adjust the grayscale value of each pixel, thereby highlighting the crypt area in the image and obtaining a more accurate crypt branch recognition result.

[0141] Figure 3 An example of a physical structure diagram of an electronic device is shown in FIG. Figure 3 As shown, the electronic device may include: a processor 310, a communication interface 320, a memory 330 and a communication bus 340, wherein the processor 310, the communication interface 320 and the memory 330 communicate with each other through the communication bus 340. The processor 310 may call the logic instructions in the memory 330 to execute a method for identifying crypt branches of inflammatory bowel disease, the method comprising: determining the crypt possibility of each pixel according to the gray value of each pixel in the intestinal crypt gray image and the gray value change trend of multiple pixels in the preset neighborhood of each pixel; determining the crypt degree of each pixel according to the crypt possibility of each pixel and the crypt possibility change trend of multiple pixels around each pixel; and identifying the crypt branch after adjusting the gray value of each pixel based on the crypt degree of each pixel.

[0142] In addition, the logic instructions in the above-mentioned memory 330 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc. Various media that can store program codes.

[0143] On the other hand, the present invention also provides a computer program product, which includes a computer program, and the computer program can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer can execute a method for identifying crypt branches of inflammatory bowel disease provided by the above-mentioned methods, the method including: determining the crypt possibility of each pixel point based on the grayscale value of each pixel point in the intestinal crypt grayscale image and the grayscale value change trend of multiple pixels in a preset neighborhood of each pixel point; determining the crypt degree of each pixel point based on the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixels around each pixel point; and identifying the crypt branch after adjusting the grayscale value of each pixel point based on the crypt degree of each pixel point.

[0144] On the other hand, the present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, is implemented to execute a method for identifying crypt branches of inflammatory bowel disease provided by the above-mentioned methods, the method comprising: determining the crypt possibility of each pixel point based on the grayscale value of each pixel point in the intestinal crypt grayscale image and the grayscale value change trend of multiple pixels points in a preset neighborhood of each pixel point; determining the crypt degree of each pixel point based on the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixels points around each pixel point; and identifying the crypt branch after adjusting the grayscale value of each pixel point based on the crypt degree of each pixel point.

[0145] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.

[0146] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.

[0147] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. 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. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for identifying crypt branches in inflammatory bowel disease, characterized in that: include: Determine the crypt possibility of each pixel point according to the grayscale value of each pixel point in the intestinal crypt grayscale image and the grayscale value change trend of multiple pixels points in a preset neighborhood of each pixel point; Determining the crypt degree of each pixel point according to the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixel points around each pixel point; After adjusting the grayscale value of each pixel based on the crypt degree of each pixel, identifying the crypt branch; The step of determining the crypt possibility of each pixel point according to the grayscale value of each pixel point in the intestinal crypt grayscale image and the grayscale value change trend of multiple pixels points in the preset neighborhood of each pixel point specifically includes: Calculating the crypt feature value of each pixel point according to the gray value of each pixel point and the gray average value of multiple pixels in a preset neighborhood of each pixel point; Determine the crypt possibility of each pixel point according to the crypt feature quantity of each pixel point and the gray value change trend of multiple pixels in a preset window of each pixel point; The step of determining the crypt possibility of each pixel point according to the crypt feature quantity of each pixel point and the gray value change trend of multiple pixels in the preset window of each pixel point specifically includes: Determining the type of the crypt feature quantity of each pixel point according to the values ​​of the crypt feature quantities of multiple pixels in the preset window of each pixel point; Sorting the values ​​of the crypt feature type of each pixel point in ascending order to obtain a crypt feature type sequence of each pixel point; The number of crypt feature quantity types of each pixel point is used as the number of rows and columns of the feature matrix of each pixel point to define the feature matrix of each pixel point; According to the crypt feature type sequence of each pixel in the preset window of each pixel, all the pixels in the preset window of each pixel are filled into the feature matrix of each pixel; The crypt possibility of each pixel is determined according to the feature matrix of each pixel.

2. The method for identifying crypt branches in inflammatory bowel disease according to claim 1, characterized in that: The step of determining the crypt degree of each pixel point according to the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixels around each pixel point specifically includes: Constructing a trend group for each pixel point according to the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixels around each pixel point; Determine the crypt degree of each pixel point according to the trend group of each pixel point for: ; In the formula, Representative i The number of trend points in a trend group of pixels; Representative i Crypt probability of each pixel; Representative i The trend group of pixels The crypt probability of a trend point.

3. The method for identifying crypt branches in inflammatory bowel disease according to claim 2, characterized in that: The step of constructing a trend group for each pixel point according to the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixels around each pixel point specifically includes: Record each pixel point as the first trend point, and perform a search with the first trend point as the starting point; Within the eight neighborhoods of each pixel point, the pixel point with the smallest crypt possibility difference with the first trend point is determined as the second trend point; Similarly, the pixel point with the smallest difference in crypt possibility between the second trend point and the eight-neighborhood region is determined as the next trend point, and the search is stopped when the next trend point is not a pixel point within a preset range centered on each pixel point, or when there is no pixel point with a smaller crypt possibility than the previous trend point among the pixel points within the preset range centered on each pixel point; The trend points obtained by searching and within a preset range centered on each pixel point are constructed as a trend group for each pixel point.

4. The method for identifying crypt branches in inflammatory bowel disease according to claim 1, characterized in that: After adjusting the grayscale value of each pixel based on the crypt degree of each pixel and before identifying the crypt branch, the step further includes: After normalizing the crypt degree of each pixel, multiply it by the gray value of each pixel and round the result upward; The rounded result is used to update the grayscale value of each pixel.

5. A device for identifying crypt branches in inflammatory bowel disease, characterized in that: include: A first determination module is used to determine the crypt possibility of each pixel point according to the grayscale value of each pixel point in the intestinal crypt grayscale image and the grayscale value change trend of multiple pixels points in a preset neighborhood of each pixel point; A second determination module is used to determine the crypt degree of each pixel point according to the crypt possibility of each pixel point and the crypt possibility change trend of multiple pixels around each pixel point; an adjustment and identification module, configured to identify crypt branches after adjusting the grayscale value of each pixel based on the crypt degree of each pixel; The first determining module is specifically used for: Calculating the crypt feature value of each pixel point according to the gray value of each pixel point and the gray average value of multiple pixels in a preset neighborhood of each pixel point; Determine the crypt possibility of each pixel point according to the crypt feature quantity of each pixel point and the gray value change trend of multiple pixels in a preset window of each pixel point; The first determining module is specifically used for: Determining the type of the crypt feature quantity of each pixel point according to the values ​​of the crypt feature quantities of multiple pixels in the preset window of each pixel point; Sorting the values ​​of the crypt feature type of each pixel point in ascending order to obtain a crypt feature type sequence of each pixel point; The number of crypt feature quantity types of each pixel point is used as the number of rows and columns of the feature matrix of each pixel point to define the feature matrix of each pixel point; According to the crypt feature type sequence of each pixel in the preset window of each pixel, all the pixels in the preset window of each pixel are filled into the feature matrix of each pixel; The crypt possibility of each pixel is determined according to the feature matrix of each pixel.

6. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the method for identifying crypt branches in inflammatory bowel disease as claimed in any one of claims 1 to 4 is implemented.

7. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method for identifying crypt branches in inflammatory bowel disease according to any one of claims 1 to 4 is implemented.

8. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the method for identifying crypt branches in inflammatory bowel disease according to any one of claims 1 to 4 is implemented.

Citation Information

Patent Citations

  • Method and device for diagnosing inflammatory bowel disease based on pathological morphological characteristics

    CN118762267A