Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/cizodevahm/line-detection-on-road-with-opencv
This repository contains a Python script that demonstrates line detection in a video using OpenCV. The script processes a video file to detect and highlight lines, which can be useful for applications such as lane detection in autonomous driving.
https://github.com/cizodevahm/line-detection-on-road-with-opencv
computer-vision cv2 linedetection opencv
Last synced: 17 days ago
JSON representation
This repository contains a Python script that demonstrates line detection in a video using OpenCV. The script processes a video file to detect and highlight lines, which can be useful for applications such as lane detection in autonomous driving.
- Host: GitHub
- URL: https://github.com/cizodevahm/line-detection-on-road-with-opencv
- Owner: cizodevahm
- License: mit
- Created: 2024-08-28T09:59:46.000Z (3 months ago)
- Default Branch: main
- Last Pushed: 2024-08-28T10:14:01.000Z (3 months ago)
- Last Synced: 2024-10-10T17:42:18.852Z (about 1 month ago)
- Topics: computer-vision, cv2, linedetection, opencv
- Language: Python
- Homepage:
- Size: 23.2 MB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Line Detection on Road with OpenCV
This repository contains a Python script that demonstrates line detection in a video using OpenCV. The script processes a video file to detect and highlight lines, which can be useful for applications such as lane detection in autonomous driving.# Overview
The script reads a video file, applies Gaussian blur and color filtering to isolate specific features, and then uses the Canny edge detector and Hough Line Transform to detect and draw lines on the video frames.# Features
### Video Processing:
Reads and processes video frames in real-time.
### Gaussian Blur:
Reduces noise and smoothens the image.
### Color Filtering:
Isolates specific color ranges in the HSV color space.
### Edge Detection:
Uses the Canny edge detector to find edges in the image.
### Line Detection:
Applies the Hough Line Transform to detect and draw lines.# Installation
1. Clone the repository:
```bash
git clone https://github.comcizodevahm/line-detection-on-road-with-OpenCV.git
```
2. Navigate to the project directory:
```bash
cd line-detection-on-road-with-OpenCV
```
3. Install the required dependencies:
```bash
pip install opencv-python numpy
```
# Usage
1. Place your video file in the project directory and update the script with the video file name.
2. Run the script:
```bash
python Line.py
```
3. The script will display the processed video with detected lines.# Example
![Sample gif](out.gif)