Skip to content
/ mosse Public

Fast javascript correlation filters for tracking objects in video

License

Notifications You must be signed in to change notification settings

auduno/mosse

Repository files navigation

mosse

mosse.js is a javascript implementation of MOSSE correlation filters as described in Visual Object Tracking using Adaptive Correlation Filters by David Bolme. The library provides three prebuilt MOSSE filters for tracking of left and right eye and face, as well as tools for building your own filters. These three filters were trained on faces from the MUCT image database.

Video example (tracking of eyes) - Webcam example (tracking of eyes) - Webcam example (tracking of face)

Usage

To use with precreated filters, include build/mosse.js in your code:

<script src="js/mosse.js"></script>

then run the mossefilter on a canvas element:

var mfilter = new mosse.mosseFilter();
mfilter.load(mosse.filters.face_filter);
var mode = mfilter.track(element, left, top, width, height);
// returns mode of correlation filter output inside window, relative to midpoint of window
// where `element` is a canvas element, and `left`, `top`, `width` and `height` 
// define the window on the canvas element

You can also update filter during tracking, by setting final parameter to true:

mfilter.track(element, left, top, width, height, true);

About

Fast javascript correlation filters for tracking objects in video

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published