Table of Contents
Simultaneous Localization And Mapping / SLAM Algorithms have the core function of enabling autonomous systems (such as robots, self-driving vehicles, and drones) to achieve self-localization and environmental mapping in unknown environments. They solve the problem of “where am I?” for autonomous systems and serve as the foundation for the system to “perceive the world.”
What Are Simultaneous Localization And Mapping / SLAM Algorithms?
Simultaneous Localization And Mapping means that a mobile device can simultaneously localize itself based on its position and environment while moving, and construct an environmental map.

The main purpose of SLAM algorithms is to perform map construction and position estimation in unknown environments. That is, as an autonomous system moves, it simultaneously “knows where it is” (localization) and “draws a map of the surrounding environment” (mapping) – both processes are performed simultaneously and depend on each other. This then guides subsequent actions such as navigation, obstacle avoidance, grasping, and other tasks.
Principles of Simultaneous Localization And Mapping / SLAM Algorithms
Simultaneous Localization And Mapping / SLAM Algorithms form a continuous closed-loop process:
–Perception: Acquire environmental information through sensors such as LiDAR, cameras, ultrasound, IMU, etc.
–Matching: Associate the current observation with the existing map or features.
–Localization: Calculate the robot’s current pose (position and orientation) using mathematical models.
–Map Update: Continuously correct and refine the environmental model.
Composition of Simultaneous Localization And Mapping / SLAM Algorithms
–Front-end Processing: Also called Odometry. It is responsible for extracting features from continuous sensor data (e.g., geometric structures in laser point clouds, corners or edges in images) and estimating the robot’s short-term relative motion by matching these features.

–Back-end Optimization: Performs global optimization on the robot’s pose (position and orientation) estimated by the front-end and the map information. Since front-end estimation accumulates errors, the back-end uses complex mathematical models (such as graph optimization or filtering algorithms) to correct these errors and improve the global consistency of the map.
–Loop Closure Detection: Identifies whether the robot has “returned to a place it has visited before.” When a loop closure is detected, the system triggers a global optimization to eliminate drift errors accumulated over long-term operation, significantly improving map accuracy and robustness.
–Mapping & Map Update: Constructs and updates the environmental map in real time based on the optimized robot pose and sensor observation data. The map can be a 2-dimensional grid map, a 3-dimensional point cloud map, or a more abstract topological map, used for path planning and obstacle avoidance.
Types of SLAM Algorithms
SLAM is mainly divided into Lidar SLAM and Visual SLAM based on differences in core sensors and technical approaches.
| Type | Main Data Source | Advantages | Disadvantages | Typical Applications |
| LiDAR SLAM | 2Dimensional/3-dimensional LiDAR point cloud | High accuracy, strong resistance to lighting interference, and long measurement range | High cost, difficulty in recognizing semantic information, sensitive to transparent/reflective surfaces (e.g., glass) | Factory workshops, warehouse logistics |
| Visual SLAM | Monocular, stereo, or RGB-D camera images | Low cost, rich information, ability to extract semantic information | Susceptible to lighting changes, texture deficiency, occlusion, and large accumulated error | Service robots, light-duty AMRs |
In industrial practical applications, multi-sensor fusion SLAM algorithms are gradually becoming mainstream to cope with complex and changing industrial environments.
Mainstream Simultaneous Localization And Mapping / SLAM Algorithms
Cartographer
A SLAM algorithm developed by Google based on LiDAR and RGB-D camera data. It is cross-platform, supports multiple sensor configurations such as LiDAR, IMU, odometry, GPS, and landmarks, and is widely used in robot navigation, autonomous driving, and other fields.
The Cartographer algorithm completes the construction of an occupancy grid map in the front-end. After obtaining the best pose for each LiDAR scan frame, it inserts the scan frame into a submap, obtaining a locally optimized submap and recording the pose.
The back-end performs global map optimization based on pose relationships between scan frames, and uses branch-and-bound to accelerate solving, thereby obtaining the best pose for closed-loop scan frames in the global map.
Karto
A SLAM method based on pose graph optimization, using a highly optimized and non-iterative Cholesky matrix to decouple and solve the system. It is suitable for various indoor environments and can handle both static and dynamic obstacles.
Karto represents the map using the standard form of graph theory, where each node represents a pose point on the mobile robot’s trajectory and the perceptual information returned by the sensors at that pose.
Edges between nodes represent displacement vectors between adjacent robot poses. For each new pose localization, the matching relationships between nodes and constraints from edges are required to maintain consistency of localization estimation errors.
LIO-SAM
A novel LiDAR-inertial navigation system that combines LiDAR and IMU data to achieve high-precision localization and trajectory mapping for robots.
The front-end, building on traditional LiDAR SLAM, uses Kalman filtering and factor graph optimization to fuse LiDAR and IMU data, further improving localization accuracy and mapping performance. The back-end incorporates optimization algorithms, greatly enhancing both localization and mapping accuracy.

LOAM Series
A mature family of LiDAR-based SLAM algorithms, including LOAM, LOAM-Velodyne, LOAM-LiDAR, etc
—LOAM uses LiDAR data for mapping and localization, utilizing features of point cloud data such as spatial clustering and continuity constraints to estimate pose.
—LOAM-Velodyne uses 3D point cloud data from Velodyne LiDAR to achieve higher-precision map reconstruction and localization.
—LOAM-LiDAR uses LiDAR sensors for mapping and localization, efficiently obtaining 3D coordinate information of target objects, offering significant advantages in some robotic application scenarios.
ORB-SLAM3
One of the best current feature-based visual SLAM systems. It supports monocular, stereo, and RGB-D camera modes, and has been optimized in feature extraction, keyframe selection, map maintenance, and pose optimization. It can establish short-term, medium-term, and long-term data associations, making the system both accurate and robust.
The front-end visual odometry is based on ORB features, establishing data associations of feature points between image frames and 3D-to-2D associations between image feature points and map points. It has good robustness and extraction efficiency. Loop closure detection and relocalization are also implemented based on ORB features.
VINS-Fusion
A visual SLAM algorithm based on visual-inertial sensors. It fuses visual and inertial information to improve a robot’s localization and navigation capabilities in unknown environments.
The front-end and back-end exchange data through a state propagation mechanism. The front-end merges IMU and image data to generate a set of state quantities, which are then passed to the back-end for fusion and optimization. The back-end passes the optimized state quantities back to the front-end to update the robot’s motion estimation.
Comparison And Selection of Different Simultaneous Localization And Mapping / SLAM Algorithms
| Attribute | Cartographer | Karto | LIO-SAM | LOAM | ORB-SLAM3 | VINS-Fusion |
| Sensors | 2-Dimensional LiDAR-based | 2-Dimensional LiDAR-based, tightly integrated with ROS | 3-Dimensional LiDAR-based | 3-Dimensional LiDAR-based, good in slow-moving scenarios | Vision sensor-based | Vision + inertial sensor-based |
| Robustness | High | Medium | Medium | Medium | Medium | High |
| Positioning Accuracy | High | Medium | Medium | Medium | High | High |
| Mapping Area | Large | Medium | Medium | Small | Medium | Medium |
| Mapping Quality | High | High | High | High | Medium | High |
| Real-time Performance | Moderate | High | High | High | High | Medium |
| Scalability | Medium | Medium | Medium | Relatively poor | Medium | High |
| Hardware Requirements | Relatively high | Relatively high | Moderate | Relatively high | Relatively low | Relatively high |
| Engineering Implementation Difficulty | Medium | Low | Relatively high | Low | Relatively high | Relatively high |
Key Technologies of Simultaneous Localization And Mapping / SLAM algorithms
Feature Extraction
The first step of SLAM algorithms is feature extraction – identifying repeatable “landmarks” in the environment from sensor data. This is similar to how humans remember reference points like “doorway,” “pillar,” or “corner” in an unfamiliar environment. Accurate and robust feature points are the foundation for subsequent data association and state estimation.

