Skip to content

This is a personal and well-commented set of scripts to learn OpenCV with a hands-on approach.

Notifications You must be signed in to change notification settings

nhpf/opencv-classes

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OpenCV Classes

I am teaching a portuguese student to use OpenCV in a small project.

This is a personal and well-commented set of scripts that might be useful for people with some computer vision knowledge getting into OpenCV.

The motivating project is an augmentation program that, upon detection of movie posters on a webcam, displays the movie title and a set of cubes representing its score (1 to 5).

Mind that if your webcam has low resolution, the image matching will work better for images with lower resolution. In other words, if the level of detail your camera can capture is low, the generation of keypoints for each image should consider the same level of detail.

You will just need Python 3.6+ and pip3 install opencv-contrib-python to run every script.

Fore more usage information, clone this repository and run python app.py -h

File Content Status
calibration/simple-calibration.py Image calibration functions and a side-by-side view of the original and calibrated images ✔️
calibration/complete-calibration.py Same as above but with a cube rendered on top of the calibrated image ✔️
calibration/calibration.py Same as calibration/simple-calibration.py but keypoints and descriptors are generated for each poster and relevant information is saved to a JSON file ✔️
coeff.yml File with calibration values for my camera, generated by the scripts above ✔️
db.json File with the path for each poster image, their shape, generated keypoints and descriptors, as well as their title and rating ✔️
detection/detect-images-simple.py Recognizes an image from a calibrated camera capture ✔️
detection/detect-images-complete.py Same as above but the camera image is replaced by the detected poster image with title and cubes representing the movie rating ✔️
detection/detection.py Same as detect-images-simple.py but the title and cubes representing the movie rating appear on top of the detected poster ✔️
app.py Calls the functions defined above with CLI help and information ✔️

Calibration References:

Detection References:

Augmentation References:

About

This is a personal and well-commented set of scripts to learn OpenCV with a hands-on approach.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Languages