# Video-Based Parking Occupancy Detection for Smart Control System
## 3 Experimental Results
### Verifying Our Approach with Real Scenes  
The parking grid judgment process is presented in Figure 16. First, the original image (see Figure 16a) was fed as an input to the model. After finding the parking spaces (see Figure 16b), the detection model drew center points and bounding boxes (see Figure 16c). Judgment of occupancy used the IOU area and overlapping methods (see Figure 16d). Judgment of parking space occupancy was based on a series of images. The cumulative method was used to calculate which parking space a car belonged to, and each parking space had its own voting accumulator. Which car belonged to which parking space was determined through the voting mechanism, which could filter noise when cars crossed into and out of parking spaces. The experiments took different environments into account, i.e., cases 1 to 5. Cases 1 to 3 are daytime settings. There is a car parking/ready to leave/pass through other parking spaces in different situations of occupancy detection. Cases 4 to 5 are nighttime settings; however, there is a streetlight on one side (parking space 6-9) and none on the other. The environment is side facing, complex, and full of obstructions. \begin{table}
\begin{tabular}{c c c c} \hline \hline
**Image** & **Camera Model** & \begin{tabular}{c} **Image Size** \\ **(H) \(\times\) (V)** \\ \end{tabular} & **Resolution** & **Accuracy** \\ \hline \hline \multirow{4}{*}{\begin{tabular}{c} CNRPark + EXT \\ \end{tabular} } & \multirow{4}{*}{\
\begin{tabular}{c} 5 MP Fixed Focus Color \\ Camera \\ \end{tabular} } & \multirow{4}{*}{
\begin{tabular}{c} 2592 \(\times\) 1944 pixels \\ \end{tabular} } & \multirow{4}{*}{96 dpi} & \multirow{4}{*}{98.97\%} \\  & & & & \\ \cline{1-1} \cline{3-4}  & Logitech-C920 HD PRO & & & \\ \cline{1-1} \cline{3-4}  & WEBCAM & & & \\ \cline{1-1} \cline{3-4}  & real scenes 1 & & & \\ \cline{1-1} \cline{3-4}  & & & & \\ \cline{1-1} \cline{3-4}  & Microsoft LifeCam Studio V2 (Q2F-00017) & & & \\ \cline{1-1} \cline{3-4}  & real scenes 2 (nighttime) & & & \\ \hline \hline \end{tabular}
\end{table} 
Table 4: Model performance in different scenes and resolutions. \begin{table}
\begin{tabular}{c c c c} \hline \hline
**Name of Network** & **Per Frame** & **FPS** & **Parameter** \\ \hline Darknet-53 & 0.55 sec & 1.8 & 61576342 \\ MobileNet v2 & 0.41 sec & 2.3 & 4359264 \\ \hline \hline \end{tabular}
\end{table} 
Table 3: MobileNet v2 compared to Darknet-53 by per frame, FPS, and parameter. In case 1, Figure 17(a1-a4) demonstrates that a car approached parking space 1. Parking spaces in red represent occupied spaces, those in green represent free spaces, and those in blue represent bounding boxes of the predict model and signified vehicles intersecting with parking spaces. The model continued to detect and compare intersection areas to verify that vehicles were parked in parking spaces. Therefore, this model continued judgment through the voting mechanism over time. Case 2 is presented in Figure 17(b1-b4). The car in parking space No. 10 was ready to leave. The model identified that parking space 10 was occupied and continued to detect and compare the intersection area to ensure that the vehicle remained in the parking space. The model detected that the intersection area with the parking space was becoming smaller until the car completely left, after which the model detected that the parking space was empty and switched parking space 10 from red to green, thereby identifying the space as free. Case 3 is presented in Figure 17(c1-c4). It verified through the voting mechanism that cars did not affect judgment when passing through the parking space. Figure 16: Occupancy detection process. (**a**) Original image of the input. (**b**) Green bounding boxes represent parking grids. (**c**) Blue bounding boxes from YOLO represent detected vehicles. (**d**) The yellow area was the intersection between parking grids and vehicles. Figure 17: Several conditions with the proposed method. (**a1–a4**) A car parking. (**b1–b4**) A car leaving its parking space.