Double-step spine X-ray film processing method based on single vertebral body segmentation

By using the YOLOv8 object detection model and the two-step processing method of the U-Net network in the spine X-ray image, the problems of low accuracy and insufficient accuracy of spine segmentation in the traditional method are solved, and higher recognition accuracy and accuracy are achieved. Supports more effective spinal diagnosis.

CN118918118AActive Publication Date: 2024-11-08DECANS MEDICAL DEVICES CO LTD

Patent Information

Application Number
CN202410959702.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-17
Publication Date
2024-11-08
Estimated Expiration
2044-07-17

AI Technical Summary

Technical Problem

Traditional image segmentation methods have problems with low recognition accuracy and insufficient segmentation accuracy when segmenting spinal X-ray images, especially because of the similar appearance of the spine and background and complex structure.

Method used

Using a two-step processing method based on single vertebra, firstly use the YOLOv8 target detection model to identify the spine position and generate the target box, and then perform detailed segmentation and feature point recognition in the U-Net network, combining target detection and semantic segmentation to improve spine segmentation accuracy and identification accuracy.

Benefits of technology

It significantly improves the accuracy and recognition accuracy of spinal segmentation, providing more effective information to support clinical diagnosis.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118918118A_ABST
    Figure CN118918118A_ABST
Patent Text Reader

Abstract

The invention belongs to the technical field of medical image processing, and discloses a double-step spine X-ray film processing method based on single vertebral body segmentation, and the method comprises the steps: S1, employing a YOLOv8 target detection model to recognize the position of each single spine vertebral body in an X-ray image, and generating a single vertebral body target frame; s2, carrying out detailed segmentation in each detected single vertebral body target frame so as to accurately draw the outline of the vertebral column; and S3, performing feature point identification in a single vertebral body target frame, and identifying key feature points of the vertebrae by using a YOLOv8POSE model so as to further improve the accuracy of feature point identification. According to the double-step spine X-ray film processing method based on single vertebral body segmentation disclosed by the invention, the target frame obtained by the YOLOv8POSE model is imported into the U-Net network for segmentation, and the precision of spine segmentation and the accuracy of recognition are improved in combination with target detection and semantic segmentation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of medical image processing, and in particular relates to a double-step spinal X-ray film processing method based on single vertebra segmentation. Background Art

[0002] Accurate segmentation of vertebral blocks in full spine X-ray images is crucial for intelligent diagnosis of spinal diseases. Traditional image segmentation methods mainly include threshold-based segmentation methods, edge detection-based segmentation methods, region-based segmentation methods, etc. The vertebral blocks in spinal X-ray images have a similar appearance to the background, and parts of the same structure in the image are covered by other tissues or blurred, which increases the difficulty of segmentation and recognition and poses a huge challenge to segmentation performance.

[0003] For spinal X-ray images with complex structures, traditional image segmentation methods often have problems such as low recognition accuracy and insufficient segmentation precision. Summary of the invention

[0004] In order to solve the problem of low accuracy and insufficient segmentation precision in the segmentation of spinal X-ray images by traditional image segmentation methods, the present invention proposes a two-step spinal X-ray processing method based on single vertebra segmentation. The present invention mainly imports the target frame obtained by the YOLOv8 POSE model into the U-Net network for segmentation, combines target detection and semantic segmentation, and improves the accuracy of spinal segmentation and recognition.

[0005] To achieve the above objectives, the present invention discloses a two-step spinal X-ray film processing method based on single vertebra segmentation, comprising the following steps:

[0006] Step S1: Use the YOLOv8 target detection model to identify the position of each single spinal vertebra in the X-ray image and generate a single vertebra target box;

[0007] Step S2: Perform detailed segmentation within each detected single vertebral target frame to accurately outline the spine;

[0008] Step S3: Perform feature point recognition within the single vertebral target frame and use the YOLOv8 POSE model to identify key feature points of the vertebra to further improve the accuracy of feature point recognition.

[0009] As a further preferred technical solution of the above technical solution, step S1 is specifically implemented as follows:

