Efficient threat detection in X-ray cargo inspection is critical for the security of the global supply chain. This study evaluates YOLO-based object-detection models from YOLOv5 to the latest, YOLOv11, which is enhanced with modified loss functions and Soft-NMS to improve accuracy. The YOLO model comparison also includes DETR (Detection Transformer) and Faster R-CNN (Region-based Convolution Neural Network). Standard loss functions struggle with overlapping items, low contrast, and small objects in X-ray imagery. To overcome these weaknesses, IoU-based loss functions—CIoU, DIoU, GIoU, and WIoU—are integrated into the YOLO frameworks. Experiments on a dedicated cargo X-ray dataset assess precision, recall, F1-score, mAP@50, mAP@50–95, GFLOPs, and inference speed. The enhanced model, YOLOv11 with WIoU and Soft-NMS, achieves superior localization, reaching 98.44% mAP@50. This work highlights effective enhancements for YOLO models to support intelligent logistics in transportation services and automated threat detection in cargo security systems.
Tee et al. (Mon,) studied this question.