# Robust Analysis and Laser Stripe Center Extraction for Rail Images
## 1 Introduction
Piecewise fitting is then applied to acquire the optimized laser  
Figure 2: Light stripe in a rail image. stripe centerline. However, while there is always a gap in rail images, these methods [13; 14] cannot recognize the gaps between surfaces caused by the shooting angle, and cannot always link the gaps; moreover, a considerable amount of time is spent on centerline optimization. In the work by [PERSON] et al. [15], a robust laser stripe extraction method that uses ridge segmentation and region ranking was proposed; however, ridge direction cannot be computed for saturated regions of the stripe, which may occur in rail images. In the method proposed by [PERSON] et al. [16], template matching is utilized to enhance the light stripe image. In this method, the grayscale distribution of the normal cross-section of the corresponding position of a good-quality light stripe image is used as a template for poor-quality light stripe images. However, this strategy is not appropriate for use in rail profile measurement, as the obtained results cannot represent the true profile. In the method developed by [PERSON] et al. [17], a multi-scale Retinex (MSR) algorithm is used to enhance the light stripe image. However, because this method enhances the entire image, it is prone to local over-enhancement. Recently, some light stripe extraction methods [18; 19] particularly for use on rail images have been proposed. In the work by [PERSON] et al. [2], regions containing the rail waist light stripe are tracked using a Kalman filter, and the extreme value method, center of mass, and Hessian matrix are then combined to extract the precise sub-pixel coordinates of the light stripe centers. In the method proposed by [PERSON] et al. [20], the deep learning model ENet was applied to segment the rail laser stripe using the grayscale and gradient direction, which makes it more robust to noise. Nevertheless, the construction of the ENet model is complicated, and due to the influence of changing ambient light, the grayscale and gradient information of the same segment may not be consistent. The current image enhancement methods can be divided into two categories, including the spatial domain and frequency domain. For the frequency domain method, firstly, the image is converted to a frequency domain, then processed with an enhancement operator, and the enhanced image is finally obtained by inverse transform. Fourier transform (FT) [21] provides a means for transformation to the frequency domain, and the information will not be lost in the process of inverse transform. This method is efficient, but has difficulty coping with adaptive image enhancement. Wavelet transform (WT) [22], like FT, is a mathematical transform. Its basic idea is to use a family of functions to express or approximate a signal. The WT image enhancement algorithm can effectively highlight the details of the image, but can easily magnify the noise in the image. The spatial method performs the operation on each pixel in the image, and directly changes the gray value of the image pixel. The Savitzky Golay filter [23] is a kind of low-pass filter. It calculates the filter coefficients by using polynomial convolution. This method is simple and easy to understand, and has strong operability. However, its parameters need to be set carefully, and automatic filtering cannot be realized. Via the preceding analysis, it is evident that the existing light stripe extraction methods are not robust to image noise, and do not make full use of the characteristics of the rail light stripe image in the procedures of preprocessing and centerline optimization. Therefore, the image quality after preprocessing remains poor, and the speed of centerline optimization is slow. To overcome these problems, this paper proposes a laser stripe center extraction method for rail images captured in outdoor environments by considering the characteristics of the rail stripe image. This method consists of two steps, namely, image preprocessing and center extraction.