[0010] Step S1.1: Perform image preprocessing before inputting the X-ray image into the YOLOv8 target detection model, including normalization, rotation, and cropping operations to adapt to the input requirements of the model;

[0011] Step S1.2: Perform feature extraction, use the backbone network (CSPDarknet53) of the YOLOv8 target detection model to extract multi-scale features from the X-ray image, use residual blocks to deepen the network and improve the effect of feature extraction, and solve the gradient vanishing and gradient exploding problems by introducing skip connections;

[0012] Step S1.3: Perform feature fusion, using FPN (feature pyramid network) and PANet (path aggregation network) to fuse features of different scales to improve the accuracy and robustness of target detection;

[0013] Step S1.4: Perform target box prediction, using the YOLO Head module of the YOLOv8 target detection model to predict the target box, category confidence, and position offset on the feature map;

[0014] Step S1.5: Perform non-maximum suppression (NMS) to remove redundant boxes and retain only high-confidence boxes to ensure that each target box uniquely corresponds to a vertebral category.

[0015] As a further preferred technical solution of the above technical solution, for step S1.3:

[0016] A top-down feature pyramid structure is constructed through FPN to extract multi-scale semantic information from feature maps at different levels to solve the problem of insufficient multi-scale information in target detection.

[0017] Through PANet, lateral connections and adaptive feature pooling mechanisms are introduced to transfer and fuse information between feature maps of different resolutions, thereby (better) utilizing the multi-scale features generated by FPN.

[0018] As a further preferred technical solution of the above technical solution, for step S1.4:

[0019] Classification head: The class label is predicted by applying convolutional layers and activation functions (such as Softmax) on the feature map. The convolutional layer converts the information in the feature map into a score for each class. The class with the highest score is the class label of the object in the target box.

[0020] The Softmax activation function converts the original scores (logits) into numerical values ​​representing probability distribution, so that the probability value of each category is between 0 and 1, and the sum of the probabilities of all categories is equal to 1. The formula is as follows:

[0021]

[0022] Where e is the base of the natural logarithm (Euler number), n is the number of categories, and z is i is the raw score of the ith category;

[0023] Regression head: used to predict the coordinate parameters and confidence score of each target box to determine the position and size of the target box. The coordinate parameters include the center coordinates, width and height of the target box. The model predicts the coordinate parameters through the regression algorithm to accurately locate the position of the target. The confidence score indicates the model's confidence in whether the target box contains the target and is used to filter the detection results.

[0024] Through the combination of the above classification head and regression head, the category, location and confidence information of the target can be accurately predicted on the feature map.

[0025] As a further preferred technical solution of the above technical solution, step S1.5 is specifically implemented as the following steps:

[0026] Step S1.5.1: Perform confidence screening. In the target box predicted by the model, first sort all the target boxes according to the confidence score and retain the target box with the highest confidence;

[0027] Step S1.5.2: Calculate the overlap. For the remaining target boxes, calculate the overlap with the target box with the highest confidence by using the Intersection over Union (IoU).

[0028] Step S1.5.3: Perform NMS operation to remove target boxes with IoU higher than the set threshold from the remaining target boxes, ensuring that no redundant target boxes with large overlap with the target box with the highest confidence are retained, and repeat this process until all target boxes are processed;

[0029] Step S1.5.4: Ensure uniqueness. After the NMS operation is completed, each retained target box (should) correspond to a unique target. If multiple target boxes highly overlap with the same target, NMS will select the target box with the highest confidence, and other target boxes will be suppressed.

[0030] As a further preferred technical solution of the above technical solution, step S2 is specifically implemented as the following steps:

[0031] Step S2.1: Perform data preparation, prepare (3000 cases) of classified single spinal vertebral X-ray image data, and standardize the data into images suitable for model input through operations including rotation and cropping;

[0032] Step S2.2: Perform data preprocessing on the extracted target frame, including scaling, cropping, and normalization operations to meet the input requirements of the U-Net network;