–LiDAR Feature Extraction: Targets LiDAR point cloud data. By analyzing local geometric properties such as curvature and normal vector changes, it detects geometric features in the environment. Common algorithms include edge detection based on local curvature and plane feature recognition based on least squares fitting. These features typically represent structured information such as walls, corners, and pillars.
–Visual Feature Extraction: In camera images, visual feature extraction aims to find keypoints that remain stable under different viewpoints, lighting, or scales. These keypoints are usually areas with rich texture and significant local variation. Common classic algorithms include:
ORB (Oriented FAST and Rotated BRIEF): An image feature that balances speed and rotation invariance, widely used in real-time SLAM due to its high computational efficiency.
SIFT (Scale-Invariant Feature Transform): Highly robust to scale and rotation changes, but relatively computationally intensive.
SURF (Speeded Up Robust Features): An accelerated version of SIFT, with similar performance but faster computation.
–Deep Learning Feature Extraction: To cope with complex and changing industrial environments (e.g., lighting changes, reflective surfaces, low-texture areas) and to improve the real-time performance and robustness of feature extraction, deep learning-assisted feature extraction is becoming a new direction. By training neural networks, robots can more intelligently identify and describe features, even performing well in scenarios where traditional methods struggle.
SuperPoint: A self-supervised neural network that simultaneously detects keypoints and generates descriptors, performing well under complex lighting and viewpoint changes.
R2D2 (Reliable and Repeatable Detector and Descriptor): A deep learning-based feature extraction method that aims to improve the repeatability of feature points (i.e., the ability to stably detect the same feature point in different images) and is robust to local geometric and appearance changes.
These deep learning methods, by learning feature patterns from massive data, can generate more discriminative and stable features, providing more reliable inputs for subsequent data association and state estimation. To improve real-time performance, many industrial robots use lightweight feature extraction networks on embedded platforms or edge computing devices, enabling parallel computation of feature detection and description.
Data Association
After feature extraction, the SLAM algorithm needs to match the current observation with the existing map. This process is called data association. Its core goal is to answer: “Have I seen these feature points before? If so, where am I now?” Mainstream methods include:
ICP (Iterative Closest Point): Iteratively aligns the current point cloud with the map point cloud to minimize the distance between them, thereby estimating the robot’s pose.
Feature Matching: Based on image or point cloud feature descriptors, it finds matching sets of similar feature points and computes pose transformations from these matches.
Probabilistic Data Association: Uses Bayesian probability inference to determine correspondences between observations and map points in the presence of occlusions, improving matching robustness.
The accuracy of data association directly affects SLAM localization stability. Incorrect matching can lead to drift or map distortion. Therefore, industrial applications often incorporate loop closure detection to correct accumulated errors.
State Estimation
After data association, the SLAM system needs to calculate the robot’s pose in space using mathematical models. This process is called state estimation, typically implemented using filtering or optimization methods.

