Image processing method and apparatus, and electronic device and storage medium

By extracting and analyzing the multi-scale features of the fundus image, generating a target matrix, and using deep learning technology to identify fundus diseases, the problem of a single type of fundus disease screening and inaccurate results in the existing technology is solved, and the screening efficiency is improved.

WO2024216763A1PCT designated stage expired Publication Date: 2024-10-24BEIJING AIRDOC TECH CO LTD +1
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2023/106122
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-04-18
Filing Date
2023-07-06
Publication Date
2024-10-24

AI Technical Summary

Technical Problem

The types of fundus disease screening in the existing technology are single and the screening results are inaccurate, resulting in low efficiency.

Method used

By extracting multi-scale fundus features of the target fundus image, a target matrix is ​​generated, and the screening results are determined based on the matrix, and deep learning technology is used to identify multiple fundus disease categories.

Benefits of technology

It improves the accuracy and efficiency of fundus disease screening, can accurately identify multiple fundus disease categories, and solves the problems of single categories and inaccurate results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2023106122_24102024_PF_FP_ABST
    Figure CN2023106122_24102024_PF_FP_ABST
Patent Text Reader

Abstract

Disclosed in the embodiments of the present application are an image processing method and apparatus, and an electronic device and a storage medium. The method comprises: acquiring a target eye fundus image to be screened; extracting multi-scale eye fundus features of the target eye fundus image; generating a target matrix according to the multi-scale eye fundus features, wherein the target matrix includes N elements, each element corresponding to one disease classification category, different elements corresponding to different disease classification categories, and N being an integer greater than 2; and according to the target matrix, determining a target screening result corresponding to the target eye fundus image. In the embodiments of the present application, since lesion area information of an image can be fully acquired from multi-scale eye fundus features, which are extracted from a target eye fundus image, various disease categories can be accurately identified according to the extracted multi-scale eye fundus features, thereby improving the screening efficiency of eye fundus diseases.
Need to check novelty before this filing date? Find Prior Art

Description

Image processing method, device, electronic device and storage medium

[0001] CROSS-REFERENCE TO RELATED APPLICATIONS

[0002] This application claims priority to the Chinese patent application filed with the China Patent Office on April 18, 2023, with application number 202310416270.X and entitled “Image Processing Method, Device, Electronic Device and Storage Medium”, the entire contents of which are incorporated by reference into this application. Technical Field

[0003] The present application relates to the field of artificial intelligence technology, and in particular to an image processing method, device, electronic device and storage medium. Background Art

[0004] With the continuous development of artificial intelligence technology, its application scenarios are becoming increasingly broad. For example, it is being used to process fundus images for screening of fundus diseases. This can provide early warnings to users about the presence of fundus diseases and provide referral instructions, suggesting that users may have certain high-risk fundus diseases and need to visit a hospital for further, more detailed diagnosis. In related technologies, when screening for fundus diseases based on fundus images, the types of fundus diseases screened are relatively limited, and the accuracy of the screening results is low, resulting in relatively low screening efficiency for fundus diseases.

[0005] Summary of the Invention

[0006] The embodiments of the present application provide an image processing method, device, electronic device, and storage medium to solve the technical problem of relatively low screening efficiency for fundus diseases existing in the related art.

[0007] According to a first aspect of the present application, an image processing method is disclosed, the method comprising:

[0008] Acquire a target fundus image to be screened;

[0009] Extracting multi-scale fundus features of the target fundus image;

[0010] Generate a target matrix according to the multi-scale fundus features, wherein the target matrix includes N elements, each element corresponds to a disease classification category, different elements correspond to different disease classification categories, and N is an integer greater than 2;

[0011] According to the target matrix, a target screening result corresponding to the target fundus image is determined.

[0012] According to a second aspect of the present application, an image processing device is disclosed, the device comprising:

[0013] An acquisition module, used for acquiring a target fundus image to be screened;

[0014] An extraction module, configured to extract multi-scale fundus features of the target fundus image;

[0015] A generating module, configured to generate a target matrix based on the multi-scale fundus features, wherein the target matrix includes N elements, each element corresponds to a disease classification category, different elements correspond to different disease classification categories, and N is an integer greater than 2;

[0016] A determination module is used to determine a target screening result corresponding to the target fundus image according to the target matrix.

[0017] According to a third aspect of the present application, an electronic device is disclosed, comprising a memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement the image processing method in the first aspect.

[0018] According to a fourth aspect of the present application, a computer-readable storage medium is disclosed, on which a computer program / instruction is stored. When the computer program / instruction is executed by a processor, the image processing method in the first aspect is implemented.

[0019] According to a fifth aspect of the present application, a computer program product is disclosed, comprising a computer program / instruction, which implements the image processing method in the first aspect when executed by a processor.

[0020] In the embodiments of the present application, considering that the scales of the lesion areas of different fundus diseases vary, when a target fundus image needs to be screened for fundus diseases, multi-scale fundus features of the target fundus image can be extracted. Based on the multi-scale fundus features, the target fundus image is screened for fundus diseases to obtain a target screening result. Because the multi-scale fundus features extracted from the target fundus image can fully capture the lesion area information of the image, the extracted multi-scale fundus features can accurately identify multiple fundus disease categories. This can solve the problems of single fundus disease screening categories and inaccurate screening results in related technologies, thereby improving the efficiency of fundus disease screening. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] FIG1 is a flow chart of an image processing method provided by an embodiment of the present application;

[0022] FIG2 is an example diagram of a fundus image provided by an embodiment of the present application;

[0023] FIG3 is an example diagram of a network structure of a classification model provided in an embodiment of the present application;

[0024] FIG4 is a flow chart of a model training method provided in an embodiment of the present application;

[0025] FIG5 is a flowchart of a process for constructing a target loss function according to an embodiment of the present application;

[0026] FIG6 is a schematic structural diagram of an image processing device provided in an embodiment of the present application;

[0027] FIG7 is a structural block diagram of an electronic device provided in an embodiment of the present application. Specific embodiments

[0028] In order to make the above-mentioned purposes, features and advantages of the present application more obvious and easy to understand, the present application is further described in detail below with reference to the accompanying drawings and specific implementation methods.

[0029] It should be noted that for the method embodiments, for the sake of simplicity, they are all expressed as a series of action combinations, but those skilled in the art should be aware that the embodiments of the present application are not limited by the order of the actions described, because according to the embodiments of the present application, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions involved are not necessarily required by the embodiments of the present application.

[0030] In recent years, significant progress has been made in the research of AI-based technologies such as computer vision, deep learning, machine learning, image processing, and image recognition. Artificial Intelligence (AI) is an emerging science and technology that studies and develops theories, methods, technologies, and application systems for simulating and extending human intelligence. Artificial Intelligence is a comprehensive discipline that involves many technologies such as chips, big data, cloud computing, the Internet of Things, distributed storage, deep learning, machine learning, and neural networks. Computer vision, as an important branch of AI, specifically enables machines to recognize the world. Computer vision technologies generally include face recognition, liveness detection, fingerprint recognition and anti-counterfeiting verification, biometric recognition, face detection, pedestrian detection, target detection, pedestrian recognition, image processing, image recognition, image semantic understanding, image retrieval, text recognition, video processing, video content recognition, 3D reconstruction, virtual reality, augmented reality, map construction, computational photography, and robot navigation. With the research and advancement of artificial intelligence technology, this technology has been applied in many fields, such as security, urban management, traffic management, building management, park management, facial access, facial attendance, logistics management, warehouse management, robots, intelligent marketing, computational photography, mobile phone imaging, cloud services, smart homes, wearable devices, unmanned driving, autonomous driving, smart medical care, facial payment, facial unlocking, fingerprint unlocking, identity verification, smart screens, smart TVs, cameras, mobile Internet, live streaming, beauty, makeup, medical beauty, smart temperature measurement and other fields.

[0031] Embodiments of the present application provide an image processing method, apparatus, electronic device, and storage medium.

[0032] The following first introduces an image processing method provided in an embodiment of the present application.

[0033] It should be noted that the image processing method provided in the embodiment of the present application is applied to a processing device, which can be connected to a fundus camera, or the processing device can receive fundus images transmitted by other devices. In actual applications, the processing device can be a mobile terminal or a computer device, and the embodiment of the present application does not limit this.

[0034] FIG1 is a flow chart of an image processing method provided by an embodiment of the present application. As shown in FIG1 , the method may include the following steps: step 101, step 102, step 103, and step 104;

[0035] In step 101 , a target fundus image to be screened is acquired.

[0036] In the embodiment of the present application, the fundus image usually includes the optic disc and fundus blood vessels, wherein the optic disc is a bright yellow oval tissue in the fundus image, and the fundus blood vessels are a dark red tree-like tissue in the fundus image. The fundus blood vessels are divided into veins and arteries. Fundus exudation usually appears yellow in the fundus image and has an irregular shape. Microaneurysm is a lesion with a smaller area in the fundus image, which is dot-shaped and has a color close to that of blood vessels. The macular area is a brown circular or oval tissue in the fundus image. Bleeding spots usually appear dark red in the fundus image, and the number and area of ​​​​the bleeding spots often reflect the severity of the fundus disease. Since the fundus image can carry the above information, fundus diseases can be screened through the fundus image.

[0037] In an embodiment of the present application, when a user needs to undergo fundus disease screening, an image of the user's fundus can be captured by a fundus camera to obtain a target fundus image of the user, wherein the target fundus image is used for screening of fundus diseases.

[0038] In an embodiment of the present application, a variety of fundus diseases can be identified through fundus images, such as diabetic retinopathy (DR), age-related macular degeneration (AMD), hypertensive retinopathy (HR) and retinal vein occlusion (RVO).

[0039] It should be noted that, for ease of understanding, the embodiments of this application mainly use diabetic retinopathy, age-related macular degeneration, hypertensive retinopathy and retinal vein occlusion as examples for illustration. In actual applications, the image processing method in the embodiments of this application can also be used for screening of other types of fundus diseases, and the embodiments of this application do not limit this.

