A three-dimensional hepatobiliary image segmentation algorithm and system

By constructing ResNet-3D and multi-scale attention networks, combining feature decoding networks and loss functions, the problems of high precision and computing efficiency in CT image segmentation in the prior art are solved, and more accurate and efficient hepatobiliary duct segmentation is achieved, especially In 3D medical imaging processing.

CN114119547BActive Publication Date: 2025-01-07SHANGHAI HAIWEI MEDICAL TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111417005.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-11-19
Publication Date
2025-01-07
Estimated Expiration
2041-11-19

AI Technical Summary

Technical Problem

The prior art cannot take into account high accuracy and computing efficiency in CT image segmentation of hepatochondria stone disease. In particular, two-dimensional convolutional neural networks tend to ignore longitudinal connections and lose spatial information when processing 3D medical images, resulting in undersegmentation.

Method used

Using the three-dimensional hepatobiliary duct image segmentation algorithm, the residual network ResNet-3D, multi-scale attention network and feature decoding network are constructed, combined with loss function, CT image sequence is processed to obtain the correlation between low-level and high-level features, and to pay attention through multi-scale attention Force module and upsampling fusion features improve segmentation performance.

Benefits of technology

It significantly improves the accuracy and efficiency of hepatic bile duct segmentation, effectively recognizes the marginal characteristics of bile ducts and stones, enhances the extraction performance of features of interest at different scales, and improves the segmentation accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114119547B_ABST
    Figure CN114119547B_ABST
Patent Text Reader

Abstract

The present invention provides a three-dimensional hepatobiliary image segmentation algorithm and system. The method first constructs a residual network ResNet-3D to process an input image sequence to obtain the residual network ResNet-3D low-level features and high-level features of the input image sequence; then, a multi-scale attention network is constructed to learn the correlation between the obtained low-level features and high-level features; then, a feature decoding network is constructed to fuse the processed low-level features and high-level features; finally, a loss function is constructed to process the obtained results to obtain the final segmentation result. The multi-scale attention module introduced in the present invention can significantly enhance the performance of extracting features of interest at different scales; a new bias loss function is used to effectively identify the edge features of the bile duct while accurately identifying the significant bile duct area, thereby improving the segmentation accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of medical image processing, and more specifically, to a three-dimensional hepatobiliary image segmentation algorithm and system. Background Art

[0002] Hepatobiliary stones are a common and frequently occurring disease in hepatobiliary surgery, and the disease is more common in East Asia. The surgical treatment of hepatobiliary stones faces many difficulties and challenges, including the difficulty in removing hepatobiliary stones. The removal of hepatobiliary stones mainly relies on minimally invasive surgery, such as percutaneous transhepatic cholangioscopy (PTCS) stone removal surgery. Stone removal surgery depends largely on the analysis of the patient's CT scans before surgery. Since the hepatobiliary ducts and intrahepatic blood vessels are close, accurate segmentation of the hepatobiliary ducts in CT images is performed to understand the specific distribution of the bile ducts, which is beneficial for better finding the stenosis during surgical intervention and reducing the possibility of massive bleeding due to incorrect puncture. Three-dimensional reconstruction of the CT sequence after image segmentation makes the preoperative planning of the operation more reasonable.

[0003] At present, there are two main technologies for segmenting CT images of hepatobiliary stones: traditional image segmentation algorithms (watershed algorithm, etc.) or convolutional neural networks (such as U-Net network, M-Net network, or convolutional networks that introduce modules such as ConvLSTM). Thanks to the significant improvement in computer computing power, methods based on convolutional neural networks have become mainstream.

[0004] The prior art discloses an image recognition system for hepatobiliary ducts and gallstones, including: an input module for acquiring an image to be tested and inputting it into a trained sparse convolutional neural network; a sparse convolutional neural network for performing image recognition on the image to be tested, and segmenting the position contours of the hepatobiliary ducts and gallstones in the image to be tested in the recognition result; each convolutional layer in the first encoder in the sparse convolutional neural network uses a small convolution kernel, and each convolutional layer in the remaining encoders and each decoder uses a sparse convolution kernel; during the first encoding process, feature maps at different scales are output to subsequent encoders and decoders, and fused with feature maps at corresponding resolutions. The solution of the present application can be used to more effectively identify images of hepatobiliary ducts and gallstones, thereby assisting doctors in treatment; however, inspired by Unet, this work proposes a cascaded solution M-Net, which achieves better results in bile duct segmentation and gallstone segmentation. However, both U-Net and M-Net are two-dimensional convolutional neural networks and cannot directly process 3D medical images. The usual practice is to divide the 3D image sequence into multiple 2D image slices and then input them into the neural network separately. This makes it easy to ignore the longitudinal connection in the slices and lose the spatial information in the CT data, which can easily lead to under-segmentation.

[0005] The prior art also discloses an image segmentation system for hepatobiliary and biliary stones. In the first encoder-decoder, feature learning is performed on the small target area in the downsampling stage, and feature fusion is performed in the upsampling stage. The downsampling extracts low-level multi-scale temporal context features for subsequent layer-by-layer feature fusion. In the second encoder-decoder module, the upsampling stage fuses the low-level multi-scale temporal context features with the high-level bidirectional temporal context features, and obtains a predicted sequence diagram of the original resolution size, thereby obtaining more accurate position and classification information. The segmentation network model is trained by an improved loss function to increase the attention to the temporal context information between the slices of the sequence image, so that it is more suitable for processing the sequence image. Thus, the technical problem that the prior art cannot simultaneously take into account the accuracy and high efficiency of the segmentation of hepatobiliary and biliary stones in the CT images of hepatobiliary stones is solved. However, by introducing the ConvLSTM module on the basis of M-Net, the spatial information of the slice is obtained, and the contextual connection in the slice is obtained. This is a 2.5D approach, but it is still necessary to convert the CT data into 2D slice data, which is essentially still a two-dimensional convolutional network. Summary of the invention

[0006] The present invention provides a three-dimensional hepatobiliary image segmentation algorithm, which solves the technical problem that the prior art cannot simultaneously take into account the spatial information and computational efficiency between CT sequences for high-precision hepatobiliary segmentation in CT images.

[0007] Another object of the present invention is to provide a three-dimensional hepatobiliary image segmentation system using the above-mentioned three-dimensional hepatobiliary image segmentation algorithm.

[0008] In order to achieve the above technical effects, the technical solution of the present invention is as follows:

[0009] A three-dimensional hepatobiliary image segmentation algorithm comprises the following steps:

[0010] S1: Construct a residual network ResNet-3D to process the input image sequence, and obtain the residual network ResNet-3D low-level features and high-level features of the input image sequence;

[0011] S2: Construct a multi-scale attention network to learn the correlation between the low-level features and high-level features obtained in step S1;

[0012] S3: Construct a feature decoding network to fuse the low-level features processed in step S2 with the high-level feature graph;

[0013] S4: Construct a loss function and process the result obtained in step S3 to obtain the final segmentation result.

[0014] Furthermore, the specific process of step S1 is:

[0015] 1) The CT sequence of size (1,1,d,512,512), where d represents the number of slices, may vary for different sequences but is guaranteed to be more than 48; is divided into multiple small feature blocks of (1,48,192,192) through patching operation and used as the input of the residual network;

[0016] 2) First, after passing through a single 3D convolutional layer with a scale of 64, the first layer feature E0 is obtained;

[0017] 3) Then, after passing through a three-layer residual module ResBlock-3D with a scale of 192, the second-layer feature E1 is obtained;

[0018] 4) Then, after passing through a three-layer residual module ResBlock-3D with a scale of 384, the third-layer feature E2 is obtained;

[0019] 5) Finally, after passing through a two-layer residual module ResBlock-3D with a scale of 384, the fourth layer feature E3 is obtained.

[0020] Furthermore, the specific process of step S2 is:

[0021] A multi-scale attention network is built using the 3D Swin Transformer block. Each Transformerblock consists of a sliding window-based W-MSA module and a feedforward network FFN, where the feedforward network FFN consists of a two-layer multi-head attention processing module MLP and an activation function GELU; layer normalization LN is used before each sliding window-based W-MSA module and feedforward network FFN, and residual connections are used after each module:

[0022]

[0023]

[0024]

[0025]

[0026] In the formula and z l denote the output features of the sliding window-based W-MSA module and the FFN module, respectively; 3DW-MSA and 3DSW-MSA denote 3D window-based multi-head self-attention using regular and shifted window partition configurations, respectively.

[0027] Furthermore, in step S2, since relative position encoding is used in the self-attention calculation, the attention is calculated as follows:

[0028]

[0029] in is the query, key, and value matrix, and d is the dimension of query and key features;

[0030] The calculation process of the multi-scale attention module is as follows:

[0031] S nx ,S nx′ =Reshape(MAST(Flatten(E nx ),Flatten(E nx′ )))

[0032] E nx ,E nx′ It represents the output feature of the residual module, S nx ,S nx′ represents the output after the attention module, where n ranges from 0 to 3, and x and x′ are 0 and 1 respectively. In the processing process, the features are first flattened, then spliced ​​into the input attention module, and then the output feature matrix of the attention module is restored to its original size to obtain S nx , S nx′ .

[0033] Furthermore, the specific process of step S3 is:

[0034] Using the S output by the multi-scale attention network in step S2 nx ,S nx′ As input, n represents the same scale (same size) of features. These two features come from different feature layers. Add them together to get a D of the same scale. n , the calculation process is as follows:

[0035] D n =S nx +S nx′

[0036] In the formula, the value range of n is 0 to 3, and the values ​​of x and x′ are 0 and 1 respectively, which are used to distinguish the outputs of two different sources of the same scale feature.

[0037] Furthermore, in step S3, since the low-level features have higher resolution and contain more position and detail information, but have undergone fewer convolutions, their semantics are lower and there is more noise, while the high-level features have stronger semantic information, but their resolution is very low and their perception of details is poor, therefore, feature D is used asn Upsample to get U n , while U n Characteristic scale and D n-1 Similarly, after adding the two, input the next upsampling layer, repeat this step until n is 1; at this time, after upsampling, the low-level features and high-level features are fused to extract the strengths of each layer to improve the segmentation performance; finally, after a full convolution layer, the segmentation result is output.

[0038] Furthermore, the specific process of step S4 is:

[0039] Construct the loss function L hep as follows:

[0040]

[0041] Where A is the manually annotated label and B is the network learning result; the first term learns the similarity between the predicted result and the label, and the second term is the bias term, which is used to learn the edge information of the bile duct; the bias term minimizes the asymmetric distance in the shape or contour space by using the integral on the boundary between regions, and takes the form of a distance metric in the contour space or region boundary, Ω represents the area enclosed by the boundary of the region learned by the network and the boundary of the true segmentation region; φA:Ω→R represents the boundary of the manually annotated label region A, b θ (q) is the softmax probability output of the network. During training, the hyperparameters are adjusted. In the initial period, α=1.0 is set to learn the region B with higher similarity. After several cycles, the size of the hyperparameters is adjusted. Through automated design, α=(α*0.01) is linearly reduced at the end of each period. In order to avoid divergence of results, the minimum α is 0.33.

[0042] A three-dimensional hepatobiliary image segmentation system, comprising:

[0043] Construct a residual network ResNet-3D module to process the input image sequence and obtain the residual network ResNet-3D low-level features and high-level features of the input image sequence;

[0044] Multi-scale attention network module, used to learn the correlation between low-level features and high-level features;

[0045] The feature decoding network module fuses the low-level features processed by the multi-scale attention network module with the high-level feature graph;

[0046] Construct a loss function module and process the output of the feature decoding network module to obtain the final segmentation result.

[0047] Compared with the prior art, the technical solution of the present invention has the following beneficial effects:

[0048] The present invention processes the input image sequence by first constructing a residual network ResNet-3D to obtain the residual network ResNet-3D low-level features and high-level features of the input image sequence; then, a multi-scale attention network is constructed to learn the correlation between the obtained low-level features and high-level features; then, a feature decoding network is constructed to fuse the processed low-level features and high-level features; finally, a loss function is constructed to process the obtained results to obtain the final segmentation result. The multi-scale attention module introduced in the present invention can significantly enhance the performance of extracting features of interest at different scales; the new bias loss function is adopted, while accurately identifying the significant bile duct area, the edge features of the bile duct can be effectively identified, and the segmentation accuracy can be improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0049] Figure 1 is a flow chart of the method of the present invention;

[0050] Figure 2 It is the Transformer module diagram;

[0051] Figure 3 This is a system block diagram of the present invention. DETAILED DESCRIPTION

[0052] The drawings are for illustrative purposes only and should not be construed as limiting the present patent;

[0053] In order to better illustrate the present embodiment, some parts in the drawings may be omitted, enlarged or reduced, and do not represent the size of the actual product;

[0054] It is understandable to those skilled in the art that some well-known structures and their descriptions may be omitted in the drawings.

[0055] The technical solution of the present invention is further described below in conjunction with the accompanying drawings and embodiments.

[0056] Example 1

[0057] like Figure 1 As shown, a three-dimensional hepatobiliary image segmentation algorithm includes the following steps:

[0058] S1: Construct a residual network ResNet-3D to process the input image sequence, and obtain the residual network ResNet-3D low-level features and high-level features of the input image sequence;

[0059] S2: Construct a multi-scale attention network to learn the correlation between the low-level features and high-level features obtained in step S1;

[0060] S3: Construct a feature decoding network to fuse the low-level features processed in step S2 with the high-level feature graph;

[0061] S4: Construct a loss function and process the result obtained in step S3 to obtain the final segmentation result.

[0062] The specific process of step S1 is:

[0063] 1) The CT sequence of size (1,1,d,512,512), where d represents the number of slices, may vary for different sequences but is guaranteed to be more than 48; is divided into multiple small feature blocks of (1,48,192,192) through patching operation and used as the input of the residual network;

[0064] 2) First, after passing through a single 3D convolutional layer with a scale of 64, the first layer feature E0 is obtained;

[0065] 3) Then, after passing through a three-layer residual module ResBlock-3D with a scale of 192, the second-layer feature E1 is obtained;

[0066] 4) Then, after passing through a three-layer residual module ResBlock-3D with a scale of 384, the third-layer feature E2 is obtained;

[0067] 5) Finally, after passing through a two-layer residual module ResBlock-3D with a scale of 384, the fourth layer feature E3 is obtained.

[0068] like Figure 2 As shown, the specific process of step S2 is:

[0069] A multi-scale attention network is built using the 3D Swin Transformer block. Each Transformerblock consists of a sliding window-based W-MSA module and a feedforward network FFN, where the feedforward network FFN consists of a two-layer multi-head attention processing module MLP and an activation function GELU; layer normalization LN is used before each sliding window-based W-MSA module and feedforward network FFN, and residual connections are used after each module:

[0070]

[0071]

[0072]

[0073]

[0074] In the formula and z ldenote the output features of the sliding window-based W-MSA module and the FFN module, respectively; 3DW-MSA and 3DSW-MSA denote 3D window-based multi-head self-attention using regular and shifted window partition configurations, respectively.

[0075] In step S2, since relative position encoding is used in self-attention calculation, the attention is calculated as follows:

[0076]

[0077] in is the query, key, and value matrix, and d is the dimension of query and key features;

[0078] The calculation process of the multi-scale attention module is as follows:

[0079] S nx ,S nx′ =Reshape(MAST(Flatten(E nx ),Flatten(E nx′ )))

[0080] E nx ,E nx′ It represents the output feature of the residual module, S nx ,S nx′ represents the output after the attention module, where n ranges from 0 to 3, and x and x′ are 0 and 1 respectively. In the processing process, the features are first flattened, then spliced ​​into the input attention module, and then the output feature matrix of the attention module is restored to its original size to obtain S nx , S nx′ .

[0081] The specific process of step S3 is:

[0082] Using the S output by the multi-scale attention network in step S2 nx ,S nx′ As input, n represents the same scale (same size) of features. These two features come from different feature layers. Add them together to get a D of the same scale. n , the calculation process is as follows:

