## 2 Materials and Methods
### Squeeze-and-Excitation Networks  
In actual safety helmet and reflective vast detection scenarios, the significance of distinct regions within a single image frequently diverges. The failure to intelligently allocate computational resources to these pivotal areas can markedly compromise the accuracy and reliability of the final recognition outcomes. Unfortunately, the conventional YOLOv8 model lacks an inherent resource allocation optimization mechanism, significantly hindering its actual detection capabilities.  
To mitigate this issue, this article innovatively incorporates attention mechanisms as a solution. By mimicking the human visual system's selective attention prowess, these mechanisms aim to autonomously discern and concentrate on the crucial information zones within images. Through a meticulous series of experiments, we thoroughly evaluated and  
Figure 2: YOLOv8n network structure.  
verified a multitude of attention mechanisms, striving to identify the optimal fit for this specific application context.  
Upon rigorous comparison and thorough analysis, the SE (Squeeze-and-Excitation) attention mechanism emerged as the standout performer in enhancing detection accuracy. By explicitly modeling the intricate interdependencies among feature channels and adaptively recalibrating their relative importance, the SE mechanism adeptly amplifies the model's sensitivity to pivotal features while effectively mitigating the distraction caused by non-essential information. This groundbreaking finding not only offers fresh perspectives for the precise detection of safety helmets and reflective vests but also serves as a robust foundation for performance optimization across a broad spectrum of similar visual tasks.  
The attention mechanism closely mimics the human eye's ability to allocate varying levels of attention based on the significance of image information during observation, effectively tackling the challenge of information overload. Its primary objective is to strategically allocate computational resources towards the crucial elements that have a more profound impact on the final results [19].  
The SE (Squeeze-and-Excitation) module aims to derive a set of weights and apply feature weighting across all original channels. It achieves this through a two-step process: Squeeze and Excitation. In the Squeeze stage, the feature maps derived from the convolutional layer are transformed into a distinctive vector, condensing spatial information. Following this, the Excitation stage leverages fully connected layers and specific nonlinear activation functions to learn and generate a weight vector for each channel. This enables the SE module to adaptively adjust the weight proportion of each channel, fine-tuning the channel's contribution within the feature map according to the specific task requirements.  
The detailed algorithm flowchart, as depicted in Figure 3, illustrates this process. By integrating the SE attention mechanism into the SDCB-YOLO model, it becomes capable of allocating diverse computational resources to different regions of the image. This ensures that the model achieves improved accuracy without incurring additional computational complexity.  
In this paper, a comparison is made in the selection of attention mechanisms, specifically comparing the common attention mechanisms. The detailed test results are shown in Table 2. It can be observed that SE attention outperforms other attention mechanisms across various indicators.