MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / DeSerializeMklDnnShape

Method DeSerializeMklDnnShape

tensorflow/core/util/mkl_util.h:588–599  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

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.

Callers 2

GetMklShapeFunction · 0.80
GetMklShapeListFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected