A glaucoma diagnosis method based on deep learning
Through deep learning-based methods, combined with fundus images and other examination data for glaucoma diagnosis, the problems of traditional diagnostic efficiency and insufficient accuracy are solved, and more efficient and reliable diagnostic results are achieved.
Patent Information
- Application Number
- CN202310805201.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-07-03
- Publication Date
- 2025-08-29
- Estimated Expiration
- 2043-07-03
AI Technical Summary
Traditional glaucoma diagnosis relies on a large number of professional instruments and doctors to analyze, and the diagnostic efficiency and accuracy are low, and the professional ability of doctors is high.
Using a deep learning-based method, the fundus image segmentation of the visual cup area of the eye disc and extracted key features through Model 1. Model 2 combines other examination data for glaucoma diagnosis, and uses neural network and big data analysis to output glaucoma diagnosis results.
It improves the efficiency and accuracy of glaucoma diagnosis, reduces the risk of missed detection and missed detection, and improves the credibility and reliability of the diagnosis.
Smart Images

Figure CN116681693B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a glaucoma diagnosis method based on deep learning. Background Art
[0002] Computer technology has been integrated into many industries, improving work efficiency and cost control. Numerous researchers are working on computer-assisted diagnosis of glaucoma, hoping to streamline the diagnostic process and transform some previously manual tasks into digital processes. This will not only facilitate both doctors and patients, but also reduce costs and increase efficiency, alleviating some pressure on medical resources. Traditional glaucoma diagnosis requires not only a large number of specialized instruments to examine the eyes, but also requires a qualified physician to analyze the examination reports to determine whether a patient has developed glaucomatous disease. Because glaucoma is a complex eye disease with a variety of causes, its diagnosis requires a high level of professional expertise from the physician. Computer-assisted diagnosis technology can, to a certain extent, transform the physician's diagnostic thinking into a digital process and incorporate the inherent advantages of computers, significantly improving diagnostic efficiency.
[0003] Currently, glaucoma is primarily diagnosed through intraocular pressure testing, visual field testing, and fundus examination. Doctors combine factors such as intraocular pressure, visual field defects, and the optic disc-to-cup ratio to make a diagnosis. There are certain patterns among glaucoma-prone populations: older patients and those with hypertension are more likely to develop glaucomatous lesions. These patterns have also been medically confirmed. Therefore, the present invention aims to combine these examination reports and patterns with neural networks and big data analysis to diagnose whether a patient has glaucoma. This invention not only addresses the shortage of specialized physicians but also improves diagnostic efficiency and accuracy to a certain extent. Summary of the Invention
[0004] The present invention aims to solve the problems existing in the above-mentioned prior art and provide a glaucoma diagnosis method based on deep learning.
[0005] The technical solutions adopted in the present invention are:
[0006] A deep learning-based glaucoma diagnosis method comprises the following steps:
[0007] Step 1): Establish Model 1 and Model 2, where:
[0008] The model 1 is used to analyze the fundus image and can output the optic disc and optic cup segmentation area in the fundus image. The model 1 includes a first convolution module, a downsampling module, a channel attention mechanism processing module, an upsampling module, a prediction map output module and a feature map output module;
[0009] The model 2 is used to analyze the data source and obtain the glaucoma diagnosis result. The model 2 includes a second convolution module, a residual module, and a prediction result output module;
[0010] Step 2): preprocessing the input original fundus image dataset to obtain image data that can be recognized and utilized by model 1;
[0011] Step 3): training model 1 so that model 1 can accurately segment the optic disc and optic cup regions based on the fundus image and output a key feature image showing the optic disc and optic cup segmentation;
[0012] Step 4): extract key feature images of model 1 in the process of processing fundus images as input parameters of model 2, and pre-process the image data to be input into model 2 and convert them into data in a unified format;
[0013] Step 5): After receiving the input data of Model 1, Model 2 is trained and then outputs a target result, which is: glaucoma or non-glaucoma.
[0014] Furthermore, in step 2), the input original fundus image is preprocessed, including image quality assessment of the input original fundus image, image averaging processing, image size adjustment and image format conversion, and finally image data with an image size of 512×512 and a Tensor format is obtained.
[0015] Furthermore, in Model 1,
[0016] Five first convolution modules and four downsampling modules are alternately connected to form the image coding area;
[0017] The image decoding area consists of 4 upsampling modules, 4 first convolution modules, a prediction map output module, and 4 channel attention mechanism processing modules;
[0018] The first convolution module includes a Conv2d convolution layer with a convolution kernel of 3 and a stride of 1, a BatchNorm2d, and a ReLU activation function. After receiving the recognizable fundus image data, the first convolution module first processes the image through a Conv2d convolution layer with a convolution kernel of 3 and a stride of 1, then performs BatchNorm2d batch normalization to ensure the stability of the model operation, and finally processes it through the ReLU activation function.
[0019] The downsampling module includes a pooling layer with a convolution kernel of 2 and a stride of 2;
[0020] The channel attention mechanism processing module adopts the SE Attention mechanism function;
[0021] The upsampling module uses an interpolation function to expand the eigenvalues of the original features of the fundus image to twice the original size, and the expanded eigenvalues are interpolated according to the Nearest principle;
[0022] The prediction map output module includes a Conv2d convolution layer with a convolution kernel of 1 and a stride of 1, as well as a Sigmoid activation function. The prediction map output module is used to generate an image of the prediction feature map;
[0023] After model 1 is trained to achieve the expected optic disc and optic cup segmentation effect, the feature map output module outputs the key feature image showing the optic disc and optic cup segmentation and is used by model 2.
[0024] Furthermore, in step 3), the training model 1 uses Dice Loss as the loss function, and the formula is:
[0025]
[0026] In the formula, A represents the set of images output by model 1 for each fundus image in the preprocessed fundus image dataset, and B represents the set of target images of samples corresponding to each fundus image in the preprocessed fundus image dataset. The standard stochastic gradient descent iterative optimization algorithm SGD is used as the optimization function for training model 1.
[0027] Furthermore, when training model 1, based on the preprocessed fundus image dataset, the four indicators of precision, recall, Dice coefficient, and intersection-over-union (IOU) were used to evaluate the fundus image segmentation effect of model 1. The formula is as follows:
[0028]
[0029]
[0030]
[0031]
[0032] Among them, TP represents the number of pixels in each fundus image that are correctly detected as positive samples; FP represents the number of pixels in each fundus image that are incorrectly detected as positive samples; FN represents the number of pixels in each fundus image that are incorrectly detected as negative samples; TN represents the number of pixels in each fundus image that are correctly detected as negative samples.
[0033] Furthermore, in step 4), the image data to be input into model 2 is preprocessed and converted into a two-dimensional array in a Tensor format of size 512.
[0034] Furthermore, in Model 2,
[0035] The second convolutional module includes a Conv2d convolutional layer with a convolution kernel of 3 and a stride of 1, a BatchNorm2d and a ReLU activation function;
[0036] The residual module is used to splice the output results of the second convolution module;
[0037] The prediction result output module includes a Conv2d convolution layer with a convolution kernel of 1 and a stride of 1 and a Sigmoid activation function. The prediction graph output module is used to output the glaucoma prediction results.
[0038] Furthermore, in step 5), the training model 2 uses BCE Loss as the loss function, and the formula is:
[0039] BCELoss=-w n [y n log x n +(1-y n )·log(1-x n )]
[0040] Among them, x n Represents the prediction result corresponding to the nth sample, y n Represents the target result corresponding to the nth sample, w n represents the constant coefficient.
[0041] Furthermore, when training Model 2, based on the preprocessed fundus image dataset, the accuracy of Model 2 for glaucoma diagnosis is evaluated according to the following formula:
[0042]
[0043] Among them, TP represents the number of samples in each sample that are correctly detected as positive samples; FP represents the number of samples in each sample that are incorrectly detected as positive samples.
[0044] Furthermore, the numerical data of fundus, blood pressure, age, and visual field loss in each fundus image are converted into feature maps, and the key feature images for optic disc and optic cup segmentation are obtained.
[0045] The present invention has the following beneficial effects:
[0046] Compared with traditional deep learning technology for diagnosing glaucoma, this invention avoids the uncertainty brought about by using a single type of data as the basis for diagnosis. The use of multiple examination data as the basis for diagnosis greatly improves the credibility and reliability of the diagnosis, and reduces the risk of false detection and missed detection in traditional diagnostic methods. BRIEF DESCRIPTION OF THE DRAWINGS
[0047] Figure 1 It is a schematic flow chart of the present invention.
[0048] Figure 2 It is a schematic diagram of the network structure in the design of the present invention. DETAILED DESCRIPTION
[0049] The present invention will be further described below with reference to the accompanying drawings.
[0050] like Figure 1 The present invention provides a glaucoma diagnosis method based on deep learning. The sample set is composed of fundus images and other related examination data, and the training is divided into two parts. Model 1 uses the fundus image as the input parameter to obtain the fundus optic disc and optic cup segmentation image and the key feature map based on the fundus image. Model 2 uses other related examination data and the data extracted from model 1 as input parameters. After model processing and analysis, the glaucoma diagnosis result of the sample is obtained.
[0051] like Figure 2 As shown, the glaucoma diagnosis method and system designed by the present invention based on deep learning include the following steps:
[0052] Model 1 is used to analyze fundus images and can output the optic disc and optic cup segmentation areas in fundus images. Model 1 includes the first convolution module, downsampling module, channel attention mechanism processing module, upsampling module, prediction map output module and feature map output module.
[0053] Model 2 is used to analyze the data source and obtain the glaucoma diagnosis results. Model 2 includes a second convolution module, a residual module, and a prediction result output module.
[0054] Step 1) The input original fundus image will be converted into model-usable data through image preprocessing. This process includes four parts: image quality assessment, image averaging, image size adjustment, and image format conversion.
[0055] Image quality assessment aims to eliminate images that do not meet the requirements. Image averaging reduces the model's computational cost. Image resizing and format conversion ensure that images are correctly loaded into the model. Inconsistent image size and format will cause the image to fail to be loaded into the model. Images are resized to 512×512. Image format conversion converts images to Tensor format.
[0056] In step 1), image quality is assessed during the image preprocessing phase. Images that do not meet image quality standards are discarded, and the user is prompted to re-enter the fundus image. Images that are too dark, too bright, obscured, contain impurities, or have incomplete optic discs are considered non-compliant. This step effectively prevents the adverse effects of substandard images on glaucoma diagnosis, ensuring the robustness of the present invention in glaucoma diagnosis.
[0057] Step 2): Preprocess the input original fundus image dataset and obtain image data that can be recognized and utilized by model 1.
[0058] Step 3): Train the model 1 so that the model 1 can accurately segment the optic disc and optic cup regions based on the fundus image and output a key feature image showing the optic disc and optic cup segmentation.
[0059] Step 4): Extract key feature images from the process of fundus image processing by model 1 as input parameters of model 2, and pre-process the image data to be input into model 2 and convert them into data in a unified format.
[0060] Step 5): After receiving the input data of Model 1, Model 2 is trained and then outputs a target result, which is: glaucoma or non-glaucoma.
[0061] In model 1, 5 first convolution modules and 4 downsampling modules are alternately connected to form the image coding area ( Figure 2 Area A in the
[0062] 4 upsampling modules, 4 first convolution modules, prediction map output module and 4 channel attention mechanism processing modules constitute the image decoding area ( Figure 2 Area B in the
[0063] The first convolution module includes a Conv2d convolution layer with a convolution kernel of 3 and a stride of 1, a BatchNorm2d, and a ReLU activation function. After receiving the recognizable fundus image data, the first convolution module first processes the image through a Conv2d convolution layer with a convolution kernel of 3 and a stride of 1, then performs BatchNorm2d batch normalization to ensure the stability of the model operation, and finally processes it through the ReLU activation function.
[0064] The downsampling module includes a pooling layer with a convolution kernel of 2 and a stride of 2;
[0065] The channel attention mechanism processing module adopts the SE Attention mechanism function;
[0066] The upsampling module uses an interpolation function to expand the eigenvalues of the original features of the fundus image to twice the original size, and the expanded eigenvalues are interpolated according to the Nearest principle;
[0067] The prediction map output module includes a Conv2d convolution layer with a convolution kernel of 1 and a stride of 1, as well as a Sigmoid activation function. The prediction map output module is used to generate an image of the prediction feature map;
[0068] After model 1 is trained to achieve the expected optic disc and optic cup segmentation effect, the feature map output module outputs the key feature image showing the optic disc and optic cup segmentation and is used by model 2.
[0069] In step 3), the training model 1 uses Dice Loss as the loss function, and the formula is:
[0070]
[0071] In the formula, A represents the set of images output by model 1 for each fundus image in the preprocessed fundus image dataset, and B represents the set of target images of samples corresponding to each fundus image in the preprocessed fundus image dataset. The standard stochastic gradient descent iterative optimization algorithm SGD is used as the optimization function for training model 1.
[0072] When training model 1, based on the preprocessed fundus image dataset, the four indicators of precision, recall, Dice coefficient, and intersection-over-union (IOU) were used to evaluate the fundus image segmentation effect of model 1. The formula is as follows:
[0073]
[0074]
[0075]
[0076]
[0077] Among them, TP represents the number of pixels in each fundus image that are correctly detected as positive samples; FP represents the number of pixels in each fundus image that are incorrectly detected as positive samples; FN represents the number of pixels in each fundus image that are incorrectly detected as negative samples; TN represents the number of pixels in each fundus image that are correctly detected as negative samples.
[0078] Preprocess the data to be input into Model 2 and convert it to a unified format. Convert the values for fundus, blood pressure, age, and visual field loss into a 512-bit two-dimensional array in Tensor format. Calculate the optic disc-to-cup ratio in the image predicted by Model 1 and convert it into a 512-bit two-dimensional array in Tensor format.
[0079] In model 2, the second convolution module includes a Conv2d convolution layer with a convolution kernel of 3 and a stride of 1, a BatchNorm2d and a ReLU activation function; the residual module ( Figure 2 The dotted arrow in the middle is the residual module) used to splice the output results of the second convolution module; the prediction result output module includes a Conv2d convolution layer with a convolution kernel of 1 and a step size of 1 and a Sigmoid activation function, and the prediction map output module is used to output the glaucoma prediction results.
[0080] In step 5), the training model 2 uses BCE Loss as the loss function, and the formula is:
[0081] BCELoss=-w n [y n log x n +(1-y n )·log(1-x n )]
[0082] Among them, x n represents the prediction result corresponding to the nth sample, yn represents the target result corresponding to the nth sample, and w n represents the constant coefficient.
[0083] When training model 2, based on the preprocessed fundus image dataset, the accuracy of model 2 for glaucoma diagnosis is evaluated according to the following formula:
[0084]
[0085] Among them, TP represents the number of samples in each sample that are correctly detected as positive samples; FP represents the number of samples in each sample that are incorrectly detected as positive samples.
[0086] The above description is only a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements can be made without departing from the principles of the present invention. These improvements should also be regarded as the scope of protection of the present invention.
Claims
1. A deep learning-based glaucoma diagnosis method, characterized by: The following steps are involved: Step 1): Establish Model 1 and Model 2, where: The model 1 is used to analyze the fundus image and can output the optic disc and optic cup segmentation area in the fundus image. The model 1 includes a first convolution module, a downsampling module, a channel attention mechanism processing module, an upsampling module, a prediction map output module and a feature map output module; The model 2 is used to analyze the data source and obtain the glaucoma diagnosis result. The model 2 includes a second convolution module, a residual module, and a prediction result output module; Step 2): Preprocess the input original fundus image dataset and obtain image data that can be recognized and utilized by model 1; Step 3): Train model 1 so that model 1 can accurately segment the optic disc and optic cup area based on the fundus image and output a key feature image showing the optic disc and optic cup segmentation; Step 4): Extract key feature images of model 1 in the process of processing fundus images as input parameters of model 2, and pre-process the image data to be input into model 2 and convert them into data in a unified format; Step 5): After receiving the input data from Model 1, Model 2 is trained and then outputs a target result, which is: glaucoma or non-glaucoma; In Model 1, the first convolutional module includes a Conv2d convolutional layer with a convolution kernel of 3 and a stride of 1, a BatchNorm2d layer, and a ReLU activation function. After receiving the recognizable fundus image data, the first convolutional module first processes the image through a Conv2d convolutional layer with a convolution kernel of 3 and a stride of 1, then performs BatchNorm2d batch normalization to ensure model stability, and finally processes the image through the ReLU activation function. The downsampling module includes a pooling layer with a convolution kernel of 2 and a stride of 2; The channel attention mechanism processing module adopts the SE Attention mechanism function; The upsampling module uses an interpolation function to expand the eigenvalues of the original features of the fundus image to twice the original size, and the expanded eigenvalues are interpolated according to the Nearest principle; The prediction map output module includes a Conv2d convolution layer with a convolution kernel of 1 and a stride of 1, as well as a Sigmoid activation function. The prediction map output module is used to generate an image of the prediction feature map; After model 1 is trained to achieve the expected optic disc and optic cup segmentation effect, the feature map output module outputs the key feature image showing the optic disc and optic cup segmentation and is used by model 2.
2. The deep learning-based glaucoma diagnosis method according to claim 1, wherein: In step 2), the input original fundus image is preprocessed, including image quality assessment, image averaging, image size adjustment, and image format conversion of the input original fundus image, and finally image data with an image size of 512×512 and a Tensor format is obtained.
3. The deep learning-based glaucoma diagnosis method according to claim 1, wherein: In step 3), the training model 1 uses Dice Loss as the loss function, and the formula is: , In the formula, A represents the set of images output by model 1 for each fundus image in the preprocessed fundus image dataset, and B represents the set of target images of samples corresponding to each fundus image in the preprocessed fundus image dataset. The standard stochastic gradient descent iterative optimization algorithm SGD is used as the optimization function for training model 1.
4. The deep learning-based glaucoma diagnosis method according to claim 3, wherein: When training model 1, based on the preprocessed fundus image dataset, the four indicators of precision, recall, Dice coefficient, and intersection-over-union (IOU) were used to evaluate the fundus image segmentation effect of model 1. The formula is as follows: , , , , Among them, TP represents the number of pixels in each fundus image that are correctly detected as positive samples; FP represents the number of pixels in each fundus image that are incorrectly detected as positive samples; FN represents the number of pixels in each fundus image that are incorrectly detected as negative samples; TN represents the number of pixels in each fundus image that are correctly detected as negative samples.
5. The deep learning-based glaucoma diagnosis method according to claim 1, wherein: In step 4), the image data to be input into model 2 is preprocessed and converted into a two-dimensional array in Tensor format of size 512.
6. The deep learning-based glaucoma diagnosis method according to claim 1, wherein: In Model 2, The second convolutional module includes a Conv2d convolutional layer with a convolution kernel of 3 and a stride of 1, a BatchNorm2d and a ReLU activation function; The residual module is used to splice the output results of the second convolution module; The prediction result output module includes a Conv2d convolution layer with a convolution kernel of 1 and a stride of 1 and a Sigmoid activation function. The prediction graph output module is used to output the glaucoma prediction results.
7. The deep learning-based glaucoma diagnosis method according to claim 1, wherein: In step 5), the training model 2 uses BCE Loss as the loss function, and the formula is: , in, Represents the prediction result corresponding to the nth sample, Represents the target result corresponding to the nth sample, represents the constant coefficient.
8. The deep learning-based glaucoma diagnosis method according to claim 7, wherein: When training model 2, based on the preprocessed fundus image dataset, the accuracy of model 2 for glaucoma diagnosis is evaluated according to the following formula: , Among them, TP represents the number of samples in each sample that are correctly detected as positive samples; FP represents the number of samples in each sample that are incorrectly detected as positive samples.
9. The deep learning-based glaucoma diagnosis method according to claim 1, wherein: The numerical data of fundus, blood pressure, age and visual field loss in each fundus image are converted into feature maps, and the key feature images for optic disc and optic cup segmentation are obtained.