[0040] In step 102 , multi-scale fundus features of the target fundus image are extracted.

[0041] In the embodiment of the present application, the multi-scale fundus feature is a feature obtained from multiple scales of the target fundus image and contains multi-scale information.

[0042] To facilitate understanding, the following example illustrates the necessity of extracting multi-scale fundus features.

[0043] As shown in Figure 2, fundus images of four fundus diseases are shown. Figure 21 is a fundus image of severe diabetic retinopathy. The key to this disease is identifying the exudative area in the local area 22 of 21. Exudative spots are a very small sign. Figure 23 is a fundus image of advanced age-related macular degeneration. The key to diagnosing age-related macular degeneration is identifying the degeneration of the macular area. The macular area is much larger than the exudative spots. Figure 24 is a fundus image of retinal vein occlusion. When the central vein is blocked, the entire eyeball has very obvious bleeding. Figure 25 is a fundus image of moderate hypertensive retinopathy. The above analysis shows that the scale of the lesion area between different fundus diseases is quite different, so it is necessary to extract multi-scale fundus features from the fundus images.

[0044] In an embodiment of the present application, fundus features may include at least one of the following: visual features (such as pixel values, texture, contrast, etc. of the image), and local features such as fundus hemorrhage, exudates and other biological damage related to retinal lesions or blood vessels.

[0045] In an embodiment of the present application, multi-scale fundus features of the target fundus image can be extracted based on the idea of ​​deep learning. Since deep learning is based on data-driven network training, that is, a feature extraction network is trained using a large number of true values. A large number of true values ​​have a strong ability to extract features of lesion areas of different scales. The feature extraction network is equivalent to having a large amount of prior knowledge, which can extract rich, comprehensive and accurate fundus features.

[0046] In some embodiments, a convolutional neural network based on deep learning can be used to extract multi-scale fundus features of the target fundus image. For example, the network structure of the convolutional neural network can adopt the Inception structure, which is one of the classic architectures of the convolutional neural network. By adopting convolution kernels of different scales (1×1, 3×3, 5×5, etc.), the diversity of features is enhanced, thereby improving network performance. Alternatively, other multi-scale feature extraction network structures can also be used, which is not limited in the embodiments of the present application.

[0047] In step 103, a target matrix is ​​generated based on the multi-scale fundus features, wherein the target matrix contains N elements, each element corresponds to a disease classification category, different elements correspond to different disease classification categories, and N is an integer greater than 2.

[0048] In the embodiment of the present application, the target matrix may be a one-dimensional vector of 1×N.

[0049] For example, the target matrix is ​​A, A=(P1,P2,P3,…,P N ), each P iCorresponding to a fundus disease classification category, different P i Corresponding to different fundus disease classification categories, 1≤i≤N.

[0050] In the embodiment of the present application, the disease classification categories may include: no fundus disease and fundus disease, wherein fundus disease may include at least one of the following: different fundus diseases and different severity of each fundus disease.

[0051] In the embodiment of the present application, different fundus diseases may include: diabetic retinopathy, age-related macular degeneration, hypertensive retinopathy and retinal vein occlusion.

[0052] Accordingly, disease classification categories may include: no fundus disease, diabetic retinopathy, age-related macular degeneration, hypertensive retinopathy, and retinal vein occlusion.

[0053] In the embodiments of the present application, the different degrees of severity of each fundus disease may include: mild diabetic retinopathy, moderate to severe diabetic retinopathy, proliferative diabetic retinopathy, early to middle-stage age-related macular degeneration, progressive age-related macular degeneration, mild hypertensive retinopathy, moderate to severe hypertensive retinopathy, and retinal vein occlusion.

[0054] Accordingly, the disease classification categories may include: no fundus disease, mild diabetic retinopathy, moderate to severe diabetic retinopathy, proliferative diabetic retinopathy, early to intermediate age-related macular degeneration, advanced age-related macular degeneration, mild hypertensive retinopathy, moderate to severe hypertensive retinopathy, and retinal vein occlusion.

[0055] In one example, N is 9 and the target matrix is ​​a 1×9 vector. In this case, the target matrix A = (P1, P2, P3, P4, P5, P6, P7, P8, P9), where each P i Corresponding to a fundus disease classification category, 1≤i≤9, P i is a probability value, P i The larger the value, the higher the probability of belonging to the corresponding fundus disease classification category. For example, P1 is the probability of no fundus disease, P2 is the probability of mild diabetic retinopathy, P3 is the probability of moderate to severe diabetic retinopathy, P4 is the probability of proliferative diabetic retinopathy, P5 is the probability of early to mid-stage age-related macular degeneration, P6 is the probability of advanced age-related macular degeneration, P7 is the probability of mild hypertensive retinopathy, P8 is the probability of moderate to severe hypertensive retinopathy, and P9 is the probability of retinal vein occlusion.

[0056] The above-disclosed 9 fundus disease classification categories are only examples. The embodiments of this application include but are not limited to the above 9 fundus disease classification categories. In actual applications, they can also be used for other types of fundus disease classification categories.

[0057] In an embodiment of the present application, a target matrix can be generated based on multi-scale fundus features based on the idea of ​​deep learning. Since deep learning is based on data-driven training of the network, that is, a classifier is trained using a large number of true values. A large number of true values ​​has a strong ability to classify different fundus diseases. The classifier is equivalent to having a large amount of prior knowledge, and a large amount of prior knowledge can generate accurate classification results.

[0058] In some embodiments, a target matrix may be fitted based on a deep learning convolutional neural network classifier. For example, the classifier network structure may adopt a Bayesian network, or other classifier network structures may be adopted, which is not limited in the present embodiment.

[0059] In step 104, a target screening result corresponding to the target fundus image is determined according to the target matrix.

[0060] In an embodiment of the present application, the target screening results may include: no fundus disease or fundus disease. When there is fundus disease, it may specifically include: the type of fundus disease and the severity of the fundus disease.

[0061] In some embodiments, the value of each element in the target matrix is ​​a probability value. In this case, the above step 104 may include the following steps: step 1041;

[0062] In step 1041 , the disease classification category corresponding to the target element with the largest probability value in the target matrix is ​​determined as the target screening result corresponding to the target fundus image.

[0063] In one example, continuing with the example in step 103, in the target matrix A = (P1, P2, P3, P4, P5, P6, P7, P8, P9), if the value of P9 is the largest, it is determined that the target screening result corresponding to the target fundus image is retinal vein occlusion.

[0064] As can be seen from the above embodiment, in this embodiment, considering that the scales of the lesion areas of different fundus diseases vary, when it is necessary to screen a target fundus image for a fundus disease, multi-scale fundus features of the target fundus image can be extracted. Based on the multi-scale fundus features, the target fundus image is screened for the disease to obtain a target screening result. Since the multi-scale fundus features extracted from the target fundus image can fully obtain the lesion area information of the image, the extracted multi-scale fundus features can accurately identify a variety of fundus disease categories. This can solve the problems of single fundus disease screening and inaccurate screening results existing in the related art, thereby improving the screening efficiency of fundus diseases.

[0065] In another embodiment provided in the present application, a classification model can be pre-trained based on a deep learning network. Through the classification model, multi-scale fundus features of the target fundus image can be extracted, and a target matrix can be generated based on the multi-scale fundus features; wherein the classification model is a model obtained by training a convolutional neural network based on deep learning.

[0066] In the embodiment of the present application, the input of the classification model is the target fundus image, and the output is the target matrix.

[0067] In one example, as shown in Figure 3, the network structure of the classification model may include: a feature extraction network 31 and a classifier 32, wherein the feature extraction network 31 is used to receive the target fundus image input into the classification model, extract the multi-scale fundus features of the target fundus image, and pass the multi-scale fundus features to the classifier 32; the classifier 32 is used to receive the multi-scale fundus features passed by the feature extraction network 31, and fit the target matrix based on the multi-scale fundus features.

[0068] The feature extraction network 31 may include multiple branches for extracting fundus features, such as a global field of view branch, a 1×1 field of view branch, a 3×3 field of view branch, and a 5×5 field of view branch. Different branches are used to extract features at different scales. For example, when both the 1×1 field of view branch and the 3×3 field of view branch are activated, it means that small areas have strong features, and therefore the image may be of the type of diabetic retinopathy. When the 1×1 field of view branch, the 3×3 field of view branch, and the 5×5 field of view branch are activated, it means that small and medium areas have strong features, and therefore the image may be of the type of age-related macular degeneration. When all four branches are activated, it means that small, medium, and large areas all have strong features, and therefore the image may be of the type of retinal vein occlusion.

[0069] The classifier 32 can fuse the fundus features extracted by the above four branches into multi-scale features, and then classify them to finally obtain the output result of the model, that is, the target matrix.

[0070] It should be noted that, for ease of understanding, the network structure of the feature extraction network is mainly illustrated in the embodiments of this application using global field of view branches, 1×1 field of view branches, 3×3 field of view branches, and 5×5 field of view branches as examples. In actual applications, field of view branches of other scales can also be added or replaced in the embodiments of this application, and the embodiments of this application do not limit this.

[0071] In some embodiments, during the training stage of the classification model, in order to reduce the amount of original data of the sample image, facilitate less calculation in subsequent processing, and improve the operation speed, the model training can be based on the grayscale image of the sample image. Therefore, during the use stage of the classification model, the target fundus image needs to be converted into a grayscale image first, and then the grayscale image is processed into the input classification model, which makes the processing speed faster and more efficient.

[0072] In some embodiments, since the deep learning-based classification model has certain requirements for the input data of the model, for example, requiring the size of the input image to be a specific size, before inputting into the classification model, if the size of the target fundus image is different from the above-mentioned specific size, the size of the target fundus image also needs to be adjusted to the above-mentioned specific size.

[0073] In some embodiments, the classification model can be a model trained using a lightweight network based on deep learning. Because lightweight networks consume fewer hardware and software resources and have shorter runtimes, they can reduce the runtime of the screening process while ensuring accurate disease screening results, thereby lowering image processing costs.

[0074] It can be seen that in the embodiment of the present application, a classification model is used to process the target fundus image. Since the classification model is a model obtained by network training based on deep learning, and deep learning is a model trained in a data-driven manner, that is, a large number of true values ​​are used to train an estimation model. A large number of true values ​​have a strong ability to extract fundus features. The estimation model is equivalent to having a large amount of prior knowledge. A large amount of prior knowledge can have a relatively accurate estimation and inference result for the input. Therefore, when it is necessary to screen the target fundus image for disease, the target fundus image is input into the classification model, and the target fundus image is processed by the classification model. According to the target matrix output by the model, the target fundus image is screened for disease, and multiple disease categories can be accurately identified, thereby solving the problems of single fundus disease screening and inaccurate screening results in related technologies, and improving the screening efficiency of fundus diseases.

[0075] FIG4 is a flow chart of a model training method provided in an embodiment of the present application. As shown in FIG4 , the method includes the following steps: step 401, step 402, and step 403;

[0076] In step 401, a training set is obtained, wherein the training set includes: multiple sample fundus images and a target label corresponding to each sample fundus image, the target label including: a first label for indicating whether the sample fundus image has a fundus disease, a second label for indicating the disease category when the sample fundus image has a fundus disease, and a third label for indicating the severity of the disease when the sample fundus image has a fundus disease.

[0077] In the embodiment of the present application, considering that the more sample data involved in model training, the better the effect of the target model obtained by training, the training set may include a large number of sample fundus images.

[0078] In some embodiments, to ensure the accuracy of the training samples, each sample fundus image and the corresponding target label in the training set may be a manually annotated data set.

[0079] In some embodiments, considering that the cost of manual labeling is relatively high when a large amount of sample data is required, sample data can be automatically generated to reduce costs.

[0080] In the embodiment of the present application, the auxiliary diagnosis task of fundus diseases based on fundus images involves classification tasks of multiple diseases at different granularity levels. Specifically, it can be divided into three levels of granularity: the first level of granularity is the overall view. The goal of the fundus image screening task is to determine whether the user needs "referral", where referral means that the user has a fundus disease and it is recommended that the user undergo further in-depth examination; the second level of granularity is the coarse-grained disease classification task, which divides users into several categories according to the type of disease. For example, users are divided into 5 categories: users who do not need referral, users referred for diabetic retinopathy, users referred for age-related macular degeneration, users referred for hypertensive retinopathy, and users referred for retinal vein occlusion; the third level of granularity is the fine-grained disease classification task, which divides users into several categories according to the severity of the disease. For example, users are divided into 9 categories: users who do not need referral, users with mild diabetic retinopathy, users with moderate to severe diabetic retinopathy, users with proliferative diabetic retinopathy, users with early and middle-stage age-related macular degeneration, users with progressive age-related macular degeneration, users with mild hypertensive retinopathy, users with moderate to severe hypertensive retinopathy, and users with retinal vein occlusion. The classification task of each level of granularity corresponds to a label, where the first level of granularity corresponds to the first label, the second level of granularity corresponds to the second label, and the third level of granularity corresponds to the third label.

[0081] It should be noted that, for ease of understanding, the embodiments of this application mainly use diabetic retinopathy, age-related macular degeneration, hypertensive retinopathy and retinal vein occlusion as examples for illustration. In actual applications, the model training method in the embodiments of this application can also be used to train models for screening other types of fundus diseases, and the embodiments of this application are not limited to this.

[0082] In step 402, a network to be trained and a target loss function are constructed.

[0083] In some embodiments, the network structure of the network to be trained may include: a feature extraction network and a classifier, wherein the feature extraction network is used to extract multi-scale fundus features of the fundus image, and the classifier is used to fit the output matrix based on the multi-scale fundus features.

[0084] In some embodiments, for the classification tasks at the three levels of granularity above, a multi-level loss function can be designed to train the classification model through the multi-level loss function. Accordingly, as shown in FIG5 , the above step 402 includes the following steps: step 4021, step 4022, step 4023, and step 4024;

[0085] In step 4021, a first loss function is determined based on the first label and the predicted category matrix, wherein the first loss function is used to represent the possibility of misdiagnosis of the disease.

[0086] In an embodiment of the present application, the first loss function is the optimization function of the first level mentioned above, targeting "whether to refer", that is, "whether there is fundus disease", wherein the first loss function can be a cross-entropy function of the model input true value and the model output predicted value based on the first level granularity. At this time, the input true value of the model is the first label.

[0087] In step 4022, a second loss function is determined based on the second label and the predicted category matrix, wherein the second loss function is used to represent the possibility of misjudging the disease category.

[0088] In an embodiment of the present application, the second loss function is an optimization function for the above-mentioned second level, for "disease type classification", wherein the second loss function can be a cross-entropy function of the model input true value and the model output predicted value based on the second level granularity. At this time, the input true value of the model is the second label.

[0089] In step 4023, a third loss function is determined based on the third label and the predicted category matrix, wherein the third loss function is used to represent the possibility of misdiagnosis of disease severity.

