Improved network-based lung nodule detection method, device, equipment and storage medium

By improving the backbone and neck unit structure of the YOLOv5 network, the problems of high computational cost and low accuracy in lung nodule detection were solved, achieving more efficient and accurate lung nodule detection.

CN116309459BActive Publication Date: 2026-01-02NAT UNIV OF DEFENSE TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310277575.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-03-21
Publication Date
2026-01-02
Estimated Expiration
2043-03-21

AI Technical Summary

Technical Problem

Existing methods for detecting lung nodules are computationally intensive and slow when dealing with a large number of lung nodule CT images, and YOLO-based methods suffer from low detection accuracy.

Method used

An improved YOLOv5 network was used, which replaced the original activation function with MetaAconC activation function in the backbone unit, added an attention mechanism structure before the SPPF structure, and used BiFPN structure in the neck unit for multi-size feature fusion to construct a neural network for lung nodule detection.

Benefits of technology

It improves the accuracy and efficiency of lung nodule detection, reduces the amount of data processing, and facilitates the observation of the effectiveness of the detection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116309459B_ABST
    Figure CN116309459B_ABST
Patent Text Reader

Abstract

The application relates to a lung nodule detection method, device and equipment based on an improved network and a storage medium. The method comprises the following steps: processing each CT original image in an acquired image sample set to extract a corresponding lung parenchyma image, so as to reduce the amount of data to be processed and facilitate observation of the effectiveness of detection, and a lung nodule detection neural network used in the method is obtained by improving a YOLOv5 network, wherein in a backbone unit, a MetaAconC activation function is used to replace original activation functions in part of a convolution structure, a CoordAtt attention mechanism structure is added before an SPPF structure, and a BiFPN structure is used in a neck unit to perform multi-size feature fusion, so that the improved YOLOv5 network is more suitable for detection of lung nodules in medical images, and the detection is more accurate and efficient.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of computer-aided detection, in particular to a lung nodule detection method, device and equipment based on an improved network and a storage medium. BACKGROUND

[0002] Medical image detection and recognition is the primary step for patient detection and treatment in clinical medicine. With the advancement of medical imaging technology, computer vision technology is closely combined with medical image analysis, and with the help of high-quality medical image datasets, image detection and analysis have become an important tool for modern medical analysis.

[0003] In recent years, domestic and foreign experts and scholars have devoted themselves to the research of applying computer-aided detection and diagnosis to the field of medical imaging. A series of effective lung nodule detection algorithms have been proposed. Traditional lung nodule detection methods use methods such as extracting texture features, then training with a classifier, and finally reducing false positives to identify lung nodules. However, traditional detection methods have the disadvantages of low efficiency, slow detection speed, and excessive dependence on manually selected features. The emergence of deep learning brings new opportunities to the field of computer vision. Zhu et al. designed a Deeplung model for nodule detection, combining a 3D double-path block and an encoder-decoder structure to learn nodule features, and finally accurately detected lung nodules. Ramachandran et al. first used the YOLO network for lung nodule detection and introduced transfer learning in the training process. The proposed detection system has good accuracy and sensitivity, as well as low false positive rate.

[0004] Currently, most methods use Faster-RCNN-based lung nodule detection methods, which use RPN networks and anchor box mechanisms. When faced with a lung nodule patient with hundreds of lung nodule CT images, the computational load is very large, and the detection speed is slow. In the use of YOLO-based lung nodule detection methods, there are low detection accuracy and low-efficiency models. SUMMARY

[0005] Therefore, it is necessary to provide a lung nodule detection method, device, equipment and storage medium based on an improved network to improve detection accuracy.

[0006] A lung nodule detection method based on an improved network, the method comprising:

[0007] Obtaining an image sample set, the image sample set comprising a plurality of lung-related CT original images;

[0008] Processing each CT original image in the image sample set to extract a corresponding lung parenchyma image;

[0009] According to each of the lung parenchyma images, a corresponding XML label is made, and is converted into a VOC format, and a training data set is constructed according to each of the lung parenchyma images converted in the format;

[0010] The training data set is input into a lung nodule detection neural network improved based on a YOLOv5 network for training, to obtain a trained lung nodule detection neural network, wherein the lung nodule detection neural network comprises a backbone unit, a neck unit and a head unit connected in sequence, in the backbone unit, a MetaAconC activation function is used to replace original activation functions in part of convolution structures, and an attention mechanism structure is added before an SPPF structure, and in the neck unit, a BiFPN structure is used for multi-size feature fusion;

[0011] A lung CT image to be detected is acquired, and the lung CT image is input into the trained lung nodule detection neural network, and a boundary and a probability of a lung nodule in the lung CT image are output to realize lung nodule detection.

[0012] In one of the embodiments, processing each of the CT original images in the image sample set to extract a corresponding lung parenchyma image comprises:

[0013] After visualizing each of the CT original images, a lung parenchyma is extracted by using a segmentation function, an erosion function and a dilation function, to obtain a corresponding lung parenchyma image.

[0014] In one of the embodiments, the backbone unit comprises in sequence:

[0015] a first CBS convolution structure, a first CBA convolution structure, a first C3 structure, a second CBA convolution structure, a second C3 structure, a third CBA convolution structure, a third C3 structure, a fourth CBA convolution structure, a fourth C3 structure, an attention mechanism structure and an SPPF structure;

[0016] The first feature map, the second feature map and the third feature map are output from the shallow layer to the deep layer in sequence by the second C3 structure, the third C3 structure and the SPPF structure respectively;

[0017] The first feature map, the second feature map and the third feature map are input into the neck unit.

[0018] In one of the embodiments, the attention mechanism structure in the backbone unit adopts CoordAtt.

[0019] In one of the embodiments, the neck unit comprises in sequence:

[0020] a second CBS convolutional structure, a first up-sampling structure, a first BiFPN structure, a fifth C3 structure, a third CBS convolutional structure, a second up-sampling structure, a second BiFPN structure, a sixth C3 structure, a third CBS convolutional structure, a third BiFPN structure, a seventh C3 structure, a fourth CBS convolutional structure, a fourth BiFPN structure, and an eighth C3 structure.

[0021] In an embodiment, inputting the first feature map, the second feature map, and the third feature map as the neck unit comprises:

[0022] The third feature map sequentially passes through the second CBS convolutional structure and the first up-sampling structure, and is fused with the second feature map in the first BiFPN structure to obtain a first feature fusion map;

[0023] The first feature fusion map sequentially passes through the fifth C3 structure, the third CBS convolutional structure, and the second up-sampling structure, and is fused with the first feature map in the second BiFPN structure to obtain a second feature fusion map;

[0024] The second feature fusion map sequentially passes through the sixth C3 structure and the third CBS convolutional structure, and is fused with the second feature map and the first feature fusion map passing through the fifth C3 structure in the third BiFPN structure to obtain a third feature fusion map;

[0025] The third feature fusion map sequentially passes through the seventh C3 structure and the fourth CBS convolutional structure, and is fused with the third feature map passing through the second CBS convolutional structure in the fourth BiFPN structure to obtain a fourth feature fusion map;

[0026] The fourth feature fusion map passes through the eighth C3 structure and then a detect layer to obtain a third prediction result image;

[0027] The third feature fusion map and the second feature fusion map pass through the seventh C3 structure and the sixth C3 structure, respectively, and then pass through a detect layer to obtain a second prediction result and a first prediction result.

[0028] In an embodiment, when the training data set is input into the lung nodule detection neural network based on the improved YOLOv5 network, the lung nodule detection neural network is trained as follows:

[0029] After inputting the lung parenchyma image in the training data set into the lung nodule detection neural network, a corresponding prediction result is obtained.

[0030] According to the prediction result and a corresponding label, a loss function is calculated, and parameters of the lung nodule detection neural network are adjusted according to a calculation result until the loss function converges, so as to obtain the trained lung nodule detection neural network.

[0031] An improved network-based lung nodule detection device, the device comprising:

[0032] An image sample set acquisition module is configured to acquire an image sample set, wherein the image sample set comprises a plurality of lung-related CT original images;

[0033] A lung parenchyma extraction module is configured to process each CT original image in the image sample set to extract a corresponding lung parenchyma image;

[0034] A training data set construction module is configured to make a corresponding XML label according to each lung parenchyma image and convert it into a VOC format, and construct a training data set according to each lung parenchyma image after format conversion;

[0035] A lung nodule detection neural network training module is configured to input the training data set into a lung nodule detection neural network improved based on a YOLOv5 network for training, so as to obtain a trained lung nodule detection neural network, wherein the lung nodule detection neural network comprises a backbone unit, a neck unit and a head unit connected in sequence, in the backbone unit, a MetaAconC activation function is used to replace original activation functions in part of the convolution structure, and an attention mechanism structure is added between SPPF structures, and in the neck unit, a BiFPN structure is used for multi-size feature fusion;

[0036] A lung nodule detection module is configured to acquire a lung CT image to be detected, input the lung CT image into the trained lung nodule detection neural network, and output a boundary and a probability of a lung nodule in the lung CT image to realize lung nodule detection.

[0037] A computer device comprising a memory and a processor, the memory storing a computer program, and the processor implementing the following steps when executing the computer program:

[0038] An image sample set is acquired, wherein the image sample set comprises a plurality of lung-related CT original images;

[0039] Each CT original image in the image sample set is processed to extract a corresponding lung parenchyma image;

[0040] A corresponding XML label is made according to each lung parenchyma image, and the XML label is converted into a VOC format, and a training data set is constructed according to each lung parenchyma image after format conversion;

[0041] The training data set is input into an improved lung nodule detection neural network based on a YOLOv5 network for training, to obtain a trained lung nodule detection neural network, wherein the lung nodule detection neural network comprises a backbone unit, a neck unit and a head unit connected in sequence, in the backbone unit, a MetaAconC activation function is used to replace original activation functions in part of the convolution structure, and an attention mechanism structure is added before an SPPF structure, and in the neck unit, a BiFPN structure is used for multi-size feature fusion;

[0042] A lung CT image to be detected is acquired, and the lung CT image is input into the trained lung nodule detection neural network, and the boundary and probability of a lung nodule in the lung CT image are output to realize lung nodule detection.

[0043] A computer readable storage medium has a computer program stored thereon, and the computer program is executed by a processor to implement the following steps:

[0044] An image sample set is acquired, and the image sample set includes a plurality of lung-related CT original images;

[0045] Each CT original image in the image sample set is processed to extract a corresponding lung parenchyma image;

[0046] An XML label corresponding to each lung parenchyma image is made, and is converted into a VOC format, and a training data set is constructed according to each lung parenchyma image after format conversion;

[0047] The training data set is input into an improved lung nodule detection neural network based on a YOLOv5 network for training, to obtain a trained lung nodule detection neural network, wherein the lung nodule detection neural network comprises a backbone unit, a neck unit and a head unit connected in sequence, in the backbone unit, a MetaAconC activation function is used to replace original activation functions in part of the convolution structure, and an attention mechanism structure is added before an SPPF structure, and in the neck unit, a BiFPN structure is used for multi-size feature fusion;

[0048] A lung CT image to be detected is acquired, and the lung CT image is input into the trained lung nodule detection neural network, and the boundary and probability of a lung nodule in the lung CT image are output to realize lung nodule detection.

[0049] The lung nodule detection method, device, equipment and storage medium based on the improved network, by processing each CT original image in the obtained image sample set to extract the corresponding lung parenchyma image, the data amount to be processed is reduced, and the effectiveness of observation and detection is facilitated, and the lung nodule detection neural network used in the method is obtained by improving the YOLOv5 network, wherein in the backbone unit, the MetaAconC activation function is used to replace the original activation function in part of the convolution structure, and the attention mechanism structure is added between the SPPF structures, and the BiFPN structure is used in the neck unit to fuse multi-size features, so that the improved YOLOv5 network is more suitable for the detection of lung nodules, and the detection is more accurate and efficient. BRIEF DESCRIPTION OF DRAWINGS

[0050] Figure 1 A flowchart of the lung nodule detection method based on the improved network in one embodiment is shown in the figure.

[0051] Figure 2 The CT data original image visualized using the SimpleITK library in one embodiment is shown in the figure.

[0052] Figure 3 A schematic diagram of the lung parenchyma extraction result in one embodiment is shown in the figure.

[0053] Figure 4 A structural diagram of the lung nodule detection neural network in one embodiment is shown in the figure.

[0054] Figure 5 A structural block diagram of the lung nodule detection device based on the improved network in one embodiment is shown in the figure.

[0055] Figure 6 An internal structure diagram of the computer equipment in one embodiment is shown in the figure. DETAILED DESCRIPTION

[0056] In order to make the purpose, technical scheme and advantages of the present application clearer, the present application will be further described in detail below with reference to the drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and do not limit the present application.

[0057] As shown in the figure, a lung nodule detection method based on an improved network is provided, comprising the following steps: Figure 1

[0058] Step S100, an image sample set is obtained, and the image sample set includes a plurality of CT original images related to the lung;

[0059] Step S110, each CT original image in the image sample set is processed to extract the corresponding lung parenchyma image; ​

[0060] Step S120: Create corresponding XML tags for each lung parenchyma image and convert them into VOC format. Construct a training dataset based on the lung parenchyma images after format conversion.

[0061] Step S130: Input the training dataset into the lung nodule detection neural network improved based on YOLOv5 network to train it, and obtain the trained lung nodule detection neural network. The lung nodule detection neural network includes a backbone unit, a neck unit and a head unit connected in sequence. In the backbone unit, the original activation function in some convolutional structures is replaced by the MetaAconC activation function, and an attention mechanism structure is added between the SPPF structures. In the neck unit, a BiFPN structure is used to perform multi-size feature fusion.

[0062] Step S140: Obtain the lung CT image to be detected, input the lung CT image into the trained lung nodule detection neural network, and output the boundary and probability of the lung nodules in the lung CT image to achieve lung nodule detection.

[0063] In this embodiment, steps S100 to S120 involve processing the dataset. Specifically, when training the lung nodule detection neural network, the image sample set used is the LUNA2016 dataset, which includes 1186 lung CT scan images. Then, by flipping, slicing, and eroding the edges of each lung CT image, a dataset compatible with the YOLOv5 network is established based on the VOC dataset format.

[0064] Specifically, in step S110, processing each original CT image in the image sample set to extract the corresponding lung parenchyma image includes: performing numerical truncation, visualization operations and segmentation on each original CT image, converting the image to grayscale to further reduce the amount of computational data, and then using erosion and dilation functions to extract the lung parenchyma to obtain the corresponding lung parenchyma image.

[0065] like Figure 2 As shown, this is the image obtained after visualizing the original CT image. It can be seen that the image retains many uninteresting parts. Furthermore, while the LUNA dataset is large, it only annotates 1186 lung nodules. Therefore, the dataset is sliced ​​and visualized for subsequent lung parenchyma extraction. Figure 3 The image shown is the result of lung parenchyma extraction. It can be seen that only key parts such as lung parenchyma and lung nodules are retained in the image. This operation greatly reduces the amount of data, which reduces the amount of computation and makes it easier to observe the effectiveness of the detection.

[0066] Further, in step S120, each nodule is marked in each lung parenchyma image to facilitate subsequent training of the lung nodule detection neural network, and the lung parenchyma image is converted to a VOC format more suitable for input to the YOLOv5 network.

[0067] In the embodiment, the lung nodule detection neural network adopts a network optimized based on the YOLOv5 network, and the structure of the network is as shown in Figure 4 The network mainly includes three parts: a backbone unit, a neck unit and a head unit. The backbone unit is used for feature extraction, the neck unit is used for fusing features, and the head unit is used for prediction based on the fused image.

[0068] In the embodiment, the MetaAconC activation function is integrated into the backbone unit in the network, and the MetaAconC activation function is used to replace the original SiLU activation function. Based on the Acon function paper, the function can adaptively select whether to activate neurons, which can improve the accuracy, but the calculation amount is slightly large, so when replacing, the function is integrated into the activation function of the first four convolution structures, and the CBS module (Conv+BN+SiLU) is replaced with the CBA module (Conv+BN+MetaAconC).

[0069] Specifically, the backbone unit includes, in sequence, a first CBS convolution structure, a first CBA convolution structure, a first C3 structure, a second CBA convolution structure, a second C3 structure, a third CBA convolution structure, a third C3 structure, a fourth CBA convolution structure, a fourth C3 structure, an attention mechanism structure and an SPPF structure.

[0070] After the image is input to the first CBS convolution structure, the first feature map, the second feature map and the third feature map are output from the shallow layer to the deep layer in sequence through the second C3 structure, the third C3 structure and the SPPF structure, and the first feature map, the second feature map and the third feature map are input as the neck unit.

[0071] Further, the SPPF structure is used to replace the SPP structure in the backbone unit of the YOLOv5 network. In the SPP structure, the parallel Maxpool2d module of different sizes is used, while in the SPPF structure, the input feature layer is serially passed through the module, and the output is spliced with the previous input. The output results of the two modules are equivalent, but the former speed is improved by nearly 2 times, and the calculation amount is smaller.

[0072] Further, an attention mechanism module CoordAtt (CA structure) is added between the SPPF structures, the CA structure can be quickly integrated into any convolutional layer, compressing part of the information and more effectively integrating the information between different channels of the feature map. The attention mechanism can enhance the feature extraction capability of the feature extraction part for lung nodules and increase the sensitivity of the channel.

[0073] In the embodiment, the structure of the multi-scale fusion part in the neck unit is adjusted. In the fusion of different input features, the original YOLOv5 network uses the structure of FPN+PAN, but this is just adding image features without distinction. However, since these different input features have different scales, their contributions to the fused output features are often unequal. Therefore, a bidirectional feature pyramid network (BiFPN) similar to the attention mechanism is introduced, which contains learnable weights to learn the importance of different input features, while repeatedly applying top-down and bottom-up multi-scale feature fusion. That is, the PANet (repeated bidirectional cross-scale connection) is strengthened, and a weighted feature fusion mechanism is added, which is more conducive to mining the information of the feature map. The existing Concat module is replaced by the BiFPN-add module.

[0074] Specifically, the neck unit sequentially includes: a second CBS convolutional structure, a first upsampling structure, a first BiFPN structure, a fifth C3 structure, a third CBS convolutional structure, a second upsampling structure, a second BiFPN structure, a sixth C3 structure, a third CBS convolutional structure, a third BiFPN structure, a seventh C3 structure, a fourth CBS convolutional structure, a fourth BiFPN structure, and an eighth C3 structure.

[0075] Further, the first feature map, the second feature map, and the third feature map are taken as the neck unit input, which includes: the third feature map sequentially passes through the second CBS convolutional structure and the first upsampling structure, and is fused with the second feature map in the first BiFPN structure to obtain a first feature fusion map.

[0076] The first feature fusion map sequentially passes through the fifth C3 structure, the third CBS convolutional structure, and the second upsampling structure, and is fused with the first feature map in the second BiFPN structure to obtain a second feature fusion map.

[0077] The second feature fusion map sequentially passes through the sixth C3 structure and the third CBS convolutional structure, and is fused with the second feature map and the first feature fusion map passing through the fifth C3 structure in the third BiFPN structure to obtain a third feature fusion map.

[0078] The third feature fusion map is sequentially passed through a seventh C3 structure and a fourth CBS convolution structure, and is fused with the third feature map passed through the second CBS convolution structure in a fourth BiFPN structure to obtain a fourth feature fusion map.

[0079] The fourth feature fusion map is passed through an eighth C3 structure to obtain a third prediction result, and the third feature fusion map and the second feature fusion map are respectively passed through a seventh C3 structure and a sixth C3 structure to obtain a second prediction result and a first prediction result.

[0080] In the embodiment, when the training data set is input into the lung nodule detection neural network improved based on the YOLOv5 network for training, the lung parenchyma images in the training data set are input into the lung nodule detection neural network to obtain corresponding prediction results, including the position of the predicted lung nodule and the probability that it is a lung nodule. Then, the sum of the three loss functions is calculated according to the prediction results and the corresponding labels, respectively, and the parameters of the lung nodule detection neural network are adjusted according to the calculation results until the loss function converges, thereby obtaining a trained lung nodule detection neural network model.

[0081] In the embodiment, step S140 is a step of applying the trained lung nodule detection neural network. When the trained lung nodule detection neural network is applied, only the real-time acquired CT scan lung images need to be input into the trained lung nodule detection neural network to obtain the predicted position and probability of the lung nodule in the image.

