[ml] Hacking tonight?

Michael C. Toren mct at toren.net
Wed Sep 2 23:43:01 UTC 2009


On Wed, Sep 02, 2009 at 03:55:41PM -0700, Josh Myer wrote:
> Tonight, we'll be (and by we, I mean Ted and I =) ) trying to put more
> bindings and infrastructure around the great code Jim and Michael have
> been putting together.  At that point, we'll be in a good place to
> start wrapping up integration and get to a release candidate quickly,
> with any luck.
> 
> 2169, 8PM, if you'd like to come help with autotools-ification or swig
> bindings.

I'll be there tonight (but probably not next week).

I did some more integration work on my flight yesterday.  I copied
Jim's HMM code to the wiigee-c directory, and then implemented the Java
GestureModel class as gesturemodel.c.  (In the Java code, the GestureModel
class is the one that calls into the Quantizer and HMM classes).  It
compiles, but I don't have a good sense of how GestureModel is used, so
I don't have any tests around it yet.  If we could try to flowchart the
call chain tonight, I can try to implement more of it this week.  But,
we'll see how things go with the swig bindings.

Also, I broke out some of quantizer.c into separate C files, so that we
now have one C file for each struct (and where each struct is closely
related to a Java class we're porting).  I also started to standardize
the naming convention for now we construct and destroy these structs. 
For example, quantizer_new() returns a pointer to a newly allocated
struct quantizer, and quantizer_free() destroys it.  Similarly, we
have hmm_new(), gesture_new(), observation_new(), etc.

The other file naming convention I introduced is having a standalone
binary encapsulating a test suite for each struct.  For example,
quantizer_test.c has a main() function that calls into quantizer.c to
implement the unit tests, and I moved Jim's main() function from hmm.c
to hmm_test.c.

The C files we have right now, in wiigee-c:

     util.c                 Random utility functions

     gesture.c              struct gesture (consumed by quantizer.c)

     observation.c          struct observation (returned by quantizer.c)

     quantizer.c            struct quantizer

     hmm.c                  struct HmmState

     gesturemodel.c         struct gesturemodel

     quantizer_test.c       quantizer.c unit tests

     hmm_test.c             hmm.c unit tests

     gesturemodel_test.c    gesturemodel.c unit tests (unimplemented;
                            today it's just a "Hello world" program)

And, ofcourse, we can change any of this around if we want to do it
another way instead.

-mct



More information about the ml mailing list