[0083] D n =S nx +S nx′

[0084] In the formula, the value range of n is 0 to 3, and the values ​​of x and x′ are 0 and 1 respectively, which are used to distinguish the outputs of two different sources of the same scale feature.

[0085] In step S3, since the low-level features have higher resolution and contain more position and detail information, but they have undergone fewer convolutions, their semantics is lower and there is more noise, while the high-level features have stronger semantic information, but their resolution is very low and their perception of details is poor. Therefore, feature D n Upsample to get U n , while U n Characteristic scale and D n-1 Similarly, after adding the two, input the next upsampling layer, repeat this step until n is 1; at this time, after upsampling, the low-level features and high-level features are fused to extract the strengths of each layer to improve the segmentation performance; finally, after a full convolution layer, the segmentation result is output.

[0086] The specific process of step S4 is:

[0087] Construct the loss function L hep as follows:

[0088]

[0089] Where A is the manually annotated label and B is the network learning result; the first term learns the similarity between the predicted result and the label, and the second term is the bias term, which is used to learn the edge information of the bile duct; the bias term minimizes the asymmetric distance in the shape or contour space by using the integral on the boundary between regions, and takes the form of a distance metric in the contour space or region boundary, Ω represents the area enclosed by the boundary of the region learned by the network and the boundary of the true segmentation region; φA:Ω→R represents the boundary of the manually annotated label region A, b θ (q) is the softmax probability output of the network. During training, the hyperparameters are adjusted. In the initial period, α=1.0 is set to learn the region B with higher similarity. After several cycles, the size of the hyperparameters is adjusted. Through automated design, α=(α*0.01) is linearly reduced at the end of each period. In order to avoid divergence of results, the minimum α is 0.33.

[0090] Example 2

[0091] like Figure 3 As shown, a three-dimensional hepatobiliary image segmentation system comprises:

[0092] Construct a residual network ResNet-3D module to process the input image sequence and obtain the residual network ResNet-3D low-level features and high-level features of the input image sequence;

[0093] Multi-scale attention network module, used to learn the correlation between low-level features and high-level features;

[0094] The feature decoding network module fuses the low-level features processed by the multi-scale attention network module with the high-level feature graph;

[0095] Construct a loss function module and process the output of the feature decoding network module to obtain the final segmentation result.

[0096] The process of building the residual network ResNet-3D module is:

[0097] 1) The CT sequence of size (1,1,d,512,512), where d represents the number of slices, may vary for different sequences but is guaranteed to be more than 48; is divided into multiple small feature blocks of (1,48,192,192) through patching operation and used as the input of the residual network;

[0098] 2) First, after passing through a single 3D convolutional layer with a scale of 64, the first layer feature E0 is obtained;

[0099] 3) Then, after passing through a three-layer residual module ResBlock-3D with a scale of 192, the second-layer feature E1 is obtained;

[0100] 4) Then, after passing through a three-layer residual module ResBlock-3D with a scale of 384, the third-layer feature E2 is obtained;

[0101] 5) Finally, after passing through a two-layer residual module ResBlock-3D with a scale of 384, the fourth layer feature E3 is obtained.

[0102] The processing process of the multi-scale attention network module is:

[0103] A multi-scale attention network is built using the 3D Swin Transformer block. Each Transformerblock consists of a sliding window-based W-MSA module and a feedforward network FFN, where the feedforward network FFN consists of a two-layer multi-head attention processing module MLP and an activation function GELU; layer normalization LN is used before each sliding window-based W-MSA module and feedforward network FFN, and residual connections are used after each module:

[0104]

[0105]

[0106]

[0107]

[0108] In the formula and z ldenote the output features of the sliding window-based W-MSA module and the FFN module, respectively; 3DW-MSA and 3DSW-MSA denote 3D window-based multi-head self-attention using regular and shifted window partition configurations, respectively.

[0109] Since relative position encoding is used in self-attention calculation, attention is calculated as follows:

[0110]

[0111] in is the query, key, and value matrix, and d is the dimension of query and key features;

[0112] The calculation process of the multi-scale attention module is as follows:

[0113] S nx ,S nx′ =Reshape(MAST(Flatten(E nx ),Flatten(E nx′ )))

[0114] E nx ,E nx′ It represents the output feature of the residual module, S nx ,S nx′ represents the output after the attention module, where n ranges from 0 to 3, and x and x′ are 0 and 1 respectively. In the processing process, the features are first flattened, then spliced ​​into the input attention module, and then the output feature matrix of the attention module is restored to its original size to obtain S nx , S nx′ .

[0115] The specific processing process of the feature decoding network module is:

[0116] The S output of the multi-scale attention network using the multi-scale attention network module nx ,S nx′ As input, n represents the same scale (same size) of features. These two features come from different feature layers. Add them together to get a D of the same scale. n , the calculation process is as follows:

[0117] D n =S nx +S nx′

[0118] In the formula, the value range of n is 0 to 3, and the values ​​of x and x′ are 0 and 1 respectively, which are used to distinguish the outputs of two different sources of the same scale feature.

[0119] Since low-level features have higher resolution and contain more position and detail information, but they have undergone fewer convolutions, their semantics are lower and they have more noise, while high-level features have stronger semantic information, but their resolution is very low and their perception of details is poor. Therefore, feature D n Upsample to get U n , while U n Characteristic scale and D n-1 Similarly, after adding the two, input the next upsampling layer, repeat this step until n is 1; at this time, after upsampling, the low-level features and high-level features are fused to extract the strengths of each layer to improve the segmentation performance; finally, after a full convolution layer, the segmentation result is output.

[0120] The specific process of building the loss function module is:

[0121] Construct the loss function L hep as follows:

[0122]

[0123] Where A is the manually annotated label and B is the network learning result; the first term learns the similarity between the predicted result and the label, and the second term is the bias term, which is used to learn the edge information of the bile duct; the bias term minimizes the asymmetric distance in the shape or contour space by using the integral on the boundary between regions, and takes the form of a distance metric in the contour space or region boundary, Ω represents the area enclosed by the boundary of the region learned by the network and the boundary of the true segmentation region; φA:Ω→R represents the boundary of the manually annotated label region A, b θ (q) is the softmax probability output of the network. During training, the hyperparameters are adjusted. In the initial period, α=1.0 is set to learn the region B with higher similarity. After several cycles, the size of the hyperparameters is adjusted. Through automated design, α=(α*0.01) is linearly reduced at the end of each period. In order to avoid divergence of results, the minimum α is 0.33.

[0124] The same or similar reference numerals correspond to the same or similar components;

[0125] The positional relationships described in the drawings are only for illustrative purposes and should not be construed as limiting the present patent.

[0126] Obviously, the above embodiments of the present invention are merely examples for clearly illustrating the present invention, and are not intended to limit the embodiments of the present invention. For those skilled in the art, other different forms of changes or modifications can be made based on the above description. It is not necessary and impossible to list all the embodiments here. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the claims of the present invention.

Claims

