| 1343 | |
| 1344 | template <typename T> |
| 1345 | TVector<size_t> MakeIndicesVector(const TConstArrayRef<T>& features) { |
| 1346 | TVector<size_t> indices; |
| 1347 | indices.reserve(features.size()); |
| 1348 | for (const auto& feature : features) { |
| 1349 | indices.push_back(SafeIntegerCast<size_t>(feature.Position.FlatIndex)); |
| 1350 | } |
| 1351 | return indices; |
| 1352 | } |
| 1353 | |
| 1354 | TVector<size_t> GetModelCatFeaturesIndices(const TFullModel& model) { |
| 1355 | return MakeIndicesVector(model.ModelTrees->GetCatFeatures()); |
no test coverage detected