–Filtering Methods:
EKF-SLAM (Extended Kalman Filter): Based on a linear-Gaussian model, it achieves real-time estimation of robot pose and map features through a prediction-update process.
FastSLAM: Decomposes the SLAM problem into multiple particles, each representing a possible trajectory, and approximates the true posterior distribution using particle filtering, solving the computational complexity problem of EKF in large-scale maps.
–Optimization Methods (Graph SLAM):
Graph Optimization: Represents robot states (poses) and sensor observation constraints as a graph. Nodes represent the robot’s pose at a specific time, and edges represent relative motion constraints between adjacent poses or constraints between observations and poses. By minimizing a global error function over the entire graph, it finds the optimal solution for all poses and map features.
g2o (General Graph Optimization) and Ceres Solver are two common graph optimization frameworks that provide efficient nonlinear optimization tools and are widely used in high-precision SLAM systems such as Google Cartographer and ORB-SLAM3.
Loop Closure Detection
SLAM algorithms inevitably accumulate errors over long-term operation due to factors such as inaccurate motion estimation. To correct these errors, the system must be able to recognize that “I have returned to a place I’ve visited before.” This is loop closure detection. Effective loop closure detection can propagate local consistency to the global level, ensuring map consistency in large scenes and significantly reducing drift. Typical techniques include:
–Geometry-based loop closure detection: Compares the geometric shape of current sensor data (e.g., laser point cloud) with regions in the historical map to determine if they overlap. This often involves variants of point cloud matching algorithms (e.g., ICP) to evaluate geometric similarity.
–Vision-based loop closure detection: Uses image data to determine scene similarity. This method is not directly constrained by the robot’s motion trajectory but focuses on recognizing the same visual environment. Common techniques include:
Bag of Words (BoW): Represents an image as a collection of “visual words” and compares the distribution of visual words across different images to determine if they belong to the same scene. BoW quantizes image features into “words” from a pre-defined visual vocabulary, enabling efficient image similarity retrieval.
CNN-based image similarity detection: Uses deep convolutional neural networks (CNNs) to extract global descriptors from images. These descriptors capture high-level semantic information and are robust to lighting and viewpoint changes. For example, networks like NetVLAD generate compact and highly discriminative image descriptors. Scene similarity is determined by comparing distances between these descriptors, which is especially suitable for loop closure detection in large-scale environments.
–Semantic-assisted loop closure detection: Incorporates deep learning networks to recognize semantic information in the scene (e.g., “this is a shelf area,” “that is an assembly line”), further improving the reliability of loop closure detection. By understanding the semantic content of the scene, robots can more intelligently determine whether two locations are the same, performing particularly well in scenarios with indistinct geometric features or dynamic environments.
When a loop closure is reliably detected, the system creates an additional constraint indicating that the robot’s current position is the same as a historical position. The system then triggers a global graph optimization to correct the entire robot trajectory and map for consistency, thereby eliminating accumulated drift and correcting the map’s topology.
Map Representation and Maintenance
The map is not only the basis for localization but also the foundation for path planning and obstacle avoidance decisions. Common map representations in SLAM algorithms have their own advantages and disadvantages to suit different application needs.
| Type | Data Structure | Advantages | Disadvantages |
| Occupancy Grid Map | 2-Dimensional grid matrix | Intuitive representation, easy for path planning and obstacle avoidance | Large memory consumption, resolution-limited accuracy |
| Feature Map | Sparse set of feature points | Low memory footprint, compact structure | Lacks semantic information, difficult for direct obstacle avoidance |
| Topological Map | Graph of nodes and edges | Supports high-level planning, semantically rich | Low geometric accuracy, high level of abstraction |
| Semantic Map | Geometry + semantic labels | Enables AI integration, provides a high-level understanding | Complex to build, high computational resource consumption |
In industrial environments, a “multi-layer map structure” is often used, maintaining simultaneously a grid layer (for physical obstacle detection), a topological layer (for area connectivity and high-level planning), and a semantic layer (for functional labeling and intelligent decision-making) to achieve multi-level decision-making. For example, an industrial robot can adopt different obstacle avoidance and speed strategies in the “assembly area” versus the “inspection area,” enabling intelligent scheduling.
Performance Evaluation Metrics of Simultaneous Localization And Mapping / SLAM algorithms
| Evaluation Metric | Meaning | Typical Quantification Method |
|---|---|---|
| Localization Accuracy | Robot position error | Average deviation from ground truth |
| Mapping Accuracy | Degree of match between the map and the actual environment | Point cloud overlap rate or error matrix |
| Real-Time Performance | Algorithm execution speed | Frame rate (FPS) or latency |
| Robustness | Adaptability to lighting changes, occlusion, and dynamic objects | Success rate or relocalization time |
| Resource Consumption (Computation Cost) | Computational power and energy usage ratio | CPU/GPU usage, battery runtime |
Applications of Simultaneous Localization And Mapping / SLAM Algorithms
SLAM algorithms demonstrate outstanding application value and broad prospects in many fields.
–Autonomous driving: SLAM algorithms are a key technology for achieving core autonomous driving functions. SLAM systems can construct high-precision 3-Dimensional maps of the vehicle’s surroundings in real time while accurately estimating the vehicle’s position within that map. This is crucial for path planning, obstacle detection and avoidance, lane keeping, and other functions.
–Drone flight control: SLAM algorithms enable drones to fly autonomously in unknown environments. By real-time mapping of terrain and environmental features, combined with flight attitude data, drones can achieve self-localization, obstacle avoidance, and path planning.

