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

Method GetContainer

tensorflow/core/common_runtime/scoped_allocator_mgr.cc:139–151  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

137}
138
139ScopedAllocatorContainer* ScopedAllocatorMgr::GetContainer(int64 step_id) {
140 VLOG(2) << "GetContainer " << step_id << " on " << device_name();
141 ScopedAllocatorContainer* sac = nullptr;
142 mutex_lock l(mu_);
143 auto it = per_step_map_.find(step_id);
144 if (it == per_step_map_.end()) {
145 sac = new ScopedAllocatorContainer(this, step_id);
146 per_step_map_[step_id] = sac;
147 } else {
148 sac = it->second;
149 }
150 return sac;
151}
152
153Status ScopedAllocatorMgr::AddScopedAllocator(
154 const Tensor& backing_tensor, int64 step_id, int32 scope_id,

Callers 5

SaveInstancesMethod · 0.80
TEST_FFunction · 0.80
GetScopedAllocatorMethod · 0.80
gpu_device.ccFile · 0.80
PrepOpFunction · 0.80

Calls 2

findMethod · 0.45
endMethod · 0.45

Tested by 3

SaveInstancesMethod · 0.64
TEST_FFunction · 0.64
PrepOpFunction · 0.64