[0082] The lung nodule detection method based on the improved network reduces the amount of data to be processed and facilitates observation of the effectiveness of detection by processing each CT original image in the acquired image sample set to extract the corresponding lung parenchyma image. The lung nodule detection neural network used in the method is improved based on the YOLOv5 network. In the backbone unit, the MetaAconC activation function is used to replace the original activation function in part of the convolution structure, and the CoordAtt attention mechanism module is added before the SPPF structure. In the neck unit, the BiFPN structure is used for multi-size feature fusion, so that the improved YOLOv5 network is more suitable for the detection of lung nodules in medical images, and the detection is more accurate and efficient.

[0083] It should be understood that, although Figure 1 The steps in the flowchart of FIG. 1 1 are displayed in sequence according to the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified herein, the execution of these steps is not strictly limited in sequence, and these steps can be executed in other orders. Moreover, Figure 1At least one of the steps in the method can include a plurality of sub-steps or a plurality of stages, which are not necessarily performed at the same time, but can be performed at different times, and the order of the execution of the sub-steps or stages is not necessarily sequential, but can be performed alternately or alternately with at least one of the other steps or sub-steps or stages of the other steps.

[0084] In one embodiment, as shown in Figure 5 An improved network-based lung nodule detection device is provided, comprising: an image sample set acquisition module 200, a lung parenchyma extraction module 210, a training data set construction module 220, a lung nodule detection neural network training module 230, and a lung nodule detection module 240, wherein:

[0085] The image sample set acquisition module 200 is configured to acquire an image sample set, wherein the image sample set includes a plurality of CT original images related to the lung;

[0086] The lung parenchyma extraction module 210 is configured to process each CT original image in the image sample set to extract a corresponding lung parenchyma image;

[0087] The training data set construction module 220 is configured to generate a corresponding XML label according to each lung parenchyma image and convert it into a VOC format, and construct a training data set according to each lung parenchyma image after format conversion;

[0088] The lung nodule detection neural network training module 230 is configured to input the training data set into a lung nodule detection neural network improved based on a YOLOv5 network for training, to obtain a trained lung nodule detection neural network, wherein the lung nodule detection neural network includes a backbone unit, a neck unit and a head unit connected in sequence, in the backbone unit, a MetaAconC activation function is used to replace the original activation function in part of the convolution structure, and an attention mechanism structure is added between SPPF structures, and in the neck unit, a BiFPN structure is used for multi-size feature fusion;

[0089] The lung nodule detection module 240 is configured to acquire a lung CT image to be detected, input the lung CT image into the trained lung nodule detection neural network, and output the boundary and probability of the lung nodule in the lung CT image to realize lung nodule detection.

[0090] The specific limitations of the improved network-based lung nodule detection device can refer to the limitations of the improved network-based lung nodule detection method described above, which will not be repeated here. Each module in the improved network-based lung nodule detection device described above can be implemented by software, hardware, and a combination thereof, in whole or in part. The above-mentioned modules can be embedded in or independent of the processor in the computer device in hardware form, or can be stored in the memory of the computer device in software form, so that the processor can call and execute the operations corresponding to each of the above modules.

[0091] In one embodiment, a computer device, which can be a terminal, has an internal structure diagram as shown in Figure 6 The computer device includes a processor, a memory, a network interface, a display screen, and an input device connected by a system bus. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operating system and the computer program in the non-volatile storage medium to run. The network interface of the computer device is used to communicate with external terminals through network connections. The computer program is executed by the processor to implement an improved network-based lung nodule detection method. The display screen of the computer device can be a liquid crystal display screen or an electronic ink display screen. The input device of the computer device can be a touch layer overlaid on the display screen, or a key, trackball, or touchpad provided on the computer device housing, or an external keyboard, touchpad, or mouse, etc.

[0092] Those skilled in the art can understand that Figure 6 The structure shown in the figure is only a block diagram of part of the structure related to the scheme of the present application, and does not constitute a limitation on the computer device to which the scheme of the present application is applied. The specific computer device can include more or fewer components than those shown in the figure, or combine certain components, or have a different component arrangement.

[0093] In one embodiment, a computer device is provided, which includes a memory and a processor, the memory stores a computer program, and the processor executes the computer program to implement the following steps:

[0094] Obtain an image sample set, which includes a plurality of lung-related CT original images;

[0095] Process each CT original image in the image sample set to extract a corresponding lung parenchyma image;

[0096] According to each lung parenchyma image, a corresponding XML label is made and converted into a VOC format, and a training data set is constructed according to each lung parenchyma image after format conversion.

