GestureRecognitionToolkit  Version: 0.1.0
The Gesture Recognition Toolkit (GRT) is a cross-platform, open-source, c++ machine learning library for real-time gesture recognition.
ZeroCrossingCounter.h File Reference

Go to the source code of this file.

Classes

class  ZeroCrossingCounter
 

Detailed Description

Author
Nicholas Gillian ngill.nosp@m.ian@.nosp@m.media.nosp@m..mit.nosp@m..edu
Version
1.0

LICENSE

GRT MIT License Copyright (c) <2012> <Nicholas Gillian, Media Lab, MIT>

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

DESCRIPTION

The ZeroCrossingCounter class counts the number of zero crossings that occur in an N dimensional signal over a given window.

The ZeroCrossingCounter stores the incoming N dimensional signal in a circular buffer, it then computes two main features from the data in this buffer, these are: zero-crossing count: the number of times the derivative of the input signal crosses zero within the buffer zero-crossing magnitude: the absolute sum of the input signal at the locations where the derivative of the input signal crosses zero within the buffer

The ZeroCrossingCounter can compute these features in two modes: INDEPENDANT_FEATURE_MODE or COMBINED_FEATURE_MODE.

In INDEPENDANT_FEATURE_MODE the zero-crossing count and zero-crossing magnitude features will be computed independently for each of the N dimensions in the input signal. In COMBINED_FEATURE_MODE the zero-crossing count and zero-crossing magnitude features will be integrated across all of the N dimensions in the input signal. This means that if the ZeroCrossingCounter is set to INDEPENDANT_FEATURE_MODE, the size of the output feature vector will be 2 * N, where 2 is the two features (zero-crossing count and zero-crossing magnitude) and N is the number of dimensions in the input signal. Alternatively in COMBINED_FEATURE_MODE the size of the output vector will simply be 2, where 2 is the two features (zero-crossing count and zero-crossing magnitude). The feature modes can be set either in the ZeroCrossingCounter constructor or by using the setFeatureMode(UINT featureMode) function.

The ZeroCrossingCounter class is part of the Feature Extraction Modules.

Definition in file ZeroCrossingCounter.h.