try interact mode

This commit is contained in:
tqchen
2014-03-05 15:28:53 -08:00
parent 2bdcad9630
commit ef5a389ecf
7 changed files with 142 additions and 24 deletions

1
demo/test/README Normal file
View File

@@ -0,0 +1 @@
test folder to test new functions

View File

@@ -4,9 +4,31 @@ python mapfeat.py
# split train and test
python mknfold.py agaricus.txt 1
# training
../../xgboost mushroom.conf
# this is what dump will looklike without feature map
../../xgboost mushroom.conf task=dump model_in=0003.model name_dump=dump.raw.txt
../../xgboost mushroom.conf num_round=1 model_out=full.model bst:max_depth=3
../../xgboost mushroom.conf task=dump model_in=full.model fmap=featmap.txt name_dump=dump.full.txt
# training
../../xgboost mushroom.conf num_round=1 model_out=m1.model bst:max_depth=1
# this is what dump will looklike with feature map
../../xgboost mushroom.conf task=dump model_in=0003.model fmap=featmap.txt name_dump=dump.nice.txt
cat dump.nice.txt
../../xgboost mushroom.conf task=dump model_in=m1.model fmap=featmap.txt name_dump=dump.m1.txt
# interaction
../../xgboost mushroom.conf task=interact model_in=m1.model model_out=m2.model interact:booster_index=0 bst:interact:expand=1
../../xgboost mushroom.conf task=interact model_in=m2.model model_out=m3.model interact:booster_index=0 bst:interact:expand=2
# this is what dump will looklike with feature map
../../xgboost mushroom.conf task=dump model_in=m2.model fmap=featmap.txt name_dump=dump.m2.txt
../../xgboost mushroom.conf task=dump model_in=m3.model fmap=featmap.txt name_dump=dump.m3.txt
echo "========m1======="
cat dump.m1.txt
echo "========m2========"
cat dump.m2.txt
echo "========m3========"
cat dump.m3.txt
echo "========full======="
cat dump.full.txt