–Factory internal logistics:
AMRs use SLAM algorithms to construct real-time maps of factory environments, enabling autonomous navigation to transport raw materials, components, and finished products. They adapt to dynamic production environments, reduce manual intervention, and improve logistics efficiency. For example, in large warehouses, SLAM helps AMRs accurately locate shelves and goods for fast picking, restocking, and inventory counting.
Recommended In-depth Reading from AI Robots Eidos
SLAM algorithms are crucial for Autonomous Mobile Robots (AMRs). They form the foundation for AMRs to achieve autonomous navigation, path planning, and obstacle avoidance, allowing them to complete tasks without relying on preset routes or external infrastructure. Furthermore, SLAM algorithms can update maps in real-time, detect environmental changes, and adjust the AMR’s localization and path planning, ensuring that the AMR can operate safely and efficiently in dynamic environments, avoiding collisions and delays.
If readers are interested in Autonomous Mobile Robots (AMRs), please read this article about Autonomous Mobile Robots.
Collaborative robots (Cobots) use SLAM algorithms to estimate their own positions in real time and share localization information to achieve mutual localization. In dynamic environments, robots can adjust their paths based on the poses of other robots to avoid collisions and achieve efficient cooperative navigation. For example, in logistics delivery scenarios, multiple robots can collaboratively transport goods while ensuring non-conflicting paths.
Challenges and Optimization of Simultaneous Localization And Mapping / SLAM algorithms
–Accumulated localization error leading to deviation from true values:
SLAM estimates continuous motion and tolerates some error. However, error accumulates over time, leading to significant deviation from true values. Error can also cause map data to break down or become distorted, making subsequent searching difficult. Consider an example of traveling around a square path. As error accumulates, the robot’s starting and ending points no longer align. This is the loop closure problem. Such pose estimation errors are inevitable. We must find ways to detect loop closures and determine how to correct or offset accumulated errors.
One countermeasure is to remember features from previously visited places as landmarks to minimize localization error. Constructing a pose graph helps correct errors. The error minimization problem is solved as an optimization problem to generate more accurate map data. In visual SLAM, this optimization is called bundle adjustment.
–Localization failure – losing position on the map:
Image and point cloud mapping do not take into account the robot’s motion characteristics. In some cases, this approach can produce discontinuous position estimates. For example, a calculation might show that a robot moving at 1 m/s suddenly “teleports” 10 meters forward.
Two approaches to avoid such localization failure are: using recovery algorithms; fusing motion models with multiple sensors to compute based on sensor data. There are many ways to achieve sensor fusion with motion models. A common method is to use Kalman filtering for localization. Since most differential-drive robots and four-wheeled vehicles generally use nonlinear motion models, extended Kalman filters and particle filters (Monte Carlo localization) are commonly used.
In some cases, more flexible Bayesian filters, such as unscented Kalman filters, can also be used. Common sensors for this purpose include inertial measurement devices such as IMUs, AHRS, INS, accelerometers, gyroscopes, and magnetometers. Wheel encoders mounted on the vehicle are often used for odometry. When localization fails, one recovery strategy is to remember a keyframe from a previously visited location as a landmark. When searching for landmarks, feature extraction is performed in a specific way for high-speed scanning. Some methods are based on image features such as Bag of Features (BoF) and Bag of Visual Words (BoVW). In recent years, deep learning has also been used to compare feature distances
–High computational cost of image processing, point cloud processing, and optimization:
Computational cost is an issue when implementing SLAM on vehicle hardware. Computation is typically performed on compact, low-power embedded microprocessors with limited processing capability. To achieve accurate localization, image processing and point cloud matching must be executed at high frequency. Furthermore, optimization calculations such as loop closure are computationally expensive processes. The challenge is how to perform such high-cost processing on embedded microprocessors.
One countermeasure is to run multiple different processes in parallel. For example, feature extraction, which is a preprocessing step for matching, is relatively well-suited for parallel execution. When using multi-core CPUs, SIMD calculations and embedded GPUs can in some cases further increase speed. Moreover, since pose graph optimization can be performed on a relatively long cycle, lowering its priority and executing it at regular intervals can also improve performance.
Insight from AI Robots Eidos about Simultaneous Localization And Mapping / SLAM algorithms
—The future of SLAM algorithms will no longer focus solely on constructing static geometric-semantic maps but will involve generating dynamic and interactive spatiotemporal semantic maps. Each entity within these maps will not only be labeled but will also include its movement trajectory, speed patterns, and even intention predictions (for example, a pedestrian might cross the street).
—When sensor visibility is limited (such as due to glass reflections, sensor malfunctions, or temporary obstructions), traditional SLAM algorithms suffer from loss of tracking or produce distortions. There is potential to incorporate diffusion models or variational autoencoders that can “imagine” plausible map structures for occluded areas based on environmental context and existing map priors. This is not simply interpolation but rather the generation of semantically coherent layouts (for instance, the system could infer that a corridor temporarily obstructed by stacked goods is most likely straight). This generative mapping fill-in will greatly enhance SLAM’s robustness in industrial environments.
—Traditional visual SLAM algorithms are limited by frame rates (30/60 fps), which causes them to fail in high-dynamic or rapidly changing lighting scenarios. Event cameras (event-driven visual sensors) output asynchronous pixel brightness changes at microsecond resolution, paving the way for completely asynchronous neuromorphic SLAM algorithms in the future. The frontend will not rely on frames but will instead directly process event streams to perform continuous pose tracking; the backend will utilize Spiking Neural Networks (SNNs) for graph optimization. This type of SLAM could reduce latency to below milliseconds while maintaining extremely low power consumption.
Image Credits: Kodifly & Mathworks & Researchgate & Iopscience & Rvp-group & Mdpi
