A method for testing the compliance of reflective vests worn by general aviation training flight trainees
By optimizing the YOLOv11 model and introducing a multi-expansion rate residual module and a context aggregation module, combined with dynamic spatial association rules that adapt to the target scale, the accuracy and robustness issues in the detection of reflective vests for general aviation training flight students were resolved, achieving efficient and accurate detection of wear compliance.
Patent Information
- Application Number
- CN202511826224.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-05
- Publication Date
- 2026-03-06
- Estimated Expiration
- 2045-12-05
AI Technical Summary
Existing technologies for detecting compliance issues in the wearing of reflective vests by general aviation training flight trainees suffer from low accuracy in detecting small targets, insufficient fine-grained differentiation, and poor robustness, making it impossible to achieve high-precision, high-efficiency, and fully automated supervision.
A target detection network based on the YOLOv11 model is constructed. By introducing three-scale detection heads (P2, P3, and P4), a multi-expansion rate residual module, and a context aggregation module, the network architecture is optimized, and an adaptive target scale dynamic spatial association rule is adopted for intelligent judgment.
It significantly improves detection accuracy and robustness in complex environments, can accurately distinguish between compliant and non-compliant statuses, achieves efficient and accurate automated supervision, and reduces the rate of missed detections and false detections.
Smart Images

Figure CN121259466B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of target detection technology, specifically to a method for detecting the compliance of reflective vests worn by general aviation training flight trainees. Background Technology
[0002] General aviation flight training grounds are high-risk areas where trainees and aircraft operate together. Therefore, the standardized wearing of highly visible reflective vests to improve visibility and ensure safety has become a basic safety management regulation. However, traditional safety supervision methods mainly rely on manual inspections, which are inefficient, have limited coverage, are susceptible to subjective factors, and cannot meet the stringent requirements of modern civil aviation for real-time, accurate, and comprehensive safety monitoring.
[0003] In recent years, with the rapid development of computer vision and deep learning technologies, target detection algorithms, represented by the YOLO (You Only Look Once) series, have achieved remarkable results in image recognition and localization. These algorithms have been applied to target recognition at airports and the detection of personal protective equipment (PPE) in other scenarios, demonstrating the feasibility of intelligent supervision.
[0004] However, applying existing visual inspection technologies to detect compliance issues with reflective vests worn by general aviation training pilots still faces numerous challenges. Firstly, monitoring at general aviation training grounds is often conducted from a long distance, resulting in extremely small targets, including pilots and their reflective vests. These subtle features are easily lost during deep network downsampling and are susceptible to interference from complex backgrounds and environments, leading to high rates of missed and false detections of small targets, severely impacting detection accuracy and robustness. Secondly, most existing technologies can only identify the presence or absence of reflective vests, but cannot distinguish between "standard wearing" and "casual wearing" (such as unfastened buttons, slipped shoulder straps, or vests pulled down to the waist), posing a significant safety hazard in practical applications.
[0005] In summary, existing technologies for intelligent detection of compliance in wearing reflective vests by general aviation training flight students have significant shortcomings in terms of small target detection accuracy, fine-grained state differentiation, and robustness to changes in target scale. They fail to provide a comprehensive solution that is highly accurate, efficient, and fully automated, and technological innovation is urgently needed to overcome these deficiencies. Summary of the Invention
[0006] To address the aforementioned problems, this invention aims to provide a method for detecting the compliance of reflective vests worn by general aviation training flight trainees. This method achieves efficient, accurate, and fully automated detection of the wearing status of reflective vests by general aviation training flight trainees, effectively improving the accuracy and robustness of small target detection, and intelligently determining fine-grained compliance. This invention includes the following steps:
[0007] Step 1: Collect monitoring video data of the flight training field covering different time periods, different weather conditions and complex backgrounds, and preprocess the video frame images;
[0008] Step 2: Perform fine-grained annotation on the preprocessed image data to obtain a dataset containing three types of targets: people, compliantly worn reflective vests, and non-compliantly worn reflective vests;
[0009] Step 3: Divide the labeled dataset into training, validation, and test sets according to the specified proportions;
[0010] Step 4: Build and train the object detection model: Perform targeted structural optimization on the benchmark YOLOv11 model, following the encoder-decoder paradigm, including the backbone network, neck network, and detection head;
[0011] A P2 feature layer is introduced into the detection head, and the detection scale is adjusted to P2, P3, P4;
[0012] In the neck network between the encoder and decoder, a multi-diffraction residual module is used to aggregate multi-scale receptive field features by using dilated convolutions with different dilation rates in parallel.
[0013] Before the detection head makes the final prediction for each scale feature layer, a context aggregation module is integrated to fuse global context information to modulate local features; finally, the constructed target detection model is trained.
[0014] Step 5: Intelligent determination of wear compliance based on the trained target detection model: Inference is performed on a test image to obtain the preliminary detection results of the three types of targets; Adaptive target scale dynamic spatial association rules are used to match spatially associated reflective vest targets for each detected personnel target. The dynamic spatial association rules comprehensively consider the center point distance and intersection-union ratio between targets; Based on the preset multi-class matching priority, the wear compliance of the reflective vest is determined.
[0015] Compared with the prior art, the beneficial effects of the present invention are as follows:
[0016] 1) This invention optimizes the YOLOv11 model architecture by introducing a three-scale detection head (P2, P3, P4), a multi-expansion rate residual (DWR) neck network, and a context aggregation module. This significantly improves the detection accuracy and robustness of long-distance, small-sized flight trainees and their reflective vests in complex flight training environments, and effectively reduces the false detection and missed detection rates.
[0017] 2) This invention innovatively constructs a dedicated dataset containing fine-grained categories of "compliant wear" and "non-compliant wear," and based on this, proposes an intelligent judgment method based on multi-class detection results and dynamic spatial association rules. This method overcomes the limitation of traditional detection methods that can only identify the "presence" or "absence" of reflective vests, and can accurately distinguish between easily confused scenarios such as "compliant" and "non-compliant," especially identifying overlooked safety hazards such as "wearing but not properly."
[0018] 3) This invention achieves a technological leap from simple "object recognition" to "state understanding", providing a high-precision and high-efficiency automated monitoring solution for general aviation flight training safety. It effectively makes up for the shortcomings of manual inspection, significantly improves the level of refined and intelligent safety management of training grounds, and has important practical significance and application value. Attached Figure Description
[0019] Figure 1 This is an overall flowchart of the method described in this invention.
[0020] Figure 2 This is a block diagram of the overall structure of the target detection network model described in this invention.
[0021] Figure 3 for Figure 2 The diagram shows the structure of the multi-expansion rate residual (DWR) module used in the network model shown.
[0022] Figure 4 for Figure 2 The diagram shows the structure of the Context Aggregation module used in the network model.
[0023] Figure 5 This is a detailed hierarchical structure and data flow diagram of the target detection network model described in this invention.
[0024] Figure 6 This is a flowchart illustrating the execution of the wearable compliance intelligent determination algorithm described in this invention.
[0025] Figure 7 for Figure 6 The diagram shows the principle of the joint determination based on dynamic radius and intersection-union ratio in the determination algorithm shown. Detailed Implementation
[0026] The present invention will now be described in further detail with reference to the accompanying drawings and specific embodiments.
[0027] A method for testing the compliance of reflective vests worn by general aviation training flight trainees, the overall process of which is shown in the attached figure. Figure 1As shown. This method mainly includes: constructing a dedicated image dataset (steps S1-S3), improving and training the object detection model (step S4), evaluating model performance (step S5), and performing intelligent detection of wearable compliance (step S6). The specific implementation steps are as follows:
[0028] Step S1: Data collection and preprocessing for general aviation flight training scenarios.
[0029] Collect monitoring video data of flight training grounds covering different time periods, different weather conditions and complex backgrounds, and preprocess the video frame images.
[0030] To ensure that the target detection model trained subsequently can adapt to the realistic and complex general aviation flight training environment, this invention first constructs a high-quality dedicated image dataset. The typical flight training scenario applied in this invention is described. The dataset construction process includes two stages: data acquisition and data preprocessing.
[0031] Step S1.1: Data Acquisition. To enhance the robustness and generalization ability of the model, flight training field monitoring videos covering various complex backgrounds were acquired from partner general aviation airports as the raw data source. The acquisition process focused on scenarios that pose challenges to model performance, mainly including:
[0032] Weather diversity: encompassing a variety of meteorological conditions, including sunny and cloudy days.
[0033] Diverse operating conditions: Covering complex operating scenarios such as multiple overlapping targets, partial obstruction, strong light and glare interference.
[0034] By extracting frames from the video, images containing clear and representative flight trainee targets are selected to construct an original image library.
[0035] Step S1.2: Data Preprocessing. To improve image quality and reduce noise interference, Gaussian filtering is used to smooth the acquired image data. Gaussian filtering is a linear smoothing filter that performs a convolution operation on the image using a convolution kernel that conforms to a Gaussian distribution. For a two-dimensional image... Its Gaussian filtered image It can be represented as:
[0036] ;
[0037] in, The weights of the Gaussian convolution kernel are defined as follows:
[0038] ;
[0039] In this formula, These are the coordinates within the convolution kernel. Determine the kernel size, It represents the standard deviation of a Gaussian distribution, controlling the smoothness. This preprocessing step effectively suppresses high-frequency noise while preserving image edge details well, providing high-quality input for subsequent accurate annotation and model training.
[0040] Step S2: Dataset labeling and data augmentation.
[0041] The preprocessed image data is then finely annotated; subsequently, data augmentation techniques are used to expand the dataset to improve the model's generalization ability and robustness.
[0042] After obtaining high-quality preprocessed images, this step involves fine-tuning the image annotations and employing various data augmentation strategies to expand the dataset, providing a solid foundation for subsequent supervised learning of the model. The steps are as follows:
[0043] Step S2.1: Data Annotation. This step uses the professional image annotation tool LabelImg to annotate the bounding boxes of targets in the image. To achieve fine-grained analysis of wearing behavior, this invention defines three types of targets:
[0044] Person: refers to flight trainees appearing in the general aviation training area. Use a bounding box to completely select the visible human outline.
[0045] Compliantly worn reflective vest (vest_t): refers to a reflective vest that is worn correctly and in accordance with regulations, such as all fasteners being fastened securely.
[0046] Non-compliant reflective vest (vest_f): This refers to a situation where a reflective vest is worn by a flight trainee but is not worn correctly, resulting in impaired safety functions. Specific scenarios include, but are not limited to: not fastened or not zipped up, shoulder straps slipping off, or pulled down to the waist.
[0047] Through the refined category definitions described above, the dataset incorporates the "state" information of the target. All annotation information is stored in a YOLO model-compatible format.
[0048] Step S2.2: Data Augmentation. To improve the model's generalization ability and robustness, this step employs a series of data augmentation strategies to expand the training set, simulating visual disturbances in real-world surveillance. The main strategies include:
[0049] Geometric transformations: Random rotation (-15° to +15°), scaling (80% to 120%), cropping, and horizontal flipping are performed on the image to enhance the model's adaptability to changes in target pose, size, and position.
[0050] Photometric transformation: Randomly adjusts the brightness, contrast, saturation, and hue of an image to simulate changes in lighting conditions at different times of day (such as dawn and dusk) and under different weather conditions.
[0051] Advanced combination strategies: Advanced data augmentation methods such as Mosaic and MixUp are introduced. Taking MixUp as an example, it generates new training samples by linearly superimposing two images and their labels. Given two randomly selected samples... and ,in It is image data. It's a label, a new sample. Generated by the following formula:
[0052] ;
[0053] ;
[0054] Among them, the mixing coefficient Sampling from the Beta distribution, i.e. MixUp enables models to learn smoother decision boundaries, thereby improving generalization performance.
[0055] By comprehensively applying the above strategies, the scale and diversity of training data were significantly expanded.
[0056] Step S3: Dataset partitioning.
[0057] The labeled dataset is divided into training, validation and test sets according to the proportions, and stratified random sampling is used to ensure that the distribution of samples in each category is balanced.
[0058] To effectively train and objectively evaluate the model, this step divides the completed dataset into three independent subsets: a training set, a validation set, and a test set. The partitioning ratio follows a standard configuration of 7:2:1, meaning 70% of the data is used for model parameter learning, 20% for performance monitoring and hyperparameter tuning during training, and the remaining 10% for evaluating the generalization ability of the final model.
[0059] To ensure the scientific rigor of the data segmentation, a stratified random sampling strategy was employed. This strategy ensures that the sample proportions of different target categories (person, vest_t, vest_f) in each data subset remain consistent with the original dataset, thereby avoiding model bias introduced by uneven data distribution and guaranteeing the fairness of the evaluation results.
[0060] Step S4: Based on the YOLOv11 model, systematically improve and train it to build a high-performance small target detection model.
[0061] The YOLOv11 backbone network is simplified and the detection heads are optimized. A higher-resolution P2 feature layer is introduced, and a three-scale detection head (P2, P3, P4) is constructed to enhance the model's ability to perceive small targets at a distance. A Dilation-wise Residual (DWR) module is introduced into the feature fusion path of the neck network. By using dilated convolutions with different dilation rates in parallel, multi-scale receptive field features are efficiently captured and aggregated, enhancing the model's feature fusion capability and adaptability for targets with drastic size changes. Before each detection head performs final prediction on the feature map, a Context Aggregation module is integrated to dynamically aggregate global context information and modulate back to local features.
[0062] This step aims to build a high-performance model deeply optimized for small target detection tasks in general aviation training scenarios. Based on YOLOv11, this invention systematically improves the model from the dimensions of network architecture and key modules to enhance the accuracy and robustness of small target detection. The specific steps are as follows:
[0063] Step S4.1: Overall Model Architecture Design. To accurately and efficiently detect small targets in general aviation training scenarios, this invention performs targeted structural optimizations on the baseline YOLOv11 model. (See attached...) Figure 2 As shown, the model follows the encoder-decoder paradigm and consists of three parts: a backbone network, a neck network, and a head network. (See attached image.) Figure 5 It further illustrates the detailed hierarchical structure and data flow diagram.
[0064] Backbone: Responsible for extracting multi-level features from the input image. This invention simplifies the deep structure of the standard YOLOv11 to reduce computational complexity and better suit real-time requirements. (See attached image) Figure 5 As shown, the backbone network is composed of stacked convolutional modules (Conv) and C3k2 modules, which ultimately generate three layers of effective feature maps of different scales: P2 (160×160), P3 (80×80), and P4 (40×40), laying the foundation for subsequent feature fusion.
[0065] Neck Network: The core task is to fuse multi-scale features output from the backbone network. This invention employs a bidirectional fusion path combining a Feature Pyramid Network (FPN) and a Path Aggregation Network (PAN). This path effectively combines high-level semantic information with low-level spatial details through top-down (upsampling and concatenation) and bottom-up (downsampling and concatenation) feature flows. To enhance multi-scale context aggregation capabilities, this invention uses a Multiple Dilation Rate Residual (DWR) module in the neck network (see step S4.2 for details).
[0066] The detection head is responsible for parsing the fused features and generating the final prediction. A key improvement in this invention is adjusting the detection scale to P2, P3, and P4, utilizing the higher-resolution P2 feature layer for prediction, which significantly improves the model's recall rate for small targets (such as long-distance flight trainees). Furthermore, a context aggregation module (see step S4.3) is introduced before the feature maps at each scale enter the final detection layer to perform global context enhancement and improve detection accuracy. Ultimately, the model collaboratively predicts at the P2, P3, and P4 scales, effectively covering targets of various sizes from small to large.
[0067] Step S4.2: Improvement of Multi-Scale Feature Fusion in the Neck Network – Dilation-wise Residual (DWR) Module. To effectively capture targets with drastically changing sizes in general aviation training scenarios, this invention introduces a dilation-wise residual (DWR) module into the feature fusion path of the neck network. This module efficiently captures multi-scale contextual information within a single structure by using dilated convolutions with different dilation rates in parallel, significantly enhancing the network's feature representation capabilities. (Appendix) Figure 3 The internal structure of the DWR module is shown in detail.
[0068] The internal data processing flow of the DWR module is as follows:
[0069] 1. Preliminary Feature Extraction. Input feature map. (in For the number of channels, and (These are the height and width of the feature map, respectively.) First, through a standard... The convolutional layer performs preliminary feature extraction and channel compression to generate intermediate feature maps. This process can be represented as:
[0070] ;
[0071] This step lays the foundation for subsequent multi-scale receptive field capture.
[0072] 2. Parallel multi-diffraction dilated convolution. Intermediate feature map. It is fed into three parallel branches, each branch using a... Dilated convolutions, but with different dilation rates, are respectively... .
[0073] Branch 1 (expansion rate) ): Equivalent to standard convolution, responsible for capturing local fine-grained features.
[0074] ;
[0075] Branch 2 (expansion rate) : has a medium receptive field, capturing the context of the target and its surrounding area.
[0076] ;
[0077] Branch 3 (expansion rate) It has a large receptive field, capturing a wider range of global context. Through parallel processing, the DWR module can simultaneously resolve spatial information at different scales.
[0078] ;
[0079] 3. Feature aggregation and fusion. Output feature maps of the three parallel branches. Concatenation is performed along the channel dimension to form an aggregated feature map that contains multi-scale receptive field information. .
[0080] ;
[0081] Then, using one Convolutional layers aggregate feature maps This step involves processing. It serves two purposes: first, to restore the number of channels to a level consistent with the input features. Consistent Secondly, it involves information interaction and fusion of features from different receptive fields at the channel dimension, learning how to optimally combine these multi-scale information.
[0082] ;
[0083] 4. Residual Connections. Finally, the fused feature maps are... Compared to the initial input feature map of the module The final output of the DWR module is obtained by performing residual joins through element-wise addition. .
[0084] ;
[0085] Residual connections help alleviate the vanishing gradient problem and ensure that the original feature information is preserved during the enhancement process.
[0086] In summary, the DWR module, through its unique parallel multi-expansion rate structure and residual connections, significantly improves the network's ability to perform multi-scale feature extraction and fusion with minimal computational cost, and effectively enhances the feature pyramid's ability to preserve detailed information about small targets.
[0087] Step S4.3: Context Enhancement Mechanism Before the Detection Head – ContextAggregation Module. To improve the model's recognition accuracy in complex backgrounds, this invention introduces a ContextAggregation module before the prediction layer of the detection head. This module is a self-attention-based global context modeling mechanism that dynamically captures and fuses global information to enhance target features and suppress noise. (Appendix) Figure 4 The internal structure of the module is shown in detail.
[0088] Given a feature map for detection at a certain scale (in For the number of channels, and (These are the height and width of the feature map, respectively). The processing flow of the context aggregation module is as follows:
[0089] 1. Feature Transformation and Attention Map Generation. Input Feature Map First, three independent [processes] are passed in parallel. Convolutional layers are used to generate three distinct intermediate representations, denoted as follows: , and .
[0090] Spatial attention map : After processing with the Sigmoid activation function, a spatial attention map is generated. Each element in this graph has a value between (0, 1), representing the input feature map. The importance weight of each location in space.
[0091] ;
[0092] in, This represents the Sigmoid activation function.
[0093] Key : Flattened and reshaped The matrix is a two-dimensional matrix, and then the Softmax function is applied along the spatial dimensions to normalize it, resulting in the key. .key Each element represents the contribution weight of all global pixels in the aggregation context.
[0094] ;
[0095] Value : Firstly, through Convolution reduces the number of channels from Dimensionality reduced to an intermediate dimension ( ,in The reduction ratio (a hyperparameter) is used to reduce computational cost. The result is then flattened and reshaped into a two-dimensional matrix to obtain the value. . It contains the feature content to be aggregated.
[0096] ;
[0097] 2. Global context vector calculation. This is achieved by calculating the value... s and keys Matrix multiplication can be used to compute a global context vector. .
[0098] ;
[0099] This operation essentially involves a weighted summation of the feature content at all locations on the feature map, thereby condensing the global information into a single vector.
[0100] 3. Contextual Information Fusion and Feature Recalibration. The calculated global context vector... Through a convolutional layers Perform a linear transformation to restore its channel count to the original dimension. and reshaped into .
[0101] ;
[0102] Transformed context information Compared with the spatial attention map generated in the first step Element-wise multiplication (broadcast mechanism) is performed. This step weights the global context information according to spatial importance and applies it to each location in the feature map.
[0103] ;
[0104] in, This indicates element-wise multiplication.
[0105] Finally, the calibrated features are connected via a residual link. Add back to the original input feature map The final output of the module is obtained above. .
[0106] ;
[0107] Through the above process, the context aggregation module can effectively integrate global context information into local feature representation, enabling the network to "perceive" the overall environment during detection, thereby better distinguishing between the target and the background, reducing false detections, and ultimately improving the average accuracy (mAP) of detection.
[0108] Step S4.4: Model Training Configuration. After completing the structural design of the object detection network model, this step trains the model end-to-end on the dedicated dataset constructed in steps S1-S3. To ensure that the model can fully learn the features in the dataset and achieve optimal performance, the following key training configurations and strategies are adopted:
[0109] 1. Training Environment and Optimizer: Model training is based on the PyTorch deep learning framework and performed on a server equipped with a high-performance graphics processing unit (GPU). Stochastic Gradient Descent (SGD) with momentum is used as the optimizer, with the momentum parameter set to 0.937 and the weight decay coefficient set to 0.0005 to guide the effective convergence of the model parameters.
[0110] 2. Learning Rate Scheduling Strategy: A learning rate scheduling strategy combining warmup and cosine annealing is employed. In the initial training phase (e.g., the first 3 epochs), the learning rate is linearly increased from a small value to a preset initial learning rate (e.g., 0.01), which is the warmup process. Subsequently, the learning rate smoothly decreases according to a cosine function curve. This strategy helps the model learn stably in the early stages of training and converge finely to the optimal solution in the later stages.
[0111] 3. Key Training Hyperparameters: The model was trained for 300 epochs, with a batch size of 64. Input images were uniformly scaled to 640×640 pixels before training. During training, in addition to the offline data augmentation mentioned in step S2.2, online Mosaic data augmentation was also enabled. Four images were dynamically stitched together into one image for most training epochs to further improve the model's generalization ability.
[0112] Step S5: Performance evaluation of the target detection model.
[0113] Multiple evaluation metrics are used to assess the performance of the trained object detection model on the test set, and the model is compared and verified with several mainstream object detection algorithms.
[0114] To objectively measure the performance of the improved model of this invention (trained in step S4), this step uses industry-recognized evaluation metrics to compare it with a variety of mainstream benchmark models on an independent test set.
[0115] Step S5.1: Performance Evaluation Metrics. This invention primarily uses precision (P), recall (R), and mean average precision (mAP) as core performance evaluation metrics.
[0116] Precision: Measures the accuracy of a model's predictions, i.e., whether the predictions are correct. The formula for calculation is as follows:
[0117] ;
[0118] in, (True Positives) represents the number of correctly detected targets; (False Positives) represents the number of falsely detected targets.
[0119] Recall: Measures the comprehensiveness of a model's detection capability, i.e., how well it finds all the targets. Its calculation formula is as follows:
[0120] ;
[0121] in, (False Negatives) represents the number of targets that were not detected.
[0122] Mean Accuracy (mAP): This metric comprehensively evaluates the model's overall performance across all categories. It is obtained by calculating the area under the PR curve for each category (i.e., mean accuracy AP), and then averaging the AP values across all categories. The formula is as follows:
[0123] ;
[0124] ;
[0125] in, Indicates the first Each category had a recall rate of Accuracy of time, The total number of categories (in this invention, That is, person, vest_t, vest_f).
[0126] Step S5.2: Comparative Experiment and Result Analysis. To verify the effectiveness of the method of this invention, the proposed model was compared with several representative lightweight YOLO models and the benchmark YOLOv11n model under the same conditions. The experimental results (shown in the table below) show that the model of this invention exhibits significant advantages in key performance indicators.
[0127] Table 1 Comparative Experimental Results
[0128] .
[0129] As shown in Table 1, while reducing the number of parameters by 33%, the core performance indicator mAP@50 of this invention significantly improved from 67.1% to 82.9%. Particularly noteworthy is the recall rate (R), which reached 78.5%, far exceeding the approximately 59.0% of other models. This strongly demonstrates that the improvements of this invention effectively solve the problem of missed detections of small targets. Experimental results confirm that this invention's model significantly improves detection accuracy while achieving lightweight design, exhibiting remarkable advancement.
[0130] Step S6: Smart detection of wearable compliance.
[0131] Based on the detection bounding box and confidence score output by the trained target detection model, logical reasoning is performed using dynamic spatial association rules that are adaptive to the target scale to achieve intelligent determination of the wearing status of reflective vests for each detected person.
[0132] The target detection model is used to infer the results of a test image to obtain preliminary detection results for three types of targets. Each detection result includes a category, confidence level, and bounding box. Adaptive target scale dynamic spatial association rules are used to match the spatially associated reflective vest target in the preliminary detection results for each detected person target. Based on the preset multi-class matching priority, the final wearing status of the person target is determined according to the matching results as compliant wearing, non-compliant wearing, or not wearing a reflective vest.
[0133] This step is a crucial step in realizing the core function of this invention, and its process is shown in the attached figure. Figure 6 As shown, it is based on a high-performance object detection model trained in step S4 and evaluated in step S5. It performs secondary logical reasoning on the preliminary detection results output by the model, thereby achieving a leap from "object recognition" to "state understanding", and finally outputs an accurate judgment on wearable compliance.
[0134] Step S6.1: Acquisition and Preprocessing of Detection Results. This step aims to parse, filter, and structure the raw output of the target detection model to provide standardized input for subsequent association determination. The specific processing flow is as follows:
[0135] 1. Parsing of raw detection results. For each input frame image, the object detection model trained in step S4 is first invoked to perform inference, obtaining the raw detection results for that frame image. Each object's information consists of its bounding box coordinates, confidence score, and class ID.
[0136] 2. Preliminary screening based on confidence thresholds. Low-quality detection results are filtered out, and all targets are screened. This invention sets independent confidence thresholds for different categories. Let the model detect the first... The categories of the targets are Confidence level is A pre-defined mapping function from category to threshold is used. Only targets that meet the following conditions will be retained:
[0137] ;
[0138] in, Indicates category The corresponding confidence threshold. For example, in a specific instance, it can be set to... , , This step can effectively reduce noise interference in subsequent processing.
[0139] 3. Structured Storage of Target Information. After filtering, valid target information is grouped by category, creating three independent lists to store information for "persons," "compliant reflective vests" (vest_t), and "non-compliant reflective vests" (vest_f), respectively. Each list contains a data structure with the target's bounding box coordinates and confidence level, laying the data foundation for the association analysis in step S6.2. For example, a personnel target can be stored as:
[0140] ;
[0141] in, The coordinates of the top left and bottom right corners of the personnel target bounding box.
[0142] Step S6.2: Joint matching determination based on dynamic radius and intersection-union ratio. This step is the core algorithm for intelligent determination of wearable compliance, aiming to establish a subordinate relationship between the "person" and the "reflective vest" target based on their relative spatial positions. (See attached...) Figure 7 As shown, this invention abandons the traditional fixed Intersection over Union (IoU) matching method and instead adopts a dynamic association strategy that can adapt to the target scale, and combines the IoU for double verification. The specific implementation is as follows:
[0143] 1. Calculation of target geometric attributes. For each structured target in step S6.1, its key geometric attributes are first calculated. For any given personnel target bounding box... Its geometric center coordinates The calculation formula is:
[0144] ;
[0145] ;
[0146] Its bounding box width The calculation formula is:
[0147] ;
[0148] Similarly, calculate the bounding box of the reflective vest target. The center of the collection .
[0149] 2. Generation of dynamically associated regions. For each "personnel" target bounding box... Define a dynamic circular associated region. The geometric center point of the bounding box of the "personnel" target. Centered on the circle, with its bounding box width Half of the radius The dynamic radius The calculation formula is as follows:
[0150] ;
[0151] This design ensures that the size of the associated area is proportional to the visual size of the person target in the image, thus adapting to scale changes at different shooting distances.
[0152] 3. Joint determination of spatial subordination. By simultaneously calculating the center point distance and bounding box intersection-union ratio of the "personnel" and the "reflective vest" target, and comparing them with the dynamic radius and a preset threshold respectively, it is determined whether there is a wearing relationship between the two.
[0153] Take a "personnel" target as the center point The center point of a "reflective vest" target (vest_t or vest_f) First, calculate the Euclidean distance between the two points. The calculation formula is as follows:
[0154] ;
[0155] To further improve matching accuracy and avoid misjudgments caused by close center point distances but small actual overlap areas, this invention introduces the Intersection over Union (IoU) ratio as an auxiliary verification condition. The IoU ratio calculates the bounding box of the person target. Boundary box of the reflective vest target The ratio of the intersection area to the union area is calculated using the following formula:
[0156] ;
[0157] Ultimately, the reflective vest target is determined to be spatially subordinate to the person target, i.e., there is a wearing relationship, only when both the center point distance and the intersection-union ratio satisfy the following two conditions:
[0158] ;
[0159] in, This represents the logical AND operation. It is a preset crossover ratio threshold used to ensure that there is at least a basic physical overlap between two targets.
[0160] Appendix Figure 7 The flowchart also illustrates this joint decision-making logic. By executing the above steps, a reliable spatial correlation basis can be established for subsequent multi-category matching.
[0161] Step S6.3: Multi-category matching and compliance status determination. This step, based on the established spatial relationships, uses a priority-based matching strategy to assign a unique wearing status to each "personnel" target. The determination logic is as follows: Figure 7 As shown.
[0162] First, each "personnel" target is assigned the initial state of "not wearing a reflective vest". Then, for each "personnel" target, the list of "compliant reflective vests" (vest_t) is traversed first for association determination. Once a match is successful, the state of the "personnel" is updated to "compliant wearing", and the next "personnel" target is processed immediately.
[0163] If no `vest_t` target is matched, the list of "non-compliant reflective vests" (`vest_f`) is then traversed for association determination. If a match is successful, the status is updated to "non-compliant wearing".
[0164] If a "personnel" target does not find a match in either list, its status remains "not wearing a reflective vest." This prioritization strategy ensures that even in complex situations where detection results overlap, a unique and clear conclusion can be reached.
[0165] Step S6.4: Visualization of the judgment result. This step aims to present the abstract judgment conclusion from Step S6.3 in an intuitive visual form on an image, generating the final result:
[0166] 1. Fusion calculation of decision confidence. To comprehensively reflect the reliability of the entire decision chain, a fusion confidence score is calculated for each decision state. .
[0167] If a "personnel" target A target wearing a reflective vest was successfully matched. Therefore, the final fusion confidence score is the product of the original confidence scores of the two:
[0168] ;
[0169] in, and The original detection confidence scores are for the "personnel" target and the matched "reflective vest" target, respectively.
[0170] If a "personnel" target If no "reflective vest" target is matched, its final confidence score is its original detection confidence score:
[0171] ;
[0172] 2. Definition of Visual Elements. Different visual identifiers are preset for different judgment states to facilitate quick differentiation. Specifically, a mapping relationship between state and color (e.g., BGR format) is defined. In an example, it can be defined as follows:
[0173] "Compliant wearables" corresponds to green (0, 255, 0).
[0174] “Non-compliant wearing” corresponds to yellow (0, 255, 255).
[0175] "Not wearing a reflective vest" corresponds to red (0, 0, 255).
[0176] 3. Result Plotting and Text Annotation. Iterate through all identified "personnel" targets and draw rectangles at their original bounding box locations using the color corresponding to their state. Simultaneously, format the determination state and fusion confidence score as text (e.g., "Compliant Wearing: 0.82") and plot it above the bounding box, ensuring the annotation information is clearly visible.
[0177] By following the steps above, a visual result image with clear compliance status labels and confidence information can be generated. Performing steps S6.1 to S6.4 on each frame of the video stream enables continuous, real-time intelligent monitoring and visual early warning of the compliance of general aviation training flight trainees' reflective vest wearing.
Claims
1. A method for detecting compliance of a student pilot reflective vest wearing, characterized in that, The method comprises the following steps: Step 1: Collect flight training field monitoring video data covering different time periods, different weather conditions and complex backgrounds, and pre-process the video frame images; Step 2: Fine-grained annotation is performed on the pre-processed image data to obtain a data set including three types of targets: personnel, compliantly worn reflective vests, and non-compliantly worn reflective vests; Step 3: The annotated data set is divided into a training set, a validation set and a test set according to a proportion; Step 4: A target detection model is constructed and trained: the baseline YOLOv11 model is optimized in a targeted manner, following an encoder-decoder paradigm, including a backbone network, a neck network and a detection head; In the detection head, a P2 feature layer is introduced, and the detection scale is adjusted to P2, P3 and P4; In the neck network between the encoder and the decoder, a multi-expansion rate residual module is used to aggregate multi-scale receptive field features by using different expansion rate hole convolutions in parallel; Before the final prediction of each scale feature layer in the detection head, a context aggregation module is integrated to fuse global context information to modulate local features; finally, the constructed target detection model is trained; Step 5: Intelligent judgment of wearing compliance based on the trained target detection model: inference is performed on a to-be-detected image to obtain preliminary detection results of the three types of targets; A dynamic spatial correlation rule with adaptive target scale is used to match a spatially correlated reflective vest target for each detected personnel target, and the dynamic spatial correlation rule comprehensively considers the center point distance and the intersection over union between targets; based on a preset multi-class matching priority, the wearing compliance of the personnel reflective vest is determined; In step 5, the determination process based on the multi-class matching priority is as follows: An initial state of not wearing a reflective vest is assigned to each detected personnel target; For each personnel target, the compliantly worn reflective vest vest_t list is traversed first, and if a compliantly worn reflective vest target that has a spatial correlation relationship with the personnel target is matched, the state of the personnel target is updated to a compliantly worn state, and subsequent matching of the personnel target is terminated; If the personnel target fails to match any compliantly worn reflective vest target, the non-compliantly worn reflective vest vest_f list is traversed, and if a non-compliantly worn reflective vest target that has a spatial correlation relationship with the personnel target is matched, the state of the personnel target is updated to a non-compliantly worn state; if no target is matched, the state of the personnel target remains as not wearing a reflective vest.
2. A method of detecting compliance with wearing of a reflective vest by a student pilot for air navigation training according to claim 1, characterized in that, In step 1, the pre-processing of the video frame images is as follows: The collected video frame image is smoothed by using Gaussian filtering to suppress high frequency noise; for a two-dimensional image the image after Gaussian filtering is expressed as: ; wherein, is the size of the convolution kernel, is the weight of the Gaussian convolution kernel, which is defined as: ; wherein is a coordinate within the convolution kernel, is the standard deviation of the Gaussian distribution, controlling the degree of smoothing.
3. A method of detecting compliance with wearing of a reflective vest by a student pilot for air navigation training according to claim 1, characterized in that, In step 2, after fine-grained annotation, data augmentation techniques are used to expand the data set, specifically including: Geometric transformation: random rotation, scaling, cropping and horizontal flipping of images; Lightness transformation: random adjustment of brightness, contrast, saturation and hue of images; Advanced combination strategy: adopt MixUp method, generate new training samples by linear superposition on two images and their labels The generation formula is: ; ; where the mixing coefficient Sampling from the Beta distribution.
4. The method for detecting compliance of reflective vests worn by general aviation training flight trainees according to claim 1, characterized in that, The multi-expansion rate residual module used in step 4 has the following specific implementation methods: performing convolution on an input feature map to perform preliminary feature extraction to obtain an intermediate feature map convolution, to perform preliminary feature extraction, to obtain an intermediate feature map the intermediate feature map parallel input to at least two cavity convolution branches with different expansion rates to capture receptive field features of different scales respectively; The output feature maps of the at least two hollow convolution branches are spliced in the channel dimension to obtain an aggregated feature map ; For the aggregated feature map conduct Convolution is used to fuse multi-scale information and unify channel dimensions to obtain a fused feature map. ; The fused feature map is connected with the input feature map to obtain the final output of the multi-dilation rate residual module .
5. The method for detecting compliance of reflective vests worn by general aviation training flight trainees according to claim 1, characterized in that, The context aggregation module integrated in step 4 has the following specific implementation methods: Step a: an input feature map in parallel through three independent convolutional layers , respectively, to generate intermediate representations , and ; processing the intermediate representations to generate spatial attention maps , keys and values ; as follows: ; ; ; wherein the spatial attention map is a sigmoid activation function applied to the intermediate representation ; the key is a flattening and reshaping of the intermediate representation into a two-dimensional matrix, followed by a softmax function applied along the spatial dimension to normalize the values is a channel dimension reduction and flattening of the intermediate representation into a two-dimensional matrix is a reshaping function Step b: Compute the global context vector by matrix multiplication with the value and the key ; Step c: performing a linear transformation on the global context vector by a convolutional layer with a number of channels equal to the original dimension of the global context vector to restore the number of channels to the original dimension, resulting in a transformed context information : ; Step d: transform the context information with spatial attention map element-wise multiplication to get a calibrated feature map : ; wherein represents an element-wise multiplication; Step e: the calibrated feature map is inputted into the context aggregation module to obtain the final output of the context aggregation module , and the calculation formula is: .
6. A method of detecting compliance with wearing of a reflective vest by a student pilot for air navigation training according to claim 1, characterized in that, In step 5, the preliminary detection results are obtained as follows: Step 511: original detection result analysis: for each input frame image, first call the trained target detection model for inference to obtain the original detection result of the frame image; each target information includes bounding box coordinates, confidence score and class label; Step 512: preliminary screening based on confidence threshold: filter out low-quality detection results, screen all targets; let the category of the target detected by the model be , and the confidence be . Pre-setting a class-to-threshold mapping function Then only targets that satisfy the following conditions will be kept: ; wherein, representing a category a corresponding confidence threshold; Step 513: target information structured storage: after screening, the effective target information is grouped by category, and three independent lists are created to store the information of persons, compliant reflective vest vest_t and non-compliant reflective vest vest_f respectively.
7. A method of detecting compliance with wearing of a reflective vest by a student pilot for air navigation training according to claim 1, characterized in that, In the step 5, the adaptive target scale dynamic spatial correlation rule is adopted, and the specific implementation manner thereof includes: Step 521 : for each detected person target, compute its geometric center point and width from its bounding box coordinates ; ; ; ; wherein, is the top-left and bottom-right coordinates of the bounding box for the person target; Similarly, the bounding box coordinates of the reflective vest target are calculated the geometric center point ; Step 522: defining a dynamic association region for the person target, the dynamic association region being a circular region with the geometric center point of the person target bounding box as the center and with half of the width as the radius , wherein the calculation formula of the dynamic association region radius is: ; Step 523: the condition for judging that the reflective vest target and the personnel target exist spatial correlation is that the following two conditions are satisfied at the same time: a) the Euclidean distance between the geometric center point of the reflective vest target and the geometric center point of the person target is less than or equal to the dynamic association zone radius with the decision condition being that ; The Euclidean distance is The calculation formula is: ; b) an intersection over union between the bounding box of the person target and the bounding box of the reflective vest target greater than or equal to a preset intersection over union threshold ; the intersection over union is a ratio of an intersection area to a union area of the bounding box of the person target and the bounding box of the reflective vest target, calculated as follows: ; The joint determination condition is expressed as: ; wherein denotes a logical AND operation; If the above two conditions are satisfied at the same time, it is judged that the current reflective vest target is spatially subordinate to the personnel target, that is, the two exist a spatial correlation relationship, otherwise, it is considered that the two have no spatial correlation.
Citation Information
Patent Citations
Reflector and helmet detection method based on improved YOLOv11s
CN120472263A
Small sample steel defect detection method based on attention feature pyramid mechanism
WO2025010883A1