Coder Social home page Coder Social logo

opencv_tests's Introduction

Tests with OpenCV Python library

This is the test code made with OpenCV Computer Vision library. This project does not have any purpose, it is only necessary for my own training in learning Python from scratch and testing the possibilities of computer vision and artificial intelligence. Over time, new tests will appear here. This repository is purely for history and progress tracking.

To install OpenCV library use pip install opencv-python in console and import it to project by import cv2.

Human face recognition

Human face recognition was implemented both from the image and from the webcam. To implement this function, a file with presets for recognition is used, which available in the OpenCV library and on it’s GitHub (pre-trained models based on neural networks). For the first two tests, I used a trained model for recognising the frontal image of a face in a photo, which allows head rotation up to 30 degrees.

1. faceCaptureImg.py

Capturing face from image

An image from a photo stock, where people are in comfortable poses and look directly at the camera, is processed without problems and faces are recognised without error.

2. faceCaptureWebcam.py

Capturing face from webcam Capturing face from webcam with mask

Of course, in order to correctly recognise the face, you need to choose the appropriate positions for yourself and the webcam. In most cases this is what happens. Unexpectedly, the system worked several times with a mask on my face, but this does not always happen correctly.

opencv_tests's People

Contributors

only1avetrill avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.