출처 : https://www.youtube.com/watch?v=v3322cNhCTk&list=PLxg0CGqViygP47ERvqHw_v7FVnUovJeaz&index=9
RANSAC : Line Fitting Example
- n개의 점에 가장 잘 피팅되는 선을 찾을 때 쓰는 방법임
- least-squares method 의 경우 outlier가 많을 때 robust하지 않음
- RANSAC은 outlier가 많은 데이터에서 쓸수있는 robust 한 모델임
RANSAC Steps
- Randomly select minimal subset of points
- 예를 들어, y=mx + c를 구하기 위해 2개의 점을 임의로 잡는다.
- hypothesize a model
- 예를 들어, (x1, y1), (x2, y2)를 이용해 m,c를 특정한다.
- compute error function
- 예를 들어, 가장 shortest distance
- select s number of points consistent with (threshold = t) model
- Repeat hypothesize-and-verify loop (N-trials)
- Select the hypothesis with the highest number of consistent points (i.e. inliers)
Choosing the parameters
- s개의 points
- 주로 어떤 모델을 특정하기까지 필요한 최소의 점으로 잡는다.
- line일때는 2개, homography matrix일 때는 4개가 필요하다.
- t threshold
- 실험적인 값으로 정한다.
- measurement error가 알려져있으면 다음과 같이 잡는다.
- N개의 sample 개수
- p = 샘플 중 적어도 하나의 점이 outlier가 아닐 확률
- w = 어떤 점을 잡아도 그게 inlier일 확률 (일반적으로 판단하기 힘들다)
'Computer Vision > Multiple View Geometry' 카테고리의 다른 글
[Multiple View Geometry] Single View Metrology (0) | 2023.07.30 |
---|---|
[Multiple View Geometry] Iterative minimization (반복최소화 방법) (0) | 2023.03.12 |
[Multiple View Geometry] 이미지에서 아핀변환과 거리 속성의 복원 (0) | 2022.10.02 |
Epipolar Geometry (0) | 2022.08.28 |
[Multiple View Geometry] Conics, Quadrics (0) | 2022.08.28 |
댓글