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

Method GetAllocatedBytes

tensorflow/core/framework/tensor.cc:70–79  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

68REGISTER_UNARY_VARIANT_DECODE_FUNCTION(Tensor, "tensorflow::Tensor");
69
70bool TensorBuffer::GetAllocatedBytes(size_t* out_bytes) const {
71 AllocationDescription allocation_description;
72 FillAllocationDescription(&allocation_description);
73 if (allocation_description.allocated_bytes() > 0) {
74 *out_bytes = allocation_description.allocated_bytes();
75 return true;
76 } else {
77 return false;
78 }
79}
80
81namespace {
82

Callers 2

GetAllocatedBytesMethod · 0.45
AllocatedBytesMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected