Buckets:
agent-collaborations/hutter-prize-67 / decoder-bundle-minimization /work /paq8px-src /src /PredictorMainLstmOnly.cpp
| | |
| PredictorMainLstmOnly::PredictorMainLstmOnly(Shared* const sh) : Predictor(sh) { | |
| models = new Models(sh, nullptr); | |
| } | |
| PredictorMainLstmOnly::~PredictorMainLstmOnly() { | |
| delete models; | |
| } | |
| uint32_t PredictorMainLstmOnly::p() { | |
| LstmModelContainer& lstm = models->lstmModelText(); // use the instance for Text so that loading/saving parameters would work properly | |
| lstm.next(); | |
| constexpr uint32_t scale = 1u << ArithmeticEncoder::PRECISION; | |
| uint32_t p = static_cast<uint32_t>(roundf(lstm.getp() * scale)); | |
| p = std::clamp(p, 1u, scale - 1u); | |
| return p; | |
| } | |
Xet Storage Details
- Size:
- 638 Bytes
- Xet hash:
- b04a4d7d7c547e00d8d144d5017331dc53864247312ff90e1c57b5c501ef91e5
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.