Machine learning-based early-stage liver cancer microlesion recognition method
By using a hierarchical guided large-kernel attention D-LKA network and a structural consistency sub-pixel feature fusion interpolation module, the problem of identifying small liver cancer lesions in complex backgrounds was solved, achieving high-precision lesion separation and boundary reconstruction, and improving the accuracy and precision of identification.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- THE FIRST PEOPLES HOSPITAL OF NANTONG
- Filing Date
- 2026-03-05
- Publication Date
- 2026-06-09
AI Technical Summary
Existing technologies are easily affected by background tissues of the liver parenchyma in the identification of small lesions of liver cancer, leading to missed or false detections. Furthermore, the lesion classification results and spatial reconstruction results lack unified constraints, making it difficult to simultaneously ensure accuracy and precision in complex backgrounds.
A hierarchical guided macrokernel attention D-LKA network encoder and a structural consistency subpixel feature fusion interpolation module are adopted. Through multi-level guidance and adaptive macrokernel receptive field modeling, the attention range is dynamically adjusted. Combined with cross-scale residual connections and subpixel-level reconstruction, high-precision identification and boundary reconstruction of lesion features are achieved.
It significantly improves the separation performance of small lesions with low contrast in complex backgrounds, reduces the probability of misdiagnosis and missed detection, and achieves high-precision reconstruction of lesion boundaries and accurate spatial positioning.
Smart Images

