CN-122023805-A - Intelligent segmentation method for erosive gastritis based on digestive endoscopes
Abstract
The invention relates to the technical field of focus identification, in particular to an intelligent segmentation method for erosive gastritis based on a digestive endoscope. The method comprises the steps of obtaining an original optical flow field and a mucous membrane displacement field, carrying out reverse reconstruction on a mucous membrane substance characteristic diagram at the previous moment based on the original optical flow field, obtaining luminosity consistency residual errors according to the numerical value difference of the mucous membrane substance characteristic diagram and the same pixel in the obtained reconstruction diagram, determining local deformation gradient values of an endoscope image based on the mucous membrane displacement field, obtaining topological anomaly indexes according to the deviation degree of the local deformation gradient values of each pixel relative to a preset neighborhood range, determining a tissue credibility weight diagram according to the luminosity consistency residual errors and the topological anomaly indexes, and correcting deep features extracted by a neural network to obtain focus areas. The invention analyzes the optical artifacts from the two continuous principles of the optical flow coincidence and biological tissues, effectively distinguishes the optical artifacts similar to the focus vision and improves the segmentation effect of the gastritis focus.
Inventors
- CHEN XIAOJUAN
Assignees
- 温州市人民医院
Dates
- Publication Date
- 20260512
- Application Date
- 20260203
Claims (10)
- 1. An intelligent segmentation method for erosive gastritis based on a digestive endoscope is characterized by comprising the following steps: Obtaining an endoscopic image at each moment in the digestive endoscopy process in real time, and extracting a mucous membrane substance characteristic diagram at the corresponding moment; optical flow tracking is carried out on the endoscope images at adjacent moments, and an original optical flow field and a mucous membrane displacement field at each moment are obtained according to the pixel displacement of each moment relative to the endoscope images at the adjacent previous moment; reversely reconstructing a mucous membrane substance characteristic diagram at the previous moment based on the original optical flow field, and acquiring a luminosity consistency residual error of each pixel in an endoscopic image at each moment according to the numerical difference between the mucous membrane substance characteristic diagram at each moment and the same pixel in the obtained reconstructed diagram; determining local deformation gradient values of pixels in the endoscope image at each moment based on the mucosa displacement field, and acquiring topological anomaly indexes of each pixel in the endoscope image at each moment according to the deviation degree of the local deformation gradient values of each pixel relative to a preset neighborhood range; And determining a tissue credibility weight map at each moment according to the luminosity consistency residual error and the topological anomaly index, and correcting deep features extracted by the neural network by using the tissue credibility weight map to obtain focus areas in the endoscopic images at each moment.
- 2. The intelligent segmentation method for erosive gastritis based on digestive endoscopy according to claim 1, wherein the extracting of the mucosa substance characteristic diagram at the corresponding moment comprises: Judging whether the maximum value of the intensity values of three color channels of each pixel is larger than a preset saturation threshold value or not for each pixel in the endoscopic image at each moment, if so, marking the pixel as a saturation point, and if not, marking the pixel as a non-saturation point; Carrying out logarithmic difference processing on the intensity values of the R channel and the G channel of each unsaturated point to obtain an original hemoglobin response value, and taking the average value of the original hemoglobin response values of all unsaturated points in a preset smooth range of each saturated point as the original hemoglobin response value of the corresponding saturated point; And constructing a mucous membrane substance characteristic map at the corresponding moment according to the standard hemoglobin response values of all pixels in the endoscopic image at each moment.
- 3. The intelligent segmentation method for erosive gastritis based on a digestive endoscope according to claim 2, wherein the acquisition method for the original optical flow field comprises the following steps: The direction of each pixel in the endoscope image at each moment, which points to the matched pixel determined by optical flow tracking in the endoscope image at the adjacent previous moment, is taken as the direction of an optical flow displacement vector, and the distance between the two corresponding pixels is taken as the size of the optical flow displacement vector; and constructing an original optical flow field by the optical flow displacement vectors of all pixels in the endoscopic image at each moment.
- 4. The intelligent segmentation method for erosive gastritis based on digestive endoscopy according to claim 3, wherein the method for acquiring the mucosa displacement field comprises the following steps: Selecting a plurality of pixels from an original optical flow field at each moment to be marked as sampling control points, and fitting by using a random sampling coincidence algorithm based on optical flow displacement vectors of the sampling control points to obtain a motion homography matrix; Determining an endoscope motion vector of each pixel in the endoscope image at each moment by utilizing the motion homography matrix; acquiring a difference vector of the optical flow displacement vector and the endoscope operation vector of the same pixel as a mucosa relative displacement vector; and constructing a mucous membrane displacement field by using the mucous membrane relative displacement vectors of all pixels in the endoscopic image at each moment.
- 5. The intelligent segmentation method for erosive gastritis based on digestive endoscopy according to claim 4, wherein determining the endoscope motion vector of each pixel in the endoscope image at each moment comprises: coordinates of each pixel in the endoscopic image for each instant Based on the motion homography matrix, calculating a theoretical coordinate corresponding to the pixel in the endoscope image adjacent to the previous moment ; Calculating the theoretical coordinates of each pixel And coordinates of Obtain the endoscope motion vector of the pixel Wherein the theoretical coordinates The method is obtained through the following homogeneous coordinate transformation and normalization processes: , , Wherein, the method comprises the steps of, Representing the motion homography matrix for each moment; representing the homogeneous coordinate normalization factor.
- 6. The intelligent segmentation method for erosive gastritis based on digestive endoscopy according to claim 3, wherein the acquiring the photometric consistency residual error of each pixel in the endoscopic image at each moment comprises: Optionally, marking one moment as an example moment, marking one pixel as an example pixel from an endoscope image at the example moment, calculating coordinates of the example pixel in the endoscope image at the example moment, and adding the optical flow displacement vector to obtain tracing coordinates of the example pixel in the endoscope image at the moment adjacent to the previous moment at the example moment; Using bilinear interpolation to take the standard hemoglobin response value at the traceable coordinates in the mucosa substance characteristic graph at the adjacent previous moment of the example moment as the deduced hemoglobin characteristic value of the example pixel; And calculating an absolute difference value between the standard hemoglobin response value and the deduced hemoglobin characteristic value of the example pixel in the endoscopic image at the example moment to serve as a luminosity consistency residual error of the example pixel.
- 7. The intelligent segmentation method for erosive gastritis based on digestive endoscopy according to claim 4, wherein determining the local deformation gradient value of each pixel in the endoscope image at each moment comprises: Calculating the spatial partial derivative of the mucosa relative displacement vector of each pixel by using the center difference for each pixel in the endoscopic image at each moment, and constructing a local deformation gradient tensor of the pixel; and calculating a right cauchy-green deformation tensor corresponding to the local deformation gradient tensor, extracting a main eigenvalue of the deformation tensor, and taking the square root of the main eigenvalue as the local deformation gradient value of each pixel.
- 8. The intelligent segmentation method for erosive gastritis based on digestive endoscopy according to claim 1, wherein the obtaining of the topological anomaly index of each pixel in the endoscopic image at each moment comprises: And respectively calculating the average value and standard deviation of the local deformation gradient values of all pixels in the preset neighborhood range of each pixel in the endoscope image at each moment, taking the difference value between the local deformation gradient value of each pixel and the average value as a numerator, taking the sum value of the standard deviation and a preset positive number as a denominator to obtain a ratio, and selecting the maximum value of the ratio and a zero value as the topological abnormality index of the corresponding pixel.
- 9. The intelligent segmentation method for erosive gastritis based on digestive endoscopy according to claim 1, wherein the acquiring focus areas in the endoscopic image at each moment comprises: respectively carrying out standardization treatment on the luminosity consistency residual error and the topological anomaly index to sequentially obtain a standard residual value and a standard anomaly value; Selecting the maximum value of the standard residual value and the standard abnormal value, and taking the difference value of a constant 1 and the maximum value as the tissue credibility weight of each pixel in the endoscope image at each moment; Inputting the endoscopic image at each moment into a pre-trained U-Net network, and extracting a deep feature tensor through an encoder path of the U-Net network, wherein the deep feature tensor is positioned at a bottleneck layer where the encoder path is connected with a decoder path; Downsampling the tissue credible weight map to the same space size as the deep feature tensor, and performing element-by-element point multiplication on the downsampled tissue credible weight map and each feature channel of the deep feature tensor to obtain a corrected feature tensor; Inputting the corrected characteristic tensor into a decoder path of a U-Net network to obtain a focus segmentation probability map at each moment; And selecting a connected domain formed by pixel points with the numerical value larger than a preset segmentation judgment threshold from the focus segmentation probability map as a focus area at each moment.
- 10. The intelligent segmentation method for erosive gastritis based on digestive endoscopy according to claim 9, wherein the tissue credibility weighting map is downsampled to the same spatial dimension as the deep feature tensor by using an average pooling algorithm.
Description
Intelligent segmentation method for erosive gastritis based on digestive endoscopes Technical Field The invention relates to the technical field of focus identification, in particular to an intelligent segmentation method for erosive gastritis based on a digestive endoscope. Background Digestive endoscopy is a key means for diagnosing erosive gastritis and early gastric cancer. During the examination, the surface of the gastric mucosa is moist and irregular in morphology, obvious specular reflection is easily generated under the irradiation of an endoscope light source, and a highlight region such as a reflection point or a reflection band is formed in the image. Such optical artifacts are visually highly similar in color, brightness and local texture to typical focal features of erosive gastritis (e.g., punctiform erosion, white coating attachment or mucosal congestion), and present significant interference to visual recognition. The existing computer aided diagnosis method based on deep learning mainly adopts a convolutional neural network to analyze a single-frame endoscopic image, and relies on the convolutional neural network to learn visual characteristics such as color, texture and the like from a static image so as to identify a focus region. However, the method lacks the utilization of time sequence dynamic information and biological tissue physical properties, is difficult to effectively distinguish physical pathological changes attached to the surface of the mucous membrane from optical reflection artifacts only existing on the image layer, and is easy to misjudge the reflection artifacts as focuses, so that the segmentation result flickers along with the change of illumination angles, and the focus segmentation of erosive gastritis is inaccurate. Disclosure of Invention In order to solve the technical problem that the focus segmentation of erosive gastritis is inaccurate due to the fact that optical artifacts similar to focus vision cannot be effectively distinguished by a deep learning method of a single-frame static image, the invention aims to provide an intelligent segmentation method for erosive gastritis based on a digestive endoscope, and the adopted technical scheme is as follows: The embodiment of the invention provides an intelligent segmentation method for erosive gastritis based on a digestive endoscope, which comprises the following steps: Obtaining an endoscopic image at each moment in the digestive endoscopy process in real time, and extracting a mucous membrane substance characteristic diagram at the corresponding moment; optical flow tracking is carried out on the endoscope images at adjacent moments, and an original optical flow field and a mucous membrane displacement field at each moment are obtained according to the pixel displacement of each moment relative to the endoscope images at the adjacent previous moment; reversely reconstructing a mucous membrane substance characteristic diagram at the previous moment based on the original optical flow field, and acquiring a luminosity consistency residual error of each pixel in an endoscopic image at each moment according to the numerical difference between the mucous membrane substance characteristic diagram at each moment and the same pixel in the obtained reconstructed diagram; determining local deformation gradient values of pixels in the endoscope image at each moment based on the mucosa displacement field, and acquiring topological anomaly indexes of each pixel in the endoscope image at each moment according to the deviation degree of the local deformation gradient values of each pixel relative to a preset neighborhood range; And determining a tissue credibility weight map at each moment according to the luminosity consistency residual error and the topological anomaly index, and correcting deep features extracted by the neural network by using the tissue credibility weight map to obtain focus areas in the endoscopic images at each moment. Further, the extracting the mucosa substance characteristic diagram at the corresponding moment includes: Judging whether the maximum value of the intensity values of three color channels of each pixel is larger than a preset saturation threshold value or not for each pixel in the endoscopic image at each moment, if so, marking the pixel as a saturation point, and if not, marking the pixel as a non-saturation point; Carrying out logarithmic difference processing on the intensity values of the R channel and the G channel of each unsaturated point to obtain an original hemoglobin response value, and taking the average value of the original hemoglobin response values of all unsaturated points in a preset smooth range of each saturated point as the original hemoglobin response value of the corresponding saturated point; And constructing a mucous membrane substance characteristic map at the corresponding moment according to the standard hemoglobin response values of all pixels in the endoscopic