[0097] inputting the training data set into a lung nodule detection neural network based on a YOLOv5 network for training to obtain a trained lung nodule detection neural network, wherein the lung nodule detection neural network comprises a backbone unit, a neck unit and a head unit connected in sequence, in the backbone unit, a MetaAconC activation function is used to replace original activation functions in part of convolution structures, and an attention mechanism structure is added between SPPF structures, and in the neck unit, a BiFPN structure is used for multi-size feature fusion;

[0098] obtaining a lung CT image to be detected, inputting the lung CT image into the trained lung nodule detection neural network, and outputting boundaries and probabilities of lung nodules in the lung CT image to realize lung nodule detection.

[0099] In one embodiment, a computer readable storage medium is provided, and a computer program is stored on the computer readable storage medium, and the computer program is executed by a processor to implement the following steps:

[0100] obtaining an image sample set, wherein the image sample set comprises a plurality of lung-related CT original images;

[0101] processing each CT original image in the image sample set to extract a corresponding lung parenchyma image;

[0102] According to each lung parenchyma image, a corresponding XML label is made and is converted into a VOC format, and a training data set is constructed according to each lung parenchyma image after format conversion;

[0103] inputting the training data set into a lung nodule detection neural network based on a YOLOv5 network for training to obtain a trained lung nodule detection neural network, wherein the lung nodule detection neural network comprises a backbone unit, a neck unit and a head unit connected in sequence, in the backbone unit, a MetaAconC activation function is used to replace original activation functions in part of convolution structures, and an attention mechanism structure is added between SPPF structures, and in the neck unit, a BiFPN structure is used for multi-size feature fusion;

[0104] obtaining a lung CT image to be detected, inputting the lung CT image into the trained lung nodule detection neural network, and outputting boundaries and probabilities of lung nodules in the lung CT image to realize lung nodule detection.

[0105] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a non-volatile computer readable storage medium, and when the computer program is executed, the processes of the above-mentioned embodiments of the methods can be included. Any reference to memory, storage, databases, or other media in the embodiments provided by the present application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration but not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

[0106] The technical features of the above embodiments can be combined in any way. In order to make the description simple, not all possible combinations of the technical features in the above embodiments are described, but as long as the combinations of the technical features do not exist, they should be considered as the scope of the present application.

[0107] The above embodiments only express several implementation manners of the present application, and the description is more specific and detailed, but it should not be understood as a limitation on the scope of the patent. It should be pointed out that for ordinary skilled in the art, without departing from the concept of the present application, some modifications and improvements can be made, which are all within the scope of the present application. Therefore, the scope of the patent of the present application should be subject to the appended claims.

Claims

1. A method for improved network-based lung nodule detection, characterized in that, The method comprises: obtaining an image sample set, wherein the image sample set comprises a plurality of CT original images related to the lung; processing each CT original image in the image sample set to extract a corresponding lung parenchyma image; creating a corresponding XML label according to each lung parenchyma image and converting the XML label into a VOC format, and constructing a training data set according to each lung parenchyma image after format conversion; inputting the training data set into a lung nodule detection neural network improved based on a YOLOv5 network for training, to obtain a trained lung nodule detection neural network, wherein the lung nodule detection neural network comprises a backbone unit, a neck unit and a head unit connected in sequence, in the backbone unit, a MetaAconC activation function is used to replace original activation functions in part of convolution structures, and an attention mechanism structure is added before an SPPF structure, in the neck unit, a BiFPN structure is used for multi-size feature fusion, the backbone unit comprises, in sequence, a first CBS convolution structure, a first CBA convolution structure, a first C3 structure, a second CBA convolution structure, a second C3 structure, a third CBA convolution structure, a third C3 structure, a fourth CBA convolution structure, a fourth C3 structure, an attention mechanism structure and an SPPF structure, wherein first, second and third feature maps progressively from a shallow layer to a deep layer are respectively output by the second C3 structure, the third C3 structure and the SPPF structure, the first, second and third feature maps are input into the neck unit, the attention mechanism structure in the backbone unit adopts CoordAtt, and the neck unit comprises, in sequence, a second CBS convolution structure, a first up-sampling structure, a first BiFPN structure, a fifth C3 structure, a third CBS convolution structure, a second up-sampling structure, a second BiFPN structure, a sixth C3 structure, a third CBS convolution structure, a third BiFPN structure, a seventh C3 structure, a fourth CBS convolution structure, a fourth BiFPN structure and an eighth C3 structure. The first feature map, the second feature map, and the third feature map are input into the neck unit, and the third feature map is sequentially subjected to the second CBS convolution structure and the first up-sampling structure, and then is subjected to feature fusion with the second feature map in the first BiFPN structure to obtain a first feature fusion map, the first feature fusion map is sequentially subjected to the fifth C3 structure, the third CBS convolution structure, and the second up-sampling structure, and then is subjected to feature fusion with the first feature map in the second BiFPN structure to obtain a second feature fusion map, the second feature fusion map is sequentially subjected to the sixth C3 structure and the third CBS convolution structure, and then is subjected to feature fusion with the second feature map and the first feature fusion map subjected to the fifth C3 structure in the third BiFPN structure to obtain a third feature fusion map, the third feature fusion map is sequentially subjected to the seventh C3 structure and the fourth CBS convolution structure, and then is subjected to feature fusion with the third feature map subjected to the second CBS convolution structure in the fourth BiFPN structure to obtain a fourth feature fusion map, the fourth feature fusion map is subjected to the eighth C3 structure and then is subjected to the detect layer to obtain a third prediction result, and the third feature fusion map and the second feature fusion map are subjected to the seventh C3 structure and the sixth C3 structure, respectively, and then are subjected to the detect layer to obtain a second prediction result and a first prediction result; The lung CT image to be detected is input into the trained lung nodule detection neural network, and the boundary and probability of the lung nodule in the lung CT image are output to realize lung nodule detection.

