1. 190531 도정찬
Introduction to SLAM
원본 : 신동원, Introduction to SLAM, SLAM KR, https://www.youtube.com/watch?v=_i8PaekcguA
2. Introduction
2
- Example : Pepper robot
- 로봇이 공간을 자유롭게 돌아다닐 수 있게 하는 것이 목적
- 바퀴만 활용하여 움직일 수 있지만 주변 환경을 인식하지 못함
- 로봇이 공간을 자유롭게 돌아다닐 수 있게 하는 것이 목적
- 로봇이 자유롭게 돌아다닐 수 있도록 하기 위해 필요한 것
- Localization
- Mapping
3. Simultaneous Localization and Mapping
3
- Visual localization
- 로봇에 장착된 센서만을 활용 (외부 장치 x)
- GPS가 잘 작동하지 않는 환경
- Ex)
- Mapping
- 사전에 주변 맵이 만들어지지 않는 또는 만들어질 수 없는 환경
- 경로 계획에 대한 정보를 제공
- Ex)
Indoor environment
Private area
Downtown
Disaster area
Cesar Cadena, Past, Present, and Future of Simultaneous Localization And Mapping: Towards the
Robust-Perception Age, IEEE Transactions on Robotics 32 (6) pp 1309-1332, 2016
4. Earlier Inspirations
4
- Bayesian Filtering based SLAM
- prototype of traditional Bayesian filtering based SLAM
framework emerged in 1900s.
- ex) EKF SLAM, FastSLAM
- Visual Odometry
- The process of estimating the ego-motion of a robot
using only the input of a single or multiple cameras
attached to it
- ex) stereo VO, monocular VO
- Structure from motion
- Investigating the problem of recovering relative camera
poses and 3D structure from a set of camera images
- Off-line version of visual SLAM
5. 다양한 위치 추정 방법
5
- 가이드 레일, QR 코드, GPS 센서
- 실제로는 가이드 레일, QR코드를 놓을 수 없는 경우가 대부분임)
- GPS 전파가 잘 닫지 않는 곳이 있음 ( 지하, 실내 공간, 도심 지역 등)
- 신뢰할 수 있지만 범용적이지 못함
- 환경적인 제약이 존재
- 카메라의 동작 방식에 따른 분류
- 단안 카메라, 양안 카메라, 깊이 카메라
- 로봇의 휠 인코더, 카메라, 레이저, IMU 센서
- 환경에 대한 간접적인 물리량을 측정
- 환경에 대해 추가적인 설치 없이 위치 추정
- 환경적인 제약이 적음
- Visual SLAM
- 카메라 센서를 주로 이용한 위치 추정 및 지도 작성 방법
6. 단안 카메라
6
- 한 개의 카메라를 움직여 물체까지의 거리를 추정
- 깊이 추정 알고리즘을 이용해 각 픽셀의 시차(disparity)를 계산
- 장점
- 다른 방법들에 비해 간단
- 계산량이 적고 실시간에 적합
- 영상에서 피쳐를 추출하고 영상간의 피쳐 매칭을 통해 3차원 포인트를 계산
- 단점
- Disparity는 계산할 수 있지만 실제적인 depth는 알 수 없음(Baseline의 부재)
- 정확한 Scale 정보를 알 수 없음
7. 양안 카메라
7
- 거리가 고정된 두 개의 카메라를 이용하여 물체까지의 거리를 추정
- 인간의 깊이 인지 체계와 유사
- 장점
- 단안 카메라 경우 보다 정확한 위치 추정 능력
- Dense한 맵 생성 가능
- Baseline : 두 카메라 사이의 고정된 거리
- 베이스라인이 멀수록 먼 거리를 측정 가능
- 단점
- 스테레오 매칭 알고리즘의 계산이 복잡
- 조명 변화에 취약
8. 깊이 카메라
8
- 적외선 구조광 방식 또는 레이저 광선의 비행시간을 측정해 깊이 예측
- 장점
- 비교적 정확한 깊이 값 예측이 가능
- Dense한 맵 생성
- 현재 일반적으로 사용되는 깊이 카메라
- Kinect V1, Kinect V2
- Xtion Pro Live
- Intel RealSense
- Google Tango
- 단점
- 좁은 측정 범위
- 작은 시야각
- 반사, 투과성 재질의 물체 깊이 측정 불가
- 주로 실내 응용에서 사용됨
9. Lidar 센서
9
- 레이저 광선의 비행시간을 측정해 깊이를 예측
- 측정 가능 거리 및 공간 분해능이 높음
- 종류
- 2D 라이다/3D 라이다
- Spinning/Solide-state
- 주요 회사
- Velodyne
- Robosense
- Ouster
- SOSLab
11. 전통적인 Visual SLAM 프레임워크
11
Sensor
input
Visual
odometry
Loop
closing
Backend
optimization
Mapping
카메라로부터 이미지를 들어오면 이미지의 특징을 나타내는 특징점(feature point)을 정의한다. 특징점
추출 방법에 따라 아래와 같이 나뉜다.
- Harris corner : 픽셀의 기울기 값을 계산하여 코너를 검출
- SIFT : 회전변환과 크기변환에 대해 불변한 특징점을 추출
- SURF : SIFT의 계산 속도를 개선함.
- FAST : 고속화 특징 검출
영상 입력 특징 검출 알고리즘
12. 전통적인 Visual SLAM 프레임워크
이 외에도 정확도, 속도 면에 따라 BRISK, BRIEF, ORB 등 많은 알고리즘이 연구되며, 특징점이 추출하게
되면 이에 대한 기술자(descriptor)가 생성 된다. 이 정보로 두 영상이 입력되면 특징 점을 찾아 같은 점인지
판별하는 정합(matching)을 할 수 있게 된다.
정합 방법
- 마할라노비스 거리(mahalanobis distance) : 데이터 분포 고려한 거리
- 유클리디안 거리를 이용한 SSD(Sum of Squared Differences) : 거리
정합
13. 전통적인 Visual SLAM 프레임워크
정합과정 도중 특징점에서는 이상치(outlier)가 발견된다. 이상치를 제거해야 두 이미지간 자세를
추정하거나 지도를 작성 할 수 있다.
이상치 제거 알고리즘
- RANSAC(RANdom Sample Consensus)
- MSAC(M-estimator Sample And Consensus)
이상치 제거
이상치 데이터 왜곡된 결과 RANSAC 적용
14. Visual Odometry
14
- Frontend
- 인접한 이미지 사이의 카메라 움직임
- 카메라의 동작에 대한 정량적인 측정이 필요
- 회전 및 이동
- 카메라와 3차원 공간 점 사이의 기하학적 관계를 이해
- Drift error
- Visual odometry만을 이용하여 궤적을 추정하면 에러가 누적됨
- 해결책
- Backend optimization과 loop closure detection
15. Backend Optimization
15
- Sensor noise
- 정밀한 센서라도 노이즈는 있기 마련
- 저렴한 센서는 측정 오류가 큼
- 일부 센서는 자기장과 온도에 영향을 받음
- Backend 최적화
- 노이즈가 많은 데이터로부터 전체 시스템의 상태를 추정하는 방법(state estimation)
- Frontend에서 발생한 Drift 에러를 제거
- Frontend에서는 Backend에 최적화 할 데이터와 데이터의 초기 값을 제공
- Backend 최적화의 종류
- 필터 기반(Kalman filter, particle filter)
- 비선형 최적화 기반(bundle adjustment, pose graph optimization)
16. Loop Closure Detection
16
- 현재 위치가 이전에 방문한 곳인지를 판단
- QR 코드 활용
- 환경적인 제약이 존재
- 카메라 영상을 활용
- 이미지 간의 유사성을 판단
- Backend에서는 루프 폐쇄에 대한 정보를 받아서 위치 추정과 지도 작성에 반영
- Drift 에러를 제거하고 전역적으로 일관된 맵을 생성
T. Sattler, “Benchmarking 6DOF Outdoor Visual Localization in Changing Conditions,” 2017.
17. Mapping
17
- 환경 맵을 만드는 과정
- 응용 프로그램에 따라 다르게 구현
- 무인 청소 로봇
- 2차원 지도로 충분
- 자율주행 드론
- 6DOF이므로 3차원 지도가 필요
- Map representation
- Pointcloud
- Voxel
- Surfel
- Occupancy grid map
- 맵 표현 밀도에 따른 종류
- Sparse, dense, semi-dense map
18. Modern State of the Art Systems
18
- Sparse SLAM
- Only use a small selected subset of the pixels (features) from a monocular color camera
- Fast and real time on CPU but it produces a sparse map (point clouds)
- Landmark-based or feature-based representations
- ORB SLAM
- One of the SOTA frameworks in the sparse SLAM category
- Complete SLAM system for monocular camera
- Real-time on standard CPUs in a wide variety of environments
- small hand-held indoors
- drones flying in industrial environments
- cars driving around a city
19. Modern State of the Art Systems
19
- Dense SLAM
- Use most or all of the pixels in each received frame
- Or use depth images from a depth camera
- It produces a dense map but GPU acceleration is necessary from the real-time operation
- Volumetric model or surfel(Surface Element)-based representations
- InfiniTam
- One of the SOTA frameworks in the Dense SLAM category
- Multi-platform framework for real-time, large-scale depth fusion and tracking
- Densely reconstructed 3D scene
20. Modern State of the Art Systems
20
- Direct method (semi-dense SLAM)
- Make use of pixel intensities directly
- Enable using all information in the image
- It produces a semi-dense map
- Higher accuracy and robustness in particular even in environments with little keypoints
- LSD SLAM
- Highly cited SLAM framework in the direct method SLAM category
- Large-scale, consistent maps of the environment
- Accurate pose estimation based on direct image alignment
21. Modern State of the Art Systems
21
- Lidar SLAM
- Make use of the Lidar sensor input for the localization and mapping
- Autonomous driving purpose-oriented in outdoor environment
- LOAM
- One of the SOTA frameworks in the Lidar SLAM category
- Very low drift error using the edge and planar features
- Low computation complexity
22. SLAM 문제의 수학적 표현
22
- Motion model
- 로봇의 위치가 어떻게 변하는지를 표현
- Sensor model
- 랜드마크가 로봇에서 어떻게 관찰되는지를 표현
23. Motion Model
23
- 로봇이 x_k-1 위치에서 컨트롤 입력 u_k를 받았을 때 새로운 로봇의 위치 x_k
- Motion model의 수학적 정의
- x_k = f(x_k-1, u_k, w_k)
- f( ) : motion model을 나타내는 함수
- u_k : 모션 센서 입력 또는 컨트롤 입력
- w_k : motion model에 대한 노이즈
- Example
- 평면에서 움직이는 청소 로봇의 경우
24. Sensor Model
24
- 로봇이 x_k 위치에서 어떤 랜드마크 y_k를 볼 때 관측데이터 z_k,j가 생성되는 것을 표현
- Sensor Model의 수학적 정의
- z_k,j = h(y_j, x_k, v_k,j)
- h( ) : sensor model을 나타내는 함수
- z_k,j : 관찰값
- v_k,j : sensor model에 대한 노이즈
- Example
- 평면에서 움직이는 청소 로봇의 경우
25. SLAM의 상태 추정 문제
25
- 모션 모델과 센서 모델
- x_k = f(x_k-1, u_k, w_k)
- z_k,j = h(y_j, x_k, v_k,j)
- 선형인가 비선형인가?
- 초기 SLAM 문제는 Extended Kalman filter를 이용
- EKF SLAM의 단점
- 선형화 과정에서의 오차
- 파티클 필터, 비선형 최적화 방법을 사용하기 시작
- Graph 기반의 SLAM 방법이 주류를 이룸
- Large scale에 적합
H. Strasdat, “Visual SLAM: Why Filter?,” 2012.