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

Function CheckColumWithMissingValue

tests/cpp/common/test_column_matrix.cc:94–102  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

92
93template <typename BinIdxType>
94void CheckColumWithMissingValue(const DenseColumnIter<BinIdxType, true>& col,
95 const GHistIndexMatrix& gmat) {
96 for (auto i = 0ull; i < col.Size(); i++) {
97 if (col.IsMissing(i)) {
98 continue;
99 }
100 EXPECT_EQ(gmat.index[gmat.row_ptr[i]], col.GetGlobalBinIdx(i));
101 }
102}
103
104TEST(ColumnMatrix, DenseColumnWithMissing) {
105 int32_t max_num_bins[] = {static_cast<int32_t>(std::numeric_limits<uint8_t>::max()) + 1,

Callers 1

TESTFunction · 0.85

Calls 3

GetGlobalBinIdxMethod · 0.80
SizeMethod · 0.45
IsMissingMethod · 0.45

Tested by

no test coverage detected