Figure CN122175912A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of liver cancer technology, and in particular to a method for identifying early-stage micro-lesions in liver cancer based on machine learning. Background Technology
[0002] Liver cancer is one of the malignant tumors with high incidence and mortality rates in clinical practice. Early-stage liver cancer often exists as small, irregularly shaped, and low-contrast lesions. Accurate identification of these lesions in medical imaging is of great significance for early clinical screening, diagnostic decision-making, and treatment planning. Currently, computed tomography (CT), magnetic resonance imaging (MRI), and their contrast-enhanced sequences have become the main imaging methods for liver cancer screening and follow-up. However, due to limitations in imaging physical characteristics and clinical acquisition conditions, medical images often suffer from limited resolution, significant noise interference, and incomplete understanding of liver parenchyma texture.
[0003] In existing technologies, computer-aided diagnostic methods for liver cancer lesions are mostly based on traditional image processing algorithms or conventional deep learning models. They rely on local feature extraction or convolution operations with fixed receptive fields to analyze local areas in images. When liver cancer lesions are small in size and have low contrast, they are easily interfered with by the background tissue of the liver parenchyma, which weakens the features of the small lesions or even misjudges them as noise, resulting in missed or false detections.
[0004] Most existing liver cancer lesion identification methods mainly detect or segment lesions at the original pixel resolution. The spatial accuracy of the results is limited by the sampling resolution of medical images. When the lesion size is close to or smaller than the scale of a single pixel, even if the lesion can be detected, it is difficult to accurately express the true location, boundary shape and spatial range of the lesion, resulting in blurred lesion outlines and large positioning deviations, which affects clinicians' judgment of lesion size and shape.
[0005] In existing liver cancer lesion identification technologies, lesion classification results and spatial reconstruction results are usually independent of each other and lack a unified collaborative constraint mechanism. The classification results generated in the lesion discrimination stage are difficult to effectively constrain the spatial reconstruction process, and the spatial reconstruction results cannot provide effective feedback to the lesion discrimination model. This results in a lack of consistency between different stages in the overall identification process, making it difficult to simultaneously ensure the accuracy of lesion identification and the refinement of spatial representation in the context of complex liver tissue. Summary of the Invention
[0006] One objective of this invention is to propose a machine learning-based method for identifying early-stage small lesions in liver cancer. This invention significantly improves the separation performance of low-contrast small lesions in complex backgrounds.
[0007] A method for identifying early-stage small lesions of liver cancer based on machine learning according to an embodiment of the present invention includes:
[0008] Collect liver medical imaging data and preprocess it to obtain a standardized liver medical imaging tensor;
[0009] Standardized liver medical image tensors are input into a hierarchical large-kernel attention D-LKA network encoder to generate an initial global feature map.
[0010] A hierarchical guidance mask is constructed based on the initial global feature map. The hierarchical guidance mask and the initial global feature map are then multiplied element-wise in the big kernel attention operation to obtain the guidance enhancement global feature map.
[0011] Multi-scale channel reshaping and spatial aggregation are performed on the guided enhancement global feature map to form a multi-scale guided enhancement feature map. Then, cross-scale residual connection is used on the multi-scale guided enhancement feature map to retain the details of small lesions and output a fused enhancement feature map.
[0012] The fused and enhanced feature map is input into the structural consistency sub-pixel feature fusion interpolation module. The fused and enhanced feature map is rearranged and fused in multiple directions according to the sub-pixel level displacement vector to obtain the sub-pixel spatial representation vector.
[0013] Learnable interpolation reconstruction is performed on the sub-pixel spatial representation vector, and structure-preserving interpolation is performed on the sub-pixel spatial representation vector to obtain a high-precision reconstruction map of the lesion boundary. The high-precision reconstruction map of the lesion boundary and the fusion enhancement feature map are jointly optimized in the spatial consistency enhancement module to output a spatial consistency optimized feature map.
[0014] Spatial consistency optimization feature maps are used to calculate the difference between the feature maps and the initial lesion classification prediction maps in the recognition-reconstruction collaborative feedback loop, generating collaborative consistency loss information. The collaborative consistency loss information is then passed back to the hierarchical guided large kernel attention D-LKA network encoder to complete the end-to-end parameter update.
[0015] After the end-to-end parameter update converges, the final identification result image of small liver cancer lesions is output.
[0016] Optionally, the preprocessing includes grayscale normalization, noise suppression, and multi-scale resampling.
[0017] Optionally, the hierarchical guided large kernel attention D-LKA network encoder includes:
[0018] The input of a standardized liver medical image tensor is hierarchically guided by the input embedding mapping operator of the large kernel attention D-LKA network encoder to obtain the encoder input feature map;
[0019] Based on the encoder input feature map, a contrast-noise sensitivity feature map of small liver cancer lesions is constructed for each pixel coordinate.
[0020] In each coding layer of the hierarchical guided big kernel attention D-LKA network encoder, the output feature map of the previous layer is processed by downsampling and channel mapping operators to obtain the input feature map of the l-th layer;
[0021] Based on the contrast-noise sensitivity feature map of small liver cancer lesions in the previous layer, an adaptive set of large kernel parameters is generated for the large kernel attention mechanism of the l-th layer.
[0022] In the l-th layer, based on the adaptive large kernel parameter set, the input feature map of the l-th layer is subjected to large kernel depth convolution operation in the horizontal and vertical directions respectively. The convolution results in the two directions are added together to obtain the long-range context aggregation feature map of the l-th layer.
[0023] The long-range context aggregation feature map of the l-th layer is input into the pointwise convolution operator and the normalized activation operator to obtain the attention response feature map of the l-th layer.
[0024] For each pixel coordinate in the l-th layer, a consistency gating feature map of small lesions is constructed based on the contrast-noise sensitivity feature map of small liver cancer lesions in the previous layer and the input feature map of the l-th layer.
[0025] The input feature map of layer l is multiplied element-wise with the attention response feature map and the small lesion consistency gating feature map of layer l, respectively, and then added to the input feature map of layer l to obtain the output feature map of layer l.
[0026] Based on the output feature map of the l-th layer, update the contrast-noise sensitivity feature map of small liver cancer lesions in the next layer;
[0027] The output feature maps of all coding layers of the hierarchical guided large kernel attention D-LKA network encoder are spatially aligned and mapped to the same size as the standardized liver medical image tensor. Then, they are fused using an inter-layer aggregation operator to obtain the initial global feature map.
[0028] Optionally, the step of performing element-wise multiplication between the hierarchical guiding mask and the initial global feature map in the big kernel attention operation includes:
[0029] Based on the initial global feature map, a candidate response map for small liver cancer lesions is constructed for each pixel coordinate.
[0030] A hierarchical guidance mask was constructed based on the candidate response map of small lesions in liver cancer.
[0031] The hierarchical bootstrap mask is extended in the channel dimension so that the hierarchical bootstrap mask is completely consistent with the initial global feature map in terms of spatial size and the number of channels in the initial global feature map in terms of channel dimension, thus obtaining the hierarchical bootstrap mask tensor;
[0032] Before the big kernel attention computation, perform element-wise multiplication between the hierarchical guide mask tensor and the initial global feature map to obtain the mask guide feature map;
[0033] Perform large kernel attention operations on the mask-guided feature map to obtain a large kernel attention response feature map;
[0034] The masked guided feature map and the large kernel attention response feature map are multiplied element-wise to obtain the guided augmentation global feature map.
[0035] Optionally, the multi-scale channel reshaping and spatial aggregation of the guided enhancement global feature map includes:
[0036] A scale index set is constructed. For each scale number, the guided enhancement global feature map is linearly remapped and the channel group is rearranged in the channel dimension to obtain the channel remodeling feature map related to small lesions of liver cancer.
[0037] For each scale number, the corresponding channel reshaping feature map is spatially aggregated using spatial aggregation kernels with different coverage in the spatial dimension to obtain a spatially aggregated feature map.
[0038] By concatenating the spatial aggregated feature maps corresponding to all scale numbers along the channel dimension, a multi-scale guided enhancement feature map is obtained.
[0039] Establish cross-scale residual connections on the multi-scale guided augmentation feature map, and construct a scale-aligned residual feature map with the same spatial size as the multi-scale guided augmentation feature map for each scale index.
[0040] The scale-aligned residual feature maps under all scale numbers are residually fused with the multi-scale guided enhancement feature maps to obtain the fused enhancement feature map.
[0041] Optionally, the structural consistency sub-pixel feature fusion interpolation module includes:
[0042] Based on the fusion-enhanced feature map tensor, the structural consistency orientation field of small lesions is calculated, including the structural amplitude map, the structural gradient vector map, and the unit tangential vector map;
[0043] Based on the sub-pixel scale ratio, construct a sub-pixel grid index set and a basic sub-pixel level displacement vector set respectively;
[0044] The channel rearrangement of the fused enhanced feature map tensor is performed according to the sub-pixel scale ratio, and the information of the channel dimension is remapped to a higher resolution sub-pixel spatial grid to obtain the sub-pixel rearranged feature map.
[0045] On the sub-pixel rearrangement feature map, construct a set of directional unit vectors for multi-directional sub-pixel feature fusion;
[0046] For each pixel coordinate, calculate the sub-pixel direction step size coefficient, and combine the basic sub-pixel level displacement vector set with the direction unit vector set based on the sub-pixel direction step size coefficient to generate a structurally consistent sub-pixel level displacement vector set;
[0047] Enumerate all sub-pixel coordinates for each pixel coordinate, and arrange the sub-pixel level displacement vector set according to structural consistency on the sub-pixel rearranged feature map. Use bilinear interpolation to obtain directional sub-pixel features for each sub-pixel coordinate and its each direction sampling point.
[0048] Multi-directional fusion is performed on the sub-pixel features in each direction to obtain the sub-pixel spatial representation vector.
[0049] Optionally, the joint optimization of the high-precision reconstructed lesion boundary map and the fused enhanced feature map in the spatial consistency enhancement module includes:
[0050] The sub-pixel spatial representation vectors corresponding to the sub-pixel spatial coordinates are linearly weighted and summed in the channel dimension to obtain the initial reconstruction value of the lesion boundary in the sub-pixel spatial coordinates, and the initial reconstruction map of the lesion boundary is formed in the entire range of sub-pixel coordinates.
[0051] Along the set of structurally consistent sub-pixel level displacement vectors, the initial reconstruction map of the lesion boundary is sampled in the corresponding direction according to the structurally consistent sub-pixel level displacement. The sampling results in each direction are weighted and summed according to the structural consistency interpolation weight to obtain the high-precision reconstruction value of the lesion boundary corresponding to the sub-pixel spatial coordinates. The high-precision reconstruction value of the lesion boundary is calculated for all sub-pixel spatial coordinates in turn to obtain the high-precision reconstruction map of the lesion boundary.
[0052] The high-precision reconstructed image of the lesion boundary is downsampled and mapped in the spatial dimension according to the sub-pixel scale ratio to obtain the final lesion boundary alignment image with the spatial size of the fused and enhanced feature map.
[0053] Using the final lesion boundary alignment map at the corresponding location as a spatial consistency constraint factor, the feature values of each channel of the fused enhanced feature map are multiplied element-wise, and then weighted and superimposed with the final lesion boundary alignment map according to a specified ratio to obtain a spatial consistency optimized feature map.
[0054] Optionally, the step of calculating the difference between the spatial consistency optimization feature map and the initial lesion classification prediction map in the recognition-reconstruction collaborative feedback loop includes:
[0055] Based on the fusion-enhanced feature map, pixel-level lesion discrimination calculation is performed on the multi-channel features corresponding to each pixel coordinate in the fusion-enhanced feature map to obtain the initial lesion classification prediction map.
[0056] The spatial consistency optimization feature map is subjected to channel amplitude aggregation in the channel dimension and then normalized to obtain the spatial consistency response map.
[0057] The difference between the initial lesion classification prediction map and the spatial consistency response map is calculated pixel by pixel to obtain the collaborative consistency loss information.
[0058] The collaborative consistency loss information is used as the optimization objective and is backpropagated to the trainable parameter set of the hierarchical guided large kernel attention D-LKA network encoder. End-to-end parameter updates are completed for the parameter set after each round of parameter iteration.
[0059] Optionally, the output image showing the final identification result of small liver cancer lesions includes:
[0060] After the end-to-end parameter update is completed and convergence is achieved, pixel-level lesion discrimination calculation is performed on the multi-channel features corresponding to each pixel coordinate in the fused enhanced feature map based on the fused enhanced feature map, and the final lesion classification prediction map after convergence is obtained.
[0061] The high-precision reconstructed image of the lesion boundary is downsampled in the spatial dimension according to the sub-pixel scale ratio. The boundary reconstruction response values of all sub-pixel spatial positions are projected and mapped onto pixel coordinates that are consistent with the size of the standardized liver medical image tensor space to obtain the final lesion boundary alignment image.
[0062] Based on the converged final classification prediction map and final lesion boundary alignment map, the final identification result map of small liver cancer lesions is generated according to the pixel-level joint discrimination rule.
[0063] Based on the final identification result image of small liver cancer lesions, the location, outline, and spatial size information of the small liver cancer lesions are extracted.
[0064] Optionally, the pixel-level joint discrimination rule includes:
[0065] Read the final classification probability value of the lesion in the converged final lesion classification prediction map for each pixel coordinate corresponding to the standardized liver medical image tensor, and the boundary alignment response value in the final lesion boundary alignment map;
[0066] The final classification probability value of the lesion is compared with a pre-set final classification threshold for the lesion. When the final classification probability value of the lesion is greater than or equal to the final classification threshold for the lesion, the corresponding pixel coordinates are determined to meet the lesion classification consistency condition; otherwise, the corresponding pixel coordinates are determined not to meet the lesion classification consistency condition.
[0067] The boundary alignment response value is compared with a preset boundary alignment threshold. If the boundary alignment response value is greater than or equal to the boundary alignment threshold, the corresponding pixel coordinates are determined to meet the boundary structure consistency condition; otherwise, the corresponding pixel coordinates are determined not to meet the boundary structure consistency condition.
[0068] Only when the same pixel coordinates simultaneously meet the lesion classification consistency condition and the boundary structure consistency condition will the corresponding pixel coordinates be set as the lesion pixel in the final identification result image of small liver cancer lesions.
[0069] When the pixel coordinates do not simultaneously meet the consistency conditions for lesion classification and boundary structure, the corresponding pixel coordinates will be set as non-lesion pixels in the final identification result image of small liver cancer lesions.
[0070] The beneficial effects of this invention are:
[0071] (1) This invention adopts a hierarchical guided large kernel attention D-LKA network encoder. By guiding the standardized liver medical image tensor in multiple layers and adaptively modeling the large kernel receptive field, the model can cross a large range of liver tissue and jointly capture global structural information and small local abnormalities. In the encoding process, the contrast-noise sensitivity feature map of small lesions of liver cancer is introduced to dynamically drive the adaptive adjustment of the attention range of each layer. This effectively enhances the model's response to sub-pixel-level small lesions with weak contrast and easily interfered by the background of liver parenchyma, and reduces the probability of lesions being misjudged as noise or missed. Compared with traditional fixed receptive field or simple attention network, it has significantly improved the separation performance of low-contrast small lesions in complex background.
[0072] (2) This invention proposes a structural consistency sub-pixel feature fusion interpolation mechanism. By using the fusion enhancement feature map and its corresponding unit tangential vector, structural gradient and sensitivity information, the structural consistency sub-pixel level displacement vector and directional fusion weight are dynamically constructed to achieve sub-pixel level reconstruction of the boundary and spatial details of small lesions. In the interpolation process, not only multi-directional sampling is considered, but also spatial weight allocation is carried out according to the main structural direction and contrast sensitivity features of the small lesion. This effectively maintains the continuity and structural consistency of the true contour of the lesion. The generated high-precision reconstruction map of the lesion boundary can achieve fine contour depiction of lesions smaller than the pixel level under the original pixel resolution, significantly reducing spatial positioning error and overcoming the defect that traditional pixel-level segmentation schemes are difficult to achieve spatial accuracy breakthrough under the condition of limited medical image resolution. Attached Figure Description
[0073] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used in conjunction with embodiments of the invention to explain the invention and do not constitute a limitation thereof. In the drawings:
[0074] Figure 1 This is a flowchart of a machine learning-based method for identifying early-stage small lesions in liver cancer proposed in this invention.
[0075] Figure 2 This is a structural diagram of the hierarchical guided large kernel attention D-LKA network encoder in the machine learning-based early small lesion identification method for liver cancer proposed in this invention. Detailed Implementation
[0076] Example 1: Reference Figures 1-2 A machine learning-based method for identifying early-stage small lesions in liver cancer, comprising:
[0077] Collect liver medical imaging data and preprocess it to obtain a standardized liver medical imaging tensor;
[0078] In this embodiment, preprocessing includes grayscale normalization, noise suppression, and multi-scale resampling.
[0079] Standardized liver medical image tensors are input into a hierarchical large-kernel attention D-LKA network encoder to generate an initial global feature map.
[0080] In this embodiment, the hierarchical guided large-kernel attention D-LKA network encoder includes:
[0081] The input of a standardized liver medical image tensor is hierarchically guided by the input embedding mapping operator of the large kernel attention D-LKA network encoder to obtain the encoder input feature map;
[0082] In Example 1, multi-channel convolutional feature extraction based on small receptive fields is sequentially performed on the standardized liver medical image tensor. Channel dimension remapping is then performed on the convolutional feature extraction results to map the original image intensity information to a high-dimensional feature space. Spatial scale-preserving nonlinear activation transformation is then performed on the remapped features to output an encoder input feature map with the same spatial size as the standardized liver medical image tensor and an increased number of channels. The encoder input feature map serves as the basic feature representation for long-range context modeling of the hierarchical guided large kernel attention D-LKA network encoder.
[0083] Based on the encoder input feature map, a contrast-noise sensitivity feature map of small liver cancer lesions is constructed for each pixel coordinate.
[0084] The calculation method for the contrast-noise sensitivity feature map of small liver cancer lesions is as follows: A local neighborhood is established with the pixel coordinates as the center and a pixel-scale radius is selected. The encoder input feature maps of all pixels within the local neighborhood are statistically analyzed. The local neighborhood mean and local neighborhood standard deviation are calculated respectively. The absolute value of the difference between the encoder input feature map value of the current pixel and the local neighborhood mean is used as the numerator, and the local neighborhood standard deviation plus a positive constant is used as the denominator. This yields the contrast-noise sensitivity feature map value of the small liver cancer lesions at the corresponding pixel coordinates. This value is used to drive the hierarchical guided large-kernel attention D-LKA network encoder to perform long-range context modeling at the small lesion scale.
[0085] In each coding layer of the hierarchical guided big kernel attention D-LKA network encoder, the output feature map of the previous layer is processed by downsampling and channel mapping operators to obtain the input feature map of the l-th layer;
[0086] In Example 1, in the first coding layer, the output feature map of the previous layer is the encoder input feature map. In the second and subsequent coding layers, the output feature map of the previous layer is the output feature map of the previous coding layer. The spatial size of the input feature map of the l-th layer is the same as the height and width pixel count set in the l-th layer, and the number of channels is the same as the number of channels in the l-th layer.
[0087] Based on the contrast-noise sensitivity feature map of small liver cancer lesions in the previous layer, an adaptive set of large kernel parameters is generated for the large kernel attention mechanism of the l-th layer.
[0088] In Example 1, the sensitivity feature values of all pixel positions in the upper layer liver cancer micro lesion contrast-noise sensitivity feature map are statistically analyzed globally to obtain the global mean of the liver cancer micro lesion contrast-noise sensitivity feature map.
[0089] The global mean of the contrast-noise sensitivity feature map of small liver cancer lesions is linearly mapped to the pre-set kernel size mapping coefficient and expansion rate mapping coefficient, respectively. Based on the mapping results, the corresponding kernel size lower limit constant and expansion rate lower limit constant are superimposed to obtain the candidate kernel size value and candidate expansion rate value of the l-th layer large kernel convolution kernel. The kernel size lower limit constant is used to limit the minimum spatial coverage of the large kernel convolution kernel to ensure that the large kernel attention mechanism has at least the ability to sense across the local tissue structure of the liver. The expansion rate lower limit constant is used to limit the minimum expansion step size of the large kernel convolution kernel during spatial sampling.
[0090] The candidate kernel size values are subjected to odd-number constraint processing to ensure that the final kernel size parameter is odd. The kernel size parameter after odd-number constraint processing and the corresponding candidate expansion rate value are combined to form the adaptive large kernel parameter set of the l-th layer large kernel attention mechanism. When the global mean of the contrast-noise sensitivity feature map of the liver cancer small lesions in the previous layer is large, the l-th layer large kernel attention mechanism automatically adopts a larger spatial receptive range to enhance the modeling ability of the long-range context of small lesions. When the global mean of the contrast-noise sensitivity feature map of the liver cancer small lesions in the previous layer is small, the l-th layer large kernel attention mechanism automatically shrinks the spatial receptive range to suppress the interference of background noise on the identification of small lesions.
[0091] In the l-th layer, based on the adaptive large kernel parameter set, the input feature map of the l-th layer is subjected to large kernel depth convolution operation in the horizontal and vertical directions respectively. The convolution results in the two directions are added together to obtain the long-range context aggregation feature map of the l-th layer.
[0092] The long-range context aggregation feature map of the l-th layer is input into the pointwise convolution operator and the normalized activation operator to obtain the attention response feature map of the l-th layer.
[0093] For each pixel coordinate in the l-th layer, a consistency gating feature map of small lesions is constructed based on the contrast-noise sensitivity feature map of small liver cancer lesions in the previous layer and the input feature map of the l-th layer.
[0094] In Example 1, the amplitude of the input feature map of the l-th layer at each channel of the pixel coordinate is exponentially taken, and the normalized amplitude distribution is obtained by channel normalization. The channel entropy is calculated using the normalized amplitude distribution. The contrast-noise sensitivity feature map of the small lesions of liver cancer in the previous layer is multiplied by the gating mapping coefficient and the channel entropy is multiplied by another gating mapping coefficient. Then, the consistency gating feature map of the small lesions is obtained by normalizing the activation operator. This is used to achieve sensitivity enhancement and channel diffusion response suppression of similar tissues of liver parenchyma under weak contrast conditions.
[0095] The input feature map of layer l is multiplied element-wise with the attention response feature map and the small lesion consistency gating feature map of layer l, respectively, and then added to the input feature map of layer l to obtain the output feature map of layer l.
[0096] Based on the output feature map of the l-th layer, update the contrast-noise sensitivity feature map of small liver cancer lesions in the next layer;
[0097] For each pixel coordinate, a local neighborhood is constructed by selecting the pixel scale radius. The output feature map values of the l-th layer of all pixels in the local neighborhood are counted. The mean and standard deviation of the local neighborhood are calculated respectively. The absolute value of the difference between the output feature map value of the l-th layer of the current pixel and the mean of the local neighborhood is used as the numerator, and the standard deviation of the local neighborhood plus a positive constant is used as the denominator to obtain the contrast-noise sensitivity feature value of the next layer of liver cancer micro lesions at the corresponding pixel coordinate.
[0098] The output feature maps of all coding layers of the hierarchical guided large kernel attention D-LKA network encoder are spatially aligned and mapped to the same size as the standardized liver medical image tensor. Then, they are fused using an inter-layer aggregation operator to obtain the initial global feature map.
[0099] In Example 1, the operation rules of the inter-layer aggregation operator are as follows: the output feature maps of each coding layer in the hierarchical guided large kernel attention D-LKA network encoder are used as hierarchical feature sets. For each output feature map in the hierarchical feature set, the scale alignment operator corresponding to the output feature map is used to map its spatial size to the number of height pixels and width pixels consistent with the standardized liver medical image tensor, resulting in a set of spatially aligned feature maps. The spatially aligned feature maps are spliced in the channel dimension to form multi-level spliced feature maps. Then, channel compression mapping is performed on the multi-level spliced feature maps to map the number of spliced channels to the preset number of global feature channels, resulting in a channel-compressed fused feature map. The channel-compressed fused feature map is then subjected to pixel-wise weighted summation to obtain an initial global feature map. The initial global feature map is used to provide a joint feature representation of the overall liver tissue structure and the suspected small lesion region in the high-precision identification task of liver cancer small lesions.
[0100] This implementation addresses the technical challenge of reliably identifying small liver cancer lesions in liver medical imaging due to their small size, low contrast, and susceptibility to being obscured by complex liver parenchyma backgrounds. It constructs a hierarchical guided large-kernel attention D-LKA network encoder, enabling cross-scale, long-range contextual joint modeling while maintaining computational control, thus enhancing the saliency and separability of small lesions in the global feature space. Simultaneously, by introducing an adaptive large kernel driven by contrast-noise sensitivity, the attention receptive field dynamically adjusts with the scale and contrast characteristics of the small lesion, avoiding the problem of insufficient response to small lesions in traditional fixed-receptive-field models.
[0101] A hierarchical guidance mask is constructed based on the initial global feature map. The hierarchical guidance mask and the initial global feature map are then multiplied element-wise in the big kernel attention operation to obtain the guidance enhancement global feature map.
[0102] In this embodiment, the hierarchical guiding mask and the initial global feature map are subjected to element-wise multiplication operations in the large kernel attention operation, including:
[0103] Based on the initial global feature map, a candidate response map for small liver cancer lesions is constructed for each pixel coordinate.
[0104] In Example 1, each pixel position in the candidate response map of small liver cancer lesions corresponds to a candidate response value. The candidate response map of small liver cancer lesions is used to represent the salience distribution of the suspected small liver cancer lesion region in the initial global feature map. The candidate response value is obtained by taking the absolute value of the feature amplitude of the initial global feature map at the pixel coordinate in all channel dimensions and then performing channel aggregation. Furthermore, normalization processing is performed within the entire pixel range of the image so that the candidate response value reflects the relative response intensity of the pixel position in the initial global feature map relative to the overall feature distribution.
[0105] A hierarchical guidance mask was constructed based on the candidate response map of small lesions in liver cancer.
[0106] In Example 1, the candidate response value of the liver cancer micro lesion corresponding to each pixel coordinate in the candidate response map of liver cancer micro lesions is read. The candidate response value of the liver cancer micro lesion is offset and compared with the preset mask center threshold to obtain the offset amount reflecting the degree of deviation of the pixel coordinate from the response center of the suspected liver cancer micro lesion. The offset amount is combined with the preset mask kurtosis coefficient to perform continuous nonlinear mapping processing, and the offset amount is mapped to a continuous weight value between zero and one. The continuous weight value is used as the hierarchical guide mask value at the corresponding pixel coordinate, forming a hierarchical guide mask in the spatial range of the entire candidate response map of liver cancer micro lesions.
[0107] The hierarchical bootstrap mask is extended in the channel dimension so that the hierarchical bootstrap mask is completely consistent with the initial global feature map in terms of spatial size and the number of channels in the initial global feature map in terms of channel dimension, thus obtaining the hierarchical bootstrap mask tensor;
[0108] The hierarchical guided mask tensor shares the same spatial guided weights in each channel dimension, which are used to apply consistent spatial positional guided constraints to the feature responses of each channel in the initial global feature map.
[0109] Before the big kernel attention computation, perform element-wise multiplication between the hierarchical guide mask tensor and the initial global feature map to obtain the mask guide feature map;
[0110] The mask-guided feature map spatially enhances the feature response of the suspected small lesion region of hepatocellular carcinoma indicated by the hierarchical guide mask, while suppressing the feature response of the background region of liver parenchyma indicated by the hierarchical guide mask.
[0111] Perform large kernel attention operations on the mask-guided feature map to obtain a large kernel attention response feature map;
[0112] The large kernel attention operation is as follows: a depthwise separable convolution operation with a larger kernel size than the regular convolution kernel is performed on the masked guided feature map in the spatial dimension. The output of the depthwise separable convolution operation is input into the pointwise convolution operator to perform linear remapping on the features in the channel dimension. Normalization activation processing is performed on the feature results after pointwise convolution to obtain a large kernel attention response feature map that is consistent with the masked guided feature map in terms of spatial size and number of channels.
[0113] The masked guided feature map and the large kernel attention response feature map are multiplied element-wise to obtain the guided augmentation global feature map.
[0114] The spatial dimensions of the guided global feature map are consistent with the height and width pixels of the standardized liver medical image tensor. The number of channels in the guided global feature map is equal to the number of channels in the initial global feature map. The guided global feature map is used to represent the global feature response after enhancement of the suspected small lesion region of liver cancer under the combined effect of hierarchical guided mask and big kernel attention.
[0115] Multi-scale channel reshaping and spatial aggregation are performed on the guided enhancement global feature map to form a multi-scale guided enhancement feature map. Then, cross-scale residual connection is used on the multi-scale guided enhancement feature map to retain the details of small lesions and output a fused enhancement feature map.
[0116] In this embodiment, multi-scale channel reshaping and spatial aggregation are performed on the guided enhancement global feature map, including:
[0117] A scale index set is constructed. For each scale number, the guided enhancement global feature map is linearly remapped and the channel group is rearranged in the channel dimension to obtain the channel remodeling feature map related to small lesions of liver cancer.
[0118] Spatial dimensions of each channel reshaping feature map and guided enhancement of global features Figure 1 The number of channels is the same, but the number of channels is determined by the corresponding scale number.
[0119] For each scale number, the corresponding channel reshaping feature map is spatially aggregated using spatial aggregation kernels with different coverage in the spatial dimension to obtain a spatially aggregated feature map.
[0120] The spatial size and number of channels of each spatially aggregated feature map are consistent with the corresponding channel remodeled feature map. The spatial aggregation operation is used to achieve multi-scale spatial representation of local details of small lesions of liver cancer and long-range structure of liver tissue at the same spatial resolution.
[0121] By concatenating the spatial aggregated feature maps corresponding to all scale numbers along the channel dimension, a multi-scale guided enhancement feature map is obtained.
[0122] Spatial size of multi-scale guided augmentation feature maps and guided augmentation global features Figure 1 The number of channels is the sum of the number of channels in the spatial aggregated feature map under all scale numbers. The multi-scale guided enhanced feature map is used to simultaneously carry multi-scale fusion information for the fine-grained texture response to small lesions of liver cancer and the contextual response to the overall structure of the liver.
[0123] Establish cross-scale residual connections on the multi-scale guided augmentation feature map, and construct a scale-aligned residual feature map with the same spatial size as the multi-scale guided augmentation feature map for each scale index.
[0124] In Example 1, based on the spatial size difference between the spatial aggregated feature map and the multi-scale guided enhancement feature map, a scale alignment mapping operation is performed. The scale alignment mapping operation includes at least one of spatial upsampling, spatial downsampling, or keeping the spatial size unchanged. After completing the spatial size alignment, channel mapping processing is performed on the spatially aligned spatial aggregated feature map to map its channel number to be consistent with the channel number required in the residual fusion stage of the multi-scale guided enhancement feature map, thus obtaining a scale-aligned residual feature map. The scale-aligned residual feature map is used to inject the edge detail features and weak contrast response features of small liver cancer lesions at different scales into the multi-scale guided enhancement feature map in the form of residuals during the cross-scale feature fusion process, thus preserving the fine-grained structural information of the small lesions during the residual fusion process.
[0125] The scale-aligned residual feature maps under all scale numbers are residually fused with the multi-scale guided enhancement feature maps to obtain the fused enhancement feature map.
[0126] The residual fusion method is as follows: add all scale-aligned residual feature maps to the multi-scale guided enhancement feature map element by element, and compress and reorganize the added feature map in the channel dimension through the fusion mapping operation to output a fused enhancement feature map with a preset number of channels.
[0127] The fused and enhanced feature map is input into the structural consistency sub-pixel feature fusion interpolation module. The fused and enhanced feature map is rearranged and fused in multiple directions according to the sub-pixel level displacement vector to obtain the sub-pixel spatial representation vector.
[0128] In this embodiment, the structural consistency sub-pixel feature fusion interpolation module includes:
[0129] Based on the fusion-enhanced feature map tensor, the structural consistency orientation field of small lesions is calculated, including the structural amplitude map, the structural gradient vector map, and the unit tangential vector map;
[0130] The structural amplitude map is the mean of the absolute values of the feature amplitudes across all channel dimensions at each pixel coordinate of the fused enhanced feature map tensor.
[0131] The structure gradient vector map is the difference between the horizontal and vertical directions of the structure magnitude map at each pixel coordinate.
[0132] The unit tangential vector map is a rotation of the normal vector at each pixel coordinate of the structure gradient vector map. The rotation operation is to take the negative of the horizontal gradient component as the new vertical component and the vertical gradient component as the new horizontal component, and then normalize them to indicate the principal direction of the fine-grained structure of the boundary of the small lesion. The normalization denominator is the square root of the sum of the squares of the horizontal and vertical gradient components plus a positive constant.
[0133] Based on the sub-pixel scale ratio, construct a sub-pixel grid index set and a basic sub-pixel level displacement vector set respectively;
[0134] Set the subpixel scale ratio, which is a positive integer, and satisfy the condition that the number of channels in the fused enhanced feature map tensor is equal to the product of the number of channels in the subpixel rearranged feature map and the square of the subpixel scale ratio.
[0135] The subpixel grid index set is a positive integer from 0 to the subpixel scale multiplier minus one, and the basic subpixel level displacement vector set is all combinations of the subpixel grid index set within each pixel unit.
[0136] The channel rearrangement of the fused enhanced feature map tensor is performed according to the sub-pixel scale ratio, and the information of the channel dimension is remapped to a higher resolution sub-pixel spatial grid to obtain the sub-pixel rearranged feature map.
[0137] In Example 1, the spatial size of the subpixel rearrangement feature map is the original height and width multiplied by the subpixel scale ratio, and the number of channels is the number of channels in the subpixel rearrangement feature map. Specifically, for each original pixel coordinate and each subpixel index, the feature value of the specified channel of the fused enhancement feature map tensor is assigned to the specified subpixel coordinate and channel index of the corresponding subpixel rearrangement feature map, so that the spatial and channel information are mapped one-to-one, and the subpixel-level expression in the entire spatial range is obtained.
[0138] On the sub-pixel rearrangement feature map, construct a set of directional unit vectors for multi-directional sub-pixel feature fusion;
[0139] The method for constructing the directional unit vector set is as follows: read the tangential direction in the unit tangential vector map corresponding to each pixel coordinate in the fused enhanced feature map, and map the tangential direction to the sub-pixel coordinate set of the sub-pixel rearrangement feature map corresponding to the pixel coordinates. This serves as the reference structural direction for all sub-pixel positions within the pixel unit. Starting from the reference structural direction, multiple direction vectors are generated sequentially in the sub-pixel coordinate space corresponding to the sub-pixel rearrangement feature map in a 2D plane at equal angular intervals according to a preset number of directions. This ensures that the generated direction vectors uniformly cover the complete directional range within the sub-pixel space. Length normalization is performed on each generated direction vector to form a directional unit vector set defined on the sub-pixel rearrangement feature map. The directional unit vector set is used in the sub-pixel rearrangement feature map to provide a multi-directional sampling reference along the consistent direction of the boundary structure of the small lesion and its adjacent directions for the sub-pixel positions of suspected liver cancer micro lesions.
[0140] For each pixel coordinate, calculate the sub-pixel direction step size coefficient, and combine the basic sub-pixel level displacement vector set with the direction unit vector set based on the sub-pixel direction step size coefficient to generate a structurally consistent sub-pixel level displacement vector set;
[0141] The sub-pixel direction step size coefficient is calculated as follows: The sensitivity value at the corresponding position in the contrast-noise sensitivity feature map of small liver cancer lesions aligned with the pixel coordinate space is read. The sensitivity value is offset and compared with a preset sensitivity center threshold to obtain an offset reflecting the degree of weak contrast significance of the small lesion at the pixel coordinates. A continuous normalization mapping is performed on the offset in conjunction with the preset step size sensitivity coefficient, mapping the offset to a continuous modulation coefficient between zero and one. Based on the continuous modulation coefficient, linear interpolation is performed between the preset lower limit constant and upper limit constant of the sub-pixel direction step size to obtain the sub-pixel direction step size coefficient at the pixel coordinates. This ensures that the sub-pixel direction step size coefficient is large in areas with high contrast-noise sensitivity of small liver cancer lesions, and small in areas with low sensitivity due to liver parenchyma background.
[0142] Multiply the sub-pixel direction step size coefficient by the reciprocal of the sub-pixel scale ratio and the set of direction unit vectors at the corresponding pixel coordinates one by one to generate a set of structurally consistent sub-pixel displacement vectors at the corresponding pixel coordinates. This set is used to determine the sub-pixel sampling displacement amplitude and direction along the structurally consistent direction of the small lesion in the sub-pixel rearrangement feature map.
[0143] Enumerate all sub-pixel coordinates for each pixel coordinate, and arrange the sub-pixel level displacement vector set according to structural consistency on the sub-pixel rearranged feature map. Use bilinear interpolation to obtain directional sub-pixel features for each sub-pixel coordinate and its each direction sampling point.
[0144] The set of all directional sub-pixel features is used to fully express the spatial diversity and directional response characteristics of the boundary structure in suspected small lesions of hepatocellular carcinoma.
[0145] Multi-directional fusion is performed on the sub-pixel features in each direction to obtain the sub-pixel spatial representation vector.
[0146] In Example 1, the directional sub-pixel features of all directions are fused in a weighted sum manner according to the structural consistency fusion weight to obtain the sub-pixel spatial expression vector, thereby realizing the sub-pixel level expression of spatial structural information under high-precision identification of small lesions of liver cancer.
[0147] The structural consistency fusion weight is obtained by multiplying the consistency measure of the dot product of the current direction unit vector and the unit tangential vector and the value of the noise sensitivity feature map of the liver cancer micro lesion aligned with the current spatial size by the direction consistency weight coefficient and the sensitivity modulation weight coefficient, respectively, and then performing weighted normalization.
[0148] Learnable interpolation reconstruction is performed on the sub-pixel spatial representation vector, and structure-preserving interpolation is performed on the sub-pixel spatial representation vector to obtain a high-precision reconstruction map of the lesion boundary. The high-precision reconstruction map of the lesion boundary and the fusion enhancement feature map are jointly optimized in the spatial consistency enhancement module to output a spatial consistency optimized feature map.
[0149] In this embodiment, the high-precision reconstructed map of the lesion boundary and the fused enhanced feature map are jointly optimized in the spatial consistency enhancement module, including:
[0150] The sub-pixel spatial representation vectors corresponding to the sub-pixel spatial coordinates are linearly weighted and summed in the channel dimension to obtain the initial reconstruction value of the lesion boundary in the sub-pixel spatial coordinates, and the initial reconstruction map of the lesion boundary is formed in the entire range of sub-pixel coordinates.
[0151] In Example 1, a linear weighted summation operation is sequentially performed on all sub-pixel spatial coordinates to form an initial reconstruction map of the lesion boundary. The initial reconstruction map of the lesion boundary is used to form a continuous, unconstrained boundary response of small liver cancer lesions in the sub-pixel space. The linear weighted channel weighting coefficients are trainable parameters set for each channel.
[0152] Along the set of structurally consistent sub-pixel level displacement vectors, the initial reconstruction map of the lesion boundary is sampled in the corresponding direction according to the structurally consistent sub-pixel level displacement. The sampling results in each direction are weighted and summed according to the structural consistency interpolation weight to obtain the high-precision reconstruction value of the lesion boundary corresponding to the sub-pixel spatial coordinates. The high-precision reconstruction value of the lesion boundary is calculated for all sub-pixel spatial coordinates in turn to obtain the high-precision reconstruction map of the lesion boundary.
[0153] The structural consistency interpolation weights are calculated as follows: For each pixel coordinate of the fused enhanced feature map, the angle consistency measure between the unit tangential vector at the pixel coordinate and the unit vector in each direction is calculated. The value of the contrast-noise sensitivity feature map of the small liver cancer lesion at the pixel coordinate and the angle consistency measure are multiplied by the direction consistency weight coefficient and the sensitivity modulation weight coefficient, respectively. The results are summed and the exponent is taken. After performing the above operation on all directions, the exponent results of each direction are summed as the normalized denominator. The exponent result of each direction is used as the normalized numerator and divided by the denominator to obtain the structural consistency interpolation weights for all directions at the pixel coordinate. The structural consistency interpolation weights are used to improve the contribution of structural directions to high-precision boundary reconstruction in the suspected small liver cancer lesion region.
[0154] ;
[0155] in, Represents pixel coordinates First The structural consistency interpolation weights corresponding to each direction These represent the pixel coordinates in the fused enhanced feature map, used to index the spatial location of small liver cancer lesions. Indicates direction index. Indicates the total number of directions, and represents the pixel coordinates. The number of directions involved in structural consistency interpolation calculations. Represents pixel coordinates First A unit vector in each direction. Represents pixel coordinates The unit tangential vector at that location is used to indicate the principal structure orientation of the boundary of small liver cancer lesions. Represents the unit vector of direction With unit tangential vector The dot product of the vectors between them This represents the directional consistency weighting coefficient. Represents pixel coordinates The contrast-noise sensitivity eigenvalue of small liver cancer lesions at a given location is used to represent the significant sensitivity of the corresponding location to small lesions under low contrast and noise interference conditions. This represents the sensitivity modulation weighting coefficient. This indicates exponentiation. Indicates index for all directions The summation operation.
[0156] The high-precision reconstructed image of the lesion boundary is downsampled and mapped in the spatial dimension according to the sub-pixel scale ratio to obtain the final lesion boundary alignment image with the spatial size of the fused and enhanced feature map.
[0157] Using the final lesion boundary alignment map at the corresponding location as a spatial consistency constraint factor, the feature values of each channel of the fused enhanced feature map are multiplied element-wise, and then weighted and superimposed with the final lesion boundary alignment map according to a specified ratio to obtain a spatial consistency optimized feature map.
[0158] The spatial consistency optimization feature map is a three-dimensional array. The first dimension is the height of the standardized liver medical image tensor in pixels, the second dimension is the width of the standardized liver medical image tensor in pixels, and the third dimension is the number of channels of the fusion enhancement feature map. The spatial consistency optimization feature map is used as a consistency constraint feature representation in the recognition-reconstruction collaborative feedback loop.
[0159] Spatial consistency optimization feature maps are used to calculate the difference between the feature maps and the initial lesion classification prediction maps in the recognition-reconstruction collaborative feedback loop, generating collaborative consistency loss information. The collaborative consistency loss information is then passed back to the hierarchical guided large kernel attention D-LKA network encoder to complete the end-to-end parameter update.
[0160] In this embodiment, the spatial consistency optimization feature map is used to calculate the difference between the feature map and the initial lesion classification prediction map in the recognition-reconstruction collaborative feedback loop, including:
[0161] Based on the fusion-enhanced feature map, pixel-level lesion discrimination calculation is performed on the multi-channel features corresponding to each pixel coordinate in the fusion-enhanced feature map to obtain the initial lesion classification prediction map.
[0162] The initial lesion classification prediction map is a two-dimensional probability distribution map with the same size as the tensor space of the standardized liver medical image. Each pixel position corresponds to an initial lesion classification probability value between zero and one, which is used to represent the initial prediction probability that the pixel position belongs to the region of small liver cancer lesions. The initial lesion classification prediction map is the initial lesion discrimination result obtained only based on the fusion enhancement feature map under the condition of preserving reconstruction without introducing sub-pixel structure.
[0163] The spatial consistency optimization feature map is subjected to channel amplitude aggregation in the channel dimension and then normalized to obtain the spatial consistency response map.
[0164] Full image normalization is achieved by summing the absolute values of all channels' feature values at each pixel coordinate in the channel dimension of the spatial consistency optimization feature map, and then dividing by the number of channels to obtain the channel amplitude aggregation amount for the corresponding pixel coordinate. The minimum and maximum values of the channel amplitude aggregation amount are then taken across all pixel coordinates. The minimum value is subtracted from the channel amplitude aggregation amount for each pixel coordinate, and the result is divided by the difference between the maximum and minimum values, plus a positive constant, to obtain the normalized spatial consistency response value. The normalized spatial consistency response values of all pixel coordinates form the spatial consistency response map. Each pixel position in the spatial consistency response map reflects the response intensity of the multi-channel information of the spatial consistency optimization feature map at that spatial position, and its dimension is the same as the initial lesion classification prediction map.
[0165] The difference between the initial lesion classification prediction map and the spatial consistency response map is calculated pixel by pixel to obtain the collaborative consistency loss information.
[0166] For each pixel coordinate, the value of the initial classification prediction map of the lesion is calculated, and the value of the spatial consistency response map is subtracted from the value of the spatial consistency response map. The square of the squared differences of all pixel coordinates is summed and divided by the total number of pixels to obtain the collaborative consistency loss information. The collaborative consistency loss information is used to measure the overall difference between the initial classification probability of pixel-level small liver cancer lesions and the spatial consistency optimization feature response.
[0167] The collaborative consistency loss information is used as the optimization objective and is backpropagated to the trainable parameter set of the hierarchical guided large kernel attention D-LKA network encoder. End-to-end parameter updates are completed for the parameter set after each round of parameter iteration.
[0168] The set of trainable parameters only includes the set of trainable weight parameters in the hierarchical guided large kernel attention D-LKA network encoder that participate in the extraction of standardized liver medical image tensor features and the discrimination of small lesions, and does not involve the sub-pixel structure preservation and reconstruction stage after the fusion and enhancement of feature maps.
[0169] After the end-to-end parameter update converges, the final identification result image of small liver cancer lesions is output.
[0170] In this embodiment, the final identification result image of small liver cancer lesions is output, including:
[0171] After the end-to-end parameter update is completed and convergence is achieved, pixel-level lesion discrimination calculation is performed on the multi-channel features corresponding to each pixel coordinate in the fused enhanced feature map based on the fused enhanced feature map, and the final lesion classification prediction map after convergence is obtained.
[0172] The high-precision reconstructed image of the lesion boundary is downsampled in the spatial dimension according to the sub-pixel scale ratio. The boundary reconstruction response values of all sub-pixel spatial positions are projected and mapped onto pixel coordinates that are consistent with the size of the standardized liver medical image tensor space to obtain the final lesion boundary alignment image.
[0173] Based on the converged final classification prediction map and final lesion boundary alignment map, the final identification result map of small liver cancer lesions is generated according to the pixel-level joint discrimination rule.
[0174] A pixel-level joint discrimination process is performed on all pixel coordinates to obtain the final identification result map of small liver cancer lesions that is consistent with the size of the standardized liver medical image tensor space. The final identification result map of small liver cancer lesions is a pixel-level binary annotation map, which is used to represent the small liver cancer lesion region determined under the condition that the consistency of the final classification prediction and the consistency of the boundary structure are satisfied at the same time.
[0175] In this embodiment, the pixel-level joint discrimination rule includes:
[0176] Read the final classification probability value of the lesion in the converged final lesion classification prediction map for each pixel coordinate corresponding to the standardized liver medical image tensor, and the boundary alignment response value in the final lesion boundary alignment map;
[0177] The final classification probability value of the lesion is compared with the pre-set final classification threshold of the lesion. When the final classification probability value of the lesion is greater than or equal to the final classification threshold of the lesion, the corresponding pixel coordinates are determined to meet the lesion classification consistency condition; otherwise, the corresponding pixel coordinates are determined not to meet the lesion classification consistency condition.
[0178] The boundary alignment response value is compared with a pre-set boundary alignment threshold. If the boundary alignment response value is greater than or equal to the boundary alignment threshold, the corresponding pixel coordinates are determined to meet the boundary structure consistency condition; otherwise, the corresponding pixel coordinates are determined not to meet the boundary structure consistency condition.
[0179] Only when the same pixel coordinates simultaneously meet the lesion classification consistency condition and the boundary structure consistency condition will the corresponding pixel coordinates be set as the lesion pixel in the final identification result image of small liver cancer lesions.
[0180] When the pixel coordinates do not simultaneously meet the consistency conditions for lesion classification and boundary structure, the corresponding pixel coordinates will be set as non-lesion pixels in the final identification result image of small liver cancer lesions.
[0181] Based on the final identification result image of small liver cancer lesions, the location, outline, and spatial size information of the small liver cancer lesions are extracted.
[0182] In Example 1, the final identification result image of small liver cancer lesions is traversed pixel by pixel. All pixel coordinates of the pixels identified as lesions are collected to form a set of pixel coordinates of the small liver cancer lesion region. Based on the set of pixel coordinates of the small liver cancer lesion region, the average value of the horizontal coordinates and the average value of the vertical coordinates of all pixels in the set are calculated. The obtained average horizontal coordinate value and average vertical coordinate value are used as the centroid coordinates of the small liver cancer lesion, which are used to represent the spatial position of the small liver cancer lesion in the standardized liver medical image tensor.
[0183] In the pixel coordinate set of the liver cancer micro lesion region, each pixel coordinate is checked to see if there are non-lesion pixels in the neighboring pixel coordinates. When there is at least one non-lesion pixel in the neighborhood of a certain pixel coordinate, the pixel coordinate is determined as a boundary pixel. All the pixel coordinates determined as boundary pixels are combined to form the contour pixel coordinate set of the liver cancer micro lesion, which is used to represent the contour information of the liver cancer micro lesion.
[0184] The difference between the maximum and minimum horizontal coordinate values of all pixels in the pixel coordinate set of the liver cancer micro-lesion region is incremented by one, and this difference is used as the width (in pixels) of the liver cancer micro-lesion in pixel space.
[0185] The difference between the maximum and minimum vertical coordinate values of all pixels in the pixel coordinate set of the liver cancer micro-lesion region is incremented by one and used as the height (in pixels) of the liver cancer micro-lesion in pixel space.
[0186] The number of pixels in width and the number of pixels in height are used together as the spatial size information of small liver cancer lesions to represent the spatial range of small liver cancer lesions in the standardized liver medical image tensor.
[0187] The final identification result image of liver cancer micro lesions includes the centroid coordinates of the location of the liver cancer micro lesion, the set of outline pixel coordinates of the liver cancer micro lesion, and the spatial size information of the liver cancer micro lesion, reflecting the specific location, boundary shape and area range of each suspected liver cancer micro lesion region in space.
[0188] Example 2: During a routine liver tumor screening process at a medical imaging center, the system received a liver CT scan. The image was a conventional abdominal CT data with a single-slice thickness of 1.2 mm and a cross-sectional resolution of 512×512. After preprocessing, it was normalized to the intensity range of 0~1.
[0189] In the initial scan data, the system identified 112 slices containing liver tissue. Gray-level normalization and edge-preserving filtering were applied to each image for noise reduction. A multi-scale resampling algorithm was then used to obtain a standardized liver medical image tensor with dimensions of 112×512×512, a three-dimensional data structure. Noise removal performance evaluation showed that the average signal-to-noise ratio improved from 17.5 to 23.2.
[0190] Standardized liver medical image tensors are fed into the D-LKA network. The first layer uses a small receptive field multi-channel convolution to extract features and generate an input feature map. The spatial size remains unchanged, but the number of channels is increased from 1 to 48.
[0191] For the pixel (320,236) in the central liver region of frame 47, the mean of the local neighborhood (radius 5) is calculated to be 0.484, the standard deviation is 0.071, the current feature value is 0.539, and the lesion contrast-noise sensitivity is 0.775.
[0192] The network automatically adjusts the convolution kernel of the second-layer large kernel attention module to 17×17 with an inflation rate of 2 (the global mean of sensitivity is higher than the set threshold), which improves the range of small target perception by about 40% compared with the traditional fixed 11×11 convolution kernel.
[0193] Each layer of feature flow is accompanied by dynamic updates to the sensitivity map and multi-scale residual feature aggregation.
[0194] Channel amplitude aggregation was performed on the encoded features: taking the hepatic hilum region (271, 188) in frame 60 as an example, the mean absolute value of the multi-channel feature amplitude was 0.314, the maximum amplitude of the whole image was 0.667 and the minimum was 0.052, and the normalized response was 0.438. A hierarchical guiding mask was generated by combining spatial adaptive threshold and the mask was expanded to be consistent with the feature map channels. The response of suspected small lesion areas was initially improved by 18% (mask weight 0.67 vs. 0.53), and the response of background areas was suppressed by 10%.
[0195] The global feature map was guided to undergo three-scale (1×, 0.5×, 0.25×) channel reshaping: the first scale retained 192 channels, the second and third scales had 96 and 48 channels respectively. A suspected micro lesion with a diameter of only 3.4 mm was found in frame 81. After the three-scale feature aggregation, the edge distribution continuity score improved from 0.64 to 0.91, and the local contrast was improved by 24%. After residual fusion, the information in the blurred boundary area was accurately transmitted to the multi-scale enhanced feature map. Finally, the response of the fused enhanced feature map in this area was more than 40% higher than that in other areas of the same frame.
[0196] The input fusion enhancement feature map is set to a sub-pixel multiplier of 4. After channel rearrangement, the spatial size is expanded to 448×2048×48. Taking the lesion boundary region (411,303) in frame 24 as an example, the tangential vector direction is 31.2°. Sampling points with an angle of less than 15° between the main direction and the tangential direction in the direction set are assigned a structural consistency weight of 0.38~0.46. Multi-directional sampling and sensitivity modulation weights are dynamically allocated. After sub-pixel fusion, the clarity of the lesion boundary contour is improved to 0.94 (compared with manual annotation).
[0197] Linear weighting was applied to the sub-pixel spatial representation vectors to generate a preliminary lesion reconstruction map. In frame 67, the reconstruction values in the boundary region ranged from 0.47 to 0.95, while the values in the noisy background region were <0.25. After consistency weighting along the tangential direction, the final high-precision reconstruction map of the lesion boundary had a Dice coefficient of 0.90 and a structural consistency score of 0.91. The sub-pixel reconstruction results were spatially downsampled and then jointly modulated with the fusion enhancement feature map. The mean response of the final spatial consistency optimized feature map to the boundary of small lesions was improved from 0.28 to 0.43.
[0198] The system synchronously outputs the initial classification prediction map of the lesion and the spatial consistency optimized feature map. The normalized mean squared error loss is calculated pixel by pixel. The initial probability of the lesion center (367,144) is 0.62, the spatial consistency response is 0.64, the squared difference is 0.0004, and the mean loss of all test slices is 0.0043. After 5 rounds of feedback iteration and convergence, the network weight is updated by about 2.5%, and the sensitivity of low contrast lesion identification is improved from 0.83 to 0.91.
[0199] After end-to-end convergence, the final identification result image of small liver cancer lesions is automatically generated: In the test set of 80 small lesions, the algorithm accurately labeled 75 cases (5 cases were missed), with an average center error of 0.42mm, an average Dice coefficient of 0.88, an area error of 2.4mm², and identified a 3.2mm diameter lesion at location (234,167), a spatial centroid of (234.5,167.3), a minimum bounding rectangle size of (5,5) pixels, and 32 contour points.
[0200] Compared with the traditional U-Net method, the average lesion localization accuracy is improved by 0.73 mm, the Dice coefficient is improved by 0.18, and the area error is reduced by 3.1 mm².
[0201] In the entire test set of 3200 images and 80 cases of small lesions, the false negative rate of this invention was 6.25%, while that of the traditional method was 23.75%. The average processing time per case of this method was 38 seconds, while that of the traditional method was 27 seconds (due to multi-stage spatial reconstruction, but with a significant improvement in accuracy). In areas with complex noise or overlap, the false positive rate of the traditional method was 11.3%, while that of this method was 3.4%. The quantitative indices of continuity of outline and preservation of structure of small lesions were both higher than 0.9, while those of the traditional method were only 0.65~0.72.
[0202] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.
Claims
1. A method for identifying early-stage micro-lesions of liver cancer based on machine learning, characterized in that, include: Liver medical imaging data were collected and preprocessed to obtain a standardized liver medical imaging tensor. Standardized liver medical image tensors are input into hierarchical large-kernel attention D-LKA network encoders to generate initial global feature maps. A hierarchical guidance mask is constructed based on the initial global feature map. The hierarchical guidance mask and the initial global feature map are then multiplied element-wise in the big kernel attention operation to obtain the guidance enhancement global feature map. Multi-scale channel reshaping and spatial aggregation are performed on the guided enhancement global feature map to form a multi-scale guided enhancement feature map. Then, cross-scale residual connection is used on the multi-scale guided enhancement feature map to retain the details of small lesions and output a fused enhancement feature map. The fused and enhanced feature map is input into the structural consistency sub-pixel feature fusion interpolation module. The fused and enhanced feature map is rearranged and fused in multiple directions according to the sub-pixel level displacement vector to obtain the sub-pixel spatial representation vector. Learnable interpolation reconstruction is performed on the sub-pixel spatial representation vector, and structure-preserving interpolation is performed on the sub-pixel spatial representation vector to obtain a high-precision reconstruction map of the lesion boundary. The high-precision reconstruction map of the lesion boundary and the fusion enhancement feature map are jointly optimized in the spatial consistency enhancement module to output a spatial consistency optimized feature map. Spatial consistency optimization feature maps are used to calculate the difference between the feature maps and the initial lesion classification prediction maps in the recognition-reconstruction collaborative feedback loop, generating collaborative consistency loss information. The collaborative consistency loss information is then passed back to the hierarchical guided large kernel attention D-LKA network encoder to complete the end-to-end parameter update. After the end-to-end parameter update converges, the final identification result image of small liver cancer lesions is output.
2. The method for identifying early-stage small lesions of liver cancer based on machine learning according to claim 1, characterized in that, The preprocessing includes grayscale normalization, noise suppression, and multi-scale resampling.
3. The method for identifying early-stage small lesions of liver cancer based on machine learning according to claim 1, characterized in that, The hierarchical guided large kernel attention D-LKA network encoder includes: The input of a standardized liver medical image tensor is hierarchically guided by the input embedding mapping operator of the large kernel attention D-LKA network encoder to obtain the encoder input feature map; Based on the encoder input feature map, a contrast-noise sensitivity feature map of small liver cancer lesions is constructed for each pixel coordinate. In each coding layer of the hierarchical guided big kernel attention D-LKA network encoder, the output feature map of the previous layer is processed by downsampling and channel mapping operators to obtain the input feature map of the l-th layer; Based on the contrast-noise sensitivity feature map of small liver cancer lesions in the previous layer, an adaptive set of large kernel parameters is generated for the large kernel attention mechanism of the l-th layer. In the l-th layer, based on the adaptive large kernel parameter set, the input feature map of the l-th layer is subjected to large kernel depth convolution operation in the horizontal and vertical directions respectively. The convolution results in the two directions are added together to obtain the long-range context aggregation feature map of the l-th layer. The long-range context aggregation feature map of the l-th layer is input into the pointwise convolution operator and the normalized activation operator to obtain the attention response feature map of the l-th layer. For each pixel coordinate in the l-th layer, a consistency gating feature map of small lesions is constructed based on the contrast-noise sensitivity feature map of small liver cancer lesions in the previous layer and the input feature map of the l-th layer. The input feature map of layer l is multiplied element-wise with the attention response feature map and the small lesion consistency gating feature map of layer l, respectively, and then added to the input feature map of layer l to obtain the output feature map of layer l. Based on the output feature map of the l-th layer, update the contrast-noise sensitivity feature map of small liver cancer lesions in the next layer; The output feature maps of all coding layers of the hierarchical guided large kernel attention D-LKA network encoder are spatially aligned and mapped to the same size as the standardized liver medical image tensor. Then, they are fused using an inter-layer aggregation operator to obtain the initial global feature map.
4. The method for identifying early-stage small lesions of liver cancer based on machine learning according to claim 3, characterized in that, The step of performing element-wise multiplication between the hierarchical guiding mask and the initial global feature map in the big kernel attention operation includes: Based on the initial global feature map, a candidate response map for small liver cancer lesions is constructed for each pixel coordinate. A hierarchical guidance mask was constructed based on the candidate response map of small lesions in liver cancer. The hierarchical bootstrap mask is extended in the channel dimension so that the hierarchical bootstrap mask is completely consistent with the initial global feature map in terms of spatial size and the number of channels in the initial global feature map in terms of channel dimension, thus obtaining the hierarchical bootstrap mask tensor; Before the big kernel attention computation, perform element-wise multiplication between the hierarchical guide mask tensor and the initial global feature map to obtain the mask guide feature map; Perform large kernel attention operations on the mask-guided feature map to obtain a large kernel attention response feature map; The masked guided feature map and the large kernel attention response feature map are multiplied element-wise to obtain the guided augmentation global feature map.
5. The method for identifying early-stage small lesions of liver cancer based on machine learning according to claim 4, characterized in that, The multi-scale channel reshaping and spatial aggregation of the guided enhancement global feature map includes: A scale index set is constructed. For each scale number, the guided enhancement global feature map is linearly remapped and the channel group is rearranged in the channel dimension to obtain the channel remodeling feature map related to small lesions of liver cancer. For each scale number, the corresponding channel reshaping feature map is spatially aggregated using spatial aggregation kernels with different coverage in the spatial dimension to obtain a spatially aggregated feature map. By concatenating the spatial aggregated feature maps corresponding to all scale numbers along the channel dimension, a multi-scale guided enhancement feature map is obtained. Establish cross-scale residual connections on the multi-scale guided augmentation feature map, and construct a scale-aligned residual feature map with the same spatial size as the multi-scale guided augmentation feature map for each scale index. The scale-aligned residual feature maps under all scale numbers are residually fused with the multi-scale guided enhancement feature maps to obtain the fused enhancement feature map.
6. The method for identifying early-stage small lesions of liver cancer based on machine learning according to claim 5, characterized in that, The structural consistency sub-pixel feature fusion interpolation module includes: Based on the fusion-enhanced feature map tensor, the structural consistency orientation field of small lesions is calculated, including the structural amplitude map, the structural gradient vector map, and the unit tangential vector map; Based on the sub-pixel scale ratio, construct a sub-pixel grid index set and a basic sub-pixel level displacement vector set respectively; The channel rearrangement of the fused enhanced feature map tensor is performed according to the sub-pixel scale ratio, and the information of the channel dimension is remapped to a higher resolution sub-pixel spatial grid to obtain the sub-pixel rearranged feature map. On the sub-pixel rearrangement feature map, construct a set of directional unit vectors for multi-directional sub-pixel feature fusion; For each pixel coordinate, calculate the sub-pixel direction step size coefficient, and combine the basic sub-pixel level displacement vector set with the direction unit vector set based on the sub-pixel direction step size coefficient to generate a structurally consistent sub-pixel level displacement vector set; Enumerate all sub-pixel coordinates for each pixel coordinate, and arrange the sub-pixel level displacement vector set according to structural consistency on the sub-pixel rearranged feature map. Use bilinear interpolation to obtain directional sub-pixel features for each sub-pixel coordinate and its each direction sampling point. Multi-directional fusion is performed on the sub-pixel features in each direction to obtain the sub-pixel spatial representation vector.
7. The method for identifying early-stage small lesions of liver cancer based on machine learning according to claim 6, characterized in that, The joint optimization of the high-precision reconstructed lesion boundary map and the fused enhanced feature map in the spatial consistency enhancement module includes: The sub-pixel spatial representation vectors corresponding to the sub-pixel spatial coordinates are linearly weighted and summed in the channel dimension to obtain the initial reconstruction value of the lesion boundary in the sub-pixel spatial coordinates, and the initial reconstruction map of the lesion boundary is formed in the entire range of sub-pixel coordinates. Along the set of structurally consistent sub-pixel level displacement vectors, the initial reconstruction map of the lesion boundary is sampled in the corresponding direction according to the structurally consistent sub-pixel level displacement. The sampling results in each direction are weighted and summed according to the structural consistency interpolation weight to obtain the high-precision reconstruction value of the lesion boundary corresponding to the sub-pixel spatial coordinates. The high-precision reconstruction value of the lesion boundary is calculated for all sub-pixel spatial coordinates in turn to obtain the high-precision reconstruction map of the lesion boundary. The high-precision reconstructed image of the lesion boundary is downsampled and mapped in the spatial dimension according to the sub-pixel scale ratio to obtain the final lesion boundary alignment image with the same spatial size as the fused and enhanced feature map. Using the final lesion boundary alignment map at the corresponding location as a spatial consistency constraint factor, the feature values of each channel of the fused enhanced feature map are multiplied element-wise, and then weighted and superimposed with the final lesion boundary alignment map according to a specified ratio to obtain a spatial consistency optimized feature map.
8. The method for identifying early-stage small lesions of liver cancer based on machine learning according to claim 7, characterized in that, The calculation of the difference between the spatial consistency optimization feature map and the initial lesion classification prediction map in the recognition-reconstruction collaborative feedback loop includes: Based on the fusion-enhanced feature map, pixel-level lesion discrimination calculation is performed on the multi-channel features corresponding to each pixel coordinate in the fusion-enhanced feature map to obtain the initial lesion classification prediction map. The spatial consistency optimization feature map is subjected to channel amplitude aggregation in the channel dimension and then normalized to obtain the spatial consistency response map. The difference between the initial lesion classification prediction map and the spatial consistency response map is calculated pixel by pixel to obtain the collaborative consistency loss information. The collaborative consistency loss information is used as the optimization objective and is backpropagated to the trainable parameter set of the hierarchical guided large kernel attention D-LKA network encoder. End-to-end parameter updates are completed for the parameter set after each round of parameter iteration.
9. The method for identifying early-stage small lesions of liver cancer based on machine learning according to claim 8, characterized in that, The output image showing the final identification result of small liver cancer lesions includes: After the end-to-end parameter update is completed and convergence is achieved, pixel-level lesion discrimination calculation is performed on the multi-channel features corresponding to each pixel coordinate in the fused enhanced feature map based on the fused enhanced feature map, and the final lesion classification prediction map after convergence is obtained. The high-precision reconstructed image of the lesion boundary is downsampled in the spatial dimension according to the sub-pixel scale ratio. The boundary reconstruction response values of all sub-pixel spatial positions are projected and mapped onto pixel coordinates that are consistent with the size of the standardized liver medical image tensor space to obtain the final lesion boundary alignment image. Based on the converged final classification prediction map and final lesion boundary alignment map, the final identification result map of small liver cancer lesions is generated according to the pixel-level joint discrimination rule. Based on the final identification result image of small liver cancer lesions, the location, outline, and spatial size information of the small liver cancer lesions are extracted.
10. The method for identifying early-stage small lesions of liver cancer based on machine learning according to claim 8, characterized in that, The pixel-level joint discrimination rules include: Read the final classification probability value of the lesion in the converged final lesion classification prediction map for each pixel coordinate corresponding to the standardized liver medical image tensor, and the boundary alignment response value in the final lesion boundary alignment map; The final classification probability value of the lesion is compared with a pre-set final classification threshold for the lesion. When the final classification probability value of the lesion is greater than or equal to the final classification threshold for the lesion, the corresponding pixel coordinates are determined to meet the lesion classification consistency condition; otherwise, the corresponding pixel coordinates are determined not to meet the lesion classification consistency condition. The boundary alignment response value is compared with a preset boundary alignment threshold. If the boundary alignment response value is greater than or equal to the boundary alignment threshold, the corresponding pixel coordinates are determined to meet the boundary structure consistency condition; otherwise, the corresponding pixel coordinates are determined not to meet the boundary structure consistency condition. Only when the same pixel coordinates simultaneously meet the lesion classification consistency condition and the boundary structure consistency condition will the corresponding pixel coordinates be set as the lesion pixel in the final identification result image of small liver cancer lesions. When the pixel coordinates do not simultaneously meet the consistency conditions for lesion classification and boundary structure, the corresponding pixel coordinates will be set as non-lesion pixels in the final identification result image of small liver cancer lesions.