Coumputer Vision helping Library
Project description
CVLearn
An easy-to-use package that helps with hand tracking, face detection, and more using OpenCV and Mediapipe.
Features
Core Features
- Hand Tracking - Real-time hand pose detection and tracking
- Face Detection - Multi-face detection and bounding boxes
- Face Mesh - Detailed facial landmarks
- Finger Counting - Single and dual-hand finger detection
- Pose Detection - Full body pose estimation
- Gesture Recognition - Gesture recognition with combo detection and velocity-based gestures
Installation
- Use Python 3.6+
- Open your terminal or command prompt and run:
pip install cvlearn
Install Dependencies (if needed)
pip install mediapipe opencv-python numpy
Hand Tracking
from cvlearn import HandTrackingModule as handTracker
import cv2
cap = cv2.VideoCapture(0)
detector = handTracker.handDetector()
while True:
ret, img = cap.read()
img = detector.findHands(img)
cv2.imshow("Result", img)
cv2.waitKey(1)
Result:
Face Detection
from cvlearn import FaceDetection as faceDetector
import cv2
cap = cv2.VideoCapture(0)
detector = faceDetector.FaceDetector()
while True:
ret, img = cap.read()
img = detector.findFaces(img)
cv2.imshow("Result", img)
cv2.waitKey(1)
Result:
Side View:
Face Mesh
from cvlearn import FaceMesh as fms
import cv2
cap = cv2.VideoCapture(0)
detector = fms.FaceMeshDetector()
while True:
ret, img = cap.read()
img, face = detector.findFaceMesh(img)
cv2.imshow("Result", img)
cv2.waitKey(1)
Result:
Finger Counting
from cvlearn import FingerCounter as fc
import cvlearn.HandTrackingModule as handTracker
import cv2
cap = cv2.VideoCapture(0)
detector = handTracker.handDetector(maxHands=1)
counter = fc.FingerCounter()
while True:
ret, frame = cap.read()
frame = cv2.flip(frame, 180)
frame = detector.findHands(frame)
lmList, bbox = detector.findPosition(frame)
if lmList:
frame = counter.drawCountedFingers(frame, lmList, bbox)
cv2.imshow("res", frame)
key = cv2.waitKey(1)
if key == 27:
break
cv2.destroyAllWindows()
Result:
Two Hands Finger Counting
from cvlearn import TwoHandsFingerCounter as fc
import cv2
cap = cv2.VideoCapture(0)
counter = fc.FingerCounter()
while True:
ret, frame = cap.read()
frame = counter.drawCountedFingers(frame)
cv2.imshow("res", frame)
key = cv2.waitKey(1)
if key == 27:
break
cv2.destroyAllWindows()
Result:
Pose Detection
import cv2
import cvlearn
from cvlearn import PoseDetector, Utils
Gesture Recognition
import cv2
from cvlearn import GestureRecognizer
cap = cv2.VideoCapture(0)
detector = GestureRecognizer(maxHands=2)
while True:
ret, frame = cap.read()
frame = detector.findHands(frame)
gesture, confidence = detector.recognizeGesture(frame)
frame = detector.drawGestureInfo(frame, gesture, confidence)
cv2.imshow("Result", frame)
key = cv2.waitKey(1)
if key == 27:
break
cv2.destroyAllWindows()
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
cvlearn-0.5.3.tar.gz
(11.0 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
cvlearn-0.5.3-py3-none-any.whl
(14.9 kB
view details)
File details
Details for the file cvlearn-0.5.3.tar.gz.
File metadata
- Download URL: cvlearn-0.5.3.tar.gz
- Upload date:
- Size: 11.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bf7ac125a9a684d80a1f758ce15af5ca700a8c24626b66d63ed43b4324844d44
|
|
| MD5 |
d70870b0f6e0c855aff0570b86e036dd
|
|
| BLAKE2b-256 |
2a06c6a31cc1c39bc098b4a2eb67e4ff4529010430e263c51a9b41182d85d69e
|
File details
Details for the file cvlearn-0.5.3-py3-none-any.whl.
File metadata
- Download URL: cvlearn-0.5.3-py3-none-any.whl
- Upload date:
- Size: 14.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7737a32c334f130894aec0886a76e726e326c0610120971ccbdceb62a760ed63
|
|
| MD5 |
b5994eec4e2df9036d9094e5d54572b7
|
|
| BLAKE2b-256 |
50380cf88c399a00570bf854aafef599e800443299c6ad46cd8e68c167e0909b
|