## 1 Introduction  
X-ray technology plays a crucial role in enhancing the security of public transportation systems. By penetrating luggage and other items under inspection with X-rays, these inspection systems can reveal their contents without resorting to opening them, making these systems an essential tool for finding prohibited or dangerous items hidden within. X-ray machines operate by emitting X-rays, a type of electromagnetic radiation, which pass through objects and are captured by a detector on the opposite side. Materials absorb X-rays differently based on their density and composition, creating detailed images that reveal much about an object's internal structure and contents [1]. The capacity of X-ray technology to visualize the internal composition of items without the need for direct manual examination makes it essential for security purposes. This technology ensures safety by preventing various threats from entering secure areas, such as airports, train stations, and subway systems, thereby protecting passengers and infrastructures. X-ray technology significantly increases the accuracy of inspection processes. Unlike manual inspections, which can be time-consuming and sensitive to human error, X-ray systems provide a fast and reliable way to check the contents of luggage and the objects under inspection. They produce detailed images that allow security personnel to quickly identify suspicious items, such as weapons and explosive materials, ensuring threats are intercepted before posing a risk to public safety [2; 3]. In recent applications of deep learning to X-ray imagery for security screening and medical diagnostics, researchers have utilised advanced techniques like denoising and super-resolution to enhance image quality [4; 5]. These techniques enable the extraction of more detailed information from X-ray images, leading to better diagnostic accuracy and efficiency. By employing sophisticated algorithms such as convolutional neural networks (CNNs), deep learning provides a more precise detection [6; 7] and classification of features within X-ray images than traditional methods can achieve. Multitask contrastive learning can also be employed for automatic X-ray diagnosis. Innovative frameworks have been introduced to distinguish COVID-19 from other pneumonia types through X-ray analysis [8]. Strategies to enhance deep learning model detection accuracy and address complex challenges in training and testing include modifying activation functions in deep CNNs, employing transfer learning [9; 10], utilising image inpainting [11; 12], and applying models to tasks such as cancer diagnosis, detection [13], and classification, material discrimination [14], medical question-answering [15; 16], and software engineering applications like optimizing project schedules, customer segmentation [17; 18], and IoT intrusion detection [19; 20]. Unique approaches, such as creatively combining activation functions and optimization systems, contribute to the advancement of deep learning models. As a result, deep learning models have become integral in various aspects of computer vision. In the medical sector, this technology facilitates the accurate diagnosis of diseases by recognizing subtle patterns indicative of various health issues, thereby enhancing patient care with timely and precise diagnoses [21; 22]. In security, deep learning automates the detection of prohibited items in scanned objects, considerably boosting both the accuracy and speed of security screenings. These advancements demonstrate the critical role of deep learning in refining X-ray imaging techniques, making it a crucial tool in improving healthcare outcomes and enhancing security measures. In the realm of security, deep learning applications are becoming more common. Convolutional neural network (CNN)-based techniques, including Faster Region-Based CNN (Faster RCNN) [23] and You Only Look Once version (YOLOv) [24] have been adapted for detecting firearms in X-ray images.