| 220 | } |
| 221 | |
| 222 | void DetectionLayer::serialize(void* buffer) const noexcept |
| 223 | { |
| 224 | auto* d = reinterpret_cast<uint8_t*>(buffer); |
| 225 | auto* const a = d; |
| 226 | write(d, mNbClasses); |
| 227 | write(d, mKeepTopK); |
| 228 | write(d, mScoreThreshold); |
| 229 | write(d, mIOUThreshold); |
| 230 | write(d, mMaxBatchSize); |
| 231 | write(d, mAnchorsCnt); |
| 232 | PLUGIN_ASSERT(d == a + getSerializationSize()); |
| 233 | } |
| 234 | |
| 235 | DetectionLayer::DetectionLayer(void const* data, size_t length) |
| 236 | { |