Image segmentation method, device, equipment and medium
By using the image segmentation method of codec and Transformer neural network structure in OCTA technology to extract vascular and avascular area information, combined with multi-scale and local feature extractors and boundary perception modules, the low accuracy of FAZ segmentation in OCTA technology is solved. problem, achieving higher segmentation accuracy.
Patent Information
- Application Number
- CN202411027240.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-30
- Publication Date
- 2024-10-18
- Estimated Expiration
- 2044-07-30
AI Technical Summary
In the existing optical coherence tomography angiography (OCTA) technology, the segmentation of the foveal avascular zone (FAZ) has shadows, noise and complex vascular structures, resulting in low segmentation accuracy.
A codec-based image segmentation method is adopted to extract blood vessel and avascular area information in OCTA images, and utilize multi-scale global feature extractor, multi-directional local feature extractor, attention module and boundary perception module, combined with Transformer neural The network structure accurately segments the foveal avascular area.
The segmentation accuracy of the foveal avascular area is improved. By limiting the boundaries of the foveal avascular area at the end of blood vessels, the accuracy of the segmentation results is significantly improved.
Smart Images

Figure CN118552573B_ABST
Abstract
Description
Background Art
[0002] Optical Coherence Tomography Angiography (OCTA) is a new imaging technique in the field of ophthalmology. It performs fundus imaging in a non-invasive manner without the need for intravenous injection of fluorescent dyes, thus greatly reducing potential damage to the eye. The foveal avascular zone is a blood vessel-free area in the retinal depression, and its shape and size are associated with exudative age-related macular degeneration and glaucoma. Therefore, the foveal avascular zone (FAZ) plays a vital role in the clinical diagnosis of various eye diseases. However, due to the presence of shadows, noise, and complex vascular structures in OCTA images, it is still challenging to accurately segment the FAZ. With the advancement of deep learning in the field of medical image processing, existing segmentation methods usually regard the segmentation of the FAZ as an independent task and perform segmentation based on the inherent background texture of the FAZ. Other methods regard FAZ segmentation and vascular segmentation as a joint task, and use the vascular segmentation results to assist the segmentation of the FAZ. However, the segmentation results in related technologies are not ideal. Summary of the invention
[0003] The present disclosure provides an image segmentation method, apparatus, device and medium, which at least to a certain extent improve the accuracy of foveal avascular area segmentation.
[0004] Other features and advantages of the present disclosure will become apparent from the following detailed description, or may be learned in part by the practice of the present disclosure.
[0005] According to one aspect of the present disclosure, there is provided an image segmentation method, comprising:
[0006] Obtain optical coherence tomography angiography (OCTA) images;
[0007] Extracting vascular image area information and avascular image area information in Optical Coherence Tomography Angiography (OCTA) images based on codec;
[0008] The vascular image region information and the avascular image region information are input into the segmentation intelligent model to obtain the foveal avascular image region.
[0009] In one embodiment of the present disclosure, the input segmentation intelligent model includes a feature aggregation module and a boundary perception module;
[0010] The vascular image area information and the avascular image area information are input into the segmentation intelligent model to obtain the foveal avascular image area, including:
[0011] Inputting the blood vessel image region information into a multi-scale global feature extractor to obtain a first output result;
[0012] Inputting the vascular image region information and the non-vascular image region information into a multi-directional local feature extractor to obtain a second output result;
[0013] Inputting the first output result and the second output result into the attention module to obtain a third output result;
[0014] The avascular image region information and the third output result are input into the boundary perception module to obtain the foveal avascular image region.
[0015] In one embodiment of the present disclosure, the blood vessel image region information is input into a multi-scale global feature extractor to obtain a first output result, including:
[0016] Determine multiple feature maps based on the Transformer neural network structure and vascular image region information;
[0017] Calculate multiple feature maps based on a first preset formula to obtain a first output result ;
[0018] Among them, the first preset formula is:
[0019] (1)
[0020] in, are multiple feature maps, Q is the query vector projected by the largest feature map, K and V are the key vector and value vector of the projections of the remaining feature maps in the multiple feature maps, respectively, and d is the dimension of the vector.
[0021] In one embodiment of the present disclosure, the vascular image region information and the non-vascular image region information are input into a multi-directional local feature extractor to obtain a second output result, including:
[0022] Determine multiple feature maps based on the Transformer neural network structure and vascular image region information;
[0023] Calculate the plurality of feature maps based on a second preset formula to obtain a second output result;
[0024] Among them, the second preset formula is:
[0025] (2)
[0026] Among them, X is the information of the avascular image area, X×W represents the strip convolution operation, W represents the strip convolution filter of size 2k+1, k is a positive integer, is the direction vector of the filter w, i is the horizontal coordinate, j is the vertical coordinate, and l is the offset of the convolution kernel in a specific direction. is the second output result.
[0027] In one embodiment of the present disclosure, the first output result and the second output result are input into the attention module to obtain a third output result, including:
[0028] Convolve the first output result and the second output result based on a third preset formula to obtain an intermediate result;
[0029] The intermediate result is operated based on the fourth preset formula and the fifth preset formula to obtain a third output result;
[0030] Among them, the third preset formula is:
[0031] (3)
[0032] in, is the intermediate result, It is a Concat operation. represents a convolutional layer with normalization operation;
[0033] The fourth preset formula is:
[0034] (4)
[0035] The fifth preset formula is:
[0036] (5)
[0037] in, Represents the sigmoid operation, and Represent channel attention operation and spatial attention operation respectively, represents element-wise multiplication, and They represent the execution of channel attention operation and the third output result respectively.
[0038] In one embodiment of the present disclosure, the avascular image region information and the third output result are input into a boundary perception module to obtain a foveal avascular image region, including:
[0039] Initialize the perception window on the avascular image region information and the third output result to obtain a window set W;
[0040] Determine the entropy value of the boundary in the information of the avascular image region and the entropy value of the blood vessel end in the third output result ,Will as well as The sum is determined as the final score of the window ;
[0041] (6)
[0042] Where (x, y) is the coordinate of the upper left corner of the window, (h, w) is the size of the window, N is the number of windows in the set W, m is the index of the height, and n is the index of the width;
[0043] Based on the non-maximum suppression operation, the windows with high overlap in the set W are removed, and the top z windows with the highest scores are determined as the final boundary-aware window set. ;
[0044] Extracting a set using convolution operations The boundary information inside the window is obtained ;
[0045] Will Fusion with the avascular image area information to obtain the foveal avascular image area .
[0046] In one embodiment of the present disclosure, the method further includes:
[0047] The intelligent model is trained based on historical vascular image region information, historical avascular image region information, and historical foveal avascular image region to obtain a segmentation intelligent model;
[0048] Among them, the loss function corresponding to the intelligent model is:
[0049] (7)
[0050] in, and They represent the Dice loss of the intelligent model prediction and the final prediction result of the encoder and decoder, and Represents a hyperparameter.
[0051] According to another aspect of the present disclosure, there is provided an image segmentation device, comprising:
[0052] An acquisition module, used for acquiring optical coherence tomography angiography OCTA images;
[0053] An extraction module, used for extracting vascular image region information and non-vascular image region information in the OCTA image based on a codec;
[0054] The input module is used to input the vascular image area information and the avascular image area information into the segmentation intelligent model to obtain the foveal avascular image area.
[0055] In one embodiment of the present disclosure, the segmentation intelligent model includes a feature aggregation module and a boundary perception module;
[0056] Input modules, including:
[0057] A first input unit, used to input the blood vessel image region information into the multi-scale global feature extractor to obtain a first output result;
[0058] A second input unit, used to input the vascular image region information and the non-vascular image region information into the multi-directional local feature extractor to obtain a second output result;
[0059] A third input unit, used to input the first output result and the second output result into the attention module to obtain a third output result;
[0060] The fourth input unit is used to input the avascular image region information and the third output result into the boundary perception module to obtain the foveal avascular image region.
[0061] In one embodiment of the present disclosure, the first input unit includes:
[0062] A first determination subunit is used to determine a plurality of feature maps based on the Transformer neural network structure and the vascular image region information;
[0063] The first calculation subunit is used to calculate the multiple feature maps based on the first preset formula to obtain a first output result ;
[0064] Among them, the first preset formula is:
[0065] (1)
[0066] in, are multiple feature maps, Q is the query vector projected by the largest feature map, K and V are the key vector and value vector of the projections of the remaining feature maps in the multiple feature maps, respectively, and d is the dimension of the vector.
[0067] In one embodiment of the present disclosure, the second input unit includes:
[0068] A second determination subunit is used to determine a plurality of feature maps based on the Transformer neural network structure and the vascular image region information;
[0069] A second calculation subunit, used to calculate the multiple feature maps based on a second preset formula to obtain a second output result;
[0070] Among them, the second preset formula is:
[0071] (2)
[0072] Among them, X is the information of the avascular image area, X×W represents the strip convolution operation, W represents the strip convolution filter of size 2k+1, k is a positive integer, is the direction vector of the filter w, i is the horizontal coordinate, j is the vertical coordinate, and l is the offset of the convolution kernel in a specific direction. is the second output result.
[0073] In one embodiment of the present disclosure, the third input unit includes:
[0074] A convolution unit, configured to convolve the first output result and the second output result based on a third preset formula to obtain an intermediate result;
[0075] A third calculation subunit, configured to operate the intermediate result based on the fourth preset formula and the fifth preset formula to obtain a third output result;
[0076] Among them, the third preset formula is:
[0077] (3)
[0078] in, is the intermediate result, It is a Concat operation. represents a convolutional layer with normalization operation;
[0079] The fourth preset formula is:
[0080] (4)
[0081] The fifth preset formula is:
[0082] (5)
[0083] in, Represents the sigmoid operation, and Represent channel attention operation and spatial attention operation respectively, represents element-wise multiplication, and They represent the execution of channel attention operation and the third output result respectively.
[0084] In one embodiment of the present disclosure, the fourth input unit includes:
[0085] an initialization subunit, configured to initialize a perception window on the avascular image region information and the third output result to obtain a window set W;
[0086] The third determination subunit is used to determine the entropy value of the boundary in the avascular image region information. and the entropy value of the blood vessel end in the third output result ,Will as well as The sum is determined as the final score of the window ;
[0087] (6)
[0088] Where (x, y) is the coordinate of the upper left corner of the window, (h, w) is the size of the window, N is the number of windows in the set W, m is the index of the height, and n is the index of the width;
[0089] The fourth determination subunit is used to remove windows with high overlap in the set W based on the non-maximum suppression operation, and determine the top z windows with the highest scores as the final boundary perception window set. ;
[0090] Extraction subunit, used to extract sets using convolution operations The boundary information inside the window is obtained ;
[0091] Fusion subunit, used to Fusion with the avascular image area information to obtain the foveal avascular image area .
[0092] In one embodiment of the present disclosure, the device further includes:
[0093] A training module, used for training the intelligent model based on historical vascular image region information, historical avascular image region information and historical foveal avascular image region to obtain a segmentation intelligent model;
[0094] Among them, the loss function corresponding to the intelligent model is:
[0095] (7)
[0096] in, and They represent the Dice loss of the intelligent model prediction and the final prediction result of the encoder and decoder, and Represents a hyperparameter.
[0097] According to another aspect of the present disclosure, an electronic device is provided, comprising: a processor; and a memory for storing executable instructions of the processor; wherein the processor is configured to perform the above-mentioned image segmentation method by executing the executable instructions.
[0098] According to another aspect of the present disclosure, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the above-mentioned image segmentation method is implemented.
[0099] The image segmentation method provided in the embodiments of the present disclosure obtains an optical coherence tomography (OCTA) image, extracts vascular image area information and avascular image area information in the OCTA image based on a codec, inputs the vascular image area information and the avascular image area information into a segmentation intelligent model to obtain a foveal avascular image area, and uses the vascular ends to restrict the boundaries of the foveal avascular area to accurately segment the boundaries of the foveal avascular area, thereby improving the segmentation accuracy of the foveal avascular area.
[0100] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0101] The accompanying drawings herein are incorporated into the specification and constitute a part of the specification, illustrate embodiments consistent with the present disclosure, and together with the specification are used to explain the principles of the present disclosure. Obviously, the accompanying drawings described below are only some embodiments of the present disclosure, and for ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without creative work.
[0102] Figure 1 A schematic diagram of a process flow of an image segmentation method in an embodiment of the present disclosure is shown;
[0103] Figure 2 A schematic diagram of another image segmentation method flow in an embodiment of the present disclosure is shown;
[0104] Figure 3 A schematic diagram of a flow chart of another image segmentation method in an embodiment of the present disclosure is shown;
[0105] Figure 4 A schematic diagram of another image segmentation device in an embodiment of the present disclosure is shown; and
[0106] Figure 5 A structural block diagram of another electronic device in an embodiment of the present disclosure is shown. DETAILED DESCRIPTION
[0107] Example embodiments will now be described more fully with reference to the accompanying drawings. However, example embodiments can be implemented in a variety of forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that the disclosure will be more comprehensive and complete and to fully convey the concepts of the example embodiments to those skilled in the art. The described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.
[0108] In addition, the accompanying drawings are only schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the figures represent the same or similar parts, and their repeated description will be omitted. Some of the block diagrams shown in the accompanying drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software form, or implemented in one or more hardware modules or integrated circuits, or implemented in different networks and / or processor devices and / or microcontroller devices.
[0109] It should be understood that the various steps described in the method embodiments of the present disclosure may be performed in different orders and / or in parallel. In addition, the method embodiments may include additional steps and / or omit the steps shown. The scope of the present disclosure is not limited in this respect.
[0110] It should be noted that the concepts such as "first" and "second" mentioned in the present disclosure are only used to distinguish different devices, modules or units, and are not used to limit the order or interdependence of the functions performed by these devices, modules or units.
[0111] It should be noted that the modifications of "one" and "plurality" mentioned in the present disclosure are illustrative rather than restrictive, and those skilled in the art should understand that unless otherwise clearly indicated in the context, it should be understood as "one or more".
[0112] In order to solve the above technical problems, the present disclosure provides an image segmentation method, device, equipment and medium.
[0113] Below, the image segmentation method provided by the present disclosure is first described.
[0114] Figure 1 A schematic flow chart of an image segmentation method in an embodiment of the present disclosure is shown.
[0115] like Figure 1 As shown, the image segmentation method provided by the present disclosure may include:
[0116] S110, acquiring an optical coherence tomography angiography (OCTA) image;
[0117] S120, extracting vascular image region information and non-vascular image region information in the OCTA image based on the codec;
[0118] In some embodiments, extracting the vascular image region information and the non-vascular image region information in the OCTA image based on the codec includes:
[0119] The encoder is used to extract vascular information and FAZ information, and the decoder is used to continuously restore the detailed information of the image, including the FAZ decoder and the vascular decoder. The encoder consists of 5 downsampling blocks. In each downsampling block, the input image is processed by two convolution operations, normalization operations, and ReLU activation functions in sequence. Finally, the feature map size is reduced to half of the original size through the maximum pooling layer. Similarly, the decoder contains 5 upsampling blocks, and the details of the image are gradually restored through the upsampling blocks. The number of channels gradually decreases and the image size gradually increases. Finally, the prediction result is restored to the original size with one channel, and the Softmax function is used to make the value range of each element between 0.0 and 1.0.
[0120] S130, inputting the vascular image region information and the avascular image region information into a segmentation intelligent model to obtain the foveal avascular image region.
[0121] The image segmentation method provided in the embodiments of the present disclosure obtains an optical coherence tomography (OCTA) image, extracts vascular image area information and avascular image area information in the OCTA image based on a codec, inputs the vascular image area information and the avascular image area information into a segmentation intelligent model to obtain a foveal avascular image area, and uses the vascular ends to restrict the boundaries of the foveal avascular area to accurately segment the boundaries of the foveal avascular area, thereby improving the segmentation accuracy of the foveal avascular area.
[0122] Figure 2 A schematic flow chart of another image segmentation method in an embodiment of the present disclosure is shown.
[0123] like Figure 2 As shown, the image segmentation method provided by the present disclosure may include:
[0124] S210, acquiring an optical coherence tomography angiography OCTA image;
[0125] S220: Extracting blood vessel image region information and non-vascular image region information from the OCTA image based on the codec.
[0126] S230, inputting the blood vessel image region information into a multi-scale global feature extractor to obtain a first output result;
[0127] In some embodiments, the blood vessel image region information is input into a multi-scale global feature extractor to obtain a first output result, including:
[0128] Determine multiple feature maps based on the Transformer neural network structure and vascular image region information;
[0129] Calculate multiple feature maps based on a first preset formula to obtain a first output result ;
[0130] Among them, the first preset formula is:
[0131] (1)
[0132] in, are multiple feature maps, Q is the query vector projected by the largest feature map, K and V are the key vector and value vector of the projections of the remaining feature maps in the multiple feature maps, respectively, and d is the dimension of the vector.
[0133] In some embodiments, the self-attention operation of Transformer is used to capture the global distribution information of blood vessels, multiple small-scale feature maps are used as input features of the self-attention operation, and the feature map with the largest scale is selected from the multiple small-scale feature maps and projected to the query vector , and the remaining feature maps are projected onto the key vector Sum value vector , perform self-attention operation, and then, Input into the feedforward neural network to achieve nonlinear transformation and feature extraction to obtain the final output result .
[0134] S240, inputting the vascular image region information and the non-vascular image region information into a multi-directional local feature extractor to obtain a second output result.
[0135] In some embodiments, the vascular image region information and the non-vascular image region information are input into a multi-directional local feature extractor to obtain a second output result, including:
[0136] Determine multiple feature maps based on the Transformer neural network structure and vascular image region information;
[0137] Calculate the plurality of feature maps based on a second preset formula to obtain a second output result;
[0138] Among them, the second preset formula is:
[0139] (2)
[0140] Among them, X is the information of the avascular image area, X×W represents the strip convolution operation, W represents the strip convolution filter of size 2k+1, k is a positive integer, is the direction vector of the filter w, i is the horizontal coordinate, j is the vertical coordinate, and l is the offset of the convolution kernel in a specific direction. is the second output result.
[0141] In some embodiments, a strip convolution kernel with multiple directions is used to capture the local distribution information of the blood vessels, and the input feature is represented as ,go through After the convolution operation, It is guided to 4 parallel channels, representing the strip convolutions in the horizontal, vertical, left diagonal and right diagonal directions respectively. Then, the feature maps generated by the strip convolutions in the four directions are connected and passed The convolution operation realizes feature aggregation, where represents the strip convolution operation, Indicates size The strip convolution filter, is a positive integer, It is a filter The direction vector of The possible values are (0, 1) (horizontally), (1, 0) (vertically), (1, 1) (left diagonal), and (-1, 1) (right diagonal).
[0142] S250, input the first output result and the second output result into an attention module to obtain a third output result.
[0143] In some embodiments, the first output result and the second output result are input into the attention module to obtain a third output result, including:
[0144] Convolve the first output result and the second output result based on a third preset formula to obtain an intermediate result;
[0145] The intermediate result is operated based on the fourth preset formula and the fifth preset formula to obtain a third output result;
[0146] Among them, the third preset formula is:
[0147] (3)
[0148] in, is the intermediate result, It is a Concat operation. represents a convolutional layer with normalization operation;
[0149] The fourth preset formula is:
[0150] (4)
[0151] The fifth preset formula is:
[0152] (5)
[0153] in, Represents the sigmoid operation, and Represent channel attention operation and spatial attention operation respectively, represents element-wise multiplication, and They represent the execution of channel attention operation and the third output result respectively.
[0154] In some embodiments, the global information of the vascular and local information , using the concatenation operation and the convolution operation to connect and ,get ,Right now
[0155] (3)
[0156] in It is a Concat operation. Represents a convolutional layer with normalization operation, and finally fuses global and local features according to channel and spatial dimensions respectively. The specific steps are as follows:
[0157] (4)
[0158] (5)
[0159] in Represents the sigmoid operation, and Represent channel attention operation and spatial attention operation respectively, represents element-wise multiplication, and They represent the feature maps after performing channel attention operation and spatial attention operation respectively.
[0160] S260: Input the avascular image region information and the third output result into a boundary perception module to obtain the foveal avascular image region.
[0161] In some embodiments, the avascular image region information and the third output result are input into a boundary perception module to obtain the foveal avascular image region, including:
[0162] Initialize the perception window on the avascular image region information and the third output result to obtain a window set W;
[0163] Determine the entropy value of the boundary in the information of the avascular image region and the entropy value of the blood vessel end in the third output result ,Will as well as The sum is determined as the final score of the window ;
[0164] (6)
[0165] Where (x, y) is the coordinate of the upper left corner of the window, (h, w) is the size of the window, N is the number of windows in the set W, m is the index of the height, and n is the index of the width;
[0166] Based on the non-maximum suppression operation, the windows with high overlap in the set W are removed, and the top z windows with the highest scores are determined as the final boundary-aware window set. ;
[0167] Extracting a set using convolution operations The boundary information inside the window is obtained ;
[0168] Will Fusion with the avascular image area information to obtain the foveal avascular image area .
[0169] In some embodiments, the input feature map and From the FAZ decoder and the vascular decoder, respectively, Initialize the perception window and get the window set ;
[0170] Calculate separately Entropy value of FAZ boundary and Entropy value of the middle vessel end , calculate the sum of the entropy values of the FAZ boundary and the vessel end in each window as the final score of the window :
[0171] S W i = 1 ⌊ h 2 ⌋ ⌊ w 2 ⌋ ∑ m = 0 ⌊ h 2 ⌋ ∑ n = 0 ⌊ w 2 ⌋ [ S faz ( ⌊ x 2 ⌋ + m , ⌊ y 2 ⌋ + n ) , S rv ( ⌊ x 2 ⌋ + m , ⌊ y 2 ⌋ + n ) ] , i = 1 , 2 , … N (6)
[0172] Where (x, y) is the coordinate of the upper left corner of the window, (h, w) is the size of the window, For collection The number of windows in ;
[0173] Using non-maximum suppression to remove sets The windows with high overlap in the middle are selected, and the top z windows with the highest scores are selected as the final boundary-aware window set. ;
[0174] Extracting a set using convolution operations Boundary information inside the window and compare it with the input image Fusion to obtain edge-enhanced images .
[0175] F VGBM = C [ F W ′ , X ]
[0176] The image segmentation method provided in the embodiments of the present disclosure obtains an optical coherence tomography (OCTA) image, extracts vascular image area information and avascular image area information in the OCTA image based on a codec, inputs the vascular image area information and the avascular image area information into a segmentation intelligent model to obtain a foveal avascular image area, and uses the vascular ends to restrict the boundaries of the foveal avascular area to accurately segment the boundaries of the foveal avascular area, thereby improving the segmentation accuracy of the foveal avascular area.
[0177] Figure 3 A flowchart of another image segmentation method in an embodiment of the present disclosure is shown.
[0178] like Figure 3 As shown, the image segmentation method provided by the present disclosure may include:
[0179] S310, acquiring an optical coherence tomography angiography OCTA image;
[0180] S320: Extracting blood vessel image region information and non-vascular image region information from the OCTA image based on the codec.
[0181] S330, training the intelligent model based on historical vascular image region information, historical avascular image region information, and historical foveal avascular image region to obtain a segmentation intelligent model.
[0182] S340, inputting the vascular image region information and the avascular image region information into a segmentation intelligent model to obtain the foveal avascular image region.
[0183] Among them, the loss function corresponding to the intelligent model is:
[0184]
[0185] in, and They represent the Dice loss of the intelligent model prediction and the final prediction result of the encoder and decoder, and Represents a hyperparameter.
[0186] In some embodiments, the loss function of the network model is defined as:
[0187]
[0188] in and They represent the Dice losses of the multi-scale global-local feature aggregation module prediction and the final prediction result of the FAZ decoder, and Represents a hyperparameter.
[0189] The image segmentation method provided in the embodiments of the present disclosure obtains an optical coherence tomography (OCTA) image, extracts vascular image area information and avascular image area information in the OCTA image based on a codec, inputs the vascular image area information and the avascular image area information into a segmentation intelligent model to obtain a foveal avascular image area, and uses the vascular ends to restrict the boundaries of the foveal avascular area to accurately segment the boundaries of the foveal avascular area, thereby improving the segmentation accuracy of the foveal avascular area.
[0190] Based on the same inventive concept, the present disclosure also provides an image segmentation device in the following embodiments. Since the principle of solving the problem in the device embodiment is similar to that in the above method embodiment, the implementation of the device embodiment can refer to the implementation of the above method embodiment, and the repeated parts will not be repeated.
[0191] Figure 4 A schematic diagram of an image segmentation device in an embodiment of the present disclosure is shown. Figure 4 As shown, the device comprises:
[0192] An acquisition module 410 is used to acquire an optical coherence tomography angiography OCTA image;
[0193] An extraction module 420 is used to extract vascular image region information and non-vascular image region information in the OCTA image based on a codec;
[0194] The input module 430 is used to input the vascular image region information and the avascular image region information into the segmentation intelligent model to obtain the foveal avascular image region.
[0195] In one embodiment of the present disclosure, the segmentation intelligent model includes a feature aggregation module and a boundary perception module;
[0196] Input modules, including:
[0197] A first input unit, used to input the blood vessel image region information into the multi-scale global feature extractor to obtain a first output result;
[0198] A second input unit, used to input the vascular image region information and the non-vascular image region information into the multi-directional local feature extractor to obtain a second output result;
[0199] A third input unit, used to input the first output result and the second output result into the attention module to obtain a third output result;
[0200] The fourth input unit is used to input the avascular image region information and the third output result into the boundary perception module to obtain the foveal avascular image region.
[0201] In one embodiment of the present disclosure, the first input unit includes:
[0202] A first determination subunit is used to determine a plurality of feature maps based on the Transformer neural network structure and the vascular image region information;
[0203] The first calculation subunit is used to calculate the multiple feature maps based on the first preset formula to obtain a first output result ;
[0204] Among them, the first preset formula is:
[0205] (1)
[0206] in, are multiple feature maps, Q is the query vector projected by the largest feature map, K and V are the key vector and value vector of the projections of the remaining feature maps in the multiple feature maps, respectively, and d is the dimension of the vector.
[0207] In one embodiment of the present disclosure, the second input unit includes:
[0208] A second determination subunit is used to determine a plurality of feature maps based on the Transformer neural network structure and the vascular image region information;
[0209] A second calculation subunit, used to calculate the multiple feature maps based on a second preset formula to obtain a second output result;
[0210] Among them, the second preset formula is:
[0211] (2)
[0212] Among them, X is the information of the avascular image area, X×W represents the strip convolution operation, W represents the strip convolution filter of size 2k+1, k is a positive integer, is the direction vector of the filter w, i is the horizontal coordinate, j is the vertical coordinate, and l is the offset of the convolution kernel in a specific direction. is the second output result.
[0213] In one embodiment of the present disclosure, the third input unit includes:
[0214] A convolution unit, configured to convolve the first output result and the second output result based on a third preset formula to obtain an intermediate result;
[0215] A third calculation subunit, configured to operate the intermediate result based on the fourth preset formula and the fifth preset formula to obtain a third output result;
[0216] Among them, the third preset formula is:
[0217] (3)
[0218] in, is the intermediate result, It is a Concat operation. represents a convolutional layer with normalization operation;
[0219] The fourth preset formula is:
[0220] (4)
[0221] The fifth preset formula is:
[0222] (5)
[0223] in, Represents the sigmoid operation, and Represent channel attention operation and spatial attention operation respectively, represents element-wise multiplication, and They represent the execution of channel attention operation and the third output result respectively.
[0224] In one embodiment of the present disclosure, the fourth input unit includes:
[0225] an initialization subunit, configured to initialize a perception window on the avascular image region information and the third output result to obtain a window set W;
[0226] The third determination subunit is used to determine the entropy value of the boundary in the avascular image region information. and the entropy value of the blood vessel end in the third output result ,Will as well as The sum is determined as the final score of the window ;
[0227] (6)
[0228] Where (x, y) is the coordinate of the upper left corner of the window, (h, w) is the size of the window, N is the number of windows in the set W, m is the index of the height, and n is the index of the width;
[0229] The fourth determination subunit is used to remove windows with high overlap in the set W based on the non-maximum suppression operation, and determine the top z windows with the highest scores as the final boundary perception window set. ;
[0230] Extraction subunit, used to extract sets using convolution operations The boundary information inside the window is obtained ;
[0231] Fusion subunit, used to Fusion with the avascular image area information to obtain the foveal avascular image area .
[0232] In one embodiment of the present disclosure, the device further includes:
[0233] A training module, used for training the intelligent model based on historical vascular image region information, historical avascular image region information and historical foveal avascular image region to obtain a segmentation intelligent model;
[0234] Among them, the loss function corresponding to the intelligent model is:
[0235] (7)
[0236] in, and They represent the Dice loss of the intelligent model prediction and the final prediction result of the encoder and decoder, and Represents a hyperparameter.
[0237] The image segmentation device provided in the embodiments of the present disclosure obtains an optical coherence tomography (OCTA) image, extracts vascular image area information and avascular image area information in the OCTA image based on a codec, inputs the vascular image area information and the avascular image area information into a segmentation intelligent model to obtain a foveal avascular image area, and uses the vascular ends to restrict the boundaries of the foveal avascular area to accurately segment the boundaries of the foveal avascular area, thereby improving the segmentation accuracy of the foveal avascular area.
[0238] Those skilled in the art will appreciate that various aspects of the present disclosure may be implemented as systems, methods or program products. Therefore, various aspects of the present disclosure may be specifically implemented in the following forms, namely: complete hardware implementation, complete software implementation (including firmware, microcode, etc.), or a combination of hardware and software, which may be collectively referred to herein as "circuits", "modules" or "systems".
[0239] Refer to the following Figure 5 The electronic device 500 according to this embodiment of the present disclosure is described. Figure 5 The electronic device 500 shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.
[0240] like Figure 5 As shown, the electronic device 500 is in the form of a general computing device. The components of the electronic device 500 may include but are not limited to: at least one processing unit 510, at least one storage unit 520, and a bus 530 connecting different system components (including the storage unit 520 and the processing unit 510).
[0241] The storage unit stores program codes, which can be executed by the processing unit 510, so that the processing unit 510 performs the steps of various exemplary embodiments of the present disclosure described in the above “Exemplary Method” section of this specification. For example, the processing unit 510 can perform the following steps of the above method embodiment:
[0242] Obtain optical coherence tomography angiography (OCTA) images;
[0243] Extracting vascular image area information and non-vascular image area information in OCTA images based on codec;
[0244] The vascular image region information and the avascular image region information are input into the segmentation intelligent model to obtain the foveal avascular image region.
[0245] The storage unit 520 may include a readable medium in the form of a volatile storage unit, such as a random access storage unit (RAM) 5201 and / or a cache storage unit 5202 , and may further include a read-only storage unit (ROM) 5203 .
[0246] The storage unit 520 may also include a program / utility 5205 having a set (at least one) of program modules 5205, such program modules 5205 including but not limited to: an operating system, one or more application programs, other program modules and program data, each of which or some combination may include an implementation of a network environment.
[0247] Bus 530 may represent one or more of several types of bus structures, including a memory unit bus or memory unit controller, a peripheral bus, an accelerated graphics port, a processing unit, or a local bus using any of a variety of bus architectures.
[0248] The electronic device 500 may also communicate with one or more external devices 550 (e.g., keyboards, pointing devices, Bluetooth devices, etc.), may also communicate with one or more devices that enable a user to interact with the electronic device 500, and / or communicate with any device that enables the electronic device 500 to communicate with one or more other computing devices (e.g., routers, modems, etc.). This communication may be performed through an input / output (I / O) interface 550. In addition, the electronic device 500 may also communicate with one or more networks (e.g., local area networks (LANs), wide area networks (WANs), and / or public networks, such as the Internet) through a network adapter 550. As shown, the network adapter 550 communicates with other modules of the electronic device 500 through a bus 530. It should be understood that, although not shown in the figure, other hardware and / or software modules may be used in conjunction with the electronic device 500, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, etc.
[0249] Through the description of the above implementation, it is easy for those skilled in the art to understand that the example implementation described here can be implemented by software, or by software combined with necessary hardware. Therefore, the technical solution according to the implementation of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, and includes a number of instructions to enable a computing device (which can be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the implementation of the present disclosure.
[0250] In an exemplary embodiment of the present disclosure, a computer-readable storage medium is also provided, which may be a readable signal medium or a readable storage medium. A program product capable of implementing the above method of the present disclosure is stored thereon. In some possible implementations, various aspects of the present disclosure may also be implemented in the form of a program product, which includes a program code, and when the program product is run on a terminal device, the program code is used to enable the terminal device to execute the steps according to various exemplary implementations of the present disclosure described in the above “Exemplary Method” section of this specification.
[0251] More specific examples of computer-readable storage media in the present disclosure may include, but are not limited to, an electrical connection having one or more conductors, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0252] In the present disclosure, a computer readable storage medium may include a data signal propagated in baseband or as part of a carrier wave, wherein a readable program code is carried. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. A readable signal medium may also be any readable medium other than a readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device.
[0253] Alternatively, the program code contained on the computer-readable storage medium may be transmitted using any appropriate medium, including but not limited to wireless, wired, optical cable, RF, etc., or any suitable combination of the foregoing.
[0254] In specific implementation, the program code for performing the operation of the present disclosure may be written in any combination of one or more programming languages, including object-oriented programming languages such as Java, C++, etc., and conventional procedural programming languages such as "C" language or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, as an independent software package, partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computing device (e.g., using an Internet service provider to connect through the Internet).
[0255] It should be noted that, although several modules or units of the device for action execution are mentioned in the above detailed description, this division is not mandatory. In fact, according to the embodiments of the present disclosure, the features and functions of two or more modules or units described above can be embodied in one module or unit. On the contrary, the features and functions of one module or unit described above can be further divided into multiple modules or units to be embodied.
[0256] In addition, although the steps of the method in the present disclosure are described in a specific order in the drawings, this does not require or imply that the steps must be performed in this specific order, or that all the steps shown must be performed to achieve the desired results. Additionally or alternatively, some steps may be omitted, multiple steps may be combined into one step, and / or one step may be decomposed into multiple steps, etc.
[0257] Through the description of the above implementation modes, it is easy for those skilled in the art to understand that the example implementation modes described here can be implemented by software, or by software combined with necessary hardware. Therefore, the technical solution according to the implementation mode of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, and includes several instructions to enable a computing device (which can be a personal computer, a server, a mobile terminal, or a network device, etc.) to execute the method according to the implementation mode of the present disclosure.
[0258] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the invention disclosed herein. The present disclosure is intended to cover any variations, uses or adaptations of the present disclosure, which follow the general principles of the present disclosure and include common knowledge or customary techniques in the art that are not disclosed in the present disclosure. The description and examples are intended to be exemplary only, and the true scope and spirit of the present disclosure are indicated by the appended claims.
Claims
1. An image segmentation method, characterized in that: The method comprises: Obtain optical coherence tomography angiography (OCTA) images; Extracting vascular image region information and non-vascular image region information in the OCTA image based on a codec; Inputting the vascular image region information and the avascular image region information into a segmentation intelligent model to obtain a foveal avascular image region; The input segmentation intelligent model includes a feature aggregation module and a boundary perception module; The step of inputting the vascular image region information and the non-vascular image region information into a segmentation intelligent model to obtain a foveal non-vascular image region includes: Inputting the blood vessel image region information into a multi-scale global feature extractor to obtain a first output result; Inputting the vascular image region information and the non-vascular image region information into a multi-directional local feature extractor to obtain a second output result; Inputting the first output result and the second output result into an attention module to obtain a third output result; Inputting the avascular image region information and the third output result into a boundary perception module to obtain a foveal avascular image region; The step of inputting the vascular image region information and the non-vascular image region information into a multi-directional local feature extractor to obtain a second output result includes: Determine multiple feature maps based on the Transformer neural network structure and vascular image region information; Calculate the plurality of feature maps based on a second preset formula to obtain a second output result; Wherein, the second preset formula is: (2) Among them, X is the information of the avascular image area, X×W represents the strip convolution operation, W represents the strip convolution filter of size 2k+1, k is a positive integer, is the direction vector of the filter w, i is the horizontal coordinate, j is the vertical coordinate, and l is the offset of the convolution kernel in a specific direction. is the second output result; The step of inputting the avascular image region information and the third output result into a boundary perception module to obtain the foveal avascular image region includes: Initialize a perception window on the avascular image region information and the third output result to obtain a window set W; Determine the entropy value of the boundary in the information of the avascular image region and the entropy value of the blood vessel end in the third output result , the as well as The sum is determined as the final score of the window ; (6) Where (x, y) is the coordinate of the upper left corner of the window, (h, w) is the size of the window, N is the number of windows in the set W, m is the index of the height, and n is the index of the width; Based on the non-maximum suppression operation, the windows with high overlap in the set W are removed, and the top z windows with the highest scores are determined as the final boundary-aware window set. ; Extracting a set using convolution operations The boundary information inside the window is obtained ; Will Fusion with the avascular image area information to obtain the foveal avascular image area .
2. The image segmentation method according to claim 1, characterized in that: The step of inputting the blood vessel image region information into a multi-scale global feature extractor to obtain a first output result includes: Determine multiple feature maps based on the Transformer neural network structure and vascular image region information; Calculate multiple feature maps based on a first preset formula to obtain a first output result ; Wherein, the first preset formula is: (1) in, are multiple feature maps, Q is the query vector projected by the largest feature map, K and V are the key vector and value vector of the projections of the remaining feature maps in the multiple feature maps, respectively, and d is the dimension of the vector.
3. The image segmentation method according to claim 1, characterized in that: The step of inputting the first output result and the second output result into an attention module to obtain a third output result includes: Convolve the first output result and the second output result based on a third preset formula to obtain an intermediate result; The intermediate result is operated based on the fourth preset formula and the fifth preset formula to obtain a third output result; Among them, the third preset formula is: (3) in, is the intermediate result, It is a Concat operation. represents a convolutional layer with normalization operation; The fourth preset formula is: (4) The fifth preset formula is: (5) in, Represents the sigmoid operation, and Represent channel attention operation and spatial attention operation respectively, represents element-wise multiplication, and They represent the execution of channel attention operation and the third output result respectively.
4. The image segmentation method according to claim 1, characterized in that: The method further comprises: The intelligent model is trained based on historical vascular image region information, historical avascular image region information, and historical foveal avascular image region to obtain a segmentation intelligent model; Among them, the loss function corresponding to the intelligent model is: (7) in, and Represents the Dice loss of the intelligent model prediction and the final prediction result of the encoder and decoder, and Represents a hyperparameter.
5. An image segmentation device, characterized in that: The device comprises: An acquisition module, used for acquiring optical coherence tomography angiography OCTA images; An extraction module, used for extracting vascular image region information and non-vascular image region information in the OCTA image based on a codec; An input module, used for inputting the vascular image region information and the avascular image region information into a segmentation intelligent model to obtain a foveal avascular image region; The input segmentation intelligent model includes a feature aggregation module and a boundary perception module; The step of inputting the vascular image region information and the non-vascular image region information into a segmentation intelligent model to obtain a foveal non-vascular image region includes: Inputting the blood vessel image region information into a multi-scale global feature extractor to obtain a first output result; Inputting the vascular image region information and the non-vascular image region information into a multi-directional local feature extractor to obtain a second output result; Inputting the first output result and the second output result into an attention module to obtain a third output result; Inputting the avascular image region information and the third output result into a boundary perception module to obtain a foveal avascular image region; The step of inputting the vascular image region information and the non-vascular image region information into a multi-directional local feature extractor to obtain a second output result includes: Determine multiple feature maps based on the Transformer neural network structure and vascular image region information; Calculate the plurality of feature maps based on a second preset formula to obtain a second output result; Wherein, the second preset formula is: (2) Among them, X is the information of the avascular image area, X×W represents the strip convolution operation, W represents the strip convolution filter of size 2k+1, k is a positive integer, is the direction vector of the filter w, i is the horizontal coordinate, j is the vertical coordinate, and l is the offset of the convolution kernel in a specific direction. is the second output result; The step of inputting the avascular image region information and the third output result into a boundary perception module to obtain the foveal avascular image region includes: Initialize a perception window on the avascular image region information and the third output result to obtain a window set W; Determine the entropy value of the boundary in the information of the avascular image region and the entropy value of the blood vessel end in the third output result , the as well as The sum is determined as the final score of the window ; (6) Where (x, y) is the coordinate of the upper left corner of the window, (h, w) is the size of the window, N is the number of windows in the set W, m is the index of the height, and n is the index of the width; Based on the non-maximum suppression operation, the windows with high overlap in the set W are removed, and the top z windows with the highest scores are determined as the final boundary-aware window set. ; Extracting a set using convolution operations The boundary information inside the window is obtained ; Will Fusion with the avascular image area information to obtain the foveal avascular image area .
6. An electronic device, characterized in that: include: processor; as well as A memory, configured to store executable instructions of the processor; Wherein, the processor is configured to perform the image segmentation method described in any one of claims 1 to 4 by executing the executable instructions.
7. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the image segmentation method according to any one of claims 1 to 4 is implemented.
Citation Information
Patent Citations
Blood vessel and macular avascular zone quantitative analysis method and system suitable for OCTA images
CN110033861A
OCTA image blood vessel segmentation method and device based on deep convolutional neural network, and medium
CN114881968A
