Contraband detection method for X-ray security images based on generative sparsity
By improving the sparse object detection algorithm, the dynamic filtering fusion module, Top-K matching strategy and IoU perceived loss function are used to solve the problem of insufficient accuracy of contraband detection in X-ray security images, and more efficient contraband detection is achieved.
Patent Information
- Application Number
- CN202510772195.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-11
- Publication Date
- 2025-08-22
- Estimated Expiration
- 2045-06-11
AI Technical Summary
The existing sparse object detection algorithm DiffusionDET is generally used in X-ray security images to detect contrabands, especially when dealing with overlapping, similar backgrounds and hidden contrabands.
By introducing dynamic filtering fusion module DFF, Hungarian Top-K matching strategy HMK and IoU-aware classification loss function ACR-Loss, DiffusionDET is improved, feature extraction and label allocation are optimized, and detection accuracy is improved.
It improves the detection accuracy and efficiency of contraband in X-ray security images, reduces the impact of hyperparameters on the detection results, and enhances the robustness of the model.
Smart Images

Figure CN120339264B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the fields of deep learning and target detection. Specifically, the present invention proposes a method for detecting contraband in X-ray security inspection images based on generative sparsity. Background Art
[0002] With the increase in passenger volume, the use of X-rays for security inspections has become a key technology for ensuring people's safety in public places. X-rays have the ability to see through things, which can help security personnel detect potential contraband in luggage backpacks. However, due to the influence of perspective, X-ray security images exhibit different characteristics from natural light images, including: (1) Overlapping: Items stacked together in luggage backpacks will overlap in the image under X-ray irradiation, causing the surface texture of the items in the image to become blurred; (2) Background similarity: Because the materials of some contraband in X-ray security images are very similar to those of background items, the contraband in the X-ray image is very similar to the background, and it is easy to be treated as background during the detection process; (3) Concealment: Some contraband in X-ray security images are small in size and overlap with other items, making them difficult to be detected by the system.
[0003] With the development of deep learning object detection technology, contraband detection in X-ray security images has become automated. Common detection frameworks include single-stage object detection, two-stage object detection, and sparse object detection. Among sparse object detection algorithms, the diffusion model-based object detection algorithm, DiffusionDET, demonstrates excellent scalability, real-time performance, and accuracy. However, when using DiffusionDET for X-ray contraband detection, its performance is mediocre. Summary of the Invention
[0004] To address the above issues, this paper proposes a contraband detection method for X-ray security inspection images based on generative sparsity. This method optimizes and improves DiffusionDET. By optimizing and improving DiffusionDET's dynamic instance interaction module, label assignment algorithm, and loss function, the system improves the detection accuracy of contraband in X-ray security inspection images. Specifically, a dynamic filtering and fusion module (DFF) is designed to iteratively filter region-of-interest features in the vertical and horizontal directions to extract spatial coordinate information from the feature map. Next, a label assignment strategy (HMK) is designed that is intermediate between one-to-one and one-to-many. Through global matching, K equally important optimal positive samples are found for each ground-truth bounding box (GT). Finally, a new IoU-aware classification loss function (ACR-Loss) is designed that emphasizes the importance of spatial information. By incorporating the ratio of IoU to classification loss into the classification loss function, the model focuses on samples whose classification and localization are inconsistent, thereby improving detection performance. This method utilizes a dynamic filtering and fusion module, an advanced label assignment strategy, and an optimized training loss function. This method aims to improve the accuracy and efficiency of contraband detection in security inspection applications.
[0005] The method for detecting contraband in X-ray security inspection images based on generative sparsity improvement includes the following steps:
[0006] Step (1) first obtains an X-ray security inspection image dataset containing target bounding boxes and category annotations, divides the dataset into a training set and a validation set, and preprocesses the images; and successively uses the ResNet backbone and feature pyramid structure to extract multi-level features in the security inspection images.
[0007] Step (2) uses the diffusion model to generate a noisy plan box noisepb. And uses noisepb to generate the region of interest feature roif and the context-aware feature representation spf.
[0008] Step (3) replaces the dynamic instance interaction part of the diffusion model DiffusionDET with the dynamic filtering fusion module DFF. DFF further refines the features during the iterative filtering process and selects the appropriate roif and spf through dynamic parameter screening operations. After that, the features are spliced to generate the refined feature map objf, and the target prediction box and the corresponding category score are obtained.
[0009] In step (4), during the label assignment phase, the Hungarian Top-K matching strategy (HMK) is used to replace the original assignment strategy. Through global matching, K equally important optimal positive samples are found for each ground truth GT. This improves the model recall rate while reducing the impact of hyperparameters on the final detection results, thereby enhancing the robustness of the model.
[0010] In step (5), the training parameters are set and the DiffusionDET loss function is replaced with the new loss function ACR-Loss. The multi-level features generated in step (1) are input into the model constructed by steps (2)-(4) for iterative training. The model is then validated on the validation set to obtain the optimal parameter model and output the contraband detection effect diagram.
[0011] Furthermore, step (2) is specifically:
[0012] (2-1) Generate anchor box samples using the diffusion model.
[0013] (2-1-1) In the forward noise addition stage, the model adds Gaussian noise to the ground truth GT to generate a noisy plan frame, denoted as noisepb. Specifically, set x0 = {cx, cy, w, h}, where cx, cy, w, h represent the center coordinates of the plan frame and the width and height of the plan frame respectively, and calculate the corresponding x t , here x t =noisepb.
[0014] (2-1-2) In the inference phase, we first create the reverse time pair tp = [(T-1, T-2), (T-2, T-3), ..., (1, 0), (0, -1)], where T represents the final moment. Then, for each time pair (t now ,t next ), the diffusion model uses the current time point t now noisepb on t next The noisepb at that time point is then sampled using the noise reduction diffusion latent model (DDIM) to reduce the noisepb noise and calculate the corresponding bounding box, i.e., the anchor box:
[0015] (2-2) Apply the region of interest alignment RoIAlign operation on the multi-level feature map {P2, P3, P4, P5} to extract the region of interest feature roif corresponding to the anchor box from the feature map.
[0016] (2-3) The self-attention mechanism is adopted to perform cross-attention mechanism feature aggregation on all features roif to realize information interaction between features, thereby obtaining a context-aware feature representation spf.
[0017] Furthermore, step (3) is specifically:
[0018] (3-1) First, a fully connected network is used to map the feature spf into the parameter space to obtain the dynamic filter parameter dfp. Then, through kernel segmentation technology, dfp is split into two independent parameters: dfv responsible for the vertical direction and dfh responsible for the horizontal direction.
[0019] (3-2) The CA attention mechanism is used to extract features from roif and generate the feature map ROICAf. The vertical filter parameter dfv and the horizontal filter parameter dfh are then used to filter the feature region of interest using the CA attention mechanism, respectively, to obtain the filtered features xfv and xfh.
[0020] (3-3) The filtered features xfh and xfv are concatenated and processed by a nonlinear activation module. Finally, the result is mapped back to the feature space to obtain the refined feature objf after filtering and fusion.
[0021] (3-4) Use MLP to perform corresponding scaling and translation operations on objf, and then calculate the prediction score and prediction box.
[0022] Furthermore, step (4) is specifically:
[0023] (4-1) HMK calculates the cost loss based on the prediction score, prediction box, GT real box and GT label, including the cost classification loss Cost reversion loss and the cost bounding box loss During the calculation process, the center point of the predicted box is checked to see if it is within the ground-truth bounding box and within a circle with a radius of 2.5, centered around the ground-truth bounding box. This means that the predicted box center is within five unit squares around the ground-truth bounding box center. Predicted boxes whose center points are not within the ground-truth bounding box or within the radius of its center are penalized.
[0024] (4-2) Calculate the IoU value between the predicted box and the ground truth. By summing these IoU values, HMK determines the number of positive samples dk required for each ground truth. Then, based on dk, the column corresponding to each ground truth in the total loss is expanded dk times to construct the final loss matrix.
[0025] (4-3) Use the Hungarian algorithm to find the dk positive sample boxes that each GT needs to match based on the loss matrix. This process ensures that each GT can be effectively matched with a certain number of prediction boxes, thereby improving the accuracy and recall of target detection.
[0026] Compared with the prior art, the present invention has the following beneficial effects:
[0027] The present invention improves the performance of the generative sparse object detection network in X-ray security inspection images by improving it. Specifically, the present invention first introduces a new dynamic filtering fusion module DFF in the iterative filtering process, which filters out useless background features and impurities in the horizontal and vertical directions and retains the refined features used for detection. Then, a Hungarian Top-K matching strategy HMK is adopted to perform a pair of K matching in the global label matching process, which improves the detection recall rate and reduces the influence of hyperparameters on the detection results. Finally, a new IoU-aware classification loss function ACR-Loss that emphasizes the importance of spatial information is utilized. By introducing spatial information consistency, the model's dependence on prediction confidence is reduced. Compared with existing sparse detection algorithms, the present invention performs well both in terms of X-ray contraband detection accuracy and timeliness. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] Figure 1 is a process flow chart of the present invention;
[0029] Figure 2 Assign a schematic diagram to the HMK tag. DETAILED DESCRIPTION
[0030] In order to better understand the purpose, structure and function of the present invention, the technical solution of the present invention is further described in detail below with reference to the accompanying drawings. The present invention proposes a method for detecting contraband in X-ray security inspection images based on generative sparsity. The overall process is as follows: Figure 1 As shown. First, the present invention designs a dynamic filtering fusion module DFF. By iteratively filtering the feature map of the region of interest in the vertical and horizontal directions, the spatial coordinate information in the feature map is extracted. Then, a label assignment strategy HMK between one-to-one and one-to-many is adopted. Figure 2 As shown. This strategy uses global matching to find K equally important optimal positive samples for each GT. This method not only improves the recall rate, but also reduces the impact of hyperparameters on the final detection results, thereby enhancing the robustness of the model. Finally, a new IoU-aware classification loss function, ACR-Loss, which emphasizes the importance of spatial information, is used. ACR-Loss helps the model pay more attention to samples whose classification and positioning are inconsistent by adding the ratio of IoU to classification loss to the classification loss function, thereby improving detection performance. Compared with previous sparse target detection algorithms, the present invention has greatly improved the accuracy of detecting contraband.
[0031] The method of the present invention comprises the steps of:
[0032] Step (1) first obtains an X-ray security inspection image dataset containing target bounding boxes and category annotations, divides the dataset into a training set and a validation set, and preprocesses the images; uses the ResNet backbone to extract multi-level features from the images. Specifically:
[0033] (1-1) The image collection is divided into two main parts: one part is used for model training, namely The other part is used to verify the accuracy of the model, i.e. Among them, R is the real number field, N t represents the number of image samples in the training set, represents the i-th training image sample, N v represents the number of image samples in the validation set, represents the jth verification image sample, H represents the image height, W represents the image width, and 3 represents the number of RGB channels;
[0034] (1-2) Each training sample Corresponding tags in Represents an image sample The number of targets contained in express Middle The true categories of the targets, where C represents the total number of categories in the dataset, express Middle The bounding box of an object consists of the horizontal coordinate x of the center point, the vertical coordinate y of the center point, the width w of the object, and the height h.
[0035] (1-3) Before formal training, a series of data augmentation operations are performed on the images. This involves randomly selecting four images from the training set, performing a series of transformations such as flipping, scaling, and adjusting hue, and then concatenating these images into a new sample while preserving their original labels. Furthermore, the images are resized to a uniform size of 640×640 pixels and pixel values are normalized to ensure consistency and validity of the model input.
[0036] (1-4) Use ResNet to image X t Perform feature extraction, and then use the feature pyramid structure to generate multi-level feature maps from P2 to P5, namely {P2, P3, P4, P5}.
[0037] Step (2) uses the diffusion model to generate a noisy plan frame noisepb. And uses noisepb to generate the region of interest feature roif and the context-aware feature representation spf. Specifically:
[0038] (2-1) Generate anchor box samples using the diffusion model.
[0039] (2-1-1) In the forward noise addition phase, the model adds Gaussian noise to the ground truth GT, thereby generating a noisy prediction frame, denoted as noisepb. Specifically, set x0 = {cx, cy, w, h} and use the following formula to calculate the corresponding x t , here x t =noisepb.
[0040]
[0041] where α t is a hyperparameter, setting the variance scheduling variable And 0<β1<β2<…<β T <1, then α t =1-β t and
[0042] where ∈ t-1 ,∈ t-2 ,…~N(0,I), It means merging two Gaussian functions with different variances. That is, for two Gaussian functions, and The new distribution after addition and merging is Its variance is expressed as: (1-α t )+α t (1-α t-1 )=1-α t α t-1 .
[0043] (2-1-2) In the inference phase, we first create the reverse time pair tp = [(T-1, T-2), (T-2, T-3), ..., (1, 0), (0, -1)], where T represents the final moment. Then, for each time pair (t now ,t next ), the diffusion model uses the current time point t now noisepb on t next The noisepb at that time point is then sampled using the DDIM algorithm to reduce the noise, and the corresponding anchor box is calculated according to the following formula:
[0044]
[0045] (2-2) Apply the region of interest alignment RoIAlign operation on the image feature map {P2, P3, P4, P5} to extract the region of interest feature roif corresponding to the anchor box from the feature map.
[0046] (2-3) The self-attention mechanism is adopted to perform feature aggregation on all features roif to realize information interaction between features, thereby obtaining a context-aware feature representation spf.
[0047] Step (3) replaces the dynamic instance interaction part of the diffusion model DiffusionDET with the dynamic filtering fusion module DFF. DFF further refines the features during the iterative filtering process and selects the appropriate roif and spf through dynamic parameter screening operations. After that, the features are spliced to generate the refined feature map objf.
[0048] Specifically:
[0049] (3-1) First, a fully connected network is used to map the feature representation spf into the parameter space to obtain the dynamic filter parameter dfp. Then, through kernel segmentation technology, dfp is split into two independent parameters: dfv responsible for the vertical direction and dfh responsible for the horizontal direction.
[0050] (3-2) Use the CA attention mechanism to extract features from roif and generate a feature map. Then use the vertical filtering parameter dfv and the horizontal filtering parameter dfh to filter the feature interest region using the CA attention mechanism to obtain the filtered features xfv and xfh.
[0051] (3-3) The filtered features xfh and xfv are concatenated and processed by a nonlinear activation module. Finally, the result is mapped back to the feature space to obtain the refined feature objf after filtering and fusion.
[0052] (3-4) Use MLP to perform corresponding scaling and translation operations on objf, and then calculate the prediction score and prediction box.
[0053] Step (4) In the label assignment phase, the HMK strategy is used to replace the original assignment strategy. Through global matching, K equally important optimal positive samples are found for each GT. While improving the model recall rate, it also reduces the impact of hyperparameters on the final detection results, thereby enhancing the robustness of the model. Specifically:
[0054] (4-1) HMK calculates the cost loss based on the prediction score predLogits, prediction box predBoxes, GT real box gtBoxes and GT label gtLabels, including the cost classification loss Cost reversion loss and the cost bounding box loss During the calculation process, the center point of the predicted box predBoxes is checked to see if it is within the GT real box gtBoxes and within a circle with a radius of 2.5 centered on the center of the GT real box. That is, the center point of the predicted box is checked to see if it is within 5 unit squares around the center of the GT real box. Predicted boxes predBoxes whose center points are not within the GT real box or are not within the radius of its center are penalized.
[0055] (4-2) Cost Classification Losses The FocalLoss(·) loss function is used for calculation:
[0056]
[0057] Where α is a weight factor used to adjust the weight balance between difficult and easy samples, giving higher weight to samples that are difficult to classify. p represents the probability that the current prediction target is a positive sample. 1-p represents the probability that the prediction is a negative sample. γ is a hyperparameter used to adjust the model's attention to difficult and easy samples. When γ increases, the model pays more attention to difficult-to-classify samples. Cost regression loss The L1(·) loss function is used for calculation. Cost bounding box loss Calculated using the GIoU(·) loss function:
[0058]
[0059] Where IOU(Ar,GT) represents the IoU between the anchor box Ar and the GT. Enclosing represents the minimum enclosed area between Ar and the GT. The total loss is obtained by summing all these losses.
[0060] (4-3) Calculate the Intersection over Union (IoU) between the predicted boxes predBoxes and the ground truth. By summing these IoU values, HMK determines the number of positive samples dk required for each ground truth. Then, based on dk, the column corresponding to each ground truth in the total loss is expanded dk times to construct the final loss matrix.
[0061] (4-4) Use the Hungarian algorithm to find the dk positive sample boxes that each GT needs to match based on the loss matrix. This process ensures that each GT can be effectively matched with a certain number of predicted boxes, thereby improving the accuracy and recall of object detection.
[0062] In step (5), set the training parameters and replace the DiffusionDET loss function with the new loss function ACR-Loss. Input the features generated in step (1) into the model constructed by steps (2)-(4) for iterative training. Validate on the validation set to obtain the optimal parameter model and output a contraband detection effect diagram.
[0063] Specifically:
[0064] (5-1) In the early stages of model training, a set of key hyperparameters need to be set, such as the initial learning rate, momentum factor, learning rate decay rate, batch size, number of GPUs used, selected optimization algorithm, and total number of training rounds.
[0065] (5-2) Set a new IoU-aware loss function ACR-Loss for model iterative training. The ACR-Loss loss function is:
[0066]
[0067] in, represents the classification loss function, Using GIoU loss calculation function, L1 bounding box regression loss is used. Specifically, The classification loss function is:
[0068]
[0069] Where t = cls α *iou 1-α , iou is the iou value obtained by target detection, BCE is the binary cross entropy function, cls i is the classification value. Regression loss for:
[0070]
[0071] Among them, pred box Represents the prediction box, gt box Represents the true annotation box.
[0072] (5-3) Input the prepared dataset into the model framework constructed in the previous steps and perform multiple rounds of training. During training, the model's performance on the validation set is continuously monitored using the mAP50 metric. Whenever the best mAP50 value is achieved during training, the corresponding model configuration is recorded and saved as the optimal parameters. This approach helps find the optimal parameter combination during training, thereby improving the model's prediction accuracy.
[0073] (5-4) After the training is completed, the validation set is used to verify the optimal model obtained in step (5-1), and the index parameters of the final model for detecting the data set are obtained. The category of the detected contraband and the confidence level are marked on the detection results.
[0074] The above embodiments have been described in detail to illustrate the objectives, technical solutions, and advantages of the present invention. It should be understood that these embodiments represent only some preferred implementations of the present invention and are not intended to limit its scope. Any modification, equivalent replacement, or improvement, subject to the core concepts and principles of the present invention, should be considered to be within the scope of protection of the present invention.
[0075] Experimental comparison description:
[0076] SparseGenX uses ResNet-50 as the feature extraction backbone, denoted as SparseGenX-R; it uses Swin-T as the feature extraction backbone, denoted as SparseGenX-S. Unless otherwise specified, SparseGen defaults to SparseGenX-R.
[0077] Table 1 Comparison results of SparseGenX and other SOTA algorithms on CLCXray
[0078]
[0079] As shown in Table 1, SparseGenX-S achieves the best detection performance on the CLCXray test set with an mAP50 accuracy of 89.7%. SparseGenX-S achieves the highest detection rate for prohibited items such as daggers, plastic bottles, cans, glass bottles, and tin cans. SparseGenX also outperforms other algorithms of the same type when detecting other prohibited items. Furthermore, a comparison of SparseGenX-R and SparseGenX-S shows that SparseGenX-S achieves a detection rate of 33.7% for glass bottles and 94.1% for plastic bottles. This demonstrates that using shape features is more effective than relying on texture features when identifying prohibited items that resemble the background. Compared to Sparse R-CNN’s 87.6% and YOLOv7u6’s 86.2% detection results, SparseGenX-S outperforms them by 2.1% and 3.5% respectively.
[0080] Table 2 Comparison results of SparseGenX and other algorithms on the WIXray dataset
[0081]
[0082]
[0083] Table 2 shows the detection results of SparseGenX on the WIXray dataset compared with Faster R-CNN, Sparse R-CNN, and DiffusionDET. The results show that when SparseGenX uses ResNet-50 as its feature extraction backbone, its mAP reaches 46.8% and its mAP50 reaches 64.0%. Compared with DiffusionDET, its mAP and mAP50 improve by 2.2% and 0.2%, respectively. When SparseGenX uses the larger ResNet-101, its mAP and mAP50 improve by 2.7% and 1.4%, respectively, compared with ResNet-50, 0.6% and 0.5% compared with Sparse R-CNN, and 6% and 3% compared with Faster R-CNN. This result highlights that the SparseGenX algorithm still has certain advantages when processing other background-similar X-ray images.
Claims
1. A method for detecting contraband in X-ray security inspection images based on generative sparsity, characterized by: The following steps are involved: Step 1: Obtain an X-ray security inspection image dataset containing target bounding boxes and category annotations, and use the ResNet backbone and feature pyramid structure to extract multi-level features from the security inspection images; Step 2: Generate a noisy pre-plan frame using the diffusion model; and use the pre-plan frame to generate the region of interest feature roif and the context-aware feature representation spf; Step 3: Replace the dynamic instance interaction of the diffusion model DiffusionDET with the dynamic filtering fusion module DFF to generate the refined feature map objf and obtain the target prediction box and the corresponding category score. The specific implementation process is as follows: Step 3-1: First, a fully connected network is used to map the feature representation spf into the parameter space to obtain the dynamic filter parameter dfp. Then, using kernel segmentation technology, dfp is split into two independent parameters: dfv responsible for the vertical direction and dfh responsible for the horizontal direction. Step 3-2: Use the CA attention mechanism to extract features from roif and generate a feature map. Then, use the vertical filter parameter dfv and the horizontal filter parameter dfh to filter the feature interest region using the CA attention mechanism to obtain the filtered features xfv and xfh. Step 3-3, concatenate the filtered features xfv and xfh, process them through a nonlinear activation module, and finally map the results back to the feature space to obtain the refined features objf after filtering and fusion; Step 3-4: Use MLP to perform corresponding scaling and translation operations on objf, and then calculate the prediction score and prediction box; Step 4: In the label assignment phase, the Hungarian Top-K matching strategy (HMK) is used to find K equally important optimal positive samples for each ground truth GT through global matching. Step 5: Construct a loss function and input the multi-level features in step 1 into the model constructed by steps 2-4 for iterative training. Verify the model on the validation set and output a contraband detection effect diagram.
2. The method for detecting contraband in X-ray security inspection images based on generative sparsity according to claim 1, characterized in that: In the step 1, specifically, the steps include obtaining an X-ray security inspection image dataset containing target bounding boxes and category annotations, dividing the dataset into a training set and a validation set, and performing data enhancement on the images through preprocessing; using a ResNet backbone to extract features from the image, and then using a feature pyramid structure to obtain multi-level features {P2, P3, P4, P5}.
3. The method for detecting contraband in X-ray security inspection images based on generative sparsity according to claim 2, characterized in that: The specific implementation process of step 2 is as follows: Step 2-1: Generate anchor box samples using the diffusion model; Step 2-2, apply the region of interest alignment RoIAlign operation on the image feature map {P2, P3, P4, P5} to extract the region of interest feature roif corresponding to the anchor box from the feature map; Step 2-3: Use the self-attention mechanism to perform cross-attention mechanism feature aggregation on all feature roifs. Realize information interaction between features and obtain context-aware feature representation spf.
4. The method for detecting contraband in X-ray security inspection images based on generative sparsity according to claim 3, characterized in that: The specific process of generating anchor box samples using the diffusion model is as follows: Step 2-1-1: In the forward noise addition phase, the diffusion model adds Gaussian noise to the ground truth GT to generate a noisy plan frame noisepb. Specifically, set x0 = {cx, cy, w, h}, where cx, cy, w, and h represent the center coordinates of the plan frame and the width and height of the plan frame, respectively, and calculate the corresponding noisepb. Step 2-1-2: In the inference phase, create a reverse time pair tp = [(T-1, T-2), (T-2, T-3), ..., (1, 0), (0, -1)], where T represents the final moment; then for each time pair (t now ,t next ), the diffusion model uses the current time point t now noisepb on t next noisepb at a given time point; then the noise reduction diffusion latent model DDIM is used to perform noise reduction sampling on noisepb and calculate the corresponding anchor frame.
5. The method for detecting contraband in X-ray security inspection images based on generative sparsity according to claim 4, characterized in that: The specific implementation process of step 4 is as follows: Step 4-1: HMK calculates the cost loss based on the prediction score, prediction box, GT ground truth box, and GT label, including cost classification loss, cost regression loss, and cost bounding box loss. During the calculation process, it determines whether the center point of the predicted box is within the GT ground truth box and whether it is within a circle with a radius of 2.5 units centered on the GT ground truth box. Penalize the predicted box whose center point is not in the GT real box or is not within its center radius; Step 4-2: Calculate the IoU value between the predicted box and the GT. By summing the IoU values, HMK determines the number of positive samples dk required for each GT. Then, based on dk, expand the column corresponding to each GT in the total loss dk times to construct the final loss matrix. Step 4-3: Use the Hungarian algorithm to find the dk positive sample boxes to be matched for each GT based on the loss matrix. This process ensures that each GT can be effectively matched with the predicted box.
Citation Information
Patent Citations
X-ray contraband detection method based on contour perception and optimal distribution migration
CN119888616A
KR20250042625A