MCPcopy Create free account
hub / github.com/catboost/catboost / GetFeatureIdToDesc

Function GetFeatureIdToDesc

catboost/libs/eval_result/eval_result.cpp:36–49  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

34}
35
36static TFeatureIdToDesc GetFeatureIdToDesc(const TDataProvider& pool) {
37 TFeatureIdToDesc res;
38
39 const auto& poolFeaturesMetaInfo = pool.MetaInfo.FeaturesLayout->GetExternalFeaturesMetaInfo();
40
41 for (size_t index = 0; index < poolFeaturesMetaInfo.size(); ++index) {
42 res.emplace(
43 poolFeaturesMetaInfo[index].Name,
44 TFeatureDesc{index, poolFeaturesMetaInfo[index].Type == EFeatureType::Categorical}
45 );
46 }
47
48 return res;
49}
50
51namespace NCB {
52

Callers 1

InitializeColumnWriterFunction · 0.85

Calls 3

sizeMethod · 0.45
emplaceMethod · 0.45

Tested by

no test coverage detected