[0090] In an embodiment of the present application, the third loss function is an optimization function for the above-mentioned third level, for the "classification of disease type and severity", wherein the third loss function can be a cross-entropy function of the model input true value and the model output predicted value based on the third level granularity. At this time, the input true value of the model is the third label.

[0091] In practical applications, the above cross entropy functions can all use binary cross entropy.

[0092] In step 4024, a target loss function is determined based on the first loss function, the second loss function, and the third loss function.

[0093] In an embodiment of the present application, the target loss function is the sum of the first loss function, the second loss function, and the third loss function. Alternatively, the target loss function is the weighted sum of the first loss function, the second loss function, and the third loss function.

[0094] In this embodiment, each sample fundus image has three labels: the first label indicates whether the image requires referral; the second label indicates the disease associated with the image; and the third label indicates the severity of the disease. Three levels of loss functions address three potential misjudgments: the possibility of incorrect referral, incorrect disease type, and incorrect disease severity. By optimizing these multiple loss functions, the accuracy of the trained classification model can be improved.

[0095] In step 403, the network to be trained is iteratively trained multiple times based on the sample fundus images. During each iterative training process, the parameters in the network to be trained are back-propagated and updated according to the predicted category matrix, target label and target loss function output by the network to be trained. The above iterative process is repeated until the model converges to obtain a classification model.

[0096] In an embodiment of the present application, when training the model, the network to be trained can be trained multiple times iteratively. During each iterative training process, a portion of sample fundus images is selected and input into the network to be trained for processing to obtain a corresponding prediction category matrix. A loss value is calculated based on the prediction category matrix, the target label, and the target loss function. Based on the calculated loss value, the parameters of the network to be trained are updated by back propagation. The iterative training process is repeated multiple times until the network to be trained converges and a classification model is obtained.

[0097] It can be seen that in the embodiment of the present application, the deep learning-based network can be trained through massive training data to obtain a classification model for disease screening of fundus images. Since the classification model is a model obtained by network training based on deep learning, and deep learning is a model trained in a data-driven manner, that is, a large number of true values ​​are used to train an estimation model. A large number of true values ​​have a strong ability to extract fundus features. The estimation model is equivalent to having a large amount of prior knowledge. A large amount of prior knowledge can have a relatively accurate estimation and inference result for the input. Therefore, when it is necessary to screen the target fundus image for disease, the target fundus image is input into the classification model, and the target fundus image is processed by the classification model. According to the target matrix output by the model, the target fundus image is screened for disease, and multiple disease categories can be accurately identified, thereby solving the problems of single fundus disease screening types and inaccurate screening results in related technologies, and improving the screening efficiency of fundus diseases.

[0098] FIG6 is a schematic diagram of the structure of an image processing device provided in an embodiment of the present application. As shown in FIG6 , the image processing device 600 may include: an acquisition module 601, an extraction module 602, a generation module 603, and a determination module 604;

[0099] An acquisition module 601 is used to acquire a target fundus image to be screened;

[0100] An extraction module 602 is configured to extract multi-scale fundus features of the target fundus image;

[0101] A generating module 603 is configured to generate a target matrix based on the multi-scale fundus features, wherein the target matrix includes N elements, each element corresponds to a disease classification category, different elements correspond to different disease classification categories, and N is an integer greater than 2;

[0102] The determination module 604 is configured to determine the target screening result corresponding to the target fundus image according to the target matrix.

[0103] As can be seen from the above embodiment, in this embodiment, considering that the scales of the lesion areas of different fundus diseases vary, when it is necessary to screen a target fundus image for a fundus disease, multi-scale fundus features of the target fundus image can be extracted. Based on the multi-scale fundus features, the target fundus image is screened for the disease to obtain a target screening result. Since the multi-scale fundus features extracted from the target fundus image can fully obtain the lesion area information of the image, the extracted multi-scale fundus features can accurately identify a variety of fundus disease categories. This can solve the problems of single fundus disease screening and inaccurate screening results existing in the related art, thereby improving the screening efficiency of fundus diseases.

[0104] Optionally, as an embodiment, the disease classification categories may include: no fundus disease and fundus disease, and the fundus disease may include at least one of the following: different fundus diseases and different degrees of severity of each fundus disease.

[0105] Optionally, as an embodiment, the value of each element in the target matrix is ​​a probability value;

[0106] The determining module 604 may include:

[0107] The determination submodule is used to determine the disease classification category corresponding to the target element with the largest probability value in the target matrix as the target screening result corresponding to the target fundus image.

[0108] Optionally, as an embodiment, the extraction module 602 may include:

[0109] An extraction submodule, configured to extract multi-scale fundus features of the target fundus image through a classification model, wherein the classification model is a model obtained by training a convolutional neural network based on deep learning;

[0110] The generating module 603 may include:

[0111] A generation submodule is used to generate a target matrix according to the multi-scale fundus features using the classification model.

[0112] Optionally, as an embodiment, the classification model can be trained in the following manner:

