Contact: vpetricek@eharmony.com

Fix a bug in quadratic feature expansion (-q) when a namespace is missing for some examples. Predictions for such example and model may differ depending on the
previous examples. This is due to subsets not being cleared when an example is parsed in. Old value of subsets from previous example at that position in
delay_ring is reused.

This bug exists in the latest version on github (4.1+) as well as 3.0 (for which there exists a smaller testcase exhibiting the bug)

To replicate

input:
2048 examples with namespace 'l' to fill in the delay_ring and an example without namespace 'l' which will reuse a slot in delay_ring and also the 'subsets'.

--- file: input -----------------------------
0 |l C
1 |l C
[... cut 2045 same lines ...]
1 |l C
1 |g M:1
---------------------------------------------

Here is a script to train a model, make predictions the usual way and then predict for each example separately with a new instance of vw. If the predictions
differ we hit the bug.

 --- file: run.sh -----------------------------------------------------------------
 #!/bin/sh

 VW=vw41

         $VW --bit_precision 20 \
                              -d input \
                              --final_regressor model \
                              --learning_rate 0.1 \
                              -q lg \

 # 1. feed vowpal all data at once
 echo "unsafe testing"
 cat input | $VW -i model -t -p output.unsafe

 # 2. execute vowpal for each example separately
 echo "safe testing"
 > output.safe
 cat input |
 while read line
 do
         echo $line | $VW -t -i model -p output.line --quiet
         cat output.safe output.line > temp
         mv temp output.safe
         echo -n "."
 done
 rm output.line

 # compare the two prediction sets - if they differ we hit the bug
 diff -u output.safe output.unsafe
 ---------------------------------------------------------------------------
Merge pull request #23 from jhofman/master

shared learning state
updated install in Makefiles
nonormalize flag
safe labels for logistic and hinge
better bad label check
fix normalization bug from Frank Astier
mac cast problem
audit bug fixed
removed rand() which changes across platforms.  Bug from Frank
switched everything to use drand48() which is apparently cross platform with macs
fixed some minor memory deallocation
To be merged with main branch.
revert lihongs patch which due to extra stuff
better version of Lihong's patch
tweaked defaults
remove nonviable optimization methods from MF
VW builds on FreeBSD 8.2. Removed -pedantic from Makefile as it complained about long long not being available in ISO C++. Test 9 is failing.
fixed random bit adding bug from Matt
updated README