1. A three-dimensional hepatobiliary image segmentation algorithm, characterized in that: The following steps are involved: S1: Construct a residual network ResNet-3D to process the input image sequence and obtain the low-level and high-level features of the residual network ResNet-3D of the input image sequence. The specific process is: 1) The CT sequence of size (1,1,d,512,512) is divided into multiple small feature blocks of (1,48,192,192) through patching operation and used as the input of the residual network. d represents the number of slices. Different sequences have different d, and all d of different sequences are greater than 48. 2) First, after passing through a single 3D convolutional layer with a scale of 64, the first layer feature E0 is obtained; 3) Then, after passing through a three-layer residual module ResBlock-3D with a scale of 192, the second-layer feature E1 is obtained; 4) Then, after passing through a three-layer residual module ResBlock-3D with a scale of 384, the third-layer feature E2 is obtained; 5) Finally, after passing through a two-layer residual module ResBlock-3D with a scale of 384, the fourth layer feature E3 is obtained; S2: Construct a multi-scale attention network to learn the correlation between the low-level features and high-level features obtained in step S1. The specific process is: A multi-scale attention network is built using the 3D Swin Transformer block. Each Transformer block consists of a sliding window-based W-MSA module and a feedforward network FFN, where the feedforward network FFN consists of a two-layer multi-head attention processing module MLP and an activation function GELU; layer normalization LN is used before each sliding window-based W-MSA module and feedforward network FFN, and residual connections are used after each module: In the formula and z l They represent the output features of the sliding window-based W-MSA module and the FFN module respectively; 3DW-MSA and 3DSW-MSA denote 3D window-based multi-head self-attention using regular and shifted window partition configurations, respectively; Since relative position encoding is used in self-attention calculation, attention is calculated as follows: in is the query, key, and value matrix, and d is the dimension of query and key features; The calculation process of the multi-scale attention MAST module is as follows: S nx ,S nx′ =Reshape(MAST(Flatten(E nx ),Flatten(E nx′ ))) E nx ,E nx′ It represents the output feature of the residual module, S nx ,S nx′ represents the output after the attention module, where n ranges from 0 to 3, and x and x′ are 0 and 1 respectively. In the processing process, the features are first flattened, then spliced ​​into the input attention module, and then the output feature matrix of the attention module is restored to its original size to obtain S nx , S nx′ ; S3: Construct a feature decoding network to fuse the low-level features processed in step S2 with the high-level feature graph. The specific process is: Using the S output by the multi-scale attention network in step S2 nx ,S nx′ As input, the same n represents the same scale or size of features. These two features come from different feature layers. Add them together to get a D of the same scale. n , the calculation process is as follows: D n =S nx +S nx′ In the formula, the value range of n is 0 to 3, and the values ​​of x and x′ are 0 and 1 respectively, which are used to distinguish the outputs of two different sources of the same scale feature; S4: Construct a loss function and process the result obtained in step S3 to obtain the final segmentation result. The specific process is: Construct the loss function L hep as follows: Where A is the manually annotated label and B is the network learning result; the first term learns the similarity between the predicted result and the label, and the second term is the bias term, which is used to learn the edge information of the bile duct; The bias term minimizes the asymmetric distance in the shape or contour space by using the integral on the boundary between regions and takes the form of a distance metric in the contour space or region boundary. Ω represents the area enclosed by the boundary of the region learned by the network and the true segmentation region; φA:Ω→R represents the boundary of the manually annotated label region A, b θ (q) is the softmax probability output of the network. During training, the hyperparameters are adjusted. In the initial period, α=1.0 is set to learn the region B with higher similarity. After several cycles, the size of the hyperparameters is adjusted. Through automated design, α=(α*0.01) is linearly reduced at the end of each period.

2. The three-dimensional hepatobiliary image segmentation algorithm according to claim 1, characterized in that: In step S3, since the low-level features have higher resolution and contain more position and detail information, but they have undergone fewer convolutions, their semantics are lower and they have more noise, while the high-level features have stronger semantic information, but their resolution is very low and their perception of details is poor. Therefore, feature D n Upsample to get U n , while U n Characteristic scale and D n-1 Similarly, after adding the two, input the next upsampling layer, repeat this step until n is 1; at this time, after upsampling, the low-level features and high-level features are fused to extract the strengths of each layer to improve the segmentation performance; finally, after a full convolution layer, the segmentation result is output.

3. The three-dimensional hepatobiliary image segmentation algorithm according to claim 2, characterized in that: To avoid divergence of the results, the minimum α is 0.

33.

4. A three-dimensional hepatobiliary image segmentation system using the three-dimensional hepatobiliary image segmentation algorithm according to claim 1, characterized in that: include: Construct a residual network ResNet-3D module to process the input image sequence and obtain the residual network ResNet-3D low-level features and high-level features of the input image sequence; Multi-scale attention network module, used to learn the correlation between low-level features and high-level features; The feature decoding network module fuses the low-level features processed by the multi-scale attention network module with the high-level feature graph; Construct a loss function module and process the output of the feature decoding network module to obtain the final segmentation result.

Citation Information

Patent Citations

  • Content-guide Residual Network for Image Super-Resolution

    AU2020100200A4

  • Remote sensing image semantic segmentation method based on attention multi-scale feature fusion

    CN111127493A