|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectrubine.Classifier
A classifier that implements rubine's algorithm to classify gestures.
Constructor Summary | |
Classifier()
|
Method Summary | |
void |
addClass(GestureClass d)
Adds a class of gestures to this classifier. |
GestureClass |
classify(Gesture g)
Recognizes a gesture. |
void |
compile()
Compiles this classifier (i.e. performs training). |
GestureClass |
createClass(java.lang.String name)
Creates a new class of gestures. |
GestureClass |
findClass(java.lang.String name)
Looks for the class of gestures labeled by a given name. |
static Classifier |
load(java.lang.String filename)
Builds a new classifier by loading its definition in a file. |
static Classifier |
newClassifier(java.lang.String file)
Builds a gesture classifier. |
Gesture |
newGesture()
Builds a new gesture to classify with this classifier. |
void |
removeClass(GestureClass d)
Removes a class of gestures from this classifier. |
void |
reset()
Resets this classifier (i.e. removes all the classes of gestures). |
void |
save(java.lang.String filename)
Saves the definition of this classifier in a file. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Classifier()
Method Detail |
public static Classifier newClassifier(java.lang.String file)
file
- The name of the file containing the definition of the classifier.
public Gesture newGesture()
public GestureClass createClass(java.lang.String name)
name
- The name of the new class of gestures.
public static Classifier load(java.lang.String filename)
filename
- The name of the file containing the definition of the classifier.
public void save(java.lang.String filename)
filename
- The name of the file where to write the definition of the classifier.public void reset()
public void addClass(GestureClass d)
d
- The class of gestures to add.public void removeClass(GestureClass d)
d
- The class of gestures to remove.public GestureClass findClass(java.lang.String name)
name
- The name of the class to look for.
public void compile()
public GestureClass classify(Gesture g) throws ClassifierNotTrainedException
g
- The gesture to recognize
ClassifierNotTrainedException
- If the classifier is not trained (compute
must have been called)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |