Finding Lane Lines Project
Goals
Identify and highlight lane lines in images and short video.
Implementation Overview
Usage of Opencv's Canny edge detection and Hough line transform functiontionality to detect and highlight lane lines.
Reference Screenshots
![Screen Shot 2018-04-21 at 3.42.12](writeup.assets/Screen Shot 2018-04-21 at 3.42.12.png)![Screen Shot 2018-04-21 at 3.42.42](writeup.assets/Screen Shot 2018-04-21 at 3.42.42.png)
Pipeline Overview
- load an image (or video frame)
- convert to grayscale (to avoid pitfall of non-white color lane-lines)
- perform canny edge detection
- remove everything outside region of interest
- perform the Hough transform to detect lines
- average out and extrapolate the lines (lane lines are detected as double, parallel, segments (edges) - combine them into single lines, stretch to the horizon the image)
- overlay the average lines image untop the original image/frame
NOTE: see jupyter notebook for in-depth process walkthrough.
Shortcomings
Where to begin? the implementation is naive.
Intensity Shortcomings
converting to grayscale makes the model likely to fail when intensity is changed:
- lightening and reflections - sunlight or even nightlamps reflecting off of the asphalt
- car headlights - may make the lane lines not be detected as lines.
- material variations - e.g some roads are concrete, which is light gray.
- Etc
Chroma Shortcomings
- the model is effectively color blind, meaning artifacts which are easily discrenible via chroma but having a similar intensity may cause the model to fail.
Geometrical Shortcomings
- camera orientation - even small differences in position may render the model useless.
- camera type
- vehicle size - e.g a truck will position the camera higher
- curving roads - the model may fail due to there not being any straight lines
- etc
Obstructions
various objects partially or wholly obstructing lane lines
-
acute - e.g a dog runnig across the road
-
chronic - e.g mud on the windshield
-
etc
Possible Improvements
Handling Curves
Trying to match curving lines instead of just straight lines.
Chroma Utilization
Lane line indetification via chroma variation instead of just intensity.
Acute Obstruction Avoidance
Using previously calculated values to avoid momentary failures due to various objects.