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

Method FillAllocationDescription

tensorflow/c/tf_tensor.cc:86–91  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

84 size_t size() const override { return len_; }
85 TensorBuffer* root_buffer() override { return this; }
86 void FillAllocationDescription(
87 tensorflow::AllocationDescription* proto) const override {
88 tensorflow::int64 rb = size();
89 proto->set_requested_bytes(rb);
90 proto->set_allocator_name(tensorflow::cpu_allocator()->Name());
91 }
92
93 // Prevents input forwarding from mutating this buffer.
94 bool OwnsMemory() const override { return false; }

Callers

nothing calls this directly

Calls 3

cpu_allocatorFunction · 0.85
sizeFunction · 0.50
NameMethod · 0.45

Tested by

no test coverage detected