Lane detection and turn prediction.
The following packages must be installed to run this code:
- cv2
- sys (std lib)
- numpy (std lib)
- os (std lib)
- sklearn
To run histogram equalization script, run
python histogram_equalization.py
The lane_detection.py script handles multiple functions. Firstly, it runs the computer vision and detection algorithms for the two sample videos. Second, the script has functionality for enabling the user to choose custom corners for each video. These corners will be used in the homography steps. Lastly, the script also has a function for generating the data1 video from the given images. See how to run these scripts below.
Please follow the terminal instructions once a program is run.
To run the lane detection script, run
lane_detection.py
with the following command line arguments:
- Run lane detection on the non-challenge video:
python lane_detection.py
- Run lane detection on challenge video:
python lane_detection.py challenge
- Execute manual corner finder on non-challenge video:
python lane_detection.py def_lane_corners
- Execute manual corner finder on challenge video:
python lane_detection.py challenge def_lane_corners
- Generate non-challenge video from its images:
python lane_detection.py gen_video
Google drive link: https://drive.google.com/file/d/1PzHiNrufgPPxtGy0a7LFq5cR81-JrZWi/view?usp=sharing