You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

facr

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

facr

Detects faces in images and returns a focal point

2.1.0
latest
Source
npmnpm
Version published
Weekly downloads
15
400%
Maintainers
1
Weekly downloads
 
Created
Source

facr

Detects faces in images and returns a focal point. Is used to crop the right part of an image. You should use this in conjunction with the ee-image-worker package which has support for cropping using focal points.

npm Travis node

The Python script bin/detect is licenced unter the GPL2 Licence. The file was copied from https://gitlab.com/wavexx/facedetect

installation

You have first to install native dependecies

ubuntu linux
sudo apt -y install python python3-opencv libopencv-dev python3-numpy

API

const FaceDetection = require('facr');

// create an instance
const detector = new FaceDetection();


// get focal point for an image
const focalPoint = await detector.detect(imageBuffer);

if (focalPoint) console.log('Yeah, we got it! x %s, y %s :)', focalPoint.x, focalPoint.y);
else console.log('sorry, failed to detect any faces in this image ...'');

Keywords

face-detection

FAQs

Package last updated on 05 Jul 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts