| 71 | } |
| 72 | |
| 73 | void TCtrValueTable::LoadThin(TMemoryInput* in) { |
| 74 | auto len = LoadSize(in); |
| 75 | auto ptr = in->Buf(); |
| 76 | in->Skip(len); |
| 77 | |
| 78 | using namespace flatbuffers; |
| 79 | Impl = TThinTable(); |
| 80 | auto& thin = std::get<TThinTable>(Impl); |
| 81 | auto ctrValueTable = flatbuffers::GetRoot<NCatBoostFbs::TCtrValueTable>(ptr); |
| 82 | ModelCtrBase.FBDeserialize(ctrValueTable->ModelCtrBase()); |
| 83 | CounterDenominator = ctrValueTable->CounterDenominator(); |
| 84 | TargetClassesCount = ctrValueTable->TargetClassesCount(); |
| 85 | |
| 86 | thin.IndexBuckets = TConstArrayRef<NCatboost::TBucket>( |
| 87 | reinterpret_cast<const NCatboost::TBucket*>(ctrValueTable->IndexHashRaw()->data()), |
| 88 | reinterpret_cast<const NCatboost::TBucket*>(ctrValueTable->IndexHashRaw()->data() + ctrValueTable->IndexHashRaw()->size()) |
| 89 | ); |
| 90 | thin.CTRBlob = TConstArrayRef<ui8>(ctrValueTable->CTRBlob()->data(), ctrValueTable->CTRBlob()->size()); |
| 91 | } |
no test coverage detected