Implement GK sketching on GPU. (#5846)
* Implement GK sketching on GPU. * Strong tests on quantile building. * Handle sparse dataset by binary searching the column index. * Hypothesis test on dask.
This commit is contained in:
@@ -117,7 +117,7 @@ inline void TestBinDistribution(const HistogramCuts &cuts, int column_idx,
|
||||
|
||||
// First and last bin can have smaller
|
||||
for (auto& kv : bin_weights) {
|
||||
EXPECT_LE(std::abs(bin_weights[kv.first] - expected_bin_weight),
|
||||
ASSERT_LE(std::abs(bin_weights[kv.first] - expected_bin_weight),
|
||||
allowable_error);
|
||||
}
|
||||
}
|
||||
@@ -189,7 +189,7 @@ inline void ValidateCuts(const HistogramCuts& cuts, DMatrix* dmat,
|
||||
// Collect data into columns
|
||||
std::vector<std::vector<float>> columns(dmat->Info().num_col_);
|
||||
for (auto& batch : dmat->GetBatches<SparsePage>()) {
|
||||
CHECK_GT(batch.Size(), 0);
|
||||
ASSERT_GT(batch.Size(), 0);
|
||||
for (auto i = 0ull; i < batch.Size(); i++) {
|
||||
for (auto e : batch[i]) {
|
||||
columns[e.index].push_back(e.fvalue);
|
||||
|
||||
Reference in New Issue
Block a user