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

Function TrainModelOnPool

catboost/libs/model/ut/leaf_weights_ut.cpp:71–93  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

69}
70
71static TFullModel TrainModelOnPool(TDataProviderPtr pool, ETargetDimMode multiclass) {
72 TFullModel model;
73 TEvalResult evalResult;
74 NJson::TJsonValue params;
75 params.InsertValue("iterations", 5);
76 if (multiclass) {
77 params.InsertValue("loss_function", "MultiClass");
78 }
79 TrainModel(
80 params,
81 nullptr,
82 Nothing(),
83 Nothing(),
84 Nothing(),
85 TDataProviders{pool, {pool}},
86 /*initModel*/ Nothing(),
87 /*initLearnProgress*/ nullptr,
88 "",
89 &model,
90 {&evalResult});
91
92 return model;
93}
94
95static TFullModel SaveLoadCBM(const TFullModel& trainedModel) {
96 TStringStream strStream;

Callers 1

RunTestWithParamsFunction · 0.85

Calls 2

NothingFunction · 0.85
TrainModelFunction · 0.50

Tested by

no test coverage detected