## 3 Methodology
### PPE Detection  
PPE(s) recognition and localization are carried out using an object detection model. Depending on the CNN architecture and the detection strategy, object detection approaches are broadly classified into single-stage and two-stage approaches. Two-stage approaches (e.g., the R-CNN family [12; 17; 18]) make predictions in two stages: first, a set of regions of interests are proposed by regional proposal network or select search, which are sparse as the candidates of potential bounding box can be infinite. Subsequently, a classifier is deployed to process the region candidates. On the other hand, one-stage approaches (e.g., YOLO and its variants [5; 19; 20]) make detection directly over a dense sampling of possible locations without the region proposal stage, which leads to a simpler architecture and makes it extremely fast in the inference phase. In 2018, [PERSON] et al. proposed YOLOv3 [5] as an improvement of the YOLO family. As demonstrated in Figure 4, YOLOv3 uses a deep network architecture with residual blocks and a total of 53 convolutional layers, i.e., Darknet-53, for feature extraction, which has better performance and is 1.5\(\times\) faster than ResNet-101 [21]. Drawing on the idea of feature pyramid networks [22], YOLOv3 makes predictions at three scales (\"predictions across scales\") by downsampling the size of the input image by 32, 16, and 8. This means, with an input of 416 \(\times\) 416, the YOLOv3 model provides feature maps of 13 \(\times\) 13, 26 \(\times\) 26, and 52 \(\times\) 52, respectively, in three output layers. The predictions of the YOLOv3 model are encoded as a 3-D tensor with bounding box candidate, objectness score, and class score (see the bottom right of Figure 4):  
\[N\times N\times(3*(4+1+C)) \tag{3}\]  
where \(N\times N\) is the number of the grid cells of the model and \(C\) is the number of the classes to be classified. Figure 3: 18 keypoints estimated by the OpenPose Model. In contrast to the sum of squared errors for classification terms used in YOLO and YOLOv2, YOLOv3 uses logistic regression to predict a confidence score for each bounding box. The Softmax classifier deployed in the YOLOv2 assumes that a target belongs to only one class, and each box is assigned to the class with the largest score. However, in some complex scenarios, a target may belong to multiple classes (with overlapping class labels), thus YOLOv3 employs a multiple independent logistic classifier (using Sigmoid function) for each class instead of one softmax layer when predicting class confidence. In addition, YOLOv3 uses binary cross-entropy loss as the loss function to train class prediction (both YOLO and YOLOv2 use a loss function based on the sum of squares):  
\[\lambda_{coord}\sum_{i=0}^{N^{2}}\sum_{j=0}^{B}\mathbbm{1}_{i,j}^{ obj}[(b_{x}-\hat{b_{x}})^{2}+(b_{y}-\hat{b_{y}})^{2}+(b_{w}-\hat{b_{w}})^{2}+(b_{h}- \hat{b_{h}})^{2}] \tag{4}\] \[+\sum_{i=0}^{N^{2}}\sum_{j=0}^{B}\mathbbm{1}_{i,j}^{obj}[-log(p_{ c})+\sum_{i=1}^{n}BCE(\hat{C_{i}},C_{i})]\] \[+\lambda_{noobj}\sum_{i=0}^{N^{2}}\sum_{j=0}^{B}\mathbbm{1}_{i,j }^{noobj}[-log(1-p_{c})]\]  
where \(N^{2}\) is the number of the grid cells (\(13\times 13\) grids, \(26\times 26\) grids, or \(52\times 52\) grids), and \(B\) is the bounding boxes. \(\mathbbm{1}_{i,j}^{obj}\) denotes that cell \(i\) contains objects and the \(j_{th}\) bounding box predictor in cell \(i\) is \"responsible\" for that prediction. In contrast, \(\mathbbm{1}_{i,j}^{noobj}\) denotes that the \(j_{th}\) bounding box predictor in cell \(i\) that contains no objects. The parameters \(\lambda_{coord}\) and \(\lambda_{noobj}\) are employed to revise the overall loss by increasing the loss from bounding box coordinate predictions and decreasing the loss from confidence predictions for boxes that contain no objects. Additionally, binary cross-entropy loss \(BCE(\hat{C_{i}},\hat{C_{i}})\) is given by  
\[BCE(\hat{C_{i}},C_{i})=-\hat{C_{i}}log(C_{i})-(1-\hat{C_{i}})log(1-C_{i}) \tag{5}\]  
where \(C_{i}\) is the objectness in cell \(i\).