[ml] quantizer test harness

Michael C. Toren mct at toren.net
Tue Sep 1 06:39:13 UTC 2009


On Thu, Aug 27, 2009 at 11:44:30PM -0700, Michael C. Toren wrote:
> Unfortunately, the output is far from identical at the moment :/  I
> created three coordinate test files, wiigee-c/test_data/increment.dat,
> zeros.dat, and repeated.dat.  The first two are returning the wrong
> number of elements (8, which happens to be the number of states, rather
> than 20, the number of coordinates in the data file), which hopefully is
> an easy bug to correct.  The third file appears to cause the program to
> enter an infinite loop, which is more annoying.
> 
> So, we have some work to do.  But, at least we have some metrics to see
> how far along -- and how correct -- we are.

Through judicious use of printf and diff, I found and fixed all the bugs!

There's a new "make test" Makefile target that runs each test_data/*.dat
file through Quantizer.java and quantizer.c and confirms the outputs are
identical.  Every test is passing at the moment.  :-)

I could use help from others to:

    - Confirm the java test suite looks sane and is behaving correctly.
      If it isn't, we're confirming our C port against something bogus,
      which would utterly and completely suck.  Read through the short
      wiigee-c/javatest/TestHarness.java, and compare my copies of
      Gesture.java and Quantizer.java in wiigee-c/javatest/logic to
      those in the upstream wiigee distribution.

    - Populate wiigee-c/test_data with more test files.  Try to think
      of corner cases that may break us.

Thanks!
-mct



More information about the ml mailing list