Finding Lane Lines on the Road
The goals / steps of this project are the following:
- Make a pipeline that finds lane lines on the road
- Reflect on your work in a written report
My pipeline is described visually in the below image.
-
Convert "orignal image" to grayscale, apply gaussian blur and then canny transform to get the "canny image"
-
Apply the "mask" defined by array describing a polygon on the image
-
Identify lines using HoughLinesP.
-
Additional functions average_pos() and m_b_points() identify lines with negative and positive slopes. All lines with positive slope and negative slope are averaged to get the single left and right line respectively. hough_lines() and draw_lines() are modified to reflect this change.
Image describing pipeline:
One potential shortcoming of the current pipeline could be that it may mis-identify other features as lines on a sharp turn. This could be avoided by changing the mask shape based on certain conditions.
Couple of improvements come to mind for the current pipeline
-
Currently the left and right lines appear jittery. This could be smoothed by averaging over multiple frames. Care must be taken to not smear out detail in doing so.
-
Canny may mis-identify lane lines due to large intensity changes present in other locations in the image than the lane itself.