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

Method ResetAllocations

tensorflow/lite/arena_planner.cc:53–61  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

51}
52
53TfLiteStatus ArenaPlanner::ResetAllocations() {
54 TF_LITE_ENSURE_STATUS(arena_.Clear());
55 TF_LITE_ENSURE_STATUS(persistent_arena_.Clear());
56 allocs_.clear();
57 allocs_.resize(graph_info_->num_tensors());
58 // Note that we only clear the alloc_queue_ when re-planning allocations, as
59 // it should only change when the graph topology itself changes.
60 return kTfLiteOk;
61}
62
63TfLiteStatus ArenaPlanner::PlanAllocations() {
64 // Invalidate any existing data.

Callers 3

SetGraphMethod · 0.80
AllocateTensorsMethod · 0.80
InvokeMethod · 0.80

Calls 4

ClearMethod · 0.45
clearMethod · 0.45
resizeMethod · 0.45
num_tensorsMethod · 0.45

Tested by 1

SetGraphMethod · 0.64