## 3 Proposed Methods
### Obstacle Detection Method Based on Superpixel Point-Cloud Height (OD-SPH)  
As mentioned earlier, the OD-PNV method can correctly classify most of the superpixels. However, this method also has certain limitations. It cannot correctly distinguish some obstacle areas with a planar geometry (such as the hood of a vehicle marked by a green box in Figure 5b) from free space areas. Nonetheless, these obstacle areas are usually significantly different in height from the free space areas, and we propose the OD-SPH method based on this difference. The flow chart of this method is shown in Figure 6. To calculate the object height, the road plane model is first estimated by combining the superpixel point cloud information and the classification result of the OD-PNV method. This method calculates the height of the superpixel point cloud based on the estimated model, and then converts the height information into the probability that the superpixel belongs to an obstacle. Figure 5: The probabilistic distribution of \(PR_{PNV}\) and the classification result of the OD-PNV method: (a) \(PR_{PNV}\) probability distribution; (b) OD-PNV method classification result. Figure 6: Flow chart of OD-SPH method. If all the superpixel point clouds in the image are used for road plane model fitting, a large part of these superpixels may belong to the obstacle area, which affects the fitting accuracy and efficiency. The OD-SPH method uses the classification result of the OD-PNV method when fitting the model, and its process is shown in Figure 7. First, the superpixel point clouds classified as free spaces by the OD-PNV method are extracted, then the RANSAC algorithm is used to fit the road plane model on these point clouds. As the majority of superpixel point clouds classified as free spaces by the OD-PNV method are located near the road plane, the proportion of inliers in the dataset is significantly increased, thus improving the efficiency of the algorithm. In addition, this method can also avoid false fitting in scenes with complex road conditions. This paper makes a reasonable assumption based on the obstacle distribution in the traffic scene. That is, the probability of whether a superpixel belongs to an obstacle is related to the height of the point cloud from the road surface. The higher the height of the superpixel point cloud, the greater the probability that it belongs to an obstacle. The height of each point in the superpixel point cloud from the road surface can be calculated according to the fitted road plane model \(Ax+By+Cz+D=0\). Assuming that there is a point \(p_{i}(x_{i},y_{i},z_{i})(i=1\dots N)\) in the superpixel point cloud, the height of the superpixel point cloud from the road surface can be represented by the mean height \(h\) of each point in the point cloud:  
\[h=\frac{1}{N}\sum_{i=1}^{N}\frac{|Ax_{i}+By_{i}+Cz_{i}+D|}{\sqrt{A^{2}+B^{2}+ C^{2}}}. \tag{7}\]  
Similarly to the OD-PNV method, the Sigmoid function is still used to convert \(h\) into a probabilistic form. According to the previous assumption, we set the probability that the superpixels whose height is close to 0 m belong to an obstacle close to 0%. The probability that the superpixels that are close to or exceed \(h_{m}\) (in this paper, \(h_{m}\) is set to 1 m) belong to obstacles is set to be close to 100%. The probability that superpixels with height \(h_{m}/2\) above the ground belong to obstacles is set to 50%. First, normalize the mean height \(h\) as follow:  
\[DV_{SPH}=(h-h_{m}/2)*10. \tag{8}\]  
Thus, the Sigmoid function is constructed as follow:  
\[PR_{SPH}=\frac{1}{1+e^{-DV_{SPH}}}. \tag{9}\]  
\(PR_{SPH}\) is approximately between 0 and 1, which is used here to indicate the probability that the superpixel belongs to an obstacle. Figure 7: Flow chart of fitting road plane in OD-SPH method: (**a**) Segmentation result of OD-PNV method; (**b**) Extracted free space area (gray area); (**c**) Fitting result of road plane (blue area); (**d**) Display of road plane in the original image.