Partitioner for multi-target tree. (#8922)

This commit is contained in:
Jiaming Yuan
2023-03-16 18:49:34 +08:00
committed by GitHub
parent 26209a42a5
commit a093770f36
8 changed files with 239 additions and 178 deletions

View File

@@ -1,15 +1,17 @@
/**
* Copyright 2020-2023 by XGBoost contributors
*/
#include <gtest/gtest.h>
#include <vector>
#include <string>
#include <utility>
#include <vector>
#include "../../../src/common/row_set.h"
#include "../../../src/common/partition_builder.h"
#include "../../../src/common/row_set.h"
#include "../helpers.h"
namespace xgboost {
namespace common {
namespace xgboost::common {
TEST(PartitionBuilder, BasicTest) {
constexpr size_t kBlockSize = 16;
constexpr size_t kNodes = 5;
@@ -74,6 +76,4 @@ TEST(PartitionBuilder, BasicTest) {
ASSERT_EQ(n_right, (kBlockSize - rows_for_left_node[nid]) * tasks[nid]);
}
}
} // namespace common
} // namespace xgboost
} // namespace xgboost::common