"git@developer.sourcefind.cn:tianlh/lightgbm-dcu.git" did not exist on "790c1e33e690c2e11c12277e30e83644af268ba1"
Commit a194045c authored by Guolin Ke's avatar Guolin Ke Committed by GitHub
Browse files

fixed a bug in model output

parent 5d022898
......@@ -317,11 +317,9 @@ void GBDT::SaveModelToFile(bool is_finish, const char* filename) {
model_output_file_ << "Tree=" << i << std::endl;
model_output_file_ << models_[i]->ToString() << std::endl;
}
if (rest > 0) {
saved_model_size_ = rest;
}
saved_model_size_ = Common::Max(saved_model_size_, rest);
model_output_file_.flush();
// training finished, can close file
if (is_finish) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment