Drift analysis and sectional post-processing of indoor simultaneous localization and mapping (SLAM)-based laser scanning data

.


Introduction
3D data such as point clouds have been part of the construction industry for almost two decades [1].It has been used for example in construction monitoring and quality control.Even though the full automation of these applications is still a challenge it is known that a combination of sensors is required to overcome the challenge [2].In addition, the integration of multiple data sources can improve the effectiveness of construction site documentation [3,4].Photogrammetry sensors and cameras as well as static laser scanners (LSs) have been used in the construction industry [5].Besides these sensors, it has been proven that handheld SLAM LSs have the required resolution for construction analysis.In addition, the usage of handheld sensors does not need trained users, and walking in the site is enough to capture the environment [6].
In addition to construction applications, handheld SLAM LSs have been studied in other applications such as cultural heritage modeling (e.g.[7,8]), underground mine mapping (e.g.[9,10]), building interior modeling (e.g.[11,12]), landform mapping (e.g.[13,14]), and tree modeling [15].There have been reports of detections of drift errors in SLAM point clouds.In the Raval et al. [16] study, a drift that is larger than a meter occurred during a one-kilometer closed-loop measurement in an underground mine.Correspondingly, Frangez et al. [10] detected the drift in an underground mine during line measurement.Zlot et al. [17] noticed that a drift error can be from 10 cm to over 1 m between features that are over 100 m apart in an outdoor cultural heritage site.In addition, in our earlier study, we detected a 20-40 cm drift during measurements on a straight street side [18].
The common feature of these studies is that the drift error was detected after the data was fitted to ground control by georeferencing [10,[16][17][18].The reason for the late detection is that the processing of the point cloud is done after the data collection and for this reason the users were unaware of problems during the SLAM data collection.Another common feature of these studies is that the drift error is small at the beginning of the trajectories, and it grows over time.However, the local error of the SLAM point clouds is minimal because the features in the environment are detected correctly, meaning that elements such as small rooms and the features inside them are in scale [10,[16][17][18].For these reasons, it is hard to recognize the drift error without georeferencing.
3D data has been used for many applications in the construction industry such as quality inspections, progress tracking and construction automation [1].The analyses are possible when a construction site has multi-time 3D data or a building information model (BIM) as a reference.However, the data should not have any drift if the analysis is meant to be reliable.For example, change detection between a drifted SLAM point cloud and a terrestrial laser scanning point cloud can demonstrate changes that do not exist in the environment.It is essential to reduce the effect of SLAM point cloud drifting if the purpose of the analysis is to apply it for construction purposes.
Errors in SLAM laser scanning have been reduced by improving the SLAM algorithm (e.g., [19,20]).This is not possible for the user of commercial SLAM LSs which utilize mostly black box SLAM algorithms.The authors have not found any studies that cover the impact of reducing errors with post-processing in commercial SLAM LSs.The https://doi.org/10.1016/j.autcon.2022  definition of post-processing in this manuscript is illustrated in Fig. 1.Before post-processing, the SLAM point cloud is collected with a SLAM LS and processed into a point cloud in the scanner's software.Then the point cloud is typically improved in third-party software.This includes noise removal, georeferencing, and error reduction with correction algorithms.
Differing from SLAM, drift errors have been reduced during postprocessing in traditional mobile laser scanning (MLS), in which case the calculation of the measurement trajectory is based on GNSS-IMU positioning (global navigation satellite system and inertial measurement unit).The reduction can be executed with a data-driven method or a model-driven method.The data-driven method reduces error based on ground control points and correction algorithms.The model-driven method reduces error based on mathematical models of MLS and analyzes individual error sources [21].Both of the methods have been widely used with traditional MLS [22][23][24][25][26][27][28][29][30][31][32].There is also plenty of software where this kind of error reduction is possible to execute [30,33,34].Because SLAM laser scanning has similar features to traditional MLS, these methods could be utilized in SLAM laser scanning.In addition, the post-processing of the traditional MLS as well as the SLAM point cloud could be executed in sections (later sectional postprocessing).In case of SLAM point clouds, the sections can be created based on the timestamps that the SLAM LS collects for the points.
This study aims to demonstrate error behavior and correction in drifted SLAM point clouds of the commercial SLAM laser scanner and software.The hypothesis regarding drift error behavior in SLAM point clouds is that the error is largest in the areas that are furthest from the start and end location in a loop measurement.In addition, we executed an experimental study on how much post-processing can reduce drift errors when the reduction of the error is done section-wise regarding the SLAM point cloud.This is executed with datasets with SLAM LS and terrestrial LS of building interiors and a small section in front of a building.The hypothesis of sectional error reduction is that smaller sections may decrease the error more than larger sections.

SLAM algorithms and drifting
Several SLAM algorithms exist.However, they have some repeating features.Every SLAM algorithm solves the problem of locating the sensor inside an unknown environment without knowledge of its own location.The basic process of the SLAM algorithm is building a map of an environment and at the same time using this map for locating itself.For this, a SLAM algorithm estimates the location of the sensor and the locations of the landmarks.At every timestamp, the algorithm saves the correlations between the sensor and the landmarks.The SLAM algorithm then updates the map and sensor locations.[35].To get good precision on the mapping results, SLAM algorithms require a closed-loop survey [36].The most known SLAM algorithms are Extended Kalman Filter (EKF) SLAM and Rao-Blackwellized particle filter known as FastSLAM [35].The new generation of the SLAM algorithms are based on the factor graphs, and they have been implemented in studies [37,38].
Most of the SLAM algorithms extract and match the features of two consecutive point cloud sets of different timestamps.Then they calculate the relative motion distance and location change with the IMU.This combination will solve the position of the SLAM laser scanner itself.The mathematical calculations differ in the algorithms [39].
Another possible method than feature-matching for the SLAM algorithm is to locate its positioning is scan-matching.Feature-matching refers to calculating absolute positioning while scan-matching refers to calculating relative positioning.The main difference is that in featurematching the features are matched and in scan-matching, the scan points are matched [36].The matching can be executed with many known algorithms such as Iterative Closest Point (ICP), Iterative Closest Line (ICL), Iterative Closest Plane (ICP), and Maximum Likelihood Estimation [40].
The drift can be caused by many factors such as misalignment of the start and stop location (loop closure), movement of objects in the environment, nonoptimal measurement path within the environment and the elapsed time in the data collection [16,18,41].The start and stop locations of the closed SLAM laser scanning measurement are recommended to be the same.Otherwise, it can lead to their misalignment [41].Movement in the environment can be as minimal as opening and closing doors or passing vehicles.However, these can lead to drift as recognized in the studies by Raval et al. [16] and Keitaanniemi et al. [18].In addition, the path of the SLAM laser scanner affects the errors of the resulting point cloud.SLAM algorithms use the iterative alignment of detected features to locate themselves in the environment.For this reason, closing loops are preferred in SLAM laser scanning to cope with dynamic drifting.Sometimes in nonideal cases, the measurement path does not provide the required number of features for the SLAM algorithm to function reliably, which leads to drifts in the path solution and thus distortions in the point cloud [18,41].

Study site
To examine the behavior of the drift of SLAM point clouds and the effect of post-processing, we collected point clouds at an Aalto University Campus in Espoo, Finland.We selected a four-story 1960s university building for our study site.It was designed by the architects Jaakko Kontio and Kalle Räike.The building has the typical features of a campus building such as lecture and meeting rooms and corridor environments [42].The study site is in Fig. 2a and it includes the hallways of the two first floors of the campus building, four rooms, and a small section in front of the building (Fig. 2b).Overall, the study site is circa 950 m2.All rooms and hallways are furnished with tables and couches and thus the SLAM algorithm has features to use for locating itself.There are six stairways in the study site which are the most featureless and narrow environments for SLAM with a narrow corridor on the first floor.In addition, the entry has many glass windows and walls, as does the 2nd floors hallway in front of the two smaller meeting rooms.In all the other locations there are many features close to the sensor.The study site also included a small section in front of the building that has a number of the features for SLAM.However, these features were only next to the building because of the wide street and the grass area next to the building (Fig. 2b).

Datasets
The reference point cloud was collected with a Leica RTC360 terrestrial laser scanner with 63 scans and 24 target spheres.The measurements took three and a half hours.The scanning settings were 6 mm in resolution at a 10 m distance.The data were processed in Leica Cyclone Register 360 software with a combination of cloud to cloud and target-based alignment resulting in an absolute mean error of 3 mm.
The SLAM point cloud was collected with a GeoSLAM ZEB-REVO laser scanner with a range of 30 m, a rotation speed of 0.5 Hz, a scanner profile frequency of 100 Hz, and a data acquisition rate is 43,200 points/sec.The vertical field of view is 360 • , and the horizontal is 270 • [43].It was executed as one scan in ten minutes with slow walking speed.In addition, during the walking path, we created internal closed loops in the rooms and hallways, as shown in Fig. 2. The data was processed in GeoSLAM Hub software with default settings.

The SLAM algorithm of the ZEB-REVO
The algorithm of the SLAM laser scanner estimates trajectory and sensor translations and rotations during the scanning.As new data is acquired, the algorithm uses the time window of the trajectory to process that data with information from the previous time step.Each segment of the data is processed iteratively.During the iteration, the algorithm identifies the corresponding surface patches from the point cloud.The second step of the iteration updates the trajectory.This step minimizes errors between matched surfaces and deviation from the measured inertial measurement unit's (IMU) accelerations and rotational velocities.It also estimates time synchronization and IMU biases [44].
After the iterative SLAM algorithm phases, the algorithm executes global registration.For it, the algorithm requires an initial parameter of the trajectory from the IMU.This trajectory should be a closed loop.In this phase the algorithm processes the entire trajectory as one window.The rest of the iteration steps are the same as in the case of segmented windows [44].

Analysis of the post-processing improvements
To demonstrate the behavior of the drift in the SLAM point cloud we compared the drifted SLAM point cloud to the reference point cloud.This process is described in more detail in Section 3.2.1.In addition, we post-processed the SLAM point cloud with two different SLAM point cloud section sizes and with two different correction algorithms.To analyze the discontinuity of the SLAM point cloud after sectional postprocessing we compared the statistical values of the overlapping area between the SLAM point cloud sections.

Initial situation analysis
To illustrate the drift in the dataset we aligned the SLAM point cloud to the same coordinate system as the reference point cloud using CloudCompare.This was executed using ICP (iterative closest point) calculation.For the ICP calculation, the SLAM point cloud was segmented to include only points from the first 99 s.In addition, the reference was manually segmented to cover the same area.These

ScanThinGrid3d
Removes some of the points that are within a grid cell which is 0.2 m in size segmented point clouds were aligned with ICP.The rest of the SLAM point cloud was transformed to the same coordinates as the first 99 s with the transformation matrix of the ICP calculation.With this process, we obtain at least the beginning of the drifted SLAM point cloud to align with the reference.After alignment, we removed the noise of the SLAM point cloud with a classification macro in Terrascan (Terrasolid, Finland).The macro classified points that are over the sensor's range, lonely clusters of points, and points from plane surfaces that were over a threshold from the median value.The steps of the classification macro are explained in more detail in Table 1 [45].Then these classes were removed before rest of the processes.After alignment and noise removal, the SLAM point cloud was manually segmented into eight sections which were 52-119 s in Cloud-Compare.Section lengths were chosen by the number of features in the section and based on the time of the detection of the points.From each section, we chose and segmented three planar surfaces with different orientations like a floor or a wall and calculated the distance difference between the SLAM point cloud and the reference point cloud.This was executed with the M3C2 plugin [46], implemented in CloudCompare.The plugin uses an existing point normal to create cylinders in a reference point cloud.These cylinders are then used for finding the intersections of the compared point clouds and the distance differences between them [46].From the distance differences, we calculated the statistical mean and standard deviation by using Gaussian fitting in CloudCompare.These values indicate the accuracy before the further drift-removing post-processing in third-party software.The process is presented in Fig. 3.
To identify the drift error accumulation, we analyzed the SLAM condition data calculated in GeoSLAM Hub software.The data shows  how well the SLAM algorithm can use detected features.This data colors the SLAM point cloud from blue, a good SLAM value, to a red, a poor SLAM value [47].The SLAM condition data was segmented in the same sections with the same method as before.For the analysis, we manually segment the points with poor SLAM value points in each section and visually analyze them based on the timestamps of the points and the trajectory.

Post-processing process
The SLAM laser scanner point clouds were post-processed in Terrascan (Terrasolid, Finland).At first, we aligned the SLAM point cloud sections to the reference point cloud with ICP in CloudCompare to give a mutual location to the sections before more detailed processing in Terrascan.Then we removed noise from the SLAM point cloud sections with the same classification macro as in Table 1 in Terrascan.The detailed processing of the SLAM point cloud sections was executed with fit to reference with correction algorithms.
Before post-processing in Terrascan, we created a reference point cloud that included 6-10 small, manually segmented areas of the reference point cloud.These segmented parts included 30 × 30-60 × 60 cm planes or segments of the furniture or other structure in the environment.The same areas that were segmented to be the reference point cloud for the post-processing were manually classified as one class in the SLAM point cloud sections in Terrascan.In the post-processing, the fit to reference with correction algorithms was executed only based on the segmented reference areas and the manually classified SLAM   points.For the correction algorithms, we concentrate on the datadriven methods of drift error reduction.There are several correction algorithms of the data-driven method.However, we concentrate on rigid and non-rigid transformation algorithms.The rigid transformation includes only translations and rotations of the point cloud.In contrast, the non-rigid transformation, also known as an affine transformation, includes deformations besides translations and rotations [48].Both of these correction algorithms are implanted to the SLAM point cloud in the post-processing phase with manually segmented reference points that are used as control points.The correction algorithm was executed in fit to reference by choosing different settings in the method.In the rigid transformation, the correction was applied systematically using transitions in XYZ directions and rotations around the XYZ axes based on the earlier defined reference point clouds.The non-rigid transformation differs only with the setting that allows deformation in the correction.The deformation is executed with a correction model based on the correction vector.The algorithm calculates the correction vector based on the reference point clouds and interpolates the values between the reference point clouds [45].
As in the initial situation, we chose and segmented the same three planar surfaces from each section and calculated the distance difference between the SLAM point cloud and the reference point cloud with the M3C2 plugin.In addition, as in the initial situation, we calculated the statistical mean distances and standard deviations by using Gaussian fitting and the average value of mean distance and standard deviation from all the section values.The processing process is shown in Fig. 4.
In addition, we analyzed the discontinuity of the sections after the post-processing in CloudCompare.We calculated the distance difference between sequential sections of the SLAM point cloud with the M3C2 plugin.From the distance difference calculations, we segmented three planar surfaces from each overlap area and calculated the mean distance and the standard deviation with Gaussian fitting.
Based on the results of the first sections of the SLAM point cloud we tested the same process with smaller sections that were from a 31-37 s timespan.The larger sections were divided into smaller ones only in the middle of the measurement path (270-475 s).The largest difference in the mean distance values was detected between those sections.The rest of the processing steps were executed in the same way as with the larger sections.We then compared the mean distance and standard deviation results of the sections and the discontinuity of the sections.

Analysis of the SLAM point cloud values during the walking path
The SLAM point cloud values based on the SLAM condition calculation of the GeoSLAM Hub are shown in Figs.5-7.

Analysis of the large sections
The SLAM point cloud was aligned to the reference point cloud based on the first 99 s of the measurement path.That part aligned to the reference with a root mean square error (RMSE) of 0.9 cm and the rest of the measurement path was transformed to its location based on the transformation matrix of that first section.The reference was aligned with this method because we knew that the SLAM point cloud had drifted and the probability that the drift had happened after the first 99 s was high based on the environment.The results of SLAM point cloud section alignments to the reference before post-processing are presented in Table 2 with information of the sections.The sections

Table 2
Display of the used section names, timestamps of the sections, lengths of the trajectories inside sections, and the number of the points in the sections.In addition, there are the root mean square errors (RMSE) of sections from alignment to the reference before post-processing.are illustrated in Fig. 8.In addition to the timestamps, we measured the length of the trajectory which was circa 440 m, and the middle point of it was under section 4 timestamps.The average point density from five meters from the sensor is circa 1900-3300 points per square meter.
The mean distances and standard deviation values between the SLAM point cloud and the reference point cloud of the horizontal planes for the larger sections are presented in Figs. 9 and 10.
The mean distances and standard deviation values between the SLAM point cloud and the reference point cloud of the vertical planes for the larger sections are summarized in Figs.11 and 12.

Discontinuity of the sections
The mean distances of overlapping areas between consecutive large sections are shown in Fig. 13 for both correction algorithms.Correspondingly, the standard deviation values of overlapping section areas are shown in Fig. 14.
The mean distances of overlapping areas between consecutive small sections are in Fig. 15 with both correction algorithms.Correspondingly, the standard deviation values of overlapping section areas are shown in Fig. 16.

Table 3
Average results of the discontinuity analysis with mean distances and standard deviations of the horizontal and vertical planes from overlapping areas between consecutive sections.

Comparison of the large and small sections
The mean distance values between the SLAM point cloud and the reference point cloud of the larger and smaller sections of rigid and nonrigid transformations are shown in Fig. 17  The average values of the discontinuity analysis from overlapping areas between consecutive sections are shown in Table 3.

Error behavior in the drifted SLAM point cloud
Based on the first results of the alignment of the SLAM point cloud to the reference point cloud, it was clear that the SLAM point cloud had drifted in the vertical direction (Fig. 9).With further analysis of the initial situation, the hypothesis of drift being largest in the furthest distance from the start and end location is correct.The drift error of the horizontal planes of the original SLAM point cloud increases towards the middle point of the measurement path and decreases towards the endpoint.The maximum drift error was 10.6 cm in the horizontal direction and it was inside section 4 (timestamps 270-337 s) that includes the middle point of the trajectory based on time and distance.The explanation for the largest drift value in the furthest distance is that the drift error is congested over time.Because of the close-loop measurement and the SLAM algorithm that tries to fit the start and end point together as well as possible, the drift moves away from that point and is congests to the furthest point of the measurement path.The congestion of the drift error could be avoided with additional control points during the measurement path which would used in the post-processing to reduce the drift.

Drift error locations
The drift error was analyzed according to the observations of measuring environment and walking path.Environments such as narrow doorways, narrow hallways with internal loops in the walking path, outside environments, and narrow staircases with a few features have led the SLAM algorithm to have decreased detection of the features to use in a SLAM algorithm.The drift error appearance locations and  walking path characteristics to prevent it are listed in Table 4.The errors of the point cloud can occur in the narrow hallway during internal loops in the walking path (Fig. 5).The second-floor hallway is long and narrow (Fig. 8).The widest part of the hallway is 8.5 m wide, and the narrowest part is 4 m wide.Most of the hallway is 6.5 m wide and 29 m long.In section 2, the trajectory has two internal loops.During these loops, the detected features had changed to the poor values for the SLAM.The first internal loop in section 2 starts to have

Table 4
Illustration of drift error locations during the walking path increases the drift with a threshold value of 2 cm.In addition, the walking path characteristics have prevented or minimized the drift error during the walking path.

Section name
Locations that increase the drift with over 2 cm Locations that increase the drift with under 2 cm Drift preventing walking path characteristics The second internal loop in section 2 has poor values of the features after turning toward the width direction of the hallway (Fig. 5).The gap in the FOV covers some of the earlier detected features.The features on the sides of the sensor are over 10 m in the distance.The poor SLAM values may be caused by the internal loop's small diameter (circa 2 m).The small diameter leads to quick turns for the sensor, and the scanner profile frequency cannot collect sufficient data for the SLAM algorithm.The size of the internal loop requires to be scaled based on the size of the space.In smaller spaces, the same errors did not occur.The distribution of the features in a narrow hallway with a small diameter internal loop causes problems for the SLAM algorithm.The internal loop in section 6 near staircase 4 in the second-floor hallway has the same problems as the second internal loop in section 2. Some of the features are close, but others are over 10 m in the distance, and the diameter of the internal loop is circa 2 m.In this case, the hallway is even narrower than in section 2. In section 6, it would have been better to create the loop as an ellipsoid towards the wider part of the hallway, while the walking path would have covered the same features again than in sections 2-4.section 4, the 180 • turn in the trajectory before staircase 3, has poor SLAM values.The poor values are smaller than section 2 in the first internal loop.This may be because the turn is executed towards the middle of the hallway.However, the turn is tight, which can cause poor SLAM values of the features.
In addition to internal loops in narrow hallways, a narrow doorway impacted the SLAM algorithm and the amount of drift (Fig. 6).In section 3, the drift is 3 cm larger after the narrow doorway.The narrow visibility of the features for the SLAM in transition through the doorway can cause the drift.The space after the doorway has only minimal detection of the features before the transition through the doorway.These detected features were insufficient to keep the SLAM localization errorless because they had poor SLAM values.The same effect was in section 4 with the same doorway.However, it was smaller because the drift error differs only circa 1 cm.This may be due to the SLAM algorithm already gathering information from both sides of the narrow doorway.The reason for the existing information is that the measurement path is revisiting the same space after the room behind the narrow doorway.For that reason, the SLAM localization works better, and the drift increases only a little bit.However, the features detected straight after the doorway from over 4 m distance had poor SLAM values.
Similarly that the narrow doorway impacted the dirt the narrow staircase 4 in the transition between sections 5 and 6 (Fig. 8) impacted the drift.The drift changes circa 2 cm larger after the transition to the downstairs in the narrow staircase (Fig. 6).The poor SLAM values may be caused by the narrow hallway of the second floor and the halfglass walls on the stairs and upstairs.The upstairs features are in the blind spot because of the narrow staircase and the gap in the sensor's FOV.Tilting the sensor more perpendicularly to the stairs would have avoided this.By tilting the sensor, the blind spot of the FOV would be covering a more featureless part of the environment.
Section 8 has a small (circa 0.7 cm) drift change in the horizontal planes after a brief visit outside.It is detectable in the SLAM values of the features, which are primarily poor on the outside (Fig. 7).Some of the poor SLAM value detections are right before the end of the measurement during the sensor's placement on the table.The same phenomenon is detectable at the start of the measurement.The poor SLAM values after the start have a minimal effect on the drift because the drift is 0.2 cm in section 1.The change in the feature distribution can cause the drift of section 8 outside.The wide street next to the building does not have many suitable features for the SLAM algorithm.For that reason, the features are mostly on one side of the sensor.Besides, indoors the floors, ceilings, and walls are all suitable for the SLAM algorithm to locate itself.In addition to them, the furniture and other objects add more diversity to the features, which helps the SLAM algorithm to do more precise locating.However, the coming back to the indoors in section 8 minimizes the drift in the section.Because the returning space is the same hallway as the starting and ending location, the drift is not accumulated in the poor SLAM value area.The processing of the SLAM point cloud has moved the error of the poor SLAM values further away from the end location, and they accumulate in the earlier sections (3)(4)(5)(6).
The accumulation of the poor value errors changes the drift error to a different location than the poor SLAM values.The most significant accumulation of the drift error is in the furthest location (section 4) from the start and end location.From the start to the most distant location through section 1 to 4, the overall drift accumulation is 10.6 cm.A small part of the error of the internal loops in section 2 is shown in the drift between sections 1 and 2 (Fig. 8).The drift accumulates slightly between these sections.In section 3, the drift is circa 3 cm larger than in section 2. This is due to the internal loops in section 2 and the narrow doorway in section 3. The largest effect of the error of the internal loops in section 2 has accumulated in section 3. n addition, the drift accumulates from section 3 to section 4 because of the narrow doorway.This accumulation between sections 3 and 4 on both sides of the narrow doorway may be small because the walking path goes through already detected features.However, the error accumulates circa 4 cm in section 4 after staircase 3. The reason is the 180 • turn before the staircase and the other error areas that have been before section 4.
The same effect is from section 8 to section 4. In section 8, the drift occurs from the outside visit with a small accumulation.This may have the same effect as between section 3 and section 4 because section 8 returns to the same space as the whole measurement has been started.The return to the same room as the starting location is shown in the drift between sections 8 and 7 with a small accumulation.After staircase 6 in section 6, the drift has accumulated circa 3 cm more from section 7. The drift grows circa 4 cm in staircase 5.All this accumulation between sections 8 and 6 are caused by the outdoor visit and the internal loop in section 6.In section 5, the drift accumulates based on the narrow staircase 4. All the drift accumulates to sections 4 and 5 even though they had a minimal amount of the poor values of the features for the SLAM algorithm to solve itself.Walking path extension to cover the same features as in sections 2-TeXFolio:sec4 of the narrow hallway on the second floor would have minimized the amount of the drift in section 6.

Recommendations for the locations of the control points
Based on these results, the locations of the additional control points should be after narrow staircases that lead to the narrow but high ceiling hallways with a low number of features, in long and narrow hallways, near narrow doorways, and outside during transitions between inside and outside measurements.After narrow and almost featureless staircases should add control points.Significantly in transitions to narrow high ceiling hallways after the narrow stairs.In narrow featureless hallways, it is important to add a control point.Adding at least two control points before and after a narrow hall would be good.However, if it is over 30 m, adding a control point in the middle of the hallway is not a bad idea.Control points could be located on both sides in narrow doorways if the measurement path enters and exits from the same doorway.The control point should be located after a narrow doorway in other cases.It is important to have a control point outdoors while visiting there.Even though the outdoor environment does not have the same feature distribution as in this study, traffic or other types of movement may affect the SLAM algorithm.
These control points could be used to prevent drift either during the SLAM algorithm calculation or during post-processing on construction sites.In some of the SLAM laser scanners on the market, adding a control point for SLAM algorithm processing is possible.The results of this study indicates some of the places that require control points so that drift can be prevented in SLAM laser scanning.Based on this information, limiting the control points to only useful locations is possible.However, if the drift occurs despite the control points it is possible to use the same control points in the post-processing with third party software.Besides, it may need a couple of control points in possible error areas depending on the post-processing method.In addition, additional control points in problem areas may bring closer the possibility of creating automation in construction monitoring and quality controlling with SLAM laser scanners.

Analysis of drift error reduction in post-processing
In addition to the error behavior, we studied error reduction with sectional post-processing.Overall, the post-processing reduced drift error in all directions with both section sizes.The maximum drift reduction was 10.4 cm.However, this was not the case with small sections in the vertical direction (Fig. 19).There the average mean distance between the SLAM point cloud and the reference stayed at the same or increased some millimeters in the sections.In addition, the average of the standard deviations between the SLAM and reference point clouds decreased after post-processing with large sections (Figs. 10, 12, 18 and 20).With small sections, the same increase was detectable as in the mean distances.The reason for this may be that the noise removal used medians of the point cloud surfaces to reduce noise.It was executed before the transformation algorithms.With the smaller sections, the median could easily be in a different location by a couple of millimeters than with the larger sections based on the amount of the data.
The vertical planes have under a 0.5 cm mean distance from the reference point cloud before the post-processing of the SLAM point cloud (Fig. 11).This can be due to the sensor's accuracy which is 1-3 cm [49].For the large sections the average mean distance does not change after post-processing.For the small sections (Fig. 19) the mean distance of the section increases over the values that were present before post-processing.This shows that it is not profitable to post-process the points from the direction that already has good values.Particularly, the average of the mean distance from all the small sections is almost the same as before post-process.These are as well under the sensor's accuracy.In conclusion, the drift is mainly detected only in one dimension.Because the drift is mainly in one dimension, in the future drifted SLAM point clouds could be processed in only the direction that has the drift.Based on the results, the differences between non-rigid and rigid transformations are relatively small.Overall, the difference is from a couple millimeters to a half of centimeter (Figs.[17][18][19][20].However, this is dependent on the case because it is possible to have drift in SLAM point clouds in many directions. In the sectional post-processing, the continuity between the sections is important.Based on the average results of the discontinuity analysis the small sections have smaller changes between horizontal planes than the larger sections (Table 3).At the same time the change is almost the same for both section sizes in vertical planes.This is shown also in Fig. 13 which has four overlapping sections with over a 2 cm mean distance between sections and in Fig. 15 where the number of sections that are over 2 cm is three.In addition, the standard deviations are smaller in the small sections than in the large sections (Figs. 14 and  16).
The hypothesis of smaller sections reducing drift more than large sections was correct in the horizontal planes.With the small sections the average mean distance between the SLAM point cloud and the reference point cloud was close to 0 cm.At the same time the value for the large sections was 0.7 cm at the best.Because the results for the vertical planes were the same with both sections it does not affect the selection of the section size in sectional post-processing.In addition, small sections show better results in the discontinuity analysis between sections.The only downside with the small sections is that the standard deviation between the SLAM point cloud and the reference is on average 0.2-0.3cm larger with the small sections than with large sections.For the transformation algorithms the section size has a small effect.With the small sections the non-rigid transformation is circa 0.6 cm better than with large sections and in rigid transformation the difference is circa 1.5 cm.In addition, the non-rigid transformation algorithm is better in horizontal plane errors and rigid transformation in vertical plane errors.Overall, the choice of the section size and post-processing algorithm is dependent on the application and needed accuracy.Smaller sections reduce drift more, however, larger sections also have results that fall below the sensor's accuracy.
Even though our post-processing gives promising results of reducing drift error, a method that requires collecting both a SLAM point cloud and some other more accurate point cloud such as a terrestrial laser scanner point cloud is not an optimal way to execute the postprocessing of a SLAM point cloud.However, it proposes that sectional post-processing with the correction algorithms in third-party software is a possible method to reduce a noticed drift error in a SLAM point cloud.The other optional methods to reduce drift would be a tool that reduces the error over time, such as an interpolation, time-based leveling, or time-based linear transformation [21,[50][51][52].However, the authors are not aware of any third-party software that includes any of these error reduction methods.However, sectional post-processing could also be executed by using added control points such as spherical targets for reference information in the post-processing.Some of the required and critical control point locations (as featureless staircases, narrow hallways and doorways) have been identified and discussed in this study.The sectional post-processing method presented in this study could be used for example for construction documentation, monitoring and quality analyzing purposes.To identify real change between new and old datasets, the datasets should include as few errors as possible.Because SLAM laser scanning is a walkable method to collect 3D data from a construction site, it would be a useful tool for construction monitoring and quality analyzing.Even though it has sometimes presented drift errors, as we explained in the introduction, this can be reduced as the experimental study illustrates.However, in the case that the reference points for the sectional post-processing are taken from earlier point clouds there needs to be points that are definitely from stable features.If the reference points are stable, the results that are shown in this experimental study can be reached with multi-time construction documentation datasets by using the sectional post-processing process.In addition, if we add features that are detectable with SLAM laser scanners in the critical locations, it is even possible to prevent drift from occurring.

Conclusions
This paper demonstrated the behavior and correction of drift in a SLAM point cloud.The study case shows that the drift error was the largest in the middle of the trajectory based on time and distance, with a value of 10.6 cm.The SLAM LS can drift over 10 cm within ten minutes of measurement.Environment affects the drift, such as narrow staircases, long narrow hallways, narrow doorways, and visits from inside to outside.It would be important to add control points after or inside these locations to prevent drift errors from occurring.In addition, the measurement path can be optimized to prevent drift.For example, the measurement path should revisit the environments that have been measured.Similarly, the internal loops, which are scaled based on the size of the environment and measured toward the middle of the room, can minimize the drift.The internal loop diameter can be circa 2 m when the space is circa 22 square meters.However, in 220 square meters, the 2 m diameter in the internal loop is too small.The drift was mainly detected only in the vertical direction because, in vertical planes, the mean distance from the SLAM point cloud to the reference was 0.5 cm.In addition, the standard deviation is under 2.6 cm, which is withing the sensor accuracy specification.
Sectional post-processing could reduce drift by from 10.6 cm to 0.2 cm in this case study.However, the drift error is detected to appear only in the vertical direction so that the post-processing could be executed only in that direction.Based on the results of this study, the horizontal direction can still be withing the sensor accuracy specification.The building interiors can be measured at the level of 1-3 cm accuracy when the SLAM point cloud is errorless and the noise is removed.Regarding section size, smaller sections reduce the drift error more than larger sections.In addition, non-rigid transformation reduces drift error more than rigid transformation.However, the choice of section size and post-processing algorithm is still dependent on the application and required accuracy because the results have minimal differences.Based on the results, it is possible to conceive a measurement path that can collect errorless point cloud data from building construction.With this kind of measurement path, commercial SLAM LSs are even more suitable for future construction applications such as documentation, monitoring, and quality analysis.In addition, the effectiveness of SLAM laser scanners in construction applications is still possible even with drifted point clouds.The commercial SLAM

Fig. 1 .
Fig. 1.Definition of post-processing used in this manuscript.

Fig. 2 .
Fig. 2. Representation of the study site with the trajectory of the SLAM sensor colored from red to blue as start to finish.(a) Floorplan of the study area inside the building (b) Area outside the building has green grass areas with some trees (circles), street (gray), and sidewalks (white).

Fig. 3 .
Fig. 3. Used process of demonstrating the drift error behavior in the initial situation.

Fig. 4 .
Fig.4.Utilized post-processing process and the process to identify the discontinuity.The process was repeated at first with the large sections and then with the small sections.

Fig. 5 .
Fig. 5. Illustration of the poor SLAM value points in the internal loops of the walking path on the second floor.All the detected points of the hallway are represented with blue colors based on the distance to the walking path (black).The hallway features are colored gray, and the poor SLAM values are represented with orange.The starting locations of the poor SLAM value detections are marked with black triangles in the walking path.In addition, the hallway images represent the environment in the internal loop locations.

Fig. 6 .
Fig. 6.Representation of the poor SLAM valued transitions in sections 3-4 and 5-6.All the detected points of the environments are represented with blue colors based on the distance to the walking path.The features of the environments are colored gray, and the poor SLAM values are represented with orange.The walking path is colored black in the areas that have detected poor SLAM values and white in the rest of the sections.(a) narrow doorway in sections 3-4 (b) narrow staircase in sections 5-6.

Fig. 7 .
Fig. 7. Distribution of the poor SLAM value points detected in section 8.All the detected points of the section are represented with blue colors based on the distance to the walking path (black).The section features are colored gray, and the poor SLAM values are represented with orange.The white lines represent the doorways, and the outside area is measured with the trajectory that is between them.

Fig. 8 .
Fig. 8. Illustration of the sections in the floorplan of the study site.The large sections are represented with colors and the red lines represent locations that separate the smaller sections inside the large sections.The staircases are named with a number for analysis purposes.

Fig. 9 .
Fig. 9. Representation of mean distance of the horizontal planes between the SLAM point cloud and the reference point cloud in the large sections.

Fig. 10 .
Fig. 10.Representation of standard deviation of the horizontal planes between the SLAM point cloud and the reference point cloud in the large sections.

Fig. 11 .Fig. 12 .
Fig. 11.Representation of mean distance of the vertical planes between the SLAM point cloud and the reference point cloud in the large sections.

Fig. 13 .
Fig. 13.Mean distances of overlapping areas of consecutive large sections are represented in rigid and non-rigid transformation.

Fig. 14 .
Fig. 14.Standard deviations of overlapping areas of consecutive large sections are represented in rigid and non-rigid transformation.

Fig. 15 .
Fig. 15.Mean distances of overlapping areas of consecutive small sections are represented in rigid and non-rigid transformation.

Fig. 16 .
Fig. 16.Standard deviations of overlapping areas of consecutive small sections are represented in rigid and non-rigid transformation.

Fig. 17 .
Fig. 17.Mean distance of the horizontal planes is presented between the SLAM point cloud and the reference point cloud in the large sections and small sections of rigid and non-rigid transformations.
in the horizontal direction and Fig. 19 in the vertical direction.The standard deviation values of rigid and non-rigid transformations are shown in Figs.18 and 20.

Fig. 18 .
Fig. 18.Standard deviation of the horizontal planes is presented between the SLAM point cloud and the reference point cloud in the large sections and small sections of rigid and non-rigid transformations.

Fig. 19 .
Fig. 19.Mean distance of the vertical planes is presented between the SLAM point cloud and the reference point cloud in the large sections and small sections of rigid and non-rigid transformations.

Fig. 20 .
Fig. 20.Standard deviation of the vertical planes is presented between the SLAM point cloud and the reference point cloud in the large sections and small sections of rigid and non-rigid transformations.
while turning toward the stairs next to staircase 2 (Fig.5).Most of the already detected features stay under the gap in the sensor's field of view (FOV) during the internal loop.The other features are self-repeating staircases or features with over 5 m distance from the sensor.The direction of the internal loop towards anti-clockwise may have caused the poor SLAM values because most of the features are in the middle of the hallway.

Table 1
Steps of the classification macro used in Terrascan with definitions.
Name of the step Definition ScanCutLong Cuts off long range measurements from the features that are detected multiple times with the sensor ScanClassifyRange Classified all the points that are over 15 m from the scanner ScanClassifyIsolated Removes isolated points that had only one two neighbors within 0.2 m radius ScanClassifySurface Classified points to a surface with 0.015 m tolerance ScanSmoothenXyz 3D smoothing process based on the 25-30 neighboring points by fitting 2nd degree surface to the points