2. The lung nodule detection method of claim 1, wherein, The CT original images in the image sample set are processed to extract corresponding lung parenchyma images, including: After visualizing the CT original images, the lung parenchyma is extracted by using segmentation, erosion, and inflation functions to obtain corresponding lung parenchyma images.

3. The lung nodule detection method of any of claims 1-2, wherein, When the training data set is input into the lung nodule detection neural network based on the improved YOLOv5 network, the following steps are performed: After the lung parenchyma images in the training data set are input into the lung nodule detection neural network, corresponding prediction results are obtained. The loss function is calculated according to the prediction results and corresponding labels, and the parameters of the lung nodule detection neural network are adjusted according to the calculation results until the loss function converges, thereby obtaining the trained lung nodule detection neural network.

4. The improved network-based lung nodule detection apparatus, characterized in that, The device implements the lung nodule detection method based on the improved network according to any one of claims 1-3, including: An image sample set acquisition module is configured to acquire an image sample set, wherein the image sample set includes a plurality of CT original images related to the lung; A lung parenchyma extraction module is configured to process each CT original image in the image sample set to extract corresponding lung parenchyma images; A training data set construction module is configured to generate corresponding XML labels from each lung parenchyma image, convert the XML labels into VOC format, and construct a training data set from each lung parenchyma image after format conversion. The lung nodule detection neural network training module is configured to input the training data set into a lung nodule detection neural network based on a YOLOv5 network to train the lung nodule detection neural network, and obtain a trained lung nodule detection neural network, wherein the lung nodule detection neural network comprises a backbone unit, a neck unit and a head unit connected in sequence, in the backbone unit, a MetaAconC activation function is used to replace original activation functions in part of convolution structures, and an attention mechanism structure is added between SPPF structures, and in the neck unit, a BiFPN structure is used for multi-size feature fusion. The lung nodule detection module is configured to acquire a lung CT image to be detected, input the lung CT image into the trained lung nodule detection neural network, and output boundaries and probabilities of lung nodules in the lung CT image to realize lung nodule detection. 5.A computer device, comprising a memory and a processor, wherein the memory stores a computer program, and the computer device is configured to perform the method according to any one of claims 1-4 when the computer program is executed by the processor. The computer program is executed by the processor to implement the steps of the method of claim 3.

6. A computer-readable storage medium having stored thereon a computer program, characterized in that, The computer program is executed by the processor to implement the steps of the method of claim 3.

Citation Information

Patent Citations

  • Pulmonary nodule automatic detection method based on CT image

    CN110942446A

  • Real-time multifunctional pest and disease damage intelligent identification and early warning system

    CN115187868A