Fix continue training in CLI

This commit is contained in:
tqchen
2016-03-10 12:42:54 -08:00
parent 845f80ec22
commit 96b17971ac
3 changed files with 17 additions and 11 deletions

View File

@@ -126,6 +126,9 @@ class GBTree : public GradientBooster {
CHECK_EQ(fi->Read(dmlc::BeginPtr(tree_info), sizeof(int) * mparam.num_trees),
sizeof(int) * mparam.num_trees);
}
this->cfg.clear();
this->cfg.push_back(std::make_pair(std::string("num_feature"),
common::ToString(mparam.num_feature)));
// clear the predict buffer.
this->ResetPredBuffer(num_pbuffer);
}