No project description provided
Project description
Python-TAWNYAPI
Documentation
- Find documentation under docs.tawny.ai
- More information about tawny.ai under info@tawny.ai
Simple Example with OpenCV
import cv2
from tawnyapi.vision.client import TawnyVisionApiClient
from tawnyapi.vision import apitypes
VIDEO_PATH = "<PATH TO YOUR VIDEO FILE>"
API_KEY = "<YOUR TAWNY API KEY>"
client = TawnyVisionApiClient(api_key=API_KEY)
cap = cv2.VideoCapture(VIDEO_PATH)
while True:
ret, frame = cap.read()
if not ret:
break
# Analyzing images already in memory:
result = client.analyze_images(
images=[frame],
max_results=1,
resize=None,
features=[
apitypes.ImageAnnotationFeatures.FACE_DETECTION,
apitypes.ImageAnnotationFeatures.FACE_EMOTION,
apitypes.ImageAnnotationFeatures.FACE_DESCRIPTOR,
apitypes.ImageAnnotationFeatures.HEAD_POSE,
apitypes.ImageAnnotationFeatures.FACE_LANDMARKS,
apitypes.ImageAnnotationFeatures.ATTENTION,
apitypes.ImageAnnotationFeatures.POSE
])
print(result)
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
tawnyapi-0.2.5.tar.gz
(7.6 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
File details
Details for the file tawnyapi-0.2.5.tar.gz.
File metadata
- Download URL: tawnyapi-0.2.5.tar.gz
- Upload date:
- Size: 7.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.1 CPython/3.8.12 Linux/5.4.0-84-generic
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a7e29db137ed10c2d2270c5e16c7fe93c83157f55303cd2f1d2d30d9fae5974a
|
|
| MD5 |
ef2224704872099a88fbd08f21836686
|
|
| BLAKE2b-256 |
d2f41e6f4fa2d7b6274c3a0e5509c428cd13230aba69fb6857c7d9cb8906aacb
|
File details
Details for the file tawnyapi-0.2.5-py3-none-any.whl.
File metadata
- Download URL: tawnyapi-0.2.5-py3-none-any.whl
- Upload date:
- Size: 9.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.1 CPython/3.8.12 Linux/5.4.0-84-generic
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3ca22ea794a5ffcb51df1282352945a270b67236f5e677cafa45de071caccd9d
|
|
| MD5 |
ab18ef0d784c9fbd36f512a1312f8bbd
|
|
| BLAKE2b-256 |
9b748b702f979e3f89ca9ed4cad17dbdbb0baba480445da0e7394cef447be57e
|