[0033] Step S2.3: Construct a U-Net network architecture. This U-Net network takes a 1024×512×1 image as input. Each encoder layer consists of two 3×3 convolutional layers followed by instance normalization, ReLU activation function, and 2×2 maximum pooling. Dropout is applied to each encoder-decoder stage of the network. Side outputs are generated at 128, 256, and 512 resolutions of the decoder, and then the final output is generated at the original resolution.

[0034] Step S2.4: Train the network, use the extracted target box as training data, and train the U-Net network. During the training process, optimize the network parameters through the back propagation algorithm so that the network can accurately learn the contour and structure of the vertebra;

[0035] Step S2.5: Perform segmentation prediction and input the extracted target box into the U-Net network to obtain the pixel-level labeling of the vertebral contour;

[0036] Step S2.6: Post-process the segmentation results, apply the region growing algorithm to fill the holes, and apply Gaussian filtering to remove noise and smooth the edges to obtain a more accurate and smoother segmentation result.

[0037] As a further preferred technical solution of the above technical solution, step S3 is specifically implemented as the following steps:

[0038] Step S3.1: Perform data preparation, prepare (1000 cases) of single spinal vertebral X-ray image data with feature point labels, and standardize the data into images suitable for model input through operations including rotation and cropping;

[0039] Step S3.2: Perform data enhancement, including random rotation, scaling, and flipping of the training data to increase data diversity, which is used to help the model better generalize to different vertebral postures and angles;

[0040] Step S3.3 calculates the loss function, and ensures that the loss function effectively guides the model to learn the accurate feature point positions through the mean square error (MSE) and the Euclidean distance of the key points;

[0041]

[0042] The mean square error (MSE) is the sum of the squares of the distances between the target variable and the predicted value;

[0043]

[0044] Where ρ is the Euclidean distance between point (x2, y2) and point (x1, y1);

[0045] Step S3.4: Perform model training, use the pre-trained YOLOv8 POSE model as the basic model, perform machine learning to adapt to the vertebral key point detection task, and optimize the model parameters through the back propagation algorithm to accurately identify the key feature points of the vertebrae;

[0046] Step S3.5: Apply the model and apply the trained feature point recognition network optimized for a specific vertebral type to the classified spinal segmentation data.

[0047] To achieve the above objectives, the present invention also provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the steps of the two-step spinal X-ray processing method based on single vertebrae segmentation are implemented.

[0048] To achieve the above objectives, the present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the two-step spinal X-ray processing method based on single vertebral segmentation.

[0049] Deep learning technology has led to rapid development of image segmentation methods. Compared with traditional image segmentation methods, the present invention has improved segmentation accuracy and precision, and can provide more effective information for clinicians. BRIEF DESCRIPTION OF THE DRAWINGS

[0050] Figure 1 It is a flow chart of a two-step spinal X-ray film processing method based on single vertebra segmentation of the present invention.

[0051] Figure 2 It is a schematic diagram of vertebral target frame detection using a YOLOv8 target detection model of a two-step spinal X-ray film processing method based on single vertebra segmentation of the present invention.

[0052] Figure 3 It is a schematic diagram of spinal contour recognition in the segmentation step of a two-step spinal X-ray film processing method based on single vertebra segmentation of the present invention.

[0053] Figure 4 It is the actual operation result of the feature point recognition of the double-step spine X-ray film processing method based on single vertebra segmentation of the present invention. DETAILED DESCRIPTION

[0054] The following description is used to disclose the present invention so that those skilled in the art can implement the present invention. The preferred embodiments described below are only examples, and those skilled in the art can think of other obvious variations. The basic principles of the present invention defined in the following description can be applied to other embodiments, variations, improvements, equivalents, and other technical solutions that do not deviate from the spirit and scope of the present invention.

[0055] In the preferred embodiment of the present invention, those skilled in the art should note that the X-ray images and the like involved in the present invention may be regarded as prior art.

[0056] Preferred embodiments.

[0057] like Figure 1 As shown, the present invention discloses a two-step spinal X-ray film processing method based on single vertebra segmentation, comprising the following steps:

[0058] Step S1: Use the YOLOv8 target detection model to identify the position of each single spinal vertebra in the X-ray image and generate a single vertebra target box;

