MCPcopy Create free account
hub / github.com/dmlc/xgboost / CheckIndexData

Function CheckIndexData

tests/cpp/common/test_hist_util.cc:140–145  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

138
139template <typename T>
140void CheckIndexData(T const* data_ptr, uint32_t const* offsets, const GHistIndexMatrix& hmat,
141 size_t n_cols) {
142 for (size_t i = 0; i < hmat.index.Size(); ++i) {
143 EXPECT_EQ(data_ptr[i] + offsets[i % n_cols], hmat.index[i]);
144 }
145}
146
147TEST(HistUtil, IndexBinData) {
148 uint64_t constexpr kBinSizes[] = {

Callers 1

TESTFunction · 0.85

Calls 1

SizeMethod · 0.45

Tested by

no test coverage detected