Optimization method for enhancement processing of CT image
By introducing convolutional groups, refining self-attention modules and strengthening jump connection modules in the CT image processing model, the problem of poor results in the processing of noise and low-contrast images is solved, and more efficient Image feature processing and image quality improvement.
Patent Information
- Application Number
- CN202411520934.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-29
- Publication Date
- 2025-02-21
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Existing CT image enhancement technology is not effective when processing noise and low-contrast images, especially when there are small differences in different tissue densities, it is difficult to effectively improve the contrast and clarity of images.
A CT image processing model is proposed, which combines dynamic convolution and deep convolution of 1×1 and 3×3 convolution kernels, combines refined self-attention module and enhanced jump connection module to perform multi-stage feature fusion and Refine, enhance the continuity of image feature processing.
It effectively improves the contrast and clarity of CT images, retains more image information, enhances the continuity of feature processing, and improves the attention of image details and the integrity of feature transmission.
Smart Images

Figure CN119494794A_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the field of image enhancement, and in particular relates to an optimization method for enhancement processing of CT images. Background Art
[0002] CT image enhancement plays a vital role in medical image processing. It aims to improve the contrast and clarity of images, making the lesion area easier to identify. The original CT images are usually difficult to observe due to noise, low contrast and other problems, especially when the density difference between different tissues is small. Image enhancement technology can help doctors observe organs, tissues and potential lesions more accurately, thereby supporting more accurate diagnosis.
[0003] The background of CT image enhancement stems from the needs of imaging diagnosis. Traditional CT imaging technology is limited by equipment, and the resolution and contrast of images are limited. With the advancement of medical imaging equipment and the continuous development of enhancement technology, more possibilities are provided for image post-processing. CT image enhancement mainly includes grayscale transformation, spatial filtering, histogram equalization and other methods to optimize image quality. Through these methods, image details can be highlighted and noise can be suppressed, thus providing doctors with clearer and easier-to-read images for diagnosis.
[0004] In practical applications, CT image enhancement not only helps identify lesions such as tumors and vascular stenosis, but can also be used for preoperative planning and postoperative evaluation. The diagnosis of different diseases requires different image enhancement technologies to meet specific needs. For example, cerebrovascular imaging needs to highlight vascular details, while lung scans need to improve contrast to clearly display the lung structure. With the introduction of artificial intelligence, the intelligence level of image enhancement continues to improve, which further improves the accuracy of automatic recognition and diagnosis, providing technical support for precision medicine and personalized treatment. Summary of the invention
[0005] The present invention provides an optimization method for enhanced processing of CT images, aiming to propose a CT image processing model, wherein a convolution group combines dynamic convolution and deep convolution of 1×1 and 3×3 convolution kernels as the basic component of the CT image processing model, and a convolution group refinement self-attention module generates a secondary value through the output features of the self-attention mechanism on the basis of the original self-attention mechanism, performs a secondary self-attention operation to achieve feature refinement, and strengthens the jump connection module to fuse the features of multiple stages, thereby retaining more CT image information and enhancing the continuity of feature processing.
[0006] The present invention aims to propose a CT image processing model and provide an optimization method for enhancing CT images, comprising the following steps: S1. CT image dataset preparation: multiple CT images are collected from existing public CT image libraries and CT image datasets as multiple optimized CT images. Blurring is performed on the multiple optimized CT images, including applying Gaussian blur, motion blur and 2x downsampling to reduce the clarity and quality of the multiple optimized CT images, to obtain multiple CT images to be processed, and corresponding to the multiple optimized CT images, to form a CT image dataset; S2, build a convolution group, including dynamic convolution and depth convolution; S3, construct a convolution group refined self-attention module, including convolution groups, root mean square normalization and weight matrix; S4, construct a skip connection module, including a convolution group and a ReLU activation function; S5, constructing an enhanced skip connection module, including a skip connection module and a convolution group; S6, construct a multi-stage processing module, including a convolution group, a convolution group refined self-attention module, and a strengthened skip connection module; S7. Construct a CT image processing model, including input, 3×3 convolution, 2x downsampling, transposed convolution, multi-order processing modules and output; S8. Training and application of CT image processing model. Use CT image dataset to train CT image processing model. After training, input a single CT image to be processed into the CT image processing model to obtain a single optimized CT image.
[0007] Preferably, in step S2, for the convolution group, given the input feature F GCIn , F GCIn ∈R H×W×C , R represents the real number domain, H, W and C represent the input features F GCIn The height, width and channel of , and then obtain the feature F GCOut , F GCOut ∈R H×W×C , feature F GCOut And the input features F GCIn The dimensions of F GCOut =DWC 3×3 (Concat(DC 3×3 (DC 1×1 (F GCIn )), DWC 1×1 (F GCIn ))), where DC 1×1 Represents 1×1 dynamic convolution, DC 3×3 Represents 3×3 dynamic convolution, DWC 1×1 Represents 1×1 depthwise convolution, DWC 3×3 represents 3×3 depth convolution, Concat represents concatenation in the channel dimension, and feature F GCOut is the output of the convolutional group.
[0008] Preferably, in step S2, for the convolution group, the introduction of dynamic convolution allows the convolution kernel to be adjusted according to the input features during the feature extraction process, thereby enhancing the adaptability of the convolution layer to different regions and contents. While reducing the amount of calculation, the deep convolution can maintain the richness of the features. By reducing the computational complexity, the deep convolution provides support for the optimization and real-time performance of the CT image processing model, so that the convolution group can still perform high performance even with limited hardware resources. Combined with 1×1 and 3×3 convolution kernels, the convolution group realizes the fusion of multi-scale features. As a modular component, the convolution group flexibly enhances the feature processing at each stage in the CT image processing model.
[0009] Preferably, in step S3, for the convolution group refinement self-attention module, given the input feature F GCRSAIn , F GCRSAIn ∈R H×W×C , R represents the real number domain, H, W and C represent the input features F GCRSAIn The height, width and channel of the first feature F GCRSA1 , F GCRSA1 =GConv1(RMSNorm(F GCRSAIn )), where GConv1 represents the first convolution group, RMSNorm represents root mean square normalization, and then obtains the query Q, key K and value V, Q = W Q (F GCRSA1 ), K=W K (F GCRSA1 ), V = W V (F GCRSA1 ), W Q , W K and W V There are three different weight matrices, implemented by three independent linear layers, and then the feature F is calculated GCRSA2 , K T represents the matrix transpose of the key K, Represents the scaling factor, Softmax represents the Softmax activation function, and then obtains the feature F GCRSA3 , F GCRSA3 =GConv2(F GCRSA2 V), GConv2 represents the second convolution group, and then calculates the secondary value V2, is the weight matrix implemented by the linear layer, and then calculates the feature F GCRSA4 , F GCRSA4 =F GCRSA2 V2, and then get the feature F GCRSAOut , F GCRSAOut ∈R H×W×C , feature FGCRSAOut And the input features F GCRSAIn The dimensions of F GCRSAOut =GConv3(RMSNorm(Drop(F GCRSA4 )))+F GCRSA3 , where Drop represents random dropout, GConv3 represents the third convolution group, RMSNorm represents root mean square normalization, + represents element-wise addition, and feature F GCRSAOut is the output of the convolutional group refined self-attention module.
[0010] Preferably, in step S3, for the convolution group refining self-attention module, based on the original self-attention mechanism, the module first obtains preliminary output features through the initial self-attention calculation, and then generates a secondary value and performs a secondary self-attention operation on it. This process allows the convolution group refining self-attention module to further focus on details that were not fully extracted in the initial attention calculation, enhance the selective capture of important features, and make the final output features more accurate and detailed.
[0011] Preferably, in step S4, for the skip connection module, given the input main feature F SCMIn and input sub-feature F SCSIn , F SCMIn ∈R H×W×C , F SCSIn ∈R H×W×C , R represents the real number domain, H, W and C represent the input main features F SCMIn and input sub-feature F SCSIn The height, width and channel of , and then get the main output feature F SCMOut and the secondary output feature F SCSOut , F SCMOut ∈R H×W×C , F SCSOut ∈R H×W×C , the main output feature F SCMOut , secondary output feature F SCSOut , input main feature F SCMIn and input sub-feature F SCSIn The dimensions of these four features are consistent, F SCMOut =GConv2(Concat(ReLU(CA1(GConv1(F SCMIn ))), F SCSIn )), F SCSOut =CA2(GConv3(F SCMIn ))+F SCSIn, where GConv1 represents the first convolution group, GConv2 represents the second convolution group, GConv3 represents the third convolution group, CA1 represents the first channel attention, CA2 represents the second channel attention, ReLU represents the ReLU activation function, Concat represents concatenation in the channel dimension, + represents element-by-element addition, and the main output feature F SCMOut and the secondary output feature F SCSOut are the two output features of the skip connection module.
[0012] Preferably, in step S5, for the enhanced skip connection module, given the input main feature F DSCMIn and input sub-feature F DSCSIn , F DSCMIn ∈R H×W×C , F DSCSIn ∈R H×W×C , R represents the real number domain, H, W and C represent the input main features F DSCMIn and input sub-feature F DSCSIn The height, width and channel of the input main feature F DSCMIn and input sub-feature F DSCSIn Input to the first skip connection module to obtain the main feature F DSCM1 and sub-feature F DSCS1 , input the main feature F DSCMIn Corresponding to the input main feature of the first jump connection module input, the input main feature F SCMIn The input secondary feature corresponding to the first jump connection module input, the main feature F DSCM1 Corresponding to the main output feature of the first jump connection module output, the secondary feature F DSCS1 Corresponding to the secondary output feature of the first jump connection module output, the main feature F DSCM1 and sub-feature F DSCS1 Concatenate in the channel dimension and input into the convolution group to obtain feature F DSC1 , F DSC1 ∈R H×W×2C , 2C represents 2 times C, and then the feature F DSC1 Split in half in the channel dimension to obtain the optimized main feature F DSCM2 and optimize the secondary feature F DSCS2 , and then optimize the main feature F DSCM2 and optimize the secondary feature F DSCS2 Input to the second skip connection module to get the output main feature F DSCMOut And output sub-feature F DSCSOu , optimize the main feature F DSCM2 Corresponding to the input main feature of the second jump connection module input, optimize the secondary feature F DSCS2 Corresponding to the input secondary feature of the second jump connection module input, the output main feature FDSCMOut Corresponding to the main output feature of the second jump connection module output, the output secondary feature F DSCSOu Corresponding to the secondary output feature output by the first jump connection module, the main feature F is output DSCMOut And output sub-feature F DSCSOu are the two output features of the enhanced skip connection module.
[0013] Preferably, in step S5, for the enhanced jump connection module, the module accepts the main features and the secondary features as input, and establishes denser connections between features at different levels through double-layer jump connections and feature splicing. This design achieves a rich fusion of CT image information and retains key information from shallow and deep layers, thereby improving the CT image processing model's attention to details and the integrity of feature transfer.
[0014] Preferably, in step S6, for the multi-stage processing module, given the input feature F MSIn , F MSIn ∈R H×W×C , R represents the real number domain, H, W and C represent the input features F MSIn The height, width and channel of the first feature F MSm1 and feature F MSa1 , F MSm1 ∈R H ×W×C , F MSa1 ∈R H×W×C , F MSm1 , F MSa1 =DSC1(GCRSA1(GeLU(CBAM(GConv1(F MSIn )))))), where CBAM represents spatial and channel attention, GeLU represents GeLU activation function, GCOnv1 represents the first convolution group, GCRSA1 represents the first convolution group refined self-attention module, DDC1 represents the first enhanced skip connection module, and the input main feature and input secondary feature of the first enhanced skip connection module DSC1 are both feature F MSmidf , feature F MSmidf By GCRSA1(GeLU(CBAM(GConv1(F MSIn ))))Get, feature F MSm1 The output main feature corresponding to the first enhanced skip connection module DSC1 output, feature F MSa1 Corresponding to the output sub-feature of the first enhanced skip connection module DSC1, the feature F is then obtained MSm1t , F MSm1t ∈R H×W×C , F MSm1t =GCRSA2(GeLU(GConv2(F MSm1 +FMSIn ))), GCOnv2 represents the second convolution group, + represents element-by-element addition, GCRSA2 represents the second convolution group refinement self-attention module, and then obtains the feature F MSm2 and feature F MSa2 , F MSm2x R H×W×C , F MSa2 ∈R H×W×C , F MSm2 , F MSa2 =DSC2(F MSm1t , F MSa1 ), DSC2 represents the second enhanced skip connection module, feature F MSm1t Corresponding to the main input feature of the second enhanced skip connection module DSC2, feature F MSa1 Corresponding to the input sub-feature of the second enhanced skip connection module DSC2, feature F MSm2 The output main feature corresponding to the second enhanced skip connection module DSC2 output, feature F MSa2 Corresponding to the output sub-feature of the second enhanced skip connection module DSC2, we get feature F MSm2t , F MSm2t ∈R H×W×C , F MSm2t =GCRSA3(GeLU(GConv3(F MSm2 +F MSm1 ), GConv3 represents the third convolution group, + represents element-by-element addition, GCRSA3 represents the third convolution group refinement self-attention module, and then obtains the feature F MSm3 and feature F MSa3 , F MSm3 ∈R H×W×C , F MSa3 ∈R H×W×C , F MSm3 , F MSa3 =DSC3(F MSm2t , F MSa2 ), DSC3 represents the third enhanced skip connection module, feature F MSm2t Corresponding to the main input feature of the third enhanced skip connection module DSC3, feature F MSa2 Corresponding to the input sub-feature of the third enhanced skip connection module DSC3, feature F MSm3 The output main feature corresponding to the output of the third enhanced skip connection module DSC3, feature F MSa3 The output sub-feature corresponding to the output of the third enhanced skip connection module DSC3, feature F MSm3 is the output of the multi-stage processing module, feature F MSm3 and the input features F of the multi-stage processing module MSIn The dimensions are consistent.
[0015] Preferably, in step S7, for the CT image processing model, a single CT image to be processed I, I∈R h×w×3 , R represents the real number domain, h, W and 3 represent the height, width and channel of a single CT image I to be processed, and the single CT image I to be processed is input into the 2-fold downsampling to obtain the downsampled image I1, is half of h, It is half of W. Input the single CT image I to be processed into the first 3×3 convolution to obtain the feature F1. H1, W1 and C1 are the height, width and channel of feature F1. Feature F1 is input into the first multi-stage processing module to obtain feature F 11 , The downsampled image I1 is input into the second 3×3 convolution to obtain the feature F2. H2, W2 and C2 represent the height, width and channel of feature F2. Feature F2 is input into the second multi-stage processing module to obtain feature F 21 , The feature F 21 Input to the transposed convolution to get the feature F 21up , The feature F 21up and feature F 11 Add element by element to get the final feature F end , The final feature F end Input to the third 3×3 convolution to obtain a single optimized CT image I + , I + ∈R h×w×3 , single optimized CT image I + is the output of the CT image processing model.
[0016] Compared with the prior art, the present invention has the following technical effects: The technical solution provided by the present invention proposes a CT image processing model, in which a convolution group combines dynamic convolution and deep convolution of 1×1 and 3×3 convolution kernels as the basic component of the CT image processing model. The convolution group refines the self-attention module based on the original self-attention mechanism, generates secondary values through the output features of the self-attention mechanism, and performs secondary self-attention operations to achieve feature refinement. The jump connection module is strengthened to fuse the features of multiple stages, thereby retaining more CT image information and enhancing the continuity of feature processing. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] Figure 1 The present invention provides a CT image enhancement processing flow chart.
[0018] Figure 2 It is a structural diagram of the CT image processing model provided by the present invention.
[0019] Figure 3 It is a single CT image to be processed provided by the present invention.
[0020] Figure 4 It is a single optimized CT image provided by the present invention. DETAILED DESCRIPTION
[0021] The present invention aims to propose an optimization method for enhanced processing of CT images, and proposes a CT image processing model, in which a convolution group combines dynamic convolution and depth convolution of 1×1 and 3×3 convolution kernels as the basic component of the CT image processing model. The convolution group refines the self-attention module based on the original self-attention mechanism, generates secondary values through the output features of the self-attention mechanism, performs secondary self-attention operations to achieve feature refinement, and strengthens the jump connection module to fuse the features of multiple stages, retains more CT image information, and enhances the continuity of feature processing.
[0022] See also Figure 1 As shown, an optimization method for enhancing CT images in an embodiment of the present application is as follows: S1. CT image dataset preparation: 600 CT images are collected from existing public CT image libraries and CT image datasets as 600 optimized CT images. The 600 optimized CT images are blurred, including applying Gaussian blur to 200 optimized CT images, applying motion blur to 200 optimized CT images, and applying 2x downsampling to 200 optimized CT images to obtain 600 CT images to be processed, and corresponding to the 600 optimized CT images, a CT image dataset is formed; S2. Convolution groups are constructed, including dynamic convolution and depth convolution; S3, construct a convolution group refined self-attention module, including convolution groups, root mean square normalization and weight matrix; S4, construct a skip connection module, including a convolution group and a ReLU activation function; S5, constructing an enhanced skip connection module, including a skip connection module and a convolution group; S6, construct a multi-stage processing module, including a convolution group, a convolution group refined self-attention module, and a strengthened skip connection module; S7. Construct a CT image processing model, including input, 3×3 convolution, 2x downsampling, transposed convolution, multi-order processing modules and output; S8. Training and application of CT image processing model. Use CT image dataset to train the CT image processing model. After the training is completed, input a single CT image to be processed into the CT image processing model. The height and width of the single CT image to be processed are both 1280, and a single optimized CT image is obtained. The height and width of the single optimized CT image are both 1280.
[0023] Further, in step S2, for the convolution group, given the input feature F GCIn , F GCIn ∈R H×W×C , R represents the real number domain, H, W and C represent the input features F GCIn The height, width and channel of , and then obtain the feature F GCOut , F GCOut ∈R H×W×C , feature F GCOut And the input features F GCIn The dimensions of F GCOut =DWC 3×3 (COncat(DC 3×3 (DC 1×1 (F GCIn )), DWC 1×1 (F GCIn ))), where DC 1×1 Represents 1×1 dynamic convolution, DC 3×3 Represents 3×3 dynamic convolution, DWC 1×1 Represents 1×1 depthwise convolution, DWC 3×3 represents 3×3 depth convolution, COncat represents concatenation in the channel dimension, and feature F GCOut is the output of the convolutional group.
[0024] Further, in step S3, for the convolution group refinement self-attention module, given the input feature F GCRSAIn , F GCRSAIn ∈R H×W×C , R represents the real number domain, H, W and C represent the input features F GCRSAIn The height, width and channel of the first feature F GCRSA1 , F GCRSA1 =GConv1(RMSNorm(F GCRSAIn )), where GConv1 represents the first convolution group, RMSNorm represents root mean square normalization, and then obtains the query Q, key K and value V, Q = W Q (F GCRSA1 ), K=W K (F GCRSA1 ), V = W V (F GCRSA1 ), W Q , W K and WV There are three different weight matrices, implemented by three independent linear layers, and then the feature F is calculated GCRSA2 , K T represents the matrix transpose of the key K, Represents the scaling factor, Softmax represents the softmax activation function, and then obtains the feature F GCRSA3 , F GCRSA3 =GConv2(F GCRSA2 V), GConv2 represents the second convolution group, and then calculates the secondary value V2, is the weight matrix implemented by the linear layer, and then calculates the feature F GCRSA4 , F GCRSA4 =F GCRSA2 V2, and then get the feature F GCRSAOut , F GCRSAOut ∈R H×W×C , feature F GCRSAOut And the input features F GCRSAIn The dimensions of F GCRSAOut =GConv3(RMSNorm(Drop(F GCRSA4 )))+F GCRSA3 , where Drop represents random dropout, GConv3 represents the third convolution group, RMSNorm represents root mean square normalization, + represents element-wise addition, and feature F GCRSAOut is the output of the convolutional group refined self-attention module.
[0025] Further, in step S4, for the skip connection module, given the input main feature F SCMIn and input sub-feature F SCSIn , F SCMIn ∈R H×W×C , F SCSIn ∈R H×W×C , R represents the real number domain, H, W and C represent the input main features F SCMIn and input sub-feature F SCSIn The height, width and channel of , and then get the main output feature F SCMOut and the secondary output feature F SCSOut , F SCMOut ∈R H×W×C , F SCSOut ∈R H×W×C , the main output feature F SCMOut , secondary output feature F SCSOut , input main feature F SCMIn and input sub-feature F SCSIn The dimensions of these four features are consistent, F SCMOut =GConv2(Concat(ReLU(CA1(GConv1(FSCMIn ))), F SCSIn )), F SCSOut =CA2(GConv3(F SCMIn ))+F SCSIn , where GConv1 represents the first convolution group, GConv2 represents the second convolution group, GConv3 represents the third convolution group, CA1 represents the first channel attention, CA2 represents the second channel attention, ReLU represents the ReLU activation function, Concat represents concatenation in the channel dimension, + represents element-by-element addition, and the main output feature F SCMOut and the secondary output feature F SCSOut are the two output features of the skip connection module.
[0026] Further, in step S5, for the enhanced skip connection module, given the input main feature F DSCMIn and input sub-feature F DSCSIn , F DSCMIn ∈R H×W×C , F DSCSIn ∈R H×W×C , R represents the real number domain, H, W and C represent the input main features F DSCMIn and input sub-feature F DSCSIn The height, width and channel of the input main feature F DSCMIn and input sub-feature F DSCSIn Input to the first skip connection module to obtain the main feature F DSCM1 and sub-feature F DSCS1 , input the main feature F DSCMIn Corresponding to the input main feature of the first jump connection module input, the input main feature F SCMIn The input secondary feature corresponding to the first jump connection module input, the main feature F DSCM1 Corresponding to the main output feature of the first jump connection module output, the secondary feature F DDCS1 Corresponding to the secondary output feature of the first jump connection module output, the main feature F DSCM1 and sub-feature F DSCS1 Concatenate in the channel dimension and input into the convolution group to obtain feature F DSC1 , F DSC1 ∈R H×W×2C , 2C represents 2 times C, and then the feature F DSC1 Split in half in the channel dimension to obtain the optimized main feature F DSCM2 and optimize the secondary feature F DSCS2 , and then optimize the main feature F DSCM2 and optimize the secondary feature F DSCS2 Input to the second skip connection module to get the output main feature F DSCMOut And output sub-feature F DSCSOu, optimize the main feature F DSCM2 Corresponding to the input main feature of the second jump connection module input, optimize the secondary feature F DSCS2 Corresponding to the input secondary feature of the second jump connection module input, the output main feature F DSCMOut Corresponding to the main output feature of the second jump connection module output, the output secondary feature F DSCSOu Corresponding to the secondary output feature output by the first jump connection module, the main feature F is output DSCMOut And output sub-feature F DSCSOu are the two output features of the enhanced skip connection module.
[0027] Further, in step S6, for the multi-stage processing module, given the input feature F MSIn , F MSIn ∈R H×W×C , R represents the real number domain, H, W and C represent the input features F MSIn The height, width and channel of the first feature F MSm1 and feature F MSa1 , F MSm1 ∈R H ×W×C , F MSa1 ∈R H×W×C , F MSm1 , F MSa1 =DSC1(GCRSA1(GeLU(CBAM(GConv1(F MSIn )))))), where CBAM represents spatial and channel attention, GeLU represents GeLU activation function, GCOnv1 represents the first convolution group, GCRSA1 represents the first convolution group refined self-attention module, DSC1 represents the first enhanced skip connection module, and the input main feature and input secondary feature of the first enhanced skip connection module DSC1 are both feature F MSmidf , feature F MSmidf By GCRSA1(GeLU(CBAM(GConv1(F MSIn ))))Get, feature F MSm1 The output main feature corresponding to the first enhanced skip connection module DSC1 output, feature F MSa1 Corresponding to the output sub-feature of the first enhanced skip connection module DSC1, the feature F is then obtained MSm1t , F MSm1t ∈R H×W×C , F MSm1t =GCRSA2(GeLU(GConv2(F MSm1 +F MSIn ))), GConv2 represents the second convolution group, + represents element-by-element addition, GCRSA2 represents the second convolution group refinement self-attention module, and then obtains the feature FMSm2 and feature F MSa2 , F MSm2 ∈R H×W×C , F MSa2 ∈R H×W×C , F MSm2 , F MSa2 =DSC2(F MSm1t , F MSa1 ), DSC2 represents the second enhanced skip connection module, feature F MSm1t Corresponding to the main input feature of the second enhanced skip connection module DSC2, feature F MSa1 Corresponding to the input sub-feature of the second enhanced skip connection module DSC2, feature F MSm2 The output main feature corresponding to the second enhanced skip connection module DSC2 output, feature F MSa2 Corresponding to the output sub-feature of the second enhanced skip connection module DSC2, we get feature F MSm2t , F MSm2t ∈R H×W×C , F Msm2t =GCRSA3(GeLU(GConv3(F MSm2 +F MSm1 ), GConv3 represents the third convolution group, + represents element-by-element addition, GCRSA3 represents the third convolution group refinement self-attention module, and then obtains the feature F MSm3 and feature F MSa3 , F MSm3 ∈R H×W×C , F MSa3 ∈R H×W×C , F MSm3 , F MSa3 =DSC3(F MSn2t , F MSa2 ), DSC3 represents the third enhanced skip connection module, feature F MSm2t Corresponding to the main input feature of the third enhanced skip connection module DSC3, feature F MSa2 Corresponding to the input sub-feature of the third enhanced skip connection module DSC3, feature F MSm3 The output main feature corresponding to the output of the third enhanced skip connection module DSC3, feature F MSa3 The output sub-feature corresponding to the output of the third enhanced skip connection module DSC3, feature F MSm3 is the output of the multi-stage processing module, feature F MSm3 and the input features F of the multi-stage processing module MSIn The dimensions are consistent.
[0028] Further, in step S7, for the CT image processing model, its structure is as follows Figure 2As shown, a single CT image to be processed is input, I∈R 1280×1280×3 , R represents the real number domain, 1280, 1280 and 3 represent the height, width and channel of a single CT image I to be processed. The single CT image I to be processed is input into the 2-fold downsampling to obtain the downsampled image I1, I1∈R 640×640×3 , input the single CT image I to be processed into the first 3×3 convolution to obtain the feature F1, F1∈R 128×128×64 , 128, 128 and 64 are the height, width and channel of feature F1. Feature F1 is input into the first multi-stage processing module to obtain feature F 11 , F 11 ∈R 128×128×64 , input the downsampled image I1 into the second 3×3 convolution to obtain the feature F2, F2∈R 64×64×32 , 64, 64 and 32 represent the height, width and channel of feature F2. Feature F2 is input into the second multi-stage processing module to obtain feature F 21 , F 21 ∈R 64×64×32 , the feature F 21 Input to the transposed convolution to get the feature F 21up , F 21up ∈R 128×128×64 , the feature F 21up and feature F 11 Add element by element to get the final feature F end , F end ∈R 128×128×64 , the final feature F end Input to the third 3×3 convolution to obtain a single optimized CT image I + , I + ∈R 1280×1280×3 , single optimized CT image I + is the output of the CT image processing model.
[0029] further, Figure 3 The figure shows a single CT image to be processed. The height and width of the single CT image to be processed are both 1280. The single CT image to be processed is input into the CT image processing model trained in step S8 to obtain Figure 4 The single optimized CT image shown has a height and width of 1280. Figure 3 , Figure 4 Contains more details and better image quality.
[0030] Further, the training details of the CT image processing model in step S8 are as follows: 600 of the CT image data sets are to be processed and optimized, and their order is disrupted. Then, 400 of the CT images to be processed and optimized are used for training, 100 of the CT images to be processed and optimized are used for verification, and 100 of the CT images to be processed and optimized are used for testing. Figure 3 The figure shows a single CT image to be processed, which comes from 100 pairs of CT images to be processed and optimized CT images in the test row. The CT image processing model is written in Python language, based on PyTorch1.11.0 framework and GeForceRTX4080GPU. The number of training rounds is 200, the batch size of one training round is 32, and the initial learning rate is 0.0001.
[0031] The above are only preferred embodiments of the present invention. It should be pointed out that a person skilled in the art can make several modifications and improvements without departing from the inventive concept of the present invention, and these all fall within the protection scope of the present invention.
Claims
1. An optimization method for enhancing CT images, characterized in that: The following steps are involved: S1. CT image dataset preparation: multiple CT images are collected from existing public CT image libraries and CT image datasets as multiple optimized CT images. Blurring is performed on the multiple optimized CT images, including applying Gaussian blur, motion blur and 2x downsampling to reduce the clarity and quality of the multiple optimized CT images, to obtain multiple CT images to be processed, and corresponding to the multiple optimized CT images, to form a CT image dataset; S2, build a convolution group, including dynamic convolution and depth convolution; S3, construct a convolution group refined self-attention module, including convolution groups, root mean square normalization and weight matrix; S4, construct a skip connection module, including a convolution group and a ReLU activation function; S5, constructing an enhanced skip connection module, including a skip connection module and a convolution group; S6, construct a multi-stage processing module, including a convolution group, a convolution group refined self-attention module, and a strengthened skip connection module; S7. Construct a CT image processing model, including input, 3×3 convolution, 2x downsampling, transposed convolution, multi-order processing modules and output; S8. Training and application of CT image processing model. Use CT image dataset to train CT image processing model. After training, input a single CT image to be processed into the CT image processing model to obtain a single optimized CT image.
2. The optimization method for enhancing CT images according to claim 1, characterized in that: In step S2, for the convolution group, given the input feature F GCIn , F GCIn ∈R H×W×C , R represents the real number domain, H, W and C represent the input features F GCIn The height, width and channel of , and then obtain the feature F GCOut , F GCOut ∈R H×W×C , feature F GCOut And the input features F GCIn The dimensions of F GCOut =DWC 3×3 (ConCat(DC 3×3 (DC 1×1 (F GCIn )), DWC 1×1 (F GCIn ))), where DC 1×1 Represents 1×1 dynamic convolution, DC 3×3 Represents 3×3 dynamic convolution, DWC 1×1 Represents 1×1 depthwise convolution, DWC 3×3 represents 3×3 depth convolution, COncat represents concatenation in the channel dimension, and feature F GCOut is the output of the convolutional group.
3. The optimization method for enhancing CT images according to claim 1, characterized in that: In step S3, for the convolution group refinement self-attention module, given the input feature F GCRSAIn , F GCRSAIn ∈R H×W×C , R represents the real number domain, H, W and C represent the input features F GCRSAIn The height, width and channel of the first feature F GCRSA1 , F GCRSA1 =GConv1(RMSNorm(F GCRSAIn )), where GConv1 represents the first convolution group, RMSNorm represents root mean square normalization, and then obtains the query Q, key K and value V, Q = W Q (F GCRSA1 ), K=W K (F GCRSA1 ), V = W V (F GCRSA1 ), W Q , W K and W V There are three different weight matrices, implemented by three independent linear layers, and then the feature F is calculated GCRSA2 , K T represents the matrix transpose of the key K, Represents the scaling factor, Softmax represents the Softmax activation function, and then obtains the feature F GCRSA3 , F GCRSA3 =GConv2(F GCRSA2 V), GConv2 represents the second convolution group, and then calculates the secondary value V2, is the weight matrix implemented by the linear layer, and then calculates the feature F GCRSA4 , F GCRSA4 =F GCRSA2 V2, and then get the feature F GCRSAOut , F GCRSAOut ∈R H×W×C , feature F GCRSAOut And the input features F GCRSAIn The dimensions of F GCRSAOut =GConv3(RMSNorm(Drop(F GCRSA4 )))+F GCRSA3 , where Drop represents random dropout, GConv3 represents the third convolution group, RMSNorm represents root mean square normalization, + represents element-wise addition, and feature F GCRSAOut is the output of the convolutional group refined self-attention module.
4. The optimization method for enhancing CT images according to claim 1, characterized in that: In step S4, for the skip connection module, given the input main feature F DCMIn and input sub-feature F SCSIn , F DCMIn ∈R H×W×C , F SCSIn ∈R H×W×C , R represents the real number domain, H, W and C represent the input main features F DCMIn and input sub-feature F SCSIn The height, width and channel of , and then get the main output feature F SCMOut and the secondary output feature F SCSOut , F SCMOut ∈R H×W×C , F SCSOut ∈R H×W×C , the main output feature F SCMOut , secondary output feature F SCSOut , input main feature F SCMIn and input sub-feature F SCSIn The dimensions of these four features are consistent, F SCMOut =GConv2(Concat(ReLU(CA1(GConv1(F SCMIn ))), F SCSIn )), F SCSOut =CA2(GConv3(F SCMIn ))+F SCSIn , where GConv1 represents the first convolution group, GConv2 represents the second convolution group, GConv3 represents the third convolution group, CA1 represents the first channel attention, CA2 represents the second channel attention, ReLU represents the ReLU activation function, Concat represents concatenation in the channel dimension, + represents element-by-element addition, and the main output feature F SCMOut and the secondary output feature F SCSOut are the two output features of the skip connection module.
5. The optimization method for enhancing CT images according to claim 1, characterized in that: In step S5, for the enhanced skip connection module, given the input main feature F DSCMIn and input sub-feature F DSCSIn , F DSCMIn ∈R H ×W×C , F DDCSIn ∈R H×W×C , R represents the real number domain, H, W and C represent the input main features F DSCMIn and input sub-feature F DSCSIn The height, width and channel of the input main feature F DSCMIn and input sub-feature F DSCSIn Input to the first skip connection module to obtain the main feature F DDCM1 and sub-feature F DDCS1 , input the main feature F DDCMIn Corresponding to the input main feature of the first jump connection module input, the input main feature F SCMIn The input secondary feature corresponding to the first jump connection module input, the main feature F DSCM1 Corresponding to the main output feature of the first jump connection module output, the secondary feature F DSCD1 Corresponding to the secondary output feature of the first jump connection module output, the main feature F DSCM1 and sub-feature F DSCS1 Concatenate in the channel dimension and input into the convolution group to obtain feature F DSC1 , F DSC1 ∈R H ×W×2C , 2C represents 2 times C, and then the feature F DSC1 Split in half in the channel dimension to obtain the optimized main feature F DSCM2 and optimize the secondary feature F DSCS2 , and then optimize the main feature F DSCM2 and optimize the secondary feature F DSCS2 Input to the second skip connection module to get the output main feature F DSCMOut And output sub-feature F DSCSOu , optimize the main feature F DSCM2 Corresponding to the input main feature of the second jump connection module input, optimize the secondary feature F DSCS2 Corresponding to the input secondary feature of the second jump connection module input, the output main feature F DSCMOut Corresponding to the main output feature of the second jump connection module output, the output secondary feature F DSCSOu Corresponding to the secondary output feature output by the first jump connection module, the main feature F is output DSCMOut And output sub-feature F DSCSOu are the two output features of the enhanced skip connection module.
6. The optimization method for enhancing CT images according to claim 1, characterized in that: In step S6, for the multi-stage processing module, given the input feature F MSIn , F MSIn ∈R H×W×C , R represents the real number domain, H, W and C represent the input features F MSIn The height, width and channel of the first feature F MSm1 and feature F MSa1 , F MSm1 ∈R H×W×C , F MSa1 ∈R H×W×C , F MSm1 , F MSa1 =DSC1(GCRSA1(GeLU(CBAM(GConv1(F MSIn )))))), where CBAM represents spatial and channel attention, GeLU represents GeLU activation function, GCOnv1 represents the first convolution group, GCRSA1 represents the first convolution group refined self-attention module, DSC1 represents the first enhanced skip connection module, and the input main feature and input secondary feature of the first enhanced skip connection module DSC1 are both feature F MSmidf , feature F MSmidf By GCRSA1(GeLU(CBAM(GConv1(F MSIn ))))Get, feature F MDm1 The output main feature corresponding to the first enhanced skip connection module DSC1 output, feature F MSa1 Corresponding to the output sub-feature of the first enhanced skip connection module DSC1, the feature F is then obtained MSm1t , F MSm1t ∈R H×W×C , F MSm1t =GCRSA2(GeLU(GConv2(F MSm1 +F MSIn ))), GCOnv2 represents the second convolution group, + represents element-by-element addition, GCRSA2 represents the second convolution group refinement self-attention module, and then obtains the feature F MSm2 and feature F MSa2 , F MSm2 ∈R H×W×C , F MSa2 ∈R H×W×C , F MSm2 , F MSa2 =DSC2(F MSm1t , F MSa1 ), DSC2 represents the second enhanced skip connection module, feature F MSm1t The main input feature corresponding to the second enhanced skip connection module DSC2 input, feature F MSa1 Corresponding to the input sub-feature of the second enhanced skip connection module DSC2, feature F MSm2 The output main feature corresponding to the second enhanced skip connection module DSC2 output, feature F MSa2 Corresponding to the output sub-feature of the second enhanced skip connection module DSC2, we get feature F MSm2t , F MSm2t ∈R H×W×C , F MSm2t =GCRSA3(GeLU(GConv3(F MSm2 +F MSm1 ))), GCOnv3 represents the third convolution group, + represents element-by-element addition, GCRSA3 represents the third convolution group refinement self-attention module, and then obtains the feature F MSm3 and feature F MSa3 , F MSm3 ∈R H×W×C , F MSa3 ∈R H×W×C , F MSm3 , F MSa3 =DSC3(F MSm2t , F MSa2 ), DSC3 represents the third enhanced skip connection module, feature F MSm2t Corresponding to the main input feature of the third enhanced skip connection module DSC3, feature F MSa2 Corresponding to the input sub-feature of the third enhanced skip connection module DSC3, feature F MSm3 The output main feature corresponding to the output of the third enhanced skip connection module DSC3, feature F MSa3 The output sub-feature corresponding to the output of the third enhanced skip connection module DSC3, feature F MSm3 is the output of the multi-stage processing module, feature F MSm3 and the input features F of the multi-stage processing module MSIn The dimensions are consistent.
7. The optimization method for enhancing CT images according to claim 1, characterized in that: In step S7, for the CT image processing model, a single CT image to be processed I is input, I∈R h×w×3 , R represents the real number domain, h, W and 3 represent the height, width and channel of a single CT image I to be processed, and the single CT image I to be processed is input into the 2-fold downsampling to obtain the downsampled image I1, is half of h, It is half of W. The single CT image I to be processed is input into the first 3×3 convolution to obtain the feature F1. H1, W1 and C1 are the height, width and channel of feature F1. Feature F1 is input into the first multi-stage processing module to obtain feature F 11 , The downsampled image I1 is input into the second 3×3 convolution to obtain the feature F2. H2, W2 and C2 represent the height, width and channel of feature F2. Feature F2 is input into the second multi-stage processing module to obtain feature F 21 , The feature F 21 Input to the transposed convolution to get the feature F 21up , The feature F 21up and feature F 11 Add element by element to get the final feature F end , The final feature F end Input to the third 3×3 convolution to obtain a single optimized CT image I + , I + ∈R h×w×3 , single optimized CT image I + is the output of the CT image processing model.
Citation Information
Patent Citations
Face hallucination method and system of global-local separation attention mechanism
CN112070670A
Convolutional neural network based on four-branch attention mechanism, and image segmentation method
CN112949838A
Medical image automatic segmentation method based on deep learning
CN114066866A
CT image liver tumor area automatic segmentation method based on deep learning
CN114240962A
Brain tumor MRI image segmentation method based on mask attention mechanism
CN114972378A