[0059] Step S2: Perform detailed segmentation within each detected single vertebral target frame to accurately outline the spine;

[0060] Step S3: perform feature point recognition within a single vertebral target frame, and use the YOLOv8 POSE model to identify key feature points of the vertebrae to further improve the accuracy of feature point recognition (the YOLOv8 POSE model is a variant of the YOLOv8 model specifically used for posture estimation. The YOLOv8 model detects the position and category of an object, while the YOLOv8 POSE model further detects the posture of the object or the key points of the human body).

[0061] Specifically, step S1 is implemented as follows:

[0062] Step S1.1: Perform image preprocessing before inputting the X-ray image into the YOLOv8 target detection model, including normalization, rotation, and cropping operations to adapt to the input requirements of the model;

[0063] Step S1.2: Perform feature extraction, use the backbone network (CSPDarknet53) of the YOLOv8 target detection model to extract multi-scale features from the X-ray image, use residual blocks to deepen the network and improve the effect of feature extraction, and solve the gradient vanishing and gradient exploding problems by introducing skip connections;

[0064] Step S1.3: Perform feature fusion, using FPN (feature pyramid network) and PANet (path aggregation network) to fuse features of different scales to improve the accuracy and robustness of target detection;

[0065] Step S1.4: Perform target box prediction, using the YOLO Head module of the YOLOv8 target detection model to predict the target box, category confidence, and position offset on the feature map;

[0066] Step S1.5: Perform non-maximum suppression (NMS) to remove redundant boxes and retain only high-confidence boxes to ensure that each target box uniquely corresponds to a vertebral category.

[0067] More specifically, for step S1.3:

[0068] A top-down feature pyramid structure is constructed through FPN to extract multi-scale semantic information from feature maps at different levels to solve the problem of insufficient multi-scale information in target detection.

[0069] Through PANet, lateral connections and adaptive feature pooling mechanisms are introduced to transfer and fuse information between feature maps of different resolutions, thereby (better) utilizing the multi-scale features generated by FPN.

[0070] Furthermore, for step S1.4:

[0071] Classification head: The class label is predicted by applying convolutional layers and activation functions (such as Softmax) on the feature map. The convolutional layer converts the information in the feature map into a score for each class. The class with the highest score is the class label of the object in the target box.

[0072] The Softmax activation function converts the original scores (logits) into numerical values ​​representing probability distribution, so that the probability value of each category is between 0 and 1, and the sum of the probabilities of all categories is equal to 1. The formula is as follows:

[0073]

[0074] Where e is the base of the natural logarithm (Euler number), n is the number of categories, and z is i is the raw score of the ith category;

[0075] Regression head: used to predict the coordinate parameters and confidence score of each target box to determine the position and size of the target box. The coordinate parameters include the center coordinates, width and height of the target box. The model predicts the coordinate parameters through the regression algorithm to accurately locate the position of the target. The confidence score indicates the model's confidence in whether the target box contains the target and is used to filter the detection results.

[0076] Through the combination of the above classification head and regression head, the category, location and confidence information of the target can be accurately predicted on the feature map.

[0077] Furthermore, step S1.5 is specifically implemented as the following steps:

[0078] Step S1.5.1: Perform confidence screening. In the target box predicted by the model, first sort all the target boxes according to the confidence score and retain the target box with the highest confidence;

[0079] Step S1.5.2: Calculate the overlap. For the remaining target boxes, calculate the overlap with the target box with the highest confidence by using the Intersection over Union (IoU).

[0080] Step S1.5.3: Perform NMS operation to remove target boxes with IoU higher than the set threshold from the remaining target boxes, ensuring that no redundant target boxes with large overlap with the target box with the highest confidence are retained, and repeat this process until all target boxes are processed;

[0081] Step S1.5.4: Ensure uniqueness. After the NMS operation is completed, each retained target box (should) correspond to a unique target. If multiple target boxes highly overlap with the same target, NMS will select the target box with the highest confidence, and other target boxes will be suppressed.

[0082] Preferably, step S2 is specifically implemented as the following steps:

[0083] Step S2.1: Perform data preparation, prepare (3000 cases) of classified single spinal vertebral X-ray image data, and standardize the data into images suitable for model input through operations including rotation and cropping;

[0084] Step S2.2: Perform data preprocessing on the extracted target frame, including scaling, cropping, and normalization operations to meet the input requirements of the U-Net network;

[0085] Step S2.3: Construct a U-Net network architecture. This U-Net network takes a 1024×512×1 image as input. Each encoder layer consists of two 3×3 convolutional layers followed by instance normalization, ReLU activation function, and 2×2 maximum pooling. Dropout is applied to each encoder-decoder stage of the network. Side outputs are generated at 128, 256, and 512 resolutions of the decoder, and then the final output is generated at the original resolution.

[0086] Step S2.4: Train the network, use the extracted target box as training data, and train the U-Net network. During the training process, optimize the network parameters through the back propagation algorithm so that the network can accurately learn the contour and structure of the vertebra;

[0087] Step S2.5: Perform segmentation prediction and input the extracted target box into the U-Net network to obtain the pixel-level labeling of the vertebral contour;

[0088] Step S2.6: Post-process the segmentation results, apply the region growing algorithm to fill the holes, and apply Gaussian filtering to remove noise and smooth the edges to obtain a more accurate and smoother segmentation result.

[0089] Preferably, step S3 is specifically implemented as the following steps:

[0090] Step S3.1: Perform data preparation, prepare (1000 cases) of single spinal vertebral X-ray image data with feature point labels, and standardize the data into images suitable for model input through operations including rotation and cropping;

[0091] Step S3.2: Perform data enhancement, including random rotation, scaling, and flipping of the training data to increase data diversity, which is used to help the model better generalize to different vertebral postures and angles;

[0092] Step S3.3 calculates the loss function, and ensures that the loss function effectively guides the model to learn the accurate feature point positions through the mean square error (MSE) and the Euclidean distance of the key points;

[0093]

[0094] The mean square error (MSE) is the sum of the squares of the distances between the target variable and the predicted value;

[0095]

[0096] Where ρ is the Euclidean distance between point (x2, y2) and point (x1, y1);

[0097] Step S3.4: Perform model training, use the pre-trained YOLOv8 POSE model as the basic model, perform machine learning to adapt to the vertebral key point detection task, and optimize the model parameters through the back propagation algorithm to accurately identify the key feature points of the vertebrae;

[0098] Step S3.5: Apply the model and apply the trained feature point recognition network optimized for a specific vertebral type to the classified spinal segmentation data.

[0099] Explanation of the algorithm in the present invention:

[0100] U-Net: U-Net is a classic convolutional neural network structure, which is often used in medical image segmentation tasks. It has an encoder-decoder structure that can effectively capture the contextual information of the image. However, U-Net has difficulties in dealing with blurred boundaries and small object segmentation.

[0101] FCN (Fully Convolutional Network): FCN is a fully convolutional network that can classify the entire image at the pixel level. It can generate dense prediction results, but it faces problems with memory consumption and computational complexity when processing large-size images.

[0102] DeepLab: DeepLab is a segmentation algorithm based on dilated convolution, which captures broader contextual information by increasing the receptive field of the convolution kernel. However, DeepLab has difficulties in dealing with small structures and blurred boundaries.

[0103] Mask R-CNN: Mask R-CNN is an object detection and segmentation algorithm based on the Region Proposal Network. It can achieve object detection and segmentation at the same time, but it faces the problem of slow training and inference speed when processing large-scale data sets.

[0104] YOLO (You Only Look Once) is an object detection algorithm based on deep learning. It predicts the object boxes and categories of multiple objects in an image simultaneously through a single forward pass. Its main features are fast and accurate. However, since YOLO divides the image into grids and makes predictions, inaccurate detection may occur for small-sized objects.

[0105] The present invention also discloses an electronic device, including a memory, a processor and a computer program stored in the memory and executable on the processor. When the processor executes the program, the steps of the two-step spinal X-ray processing method based on single vertebra segmentation are implemented.

