# Occlusion-Aware Worker Detection in Masonry Work: Performance Evaluation of YOLOv8 and SAMURAI
## 2 Methodology
### Performance Comparison Between YOLOv8 and SAMURAI  
This section presents the methodology for evaluating the detection performance of YOLOv8 and SAMURAI under varying occlusion conditions. The evaluation process systematically segments video sequences into fixed temporal intervals and measures detection accuracy at each time-step. To ensure structured analysis, detection results are compiled in tabular format, allowing for a comparative assessment based on task type, applied algorithm, occlusion case, and time-based evaluation intervals. Figure 5 visually represents the evaluation segments for each occlusion scenario, including key time points (T\({}_{1}\) to T\({}_{1}\)) and occlusion severity levels. Additionally, it illustrates the overall experimental workflow, detailing the processes of data preprocessing, model implementation (YOLOv8 and SAMURAI), and systematic performance evaluation across different tasks and conditions. T\({}_{1}\) denotes the initial evaluation time-step for each occlusion scenario, while T\({}_{L}\) (last time-step) represents the final evaluation time point.  
For the brick transportation task, performance evaluation encompasses Case 1 (non-occlusion), Case 2 (partial occlusion), and Case 3 (severe occlusion). The evaluation period starts from the moment the worker enters the occlusion region until they are fully visible again. In all cases, a total duration of 15 s is analyzed, with detection results recorded at 0.25 s intervals, yielding 60 evaluation time points (T\({}_{1}\) to T\({}_{60}\)). In Case 1, the worker remains fully visible without obstruction, providing a baseline for detection performance. In Case 2, the worker becomes partially occluded as an obstacle obstructs the lower body, and evaluation continues until visibility is fully restored. In Case 3, severe occlusion occurs when the worker's upper body and head are significantly obscured by the obstacle, posing additional detection challenges. By dividing the evaluation into 0.25 s intervals, the study assesses how YOLOv8 and SAMURAI perform during the occlusion period.  
For the brick laying task, performance evaluation is based on occlusion progression due to the increasing height of stacked bricks rather than worker movement. The non  
Figure 5: Comprehensive workflow and evaluation structure for YOLOv8 and SAMURAI detection performance under varying occlusion conditions.  
occlusion condition (Case 1) is defined as the stage when the worker remains fully visible, corresponding to brick layers up to the second and third rows. Partial occlusion (Case 2) is observed when only the upper body of the worker is visible, occurring from the seventh to eighth brick layers. Severe Occlusion (Case 3) begins when only the worker's face or part of the upper body is visible, occurring from the twelfth brick layer onward. Since stacking two brick layers takes approximately one minute, the evaluation follows the same segmentation approach as the brick transportation task, recording detection results at 0.25 s intervals over 240 time-steps (T\({}_{1}\) to T\({}_{240}\)).  
By structuring the evaluation in this manner, detection trends can be analyzed across time, and the comparative performance of YOLOv8 and SAMURAI under varying occlusion levels can be assessed. The subsequent section discusses the experimental results and provides a detailed performance comparison based on the collected data.  
All experimental evaluations were conducted using Python 3.10 and PyTorch 2.0 on a workstation equipped with an NVIDIA RTX 3090 GPU and Intel Core i9-12900K CPU. Both YOLOv8 and SAMURAI were implemented in the same software environment to ensure consistency in detection performance measurement across time-steps. Detection results were recorded and processed systematically at each predefined interval, supporting accurate and reproducible evaluation.