A spinal vertebral segmentation method based on an improved AFFormer network
Objective To propose an improved AFFormer model for accurate segmentation of spinal vertebrae,which assists physicians in quickly diagnosing scoliosis.Methods The dataset in this article is a full spine orthopedic X-ray,with an image size of approximately 5 000×8 000.Considering the characteristics of large image size,small foreground area,large background area,and large individual differences among subjects but small differences in the same part,the light-weight semantic segmentation model AFFormer is used for spinal segmentation.In response to the phenomenon of losing a large amount of detail information in deep feature maps,when modeling local details in features using pixel semantics,a branch output 8-channel feature map is concatenated on the basis of the original 16 dimensional feature map to achieve multi-scale feature fusion,thereby learning more detail information.The dataset consists of 146 clinical orthopedic full spine X-ray images from a certain hospital.After pixel level annotation using the labelme tool,the images are randomly divided into a training set(117 images),a validation set(15 images),and a testing set(14 images)in an 8∶1∶1 ratio.When training the network,the weighted sum of cross entropy,Dice coefficient,and a custom score function that adds prior knowledge is used as the loss function to optimize model training.On the validation set,we use the average intersection to union ratio and average accuracy for testing,further adjust the hyperparameters of the model,and preliminarily evaluate the models to select the best performing model.Results The model trained using the proposed method is tested on the test set and achieves the highest mIoU value(0.867 8)and mAcc value(0.923 2).Conclusions The method proposed in this article has been experimentally proven to have better segmentation performance than existing mainstream segmentation models,and can achieve precise segmentation of the spinal vertebrae,providing a solid foundation for assisting in spinal medical diagnosis.
spinal segmentationauxiliary medical treatmentTransformer structuremulti-scale feature