# A Multidimensional Data Collection and Edge Computing Analysis Method
## 3 Overall System Architecture and Improved Target Detection Model
### Object Detection and Sensing Data Correction
#### 3.2.2 Improved Target Detection Model
The improved CIOU loss function is:  
\[L_{CIOU}=1-IOU+\rho^{2}(b,b^{gt})/c^{2}+k\times v^{2}/[(1-IOU)+v] \tag{12}\]  
\[v=(4/\pi^{2})[arctan(w^{gt}/h^{gt})-arctan(w/h)]^{2} \tag{13}\]  
where \(\rho^{2}(b,b^{gt})\) is the distance between the predicted centroid position and the true centroid position. \(w\) and \(h\) are the width and height respectively, but this part cannot improve the accuracy of the detection, so we added the k-factor in front of the centroid position parameter \(\rho^{2}(b,b^{gt})\) to increase the weight of the centroid position. The three improved losses are superimposed to form the final loss function, and we name this improved loss function as the common space loss function, so our improved model can be called the CS-YOLOv4-tiny model. The CS-YOLOv4-tiny model is illustrated in Figure 7.  
The improved target detection model in this paper can be divided into a model for detecting people alone and a model for detecting all objects and people. We evaluate our proposed improved target detection method using mAP and FPS. In our process of detecting and classifying targets, there may be multiple labels for people and other objects in a single image, i.e., each image may have different categories of targets, so the evaluation cannot use the common single-label classification criteria, and the target detection task uses a method similar to information retrieval--mAP, i.e., the average of the accuracy rates for each category. Average precision is defined as the area enclosed by the accuracy and recall curve and the coordinate axis. Figure 7: The CS-YOLOv4-tiny model. The accuracy rate and recall rate are computed as: Precision, TP/(TP + FP); Recall, TP/(TP + FN). True positive (TP) means that the model predicts a positive sample, and the actual prediction is accurate; false positive (FP) means that the model predicts a positive sample, and the detection is mistaken; and false negative (FN) means that the model predicts a negative sample, and the detection is mistaken. FPS is currently a common indicator for evaluating model efficiency. In two-dimensional image detection, it is defined as the number of portraits that can be processed per second. We conducted training analysis on the samples and selected different a-parameters and \(k\)-parameters to observe their training accuracy (mAP); The results are shown in Table 2. From Table 2, we also determine the optimal values of \(a\) and \(k\). That is, \(k=1.5\) and \(a=0.3\). Likewise, we compared some current target detection models, such as: Faster R-CNN, YOLOv4, SSD, and RefineDet. These target detection models with our CS-YOLOv4-tiny, as shown in Figure 8. Our improved model has been effectively improved in terms of accuracy (mAP). Figure 9 shows the actual acquired image detection results. By training our improved model for various models, we can see that the requirements for our parameter acquisition are satisfied. Figure 8: Comparison chart of accuracy of different models. Figure 9: Improved target detection model for practical detection: (**a**) Various target detection charts; (**b**) Pedestrian and fitness equipment detection chart; (**c**) Nighttime pedestrian detection map.