[0113] Acquire a training set, wherein the training set includes: a plurality of sample fundus images and a target label corresponding to each of the sample fundus images, the target label including: a first label for indicating whether the sample fundus image has a fundus disease, a second label for indicating the disease category when the sample fundus image has a fundus disease, and a third label for indicating the severity of the disease when the sample fundus image has a fundus disease;

[0114] Construct the network to be trained and the target loss function;

[0115] Based on the sample fundus image, the network to be trained is trained multiple times iteratively. During each iterative training process, the parameters in the network to be trained are back-propagated and updated according to the predicted category matrix output by the network to be trained, the target label and the target loss function. The above iterative process is repeated until the model converges to obtain the classification model.

[0116] Optionally, as an embodiment, the target loss function can be constructed in the following manner:

[0117] Determining a first loss function based on the first label and the predicted category matrix, wherein the first loss function is used to represent the possibility of misdiagnosis of the disease;

[0118] Determining a second loss function based on the second label and the predicted category matrix, wherein the second loss function is used to represent the possibility of misclassification of the disease category;

[0119] Determining a third loss function based on the third label and the predicted category matrix, wherein the third loss function is used to represent the possibility of misdiagnosis of disease severity;

[0120] The target loss function is determined according to the first loss function, the second loss function and the third loss function.

[0121] Any step in the embodiment of the image processing method provided in the present application and the specific operation in any step can be completed by the corresponding module in the image processing device. The process of the corresponding operation completed by each module in the image processing device refers to the process of the corresponding operation described in the embodiment of the image processing method.

[0122] As for the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.

[0123] Figure 7 is a block diagram of an electronic device according to an embodiment of the present application. The electronic device includes a processing component 722, which further includes one or more processors, and memory resources represented by memory 732 for storing instructions executable by the processing component 722, such as applications. The applications stored in memory 732 may include one or more modules, each corresponding to a set of instructions. Furthermore, the processing component 722 is configured to execute the instructions to perform the above-described method.

[0124] The electronic device may further include a power supply component 726 configured to perform power management of the electronic device, a wired or wireless network interface 750 configured to connect the electronic device to a network, and an input / output (I / O) interface 758. The electronic device may operate based on an operating system stored in the memory 732, such as Windows Server™, MacOS X™, Unix™, Linux™, FreeBSD™, or the like.

[0125] According to another embodiment of the present application, the present application further provides a computer-readable storage medium having a computer program / instruction stored thereon, which, when executed by a processor, implements the steps in the image processing method described in any of the above embodiments.

[0126] According to another embodiment of the present application, the present application further provides a computer program product, including a computer program / instruction, which implements the steps of the image processing method described in any of the above embodiments when executed by a processor.

[0127] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.

[0128] Those skilled in the art will appreciate that the embodiments of the present application can be provided as methods, devices, or computer program products. Therefore, the present application can adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present application can adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0129] The present application embodiment is described with reference to the flow chart and / or block diagram of the method, terminal device (system), and computer program product according to the embodiment of the present application. It should be understood that each process and / or box in the flow chart and / or block diagram and the combination of the process and / or box in the flow chart and / or block diagram can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor or other programmable data processing terminal device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing terminal device produce a device for realizing the function specified in one process or multiple processes and / or one box or multiple boxes of the flow chart.

[0130] These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing terminal device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce a manufactured product including an instruction device that implements the functions specified in one or more processes in the flowchart and / or one or more boxes in the block diagram.

[0131] Although preferred embodiments of the present invention have been described, those skilled in the art may make additional changes and modifications to these embodiments once they become aware of the basic inventive concepts. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the embodiments of the present invention.

[0132] Finally, it should be noted that, in this document, relational terms such as first and second, etc., are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the terms "comprises," "comprising," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or terminal device that includes a series of elements includes not only those elements, but also other elements not explicitly listed, or elements inherent to such process, method, article, or terminal device. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of additional identical elements in the process, method, article, or terminal device that includes the element.

[0133] The above is a detailed introduction to the image processing method, device, electronic device and storage medium provided by the present application. Specific examples are used herein to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method of the present application and its core idea. At the same time, for those skilled in the art, according to the ideas of the present application, there may be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as a limitation on the present application.

Claims

1. An image processing method, wherein: The method comprises: Acquire a target fundus image to be screened; Extracting multi-scale fundus features of the target fundus image; Generate a target matrix according to the multi-scale fundus features, wherein the target matrix contains N elements, each of which corresponds to a disease classification category, different elements correspond to different disease classification categories, and N is an integer greater than 2; According to the target matrix, a target screening result corresponding to the target fundus image is determined.

2. The method according to claim 1, wherein: The disease classification categories include: no fundus disease and fundus disease, and the fundus disease includes at least one of the following: different fundus diseases and different severity of each fundus disease.

3. The method according to claim 1, wherein: The value of each element in the target matrix is ​​a probability value; Determining the target screening result corresponding to the target fundus image according to the target matrix includes: The disease classification category corresponding to the target element with the largest probability value in the target matrix is ​​determined as the target screening result corresponding to the target fundus image.

