SlideShare a Scribd company logo
Line Detection in Images–
Recent Developments and Applications
NANDEDKAR PARTH SHIRISH
1
Department of
Intelligent Media,
Yagi Laboratory
今日の流れーTopics
1.Goal of Line Detection, difference with Edge Detection
2.Successive Approximation Method
3.Hough Transform Method
4.RANSAC(Random Sample Consensus) Method
5.Vanishing Point Detection using Hough Transform
6.Applications-Rectangle Detection
2
Department of
Intelligent Media,
Yagi Laboratory
1. Goal of Line Detection
Line detection is an algorithm that takes a collection of
n edge points and finds all the lines on which these edge
points lie.
Most popular line detectors are Hough
transform and convolution-based techniques.
Convolution-based Line Detection:
Same process as Edge Detection.
3
1. Difference with Edge Detection
An edge is a transition from one phase/object/thing to
another. On one side you have one color, on the other side
you have another color.
A line is a 1D structure. It has the same phase/object/thing
on either side. On one side you have background, on the
other side you have background also.
→Better techniques can better differentiate between these.
4
2.Successive Approximation Method
• Transforming from a curve-contour to a simpler
representation (to Piecewise-linear polyline or B-spline cur
• Algorithm: Mark the first and last point. Find the farthest
inlier from this line and join First and this point. Now remov
the farthest inlier to this line.
• If contour is a line we can simplify it to that line.
5
3.Hough Transform Basics
A line-to-point transform, that transforms the data from
x,y space to m,h space, where each line is transformed
to a point.
Problem: neither m or h are bounded
Line k to x axis ⇒ h not defined
Line k to y axis ⇒ m → ∞ 6
3.Polar Hough Transform
Now both variables are bounded!
→ Polar Hough Transform:
Value for an arbitrary line (r – xcosθ – ysinθ = 0) in (r, θ)
Where f(x,y) is the 2D image
→ Unit Sphere & Cubemap Mappings possible(pg. 253)
7
3.Polar Hough Transform – Theoretical Example
Output in the case of perfectly continuous lines.
8
3.Hough Transform for Line Detection
→ Goal: To identify straight lines
• Process: For each pixel at (x,y) the Polar Hough transform
algorithm determines if there is enough evidence of a
straight line at that pixel, using votes from sample points.
→ Strengths:
• Gives equations of lines(but not “end-points” of segments).
• Works well with simple images that contain good straight
lines. (Good for Robot Vision)
• Deals with broken lines very well (in next slide).
• Reasonably efficient if there are “few” edge points.
9
3.Polar Hough Transform – Broken Line/
Sampling Example
10
3.Polar Hough Transform – Discrete case
Same as before, but discrete. Number in Accumulator cell
proportional to number of points on the line.
11
3.Polar Hough Transform – Voting Algorithm
12
3.Hough Transform for Line Detection
→ Problems:
• Very slow of there are many edge points.
• Hough Space is non-linear, different edge sensitivities in
different directions.
• Poor for short lines.
→ Recent Extensions of Hough Method:
• Circle and Ellipse detection by Double Hough Method.
• Image transform plus Hough for general 2D shape
detection.
• Vanishing Points Detection(section 4.3.3, part 5 of slides)13
4.RANSAC (Random Sample Consensus)
Method – (For Feature Detection)
• Determines the best transformation that includes the
most number of match features (inliers) from the previous
step.
• RANSAC loop for planar pattern detection:
1. Select four feature pairs (at random) in the two angles.
2. Compute homography H (see next slide).
3. Compute inliers where SSD(pi’, Hpi) < a certain value,ε.
4. Keep largest set of inliers.
5. Re-compute least-squares estimate on all of the inliers.
14
4.RANSAC Method – What are Homographies?
• Example of Homography
• Definition: Projective–mapping between any two
projection planes with the same center of
projection
15
4.RANSAC Method – What are Homographies?
• Definition: Projective–mapping between any two
projection planes with the same center of
projection
16
4.RANSAC Method – (For Line Detection)
→ Simple example: Let us fit a line
• Use biggest set of inliers
• Do least-square fit => SD is low, Very likely it is a line
17
4.RANSAC Method – Video: Fitting a Line
→ Strengths:
• Robust estimation
• Relatively high
accuracy
→ Weaknesses:
• Randomness.
• Number of
Iterations required
for p% success
18
→ Goal: To collect lost 3D information from perspective in a
2D image detecting Vanishing points of Parallel lines.
19
5.Vanishing Points Detection – using Hough Transform
5.Vanishing Points Detection – using Hough Transform
→ Textbook method using Cross Product:
Step 1) Calculate Vanishing Point Hypothesis (weight)
= Cross product of any two line vectors =
 Near-Collinear segments downweighted
Step 2) Populate Hough space(accumulator) with weights
and find peaks for Vanishing point votes from the lines.
Step 3) Calculate Least Squares Estimate for all Vanishing
points with respect to lines that voted for it.
20
where = Green Triangle area
Rule: The lower the sum of all areas subtended to segment
endpoints, the more appropriate the vanishing point.
21
5.Vanishing Points Detection – using Hough Transform
6.Applications
Rectangle Detection:
Step 1) First, detect all vanishing points
Step 2) Detect the Edge points/Lines that are aligned along
vanishing lines.
We then efficiently recover the inter-sections of pairs of
lines corresponding to different vanishing points. (論文[8])22
6.Applications
Rectangle Detection:
Using only Hough
Detection is an 8D
vector-space problem
(論文[8]).
Major Quadrilaterals in
image can be detected
using only Vanishing
Point and Line Detection
(論文[8]).
23
References
[1] Polar Hough:
https://www.wikiwand.com/en/Hough_transform
[2] Hough Accumulator:
https://chmodux.wordpress.com/2012/04/16/target-
acquisition/
[3] Ransac:
https://www.slideshare.net/allynjoycalcaben/computer-
vision-feature-matching-with-ransac-algorithm
[4] Homographies:
https://docs.opencv.org/master/d9/dab/tutorial_homog
raphy.html
24
References
[5] Ransac animation:
https://kapernikov.com/cable-detection-in-lidar-data/
[6] Various:
Computer Vision: Algorithms and Applications by Richard
Szeliski
[7] Vanishing Points Examples:
http://teresabernardart.com/the-rules-of-
perspective/#:~:text=There%20are%20three%20basic%20
types,illusion%20of%20depth%20and%20space.
[8] Rectangle Detection Algorithm:
https://www.researchgate.net/publication/228697341_Pe
rspective_rectangle_detection 25

More Related Content

PPTX
Line Detection in Computer Vision
PPTX
Orb feature by nitin
PDF
Practical Digital Image Processing 4
PDF
Line Detection on the GPU
PDF
An Easier Approach to Visible Edge Determination from Moving Viewpoint, Paper...
PPTX
Linear Hough TRansform
PDF
Practical Digital Image Processing 3
PDF
Practical Digital Image Processing 5
Line Detection in Computer Vision
Orb feature by nitin
Practical Digital Image Processing 4
Line Detection on the GPU
An Easier Approach to Visible Edge Determination from Moving Viewpoint, Paper...
Linear Hough TRansform
Practical Digital Image Processing 3
Practical Digital Image Processing 5

What's hot (19)

PDF
A Hough Transform Implementation for Line Detection for a Mobile Robot Self-N...
PPTX
Hough Transform By Md.Nazmul Islam
PPTX
Edge Detection using Hough Transform
PPTX
Invariant Generalised Hough Transform
PPTX
Back face detection
PDF
Robotics for Path Planning
PDF
Real time Canny edge detection
PPTX
Computer Graphics (Hidden surfaces and line removal, Curves and surfaces, Sur...
ODP
Exact Cell Decomposition of Arrangements used for Path Planning in Robotics
PDF
Path Planning for Mobile Robot Navigation Using Voronoi Diagram and Fast Marc...
PDF
DESIGN AND IMPLEMENTATION OF PATH PLANNING ALGORITHM
PDF
VEHICLE RECOGNITION USING VIBE AND SVM
PPTX
Canny Edge Detection
PPT
Path Planning And Navigation
PPTX
Morphological antialiasing
PDF
An automatic algorithm for object recognition and detection based on asift ke...
PPTX
OpenCV presentation series- part 5
PDF
Identification of Scatter Sources and Significant Reduction of Scatter Occurr...
PPSX
Rapidly-Exploring Random Tree
A Hough Transform Implementation for Line Detection for a Mobile Robot Self-N...
Hough Transform By Md.Nazmul Islam
Edge Detection using Hough Transform
Invariant Generalised Hough Transform
Back face detection
Robotics for Path Planning
Real time Canny edge detection
Computer Graphics (Hidden surfaces and line removal, Curves and surfaces, Sur...
Exact Cell Decomposition of Arrangements used for Path Planning in Robotics
Path Planning for Mobile Robot Navigation Using Voronoi Diagram and Fast Marc...
DESIGN AND IMPLEMENTATION OF PATH PLANNING ALGORITHM
VEHICLE RECOGNITION USING VIBE AND SVM
Canny Edge Detection
Path Planning And Navigation
Morphological antialiasing
An automatic algorithm for object recognition and detection based on asift ke...
OpenCV presentation series- part 5
Identification of Scatter Sources and Significant Reduction of Scatter Occurr...
Rapidly-Exploring Random Tree
Ad

Similar to Line Detection in Computer Vision - Recent Developments and Applications (20)

PPTX
Lane detection by use of canny edge
PPT
color doppler
PPTX
06 image features
PDF
Passive stereo vision with deep learning
PPT
Chapter10 image segmentation
PPT
PSanthanam.ppt
PDF
Outlier detection method introduction
PDF
Machine learning for high-speed corner detection
PPTX
Computer Vision - RANSAC
PPT
cv1.ppt
PDF
PDF
A Method to Determine End-Points ofStraight Lines Detected Using the Hough Tr...
PDF
Object tracking with SURF: ARM-Based platform Implementation
PPT
cohenmedioni.ppt
PPTX
Line Detection using Hough transform .pptx
PPTX
Dijkstra’s Algorithm in modern navigation and autonomous vehicles
PDF
Methods for comparing scanpaths and saliency maps: strengths and weaknesses
PDF
Camera-Based Road Lane Detection by Deep Learning II
PDF
Fisheye Omnidirectional View in Autonomous Driving
PDF
Computer Vision: Feature matching with RANSAC Algorithm
Lane detection by use of canny edge
color doppler
06 image features
Passive stereo vision with deep learning
Chapter10 image segmentation
PSanthanam.ppt
Outlier detection method introduction
Machine learning for high-speed corner detection
Computer Vision - RANSAC
cv1.ppt
A Method to Determine End-Points ofStraight Lines Detected Using the Hough Tr...
Object tracking with SURF: ARM-Based platform Implementation
cohenmedioni.ppt
Line Detection using Hough transform .pptx
Dijkstra’s Algorithm in modern navigation and autonomous vehicles
Methods for comparing scanpaths and saliency maps: strengths and weaknesses
Camera-Based Road Lane Detection by Deep Learning II
Fisheye Omnidirectional View in Autonomous Driving
Computer Vision: Feature matching with RANSAC Algorithm
Ad

More from Parth Nandedkar (11)

PDF
Large scale cell tracking using an approximated Sinkhorn algorithm
PPTX
Large scale cell tracking using an approximated Sinkhorn algorithm
PDF
Discount tracker - Fujitsu Hackathon
PPTX
Motion and Position Map in Cell Tracking for Bioimaging
PDF
Speech at english_seminar
PDF
Permutations and Combinations IIT JEE+Olympiad Lecture 1
PDF
Permutations and Combinations IIT JEE+Olympiad Lecture 4
PDF
Permutations and Combinations IIT JEE+Olympiad Lecture 3
PDF
LSTM and GRU RNNs in Sentiment Analysis (Japanese)
PDF
Deep Learning Demonstration using Tensorflow (7th lecture)
PDF
Basics of Deep Learning (2nd lecture)
Large scale cell tracking using an approximated Sinkhorn algorithm
Large scale cell tracking using an approximated Sinkhorn algorithm
Discount tracker - Fujitsu Hackathon
Motion and Position Map in Cell Tracking for Bioimaging
Speech at english_seminar
Permutations and Combinations IIT JEE+Olympiad Lecture 1
Permutations and Combinations IIT JEE+Olympiad Lecture 4
Permutations and Combinations IIT JEE+Olympiad Lecture 3
LSTM and GRU RNNs in Sentiment Analysis (Japanese)
Deep Learning Demonstration using Tensorflow (7th lecture)
Basics of Deep Learning (2nd lecture)

Recently uploaded (20)

PPTX
Understanding_Digital_Forensics_Presentation.pptx
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PDF
Review of recent advances in non-invasive hemoglobin estimation
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PDF
Encapsulation theory and applications.pdf
PDF
Empathic Computing: Creating Shared Understanding
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PDF
Network Security Unit 5.pdf for BCA BBA.
PDF
cuic standard and advanced reporting.pdf
PDF
KodekX | Application Modernization Development
PPTX
sap open course for s4hana steps from ECC to s4
PPTX
Cloud computing and distributed systems.
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
Unlocking AI with Model Context Protocol (MCP)
DOCX
The AUB Centre for AI in Media Proposal.docx
Understanding_Digital_Forensics_Presentation.pptx
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
Review of recent advances in non-invasive hemoglobin estimation
The Rise and Fall of 3GPP – Time for a Sabbatical?
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
20250228 LYD VKU AI Blended-Learning.pptx
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Encapsulation theory and applications.pdf
Empathic Computing: Creating Shared Understanding
NewMind AI Weekly Chronicles - August'25 Week I
Network Security Unit 5.pdf for BCA BBA.
cuic standard and advanced reporting.pdf
KodekX | Application Modernization Development
sap open course for s4hana steps from ECC to s4
Cloud computing and distributed systems.
Per capita expenditure prediction using model stacking based on satellite ima...
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Unlocking AI with Model Context Protocol (MCP)
The AUB Centre for AI in Media Proposal.docx

Line Detection in Computer Vision - Recent Developments and Applications

  • 1. Line Detection in Images– Recent Developments and Applications NANDEDKAR PARTH SHIRISH 1 Department of Intelligent Media, Yagi Laboratory
  • 2. 今日の流れーTopics 1.Goal of Line Detection, difference with Edge Detection 2.Successive Approximation Method 3.Hough Transform Method 4.RANSAC(Random Sample Consensus) Method 5.Vanishing Point Detection using Hough Transform 6.Applications-Rectangle Detection 2 Department of Intelligent Media, Yagi Laboratory
  • 3. 1. Goal of Line Detection Line detection is an algorithm that takes a collection of n edge points and finds all the lines on which these edge points lie. Most popular line detectors are Hough transform and convolution-based techniques. Convolution-based Line Detection: Same process as Edge Detection. 3
  • 4. 1. Difference with Edge Detection An edge is a transition from one phase/object/thing to another. On one side you have one color, on the other side you have another color. A line is a 1D structure. It has the same phase/object/thing on either side. On one side you have background, on the other side you have background also. →Better techniques can better differentiate between these. 4
  • 5. 2.Successive Approximation Method • Transforming from a curve-contour to a simpler representation (to Piecewise-linear polyline or B-spline cur • Algorithm: Mark the first and last point. Find the farthest inlier from this line and join First and this point. Now remov the farthest inlier to this line. • If contour is a line we can simplify it to that line. 5
  • 6. 3.Hough Transform Basics A line-to-point transform, that transforms the data from x,y space to m,h space, where each line is transformed to a point. Problem: neither m or h are bounded Line k to x axis ⇒ h not defined Line k to y axis ⇒ m → ∞ 6
  • 7. 3.Polar Hough Transform Now both variables are bounded! → Polar Hough Transform: Value for an arbitrary line (r – xcosθ – ysinθ = 0) in (r, θ) Where f(x,y) is the 2D image → Unit Sphere & Cubemap Mappings possible(pg. 253) 7
  • 8. 3.Polar Hough Transform – Theoretical Example Output in the case of perfectly continuous lines. 8
  • 9. 3.Hough Transform for Line Detection → Goal: To identify straight lines • Process: For each pixel at (x,y) the Polar Hough transform algorithm determines if there is enough evidence of a straight line at that pixel, using votes from sample points. → Strengths: • Gives equations of lines(but not “end-points” of segments). • Works well with simple images that contain good straight lines. (Good for Robot Vision) • Deals with broken lines very well (in next slide). • Reasonably efficient if there are “few” edge points. 9
  • 10. 3.Polar Hough Transform – Broken Line/ Sampling Example 10
  • 11. 3.Polar Hough Transform – Discrete case Same as before, but discrete. Number in Accumulator cell proportional to number of points on the line. 11
  • 12. 3.Polar Hough Transform – Voting Algorithm 12
  • 13. 3.Hough Transform for Line Detection → Problems: • Very slow of there are many edge points. • Hough Space is non-linear, different edge sensitivities in different directions. • Poor for short lines. → Recent Extensions of Hough Method: • Circle and Ellipse detection by Double Hough Method. • Image transform plus Hough for general 2D shape detection. • Vanishing Points Detection(section 4.3.3, part 5 of slides)13
  • 14. 4.RANSAC (Random Sample Consensus) Method – (For Feature Detection) • Determines the best transformation that includes the most number of match features (inliers) from the previous step. • RANSAC loop for planar pattern detection: 1. Select four feature pairs (at random) in the two angles. 2. Compute homography H (see next slide). 3. Compute inliers where SSD(pi’, Hpi) < a certain value,ε. 4. Keep largest set of inliers. 5. Re-compute least-squares estimate on all of the inliers. 14
  • 15. 4.RANSAC Method – What are Homographies? • Example of Homography • Definition: Projective–mapping between any two projection planes with the same center of projection 15
  • 16. 4.RANSAC Method – What are Homographies? • Definition: Projective–mapping between any two projection planes with the same center of projection 16
  • 17. 4.RANSAC Method – (For Line Detection) → Simple example: Let us fit a line • Use biggest set of inliers • Do least-square fit => SD is low, Very likely it is a line 17
  • 18. 4.RANSAC Method – Video: Fitting a Line → Strengths: • Robust estimation • Relatively high accuracy → Weaknesses: • Randomness. • Number of Iterations required for p% success 18
  • 19. → Goal: To collect lost 3D information from perspective in a 2D image detecting Vanishing points of Parallel lines. 19 5.Vanishing Points Detection – using Hough Transform
  • 20. 5.Vanishing Points Detection – using Hough Transform → Textbook method using Cross Product: Step 1) Calculate Vanishing Point Hypothesis (weight) = Cross product of any two line vectors =  Near-Collinear segments downweighted Step 2) Populate Hough space(accumulator) with weights and find peaks for Vanishing point votes from the lines. Step 3) Calculate Least Squares Estimate for all Vanishing points with respect to lines that voted for it. 20
  • 21. where = Green Triangle area Rule: The lower the sum of all areas subtended to segment endpoints, the more appropriate the vanishing point. 21 5.Vanishing Points Detection – using Hough Transform
  • 22. 6.Applications Rectangle Detection: Step 1) First, detect all vanishing points Step 2) Detect the Edge points/Lines that are aligned along vanishing lines. We then efficiently recover the inter-sections of pairs of lines corresponding to different vanishing points. (論文[8])22
  • 23. 6.Applications Rectangle Detection: Using only Hough Detection is an 8D vector-space problem (論文[8]). Major Quadrilaterals in image can be detected using only Vanishing Point and Line Detection (論文[8]). 23
  • 24. References [1] Polar Hough: https://www.wikiwand.com/en/Hough_transform [2] Hough Accumulator: https://chmodux.wordpress.com/2012/04/16/target- acquisition/ [3] Ransac: https://www.slideshare.net/allynjoycalcaben/computer- vision-feature-matching-with-ransac-algorithm [4] Homographies: https://docs.opencv.org/master/d9/dab/tutorial_homog raphy.html 24
  • 25. References [5] Ransac animation: https://kapernikov.com/cable-detection-in-lidar-data/ [6] Various: Computer Vision: Algorithms and Applications by Richard Szeliski [7] Vanishing Points Examples: http://teresabernardart.com/the-rules-of- perspective/#:~:text=There%20are%20three%20basic%20 types,illusion%20of%20depth%20and%20space. [8] Rectangle Detection Algorithm: https://www.researchgate.net/publication/228697341_Pe rspective_rectangle_detection 25