| 586 | } |
| 587 | |
| 588 | void DeSerializeMklDnnShape(const unsigned char* buf, size_t buf_size) { |
| 589 | // Make sure buffer holds at least is_mkl_tensor_. |
| 590 | CHECK(buf_size >= sizeof(data_.is_mkl_tensor_)) |
| 591 | << "Buffer size is too small in DeSerializeMklDnnShape"; |
| 592 | |
| 593 | const bool is_mkl_tensor = *reinterpret_cast<const bool*>(buf); |
| 594 | if (is_mkl_tensor) { // If it is an MKL Tensor then read the rest |
| 595 | CHECK(buf_size >= GetSerializeBufferSize()) |
| 596 | << "Buffer size is too small in DeSerializeMklDnnShape"; |
| 597 | data_ = *reinterpret_cast<const MklShapeData*>(buf); |
| 598 | } |
| 599 | } |
| 600 | }; |
| 601 | |
| 602 | // List of MklShape objects. Used in Concat/Split layers. |
no outgoing calls
no test coverage detected