".github/vscode:/vscode.git/clone" did not exist on "5a1fe74ecdc2e520265e0fd8e439f5d602dacf8f"
Commit fb8d2eb7 authored by Zibi789's avatar Zibi789 Committed by Guolin Ke
Browse files

It fixes the bug in ResetGoss (issue #1192) (#1193)

parent 195d9531
......@@ -14,6 +14,7 @@
#include <string>
#include <fstream>
#include <chrono>
#include <algorithm>
namespace LightGBM {
......@@ -75,6 +76,7 @@ public:
is_use_subset_ = false;
if (gbdt_config_->top_rate + gbdt_config_->other_rate <= 0.5) {
auto bag_data_cnt = static_cast<data_size_t>((gbdt_config_->top_rate + gbdt_config_->other_rate) * num_data_);
bag_data_cnt = std::max(1, bag_data_cnt);
tmp_subset_.reset(new Dataset(bag_data_cnt));
tmp_subset_->CopyFeatureMapperFrom(train_data_);
is_use_subset_ = true;
......
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