npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

object-detect

v2.0.0-alpha.2

Published

Native JavaScript Object Detection

Downloads

1

Readme

js-objectdetect

js-objectdetect is a javascript library for real-time object detection.

This library is based on the work of Paul Viola and Rainer Lienhart and compatible to stump based HAAR cascade classifiers used by the OpenCV object detector.

Watch this video for a short demonstration.

All modern browsers including IE 9+, Safari and Opera Mobile are supported.

Examples

js-objectdetect can be used for object detection, tracking and, in combination with mordern HTML5 features such as WebRTC, for all sorts of augmented reality applications that run in the browser without any plugin.

The following demos are available (Internet Explorer and iOS not supported):

gesture input Rotating a 3D object via hand gesture

gesture scroll Scrolling a website via hand gesture

glasses Trying out various sunglasses

Classifiers

js-objectdetect is compatible to stump based classifiers used by OpenCV. Classifiers for face, hand and eye detection are already included. More can be found on the web (classifier repository). However, not all classifiers have the same performance and some are quite sensitive to lighting conditions. Cascades have to be converted into the js-objectdetect format before usage. The cascade format is similar to that of tracking.js. Converters for old and new style OpenCV xml haarcascades are available.

Performance

The following list provides a runtime and detection performance comparison among current JavaScript face detection libraries. All test results have been acquired by applying either a 24x24 stump-based HAAR cascade or, in case of CCV, a 24x24 SURF cascade classifier with minimum step size on a single scale 80x80 image. Measured times are summed over 100 executions.

Last updated on February 7, 2015

Chrome 40 / FF 35 | Detections per Second | Detections | Seconds ------------------- |:---------------------:|:----------:|:-------: js-objectdetect | 17.5 / 16.9 | 50 / 50 | 2.86 / 2.96 jsfeat1 | 9.4 / 6.3 | 30 / 30 | 3.18 / 4.75 tracking.js | 7.7 / 8.97 | 48 / 48 | 6.24 / 5.35 Beyond Reality Face2 | 7.4 / 1.7 | 41 / 41 | 5.50 / 23.98 CCV3 | 2.2 / 4.4 | 8 / 8 | 2.22 / 1.80

js-objectdetect | tracking.js | jsfeat1 | Beyond Reality Face2 | CCV3 :---:|:---:|:---:|:---:|:---: Detections | Detections | Detections | Detections | Detections

1 also auduno/clmtrackr, camgaze.js. Based on an older version of js-objectdetect.

2 Proprietary software, tested with v3.0.15. Fails to compile asm module in FF.

3 also jquery.facedetection, neave/face-detection, wesbos/HTML5-Face-Detection, auduno/headtrackr

Usage

Examples can be found in the repository. For documentation, refer to the JSDoc in the source files.

Download

License

js-objectdetect is distributed under MIT license. The included classifiers are subject to their own licenses.

Credits

Thanks to Audun Mathias Øygard (auduno) for his inspirational headtrackr library, Brandon Jones (toji) for his valuable javascript performance tipps, Nikos (foo123) for his port of JViolaJones on which the canny pruning algorithm is based on and tracking.js for the classifier format.