| 45 | data.emplace_back(static_cast<uint8_t>(static_cast<int8_t>((value * 2 - 1) * 128))); |
| 46 | } |
| 47 | void writeEnergy(std::vector<uint8_t>& data, float value) |
| 48 | { |
| 49 | writeFloat(data, (value - 150.0f) / 100); |
| 50 | } |
| 51 | void writeNeuronProperty(std::vector<uint8_t>& data, float value) |
| 52 | { |
| 53 | value = std::max(-3.9f, std::min(3.9f, value)); |
no test coverage detected