# Localization of LHD Machines in Underground Conditions Using IMU Sensors and DTW Algorithm
## 5 Conclusions  
The location of LHD in underground mining excavations is a key issue not only from the point of view of navigation and automation of the haulage process and increasing safety through anti-collision systems, but also the development of advanced analytics  
Figure 14: Examples of patterns extracted in cycle number 13. Figure 15: DTW distance between the road quality signal for cycle 13 and pattern B and its modifications. in the field of predictive traffic maintenance, production planning, and optimization of horizontal transport. For indoor conditions, especially underground, the range of available technology is limited. Internal sensors such as inertial, odometry, and heading angle are commonly used to estimate the absolute position of the vehicle in the fixed real-world coordinate system. Their main disadvantage is high susceptibility to scale errors and offsets which lead to unbounded errors on the position estimate. For this reason, it is necessary to correct them through additional sources of information from the LHD environment. In practice, solutions based on the detection of artificial beacons or natural features of the environment are used. Therefore, such solutions require the fusion of data from internal sensors embedded on the machine and the expansion of the infrastructure in its surroundings, which is not cost-effective both from the point of view of construction and maintenance of such a system. For the needs of post-factum analytics development, the mining industry is expected to develop a cheap and possibly non-invasive system, preferably based on a single data source. For this reason, we fill this niche by proposing an approach based solely on the accelerometer signal and digital map. In the article, we have focused on the issue of identifying the characteristic road surface patterns that will serve as control points for the correction of the estimated movement path on the map. In our case, the task comes down to recognizing the patterns hidden in the accelerometer signal along the \(Z\)-axis resulting from different height profiles of pavement. These patterns are not visible in the raw signals; therefore, we have proposed using the three-state road quality classification procedure for their extraction. Having a pattern database for various local mine points, we can further identify them while processing subsequent signals. This issue is related to the identification of similarity in signals (or their segments) and is commonly known in the literature as the time series matching approach. The most popular approach to measuring the similarity/dissimilarity between two time series is to estimate the Euclidean distance on the transformed representation. In our case, we chose the DTW algorithm because it is resistant to the boundary conditions of the investigated task (different runs of the machine in relation to the width of the road, unplanned stoppages, and different driving speeds resulting in different signal lengths and pattern distribution, the influence of driving speed and cargo box load on vibration level, and input data in flag form). The described concept was presented and validated on a laboratory stand, with the real industrial data being recorded by the LHD vehicle operating in an underground mine. The minimal length of the pattern was established as three times the wheelbase of the vehicle. For that pattern length, we were able to accurately identify different patterns for each of the three conducted test drives. The advantage of using the DTW method is the algorithm robustness to the signal distortion, consisting of the stretching or shortening of its specific fragments, which would correspond to operators covering given parts of the route more slowly or quickly, respectively. Conceptualization, P.S. and B.J. ; methodology, P.S. and B.J. ; validation, A.S. and W.K. ; formal analysis, P.S. ; investigation, P.S., B.J., and A.S.; resources, P.S., B.J., and A.S.; data curation, A.S.; writing--original draft preparation, P.S., B.J., and W.K.