4. The method according to any one of claims 1 to 3, wherein: Extracting multi-scale fundus features of the target fundus image; According to the multi-scale fundus features, a target matrix is ​​generated, including: Extracting multi-scale fundus features of the target fundus image through a classification model, and generating a target matrix according to the multi-scale fundus features; Among them, the classification model is a model obtained by training a convolutional neural network based on deep learning.

5. The method according to claim 4, wherein: The classification model is trained in the following way: Acquire a training set, wherein the training set includes: a plurality of sample fundus images and a target label corresponding to each of the sample fundus images, the target label including: a first label for indicating whether the sample fundus image has a fundus disease, a second label for indicating the disease category when the sample fundus image has a fundus disease, and a third label for indicating the severity of the disease when the sample fundus image has a fundus disease; Construct the network to be trained and the target loss function; Based on the sample fundus image, the network to be trained is trained for multiple iterations. In each iteration training process, the parameters in the network to be trained are back-propagated and updated according to the predicted category matrix output by the network to be trained, the target label and the target loss function. The above iteration process is repeated until the model converges to obtain the classification model.

6. The method according to claim 5, wherein: The objective loss function is constructed in the following way: Determine a first loss function according to the first label and the predicted category matrix, wherein the first loss function is used to represent the possibility of misdiagnosis of the disease; Determine a second loss function according to the second label and the predicted category matrix, wherein the second loss function is used to represent the possibility of misjudgment of the disease category; Determining a third loss function according to the third label and the predicted category matrix, wherein the third loss function is used to represent the possibility of misdiagnosis of disease severity; The target loss function is determined according to the first loss function, the second loss function and the third loss function.

7. An image processing device, wherein: The device comprises: An acquisition module, used for acquiring a target fundus image to be screened; An extraction module, used for extracting multi-scale fundus features of the target fundus image; A generating module, used for generating a target matrix according to the multi-scale fundus features, wherein the target matrix contains N elements, each of which corresponds to a disease classification category, different elements correspond to different disease classification categories, and N is an integer greater than 2; A determination module is used to determine a target screening result corresponding to the target fundus image according to the target matrix.

8. The device according to claim 7, wherein: The disease classification categories include: no fundus disease and fundus disease, and the fundus disease includes at least one of the following: different fundus diseases and different severity of each fundus disease.

9. The device according to claim 7, wherein: The value of each element in the target matrix is ​​a probability value; The determination module comprises: A determination submodule is used to determine the disease classification category corresponding to the target element with the largest probability value in the target matrix as the target screening result corresponding to the target fundus image.

10. The device according to any one of claims 7 to 9, wherein: The extraction module comprises: An extraction submodule, used for extracting multi-scale fundus features of the target fundus image through a classification model, wherein the classification model is a model obtained by training a convolutional neural network based on deep learning; The generation module comprises: A generating submodule is used to generate a target matrix according to the multi-scale fundus features through the classification model.

11. The device according to claim 10, wherein: The classification model is trained in the following way: Acquire a training set, wherein the training set includes: a plurality of sample fundus images and a target label corresponding to each of the sample fundus images, the target label including: a first label for indicating whether the sample fundus image has a fundus disease, a second label for indicating the disease category when the sample fundus image has a fundus disease, and a third label for indicating the severity of the disease when the sample fundus image has a fundus disease; Construct the network to be trained and the target loss function; Based on the sample fundus image, the network to be trained is trained for multiple iterations. In each iteration training process, the parameters in the network to be trained are back-propagated and updated according to the predicted category matrix output by the network to be trained, the target label and the target loss function. The above iteration process is repeated until the model converges to obtain the classification model.

12. The device according to claim 11, wherein: The objective loss function is constructed in the following way: Determine a first loss function according to the first label and the predicted category matrix, wherein the first loss function is used to represent the possibility of misdiagnosis of the disease; Determine a second loss function according to the second label and the predicted category matrix, wherein the second loss function is used to represent the possibility of misjudgment of the disease category; Determining a third loss function according to the third label and the predicted category matrix, wherein the third loss function is used to represent the possibility of misdiagnosis of disease severity; The target loss function is determined according to the first loss function, the second loss function and the third loss function.

13. An electronic device comprising a memory, a processor, and a computer program stored in the memory, wherein: The processor executes the computer program to implement the image processing method according to any one of claims 1 to 6.

14. A computer-readable storage medium having a computer program / instruction stored thereon, wherein: When the computer program / instruction is executed by a processor, the image processing method according to any one of claims 1 to 6 is implemented.

15. A computer program product comprising a computer program / instructions, wherein: When the computer program / instruction is executed by a processor, the image processing method according to any one of claims 1 to 6 is implemented.

Citation Information

Patent Citations

  • Judgment method for simultaneously identifying stages and lesion features of diabetic retinopathy

    CN112869697A

  • Lung cancer pathological section image processing method and system based on multilevel discrimination

    CN113034443A

  • Image classification method, computer equipment and storage medium

    CN114724016A

  • Focus image classification and identification method based on fundus image

    CN114821189A

  • Crop disease identification method based on FCSA-OfficientNetV2

    CN114863278A