[0106] The present invention also discloses a non-transitory computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the steps of the double-step spinal X-ray film processing method based on single vertebra segmentation are implemented.

[0107] It is worth mentioning that the technical features such as X-ray images involved in the patent application of this invention should be regarded as prior art. The specific structure, working principle and possible control method and spatial layout method of these technical features can be selected by conventional methods in the field, and should not be regarded as the inventive point of this patent. This patent will not be further elaborated.

[0108] For those skilled in the art, it is still possible to modify the technical solutions described in the aforementioned embodiments, or to make equivalent substitutions for some of the technical features therein. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the protection scope of the present invention.

Claims

1. A two-step spinal X-ray processing method based on single vertebra segmentation, characterized in that: The following steps are involved: Step S1: Use the YOLOv8 target detection model to identify the position of each single spinal vertebra in the X-ray image and generate a single vertebra target box; Step S2: Perform detailed segmentation within each detected single vertebral target frame to accurately outline the spine; Step S3: Perform feature point recognition within the single vertebral target frame and use the YOLOv8 POSE model to identify key feature points of the vertebra to further improve the accuracy of feature point recognition.

2. A two-step spinal X-ray film processing method based on single vertebra segmentation according to claim 1, characterized in that: Step S1 is specifically implemented as follows: Step S1.1: Perform image preprocessing before inputting the X-ray image into the YOLOv8 target detection model, including normalization, rotation and cropping operations to adapt to the input requirements of the model; Step S1.2: Perform feature extraction, use the backbone network of the YOLOv8 target detection model to extract multi-scale features from the X-ray image, use residual blocks to deepen the network and improve the effect of feature extraction, and solve the gradient vanishing and gradient exploding problems by introducing jump connections; Step S1.3: Perform feature fusion, using FPN and PANet to fuse features of different scales to improve the accuracy and robustness of target detection; Step S1.4: Perform target box prediction, using the YOLO Head module of the YOLOv8 target detection model to predict the target box, category confidence, and position offset on the feature map; Step S1.5: Perform non-maximum suppression to remove redundant boxes and retain only high-confidence boxes to ensure that each target box uniquely corresponds to one vertebral category.

3. A two-step spinal X-ray film processing method based on single vertebra segmentation according to claim 2, characterized in that: For step S1.3: A top-down feature pyramid structure is constructed through FPN to extract multi-scale semantic information from feature maps at different levels to solve the problem of insufficient multi-scale information in target detection. The lateral connection and adaptive feature pooling mechanism are introduced through PANet to transfer and fuse information between feature maps of different resolutions, thereby utilizing the multi-scale features generated by FPN.

4. A two-step spinal X-ray film processing method based on single vertebra segmentation according to claim 3, characterized in that: For step S1.4: Classification head: The class label is predicted by applying convolutional layers and activation functions on the feature map. The convolutional layer converts the information in the feature map into a score for each class. The class with the highest score is the class label of the object in the target box. The Softmax activation function converts the original score into a numerical value representing the probability distribution, so that the probability value of each category is between 0 and 1, and the sum of the probabilities of all categories is equal to 1. The formula is as follows: Where e is the base of the natural logarithm, n is the number of categories, and z is i is the raw score of the ith category; Regression head: used to predict the coordinate parameters and confidence score of each target box to determine the position and size of the target box. The coordinate parameters include the center coordinates, width and height of the target box. The model predicts the coordinate parameters through the regression algorithm to accurately locate the position of the target. The confidence score indicates the model's confidence in whether the target box contains the target and is used to filter the detection results. Through the combination of the above classification head and regression head, the category, location and confidence information of the target can be accurately predicted on the feature map.

5. A two-step spinal X-ray film processing method based on single vertebra segmentation according to claim 4, characterized in that: Step S1.5 is specifically implemented as follows: Step S1.5.1: Perform confidence screening. In the target box predicted by the model, first sort all the target boxes according to the confidence score and retain the target box with the highest confidence; Step S1.5.2: Calculate the overlap degree. For the remaining target frames, calculate the overlap degree with the target frame with the highest confidence by using the intersection-over-union ratio. Step S1.5.3: Perform NMS operation to remove target boxes with IoU higher than the set threshold from the remaining target boxes, ensuring that no redundant target boxes with large overlap with the target box with the highest confidence are retained, and repeat this process until all target boxes are processed; Step S1.5.4: Ensure uniqueness. After the NMS operation is completed, each retained target box corresponds to a unique target. If multiple target boxes highly overlap with the same target, NMS will select the target box with the highest confidence, and other target boxes will be suppressed.

6. A two-step spinal X-ray film processing method based on single vertebra segmentation according to claim 5, characterized in that: Step S2 is specifically implemented as follows: Step S2.1: Perform data preparation to prepare the classified single spinal cone X-ray image data, and standardize the data into an image suitable for model input by including rotation and cropping operations; Step S2.2: Perform data preprocessing on the extracted target frame, including scaling, cropping and normalization operations to meet the input requirements of the U-Net network; Step S2.3: Construct a U-Net network architecture. This U-Net network takes a 1024×512×1 image as input. Each encoder layer consists of two 3×3 convolutional layers followed by instance normalization, ReLU activation function, and 2×2 maximum pooling. Dropout is applied to each encoder-decoder stage of the network. Side outputs are generated at 128, 256, and 512 resolutions of the decoder, and then the final output is generated at the original resolution. Step S2.4: Train the network, use the extracted target box as training data, and train the U-Net network. During the training process, optimize the network parameters through the back propagation algorithm so that the network can accurately learn the contour and structure of the vertebra; Step S2.5: Perform segmentation prediction and input the extracted target box into the U-Net network to obtain the pixel-level labeling of the vertebral contour; Step S2.6: Post-process the segmentation results, apply the region growing algorithm to fill the holes, and apply Gaussian filtering to remove noise and smooth the edges to obtain a more accurate and smoother segmentation result.

7. A two-step spinal X-ray film processing method based on single vertebra segmentation according to claim 6, characterized in that: Step S3 is specifically implemented as the following steps: Step S3.1: Perform data preparation, prepare single spinal cone X-ray image data with feature point labels, and standardize the data into an image suitable for model input by including rotation and cropping operations; Step S3.2: Perform data augmentation, including random rotation, scaling, and flipping of the training data to increase data diversity, which is used to help the model better generalize to different vertebral postures and angles; Step S3.3 calculates the loss function, and ensures that the loss function effectively guides the model to learn the accurate feature point position through the mean square error and the Euclidean distance of the key points; The mean square error is the sum of the squares of the distances between the target variable and the predicted value; Where ρ is the Euclidean distance between point (x2, y2) and point (x1, y1); Step S3.4: Perform model training, use the pre-trained YOLOv8 POSE model as the basic model, perform machine learning to adapt to the vertebral key point detection task, and optimize the model parameters through the back propagation algorithm to accurately identify the key feature points of the vertebrae; Step S3.5: Apply the model and apply the trained feature point recognition network optimized for a specific vertebral type to the classified spinal segmentation data.

8. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the program, the steps of the double-step spinal X-ray processing method based on single vertebral segmentation as described in any one of claims 1 to 7 are implemented.

9. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the double-step spinal X-ray film processing method based on single vertebra segmentation as claimed in any one of claims 1 to 7 are implemented.

Citation Information

Patent Citations

  • Improved YOLOv3 algorithm based on activation function

    CN112364974A

  • Scoliosis progress prediction method based on X-ray film and scoliosis progress prediction device based on X-ray film

    CN113781453A

  • Lightweight YOLOv4 construction site safety helmet wearing detection method and device

    CN113989852A

  • X-ray spine image key point detection and identification method

    CN114463298A

  • Method for detecting target object grabbed by mechanical arm based on improved YOLOv5 algorithm

    CN116630602A

Cited By

  • Spine image recognition method and related equipment

    CN120782706A

  • H-shaped steel attitude estimation system and method based on monocular camera and readable storage medium

    CN121259102A