Remove hist builder class. (#9400)

* Remove hist build class.

* Cleanup this stateless class.

* Add comment to thread block.
This commit is contained in:
Jiaming Yuan
2023-07-22 10:43:12 +08:00
committed by GitHub
parent 0de7c47495
commit 22b0a55a04
6 changed files with 54 additions and 77 deletions

View File

@@ -48,12 +48,10 @@ void TestEvaluateSplits(bool force_read_by_column) {
std::iota(row_indices.begin(), row_indices.end(), 0);
row_set_collection.Init();
auto hist_builder = common::GHistBuilder(gmat.cut.Ptrs().back());
hist.Init(gmat.cut.Ptrs().back());
hist.AddHistRow(0);
hist.AllocateAllData();
hist_builder.template BuildHist<false>(row_gpairs, row_set_collection[0],
gmat, hist[0], force_read_by_column);
common::BuildHist<false>(row_gpairs, row_set_collection[0], gmat, hist[0], force_read_by_column);
// Compute total gradient for all data points
GradientPairPrecise total_gpair;