Line fitting.

Slides:



Advertisements
Similar presentations
Hilal Tayara ADVANCED INTELLIGENT ROBOTICS 1 Depth Camera Based Indoor Mobile Robot Localization and Navigation.
Advertisements

Robot Vision SS 2005 Matthias Rüther 1 ROBOT VISION Lesson 3: Projective Geometry Matthias Rüther Slides courtesy of Marc Pollefeys Department of Computer.
(Includes references to Brian Clipp
Chapter 6 Feature-based alignment Advanced Computer Vision.
Multi-model Estimation with J-linkage Jeongkyun Lee.
SA-1 Probabilistic Robotics Probabilistic Sensor Models Beam-based Scan-based Landmarks.
Uncertainty Representation. Gaussian Distribution variance Standard deviation.
Segmentation into Planar Patches for Recovery of Unmodeled Objects Kok-Lim Low COMP Computer Vision 4/26/2000.
Sam Pfister, Stergios Roumeliotis, Joel Burdick
SA-1 Probabilistic Robotics Probabilistic Sensor Models Beam-based Scan-based Landmarks.
Multiple View Geometry
Recognising Panoramas
Fitting. We’ve learned how to detect edges, corners, blobs. Now what? We would like to form a higher-level, more compact representation of the features.
Geometric Optimization Problems in Computer Vision.
A Probabilistic Approach to Collaborative Multi-robot Localization Dieter Fox, Wolfram Burgard, Hannes Kruppa, Sebastin Thrun Presented by Rajkumar Parthasarathy.
Fitting a Model to Data Reading: 15.1,
reconstruction process, RANSAC, primitive shapes, alpha-shapes
Fitting. Choose a parametric object/some objects to represent a set of tokens Most interesting case is when criterion is not local –can’t tell whether.
Lecture 10: Robust fitting CS4670: Computer Vision Noah Snavely.
Random Sample Consensus: A Paradigm for Model Fitting with Application to Image Analysis and Automated Cartography Martin A. Fischler, Robert C. Bolles.
1Jana Kosecka, CS 223b EM and RANSAC EM and RANSAC.
Computing transformations Prof. Noah Snavely CS1114
Fitting.
CSE 473/573 RANSAC & Least Squares Devansh Arpit.
כמה מהתעשייה? מבנה הקורס השתנה Computer vision.
Robust fitting Prof. Noah Snavely CS1114
Kalman filter and SLAM problem
CSE 185 Introduction to Computer Vision
Chapter 6 Feature-based alignment Advanced Computer Vision.
Computer Vision - Fitting and Alignment
Parallel implementation of RAndom SAmple Consensus (RANSAC) Adarsh Kowdle.
Advanced Computer Vision Feature-based Alignment Lecturer: Lu Yi & Prof. Fuh CSIE NTU.
COMMON EVALUATION FINAL PROJECT Vira Oleksyuk ECE 8110: Introduction to machine Learning and Pattern Recognition.
Mapping and Localization with RFID Technology Matthai Philipose, Kenneth P Fishkin, Dieter Fox, Dirk Hahnel, Wolfram Burgard Presenter: Aniket Shah.
SA-1 Probabilistic Robotics Probabilistic Sensor Models Beam-based Scan-based Landmarks.
Example: line fitting. n=2 Model fitting Measure distances.
Ground Truth Free Evaluation of Segment Based Maps Rolf Lakaemper Temple University, Philadelphia,PA,USA.
1 Research Question  Can a vision-based mobile robot  with limited computation and memory,  and rapidly varying camera positions,  operate autonomously.
RANSAC Robust model estimation from data contaminated by outliers Ondřej Chum.
Course 8 Contours. Def: edge list ---- ordered set of edge point or fragments. Def: contour ---- an edge list or expression that is used to represent.
Fitting image transformations Prof. Noah Snavely CS1114
October 16, 2014Computer Vision Lecture 12: Image Segmentation II 1 Hough Transform The Hough transform is a very general technique for feature detection.
Sensors Uncertainties, Line extraction from laser scans Vision
CS 2750: Machine Learning Linear Regression Prof. Adriana Kovashka University of Pittsburgh February 10, 2016.
Robust Estimation Course web page: vision.cis.udel.edu/~cv April 23, 2003  Lecture 25.
Fitting.
Mobile Robot Localization and Mapping Using Range Sensor Data Dr. Joel Burdick, Dr. Stergios Roumeliotis, Samuel Pfister, Kristo Kriechbaum.
Computational Intelligence: Methods and Applications Lecture 26 Density estimation, Expectation Maximization. Włodzisław Duch Dept. of Informatics, UMK.
Robust Feature Extraction for 3D Point Clouds from Vehicle Based Laser Scanner Abdul Nurunnabi, David Belton, Geoff West Department of Spatial Sciences.
CSCI 631 – Foundations of Computer Vision March 15, 2016 Ashwini Imran Image Stitching.
SLAM Techniques -Venkata satya jayanth Vuddagiri 1.
Autonomous Mobile Robots Autonomous Systems Lab Zürich Probabilistic Map Based Localization "Position" Global Map PerceptionMotion Control Cognition Real.
EE 7730 Parametric Motion Estimation. Bahadir K. Gunturk2 Parametric (Global) Motion Affine Flow.
3D Perception and Environment Map Generation for Humanoid Robot Navigation A DISCUSSION OF: -BY ANGELA FILLEY.
25 Years of RANSAC 25 Years of RANSAC Ondřej Chum
University of Ioannina
Fitting: Voting and the Hough Transform
Robot & Vision Lab. Wanjoo Park (revised by Dong-eun Seo)
A Brief Introduction of RANSAC
Lecture 7: Image alignment
A special case of calibration
Probabilistic Robotics
Probabilistic Map Based Localization
CENG 789 – Digital Geometry Processing 11- Least-Squares Solutions
Introduction to Sensor Interpretation
Introduction to Sensor Interpretation
Calibration and homographies
CS5760: Computer Vision Lecture 9: RANSAC Noah Snavely
CS5760: Computer Vision Lecture 9: RANSAC Noah Snavely
Presentation transcript:

Line fitting

Jack Elton Bresenham b. 1937 IBM / Winthrop University Bresenham's Line Algorithm (1962)

Line Tracing Input: (x0,y0) & (x1,y1) Output: Approximation of Coordinates on that line

Line Tracing (x,y) (x+dx,y+dy)

Line Tracing - Pseudocode (x,y) drawLineP(x,y,x+dx,y+dy) // assume dx,dy>0 a=0, b=0 while a<=dx and b<=dy drawPixel(x+a,y+b) if a/dx <= b/dy a++ else b++ Works for positive dx and dy (x+dx,y+dy)

Split and merge Linear regression RANSAC Hough-Transform Line Extraction Split and merge Linear regression RANSAC Hough-Transform

Line Extraction: Motivation 4b - Perception - Features Line Extraction: Motivation Map of the ASL hallway built using line segments

Line Extraction: Motivation 4b - Perception - Features Line Extraction: Motivation Map of the ASL hallway built using orthogonal planes constructed from line segments

Line Extraction: Motivation 4b - Perception - Features Line Extraction: Motivation Why laser scanner: Dense and accurate range measurements High sampling rate, high angular resolution Good range distance and resolution. Why line segment: The simplest geometric primitive Compact, requires less storage Provides rich and accurate information Represents most office-like environment.

Line Extraction: The Problem 4b - Perception - Features Line Extraction: The Problem Scan point in polar form: (ρi, θi) Assumptions: Gaussian noise with (0, σ) for ρ Negligible angular uncertainty Line model in polar form: x cos α + y sin α = r -π < α <= π r >= 0 r α

Line Extraction: The Problem (2) 4b - Perception - Features Line Extraction: The Problem (2) Three main problems: How many lines ? Which points belong to which line ? This problem is called SEGMENTATION Given points that belong to a line, how to estimate the line parameters ? This problem is called LINE FITTING The Algorithms we will see: Split and merge Linear regression RANSAC Hough-Transform

Algorithm 1: Split-and-Merge (standard) 4b - Perception - Features Algorithm 1: Split-and-Merge (standard) The most popular algorithm which is originated from computer vision. A recursive procedure of fitting and splitting. A slightly different version, called Iterative-End-Point-Fit, simply connects the end points for line fitting.

Algorithm 1: Split-and-Merge (Iterative-End-Point-Fit) 4b - Perception - Features Algorithm 1: Split-and-Merge (Iterative-End-Point-Fit)

Algorithm 1: Split-and-Merge 4b - Perception - Features Algorithm 1: Split-and-Merge

Algorithm 2: Line-Regression 4d - Perception - Features Algorithm 2: Line-Regression

Algorithm 3: RANSAC Acronym of Random Sample Consensus. 4d - Perception - Features Algorithm 3: RANSAC Acronym of Random Sample Consensus. It is a generic and robust fitting algorithm of models in the presence of outliers (points which do not satisfy a model) RANSAC is not restricted to line extraction from laser data but it can be generally applied to any problem where the goal is to identify the inliers which satisfy a predefined mathematical model. Typical applications in robotics are: line extraction from 2D range data (sonar or laser); plane extraction from 3D range data, and structure from motion RANSAC is an iterative method and is non-deterministic in that the probability to find a line free of outliers increases as more iterations are used Drawback: A nondeterministic method, results are different between runs.

Algorithm 3: RANSAC

Algorithm 3: RANSAC Select sample of 2 points at random

Algorithm 3: RANSAC Select sample of 2 points at random Calculate model parameters that fit the data in the sample

RANSAC Select sample of 2 points at random Calculate model parameters that fit the data in the sample Calculate error function for each data point

Algorithm 3: RANSAC Select sample of 2 points at random Calculate model parameters that fit the data in the sample Calculate error function for each data point Select data that support current hypothesis

Algorithm 3: RANSAC Select sample of 2 points at random Calculate model parameters that fit the data in the sample Calculate error function for each data point Select data that support current hypothesis Repeat sampling

Algorithm 3: RANSAC Select sample of 2 points at random Calculate model parameters that fit the data in the sample Calculate error function for each data point Select data that support current hypothesis Repeat sampling

Algorithm 3: RANSAC ALL-INLIER SAMPLE

Algorithm 3: RANSAC How many iterations does RANSAC need? 4b - Perception - Uncertainty Algorithm 3: RANSAC How many iterations does RANSAC need? Because we cannot know in advance if the observed set contains the maximum number of inliers, the ideal would be to check all possible combinations of 2 points in a dataset of N points. The number of combinations is given by N(N-1)/2, which makes it computationally unfeasible if N is too large. For example, in a laser scan of 360 points we would need to check all 360*359/2= 64,620 possibilities! Do we really need to check all possibilities or can we stop RANSAC after iterations? The answer is that indeed we do not need to check all combinations but just a subset of them if we have a rough estimate of the percentage of inliers in our dataset This can be done in a probabilistic way

Algorithm 3: RANSAC How many iterations does RANSAC need? 4b - Perception - Uncertainty Algorithm 3: RANSAC How many iterations does RANSAC need? Let w be the fraction of inliers in the data. w = number of inliers / N where N is the total number of points. w represents also the probability of selecting an inlier Let p be the probability of finding a set of points free of outliers If we assume that the two points needed for estimating a line are selected independently, w2 is the probability that both points are inliers and 1-w2 is the probability that at least one of these two points is an outlier Now, let k be the number of RANSAC iterations executed so far, then (1-w2) k will be the probability that RANSAC never selects two points that are both inliers. This probability must be equal to (1-p). Accordingly, 1-p = (1-w2) k and therefore

Algorithm 3: RANSAC How many iterations does RANSAC need? 4b - Perception - Uncertainty Algorithm 3: RANSAC How many iterations does RANSAC need? The number of iterations k is This expression tells us that knowing the fraction of inliers w, after k RANSAC iterations we will have a probability p of finding a set of points free of outliers. For example, if we want a probability of success equal to p=99% and the we know that the percentage of inliers in the dataset is w=50%, then we get k=16 iterations, which is much less than the number of all possible combinations that we had to check in the previous example! Also observe that in practice we do not need a precise knowledge of the fraction of inliers but just a rough estimate. More advanced implementations of RANSAC estimate the fraction of inliers by changing it adaptively iteration after iteration.