A tumor segmentation method based on artificial intelligence
By constructing a multi-scale attention processing module and a multi-layer search algorithm to optimize hyperparameters, the problem of low tumor CT image segmentation accuracy is solved, achieving higher accuracy and sensitivity, reducing the misdiagnosis rate, and providing reliable auxiliary diagnosis. tool.
Patent Information
- Application Number
- CN202410930896.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-12
- Publication Date
- 2024-10-18
- Estimated Expiration
- 2044-07-12
AI Technical Summary
The existing technology has low segmentation accuracy for tumor CT images, especially due to the complex structure of the lesion, fuzzy boundaries, irregular shape, and connection with surrounding tissues, which leads to low segmentation accuracy.
Build a multi-scale attention processing module, fuse it to form an artificial intelligence model, and optimize hyperparameters through a multi-layer search algorithm to improve the accuracy and sensitivity of tumor segmentation.
It significantly improves the accuracy and detection efficiency of tumor segmentation, reduces the misdiagnosis rate, and provides a reliable auxiliary diagnostic tool.
Smart Images

Figure CN118485834B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of data processing, and in particular relates to a tumor segmentation method based on artificial intelligence. Background Art
[0002] At present, imaging examination is the most important means of screening tumors in clinical practice. For tumors, the most commonly used imaging examination method is computed tomography (CT). As a tomographic imaging technology, CT can image human tissue sections, clearly show the subtle differences in human tissue structure, and detect abnormal tissue through CT images. In addition, CT examination is more sensitive to high-density tissues and can observe the edges, size, location, etc. of abnormal tissues. At the same time, CT examination also has the advantages of short time and low cost. Therefore, CT is considered to be the most important examination method for tumors.
[0003] The problem of low segmentation accuracy is caused by the complex tissue structure, fuzzy boundaries, irregular shapes and different sizes of lesions in tumor CT images, and the lesions are usually connected to the surrounding fat and blood vessels. Summary of the invention
[0004] The present invention provides a tumor segmentation method based on artificial intelligence to solve the technical problem of low tumor segmentation accuracy in the prior art.
[0005] A tumor segmentation method based on artificial intelligence, comprising:
[0006] Constructing a first multi-scale attention processing module, a second multi-scale attention processing module, a third multi-scale attention processing module, a fourth multi-scale attention processing module, and a fifth multi-scale attention processing module;
[0007] fusing the first multi-scale attention processing module, the second multi-scale attention processing module, the third multi-scale attention processing module, the fourth multi-scale attention processing module, and the fifth multi-scale attention processing module to obtain an artificial intelligence model for segmenting tumors;
[0008] Initialize the loss function corresponding to the artificial intelligence model, and optimize the hyperparameters corresponding to the artificial intelligence model according to the loss function and using a multi-layer search algorithm to obtain an optimized artificial intelligence model;
[0009] A CT image of a tumor to be segmented is obtained, and the optimized artificial intelligence model is used to segment the CT image of the tumor to be segmented to obtain a tumor segmentation result.
[0010] Further, the first multi-scale attention processing module includes a first multi-scale convolution unit, a first weight-enhanced attention unit, a first cropping layer, a first splicing layer, a second multi-scale convolution unit, a second weight-enhanced attention unit and a third multi-scale convolution unit connected in sequence;
[0011] Among them, the output of the first weight-enhanced attention unit is used as the input of the second multi-scale attention processing module; the first cropping layer is used to crop a feature map of the same size as the feature map output by the second multi-scale attention processing module from the feature map output by the first weight-enhanced attention unit based on the center of the feature map output by the first weight-enhanced attention unit; the first splicing layer is used to splice the feature map output by the first cropping layer with the feature map output by the second multi-scale attention processing module.
[0012] Further, the second multi-scale attention processing module includes a first maximum pooling layer, a fourth multi-scale convolution unit, a third weight-enhanced attention unit, a second cropping layer, a second splicing layer, a fifth multi-scale convolution unit, a fourth weight-enhanced attention unit and a first deconvolution layer connected in sequence;
[0013] Among them, the output of the third weight-enhanced attention unit is used as the input of the third multi-scale attention processing module; the second cropping layer is used to crop a feature map with the same size as the feature map output by the third multi-scale attention processing module from the feature map output by the third weight-enhanced attention unit based on the center of the feature map output by the third weight-enhanced attention unit; the second splicing layer is used to splice the feature map output by the second cropping layer with the feature map output by the third multi-scale attention processing module.
[0014] Further, the third multi-scale attention processing module includes a second maximum pooling layer, a sixth multi-scale convolution unit, a fifth weight-enhanced attention unit, a third cropping layer, a third splicing layer, a seventh multi-scale convolution unit, a sixth weight-enhanced attention unit and a second deconvolution layer connected in sequence;
[0015] Among them, the output of the fifth weighted enhanced attention unit is used as the input of the fourth multi-scale attention processing module; the third cropping layer is used to crop a feature map with the same size as the feature map output by the fourth multi-scale attention processing module from the feature map output by the fifth weighted enhanced attention unit based on the center of the feature map output by the fifth weighted enhanced attention unit; the third splicing layer is used to splice the feature map output by the third cropping layer with the feature map output by the fourth multi-scale attention processing module.
[0016] Further, the fourth multi-scale attention processing module includes a third maximum pooling layer, an eighth multi-scale convolution unit, a seventh weight-enhanced attention unit, a fourth cropping layer, a fourth splicing layer, a ninth multi-scale convolution unit, an eighth weight-enhanced attention unit and a third deconvolution layer connected in sequence;
[0017] Among them, the output of the seventh weighted enhanced attention unit is used as the input of the fifth multi-scale attention processing module; the fourth cropping layer is used to crop a feature map with the same size as the feature map output by the fifth multi-scale attention processing module from the feature map output by the seventh weighted enhanced attention unit based on the center of the feature map output by the seventh weighted enhanced attention unit; the fourth splicing layer is used to splice the feature map output by the fourth cropping layer with the feature map output by the fifth multi-scale attention processing module.
[0018] Further, the fifth multi-scale attention processing module includes a fourth maximum pooling layer, a tenth multi-scale convolution unit, an eleventh multi-scale convolution unit and a fourth deconvolution layer connected in sequence;
[0019] The fourth maximum pooling layer takes the output of the seventh weighted enhanced attention unit as input, and the output of the fourth deconvolution layer serves as the input of the fourth splicing layer.
[0020] Further, the structures of the first multi-scale convolutional unit to the eleventh multi-scale convolutional unit are the same, and all include: a first convolutional layer, a second convolutional layer, a third convolutional layer, a fourth convolutional layer, a first batch of normalization layers, a second batch of normalization layers, a third batch of normalization layers, a fourth batch of normalization layers, a fifth convolutional layer, a mean pooling layer, a fifth batch of normalization layers, a sixth batch of normalization layers, and a fifth splicing layer;
[0021] The first convolution layer, the second convolution layer, the third convolution layer and the fourth convolution layer jointly receive external input, and the fifth splicing layer is used to splice and output the outputs of the first batch of normalization layers, the fifth batch of normalization layers, the sixth batch of normalization layers and the fourth batch of normalization layers in the channel dimension.
[0022] Furthermore, the structures of the first weighted enhanced attention unit to the eighth weighted enhanced attention unit are the same, and all include a global mean pooling layer, a first fully connected layer, a ReLU activation function layer, a second fully connected layer, a Sigmoid activation function layer, and a sixth splicing layer connected in sequence;
[0023] The global mean pooling layer is used to compress the H×W×C feature map into a 1×1×C feature map; wherein H represents the height of the feature map, W represents the width of the feature map, and C represents the dimension of the feature map;
[0024] The first fully connected layer is used to reduce the dimension of the 1×1×C feature map to a 1×1×C / r feature map; wherein r represents a parameter for dimensionality reduction;
[0025] The ReLU activation function layer is used for constructing the correlation between channels in the 1×1×C / r feature map;
[0026] The second fully connected layer is used to restore the feature map related to the activated channel to a 1×1×C feature map;
[0027] The Sigmoid activation function layer is used to activate the features of the 1×1×C feature map generated by the second fully connected layer in the channel dimension and generate the weight of each channel;
[0028] The sixth concatenation layer is used to weight the features in the feature map output by the Sigmoid activation function layer into the H×W×C feature map channel by channel through multiplication, so as to realize weight-enhanced attention processing.
[0029] Furthermore, the loss function is:
[0030]
[0031] in, represents the loss function, It represents the average brightness corresponding to the tumor segmentation result obtained by artificial intelligence model segmentation. represents the average brightness of the desired tumor segmentation result, represents the first random number less than 0.00001, represents a second random number less than 0.00001, It represents the brightness standard deviation corresponding to the tumor segmentation result obtained by artificial intelligence model segmentation. Represents the brightness standard deviation of the expected tumor segmentation result.
[0032] Furthermore, the hyperparameters corresponding to the artificial intelligence model are optimized according to the loss function and a multi-layer search algorithm is used to obtain an optimized artificial intelligence model, including:
[0033] A1. Initialize the hyperparameters corresponding to the artificial intelligence model, and form a vector with the initialized hyperparameters to obtain a hyperparameter vector;
[0034] A2. Repeatedly obtain multiple hyperparameter vectors;
[0035] A3. Determine the loss function corresponding to each hyperparameter vector according to the loss function;
[0036] A4. For each hyperparameter vector, an adaptive region exploration strategy is used to perform an adaptive search on each hyperparameter vector to obtain a hyperparameter vector after the adaptive search, including:
[0037] Determine the search scope to:
[0038]
[0039] in, represents the attenuation coefficient, Indicates t The search range during the sub-optimization process, Indicates t +1 The search range during the optimization process. The initial search range is set at the initial moment;
[0040] Determine whether the loss function value corresponding to the hyperparameter vector is less than or equal to its historical optimal loss function value. If so, keep the search step length unchanged. Otherwise, obtain the adaptive search step length according to the current optimization times:
[0041]
[0042] in, Indicates t The search step size in the optimization process, T represents the maximum optimization step size, Indicates t +1 The search step size during the process of calcification;
[0043] Based on the search range, the search position is determined as:
[0044]
[0045]
[0046] in, indicates the first search position, indicates the second search position, Indicates t The first optimization process i A vector of hyperparameters, i =1,2,…, I , I represents the total number of hyperparameter vectors; represents a search direction vector, the dimension of the search direction vector is the same as the dimension of the hyperparameter vector, and each dimension is a random number between (-1, 1);
[0047] Based on the adaptive search step size and search position, the hyperparameter vector is searched as follows:
[0048]
[0049] in, Represents the hyperparameter vector after adaptive search , represents the loss function corresponding to the first search position, represents the loss function corresponding to the second search position; sign represents the sign function. - When it is less than 0, it takes 1; when - If it is greater than 0, it takes -1, and otherwise takes 0;
[0050] A5. Re-obtaining the loss function value corresponding to the hyperparameter vector after the adaptive search, and determining the optimal hyperparameter vector according to the loss function value;
[0051] A6. According to the optimal hyperparameter vector, an information interaction strategy is used to conduct a guided balanced search on the hyperparameter vector after the adaptive search to obtain the hyperparameter vector after the balanced search, including:
[0052]
[0053]
[0054] in, Indicates t The first optimization process j The hyperparameter vector after adaptive search, j =1,2,…, I , Represents the hyperparameter vector In the t +1 for the amount of updates during the optimization process, Represents the hyperparameter vector after equilibrium search , represents the inertia weight, Represents the hyperparameter vector In the t The amount of updates during the optimization process, represents a random number uniformly distributed in [0,1], represents a random number uniformly distributed in [0,1], represents a random number uniformly distributed in [0,1], represents the interaction control factor; represents an elite vector, that is, any one of the vectors with the smallest loss function value, and and different; represents the mean vector corresponding to all hyperparameter vectors, represents the optimal hyperparameter vector;
[0055] A7. Use the reverse learning strategy to perform a global search on the hyperparameter vector after the balanced search, and use the greedy strategy to control the global search process to obtain the hyperparameter vector after the global search;
[0056] A8. Determine whether the current number of optimizations is greater than or equal to the maximum number of optimizations. If so, re-obtain the optimal hyperparameter vector and use the optimal hyperparameter vector as the final hyperparameter of the artificial intelligence model to obtain the optimized artificial intelligence model. Otherwise, return to step A3 for the next optimization.
[0057] The present invention provides an artificial intelligence-based tumor segmentation method, which constructs an efficient artificial intelligence model through image processing technology and machine learning algorithms. The artificial intelligence module can intelligently identify and segment tumors with higher accuracy and sensitivity than traditional methods. Then, a multi-layer search algorithm is used to optimize the hyperparameters corresponding to the artificial intelligence model, so that the artificial intelligence can accurately complete the segmentation task. In addition, by continuously updating and optimizing the detection algorithm, it can adapt to the identification needs of different types of tumors, significantly improve the detection efficiency and accuracy, and reduce the misdiagnosis rate, thereby providing a reliable auxiliary diagnostic tool. BRIEF DESCRIPTION OF THE DRAWINGS
[0058] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.
[0059] Figure 1 A flowchart of a tumor segmentation method based on artificial intelligence provided by an embodiment of the present invention.
[0060] Figure 2 A schematic diagram of the structure of an artificial intelligence model provided in an embodiment of the present invention.
[0061] Figure 3 A schematic diagram of the structures of the first to eleventh multi-scale convolution units provided in an embodiment of the present invention.
[0062] Figure 4 A schematic diagram of the structures of the first weight-enhanced attention unit to the eighth weight-enhanced attention unit provided in an embodiment of the present invention.
[0063] The above drawings have shown clear embodiments of the present invention, which will be described in more detail below. These drawings and text descriptions are not intended to limit the scope of the present invention in any way, but to illustrate the concept of the present invention for those skilled in the art by referring to specific embodiments. DETAILED DESCRIPTION
[0064] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present invention. Instead, they are merely examples of devices and methods consistent with some aspects of the present invention as detailed in the appended claims.
[0065] The embodiments of the present invention are described in detail below with reference to the accompanying drawings.
[0066] like Figure 1-4 As shown in the figure, the embodiment of the present invention provides a tumor segmentation method based on artificial intelligence, including:
[0067] S101, construct a first multi-scale attention processing module, a second multi-scale attention processing module, a third multi-scale attention processing module, a fourth multi-scale attention processing module and a fifth multi-scale attention processing module.
[0068] In response to the problem of low accuracy in tumor CT image segmentation in the prior art, an embodiment of the present invention constructs a first multi-scale attention processing module, a second multi-scale attention processing module, a third multi-scale attention processing module, a fourth multi-scale attention processing module, and a fifth multi-scale attention processing module. These multi-scale attention processing modules can be used to enhance the feature extraction effect and extract spatial features of lesions at different scales in tumor CT images, thereby enriching the diversity of the feature space and improving the segmentation accuracy.
[0069] S102, fusing the first multi-scale attention processing module, the second multi-scale attention processing module, the third multi-scale attention processing module, the fourth multi-scale attention processing module and the fifth multi-scale attention processing module to obtain an artificial intelligence model for segmenting tumors.
[0070] It is worth noting that in addition to the artificial intelligence model constructed by the embodiment of the present invention, other segmentation models can also be used, and the multi-layer search algorithm provided by the embodiment of the present invention can be used to search the segmentation model, which can also improve the segmentation accuracy to a certain extent.
[0071] S103, initializing a loss function corresponding to the artificial intelligence model, and optimizing the hyperparameters corresponding to the artificial intelligence model according to the loss function and using a multi-layer search algorithm to obtain an optimized artificial intelligence model;
[0072] In the existing optimization algorithms, the hyperparameter optimization capability is poor, resulting in low segmentation accuracy. In order to achieve higher segmentation accuracy, the embodiment of the present invention provides a multi-layer search algorithm to optimize the artificial intelligence model, thereby improving the effect of parameter optimization.
[0073] S104: Acquire a CT image of the tumor to be segmented, and use the optimized artificial intelligence model to segment the CT image of the tumor to be segmented to obtain a tumor segmentation result.
[0074] The tumor CT image may be a chest CT image, a brain CT image, etc. By segmenting the tumor CT image to be segmented using an optimized artificial intelligence model, the accuracy of tumor segmentation can be effectively improved.
[0075] The present invention provides an artificial intelligence-based tumor segmentation method, which constructs an efficient artificial intelligence model through image processing technology and machine learning algorithms. The artificial intelligence module can intelligently identify and segment tumors with higher accuracy and sensitivity than traditional methods. Then, a multi-layer search algorithm is used to optimize the hyperparameters corresponding to the artificial intelligence model, so that the artificial intelligence can accurately complete the segmentation task. In addition, by continuously updating and optimizing the detection algorithm, it can adapt to the identification needs of different types of tumors, significantly improve the detection efficiency and accuracy, and reduce the misdiagnosis rate, thereby providing a reliable auxiliary diagnostic tool.
[0076] like Figure 2 As shown, an embodiment of the present invention provides a structural diagram of an artificial intelligence model, and the specific structure is described as follows.
[0077] In an embodiment of the present invention, the first multi-scale attention processing module includes a first multi-scale convolution unit, a first weight-enhanced attention unit, a first cropping layer, a first splicing layer, a second multi-scale convolution unit, a second weight-enhanced attention unit, and a third multi-scale convolution unit connected in sequence;
[0078] Among them, the output of the first weight-enhanced attention unit is used as the input of the second multi-scale attention processing module; the first cropping layer is used to crop a feature map of the same size as the feature map output by the second multi-scale attention processing module from the feature map output by the first weight-enhanced attention unit based on the center of the feature map output by the first weight-enhanced attention unit; the first splicing layer is used to splice the feature map output by the first cropping layer with the feature map output by the second multi-scale attention processing module.
[0079] In an embodiment of the present invention, the second multi-scale attention processing module includes a first maximum pooling layer, a fourth multi-scale convolution unit, a third weight-enhanced attention unit, a second concatenation layer, a fifth multi-scale convolution unit, a fourth weight-enhanced attention unit, and a first deconvolution layer connected in sequence;
[0080] Among them, the output of the third weight-enhanced attention unit is used as the input of the third multi-scale attention processing module; the second cropping layer is used to crop a feature map with the same size as the feature map output by the third multi-scale attention processing module from the feature map output by the third weight-enhanced attention unit based on the center of the feature map output by the third weight-enhanced attention unit; the second splicing layer is used to splice the feature map output by the second cropping layer with the feature map output by the third multi-scale attention processing module.
[0081] In an embodiment of the present invention, the third multi-scale attention processing module includes a second maximum pooling layer, a sixth multi-scale convolution unit, a fifth weight-enhanced attention unit, a third cropping layer, a third splicing layer, a seventh multi-scale convolution unit, a sixth weight-enhanced attention unit and a second deconvolution layer connected in sequence;
[0082] Among them, the output of the fifth weighted enhanced attention unit is used as the input of the fourth multi-scale attention processing module; the third cropping layer is used to crop a feature map with the same size as the feature map output by the fourth multi-scale attention processing module from the feature map output by the fifth weighted enhanced attention unit based on the center of the feature map output by the fifth weighted enhanced attention unit; the third splicing layer is used to splice the feature map output by the third cropping layer with the feature map output by the fourth multi-scale attention processing module.
[0083] In an embodiment of the present invention, the fourth multi-scale attention processing module includes a third maximum pooling layer, an eighth multi-scale convolution unit, a seventh weight-enhanced attention unit, a fourth cropping layer, a fourth splicing layer, a ninth multi-scale convolution unit, an eighth weight-enhanced attention unit, and a third deconvolution layer connected in sequence;
[0084] Among them, the output of the seventh weighted enhanced attention unit is used as the input of the fifth multi-scale attention processing module; the fourth cropping layer is used to crop a feature map with the same size as the feature map output by the fifth multi-scale attention processing module from the feature map output by the seventh weighted enhanced attention unit based on the center of the feature map output by the seventh weighted enhanced attention unit; the fourth splicing layer is used to splice the feature map output by the fourth cropping layer with the feature map output by the fifth multi-scale attention processing module.
[0085] In an embodiment of the present invention, the fifth multi-scale attention processing module includes a fourth maximum pooling layer, a tenth multi-scale convolution unit, an eleventh multi-scale convolution unit and a fourth deconvolution layer connected in sequence;
[0086] The fourth maximum pooling layer takes the output of the seventh weighted enhanced attention unit as input, and the output of the fourth deconvolution layer serves as the input of the fourth splicing layer.
[0087] In an embodiment of the present invention, data is downsampled through a maximum pooling layer to reduce the data dimension by half. After features are extracted through different multi-scale attention processing modules, up-sampled through a deconvolution layer to make the feature map output by each level the same size as the feature map output by the previous level (e.g., making the feature map output by the second multi-scale attention processing module the same size as the feature map output by the first multi-scale attention processing module). Through multi-scale feature extraction and fusion, the feature quantity can be effectively increased, thereby improving the segmentation accuracy.
[0088] like Figure 3 As shown, the structures of the first multi-scale convolutional unit to the eleventh multi-scale convolutional unit are the same, and all include: a first convolutional layer, a second convolutional layer, a third convolutional layer, a fourth convolutional layer, a first batch of normalization layers, a second batch of normalization layers, a third batch of normalization layers, a fourth batch of normalization layers, a fifth convolutional layer, a mean pooling layer, a fifth batch of normalization layers, a sixth batch of normalization layers, and a fifth splicing layer;
[0089] The first convolution layer, the second convolution layer, the third convolution layer and the fourth convolution layer jointly receive external input, and the fifth splicing layer is used to splice and output the outputs of the first batch of normalization layers, the fifth batch of normalization layers, the sixth batch of normalization layers and the fourth batch of normalization layers in the channel dimension.
[0090] Optionally, the sizes of the first convolution layer, the second convolution layer and the third convolution layer are set to 1×1, and the sizes of the fourth convolution layer and the fifth convolution layer are set to 3×3.
[0091] As the network gets deeper during the encoding phase and the resolution of the feature map decreases after downsampling, the location information of some smaller lesions may be lost during feature extraction. Multi-scale convolution is used to increase the receptive field of the convolution kernel to extract features of the tumor at different scales, extract richer local information, and provide richer features for the decoding phase.
[0092] like Figure 4 As shown, the structures of the first weighted enhanced attention unit to the eighth weighted enhanced attention unit are the same, and all include a global mean pooling layer, a first fully connected layer, a ReLU activation function layer, a second fully connected layer, a Sigmoid activation function layer, and a sixth splicing layer connected in sequence;
[0093] The global mean pooling layer is used to compress the H×W×C feature map into a 1×1×C feature map; wherein H represents the height of the feature map, W represents the width of the feature map, and C represents the dimension of the feature map;
[0094] The first fully connected layer is used to reduce the dimension of the 1×1×C feature map to a 1×1×C / r feature map; wherein r represents a parameter for dimensionality reduction;
[0095] The ReLU activation function layer is used to construct the correlation between channels in the 1×1×C / r feature map;
[0096] The second fully connected layer is used to restore the feature map related to the activated channel to a 1×1×C feature map;
[0097] The Sigmoid activation function layer is used to activate the features of the 1×1×C feature map generated by the second fully connected layer in the channel dimension and generate the weight of each channel;
[0098] The sixth concatenation layer is used to weight the features in the feature map output by the Sigmoid activation function layer into the H×W×C feature map channel by channel through multiplication, so as to realize weight-enhanced attention processing.
[0099] Since multi-scale convolution enriches the feature space, the feature space may contain non-lesion features, which increases the difficulty of detecting lesions in the encoding stage, resulting in low segmentation accuracy. In addition, in clinical practice, lesions in tumor CT images are affected by surrounding fat, blood vessels and noise, which may lead to feature redundancy in the features extracted by multi-scale convolution kernels. The embodiment of the present invention proposes a weight-enhanced attention mechanism to reduce the dimension and weight the spatial features at different scales to enhance the weight of tumor features and improve the expressiveness of tumor features.
[0100] In this embodiment of the present invention, the loss function is:
[0101]
[0102] in, represents the loss function, It represents the average brightness corresponding to the tumor segmentation result obtained by artificial intelligence model segmentation. represents the average brightness of the desired tumor segmentation result, represents the first random number less than 0.00001, represents a second random number less than 0.00001, It represents the brightness standard deviation corresponding to the tumor segmentation result obtained by artificial intelligence model segmentation. Represents the brightness standard deviation of the expected tumor segmentation result.
[0103] It is worth noting that in addition to the above loss functions, the cross entropy loss function can also be introduced for supervised training.
[0104] In the existing optimization algorithms, the hyperparameter optimization capability is poor, resulting in low segmentation accuracy. In order to achieve higher segmentation accuracy, the embodiment of the present invention introduces a new hyperparameter optimization algorithm, which can not only achieve higher search efficiency but also improve search accuracy.
[0105] In an embodiment of the present invention, the hyperparameters corresponding to the artificial intelligence model are optimized according to the loss function and a multi-layer search algorithm is used to obtain an optimized artificial intelligence model, including:
[0106] A1. Initialize the hyperparameters corresponding to the artificial intelligence model, and form a vector with the initialized hyperparameters to obtain a hyperparameter vector.
[0107] For example, the random initialization method can be used to randomly initialize the hyperparameters corresponding to the artificial intelligence model (such as the connection weights and thresholds between network layers) between the upper and lower limits of the hyperparameters. In order to further improve the convergence speed of the algorithm, the chaotic search strategy can also be used to optimize the hyperparameters corresponding to the artificial intelligence model, thereby improving the search speed.
[0108] A2. Repeatedly obtain multiple hyperparameter vectors;
[0109] A3. Determine the loss function corresponding to each hyperparameter vector according to the loss function;
[0110] A4. For each hyperparameter vector, an adaptive region exploration strategy is used to perform an adaptive search on each hyperparameter vector to obtain a hyperparameter vector after the adaptive search, including:
[0111] Determine the search scope to:
[0112]
[0113] in, represents the attenuation coefficient (such as 0.95), Indicates t The search range during the sub-optimization process, Indicates t +1 The search range during the optimization process. The initial search range is set at the initial moment;
[0114] In the early stage of the algorithm, a larger search range is needed, so a larger search range can be set so that the hyperparameter vector can be searched in a large range within its neighborhood, thereby improving the search efficiency. In the later stage of the algorithm, the search range is gradually reduced through the attenuation coefficient, thereby improving the search accuracy.
[0115] Determine whether the loss function value corresponding to the hyperparameter vector is less than or equal to its historical optimal loss function value. If so, keep the search step length unchanged. Otherwise, obtain the adaptive search step length according to the current optimization times:
[0116]
[0117] in, Indicates t The search step size in the optimization process, T represents the maximum optimization step size, Indicates t +1 The search step size during the process of calcification;
[0118] When the loss function value corresponding to the hyperparameter vector is less than or equal to its historical optimal loss function value, it proves that the search performance is good at this time, so the search can be performed with the default step size. Otherwise, the search step size needs to be updated to reduce the step size factor to increase the convergence speed. At the same time, it also ensures that as the algorithm iterates, the step size gradually decreases as it approaches the optimal value to improve the accuracy of the algorithm.
[0119] Based on the search range, the search position is determined as:
[0120]
[0121]
[0122] in, indicates the first search position, indicates the second search position, Indicates t The first optimization process i A vector of hyperparameters, i =1,2,…, I , I represents the total number of hyperparameter vectors; represents a search direction vector, the dimension of the search direction vector is the same as the dimension of the hyperparameter vector, and each dimension is a random number between (-1, 1);
[0123] Based on the adaptive search step size and search position, the hyperparameter vector is searched as follows:
[0124]
[0125] in, Represents the hyperparameter vector after adaptive search , represents the loss function corresponding to the first search position, represents the loss function corresponding to the second search position; sign represents the sign function. - When it is less than 0, it takes 1; when - If it is greater than 0, it takes -1, and otherwise takes 0;
[0126] By searching the location within the neighborhood of the hyperparameter vector and searching towards a better location, the search efficiency of the algorithm within the neighborhood can be effectively improved and the search accuracy can be improved.
[0127] A5. Re-obtaining the loss function value corresponding to the hyperparameter vector after the adaptive search, and determining the optimal hyperparameter vector according to the loss function value;
[0128] A6. According to the optimal hyperparameter vector, an information interaction strategy is used to conduct a guided balanced search on the hyperparameter vector after the adaptive search to obtain the hyperparameter vector after the balanced search, including:
[0129]
[0130]
[0131] in, Indicates t The first optimization process j The hyperparameter vector after adaptive search, j =1,2,…, I , Represents the hyperparameter vector In the t +1 for the amount of updates during the optimization process, Represents the hyperparameter vector after equilibrium search , represents the inertia weight, Represents the hyperparameter vector In the t The amount of updates during the optimization process, represents a random number uniformly distributed in [0,1], represents a random number uniformly distributed in [0,1], represents a random number uniformly distributed in [0,1], represents the interaction control factor; represents an elite vector, that is, any one of the vectors with the smallest loss function value, and and different; represents the mean vector corresponding to all hyperparameter vectors, represents the optimal hyperparameter vector;
[0132] The information interaction strategy provided by the embodiment of the present invention can effectively utilize other vector information, overall information and optimal position information for interaction, so that while effectively exploring unknown areas, it can perform certain global optimization, improve the global search capability, and ensure convergence accuracy.
[0133] A7. Use the reverse learning strategy to perform a global search on the hyperparameter vector after the balanced search, and use the greedy strategy to control the global search process to obtain the hyperparameter vector after the global search;
[0134] Although the above achieves a certain degree of global search, it is not possible to achieve a more comprehensive global search in the solution space, and it is usually easy to fall into the local optimum during the high-dimensional parameter solution process. Therefore, the embodiment of the present invention first learns the reverse position of each vector through the reverse learning strategy, and then uses the greedy strategy to control the global search process, that is, if the loss function value decreases, the reverse learning is retained, otherwise the reverse learning is rejected.
[0135] A8. Determine whether the current number of optimizations is greater than or equal to the maximum number of optimizations. If so, re-obtain the optimal hyperparameter vector and use the optimal hyperparameter vector as the final hyperparameter of the artificial intelligence model to obtain the optimized artificial intelligence model. Otherwise, return to step A3 for the next optimization.
[0136] It should be understood by those skilled in the art that the embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes. The solutions in the embodiments of the present invention may be implemented in various computer languages, for example, object-oriented programming language Java and interpreted scripting language JavaScript, etc.
[0137] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0138] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0139] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0140] Although the preferred embodiments of the present invention have been described, those skilled in the art may make other changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the present invention.
[0141] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.
Claims
1. A tumor segmentation method based on artificial intelligence, characterized in that: include: Constructing a first multi-scale attention processing module, a second multi-scale attention processing module, a third multi-scale attention processing module, a fourth multi-scale attention processing module, and a fifth multi-scale attention processing module; fusing the first multi-scale attention processing module, the second multi-scale attention processing module, the third multi-scale attention processing module, the fourth multi-scale attention processing module, and the fifth multi-scale attention processing module to obtain an artificial intelligence model for segmenting tumors; Initialize the loss function corresponding to the artificial intelligence model, and optimize the hyperparameters corresponding to the artificial intelligence model according to the loss function and using a multi-layer search algorithm to obtain an optimized artificial intelligence model; Acquire a CT image of a tumor to be segmented, and use an optimized artificial intelligence model to segment the CT image of the tumor to be segmented to obtain a tumor segmentation result; The first multi-scale attention processing module includes a first multi-scale convolution unit, a first weight-enhanced attention unit, a first cropping layer, a first splicing layer, a second multi-scale convolution unit, a second weight-enhanced attention unit, and a third multi-scale convolution unit connected in sequence; The output of the first weight-enhanced attention unit is used as the input of the second multi-scale attention processing module; the first cropping layer is used to crop a feature map of the same size as the feature map output by the second multi-scale attention processing module from the feature map output by the first weight-enhanced attention unit based on the center of the feature map output by the first weight-enhanced attention unit; the first splicing layer is used to splice the feature map output by the first cropping layer with the feature map output by the second multi-scale attention processing module; The second multi-scale attention processing module includes a first maximum pooling layer, a fourth multi-scale convolution unit, a third weight-enhanced attention unit, a second cropping layer, a second splicing layer, a fifth multi-scale convolution unit, a fourth weight-enhanced attention unit and a first deconvolution layer connected in sequence; The output of the third weighted enhanced attention unit is used as the input of the third multi-scale attention processing module; the second cropping layer is used to crop a feature map of the same size as the feature map output by the third multi-scale attention processing module from the feature map output by the third weighted enhanced attention unit based on the center of the feature map output by the third weighted enhanced attention unit; the second splicing layer is used to splice the feature map output by the second cropping layer with the feature map output by the third multi-scale attention processing module; The third multi-scale attention processing module includes a second maximum pooling layer, a sixth multi-scale convolution unit, a fifth weight-enhanced attention unit, a third cropping layer, a third splicing layer, a seventh multi-scale convolution unit, a sixth weight-enhanced attention unit and a second deconvolution layer connected in sequence; The output of the fifth weighted enhanced attention unit is used as the input of the fourth multi-scale attention processing module; the third cropping layer is used to crop a feature map of the same size as the feature map output by the fourth multi-scale attention processing module from the feature map output by the fifth weighted enhanced attention unit based on the center of the feature map output by the fifth weighted enhanced attention unit; the third splicing layer is used to splice the feature map output by the third cropping layer with the feature map output by the fourth multi-scale attention processing module; The fourth multi-scale attention processing module includes a third maximum pooling layer, an eighth multi-scale convolution unit, a seventh weight-enhanced attention unit, a fourth cropping layer, a fourth splicing layer, a ninth multi-scale convolution unit, an eighth weight-enhanced attention unit and a third deconvolution layer connected in sequence; The output of the seventh weighted enhanced attention unit is used as the input of the fifth multi-scale attention processing module; the fourth cropping layer is used to crop a feature map of the same size as the feature map output by the fifth multi-scale attention processing module from the feature map output by the seventh weighted enhanced attention unit based on the center of the feature map output by the seventh weighted enhanced attention unit; the fourth splicing layer is used to splice the feature map output by the fourth cropping layer with the feature map output by the fifth multi-scale attention processing module; The fifth multi-scale attention processing module includes a fourth maximum pooling layer, a tenth multi-scale convolution unit, an eleventh multi-scale convolution unit and a fourth deconvolution layer connected in sequence; The fourth maximum pooling layer uses the output of the seventh weighted enhanced attention unit as input, and the output of the fourth deconvolution layer serves as the input of the fourth splicing layer; The structures of the first multi-scale convolutional unit to the eleventh multi-scale convolutional unit are the same, and all include: a first convolutional layer, a second convolutional layer, a third convolutional layer, a fourth convolutional layer, a first batch of normalization layers, a second batch of normalization layers, a third batch of normalization layers, a fourth batch of normalization layers, a fifth convolutional layer, a mean pooling layer, a fifth batch of normalization layers, a sixth batch of normalization layers, and a fifth splicing layer; The first convolution layer, the second convolution layer, the third convolution layer and the fourth convolution layer jointly receive external input, and the fifth splicing layer is used to splice the outputs of the first batch of normalization layers, the fifth batch of normalization layers, the sixth batch of normalization layers and the fourth batch of normalization layers in the channel dimension and output them; The structures of the first weighted enhanced attention unit to the eighth weighted enhanced attention unit are the same, and all include a global mean pooling layer, a first fully connected layer, a ReLU activation function layer, a second fully connected layer, a Sigmoid activation function layer, and a sixth splicing layer connected in sequence; The global mean pooling layer is used to compress the H×W×C feature map into a 1×1×C feature map; wherein H represents the height of the feature map, W represents the width of the feature map, and C represents the dimension of the feature map; The first fully connected layer is used to reduce the dimension of the 1×1×C feature map to a 1×1×C / r feature map; wherein r represents a parameter for dimensionality reduction; The ReLU activation function layer is used for constructing the correlation between channels in the 1×1×C / r feature map; The second fully connected layer is used to restore the feature map related to the activated channel to a 1×1×C feature map; The Sigmoid activation function layer is used to activate the features of the 1×1×C feature map generated by the second fully connected layer in the channel dimension and generate the weight of each channel; The sixth concatenation layer is used to weight the features in the feature map output by the Sigmoid activation function layer into the H×W×C feature map channel by channel through multiplication, so as to realize weight-enhanced attention processing.
2. The tumor segmentation method based on artificial intelligence according to claim 1, characterized in that: The loss function is: in, represents the loss function, It represents the average brightness corresponding to the tumor segmentation result obtained by artificial intelligence model segmentation. represents the average brightness of the desired tumor segmentation result, represents the first random number less than 0.00001, represents a second random number less than 0.00001, It represents the brightness standard deviation corresponding to the tumor segmentation result obtained by artificial intelligence model segmentation. Represents the brightness standard deviation of the expected tumor segmentation result.
3. The tumor segmentation method based on artificial intelligence according to claim 2, characterized in that: According to the loss function and using a multi-layer search algorithm, the hyperparameters corresponding to the artificial intelligence model are optimized to obtain an optimized artificial intelligence model, including: A1. Initialize the hyperparameters corresponding to the artificial intelligence model, and form a vector with the initialized hyperparameters to obtain a hyperparameter vector; A2. Repeatedly obtain multiple hyperparameter vectors; A3. Determine the loss function corresponding to each hyperparameter vector according to the loss function; A4. For each hyperparameter vector, an adaptive region exploration strategy is used to perform an adaptive search on each hyperparameter vector to obtain a hyperparameter vector after the adaptive search, including: Determine the search scope to: in, represents the attenuation coefficient, Indicates t The search range during the sub-optimization process, Indicates t +1 The search range during the optimization process. The initial search range is set at the initial moment; Determine whether the loss function value corresponding to the hyperparameter vector is less than or equal to its historical optimal loss function value. If so, keep the search step length unchanged. Otherwise, obtain the adaptive search step length according to the current optimization times: in, Indicates t The search step size in the optimization process, T represents the maximum optimization step size, Indicates t +1 The search step size during the process of calcification; Based on the search range, the search position is determined as: in, indicates the first search position, indicates the second search position, Indicates t The first optimization process i A vector of hyperparameters, i =1,2,…, I , I represents the total number of hyperparameter vectors; represents a search direction vector, the dimension of the search direction vector is the same as the dimension of the hyperparameter vector, and each dimension is a random number between (-1, 1); Based on the adaptive search step size and search position, the hyperparameter vector is searched as follows: in, Represents the hyperparameter vector after adaptive search , represents the loss function corresponding to the first search position, represents the loss function corresponding to the second search position; sign represents the sign function. - When it is less than 0, it takes 1; when - If it is greater than 0, it takes -1, and otherwise takes 0; A5. Re-obtaining the loss function value corresponding to the hyperparameter vector after the adaptive search, and determining the optimal hyperparameter vector according to the loss function value; A6. According to the optimal hyperparameter vector, an information interaction strategy is used to conduct a guided balanced search on the hyperparameter vector after the adaptive search to obtain the hyperparameter vector after the balanced search, including: in, Indicates t The first optimization process j The hyperparameter vector after adaptive search, j =1,2,…, I , Represents the hyperparameter vector In the t +1 for the amount of updates during the optimization process, Represents the hyperparameter vector after equilibrium search , represents the inertia weight, Represents the hyperparameter vector In the t The amount of updates during the optimization process, represents a random number uniformly distributed in [0,1], represents a random number uniformly distributed in [0,1], represents a random number uniformly distributed in [0,1], represents the interaction control factor; represents an elite vector, that is, any one of the vectors with the smallest loss function value, and and different; represents the mean vector corresponding to all hyperparameter vectors, represents the optimal hyperparameter vector; A7. Use the reverse learning strategy to perform a global search on the hyperparameter vector after the balanced search, and use the greedy strategy to control the global search process to obtain the hyperparameter vector after the global search; A8. Determine whether the current number of optimizations is greater than or equal to the maximum number of optimizations. If so, re-obtain the optimal hyperparameter vector and use the optimal hyperparameter vector as the final hyperparameter of the artificial intelligence model to obtain the optimized artificial intelligence model. Otherwise, return to step A3 for the next optimization.
Citation Information
Patent Citations
Endoscopic OCT image segmentation method and device for colorectal tumor, medium and product
CN115272283A
